Skip to content

Cannot load saved model. #26

@lkhphuc

Description

@lkhphuc

I cannot load model back after saved, using load_from_metrics:

Traceback (most recent call last):
  File "eval-metric.py", line 60, in <module>
    main(hyperparams)
  File "eval-metric.py", line 32, in main
    on_gpu=False, map_location=None)
  File "/opt/anaconda3/lib/python3.7/site-packages/pytorch_lightning/root_module/root_module.py", line 112, in load_from_metrics
    model = cls(hparams)
  File "/home/jupyter/kaggle-CellSignal/arcface_module.py", line 74, in __init__
    super().__init__(hparams)
  File "/opt/anaconda3/lib/python3.7/site-packages/pytorch_lightning/root_module/root_module.py", line 12, in __init__
    super(LightningModule, self).__init__(*args, **kwargs)
TypeError: __init__() takes 1 positional argument but 2 were given

Really don't know what went wrong.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions