Updating Python on Your Jetson Nano Like a Pro

So, you’ve dusted off your trusty Jetson Nano, a noble edge AI companion from yesteryear — and you’re ready to teach it some new tricks. There’s just one problem: it’s still rocking Python 3.6, like it’s stuck in 2018. Time to update that thing and unlock the magical powers of Python 3.8, 3.10, or even the glorious Python 3.11. Let’s go full modern wizard on this little board!

🧙‍♂️ The Setup: Jetson Linux & JetPack 4

If you’re running JetPack 4.x, you’re also on Jetson Linux 32.7, which is basically Ubuntu 18.04 in disguise. That means your default Python options are limited (3.6, 3.7, 3.8) unless you summon something newer from the void.

But don’t worry — upgrading Python on Jetson is way easier than convincing your smart fridge to stop playing Despacito.

💬 So Why Go Through the Trouble?

Because the Jetson Nano still has a lot of potential — and modern Python opens the door to newer libraries, frameworks, and tools. If you’re into AI, computer vision, or just love to tinker, this update is 100% worth your time.

🐍 Installing Python 3.8 (The Easy One)

Want something newer but not bleeding-edge? Install Python 3.8 right from the official Ubuntu repos:

sudo apt update && sudo apt upgrade
sudo apt install python3.8

Now you’ve got a modern(ish) Python without needing to fight a compiler.

🚀 Going Full Turbo: Python 3.11 (a.k.a. Build-It-Yourself Edition)

Okay, let’s say you want the freshest Python on the block — Python 3.11. Ubuntu 18.04 doesn’t have it. But there’s a workaround: build it from source using a pre-made script from JetsonHacksNano.

git clone https://github.com/JetsonHacksNano/build_python.git
cd build_python
bash ./build_python3.sh

This script defaults to Python 3.11 and builds it into ~/Python_Builds. Want 3.9 or 3.10 instead? Pass a version flag to the script. The catch? The build takes about 2 hours on a Jetson Nano, so go make a sandwich. Or three.

bash ./build_python3.sh --version 3.10

📦 APT Repo Like a Boss

Want to go full pro and install Python like it’s coming from your own personal Ubuntu mirror? You can set up a local APT repository with just one command, thanks to a helpful script:

bash ./make_apt_repository.sh

This script does the heavy lifting:

  • Grabs all the .deb files for your selected Python version (e.g., Python 3.11)
  • Drops them into /opt/apt/python3.11
  • Adds a .list file to /etc/apt/sources.list.d so your system knows where to find your local magic packages

After that, your Jetson is convinced you’re Canonical. Update your APT index:

sudo apt update

Then install like a civilized developer:

sudo apt install python3.11-full

Now you’ve got Python 3.11, pip, and probably way too much coffee — but hey, it works!

🛋️ Feeling Lazy? Just Use Docker!

Alright, so you’re all pumped up about upgrading Python on your Jetson Nano… but let’s face it — sometimes you just want to get things done without spending hours compiling stuff. Enter Docker.

Why bother building Python from source when there are ready-to-use Docker images that are already optimized for JetPack? Yes, they exist, and they’re awesome.

Check out the l4t-jetpack-python Docker images, which are specifically designed for Jetson devices running JetPack. These images come pre-configured with popular Python versions and are optimized for Jetson’s GPU acceleration. Plus, the Python environment is already set up and ready to go — so you don’t need to manually install anything. Just grab the image and dive right in!

docker run -it acerbetti/l4t-jetpack-python:3.11 python3 -V

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top