repo_name
string
path
string
copies
string
size
string
content
string
license
string
aestrivex/mne-python
mne/epochs.py
1
92751
"""Tools for working with epoched data""" # Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> # Matti Hamalainen <msh@nmr.mgh.harvard.edu> # Daniel Strohmeier <daniel.strohmeier@tu-ilmenau.de> # Denis Engemann <denis.engemann@gmail.com> # Mainak Jas <mainak@neuro...
bsd-3-clause
salotz/mast
mastic/system.py
1
41717
""" The system module. """ import collections as col import itertools as it from mastic.molecule import Atom, Bond, Molecule, AtomType, BondType, MoleculeType from mastic.selection import SelectionMember, SelectionsList, IndexedSelection, GenericSelection import mastic.config.system as masticsysconfig __all__ = ['o...
mit
glemaitre/protoclass
protoclass/classification/classification.py
1
70181
"""Module to perform classification.""" import multiprocessing import numpy as np from collections import Counter from collections import namedtuple from random import sample from sklearn.metrics import roc_curve from sklearn.metrics import roc_auc_score from imblearn.over_sampling import RandomOverSampler from i...
gpl-2.0
jhamrick/bayesian-quadrature
bayesian_quadrature/bq.py
1
33157
import numpy as np import logging import matplotlib.pyplot as plt import scipy.stats from copy import copy, deepcopy from gp import GP, GaussianKernel, PeriodicKernel from . import bq_c from . import linalg_c as la from . import util logger = logging.getLogger("bayesian_quadrature") DTYPE = np.dtype('float64') MIN =...
mit
bdh1011/wau
venv/lib/python2.7/site-packages/pandas/core/ops.py
1
44317
""" 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 numpy as np import pandas as pd from pandas import compat, lib, tslib import pandas.index as _index from pandas.util.decorators import Appender i...
mit
plotly/python-api
packages/python/plotly/plotly/graph_objs/carpet/_aaxis.py
1
81529
from plotly.basedatatypes import BaseTraceHierarchyType as _BaseTraceHierarchyType import copy as _copy class Aaxis(_BaseTraceHierarchyType): # class properties # -------------------- _parent_path_str = "carpet" _path_str = "carpet.aaxis" _valid_props = { "arraydtick", "arraytick0...
mit
harisbal/pandas
pandas/tests/internals/test_internals.py
1
48745
# -*- coding: utf-8 -*- # pylint: disable=W0102 from datetime import datetime, date import operator import sys import pytest import numpy as np import re from distutils.version import LooseVersion import itertools from pandas import (Index, MultiIndex, DataFrame, DatetimeIndex, Series, Categorical...
bsd-3-clause
jamesrobertlloyd/automl-phase-2
managers.py
1
63020
from __future__ import division import glob import shutil __author__ = 'James Robert Lloyd, Emma Smith' __description__ = 'Objects to coordinate stuff' import constants import os import time from collections import defaultdict import psutil # import matplotlib import matplotlib.pyplot as plt import functools import p...
mit
chaubold/hytra
hytra/core/trackingfeatures.py
1
31878
import sys sys.path.append('../.') sys.path.append('.') import h5py import pgmlink as track import numpy as np import math import os import os.path as path import argparse from hytra.util.progressbar import ProgressBar def get_feature(h5file, feature_path, object_id): if not feature_path in h5file: raise E...
mit
MartinHeinz/training-and-food-tracker
libs/garden/matplotlib/backend_kivy.py
1
49849
''' Backend Kivy ===== .. image:: images/backend_kivy_example.jpg :align: right The :class:`FigureCanvasKivy` widget is used to create a matplotlib graph. This widget has the same properties as :class:`kivy.ext.mpl.backend_kivyagg.FigureCanvasKivyAgg`. FigureCanvasKivy instead of rendering a static image, uses th...
mit
hail-is/hail
hail/python/test/hail/table/test_table.py
1
63750
import unittest import pandas as pd import pyspark.sql import pytest import random import hail as hl import hail.expr.aggregators as agg from hail.utils import new_temp_file from hail.utils.java import Env from ..helpers import * from test.hail.matrixtable.test_file_formats import create_all_values_datasets setUpMod...
mit
rodluger/everest
everest/basecamp.py
1
41486
#!/usr/bin/env python # -*- coding: utf-8 -*- ''' :py:mod:`basecamp.py` - The Everest base class ---------------------------------------------- The :py:obj:`everest` engine. All :py:obj:`everest` models inherit from :py:class:`Basecamp`. ''' from __future__ import division, print_function, absolute_import, \ uni...
mit
gofortargets/CNN_brandsafety
knx/text/classifier/base.py
1
66928
#!/usr/bin/python import argparse import json import os import pickle import sys from functools import partial from multiprocessing import Pipe, Process, cpu_count import numpy from knx.metrics.confusionmatrix import ConfusionMatrix from knx.text.doc_to_feature import DocToFeature, tf_to_tfidf, tf_to_okapi, tf_to_midf...
apache-2.0
aeklant/scipy
scipy/stats/_distn_infrastructure.py
2
127400
# # Author: Travis Oliphant 2002-2011 with contributions from # SciPy Developers 2004-2011 # from scipy._lib._util import getfullargspec_no_self as _getfullargspec import sys import keyword import re import types import warnings from itertools import zip_longest from scipy._lib import doccer from ._distr_p...
bsd-3-clause
ryfeus/lambda-packs
Pandas_numpy/source/pandas/core/indexes/base.py
1
145077
import datetime import warnings import operator import numpy as np from pandas._libs import (lib, index as libindex, tslib as libts, algos as libalgos, join as libjoin, Timestamp, Timedelta, ) from pandas._libs.lib import is_datetime_array from pandas._libs.tslibs im...
mit
hulingfei/Shaka
bia-660/final/experiment_reviews.py
1
107408
# -*- coding: utf-8 -*- """ Created on Sat Nov 07 00:08:44 2015 @author: Lingfei Hu """ import re import HTMLParser from sklearn.feature_extraction.text import CountVectorizer from sklearn.feature_extraction.text import TfidfTransformer from sklearn.neighbors import KNeighborsClassifier from sklearn.naive_bayes impor...
apache-2.0
lvniqi/tianchi_power
code/preprocess.py
1
32964
#!/usr/bin/env python2 # -*- coding: utf-8 -*- """ Created on Sat May 13 17:36:18 2017 @author: boweiy """ from sklearn.model_selection import train_test_split import pandas as pd import numpy as np import os import xgboost as xgb from multiprocessing import Pool as m_Pool from sklearn import preprocessing from sklea...
mit
MattWellie/DDG2P_pure
frameshift_comp_with_probes.py
1
31409
""" This script will take three inputs; - A CSV file containing CNV details, exported directly from Cartagenia - A pickle file which contains the chromosomal coordinates of all DDG2P genes - A BED file contining the probe sites of the array The contents of these files will be cross referenced in severa...
gpl-3.0
mMPI-MRI/TractLAS
utils.py
1
74376
# -*- coding: utf-8 -*- """ Created on Thu Feb 23, 2017 Compute large connectomes using mrtrix and sparse matrices @author: Christopher Steele """ from __future__ import division # to allow floating point calcs of number of voxels from pandas import read_csv def natural_sort(l): """ Returns alphanumerical...
gpl-3.0
Dennett/asp
asp/distributions.py
1
46633
# -*- coding: utf-8 -*- """ ------------------------------- **distributions** ------------------------------- Description ----------- Create shortest path distributions for path families and edges. Copyright (C) 2017 Michael W. Ramsey <michael.ramsey@gmail.com> License -------- This program is free software: you ca...
gpl-3.0
witgo/spark
python/pyspark/sql/session.py
1
31079
# # 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
TNT-Samuel/Coding-Projects
DNS Server/Source/Lib/site-packages/dask/dataframe/groupby.py
2
44775
from __future__ import absolute_import, division, print_function import collections import itertools as it import operator import warnings import numpy as np import pandas as pd from .core import (DataFrame, Series, aca, map_partitions, merge, new_dd_object, no_default, split_out_on_index) from .m...
gpl-3.0
tochikuji/pyPyrTools
pyrtools/pyPyrTools.py
1
80812
import numpy #import pyPyrUtils as ppu from . import pyPyrUtils #import pyPyrCcode import math import matplotlib.cm import os import scipy.misc import cmath from . import JBhelpers import pylab import copy class pyramid: # pyramid # properties pyr = [] pyrSize = [] pyrType = '' image = '' # ...
mit
SeanMcGrath/ScopeOut
scopeout/widgets.py
1
62717
""" ScopeOut Widgets Widget classes for Scopeout GUI. Sean McGrath, 2014 """ import os import re import logging from numpy import multiply, amax from PyQt5 import QtGui, QtWidgets, QtCore from matplotlib.figure import Figure from matplotlib.widgets import Cursor from matplotlib.backends.backend_qt5agg import Figure...
mit
bdh1011/wau
venv/lib/python2.7/site-packages/notebook/notebookapp.py
1
42986
# coding: utf-8 """A tornado based IPython notebook server.""" # Copyright (c) Jupyter Development Team. # Distributed under the terms of the Modified BSD License. from __future__ import absolute_import, print_function import base64 import datetime import errno import importlib import io import json import logging i...
mit
rsmailach/SRPT
ClassBased_SingleServer_Catastrophic.py
1
41746
#----------------------------------------------------------------------# # ApproxSRPTE.py # # This application simulates a single server with Poisson arrivals # and processing times of a general distribution. There are errors in # time estimates within a range. Arrivals are assigned to SRPT classes # using the methods ...
mit
jjdmol/LOFAR
CEP/PyBDSM/src/python/functions.py
1
74920
# some functions def poly(c,x): """ y = Sum { c(i)*x^i }, i=0,len(c)""" import numpy as N y=N.zeros(len(x)) for i in range(len(c)): y += c[i]*(x**i) return y def sp_in(c, x): """ Spectral index in freq-flux space """ import numpy as N order = len(c)-1 if order == 1: ...
gpl-3.0
Spiderlover/Toontown
toontown/chat/WhiteListData.py
1
594015
WHITELIST = [ '', '!', '"', '$', '$1', '$10', '$5', '%', '%s', '&', "'", "'boss", "'cause", "'course", "'ello", "'em", "'n", "'s", '(', '(:', '(=<', '(>^.^)>', ')', '):', ')=<', '*', '*scared', '+', ',', ...
mit
jseabold/statsmodels
statsmodels/duration/hazard_regression.py
4
58578
""" Implementation of proportional hazards regression models for duration data that may be censored ("Cox models"). References ---------- T Therneau (1996). Extending the Cox model. Technical report. http://www.mayo.edu/research/documents/biostat-58pdf/DOC-10027288 G Rodriguez (2005). Non-parametric estimation in ...
bsd-3-clause
plotly/python-api
packages/python/plotly/plotly/express/_chart_types.py
1
32102
from ._core import make_figure from ._doc import make_docstring import plotly.graph_objs as go def scatter( data_frame=None, x=None, y=None, color=None, symbol=None, size=None, hover_name=None, hover_data=None, custom_data=None, text=None, facet_row=None, facet_col=None...
mit
qsnake/gpaw
gpaw/transport/analysor.py
1
48167
from gpaw.transport.selfenergy import LeadSelfEnergy from gpaw.transport.tools import get_matrix_index, aa1d, aa2d, sum_by_unit, \ dot, fermidistribution, eig_states_norm, \ find, get_atom_indices, dagger, \ write, gather_nd...
gpl-3.0
ChrisThoung/fsic
test_fsic.py
1
78338
# -*- coding: utf-8 -*- """ test_fsic ========= Test suite for FSIC. Example equations/models are adapted from: Almon, C. (2017) *The craft of economic modeling*, Third, enlarged edition, *Inforum* http://www.inforum.umd.edu/papers/TheCraft.html Godley, W., Lavoie, M. (2007) *Monetary economi...
mit
agile-geoscience/welly
welly/curve.py
1
30920
""" Defines log curves. :copyright: 2021 Agile Scientific :license: Apache 2.0 """ from __future__ import division import numpy as np from scipy.interpolate import interp1d import matplotlib.pyplot as plt import matplotlib as mpl from matplotlib.patches import PathPatch import warnings from . import utils class ...
apache-2.0
maciejkula/scipy
scipy/signal/signaltools.py
1
75779
# Author: Travis Oliphant # 1999 -- 2002 from __future__ import division, print_function, absolute_import import warnings import threading from . import sigtools from scipy.lib.six import callable from scipy.lib._version import NumpyVersion from scipy import linalg from scipy.fftpack import (fft, ifft, ifftshift, ff...
bsd-3-clause
asdf2014/superset
superset/viz.py
1
52742
"""This module contains the "Viz" objects These objects represent the backend of all the visualizations that Superset can render. """ from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals import copy import hashlib import l...
apache-2.0
magic2du/contact_matrix
Contact_maps/DeepLearning/DeepLearningTool/DL_contact_matrix_New_Server_0706_2015_3.py
1
47381
# coding: utf-8 # In[5]: import sys, os sys.path.append('../../../libs/') sys.path.append('../libs/') sys.path.append('../../libs/') import os.path import IO_class from IO_class import FileOperator from sklearn import cross_validation import sklearn import csv from dateutil import parser from datetime import timede...
gpl-2.0
gsnyder206/synthetic-image-morph
statmorph_gfs.py
1
82960
import math import string import sys import struct import matplotlib matplotlib.use('TkAgg') import matplotlib.pyplot as pyplot import matplotlib.colors as pycolors import matplotlib.cm as cm import matplotlib.patches as patches import numpy as np #import cPickle import scipy.ndimage import scipy.stats as ss import sci...
gpl-2.0
rs2/pandas
pandas/tests/indexing/test_indexing.py
1
37462
""" test fancy indexing & misc """ from datetime import datetime import re import weakref import numpy as np import pytest from pandas.core.dtypes.common import is_float_dtype, is_integer_dtype import pandas as pd from pandas import DataFrame, Index, NaT, Series import pandas._testing as tm from pandas.core.indexin...
bsd-3-clause
jaeilepp/mne-python
mne/evoked.py
1
51449
# -*- coding: utf-8 -*- # Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> # Matti Hamalainen <msh@nmr.mgh.harvard.edu> # Denis Engemann <denis.engemann@gmail.com> # Andrew Dykstra <andrew.r.dykstra@gmail.com> # Mads Jensen <mje.mads@gmail.com> # # License: BSD (...
bsd-3-clause
cosmicBboy/Urbanscape
UrbanScape/urbanscape.py
1
31449
import numpy as np import numpy.random as random import matplotlib.pyplot as pyplot #Urbanscape v1.4 #Changes: # randomized the income and rent distribution functions with a random multiplier # added an element of randomness to the FAFH and FFR functions using a random float multiplier # changed the FFR function such...
mit
clawpack/clawpack-4.x
python/pyclaw/plotters/data.py
1
58418
#!/usr/bin/env python # encoding: utf-8 # ====================================================================== # Package: pyclaw.plotters # File: data.py # Created: Aug 7, 2009 # Author: R.J. LeVeque # ============================================================================ """ Plotting Da...
bsd-3-clause
cdegroc/scikit-learn
sklearn/gaussian_process/gaussian_process.py
1
32730
#!/usr/bin/python # -*- coding: utf-8 -*- # Author: Vincent Dubourg <vincent.dubourg@gmail.com> # (mostly translation, see implementation details) # License: BSD style import numpy as np from scipy import linalg, optimize, rand from ..base import BaseEstimator, RegressorMixin from ..metrics.pairwise import m...
bsd-3-clause
gfyoung/scipy
scipy/interpolate/_bsplines.py
2
34756
from __future__ import division, print_function, absolute_import import functools import operator import numpy as np from scipy._lib.six import string_types from scipy.linalg import (get_lapack_funcs, LinAlgError, cholesky_banded, cho_solve_banded) from . import _bspl from . import _fitpack_...
bsd-3-clause
e2crawfo/dps
dps/datasets/atari.py
1
30355
import gym import numpy as np import os import tensorflow as tf import matplotlib.pyplot as plt from collections import defaultdict from pprint import pprint from scipy import optimize from gym_recording import scan_recorded_traces from dps import cfg from dps.datasets.base import ImageDataset, ArrayFeature, ImageFeat...
apache-2.0
jcornford/pyecog
pyecog/visualisation/pyecog_main_gui.py
1
59431
import sys import os import bisect import traceback import time import numpy as np import pandas as pd import pickle as p from PyQt5 import QtGui, QtWidgets#,# uic from PyQt5.QtCore import QThread, pyqtSignal, Qt, QRect, QTimer from scipy import signal, stats import pyqtgraph as pg import inspect import h5py try: # f...
mit
massmutual/scikit-learn
sklearn/linear_model/coordinate_descent.py
1
76509
# Author: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Fabian Pedregosa <fabian.pedregosa@inria.fr> # Olivier Grisel <olivier.grisel@ensta.org> # Gael Varoquaux <gael.varoquaux@inria.fr> # # License: BSD 3 clause import sys import warnings from abc import ABCMeta, abstractmethod import n...
bsd-3-clause
dotsdl/seaborn
seaborn/axisgrid.py
1
48212
from __future__ import division from itertools import product import numpy as np import pandas as pd import matplotlib as mpl import matplotlib.pyplot as plt from six import string_types from . import utils from .palettes import color_palette class Grid(object): """Base class for grids of subplots.""" _marg...
bsd-3-clause
astrotuvi/pyplate
pyplate/process/sources.py
1
30440
import os import glob import shutil import sys import math import datetime as dt import subprocess as sp import numpy as np import warnings import xml.etree.ElementTree as ET from astropy import __version__ as astropy_version from astropy import wcs from astropy.io import fits, votable from astropy.table import Table, ...
apache-2.0
Haunter17/MIR_SU17
exp1/exp1k.py
1
335969
import numpy as np import tensorflow as tf import h5py from sklearn.preprocessing import OneHotEncoder import matplotlib matplotlib.use('Agg') import matplotlib.pyplot as plt import time startTime = time.time() print('==> Experiment 1i') def loadData(filepath): print('==> Loading data from {}'.format(filepath)) f...
mit
mikofski/pvsc44-clearsky-aod
PVSC-Clearsky-AOD.py
1
35909
# coding: utf-8 # # Use of Measured Aerosol Optical Depth and Precipitable Water to Model Clear Sky Irradiance # *presented at: 2017 IEEE PVSC-44* # *by: Mark A. Mikofski, Clifford W. Hansen, William F. Holmgren and Gregory M. Kimball* # # ## Introduction # Predicting irradiance is crucial for developing solar power...
bsd-3-clause
jseabold/statsmodels
statsmodels/tsa/statespace/tests/test_dynamic_factor.py
4
38900
""" Tests for VARMAX models Author: Chad Fulton License: Simplified-BSD """ import os import re import warnings import numpy as np from numpy.testing import assert_equal, assert_raises, assert_allclose import pandas as pd import pytest from statsmodels.tsa.statespace import dynamic_factor from .results import result...
bsd-3-clause
alephu5/Soundbyte
environment/lib/python3.3/site-packages/pandas/tests/test_graphics.py
1
41665
import nose import os import string from distutils.version import LooseVersion from datetime import datetime, date, timedelta from pandas import Series, DataFrame, MultiIndex, PeriodIndex, date_range from pandas.compat import range, lrange, StringIO, lmap, lzip, u, zip import pandas.util.testing as tm from pandas.uti...
gpl-3.0
SamWitte/Codds_DarkMatter
src/modulation_band.py
1
57590
from experiment_HaloIndep import * from scipy import interpolate from scipy.optimize import brentq, minimize, brute from globalfnc import * from basinhopping import * from custom_minimizer import * import matplotlib.pyplot as plt import os # for speaking import parallel_map as par from scipy.stats import poisson impo...
gpl-2.0
canismarko/xanespy
tests/test_importers.py
1
51016
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright © 2016 Mark Wolf # # This file is part of Xanespy. # # Xanespy 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 # ...
gpl-3.0
zsomko/visualcortex
python/spikes/poster.py
1
45824
from numpy import * from numpy.random import * from plotting.plot_images import * from plotting.myplot import * from plotting.covariance_ellipse import * from spikes.spikes import * import matplotlib.image as img import matplotlib.cm as cm import matplotlib.gridspec as gridspec def new_g_pairs(make): # make: make i...
gpl-2.0
kevin-intel/scikit-learn
sklearn/feature_extraction/tests/test_text.py
2
50267
# -*- coding: utf-8 -*- from collections.abc import Mapping import re import pytest from scipy import sparse 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_ex...
bsd-3-clause
kushalbhola/MyStuff
Practice/PythonApplication/env/Lib/site-packages/pandas/io/formats/style.py
1
47229
""" Module for applying conditional formatting to DataFrames and Series. """ from collections import defaultdict from contextlib import contextmanager import copy from functools import partial from itertools import product from uuid import uuid1 import numpy as np from pandas._config import get_option from pandas.c...
apache-2.0
MTgeophysics/mtpy
mtpy/core/edi_collection.py
1
41748
# -*- coding: utf-8 -*- """ Description: To compute and encapsulate the properties of a set of EDI files Author: fei.zhang@ga.gov.au CreateDate: 2017-04-20 """ import csv import glob import os import sys from logging import INFO,DEBUG,WARNING,ERROR import geopandas as gpd import matplotlib.pyplot as plt import num...
gpl-3.0
matthew-tucker/mne-python
mne/time_frequency/tfr.py
2
46795
"""A module which implements the time frequency estimation. Authors : Alexandre Gramfort, alexandre.gramfort@telecom-paristech.fr Hari Bharadwaj <hari@nmr.mgh.harvard.edu> License : BSD 3-clause Morlet code inspired by Matlab code from Sheraz Khan & Brainstorm & SPM """ import warnings from math import sq...
bsd-3-clause
runt18/nupic
external/linux32/lib/python2.6/site-packages/matplotlib/backends/backend_pdf.py
1
71974
# -*- coding: iso-8859-1 -*- """ A PDF matplotlib backend (not yet complete) Author: Jouni K Seppänen <jks@iki.fi> """ from __future__ import division import os import re import sys import time import warnings import zlib import numpy as npy from cStringIO import StringIO from datetime import datetime from math impo...
agpl-3.0
twdb/sonde
scripts/compute_water_level_filter_salinity.py
1
35995
""" compute_water_level_filter_saliniy.py ~~~~~~~~ This script is used to: 1- calculate water depth above pressure sensor from pressure reading and coincident barometric pressure measurements. 2- calculate total water depth 3- calculate water surface elevation 4- filter salinity when water level...
bsd-3-clause
azjps/bokeh
bokeh/charts/data_source.py
1
34233
"""The classes and functionality used to transform data inputs to consistent types.""" # ----------------------------------------------------------------------------- # Copyright (c) 2012 - 2014, Continuum Analytics, Inc. All rights reserved. # # Powered by the Bokeh Development Team. # # The full license is in the fil...
bsd-3-clause
ebranca/Mixed
Data_Analysis_Tools/06_pearson_r.py
1
79903
# -*- coding: utf-8 -*- import sys # import io from collections import OrderedDict from tabulate import tabulate import decimal from decimal import Decimal import itertools import numbers import string import numpy as np from scipy import stats import pandas as pd #import seaborn as sns import matplotlib as mpl impor...
apache-2.0
schaunwheeler/wrappers
wrappers/plotting.py
1
51133
# -*- coding: utf-8 -*- """ Created on Thu Aug 7 09:22:34 2014 @author: schaunwheeler """ import pandas as pd import numpy as np import colorsys from matplotlib.colors import ColorConverter import tempfile import re import uuid import bokeh import bokeh.plotting import bokeh.colors import os from collections import ...
mit
datapythonista/pandas
pandas/tests/indexing/test_iloc.py
1
46020
""" test positional based indexing with iloc """ from datetime import datetime import re from warnings import ( catch_warnings, simplefilter, ) import numpy as np import pytest import pandas.util._test_decorators as td from pandas import ( Categorical, CategoricalDtype, DataFrame, Index, ...
bsd-3-clause
UMN-Hydro/GSFLOW_pre-processor
python_scripts/GSFLOW_print_PRMSparamfile4.py
1
44605
# -*- coding: utf-8 -*- """ Created on Tue Sep 12 22:21:56 2017 Based on: GSFLOW_print_PRMSparamfile4.m @author: gcng """ import numpy as np # matlab core import scipy as sp # matlab toolboxes import matplotlib.pyplot as plt # matlab-like plots import os # os functions import pandas as pd # for data structures and r...
gpl-3.0
fspaolo/scikit-learn
sklearn/decomposition/dict_learning.py
2
40463
""" Dictionary learning """ from __future__ import print_function # Author: Vlad Niculae, Gael Varoquaux, Alexandre Gramfort # License: BSD 3 clause import time import sys import itertools from math import sqrt, floor, ceil import numpy as np from scipy import linalg from numpy.lib.stride_tricks import as_strided f...
bsd-3-clause
NREL/glmgen
glmgen/feeder.py
1
36373
#!/usr/bin/env python import datetime, copy, os, re, warnings # import networkx as nx from matplotlib import pyplot as plt import re from collections import deque class GlmFile(dict): """ GlmFile is a dict with integer keys (for ordering the file) and dict values, each of which is an item in a glm file. ...
gpl-2.0
ThomasBrouwer/BNMTF
experiments/experiments_toy/convergence/nmtf_np.py
1
61674
""" Recover the toy dataset using the non-probabilistic NMTF. We can plot the MSE, R2 and Rp as it converges, on the entire dataset. We have I=100, J=80, K=5, L=5, and no test data. """ import sys, os project_location = os.path.dirname(__file__)+"/../../../../" sys.path.append(project_location) from BNMTF.code.mode...
apache-2.0
sniemi/SamPy
resolve/misc/findSlitmaskPosition.py
1
47929
""" Class to fit spectroscopic observations to a direct image. The class has been designed for image slicer data where at the moment three spectra are recorded simultaneously. The script is flexible enough that the input can contain either a single pointing or single plus offset positions. Rotations are not allowed at...
bsd-2-clause
azjps/bokeh
bokeh/palettes.py
1
80075
########################################################################### # License regarding the Viridis, Magma, Plasma and Inferno colormaps: # New matplotlib colormaps by Nathaniel J. Smith, Stefan van der Walt, # and (in the case of viridis) Eric Firing. # # The Viridis, Magma, Plasma, and Inferno colormaps are r...
bsd-3-clause
Kate-Willett/HadISDH_Marine_Build
ANALYSIS_PLOTS/PlotObsDistributions_AUG2018.py
1
47935
#!/usr/local/sci/bin/python # PYTHON2.7 # # Author: Kate Willett # Created: 23 Aug 2018 # Last update: 23 August 2018 # Location: /data/local/hadkw/HADCRUH2/MARINE/EUSTACEMDS/ANALYSIS_PLOTS/ # GitHub: https://github.com/Kate-Willett/HadISDH_Marine_Build/ # ----------------------- # CODE PURPOSE AND OUTPUT # -----...
cc0-1.0
dsm054/pandas
pandas/core/dtypes/common.py
2
55173
""" common type operations """ import numpy as np from pandas._libs import algos, lib from pandas._libs.interval import Interval from pandas._libs.tslibs import Period, Timestamp, conversion from pandas.compat import PY3, PY36, binary_type, string_types, text_type from pandas.core.dtypes.dtypes import ( Categoric...
bsd-3-clause
jorgehog/Deux-kMC
scripts/dcviz.py
1
194412
#DCVIZ from DCViz_sup import DCVizPlotter import numpy import numpy as np import os import re from numpy import exp, floor, ceil from scipy.stats import linregress from scipy.optimize import curve_fit from scipy.special import lambertw from matplotlib.ticker import FormatStrFormatter, FuncFormatter from matplotlib im...
gpl-3.0
jreback/pandas
pandas/io/stata.py
1
125519
""" 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...
bsd-3-clause
meren/anvio
anvio/trnaidentifier.py
1
89401
# -*- coding: utf-8 # pylint: disable=line-too-long """tRNA identification from input sequence""" import itertools import pandas as pd from tabulate import tabulate from anvio.errors import TRNAIdentifierError from anvio.filesnpaths import is_file_exists, is_output_file_writable from anvio.constants import LONGEST_K...
gpl-3.0
plotly/python-api
packages/python/plotly/plotly/figure_factory/_gantt.py
1
34739
from __future__ import absolute_import from numbers import Number import copy from plotly import exceptions, optional_imports import plotly.colors as clrs from plotly.figure_factory import utils import plotly.graph_objects as go pd = optional_imports.get_module("pandas") REQUIRED_GANTT_KEYS = ["Task", "Start", "Fi...
mit
lexbrandt/plot-csv
plot-csv.py
1
30029
#! /usr/bin/env python #! -*- coding:utf-8 -*- import sys import csv import re import os import math import random import argparse import re import prettyplotlib as ppl import numpy as np # This is "import matplotlib.pyplot as plt" from the prettyplotlib library import matplotlib.pyplot as plt # This is "import ma...
mit
jreback/pandas
pandas/plotting/_matplotlib/converter.py
1
35528
import contextlib import datetime as pydt from datetime import datetime, timedelta, tzinfo import functools from typing import Any, Dict, List, Optional, Tuple from dateutil.relativedelta import relativedelta import matplotlib.dates as dates from matplotlib.ticker import AutoLocator, Formatter, Locator from matplotlib...
bsd-3-clause
massgov/incubator-superset
superset/views/core.py
1
84670
from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals from collections import defaultdict from datetime import datetime, timedelta import json import logging import pandas as pd import pickle import re import time import tra...
apache-2.0
GuessWhoSamFoo/pandas
pandas/plotting/_core.py
1
128312
# being a bit too dynamic # pylint: disable=E1101 from __future__ import division from collections import namedtuple from distutils.version import LooseVersion import re import warnings import numpy as np import pandas.compat as compat from pandas.compat import lrange, map, range, string_types, zip from pandas.error...
bsd-3-clause
joshp123/genx
event_handlers.py
1
39905
''' Just a library of the different eventhandler needed in the GUI File started by: Matts Bjorck $Rev:: $: Revision of last commit $Author:: $: Author of last commit $Date:: $: Date of last commit ''' import version __ver...
gpl-3.0
atztogo/phonopy
phonopy/cui/phonopy_script.py
1
66553
# Copyright (C) 2020 Atsushi Togo # All rights reserved. # # This file is part of phonopy. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # * Redistributions of source code must retain the above copyright # notic...
bsd-3-clause
datapythonista/pandas
pandas/tests/io/pytables/test_store.py
2
32047
import datetime import hashlib import os import time from warnings import ( catch_warnings, simplefilter, ) import numpy as np import pytest import pandas.util._test_decorators as td import pandas as pd from pandas import ( DataFrame, DatetimeIndex, Index, MultiIndex, Series, Timestam...
bsd-3-clause
antoinecarme/pyaf
pyaf/Bench/TS_datasets.py
1
37511
# Copyright (C) 2016 Antoine Carme <Antoine.Carme@Laposte.net> # All rights reserved. # This file is part of the Python Automatic Forecasting (PyAF) library and is made available under # the terms of the 3 Clause BSD license import pandas as pd import numpy as np import datetime from datetime import date # from mem...
bsd-3-clause
yuanbaowen521/tadbit
_pytadbit/imp/structuralmodels.py
1
123961
""" 19 Jul 2013 """ from pytadbit.utils.three_dim_stats import calc_consistency, mass_center from pytadbit.utils.three_dim_stats import dihedral, calc_eqv_rmsd from pytadbit.utils.three_dim_stats import get_center_of_mass, distance from pytadbit.utils.tadmaths import calinski_harabasz, nozero_log_list from pytad...
gpl-3.0
MTgeophysics/mtpy
mtpy/modeling/modem/plot_rms_maps.py
1
34831
""" ================== ModEM ================== # Generate files for ModEM # revised by JP 2017 # revised by AK 2017 to bring across functionality from ak branch Revision History: brenainn.moushall@ga.gov.au 31-03-2020 13:38:10 AEDT: - Add ability to plot on background geotiff - Add ability to wr...
gpl-3.0
CamDavidsonPilon/lifelines
lifelines/fitters/cox_time_varying_fitter.py
1
33961
# -*- coding: utf-8 -*- from datetime import datetime import warnings import time import numpy as np import pandas as pd from scipy import stats from numpy.linalg import norm, inv from numpy import sum as array_sum_to_scalar from scipy.linalg import solve as spsolve, LinAlgError from autograd import elementwise_g...
mit
DonBeo/scikit-learn
sklearn/metrics/pairwise.py
1
41696
# -*- coding: utf-8 -*- # Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Mathieu Blondel <mathieu@mblondel.org> # Robert Layton <robertlayton@gmail.com> # Andreas Mueller <amueller@ais.uni-bonn.de> # Philippe Gervais <philippe.gervais@inria.fr> # Lars Buitinck ...
bsd-3-clause
rabrahm/ceres
feros/ferospipe.py
1
60563
import sys import matplotlib matplotlib.use("Agg") import matplotlib.pyplot as plt from matplotlib.backends.backend_pdf import PdfPages from pylab import * base = '../' sys.path.append(base+"utils/Correlation") sys.path.append(base+"utils/GLOBALutils") sys.path.append(base+"utils/OptExtract") baryc_dir= base+'util...
mit
LarsDu/DeepPixelMonster
dpixelmonster/dcgan_dtlayers.py
1
32662
import tensorflow as tf import matplotlib.pyplot as plt import numpy as np import os from tensorflow.contrib.layers.python.layers import batch_norm as batch_norm """ An implementation of Layer Wise Relevance Propagation in Tensorflow with some other good stuff Also, includes classes for Deep Convolutional Adverserial...
apache-2.0
raincoatrun/basemap
lib/mpl_toolkits/basemap/__init__.py
1
253424
""" Module for plotting data on maps with matplotlib. Contains the :class:`Basemap` class (which does most of the heavy lifting), and the following functions: :func:`interp`: bilinear interpolation between rectilinear grids. :func:`maskoceans`: mask 'wet' points of an input array. :func:`shiftgrid`: shifts globa...
gpl-2.0
ljchang/nltools
nltools/stats.py
1
81637
from __future__ import division ''' NeuroLearn Statistics Tools =========================== Tools to help with statistical analyses. ''' __all__ = ['pearson', 'zscore', 'fdr', 'holm_bonf', 'threshold', 'multi_threshold', 'winsorize', 'trim...
mit
QTB-HHU/ModelHeatShock
HSM_FunctsOfSimulateClass.py
1
46946
from mpl_toolkits.mplot3d import axes3d from matplotlib import cm from HSM_ODEsSystem10or9eqs import * from HSM_HSModelClass import * from HSM_PlottingFunctions import * import time def SolveODEsystem(self, DirectControlnuPp, ModifyKset="No", ParamsToBeModif={}, TimeOfMod=vorl, Add3rdmRNA_ARS="No"): """ Set th...
gpl-3.0
frzdian/jaksafe-engine
jaksafe/jaksafe/jakservice/post_processing/report.py
1
42036
# coding = utf-8 __AUTHOR__ = 'Abdul Somat Budiaji' import datetime import os import sys import matplotlib matplotlib.use('Agg') import matplotlib.pyplot as plt import matplotlib.ticker as ticker from matplotlib.backends.backend_pdf import PdfPages from matplotlib.font_manager import FontProperties from matplotlib.of...
gpl-2.0
adykstra/mne-python
mne/channels/layout.py
1
33349
# 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 <jona.sass...
bsd-3-clause
vortex-ape/scikit-learn
sklearn/utils/testing.py
5
34209
"""Testing utilities.""" # Copyright (c) 2011, 2012 # Authors: Pietro Berkes, # Andreas Muller # Mathieu Blondel # Olivier Grisel # Arnaud Joly # Denis Engemann # Giorgio Patrini # Thierry Guillemot # License: BSD 3 clause import os import inspect import p...
bsd-3-clause
pjryan126/solid-start-careers
store/api/zillow/venv/lib/python2.7/site-packages/pandas/io/tests/test_gbq.py
1
34282
import re from datetime import datetime import nose import pytz import platform from time import sleep import numpy as np from distutils.version import StrictVersion from pandas import compat from pandas import NaT from pandas.compat import u, range from pandas.core.frame import DataFrame import pandas.io.gbq as gbq...
gpl-2.0
cactusbin/nyt
matplotlib/lib/matplotlib/axes.py
1
334492
from __future__ import division, print_function import math import warnings from operator import itemgetter import itertools import numpy as np from numpy import ma import matplotlib rcParams = matplotlib.rcParams import matplotlib.artist as martist from matplotlib.artist import allow_rasterization import matplotlib...
unlicense
varenius/salsa
Control_program/mapper.py
1
40971
#!/usr/bin/env python from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas from matplotlib.backends.backend_qt4agg import NavigationToolbar2QT as NavigationToolbar2QTAgg import sys import ephem from PyQt4 import QtGui, QtCore sys.path.append('./') from telescope import * from measurement imp...
mit