working on google colab
See original GitHub issueDoes the code work on google colab ?
I have this error “KeyError: Caught KeyError in DataLoader worker process 0.” when calling train(segmentation_module, iterator_train, optimizers, history, epoch+1, cfg) after running the command python3 train.py --gpu 1
…
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
How to use Google Colab - GeeksforGeeks
To start working with Colab you first need to log in to your google account, then go to this link https://colab.research.google.com.
Read more >Google Colab — The Beginner's Guide | by Vishakha Lall
Open Google Drive. Create a new folder for the project. Click on 'New' > 'More' > 'Colaboratory'. Setting GPU Accelerator.
Read more >Getting Started With Google Colab | by Anne Bonner
A Simple Tutorial for the Frustrated and Confused · Setting up your drive · Game on! · Set up your free GPU ·...
Read more >How to use Colab | EECS 442: Computer Vision
1. Go to Colab webpage · 2. Upload your .ipynb file · 3. Connect to hosted runtime · 4. Use GPU as an...
Read more >Google Colaboratory – How to Run Python Code in Your ...
How to Add Colab to Your Google Drive ... 2. Click “more”, then click “connect more apps” at the bottom of that new...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
train.py needs to be modified as per this issue to run on a single GPU.
to run on a single GPU it’s
as opposed to train.py --gpu 1 .
I’ve also uploaded the pretrained models that can be found here
Finally to run the eval_ood.py if using the default config/ade20k-resnet50dilated-ppm_deepsup.yaml and the model I’ve uploaded, change the num_classes parameter in the yaml file to be 13.
Thanks for pointing out the typo. I fixed it and another as well.
I’ve also updated the README as well to reflect these changes
Thanks for the update @xksteven . The previous error have disappeared but I think there is still something missing because I can’t make the command
python train.py
works… I had to add feed_dict = feed_dict[0] in line 32 of models.py because I had a list and not a dictionnary but then I have “Input type (torch.FloatTensor) and weight type (torch.cuda.FloatTensor) should be the same”. You can check link_colab if you have timePS : I also noted one minor error in eval_ood.py :
in_scores = - conf[np.logical_not(out_label))]
line 51, there is one parenthesis too many