Skip to content

Instantly share code, notes, and snippets.

BigsnarfDude bigsnarfdude

Block or report user

Report or block bigsnarfdude

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View app2.js
<div>Teachable Machine Image Model</div>
<button type="button" onclick="init()">Start</button>
<div id="webcam-container"></div>
<div id="label-container"></div>
<script src="https://cdn.jsdelivr.net/npm/@tensorflow/tfjs@1.3.1/dist/tf.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/@teachablemachine/image@0.8/dist/teachablemachine-image.min.js"></script>
<script type="text/javascript">
// More API functions here:
// https://github.com/googlecreativelab/teachablemachine-community/tree/master/libraries/image
View app.js
<div>Teachable Machine Image Model</div>
<button type="button" onclick="init()">Start</button>
<div id="webcam-container"></div>
<div id="label-container"></div>
<script src="https://cdn.jsdelivr.net/npm/@tensorflow/tfjs@1.3.1/dist/tf.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/@teachablemachine/image@0.8/dist/teachablemachine-image.min.js"></script>
<script type="text/javascript">
// More API functions here:
// https://github.com/googlecreativelab/teachablemachine-community/tree/master/libraries/image
@bigsnarfdude
bigsnarfdude / app.js
Created Nov 8, 2019
teachable machine script
View app.js
<div>Teachable Machine Image Model</div>
<button type="button" onclick="init()">Start</button>
<div id="webcam-container"></div>
<div id="label-container"></div>
<script src="https://cdn.jsdelivr.net/npm/@tensorflow/tfjs@1.3.1/dist/tf.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/@teachablemachine/image@0.8/dist/teachablemachine-image.min.js"></script>
<script type="text/javascript">
// More API functions here:
// https://github.com/googlecreativelab/teachablemachine-community/tree/master/libraries/image
View gist:a37b6e447d43e2476712644a7e081414
https://www.usafmarathon.com/wp-content/uploads/2017/09/170916-F-AV193-1299.jpg
https://arxiv.org/abs/1910.05085
http://openaccess.thecvf.com/content_CVPRW_2019/html/CVSports/Liu_Pose-Guided_R-CNN_for_Jersey_Number_Recognition_in_Sports_CVPRW_2019_paper.html
https://www.reddit.com/r/MachineLearning/comments/dmiybr/d_suggestion_for_multidigit_number_recognitionocr/
@bigsnarfdude
bigsnarfdude / pdConcat.py
Last active Oct 10, 2019
pandas concat multiple files
View pdConcat.py
import pandas as pd
from glob import glob
raw_files = sorted(glob('files*.csv'))
pd.concat((pd.read_csv(singleFile).assign(filename=singleFile) for singleFile in raw_files), ignore_index=True)
View extractor.py
from slimit.parser import Parser
from slimit.visitors import nodevisitor
from slimit import ast
import re
def check_code_sanity(sequence):
parser = Parser()
tree = parser.parse(sequence)
for node in nodevisitor.visit(tree):
View whammy.js
/*
var vid = new Whammy.Video();
vid.add(canvas or data url)
vid.compile()
*/
window.Whammy = (function(){
// in this case, frames has a very specific meaning, which will be
// detailed once i finish writing the code
@bigsnarfdude
bigsnarfdude / tester.py
Created Aug 7, 2019
opencv convert to jpeg python of "webm" files
View tester.py
import cv2
cap = cv2.VideoCapture('test.webm')
i=0
while(cap.isOpened()):
ret, frame = cap.read()
if ret == False:
break
cv2.imwrite('tester'+str(i)+'.jpg',frame)
View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="description" content="WebRTC code samples">
<meta name="viewport" content="width=device-width, user-scalable=yes, initial-scale=1, maximum-scale=1">
<meta itemprop="description" content="Client-side WebRTC code samples">
<meta itemprop="image" content="../../../images/webrtc-icon-192x192.png">
<meta itemprop="name" content="WebRTC code samples">
You can’t perform that action at this time.