repo_name string | path string | copies string | size string | content string | license string |
|---|---|---|---|---|---|
bmazin/SDR | Setup/lib/iqsweep.py | 1 | 37697 | #!/usr/bin/env python
# encoding: utf-8
"""
iqsweep.py
Created by Ben Mazin on 2011-03-24.
Copyright (c) 2011 . All rights reserved.
"""
from tables import *
import numpy as np
import os
import sys
import matplotlib
import matplotlib.pyplot as plt
from matplotlib.backends.backend_pdf import PdfPages
import time
impor... | gpl-2.0 |
winklerand/pandas | pandas/core/ops.py | 1 | 55452 | """
Arithmetic operations for PandasObjects
This is not a public API.
"""
# necessary to enforce truediv in Python 2.X
from __future__ import division
import operator
import warnings
import numpy as np
import pandas as pd
import datetime
from pandas._libs import (lib, index as libindex,
tsli... | bsd-3-clause |
timothyb0912/pylogit | tests/test_choice_calcs.py | 1 | 75667 | """
Tests for the choice_calcs.py file.
"""
import unittest
import warnings
from collections import OrderedDict
import numpy as np
import numpy.testing as npt
import pandas as pd
from scipy.sparse import csr_matrix
from scipy.sparse import diags
from scipy.sparse import block_diag
import pylogit.asym_logit as asym
im... | bsd-3-clause |
fsimkovic/conkit | conkit/core/tests/test_contactmap.py | 1 | 53060 | """Testing facility for conkit.core.ContactMap"""
__author__ = "Felix Simkovic"
__date__ = "12 Aug 2016"
import unittest
try:
import sklearn.neighbors
SKLEARN = True
except ImportError:
SKLEARN = False
from conkit.core.struct import Gap, Residue
from conkit.core.contact import Contact
from conkit.core.c... | bsd-3-clause |
synthicity/orca | orca/tests/test_orca.py | 1 | 34173 | # Orca
# Copyright (C) 2016 UrbanSim Inc.
# See full license in LICENSE.
import os
import tempfile
import pandas as pd
import pandas.testing as pdt
import pytest
from .. import orca
from ..utils.testing import assert_frames_equal
def setup_function(func):
orca.clear_all()
orca.enable_cache()
def teardown... | bsd-3-clause |
boomsbloom/dtm-fmri | DTM/for_gensim/lib/python2.7/site-packages/matplotlib/ticker.py | 1 | 62923 | """
Tick locating and formatting
============================
This module contains classes to support completely configurable tick locating
and formatting. Although the locators know nothing about major or minor
ticks, they are used by the Axis class to support major and minor tick
locating and formatting. Generic t... | mit |
DonBeo/statsmodels | statsmodels/regression/tests/test_robustcov.py | 1 | 31412 | # -*- coding: utf-8 -*-
"""Testing OLS robust covariance matrices against STATA
Created on Mon Oct 28 15:25:14 2013
Author: Josef Perktold
"""
import numpy as np
from scipy import stats
from numpy.testing import (assert_allclose, assert_equal, assert_warns,
assert_raises)
from statsmode... | bsd-3-clause |
Gyscos/CMANes | plotcmaesdat.py | 1 | 178359 | #!/usr/bin/env python2.7
"""module cma implements the CMA-ES, Covariance Matrix Adaptation Evolution Strategy,
a stochastic optimizer for robust non-linear non-convex function minimization,
function cma.plotdata() plots data generated, for example, from the Java CMA-ES
code. Example in the python shell (package m... | lgpl-3.0 |
alexandrebarachant/mne-python | mne/dipole.py | 2 | 41062 | # Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr>
# Eric Larson <larson.eric.d@gmail.com>
#
# License: Simplified BSD
from copy import deepcopy
import re
import numpy as np
from scipy import linalg
from .cov import read_cov, _get_whitener_data
from .io.constants import FIFF
from .io.pi... | bsd-3-clause |
jmd-dk/concept | concept/commons.py | 1 | 194794 | # This file is part of CO𝘕CEPT, the cosmological 𝘕-body code in Python.
# Copyright © 2015–2021 Jeppe Mosgaard Dakin.
#
# CO𝘕CEPT 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 Lice... | gpl-3.0 |
petercable/xray | xray/test/test_variable.py | 1 | 37734 | from collections import namedtuple
from copy import copy, deepcopy
from datetime import datetime, timedelta
from textwrap import dedent
from distutils.version import LooseVersion
import numpy as np
import pandas as pd
from xray import Variable, Dataset, DataArray
from xray.core import indexing
from xray.core.variable... | apache-2.0 |
brsaylor/TuneScope | tunescope/visualization/colormaps.py | 1 | 50038 | # 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... | gpl-3.0 |
dssg/education-college-public | code/modeling/features/all_features.py | 1 | 63242 | from modeling.featurepipeline.abstractfeature import *
from modeling.featurepipeline.abstractboundedfeature import *
from modeling.featurepipeline.abstractpandasfeature import *
from modeling.featurepipeline.abstractboundedpandasfeature import *
from modeling.featurepipeline.abstracttargetfeature import *
from datetime... | mit |
GuessWhoSamFoo/pandas | pandas/tests/io/test_stata.py | 2 | 69850 | # -*- coding: utf-8 -*-
# pylint: disable=E1101
from collections import OrderedDict
import datetime as dt
from datetime import datetime
import gzip
import io
import os
import struct
import warnings
import numpy as np
import pytest
import pandas.compat as compat
from pandas.compat import PY3, ResourceWarning, iterkey... | bsd-3-clause |
tturowski/gwide | gwide/Classes/gwidePlot_class.py | 1 | 60727 | #!/usr/bin/env python
import numpy as np
import sys, collections, re
from pypeaks import Data
import pandas as pd
from pyCRAC.Parsers import GTF2
import matplotlib.pyplot as plt
import matplotlib
import plotly.plotly as py
import plotly.graph_objs as go
import scipy.stats.morestats as ss
import scipy.stats.stats as ss... | apache-2.0 |
CNR-Engineering/TelTools | pyteltools/workflow/nodes_vis.py | 2 | 62836 | from itertools import cycle, islice
import numpy as np
import matplotlib.pyplot as plt
from matplotlib import cm
import matplotlib.tri as mtri
from mpl_toolkits.axes_grid1 import make_axes_locatable
from PyQt5.QtWidgets import (QAction, QDialog, QMessageBox, QStyle)
from pyteltools.conf import settings
from pyteltools... | gpl-3.0 |
plotly/plotly.py | packages/python/plotly/plotly/graph_objs/_icicle.py | 1 | 80739 | from plotly.basedatatypes import BaseTraceType as _BaseTraceType
import copy as _copy
class Icicle(_BaseTraceType):
# class properties
# --------------------
_parent_path_str = ""
_path_str = "icicle"
_valid_props = {
"branchvalues",
"count",
"customdata",
"customd... | mit |
jamestwebber/scipy | scipy/special/add_newdocs.py | 1 | 225603 | # Docstrings for generated ufuncs
#
# The syntax is designed to look like the function add_newdoc is being
# called from numpy.lib, but in this file add_newdoc puts the
# docstrings in a dictionary. This dictionary is used in
# _generate_pyx.py to generate the docstrings for the ufuncs in
# scipy.special at the C level... | bsd-3-clause |
cuemacro/finmarketpy | finmarketpy/backtest/backtestengine.py | 1 | 99841 | __author__ = 'saeedamen'
#
# Copyright 2016 Cuemacro
#
# 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 ... | apache-2.0 |
petroniocandido/pyFTS | pyFTS/benchmarks/benchmarks.py | 1 | 68505 | #!/usr/bin/python
# -*- coding: utf8 -*-
"""Benchmarks methods for FTS methods"""
import datetime
import time
from copy import deepcopy
import traceback
import matplotlib as plt
import matplotlib.pyplot as plt
import numpy as np
from mpl_toolkits.mplot3d import Axes3D
from itertools import product
from pyFTS.comm... | gpl-3.0 |
pvlib/pvlib-python | pvlib/pvsystem.py | 1 | 116166 | """
The ``pvsystem`` module contains functions for modeling the output and
performance of PV modules and inverters.
"""
from collections import OrderedDict
import functools
import io
import itertools
import os
from urllib.request import urlopen
import numpy as np
import pandas as pd
from pvlib._deprecation import dep... | bsd-3-clause |
sahilTakiar/spark | python/pyspark/sql/functions.py | 1 | 110821 | #
# 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 |
madmax983/h2o-3 | h2o-py/h2o/frame.py | 1 | 70908 | # -*- coding: utf-8 -*-
# import numpy no numpy cuz windoz
import collections, csv, itertools, os, re, tempfile, urllib2, sys, urllib,imp,copy, tabulate
import h2o
from expr import ExprNode
from astfun import _bytecode_decompile_lambda
from group_by import GroupBy
# TODO: Automatically convert column names into Fr... | apache-2.0 |
scenarios/tensorflow | tensorflow/contrib/learn/python/learn/estimators/estimator_test.py | 1 | 42886 | # 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 |
bmanubay/open-forcefield-tools | single-molecule-property-generation/sample_posterior.py | 1 | 110225 | # -*- coding: utf-8 -*-
"""
Created on Tue Feb 14 16:09:09 2017
@author: Bryce Manubay
"""
"""
This script represents prototyping for constructing posterior distributions
across parameter space given some initial set of data.
Author: Bryce Manubay
"""
import matplotlib as mpl
mpl.use('Agg')
fr... | mit |
sergej-C/dl_utils | preprocessing.py | 1 | 30616 | import numpy as np
import PIL.Image
import PIL.ImageOps
from skimage import data, color, io, img_as_float
import PIL.ImageFilter as ImageFilter
from PIL import ImageEnhance
import matplotlib.pyplot as plt
from skimage import img_as_ubyte
from glob import glob
import cv2
from skimage import morphology
from skimage impo... | mit |
zfrenchee/pandas | pandas/core/reshape/merge.py | 1 | 61412 | """
SQL-style merge routines
"""
import copy
import warnings
import string
import numpy as np
from pandas.compat import range, lzip, zip, map, filter
import pandas.compat as compat
from pandas import (Categorical, Series, DataFrame,
Index, MultiIndex, Timedelta)
from pandas.core.frame import _mer... | bsd-3-clause |
mmottahedi/neuralnilm_prototype | scripts/e93.py | 2 | 36320 | from __future__ import print_function, division
import matplotlib
matplotlib.use('Agg') # Must be before importing matplotlib.pyplot or pylab!
from neuralnilm import Net, RealApplianceSource, BLSTMLayer, SubsampleLayer, DimshuffleLayer
from lasagne.nonlinearities import sigmoid, rectify
from lasagne.objectives import c... | mit |
anderspitman/scikit-bio | skbio/sequence/_sequence.py | 1 | 72981 | # ----------------------------------------------------------------------------
# Copyright (c) 2013--, scikit-bio development team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file COPYING.txt, distributed with this software.
# --------------------------------------------... | bsd-3-clause |
ajenhl/tacl | tacl/results.py | 1 | 49095 | """Module containing the Results class."""
import csv
import logging
import os
import re
import tempfile
import pandas as pd
from . import constants
from .decorators import requires_columns
from .exceptions import MalformedResultsError
from .text import FilteredWitnessText, Text
DELETE_FIELDNAME = 'delete'
class... | gpl-3.0 |
stverhae/incubator-airflow | airflow/www/views.py | 1 | 94361 | # -*- 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 |
kseetharam/genPolaron | pf_dynamic_sph.py | 1 | 39955 | import numpy as np
import pandas as pd
import xarray as xr
from scipy.integrate import quad
from timeit import default_timer as timer
import os
from scipy import interpolate
import Grid
# ---- HELPER FUNCTIONS ----
def kcos_func(kgrid):
#
names = list(kgrid.arrays.keys())
functions_kcos = [lambda k: k, ... | mit |
alphaBenj/zipline | tests/test_algorithm.py | 1 | 175570 | #
# Copyright 2014 Quantopian, Inc.
#
# 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 wr... | apache-2.0 |
qkitgroup/qkit | qkit/drivers/IQ_Mixer.py | 1 | 40169 | # Toolset for calibrating and using IQ-Mixers as Single-Sideband-Mixers (SSB)
# Started by Andre Schneider 01/2015 <andre.schneider@student.kit.edu>
import qkit
from qkit.core.instrument_base import Instrument
import time
import types
import logging
import os
import numpy as np
if qkit.module_available("matp... | gpl-2.0 |
pratapvardhan/pandas | pandas/core/dtypes/common.py | 1 | 52444 | """ common type operations """
import numpy as np
from pandas.compat import (string_types, text_type, binary_type,
PY3, PY36)
from pandas._libs import algos, lib
from pandas._libs.tslibs import conversion
from pandas.core.dtypes.dtypes import (
registry, CategoricalDtype, CategoricalDty... | bsd-3-clause |
kevin-intel/scikit-learn | sklearn/cluster/_kmeans.py | 2 | 74849 | """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.pretten... | bsd-3-clause |
bert9bert/statsmodels | statsmodels/tsa/statespace/tests/test_representation.py | 2 | 43812 | """
Tests for python wrapper of state space representation and filtering
Author: Chad Fulton
License: Simplified-BSD
References
----------
Kim, Chang-Jin, and Charles R. Nelson. 1999.
"State-Space Models with Regime Switching:
Classical and Gibbs-Sampling Approaches with Applications".
MIT Press Books. The MIT Press... | bsd-3-clause |
BoPeng/simuPOP | src/demography.py | 1 | 97830 | #!/usr/bin/env python
#
# $File: utils.py $
# $LastChangedDate: 2014-02-05 14:38:36 -0600 (Wed, 05 Feb 2014) $
# $Rev: 4792 $
#
# This file is part of simuPOP, a forward-time population genetics
# simulation environment. Please visit http://simupop.sourceforge.net
# for details.
#
# Copyright (C) 2004 - 2010 Bo Peng (... | gpl-2.0 |
hydraplatform/hydra-base | hydra_base/db/model.py | 1 | 96195 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# (c) Copyright 2013 to 2017 University of Manchester
#
# HydraPlatform is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation, either version 3 of the License, or... | lgpl-3.0 |
louispotok/pandas | pandas/tests/frame/test_axis_select_reindex.py | 1 | 44322 | # -*- coding: utf-8 -*-
from __future__ import print_function
import pytest
from datetime import datetime
from numpy import random
import numpy as np
from pandas.compat import lrange, lzip, u
from pandas import (compat, DataFrame, Series, Index, MultiIndex,
date_range, isna)
import pandas as pd... | bsd-3-clause |
chrsrds/scikit-learn | sklearn/metrics/tests/test_classification.py | 1 | 82355 |
from functools import partial
from itertools import product
import warnings
import numpy as np
from scipy import linalg
import pytest
from sklearn import datasets
from sklearn import svm
from sklearn.datasets import make_multilabel_classification
from sklearn.preprocessing import label_binarize, LabelBinarizer
from... | bsd-3-clause |
NirBenTalLab/proorigami-cde-package | cde-root/usr/lib64/python2.4/site-packages/numpy/lib/io.py | 2 | 53226 | __all__ = ['savetxt', 'loadtxt',
'genfromtxt', 'ndfromtxt', 'mafromtxt', 'recfromtxt', 'recfromcsv',
'load', 'loads',
'save', 'savez',
'packbits', 'unpackbits',
'fromregex',
'DataSource']
import numpy as np
import format
import cStringIO
import os
impor... | mit |
dimkal/mne-python | mne/io/base.py | 1 | 91104 | # Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr>
# Matti Hamalainen <msh@nmr.mgh.harvard.edu>
# Martin Luessi <mluessi@nmr.mgh.harvard.edu>
# Denis Engemann <denis.engemann@gmail.com>
# Teon Brooks <teon.brooks@gmail.com>
# Marijn van Vliet <w.m.vanvli... | bsd-3-clause |
flimao/racecar | racecar/racecar.py | 1 | 37060 | #!/usr/env/python3
# -*- coding: utf-8 -*-
import csv
import pint
from pint.errors import DimensionalityError
import matplotlib.pyplot as plt
import numpy as np
import re
from scipy.optimize import fsolve
import sympy as sp
import racecar.series as Series
from . import u, airdensity
# define acceleration in G
u.def... | gpl-3.0 |
quantopian/zipline | zipline/pipeline/loaders/blaze/core.py | 1 | 38712 | """
Blaze integration with the Pipeline API.
For an overview of the blaze project, see blaze.pydata.org
The blaze loader for the Pipeline API is designed to allow us to load
data from arbitrary sources as long as we can execute the needed expressions
against the data with blaze.
Data Format
-----------
The blaze Pi... | apache-2.0 |
socialsensor/community-evolution-analysis | python/CommunityRanking_NONadaptive.py | 1 | 48145 | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
#-------------------------------------------------------------------------------
# Name:
# Purpose: This .py file extracts adjacency lists and detects communities
# from the corresponding timeslots.
#
# Required libs: python-dateutil,pyparsing,numpy,ma... | apache-2.0 |
shoyer/xarray | xarray/tests/test_plot.py | 1 | 83636 | import inspect
from copy import deepcopy
from datetime import datetime
import numpy as np
import pandas as pd
import pytest
import xarray as xr
import xarray.plot as xplt
from xarray import DataArray, Dataset
from xarray.plot.dataset_plot import _infer_meta_data
from xarray.plot.plot import _infer_interval_breaks
fro... | apache-2.0 |
pjryan126/solid-start-careers | store/api/zillow/venv/lib/python2.7/site-packages/pandas/tests/test_base.py | 1 | 38533 | # -*- coding: utf-8 -*-
from __future__ import print_function
import re
import sys
from datetime import datetime, timedelta
import numpy as np
import pandas as pd
import pandas.compat as compat
import pandas.core.common as com
import pandas.util.testing as tm
from pandas import (Series, Index, DatetimeIndex, Timedel... | gpl-2.0 |
McDermott-Group/LabRAD | LabRAD/TestScripts/fpgaTest/fpgaTest.py | 1 | 67873 | # Author: Daniel Sank
# Created: 2010
# CHANGELOG
#
# 2012 Sep 26 - Jim Wenner
# Added documentation. Added adcAmpToVoltage, dacAmpToAdcAmp, dacAmpToVoltage to calibrate
# adc/dac wrt Volts. Code debugging.
#
# 2011 Feb 10 - Daniel Sank
# Added the instructions
# + STARTUP INSTRUCTIONS
# In order to use fpgaTest.py f... | gpl-2.0 |
goldmedal/spark | python/pyspark/sql/tests/test_dataframe.py | 1 | 38382 | #
# 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 |
yanlinqian/CS190.1X | ML_lab3_linear_reg_student.py | 1 | 45076 |
# coding: utf-8
# 
# # **Linear Regression Lab**
# #### This lab covers a common supervised learning pipeline, using a subset of the [Million Song Dataset](http://labrosa.ee.columbia.edu/millionsong/) from the [UCI Machine Learning Repos... | mit |
philouc/pyhrf | python/pyhrf/sandbox/parcellation.py | 1 | 63707 | import numpy as np
import numpy.testing as npt
import pyhrf
from pyhrf.graph import graph_from_lattice
from pyhrf.tools import add_prefix
def b():
""" for debug """
raise Exception()
### modified hierachical.py from scikit learn
"""Hierarchical Agglomerative Clustering
These routines perform some hierac... | gpl-3.0 |
gfyoung/scipy | scipy/optimize/zeros.py | 1 | 30196 | from __future__ import division, print_function, absolute_import
import warnings
from collections import namedtuple
from . import _zeros
import numpy as np
_iter = 100
_xtol = 2e-12
_rtol = 4 * np.finfo(float).eps
__all__ = ['newton', 'bisect', 'ridder', 'brentq', 'brenth', 'RootResults']
CONVERGED = 'converged'
SI... | bsd-3-clause |
gengliangwang/spark | python/pyspark/pandas/plot/matplotlib.py | 1 | 30173 | #
# 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 |
ruymanengithub/vison | vison/point/PointTask.py | 1 | 35174 | #!/usr/bin/env python2
# -*- coding: utf-8 -*-
"""
Created on Wed Dec 6 15:55:00 2017
:author: Ruyman Azzollini
"""
# IMPORT STUFF
import copy
from pdb import set_trace as stop
import numpy as np
import os
from collections import OrderedDict
import pandas as pd
import string as st
from vison.datamodel import comp... | gpl-3.0 |
xccui/flink | flink-python/pyflink/table/table.py | 1 | 48985 | ################################################################################
# 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... | apache-2.0 |
CalebBell/thermo | thermo/eos_mix.py | 1 | 422603 | # -*- coding: utf-8 -*-
'''Chemical Engineering Design Library (ChEDL). Utilities for process modeling.
Copyright (C) 2016, 2017, 2018, 2019, 2020, 2021
Caleb Bell <Caleb.Andrew.Bell@gmail.com>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation fi... | mit |
kyleabeauchamp/mdtraj | mdtraj/core/trajectory.py | 1 | 61694 | ##############################################################################
# MDTraj: A Python Library for Loading, Saving, and Manipulating
# Molecular Dynamics Trajectories.
# Copyright 2012-2014 Stanford University and the Authors
#
# Authors: Robert McGibbon
# Contributors: Kyle A. Beauchamp, TJ Lane, Jo... | lgpl-2.1 |
yuxiaobu/nansat | domain.py | 1 | 46385 | # Name: domain.py
# Purpose: Container of Domain class
# Authors: Asuka Yamakawa, Anton Korosov, Knut-Frode Dagestad,
# Morten W. Hansen, Alexander Myasoyedov,
# Dmitry Petrenko, Evgeny Morozov
# Created: 29.06.2011
# Copyright: (c) NERSC 2011 - 2013
# Licence:
# This... | gpl-3.0 |
hajicj/safire | build/lib/safire/utils/transformers.py | 1 | 35769 | # !/usr/bin/env python
"""
``transformers.py`` is a library that contains various non-NNET SAFIRE
transformer components, mainly used for miscellaneous preprocessing (scaling,
normalization, sigmoid nonlinearity, etc.).
"""
import collections
import itertools
import logging
import operator
import copy
import gensim
fr... | gpl-3.0 |
ptkool/spark | python/pyspark/sql/tests/test_pandas_udf_scalar.py | 1 | 52137 | #
# 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 |
kambysese/mne-python | mne/preprocessing/tests/test_ica.py | 3 | 59318 | # Author: Denis Engemann <denis.engemann@gmail.com>
# Alexandre Gramfort <alexandre.gramfort@inria.fr>
#
# License: BSD (3-clause)
from itertools import product
import os
import os.path as op
import shutil
from unittest import SkipTest
import pytest
import numpy as np
from numpy.testing import (assert_array_a... | bsd-3-clause |
louispotok/pandas | pandas/core/indexes/period.py | 1 | 44775 | # pylint: disable=E1101,E1103,W0232
from datetime import datetime, timedelta
import numpy as np
import warnings
from pandas.core import common as com
from pandas.core.dtypes.common import (
is_integer,
is_float,
is_integer_dtype,
is_float_dtype,
is_scalar,
is_datetime64_dtype,
is_datetime64... | bsd-3-clause |
tanghaibao/jcvi | jcvi/formats/blast.py | 1 | 41254 | """
parses tabular BLAST -m8 (-format 6 in BLAST+) format
"""
import os.path as op
import sys
import logging
from itertools import groupby
from collections import defaultdict
from jcvi.formats.base import LineFile, BaseFile, must_open
from jcvi.formats.bed import Bed
from jcvi.formats.sizes import Sizes
from jcvi.ut... | bsd-2-clause |
dagbldr/dagbldr | dagbldr/datasets/audio_utils/audio_tools.py | 2 | 82153 | # License: BSD 3-clause
# Authors: Kyle Kastner
import numpy as np
# Do numpy version check for <= 1.9 ! Something crazy going on in 1.10
if int(np.__version__.split(".")[1]) >= 10:
print("Only numpy <= 1.9 currently supported! There is a "
"numerical error in one of the numpy 1.10 routines. "
... | bsd-3-clause |
rlpy/rlpy | rlpy/Tools/GeneralTools.py | 1 | 41049 | """General Tools for use throughout RLPy"""
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
from __future__ import absolute_import
from builtins import int
from builtins import round
from builtins import dict
from future import standard_library
standard_li... | bsd-3-clause |
SlashDK/PennApps-XIV | ChristiansPythonLib/matplotlibUtil.py | 1 | 44939 |
"""
@package matplotlibUtil A module for creating beautiful graphs
@copyright GNU Public License
@author written 2013, 2014 by Christian Herbst (www.christian-herbst.org)
@author Sponsored by the Dept. of Cognitive Biology, University of Vienna,
@note
This program is free software; you can redistribute it and/or... | gpl-3.0 |
Ecotrust/forestplanner | lot/trees/plots.py | 1 | 71457 | from trees.utils import angular_diff
import numpy as np
from scipy.spatial import KDTree
import math
import pandas as pd
from django.db import connection
from django.core.cache import cache
from madrona.common.utils import get_logger
logger = get_logger()
def dictfetchall(cursor, classname=None):
"""Returns all ro... | bsd-3-clause |
yutiansut/QUANTAXIS | QUANTAXIS/QAFactor/fetcher.py | 2 | 42360 | # /usr/bin/env python3
"""
网络查询接口:
1. 个股查询
- QA_fetch_get_individual_financial: 查询个股指定时间段指定财务报表指定报告类型数据
2. 截面查询
- QA_fetch_get_crosssection_financial: 查询指定报告期指定报表指定报告类型数据
本地查询接口:
1. 截面查询
- QA_fetch_crosssection_financial
2. 高级查询
- QA_fetch_financial_adv
"""
import datetime
import time
from typing impor... | mit |
nmayorov/scikit-learn | sklearn/metrics/tests/test_common.py | 1 | 41341 | from __future__ import division, print_function
from functools import partial
from itertools import product
import numpy as np
import scipy.sparse as sp
from sklearn.datasets import make_multilabel_classification
from sklearn.preprocessing import LabelBinarizer
from sklearn.utils.multiclass import type_of_target
fro... | bsd-3-clause |
ctheissen/LoKi | loki/loki.py | 1 | 34504 |
# -*- coding: utf-8 -*-
"""
LoKi (Low-mass Kinematics): A galactic model for simulating low-mass stellar populations.
Based off the model used for the SLoWPoKES sample (Dhital et al. 2010)
"""
# Import needed packages and functions
from __future__ import (absolute_import, division,
print_func... | mit |
chrishales/polcalerrsims | lin.py | 1 | 30229 | # Christopher A. Hales
# 22 June 2017
# Version 1.0
#
#
# This code is released under a BSD 3-Clause License
# See LICENSE for details
#
# This code was used to obtain the results shown in arXiv:1706.06612
# and EVLA Memo 201 / ALMA Memo 603.
#
#
# This code will plot spurious full-array on-axis linear polarization
# (... | bsd-3-clause |
jakereps/q2-feature-table | q2_feature_table/tests/filter/test_filter_samples.py | 2 | 35617 | # ----------------------------------------------------------------------------
# Copyright (c) 2016-2021, QIIME 2 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 |
VNGResearch/doc2vec | main.py | 1 | 33261 | from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import warnings
from sklearn.model_selection import GridSearchCV
from sklearn.pipeline import Pipeline
from sklearn.base import BaseEstimator
from sklearn.manifold import TSNE
import matplotlib.pyplot as plt
i... | apache-2.0 |
Quantipy/quantipy | quantipy/core/dataset.py | 1 | 295741 | #!/usr/bin/python
# -*- coding: utf-8 -*-
import numpy as np
import pandas as pd
import quantipy as qp
from quantipy.core.tools.dp.io import (
read_quantipy as r_quantipy,
read_dimensions as r_dimensions,
read_decipher as r_decipher,
read_spss as r_spss,
read_ascribe as r_ascribe,
write_spss as... | mit |
alephu5/Soundbyte | environment/lib/python3.3/site-packages/matplotlib/mathtext.py | 1 | 110713 | r"""
:mod:`~matplotlib.mathtext` is a module for parsing a subset of the
TeX math syntax and drawing them to a matplotlib backend.
For a tutorial of its usage see :ref:`mathtext-tutorial`. This
document is primarily concerned with implementation details.
The module uses pyparsing_ to parse the TeX expression.
.. _p... | gpl-3.0 |
person142/scipy | scipy/optimize/_lsq/least_squares.py | 2 | 38353 | """Generic interface for least-squares minimization."""
from warnings import warn
import numpy as np
from numpy.linalg import norm
from scipy.sparse import issparse, csr_matrix
from scipy.sparse.linalg import LinearOperator
from scipy.optimize import _minpack, OptimizeResult
from scipy.optimize._numdiff import approx... | bsd-3-clause |
DailyActie/Surrogate-Model | 01-codes/scikit-learn-master/doc/sphinxext/gen_rst.py | 1 | 40232 | """
Example generation for the scikit learn
Generate the rst files for the examples by iterating over the python
example files.
Files that generate images should start with 'plot'
"""
from __future__ import division, print_function
import ast
import glob
import gzip
import os
import posixpath
import re
import shuti... | mit |
zohannn/motion_manager | scripts/old/task_2_reaching/var_2/training_task_2_var_2_10k.py | 1 | 299717 | #!/usr/bin/env python3
import sys
import pandas as pd
import sklearn
from sklearn import decomposition
from IPython import display
import seaborn as sns
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
# sklearn
from sklearn.cluster import KMeans
from sklearn import metrics
from sklearn impo... | mit |
mfouesneau/pyphot | pyphot/sandbox.py | 1 | 55913 | """
Sandbox of new developments
Use at your own risks
Photometric package using Astropy Units
=======================================
Defines a Filter class and associated functions to extract photometry.
This also include functions to keep libraries up to date
.. note::
integrations are done using :func:`tra... | mit |
synthicity/activitysim | activitysim/abm/tables/shadow_pricing.py | 2 | 33307 | # ActivitySim
# See full license in LICENSE.txt.
from __future__ import (absolute_import, division, print_function, )
from future.standard_library import install_aliases
install_aliases() # noqa: E402
from future.utils import iteritems
import logging
import time
import multiprocessing
import ctypes
from collection... | agpl-3.0 |
willgrass/pandas | pandas/stats/ols.py | 1 | 36041 | """
Ordinary least squares regression
"""
# pylint: disable-msg=W0201
from itertools import izip, starmap
from StringIO import StringIO
import numpy as np
from pandas.core.api import DataFrame, DataMatrix, Series
from pandas.core.panel import WidePanel
from pandas.util.decorators import cache_readonly
... | bsd-3-clause |
BiaDarkia/scikit-learn | sklearn/gaussian_process/gpc.py | 7 | 32306 | """Gaussian processes classification."""
# Authors: Jan Hendrik Metzen <jhm@informatik.uni-bremen.de>
#
# License: BSD 3 clause
import warnings
from operator import itemgetter
import numpy as np
from scipy.linalg import cholesky, cho_solve, solve
from scipy.optimize import fmin_l_bfgs_b
from scipy.special import erf... | bsd-3-clause |
CGATOxford/CGATPipelines | CGATPipelines/pipeline_windows.py | 1 | 82564 | """===================================================
pipeline_windows - Window based genomic analysis
===================================================
This pipeline takes mapped reads from ChIP-Seq experiments
such has chromatin marks, MeDIP and performs analyses
of the genomic read distribution. This contrasts w... | mit |
david-hoffman/dphutils | __init__.py | 1 | 41928 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# dphutils.py
"""
This is for small utility functions that don't have a proper home yet
Copyright (c) 2016, David Hoffman
"""
import subprocess
import numpy as np
import scipy as sp
import re
import io
import os
import requests
import tifffile as tif
from scipy.fftpack.he... | apache-2.0 |
ros-planning/moveit | moveit_ros/benchmarks/scripts/moveit_benchmark_statistics.py | 1 | 30551 | #!/usr/bin/env python
######################################################################
# Software License Agreement (BSD License)
#
# Copyright (c) 2010, Rice University
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that t... | bsd-3-clause |
vortex-ape/scikit-learn | sklearn/preprocessing/tests/test_data.py | 4 | 86765 | # Authors:
#
# Giorgio Patrini
#
# License: BSD 3 clause
from __future__ import division
import warnings
import re
import itertools
import numpy as np
import numpy.linalg as la
from scipy import sparse, stats
from distutils.version import LooseVersion
import pytest
from sklearn.utils import gen_batches
fro... | bsd-3-clause |
PyCQA/isort | tests/unit/test_isort.py | 1 | 173926 | """Tests all major functionality of the isort library
Should be ran using py.test by simply running py.test in the isort project directory
"""
import os
import os.path
from pathlib import Path
import subprocess
import sys
from io import StringIO
from tempfile import NamedTemporaryFile
from typing import Any, Dict, Ite... | mit |
effigies/mne-python | mne/channels/layout.py | 1 | 32335 | # Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr>
# Denis Engemann <denis.engemann@gmail.com>
# Martin Luessi <mluessi@nmr.mgh.harvard.edu>
# Eric Larson <larson.eric.d@gmail.com>
# Marijn van Vliet <w.m.vanvliet@gmail.com>
# Jona Sassenhagen
# ... | bsd-3-clause |
dimonaks/siman | siman/classes.py | 1 | 236683 | # -*- coding: utf-8 -*-
#Copyright Aksyonov D.A
from __future__ import division, unicode_literals, absolute_import, print_function
import itertools, os, copy, math, glob, re, shutil, sys, pickle, gzip, shutil, random
import re, io, json
import pprint
from textwrap import wrap
import numpy as np
#additional packages... | gpl-2.0 |
broadinstitute/cms | cms/likes_from_model.py | 1 | 37167 | #!/usr/bin/env python
## top-level script for generating probability distributions for component scores as part of CMS 2.0.
## last updated: 06.24.2017 vitti@broadinstitute.org
import matplotlib as mp
mp.use('agg')
from dists.freqbins_func import run_traj, get_bin_strings, get_bins, check_create_dir, check_create_... | bsd-2-clause |
joonro/PyTables | setup.py | 1 | 33214 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup script for the tables package"""
from __future__ import print_function
import os
import re
import sys
import ctypes
import tempfile
import textwrap
import subprocess
from os.path import exists, expanduser
import glob
# Using ``setuptools`` enables lots of goodi... | bsd-3-clause |
josephmfaulkner/stoqs | stoqs/loaders/CANON/realtime/Contour.py | 1 | 39846 | #!/usr/bin/env python
__author__ = 'D.Cline'
__version__ = '$Revision: $'.split()[1]
__date__ = '$Date: $'.split()[1]
__copyright__ = '2011'
__license__ = 'GPL v3'
__contact__ = 'dcline at mbari.org'
__doc__ = '''
Creates still and animated contour and dot plots plots from MBARI LRAUV data
D Cline
MBARI 25 Se... | gpl-3.0 |
jhamman/xarray | xarray/backends/api.py | 1 | 48993 | import os.path
import warnings
from glob import glob
from io import BytesIO
from numbers import Number
from pathlib import Path
from textwrap import dedent
from typing import (
TYPE_CHECKING,
Callable,
Dict,
Hashable,
Iterable,
Mapping,
Tuple,
Union,
)
import numpy as np
from .. import... | apache-2.0 |
GuessWhoSamFoo/pandas | pandas/tests/indexes/interval/test_interval.py | 1 | 51858 | from __future__ import division
from itertools import permutations
import re
import numpy as np
import pytest
from pandas.compat import lzip
import pandas as pd
from pandas import (
Index, Interval, IntervalIndex, Timedelta, Timestamp, date_range,
interval_range, isna, notna, timedelta_range)
import pandas.... | bsd-3-clause |
jreback/pandas | pandas/core/arrays/timedeltas.py | 1 | 35525 | from datetime import timedelta
from typing import List, Optional, Union
import numpy as np
from pandas._libs import lib, tslibs
from pandas._libs.tslibs import (
BaseOffset,
NaT,
NaTType,
Period,
Tick,
Timedelta,
Timestamp,
iNaT,
to_offset,
)
from pandas._libs.tslibs.conversion imp... | bsd-3-clause |
louispotok/pandas | pandas/tests/io/json/test_ujson.py | 1 | 56148 | # -*- coding: utf-8 -*-
try:
import json
except ImportError:
import simplejson as json
import math
import pytz
import pytest
import time
import datetime
import calendar
import re
import decimal
import dateutil
from functools import partial
from pandas.compat import range, zip, StringIO, u
import pandas._libs.j... | bsd-3-clause |
jimgoo/zipline-fork | zipline/algorithm.py | 1 | 61776 | #
# Copyright 2014 Quantopian, Inc.
#
# 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 wr... | apache-2.0 |
plotly/plotly.py | packages/python/plotly/plotly/graph_objs/layout/polar/_radialaxis.py | 1 | 86348 | from plotly.basedatatypes import BaseLayoutHierarchyType as _BaseLayoutHierarchyType
import copy as _copy
class RadialAxis(_BaseLayoutHierarchyType):
# class properties
# --------------------
_parent_path_str = "layout.polar"
_path_str = "layout.polar.radialaxis"
_valid_props = {
"angle",... | mit |
louispotok/pandas | pandas/tests/reshape/merge/test_merge_asof.py | 1 | 39116 | import os
import pytest
import pytz
import numpy as np
import pandas as pd
from pandas import (merge_asof, read_csv,
to_datetime, Timedelta)
from pandas.core.reshape.merge import MergeError
from pandas.util import testing as tm
from pandas.util.testing import assert_frame_equal
class TestAsOfMerg... | bsd-3-clause |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.