Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
csst-pipeline
csst_common
Commits
2559b176
Commit
2559b176
authored
Jul 11, 2023
by
BO ZHANG
🏀
Browse files
tweaks
parent
23c06579
Changes
1
Hide whitespace changes
Inline
Side-by-side
csst_common/pipeline.py
View file @
2559b176
...
...
@@ -31,7 +31,7 @@ class Pipeline:
self
.
n_jobs_cpu
=
n_jobs_cpu
self
.
n_jobs_gpu
=
n_jobs_gpu
self
.
device
=
device
self
.
device
=
device
.
upper
()
self
.
pipeline_logger
=
get_logger
(
name
=
"pipeline"
,
filename
=
os
.
path
.
join
(
self
.
dir_out
,
"pipeline.log"
))
self
.
module_logger
=
get_logger
(
name
=
"module"
,
filename
=
os
.
path
.
join
(
self
.
dir_out
,
"module.log"
))
...
...
@@ -45,10 +45,17 @@ class Pipeline:
self
.
clean_directory
(
self
.
dir_out
)
# Frequently used files
self
.
m
sg_fil
e
=
Message
(
os
.
path
.
join
(
self
.
dir_out
,
"msg.txt"
))
self
.
m
essag
e
=
Message
(
os
.
path
.
join
(
self
.
dir_out
,
"msg.txt"
))
self
.
time_stamp
=
TimeStamp
(
os
.
path
.
join
(
self
.
dir_out
,
"time_stamp.txt"
))
self
.
exit_code
=
ExitCode
(
os
.
path
.
join
(
self
.
dir_out
,
"exit_code"
))
def
set_test_env
(
self
):
os
.
environ
[
"CSST_DFS_API_MODE"
]
=
"cluster"
os
.
environ
[
"CSST_DFS_GATEWAY"
]
=
"172.24.27.2:30880"
os
.
environ
[
"CSST_DFS_APP_ID"
]
=
"test"
os
.
environ
[
"CSST_DFS_APP_TOKEN"
]
=
"test"
os
.
environ
[
"CRDS_SERVER_URL"
]
=
"http://172.24.27.2:29000"
@
staticmethod
def
clean_directory
(
d
):
print
(
f
"Clean output directory '
{
d
}
'..."
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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