Skip to content

Instantly share code, notes, and snippets.

View fsodogandji's full-sized avatar

Fabrice Sodogandji fsodogandji

View GitHub Profile
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@fsodogandji
fsodogandji / elastic_transform.py
Created August 11, 2016 10:54 — forked from chsasank/elastic_transform.py
Elastic transformation of an image in Python
import numpy as np
from scipy.ndimage.interpolation import map_coordinates
from scipy.ndimage.filters import gaussian_filter
def elastic_transform(image, alpha, sigma, random_state=None):
"""Elastic deformation of images as described in [Simard2003]_.
.. [Simard2003] Simard, Steinkraus and Platt, "Best Practices for
Convolutional Neural Networks applied to Visual Document Analysis", in
@fsodogandji
fsodogandji / readme.md
Created September 1, 2016 23:14 — forked from baraldilorenzo/readme.md
VGG-16 pre-trained model for Keras

##VGG16 model for Keras

This is the Keras model of the 16-layer network used by the VGG team in the ILSVRC-2014 competition.

It has been obtained by directly converting the Caffe model provived by the authors.

Details about the network architecture can be found in the following arXiv paper:

Very Deep Convolutional Networks for Large-Scale Image Recognition

K. Simonyan, A. Zisserman

@fsodogandji
fsodogandji / mdn_demo_theano.py
Created September 10, 2016 10:06 — forked from mujjingun/mdn_demo_theano.py
Mixture Density Network(MDN) implemenation in Theano
# -*- coding: utf-8 -*-
"""
Created on Mon Aug 22 00:36:48 2016
@author: park
"""
#%% train
import theano
@fsodogandji
fsodogandji / stacked_ensemble.py
Created October 3, 2016 09:26 — forked from ktrnka/stacked_ensemble.py
Stacked ensemble of classifiers compatible with scikit-learn
class StackedEnsembleClassifier(sklearn.base.BaseEstimator, sklearn.base.ClassifierMixin):
"""
Ensemble of classifiers. Each classifier must have predict_proba and the head classifier is trained
to predict the output based on the individual classifier outputs. Stratified k-fold cross-validation
is used to get probabilities on held-out data.
"""
def __init__(self, classifiers, head_classifier, num_folds=3):
self.classifiers = classifiers
self.head_classifier = head_classifier
self.num_folds = num_folds
@fsodogandji
fsodogandji / pmf-and-modified-bpmf-pymc.py
Created October 28, 2016 03:35 — forked from macks22/pmf-and-modified-bpmf-pymc.py
Probabilistic Matrix Factorization (PMF) + Modified Bayesian BMF
"""
Implementations of:
Probabilistic Matrix Factorization (PMF) [1],
Bayesian PMF (BPMF) [2],
Modified BPFM (mBPMF)
using `pymc3`. mBPMF is, to my knowledge, my own creation. It is an attempt
to circumvent the limitations of `pymc3` w/regards to the Wishart distribution:
import pandas as pd
from collections import Counter
import tensorflow as tf
from tffm import TFFMRegressor
from sklearn.metrics import mean_squared_error
from sklearn.model_selection import train_test_split
import numpy as np
# Loading datasets'
// Processing code by Etienne JACOB
// motion blur template by beesandbombs
// opensimplexnoise code in another tab might be necessary
// --> code here : https://gist.github.com/Bleuje/fce86ef35b66c4a2b6a469b27163591e
int[][] result;
float t, c;
float ease(float p) {
return 3*p*p - 2*p*p*p;
@fsodogandji
fsodogandji / Aezakmi Fingerprints Filter
Created June 7, 2021 10:27 — forked from chelovekula/Aezakmi Fingerprints Filter
All possible combinations for creating prints in Aezakmi
This file has been truncated, but you can view the full file.
[{
"headers" : {
"browser" : {
"name" : "Chrome"
},
"os" : {
"name" : "Windows"
}
},
@fsodogandji
fsodogandji / README.md
Created February 3, 2022 14:25 — forked from ajxchapman/README.md
Install Windows on Digital Ocean droplet