Image / app.py
Pezh's picture
Update app.py
d6a72d9 verified
import streamlit as st
import os
from pdf2image import convert_from_path
def convert_pdf_to_images(pdf_path):
images = convert_from_path(pdf_path)
for i, image in enumerate(images):
image.save(f'image{i}.png')
if st.button('ss'):
convert_pdf_to_images('hoor.pdf')