Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ycai
simbricks
Commits
f260bf16
".github/vscode:/vscode.git/clone" did not exist on "cfb3b75d63bf097fec2efb0835d7bf62a0bd3492"
Commit
f260bf16
authored
Apr 30, 2024
by
Jonas Kaufmann
Committed by
Antoine Kaufmann
May 06, 2024
Browse files
orchestration/experiment_output.py: dump formatted JSON
parent
9481133e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
experiments/simbricks/orchestration/experiment/experiment_output.py
...s/simbricks/orchestration/experiment/experiment_output.py
+1
-1
No files found.
experiments/simbricks/orchestration/experiment/experiment_output.py
View file @
f260bf16
...
...
@@ -70,7 +70,7 @@ class ExpOutput(object):
def
dump
(
self
,
outpath
:
str
)
->
None
:
pathlib
.
Path
(
outpath
).
parent
.
mkdir
(
parents
=
True
,
exist_ok
=
True
)
with
open
(
outpath
,
'w'
,
encoding
=
'utf-8'
)
as
file
:
json
.
dump
(
self
.
__dict__
,
file
)
json
.
dump
(
self
.
__dict__
,
file
,
sort_keys
=
True
,
indent
=
4
)
def
load
(
self
,
file
:
str
)
->
None
:
with
open
(
file
,
'r'
,
encoding
=
'utf-8'
)
as
fp
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment