Skip to content

Create YOLACT++ Google Colaboratory demo#252

Open
mrm8488 wants to merge 1 commit into
dbolya:masterfrom
mrm8488:master
Open

Create YOLACT++ Google Colaboratory demo#252
mrm8488 wants to merge 1 commit into
dbolya:masterfrom
mrm8488:master

Conversation

@mrm8488
Copy link
Copy Markdown

@mrm8488 mrm8488 commented Dec 17, 2019

I think this is so helpful to get people into YOLACT/YOLACT++ in the easiest way!
Just one click and everything is ready :)

@mrm8488 mrm8488 changed the title Create yolact++ Gooble Colaboratory demo Create yolact++ Google Colaboratory demo Dec 17, 2019
@mrm8488 mrm8488 changed the title Create yolact++ Google Colaboratory demo Create YOLACT++ Google Colaboratory demo Dec 17, 2019
@abhigoku10
Copy link
Copy Markdown

@mrm8488 where is the google colab file , is it only the inference pipeline or even training is available . Wonderful thought in getting into the colab

@mrm8488
Copy link
Copy Markdown
Author

mrm8488 commented Dec 18, 2019

It's in the root dir. It's for inference.

@abhigoku10
Copy link
Copy Markdown

@mrm8488 thanks a lot i was looking into wrong directory

Copy link
Copy Markdown
Contributor

@breznak breznak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @mrm8488 , this a is great work! 👍 Thanks for setting the Collab up.

I've tested and reviewed your PR,

  • mostly some formatting improvement suggestions
  • I got the image upload fail on me (FF, linux)
    • would be good to include some out of the box images to test (already avail in the repo)

Comment thread yolact++_colab_demo.ipynb
"colab": {}
},
"source": [
"!mkdir weights"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we merge the

git clone
cd yolact
mkdir weights

into one execution block?

Comment thread yolact++_colab_demo.ipynb
"colab": {}
},
"source": [
"cd external/DCNv2"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be part of the section below

"# Compile deformable convolutional layers (from DCNv2) to use YOLACT++ version"

Comment thread yolact++_colab_demo.ipynb
"colab_type": "text"
},
"source": [
"# Download the model weights"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You might add more details from the Readme, ie the different pretrained nets and their FPS/mAP as a documentation here. Ofc only one net is downloaded

Comment thread yolact++_colab_demo.ipynb
"colab": {}
},
"source": [
"from google.colab import files\n",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm getting an err executing this cell:

Upload widget is only available when the cell has been executed in the current browser session. Please rerun this cell to enable.

---------------------------------------------------------------------------

MessageError                              Traceback (most recent call last)

<ipython-input-12-354be791d27e> in <module>()
      1 from google.colab import files
      2 
----> 3 uploaded = files.upload()
      4 pic_names = list(uploaded.keys())
      5 for pic_name in pic_names:

2 frames

/usr/local/lib/python3.6/dist-packages/google/colab/_message.py in read_reply_from_input(message_id, timeout_sec)
    104         reply.get('colab_msg_id') == message_id):
    105       if 'error' in reply:
--> 106         raise MessageError(reply['error'])
    107       return reply.get('data', None)
    108 

MessageError: TypeError: google.colab._files is undefined


Running on FF on linux

Comment thread yolact++_colab_demo.ipynb
"colab_type": "text"
},
"source": [
"# Detect objects in the uploaded pictures"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

...as the custom image upload may fail, offer a cell running detection on already available image(s) in the repo.

@dbolya
Copy link
Copy Markdown
Owner

dbolya commented Jan 24, 2020

I think this is a great idea! It looks like Adam Kelly has also created a collab notebook that also has video support: https://colab.research.google.com/drive/1ncRxvmNR-iTtQCscj2UFSGV8ZQX_LN0M
(Blog post here: https://www.immersivelimit.com/tutorials/yolact-with-google-colab)

Should we merge the functionality of both notebooks?

@breznak
Copy link
Copy Markdown
Contributor

breznak commented Jan 25, 2020

I'm not sure if the author of this PR is still active, @mrm8488 ?

Anyway, the Adam's notebook worked great for me!

Adam Kelly has also created a collab notebook that also has video support: https://colab.research.google.com/drive/1ncRxvmNR-iTtQCscj2UFSGV8ZQX_LN0M
(Blog post here: https://www.immersivelimit.com/tutorials/yolact-with-google-colab)

  • is there an OSS licence to the file?
  • can we add it to the repo? (so we can make modifications)

@dbolya
Copy link
Copy Markdown
Owner

dbolya commented Feb 5, 2020

@breznak He reached out to me about the existence of it, so I can ask him. Worst case we can just link it right? Or is it better to have it in the repo (in which case we can roll our own / update this one).

@mrm8488
Copy link
Copy Markdown
Author

mrm8488 commented Feb 5, 2020

Ofc, you can do you decide with my PR. License is the same as this repo.

@breznak
Copy link
Copy Markdown
Contributor

breznak commented Feb 5, 2020

Worst case we can just link it right?

true, we can always put a link in the Readme.

Or is it better to have it in the repo (in which case we can roll our own / update this one).

imho slightly better:

  • we can manage updates/fixes to the file
  • google warns that "you are executing a 3rd party ipython notebook from xxx" (it'd be better to have this repo as "author" rather than another nick)

@abhigoku10
Copy link
Copy Markdown

@mrm8488 @breznak @dbolya hi thanks for opensourcing and sharing the colab to run the yolact++ but when i try to do the same by myself by creating a repo and uploading all the files and changing the git clone from author to my repo and run it i get error in evaluation as mentioned below "File "/content/yolact_adas/backbone.py", line 11, in DCN
raise Exception('DCN could not be imported. If you want to use YOLACT++ models, compile DCN. Check the README for instructions.')
Exception: DCN could not be imported. If you want to use YOLACT++ models, compile DCN. Check the README for instructions." is it not possbile to do it ?? or should we perform only authors repo

@SnehashishSrivastava
Copy link
Copy Markdown

really interesting and helpful

@breznak
Copy link
Copy Markdown
Contributor

breznak commented Sep 30, 2021

@dbolya can we merge this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants