Pierre Chapuis commited on
Commit
4ec1154
1 Parent(s): b0f5547

support heic (if browser supports it)

Browse files
Files changed (4) hide show
  1. pyproject.toml +1 -0
  2. requirements.lock +3 -0
  3. requirements.txt +1 -0
  4. src/app.py +3 -0
pyproject.toml CHANGED
@@ -12,6 +12,7 @@ dependencies = [
12
  "httpx>=0.27.0",
13
  "pillow>=10.4.0",
14
  "gradio-imageslider>=0.0.20",
 
15
  ]
16
  readme = "README.md"
17
  requires-python = ">= 3.12, <3.13"
 
12
  "httpx>=0.27.0",
13
  "pillow>=10.4.0",
14
  "gradio-imageslider>=0.0.20",
15
+ "pillow-heif>=0.18.0",
16
  ]
17
  readme = "README.md"
18
  requires-python = ">= 3.12, <3.13"
requirements.lock CHANGED
@@ -107,6 +107,9 @@ pillow==10.4.0
107
  # via gradio
108
  # via gradio-imageslider
109
  # via matplotlib
 
 
 
110
  pydantic==2.8.2
111
  # via fastapi
112
  # via gradio
 
107
  # via gradio
108
  # via gradio-imageslider
109
  # via matplotlib
110
+ # via pillow-heif
111
+ pillow-heif==0.18.0
112
+ # via eraser
113
  pydantic==2.8.2
114
  # via fastapi
115
  # via gradio
requirements.txt CHANGED
@@ -3,3 +3,4 @@ gradio_imageslider>=0.0.20
3
  environs>=11.0.0
4
  httpx>=0.27.0
5
  pillow>=10.4.0
 
 
3
  environs>=11.0.0
4
  httpx>=0.27.0
5
  pillow>=10.4.0
6
+ pillow-heif>=0.18.0
src/app.py CHANGED
@@ -7,6 +7,9 @@ from environs import Env
7
  from gradio_image_annotation import image_annotator
8
  from gradio_imageslider import ImageSlider
9
  from PIL import Image
 
 
 
10
 
11
  env = Env()
12
  env.read_env()
 
7
  from gradio_image_annotation import image_annotator
8
  from gradio_imageslider import ImageSlider
9
  from PIL import Image
10
+ from pillow_heif import register_heif_opener
11
+
12
+ register_heif_opener()
13
 
14
  env = Env()
15
  env.read_env()