Skip to content

Instantly share code, notes, and snippets.

View Yangqing's full-sized avatar
:octocat:

Yangqing Jia Yangqing

:octocat:
View GitHub Profile
@Yangqing
Yangqing / ypickle.py
Created May 13, 2013 22:48
ypickle: a simple script to achieve matlab type save and load, with the file compressed with zlib
"""ypickle.py implements an interface similar to pickle, but allows one to
perform a matlab-like store and load with zlib compression
"""
import cPickle as pickle
import zlib
class YPickle(object):
"""The abstract class that holds the data as attributes
"""
pass
@Yangqing
Yangqing / mr_compute_gist.py
Created May 17, 2013 00:05
The mapreduce code to extract gist features from ImageNet images. To be used together with mincepie.
from mincepie import mapreducer, launcher
import gflags
import glob
import leargist
import numpy as np
import os
from PIL import Image
import uuid
# constant value
@Yangqing
Yangqing / deep lena
Created September 5, 2013 20:11
An ipython notebook showing the results of lena going through the imagenet deep learning classifier.
This file has been truncated, but you can view the full file.
{
"metadata": {
"name": ""
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
#include "caffe2/core/init.h"
#include "caffe2/core/operator.h"
#include "caffe2/proto/caffe2.pb.h"
#include "caffe2/utils/proto_utils.h"
#include "caffe2/core/logging.h"
#include <regex>
#include <string>
CAFFE2_DEFINE_string(net, "", "The given net to benchmark.");