Dear HuggingFace/SageMaker pros,
I am trying to produce visual embeddings to fine-tune a VisualBERT model: VisualBERT
There is one example “Generate Embeddings for VisualBERT” that uses detectron2 to do this: VisualBERT
However, this notebook is for Colab. I can run inside Colab, but when I download the ipynb and try to run it in SageMaker I cannot download detectron2…
I try to run:
python -m pip install ‘git+https://github.com/facebookresearch/detectron2.git’
As well as:
git clone GitHub - facebookresearch/detectron2: Detectron2 is a platform for object detection, segmentation and other visual recognition tasks.
python -m pip install -e detectron2
But both fails to install detectron2…
Would anyone have an idea on how I can run the “Generate Embeddings for VisualBERT” example inside SageMaker? (Either how to install detectron2, or a way to bypass this.)
Or would you know some other way to successfully extract the visual embedding in a way that VisualBERT would accept?
Many thanks for your help! Best, Petrus