-
Notifications
You must be signed in to change notification settings - Fork 20
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 in tiff images while executing python generate_aitod_imgs.py. #21
Comments
Maybe some error occurs when uncompressing the files, some .tiff files may be broken when using the ".zip" file. It seems that using the provided ".tar" file for uncompressing can solve this problem. |
I tried it in the manner you suggested, and downloaded the tar files from xview for both the training set and the labels geojson file. However the same error persists. I have attached another screenshot that shows the tiff images within the train_images folder (and there appears to be no issues with their names). However if you check the error in the perviously added screenshot, you can find the file name ._100.tiff where i guess its name is what is causing the issue but its not there in the train_images set while checking the file directly for that particular image (._100.tiff). Please do let me know if there's a way I could go about to help resolve this, and any help you provide will be quite valuable. |
Hi, |
Yes sure thank you, my email id is pranavhari2000@gmail.com. You could share it on this one. After which I just need to replace the train_images folder by the one you send right? |
Yes |
Ok sir I received the onedrive link, and it seems that with regards to its contents (i.e the aitod dataset) there isn't any issue, as this error popping up in the terminal is purely based on the tiff images within the xview dataset. I am actually using the aitod dataset for running your algorithm of RFLA, for which I followed the instructions of this page to use the aitod dataset. So can I directly use only the images of aitod part and leave out the xview images for its execution? Or I need to include the tiff images also? Because I am not aware of how to solve the issue thats popping up with regards to the unrecognized tiff files. |
The link is the whole aitod dataset (as mentioned in the aitod paper, it is constructed partly based on the xview, so the provided data already contains the xview part), it is the same as what is generated from this repo. You can directly use the dataset from the provided link as training data. And you do not need to include the tiff images. |
Oh ok sir. So I should directly include the dataset images and its annotations in a folder within the mmdet-rfla cloned folder before running "python setup.py develop" right?? |
"python setup.py develop" is for installing the repo, the organization of training data can refer to the official guide of (mmdetection)[https://github.com/open-mmlab/mmdetection/blob/master/docs/en/2_new_data_model.md], you need to create a folder named data inside the mmdet-rfla folder and put the images and anns into this data folder, please refer to the link for details. |
Ok sir got it thanks for the help. Finally, after adding the data in this manner, I'd move forward by executing the train.py available within the tools folder right? (I tried it already tho, and that too requests the mmcv version to be between 1.3.2 and 1.4.0 and not the latest) Just wanted to clarify this last part about executing the train.py . Thank you. |
Yes, you may need to install the mmcv of the required version and execute the train.py command with the config file. |
Hello Sir, I was able to get through with the previously mentioned issues, and while I'm simply using the AI-TOD set of images (leaving out the tiff images), there's an issue with regards to unpacking that I'm facing (screenshot attached below). I am still quite new when it comes to analyzing the code and debugging hence I thought of putting it here to get some ideas from anything that you could help me with. Please do let me know how to approach this and any help will be really appreciated. Thank you. |
Hi, maybe you can enter the mmdet-rfla dir and try to execute:
Under the mmdetection framework, some errors may occur if the command is not executed under the correct directory. |
Hi Sir, thanks for providing the update, however even after executing the said statement in the mmdet-rfla dir, I have come upon a new error, and I'm not sure how this has come to happen, (I did try to delete and redo the setup of cloning the rfla folder and proceeding). Please do let me know if I should simply reset it and uninstall all packages etc and retry it. |
Hi, it seems that there is a mismatch between the installed mmcv and the required mmcv of the mmdet. The mmcv used in my mmdet-rfla is mmcv-full v1.3.8, maybe you can try it. |
Sir, I'm having some issue with installing previous versions of mmcv-full in my system as well (like 1.3.8 as you mentioned) so for my openmmlab environment i am thinking of specifically reinstalling the appropriate versions of torch, mmcv and other requirements. Could you specify which all versions are you utilizing for the rfla code (just as you specified about mmcv 1.3.8)? |
All packages in the rfla env are shown below. Besides, I used RTX3090 gpu with cuda 11.1: |
Hi @Chasel-Tsui Sir, so I was able to re-install the packages and try the training execution. In this manner, it ran through and through for the given 12 epochs, using "python tools/train.py configs/rfla/aitod_faster_r50_rfla_kld_1x.py". But at this point a RunTimeError turns up (shown as below). Even though I'm trying to make the changes in the bbox_nms.py folder by adding .cpu() in the inds variables, it isn't working, so I thought of asking you about the same. |
It seems that this error occurs in the inference stage when using the get_bboxes() function. Maybe you need to verify whether the inputs of the multiclass_nms() function in the bbox_head.py (as indicated in the error "line 371") are in the same device, if not, you need to transfer the input to the same device. |
Hey sir, I am able unable to understand exactly how to transfer the input to the same device, as mentioned in my previous comment, I was trying to use .cpu() to get the inds (indices) to the cpu part, however I'm unable to do the same in the function mentioned in your comment above (in bbox_head.py). Can you uggest how exactly should I go about transfering to either the cpu or gpu? |
Hi, to my best knowledge, this error occurs when the "inds" and its indexed variables are not in the same device. To tackle this problem, you can try to debug by printing out the device of correlated variables and check whether they are in the same device. Then, you can transfer the problematic variable by command "to(device)", for example, the "device" can be obtained by the command "inds.device". This checking process can be done in bbox_nms, or you can check whether the input in the multiclass_nms() are in the same device as the "inds". |
Hello Sir,
I followed the steps as mentioned, and go to the execution part of "python generate_aitod_imgs.py". However, in my terminal, the error depicted in the below given image is being shown. Please do let me know of a way in which I can rectify it and whether the error is in some of the tiff images only or something else. Thanks.
The text was updated successfully, but these errors were encountered: