mirror of
https://github.com/ROCm/ROCm.git
synced 2026-02-19 02:34:19 -05:00
site restructure phase 1 - file reorganization (#2428)
This commit is contained in:
27
docs/tutorials/index.md
Normal file
27
docs/tutorials/index.md
Normal file
@@ -0,0 +1,27 @@
|
||||
# ROCm tutorials
|
||||
|
||||
:::::{grid} 1 1 2 2
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} [Installing ROCm](./install/index.md)
|
||||
|
||||
Learn how to install ROCm on Linux and Windows.
|
||||
|
||||
:::
|
||||
|
||||
:::{grid-item-card} [ROCm examples](https://github.com/amd/rocm-examples)
|
||||
:link-type: url
|
||||
Sample code demonstrating the HIP API and ROCm-accelerated domain libraries.
|
||||
|
||||
:::
|
||||
|
||||
:::{grid-item-card} [Artificial intelligence](../rocm_ai/rocm_ai)
|
||||
|
||||
Detailed walkthroughs of specific artificial intelligence use cases using ROCm acceleration.
|
||||
|
||||
- [Implementing Inception V3 on ROCm with PyTorch](../rocm_ai/pytorch_inception)
|
||||
- [Optimizing Inference with MIGraphX](../rocm_ai/migraphx_optimization)
|
||||
|
||||
:::
|
||||
|
||||
:::::
|
||||
90
docs/tutorials/install/docker.md
Normal file
90
docs/tutorials/install/docker.md
Normal file
@@ -0,0 +1,90 @@
|
||||
# Deploy ROCm Docker containers
|
||||
|
||||
## Prerequisites
|
||||
|
||||
Docker containers share the kernel with the host operating system, therefore the
|
||||
ROCm kernel-mode driver must be installed on the host. Please refer to
|
||||
{ref}`linux_install_methods` on installing `amdgpu-dkms`. The other
|
||||
user-space parts (like the HIP-runtime or math libraries) of the ROCm stack will
|
||||
be loaded from the container image and don't need to be installed to the host.
|
||||
|
||||
(docker-access-gpus-in-container)=
|
||||
|
||||
## Accessing GPUs in containers
|
||||
|
||||
In order to access GPUs in a container (to run applications using HIP, OpenCL or
|
||||
OpenMP offloading) explicit access to the GPUs must be granted.
|
||||
|
||||
The ROCm runtimes make use of multiple device files:
|
||||
|
||||
- `/dev/kfd`: the main compute interface shared by all GPUs
|
||||
- `/dev/dri/renderD<node>`: direct rendering interface (DRI) devices for each
|
||||
GPU. **`<node>`** is a number for each card in the system starting from 128.
|
||||
|
||||
Exposing these devices to a container is done by using the
|
||||
[`--device`](https://docs.docker.com/engine/reference/commandline/run/#device)
|
||||
option, i.e. to allow access to all GPUs expose `/dev/kfd` and all
|
||||
`/dev/dri/renderD` devices:
|
||||
|
||||
```shell
|
||||
docker run --device /dev/kfd --device /dev/renderD128 --device /dev/renderD129 ...
|
||||
```
|
||||
|
||||
More conveniently, instead of listing all devices, the entire `/dev/dri` folder
|
||||
can be exposed to the new container:
|
||||
|
||||
```shell
|
||||
docker run --device /dev/kfd --device /dev/dri
|
||||
```
|
||||
|
||||
Note that this gives more access than strictly required, as it also exposes the
|
||||
other device files found in that folder to the container.
|
||||
|
||||
(docker-restrict-gpus)=
|
||||
|
||||
### Restricting a container to a subset of the GPUs
|
||||
|
||||
If a `/dev/dri/renderD` device is not exposed to a container then it cannot use
|
||||
the GPU associated with it; this allows to restrict a container to any subset of
|
||||
devices.
|
||||
|
||||
For example to allow the container to access the first and third GPU start it
|
||||
like:
|
||||
|
||||
```shell
|
||||
docker run --device /dev/kfd --device /dev/dri/renderD128 --device /dev/dri/renderD130 <image>
|
||||
```
|
||||
|
||||
### Additional Options
|
||||
|
||||
The performance of an application can vary depending on the assignment of GPUs
|
||||
and CPUs to the task. Typically, `numactl` is installed as part of many HPC
|
||||
applications to provide GPU/CPU mappings. This Docker runtime option supports
|
||||
memory mapping and can improve performance.
|
||||
|
||||
```shell
|
||||
--security-opt seccomp=unconfined
|
||||
```
|
||||
|
||||
This option is recommended for Docker Containers running HPC applications.
|
||||
|
||||
```shell
|
||||
docker run --device /dev/kfd --device /dev/dri --security-opt seccomp=unconfined ...
|
||||
```
|
||||
|
||||
## Docker images in the ROCm ecosystem
|
||||
|
||||
### Base images
|
||||
|
||||
<https://github.com/RadeonOpenCompute/ROCm-docker> hosts images useful for users
|
||||
wishing to build their own containers leveraging ROCm. The built images are
|
||||
available from [Docker Hub](https://hub.docker.com/u/rocm). In particular
|
||||
`rocm/rocm-terminal` is a small image with the prerequisites to build HIP
|
||||
applications, but does not include any libraries.
|
||||
|
||||
### Applications
|
||||
|
||||
AMD provides pre-built images for various GPU-ready applications through its
|
||||
Infinity Hub at <https://www.amd.com/en/technologies/infinity-hub>.
|
||||
Examples for invoking each application and suggested parameters used for
|
||||
benchmarking are also provided there.
|
||||
22
docs/tutorials/install/index.md
Normal file
22
docs/tutorials/install/index.md
Normal file
@@ -0,0 +1,22 @@
|
||||
# Installing ROCm
|
||||
|
||||
Our installation guides are designed to walk you through a ROCm installation in detail. If you want to get up and running quickly, try our [quick-start guides](../quick_start/index).
|
||||
|
||||
:::::{grid} 1 1 2 2
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Linux installation guide
|
||||
:link: ./linux/index
|
||||
:link-type: doc
|
||||
Install ROCm on Linux.
|
||||
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Windows installation guide
|
||||
:link: ./windows/index
|
||||
:link-type: doc
|
||||
Install ROCm on Linux.
|
||||
|
||||
:::
|
||||
|
||||
:::::
|
||||
55
docs/tutorials/install/linux/index.md
Normal file
55
docs/tutorials/install/linux/index.md
Normal file
@@ -0,0 +1,55 @@
|
||||
# Install ROCm on Linux
|
||||
|
||||
Start with {doc}`../../quick_start/linux` or follow the detailed
|
||||
instructions below.
|
||||
|
||||
## Prepare to Install
|
||||
|
||||
::::{grid} 1 1 2 2
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Prerequisites
|
||||
:link: prerequisites
|
||||
:link-type: doc
|
||||
|
||||
The prerequisites page lists the required steps *before* installation.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Install Choices
|
||||
:link: install_overview
|
||||
:link-type: doc
|
||||
|
||||
Package manager vs AMDGPU Installer
|
||||
|
||||
Standard Packages vs Multi-Version Packages
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
(linux_install_methods)=
|
||||
|
||||
## Choose your install method
|
||||
|
||||
::::{grid} 1 1 2 2
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Package Manager
|
||||
:link: os-native/index
|
||||
:link-type: doc
|
||||
|
||||
Directly use your distribution's package manager to install ROCm.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} AMDGPU Installer
|
||||
:link: installer/index
|
||||
:link-type: doc
|
||||
|
||||
Use an installer tool that orchestrates changes via the package
|
||||
manager.
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## See Also
|
||||
|
||||
- {doc}`../../../about/release/linux_support`
|
||||
71
docs/tutorials/install/linux/install_overview.md
Normal file
71
docs/tutorials/install/linux/install_overview.md
Normal file
@@ -0,0 +1,71 @@
|
||||
# ROCm Installation Options (Linux)
|
||||
|
||||
Users installing ROCm must choose between various installation options. A new
|
||||
user should follow the [Quick Start guide](../../quick_start/linux).
|
||||
|
||||
## Package Manager versus AMDGPU Installer?
|
||||
|
||||
ROCm supports two methods for installation:
|
||||
|
||||
- Directly using the Linux distribution's package manager
|
||||
- The `amdgpu-install` script
|
||||
|
||||
There is no difference in the final installation state when choosing either
|
||||
option.
|
||||
|
||||
Using the distribution's package manager lets the user install,
|
||||
upgrade and uninstall using familiar commands and workflows. Third party
|
||||
ecosystem support is the same as your OS package manager.
|
||||
|
||||
The `amdgpu-install` script is a wrapper around the package manager. The same
|
||||
packages are installed by this script as the package manager system.
|
||||
|
||||
The installer automates the installation process for the AMDGPU
|
||||
and ROCm stack. It handles the complete installation process
|
||||
for ROCm, including setting up the repository, cleaning the system, updating,
|
||||
and installing the desired drivers and meta-packages. Users who are
|
||||
less familiar with the package manager can choose this method for ROCm
|
||||
installation.
|
||||
|
||||
(installation-types)=
|
||||
|
||||
## Single Version ROCm install versus Multi-Version
|
||||
|
||||
ROCm packages are versioned with both semantic versioning that is package
|
||||
specific and a ROCm release version.
|
||||
|
||||
### Single-version Installation
|
||||
|
||||
The single-version ROCm installation refers to the following:
|
||||
|
||||
- Installation of a single instance of the ROCm release on a system
|
||||
- Use of non-versioned ROCm meta-packages
|
||||
|
||||
### Multi-version Installation
|
||||
|
||||
The multi-version installation refers to the following:
|
||||
|
||||
- Installation of multiple instances of the ROCm stack on a system. Extending
|
||||
the package name and its dependencies with the release version adds the
|
||||
ability to support multiple versions of packages simultaneously.
|
||||
- Use of versioned ROCm meta-packages.
|
||||
|
||||
```{attention}
|
||||
ROCm packages that were previously installed from a single-version installation
|
||||
must be removed before proceeding with the multi-version installation to avoid
|
||||
conflicts.
|
||||
```
|
||||
|
||||
```{note}
|
||||
Multiversion install is not available for the kernel driver module, also referred to as AMDGPU.
|
||||
```
|
||||
|
||||
The following image demonstrates the difference between single-version and
|
||||
multi-version ROCm installation types:
|
||||
|
||||
```{figure-md} install-types
|
||||
|
||||
<img src="/data/tutorials/install/linux/linux001.png" alt="">
|
||||
|
||||
ROCm Installation Types
|
||||
```
|
||||
31
docs/tutorials/install/linux/installer/index.md
Normal file
31
docs/tutorials/install/linux/installer/index.md
Normal file
@@ -0,0 +1,31 @@
|
||||
# AMDGPU Install Script
|
||||
|
||||
::::{grid} 2 3 3 3
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Install
|
||||
:link: install
|
||||
:link-type: doc
|
||||
|
||||
How to install ROCm?
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Upgrade
|
||||
:link: upgrade
|
||||
:link-type: doc
|
||||
|
||||
Instructions for upgrading an existing ROCm installation.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Uninstall
|
||||
:link: uninstall
|
||||
:link-type: doc
|
||||
|
||||
Steps for removing ROCm packages, libraries and tools.
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## See Also
|
||||
|
||||
- {doc}`../../../../about/release/linux_support`
|
||||
325
docs/tutorials/install/linux/installer/install.md
Normal file
325
docs/tutorials/install/linux/installer/install.md
Normal file
@@ -0,0 +1,325 @@
|
||||
# Installation with install script
|
||||
|
||||
Prior to beginning, please ensure you have the [prerequisites](../prerequisites)
|
||||
installed.
|
||||
|
||||
## Download the Installer Script
|
||||
|
||||
To download and install the `amdgpu-install` script on the system, use the
|
||||
following commands based on your distribution.
|
||||
|
||||
::::::{tab-set}
|
||||
:::::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu 20.04
|
||||
:sync: ubuntu-20.04
|
||||
|
||||
```shell
|
||||
sudo apt update
|
||||
wget https://repo.radeon.com/amdgpu-install/5.6.1/ubuntu/focal/amdgpu-install_5.6.50601-1_all.deb
|
||||
sudo apt install ./amdgpu-install_5.6.50601-1_all.deb
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Ubuntu 22.04
|
||||
:sync: ubuntu-22.04
|
||||
|
||||
```shell
|
||||
sudo apt update
|
||||
wget https://repo.radeon.com/amdgpu-install/5.6.1/ubuntu/jammy/amdgpu-install_5.6.50601-1_all.deb
|
||||
sudo apt install ./amdgpu-install_5.6.50601-1_all.deb
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
:::::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} RHEL 8.6
|
||||
:sync: RHEL-8.6
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
sudo yum install https://repo.radeon.com/amdgpu-install/5.6.1/rhel/8.6/amdgpu-install-5.6.50601-1.el8.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 8.7
|
||||
:sync: RHEL-8.7
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
sudo yum install https://repo.radeon.com/amdgpu-install/5.6.1/rhel/8.7/amdgpu-install-5.6.50601-1.el8.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 8.8
|
||||
:sync: RHEL-8.8
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
sudo yum install https://repo.radeon.com/amdgpu-install/5.6.1/rhel/8.8/amdgpu-install-5.6.50601-1.el8.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 9.1
|
||||
:sync: RHEL-9.1
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
sudo yum install https://repo.radeon.com/amdgpu-install/5.6.1/rhel/9.1/amdgpu-install-5.6.50601-1.el9.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 9.2
|
||||
:sync: RHEL-9.2
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
sudo yum install https://repo.radeon.com/amdgpu-install/5.6.1/rhel/9.2/amdgpu-install-5.6.50601-1.el9.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
:::::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} SLES 15.4
|
||||
:sync: SLES-15.4
|
||||
|
||||
```shell
|
||||
sudo zypper --no-gpg-checks install https://repo.radeon.com/amdgpu-install/5.6.1/sle/15.4/amdgpu-install-5.6.50601-1.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} SLES 15.5
|
||||
:sync: SLES-15.5
|
||||
|
||||
```shell
|
||||
sudo zypper --no-gpg-checks install https://repo.radeon.com/amdgpu-install/5.6.1/sle/15.5/amdgpu-install-5.6.50601-1.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
::::::
|
||||
|
||||
## Use cases
|
||||
|
||||
Instead of installing individual applications or libraries the installer script
|
||||
groups packages into specific use cases, matching typical workflows and runtimes.
|
||||
|
||||
To display a list of available use cases execute the command:
|
||||
|
||||
```shell
|
||||
sudo amdgpu-install --list-usecase
|
||||
```
|
||||
|
||||
The available use-cases will be printed in a format similar to the example
|
||||
output below.
|
||||
|
||||
```none
|
||||
If --usecase option is not present, the default selection is "graphics,opencl,hip"
|
||||
|
||||
Available use cases:
|
||||
rocm(for users and developers requiring full ROCm stack)
|
||||
- OpenCL (ROCr/KFD based) runtime
|
||||
- HIP runtimes
|
||||
- Machine learning framework
|
||||
- All ROCm libraries and applications
|
||||
- ROCm Compiler and device libraries
|
||||
- ROCr runtime and thunk
|
||||
lrt(for users of applications requiring ROCm runtime)
|
||||
- ROCm Compiler and device libraries
|
||||
- ROCr runtime and thunk
|
||||
opencl(for users of applications requiring OpenCL on Vega or
|
||||
later products)
|
||||
- ROCr based OpenCL
|
||||
- ROCm Language runtime
|
||||
|
||||
openclsdk (for application developers requiring ROCr based OpenCL)
|
||||
- ROCr based OpenCL
|
||||
- ROCm Language runtime
|
||||
- development and SDK files for ROCr based OpenCL
|
||||
|
||||
hip(for users of HIP runtime on AMD products)
|
||||
- HIP runtimes
|
||||
hiplibsdk (for application developers requiring HIP on AMD products)
|
||||
- HIP runtimes
|
||||
- ROCm math libraries
|
||||
- HIP development libraries
|
||||
```
|
||||
|
||||
To install use cases specific to your requirements, use the installer
|
||||
`amdgpu-install` as follows:
|
||||
|
||||
- To install a single use case add it with the `--usecase` option:
|
||||
|
||||
```shell
|
||||
sudo amdgpu-install --usecase=rocm
|
||||
```
|
||||
|
||||
- For multiple use cases separate them with commas:
|
||||
|
||||
```shell
|
||||
sudo amdgpu-install --usecase=hiplibsdk,rocm
|
||||
```
|
||||
|
||||
## Single-version ROCm Installation
|
||||
|
||||
By default (without the `--rocmrelease` option)
|
||||
the installer script will install packages in the single-version layout.
|
||||
|
||||
## Multi-version ROCm Installation
|
||||
|
||||
For the multi-version ROCm installation you must use the installer script from
|
||||
the latest release of ROCm that you wish to install.
|
||||
|
||||
**Example:** If you want to install ROCm releases 5.3.3 and 5.4.3
|
||||
simultaneously, you are required to download the installer from the latest ROCm
|
||||
release v5.4.3.
|
||||
|
||||
### Add Required Repositories
|
||||
|
||||
You must add the ROCm repositories manually for all ROCm releases
|
||||
you want to install except the latest one. The `amdgpu-install` script
|
||||
automatically adds the required repositories for the latest release.
|
||||
|
||||
Run the following commands based on your distribution to add the repositories:
|
||||
|
||||
::::::{tab-set}
|
||||
:::::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu 20.04
|
||||
:sync: ubuntu-20.04
|
||||
|
||||
```shell
|
||||
for ver in 5.4.6 5.5.3; do
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/trusted.gpg.d/rocm-keyring.gpg] https://repo.radeon.com/rocm/apt/$ver focal main" | sudo tee /etc/apt/sources.list.d/rocm.list
|
||||
done
|
||||
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' | sudo tee /etc/apt/preferences.d/rocm-pin-600
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Ubuntu 22.04
|
||||
:sync: ubuntu-22.04
|
||||
|
||||
```shell
|
||||
for ver in 5.4.6 5.5.3; do
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/trusted.gpg.d/rocm-keyring.gpg] https://repo.radeon.com/rocm/apt/$ver jammy main" | sudo tee /etc/apt/sources.list.d/rocm.list
|
||||
done
|
||||
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' | sudo tee /etc/apt/preferences.d/rocm-pin-600
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
:::::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} RHEL 8
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
for ver in 5.4.6 5.5.3; do
|
||||
sudo tee --append /etc/yum.repos.d/rocm.repo <<EOF
|
||||
[ROCm-$ver]
|
||||
name=ROCm$ver
|
||||
baseurl=https://repo.radeon.com/rocm/rhel8/$ver/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
done
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 9
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
for ver in 5.4.6 5.5.3; do
|
||||
sudo tee --append /etc/yum.repos.d/rocm.repo <<EOF
|
||||
[ROCm-$ver]
|
||||
name=ROCm$ver
|
||||
baseurl=https://repo.radeon.com/rocm/rhel9/$ver/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
done
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
:::::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
```shell
|
||||
for ver in 5.4.6 5.5.3; do
|
||||
sudo tee --append /etc/zypp/repos.d/rocm.repo <<EOF
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/zyp/$ver/main
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
done
|
||||
sudo zypper ref
|
||||
```
|
||||
|
||||
:::::
|
||||
::::::
|
||||
|
||||
### Install packages
|
||||
|
||||
Use the installer script as given below:
|
||||
|
||||
```none
|
||||
sudo amdgpu-install --usecase=rocm --rocmrelease=<release-number-1>
|
||||
sudo amdgpu-install --usecase=rocm --rocmrelease=<release-number-2>
|
||||
sudo amdgpu-install --usecase=rocm --rocmrelease=<release-number-3>
|
||||
```
|
||||
|
||||
Following are examples of ROCm multi-version installation. The kernel-mode
|
||||
driver, associated with the ROCm release v5.4.3, will be installed as its latest
|
||||
release in the list.
|
||||
|
||||
```none
|
||||
sudo amdgpu-install --usecase=rocm --rocmrelease=5.4.6
|
||||
sudo amdgpu-install --usecase=rocm --rocmrelease=5.5.3
|
||||
```
|
||||
|
||||
## Additional options
|
||||
|
||||
### Unattended installation
|
||||
|
||||
Adding `-y` as a parameter to `amdgpu-install` skips user prompts (for
|
||||
automation). Example: `amdgpu-install -y --usecase=rocm`
|
||||
|
||||
### Skipping kernel mode driver installation
|
||||
|
||||
The installer script tries to install the kernel mode driver along with the
|
||||
requested use cases. This might be unnecessary as in the case of docker
|
||||
containers or you may wish to keep a specific version when using multi-version
|
||||
installation, and not have the last installed version overwrite the kernel mode
|
||||
driver.
|
||||
|
||||
To skip the installation of the kernel-mode driver add the `--no-dkms` option
|
||||
when calling the installer script.
|
||||
25
docs/tutorials/install/linux/installer/uninstall.md
Normal file
25
docs/tutorials/install/linux/installer/uninstall.md
Normal file
@@ -0,0 +1,25 @@
|
||||
# Installer Script Uninstallation (Linux)
|
||||
|
||||
To uninstall all ROCm packages and the kernel-mode driver the following commands
|
||||
can be used.
|
||||
|
||||
::::{rubric} Uninstalling Single-Version Install
|
||||
::::
|
||||
|
||||
```console shell
|
||||
sudo amdgpu-install --uninstall
|
||||
```
|
||||
|
||||
::::{rubric} Uninstalling a Specific ROCm Release
|
||||
::::
|
||||
|
||||
```console shell
|
||||
sudo amdgpu-install --uninstall --rocmrelease=<release-number>
|
||||
```
|
||||
|
||||
::::{rubric} Uninstalling all ROCm Releases
|
||||
::::
|
||||
|
||||
```console shell
|
||||
sudo amdgpu-install --uninstall --rocmrelease=all
|
||||
```
|
||||
5
docs/tutorials/install/linux/installer/upgrade.md
Normal file
5
docs/tutorials/install/linux/installer/upgrade.md
Normal file
@@ -0,0 +1,5 @@
|
||||
# Upgrading with the Installer Script (Linux)
|
||||
|
||||
The upgrade procedure with the installer script is exactly the same as
|
||||
installing for 1st time use. Refer to the {doc}`install`
|
||||
section on the exact procedure to follow.
|
||||
38
docs/tutorials/install/linux/os-native/index.md
Normal file
38
docs/tutorials/install/linux/os-native/index.md
Normal file
@@ -0,0 +1,38 @@
|
||||
# Installation via Package manager
|
||||
|
||||
::::{grid} 2 3 3 3
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Install
|
||||
:link: install
|
||||
:link-type: doc
|
||||
|
||||
How to install ROCm?
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Upgrade
|
||||
:link: upgrade
|
||||
:link-type: doc
|
||||
|
||||
Instructions for upgrading an existing ROCm installation.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Uninstall
|
||||
:link: uninstall
|
||||
:link-type: doc
|
||||
|
||||
Steps for removing ROCm packages libraries and tools.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Package Manager Integration
|
||||
:link: package_manager_integration
|
||||
:link-type: doc
|
||||
|
||||
Information about packages.
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## See Also
|
||||
|
||||
- {doc}`../../../../about/release/linux_support`
|
||||
556
docs/tutorials/install/linux/os-native/install.md
Normal file
556
docs/tutorials/install/linux/os-native/install.md
Normal file
@@ -0,0 +1,556 @@
|
||||
# Installation (Linux)
|
||||
|
||||
## Understanding the Release-specific AMDGPU and ROCm Repositories on Linux Distributions
|
||||
|
||||
The release-specific repositories consist of packages from a specific release of
|
||||
versions of AMDGPU and ROCm. The repositories are not updated for the latest
|
||||
packages with subsequent releases. When a new ROCm release is available, the new
|
||||
repository, specific to that release, is added. You can select a specific
|
||||
release to install, update the previously installed single version to the later
|
||||
available release, or add the latest version of ROCm along with the currently
|
||||
installed version by using the multi-version ROCm packages.
|
||||
|
||||
## Step by Step Instructions
|
||||
|
||||
::::::{tab-set}
|
||||
:::::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
::::{rubric} 1. Download and convert the package signing key
|
||||
::::
|
||||
|
||||
```shell
|
||||
# Make the directory if it doesn't exist yet.
|
||||
# This location is recommended by the distribution maintainers.
|
||||
sudo mkdir --parents --mode=0755 /etc/apt/keyrings
|
||||
# Download the key, convert the signing-key to a full
|
||||
# keyring required by apt and store in the keyring directory
|
||||
wget https://repo.radeon.com/rocm/rocm.gpg.key -O - | \
|
||||
gpg --dearmor | sudo tee /etc/apt/keyrings/rocm.gpg > /dev/null
|
||||
```
|
||||
|
||||
```{note}
|
||||
The GPG key may change; ensure it is updated when installing a new release. If
|
||||
the key signature verification fails while updating, re-add the key from the
|
||||
ROCm to the apt repository as mentioned above. The current `rocm.gpg.key` is not
|
||||
available in a standard key ring distribution but has the following SHA1 sum
|
||||
hash: `73f5d8100de6048aa38a8b84cd9a87f05177d208 rocm.gpg.key`
|
||||
```
|
||||
|
||||
::::{rubric} 2. Add the AMDGPU Repository and Install the Kernel-mode Driver
|
||||
::::
|
||||
|
||||
```{tip}
|
||||
If you have a version of the kernel-mode driver installed, you may skip this
|
||||
section.
|
||||
```
|
||||
|
||||
To add the AMDGPU repository, follow these steps:
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu 20.04
|
||||
:sync: ubuntu-20.04
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
# amdgpu repository for focal
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/amdgpu/$ver/ubuntu focal main" \
|
||||
| sudo tee /etc/apt/sources.list.d/amdgpu.list
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Ubuntu 22.04
|
||||
:sync: ubuntu-22.04
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
# amdgpu repository for jammy
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/amdgpu/$ver/ubuntu jammy main" \
|
||||
| sudo tee /etc/apt/sources.list.d/amdgpu.list
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
Install the kernel mode driver and reboot the system using the following
|
||||
commands:
|
||||
|
||||
```shell
|
||||
sudo apt install amdgpu-dkms
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
::::{rubric} 3. Add the ROCm Repository
|
||||
::::
|
||||
|
||||
To add the ROCm repository, use the following steps:
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu 20.04
|
||||
:sync: ubuntu-20.04
|
||||
|
||||
```shell
|
||||
# ROCm repositories for focal
|
||||
for ver in 5.3.3 5.4.6 5.5.3 5.6.1; do
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/rocm/apt/$ver focal main" \
|
||||
| sudo tee --append /etc/apt/sources.list.d/rocm.list
|
||||
done
|
||||
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' \
|
||||
| sudo tee /etc/apt/preferences.d/rocm-pin-600
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Ubuntu 22.04
|
||||
:sync: ubuntu-22.04
|
||||
|
||||
```shell
|
||||
# ROCm repositories for jammy
|
||||
for ver in 5.3.3 5.4.6 5.5.3 5.6.1; do
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/rocm/apt/$ver jammy main" \
|
||||
| sudo tee --append /etc/apt/sources.list.d/rocm.list
|
||||
done
|
||||
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' \
|
||||
| sudo tee /etc/apt/preferences.d/rocm-pin-600
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
::::{rubric} 4. Install packages
|
||||
::::
|
||||
|
||||
Install packages of your choice in a single-version ROCm install or
|
||||
in a multi-version ROCm install fashion. For more information on what
|
||||
single/multi-version installations are, refer to {ref}`installation-types`.
|
||||
For a comprehensive list of meta-packages, refer to
|
||||
{ref}`meta-package-desc`.
|
||||
|
||||
- Sample Single-version installation
|
||||
|
||||
```shell
|
||||
sudo apt install rocm-hip-sdk
|
||||
```
|
||||
|
||||
- Sample Multi-version installation
|
||||
|
||||
```shell
|
||||
sudo apt install rocm-hip-sdk5.6.1 rocm-hip-sdk5.5.3
|
||||
```
|
||||
|
||||
:::::
|
||||
:::::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
::::{rubric} 1. Add the AMDGPU Stack Repository and Install the Kernel-mode Driver
|
||||
::::
|
||||
|
||||
```{tip}
|
||||
If you have a version of the kernel-mode driver installed, you may skip this
|
||||
section.
|
||||
```
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} RHEL 8.6
|
||||
:sync: RHEL-8.6
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$ver/rhel/8.6/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} RHEL 8.7
|
||||
:sync: RHEL-8.7
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$ver/rhel/8.7/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} RHEL 8.8
|
||||
:sync: RHEL-8.8
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$ver/rhel/8.8/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} RHEL 9.1
|
||||
:sync: RHEL-9.1
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$ver/rhel/9.1/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} RHEL 9.2
|
||||
:sync: RHEL-9.2
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$ver/rhel/9.2/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
Install the kernel mode driver and reboot the system using the following
|
||||
commands:
|
||||
|
||||
```shell
|
||||
sudo yum install amdgpu-dkms
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
::::{rubric} 2. Add the ROCm Stack Repository
|
||||
::::
|
||||
|
||||
To add the ROCm repository, use the following steps, based on your distribution:
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} RHEL 8
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
for ver in 5.3.3 5.4.6 5.5.3 5.6.1; do
|
||||
sudo tee --append /etc/yum.repos.d/rocm.repo <<EOF
|
||||
[ROCm-$ver]
|
||||
name=ROCm$ver
|
||||
baseurl=https://repo.radeon.com/rocm/rhel8/$ver/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
done
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 9
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
for ver in 5.3.3 5.4.6 5.5.3 5.6.1; do
|
||||
sudo tee --append /etc/yum.repos.d/rocm.repo <<EOF
|
||||
[ROCm-$ver]
|
||||
name=ROCm$ver
|
||||
baseurl=https://repo.radeon.com/rocm/rhel9/$ver/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
done
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
::::{rubric} 3. Install packages
|
||||
::::
|
||||
|
||||
Install packages of your choice in a single-version ROCm install or
|
||||
in a multi-version ROCm install fashion. For more information on what
|
||||
single/multi-version installations are, refer to {ref}`installation-types`.
|
||||
For a comprehensive list of meta-packages, refer to
|
||||
{ref}`meta-package-desc`.
|
||||
|
||||
- Sample Single-version installation
|
||||
|
||||
```shell
|
||||
sudo yum install rocm-hip-sdk
|
||||
```
|
||||
|
||||
- Sample Multi-version installation
|
||||
|
||||
```shell
|
||||
sudo yum install rocm-hip-sdk5.6.1 rocm-hip-sdk5.5.3
|
||||
```
|
||||
|
||||
:::::
|
||||
:::::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
::::{rubric} 1. Add the AMDGPU Repository and Install the Kernel-mode Driver
|
||||
::::
|
||||
|
||||
```{tip}
|
||||
If you have a version of the kernel-mode driver installed, you may skip this
|
||||
section.
|
||||
```
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} SLES 15.4
|
||||
:sync: SLES-15.4
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/zypp/repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$ver/sle/15.4/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo zypper ref
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} SLES 15.5
|
||||
:sync: SLES-15.5
|
||||
|
||||
```shell
|
||||
# version
|
||||
ver=5.6.1
|
||||
|
||||
sudo tee /etc/zypp/repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$ver/sle/15.5/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo zypper ref
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
Install the kernel mode driver and reboot the system using the following
|
||||
commands:
|
||||
|
||||
```shell
|
||||
sudo zypper --gpg-auto-import-keys install amdgpu-dkms
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
::::{rubric} 2. Add the ROCm Stack Repository
|
||||
::::
|
||||
|
||||
To add the ROCm repository, use the following steps:
|
||||
|
||||
```shell
|
||||
for ver in 5.3.3 5.4.6 5.5.3 5.6.1; do
|
||||
sudo tee --append /etc/zypp/repos.d/rocm.repo <<EOF
|
||||
[ROCm-$ver]
|
||||
name=ROCm$ver
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/zyp/$ver/main
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
done
|
||||
sudo zypper ref
|
||||
```
|
||||
|
||||
::::{rubric} 3. Install packages
|
||||
::::
|
||||
|
||||
Install packages of your choice in a single-version ROCm install or
|
||||
in a multi-version ROCm install fashion. For more information on what
|
||||
single/multi-version installations are, refer to {ref}`installation-types`.
|
||||
For a comprehensive list of meta-packages, refer to
|
||||
{ref}`meta-package-desc`.
|
||||
|
||||
- Sample Single-version installation
|
||||
|
||||
```shell
|
||||
sudo zypper --gpg-auto-import-keys install rocm-hip-sdk
|
||||
```
|
||||
|
||||
- Sample Multi-version installation
|
||||
|
||||
```shell
|
||||
sudo zypper --gpg-auto-import-keys install rocm-hip-sdk5.6.1 rocm-hip-sdk5.5.3
|
||||
```
|
||||
|
||||
:::::
|
||||
::::::
|
||||
|
||||
(post-install-actions-linux)=
|
||||
|
||||
## Post-install Actions and Verification Process
|
||||
|
||||
The post-install actions listed here are optional and depend on your use case,
|
||||
but are generally useful. Verification of the install is advised.
|
||||
|
||||
### Post-install Actions
|
||||
|
||||
1. Instruct the system linker where to find the shared objects (`.so` files) for
|
||||
ROCm applications.
|
||||
|
||||
```shell
|
||||
sudo tee --append /etc/ld.so.conf.d/rocm.conf <<EOF
|
||||
/opt/rocm/lib
|
||||
/opt/rocm/lib64
|
||||
EOF
|
||||
sudo ldconfig
|
||||
```
|
||||
|
||||
```{note}
|
||||
Multi-version installations require extra care. Having multiple versions on
|
||||
the system linker library search path is unadvised. One must take care both
|
||||
at compile-time and at run-time to assure that the proper libraries are
|
||||
picked up. You can override `ld.so.conf` entries on a case-by-case basis
|
||||
using the `LD_LIBRARY_PATH` environmental variable.
|
||||
```
|
||||
|
||||
2. Add binary paths to the `PATH` environment variable.
|
||||
|
||||
```shell
|
||||
export PATH=$PATH:/opt/rocm-5.6.1/bin:/opt/rocm-5.6.1/opencl/bin
|
||||
|
||||
```
|
||||
|
||||
```{attention}
|
||||
When using CMake to build applications, having the ROCm install location on
|
||||
the PATH subtly affects how ROCm libraries are searched for. See [Config Mode
|
||||
Search Procedure](https://cmake.org/cmake/help/latest/command/find_package.html#config-mode-search-procedure)
|
||||
and [CMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH](https://cmake.org/cmake/help/latest/variable/CMAKE_FIND_USE_SYSTEM_ENVIRONMENT_PATH.html)
|
||||
for details.
|
||||
|
||||
(Entries in the `PATH` minus `bin` and `sbin` are added to library search
|
||||
paths, therefore this convenience will affect builds and result in ROCm
|
||||
libraries almost always being found. This may be an issue when you're
|
||||
developing these libraries or want to use self-built versions of them.)
|
||||
```
|
||||
|
||||
(verifying-kernel-mode-driver-installation)=
|
||||
|
||||
### Verifying Kernel-mode Driver Installation
|
||||
|
||||
Check the installation of the kernel-mode driver by typing the command given
|
||||
below:
|
||||
|
||||
```shell
|
||||
dkms status
|
||||
```
|
||||
|
||||
### Verifying ROCm Installation
|
||||
|
||||
After completing the ROCm installation, execute the following commands on the
|
||||
system to verify if the installation is successful. If you see your GPUs listed
|
||||
by both commands, the installation is considered successful:
|
||||
|
||||
```shell
|
||||
/opt/rocm/bin/rocminfo
|
||||
# OR
|
||||
/opt/rocm/opencl/bin/clinfo
|
||||
```
|
||||
|
||||
### Verifying Package Installation
|
||||
|
||||
To ensure the packages are installed successfully, use the following commands:
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
```shell
|
||||
sudo apt list --installed
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
```shell
|
||||
sudo yum list installed
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
```shell
|
||||
sudo zypper search --installed-only
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
@@ -0,0 +1,116 @@
|
||||
# Package Manager Integration
|
||||
|
||||
This section provides information about the required meta-packages for the
|
||||
following AMD ROCm programming models:
|
||||
|
||||
- Heterogeneous-Computing Interface for Portability (HIP)
|
||||
- OpenCL™
|
||||
- OpenMP™
|
||||
|
||||
## ROCm Package Naming Conventions
|
||||
|
||||
A meta-package is a grouping of related packages and dependencies used to
|
||||
support a specific use case.
|
||||
|
||||
**Example:** Running HIP applications
|
||||
|
||||
All meta-packages exist in both versioned and non-versioned forms.
|
||||
|
||||
- Non-versioned packages – For a single-version installation of the ROCm stack
|
||||
- Versioned packages – For multi-version installations of the ROCm stack
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/linux/linux002.png
|
||||
:name: package-naming
|
||||
:align: center
|
||||
|
||||
ROCm Release Package Naming
|
||||
```
|
||||
|
||||
The preceding image demonstrates the single and multi-version ROCm packages' naming
|
||||
structure, including examples for various Linux distributions. See terms below:
|
||||
|
||||
_Module_ - It is the part of the package that represents the name of the ROCm
|
||||
component.
|
||||
|
||||
**Example:** The examples mentioned in the image represent the ROCm HIP module.
|
||||
|
||||
_Module version_ - It is the version of the library released in that package. It
|
||||
should increase with a newer release.
|
||||
|
||||
_Release version_ - It shows the ROCm release version when the package was
|
||||
released.
|
||||
|
||||
**Example:** `50400` points to the ROCm 5.4.0 release.
|
||||
|
||||
_Build id_ - It represents the Jenkins build number for that release.
|
||||
|
||||
_Arch_ - It shows the architecture for which the package was created.
|
||||
|
||||
_Distro_ - It describes the distribution for which the package was created. It is
|
||||
valid only for rpm packages.
|
||||
|
||||
**Example:** `el8` represents RHEL 8.x packages.
|
||||
|
||||
## Components of ROCm Programming Models
|
||||
|
||||
The following image demonstrates the high-level layered architecture of ROCm
|
||||
programming models and their meta-packages. All meta-packages are a combination
|
||||
of required packages and libraries.
|
||||
|
||||
**Example:**
|
||||
|
||||
- `rocm-hip-runtime` is used to deploy on supported machines to execute HIP
|
||||
applications.
|
||||
- `rocm-hip-sdk` contains runtime components to deploy and execute HIP
|
||||
applications.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/linux/linux003.png
|
||||
:name: meta-packages
|
||||
|
||||
ROCm Meta Packages
|
||||
```
|
||||
|
||||
```{note}
|
||||
`rocm-llvm` is not a meta-package but a single package that installs the ROCm
|
||||
clang compiler files.
|
||||
```
|
||||
|
||||
```{table} Meta-packages and Their Descriptions
|
||||
:name: meta-package-desc
|
||||
| **Meta-packages** | **Description** |
|
||||
|:---------------------------|-----------------------------------------------------------------------------------------------------------------------------------------:|
|
||||
| `rocm-language-runtime` | The ROCm runtime |
|
||||
| `rocm-hip-runtime` | Run HIP applications written for the AMD platform |
|
||||
| `rocm-opencl-runtime` | Run OpenCL-based applications on the AMD platform |
|
||||
| `rocm-hip-runtime-devel` | Develop applications on HIP or port from CUDA |
|
||||
| `rocm-opencl-sdk` | Develop applications in OpenCL for the AMD platform |
|
||||
| `rocm-hip-libraries` | HIP libraries optimized for the AMD platform |
|
||||
| `rocm-hip-sdk` | Develop or port HIP applications and libraries for the AMD platform |
|
||||
| `rocm-developer-tools` | Debug and profile HIP applications |
|
||||
| `rocm-ml-sdk` | Develop and run Machine Learning applications with optimized for AMD |
|
||||
| `rocm-ml-libraries` | Key Machine Learning libraries, specifically MIOpen |
|
||||
| `rocm-openmp-sdk` | Develop OpenMP-based applications for the AMD platform |
|
||||
| `rocm-openmp-runtime` | Run OpenMP-based applications for the AMD platform |
|
||||
```
|
||||
|
||||
## Packages in ROCm Programming Models
|
||||
|
||||
This section discusses the available meta-packages and their packages. The
|
||||
following image visualizes the meta-packages and their associated packages in a
|
||||
ROCm programming model.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/linux/linux004.png
|
||||
:name: assoc-packages
|
||||
|
||||
Associated Packages
|
||||
```
|
||||
|
||||
- Meta-packages can include another meta-package.
|
||||
- `rocm-core` package is common across all the meta-packages.
|
||||
- Meta-packages and associated packages are represented in the same color.
|
||||
|
||||
```{note}
|
||||
The preceding image is for informational purposes only, as the individual
|
||||
packages in a meta-package are subject to change. Install meta-packages, and not
|
||||
individual packages, to avoid conflicts.
|
||||
```
|
||||
170
docs/tutorials/install/linux/os-native/uninstall.md
Normal file
170
docs/tutorials/install/linux/os-native/uninstall.md
Normal file
@@ -0,0 +1,170 @@
|
||||
# Uninstallation with package manager (Linux)
|
||||
|
||||
This section describes how to uninstall ROCm with the Linux distribution's
|
||||
package manager. This method should be used if ROCm was installed via the package
|
||||
manager. If the installer script was used for installation, then it should be
|
||||
used for uninstallation too, refer to {doc}`../installer/uninstall`.
|
||||
|
||||
::::::{tab-set}
|
||||
:::::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
::::{rubric} Uninstalling Specific Meta-packages
|
||||
::::
|
||||
|
||||
```shell
|
||||
# Uninstall single-version ROCm packages
|
||||
sudo apt autoremove <package-name>
|
||||
# Uninstall multiversion ROCm packages
|
||||
sudo apt autoremove <package-name with release version>
|
||||
```
|
||||
|
||||
::::{rubric} Complete Uninstallation of ROCm Packages
|
||||
::::
|
||||
|
||||
```shell
|
||||
# Uninstall single-version ROCm packages
|
||||
sudo apt autoremove rocm-core
|
||||
# Uninstall multiversion ROCm packages
|
||||
sudo apt autoremove rocm-core<release version>
|
||||
```
|
||||
|
||||
::::{rubric} Uninstall Kernel-mode Driver
|
||||
::::
|
||||
|
||||
```shell
|
||||
sudo apt autoremove amdgpu-dkms
|
||||
```
|
||||
|
||||
::::{rubric} Remove ROCm and AMDGPU Repositories
|
||||
::::
|
||||
|
||||
1. Execute these commands:
|
||||
|
||||
```shell
|
||||
sudo rm /etc/apt/sources.list.d/<rocm_repository-name>.list
|
||||
sudo rm /etc/apt/sources.list.d/<amdgpu_repository-name>.list
|
||||
```
|
||||
|
||||
2. Clear the cache and clean the system.
|
||||
|
||||
```shell
|
||||
sudo rm -rf /var/cache/apt/*
|
||||
sudo apt-get clean all
|
||||
```
|
||||
|
||||
3. Restart the system.
|
||||
|
||||
```shell
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
:::::
|
||||
:::::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
::::{rubric} Uninstalling Specific Meta-packages
|
||||
::::
|
||||
|
||||
```shell
|
||||
# Uninstall single-version ROCm packages
|
||||
sudo yum remove <package-name>
|
||||
# Uninstall multiversion ROCm packages
|
||||
sudo yum remove <package-name with release version>
|
||||
```
|
||||
|
||||
::::{rubric} Complete Uninstallation of ROCm Packages
|
||||
::::
|
||||
|
||||
```shell
|
||||
# Uninstall single-version ROCm packages
|
||||
sudo yum remove rocm-core
|
||||
# Uninstall multiversion ROCm packages
|
||||
sudo yum remove rocm-core<release version>
|
||||
```
|
||||
|
||||
::::{rubric} Uninstall Kernel-mode Driver
|
||||
::::
|
||||
|
||||
```shell
|
||||
sudo yum autoremove amdgpu-dkms
|
||||
```
|
||||
|
||||
::::{rubric} Remove ROCm and AMDGPU Repositories
|
||||
::::
|
||||
|
||||
1. Execute these commands:
|
||||
|
||||
```shell
|
||||
sudo rm -rf /etc/yum.repos.d/<rocm_repository-name> # Remove only rocm repo
|
||||
sudo rm -rf /etc/yum.repos.d/<amdgpu_repository-name> # Remove only amdgpu repo
|
||||
```
|
||||
|
||||
2. Clear the cache and clean the system.
|
||||
|
||||
```shell
|
||||
sudo rm -rf /var/cache/yum #Remove the cache
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
3. Restart the system.
|
||||
|
||||
```shell
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
:::::
|
||||
:::::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
::::{rubric} Uninstalling Specific Meta-packages
|
||||
::::
|
||||
|
||||
```shell
|
||||
# Uninstall all single-version ROCm packages
|
||||
sudo zypper remove <package-name>
|
||||
# Uninstall all multiversion ROCm packages
|
||||
sudo zypper remove <package-name with release version>
|
||||
```
|
||||
|
||||
::::{rubric} Complete Uninstallation of ROCm Packages
|
||||
::::
|
||||
|
||||
```shell
|
||||
# Uninstall all single-version ROCm packages
|
||||
sudo zypper remove rocm-core
|
||||
# Uninstall all multiversion ROCm packages
|
||||
sudo zypper remove rocm-core<release version>
|
||||
```
|
||||
|
||||
::::{rubric} Uninstall Kernel-mode Driver
|
||||
::::
|
||||
|
||||
```shell
|
||||
sudo zypper remove --clean-deps amdgpu-dkms
|
||||
```
|
||||
|
||||
::::{rubric} Remove ROCm and AMDGPU Repositories
|
||||
::::
|
||||
|
||||
1. Execute these commands:
|
||||
|
||||
```shell
|
||||
sudo zypper removerepo <rocm_repository-name>
|
||||
sudo zypper removerepo <amdgpu_repository-name>
|
||||
```
|
||||
|
||||
2. Clear the cache and clean the system.
|
||||
|
||||
```shell
|
||||
sudo zypper clean --all
|
||||
```
|
||||
|
||||
3. Restart the system.
|
||||
|
||||
```shell
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
:::::
|
||||
::::::
|
||||
401
docs/tutorials/install/linux/os-native/upgrade.md
Normal file
401
docs/tutorials/install/linux/os-native/upgrade.md
Normal file
@@ -0,0 +1,401 @@
|
||||
# Upgrade ROCm with the package manager
|
||||
|
||||
This section explains how to upgrade the existing AMDGPU driver and ROCm
|
||||
packages to the latest version using your OS's distributed package manager.
|
||||
|
||||
```{note}
|
||||
Package upgrade is applicable to single-version packages only. If the preference
|
||||
is to install an updated version of the ROCm along with the currently
|
||||
installed version, refer to the [](install) page.
|
||||
```
|
||||
|
||||
## Upgrade Steps
|
||||
|
||||
### Update the AMDGPU repository
|
||||
|
||||
Execute the commands below based on your distribution to point the `amdgpu`
|
||||
repository to the new release.
|
||||
|
||||
::::::{tab-set}
|
||||
:::::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu 20.04
|
||||
:sync: ubuntu-20.04
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
# amdgpu repository for focal
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/amdgpu/$version/ubuntu focal main" \
|
||||
| sudo tee /etc/apt/sources.list.d/amdgpu.list
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Ubuntu 22.04
|
||||
:sync: ubuntu-22.04
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
# amdgpu repository for jammy
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/amdgpu/$version/ubuntu jammy main" \
|
||||
| sudo tee /etc/apt/sources.list.d/amdgpu.list
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
:::::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} RHEL 8.6
|
||||
:sync: RHEL-8.6
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$version/rhel/8.6/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 8.7
|
||||
:sync: RHEL-8.7
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$version/rhel/8.7/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 8.8
|
||||
:sync: RHEL-8.8
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$version/rhel/8.8/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 9.1
|
||||
:sync: RHEL-9.1
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$version/rhel/9.1/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 9.2
|
||||
:sync: RHEL-9.2
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$version/rhel/9.2/main/x86_64/
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
:::::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} SLES 15.4
|
||||
:sync: SLES-15.4
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/zypp/repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/$version/sle/15.4/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo zypper ref
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} SLES 15.5
|
||||
:sync: SLES-15.5
|
||||
|
||||
```shell
|
||||
sudo tee /etc/zypp/repos.d/amdgpu.repo <<EOF
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/5.6/sle/15.5/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo zypper ref
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
::::::
|
||||
|
||||
### Upgrade the kernel-mode driver & reboot
|
||||
|
||||
Upgrade the kernel mode driver and reboot the system using the following
|
||||
commands based on your distribution:
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
```shell
|
||||
sudo apt install amdgpu-dkms
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
```shell
|
||||
sudo yum install amdgpu-dkms
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
```shell
|
||||
sudo zypper --gpg-auto-import-keys install amdgpu-dkms
|
||||
sudo reboot
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
### Update the ROCm repository
|
||||
|
||||
Execute the commands below based on your distribution to point the `rocm`
|
||||
repository to the new release.
|
||||
|
||||
::::::{tab-set}
|
||||
:::::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu 20.04
|
||||
:sync: ubuntu-20.04
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/rocm/apt/$version focal main" \
|
||||
| sudo tee /etc/apt/sources.list.d/rocm.list
|
||||
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' \
|
||||
| sudo tee /etc/apt/preferences.d/rocm-pin-600
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Ubuntu 22.04
|
||||
:sync: ubuntu-22.04
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/rocm/apt/$version jammy main" \
|
||||
| sudo tee /etc/apt/sources.list.d/rocm.list
|
||||
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' \
|
||||
| sudo tee /etc/apt/preferences.d/rocm-pin-600
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
:::::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} RHEL 8
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/yum.repos.d/rocm.repo <<EOF
|
||||
[ROCm-$ver]
|
||||
name=ROCm$ver
|
||||
baseurl=https://repo.radeon.com/rocm/rhel8/$version/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 9
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
|
||||
sudo tee /etc/yum.repos.d/rocm.repo <<EOF
|
||||
[ROCm-$ver]
|
||||
name=ROCm$ver
|
||||
baseurl=https://repo.radeon.com/rocm/rhel9/$version/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
:::::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
```shell
|
||||
# version
|
||||
version=5.6.1
|
||||
|
||||
sudo tee /etc/zypp/repos.d/rocm.repo <<EOF
|
||||
[ROCm-$ver]
|
||||
name=ROCm$ver
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/zyp/$version/main
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
sudo zypper ref
|
||||
```
|
||||
|
||||
:::::
|
||||
::::::
|
||||
|
||||
### Upgrade the ROCm packages
|
||||
|
||||
Your packages can be upgraded now through their meta-packages, see the following
|
||||
example based on your distribution:
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
```shell
|
||||
sudo apt install --only-upgrade rocm-hip-sdk
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
```shell
|
||||
sudo yum update rocm-hip-sdk
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Suse Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
```shell
|
||||
sudo zypper --gpg-auto-import-keys update rocm-hip-sdk
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
## Verification Process
|
||||
|
||||
To verify if the upgrade is successful, refer to the
|
||||
{ref}`post-install-actions-linux` given in the
|
||||
[Installation](install) section.
|
||||
212
docs/tutorials/install/linux/prerequisites.md
Normal file
212
docs/tutorials/install/linux/prerequisites.md
Normal file
@@ -0,0 +1,212 @@
|
||||
# Installation Prerequisites (Linux)
|
||||
|
||||
You must perform the following steps before installing ROCm and check if the
|
||||
system meets all the requirements to proceed with the installation.
|
||||
|
||||
## Confirm the System Has a Supported Linux Distribution Version
|
||||
|
||||
The ROCm installation is supported only on specific Linux distributions and
|
||||
kernel versions.
|
||||
|
||||
### Check the Linux Distribution and Kernel Version on Your System
|
||||
|
||||
This section discusses obtaining information about the Linux distribution and
|
||||
kernel version.
|
||||
|
||||
#### Linux Distribution Information
|
||||
|
||||
Verify the Linux distribution using the following steps:
|
||||
|
||||
1. To obtain the Linux distribution information, type the following command on
|
||||
your system from the Command Line Interface (CLI):
|
||||
|
||||
```shell
|
||||
uname -m && cat /etc/*release
|
||||
```
|
||||
|
||||
2. Confirm that the obtained Linux distribution information matches with those listed in {ref}`linux_support`.
|
||||
|
||||
**Example:** Running the command above on an Ubuntu system results in the
|
||||
following output:
|
||||
|
||||
```shell
|
||||
x86_64
|
||||
DISTRIB_ID=Ubuntu
|
||||
DISTRIB_RELEASE=20.04
|
||||
DISTRIB_CODENAME=focal
|
||||
DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS"
|
||||
```
|
||||
|
||||
(check-kernel-info)=
|
||||
|
||||
#### Kernel Information
|
||||
|
||||
Verify the kernel version using the following steps:
|
||||
|
||||
1. To check the kernel version of your Linux system, type the following command:
|
||||
|
||||
```shell
|
||||
uname -srmv
|
||||
```
|
||||
|
||||
**Example:** The output of the command above lists the kernel version in the
|
||||
following format:
|
||||
|
||||
```output
|
||||
Linux 5.15.0-46-generic #44~20.04.5-Ubuntu SMP Fri Jun 24 13:27:29 UTC 2022 x86_64
|
||||
```
|
||||
|
||||
2. Confirm that the obtained kernel version information matches with system
|
||||
requirements as listed in {ref}`linux_support`.
|
||||
|
||||
## Additional package repositories
|
||||
|
||||
On some distributions the ROCm packages depend on packages outside the default
|
||||
package repositories. These extra repositories need to be enabled before
|
||||
installation. Follow the instructions below based on your distributions.
|
||||
|
||||
::::::{tab-set}
|
||||
|
||||
:::::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
All packages are available in the default Ubuntu repositories, therefore
|
||||
no additional repositories need to be added.
|
||||
|
||||
:::::
|
||||
:::::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
::::{rubric} 1. Add the EPEL repository
|
||||
::::
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} RHEL 8
|
||||
:sync: RHEL-8
|
||||
|
||||
```shell
|
||||
wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
|
||||
sudo rpm -ivh epel-release-latest-8.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} RHEL 9
|
||||
:sync: RHEL-9
|
||||
|
||||
```shell
|
||||
wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
|
||||
sudo rpm -ivh epel-release-latest-9.noarch.rpm
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
::::{rubric} 2. Enable the CodeReady Linux Builder repository
|
||||
::::
|
||||
|
||||
Run the following command and follow the instructions.
|
||||
|
||||
```shell
|
||||
sudo crb enable
|
||||
```
|
||||
|
||||
:::::
|
||||
:::::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
Add the perl languages repository.
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} SLES 15.4
|
||||
:sync: SLES-15.4
|
||||
|
||||
```shell
|
||||
zypper addrepo https://download.opensuse.org/repositories/devel:languages:perl/SLE_15_SP4/devel:languages:perl.repo
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} SLES 15.5
|
||||
:sync: SLES-15.5
|
||||
|
||||
```shell
|
||||
zypper addrepo https://download.opensuse.org/repositories/devel:/languages:/perl/15.5/devel:languages:perl.repo
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
:::::
|
||||
::::::
|
||||
|
||||
## Kernel headers and development packages
|
||||
|
||||
The driver package uses
|
||||
[{abbr}`DKMS (Dynamic Kernel Module Support)`][DKMS-wiki] to build
|
||||
the `amdgpu-dkms` module (driver) for the installed kernels. This requires the
|
||||
Linux kernel headers and modules to be installed for each. Usually these are
|
||||
automatically installed with the kernel, but if you have multiple kernel
|
||||
versions or you have downloaded the kernel images and not the kernel
|
||||
meta-packages then they must be manually installed.
|
||||
|
||||
[DKMS-wiki]: https://en.wikipedia.org/wiki/Dynamic_Kernel_Module_Support
|
||||
|
||||
To install for the currently active kernel run the command corresponding
|
||||
to your distribution.
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
```shell
|
||||
sudo apt install "linux-headers-$(uname -r)" "linux-modules-extra-$(uname -r)"
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
```shell
|
||||
sudo yum install kernel-headers kernel-devel
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
```shell
|
||||
sudo zypper install kernel-default-devel
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
(linux_group_permissions)=
|
||||
|
||||
## Setting Permissions for Groups
|
||||
|
||||
This section provides steps to add any current user to a video group to access
|
||||
GPU resources.
|
||||
Use of the video group is recommended for all ROCm-supported operating
|
||||
systems.
|
||||
|
||||
1. To check the groups in your system, issue the following command:
|
||||
|
||||
```shell
|
||||
groups
|
||||
```
|
||||
|
||||
2. Add yourself to the `render` and `video` group using the command:
|
||||
|
||||
```shell
|
||||
sudo usermod -a -G render,video $LOGNAME
|
||||
```
|
||||
|
||||
To add all future users to the `video` and `render` groups by default, run
|
||||
the following commands:
|
||||
|
||||
```shell
|
||||
echo 'ADD_EXTRA_GROUPS=1' | sudo tee -a /etc/adduser.conf
|
||||
echo 'EXTRA_GROUPS=video' | sudo tee -a /etc/adduser.conf
|
||||
echo 'EXTRA_GROUPS=render' | sudo tee -a /etc/adduser.conf
|
||||
```
|
||||
92
docs/tutorials/install/magma_install.md
Normal file
92
docs/tutorials/install/magma_install.md
Normal file
@@ -0,0 +1,92 @@
|
||||
# Magma Installation for ROCm
|
||||
|
||||
## MAGMA for ROCm
|
||||
|
||||
Matrix Algebra on GPU and Multi-core Architectures, abbreviated as MAGMA, is a
|
||||
collection of next-generation dense linear algebra libraries that is designed
|
||||
for heterogeneous architectures, such as multiple GPUs and multi- or many-core
|
||||
CPUs.
|
||||
|
||||
MAGMA provides implementations for CUDA, HIP, Intel Xeon Phi, and OpenCL™. For
|
||||
more information, refer to
|
||||
[https://icl.utk.edu/magma/index.html](https://icl.utk.edu/magma/index.html).
|
||||
|
||||
### Using MAGMA for PyTorch
|
||||
|
||||
Tensor is fundamental to Deep Learning techniques because it provides extensive
|
||||
representational functionalities and math operations. This data structure is
|
||||
represented as a multidimensional matrix. MAGMA accelerates tensor operations
|
||||
with a variety of solutions including driver routines, computational routines,
|
||||
BLAS routines, auxiliary routines, and utility routines.
|
||||
|
||||
### Build MAGMA from Source
|
||||
|
||||
To build MAGMA from the source, follow these steps:
|
||||
|
||||
1. In the event you want to compile only for your uarch, use:
|
||||
|
||||
```bash
|
||||
export PYTORCH_ROCM_ARCH=<uarch>
|
||||
```
|
||||
|
||||
`<uarch>` is the architecture reported by the `rocminfo` command.
|
||||
|
||||
2. Use the following:
|
||||
|
||||
```bash
|
||||
export PYTORCH_ROCM_ARCH=<uarch>
|
||||
|
||||
# "install" hipMAGMA into /opt/rocm/magma by copying after build
|
||||
git clone https://bitbucket.org/icl/magma.git
|
||||
pushd magma
|
||||
# Fixes memory leaks of magma found while executing linalg UTs
|
||||
git checkout 5959b8783e45f1809812ed96ae762f38ee701972
|
||||
cp make.inc-examples/make.inc.hip-gcc-mkl make.inc
|
||||
echo 'LIBDIR += -L$(MKLROOT)/lib' >> make.inc
|
||||
echo 'LIB += -Wl,--enable-new-dtags -Wl,--rpath,/opt/rocm/lib -Wl,--rpath,$(MKLROOT)/lib -Wl,--rpath,/opt/rocm/magma/lib' >> make.inc
|
||||
echo 'DEVCCFLAGS += --gpu-max-threads-per-block=256' >> make.inc
|
||||
export PATH="${PATH}:/opt/rocm/bin"
|
||||
if [[ -n "$PYTORCH_ROCM_ARCH" ]]; then
|
||||
amdgpu_targets=`echo $PYTORCH_ROCM_ARCH | sed 's/;/ /g'`
|
||||
else
|
||||
amdgpu_targets=`rocm_agent_enumerator | grep -v gfx000 | sort -u | xargs`
|
||||
fi
|
||||
for arch in $amdgpu_targets; do
|
||||
echo "DEVCCFLAGS += --amdgpu-target=$arch" >> make.inc
|
||||
done
|
||||
# hipcc with openmp flag may cause isnan() on __device__ not to be found; depending on context, compiler may attempt to match with host definition
|
||||
sed -i 's/^FOPENMP/#FOPENMP/g' make.inc
|
||||
make -f make.gen.hipMAGMA -j $(nproc)
|
||||
LANG=C.UTF-8 make lib/libmagma.so -j $(nproc) MKLROOT=/opt/conda
|
||||
make testing/testing_dgemm -j $(nproc) MKLROOT=/opt/conda
|
||||
popd
|
||||
mv magma /opt/rocm
|
||||
```
|
||||
|
||||
## References
|
||||
|
||||
C. Szegedy, V. Vanhoucke, S. Ioffe, J. Shlens and Z. Wojna, "Rethinking the Inception Architecture for Computer Vision," CoRR, p. abs/1512.00567, 2015
|
||||
|
||||
PyTorch, \[Online\]. Available: [https://pytorch.org/vision/stable/index.html](https://pytorch.org/vision/stable/index.html)
|
||||
|
||||
PyTorch, \[Online\]. Available: [https://pytorch.org/hub/pytorch_vision_inception_v3/](https://pytorch.org/hub/pytorch_vision_inception_v3/)
|
||||
|
||||
Stanford, \[Online\]. Available: [http://cs231n.stanford.edu/](http://cs231n.stanford.edu/)
|
||||
|
||||
Wikipedia, \[Online\]. Available: [https://en.wikipedia.org/wiki/Cross_entropy](https://en.wikipedia.org/wiki/Cross_entropy)
|
||||
|
||||
AMD, "ROCm issues," \[Online\]. Available: [https://github.com/RadeonOpenCompute/ROCm/issues](https://github.com/RadeonOpenCompute/ROCm/issues)
|
||||
|
||||
PyTorch, \[Online image\]. [https://pytorch.org/assets/brand-guidelines/PyTorch-Brand-Guidelines.pdf](https://pytorch.org/assets/brand-guidelines/PyTorch-Brand-Guidelines.pdf)
|
||||
|
||||
TensorFlow, \[Online image\]. [https://www.tensorflow.org/extras/tensorflow_brand_guidelines.pdf](https://www.tensorflow.org/extras/tensorflow_brand_guidelines.pdf)
|
||||
|
||||
MAGMA, \[Online image\]. [https://bitbucket.org/icl/magma/src/master/docs/](https://bitbucket.org/icl/magma/src/master/docs/)
|
||||
|
||||
Advanced Micro Devices, Inc., \[Online\]. Available: [https://rocmsoftwareplatform.github.io/AMDMIGraphX/doc/html/](https://rocmsoftwareplatform.github.io/AMDMIGraphX/doc/html/)
|
||||
|
||||
Advanced Micro Devices, Inc., \[Online\]. Available: [https://github.com/ROCmSoftwarePlatform/AMDMIGraphX/wiki](https://github.com/ROCmSoftwarePlatform/AMDMIGraphX/wiki)
|
||||
|
||||
Docker, \[Online\]. [https://docs.docker.com/get-started/overview/](https://docs.docker.com/get-started/overview/)
|
||||
|
||||
Torchvision, \[Online\]. Available [https://pytorch.org/vision/master/index.html?highlight=torchvision#module-torchvision](https://pytorch.org/vision/master/index.html?highlight=torchvision#module-torchvision)
|
||||
448
docs/tutorials/install/pytorch_install.md
Normal file
448
docs/tutorials/install/pytorch_install.md
Normal file
@@ -0,0 +1,448 @@
|
||||
# PyTorch Installation for ROCm
|
||||
|
||||
## PyTorch
|
||||
|
||||
PyTorch is an open-source machine learning Python library, primarily
|
||||
differentiated by Tensor computing with GPU acceleration and a type-based
|
||||
automatic differentiation. Other advanced features include:
|
||||
|
||||
- Support for distributed training
|
||||
- Native ONNX support
|
||||
- C++ front-end
|
||||
- The ability to deploy at scale using TorchServe
|
||||
- A production-ready deployment mechanism through TorchScript
|
||||
|
||||
### Installing PyTorch
|
||||
|
||||
To install ROCm on bare metal, refer to the sections
|
||||
[GPU and OS Support (Linux)](../../about/release/linux_support) and
|
||||
[Compatibility](../../about/compatibility/index) for hardware, software and
|
||||
3rd-party framework compatibility between ROCm and PyTorch. The recommended
|
||||
option to get a PyTorch environment is through Docker. However, installing the
|
||||
PyTorch wheels package on bare metal is also supported.
|
||||
|
||||
#### Option 1 (Recommended): Use Docker Image with PyTorch Pre-Installed
|
||||
|
||||
Using Docker gives you portability and access to a prebuilt Docker container
|
||||
that has been rigorously tested within AMD. This might also save on the
|
||||
compilation time and should perform as it did when tested without facing
|
||||
potential installation issues.
|
||||
|
||||
Follow these steps:
|
||||
|
||||
1. Pull the latest public PyTorch Docker image.
|
||||
|
||||
```bash
|
||||
docker pull rocm/pytorch:latest
|
||||
```
|
||||
|
||||
Optionally, you may download a specific and supported configuration with
|
||||
different user-space ROCm versions, PyTorch versions, and supported operating
|
||||
systems. To download the PyTorch Docker image, refer to
|
||||
[https://hub.docker.com/r/rocm/pytorch](https://hub.docker.com/r/rocm/pytorch).
|
||||
|
||||
2. Start a Docker container using the downloaded image.
|
||||
|
||||
```bash
|
||||
docker run -it --cap-add=SYS_PTRACE --security-opt seccomp=unconfined --device=/dev/kfd --device=/dev/dri --group-add video --ipc=host --shm-size 8G rocm/pytorch:latest
|
||||
```
|
||||
|
||||
:::{note}
|
||||
This will automatically download the image if it does not exist on the host.
|
||||
You can also pass the -v argument to mount any data directories from the host
|
||||
onto the container.
|
||||
:::
|
||||
|
||||
(install_pytorch_using_wheels)=
|
||||
|
||||
#### Option 2: Install PyTorch Using Wheels Package
|
||||
|
||||
PyTorch supports the ROCm platform by providing tested wheels packages. To
|
||||
access this feature, refer to
|
||||
[https://pytorch.org/get-started/locally/](https://pytorch.org/get-started/locally/)
|
||||
and choose the "ROCm" compute platform. The following image is a matrix from <https://pytorch.org/> that illustrates the installation compatibility between ROCm and the PyTorch build.
|
||||
|
||||
```{figure} ../../data/tutorials/install/magma_install/magma006.png
|
||||
:name: installation-matrix-pytorch
|
||||
:align: center
|
||||
|
||||
Installation Matrix from Pytorch
|
||||
```
|
||||
|
||||
To install PyTorch using the wheels package, follow these installation steps:
|
||||
|
||||
1. Choose one of the following options:
|
||||
a. Obtain a base Docker image with the correct user-space ROCm version
|
||||
installed from
|
||||
[https://hub.docker.com/repository/docker/rocm/dev-ubuntu-20.04](https://hub.docker.com/repository/docker/rocm/dev-ubuntu-20.04).
|
||||
|
||||
or
|
||||
|
||||
b. Download a base OS Docker image and install ROCm following the
|
||||
installation directions in the [Installation](../../tutorials/install/linux/index) section. ROCm 5.2 is installed in
|
||||
this example, as supported by the installation matrix from
|
||||
<https://pytorch.org/>.
|
||||
|
||||
or
|
||||
|
||||
c. Install on bare metal. Skip to Step 3.
|
||||
|
||||
```bash
|
||||
docker run -it --device=/dev/kfd --device=/dev/dri --group-add video rocm/dev-ubuntu-20.04:latest
|
||||
```
|
||||
|
||||
2. Start the Docker container, if not installing on bare metal.
|
||||
|
||||
```dockerfile
|
||||
docker run -it --device=/dev/kfd --device=/dev/dri --group-add video rocm/dev-ubuntu-20.04:latest
|
||||
```
|
||||
|
||||
3. Install any dependencies needed for installing the wheels package.
|
||||
|
||||
```bash
|
||||
sudo apt update
|
||||
sudo apt install libjpeg-dev python3-dev
|
||||
pip3 install wheel setuptools
|
||||
```
|
||||
|
||||
4. Install torch, `torchvision`, and `torchaudio` as specified by the installation
|
||||
matrix.
|
||||
|
||||
:::{note}
|
||||
ROCm 5.2 PyTorch wheel in the command below is shown for reference.
|
||||
:::
|
||||
|
||||
```bash
|
||||
pip3 install --pre torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/nightly/rocm5.2/
|
||||
```
|
||||
|
||||
#### Option 3: Install PyTorch Using PyTorch ROCm Base Docker Image
|
||||
|
||||
A prebuilt base Docker image is used to build PyTorch in this option. The base
|
||||
Docker has all dependencies installed, including:
|
||||
|
||||
- ROCm
|
||||
- Torchvision
|
||||
- Conda packages
|
||||
- Compiler toolchain
|
||||
|
||||
Additionally, a particular environment flag (`BUILD_ENVIRONMENT`) is set, and
|
||||
the build scripts utilize that to determine the build environment configuration.
|
||||
|
||||
Follow these steps:
|
||||
|
||||
1. Obtain the Docker image.
|
||||
|
||||
```bash
|
||||
docker pull rocm/pytorch:latest-base
|
||||
```
|
||||
|
||||
The above will download the base container, which does not contain PyTorch.
|
||||
|
||||
2. Start a Docker container using the image.
|
||||
|
||||
```bash
|
||||
docker run -it --cap-add=SYS_PTRACE --security-opt seccomp=unconfined --device=/dev/kfd --device=/dev/dri --group-add video --ipc=host --shm-size 8G rocm/pytorch:latest-base
|
||||
```
|
||||
|
||||
You can also pass the -v argument to mount any data directories from the host
|
||||
onto the container.
|
||||
|
||||
3. Clone the PyTorch repository.
|
||||
|
||||
```bash
|
||||
cd ~
|
||||
git clone https://github.com/pytorch/pytorch.git
|
||||
cd pytorch
|
||||
git submodule update --init --recursive
|
||||
```
|
||||
|
||||
4. Build PyTorch for ROCm.
|
||||
|
||||
:::{note}
|
||||
By default in the `rocm/pytorch:latest-base`, PyTorch builds for these
|
||||
architectures simultaneously:
|
||||
- gfx900
|
||||
- gfx906
|
||||
- gfx908
|
||||
- gfx90a
|
||||
- gfx1030
|
||||
:::
|
||||
|
||||
5. To determine your AMD uarch, run:
|
||||
|
||||
```bash
|
||||
rocminfo | grep gfx
|
||||
```
|
||||
|
||||
6. In the event you want to compile only for your uarch, use:
|
||||
|
||||
```bash
|
||||
export PYTORCH_ROCM_ARCH=<uarch>
|
||||
```
|
||||
|
||||
`<uarch>` is the architecture reported by the `rocminfo` command.
|
||||
|
||||
7. Build PyTorch using the following command:
|
||||
|
||||
```bash
|
||||
./.jenkins/pytorch/build.sh
|
||||
```
|
||||
|
||||
This will first convert PyTorch sources for HIP compatibility and build the
|
||||
PyTorch framework.
|
||||
|
||||
8. Alternatively, build PyTorch by issuing the following commands:
|
||||
|
||||
```bash
|
||||
python3 tools/amd_build/build_amd.py
|
||||
USE_ROCM=1 MAX_JOBS=4 python3 setup.py install --user
|
||||
```
|
||||
|
||||
#### Option 4: Install Using PyTorch Upstream Docker File
|
||||
|
||||
Instead of using a prebuilt base Docker image, you can build a custom base
|
||||
Docker image using scripts from the PyTorch repository. This will utilize a
|
||||
standard Docker image from operating system maintainers and install all the
|
||||
dependencies required to build PyTorch, including
|
||||
|
||||
- ROCm
|
||||
- Torchvision
|
||||
- Conda packages
|
||||
- Compiler toolchain
|
||||
|
||||
Follow these steps:
|
||||
|
||||
1. Clone the PyTorch repository on the host.
|
||||
|
||||
```bash
|
||||
cd ~
|
||||
git clone https://github.com/pytorch/pytorch.git
|
||||
cd pytorch
|
||||
git submodule update --init --recursive
|
||||
```
|
||||
|
||||
2. Build the PyTorch Docker image.
|
||||
|
||||
```bash
|
||||
cd.circleci/docker
|
||||
./build.sh pytorch-linux-bionic-rocm<version>-py3.7
|
||||
# eg. ./build.sh pytorch-linux-bionic-rocm3.10-py3.7
|
||||
```
|
||||
|
||||
This should be complete with a message "Successfully build `<image_id>`."
|
||||
|
||||
3. Start a Docker container using the image:
|
||||
|
||||
```bash
|
||||
docker run -it --cap-add=SYS_PTRACE --security-opt
|
||||
seccomp=unconfined --device=/dev/kfd --device=/dev/dri --group-add
|
||||
video --ipc=host --shm-size 8G <image_id>
|
||||
```
|
||||
|
||||
You can also pass -v argument to mount any data directories from the host
|
||||
onto the container.
|
||||
|
||||
4. Clone the PyTorch repository.
|
||||
|
||||
```bash
|
||||
cd ~
|
||||
git clone https://github.com/pytorch/pytorch.git
|
||||
cd pytorch
|
||||
git submodule update --init --recursive
|
||||
```
|
||||
|
||||
5. Build PyTorch for ROCm.
|
||||
|
||||
:::{note}
|
||||
By default in the `rocm/pytorch:latest-base`, PyTorch builds for these
|
||||
architectures simultaneously:
|
||||
- gfx900
|
||||
- gfx906
|
||||
- gfx908
|
||||
- gfx90a
|
||||
- gfx1030
|
||||
:::
|
||||
|
||||
6. To determine your AMD uarch, run:
|
||||
|
||||
```bash
|
||||
rocminfo | grep gfx
|
||||
```
|
||||
|
||||
7. If you want to compile only for your uarch:
|
||||
|
||||
```bash
|
||||
export PYTORCH_ROCM_ARCH=<uarch>
|
||||
```
|
||||
|
||||
`<uarch>` is the architecture reported by the `rocminfo` command.
|
||||
|
||||
8. Build PyTorch using:
|
||||
|
||||
```bash
|
||||
./.jenkins/pytorch/build.sh
|
||||
```
|
||||
|
||||
This will first convert PyTorch sources to be HIP compatible and then build the
|
||||
PyTorch framework.
|
||||
|
||||
Alternatively, build PyTorch by issuing the following commands:
|
||||
|
||||
```bash
|
||||
python3 tools/amd_build/build_amd.py
|
||||
USE_ROCM=1 MAX_JOBS=4 python3 setup.py install --user
|
||||
```
|
||||
|
||||
### Test the PyTorch Installation
|
||||
|
||||
You can use PyTorch unit tests to validate a PyTorch installation. If using a
|
||||
prebuilt PyTorch Docker image from AMD ROCm DockerHub or installing an official
|
||||
wheels package, these tests are already run on those configurations.
|
||||
Alternatively, you can manually run the unit tests to validate the PyTorch
|
||||
installation fully.
|
||||
|
||||
Follow these steps:
|
||||
|
||||
1. Test if PyTorch is installed and accessible by importing the torch package in
|
||||
Python.
|
||||
|
||||
:::{note}
|
||||
Do not run in the PyTorch git folder.
|
||||
:::
|
||||
|
||||
```bash
|
||||
python3 -c 'import torch' 2> /dev/null && echo 'Success' || echo 'Failure'
|
||||
```
|
||||
|
||||
2. Test if the GPU is accessible from PyTorch. In the PyTorch framework,
|
||||
`torch.cuda` is a generic mechanism to access the GPU; it will access an AMD
|
||||
GPU only if available.
|
||||
|
||||
```bash
|
||||
python3 -c 'import torch; print(torch.cuda.is_available())'
|
||||
```
|
||||
|
||||
3. Run the unit tests to validate the PyTorch installation fully. Run the
|
||||
following command from the PyTorch home directory:
|
||||
|
||||
```bash
|
||||
BUILD_ENVIRONMENT=${BUILD_ENVIRONMENT:-rocm} ./.jenkins/pytorch/test.sh
|
||||
```
|
||||
|
||||
This ensures that even for wheel installs in a non-controlled environment,
|
||||
the required environment variable will be set to skip certain unit tests for
|
||||
ROCm.
|
||||
|
||||
:::{note}
|
||||
Make sure the PyTorch source code is corresponding to the PyTorch wheel or
|
||||
installation in the Docker image. Incompatible PyTorch source code might give
|
||||
errors when running the unit tests.
|
||||
:::
|
||||
|
||||
This will first install some dependencies, such as a supported `torchvision`
|
||||
version for PyTorch. `torchvision` is used in some PyTorch tests for loading
|
||||
models. Next, this will run all the unit tests.
|
||||
|
||||
:::{note}
|
||||
Some tests may be skipped, as appropriate, based on your system
|
||||
configuration. All features of PyTorch are not supported on ROCm, and the
|
||||
tests that evaluate these features are skipped. In addition, depending on the
|
||||
host memory, or the number of available GPUs, other tests may be skipped. No
|
||||
test should fail if the compilation and installation are correct.
|
||||
:::
|
||||
|
||||
4. Run individual unit tests with the following command:
|
||||
|
||||
```bash
|
||||
PYTORCH_TEST_WITH_ROCM=1 python3 test/test_nn.py --verbose
|
||||
```
|
||||
|
||||
`test_nn.py` can be replaced with any other test set.
|
||||
|
||||
### Run a Basic PyTorch Example
|
||||
|
||||
The PyTorch examples repository provides basic examples that exercise the
|
||||
functionality of the framework. MNIST (Modified National Institute of Standards
|
||||
and Technology) database is a collection of handwritten digits that may be used
|
||||
to train a Convolutional Neural Network for handwriting recognition.
|
||||
Alternatively, ImageNet is a database of images used to train a network for
|
||||
visual object recognition.
|
||||
|
||||
Follow these steps:
|
||||
|
||||
1. Clone the PyTorch examples repository.
|
||||
|
||||
```bash
|
||||
git clone https://github.com/pytorch/examples.git
|
||||
```
|
||||
|
||||
2. Run the MNIST example.
|
||||
|
||||
```bash
|
||||
cd examples/mnist
|
||||
```
|
||||
|
||||
3. Follow the instructions in the `README` file in this folder. In this case:
|
||||
|
||||
```bash
|
||||
pip3 install -r requirements.txt
|
||||
python3 main.py
|
||||
```
|
||||
|
||||
4. Run the ImageNet example.
|
||||
|
||||
```bash
|
||||
cd examples/imagenet
|
||||
```
|
||||
|
||||
5. Follow the instructions in the `README` file in this folder. In this case:
|
||||
|
||||
```bash
|
||||
pip3 install -r requirements.txt
|
||||
python3 main.py
|
||||
```
|
||||
|
||||
## Using MIOpen kdb files with ROCm PyTorch wheels
|
||||
|
||||
PyTorch uses MIOpen for machine learning primitives. These primitives are compiled into kernels at runtime. Runtime compilation causes a small warm-up phase when starting PyTorch. MIOpen kdb files contain precompiled kernels that can speed up the warm-up phase of an application. More information is available in the {doc}`MIOpeninstallation page <miopen:install>`.
|
||||
|
||||
MIOpen kdb files can be used with ROCm PyTorch wheels. However, the kdb files need to be placed in a specific location with respect to the PyTorch installation path. A helper script simplifies this task for the user. The script takes in the ROCm version and user's GPU architecture as inputs, and works for Ubuntu and CentOS.
|
||||
|
||||
Helper script: [install_kdb_files_for_pytorch_wheels.sh](https://raw.githubusercontent.com/wiki/ROCmSoftwarePlatform/pytorch/files/install_kdb_files_for_pytorch_wheels.sh)
|
||||
|
||||
Usage:
|
||||
|
||||
After installing ROCm PyTorch wheels:
|
||||
|
||||
1. [Optional] `export GFX_ARCH=gfx90a`
|
||||
2. [Optional] `export ROCM_VERSION=5.5`
|
||||
3. `./install_kdb_files_for_pytorch_wheels.sh`
|
||||
|
||||
## References
|
||||
|
||||
C. Szegedy, V. Vanhoucke, S. Ioffe, J. Shlens and Z. Wojna, "Rethinking the Inception Architecture for Computer Vision," CoRR, p. abs/1512.00567, 2015
|
||||
|
||||
PyTorch, \[Online\]. Available: [https://pytorch.org/vision/stable/index.html](https://pytorch.org/vision/stable/index.html)
|
||||
|
||||
PyTorch, \[Online\]. Available: [https://pytorch.org/hub/pytorch_vision_inception_v3/](https://pytorch.org/hub/pytorch_vision_inception_v3/)
|
||||
|
||||
Stanford, \[Online\]. Available: [http://cs231n.stanford.edu/](http://cs231n.stanford.edu/)
|
||||
|
||||
Wikipedia, \[Online\]. Available: [https://en.wikipedia.org/wiki/Cross_entropy](https://en.wikipedia.org/wiki/Cross_entropy)
|
||||
|
||||
AMD, "ROCm issues," \[Online\]. Available: [https://github.com/RadeonOpenCompute/ROCm/issues](https://github.com/RadeonOpenCompute/ROCm/issues)
|
||||
|
||||
PyTorch, \[Online image\]. [https://pytorch.org/assets/brand-guidelines/PyTorch-Brand-Guidelines.pdf](https://pytorch.org/assets/brand-guidelines/PyTorch-Brand-Guidelines.pdf)
|
||||
|
||||
TensorFlow, \[Online image\]. [https://www.tensorflow.org/extras/tensorflow_brand_guidelines.pdf](https://www.tensorflow.org/extras/tensorflow_brand_guidelines.pdf)
|
||||
|
||||
MAGMA, \[Online image\]. [https://bitbucket.org/icl/magma/src/master/docs/](https://bitbucket.org/icl/magma/src/master/docs/)
|
||||
|
||||
Advanced Micro Devices, Inc., \[Online\]. Available: [https://rocmsoftwareplatform.github.io/AMDMIGraphX/doc/html/](https://rocmsoftwareplatform.github.io/AMDMIGraphX/doc/html/)
|
||||
|
||||
Advanced Micro Devices, Inc., \[Online\]. Available: [https://github.com/ROCmSoftwarePlatform/AMDMIGraphX/wiki](https://github.com/ROCmSoftwarePlatform/AMDMIGraphX/wiki)
|
||||
|
||||
Docker, \[Online\]. [https://docs.docker.com/get-started/overview/](https://docs.docker.com/get-started/overview/)
|
||||
|
||||
Torchvision, \[Online\]. Available [https://pytorch.org/vision/master/index.html?highlight=torchvision#module-torchvision](https://pytorch.org/vision/master/index.html?highlight=torchvision#module-torchvision)
|
||||
206
docs/tutorials/install/tensorflow_install.md
Normal file
206
docs/tutorials/install/tensorflow_install.md
Normal file
@@ -0,0 +1,206 @@
|
||||
# TensorFlow Installation for ROCm
|
||||
|
||||
## TensorFlow
|
||||
|
||||
TensorFlow is an open-source library for solving Machine Learning,
|
||||
Deep Learning, and Artificial Intelligence problems. It can be used to solve
|
||||
many problems across different sectors and industries but primarily focuses on
|
||||
training and inference in neural networks. It is one of the most popular and
|
||||
in-demand frameworks and is very active in open source contribution and
|
||||
development.
|
||||
|
||||
### Installing TensorFlow
|
||||
|
||||
The following sections contain options for installing TensorFlow.
|
||||
|
||||
#### Option 1: Install TensorFlow Using Docker Image
|
||||
|
||||
To install ROCm on bare metal, follow the section
|
||||
[Installation (Linux)](../../tutorials/install/linux/os-native/install). The recommended option to
|
||||
get a TensorFlow environment is through Docker.
|
||||
|
||||
Using Docker provides portability and access to a prebuilt Docker container that
|
||||
has been rigorously tested within AMD. This might also save compilation time and
|
||||
should perform as tested without facing potential installation issues.
|
||||
Follow these steps:
|
||||
|
||||
1. Pull the latest public TensorFlow Docker image.
|
||||
|
||||
```bash
|
||||
docker pull rocm/tensorflow:latest
|
||||
```
|
||||
|
||||
2. Once you have pulled the image, run it by using the command below:
|
||||
|
||||
```bash
|
||||
docker run -it --network=host --device=/dev/kfd --device=/dev/dri \
|
||||
--ipc=host --shm-size 16G --group-add video --cap-add=SYS_PTRACE \
|
||||
--security-opt seccomp=unconfined rocm/tensorflow:latest
|
||||
```
|
||||
|
||||
#### Option 2: Install TensorFlow Using Wheels Package
|
||||
|
||||
To install TensorFlow using the wheels package, follow these steps:
|
||||
|
||||
1. Check the Python version.
|
||||
|
||||
```bash
|
||||
python3 --version
|
||||
```
|
||||
|
||||
| If: | Then: |
|
||||
|:-----------------------------------:|:--------------------------------:|
|
||||
| The Python version is less than 3.7 | Upgrade Python. |
|
||||
| The Python version is more than 3.7 | Skip this step and go to Step 3. |
|
||||
|
||||
:::{note}
|
||||
The supported Python versions are:
|
||||
|
||||
- 3.7
|
||||
- 3.8
|
||||
- 3.9
|
||||
- 3.10
|
||||
:::
|
||||
|
||||
```bash
|
||||
sudo apt-get install python3.7 # or python3.8 or python 3.9 or python 3.10
|
||||
```
|
||||
|
||||
2. Set up multiple Python versions using update-alternatives.
|
||||
|
||||
```bash
|
||||
update-alternatives --query python3
|
||||
sudo update-alternatives --install
|
||||
/usr/bin/python3 python3 /usr/bin/python[version] [priority]
|
||||
```
|
||||
|
||||
:::{note}
|
||||
Follow the instruction in Step 2 for incompatible Python versions.
|
||||
:::
|
||||
|
||||
```bash
|
||||
sudo update-alternatives --config python3
|
||||
```
|
||||
|
||||
3. Follow the screen prompts, and select the Python version installed in Step 2.
|
||||
|
||||
4. Install or upgrade PIP.
|
||||
|
||||
```bash
|
||||
sudo apt install python3-pip
|
||||
```
|
||||
|
||||
To install PIP, use the following:
|
||||
|
||||
```bash
|
||||
/usr/bin/python[version] -m pip install --upgrade pip
|
||||
```
|
||||
|
||||
Upgrade PIP for Python version installed in step 2:
|
||||
|
||||
```bash
|
||||
sudo pip3 install --upgrade pip
|
||||
```
|
||||
|
||||
5. Install TensorFlow for the Python version as indicated in Step 2.
|
||||
|
||||
```bash
|
||||
/usr/bin/python[version] -m pip install --user tensorflow-rocm==[wheel-version] --upgrade
|
||||
```
|
||||
|
||||
For a valid wheel version for a ROCm release, refer to the instruction below:
|
||||
|
||||
```bash
|
||||
sudo apt install rocm-libs rccl
|
||||
```
|
||||
|
||||
6. Update `protobuf` to 3.19 or lower.
|
||||
|
||||
```bash
|
||||
/usr/bin/python3.7 -m pip install protobuf=3.19.0
|
||||
sudo pip3 install tensorflow
|
||||
```
|
||||
|
||||
7. Set the environment variable `PYTHONPATH`.
|
||||
|
||||
```bash
|
||||
export PYTHONPATH="./.local/lib/python[version]/site-packages:$PYTHONPATH" #Use same python version as in step 2
|
||||
```
|
||||
|
||||
8. Install libraries.
|
||||
|
||||
```bash
|
||||
sudo apt install rocm-libs rccl
|
||||
```
|
||||
|
||||
9. Test installation.
|
||||
|
||||
```bash
|
||||
python3 -c 'import tensorflow' 2> /dev/null && echo 'Success' || echo 'Failure'
|
||||
```
|
||||
|
||||
:::{note}
|
||||
For details on `tensorflow-rocm` wheels and ROCm version compatibility, see:
|
||||
[https://github.com/ROCmSoftwarePlatform/tensorflow-upstream/blob/develop-upstream/rocm_docs/tensorflow-rocm-release.md](https://github.com/ROCmSoftwarePlatform/tensorflow-upstream/blob/develop-upstream/rocm_docs/tensorflow-rocm-release.md)
|
||||
:::
|
||||
|
||||
### Test the TensorFlow Installation
|
||||
|
||||
To test the installation of TensorFlow, run the container image as specified in
|
||||
the previous section Installing TensorFlow. Ensure you have access to the Python
|
||||
shell in the Docker container.
|
||||
|
||||
```bash
|
||||
python3 -c 'import tensorflow' 2> /dev/null && echo ‘Success’ || echo ‘Failure’
|
||||
```
|
||||
|
||||
### Run a Basic TensorFlow Example
|
||||
|
||||
The TensorFlow examples repository provides basic examples that exercise the
|
||||
framework's functionality. The MNIST database is a collection of handwritten
|
||||
digits that may be used to train a Convolutional Neural Network for handwriting
|
||||
recognition.
|
||||
|
||||
Follow these steps:
|
||||
|
||||
1. Clone the TensorFlow example repository.
|
||||
|
||||
```bash
|
||||
cd ~
|
||||
git clone https://github.com/tensorflow/models.git
|
||||
```
|
||||
|
||||
2. Install the dependencies of the code, and run the code.
|
||||
|
||||
```bash
|
||||
#pip3 install requirement.txt
|
||||
#python mnist_tf.py
|
||||
```
|
||||
|
||||
## References
|
||||
|
||||
C. Szegedy, V. Vanhoucke, S. Ioffe, J. Shlens and Z. Wojna, "Rethinking the Inception Architecture for Computer Vision," CoRR, p. abs/1512.00567, 2015
|
||||
|
||||
PyTorch, \[Online\]. Available: [https://pytorch.org/vision/stable/index.html](https://pytorch.org/vision/stable/index.html)
|
||||
|
||||
PyTorch, \[Online\]. Available: [https://pytorch.org/hub/pytorch_vision_inception_v3/](https://pytorch.org/hub/pytorch_vision_inception_v3/)
|
||||
|
||||
Stanford, \[Online\]. Available: [http://cs231n.stanford.edu/](http://cs231n.stanford.edu/)
|
||||
|
||||
Wikipedia, \[Online\]. Available: [https://en.wikipedia.org/wiki/Cross_entropy](https://en.wikipedia.org/wiki/Cross_entropy)
|
||||
|
||||
AMD, "ROCm issues," \[Online\]. Available: [https://github.com/RadeonOpenCompute/ROCm/issues](https://github.com/RadeonOpenCompute/ROCm/issues)
|
||||
|
||||
PyTorch, \[Online image\]. [https://pytorch.org/assets/brand-guidelines/PyTorch-Brand-Guidelines.pdf](https://pytorch.org/assets/brand-guidelines/PyTorch-Brand-Guidelines.pdf)
|
||||
|
||||
TensorFlow, \[Online image\]. [https://www.tensorflow.org/extras/tensorflow_brand_guidelines.pdf](https://www.tensorflow.org/extras/tensorflow_brand_guidelines.pdf)
|
||||
|
||||
MAGMA, \[Online image\]. [https://bitbucket.org/icl/magma/src/master/docs/](https://bitbucket.org/icl/magma/src/master/docs/)
|
||||
|
||||
Advanced Micro Devices, Inc., \[Online\]. Available: [https://rocmsoftwareplatform.github.io/AMDMIGraphX/doc/html/](https://rocmsoftwareplatform.github.io/AMDMIGraphX/doc/html/)
|
||||
|
||||
Advanced Micro Devices, Inc., \[Online\]. Available: [https://github.com/ROCmSoftwarePlatform/AMDMIGraphX/wiki](https://github.com/ROCmSoftwarePlatform/AMDMIGraphX/wiki)
|
||||
|
||||
Docker, \[Online\]. [https://docs.docker.com/get-started/overview/](https://docs.docker.com/get-started/overview/)
|
||||
|
||||
Torchvision, \[Online\]. Available [https://pytorch.org/vision/master/index.html?highlight=torchvision#module-torchvision](https://pytorch.org/vision/master/index.html?highlight=torchvision#module-torchvision)
|
||||
31
docs/tutorials/install/windows/cli/index.md
Normal file
31
docs/tutorials/install/windows/cli/index.md
Normal file
@@ -0,0 +1,31 @@
|
||||
# Command Line Installation
|
||||
|
||||
::::{grid} 2 3 3 3
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Install
|
||||
:link: install
|
||||
:link-type: doc
|
||||
|
||||
How to install ROCm?
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Upgrade
|
||||
:link: upgrade
|
||||
:link-type: doc
|
||||
|
||||
Instructions for upgrading an existing ROCm installation.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Uninstall
|
||||
:link: uninstall
|
||||
:link-type: doc
|
||||
|
||||
Steps for removing ROCm packages and libraries.
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## See Also
|
||||
|
||||
- {doc}`../../../../about/release/windows_support`
|
||||
55
docs/tutorials/install/windows/cli/install.md
Normal file
55
docs/tutorials/install/windows/cli/install.md
Normal file
@@ -0,0 +1,55 @@
|
||||
# Installation Using the Command Line Interface
|
||||
|
||||
The steps to install the HIP SDK for Windows are described in this document.
|
||||
|
||||
## System Requirements
|
||||
|
||||
The HIP SDK is supported on Windows 10 and 11. The HIP SDK may be installed on a
|
||||
system without AMD GPUs to use the build toolchains. To run HIP applications, a
|
||||
compatible GPU is required. Please see the supported GPU guide for more details.
|
||||
|
||||
## HIP SDK Installation
|
||||
|
||||
The command line installer is the same executable which is used by the graphical
|
||||
front-end. Download the installer from the
|
||||
[HIP-SDK download page](https://www.amd.com/en/developer/rocm-hub/hip-sdk.html).
|
||||
The options supported by the command line interface are summarized in the following table.
|
||||
|
||||
```{table} HIP SDK Command Line Options
|
||||
:name: hip-sdk-cli-install
|
||||
| **Install Option** | **Description** |
|
||||
|:------------------:|:---------------:|
|
||||
| `-install` | Command used to install packages, both driver and applications. No output to the screen. |
|
||||
| `-install -boot` | Silent install with auto reboot. |
|
||||
| `-install -log <absolute path>` | Write install result code to the specified log file. The specified log file must be on a local machine. Double quotes are needed if there are spaces in the log file path. |
|
||||
| `-uninstall` | Command to uninstall all packages installed by this installer on the system. There is no option to specify which packages to uninstall. |
|
||||
| `-uninstall -boot` | Silent uninstall with auto reboot. |
|
||||
| `/?` or /help | Shows a brief description of all switch commands. |
|
||||
```
|
||||
|
||||
```{note}
|
||||
Unlike the graphical installer, the command line interface doesn't support
|
||||
selectively installing parts of the SDK bundle. It's all or nothing.
|
||||
```
|
||||
|
||||
### Launching the Installer From the Command Line
|
||||
|
||||
The installer is still a graphical application with a `WinMain` entry point, even
|
||||
when called on the command line. This means that the application lifetime is
|
||||
tied to a window, even on headless systems where that window may not be visible.
|
||||
To launch the installer from PowerShell that will block until the installer
|
||||
exits, one may use the following pattern:
|
||||
|
||||
```pwsh
|
||||
Start-Process $InstallerExecutable -ArgumentList $InstallerArgs -NoNewWindow -Wait
|
||||
```
|
||||
|
||||
```{important}
|
||||
Running the installer requires Administrator Privileges.
|
||||
```
|
||||
|
||||
For example, installing all components and
|
||||
|
||||
```pwsh
|
||||
Start-Process ~\Downloads\Setup.exe -ArgumentList '-install','-log',"${env:USERPROFILE}\installer_log.txt" -NoNewWindow -Wait
|
||||
```
|
||||
48
docs/tutorials/install/windows/cli/uninstall.md
Normal file
48
docs/tutorials/install/windows/cli/uninstall.md
Normal file
@@ -0,0 +1,48 @@
|
||||
# Uninstallation Using the Command Line Interface
|
||||
|
||||
The steps to uninstall the HIP SDK for Windows are described in this document.
|
||||
|
||||
## HIP SDK Uninstallation
|
||||
|
||||
The command line installer is the same executable which is used by the graphical
|
||||
front-end. The options supported by the command line interface are summarized in
|
||||
the following table.
|
||||
|
||||
```{table} HIP SDK Command Line Options
|
||||
:name: hip-sdk-cli-uninstall
|
||||
| **Install Option** | **Description** |
|
||||
|:------------------:|:---------------:|
|
||||
| `-install` | Command used to install packages, both driver and applications. No output to the screen. |
|
||||
| `-install -boot` | Silent install with auto reboot. |
|
||||
| `-install -log <absolute path>` | Write install result code to the specified log file. The specified log file must be on a local machine. Double quotes are needed if there are spaces in the log file path. |
|
||||
| `-uninstall` | Command to uninstall all packages installed by this installer on the system. There is no option to specify which packages to uninstall. |
|
||||
| `-uninstall -boot` | Silent uninstall with auto reboot. |
|
||||
| `/?` or /help | Shows a brief description of all switch commands. |
|
||||
```
|
||||
|
||||
```{note}
|
||||
Unlike the graphical installer, the command line interface doesn't support
|
||||
selectively installing parts of the SDK bundle. It's all or nothing.
|
||||
```
|
||||
|
||||
### Launching the Installer From the Command Line
|
||||
|
||||
The installer is still a graphical application with a `WinMain` entry point, even
|
||||
when called on the command line. This means that the application lifetime is
|
||||
tied to a window, even on headless systems where that window may not be visible.
|
||||
To launch the installer from PowerShell that will block until the installer
|
||||
exits, one may use the following pattern:
|
||||
|
||||
```pwsh
|
||||
Start-Process $InstallerExecutable -ArgumentList $InstallerArgs -NoNewWindow -Wait
|
||||
```
|
||||
|
||||
```{important}
|
||||
Running the installer requires Administrator Privileges.
|
||||
```
|
||||
|
||||
For example, uninstalling all components and
|
||||
|
||||
```pwsh
|
||||
Start-Process ~\Downloads\Setup.exe -ArgumentList '-uninstall' -NoNewWindow -Wait
|
||||
```
|
||||
14
docs/tutorials/install/windows/cli/upgrade.md
Normal file
14
docs/tutorials/install/windows/cli/upgrade.md
Normal file
@@ -0,0 +1,14 @@
|
||||
# Upgrading Using the Graphical Interface
|
||||
|
||||
The steps to uninstall the HIP SDK for Windows are described in this document.
|
||||
|
||||
## HIP SDK Upgrade
|
||||
|
||||
To upgrade an existing installation of the HIP SDK without preserving the
|
||||
previous version, first uninstall it, then install the new version following the
|
||||
instructions in {doc}`./uninstall` and
|
||||
{doc}`./install` using the old and new installers
|
||||
respectively.
|
||||
|
||||
To upgrade by installing both versions side-by-side, just run the installer of
|
||||
the newer version.
|
||||
31
docs/tutorials/install/windows/gui/index.md
Normal file
31
docs/tutorials/install/windows/gui/index.md
Normal file
@@ -0,0 +1,31 @@
|
||||
# Graphical Installation
|
||||
|
||||
::::{grid} 2 3 3 3
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Install
|
||||
:link: install
|
||||
:link-type: doc
|
||||
|
||||
How to install ROCm?
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Upgrade
|
||||
:link: upgrade
|
||||
:link-type: doc
|
||||
|
||||
Instructions for upgrading an existing ROCm installation.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Uninstall
|
||||
:link: uninstall
|
||||
:link-type: doc
|
||||
|
||||
Steps for removing ROCm packages and libraries.
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## See Also
|
||||
|
||||
- {doc}`../../../../about/release/windows_support`
|
||||
158
docs/tutorials/install/windows/gui/install.md
Normal file
158
docs/tutorials/install/windows/gui/install.md
Normal file
@@ -0,0 +1,158 @@
|
||||
# Installation Using the Graphical Interface
|
||||
|
||||
The steps to install the HIP SDK for Windows are described in this document.
|
||||
|
||||
## System Requirements
|
||||
|
||||
The HIP SDK is supported on Windows 10 and 11. The HIP SDK may be installed on a
|
||||
system without AMD GPUs to use the build toolchains. To run HIP applications, a
|
||||
compatible GPU is required. Please see the supported GPU guide for more details.
|
||||
|
||||
## HIP SDK Installation
|
||||
|
||||
### Download the installer
|
||||
|
||||
Download the installer from the
|
||||
[HIP-SDK download page](https://www.amd.com/en/developer/rocm-hub/hip-sdk.html).
|
||||
|
||||
### Launching the installer
|
||||
|
||||
To launch the AMD HIP SDK Installer, click the **Setup** icon shown in the following image.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/000-setup-icon.png
|
||||
:name: setup-icon-install
|
||||
:alt: Icon with AMD arrow logo and User Access Control Shield overlayed.
|
||||
Setup Icon
|
||||
```
|
||||
|
||||
The installer requires Administrator Privileges, so you may be greeted with a
|
||||
User Access Control (UAC) pop-up. Click Yes.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/001-uac-dark.png
|
||||
:name: uac-dark-install
|
||||
:class: only-dark
|
||||
:alt: User Access Control pop-up
|
||||
User Access Control pop-up
|
||||
```
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/001-uac-light.png
|
||||
:name: uac-light-install
|
||||
:class: only-light
|
||||
:alt: User Access Control pop-up
|
||||
User Access Control pop-up
|
||||
```
|
||||
|
||||
The installer executable will temporarily extract installer packages to `C:\AMD`
|
||||
which it will remove after installation completes. This extraction is signified
|
||||
by the "Initializing install" window in the following image.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/002-initializing.png
|
||||
:name: init-install
|
||||
:alt: Window with AMD arrow logo, futuristic background and progress counter.
|
||||
Installer initialization window
|
||||
```
|
||||
|
||||
The installer will then detect your system configuration to determine which installable components
|
||||
are applicable to your system.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/003-detecting-system-config.png
|
||||
:name: detect-sys-components
|
||||
:alt: Window with AMD arrow logo, futuristic background and activity indicator.
|
||||
Installer initialization window.
|
||||
```
|
||||
|
||||
### Customizing the install
|
||||
|
||||
When the installer launches, it displays a window that lets the user customize
|
||||
the installation. By default, all components are selected for installation.
|
||||
Refer to the following image for an instance when the Select All option
|
||||
is turned on.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/004-installer-window.png
|
||||
:name: installer-window
|
||||
:alt: Window with AMD arrow logo, futuristic background and activity indicator.
|
||||
Installer initialization window.
|
||||
```
|
||||
|
||||
#### HIP SDK Installer
|
||||
|
||||
The HIP SDK installation options are listed in the following table.
|
||||
|
||||
```{table} HIP SDK Components for Installation
|
||||
:name: hip-sdk-options
|
||||
| **HIP Components** | **Install Type** | **Additional Options** |
|
||||
|:------------------:|:----------------:|:----------------------:|
|
||||
| HIP SDK Core | 5.5.0 | Install location |
|
||||
| HIP Libraries | Full, Partial, None | Runtime, Development (Libs and headers) |
|
||||
| HIP Runtime Compiler | Full, Partial, None | Runtime, Development (Headers) |
|
||||
| HIP Ray Tracing | Full, Partial, None | Runtime, Development (Headers) |
|
||||
| Visual Studio Plugin | Full, Partial, None | Visual Studio 2017, 2019, 2022 Plugin |
|
||||
```
|
||||
|
||||
```{note}
|
||||
The Select/DeSelect All option only applies to the installation of HIP SDK
|
||||
components. To install the bundled AMD Display Driver, manually select the
|
||||
install type.
|
||||
```
|
||||
|
||||
```{tip}
|
||||
Should you only wish to install a few select components,
|
||||
DeSelecting All and then picking the individual components may be more
|
||||
convenient.
|
||||
```
|
||||
|
||||
#### AMD Display Driver
|
||||
|
||||
The HIP SDK installer bundles an AMD Radeon Software PRO 23.10 installer. The
|
||||
supported install options are summarized in the following table:
|
||||
|
||||
```{table} AMD Display Driver Install Options
|
||||
:name: display-driver-install-options
|
||||
| **Install Option** | **Description** |
|
||||
|:------------------:|:---------------:|
|
||||
| Install Location | Location on disk to store driver files. |
|
||||
| Install Type | The breadth of components to be installed. |
|
||||
| Factory Reset (Optional) | A Factory Reset will remove all prior versions of AMD HIP SDK and drivers. You will not be able to roll back to previously installed drivers. |
|
||||
```
|
||||
|
||||
```{table} AMD Display Driver Install Types
|
||||
:name: display-driver-install-types
|
||||
| **Install Type** | **Description** |
|
||||
|:----------------:|:---------------:|
|
||||
| Full Install | Provides all AMD Software features and controls for gaming, recording, streaming, and tweaking the performance on your graphics hardware. |
|
||||
| Minimal Install | Provides only the basic controls for AMD Software features and does not include advanced features such as performance tweaking or recording and capturing content. |
|
||||
| Driver Only | Provides no user interface for AMD Software features. |
|
||||
```
|
||||
|
||||
```{note}
|
||||
You must perform a system restart for a complete installation of the
|
||||
Display Driver.
|
||||
```
|
||||
|
||||
### Installing Components
|
||||
|
||||
Please wait for the installation to complete during as shown in the following image.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/012-install-progress.png
|
||||
:name: install-progress
|
||||
:alt: Window with AMD arrow logo, futuristic background and progress meter.
|
||||
Installation Progress
|
||||
```
|
||||
|
||||
### Installation Complete
|
||||
|
||||
Once the installation is complete, the installer window may prompt you for a
|
||||
system restart. Click **Restart** at the lower right corner, shown in the following image.
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/013-install-complete.png
|
||||
:name: install-complete
|
||||
:alt: Window with AMD arrow logo, futuristic background and completion notice.
|
||||
Installation Complete
|
||||
```
|
||||
|
||||
```{error}
|
||||
Should the installer terminate due to unexpcted circumstances, or the user
|
||||
forcibly terminates the installer, the temporary directory created under
|
||||
`C:\AMD` may be safely removed. Installed components will not depend on this
|
||||
folder (unless the user specifies `C:\AMD` as an install folder explicitly).
|
||||
```
|
||||
27
docs/tutorials/install/windows/gui/uninstall.md
Normal file
27
docs/tutorials/install/windows/gui/uninstall.md
Normal file
@@ -0,0 +1,27 @@
|
||||
# Uninstallation Using the Graphical Interface
|
||||
|
||||
The steps to uninstall the HIP SDK for Windows are described in this document.
|
||||
|
||||
## Uninstallation
|
||||
|
||||
All components, except visual studio plug-in should be uninstalled through
|
||||
control panel -> Add/Remove Program. For visual studio extension uninstallation,
|
||||
please refer to
|
||||
<https://github.com/ROCm-Developer-Tools/HIP-VS/blob/master/README.md>.
|
||||
Uninstallation of the HIP SDK components can be done through the Windows
|
||||
Settings app. Navigate to "Apps > Installed apps", click the "..." on the far
|
||||
right next to the component to uninstall, and click "Uninstall".
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/014-uninstall-dark.png
|
||||
:name: uninstall-dark
|
||||
:class: only-dark
|
||||
:alt: Installed apps section of the Setting app showing installed HIP SDK components.
|
||||
Removing the SDK via the Setting app
|
||||
```
|
||||
|
||||
```{figure} ../../../../data/tutorials/install/windows/014-uninstall-light.png
|
||||
:name: uninstall-light
|
||||
:class: only-light
|
||||
:alt: Installed apps section of the Setting app showing installed HIP SDK components.
|
||||
Removing the SDK via the Setting app
|
||||
```
|
||||
4
docs/tutorials/install/windows/gui/upgrade.md
Normal file
4
docs/tutorials/install/windows/gui/upgrade.md
Normal file
@@ -0,0 +1,4 @@
|
||||
# Upgrading Using the Graphical Interface
|
||||
|
||||
The steps to upgrade an existing HIP SDK installation for Windows are described
|
||||
in this document.
|
||||
65
docs/tutorials/install/windows/index.md
Normal file
65
docs/tutorials/install/windows/index.md
Normal file
@@ -0,0 +1,65 @@
|
||||
# Install ROCm (HIP SDK) on Windows
|
||||
|
||||
Start with {doc}`../../quick_start/windows` or follow the detailed
|
||||
instructions below.
|
||||
|
||||
## Prepare to Install
|
||||
|
||||
::::{grid} 1 1 2 2
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Prerequisites
|
||||
:link: prerequisites
|
||||
:link-type: doc
|
||||
|
||||
The prerequisites page lists the required steps to verify that the system
|
||||
supports ROCm.
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## Choose your install method
|
||||
|
||||
::::{grid} 1 1 2 2
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} Graphical Installation
|
||||
:link: gui/index
|
||||
:link-type: doc
|
||||
|
||||
Use the graphical front-end of the installer.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Command Line Installation
|
||||
:link: cli/index
|
||||
:link-type: doc
|
||||
|
||||
Use the command line front-end of the installer.
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## Post Installation
|
||||
|
||||
::::{grid} 1 1 2 2
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} ROCm-Examples
|
||||
:link: https://github.com/amd/rocm-examples
|
||||
:link-type: url
|
||||
|
||||
Learn how to use ROCm with descriptive examples for novice to intermediate users.
|
||||
:::
|
||||
|
||||
:::{grid-item-card} Windows App Deployment Guidelines
|
||||
:link: ../../../conceptual/windows-app-deployment-guidelines
|
||||
:link-type: doc
|
||||
|
||||
Discusses strategies on how to bundle HIP libraries with an end user application.
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## See Also
|
||||
|
||||
- {doc}`../../../about/release/windows_support`
|
||||
74
docs/tutorials/install/windows/prerequisites.md
Normal file
74
docs/tutorials/install/windows/prerequisites.md
Normal file
@@ -0,0 +1,74 @@
|
||||
# Installation Prerequisites (Windows)
|
||||
|
||||
You must perform the following steps before installing ROCm and check if the
|
||||
system meets all the requirements to proceed with the installation.
|
||||
|
||||
## Confirm the System Is Supported
|
||||
|
||||
The ROCm installation is supported only on specific host architectures, Windows
|
||||
Editions and update versions.
|
||||
|
||||
### Check the Windows Editions and Update Version on Your System
|
||||
|
||||
This section discusses obtaining information about the host architecture,
|
||||
Windows Edition and update version.
|
||||
|
||||
#### Command Line Check
|
||||
|
||||
Verify the Windows Edition using the following steps:
|
||||
|
||||
1. To obtain the Linux distribution information, type the following command on
|
||||
your system from a PowerShell Command Line Interface (CLI):
|
||||
|
||||
```pwsh
|
||||
Get-ComputerInfo | Format-Table CsSystemType,OSName,OSDisplayVersion
|
||||
```
|
||||
|
||||
2. Confirm that the obtained information matches with those listed in
|
||||
{ref}`supported_skus`.
|
||||
|
||||
**Example:** Running the command above on a Windows system may result in the
|
||||
following output:
|
||||
|
||||
```output
|
||||
CsSystemType OsName OSDisplayVersion
|
||||
------------ ------ ----------------
|
||||
x64-based PC Microsoft Windows 11 Pro 22H2
|
||||
```
|
||||
|
||||
#### Graphical Check
|
||||
|
||||
1. Open the Setting app.
|
||||
|
||||
```{figure} ../../../data/tutorials/install/windows/000-settings-dark.png
|
||||
:name: settings-dark
|
||||
:class: only-dark
|
||||
:alt: Gear icon of the Windows Settings app
|
||||
Windows Settings app icon
|
||||
```
|
||||
|
||||
```{figure} ../../../data/tutorials/install/windows/000-settings-light.png
|
||||
:name: settings-light
|
||||
:class: only-light
|
||||
:alt: Gear icon of the Windows Settings app
|
||||
Windows Settings app icon
|
||||
```
|
||||
|
||||
2. Navigate to **System > About**.
|
||||
|
||||
```{figure} ../../../data/tutorials/install/windows/001-about-dark.png
|
||||
:name: about-dark
|
||||
:class: only-dark
|
||||
:alt: Settings app panel showing Device and OS information
|
||||
Settings > About page
|
||||
```
|
||||
|
||||
```{figure} ../../../data/tutorials/install/windows/001-about-light.png
|
||||
:name: about-light
|
||||
:class: only-light
|
||||
:alt: Settings app panel showing Device and OS information
|
||||
Settings > About page
|
||||
```
|
||||
|
||||
3. Confirm that the obtained information matches with those listed in
|
||||
{ref}`supported_skus`.
|
||||
16
docs/tutorials/quick_start/index.md
Normal file
16
docs/tutorials/quick_start/index.md
Normal file
@@ -0,0 +1,16 @@
|
||||
# ROCm quick-start guides
|
||||
|
||||
Quick-start guides are designed to get you up and running quickly. They do not go into detail or help
|
||||
with troubleshooting. For more in-depth installation guides, see [Installing ROCm](../install/index.md).
|
||||
|
||||
:::::{grid} 1 1 2 2
|
||||
:gutter: 1
|
||||
|
||||
:::{grid-item-card} [Linux quick-start guide](linux.md)
|
||||
:::
|
||||
|
||||
:::{grid-item-card} [Windows quick-start guide](windows.md)
|
||||
:link-type: url
|
||||
:::
|
||||
|
||||
:::::
|
||||
369
docs/tutorials/quick_start/linux.md
Normal file
369
docs/tutorials/quick_start/linux.md
Normal file
@@ -0,0 +1,369 @@
|
||||
# Quick Start (Linux)
|
||||
|
||||
## Add Repositories
|
||||
|
||||
::::::{tab-set}
|
||||
:::::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
::::{rubric} 1. Download and convert the package signing key
|
||||
::::
|
||||
|
||||
```shell
|
||||
# Make the directory if it doesn't exist yet.
|
||||
# This location is recommended by the distribution maintainers.
|
||||
sudo mkdir --parents --mode=0755 /etc/apt/keyrings
|
||||
# Download the key, convert the signing-key to a full
|
||||
# keyring required by apt and store in the keyring directory
|
||||
wget https://repo.radeon.com/rocm/rocm.gpg.key -O - | \
|
||||
gpg --dearmor | sudo tee /etc/apt/keyrings/rocm.gpg > /dev/null
|
||||
```
|
||||
|
||||
::::{rubric} 2. Add the repositories
|
||||
::::
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu 20.04
|
||||
:sync: ubuntu-20.04
|
||||
|
||||
```shell
|
||||
# Kernel driver repository for focal
|
||||
sudo tee /etc/apt/sources.list.d/amdgpu.list <<'EOF'
|
||||
deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/amdgpu/latest/ubuntu focal main
|
||||
EOF
|
||||
# ROCm repository for focal
|
||||
sudo tee /etc/apt/sources.list.d/rocm.list <<'EOF'
|
||||
deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/rocm/apt/debian focal main
|
||||
EOF
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} Ubuntu 22.04
|
||||
:sync: ubuntu-22.04
|
||||
|
||||
```shell
|
||||
# Kernel driver repository for jammy
|
||||
sudo tee /etc/apt/sources.list.d/amdgpu.list <<'EOF'
|
||||
deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/amdgpu/latest/ubuntu jammy main
|
||||
EOF
|
||||
# ROCm repository for jammy
|
||||
sudo tee /etc/apt/sources.list.d/rocm.list <<'EOF'
|
||||
deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/rocm/apt/debian jammy main
|
||||
EOF
|
||||
# Prefer packages from the rocm repository over system packages
|
||||
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' | sudo tee /etc/apt/preferences.d/rocm-pin-600
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
::::{rubric} 3. Update the list of packages
|
||||
::::
|
||||
|
||||
```shell
|
||||
sudo apt update
|
||||
```
|
||||
|
||||
:::::
|
||||
|
||||
:::::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
::::{rubric} 1. Add the repositories
|
||||
::::
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} RHEL 8.6
|
||||
:sync: RHEL-8.6
|
||||
|
||||
```shell
|
||||
# Add the amdgpu module repository for RHEL 8.6
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<'EOF'
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/latest/rhel/8.6/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
# Add the rocm repository for RHEL 8
|
||||
sudo tee /etc/yum.repos.d/rocm.repo <<'EOF'
|
||||
[rocm]
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/rhel8/latest/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} RHEL 8.7
|
||||
:sync: RHEL-8.7
|
||||
|
||||
```shell
|
||||
# Add the amdgpu module repository for RHEL 8.7
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<'EOF'
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/latest/rhel/8.7/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
# Add the rocm repository for RHEL 8
|
||||
sudo tee /etc/yum.repos.d/rocm.repo <<'EOF'
|
||||
[rocm]
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/rhel8/latest/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} RHEL 8.8
|
||||
:sync: RHEL-8.8
|
||||
|
||||
```shell
|
||||
# Add the amdgpu module repository for RHEL 8.8
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<'EOF'
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/latest/rhel/8.8/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
# Add the rocm repository for RHEL 8
|
||||
sudo tee /etc/yum.repos.d/rocm.repo <<'EOF'
|
||||
[rocm]
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/rhel8/latest/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} RHEL 9.1
|
||||
:sync: RHEL-9.1
|
||||
|
||||
```shell
|
||||
# Add the amdgpu module repository for RHEL 9.1
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<'EOF'
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/latest/rhel/9.1/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
# Add the rocm repository for RHEL 9
|
||||
sudo tee /etc/yum.repos.d/rocm.repo <<'EOF'
|
||||
[rocm]
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/rhel9/latest/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} RHEL 9.2
|
||||
:sync: RHEL-9.2
|
||||
|
||||
```shell
|
||||
# Add the amdgpu module repository for RHEL 9.2
|
||||
sudo tee /etc/yum.repos.d/amdgpu.repo <<'EOF'
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/latest/rhel/9.2/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
# Add the rocm repository for RHEL 9
|
||||
sudo tee /etc/yum.repos.d/rocm.repo <<'EOF'
|
||||
[rocm]
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/rhel9/latest/main
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
::::{rubric} 2. Clean cached files from enabled repositories
|
||||
::::
|
||||
|
||||
```shell
|
||||
sudo yum clean all
|
||||
```
|
||||
|
||||
:::::
|
||||
|
||||
:::::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
::::{rubric} 1. Add the repositories
|
||||
::::
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} SLES 15.4
|
||||
:sync: SLES-15.4
|
||||
|
||||
```shell
|
||||
|
||||
# Add the amdgpu module repository for SLES 15.4
|
||||
sudo tee /etc/zypp/repos.d/amdgpu.repo <<'EOF'
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/latest/sle/15.4/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
# Add the rocm repository for SLES
|
||||
sudo tee /etc/zypp/repos.d/rocm.repo <<'EOF'
|
||||
[rocm]
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/zyp/zypper
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
```
|
||||
|
||||
:::
|
||||
:::{tab-item} SLES 15.5
|
||||
:sync: SLES-15.5
|
||||
|
||||
```shell
|
||||
|
||||
# Add the amdgpu module repository for SLES 15.5
|
||||
sudo tee /etc/zypp/repos.d/amdgpu.repo <<'EOF'
|
||||
[amdgpu]
|
||||
name=amdgpu
|
||||
baseurl=https://repo.radeon.com/amdgpu/latest/sle/15.5/main/x86_64
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
# Add the rocm repository for SLES
|
||||
sudo tee /etc/zypp/repos.d/rocm.repo <<'EOF'
|
||||
[rocm]
|
||||
name=rocm
|
||||
baseurl=https://repo.radeon.com/rocm/zyp/zypper
|
||||
enabled=1
|
||||
priority=50
|
||||
gpgcheck=1
|
||||
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key
|
||||
EOF
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
::::{rubric} 2. Update the new repository
|
||||
::::
|
||||
|
||||
```shell
|
||||
sudo zypper ref
|
||||
```
|
||||
|
||||
:::::
|
||||
::::::
|
||||
|
||||
## Install Drivers
|
||||
|
||||
Install the `amdgpu-dkms` kernel module, aka driver, on your system.
|
||||
|
||||
::::{tab-set}
|
||||
|
||||
:::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
```shell
|
||||
sudo apt install amdgpu-dkms
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
```shell
|
||||
sudo yum install amdgpu-dkms
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
```shell
|
||||
sudo zypper install amdgpu-dkms
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
::::
|
||||
|
||||
## Install ROCm Runtimes
|
||||
|
||||
Install the `rocm-hip-libraries` meta-package. This contains dependencies for most
|
||||
common ROCm applications.
|
||||
|
||||
::::{tab-set}
|
||||
:::{tab-item} Ubuntu
|
||||
:sync: ubuntu
|
||||
|
||||
```console shell
|
||||
sudo apt install rocm-hip-libraries
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} Red Hat Enterprise Linux
|
||||
:sync: RHEL
|
||||
|
||||
```console shell
|
||||
sudo yum install rocm-hip-libraries
|
||||
```
|
||||
|
||||
:::
|
||||
|
||||
:::{tab-item} SUSE Linux Enterprise Server
|
||||
:sync: SLES
|
||||
|
||||
```console shell
|
||||
sudo zypper install rocm-hip-libraries
|
||||
```
|
||||
|
||||
:::
|
||||
::::
|
||||
|
||||
## Reboot the system
|
||||
|
||||
Loading the new driver requires a reboot of the system.
|
||||
|
||||
```shell
|
||||
sudo reboot
|
||||
```
|
||||
182
docs/tutorials/quick_start/windows.md
Normal file
182
docs/tutorials/quick_start/windows.md
Normal file
@@ -0,0 +1,182 @@
|
||||
# Quick Start (Windows)
|
||||
|
||||
The steps to install the HIP SDK for Windows are described in this document.
|
||||
|
||||
## System Requirements
|
||||
|
||||
The HIP SDK is supported on Windows 10 and 11. The HIP SDK may be installed on a
|
||||
system without AMD GPUs to use the build toolchains. To run HIP applications, a
|
||||
compatible GPU is required. Please see the supported GPU guide for more details.
|
||||
|
||||
## HIP SDK Installation
|
||||
|
||||
### Download the installer
|
||||
|
||||
Download the installer from the
|
||||
[HIP-SDK download page](https://www.amd.com/en/developer/rocm-hub/hip-sdk.html).
|
||||
|
||||
### Launching the installer
|
||||
|
||||
To launch the AMD HIP SDK Installer, click the **Setup** icon shown in the following image.
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/000-setup-icon.png
|
||||
:name: setup-icon
|
||||
:alt: Icon with AMD arrow logo and User Access Control Shield overlayed.
|
||||
Setup Icon
|
||||
```
|
||||
|
||||
The installer requires Administrator Privileges, so you may be greeted with a
|
||||
User Access Control (UAC) pop-up. Click Yes.
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/001-uac-dark.png
|
||||
:name: uac-dark
|
||||
:class: only-dark
|
||||
:alt: User Access Control pop-up
|
||||
User Access Control pop-up
|
||||
```
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/001-uac-light.png
|
||||
:name: uac-light
|
||||
:class: only-light
|
||||
:alt: User Access Control pop-up
|
||||
User Access Control pop-up
|
||||
```
|
||||
|
||||
The installer executable will temporarily extract installer packages to `C:\AMD`
|
||||
which it will remove after installation completes. This extraction is signified
|
||||
by the "Initializing install" window in the following image.
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/002-initializing.png
|
||||
:name: init-win-install
|
||||
:alt: Window with AMD arrow logo, futuristic background and progress counter.
|
||||
Installer initialization window
|
||||
```
|
||||
|
||||
The installer will then detect your system configuration to determine which installable components
|
||||
are applicable to your system.
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/003-detecting-system-config.png
|
||||
:name: detecting-system-components
|
||||
:alt: Window with AMD arrow logo, futuristic background and activity indicator.
|
||||
Installer initialization window.
|
||||
```
|
||||
|
||||
### Customizing the install
|
||||
|
||||
When the installer launches, it displays a window that lets the user customize
|
||||
the installation. By default, all components are selected for installation.
|
||||
Refer to the following image for an instance when the Select All option
|
||||
is turned on.
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/004-installer-window.png
|
||||
:name: install-window
|
||||
:alt: Window with AMD arrow logo, futuristic background and activity indicator.
|
||||
Installer initialization window.
|
||||
```
|
||||
|
||||
#### HIP SDK Installer
|
||||
|
||||
The HIP SDK installation options are listed in the following table.
|
||||
|
||||
```{table} HIP SDK Components for Installation
|
||||
:name: hip-sdk-options-win
|
||||
| **HIP Components** | **Install Type** | **Additional Options** |
|
||||
|:------------------:|:----------------:|:----------------------:|
|
||||
| HIP SDK Core | 5.5.0 | Install location |
|
||||
| HIP Libraries | Full, Partial, None | Runtime, Development (Libs and headers) |
|
||||
| HIP Runtime Compiler | Full, Partial, None | Runtime, Development (Headers) |
|
||||
| HIP Ray Tracing | Full, Partial, None | Runtime, Development (Headers) |
|
||||
| Visual Studio Plugin | Full, Partial, None | Visual Studio 2017, 2019, 2022 Plugin |
|
||||
```
|
||||
|
||||
```{note}
|
||||
The Select/DeSelect All option only applies to the installation of HIP SDK
|
||||
components. To install the bundled AMD Display Driver, manually select the
|
||||
install type.
|
||||
```
|
||||
|
||||
```{tip}
|
||||
Should you only wish to install a few select components,
|
||||
DeSelecting All and then picking the individual components may be more
|
||||
convenient.
|
||||
```
|
||||
|
||||
#### AMD Display Driver
|
||||
|
||||
The HIP SDK installer bundles an AMD Radeon Software PRO 23.10 installer. The
|
||||
supported install options are summarized in the following table:
|
||||
|
||||
```{table} AMD Display Driver Install Options
|
||||
:name: display-driver-install-win
|
||||
| **Install Option** | **Description** |
|
||||
|:------------------:|:---------------:|
|
||||
| Install Location | Location on disk to store driver files. |
|
||||
| Install Type | The breadth of components to be installed. |
|
||||
| Factory Reset (Optional) | A Factory Reset will remove all prior versions of AMD HIP SDK and drivers. You will not be able to roll back to previously installed drivers. |
|
||||
```
|
||||
|
||||
```{table} AMD Display Driver Install Types
|
||||
:name: display-driver-win-types
|
||||
| **Install Type** | **Description** |
|
||||
|:----------------:|:---------------:|
|
||||
| Full Install | Provides all AMD Software features and controls for gaming, recording, streaming, and tweaking the performance on your graphics hardware. |
|
||||
| Minimal Install | Provides only the basic controls for AMD Software features and does not include advanced features such as performance tweaking or recording and capturing content. |
|
||||
| Driver Only | Provides no user interface for AMD Software features. |
|
||||
```
|
||||
|
||||
```{note}
|
||||
You must perform a system restart for a complete installation of the
|
||||
Display Driver.
|
||||
```
|
||||
|
||||
### Installing Components
|
||||
|
||||
Please wait for the installation to complete during as shown in the following image.
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/012-install-progress.png
|
||||
:name: install-progress-win
|
||||
:alt: Window with AMD arrow logo, futuristic background and progress meter.
|
||||
Installation Progress
|
||||
```
|
||||
|
||||
### Installation Complete
|
||||
|
||||
Once the installation is complete, the installer window may prompt you for a
|
||||
system restart. Click **Restart** at the lower right corner, shown in the following image.
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/013-install-complete.png
|
||||
:name: install-complete-win
|
||||
:alt: Window with AMD arrow logo, futuristic background and completion notice.
|
||||
Installation Complete
|
||||
```
|
||||
|
||||
```{error}
|
||||
Should the installer terminate due to unexpcted circumstances, or the user
|
||||
forcibly terminates the installer, the temporary directory created under
|
||||
`C:\AMD` may be safely removed. Installed components will not depend on this
|
||||
folder (unless the user specifies `C:\AMD` as an install folder explicitly).
|
||||
```
|
||||
|
||||
## Uninstallation
|
||||
|
||||
All components, except visual studio plug-in should be uninstalled through
|
||||
control panel -> Add/Remove Program. For visual studio extension uninstallation,
|
||||
please refer to
|
||||
<https://github.com/ROCm-Developer-Tools/HIP-VS/blob/master/README.md>.
|
||||
Uninstallation of the HIP SDK components can be done through the Windows
|
||||
Settings app. Navigate to "Apps > Installed apps", click the "..." on the far
|
||||
right next to the component to uninstall, and click "Uninstall".
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/014-uninstall-dark.png
|
||||
:name: uninstall-dark-win
|
||||
:class: only-dark
|
||||
:alt: Installed apps section of the Setting app showing installed HIP SDK components.
|
||||
Removing the SDK via the Setting app
|
||||
```
|
||||
|
||||
```{figure} ../../data/tutorials/install/windows/014-uninstall-light.png
|
||||
:name: uninstall-light-win
|
||||
:class: only-light
|
||||
:alt: Installed apps section of the Setting app showing installed HIP SDK components.
|
||||
Removing the SDK via the Setting app
|
||||
```
|
||||
Reference in New Issue
Block a user