Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
bob
bob.pipelines
Commits
be583847
Commit
be583847
authored
Nov 26, 2020
by
Amir MOHAMMADI
Browse files
[CheckpointWrapper] Allow custom save and load functions through estimator tags
parent
b652eb14
Pipeline
#46109
passed with stage
in 3 minutes and 57 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
bob/pipelines/wrappers.py
View file @
be583847
...
...
@@ -249,8 +249,16 @@ class CheckpointWrapper(BaseWrapper, TransformerMixin):
self
.
model_path
=
model_path
self
.
features_dir
=
features_dir
self
.
extension
=
extension
self
.
save_func
=
save_func
or
bob
.
io
.
base
.
save
self
.
load_func
=
load_func
or
bob
.
io
.
base
.
load
self
.
save_func
=
(
save_func
or
estimator
.
_get_tags
().
get
(
"bob_features_save_fn"
)
or
bob
.
io
.
base
.
save
)
self
.
load_func
=
(
load_func
or
estimator
.
_get_tags
().
get
(
"bob_features_load_fn"
)
or
bob
.
io
.
base
.
load
)
self
.
sample_attribute
=
sample_attribute
self
.
hash_fn
=
hash_fn
if
model_path
is
None
and
features_dir
is
None
:
...
...
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