Downloads · 30 days
0
ketanmore/ArabicDoc-layout-Detection
ArabicDoc-layout-Detection is a machine learning model from ketanmore. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as apache-2.0.
The author has not provided requirements.txt file, but environment.yml from our conda environment has been uploaded, This file can be used to recreate environment for arabiclayoutmodel model.
Downloads · 30 days
0
Access
Public
Updated Oct 31, 2024
Repo size
64.1 MB
Likes
0
Public
Click a slice to open those files.
.pt64.1 MB · 92%
From the Hugging Face model README
git clone https://github.com/VikParuchuri/surya.git
cd surya
git checkout f7c6c04
The author has not provided requirements.txt file, but environment.yml from our conda environment has been uploaded, This file can be used to recreate environment for arabic_layout_model model.
Download ArabicDoc.cpython-310-x86_64-linux-gnu.so , 10x_best.pt and surya folder from the Repository.
Place ArabicDoc.cpython-310-x86_64-linux-gnu.so, 10x_best.pt and surya folder in same directory (They are dependent on each other).
from ArabicDoc import arabic_layout_model # This import will originate from ArabicDoc.cpython-310-x86_64-linux-gnu.so , which is present in the repo. Also this works with Linux based OS only.
from surya.postprocessing.heatmap import draw_bboxes_on_image
from PIL import Image
image_path = "sample.jpg"
image = Image.open(image_path)
bboxes = arabic_layout_model(image_path)
plotted_image = draw_bboxes_on_image(bboxes,image)
benchmark.ipynb for comparison between Traditional Surya Layout Model and New Layout Model.results folder to visualize images obtained from both the models.