Skip to content

TypeError: __call__() got an unexpected keyword argument 'pretrained' #21

@joshhu

Description

@joshhu

Running env:
docker in wsl2 20.10.16
nvidia pytorch image:
nvcr.io/nvidia/pytorch:22.05-py3

Here is the error code

root@dd288f178ecc:/workspace/pytorch-gpu-benchmark# ./test.sh
start
benchmark start : 2022/06/28 08:39:29
Number of GPUs on current device : 1
CUDA Version : 11.7
Cudnn Version : 8400
Device Name : NVIDIA GeForce RTX 3080 Ti
uname_result(system='Linux', node='dd288f178ecc', release='5.10.16.3-microsoft-standard-WSL2', version='#1 SMP Fri Apr 2 22:23:49 UTC 2021', machine='x86_64', processor='x86_64')
                     scpufreq(current=2419.1979999999985, min=0.0, max=0.0)
                    cpu_count: 24
                    memory_available: 31270019072
Traceback (most recent call last):
  File "benchmark_models.py", line 183, in <module>
    train_result = train(precision)
  File "benchmark_models.py", line 81, in train
    model = getattr(model_type, model_name)(pretrained=False)
TypeError: __call__() got an unexpected keyword argument 'pretrained'
end

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions