zzpustc / CC-SAM

This is the implementation of our CVPR'23 paper "Class-Conditional Sharpness-Aware Minimization for Deep Long-Tailed Recognition".
16 stars 4 forks source link

Missing modules in code #4

Open pradipto111 opened 1 year ago

pradipto111 commented 1 year ago

While running the code with the given command, I encountered the following issues:

  1. ModuleNotFoundError: No module named 'datasets.autoaugment', This error occurs when the train_cifar.py file tries to import Cifar10Policy from datasets.autoaugment, however no such file exists.
  2. ImportError: cannot import name 'grad_norm' from 'utils.pytorch'. Similarly here, utils/pytorch.py does not contain any function called grad_norm.
zzpustc commented 1 year ago

These issues have been dealt with and you can try again :)

pradipto111 commented 1 year ago

Thank you for the code update. It now runs without any errors. However, on CIFAR10-LT (IF=100), I could not reproduce the claimed numbers (83.92). My run yielded 74.04% overall accuracy at the end of training.

zzpustc commented 1 year ago

Hi, you can adjust the hyper-parameter (e.g., up_limit)to obtain a satisfied performance. Besides, to achieve the reported performance, you'd better adopt the strong data augmentation strategy (i.e., CIFAR10Policy) :)