Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove unused materials definitions from final gdml #41

Open
lobis opened this issue Nov 29, 2021 · 0 comments
Open

Remove unused materials definitions from final gdml #41

lobis opened this issue Nov 29, 2021 · 0 comments

Comments

@lobis
Copy link
Contributor

lobis commented Nov 29, 2021

Currently materials loaded from a URL via loadMaterials (src/jvmMain/kotlin/space/kscience/gdml/loadMaterials.kt) are added to the <materials> section of the final GDML.

This creates a nuisance when using the GDML in Geant4 as Geant4 will (only on some physics lists such as decay) load cross sections for all isotopes which can take a few extra minutes in my experience.

The solution would be to identify materials used in the geometry and only keep those, while also keeping child materials/isotopes/elements. It would also reduce the size of the file and make it more readable.

I will try to implement this if nobody is available.

Edit: I am currently working on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant