Monday, July 7, 2008

Installing OpenScientist

OpenScientist is a full C++ implementation of AIDA. I was having big problems using Java on 64 bit machines reliably so switched to this instead of AIDAJNI.
To install, first download from openscientist.lal.in2p3.fr. I went for the "batch" version, which is basically the simple version without any GUI stuff for batch processing.
The installation instructions weren't particularly to the point so I'll recap what I did briefly (obviously change the version number if appropriate):
unzip osc_batch_source_v16r4.zip
cd OpenScientist/v16r4/osc_batch/v16r4/obuild
source setup.sh
./sh/build
./sh/build_release

I think that builds everything (there is more to OpenScientist than just an AIDA implementation), but it's easier than figuring out which bits you actually need.

To use it with the lcio software you need a CMake module. I wrote one with all the library and include directories hard coded into it; it would be nice if I wrote a proper self-detecting one but I haven't had the time. You can find out the compiler flags for AIDA with the utility "<location>/OpenScientist/v16r4/osc_batch/v16r4/bin_obuild/osc_batch/v16r4/bin/aida-config".

My module is here, obviously you'll need to change the directories to match your system. I called the module FindBatchLab.cmake, so then all you have to do is put that module in with the other CMake modules and change the dependencies in your projects CMakeLists.txt file from "AIDAJNI" to "BatchLab".

IMPORTANT NOTE FOR JAS USERS - BatchLab puts empty histograms/clouds etcetera into the AIDA file, which JAS doesn't like (e.g. if you create a histogram and didn't fill it with anything). I modified the file "OpenScientist/v16r4/BatchLab/v1r2p1/source/XML/XML_DataWriter.cxx" to this. Copy my file over the original before building if you want to use JAS to analyse your AIDA files. The xml schema says there should be at least one entry for clouds/histograms/etc, so I think the JAS way is the correct way.

No comments: