Skip to content

Commit

Permalink
check train.x
Browse files Browse the repository at this point in the history
  • Loading branch information
yomichi committed Oct 26, 2024
1 parent 3269e87 commit 703536f
Showing 1 changed file with 14 additions and 11 deletions.
25 changes: 14 additions & 11 deletions abics/applications/latgas_abinitio_interface/aenet_trainer.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,17 +150,20 @@ def train(self, train_dir = "train"):
while True:
# Repeat until test set error begins to rise
with open(os.path.join(os.getcwd(), "stdout"), "w") as fi:
subprocess.run(
self.train_exe, stdout=fi, stderr=subprocess.STDOUT, check=True
)
# try:
# subprocess.run(
# self.train_exe, stdout=fi, stderr=subprocess.STDOUT, check=True
# )
# except subprocess.CalledProcessError as e:
# print(e.stdout)
# print(e.stderr)
# raise
# subprocess.run(
# self.train_exe, stdout=fi, stderr=subprocess.STDOUT, check=True
# )
try:
# subprocess.run(
# self.train_exe, stdout=fi, stderr=subprocess.STDOUT, check=True
# )
subprocess.run(
self.train_exe, check=True
)
except subprocess.CalledProcessError as e:
print(e.stdout)
print(e.stderr)
raise
with open("stdout", "r") as trainout:
fullout = trainout.readlines()
epoch_data = []
Expand Down

0 comments on commit 703536f

Please sign in to comment.