WireCell / wire-cell-gen

Wire Cell packages that can generate things like wires, cells, depositions, diffusions, slices, frames, ...
0 stars 1 forks source link

Drifter slows when many depos are given #30

Closed brettviren closed 6 years ago

brettviren commented 6 years ago

When run inside larsoft, G4 causes on order 600k depos to be fed to WCT simulation. This leads to an ~hours/event of running time. A simple test that mostly just drifts:

Some doubling:

Roughly O(N^2)....

The problem is in the loop in flush_ripe(). Trial fix is to change xr.depos into a sorted set and then quit from the loop as soon as now is reached.

brettviren commented 6 years ago

After trial fix:

brettviren commented 6 years ago

FYI, this bug fix can be exercised with:

wire-cell -c cfg/pgrapher/test/wct-test-drifter.jsonnet

Then, change the step size in the Jsonnet.