This file contains 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
# .. Memory benchmarks for SciPy's Singular Value Decomposition .. | |
# .. Author: Fabian Pedregosa <fabian@fseoane.net> | |
import numpy as np | |
from scipy.sparse import linalg as splinalg | |
from scipy import sparse, linalg | |
import pylab as pl | |
from memory_profiler import memory_usage | |
dims = np.arange(500, 1500, 20) |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
import numpy as np | |
# Author : Fabian Pedregosa <fabian@fseoane.net> | |
# | |
# License : BSD | |
def isotonic_regression_new(w, y, x_min=None, x_max=None): | |
""" | |
Solve the isotonic regression with complete ordering model: |
This file contains 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
# -*- coding: utf-8 -*- | |
""" | |
Strong rules for coordinate descent | |
Author: Fabian Pedregosa <fabian@fseoane.net> | |
""" | |
import numpy as np | |
from scipy import linalg |
This file contains 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
# -*- coding: utf-8 -*- | |
""" | |
Minimalistic implementation of l1 minimization via coordinate descent. | |
Reference: www.jstatsoft.org/v33/i01/paper | |
Author: Fabian Pedregosa <fabian@fseoane.net> | |
""" | |
import numpy as np |
This file contains 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
import numpy as np | |
# Author : Alexandre Gramfort | |
# license : BSD | |
def pav(y): | |
""" | |
PAV uses the pair adjacent violators method to produce a monotonic | |
smoothing of y |
This file contains 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
import numpy as np | |
def isotonic_regression(w, y, x_min=None, x_max=None): | |
""" | |
Solve the isotonic regression model: | |
min Sum w_i (y_i - x_i) ** 2 | |
subject to x_min = x_1 <= x_2 ... <= x_n = x_max |
This file contains 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
import sys, os, termios, tty | |
pid, fd = os.forkpty() | |
term_info = termios.tcgetattr(sys.stdin.fileno()) | |
if pid < 0: | |
raise ValueError("Early exit: could not fork process") | |
elif pid == 0: | |
# .. child .. |
This file contains 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
""" | |
Implementation of pairwise ranking using scikit-learn LinearSVC | |
Reference: | |
"Large Margin Rank Boundaries for Ordinal Regression", R. Herbrich, | |
T. Graepel, K. Obermayer 1999 | |
"Learning to rank from medical imaging data." Pedregosa, Fabian, et al., | |
Machine Learning in Medical Imaging 2012. |
This file contains 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
/* | |
* pidgin | |
* | |
* Pidgin is the legal property of its developers, whose names are too numerous | |
* to list here. Please refer to the COPYRIGHT file distributed with this | |
* source distribution. | |
* | |
* This program is free software; you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License as published by | |
* the Free Software Foundation; either version 2 of the License, or |