Skip to content

Instantly share code, notes, and snippets.

bunkering down

John D. Pope johndpope

bunkering down
View GitHub Profile
# -*- coding: utf-8 -*-
"""DALL-E Pytorch - COCO dataset
Automatically generated by Colaboratory.
Original file is located at
**Install necessary dependencies**
# from
import argparse
import os
import shutil
import numpy as np
import dnnlib
import dnnlib.tflib as tflib
import pretrained_networks
johndpope / Dockerfile
Last active Dec 19, 2020
tweaks for docker container 3090 nvidia / ssh / zsh
View Dockerfile
# Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved.
# NVIDIA CORPORATION and its licensors retain all intellectual property
# and proprietary rights in and to this software, related documentation
# and any modifications thereto. Any use, reproduction, disclosure or
# distribution of this software and related documentation without an express
# license agreement from NVIDIA CORPORATION is strictly prohibited.
import argparse
import json
import subprocess
import urllib.error
import urllib.parse
import urllib.request
def find_forks(remote):
johndpope / GenerateFirebasePushID.SQL
Created Nov 14, 2020 — forked from DimuDesigns/GenerateFirebasePushID.SQL
MySQL Stored Procedure for generating Firebase Push IDs
View GenerateFirebasePushID.SQL
* Fancy ID generator that creates 20-character string identifiers with the following properties:
* 1. They're based on timestamp so that they sort *after* any existing ids.
* 2. They contain 72-bits of random data after the timestamp so that IDs won't collide with other clients' IDs.
* 3. They sort *lexicographically* (so the timestamp is converted to characters that will sort properly).
* 4. They're monotonically increasing. Even if you generate more than one in the same timestamp, the
* latter ones will sort after the former ones. We do this by using the previous random bits
* but "incrementing" them by 1 (only in the case of a timestamp collision).
johndpope / PushIDGenerator.swift
Created Oct 23, 2020 — forked from AhmedOS/PushIDGenerator.swift
Swift 4 port of Firebase Push ID generator
View PushIDGenerator.swift
// original:
class PushIDGenerator {
private init() { }
static private let PUSH_CHARS = Array("-0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz")
static private var lastPushTime: UInt64 = 0
static private var lastRandChars = Array<Int>(repeating: 0, count: 12)
static func generate() -> String {
View jukebox_extended_notebook.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
We couldn’t find that file to show.
View maya - skeleton 3d - arkit
CATALINA (use system python 2 framework / not conda / not pyenv)
install maya trial 2020
Need to install / build the maya plugin
PYTHON 2 - USD is officially supported.
PYTHON 3 - not yet - but nvidia does support.
johndpope / .zprofile
Last active May 7, 2020
gist to split out youtube mp3-> tracks
View .zprofile
export PATH="$HOME/.cargo/bin:$PATH"
mp3(){cd /Users/johndpope/Downloads/spleeter
mv *.mp3 backup
mv output/* backup
youtube-dl $1 --extract-audio --audio-format mp3 -o "%(title)s-%(id)s.%(ext)s"
thefile=$(ls *.mp3)
echo "Splitting file..."
split $thefile