Spaces:
Sleeping
Sleeping
Update app.py
Browse files177 unmodified lines178179180181182183177 unmodified linesif run_button and uploaded_file is not None:image = np.array(Image.open(uploaded_file))height, width, _ = image.shapeimage_name = os.path.splitext(uploaded_file.name)[0]message, labels, boxes, scale_bar_pixels, scores= app.process(image, image_name, scale_bar_length_nm, thresh, height, width)177 unmodified lines178179180181182183184185177 unmodified linesif run_button and uploaded_file is not None:image = np.array(Image.open(uploaded_file))if image.shape[2] == 4:image = cv2.cvtColor(image, cv2.COLOR_BGRA2BGR)height, width, _ = image.shapeimage_name = os.path.splitext(uploaded_file.name)[0]message, labels, boxes, scale_bar_pixels, scores= app.process(image, image_name, scale_bar_length_nm, thresh, height, width)
app.py+2