Spaces:
Runtime error
Runtime error
Update utility/utils.py
Browse files- utility/utils.py +2 -4
utility/utils.py
CHANGED
|
@@ -24,10 +24,8 @@ logging.basicConfig(
|
|
| 24 |
os.environ['PADDLEOCR_HOME'] = '/tmp/.paddleocr'
|
| 25 |
|
| 26 |
RESULT_FOLDER = 'static/results/'
|
| 27 |
-
os.
|
| 28 |
-
|
| 29 |
-
if not os.path.exists(app.config['RESULT_FOLDER']):
|
| 30 |
-
os.makedirs(app.config['RESULT_FOLDER'])
|
| 31 |
|
| 32 |
# Check if PaddleOCR home directory is writable
|
| 33 |
if not os.path.exists('/tmp/.paddleocr'):
|
|
|
|
| 24 |
os.environ['PADDLEOCR_HOME'] = '/tmp/.paddleocr'
|
| 25 |
|
| 26 |
RESULT_FOLDER = 'static/results/'
|
| 27 |
+
if not os.path.exists('/tmp/.paddleocr'):
|
| 28 |
+
os.makedirs(RESULT_FOLDER, exist_ok=True)
|
|
|
|
|
|
|
| 29 |
|
| 30 |
# Check if PaddleOCR home directory is writable
|
| 31 |
if not os.path.exists('/tmp/.paddleocr'):
|