Giter Site home page Giter Site logo

Comments (7)

sethrj avatar sethrj commented on June 21, 2024

@whokion happy for any comments you have here 😄
@paulromano have you done any exploration of single-precision geometry?

from celeritas.

whokion avatar whokion commented on June 21, 2024

Where are these small steps happening (i.e. are they from the physics stepping or only inside the field propagator as segments of a step)? I assume latter (otherwise, the linear propagator should experience the same problem and/or it is a general tracking problem). If the problem is only from the field propagator, the relative tolerance (as a function of some length scale) may not be a good choice as the field integration should be controlled by the relative error and a small step over the tolerance should not be segmented further. Should the tolerance of geometry serve as the cut for entering the field propagator (i.e., s < tolerance, should use the linear propagator)? MSC is another potential place, but again the small step limitation should serve the same role.

from celeritas.

sethrj avatar sethrj commented on June 21, 2024

@whokion The linear propagator is also seeing this (charged particles, no fields). I'm assuming it's due to the MSC step limiting or other range limits for low-energy particles. The field substepping is probably another issue on top of this 😅

from celeritas.

paulromano avatar paulromano commented on June 21, 2024

@sethrj I haven't personally tried doing geometry in single precision as it becomes a lot harder. @pshriwise may be able to comment on his experience as I believe he has tried doing some single and/or mixed precision geometry work

from celeritas.

whokion avatar whokion commented on June 21, 2024

Okay. If MSC is the primary source of the issue, we may adjust UrbanMscParameters::limit_min_fix (currently, 1e-9 * units::centimeter) for the single precision mode and test how it goes first. For the small returning range limit from low energy particles, we should limit the step (so, locally deposit energy and kill them) based on the tracking cut (absolute length, but relative energy) and the lowest electron energy (use in the energy loss calculation) which can be easily configurable and tested. Anyway, we may need to categorize where those small steps come from and investigate from there rather than introducing another ad hoc parameter for the single precision mode.

from celeritas.

sethrj avatar sethrj commented on June 21, 2024

Interestingly when I ran CMS2018 with assertions (uniform field + msc) on I got an assertion failure on one of the two CPU wildstyle runs:

internal assertion failed: `track.make_geo_view().pos() != orig_pos` at `PropagationApplier.hh:116`

so we're even taking too-small steps for double precision to count. We definitely need some sort of minimum based on the local volume extents.

from celeritas.

sethrj avatar sethrj commented on June 21, 2024

Another thing we should totally do in the propagators is to use the local coordinate system. Instead of operating on the global position and rotate/translate "down", which loses accuracy if local universe is smaller than the global, we should do propagation in the local coordinate system since we know we won't cross boundaries or exit the cell. The global position can be updated at the end of the propagator call.

This should vastly reduce loss of accuracy in the substepper.

from celeritas.

Related Issues (20)

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.