Open ycwei0321 opened 1 year ago
Hello, The "gpus" argument is no longer present in the newest versions of pytorch-lightning You need to install an older version, for example pytorch-lightning==1.5.10
Hello, The "gpus" argument is no longer present in the newest versions of pytorch-lightning You need to install an older version, for example pytorch-lightning==1.5.10
Thanks for your answer. It solved my problem.
[2023-07-19 04:56:12,667] INFO [deepethogram.base.init:95] scheduler mode: min [2023-07-19 04:56:12,747] INFO [deepethogram.losses.get_regularization_loss:204] Regularization: L2_SP. Pretrained file: /content/drive/MyDrive/Public/testing_deepethogram_archive/models/pretrained_models/200221_115158_TinyMotionNet/checkpoint.pt alpha: 1e-05 beta: 0.001 [2023-07-19 04:56:12,796] INFO [deepethogram.flow_generator.losses.init:178] Using MotionNet Loss with settings: smooth_weights: [0.01, 0.02, 0.04, 0.08, 0.16] flow_sparsity: False sparsity_weight: 0.0 reloading weights...
TypeError Traceback (most recent call last) /usr/local/lib/python3.10/dist-packages/deepethogram/base.py in get_trainer_from_cfg(cfg, lightning_module, stopper, profiler) 385 # don't like how they keep updating the api without proper deprecation warnings, etc. --> 386 trainer = pl.Trainer(gpus=[cfg.compute.gpu_id], 387 precision=16 if cfg.compute.fp16 else 32,
4 frames TypeError: Trainer.init() got an unexpected keyword argument 'gpus'
During handling of the above exception, another exception occurred:
TypeError Traceback (most recent call last) /usr/local/lib/python3.10/dist-packages/pytorch_lightning/utilities/argparse.py in insert_env_defaults(self, *args, **kwargs) 67 68 def parse_argparser(cls: Type["pl.Trainer"], arg_parser: Union[ArgumentParser, Namespace]) -> Namespace: ---> 69 """Parse CLI arguments, required for custom bool types.""" 70 args = arg_parser.parse_args() if isinstance(arg_parser, ArgumentParser) else arg_parser 71
TypeError: Trainer.init() got an unexpected keyword argument 'gpus'
I was trying to run deepethogram on COLAB, everything is good until "flow_generator = flow_generator_train(cfg)". Does someone have same issue and know how to fix it? Thanks.