This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| This tests issue https://github.com/scikit-learn/scikit-learn/issues/3835 | |
| """ | |
| import time | |
| import itertools | |
| import joblib | |
| from math import ceil | |
| from multiprocessing import Pool, cpu_count | |
| from functools import partial |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [ | |
| { | |
| "city": "New York", | |
| "growth_from_2000_to_2013": "4.80%", | |
| "latitude": 40.7127837, | |
| "longitude": -74.0059413, | |
| "population": 8405837, | |
| "rank": 1, | |
| "state": "New York", | |
| "timezone": "America/New_York" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Ask for the user password | |
| # Script only works if sudo caches the password for a few minutes | |
| sudo true | |
| # Install kernel extra's to enable docker aufs support | |
| # sudo apt-get -y install linux-image-extra-$(uname -r) | |
| # Add Docker PPA and install latest version | |
| # sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 36A1D7869245C8950F966E92D8576A8BA88D21E9 | |
| # sudo sh -c "echo deb https://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### Keybase proof | |
| I hereby claim: | |
| * I am escherba on github. | |
| * I am etangent (https://keybase.io/etangent) on keybase. | |
| * I have a public key whose fingerprint is 4191 7845 CFC0 8A8C D122 5D1F 3C87 6168 7E41 8426 | |
| To claim this, I am signing this object: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # (C) Mathieu Blondel, November 2013 | |
| # License: BSD 3 clause | |
| import numpy as np | |
| def ranking_precision_score(y_true, y_score, k=10): | |
| """Precision at rank k | |
| Parameters |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """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 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| Three ways of computing the Hellinger distance between two discrete | |
| probability distributions using NumPy and SciPy. | |
| """ | |
| import numpy as np | |
| from scipy.linalg import norm | |
| from scipy.spatial.distance import euclidean | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff -ur org/freeglut-2.8.1/progs/demos/smooth_opengl3/smooth_opengl3.c freeglut-2.8.1/progs/demos/smooth_opengl3/smooth_opengl3.c | |
| --- org/freeglut-2.8.1/progs/demos/smooth_opengl3/smooth_opengl3.c 2014-06-01 21:27:45.000000000 -0700 | |
| +++ freeglut-2.8.1/progs/demos/smooth_opengl3/smooth_opengl3.c 2014-06-01 21:28:00.000000000 -0700 | |
| @@ -102,12 +102,9 @@ | |
| typedef void (APIENTRY *PFNGLGENVERTEXARRAYSPROC) (GLsizei n, GLuint *arrays); | |
| typedef void (APIENTRY *PFNGLBINDVERTEXARRAYPROC) (GLuint array); | |
| #endif | |
| -#ifndef GL_VERSION_1_5 | |
| typedef void (APIENTRY *PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); | |
| typedef void (APIENTRY *PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff -ur org/freeglut-2.8.1/include/GL/freeglut_std.h freeglut-2.8.1/include/GL/freeglut_std.h | |
| --- org/freeglut-2.8.1/include/GL/freeglut_std.h | |
| +++ freeglut-2.8.1/include/GL/freeglut_std.h | |
| @@ -122,7 +122,7 @@ | |
| * Always include OpenGL and GLU headers | |
| */ | |
| #if __APPLE__ | |
| -# include <OpenGL/gl.h> | |
| +# include <OpenGL/gl3.h> | |
| # include <OpenGL/glu.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/zbar/jpeg.c b/zbar/jpeg.c | |
| index fb566f4..d1c1fb2 100644 | |
| --- a/zbar/jpeg.c | |
| +++ b/zbar/jpeg.c | |
| @@ -79,8 +79,15 @@ int fill_input_buffer (j_decompress_ptr cinfo) | |
| void skip_input_data (j_decompress_ptr cinfo, | |
| long num_bytes) | |
| { | |
| - cinfo->src->next_input_byte = NULL; | |
| - cinfo->src->bytes_in_buffer = 0; |
NewerOlder