Spaces:
Running
Running
import os | |
class Config: | |
def __init__(self): | |
self.current_dir = os.path.dirname(os.path.abspath(__file__)) | |
self.seg_model_path = os.path.join(self.current_dir, "seg.pth") | |
self.rec_model_path = os.path.join( | |
self.current_dir, "DocScanner-L.pth" | |
) | |
self.geotr_model_path = os.path.join(self.current_dir, "pretrained", "model.pt") | |
self.save_path = os.path.join(self.current_dir, "output") | |
def get_seg_model_path(self): | |
return self.seg_model_path | |
def get_rec_model_path(self): | |
return self.rec_model_path | |
def get_geotr_model_path(self): | |
return self.geotr_model_path | |
def get_save_path(self): | |
return self.save_path | |