Skip to content
Snippets Groups Projects

Create and process external MDC events to test RAVEN pipeline; fixes #401 and #403

Merged Brandon Piotrzkowski requested to merge brandon.piotrzkowski/gwcelery:raven-mdc-test into main
1 file
+ 2
2
Compare changes
  • Side-by-side
  • Inline
@@ -38,13 +38,13 @@ def create_grb_event(gpstime):
root.find(("./WhereWhen/ObsDataLocation/"
"ObservationLocation/AstroCoords/Position2D/Value2/"
"C1")).text = str(np.random.uniform(0, 360)).encode()
thetas = np.arange(-np.pi/2, np.pi/2, .01)
thetas = np.arange(-np.pi / 2, np.pi / 2, .01)
root.find(("./WhereWhen/ObsDataLocation/"
"ObservationLocation/AstroCoords/Position2D/Value2/"
"C2")).text = \
str(np.random.choice(np.rad2deg(thetas),
p=np.cos(thetas) / sum(np.cos(thetas)))
).encode()
).encode()
root.find(("./WhereWhen/ObsDataLocation/"
"ObservationLocation/AstroCoords/Position2D/"
"Error2Radius")).text = str(np.random.uniform(1, 30)).encode()
Loading