Commit 91ced12f authored by Kipp Cannon's avatar Kipp Cannon

snglcoinc: get_doubles() performance increase

- move an attribute look-up out of a loop
Original: 6063f047a4ea9c3350459145202ad9af66e5c37b
parent f152a228
......@@ -312,9 +312,10 @@ def get_doubles(eventlists, instruments, thresholds, unused):
# with it from the set.
offset_a = eventlista.offset
eventlistb_get_coincs = eventlistb.get_coincs
for eventa in eventlista:
eventa_id = id(eventa)
matches = eventlistb.get_coincs(eventa, offset_a, dt, threshold_data)
matches = eventlistb_get_coincs(eventa, offset_a, dt, threshold_data)
if matches:
for eventb in matches:
eventb_id = id(eventb)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment