PDFtoDocx-OCR / setup.sh
Chirapath's picture
Upload 9 files
989cfff verified
raw
history blame contribute delete
636 Bytes
#!/bin/bash
# Exit immediately if a command exits with a non-zero status.
set -e
# Update and install system-level dependencies
echo "APT-GET: UPDATING AND INSTALLING DEPENDENCIES"
apt-get update -y
apt-get install -y tesseract-ocr \
libtesseract-dev \
libgl1-mesa-glx \
libglib2.0-0 \
python3-opencv
# Clean up the apt cache to reduce image size
rm -rf /var/lib/apt/lists/*
# Install Python dependencies from requirements.txt
echo "PIP: INSTALLING PYTHON PACKAGES"
pip install --no-cache-dir -r requirements.txt
echo "SETUP COMPLETE"