Closed FiyinfobaO closed 1 year ago
We used quite old mmdetection version and then it changed, so config and weights became incompatible. Sorry, we didn't specify it.
We used mmdetection commit d0c0418763 that is in between 1.0rc0 and 1.0rc1 and mmcv 0.2.14.
You can try to remove .decode call since you get non-compressed masks (decode uncompresses RLE-coded masks), but maybe simpler to use that version of mmdetection.
Thanks for the response. I will try the mmcv and mmdetection version you specified
@MikhailMashukov pls how do i specify the exact commit to install the mmdetection?
I tried using the command: pip install git+https://github.com/open-mmlab/mmdetection.git@d0c0418763
but I keep getting the error shown below, which makes it seem like the installation won't work if I'm not using Linux as I'm currently using mac
Kindly note that before running the earlier command, I already installed mmcv using the command: pip install mmcv==0.2.14
Oh, to install it can be a big problem... It looks like the problem is not in pip command, but in CUDA Toolkit setup. Maybe you don't have it at all? And maybe it is worth trying to add -e to pip.
Here are some commands I used when installed mmdetection. Better not to try to run them as is (maybe you don't need all these modules in .yml and so on), but to look for ideas instead.
conda env create -f ~/CondaEnvs/gs_open-mm.environment.yml -n open-mmlab7 conda activate open-mmlab7 conda install -c anaconda pandas cd /mnt/tenTB/mashukov_mu/mmcv/ python setup.py develop cd .. git clone https://github.com/open-mmlab/mmdetection.git mmdetection7 git checkout d0c0418763 cd mmdetection7 python setup.py develop
Here is renamed gs_open-mm.environment.yml: gs_open-mm.environment.txt
sorry but can you send the .yml
environment file rather than .txt
since the i can easily create the environment with that
Then where do i find this mnt folder in this path you provided: /mnt/tenTB/mashukov_mu/mmcv/
I attached .yml for you above, but since github doesn't allow yml extension, I renamed it. /mnt/tenTB/mashukov_mu is initially empty folder in which I setted up mmcv and mmdetection. Use any other on your drive. I don't remember exactly, but maybe I also checked out latest mmcv version from its GIT, into this .../mmcv subfolder. Then python setup.py develop
Okay, thanks. Quick one: is it the mmcv-full
or mmcv
that you guys used?
Then I noticed that the above method we're using to install the mmcv is from source, and when I tried it, it was the 1.7.1 version that installed and not 0.2.14. Is there a way to specify the 0.2.14 version?
Lastly, after cloning mmdetection and checking out the commit you specified, I got this message (not sure if its showing what is meant to show or not)
So, I continued and ran the python setup.py develop
command but it throws the same CUDA HOME
error I mentioned in my earlier comment
Please what exactly am I doing wrong?
I don't remember, rather mmcv, I don't remember "-full".
mmcv is from source, and when I tried it, it was the 1.7.1 version
I suppose you didn't checked out older commit, by default GIT checks out latest master.
What it says about switch is logical, you haven't create branch and this is strange for GIT. Read documentation if you want to understand deeper.
As I wrote, missing CUDA_HOME maybe means you haven't installed require CUDA Toolkit.
I honestly don't understand what you are saying. For mmcv, you didn't give any commit for me to checkout. All you said was "..latest mmcv version" which is why I'm wondering how you were able to use the 0.2.14 version. However, I've been able to sort that one out. I found the 0.2.14 version commit, checked out the commit and ran the setup.py which worked.
For mmdetection, where I am getting the cuda_home error, I mentioned that I'm using a MacBook and macs can't have cuda toolkit installed. Which is why I was asking if this project can really work on a mac or whether its specific to linux?
Fiyinfoba, I don't work on Mac, so you should know your computer better than me. 1-minute googling showed that CUDA can be installed on Macs. This should be your work to google for details, whether this is possible for you MacBook and OS. Our project doesn't prevent from running it on Macs, but we didn't try. What we know is that it needs CUDA Toolkit or something like this (CuDNN runtime libraries for example).
I sent you our mmcv version which is 0.2.14. So you could find a corresponding commit in GIT history if you want to install it from sources.
Can you share the link where you saw that CUDA can be installed on macs, cause I didn't see any. Thanks.
Thanks for sharing.
@MikhailMashukov I've been going through the code but I can't seem to find the training script that was used to create the epoch_500_3x.pth
file. Can you kindly point me to it?
Thanks.
Training of the network is another and complicated question, so we didn't share it. Were you able to run inference?
Yes, I did, but the results (shown below) weren't looking good on the data, which wasn't really surprising since the model wasn't trained on my data.
As you can see, the results are not good. This is why I need the training script so I can build a custom model
Ah, well. Yes, of course this is too far from particles we had. You for sure need our service https://t.me/nanoparticles_nsk instead where you can train on your data. It has to have instruction in English too in pinned message
thanks, but it seems like the telegram link doesn't work.
The main thing you need to do is to take this part "nanoparticles_nsk", add @ before it and search in Telegram: @nanoparticles_nsk
so the telegram gc helps to train the model for custom datasets which is good, but what of cases where the person wants to manually train the model by themselves, shouldn't that option be possible?
Yes, of course. Google for any model you want and go forward
I am trying to reproduce the code on your data provided and my custom data by running the
nano_predict.py
file but I am getting different errors.The first (shown below) was a type error which I resolved using a new config according to this solution
After resolving it, I then got an Index Error from line 70 of nano_predict.py (as seen in the screenshot below) that I am yet to rectify and would need help with as I still get the same error even when I use my own data.
It seems the error is coming from the the content of
segms[inst_cls][i]
which was passed insidemaskUtils.decode()
. When I print out thesegms[inst_cls][i]
, it shows the screenshot below.I would appreciate any help in rectifying this error. Thanks.