环境要求
cuda11.8
https://developer.nvidia.com/cuda-11-8-0-download-archive?target_os=Windows&target_arch=x86_64&target_version=11&target_type=exe_local
torch2.0.1
OSX
# conda
conda install pytorch==2.0.1 torchvision==0.15.2 torchaudio==2.0.2 -c pytorch
Linux and Windows
conda install pytorch==2.0.1 torchvision==0.15.2 torchaudio==2.0.2 pytorch-cuda=11.8 -c pytorch -c nvidia
conda
https://docs.anaconda.com/miniconda/
GOT-OCR2.0安装
1.Clone this repository and navigate to the GOT folder
git clone https://github.com/Ucas-HaoranWei/GOT-OCR2.0.git
cd 'the GOT folder'
2.Install Package(记得先安装torch2.0.1)
conda create -n got python=3.10 -y
conda activate got
pip install -e .
3.Install Flash-Attention
pip install ninja
pip install flash-attn --no-build-isolation