Helium6CRES / he6-cres-spec-sims

A python package to simulate cres data for the 6He CRES experiment at CENPA (University of Washington).
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Feature/no vectorize #14

Closed buzinsky closed 2 months ago

buzinsky commented 2 months ago

Approximately order of magnitude faster spec sims (for 100 betas, I get 33 s with develop -> ~4s with this branch)

Here is a small script you can use to just compare the outputs of 2 files, in the relevant columns compare.py.txt

In general, I find that zmax is the same to within 1e-15 m, fA to within 1Hz, and B_avg to within 1e-8 T

From my standalone testing, there should be approximately another order of magnitude "hanging around", if we call these fill_properties more than one beta at a time. Maybe in 10^3 or 10^4 beta "chunks" is optimal. Too much, and there is a lot of wasted time allocating memory all once

I think it makes sense to merge this, and then as you work on segmentBuilder, we can unlock this extra order of magnitude.

Didn't mention, the speed was attained by:

That these components work is proven by comparing the csvs for develop vs. this branch, though I did test each of these changes

output