kanezaki / pytorch-unsupervised-segmentation Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
Hi,
I tried to execute the demo command on README and get the below errors:
python demo.py --input images/101027.jpg
Traceback (most recent call last):
File "demo.py", line 118, in <module>
print (batch_idx, '/', args.maxIter, ':', nLabels, loss.data[0])
IndexError: invalid index of a 0-dim tensor. Use tensor.item() to convert a 0-dim tensor to a Python number
I'm not familiar with tensor though. Could you please suggest how to modify the code to solve this problem?
My system is Windows 10. Python version 3.7.3. PyTorch==1.2+cpu, opencv-python==4.1.1.26, scikit-image==0.15.0.
Hi, can you share the code how to draw precision-recall curve?
Thank you so much
Hi,
The README file only states opencv2 and PyTorch as dependencies. However, this program also needs scikit-image to work. Perhaps consider to add it to the README file?
You mentioned in the paper that the number of convolutional components were varied from 1 to 5. The best "average precision score" was achieved with how many convolutional layers?
Dear @kanezaki ,
Thanks for sharing the great work.
It seems the number of classes is determined by SLIC.
pytorch-unsupervised-segmentation/demo.py
Lines 74 to 77 in 8dbde70
How can we manually specify the segmentation class number?
e.g., I only want the method segments the input image into 3 classes.
Best regards,
Jun
deleted
Hi,
I was wondering if this method can be extended for 3D medical images. If it can be, what do you think could be the major bottlenecks?
Thank you.
Hi,
Thanks for the paper & open sourcing the code.
I was planning to use this approach to label a dataset and save the model. In future use the same model with same classes for new images.
How would you suggest to proceed with it , saving the model & classes ?
Hello,
Thanks for the paper & open sourcing the code very much.
I noticed that in the paper you mentioned "...Note that these components for feature extraction are able to be replaced by alternatives such as fully convolutional networks (FCN) .. ", so I imported the fcn-8s-atonce model structure code, and tried to run it with pretrained parameters and with the default pytorch parameters. But both of the results are bad:
For the former, fcn-8s-atonce model with pretrained parameters, the output segmented graphs are like these:
the original image:
And the following iterations result are just like iteration3, by the way, I deleted the limitation of the number of the output classes. It seems that overfit happens.
And For the latter one, fcn-8s-atonce model with default pytorch parameters, the output segmented graphs are like these:
the original image:
I think something wrong happened, and it seems that the backward propagation do not update the parameters effectively.
So I wanna ask that if you have tried with fcn before, and can you give me some advice about it?
Thank you very much !!!
You seems to be using batch normalization (self.bn0) twice.
https://github.com/kanezaki/pytorch-unsupervised-segmentation/blob/master/demo.py#L61
This is not the same code with that written in your paper.
Did you use this code for your experiment?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.