How to run DeepSeek Janus Pro on Google Colab
The DeepDeek’s Janus series repository on GitHub provides a demo using Gradio for anyone to try. We can set this up on a Google Colab notebook as shown below.
Open a new Google Colab notebook.
In the first cell, let’s clone the Github repo.
!git clone https://github.com/deepseek-ai/Janus.git
In the second cell, install package in editable mode and also install Gradio.
%cd Janus
!pip install -e .
!pip install gradio
You can edit the demo/app_januspro.py file to use desirable model for testing. By default it uses “deepseek-ai/Janus-Pro-7B” model. The list of available models can be found here - https://github.com/deepseek-ai/Janus?tab=readme-ov-file#huggingface
In the third cell, run the demo.
!python3 demo/app_januspro.py
It will create a gradio.live link that you can click to view the Gradio interface where you can play with the “Multimodal Understanding” and “Text-to-Image Generation” features of the Janus Pro model.
The Gradio interface should look like this.