mike23415 commited on
Commit
ae1011b
·
verified ·
1 Parent(s): c54282a

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +3 -0
Dockerfile CHANGED
@@ -28,9 +28,12 @@ ENV PYTHONUNBUFFERED=1
28
  ENV TRANSFORMERS_NO_ADVISORY_WARNINGS=1
29
  ENV HF_HUB_DISABLE_PROGRESS_BARS=1
30
  ENV HF_HUB_DISABLE_TELEMETRY=1
 
 
31
 
32
  # Expose the port the app runs on
33
  EXPOSE 7860
 
34
 
35
  # Command to run the application
36
  CMD ["python", "app.py"]
 
28
  ENV TRANSFORMERS_NO_ADVISORY_WARNINGS=1
29
  ENV HF_HUB_DISABLE_PROGRESS_BARS=1
30
  ENV HF_HUB_DISABLE_TELEMETRY=1
31
+ # Add environment variable to enable wider GPU memory compatibility
32
+ ENV PYTORCH_CUDA_ALLOC_CONF=max_split_size_mb:128
33
 
34
  # Expose the port the app runs on
35
  EXPOSE 7860
36
+ EXPOSE 5000 # Also expose the Flask API port
37
 
38
  # Command to run the application
39
  CMD ["python", "app.py"]