UDOP_Document_AI / logic.py
Polo123's picture
Create logic.py
31ac8a4 verified
raw
history blame contribute delete
278 Bytes
from transformers import UdopProcessor, UdopForConditionalGeneration
def load_Model():
repo_id = "microsoft/udop-large"
processor = UdopProcessor.from_pretrained(repo_id)
model = UdopForConditionalGeneration.from_pretrained(repo_id)
return model, processor