Skip to content

Instantly share code, notes, and snippets.

View automata's full-sized avatar

Vilson Vieira automata

View GitHub Profile
@automata
automata / INSTALL.md
Last active November 20, 2018 17:56
Install Tensorflow 1.12 (CUDA 9.0 + cuDNN) on Ubuntu 16.04 (NVIDIA GTX1060)

Install NVIDIA drivers (they were already installed, but it should be as simple as):

sudo apt-get install nvidia-384 nvidia-modprobe

Install CUDA:

Get URL from https://developer.nvidia.com/cuda-downloads
mkdir ~/nvidia-install ; cd ~/nvidia-install
wget -c https://developer.nvidia.com/compute/cuda/9.0/Prod/local_installers/cuda_9.0.176_384.81_linux-run

chmod +x cuda_9.0.176_384.81_linux-run

@automata
automata / .gitlab-ci.yml
Created June 5, 2018 00:56
Heroku Docker Container Release from GitLab CI (without Heroku CLI)
image: docker:latest
# Remember to set required vars as secret vars on GitLab CI settings
variables:
DOCKER_DRIVER: overlay
CONTAINER_TEST_IMAGE: ${CI_REGISTRY}/${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME}_${CI_COMMIT_SHA}_test
CONTAINER_DEPLOY_IMAGE: ${HEROKU_REGISTRY}/${CI_PROJECT_NAME}/web
HEROKU_API_KEY: ${HEROKU_AUTH_TOKEN}
services:
@automata
automata / about.md
Created February 20, 2018 03:14
Using @mattdesl's Texel with Three.js (WebGL renderer)
npm install [email protected] --global
texel index.js --open
ffmpeg -framerate 24 -i tmp/%03d.png -y output.gif
ffmpeg -framerate 24 -i tmp/%03d.png -y -c:v libx264 -profile:v high -crf 20 -pix_fmt yuv420p output.mp4

output.gif

@automata
automata / run.sh
Created September 5, 2016 02:24
Screenshot HTML content
#!/bin/bash
# First install phantomjs: `npm install phantomjs`
./node_modules/.bin/phantomjs script.js
git clone https://github.com/imgflo/imgflo.git
cd imgflo
git submodule update --init
TRAVIS_OS_NAME=osx make travis-deps
npm install
rm install/lib/libs/libsqlite*.dylib
make run RELOCATE_DEPS=true NOAUTOLAUNCH=1 GRAPH=graphs/checker.json
[{"id":"c64ac187-d0f7-447c-a553-82ddc8d0ee66","item":"a21d9980-e90d-4847-9468-fdee96410be2","type":"article","html":"<article><h1>&apos;Light field&apos; camera maker Lytro announces professional VR video rig</h1><p>Camera maker Lytro drew our attention three years ago with what it called &quot;light field&quot; photography. Instead of focusing at a specific depth, its camera would capture everything in range of its finder, so you could do things like pick a focus after taking the picture.</p><img src=\"https://cdn2.vox-cdn.com/thumbor/coa6r2TY3lum-A4sKovYI9akKr0=/cdn0.vox-cdn.com/uploads/chorus_asset/file/4232179/Lytro_Immerge_Coast.0.jpg\"></article>","score":0,"created_at":null,"updated_at":null,"metadata":{"datePublished":null,"caption":"Camera maker Lytro drew our attention three years ago with what it called \"light field\" photography. Instead of focusing at a specific depth, its camera would capture everything in range of its finder, so you could do things like pick a focus after taking the picture.",
(node) warning: possible EventEmitter memory leak detected. 11 removeInitial listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at Graph.addListener (events.js:239:17)
at Network.subscribeGraph (/home/vilson/src/the-grid/caliper/node_modules/noflo/lib/Network.js:347:25)
at /home/vilson/src/the-grid/caliper/node_modules/noflo/lib/Network.js:220:17
at /home/vilson/src/the-grid/caliper/node_modules/noflo/lib/Network.js:213:22
at Network.addDefaults (/home/vilson/src/the-grid/caliper/node_modules/noflo/lib/Network.js:589:16)
at /home/vilson/src/the-grid/caliper/node_modules/noflo/lib/Network.js:205:39
at /home/vilson/src/the-grid/caliper/node_modules/noflo/lib/Network.js:213:22
at Network.addDefaults (/home/vilson/src/the-grid/caliper/node_modules/noflo/lib/Network.js:589:16)
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "ubuntu/trusty64"
config.vm.network "forwarded_port", guest: 5000, host: 5000
config.vm.network "forwarded_port", guest: 8080, host: 8080
config.vm.synced_folder "vagrant", "/vagrant", disabled: true
config.vm.synced_folder "src", "/home/vagrant/src", disabled: false
config.vm.provider "virtualbox" do |vb|
sharp.cache(true):
{ rss: 140107776, heapTotal: 107423328, heapUsed: 77185488 }
{ rss: 1835532288, heapTotal: 108443232, heapUsed: 77948600 }
sharp.cache(false):
{ rss: 146997248, heapTotal: 106391392, heapUsed: 76500328 }
{ rss: 150020096, heapTotal: 106391392, heapUsed: 77437088 }
Resident memory while caching (1835 MB) is around 10x more when
caching is disabled (150 MB).