From a6c4b5fcd1853ef29b451c7ed03a5b5f232d2657 Mon Sep 17 00:00:00 2001 From: Svenn Tveit Date: Thu, 31 Oct 2024 09:56:47 +0100 Subject: [PATCH] List arrays in restart file at specified report date --- misc/ecl.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/misc/ecl.py b/misc/ecl.py index a20287d..5cc26e5 100644 --- a/misc/ecl.py +++ b/misc/ecl.py @@ -760,6 +760,10 @@ def date(self): # convert Eclipse date field to a Python date object return _intehead_date(intehead) + + def arrays(self): + ecl_file = EclipseFile(self.root, self.ext) + return [list(ecl_file.cat.keys())[i][0] for i, _ in enumerate(ecl_file.cat)] class EclipseSummary (EclipseData): @@ -1075,6 +1079,9 @@ def grid(self): # offload this routine to the grid object return self._grid.grid() + def arrays(self, when): + return self.at(when).arrays() + class EclipseRFT (object): """Read data from an Eclipse RFT file."""