how_to_download_models_en.md 1020 Bytes
Newer Older
1
2
Model downloads are divided into initial downloads and updates to the model directory. Please refer to the corresponding documentation for instructions on how to proceed.

3

4
5
# Initial download of model files

6
### Download the Model from Hugging Face
7

8
Use a Python Script to Download Model Files from Hugging Face
9
```bash
10
pip install huggingface_hub
11
wget https://github.com/opendatalab/MinerU/raw/master/scripts/download_models_hf.py -O download_models_hf.py
12
python download_models_hf.py
13
```
14
The Python script will automatically download the model files and configure the model directory in the configuration file.
15

16
The configuration file can be found in the user directory, with the filename `magic-pdf.json`.
17

18

19
20
# How to update models previously downloaded

21
## 1. Models downloaded via Hugging Face or Model Scope
22
23

If you previously downloaded models via Hugging Face or Model Scope, you can rerun the Python script used for the initial download. This will automatically update the model directory to the latest version.