Coder Social home page Coder Social logo

Comments (7)

drinkingkazu avatar drinkingkazu commented on July 29, 2024

Sorry I forgot to quote: I used edep-sim built in this container if anyone would like to know/see.

from edep-sim.

ClarkMcGrew avatar ClarkMcGrew commented on July 29, 2024

The process and sub-process type are copied directly from the underlying G4VProcess* for the step or track. I suspect that you are looking at a particles with an undefined process.

Can you please attach the simplest input kinematics file and the associated geant4 macro file that will reproduce the issue.

from edep-sim.

drinkingkazu avatar drinkingkazu commented on July 29, 2024

I have no doubt they are supposed to be copied from G4 and there appears to be no room of a mistake.
Yet, these particles are injected by me.
12 muons per event, all with identical momentum to the floating point precision (not printed out above but i'm sure you can check by yourself easily, + easy modification to above script).
So I expect them to have the same Process and Subprocess attribute values.

Unfortunately I don't have a g4 macro that works handy because this came out from running a custom event generator.
If you are certain that this cannot happen (that Process and Subprocess attribute values should be correctly reset to 0 by Geant4 for all subsequent events after the first one) because this is explicitly verified (rather than considered "should not happen"), I am happy to postpone this discussion till I can give you a run script.

But if somehow you could take a look, that would be great. Sorry for not being able to attend this problem right now... I will for now comment as a potential bug in my software that depend on edep-sim and mark as unreliable information when ParentId == -1.

from edep-sim.

ClarkMcGrew avatar ClarkMcGrew commented on July 29, 2024

The trajectory point values should be a faithful representation of the internal G4 values (and if G4 doesn't initialize the value, it should be a faithful copy of that too). Have you seen evidence that the value is not a good copy of the step that created the trajectory point?

What needs to be checked, and which I haven't reproduced, is an example where the process/subprocess values copied into the TG4TrajectoryPoint object do not match the values present in the G4VProcess (actually the derived class) associated with the step that is creating the trajectory point, or that the value in the TG4TrajectoryPoint object is being incorrectly modified after it is assigned.

from edep-sim.

drinkingkazu avatar drinkingkazu commented on July 29, 2024

@ClarkMcGrew to me, above stored values are enough evidences.

But let me understand this point clearly: so you are suggesting the issue may be in Geant4 rather than edep-sim?

I expect Geant4 to give an identical tag for creation process for injected particles if Geant4 is correctly reset for each event simulation. In the past, I have dealt with G4String rather than a combination of process and subprocess enums (not in edep-sim, different experiments different G4 wrapper softwares / running bare G4). But I don't have a reason to doubt it should be different (i.e. like G4String I assume process and subprocess enums to be reset).

Yes, I am glad to hear you have not done the check = this remains as a possibility. That was my question (whether this was actually checked before) and I appreciate the answer that this is never validated.

is because whenever I dealt with Geant4 in the past, the G4String associated with a creation process of injected particles have been consistent

from edep-sim.

ClarkMcGrew avatar ClarkMcGrew commented on July 29, 2024

My understanding is that you have found a case where the saved process and subprocess values do not match your expectation, and you have isolated the problem to be that the saved edep-sim values to do not match internal geant4 values.

The validation includes inputs similar to what I think you describe, and does not reproduce your report. It "works for me".

I do not have example inputs where the process and subprocess values are incorrectly saved.

To debug, I need example inputs which produce incorrect results and that can be used to write a test. The output is not sufficient.

Alternatively, I would be very happy to have a PR with a test (and, ideally, a fix), which can be validated and merged.

from edep-sim.

ClarkMcGrew avatar ClarkMcGrew commented on July 29, 2024

Bug not verified.

from edep-sim.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.