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 May 20, 2024
1 parent 019d361 commit 50b0009
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 6 deletions.
6 changes: 4 additions & 2 deletions deepmd/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -770,7 +770,9 @@ def main_parser() -> argparse.ArgumentParser:
"""
),
)
parser_list_model_branch.add_argument("INPUT", help="The input multi-task pre-trained model file")
parser_list_model_branch.add_argument(
"INPUT", help="The input multi-task pre-trained model file"
)

return parser

Expand Down Expand Up @@ -829,7 +831,7 @@ def main():
"compress",
"convert-from",
"train-nvnmd",
"list-model-branch"
"list-model-branch",
):
deepmd_main = BACKENDS[args.backend]().entry_point_hook
elif args.command is None:
Expand Down
3 changes: 1 addition & 2 deletions deepmd/pt/entrypoints/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@
from deepmd.utils.summary import SummaryPrinter as BaseSummaryPrinter

log = logging.getLogger(__name__)
from IPython import embed


def get_trainer(
Expand Down Expand Up @@ -346,7 +345,7 @@ def main(args: Optional[Union[List[str], argparse.Namespace]] = None):
# Pretrained model must be multitask mode
assert finetune_from_multi_task, "When using --list-model-branch, the pretrained model must be multitask model"
model_branch = list(model_params["model_dict"].keys())
log.info(f"Available model branches are {model_branch}")
log.info(f"Available model branches are {model_branch}")
else:
raise RuntimeError(f"Invalid command {FLAGS.command}!")

Expand Down
4 changes: 3 additions & 1 deletion deepmd/pt/train/training.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,9 @@
)

log = logging.getLogger(__name__)
from IPython import embed
from IPython import (
embed,
)


class Trainer:
Expand Down
1 change: 0 additions & 1 deletion deepmd/pt/utils/finetune.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
)

import torch
from IPython import embed

from deepmd.pt.utils import (
env,
Expand Down

0 comments on commit 50b0009

Please sign in to comment.