image_through_model #49

Merged
brian merged 75 commits from image_through_model into main 2024-10-20 00:10:27 +02:00
Showing only changes of commit e656cd4e12 - Show all commits
+3 -10
View File
@@ -1,25 +1,18 @@
"""Main script to be run by service."""
from pathlib import Path
from dotenv import load_dotenv
from models import VisualCommunicationModel
from torchinfo import summary
from utils import load_model
from shared.data_store import connect
from shared.utils import setup_logging
if __name__ == '__main__':
# load in env file
env_path = Path(__file__).parent.parent.parent / 'server.env'
load_dotenv(env_path)
# setup logging
setup_logging()
# connect to minio
minio_client = connect()
# instantiate model
model: VisualCommunicationModel = load_model(client=minio_client)
# show model weights
summary(model)
print('loaded model')
# get image
# make prediction