I want to use the ydf package in a docker image, but every time I try to build Docker Image of Python with ydf package I get this error:
1.699 ERROR: Could not find a version that satisfies the requirement ydf (from versions: 0.0.0)
1.700 ERROR: No matching distribution found for ydf
But I use compatible version of Python, because YDF is available on Python 3.8, 3.9, 3.10, 3.11 and 3.12, on Windows x86-64 Linux x86-64, and macOS ARM64.(from text
For more context I'm on Mac M3 and when I install ydf on Python 3.11 locally, that's work and I can use it.
Here is my Dockerfile:
FROM python:3.11.0
WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
EXPOSE 8000
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]
And here is my requirements.txt :
fastapi
uvicorn
pandas
ydf
I have already tried lot of solutions:
Install ydf directly on the Dockerfile
RUN pip install --dry-run ydfInstall ydf directly on the Dockerfile from file:
RUN pip install --no-cache-dir ydf-0.10.0-cp312-cp312-macosx_12_0_arm64.whlI also followed the official ydf documentation to dockerize a model: text And I have the same error when I try to build image.
I have tried with lot of python official image (3.9-slim, 3.10 ...)
Have you already solve this problem, or do you have any solutions to solve it ? Thank's in advance

--platform=linux/amd64argument on the Python image on the Dockerfile. But if I use,--platform=linux/arm64That's doesn't work, do you how I can build image of python on Mac ARM64 with Docker ?