| | |
| | | #include "box.h" |
| | | #include "image.h" |
| | | #include "demo.h" |
| | | #include <sys/time.h> |
| | | //#include <sys/time.h> |
| | | #include <time.h> |
| | | #include <winsock.h> |
| | | #include "gettimeofday.h" |
| | | |
| | | #define FRAMES 3 |
| | | |
| | |
| | | if(l.type == DETECTION){ |
| | | get_detection_boxes(l, 1, 1, demo_thresh, probs, boxes, 0); |
| | | } else if (l.type == REGION){ |
| | | get_region_boxes(l, 1, 1, demo_thresh, probs, boxes, 0); |
| | | get_region_boxes(l, 1, 1, demo_thresh, probs, boxes, 0, 0); |
| | | } else { |
| | | error("Last layer must produce detections\n"); |
| | | } |
| | |
| | | srand(2222222); |
| | | |
| | | if(filename){ |
| | | printf("video file: %s\n", filename); |
| | | cap = cvCaptureFromFile(filename); |
| | | }else{ |
| | | cap = cvCaptureFromCAM(cam_index); |