repo_name
string
path
string
copies
string
size
string
content
string
license
string
pathomx/pathomx
pathomx/views.py
2
43143
# -*- coding: utf-8 -*- from __future__ import unicode_literals import logging logging.debug('Loading views.py') # Import PyQt5 classes from .qt import * import os, re, sys, logging from collections import OrderedDict # Pathomx classes from . import utils from . import db import numpy as np import pandas as pd fr...
gpl-3.0
deapplegate/wtgpipeline
adam_do_multiple_photoz.py
1
40429
#!/usr/bin/env python import os import astropy.io.fits as pyfits ns_dmp=globals() def parse_column_file(input,output=None,offsets=None): f = open(input,'r').readlines() dict = {} for l in f: import re res = re .split('\s+',l) print res if len(res) > 3: t = {} ...
mit
jskDr/jamespy
jchem.py
3
51654
from rdkit import Chem from rdkit.Chem import AllChem from rdkit.Chem import Draw from rdkit import DataStructs from rdkit.Chem import MACCSkeys from rdkit.Chem import FragmentCatalog import matplotlib.pyplot as plt import numpy as np import pandas as pd import os # This is James Sungjin Kim's library im...
mit
pjryan126/solid-start-careers
store/api/zillow/venv/lib/python2.7/site-packages/pandas/core/generic.py
1
194836
# pylint: disable=W0231,E1101 import warnings import operator import weakref import gc import numpy as np import pandas.lib as lib import pandas as pd from pandas.core.base import PandasObject from pandas.core.index import (Index, MultiIndex, _ensure_index, InvalidIndexError) import pan...
gpl-2.0
huggingface/pytorch-transformers
templates/adding_a_new_example_script/{{cookiecutter.directory_name}}/run_{{cookiecutter.example_shortcut}}.py
1
36461
#!/usr/bin/env python # coding=utf-8 # Copyright {{cookiecutter.authors}} and The HuggingFace Inc. team. 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://ww...
apache-2.0
joegomes/deepchem
deepchem/models/tensorflow_models/__init__.py
1
30137
"""Helper operations and classes for general model building. """ from __future__ import print_function from __future__ import division from __future__ import unicode_literals import collections import pickle import os import time import warnings import numpy as np import pandas as pd import tensorflow as tf import tem...
mit
DTOcean/dtocean-core
example_data/floating_wave_staggered_layout_scenario.py
1
31891
# -*- coding: utf-8 -*- """ Created on Thu Apr 09 10:39:38 2015 @author: 108630 """ import os import numpy as np import pandas as pd from datetime import datetime, timedelta from dtocean_core.utils.moorings import get_moorings_tables # Note that the electrical folder in the test_data directory should be # placed i...
gpl-3.0
RRCKI/pilot
RunJobHpcEvent.py
1
33653
# Class definition: # RunJobHpcEvent # This class is the base class for the HPC Event Server classes. # Instances are generated with RunJobFactory via pUtil::getRunJob() # Implemented as a singleton class # http://stackoverflow.com/questions/42558/python-and-the-singleton-pattern import commands import json ...
apache-2.0
dsten/datascience
tests/test_tables.py
1
53150
import doctest import re import pytest import warnings import numpy as np from numpy.testing import assert_array_equal from datascience import * import pandas as pd ######### # Utils # ######### @pytest.fixture(scope='function') def table(): """Setup Scrabble table""" return Table().with_columns([ '...
bsd-3-clause
qiime2/qiime2
qiime2/metadata/tests/test_io.py
1
46619
# ---------------------------------------------------------------------------- # 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
gfyoung/pandas
pandas/tests/groupby/transform/test_transform.py
1
38285
""" test with the .transform """ from io import StringIO import numpy as np import pytest from pandas.core.dtypes.common import ensure_platform_int, is_timedelta64_dtype import pandas as pd from pandas import ( Categorical, DataFrame, MultiIndex, Series, Timestamp, concat, date_range, ) i...
bsd-3-clause
ndingwall/scikit-learn
sklearn/gaussian_process/_gpc.py
2
34789
"""Gaussian processes classification.""" # Authors: Jan Hendrik Metzen <jhm@informatik.uni-bremen.de> # # License: BSD 3 clause from operator import itemgetter import numpy as np from scipy.linalg import cholesky, cho_solve, solve import scipy.optimize from scipy.special import erf, expit from ..base import BaseEst...
bsd-3-clause
perryjohnson/biplaneblade
biplane_blade_lib/prep_stn19_mesh.py
1
30753
"""Write initial TrueGrid files for one biplane blade station. Usage ----- start an IPython (qt)console with the pylab flag: $ ipython qtconsole --pylab or $ ipython --pylab Then, from the prompt, run this script: |> %run biplane_blade_lib/prep_stnXX_mesh.py or |> import biplane_blade_lib/prep_stnXX_mesh ...
gpl-3.0
supriyantomaftuh/innstereo
innstereo/layer_properties.py
1
42396
#!/usr/bin/python3 """ This module contains the layer properties dialog. Each dialog window has its own class that controls its behaviour. This module stores the AboutDialog-, PrintDialog-, StereonetProperties-, LayerProperties-, and FileChooserParse-class. """ from gi.repository import Gtk import matplotlib.colors ...
gpl-2.0
trichter/sito
imaging.py
1
81559
#!/usr/bin/env python # -*- coding: utf-8 -*- # by TR from matplotlib import cbook from matplotlib.mlab import psd from matplotlib.ticker import AutoMinorLocator, MaxNLocator from mpl_toolkits.axes_grid1 import make_axes_locatable from obspy.core import UTCDateTime from obspy.core.util import deprecated from sito.uti...
mit
d-lee/airflow
airflow/www/views.py
1
87584
# -*- 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
DGrady/pandas
pandas/core/indexes/multi.py
1
94565
# pylint: disable=E1101,E1103,W0232 import datetime import warnings from functools import partial from sys import getsizeof import numpy as np from pandas._libs import index as libindex, lib, Timestamp from pandas.compat import range, zip, lrange, lzip, map from pandas.compat.numpy import function as nv from pandas ...
bsd-3-clause
fidelram/deepTools
deeptools/plotProfile.py
1
38404
#!/usr/bin/env python # -*- coding: utf-8 -*- import sys import argparse import numpy as np import matplotlib matplotlib.use('Agg') matplotlib.rcParams['pdf.fonttype'] = 42 matplotlib.rcParams['svg.fonttype'] = 'none' import matplotlib.pyplot as plt from matplotlib.font_manager import FontProperties from matplotlib ...
gpl-3.0
herilalaina/scikit-learn
sklearn/preprocessing/data.py
1
106892
# 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
Erotemic/ibeis
ibeis/other/detectgrave.py
1
103398
# -*- coding: utf-8 -*- """Developer convenience functions for ibs (detections). TODO: need to split up into sub modules: consistency_checks feasibility_fixes move the export stuff to dbio then there are also convineience functions that need to be ordered at least within this file """ from __futur...
apache-2.0
ryandougherty/mwa-capstone
MWA_Tools/build/matplotlib/lib/matplotlib/backends/backend_gtk.py
1
43162
from __future__ import division import os, sys def fn_name(): return sys._getframe(1).f_code.co_name try: import gobject import gtk; gdk = gtk.gdk import pango except ImportError: raise ImportError("Gtk* backend requires pygtk to be installed.") pygtk_version_required = (2,4,0) if gtk.pygtk_version <...
gpl-2.0
claesenm/optunity-benchmark
optimizers/tpe/hyperopt_august2013_mod_src/hyperopt_installer/hyperopt-master/hyperopt/mongoexp.py
2
60046
""" Mongo-based Experiment driver and worker client =============================================== Components involved: - mongo e.g. mongod ... - driver e.g. hyperopt-mongo-search mongo://address bandit_json bandit_algo_json - worker e.g. hyperopt-mongo-worker --loop mongo://address Mongo ===== Mong...
gpl-3.0
ahkab/ahkab
ahkab/ahkab.py
1
34309
#!/usr/bin/env python # -*- coding: iso-8859-1 -*- # ahkab.py # The frontend of the simulator # Copyright 2006 Giuseppe Venturini # This file is part of the ahkab simulator. # # Ahkab is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Fr...
gpl-2.0
AstroVPK/kali
python/kali/mbhb.py
2
53365
#!/usr/bin/env python """ Module to model MBHBs. """ import numpy as np import math as math import scipy.stats as spstats import scipy.signal.spectral from scipy.interpolate import UnivariateSpline import cmath as cmath import random import sys as sys import abc as abc import psutil as psutil import types as types imp...
gpl-2.0
blaze/dask
dask/utils.py
1
41623
from datetime import datetime, timedelta import functools import inspect import os import shutil import sys import tempfile import re from errno import ENOENT from collections.abc import Iterator from contextlib import contextmanager from importlib import import_module from numbers import Integral, Number from threadin...
bsd-3-clause
cjayb/mne-python
mne/viz/utils.py
1
129999
# -*- coding: utf-8 -*- """Utility functions for plotting M/EEG data.""" # Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Denis Engemann <denis.engemann@gmail.com> # Martin Luessi <mluessi@nmr.mgh.harvard.edu> # Eric Larson <larson.eric.d@gmail.com> # Mainak Jas <mainak...
bsd-3-clause
PanDAWMS/panda-server
pandaserver/daemons/scripts/datasetManager.py
1
54467
import os import re import sys import time import datetime import traceback import threading import pandaserver.taskbuffer.ErrorCode import pandaserver.taskbuffer.ErrorCode from pandacommon.pandalogger.PandaLogger import PandaLogger from pandaserver.config import panda_config from pandaserver.dataservice.DDM import ru...
apache-2.0
dricciardelli/vae2vec
def_def_oh_ctc.py
1
37360
''' Significant lifting from https://jmetzen.github.io/2015-11-27/vae.html ''' import time import numpy as np import tensorflow as tf from tensorflow.python.ops import rnn import random import matplotlib.pyplot as plt import re, string from sklearn.feature_extraction.text import CountVectorizer from collections impo...
mit
gfyoung/pandas
pandas/tests/computation/test_eval.py
1
72020
from distutils.version import LooseVersion from functools import reduce from itertools import product import operator from typing import Dict, List, Type import warnings import numpy as np import pytest from pandas.compat import is_platform_windows, np_version_under1p17 from pandas.errors import PerformanceWarning im...
bsd-3-clause
BigDataforYou/movie_recommendation_workshop_1
big_data_4_you_demo_1/venv/lib/python2.7/site-packages/pandas/io/tests/json/test_ujson.py
1
56092
# -*- coding: utf-8 -*- from unittest import TestCase try: import json except ImportError: import simplejson as json import math import nose import platform import sys import time import datetime import calendar import re import decimal from functools import partial from pandas.compat import range, zip, Strin...
mit
MS047/XtraDataManager
XtraDataManager/FeaturesExploitation.py
1
48305
# -*- coding utf-8 -*- from __future__ import print_function # This script allows to use a scikit-learn.org classifier (supervised or unsupervised), # in order to sort kilosort/phy generated units according to their cell type # using their features, extracted thanks to the DataManager class written in FeaturesExtractio...
gpl-3.0
GuessWhoSamFoo/pandas
pandas/tests/indexes/datetimes/test_timezones.py
1
46581
# -*- coding: utf-8 -*- """ Tests for DatetimeIndex timezone-related methods """ from datetime import date, datetime, time, timedelta, tzinfo from distutils.version import LooseVersion import dateutil from dateutil.tz import gettz, tzlocal import numpy as np import pytest import pytz from pandas._libs.tslibs import c...
bsd-3-clause
avistous/QSTK
qstkutil/DataEvolved.py
1
34666
''' (c) 2011, 2012 Georgia Tech Research Corporation This source code is released under the New BSD license. Please see http://wiki.quantsoftware.org/index.php?title=QSTK_License for license details. Created on May 14, 2012 @author: Jeffrey Portman @contact: chromox@gmail.com @summary: <summary> ''' import os impor...
bsd-3-clause
kalleknast/GU_scan
GU_analyze.py
1
68850
# import the Stimfit input/output module: import stfio import numpy as np import matplotlib.pyplot as plt # For patches/fields in figures from matplotlib.patches import Rectangle, Circle from mpl_toolkits.axes_grid1.inset_locator import inset_axes # For saving the list of dicts produced by plt_cGlu_pos from pickle impo...
mit
evanbiederstedt/RRBSfun
epiphen/cll_tests/total_cells.py
1
32920
import glob import pandas as pd import numpy as np pd.set_option('display.max_columns', 50) # print all rows import os os.chdir("/gpfs/commons/home/biederstedte-934/evan_projects/correct_phylo_files") normalB = glob.glob("binary_position_RRBS_normal_B_cell*") mcell = glob.glob("binary_position_RRBS_NormalBCD19pCD27...
mit
igoumiri/pyMST
adhoc/functions.py
1
82864
# import functions (produces .pyc file) def b10tobx(x,b): # x is an integer in base 10 # b is the base for the desired result """Given (DECIMAL_INTEGER,BASE), this returns array of base multiples. It may lead to unexpected results for BASE greater than 10. """ import scipy as sp if x==0: d=1 ...
mit
uomsystemsbiology/LMMEL-miR-miner
create_TCGA_plots.py
1
42582
import os import csv import numpy as np import matplotlib.pyplot as plt __author__ = 'jcursons' # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # This script is used to analyse melanoma (SKCM) data from The Cancer Genome Atlas (TCGA) project, in p...
mit
ProfHoekstra/bluesky
bluesky/traffic/metric.py
1
52178
from time import time, gmtime, strftime import numpy as np import matplotlib.pyplot as plt from math import degrees import collections from collections import defaultdict import itertools as IT import bluesky as bs from bluesky.tools import geo from bluesky.tools.misc import tim2txt from bluesky.tools.aero import * fr...
gpl-3.0
lucarebuffi/OASYS1
oasys/widgets/error_profile/ow_abstract_height_profile_simulator.py
1
41559
import os, sys import numpy from PyQt5.QtCore import QRect, Qt from PyQt5.QtWidgets import QApplication, QMessageBox, QLabel, QSizePolicy from PyQt5.QtGui import QTextCursor, QFont, QPalette, QColor, QPixmap from srxraylib.metrology import profiles_simulation from matplotlib import cm from matplotlib.backends.backend...
gpl-3.0
grlee77/numpy
numpy/core/numeric.py
1
76347
import functools import itertools import operator import sys import warnings import numbers import numpy as np from . import multiarray from .multiarray import ( _fastCopyAndTranspose as fastCopyAndTranspose, ALLOW_THREADS, BUFSIZE, CLIP, MAXDIMS, MAY_SHARE_BOUNDS, MAY_SHARE_EXACT, RAISE, WRAP, arange, arr...
bsd-3-clause
blond-admin/BLonD
blond/beam/distributions_multibunch.py
1
39051
''' **Module to generate multibunch distributions** :Authors: **Danilo Quartullo**, **Alexandre Lasheen**, **Theodoros Argyropoulos** ''' from __future__ import division, print_function, absolute_import from builtins import range import numpy as np import copy import matplotlib.pyplot as plt from scipy.integrate impo...
gpl-3.0
pratapvardhan/pandas
pandas/core/series.py
1
135882
""" Data structure for 1-dimensional cross-sectional and time series data """ from __future__ import division # pylint: disable=E1101,E1103 # pylint: disable=W0703,W0622,W0613,W0201 import types import warnings from textwrap import dedent import numpy as np import numpy.ma as ma from pandas.core.accessor import Cac...
bsd-3-clause
boada/planckClusters
MOSAICpipe/legacy/CLUSTERpipe/find_position_SOI.py
1
50780
#!/usr/bin/env python from __future__ import division from __future__ import print_function from builtins import zip from builtins import map from builtins import range from builtins import object from past.utils import old_div import os import sys import glob import math from pyfits import getheader, getval #import a...
mit
USCLiquidPropulsionLaboratory/Engine-sizing-snake
LOX_IPA.py
1
35102
## LOX-IPA sim #@ Author Juha Nieminen #import sys #sys.path.insert(0, '/Users/juhanieminen/Documents/adamrocket') import RocketComponents as rc from physical_constants import poise, inches, Runiv, gallons, lbm, \ gearth, atm, psi, lbf from numpy import pi, linspace, cos, radians, sqrt, exp, log, array from scipy...
mit
toobaz/pandas
pandas/core/generic.py
1
381557
import collections from datetime import timedelta import functools import gc import json import operator import pickle from textwrap import dedent from typing import Callable, Dict, FrozenSet, List, Optional, Set import warnings import weakref import numpy as np from pandas._config import config from pandas._libs im...
bsd-3-clause
pratapvardhan/pandas
pandas/core/strings.py
1
92110
import numpy as np from pandas.compat import zip from pandas.core.dtypes.generic import ABCSeries, ABCIndex from pandas.core.dtypes.missing import isna, notna from pandas.core.dtypes.common import ( is_bool_dtype, is_categorical_dtype, is_object_dtype, is_string_like, is_list_like, is_scalar, ...
bsd-3-clause
plotly/plotly.py
packages/python/plotly/plotly/graph_objs/histogram2dcontour/_colorbar.py
1
73625
from plotly.basedatatypes import BaseTraceHierarchyType as _BaseTraceHierarchyType import copy as _copy class ColorBar(_BaseTraceHierarchyType): # class properties # -------------------- _parent_path_str = "histogram2dcontour" _path_str = "histogram2dcontour.colorbar" _valid_props = { "bg...
mit
jseabold/statsmodels
statsmodels/stats/tests/test_proportion.py
4
39422
# -*- coding: utf-8 -*- """ Created on Fri Mar 01 14:56:56 2013 Author: Josef Perktold """ import warnings import pytest import numpy as np import pandas as pd from numpy.testing import (assert_almost_equal, assert_equal, assert_array_less, assert_raises, assert_allclose) from statsmodels...
bsd-3-clause
zfrenchee/pandas
pandas/tests/reshape/test_concat.py
1
84574
from warnings import catch_warnings import dateutil import numpy as np from numpy.random import randn from datetime import datetime from pandas.compat import StringIO, iteritems, PY2 import pandas as pd from pandas import (DataFrame, concat, read_csv, isna, Series, date_range, ...
bsd-3-clause
CroatianMeteorNetwork/CMN-codes
triangulation/FF_bin_suite.py
1
49348
# coding=utf-8 # Copyright 2014 Denis Vida, denis.vida@gmail.com # The FF_bin_suite 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, version 2. # The FF_bin_suite is distributed in the hope that it will be # ...
gpl-2.0
jniediek/mne-python
mne/time_frequency/tfr.py
3
70609
"""A module which implements the time-frequency estimation. Morlet code inspired by Matlab code from Sheraz Khan & Brainstorm & SPM """ # Authors : Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> # Hari Bharadwaj <hari@nmr.mgh.harvard.edu> # Clement Moutard <clement.moutard@polytechniq...
bsd-3-clause
dfm/kplr
kplr/api.py
1
34372
# -*- coding: utf-8 -*- from __future__ import (division, print_function, absolute_import, unicode_literals) __all__ = ["API", "KOI", "Planet", "Star", "LightCurve", "TargetPixelFile"] import os import re import json import shutil import logging from itertools import product from functools im...
mit
phageghost/pg_tools
pgtools/myplots.py
1
65648
import os import matplotlib #matplotlib.use('Agg') import seaborn import matplotlib.pyplot as plt from mpl_toolkits.mplot3d import Axes3D import plotly.plotly as py import plotly.graph_objs as go import numpy import scipy import scipy.stats import pandas import itertools import sklearn.manifold import sklearn.decomposi...
mit
xiezhen/brilws
brilws/api.py
1
68398
import numpy as np import pandas as pd from sqlalchemy import exc,schema,types,Table,MetaData,Column from datetime import datetime import decimal import os import random import time #import yaml import re import contextlib import sys import ast import logging import string import collections import itertools from brilw...
mit
easytaxibr/airflow
airflow/contrib/hooks/bigquery_hook.py
1
39002
# -*- 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
ebilionis/py-best
best/gp/_multioutput_gaussian_process.py
1
50867
"""Define the Multioutput Gaussian Process model. Author: Ilias Bilionis Date: 11/20/2012 1/29/2013 (Made it conform to MarkovChainMonteCarlo class so that it can be used in conjuction with uq.random.SequentialMonteCarlo.) 1/31/2013 (Added sample_prediction.) 1/2/2013 (Adde...
lgpl-3.0
eclee25/flu-SDI-exploratory-age
scripts/exploratory_Fall2012/DrawCharts.py
1
45590
#!/usr/bin/python ############################################## ###Python template ###Author: Elizabeth Lee ###Date: 10/10/12 ###Function: Draw exploratory charts for SDI data ###Import data: A1, A2, A3, B3, C1, C2, C3 ###Command Line: ipython DrawCharts.py ############################################## ### notes #...
mit
CompPhysics/MachineLearning
doc/LectureNotes/_build/jupyter_execute/chapter5.py
1
38036
# Support Vector Machines, overarching aims A Support Vector Machine (SVM) is a very powerful and versatile Machine Learning method, capable of performing linear or nonlinear classification, regression, and even outlier detection. It is one of the most popular models in Machine Learning, and anyone interested in Machi...
cc0-1.0
PuzzleboxIO/jigsaw-python
Puzzlebox/Jigsaw/Interface_Plot.py
1
35556
# -*- coding: utf-8 -*- # Copyright Puzzlebox Productions, LLC (2010-2012) # # This code is released under the GNU Pulic License (GPL) version 2 # For more information please refer to http://www.gnu.org/copyleft/gpl.html __changelog__ = """\ Last Update: 2013.07.25 """ import os, sys import Puzzlebox.Jigsaw.Configu...
agpl-3.0
yjzhang/uncurl_python
uncurl/experiment_runner.py
1
38675
# general framework for running purity experiments on 10x dataset # two steps: dimensionality reduction/preprocessing, and clustering # preprocessing -> dim_red -> clustering? # ex. uncurl_mw -> tsne -> km??? # preprocessing returns a matrix of shape (k, cells), where k <= genes from __future__ import print_function ...
mit
workflo/dxf2gcode
python_examples/NURBS_fitting_by_Biarc_curves.py
1
69179
#!/usr/bin/python # -*- coding: cp1252 -*- # #NURBS_fittin_by_Biarc_curves #Programmer: Christian Kohlöffel #E-mail: n/A # #Copyright 2008 Christian Kohlöffel # #Distributed under the terms of the GPL (GNU Public License) # #dxf2gcode is free software; you can redistribute it and/or modify #it under the terms of th...
gpl-3.0
gkunter/coquery
coquery/gui/app.py
1
127835
# -*- coding: utf-8 -*- """ app.py is part of Coquery. Copyright (c) 2016-2018 Gero Kunter (gero.kunter@coquery.org) Coquery is released under the terms of the GNU General Public License (v3). For details, see the file LICENSE that you should have received along with Coquery. If not, see <http://www.gnu.org/licenses/...
gpl-3.0
zrisher/webapp-public
webapp/apps/taxbrain/helpers.py
1
34981
from collections import namedtuple import numbers import os import pandas as pd import dropq import sys import time #Mock some module for imports because we can't fit them on Heroku slugs from mock import Mock import sys MOCK_MODULES = ['numba', 'numba.jit', 'numba.vectorize', 'numba.guvectorize', 'mat...
mit
sinagolara/VRP
VRP-03 - .py
1
30150
# -*- coding: utf-8 -*- """ This program offers a heuristic solution to the Vehicle Routng Problem problem. The algorithm is based on two steps. The first step uses an improved adaptive Simulated Annealing meta-heuristic to minimize the number of routes. The basic SA is modified to adaptively adjust its search spa...
mit
DailyActie/Surrogate-Model
01-codes/numpy-master/numpy/linalg/linalg.py
1
77909
"""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
wolfier/incubator-airflow
airflow/www/views.py
1
103652
# -*- 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
fermiPy/fermipy
fermipy/plotting.py
1
57802
# Licensed under a 3-clause BSD style license - see LICENSE.rst from __future__ import absolute_import, division, print_function import copy import os import matplotlib import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec import matplotlib.patheffects as PathEffects from matplotlib.patches import Circ...
bsd-3-clause
wronk/mne-python
mne/viz/topomap.py
1
80040
"""Functions to plot M/EEG data e.g. topographies """ from __future__ import print_function # 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...
bsd-3-clause
felixfan/PyHLA
PyHLA.py
1
112728
#!/usr/bin/env python #coding=utf-8 from __future__ import division import statsmodels.formula.api as smf from collections import Counter import numpy as np import pandas as pd import scipy.stats import argparse import time import sys import random import math import os import string ###################### HLAcount ##...
gpl-2.0
albertoferna/compmech
compmech/panels/kpanels/kpanelcheb/kpanelcheb.py
1
52667
from __future__ import division import gc import os import sys import traceback from collections import Iterable import time import cPickle import __main__ import numpy as np from scipy.sparse import csr_matrix from scipy.sparse.linalg import eigsh from scipy.optimize import leastsq from numpy import linspace, cos, si...
bsd-3-clause
uglyboxer/linear_neuron
net-p3/lib/python3.5/site-packages/sklearn/tests/test_cross_validation.py
1
45109
"""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...
mit
RAPD/RAPD
src/plugins/merge/plugin.py
1
64460
"""Hierarchical clustering and merging of data for RAPD plugin""" """ This file is part of RAPD Copyright (C) 2017, Cornell University All rights reserved. RAPD is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Founda...
agpl-3.0
blaze/dask
dask/dataframe/tests/test_shuffle.py
1
36132
import itertools import os import random import tempfile from unittest import mock import pandas as pd import pytest import pickle import numpy as np import string import multiprocessing as mp from copy import copy import dask import dask.dataframe as dd from dask.dataframe._compat import tm, assert_categorical_equal...
bsd-3-clause
dricciardelli/vae2vec
capt_gen_aux_oh.py
1
38983
# -*- coding: utf-8 -*- import math import os import tensorflow as tf import numpy as np import pandas as pd import pickle import pickle as pkl import cv2 import skimage import random import tensorflow.python.platform from tensorflow.python.ops import rnn from keras.preprocessing import sequence from collections import...
mit
jwi078/incubator-airflow
airflow/www/views.py
1
83984
# -*- 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
tschaume/pymatgen
pymatgen/analysis/chemenv/coordination_environments/structure_environments.py
1
88719
# coding: utf-8 # Copyright (c) Pymatgen Development Team. # Distributed under the terms of the MIT License. """ This module contains objects that are used to describe the environments in a structure. The most detailed object (StructureEnvironments) contains a very thorough analysis of the environments of a given ato...
mit
Fokko/incubator-airflow
tests/gcp/hooks/test_bigquery.py
1
52970
# -*- 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
dsm054/pandas
pandas/core/indexes/category.py
1
31037
import operator import warnings import numpy as np from pandas._libs import index as libindex from pandas import compat from pandas.compat.numpy import function as nv from pandas.core.dtypes.generic import ABCCategorical, ABCSeries from pandas.core.dtypes.dtypes import CategoricalDtype from pandas.core.dtypes.common ...
bsd-3-clause
dsm054/pandas
pandas/tests/frame/test_missing.py
1
31857
# -*- coding: utf-8 -*- from __future__ import print_function import pytest from distutils.version import LooseVersion from numpy import nan, random import numpy as np import datetime import dateutil from pandas.compat import lrange from pandas import (DataFrame, Series, Timestamp, date_range, ...
bsd-3-clause
jaeilepp/mne-python
mne/inverse_sparse/mxne_optim.py
1
40259
from __future__ import print_function # Author: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> # Daniel Strohmeier <daniel.strohmeier@gmail.com> # # License: Simplified BSD from math import sqrt, ceil import numpy as np from scipy import linalg from .mxne_debiasing import compute_bias from ..ut...
bsd-3-clause
guangtunbenzhu/BGT-Cosmology
Examples/LRG-MgII/Sigma_MonteCarlo.py
1
52418
""" Sigma_MonteCarlo """ import numpy as np from scipy import interpolate import halomodel as hm import matplotlib.pyplot as plt from matplotlib import rc, rcParams rc('text', usetex=True) rcParams['text.latex.preamble']=[r"\usepackage{amsmath}"] CosPar={'Omega_M':0.3, 'Omega_L':0.7, 'Omega_b':0.045, 'Omega_nu':1e-5,...
mit
tyb0807/angr
angr/knowledge_plugins/functions/function.py
1
42667
import os import logging import networkx import string import itertools from collections import defaultdict import claripy from ...errors import SimEngineError, SimMemoryError from ...procedures import SIM_LIBRARIES l = logging.getLogger("angr.knowledge.function") class Function(object): """ A representati...
bsd-2-clause
jhpeterson/DXFtoMesh
DXFtoSegments.py
1
42441
#!/usr/bin/env python ''' Code Written by Jeff Peterson (2016) The DXFGeometry object in this file is the primary class. It can be used to read a DXF file and then convert the information into a form that can then be used in the construction of a computational mesh. This module should be imported into another script a...
mit
SiLab-Bonn/testbeam_analysis
testbeam_analysis/gui/gui_widgets/analysis_widgets.py
1
42912
""" Implements generic analysis widgets to apply analysis functions on test beam data. Two separate widgets to apply one analysis function in parallel to all input data and to apply multiple analysis functions to multiple input data """ import os import inspect import logging import math from subprocess import call f...
mit
jaeilepp/mne-python
mne/dipole.py
1
46536
"""Single-dipole functions and classes.""" # Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> # Eric Larson <larson.eric.d@gmail.com> # # License: Simplified BSD from copy import deepcopy from functools import partial import re import numpy as np from scipy import linalg from .cov impo...
bsd-3-clause
sknepneklab/SAMoS
utils/pvmodel/cellmesh.py
1
78048
from openmesh import * import writemesh as wr import ioutils as io from ioutils import omvec, OrderedSet import numpy as np from numpy.linalg import norm, eig import scipy.integrate as integrate import matplotlib.pyplot as plt from collections import OrderedDict from scipy.spatial import Delaunay from tmp_read_data...
gpl-3.0
woel0007/caravel
caravel/models.py
1
54161
"""A collection of ORM sqlalchemy models for Caravel""" from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals import functools import json import logging import textwrap from collections import namedtuple from copy import de...
apache-2.0
guaix-ucm/pyemir
emirdrp/tools/fit_boundaries.py
2
62586
# # Copyright 2008-2020 Universidad Complutense de Madrid # # This file is part of PyEmir # # PyEmir is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any l...
gpl-3.0
3kakakhel/pygw2sim
pygw2sim.py
1
71036
""" This module contains classes and data for gw2 simulation in general. :Author: purpleflame (ak.purpleflame@gmail.com) :License: GNU General Public License Version 3 Current Version To Do List ================================================================================ 0. Add boon and condition objects, fig...
gpl-3.0
matthewpklein/battsimpy
tests/full_1d_fvm_ida_broken.py
1
91385
import numpy import scipy.linalg import scipy.optimize from copy import deepcopy from matplotlib import pyplot as plt plt.style.use('classic') from assimulo.solvers import IDA from assimulo.problem import Implicit_Problem from scipy.signal import wiener, filtfilt, butter, gaussian from scipy.ndimage import filter...
gpl-3.0
iwelland/hop
hop/siteanalysis.py
1
58880
# $Id$ # Hop --- a framework to analyze solvation dynamics from MD simulations # Copyright (c) 2009 Oliver Beckstein <orbeckst@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...
lgpl-3.0
dssg/wikienergy
disaggregator/build/pandas/pandas/tseries/tests/test_base.py
1
45324
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, assert_isinstance from pandas.tseries.common import is_datetimelike from pandas import...
mit
eubr-bigsea/tahiti
migrations/versions/50e0ae9aa406f_refactoring_sklearn.py
1
32968
# coding=utf-8 """refactoring_sklearn Revision ID: 50e0ae9aa406f Revises: fef08022f308 Create Date: 2019-01-23 14:55:47.471104 """ import itertools from alembic import context from alembic import op from sqlalchemy import Integer, String from sqlalchemy.orm import sessionmaker from sqlalchemy.sql import table, column ...
apache-2.0
KgBC/just-dice-bot
just-dice-bot.py
1
40778
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Simple martingale bot for just-dice.com Copyright (c) 2013 KgBC <IFGIWg@tormail.org> 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 ...
gpl-2.0
metabolite-atlas/metatlas
metatlas/helpers/mzmine_helpers.py
1
49339
from __future__ import print_function import numpy as np import sys import json import pandas as pd import re import glob as glob import os from collections import defaultdict from xml.etree import cElementTree as ET import multiprocessing as mp import matplotlib.pyplot as plt import metatlas.metatlas_objects as meto...
bsd-3-clause
mcgratta/macfp-db
Utilities/macfp.py
1
30373
#!/usr/bin/env python3 """ macfp.py by Randy McDermott Feb 2020 Measurement and Computation of Fire Phenomena (MaCFP) Collection of functions for plotting and analysis """ import sys import matplotlib.pyplot as plt import numpy as np import pandas as pd def plot_to_fig(x_data,y_data,**kwargs): """ Create a ...
mit
MJuddBooth/pandas
pandas/tests/arithmetic/test_datetime64.py
1
95490
# -*- coding: utf-8 -*- # Arithmetic tests for DataFrame/Series/Index/Array classes that should # behave identically. # Specifically for datetime64 and datetime64tz dtypes from datetime import datetime, timedelta from itertools import product, starmap import operator import warnings import numpy as np import pytest im...
bsd-3-clause
linebp/pandas
pandas/tests/tseries/test_timezones.py
1
67637
# pylint: disable-msg=E1101,W0612 import pytest import pytz import dateutil import numpy as np from dateutil.parser import parse from pytz import NonExistentTimeError from distutils.version import LooseVersion from dateutil.tz import tzlocal, tzoffset from datetime import datetime, timedelta, tzinfo, date import pan...
bsd-3-clause
alephu5/Soundbyte
environment/lib/python3.3/site-packages/matplotlib/contour.py
1
66454
""" These are classes to support contour plotting and labelling for the axes class """ import warnings import matplotlib as mpl import numpy as np from numpy import ma import matplotlib._cntr as _cntr import matplotlib.path as mpath import matplotlib.ticker as ticker import matplotlib.cm as cm import matplotlib.color...
gpl-3.0
stechma2/samuraiAnalysis
samPlt.py
1
57977
""" samPlt ====== Common plotting routines for SAMURAI data. initMapPlot plotContour plotVec plotXS xsKDtree xsCrdCald multXSCrdCalc """ import pyart import cmocean import warnings import matplotlib as mpl # mpl.use('PDF') from matplotlib import pyplot as plt import numpy as np import num...
gpl-3.0