remove unneeded code for running in docker container
This commit is contained in:
+3
-10
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user