[Halld-offline] MD5 Geometry checksum added to HDDS and HDGeant

Mark M. Ito marki at jlab.org
Fri Nov 9 10:13:23 EST 2012


Is there any enforcement of consistency?

On 11/08/2012 08:59 AM, David Lawrence wrote:
> Hi Offliners,
>
>     I have recently committed a series of changes to our code repository that
> implement a means of calculating an md5 checksum of the HDDS XML
> files used of the geometry. The changes are in HDDS, HDDM, and HDGeant.
> Therefore, if you update either HDDS or sim-recon, you should updated the
> other as well to get a working system.
>
>     The primary motivation of this is to provide a way to check that the
> geometry used to produce an hddm file matches the geometry in an existing
> set of XML files. Development of new experiments or any other exercise that
> may require optimization of the geometry should find this an important
> bookkeeping tool.
>
>     This is related to a change I committed last week that provides an option
> in hdgeant to dynamically generate, compile, and link the geometry from
> the XML source at run time.
>
> Some details:
>
> - The hdds tools that generate the FORTRAN and C++(root) code using
>      the XML files for input now produce a md5geom() subroutine as part of
>      the generated code. This subroutine returns the md5 checksum for the
>      geometry used to generate that code.
>
> - A single checksum is produced for the entire set of XML files that are
>      used. The checksum calculation is integrated with the Xerces parser so
>      that as the parser includes files, they are added to the checksum
> (the order of
>      the files is thus important but is handled by Xerces).
>
> - The simulation HDDM format (class="s") was modified to include places
>      for geometry md5 checksums for hdgeant, mcsmear, and the dana
>      analysis program. Currently, only hdgeant fills in this value (mcsmear
>      has a lot of hard-coded geometry). The new geometry tag is only written
>      out for the first event.
>
> - The hdgeant program has been modified to allow command line arguments.
>      One is "-xml" which will generate, compile, and dynamically link
> geometry
>      based on the XML source in the directory pointed to by the HDDS_HOME
>      environment variable.
>      Another is "-checksum" which will print the md5 checksum for the
> geometry
>      to be used and then exit. If the -xml option is given along with the
>      -checksum option, then the generate,compile,link cycle is performed
>      first and the checksum obtained from the shared object.
>
> - A new hdds-md5 tool was added to allow you to quickly calculate the
>      md5 checksum of the current set of XML files so you can compare to
>      the one recorded in the hddm file.
>
>
> If you experience any trouble or have questions or comments, please
> contact me.
>
> Regards,
> -David
> _______________________________________________
> Halld-offline mailing list
> Halld-offline at jlab.org
> https://mailman.jlab.org/mailman/listinfo/halld-offline
>

-- 
Mark M. Ito
Jefferson Lab
marki at jlab.org
(757)269-5295



More information about the Halld-offline mailing list