szc19990412 / TransMIL

TransMIL: Transformer based Correlated Multiple Instance Learning for Whole Slide Image Classification
325 stars 72 forks source link

pytorch-lightning version #3

Closed RuixiangZhao closed 2 years ago

RuixiangZhao commented 2 years ago

Hi, thank you for your sharing!

I met some problems when I tried to use multi gpus to train, which was seemly caused by pytorch-lightning version:

pytorch_lightning.utilities.exceptions.MisconfigurationException: You have asked for amp_level='O2' but it's only supported with amp_backend='apex'

init() got an unexpected keyword argument 'dirpath'

Can you tell me your pytorch-lightning and some other packages' version? Thank you very much!

szc19990412 commented 2 years ago

addict==2.2.1 apex==0.9.10dev einops==0.3.0 h5py==2.10.0 numpy==1.20.0 nystrom_attention==0.0.9 opencv_python==4.2.0.34 pandas==1.2.3 pytorch_lightning==1.2.3 pytorch_toolbelt==0.4.0 PyYAML==6.0 scikit_learn==1.0.2 scipy==1.5.4 setuptools==58.0.4 tensorboard==2.7.0 timm==0.3.2 torch==1.7.1+cu110 torchmetrics==0.4.1 torchvision==0.8.2+cu110 tqdm==4.46.1

LXYTSOS commented 2 years ago

same problem, have you solved it?

jieruyao49 commented 1 year ago

addict==2.2.1 apex==0.9.10dev einops==0.3.0 h5py==2.10.0 numpy==1.20.0 nystrom_attention==0.0.9 opencv_python==4.2.0.34 pandas==1.2.3 pytorch_lightning==1.2.3 pytorch_toolbelt==0.4.0 PyYAML==6.0 scikit_learn==1.0.2 scipy==1.5.4 setuptools==58.0.4 tensorboard==2.7.0 timm==0.3.2 torch==1.7.1+cu110 torchmetrics==0.4.1 torchvision==0.8.2+cu110 tqdm==4.46.1

Can you tell me your pytorch and python version?

szc19990412 commented 1 year ago

conda create -n pytorch python=3.7 pip3 install torch==1.7.1+cu110 torchvision==0.8.2+cu110 -f https://download.pytorch.org/whl/cu110/torch_stable.html

weiaicunzai commented 6 months ago

You could simply comment out this argument amp_level.