diff --git a/samples/python2/camshift.py b/samples/python2/camshift.py index 3a576e111c..79b4c29510 100644 --- a/samples/python2/camshift.py +++ b/samples/python2/camshift.py @@ -58,7 +58,7 @@ class App(object): ret, self.frame = self.cam.read() vis = self.frame.copy() hsv = cv2.cvtColor(self.frame, cv2.COLOR_BGR2HSV) - mask = cv2.inRange(hsv, np.array((0, 60, 32)), np.array((180, 255, 255))) + mask = cv2.inRange(hsv, np.array((0., 60., 32.)), np.array((180., 255., 255.))) if self.selection: x0, y0, x1, y1 = self.selection diff --git a/samples/python2/demo.py b/samples/python2/demo.py index 5fb801036d..c8bdcd9f30 100644 --- a/samples/python2/demo.py +++ b/samples/python2/demo.py @@ -141,7 +141,7 @@ class App: def on_run(self, *args): cmd = self.cmd_entry.get() print 'running:', cmd - Popen(cmd, shell=True) + Popen("python " + cmd, shell=True) def run(self): tk.mainloop()