mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
Mage: Logging BIN and GRA name in reading methode.
This commit is contained in:
1 parent
cbaeeaed83
commit
79d8bb7dee
1 file changed
+6
-4
+6
-4
@@ -575,9 +575,10 @@ class Mage8(Mage):
|
|||||||
|
|
||||||
@timer
|
@timer
|
||||||
def read_bin(self, study, repertory, results, qlog = None, name="0"):
|
def read_bin(self, study, repertory, results, qlog = None, name="0"):
|
||||||
logger.info(f"read_bin: Start ...")
|
fname = os.path.join(repertory, f"{name}.BIN")
|
||||||
|
logger.info(f"read_bin: Start reading '{fname}' ...")
|
||||||
|
|
||||||
with mage_file_open(os.path.join(repertory, f"{name}.BIN"), "r") as f:
|
with mage_file_open(fname, "r") as f:
|
||||||
newline = lambda: np.fromfile(f, dtype=np.int32, count=1)
|
newline = lambda: np.fromfile(f, dtype=np.int32, count=1)
|
||||||
endline = lambda: np.fromfile(f, dtype=np.int32, count=1)
|
endline = lambda: np.fromfile(f, dtype=np.int32, count=1)
|
||||||
|
|
||||||
@@ -700,9 +701,10 @@ class Mage8(Mage):
|
|||||||
if not study.river.has_sediment():
|
if not study.river.has_sediment():
|
||||||
return
|
return
|
||||||
|
|
||||||
logger.info(f"read_gra: Start ...")
|
fname = os.path.join(repertory, f"{name}.GRA")
|
||||||
|
logger.info(f"read_gra: Start reading '{fname}' ...")
|
||||||
|
|
||||||
with mage_file_open(os.path.join(repertory, f"{name}.GRA"), "r") as f:
|
with mage_file_open(fname, "r") as f:
|
||||||
newline = lambda: np.fromfile(f, dtype=np.int32, count=1)
|
newline = lambda: np.fromfile(f, dtype=np.int32, count=1)
|
||||||
endline = lambda: np.fromfile(f, dtype=np.int32, count=1)
|
endline = lambda: np.fromfile(f, dtype=np.int32, count=1)
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user