This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Load the IFrame Player API code asynchronously. | |
var tag = document.createElement("script"); | |
tag.src = "https://www.youtube.com/iframe_api"; | |
var firstScriptTag = document.getElementsByTagName("script")[0]; | |
firstScriptTag.parentNode.insertBefore(tag, firstScriptTag); | |
// Instantiate the Player. | |
function onYouTubeIframeAPIReady() { | |
var player = new YT.Player("player", { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import base64 | |
import hmac | |
import hashlib | |
from urllib import parse | |
from django.contrib.auth.decorators import login_required | |
from django.http import HttpResponseBadRequest, HttpResponseRedirect | |
from django.conf import settings | |
@login_required |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# couple things I'd throw in there: | |
# moar whitespace | |
res = [ | |
[ | |
[ | |
kriger.predict(x,y,z) | |
for x in grid[0] | |
] | |
for y in grid[1] | |
] |