Instructions WIP
Tested on Ubuntu 18.04.
Follow instructions from here.
Instructions WIP
Tested on Ubuntu 18.04.
Follow instructions from here.
| #! /usr/bin/env python | |
| class Pipeline(object): | |
| def __init__(self): | |
| self.source = None | |
| def __iter__(self): | |
| return self.generator() | |
| def generator(self): |
| #!/usr/bin/env python | |
| """ | |
| This script makes use of pre-trained Inception V3 network's weights to make your own image classifier | |
| Go through the script, make your own changes to the network as well as to the hyper-parameters | |
| Dependencies: numpy | |
| tensorflow | |
| keras | |
| Usage: python3 classifier.py #n_epochs |
| wget --no-check-certificate --content-disposition https://github.com/joyent/node/tarball/v0.7.1 | |
| # --no-check-cerftificate was necessary for me to have wget not puke about https | |
| curl -LJO https://github.com/joyent/node/tarball/v0.7.1 |
| # Take base as Ubuntu: 16.04, then you can simply apt-get install ffmpeg | |
| FROM ubuntu:16.04 | |
| # Install missing part of ubuntu core + python + building dependencies | |
| RUN apt-get update && \ | |
| apt-get install -y wget git unzip curl \ | |
| libtcmalloc-minimal4 software-properties-common apt-utils \ | |
| build-essential cmake pkg-config \ | |
| libjpeg8-dev libtiff5-dev libjasper-dev libpng12-dev \ | |
| libavcodec-dev libavformat-dev libswscale-dev libv4l-dev \ | |
| libxvidcore-dev libx264-dev \ |
| #!/usr/bin/env python | |
| from pygame import camera | |
| import pygame | |
| import time | |
| import cv | |
| import os | |
| # Recognition |
| import pygame | |
| import pygame.camera | |
| from pygame.locals import * | |
| DEVICE = '/dev/video0' | |
| SIZE = (640, 480) | |
| FILENAME = 'capture.png' | |
| def camstream(): | |
| pygame.init() |
| ''' | |
| QT4 Webcam demo in python | |
| Copyright (c) 2013, Tim Sheerman-Chase | |
| All rights reserved. | |
| Redistribution and use in source and binary forms, with or without | |
| modification, are permitted provided that the following conditions are met: | |
| 1. Redistributions of source code must retain the above copyright notice, this | |
| list of conditions and the following disclaimer. |