From 62f91de1ab28dd4a71140de7f2fd725abf274310 Mon Sep 17 00:00:00 2001
From: Emmanuel Branlard <elmanuelito.github@gmail.com>
Date: Mon, 22 Oct 2018 17:47:08 -0600
Subject: [PATCH] Fixed ae_file reading when several ae-sets are present

---
 wetb/hawc2/ae_file.py | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/wetb/hawc2/ae_file.py b/wetb/hawc2/ae_file.py
index 4557bb0..6bbf7ec 100644
--- a/wetb/hawc2/ae_file.py
+++ b/wetb/hawc2/ae_file.py
@@ -35,12 +35,12 @@ class AEFile(object):
         lptr = 1
         self.ae_sets = {}
         for _ in range(1, nsets + 1):
-            for _ in range(nsets):
-                set_nr, n_rows = [int(v) for v in lines[lptr ].split()[:2]]
-                lptr += 1
-                data = np.array([[float(v) for v in l.split()[:4]] for l in lines[lptr:lptr + n_rows]])
-                self.ae_sets[set_nr] = data
-                lptr += n_rows
+            #for _ in range(nsets):
+            set_nr, n_rows = [int(v) for v in lines[lptr ].split()[:2]]
+            lptr += 1
+            data = np.array([[float(v) for v in l.split()[:4]] for l in lines[lptr:lptr + n_rows]])
+            self.ae_sets[set_nr] = data
+            lptr += n_rows
 
 
     def _value(self, radius, column, set_nr=1):
-- 
GitLab