Skip to content

Instantly share code, notes, and snippets.

View liviust's full-sized avatar
👾

Liviu-Daniel liviust

👾
View GitHub Profile
@liviust
liviust / rank_metrics.py
Created February 1, 2018 22:11 — forked from bwhite/rank_metrics.py
Ranking Metrics
"""Information Retrieval metrics
Useful Resources:
http://www.cs.utexas.edu/~mooney/ir-course/slides/Evaluation.ppt
http://www.nii.ac.jp/TechReports/05-014E.pdf
http://www.stanford.edu/class/cs276/handouts/EvaluationNew-handout-6-per.pdf
http://hal.archives-ouvertes.fr/docs/00/72/67/60/PDF/07-busa-fekete.pdf
Learning to Rank for Information Retrieval (Tie-Yan Liu)
"""
import numpy as np
@liviust
liviust / install.sh
Created January 24, 2018 21:00 — forked from NLKNguyen/install.sh
Install Hadoop on Ubuntu 16.04
# Copy line by line and paste to an interactive shell
# Update system
sudo apt-get update && sudo apt-get dist-upgrade
# Install Java
sudo add-apt-repository ppa:openjdk-r/ppa
sudo apt-get update
sudo apt-get install openjdk-7-jdk
@liviust
liviust / install_tensorflow.sh
Created January 24, 2018 14:20 — forked from izmailoff/install_tensorflow.sh
install tensorflow on Fedora
# install protobuf
sudo dnf install protobuf*
# install bazel
# https://docs.bazel.build/versions/master/install-redhat.html
sudo dnf copr enable vbatts/bazel
sudo dnf install bazel
# get TF src
git clone https://github.com/tensorflow/tensorflow.git
@liviust
liviust / CaffeBatchPrediction.cpp
Created May 16, 2017 17:26 — forked from erogol/CaffeBatchPrediction.cpp
Caffe c++ batch based prediction
#include "caffeclassifier.h"
CaffeClassifier::CaffeClassifier(const string& model_file,
const string& trained_file,
const string& mean_file,
const string& label_file,
const bool use_GPU,
const int batch_size) {
if (use_GPU)
Caffe::set_mode(Caffe::GPU);
@liviust
liviust / C++ Predict with caffe
Created May 16, 2017 17:25 — forked from onauparc/C++ Predict with caffe
sample code for caffe C++ prediction
#include <cuda_runtime.h>
#include <cstring>
#include <cstdlib>
#include <vector>
#include <string>
#include <iostream>
#include <stdio.h>
#include "caffe/caffe.hpp"
import sys
import numpy as np
import scipy.io
import caffe
# take args for model arch (prototxt), input/output models (binaryproto ),
# layer name, and channel permutation.
arch_f, in_f, out_f = sys.argv[1:4]
layer = sys.argv[4]
@liviust
liviust / Readme.md
Created May 3, 2017 22:02 — forked from myfavouritekk/Readme.md
Extract dense optical flow and save as grayscale or RGB images

#Extract dense optical flow and save as grayscale or RGB images Copyright @ Kai Kang (myfavouritekk@gmail.com) 2016

##Dependencies

  • OpenCV 2 with Python interface
  • glob, numpy, siopy

##Usages

# help messages