GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » Fairroot » General Discussion » Geant4 not working with mc generation
Geant4 not working with mc generation [message #13688] Mon, 02 July 2012 16:57 Go to next message
Raghav Kunnawalkam is currently offline  Raghav Kunnawalkam
Messages: 63
Registered: February 2012
Location: Stony Brook, New York
continuous participant
From: *physics.sunysb.edu
Hi All

I was doing mc simulations based on the examples given in fairroot and i have just noticed that i was using TGeant3 for all my stuff. I changed it to TGeant4 to see whats the difference since i was told the Geant4 has much better implementation of physics process for particles through a medium and it looks like my program is not able to see it. But i am very sure that my geant4 is properly defined.


here is the error message:

Loading Geant4 global libraries ...Our Macro
sh: /Users/raghav/fairsoft/bin/geant4-config: No such file or directory
Error in <TUnixSystem::GetFromPipe>: command "$SIMPATH/bin/geant4-config --libs" returned 32512
Loading VGM libraries ...
Loading g4root library ...
dlopen error: dlopen(/Users/raghav/fairsoft/transport/geant4_vmc/lib/libg4root.so, 9): Symbol not found: __ZTI27G4VUserDetectorConstruction
Referenced from: /Users/raghav/fairsoft/transport/geant4_vmc/lib/libg4root.so
Expected in: flat namespace
in /Users/raghav/fairsoft/transport/geant4_vmc/lib/libg4root.so
Load Error: Failed to load Dynamic link library /Users/raghav/fairsoft/transport/geant4_vmc/lib/libg4root.so
Warning: Return value of void g4libs_global() ignored /Users/raghav/fairsoft/transport/macro/g4libs.C:135:
Error: Symbol TG4RunConfiguration is not defined in current scope /Users/raghav/fairroot/example/gconfig/g4Config.C:29:
Error: Symbol TG4RunConfiguration is not defined in current scope /Users/raghav/fairroot/example/gconfig/g4Config.C:29:
Error: type TG4RunConfiguration not defined FILE:/Users/raghav/fairroot/example/gconfig/g4Config.C LINE:29
Error: Invalid type 'TG4RunConfiguration*' in declaration of 'runConfiguration' /Users/raghav/fairroot/example/gconfig/g4Config.C:29:
*** Interpreter error recovered ***
SetCuts Macro: Setting Processes..
Error: illegal pointer to class object gMC 0x0 3002 /Users/raghav/fairroot/example/gconfig/SetCuts.C:23:
*** Interpreter error recovered ***

*** Break *** segmentation violation

I appreciate the help guys,
Cheers
Raghav
Re: Geant4 not working with mc generation [message #13690 is a reply to message #13688] Tue, 03 July 2012 09:00 Go to previous messageGo to next message
Mohammad Al-Turany is currently offline  Mohammad Al-Turany
Messages: 518
Registered: April 2004
Location: GSI, Germany
first-grade participant
From: *gsi.de
Hi,

As you install the externals, did you choose to install in a separate directory? can you check the log files of installation to see if Geant4 was installed without errors? in the source directory of the externals can you type "svn info" and post the output here?

Mohammad
Re: Geant4 not working with mc generation [message #13694 is a reply to message #13690] Tue, 03 July 2012 15:52 Go to previous messageGo to next message
Raghav Kunnawalkam is currently offline  Raghav Kunnawalkam
Messages: 63
Registered: February 2012
Location: Stony Brook, New York
continuous participant
From: *physics.sunysb.edu
Hi Mohammad

UPDATE:: I got it working now, It was just a simple path mistake.
Thanks for your help.


When i installed fairsoft, i selected the option of installing them in their source directories itself.

Here is the log file from my last installation:
OpenGL found on this system
C++ compiler found in PATH
*** Compiling the external packages with the GCC compiler
*** Building the libraries with best optimization
The following parameters are set.
System : 64bit
C++ compiler : g++
C compiler : gcc
Fortran compiler : gfortran
CXXFLAGS : -O3
CFLAGS : -O3
Compiler : gcc
Debug : no
Optimization : yes
Platform : macosx
Architecture : macosx64
G4System : Darwin-g++
g4_data_files : yes
g4_get_data : no
Number of parallel
processes for build : 4
Found cmake version 2.8.7 which is newer than the
required version 2.8.2 in PATH
This version is okay. Don't install cmake as external package.
*** Package gtest is OK ***
*** Package glpk is OK ***
*** Package gsl is OK ***
*** Package Boost is OK ***
*** Package ApMon is OK ***
*** Package ml-gsoapclient is OK ***
*** Package Pythia6 is OK ***
*** Package pythia8 is OK ***
*** Package Clhep is OK ***
*** Package Geant4-Source is OK ***
*** Package Geant4-lib is OK ***
**** Installing the Geant4 data files ****
*** Package G4EMLOW already unpacked ***
*** Package G4NDL already unpacked ***
*** Package RadioactiveDecay already unpacked ***
*** Package PhotonEvaporation already unpacked ***
*** Package G4ABLA already unpacked ***
*** Package RealSurface already unpacked ***
*** Package G4NEUTRONXS already unpacked ***
*** Package G4PII already unpacked ***
*** Compiling root ................
Copied rootconfig.sh ......................
Configure Root ..........................................
*** root compiled successfully ***
*** Package pluto is OK ***
*** Package Geant3 is OK ***
*** Package VGM is OK ***
*** Package Geant4_VMC is OK ***
*** End installation of external packages without Errors***

It says that geant4 is installed properly. I think that there is something wrong with my libraries path.

This is the output that you asked for, in the source directory fairsoft.
raghav:fairsoft raghav$ svn info
Path: .
URL: https://subversion.gsi.de/fairroot/fairsoft/trunk
Repository Root: https://subversion.gsi.de/fairroot
Repository UUID: 0381ead4-6506-0410-b988-94b70fbc4730
Revision: 15305
Node Kind: directory
Schedule: normal
Last Changed Author: uhlig
Last Changed Rev: 15284
Last Changed Date: 2012-04-16 08:13:00 -0400 (Mon, 16 Apr 2012)

Cheers
Raghav

UPDATE::

I played around with the libraries and copied the geant4-config file to the spot that it wanted and now it looks like it can see geant4 or atleast most of it.

I am having some problems regarding specific files, namely the data file for low energy EM processes. I tried getting the new data file and unpacked it and placed it in the place of the old one (even though i think that they are both the same), i am still getting the same issues.

-------------- input/output --------------------------------------------------
first input: none
second input: none
output:
OBJ: FairParRootFile /Users/raghav/fairroot/example/EIC/macros/data/params_test_A_C.root : 0 at: 0x7ff5ecb49a70
Root file I/O /Users/raghav/fairroot/example/EIC/macros/data/params_test_A_C.root is open
detector I/Os: FairGenericParIo

-------- EEEE ------- G4Exception-START -------- EEEE -------
*** G4Exception : em0003
issued by : G4SeltzerBergerModel::ReadData()
Bremsstrahlung data file </brem_SB/br1> is not opened!
G4LEDATA version should be G4EMLOW6.23 or later.

*** Fatal Exception *** core dump ***
-------- EEEE -------- G4Exception-END --------- EEEE -------


[Updated on: Tue, 03 July 2012 16:21]

Report message to a moderator

Re: Geant4 not working with mc generation [message #13697 is a reply to message #13694] Wed, 04 July 2012 09:43 Go to previous message
Mohammad Al-Turany is currently offline  Mohammad Al-Turany
Messages: 518
Registered: April 2004
Location: GSI, Germany
first-grade participant
From: *gsi.de
Hallo Raghav,

Sorry for that, this is a bug which we corrected in the release and forget to merge it back to the trunk, please go to the directory:

/Users/raghav/fairsoft/transport/macro/

and call "svn update" there.

This should solve your problem!

regards,

Mohammad
Previous Topic: My updated fairtools library not loading
Next Topic: Questions on HIts in detector and MCPoint
Goto Forum:
  


Current Time: Sat Nov 23 01:14:00 CET 2024

Total time taken to generate the page: 0.00946 seconds