Skip to content

Instantly share code, notes, and snippets.

$ ./build/tools/caffe time --model=models/NIN/train_val.prototxt
Check failed: status.ok() Failed to open leveldb cifar-train-leveldb
Invalid argument: cifar-train-leveldb: does not exist (create_if_missing is false)
*** Check failure stack trace: ***
@ProGamerGov
ProGamerGov / illust2vec_tag.prototxt
Last active July 27, 2016 01:20
The "illust2vec_tag.prototxt" Converted so that you can you the "illust2vec_tag" model in systems such as Deepdream
name: "CaffeNet"
force_backward: true
input: "data"
input_dim: 1
input_dim: 3
input_dim: 224
input_dim: 224
layer {
name: "conv1_1"
type: "Convolution"
`simon1.tar.gz` 586 images (only colored) | 184 MB
`simon2.tar.gz` 725 images (including uncolored sketches and photos of sketches) | 282 MB
None of the images have been resized or cropped yet. A txt file called "filelist.txt" lists every image's name, so all you need to do is add the category and path for use in Caffe.
`simon1.tar.gz` 586 images (only colored) | 184 MB
`simon2.tar.gz` 725 images (including uncolored sketches and photos of sketches) | 282 MB
None of the images have been resized or cropped yet.
A txt file called "filelist.txt" lists every image's name,
so all you need to do is add the category value and the paths
for use in Caffe when making your train.txt and val.txt files.
@ProGamerGov
ProGamerGov / train_val_nsfw.prototxt
Last active October 14, 2016 06:14
A train_val for the Yahoo nsfw model
name: "Resnet_50_1by2"
force_backward: true
# Note - replace below layer with your data layer
layer {
name: "data"
type: "MemoryData"
top: "data"
top: "label"
transform_param {
crop_size: 224
Datasts:
https://github.com/ChristosChristofidis/awesome-deep-learning#datasets
Style Transfer Projects:
https://github.com/jcjohnson/neural-style/wiki/Similar-to-Neural-Style
name: "VGG16_SOD_finetune"
layer {
name: "data"
type: "Data"
top: "data"
top: "label"
include {
phase: TRAIN
}
transform_param {
@ProGamerGov
ProGamerGov / tensor_test.py
Last active January 5, 2017 23:38
Tests whether or not Tensorflow sees your GPU or CPU
import tensorflow as tf
# Creates a graph.
a = tf.constant([1.0, 2.0, 3.0, 4.0, 5.0, 6.0], shape=[2, 3], name='a')
b = tf.constant([1.0, 2.0, 3.0, 4.0, 5.0, 6.0], shape=[3, 2], name='b')
c = tf.matmul(a, b)
# Creates a session with log_device_placement set to True.
sess = tf.Session(config=tf.ConfigProto(log_device_placement=True))
# Runs the op.
print sess.run(c)
@ProGamerGov
ProGamerGov / neural_style_csv.lua
Last active January 21, 2017 20:29
A version of neural_style.lua that outputs loss values to the terminal in a csv friendly format
require 'torch'
require 'nn'
require 'image'
require 'optim'
require 'loadcaffe'
local cmd = torch.CmdLine()
require 'torch'
require 'nn'
require 'image'
require 'optim'
require 'loadcaffe'
local cmd = torch.CmdLine()