Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Sep 19, 2023
1 parent 8071a2f commit dc9220a
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 17 deletions.
24 changes: 12 additions & 12 deletions nobrainer/processing/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,11 @@ def save(self, save_dir):

@classmethod
def load(
cls,
model_dir,
multi_gpu=True,
custom_objects=None,
compile=False,
cls,
model_dir,
multi_gpu=True,
custom_objects=None,
compile=False,
):
"""Loads a trained model from a save directory"""
model_dir = Path(str(model_dir).rstrip(os.pathsep))
Expand Down Expand Up @@ -87,13 +87,13 @@ def load(

@classmethod
def init_with_checkpoints(
cls,
model_name,
checkpoint_filepath,
multi_gpu=True,
custom_objects=None,
compile=False,
model_args=None,
cls,
model_name,
checkpoint_filepath,
multi_gpu=True,
custom_objects=None,
compile=False,
model_args=None,
):
"""Initialize a model for training, either from the latest
checkpoint found, or from scratch if no checkpoints are
Expand Down
10 changes: 5 additions & 5 deletions nobrainer/processing/checkpoint.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ def save(self, directory):
self.estimator.save(directory)

def load(
self,
multi_gpu=True,
custom_objects=None,
compile=False,
model_args=None,
self,
multi_gpu=True,
custom_objects=None,
compile=False,
model_args=None,
):
"""Loads the most-recently created checkpoint from the
checkpoint directory.
Expand Down

0 comments on commit dc9220a

Please sign in to comment.