Spaces:
Runtime error
Runtime error
A newer version of the Gradio SDK is available:
6.5.1
Detailed installing instructions
This instalation guide for edocr2 includes steps to install WSL, Anaconda, Cuda and VS Code. If you have experience with this, jump to step 4.
1. Enable Windows Subsystem for Linux (WSL)
- Open PowerShell as Administrator and run the following command to install WSL:
wsl --install - Go to Turn Windows features on or off and ensure the following features are enabled:
- Virtual Machine Platform
- Windows Subsystem for Linux
2. Set Up Anaconda and Cuda in WSL
Open the Ubuntu terminal in WSL and install Anaconda:
- Check the latest version of Anaconda from Anaconda Archive.
- Run the following command (replace with the latest version):
wget https://repo.anaconda.com/archive/Anaconda3-2024.06-1-Linux-x86_64.sh
Install CUDA 11.8 from the Nvidia CUDA Toolkit.
Add CUDA to your
.bashrcfile:- Follow the instructions in this Ask Ubuntu post to configure your environment.
3. Install and Configure VS Code
- Install Visual Studio Code:
sudo apt install code - Open the project in VS Code:
code .
4. Install Required Python Packages
Create your conda environment (Python 3.11)
conda create -n edocr2 python=3.11 -y conda activate edocr2Install TensorFlow with CUDA support:
pip install tensorflow[and-cuda]Install edocr requirements:
pip install -r 'requirements.txt'Install Tesseract OCR and pytesseract:
- Install the necessary dependencies:
sudo apt-get install libleptonica-dev tesseract-ocr libtesseract-dev python3-pil tesseract-ocr-eng tesseract-ocr-script-latn tesseract-ocr-nor - For swedish:
sudo apt-get install tesseract-ocr-swe - Install Tesseract and pytesseract:
pip install tesseract pip install pytesseract
- Install the necessary dependencies: