Skip to content

Commit

Permalink
Added run w/ GPS file
Browse files Browse the repository at this point in the history
  • Loading branch information
Yossi committed May 31, 2016
1 parent 52d846c commit 8eea878
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 0 deletions.
Binary file modified .DS_Store
Binary file not shown.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
*.pyc
wGPS
33 changes: 33 additions & 0 deletions mainGPS.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
import cv2
from classes import frameAnalyzer
from config import *
from classes.capture import capture
from classes.gps import GPS
import time

# # load image
# image = cv2.imread('training/set6/1.png')
# frameAnalyzer.analyze_frame(image, True, False, True)


# load video file
filename = '1464525240'


gps = GPS()
cap = cv2.VideoCapture(PARENT_DIR + "/training/wGPS/clip/"+filename+".avi")
capture = capture(int(cap.get(3)), int(cap.get(4)))
start = time.clock()
c = 0
while True:
# if c >0:
# cv2.waitKey(0)
c +=1
# # print c
if cap.grab():
gps.updateSystemPositionData(int(time.clock() - start), filename)

flag, frame = cap.retrieve()

frameAnalyzer.analyze_frame(frame, True, True)

Binary file modified modules/.DS_Store
Binary file not shown.
Binary file modified modules/video/.DS_Store
Binary file not shown.
Binary file modified training/.DS_Store
Binary file not shown.

0 comments on commit 8eea878

Please sign in to comment.