Prevent fatal exit cuased by missing imports #8
17
main.py
17
main.py
@ -1,21 +1,20 @@
|
||||
|
||||
from time import sleep
|
||||
from PIL import Image
|
||||
import os
|
||||
import serial
|
||||
import sys
|
||||
import os
|
||||
import json
|
||||
import datetime
|
||||
|
||||
try:
|
||||
import numpy as np
|
||||
from picamera import PiCamera
|
||||
from picamera.array import PiRGBArray
|
||||
import cv2
|
||||
import numpy as np
|
||||
from picamera import PiCamera
|
||||
from picamera.array import PiRGBArray
|
||||
import serial
|
||||
import cv2
|
||||
|
||||
except Exception as ex:
|
||||
print('[ Error ] some depandincies are missing\n'+ str(ex.args))
|
||||
sys.exit()
|
||||
print('[ Error ] some depandincies are missing\n'+ str(ex.args))
|
||||
sys.exit()
|
||||
|
||||
def init():
|
||||
go = True
|
||||
|
Loading…
Reference in New Issue
Block a user