Yes, I believe you can. Doing the following, I a least successfully installed ROCm 5.1.1 on the Ubuntu-based Pop!_OS 22.04. I am now able to run PyTorch computations on my GPU, an AMD RX 6800 XT.

I essentially followed this comment, with a bit of extras. See also that comment for reasons for some steps.

Some places below, you must replace 5.1.1 with the version you want.

amdgpu-install

We going to use a terminal. So open one. Create a directory to work in:

mkdir ~/ROCm && cd ~/ROCm

Update, then download the .deb file for amdgpu-install, and install it (link gotten from AMD):

sudo apt update
wget https://repo.radeon.com/amdgpu-install/22.20.1/ubuntu/focal/amdgpu-install_22.20.50201-1_all.deb
sudo apt-get install ./amdgpu-install_22.20.50201-1_all.deb

We now have to edit amdgpu-install:

sudo gedit /usr/bin/amdgpu-install 
  1. Pop!_OS is not listed as supported by amdgpu-install, so we add it: Search for ubuntu, and add |pop to the list (| reads "or").

  2. Search for linux-modules-extra and replace the entire function debian_build_package_list() with, on one line,

     function debian_build_package_list() { echo 'empty function'; }
    
  3. Save and quit

Python 3.8

Packages in the next steps require that we have also the older Python 3.8 installed. So:

sudo add-apt-repository --yes ppa:deadsnakes/ppa
sudo apt-get update
sudo apt install --yes python3.8

ROCm Repositories and Package Editing

Next, we add the desired ROCm repository. The link is relative to the ROCm version to be installed, so look up the base URL here.

echo 'deb [arch=amd64] <Release-1 specific rocm baseurl> ubuntu main' | sudo tee /etc/apt/sources.list.d/rocm.list
sudo apt update

I used ROCm 5.1.1, so I used specifically

echo 'deb [arch=amd64] https://repo.radeon.com/rocm/apt/5.1.1 ubuntu main' | sudo tee /etc/apt/sources.list.d/rocm.list

The download the .deb file for the ROCm package:

apt download rocm-llvm5.1.1

Edit Package 1/2

We need to edit this package before it will install. So we unpack, unpack and edit (by <tab> I mean press Tab to autocomplete):

 ar x rocm-llvm<tab>
 tar xf control.tar.xz
 gedit control

In control, edit the Depends line to

Depends: python3, libc6, libstdc++6|libstdc++8, libstdc++-5-dev|libstdc++-7-dev|libstdc++-10-dev, libgcc-5-dev|libgcc-7-dev|libgcc-10-dev, rocm-core5.1.1

I.e., add |libstdc++-10-dev and |libgcc-10-dev in the appropriate positions.

Then repack:

tar c postinst prerm control | xz -c > control.tar.xz
ar rcs rocm-llvm5.1.1_14.0.0.22114.50101-48_amd64.deb debian-binary control.tar.xz data.tar.xz

Great! Now, we install the possible dependencies we just added, and rocm-core5.1.1:

sudo apt install libstdc++-10-dev libgcc-10-dev rocm-core5.1.1

Now the downloaded package installed for me with

sudo dpkg -i rocm-llvm<tab>

Super.

Edit Package 2/2

Now we download, identically edit, and repack another package, openmp-extras5.1.1:

mkdir openmp && cd openmp
apt download openmp-extras5.1.1
ar x openmp<tab>
tar xf control.tar.xz
gedit control

Edit Depends line, add |libstdc++-10-dev and |libgcc-10-dev as before. Save, close, repack, install a dependency, and then the package with:

tar c control | xz -c > control.tar.xz
ar rcs openmp-extras5.1.1_13.51.0.50101-48_amd64.deb debian-binary control.tar.xz data.tar.xz
sudo apt install rocm-device-libs5.1.1
sudo dpkg -i openmp<tab>

I hope that all went smoothly.

Install ROCm

Install ROCm with the usecases you need. Mine are ROCm and HIP. See amdgpu-install --help for options.

sudo amdgpu-install --rocmrelease=5.1.1 --usecase=rocm,hip --no-dkms

Cool.

Now a final piece of setup: Add your user to the render and video groups:

sudo usermod -a -G render $LOGNAME
sudo usermod -a -G video $LOGNAME

and reboot.

Once rebooted, check that ROCm is loaded with

rocminfo

Hurra!, I hope, and time for cleaning:

rm -rf ~/ROCm

PyTorch Postscript

Note: Be sure that the ROCm version you installed is supported by Pytorch. At time of writing, Stable supports ROCm 5.1.1, Nightly supports 5.2. Check the PyTorch Start Locally page.

I needed ROCm for PyTorch, installed with

pip3 install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/rocm5.1.1

I then got verification that I could use my GPU for computation by running

python3
import torch
torch.cuda.is_available()
torch.cuda.get_device_name(torch.cuda.current_device())
Answer from Rasmus on askubuntu.com
🌐
AMD ROCm
rocm.docs.amd.com › projects › install-on-linux › en › latest › install › post-install.html
Post-installation instructions — ROCm installation (Linux)
If package installation was successful, the list will contain rocm* and hip* packages currently installed on the system. ... Marketing Name: AMD EPYC 9654 96-Core Processor Marketing Name: AMD EPYC 9654 96-Core Processor Marketing Name: AMD Instinct MI300X clinfo ... AMDSMI Tool: 26.2.2+97f5574fe2 | AMDSMI Library version: 26.2.2 | ROCm version: 7.2.4 | amdgpu version: 6.16.13 | hsmp version: N/A
🌐
GitHub
github.com › ROCm › ROCm › issues › 419
How to check installed ROCm version? · Issue #419 · ROCm/ROCm
May 17, 2018 - Are there any way (preferably a one liner command) to print/confirm the installed version of ROCm? (1.8.0 or other versions) I don't think I could find this detail in rocm-info.
Author   ROCm
Discussions

Installing ROCm / HIPLIB on Ubuntu 22.04 - Linux - Framework Community
Hey folks - I’m loving my FrameWork so far, but wanted to get an idea of if anyone has any good tutorials for getting ROCm and HIP installation done on the Framework 16 for Ubuntu 22.04. I’m currently running into issues with the amdgpu-install tool that AMD provides - it’s not installing ... More on community.frame.work
🌐 community.frame.work
0
May 6, 2024
[Issue]:
Problem Description I am using UBUNTU 23.10 with Vega 64 using the latest ROCm 5.7 drivers. This started when I upgraded to 23.10. Was not happening in 22.04 or 23.04. In Wayland, it always crashes the gnome session and I have to hardwar... More on github.com
🌐 github.com
13
February 20, 2024
A video guide for installing ROCm drivers and Stable Diffusion in Linux for AMD GPU (Automatic1111 and ComfyUI)
It should not be this involved. It is still a cluster of a process. But I hope some folks can get this to work. More on reddit.com
🌐 r/Amd
22
62
November 19, 2023
Getting started with rocM
I use fedora 38 with rocm. I target the rhel 9.2 repo that amd hosts for rocm bits. Make sure to exclude dkms during install if your using a gui Linux, as you'll already have the driver loaded. Unfortunately it is extremely niche, amd users that also use Linux, that also want to play ai/ml, tiny subset of people that are capable of even reaching the starting line. Good news is it works great. I've run native stable diffusion with all kinds of models and model add ons via rocm on my 6800 xt. Just recently got mlc-llm fully working with the new llama2 llm models too. I'm getting 70+ tokens per second, amazing performance. Really cool stuff going on, the people that say amd can't do ml/ai are just lazy. And with all the vram, even a 6800 can run huge 13b models with crazy performance. Here's the article that got me going with the llama2 stuff. I had to compile some stuff to get the 6800xt working, but if you have 7000 series it's all precompiled. https://blog.mlc.ai/2023/08/09/Making-AMD-GPUs-competitive-for-LLM-inference More on reddit.com
🌐 r/Amd
27
20
August 28, 2023
🌐
AMD GPUOpen
gpuopen.com › learn › amd-lab-notes › amd-lab-notes-rocm-installation-readme
AMD ROCm™ installation - AMD GPUOpen
We are using Ubuntu 22.04 and installing ROCm 5.7.1 and find that the script is named amdgpu-install_5.7.50701-1_all. ... Once the amdgpu-install script has been extracted, it can be used to install the kernel code, libraries and developer code. For a typical HPC environment HIP, ROCm and the kernel drivers should be sufficient: ... The ROCm code installs to /opt/rocm by default. You can verify that ROCm is installed by running ... and checking that the card was detected by the software.
🌐
Framework Community
community.frame.work › framework laptop 16 › linux
Installing ROCm / HIPLIB on Ubuntu 22.04 - Linux - Framework Community
May 6, 2024 - Hey folks - I’m loving my FrameWork so far, but wanted to get an idea of if anyone has any good tutorials for getting ROCm and HIP installation done on the Framework 16 for Ubuntu 22.04. I’m currently running into issues with the amdgpu-install tool that AMD provides - it’s not installing ...
Top answer
1 of 2
6

Yes, I believe you can. Doing the following, I a least successfully installed ROCm 5.1.1 on the Ubuntu-based Pop!_OS 22.04. I am now able to run PyTorch computations on my GPU, an AMD RX 6800 XT.

I essentially followed this comment, with a bit of extras. See also that comment for reasons for some steps.

Some places below, you must replace 5.1.1 with the version you want.

amdgpu-install

We going to use a terminal. So open one. Create a directory to work in:

mkdir ~/ROCm && cd ~/ROCm

Update, then download the .deb file for amdgpu-install, and install it (link gotten from AMD):

sudo apt update
wget https://repo.radeon.com/amdgpu-install/22.20.1/ubuntu/focal/amdgpu-install_22.20.50201-1_all.deb
sudo apt-get install ./amdgpu-install_22.20.50201-1_all.deb

We now have to edit amdgpu-install:

sudo gedit /usr/bin/amdgpu-install 
  1. Pop!_OS is not listed as supported by amdgpu-install, so we add it: Search for ubuntu, and add |pop to the list (| reads "or").

  2. Search for linux-modules-extra and replace the entire function debian_build_package_list() with, on one line,

     function debian_build_package_list() { echo 'empty function'; }
    
  3. Save and quit

Python 3.8

Packages in the next steps require that we have also the older Python 3.8 installed. So:

sudo add-apt-repository --yes ppa:deadsnakes/ppa
sudo apt-get update
sudo apt install --yes python3.8

ROCm Repositories and Package Editing

Next, we add the desired ROCm repository. The link is relative to the ROCm version to be installed, so look up the base URL here.

echo 'deb [arch=amd64] <Release-1 specific rocm baseurl> ubuntu main' | sudo tee /etc/apt/sources.list.d/rocm.list
sudo apt update

I used ROCm 5.1.1, so I used specifically

echo 'deb [arch=amd64] https://repo.radeon.com/rocm/apt/5.1.1 ubuntu main' | sudo tee /etc/apt/sources.list.d/rocm.list

The download the .deb file for the ROCm package:

apt download rocm-llvm5.1.1

Edit Package 1/2

We need to edit this package before it will install. So we unpack, unpack and edit (by <tab> I mean press Tab to autocomplete):

 ar x rocm-llvm<tab>
 tar xf control.tar.xz
 gedit control

In control, edit the Depends line to

Depends: python3, libc6, libstdc++6|libstdc++8, libstdc++-5-dev|libstdc++-7-dev|libstdc++-10-dev, libgcc-5-dev|libgcc-7-dev|libgcc-10-dev, rocm-core5.1.1

I.e., add |libstdc++-10-dev and |libgcc-10-dev in the appropriate positions.

Then repack:

tar c postinst prerm control | xz -c > control.tar.xz
ar rcs rocm-llvm5.1.1_14.0.0.22114.50101-48_amd64.deb debian-binary control.tar.xz data.tar.xz

Great! Now, we install the possible dependencies we just added, and rocm-core5.1.1:

sudo apt install libstdc++-10-dev libgcc-10-dev rocm-core5.1.1

Now the downloaded package installed for me with

sudo dpkg -i rocm-llvm<tab>

Super.

Edit Package 2/2

Now we download, identically edit, and repack another package, openmp-extras5.1.1:

mkdir openmp && cd openmp
apt download openmp-extras5.1.1
ar x openmp<tab>
tar xf control.tar.xz
gedit control

Edit Depends line, add |libstdc++-10-dev and |libgcc-10-dev as before. Save, close, repack, install a dependency, and then the package with:

tar c control | xz -c > control.tar.xz
ar rcs openmp-extras5.1.1_13.51.0.50101-48_amd64.deb debian-binary control.tar.xz data.tar.xz
sudo apt install rocm-device-libs5.1.1
sudo dpkg -i openmp<tab>

I hope that all went smoothly.

Install ROCm

Install ROCm with the usecases you need. Mine are ROCm and HIP. See amdgpu-install --help for options.

sudo amdgpu-install --rocmrelease=5.1.1 --usecase=rocm,hip --no-dkms

Cool.

Now a final piece of setup: Add your user to the render and video groups:

sudo usermod -a -G render $LOGNAME
sudo usermod -a -G video $LOGNAME

and reboot.

Once rebooted, check that ROCm is loaded with

rocminfo

Hurra!, I hope, and time for cleaning:

rm -rf ~/ROCm

PyTorch Postscript

Note: Be sure that the ROCm version you installed is supported by Pytorch. At time of writing, Stable supports ROCm 5.1.1, Nightly supports 5.2. Check the PyTorch Start Locally page.

I needed ROCm for PyTorch, installed with

pip3 install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/rocm5.1.1

I then got verification that I could use my GPU for computation by running

python3
import torch
torch.cuda.is_available()
torch.cuda.get_device_name(torch.cuda.current_device())
2 of 2
1

Update: as of ROCm 5.3.0, support for Ubuntu 22.04 has been added.

Installation guide: https://docs.amd.com/bundle/ROCm-Installation-Guide-v5.3

🌐
Arch Linux Forums
bbs.archlinux.org › viewtopic.php
[SOLVED] Getting latest ROCm binaries / Programming & Scripting / Arch Linux Forums
February 19, 2025 - I've started to learn JuliaLang, and I need the latest rocm-hip-sdk-6.3.2. Arch repo has 6.2.4, but I don't ask for an update because the package is huge and very expensive to compile. The problem is that 6.2.4 causes "Assertion `err == hipSuccess' failed" and the subsequent coredump each time I perform a simple operation, and I suspect that there is a version mismatch that can be solved by upgrading. I'd like to ask whether it's compatible to download this package from Ubuntu repo and to install it on Arch, or maybe there is a better way of getting the binaries?
Find elsewhere
🌐
AMD ROCm
rocm.docs.amd.com › projects › rocWMMA › en › docs-5.2.1 › Linux_Install_Guide.html
1. Getting Started Guide for Linux — rocWMMA Documentation
The rocWMMA source code is available at the rocWMMA github page. rocWMMA has a minimum ROCm support version 4.3. Check the ROCm Version on your system. For Ubuntu use
🌐
AMD ROCm
rocm.docs.amd.com › projects › install-on-linux › en › latest
ROCm installation for Linux — ROCm installation (Linux)
April 17, 2026 - The ROCm 7.13.0 technology preview release documentation is available at ROCm Preview documentation.
🌐
Phoronix
phoronix.com › news › Ubuntu-26.04-With-ROCm
Ubuntu 26.04 Allows "sudo apt install rocm" But It's Months Out-Of-Date - Phoronix
April 23, 2026 - The plan has been to ship AMD ROCm AI/ML and HPC libraries in the Ubuntu archive so it would be as easy as sudo apt install rocm for getting started with AMD's open-source GPU compute stack. With today being the Ubuntu 26.04 LTS release day, I decided to revisit the topic.
🌐
Reddit
reddit.com › r › ROCm
ROCm - Open Source Platform for HPC and Ultrascale GPU Computing
November 8, 2018 - It was better in prefill than Vulkan, but since then Vulkan has improved even in prefill. I did not have time to extensively test it on more LLM models, and the results are a mixture of older and newer ROCm, Vulkan, different settings, and different Ubuntu versions/Docker images.
🌐
GitHub
github.com › ROCm › ROCm › issues › 2908
[Issue]: · Issue #2908 · ROCm/ROCm
February 20, 2024 - Problem Description I am using UBUNTU 23.10 with Vega 64 using the latest ROCm 5.7 drivers. This started when I upgraded to 23.10. Was not happening in 22.04 or 23.04. In Wayland, it always crashes the gnome session and I have to hardwar...
Author   ROCm
🌐
AMD ROCm
rocm.docs.amd.com › projects › rocBLAS › en › docs-5.2.3 › Linux_Install_Guide.html
Getting Started Guide for Linux — rocBLAS Documentation
The rocBLAS source code is available at the rocBLAS github page. Check the ROCm Version on your system. For Ubuntu use
🌐
Readthedocs
doc-aug-21.readthedocs.io › en › latest › Installation_Guide › Installation-Guide.html
ROCm Installation Guide — ROCm Documentation 1.0.0 documentation
The ROCm Platform brings a rich foundation to advanced computing by seamlessly integrating the CPU and GPU with the goal of solving real-world problems. This software enables the high-performance operation of AMD GPUs for computation oriented tasks in the Linux operating system. The latest supported version of the drivers, tools, libraries and source code for the ROCm platform have been released and are available from the following GitHub repositories:
🌐
Reddit
reddit.com › r/amd › a video guide for installing rocm drivers and stable diffusion in linux for amd gpu (automatic1111 and comfyui)
r/Amd on Reddit: A video guide for installing ROCm drivers and Stable Diffusion in Linux for AMD GPU (Automatic1111 and ComfyUI)
November 19, 2023 -

https://www.youtube.com/watch?v=QEbI6v2oPvQ

I had a lot of trouble setting up ROCm and Automatic1111. I tried first with Docker, then natively and failed many times. Then I found this video. It has a good overview for the setup and a couple of critical bits that really helped me. Those were the reinstallation of compatible version of PyTorch and how to test if ROCm and pytorch are working. I still had a few of those Python problems that crop up when updating A1111, but a quick search in A1111 bug reports gave work arounds for those. And a strange HIP hardware error came at startup, but a simple reboot solved that.

Also he says he couldn't make it work with ROCm 5.7, but for me now 2 months later, ROCm 5.7 with 7900 XTX and Ubuntu 22.04 worked.

And coming from a Windows DirectML setup, the speed is heavenly.

🌐
GitHub
gist.github.com › damico › 484f7b0a148a0c5f707054cf9c0a0533
Script for testing PyTorch support with AMD GPUs using ROCM · GitHub
Checking user groups... GOOD: The user ... is in RENDER and VIDEO groups. GOOD: PyTorch ROCM support found. Testing PyTorch ROCM support... Everything fine! You can run PyTorch code inside of: ---> Intel(R) Core(TM) i5-10600K CPU @ 4.10GHz ---> gfx1012 ... Mint 21.1 (Ubuntu 22.04) rocm works with GPU support on stable-diffusion.
🌐
GitHub
github.com › Grench6 › RX580-rocM-tensorflow-ubuntu20.4-guide
GitHub - Grench6/RX580-rocM-tensorflow-ubuntu20.4-guide: Install guide of ROCm and Tensorflow on Ubuntu for the RX580 · GitHub
ROCm requieres the kernel version 5.4 (you can check your currently running kernel version with uname -r). ... sudo apt install linux-headers-5.4.0-54-generic \ linux-image-5.4.0-54-generic \ linux-modules-5.4.0-54-generic \ linux-modules-e...
Starred by 128 users
Forked by 17 users
🌐
YouTube
youtube.com › phazer tech
How to Install AMD ROCm on Linux - Updated Guide 10/2023 - YouTube
See the new 2024 version of this guide: https://youtu.be/hBMvM9eQhPsUpdated guide (10/2023) showing how to install AMD ROCm on Ubuntu and Arch based distros....
Published   October 13, 2023
Views   15K
🌐
Reddit
reddit.com › r/amd › getting started with rocm
r/Amd on Reddit: Getting started with rocM
August 28, 2023 -

Hello,

I recently acquired a new PC including the 7900 xtx and 7800x3d and wanted to try to run rocm. I already found the documentation:
https://rocm.docs.amd.com/en/latest/index.html

However i wanted to ask if there is a community that is active and discusses current progression/bugs etc. I honestly cant find much information online however it is probably a relativley niche topic since most people use nvidia.

I will also probably have to install a supported OS and the respective kernel accourding to : https://rocm.docs.amd.com/en/latest/release/gpu_os_support.html

How accurate is this? I currently have Ubuntu 22.04.3 with kernel 6.2.0-26-generic, its neither in the supported nor unsupported tab.

Also what about the disadvantages of dockerization? It sounds pretty good and useful but will the perfomance suffer? Im familiar with docker to some degree but im kinda sceptical how it works to pass the actual physcial gpu to the Container.

Also i would be grateful for every information/source you can give me. Also grateful for every advice.