Code Monkey home page Code Monkey logo

edesc-pytorch's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

edesc-pytorch's Issues

About Data Loading

Hi,
Thanks for your code. It helps a lot but I'm confused about how to load the data from CIFAR-10 and CIFAR-100. May I have to load their x and y into .npy file? Also, is it available for other datasets?
Thanks a lot!

关于代码的运行

你好!我对EDESC聚类方法非常感兴趣,请问在Ubuntu系统中安装pytorch和TensorFlow完配置好环境后,使用指令“python EDESC.py” 发现报错“segmentation fault” 是怎么回事呢?应该怎么运行代码呢?

About The Experiment on CIFAR10

Thanks for your GREAT work!! And the released code really helps a lot!!
But when I tried to replicate the experimental results on CIFAR10, I failed and only got 0.35 accuracy.
It might because of the inappropriate hyper-parameter setting, or my misunderstanding on other experimental details on CIFAR10.
I've tried different beta values (0.1, 1,5, 10) and d values (5, 10). And for the feature extraction on CIFAR10, here's my implementation:

@torch.no_grad()
def CIFAR10_features():
    cifar10 = torchvision.datasets.CIFAR10(root='/home/mxh/datasets/CIFAR10',train=True,download=False)
    model = torchvision.models.resnet50(weights='DEFAULT')
    model.eval()
    model.fc= torch.nn.Identity()
    to_tensor = transforms.ToTensor()
    img_list = []
    label_list = []
    for idx in tqdm(range(len(cifar10))):
        img,label = cifar10[idx]
        img = to_tensor(img).unsqueeze(0)
        img_list.append(model(img))
        label_list.append(label)
    cifar10 = torchvision.datasets.CIFAR10(root='/home/mxh/datasets/CIFAR10',train=False,download=False)
    for idx in tqdm(range(len(cifar10))):
        img,label = cifar10[idx]
        img = to_tensor(img).unsqueeze(0)
        img_list.append(model(img))
        label_list.append(label)
    img_list = torch.cat(img_list, dim=0).numpy()
    label_list = np.array(label_list)
    data = {'data':img_list, 'label':label_list}
    np.save("/home/mxh/codes/EDESC/data/CIFAR10/cifar.npy", data)

Could you please give me some advice on the replication of CIFAR10? It would be extremely helpful!! Thanks a lot!!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.