Skip to content

Commit 935affb

Browse files
authored
[Migrphax] Fix docker file (#26737)
Fix issue #26692 by upgrading base image.
1 parent 790018d commit 935affb

File tree

2 files changed

+5
-10
lines changed

2 files changed

+5
-10
lines changed

dockerfiles/Dockerfile.migraphx

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,17 @@
55
# Dockerfile to run ONNXRuntime with MIGraphX integration
66
#--------------------------------------------------------------------------
77

8-
FROM rocm/pytorch:rocm6.2.3_ubuntu22.04_py3.10_pytorch_release_2.3.0
8+
FROM rocm/pytorch:rocm7.1_ubuntu24.04_py3.12_pytorch_release_2.9.1
99

10-
ARG ONNXRUNTIME_REPO=https://github.com/Microsoft/onnxruntime
10+
ARG ONNXRUNTIME_REPO=https://github.com/microsoft/onnxruntime
1111
ARG ONNXRUNTIME_BRANCH=main
1212

13-
ENV PATH=/code/cmake-3.27.3-linux-x86_64/bin:${PATH}
14-
15-
RUN apt-get update &&\
16-
apt-get install -y migraphx
17-
1813
WORKDIR /code
1914

2015
# Prepare onnxruntime repository & build onnxruntime
2116
RUN git clone --single-branch --branch ${ONNXRUNTIME_BRANCH} --recursive ${ONNXRUNTIME_REPO} onnxruntime &&\
2217
/bin/sh onnxruntime/dockerfiles/scripts/install_common_deps.sh &&\
2318
cd onnxruntime && pip install --upgrade pip &&\
24-
/bin/sh ./build.sh --allow_running_as_root --cmake_extra_defines ONNXRUNTIME_VERSION=`cat ./VERSION_NUMBER` --config Release --parallel \
25-
--skip_tests --build_wheel --use_migraphx &&\
19+
/bin/sh ./build.sh --allow_running_as_root --cmake_extra_defines ONNXRUNTIME_VERSION=`cat ./VERSION_NUMBER` \
20+
--config Release --parallel --skip_tests --build_wheel --use_migraphx &&\
2621
pip install /code/onnxruntime/build/Linux/Release/dist/*.whl

onnxruntime/test/providers/migraphx/migraphx_basic_test.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,7 @@ TEST(MIGraphXExecutionProviderTest, canEvalArgument) {
188188
ASSERT_EQ(canEvalNodeArgument(gv, node2, {1}, input_nodes), true);
189189
}
190190

191+
#if defined(WIN32)
191192
static bool SessionHasEp(Ort::Session& session, const char* ep_name) {
192193
// Access the underlying InferenceSession.
193194
const OrtSession* ort_session = session;
@@ -203,7 +204,6 @@ static bool SessionHasEp(Ort::Session& session, const char* ep_name) {
203204
return has_ep;
204205
}
205206

206-
#if defined(WIN32)
207207
// Tests autoEP feature to automatically select an EP that supports the GPU.
208208
// Currently only works on Windows.
209209
TEST(MIGraphXExecutionProviderTest, AutoEp_PreferGpu) {

0 commit comments

Comments
 (0)