Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error #1

Open
jerryniu0624 opened this issue Oct 21, 2023 · 1 comment
Open

error #1

jerryniu0624 opened this issue Oct 21, 2023 · 1 comment

Comments

@jerryniu0624
Copy link

When i execute "python main.py data=dcmall model.beta=1 noise=uniform noise.params.sigma_max=55"
(T3SC) jerry@jerry:/mnt/c/Users/17735/OneDrive/桌面/T3SC$ python main.py data=dcmall model.beta=1 noise=uniform noise.params.sigma_max=55 Traceback (most recent call last): File "main.py", line 6, in <module> from t3sc.train import train File "/mnt/c/Users/17735/OneDrive/桌面/T3SC/t3sc/train.py", line 5, in <module> import pytorch_lightning as pl File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/__init__.py", line 20, in <module> from pytorch_lightning import metrics # noqa: E402 File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/metrics/__init__.py", line 15, in <module> from pytorch_lightning.metrics.classification import ( # noqa: F401 File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/metrics/classification/__init__.py", line 14, in <module> from pytorch_lightning.metrics.classification.accuracy import Accuracy # noqa: F401 File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/metrics/classification/accuracy.py", line 18, in <module> from pytorch_lightning.metrics.utils import deprecated_metrics, void File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/metrics/utils.py", line 22, in <module> from torchmetrics.utilities.data import get_num_classes as _get_num_classes ImportError: cannot import name 'get_num_classes' from 'torchmetrics.utilities.data' (/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/torchmetrics/utilities/data.py)
This error happens ,why is that

@jerryniu0624
Copy link
Author

(T3SC) jerry@jerry:/mnt/c/Users/17735/OneDrive/桌面/T3SC$ python main.py data=dcmall model.beta=1 noise=uniform noise.params.sigma_max=55
Traceback (most recent call last):
File "main.py", line 6, in
from t3sc.train import train
File "/mnt/c/Users/17735/OneDrive/桌面/T3SC/t3sc/train.py", line 5, in
import pytorch_lightning as pl
File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/init.py", line 20, in
from pytorch_lightning import metrics # noqa: E402
File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/metrics/init.py", line 15, in
from pytorch_lightning.metrics.classification import ( # noqa: F401
File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/metrics/classification/init.py", line 14, in
from pytorch_lightning.metrics.classification.accuracy import Accuracy # noqa: F401
File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/metrics/classification/accuracy.py", line 18, in
from pytorch_lightning.metrics.utils import deprecated_metrics, void
File "/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/pytorch_lightning/metrics/utils.py", line 22, in
from torchmetrics.utilities.data import get_num_classes as _get_num_classes
ImportError: cannot import name 'get_num_classes' from 'torchmetrics.utilities.data' (/home/jerry/openmmlab/ENTER/envs/T3SC/lib/python3.8/site-packages/torchmetrics/utilities/data.py)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant