Skip to content
Snippets Groups Projects
Commit f2ac9fa1 authored by mads's avatar mads
Browse files

user name thing

parent d0d2b460
No related branches found
No related tags found
No related merge requests found
Pipeline #
from wetb.hawc2.simulation import Simulation, SimulationThread
import os
import os
import sys
from threading import Thread
class ClusterSimulation(Simulation):
......@@ -17,7 +17,7 @@ class ClusterSimulation(Simulation):
def update_status(self, *args, **kwargs):
Simulation.update_status(self, *args, **kwargs)
with open("/home/mmpe/.hawc2launcher/status_%s" % self.simulation_id, 'w') as fid:
with open("/home/%s/.hawc2launcher/status_%s" % (os.environ['USER'], self.simulation_id), 'w') as fid:
fid.write (";".join([self.simulation_id, self.status] + [str(getattr(self.logFile, v)) for v in ['status', 'pct', 'remaining_time', 'lastline']]) + "\n")
def show_status(self):
......
......@@ -234,6 +234,9 @@ class HTCFile(HTCContents, HTCDefaults):
raise Exception (str(stdout) + str(stderr))
if "__main__" == __name__:
f = HTCFile(r"C:\mmpe\HAWC2\models\PhaseIJacketv30\htc", "../../")
f = HTCFile(r"C:\mmpe\HAWC2\models\DTU10MWRef6.0\htc\DTU_10MW_RWT_power_curve.htc", "../")
f.save(r"C:\mmpe\HAWC2\models\DTU10MWRef6.0\htc\DTU_10MW_RWT_power_curve.htc")
f = HTCFile(r"C:\mmpe\HAWC2\models\DTU10MWRef6.0\htc\DTU_10MW_RWT.htc", "../")
f.save(r"C:\mmpe\HAWC2\models\DTU10MWRef6.0\htc\DTU_10MW_RWT.htc")
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment