HepMC
2.05 I/O Issues

HepMC Savannah ] [ HepMC Homepage ] [ Downloads ]

Proposed Changes ]
Status Codes ] [ Barcodes ] [ Vector Methods ] [ Cross Section ] [ IO Issues ] [ Other Issues ]
User Manual ] [ Doxygen Reference Manual ]

Please use Savannah sr #106971 for comments.

IO_Ascii

IO_Ascii has been deprecated since release 2.02.00. Further, IO_Ascii does not persist all information in a GenEvent, and in particular does not persist the unit information. Therefore, as agreed during the HepMC 2.04 discussion, IO_Ascii will be removed from HepMC. Any existing files written by IO_Ascii can be read by IO_GenEvent.

This is a firm proposal.

Ascii Output Precision

There is a request (bug #41602) to allow users to set the precision of data saved by IO_GenEvent. This could dramatically decrease the size of the output data file.

This proposal was accepted. A precision() method was added to IO_GenEvent.

Enable Standard Stream I/O

There is a request to be able to access the state of an active stream. This request can be satisfied by providing the standard IO operators:

This proposal was accepted.

IO_GenEvent now uses these methods.

The new streaming I/O operators do not set precision. The user must call the stream precision operator explicitly. Note that the default precision of IO_GenEvent is precision(16). Also, when using operator <<, the begin and end block lines are not written unless the user calls write_HepMC_IO_block_begin( output_stream ) and write_HepMC_IO_block_end( output_stream )

Reading NaN's

HepMC ascii IO does not deal gracefully with NaN's or other invalid data in an input file. It simply stops processing. IO_GenEvent will be modified so that processing can continue when invalid data is encountered. Any events with invalid data will be skipped. Since the event loop is controlled by the user, it will be up to the user to decide whether or not to continue.

This proposal was accepted.

Please use Savannah sr #106971 for comments.