import os

# os.environ["config"]="{\"TZ\": \"Asia/Kolkata\", \"MONGO_URI\": \"mongodb://192.168.8.100:2717\", \"MONGO_DATABASE\": \"ilens_ai\", \"MONGO_COLLECTION\": \"janusDeployment\", \"MONGO_KEY\": \"deploymentId\", \"MONGO_VALUE\": \"VPM_a3c5ee04\", \"MONGO_COLL\": \"serviceConfiguration\", \"MONGO_DB\": \"ilens_ai\"}"
os.environ["config"]="{\"TZ\": \"Asia/Kolkata\", \"MONGO_URI\": \"mongodb://svc-ilens:svc2345@192.168.3.220:21017\", \"MONGO_DATABASE\": \"ilens_wps\", \"MONGO_COLLECTION\": \"janusDeployment\", \"MONGO_KEY\": \"deploymentId\", \"MONGO_VALUE\": \"ACCCementCamera20_61275102\", \"MONGO_COLL\": \"serviceConfiguration\", \"MONGO_DB\": \"ilens_wps\"}"

from edge_engine.edge_processor import ExecutePipeline
from edge_engine.edge_processor import Pubs
from scripts import CementBagCounter
from edge_engine.common.config import EDGE_CONFIG

if __name__ == '__main__':
    pubs = Pubs()
    mod = CementBagCounter(config=EDGE_CONFIG,
                           model_config=EDGE_CONFIG["modelConfig"],
                           pubs=pubs,
                           device_id=EDGE_CONFIG['deviceId'])
    ex = ExecutePipeline(mod)
    ex.run_model()
