# AMD scales DINOv2 histopathology pretraining on Instinct MI355X GPUs

> **Key takeaway:** Bayer's DINOv2 vision model recipe achieves high-throughput histopathology pretraining on AMD Instinct MI355X hardware using ROCm 7.2.2 and custom xformers builds.

**Published:** 2026-12-03T22:03:19.841566+00:00 
**Source:** AMD ROCm Official Blog 
**Category:** ai-local-edge 
**Canonical URL:** https://fosswire.org/news/amd-scales-dinov2-histopathology-pretraining-on-instinct-mi3 

## Summary
AMD has demonstrated the ability to scale DINOv2 self-supervised pretraining for computational pathology using the Instinct MI355X GPU architecture. By utilizing a specialized fork of the DINOv2 model, researchers can process millions of image patches from whole-slide imaging (WSI) data to create general-purpose visual representations for tissue classification and segmentation.

The implementation relies on the ROCm 7.2.2 stack and PyTorch 2.10.0, specifically optimized for the gfx950 architecture. To ensure compatibility with DINOv2's memory-efficient attention mechanisms, the workflow includes building a custom xformers wheel from source, allowing the training recipe to run on MI355X nodes with no changes to the original training code.

## Technical implementation on gfx950 architecture
- **Software Stack:** The environment utilizes the official rocm/pytorch Docker image based on Ubuntu 24.04, running ROCm 7.2.2 and PyTorch 2.10.0.
- **Custom xformers Integration:** Because pre-built wheels for the gfx950 architecture were unavailable on the PyTorch ROCm index, a custom xformers build is required using `PYTORCH_ROCM_ARCH=gfx950` and `USE_ROCM=1` to enable Composable Kernel dispatch.
- **Hardware Scaling:** Benchmarks were conducted on eight-GPU MI355X nodes, requiring a specific CPU allocation of 24 cores per GPU to prevent throughput instability and GPU underutilization.
- **Model Configuration:** The study focused on the ViT-L/14 Vision Transformer architecture, employing Fully Sharded Data Parallel (FSDP) training paths for multi-GPU scaling.

## Why it matters
This development proves that high-performance vision foundation models can be ported to AMD Instinct hardware with minimal code modification, providing a viable alternative to CUDA-centric workflows in medical AI. It offers a concrete blueprint for developers to optimize complex attention-based models like DINOv2 for the latest ROCm-supported hardware architectures.