Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
D
DAN
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package registry
Container Registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Automatic Text Recognition
DAN
Merge requests
!185
Correctly set mlflow logging
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Correctly set mlflow logging
correctly-disable-mlflow
into
main
Overview
0
Commits
1
Pipelines
0
Changes
1
Merged
Yoann Schneider
requested to merge
correctly-disable-mlflow
into
main
1 year ago
Overview
0
Commits
1
Pipelines
0
Changes
1
Expand
The parameter was hardcoded to
True
up till now.
0
0
Merge request reports
Compare
main
main (base)
and
latest version
latest version
a4982474
1 commit,
1 year ago
1 file
+
5
−
5
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
dan/ocr/document/train.py
+
5
−
5
Options
@@ -258,18 +258,18 @@ def serialize_config(config):
return
serialized_config
def
start_training
(
config
)
->
None
:
def
start_training
(
config
,
mlflow_logging
:
bool
)
->
None
:
if
(
config
[
"
training_params
"
][
"
use_ddp
"
]
and
not
config
[
"
training_params
"
][
"
force_cpu
"
]
):
mp
.
spawn
(
train_and_test
,
args
=
(
config
,
True
),
args
=
(
config
,
mlflow_logging
),
nprocs
=
config
[
"
training_params
"
][
"
nb_gpu
"
],
)
else
:
train_and_test
(
0
,
config
,
True
)
train_and_test
(
0
,
config
,
mlflow_logging
)
def
run
():
@@ -286,7 +286,7 @@ def run():
raise
MLflowNotInstalled
()
if
"
mlflow
"
not
in
config
:
start_training
(
config
)
start_training
(
config
,
mlflow_logging
=
False
)
else
:
labels_path
=
(
Path
(
config
[
"
dataset_params
"
][
"
datasets
"
][
dataset_name
])
/
"
labels.json
"
@@ -314,4 +314,4 @@ def run():
dictionary
=
artifact
,
artifact_file
=
filename
,
)
start_training
(
config
)
start_training
(
config
,
mlflow_logging
=
True
)
Loading