repo_name
string
path
string
copies
string
size
string
content
string
license
string
apache/spark
python/pyspark/sql/functions.py
14
161861
# # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not us...
apache-2.0
JeanKossaifi/scikit-learn
sklearn/tree/tests/test_tree.py
48
47506
""" Testing for the tree module (sklearn.tree). """ import pickle from functools import partial from itertools import product import platform import numpy as np from scipy.sparse import csc_matrix from scipy.sparse import csr_matrix from scipy.sparse import coo_matrix from sklearn.random_projection import sparse_rand...
bsd-3-clause
Sumith1896/sympy
sympy/utilities/runtests.py
4
78928
""" This is our testing framework. Goals: * it should be compatible with py.test and operate very similarly (or identically) * doesn't require any external dependencies * preferably all the functionality should be in this file only * no magic, just import the test file and execute the test functions, that's it * po...
bsd-3-clause
gauravmm/Remote-Temperature-Monitor
utilities/colormap/colormaps.py
28
50518
# New matplotlib colormaps by Nathaniel J. Smith, Stefan van der Walt, # and (in the case of viridis) Eric Firing. # # This file and the colormaps in it are released under the CC0 license / # public domain dedication. We would appreciate credit if you use or # redistribute these colormaps, but do not impose any legal r...
mit
vermouthmjl/scikit-learn
sklearn/metrics/classification.py
1
69294
"""Metrics to assess performance on classification task given class prediction Functions named as ``*_score`` return a scalar value to maximize: the higher the better Function named as ``*_error`` or ``*_loss`` return a scalar value to minimize: the lower the better """ # Authors: Alexandre Gramfort <alexandre.gramf...
bsd-3-clause
eegroopm/pyLATTICE
gui/pyLATTICE.py
1
74321
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ pyLATTICE is... """ from __future__ import division #necessary for python2 from __future__ import unicode_literals # define authorship information __authors__ = ['Evan Groopman', 'Thomas Bernatowicz'] __author__ = ','.join(__authors__) __credits__...
gpl-2.0
tawsifkhan/scikit-learn
sklearn/linear_model/omp.py
127
30417
"""Orthogonal matching pursuit algorithms """ # Author: Vlad Niculae # # License: BSD 3 clause import warnings from distutils.version import LooseVersion import numpy as np from scipy import linalg from scipy.linalg.lapack import get_lapack_funcs from .base import LinearModel, _pre_fit from ..base import RegressorM...
bsd-3-clause
cbertinato/pandas
pandas/tests/frame/test_axis_select_reindex.py
1
44030
from datetime import datetime import numpy as np import pytest from pandas.errors import PerformanceWarning import pandas as pd from pandas import ( Categorical, DataFrame, Index, MultiIndex, Series, date_range, isna) from pandas.tests.frame.common import TestData import pandas.util.testing as tm from pandas.uti...
bsd-3-clause
chaluemwut/fbserver
venv/lib/python2.7/site-packages/sklearn/feature_extraction/text.py
1
49725
# -*- coding: utf-8 -*- # Authors: Olivier Grisel <olivier.grisel@ensta.org> # Mathieu Blondel <mathieu@mblondel.org> # Lars Buitinck <L.J.Buitinck@uva.nl> # Robert Layton <robertlayton@gmail.com> # Jochen Wersdörfer <jochen@wersdoerfer.de> # Roman Sinayev <roman.sinayev@gma...
apache-2.0
cbertinato/pandas
pandas/tests/frame/test_combine_concat.py
1
34741
from datetime import datetime import numpy as np import pytest import pandas as pd from pandas import DataFrame, Index, Series, Timestamp, date_range import pandas.util.testing as tm from pandas.util.testing import assert_frame_equal, assert_series_equal class TestDataFrameConcatCommon: def test_concat_multipl...
bsd-3-clause
massmutual/scikit-learn
sklearn/utils/estimator_checks.py
1
54609
from __future__ import print_function import types import warnings import sys import traceback import pickle from copy import deepcopy import numpy as np from scipy import sparse import struct from sklearn.externals.six.moves import zip from sklearn.externals.joblib import hash, Memory from sklearn.utils.testing imp...
bsd-3-clause
INM-6/python-neo
neo/io/neuralynxio_v1.py
2
105289
""" Class for reading data from Neuralynx files. This IO supports NCS, NEV and NSE file formats. This module is an older implementation with old neo.io API. A new class NeuralynxIO compunded by NeuralynxRawIO and BaseFromIO superseed this one. Depends on: numpy Supported: Read Author: Julia Sprenger, Carlos Canova...
bsd-3-clause
jarathomas/openVA-Pipeline
pipeline.py
1
49777
#-------------------------------------------------------------------------------------------------------------------------------------------# # openVA Pipeline: pipeline.py -- Software for processing Verbal Autopsy data with automated cause of death assignment. # # Copyright (C) 2018 Jason Thomas,...
gpl-3.0
PrashntS/scikit-learn
sklearn/linear_model/ridge.py
60
44642
""" Ridge regression """ # Author: Mathieu Blondel <mathieu@mblondel.org> # Reuben Fletcher-Costin <reuben.fletchercostin@gmail.com> # Fabian Pedregosa <fabian@fseoane.net> # Michael Eickenberg <michael.eickenberg@nsup.org> # License: BSD 3 clause from abc import ABCMeta, abstractmethod impor...
bsd-3-clause
dsquareindia/scikit-learn
sklearn/tests/test_cross_validation.py
79
47914
"""Test the cross_validation module""" from __future__ import division import warnings import numpy as np from scipy.sparse import coo_matrix from scipy.sparse import csr_matrix from scipy import stats from sklearn.exceptions import ConvergenceWarning from sklearn.utils.testing import assert_true from sklearn.utils.t...
bsd-3-clause
tiagofrepereira2012/tensorflow
tensorflow/contrib/learn/python/learn/estimators/dnn_linear_combined_test.py
52
69800
# 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
jstoxrocky/statsmodels
statsmodels/regression/tests/test_regression.py
6
37622
""" Test functions for models.regression """ # TODO: Test for LM from statsmodels.compat.python import long, lrange import warnings import pandas import numpy as np from numpy.testing import (assert_almost_equal, assert_approx_equal, assert_raises, assert_equal, assert_allclose) from scipy.l...
bsd-3-clause
google/rysim
python/results_analyzer/Main.py
1
119456
# Copyright 2014 The RySim 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 applicable law o...
apache-2.0
pratapvardhan/pandas
pandas/tests/test_base.py
2
46174
# -*- coding: utf-8 -*- from __future__ import print_function import re import sys from datetime import datetime, timedelta import pytest import numpy as np import pandas as pd import pandas.compat as compat from pandas.core.dtypes.common import ( is_object_dtype, is_datetimetz, is_datetime64_dtype, needs_i8_...
bsd-3-clause
rvraghav93/scikit-learn
sklearn/feature_extraction/tests/test_text.py
8
35969
from __future__ import unicode_literals import warnings from sklearn.feature_extraction.text import strip_tags from sklearn.feature_extraction.text import strip_accents_unicode from sklearn.feature_extraction.text import strip_accents_ascii from sklearn.feature_extraction.text import HashingVectorizer from sklearn.fe...
bsd-3-clause
cgalleguillosm/accasim
accasim/utils/plot_factory.py
1
51706
""" MIT License Copyright (c) 2017 cgalleguillosm, AlessioNetti Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, ...
mit
rs2/pandas
pandas/io/sql.py
1
62655
""" Collection of query wrappers / abstractions to both facilitate data retrieval and to reduce dependency on DB-specific API. """ from contextlib import contextmanager from datetime import date, datetime, time from functools import partial import re from typing import Iterator, Optional, Union, overload import warnin...
bsd-3-clause
kenshay/ImageScripter
ProgramData/SystemFiles/Python/Lib/site-packages/pandas/io/stata.py
7
82769
""" Module contains tools for processing Stata files into DataFrames The StataReader below was originally written by Joe Presbrey as part of PyDTA. It has been extended and improved by Skipper Seabold from the Statsmodels project who also developed the StataWriter and was finally added to pandas in a once again improv...
gpl-3.0
JPFrancoia/scikit-learn
sklearn/preprocessing/data.py
13
70436
# Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Mathieu Blondel <mathieu@mblondel.org> # Olivier Grisel <olivier.grisel@ensta.org> # Andreas Mueller <amueller@ais.uni-bonn.de> # Eric Martin <eric@ericmart.in> # Giorgio Patrini <giorgio.patrini@anu.edu.au> # Lic...
bsd-3-clause
nsalomonis/AltAnalyze
AltAnalyzeViewer.py
1
282646
import os.path, sys, shutil import os import string, re import subprocess import numpy as np import unique import traceback import wx import wx.lib.scrolledpanel import wx.grid as gridlib try: import warnings with warnings.catch_warnings(): warnings.filterwarnings("ignore",category=UserWarning) ...
apache-2.0
jereze/scikit-learn
sklearn/preprocessing/data.py
68
57385
# Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Mathieu Blondel <mathieu@mblondel.org> # Olivier Grisel <olivier.grisel@ensta.org> # Andreas Mueller <amueller@ais.uni-bonn.de> # Eric Martin <eric@ericmart.in> # License: BSD 3 clause from itertools import chain, combina...
bsd-3-clause
valexandersaulys/airbnb_kaggle_contest
venv/lib/python3.4/site-packages/pandas/tseries/tests/test_base.py
9
82416
from __future__ import print_function import re from datetime import datetime, timedelta import numpy as np import pandas as pd from pandas.tseries.base import DatetimeIndexOpsMixin from pandas.util.testing import assertRaisesRegexp, assertIsInstance from pandas.tseries.common import is_datetimelike from pandas import ...
gpl-2.0
timcera/hspfbintoolbox
tests/test_catalog.py
1
115314
# -*- coding: utf-8 -*- """ catalog ---------------------------------- Tests for `hspfbintoolbox` module. """ import csv import shlex import subprocess import sys from unittest import TestCase from pandas.testing import assert_frame_equal try: from cStringIO import StringIO except: from io import StringIO ...
bsd-3-clause
blaze/dask
dask/base.py
1
37839
from collections import OrderedDict from collections.abc import Mapping, Iterator from contextlib import contextmanager from functools import partial from hashlib import md5 from operator import getitem import inspect import pickle import os import threading import uuid from distutils.version import LooseVersion from ...
bsd-3-clause
LeeYiFang/Carkinos
src/probes/views.py
1
122212
from django.shortcuts import render,render_to_response from django.http import HttpResponse, Http404,JsonResponse from django.views.decorators.http import require_GET from .models import Dataset, CellLine, ProbeID, Sample, Platform, Clinical_Dataset,Clinical_sample,Gene from django.template import RequestContext from d...
mit
aetilley/scikit-learn
sklearn/datasets/samples_generator.py
45
56433
""" Generate samples of synthetic data sets. """ # Authors: B. Thirion, G. Varoquaux, A. Gramfort, V. Michel, O. Grisel, # G. Louppe, J. Nothman # License: BSD 3 clause import numbers import warnings import array import numpy as np from scipy import linalg import scipy.sparse as sp from ..preprocessing impo...
bsd-3-clause
rbooth200/DiscEvolution
DiscEvolution/internal_photo.py
1
30463
# internal_photo.py # # Author: A. Sellek # Date: 12 - Aug - 2020 # # Implementation of Photoevaporation Models ################################################################################ import numpy as np import argparse import json import matplotlib.pyplot as plt from DiscEvolution.constants import * from DiscE...
gpl-3.0
zfrenchee/pandas
doc/sphinxext/ipython_sphinxext/ipython_directive.py
1
37812
# -*- coding: utf-8 -*- """ Sphinx directive to support embedded IPython code. This directive allows pasting of entire interactive IPython sessions, prompts and all, and their code will actually get re-executed at doc build time, with all prompts renumbered sequentially. It also allows you to input code as a pure pyth...
bsd-3-clause
lamastex/scalable-data-science
db/xtraResources/edXBigDataSeries2015/CS100-1x/Module 4: Text Analysis and Entity Resolution Lab Solutions.py
2
73278
# Databricks notebook source exported at Mon, 14 Mar 2016 03:33:29 UTC # MAGIC %md # MAGIC **SOURCE:** This is from the Community Edition of databricks and has been added to this databricks shard at [/#workspace/scalable-data-science/xtraResources/edXBigDataSeries2015/CS100-1x](/#workspace/scalable-data-science/xtraRes...
unlicense
iarroyof/distributionalSemanticStabilityThesis
mklObj.py
2
55729
#!/usr/bin/env python # -*- coding: utf-8 -*- import sys __author__ = 'Ignacio Arroyo-Fernandez' from modshogun import * from tools.load import LoadMatrix from sklearn.metrics import r2_score import random from math import sqrt import numpy from os import getcwd from sys import stderr from pdb import set_trace as...
gpl-2.0
cbertinato/pandas
pandas/tests/io/test_packers.py
1
33090
import datetime from distutils.version import LooseVersion import glob from io import BytesIO import os from warnings import catch_warnings import numpy as np import pytest from pandas._libs.tslib import iNaT from pandas.errors import PerformanceWarning import pandas from pandas import ( Categorical, DataFrame, ...
bsd-3-clause
sfepy/sfepy
examples/linear_elasticity/dispersion_analysis.py
2
35004
#!/usr/bin/env python """ Dispersion analysis of a heterogeneous finite scale periodic cell. The periodic cell mesh has to contain two subdomains Y1 (with the cell ids 1), Y2 (with the cell ids 2), so that different material properties can be defined in each of the subdomains (see ``--pars`` option). The command line ...
bsd-3-clause
ky822/scikit-learn
sklearn/utils/estimator_checks.py
9
51912
from __future__ import print_function import types import warnings import sys import traceback import inspect import pickle from copy import deepcopy import numpy as np from scipy import sparse import struct from sklearn.externals.six.moves import zip from sklearn.externals.joblib import hash, Memory from sklearn.ut...
bsd-3-clause
heli522/scikit-learn
sklearn/utils/arpack.py
265
64837
""" This contains a copy of the future version of scipy.sparse.linalg.eigen.arpack.eigsh It's an upgraded wrapper of the ARPACK library which allows the use of shift-invert mode for symmetric matrices. Find a few eigenvectors and eigenvalues of a matrix. Uses ARPACK: http://www.caam.rice.edu/software/ARPACK/ """ #...
bsd-3-clause
Vvucinic/Wander
venv_2_7/lib/python2.7/site-packages/pandas/core/indexing.py
9
64500
# pylint: disable=W0223 from pandas.core.index import Index, MultiIndex from pandas.compat import range, zip import pandas.compat as compat import pandas.core.common as com from pandas.core.common import (is_bool_indexer, is_integer_dtype, _asarray_tuplesafe, is_list_like, isnull, ...
artistic-2.0
anntzer/scikit-learn
sklearn/tests/test_multiclass.py
5
32749
import numpy as np import scipy.sparse as sp import pytest from re import escape from sklearn.utils._testing import assert_array_equal from sklearn.utils._testing import assert_almost_equal from sklearn.utils._testing import ignore_warnings from sklearn.utils._mocking import CheckingClassifier from sklearn.multiclass...
bsd-3-clause
rtrwalker/geotecha
geotecha/mathematics/quadrature.py
1
74253
# geotecha - A software suite for geotechncial engineering # Copyright (C) 2018 Rohan T. Walker (rtrwalker@gmail.com) # # 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 3 of the L...
gpl-3.0
evgchz/scikit-learn
sklearn/ensemble/gradient_boosting.py
6
63474
"""Gradient Boosted Regression Trees This module contains methods for fitting gradient boosted regression trees for both classification and regression. The module structure is the following: - The ``BaseGradientBoosting`` base class implements a common ``fit`` method for all the estimators in the module. Regressio...
bsd-3-clause
rs2/pandas
pandas/tests/indexes/test_base.py
1
93051
from collections import defaultdict from datetime import datetime, timedelta from io import StringIO import math import operator import re import numpy as np import pytest import pandas._config.config as cf from pandas._libs.tslib import Timestamp from pandas.compat.numpy import np_datetime64_compat from pandas.util...
bsd-3-clause
olafhauk/mne-python
mne/utils/numerics.py
4
36095
# -*- coding: utf-8 -*- """Some utility functions.""" # Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # # License: BSD (3-clause) from contextlib import contextmanager import hashlib from io import BytesIO, StringIO from math import sqrt import numbers import operator import os import os.path as op from ma...
bsd-3-clause
cwu2011/seaborn
doc/sphinxext/ipython_directive.py
37
37557
# -*- coding: utf-8 -*- """ Sphinx directive to support embedded IPython code. This directive allows pasting of entire interactive IPython sessions, prompts and all, and their code will actually get re-executed at doc build time, with all prompts renumbered sequentially. It also allows you to input code as a pure pyth...
bsd-3-clause
jhamman/xray
xarray/tests/test_variable.py
1
54048
from __future__ import absolute_import from __future__ import division from __future__ import print_function from collections import namedtuple from copy import copy, deepcopy from datetime import datetime, timedelta from textwrap import dedent import pytest from distutils.version import LooseVersion import numpy as n...
apache-2.0
NeuralEnsemble/elephant
elephant/asset/asset.py
2
102992
# -*- coding: utf-8 -*- """ ASSET is a statistical method :cite:`asset-Torre16_e1004939` for the detection of repeating sequences of synchronous spiking events in parallel spike trains. ASSET analysis class object of finding patterns ----------------------------------------------- .. autosummary:: :toctree: _toc...
bsd-3-clause
xubenben/scikit-learn
sklearn/linear_model/ridge.py
25
39394
""" Ridge regression """ # Author: Mathieu Blondel <mathieu@mblondel.org> # Reuben Fletcher-Costin <reuben.fletchercostin@gmail.com> # Fabian Pedregosa <fabian@fseoane.net> # Michael Eickenberg <michael.eickenberg@nsup.org> # License: BSD 3 clause from abc import ABCMeta, abstractmethod impor...
bsd-3-clause
manterd/myPhyloDB
functions/analysis/spls_graphs.py
1
32640
import datetime from django.http import HttpResponse import logging import pandas as pd from pyper import * from scipy import stats import json from database.models import Kingdom, Phyla, Class, Order, Family, Genus, Species, OTU_99, \ ko_lvl1, ko_lvl2, ko_lvl3, \ nz_lvl1, nz_lvl2, nz_lvl3, nz_lvl4 import fun...
gpl-3.0
wateraccounting/SEBAL
PreSEBAL/preSEBAL.py
1
110216
# -*- coding: utf-8 -*- """ Created on Thu Sep 08 15:09:49 2016 #test Github @author: tih """ import numpy as np import os import scipy.interpolate import gdal from openpyxl import load_workbook import osr from datetime import datetime, timedelta import pandas as pd import shutil import glob from netCDF4 import Dataset...
apache-2.0
DailyActie/Surrogate-Model
01-codes/scikit-learn-master/sklearn/preprocessing/data.py
1
67256
# Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Mathieu Blondel <mathieu@mblondel.org> # Olivier Grisel <olivier.grisel@ensta.org> # Andreas Mueller <amueller@ais.uni-bonn.de> # Eric Martin <eric@ericmart.in> # Giorgio Patrini <giorgio.patrini@anu.edu.au> # Lic...
mit
ryanvarley/ExoData
exodata/astroclasses.py
1
42589
""" Contains structural classes ie binary, star, planet etc which mimic the xml structure with objects """ import sys import math from pkg_resources import resource_stream import logging import numpy as np import astropy.coordinates import astropy.units as u from . import equations as eq from . import astroquantities...
mit
vrooje/pulsar-hunters-analysis
aggregate_pulsarclass.py
1
33505
#Python 2.7.9 (default, Apr 5 2015, 22:21:35) import sys, os # file with raw classifications (csv) # put this way up here so if there are no inputs we exit quickly before even trying to load everything else try: classfile_in = sys.argv[1] except: #classfile_in = 'data/2e3d12a2-56ca-4d1f-930a-9ecc7fd39885.csv'...
mit
mbayon/TFG-MachineLearning
vbig/lib/python2.7/site-packages/pandas/tests/series/test_indexing.py
3
88164
# coding=utf-8 # pylint: disable-msg=E1101,W0612 import pytest from datetime import datetime, timedelta from numpy import nan import numpy as np import pandas as pd import pandas._libs.index as _index from pandas.core.dtypes.common import is_integer, is_scalar from pandas import (Index, Series, DataFrame, isnull, ...
mit
sergiohgz/incubator-airflow
airflow/www/views.py
2
111267
# -*- coding: utf-8 -*- # # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the #...
apache-2.0
hsaputra/tensorflow
tensorflow/contrib/learn/python/learn/learn_io/data_feeder.py
8
31357
# 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
patricksnape/menpo
menpo/image/base.py
2
131364
from typing import Iterable, Optional from warnings import warn import PIL.Image as PILImage import numpy as np from menpo.base import MenpoDeprecationWarning, Vectorizable, copy_landmarks_and_path from menpo.landmark import Landmarkable from menpo.shape import PointCloud, bounding_box from menpo.transform import ( ...
bsd-3-clause
Eric89GXL/mne-python
mne/externals/tqdm/_tqdm/std.py
14
55471
""" Customisable progressbar decorator for iterators. Includes a default (x)range iterator printing to stderr. Usage: >>> from tqdm import trange[, tqdm] >>> for i in trange(10): #same as: for i in tqdm(xrange(10)) ... ... """ from __future__ import absolute_import, division # compatibility functions and uti...
bsd-3-clause
exowanderer/Charge-Carrier-Trapping-Comparison
Charge Carrier Trapping Experiment.py
1
37127
# coding: utf-8 # # Charge Carrier Trapping Experiment # # CCT = Charge Carrier Trapping - This is a test of comparing the Zhou et al 2017 results with a data driven analysis using multinest # In[ ]: get_ipython().magic('matplotlib inline') from pylab import *;ion() from pandas import read_csv, DataFrame, concat ...
gpl-3.0
krisht/Krishna-Thesis
Research/src/BrainNet.py
1
43359
from __future__ import print_function import datetime import itertools import matplotlib import os import re os.environ["CUDA_DEVICE_ORDER"]="PCI_BUS_ID" os.environ["CUDA_VISIBLE_DEVICES"]="0,1" matplotlib.use('Agg') import matplotlib.pyplot as plt plt.rcParams["font.family"] = "FreeSerif" import numpy as np impor...
mit
tkaitchuck/nupic
external/linux64/lib/python2.6/site-packages/matplotlib/backends/backend_wx.py
69
77038
from __future__ import division """ backend_wx.py A wxPython backend for matplotlib, based (very heavily) on backend_template.py and backend_gtk.py Author: Jeremy O'Donoghue (jeremy@o-donoghue.com) Derived from original copyright work by John Hunter (jdhunter@ace.bsd.uchicago.edu) Copyright (C) Jeremy O'Don...
gpl-3.0
ScreamingUdder/mantid
scripts/HFIRPowderReduction/HfirPDReductionGUI.py
1
91448
# pylint: disable=invalid-name, relative-import, too-many-lines,too-many-instance-attributes,too-many-arguments,C901 ################################################################################ # Main class for HFIR powder reduction GUI # Key word for future developing: FUTURE, NEXT, REFACTOR, RELEASE 2.0 #########...
gpl-3.0
toobaz/pandas
pandas/core/groupby/generic.py
1
62983
""" Define the SeriesGroupBy and DataFrameGroupBy classes that hold the groupby interfaces (and some implementations). These are user facing as the result of the ``df.groupby(...)`` operations, which here returns a DataFrameGroupBy object. """ from collections import OrderedDict, abc, namedtuple import copy import fun...
bsd-3-clause
JPFrancoia/scikit-learn
sklearn/cluster/k_means_.py
4
59475
"""K-means clustering""" # Authors: Gael Varoquaux <gael.varoquaux@normalesup.org> # Thomas Rueckstiess <ruecksti@in.tum.de> # James Bergstra <james.bergstra@umontreal.ca> # Jan Schlueter <scikit-learn@jan-schlueter.de> # Nelle Varoquaux # Peter Prettenhofer <peter.prettenh...
bsd-3-clause
oknuutti/visnav-py
visnav/render/stars.py
1
34131
from datetime import datetime from functools import lru_cache import cv2 import math import os import sqlite3 import re import time import numpy as np import quaternion from visnav.algo import tools from visnav.algo.image import ImageProc from visnav.algo.model import SystemModel from visnav.missions...
mit
alsrgv/tensorflow
tensorflow/contrib/learn/python/learn/learn_io/data_feeder.py
3
32746
# 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
billy-inn/scikit-learn
sklearn/tests/test_cross_validation.py
27
41664
"""Test the cross_validation module""" from __future__ import division import warnings import numpy as np from scipy.sparse import coo_matrix from scipy import stats from sklearn.utils.testing import assert_true from sklearn.utils.testing import assert_false from sklearn.utils.testing import assert_equal from sklearn...
bsd-3-clause
ryfeus/lambda-packs
Sklearn_scipy_numpy/source/scipy/stats/morestats.py
4
94486
# Author: Travis Oliphant, 2002 # # Further updates and enhancements by many SciPy developers. # from __future__ import division, print_function, absolute_import import math import warnings from collections import namedtuple import numpy as np from numpy import (isscalar, r_, log, around, unique, asarray, ...
mit
SophieIPP/ipp-macro-series-parser
ipp_macro_series_parser/denombrements_fiscaux/agregats_ipp.py
1
36244
# -*- coding: utf-8 -*- # TAXIPP -- A French microsimulation model # By: IPP <taxipp@ipp.eu> # # Copyright (C) 2012, 2013, 2014, 2015 IPP # https://github.com/taxipp # # This file is part of TAXIPP. # # TAXIPP is free software; you can redistribute it and/or modify # it under the terms of the GNU Affero General Publi...
gpl-3.0
Titan-C/scikit-learn
sklearn/linear_model/omp.py
8
31640
"""Orthogonal matching pursuit algorithms """ # Author: Vlad Niculae # # License: BSD 3 clause import warnings import numpy as np from scipy import linalg from scipy.linalg.lapack import get_lapack_funcs from .base import LinearModel, _pre_fit from ..base import RegressorMixin from ..utils import as_float_array, ch...
bsd-3-clause
dhimmel/networkx
networkx/convert_matrix.py
13
33243
"""Functions to convert NetworkX graphs to and from numpy/scipy matrices. The preferred way of converting data to a NetworkX graph is through the graph constuctor. The constructor calls the to_networkx_graph() function which attempts to guess the input type and convert it automatically. Examples -------- Create a 10...
bsd-3-clause
aloverso/SoftwareSystems
hw04/wave3/thinkdsp.py
23
31996
"""This file contains code used in "Think DSP", by Allen B. Downey, available from greenteapress.com Copyright 2013 Allen B. Downey License: GNU GPLv3 http://www.gnu.org/licenses/gpl.html """ import array import math import numpy import random import scipy import scipy.stats import struct import subprocess import thi...
gpl-3.0
arborh/tensorflow
tensorflow/python/keras/engine/data_adapter_test.py
3
30720
# Copyright 2019 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
tswast/google-cloud-python
bigquery/tests/unit/test_job.py
1
231908
# Copyright 2015 Google LLC # # 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 writing, s...
apache-2.0
zzcclp/spark
python/pyspark/pandas/plot/core.py
11
41921
# # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not us...
apache-2.0
yanchen036/tensorflow
tensorflow/contrib/labeled_tensor/python/ops/ops.py
7
46402
# 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
ronny3050/MobileNet
retrain.py
1
56996
# Copyright 2015 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...
mit
nhejazi/scikit-learn
sklearn/linear_model/least_angle.py
6
58438
""" Least Angle Regression algorithm. See the documentation on the Generalized Linear Model for a complete discussion. """ from __future__ import print_function # Author: Fabian Pedregosa <fabian.pedregosa@inria.fr> # Alexandre Gramfort <alexandre.gramfort@inria.fr> # Gael Varoquaux # # License: BSD 3 ...
bsd-3-clause
madjelan/scikit-learn
sklearn/preprocessing/data.py
113
56747
# Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Mathieu Blondel <mathieu@mblondel.org> # Olivier Grisel <olivier.grisel@ensta.org> # Andreas Mueller <amueller@ais.uni-bonn.de> # Eric Martin <eric@ericmart.in> # License: BSD 3 clause from itertools import chain, combina...
bsd-3-clause
Carmezim/tensorflow
tensorflow/contrib/learn/python/learn/estimators/estimator.py
5
55283
# 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
josenavas/labman
labman/db/process.py
1
115578
# ---------------------------------------------------------------------------- # Copyright (c) 2017-, labman development team. # # Distributed under the terms of the Modified BSD License. # # The full license is in the file LICENSE, distributed with this software. # -----------------------------------------------------...
bsd-3-clause
mrares/incubator-airflow
airflow/www/views.py
1
97991
# -*- coding: utf-8 -*- # # 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 writing, software ...
apache-2.0
yuxiang-zhou/menpofit
menpofit/aps/base.py
2
39189
from __future__ import division import warnings import numpy as np from scipy.stats import multivariate_normal from menpo.base import name_of_callable from menpo.feature import no_op from menpo.visualize import print_dynamic, print_progress from menpo.model import GMRFModel from menpo.shape import (DirectedGraph, Undi...
bsd-3-clause
kelseyoo14/Wander
venv_2_7/lib/python2.7/site-packages/pandas/tests/test_categorical.py
9
162878
# -*- coding: utf-8 -*- # pylint: disable=E1101,E1103,W0232 from datetime import datetime from pandas.compat import range, lrange, u, PY3 import os import pickle import re from distutils.version import LooseVersion import numpy as np import pandas as pd from pandas import Categorical, Index, Series, DataFrame, Perio...
artistic-2.0
aselle/tensorflow
tensorflow/contrib/learn/python/learn/learn_io/data_feeder.py
39
32726
# 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
siutanwong/scikit-learn
sklearn/ensemble/tests/test_forest.py
48
35412
""" Testing for the forest module (sklearn.ensemble.forest). """ # Authors: Gilles Louppe, # Brian Holt, # Andreas Mueller, # Arnaud Joly # License: BSD 3 clause import pickle from collections import defaultdict from itertools import product import numpy as np from scipy.sparse import csr_...
bsd-3-clause
ryfeus/lambda-packs
Tensorflow_LightGBM_Scipy_nightly/source/numpy/linalg/linalg.py
3
82838
"""Lite version of scipy.linalg. Notes ----- This module is a lite version of the linalg.py module in SciPy which contains high-level Python interface to the LAPACK library. The lite version only accesses the following LAPACK functions: dgesv, zgesv, dgeev, zgeev, dgesdd, zgesdd, dgelsd, zgelsd, dsyevd, zheevd, dgetr...
mit
kelseyoo14/Wander
venv_2_7/lib/python2.7/site-packages/numpy/lib/polynomial.py
82
37957
""" Functions to operate on polynomials. """ from __future__ import division, absolute_import, print_function __all__ = ['poly', 'roots', 'polyint', 'polyder', 'polyadd', 'polysub', 'polymul', 'polydiv', 'polyval', 'poly1d', 'polyfit', 'RankWarning'] import re import warnings import numpy.core....
artistic-2.0
rrrrrr8/vnpy
vnpy/trader/app/ctaStrategy/ctaBacktesting.py
1
56364
# encoding: UTF-8 ''' 本文件中包含的是CTA模块的回测引擎,回测引擎的API和CTA引擎一致, 可以使用和实盘相同的代码进行回测。 ''' from __future__ import division from __future__ import print_function from datetime import datetime, timedelta from collections import OrderedDict from itertools import product import multiprocessing import copy import pymongo import pa...
mit
tomasreimers/tensorflow-emscripten
tensorflow/contrib/learn/python/learn/estimators/estimator.py
5
55320
# 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
fegonda/icon_demo
code/model/unet/g.py
1
44565
import os import sys import skimage.transform import skimage.exposure import time import glob import numpy as np import mahotas import random import matplotlib import matplotlib.pyplot as plt import scipy import scipy.ndimage import json from scipy.ndimage.filters import maximum_filter base_path = os.path.dirname(__fi...
mit
lhilt/scipy
scipy/interpolate/interpolate.py
4
97600
from __future__ import division, print_function, absolute_import __all__ = ['interp1d', 'interp2d', 'lagrange', 'PPoly', 'BPoly', 'NdPPoly', 'RegularGridInterpolator', 'interpn'] import itertools import warnings import functools import operator import numpy as np from numpy import (array, transpose, searc...
bsd-3-clause
aminert/scikit-learn
sklearn/preprocessing/tests/test_data.py
113
38432
import warnings import numpy as np import numpy.linalg as la from scipy import sparse from distutils.version import LooseVersion from sklearn.utils.testing import assert_almost_equal, clean_warning_registry from sklearn.utils.testing import assert_array_almost_equal from sklearn.utils.testing import assert_array_equal...
bsd-3-clause
chengsoonong/acton
acton/database.py
1
72157
"""Wrapper class for databases.""" from abc import ABC, abstractmethod from inspect import Traceback import json import logging import os.path import tempfile from typing import Iterable, List, Sequence import warnings import time from acton.proto.acton_pb2 import Database as DatabasePB import astropy.io.ascii as io_...
bsd-3-clause
pv/scikit-learn
sklearn/tests/test_cross_validation.py
70
41943
"""Test the cross_validation module""" from __future__ import division import warnings import numpy as np from scipy.sparse import coo_matrix from scipy import stats from sklearn.utils.testing import assert_true from sklearn.utils.testing import assert_false from sklearn.utils.testing import assert_equal from sklearn...
bsd-3-clause
mwickert/SP-Comm-Tutorial-using-scikit-dsp-comm
hardware_configure/sigsys.py
1
81778
""" Signals and Systems Function Module Copyright (c) March 2017, Mark Wickert All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, ...
bsd-2-clause
shikhar413/openmc
openmc/filter.py
6
63054
from abc import ABCMeta from collections import OrderedDict from collections.abc import Iterable import hashlib from itertools import product from numbers import Real, Integral from xml.etree import ElementTree as ET import numpy as np import pandas as pd import openmc import openmc.checkvalue as cv from .cell import...
mit
Gabriel-p/mcs_rot_angles
aux_modules/MCs_plane.py
1
38946
import numpy as np from astropy.coordinates import Distance, Angle, SkyCoord from astropy import units as u import numpy.linalg as la import matplotlib.pyplot as plt from mpl_toolkits.mplot3d import Axes3D # Define main path. import os import sys r_path = os.path.realpath(__file__)[:-24] # print r_path sys.path.insert...
gpl-3.0
rkmaddox/mne-python
tutorials/preprocessing/25_background_filtering.py
3
48286
# -*- coding: utf-8 -*- r""" .. _disc-filtering: =================================== Background information on filtering =================================== Here we give some background information on filtering in general, and how it is done in MNE-Python in particular. Recommended reading for practical applications ...
bsd-3-clause