Adding model download
Browse files
app.py
CHANGED
@@ -56,5 +56,11 @@ async def process_pdf(
|
|
56 |
}
|
57 |
|
58 |
if __name__ == "__main__":
|
|
|
|
|
|
|
|
|
|
|
|
|
59 |
rabbit_worker()
|
60 |
uvicorn.run(app, host="0.0.0.0", port=8000)
|
|
|
56 |
}
|
57 |
|
58 |
if __name__ == "__main__":
|
59 |
+
os.system('pip uninstall -y magic-pdf')
|
60 |
+
os.system('pip install git+https://github.com/opendatalab/MinerU.git@dev')
|
61 |
+
# os.system('pip install git+https://github.com/myhloli/Magic-PDF.git@dev')
|
62 |
+
|
63 |
+
os.system('wget https://github.com/opendatalab/MinerU/raw/dev/scripts/download_models_hf.py -O download_models_hf.py')
|
64 |
+
os.system('python download_models_hf.py')
|
65 |
rabbit_worker()
|
66 |
uvicorn.run(app, host="0.0.0.0", port=8000)
|