Download Dockerfile from Akash8150/DeepClean-CNN-Autoencoder-for-Image-Denoising: direct link, hf CLI and curl.
- Browser
- Download file 816 Bytes
-
https://huggingface.co/spaces/Akash8150/DeepClean-CNN-Autoencoder-for-Image-Denoising/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/Akash8150/DeepClean-CNN-Autoencoder-for-Image-Denoising/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/Akash8150/DeepClean-CNN-Autoencoder-for-Image-Denoising/resolve/main/Dockerfile
816 Bytes
| FROM python:3.10-slim | |
| # Suppress TensorFlow oneDNN warnings | |
| ENV TF_ENABLE_ONEDNN_OPTS=0 | |
| ENV TF_CPP_MIN_LOG_LEVEL=2 | |
| # Set working directory | |
| WORKDIR /app | |
| # Install system dependencies | |
| RUN apt-get update && apt-get install -y \ | |
| libglib2.0-0 \ | |
| libsm6 \ | |
| libxext6 \ | |
| libxrender-dev \ | |
| libgomp1 \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Copy requirements first for better Docker layer caching | |
| COPY requirements-hf.txt . | |
| # Install Python dependencies | |
| RUN pip install --no-cache-dir -r requirements-hf.txt | |
| # Copy application files | |
| COPY app.py . | |
| COPY model_info.json . | |
| COPY best_autoencoder_model.h5 . | |
| COPY src/ ./src/ | |
| COPY static/ ./static/ | |
| COPY templates/ ./templates/ | |
| COPY test_images/ ./test_images/ | |
| # Hugging Face Spaces runs on port 7860 | |
| EXPOSE 7860 | |
| # Run the Flask app | |
| CMD ["python", "app.py"] |