repo_name stringlengths 6 103 | path stringlengths 5 191 | copies stringlengths 1 4 | size stringlengths 4 6 | content stringlengths 986 970k | license stringclasses 15
values |
|---|---|---|---|---|---|
vdumoulin/fuel | fuel/transformers/sequences.py | 7 | 4963 | from fuel.transformers import Transformer
class Window(Transformer):
"""Return pairs of source and target windows from a stream.
This data stream wrapper takes as an input a data stream outputting
sequences of potentially varying lengths (e.g. sentences, audio tracks,
etc.). It then returns two slidi... | mit |
yafeunteun/wikipedia-spam-classifier | revscoring/revscoring/utilities/tune.py | 1 | 9729 | """
Tunes a set of models against a training set to identify the best
model/configuration.
Usage:
tune <params-config> <features> <label>
[--observations=<path>]
[--scoring=<type>]
[--test-prop=<prop>]
[--folds=<num>]
[--report=<path>]
[--label-type=<type>]
... | mit |
lakshayg/tensorflow | tensorflow/contrib/learn/python/learn/preprocessing/categorical.py | 151 | 4269 | # Copyright 2016 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | apache-2.0 |
musically-ut/statsmodels | examples/python/tsa_dates.py | 29 | 1169 |
## Dates in timeseries models
from __future__ import print_function
import statsmodels.api as sm
import pandas as pd
# ## Getting started
data = sm.datasets.sunspots.load()
# Right now an annual date series must be datetimes at the end of the year.
dates = sm.tsa.datetools.dates_from_range('1700', length=len(da... | bsd-3-clause |
jpzk/evopy | evopy/examples/experiments/cv_ppv_dsesscv/plot_precisions.py | 1 | 4256 | '''
This file is part of evopy.
Copyright 2012 - 2013, Jendrik Poloczek
evopy 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 3 of the License, or (at your
option) any later version.
evopy is di... | gpl-3.0 |
lakshayg/tensorflow | tensorflow/python/keras/_impl/keras/datasets/fashion_mnist.py | 12 | 2055 | # Copyright 2017 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | apache-2.0 |
musically-ut/statsmodels | statsmodels/datasets/statecrime/data.py | 25 | 3128 | #! /usr/bin/env python
"""Statewide Crime Data"""
__docformat__ = 'restructuredtext'
COPYRIGHT = """Public domain."""
TITLE = """Statewide Crime Data 2009"""
SOURCE = """
All data is for 2009 and was obtained from the American Statistical Abstracts except as indicated below.
"""
DESCRSHORT = """State ... | bsd-3-clause |
PAIR-code/recommendation-rudders | hyperbolic-rs/preprocess.py | 1 | 11964 | # Copyright 2017 The Rudders Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | apache-2.0 |
openplans/shareabouts-api | src/sa_api_v2/tasks.py | 1 | 10690 |
import requests
import ujson as json
from celery import shared_task
from celery.result import AsyncResult
from django.db import transaction
from django.test.client import RequestFactory
from django.utils.timezone import now
from itertools import chain
#from social.apps.django_app.default.models import UserSocialAuth
... | gpl-3.0 |
kastnerkyle/pylearn2 | pylearn2/datasets/stl10.py | 1 | 5304 | """
.. todo::
WRITEME
"""
__authors__ = "Ian Goodfellow"
__copyright__ = "Copyright 2010-2012, Universite de Montreal"
__credits__ = ["Ian Goodfellow"]
__license__ = "3-clause BSD"
__maintainer__ = "LISA Lab"
__email__ = "pylearn-dev@googlegroups"
import numpy as np
from pylearn2.datasets import dense_design_matri... | bsd-3-clause |
nicproulx/mne-python | examples/connectivity/plot_mixed_source_space_connectity.py | 3 | 6976 | """
===============================================================================
Compute mixed source space connectivity and visualize it using a circular graph
===============================================================================
This example computes the all-to-all connectivity between 75 regions in
a m... | bsd-3-clause |
tabhitmy/MLTF | WORKFLOW/code/python_code/sklearnTrainer.py | 1 | 12746 | # sklearnTrainer
import numpy
import numpy as np
import copy
from toolkitJ import cell2dmatlab_jsp
import matplotlib as mpl
from matplotlib.font_manager import FontProperties
zhfont = FontProperties(fname="/usr/share/fonts/cjkuni-ukai/ukai.ttc") # 图片显示中文字体
mpl.use('Agg')
import pprint
from sklearn.ex... | mit |
aranega/pyecore | experimental/m2m/transfo_example.py | 2 | 2226 | import motra
# generated using
# https://github.com/kolovos/datasets/blob/master/github-mde/ghmde.ecore
# as input metamodel
import ghmde
from pyecore.ecore import *
# Define a graph like metamodel in a static way
eClass = EPackage('graph', nsURI='http://graph/1.0', nsPrefix='graph')
@EMetaclass
class Node(object):... | bsd-3-clause |
vdumoulin/fuel | fuel/converters/cifar100.py | 18 | 3576 | import os
import tarfile
import h5py
import numpy
import six
from six.moves import cPickle
from fuel.converters.base import fill_hdf5_file, check_exists
DISTRIBUTION_FILE = 'cifar-100-python.tar.gz'
@check_exists(required_files=[DISTRIBUTION_FILE])
def convert_cifar100(directory, output_directory,
... | mit |
agnusfeec/tattCBIR | lib_sistema.py | 1 | 25313 | # -*- coding: utf-8 -*-
"""
Created on Thu Jul 14 13:36:05 2016
@author: agnus
"""
#%%
def monta_lista_imagens(path = '.', ext='.png'):
import os
imagens = {}
for dirname, dirnames, filenames in os.walk(path):
# print path to all filenames with extension py.
for filename in filenames:
... | gpl-3.0 |
aalmah/pylearn2 | pylearn2/devtools/tests/test_format.py | 24 | 25785 | """
Unit tests for format checking
"""
from __future__ import print_function
from nose.plugins.skip import SkipTest
import os
import pylearn2
from pylearn2.devtools.tests.docscrape import docstring_errors
from pylearn2.devtools.list_files import list_files
from pylearn2.devtools.tests.pep8.pep8 import StyleGuide
w... | bsd-3-clause |
jfsantos/ift6266h14 | old/test_timit_iy.py | 1 | 2996 | from timit_full import TimitFullCorpusReader
import itertools
import numpy as np
from pylearn2.datasets import DenseDesignMatrix
from pylearn2.models.mlp import *
from pylearn2.costs.mlp.dropout import Dropout
from pylearn2.termination_criteria import EpochCounter
from pylearn2.training_algorithms.sgd import SGD
from p... | mit |
neuroneuro15/natnetclient | build/lib/natnetclient/utils.py | 1 | 1318 | __author__ = 'ratcave'
import numpy as np
from sklearn.decomposition import PCA
def rotate_to_var(markers):
"""Returns degrees to rotate about y axis so greatest marker variance points in +X direction"""
# Mean-Center
markers -= np.mean(markers, axis=0)
# Vector in direction of greatest variance
... | gpl-2.0 |
joshbohde/scikit-learn | sklearn/linear_model/tests/test_sgd.py | 1 | 16225 | import numpy as np
from numpy.testing import assert_array_equal, assert_approx_equal
from numpy.testing import assert_almost_equal, assert_array_almost_equal
from sklearn import linear_model, datasets, metrics
from sklearn import preprocessing
import unittest
from nose.tools import raises
from nose.tools import asser... | bsd-3-clause |
ephes/scikit-learn | sklearn/semi_supervised/label_propagation.py | 127 | 15312 | # coding=utf8
"""
Label propagation in the context of this module refers to a set of
semisupervised classification algorithms. In the high level, these algorithms
work by forming a fully-connected graph between all points given and solving
for the steady-state distribution of labels at each point.
These algorithms per... | bsd-3-clause |
google-research/scenic | scenic/projects/robust_segvit/datasets/cityscapes_variants.py | 1 | 11019 | """Data generators for the Cityscapes dataset variants.
Supported datasets, set by dataset_configs.dataset_name in the config file:
cityscapes_corrupted: https://arxiv.org/pdf/1907.07484.pdf
fishyscapes: https://link.springer.com/article/10.1007/s11263-021-01511-6
Implementation details:
cityscapes_c: https://githu... | apache-2.0 |
starimpact/fast-rcnn | tools/train_net.py | 23 | 3134 | #!/usr/bin/env python
# --------------------------------------------------------
# Fast R-CNN
# Copyright (c) 2015 Microsoft
# Licensed under The MIT License [see LICENSE for details]
# Written by Ross Girshick
# --------------------------------------------------------
"""Train a Fast R-CNN network on a region of int... | mit |
End of preview. Expand in Data Studio
No dataset card yet
- Downloads last month
- 3