You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
defbuild_random_csv_input(n):
"""Build a random input with electron ionization. This should be used in micro_physics.ChunkInput. Returns a Pandas Dataframe. Args: n (int): number of instructions to generate """df=pd.DataFrame()
r=np.sqrt(np.random.uniform(0, 250000, n))
t=np.random.uniform(-np.pi, np.pi, n)
df["xp"] =r*np.cos(t)
df["yp"] =r*np.sin(t)
df["zp"] =np.random.uniform(-1500, -10, n)
df["xp_pri"] =df["xp"]
df["yp_pri"] =df["yp"]
df["zp_pri"] =df["zp"]
df["time"] =np.zeros(n)
df["ed"] =np.random.uniform(1, 100, n)
df["type"] ="e-"df["trackid"] =0df["parenttype"] ="None"df["parentid"] =0df["creaproc"] ="None"df["edproc"] ="eIoni"df["eventid"] =np.arange(n)
returndf
In this code I build a random csv input with a single interaction higher than the liquid level. Then, interactions_in_roi will be empty.
This is a rare case, but it might be necessary to look at how fuse produce chunks.
The text was updated successfully, but these errors were encountered:
Strax complains about data not being continuous with an empty instruction. Here is how to reproduce it:
In this code I build a random csv input with a single interaction higher than the liquid level. Then,
interactions_in_roi
will be empty.This is a rare case, but it might be necessary to look at how fuse produce chunks.
The text was updated successfully, but these errors were encountered: