text stringlengths 12 1.05M | repo_name stringlengths 5 86 | path stringlengths 4 191 | language stringclasses 1
value | license stringclasses 15
values | size int32 12 1.05M | keyword listlengths 1 23 | text_hash stringlengths 64 64 |
|---|---|---|---|---|---|---|---|
#!/usr/bin/env python
from __future__ import print_function
## Author: Chris Wymant, c.wymant@imperial.ac.uk
## Acknowledgement: I wrote this while funded by ERC Advanced Grant PBDR-339251
##
## Overview:
ExplanatoryMessage = '''For each bam file in the list given as input, this
script does the following. The distribu... | BDI-pathogens/phyloscanner | tools/EstimateReadCountPerWindow.py | Python | gpl-3.0 | 14,576 | [
"pysam"
] | a88bd0e45e4c32af737cc7b9936d107dd92d9e7707dce5e2fe95da74b9ddc0dd |
# -*- coding: utf-8 -*-
# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or... | googleapis/python-workflows | tests/unit/gapic/executions_v1/test_executions.py | Python | apache-2.0 | 88,445 | [
"Octopus"
] | 2cac194953aefcf76cf2753d0e2bda04bb1d40eec4d2f94480aede087897c059 |
__author__ = 'stephen'
# ===============================================================================
# GLOBAL IMPORTS:
import os,sys
import numpy as np
import argparse
# ===============================================================================
# LOCAL IMPORTS:
HK_DataMiner_Path = os.path.relpath(os.pardir)
#... | stephenliu1989/HK_DataMiner | hkdataminer/scripts/test_dbscan.py | Python | apache-2.0 | 3,593 | [
"MDTraj"
] | 4f8f4b5d124136dfb812c371b30844b2e5fba3d490f787087fb75e2397329935 |
"""
The Job Path Agent determines the chain of Optimizing Agents that must
work on the job prior to the scheduling decision.
Initially this takes jobs in the received state and starts the jobs on the
optimizer chain. The next development will be to explicitly specify the
path through the optimizers.
"""
__... | marcelovilaca/DIRAC | WorkloadManagementSystem/Executor/JobPath.py | Python | gpl-3.0 | 4,241 | [
"DIRAC"
] | e68edc4c90c6033983b3456d3337918eb650ac9403990096baecdff0f32a2515 |
import pytest
import numpy as np
from cplpy import run_test, prepare_config
import os
# -----Velocities TESTS-----
# EXPLANATION:
MD_FNAME = "lammps_vels.in"
MD_ARGS = "-in " + MD_FNAME
MD_EXEC = "lmp_cpl"
CFD_FNAME = "dummyCFD.py"
CFD_ARGS = CFD_FNAME
CFD_EXEC = "python"
TEST_TEMPLATE_DIR = os.path.join(os.environ[... | Crompulence/cpl-library | examples/sockets/LAMMPS/LAMMPS-dev/cpl-socket/test/velocityP-C/test_vels.py | Python | gpl-3.0 | 3,494 | [
"LAMMPS"
] | 7adec9516a11cbcb51fe166f2941ac6fc7e9587d742e5b980b1701d9cbcc2a69 |
#!/usr/bin/env python
# Copyright 2014-2020 The PySCF Developers. 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
#
# U... | sunqm/pyscf | pyscf/pbc/grad/kuhf.py | Python | apache-2.0 | 3,969 | [
"PySCF"
] | 516b10364c48dff0be8b4867901cd238de4fc3cc28340f3392a95bb6cd1cade1 |
# $Id$
#
# Copyright (C) 2003-2006 greg Landrum and Rational Discovery LLC
#
# @@ All Rights Reserved @@
# This file is part of the RDKit.
# The contents are covered by the terms of the BSD license
# which is included in the file license.txt, found at the root
# of the RDKit source tree.
#
""" This functionality ... | jandom/rdkit | rdkit/DataStructs/BitEnsembleDb.py | Python | bsd-3-clause | 1,571 | [
"RDKit"
] | 624d525b88e46dfb6e165688ff7ea5350fc659462f1733aadcca09bc3328ac3b |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
import unittest
import pickle
import os
import numpy as np
import warnings
import scipy.constants as const
from pathlib import Path
from monty.tempfile import ScratchDir
from pymatgen.util.testing import Pymat... | fraricci/pymatgen | pymatgen/io/vasp/tests/test_inputs.py | Python | mit | 33,414 | [
"VASP",
"pymatgen"
] | 9e225fee51fc872239b87585f6f39d56f3e1ebd9ef5ba0bd1a3ff20f0f18d4c3 |
# -*- coding: utf-8 -*-
"""
@author: zhoujiagen
Created on 15/07/2019 10:16 AM
"""
def construct_test(rule_file_path):
"""构造测试方法."""
with open(rule_file_path) as f:
for rule_raw in f:
rule = rule_raw[0:-1]
rule_capitalize = rule[0].upper() + rule[1:]
print("""
... | zhoujiagen/giant-data-analysis | data-models/datamodel-logic/src/test/resources/test_antlr_rule.py | Python | mit | 2,331 | [
"VisIt"
] | ccdacb1f4cbf9704d92eeb07886d30face17a985f155d62efa3affaa7898917b |
##############################################################################
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-64... | lgarren/spack | var/spack/repos/builtin/packages/netcdf/package.py | Python | lgpl-2.1 | 10,483 | [
"NetCDF"
] | c50fcd9834a6c0704dc1ca7faeb6ade49b8a4b7354e5bc4df4304f9cbb2c43a0 |
#!/usr/bin/python
# -*- coding: utf-8 -*-
from scipy import exp
from scipy import __version__
from scipy.constants import pi, Avogadro
if int(__version__.split(".")[1]) < 10:
from scipy.constants import Bolzmann as Boltzmann
else:
from scipy.constants import Boltzmann
from lib.meos import MEoS
from lib import... | edusegzy/pychemqt | lib/mEoS/Methanol.py | Python | gpl-3.0 | 14,895 | [
"Avogadro"
] | 5eb19844ec4ee06e4d757b04dee2515df86ab228172b3a89efcc24be0c240fbb |
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# --- BEGIN_HEADER ---
#
# jobschedule - shared scheduling functions
# Copyright (C) 2003-2010 The MiG Project lead by Brian Vinter
#
# This file is part of MiG.
#
# MiG is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public Li... | heromod/migrid | mig/shared/jobschedule.py | Python | gpl-2.0 | 1,013 | [
"Brian"
] | 01adec3fe4dd4a35ebe2046d80a097be6c1def4f437c58a0e956806d5f3de041 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
from __future__ import division, unicode_literals, print_function
import math
import re
import os
import textwrap
import warnings
from collections import OrderedDict, deque
import six
from six.moves import zi... | aykol/pymatgen | pymatgen/io/cif.py | Python | mit | 35,271 | [
"Avogadro",
"CRYSTAL",
"pymatgen"
] | e5b672bf6fdd021daf9d5e8610a3530148b21bd2431c38801febf43b7e88829a |
from jinja2.ext import Extension
import os
from pyjade import Parser, Compiler as _Compiler
from pyjade.runtime import attrs
from jinja2.debug import fake_exc_info
from pyjade.utils import process
ATTRS_FUNC = '__pyjade_attrs'
class Compiler(_Compiler):
def visitCodeBlock(self,block):
self.buffer('{%% blo... | xlk521/cloudguantou | pyjade/ext/jinja.py | Python | bsd-3-clause | 3,086 | [
"VisIt"
] | 974ebc7963b6dd2d081430ed719de0af85d3e9b246cfd9575a52b8fe775bcae5 |
from __future__ import division
import numpy as np
from auxiliary import rotation_matrix2 as rotation_matrix
import time
def compute_S_matrix_fast(zdir, xtal):
'''
Computes the compliance and stiffness matrices S and C a given z-direction.
The x- and y-directions are determined automatically
'... | aripekka/pytakagitaupin | smatrix.py | Python | mit | 4,871 | [
"CRYSTAL"
] | ec90fa3242a998b4f19863e7948e40253f65f9ed93a94ffbcbccf82f5a604e66 |
# commands.py - command processing for mercurial
#
# Copyright 2005-2007 Matt Mackall <mpm@selenic.com>
#
# This software may be used and distributed according to the terms of the
# GNU General Public License version 2 or any later version.
from node import hex, nullid, nullrev, short
from lock import release
from i18... | iluxa-com/mercurial-crew-tonfa | mercurial/commands.py | Python | gpl-2.0 | 141,490 | [
"VisIt"
] | 613f2e4a3c100f75b2c92341db7aa74111eb615d072b69e471de770728237b8b |
#! /usr/bin/env python
import sys, csv
from functools import partial
e_cutoff = 1e-3
def printHelp():
sys.exit("NAME\n\treciprocalCompare: A tool for sorting through the results of a reciprocal blast.\nSYNOPSIS\n\treciprocalCompare --help\n\treciprocalCompare [-[|]e12] [-s] file1 file2 [outputfile]\nDESCRIPTION\n\... | mattsoulanille/Protein-reciprocal-compare | reciprocalCompare.py | Python | mit | 4,727 | [
"BLAST"
] | a711428801f71bf03f9bdbaaadc96eeacc557f63d3235862699c33179b088c43 |
from gpaw import GPAW
from ase.structure import bulk
from ase.dft.kpoints import ibz_points, get_bandpath
import numpy as np
si = bulk('Si', 'diamond', a=5.459)
if 1:
k = 6
calc = GPAW(kpts=(k, k, k),
xc='PBE')
si.set_calculator(calc)
e = si.get_potential_energy()
efermi = calc.get... | qsnake/gpaw | doc/exercises/band_structure/Si_guc.py | Python | gpl-3.0 | 1,475 | [
"ASE",
"GPAW"
] | c60def6a84ba09364713ca35100ba2a4a6e3078e7ffa7b7687f2a6f036f41861 |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('whsites', '0002_auto_20150102_1905'),
('members', '0001_initial'),
]
operations = [
migrations.AddField(
... | robjordan/unesco_project | unesco/members/migrations/0002_member_visits.py | Python | apache-2.0 | 494 | [
"VisIt"
] | 6fe79cf866c7ae01cfd05c878c7632c98c55edd7d6a65601f923eb8295d796de |
#!/usr/bin/env python
import sys
import os
import numpy as np
from datetime import datetime
"""
Obtain a tight binding Hamiltonian of Haldane model with Wannier90 format
How to run
python haldane_hr_gen.py
This will generate the tight binding hamiltonian Haldane_hr.dat
LATTICE
Angstrom
2.1377110 -1.2342080 0.00... | quanshengwu/wannier_tools | examples/Haldane_model/haldane_hr_gen-gapless.py | Python | gpl-3.0 | 3,153 | [
"Wannier90"
] | faf21bc9b0bc4faa2ccedea1d668cb3a194ef83412355f65b4635b391f83521f |
#
# Copyright (C) 2017-2019 The ESPResSo project
#
# This file is part of ESPResSo.
#
# ESPResSo is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later... | espressomd/espresso | testsuite/python/rescale.py | Python | gpl-3.0 | 2,433 | [
"ESPResSo"
] | 954330782f1c337e824dde20d31c245f8d378a9bccf65fcdff81119150aeef86 |
"""User-friendly public interface to polynomial functions. """
from sympy.core import (
S, Basic, Expr, I, Integer, Add, Mul, Dummy, Tuple, Rational
)
from sympy.core.mul import _keep_coeff
from sympy.core.sympify import (
sympify, SympifyError,
)
from sympy.core.decorators import (
_sympifyit,
)
from ... | amitjamadagni/sympy | sympy/polys/polytools.py | Python | bsd-3-clause | 155,247 | [
"Gaussian"
] | ca816075a8fdd2e063d44e6a12dcd767c12c120d2e8f4bd91b0f6f796582f75b |
from itertools import combinations_with_replacement
import numpy as np
from scipy import ndimage as ndi
from scipy import stats
from ..util import img_as_float
from ..feature import peak_local_max
from ..feature.util import _prepare_grayscale_input_2D
from ..feature.corner_cy import _corner_fast
from ._hessian_det_ap... | rjeli/scikit-image | skimage/feature/corner.py | Python | bsd-3-clause | 26,730 | [
"Gaussian"
] | 2445f085ffe7626cff856681c66e3df05e1ecfe40a35b49711d2a04e18eacff2 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# lm.py
"""
A python implementation of Levenberg–Marquardt.
exposes a drop in replacement for scipy.curve_fit and
allows the user to fit their function by maximizing the
maximum likelihood for poisson deviates rather than for
gaussian deviates, requires the jacobian to be ... | david-hoffman/dphutils | lm.py | Python | apache-2.0 | 23,083 | [
"Gaussian"
] | 14fd014102f56719ca5686adf83028a35542c1690d97d5edc961cfa75c30307a |
#!/usr/bin/env python
# NetView P v.0.7.1 - Windows
# Dependencies: PLINK
# Eike Steinig
# Zenger Lab, JCU
# https://github.com/esteinig/netview
import os
import time
import json
import shutil
import argparse
import subprocess
import numpy as np
import multiprocessing as mp
import scipy.sparse.csgraph as csg
import sc... | esteinig/netviewP | program/win/0.7.1/netview.py | Python | gpl-2.0 | 37,628 | [
"Biopython"
] | 20078e31b111eb7a69feeeabb90e73ca157addd89cce1bc7cc6e26b70b5cb9a2 |
# -*- coding: utf-8 -*-
# Copyright (c) 2015 Audun Gravdal Johansen
"""
"""
import numpy as np
from struct import pack
from base64 import b64encode
from ..exceptions import VtkError
# index arrays to reorder element connectivity - keys are SESAM element id's
sesam2vtk_connectivity = {23 : np.array([0,2,1]),
... | agrav/freesif | freesif/utils/writers.py | Python | mit | 7,490 | [
"VTK"
] | b40463db336a93c2db32f9208d0ff8768cb84ac50092bc9190a20aceca3faf4a |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from setuptools import setup
import numpy
# Version number
version = '1.0'
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(name = 'DGP',
version = version,
author = read('AUTHORS.txt'),
author_ema... | zhenwendai/DeepGP | setup.py | Python | bsd-3-clause | 1,434 | [
"Gaussian"
] | f0562e6d9652ba362948d83753f29945093281238f66dacc9c3686078bd16c1c |
"""
Extensions to SQLAlchemy for altering existing tables.
At the moment, this isn't so much based off of ANSI as much as
things that just happen to work with multiple databases.
"""
import StringIO
import sqlalchemy as sa
from sqlalchemy.schema import SchemaVisitor
from sqlalchemy.engine.default import Defa... | SohKai/ChronoLogger | web/flask/lib/python2.7/site-packages/migrate/changeset/ansisql.py | Python | mit | 10,694 | [
"VisIt"
] | 9973ec7115304d222dfc7595345d035871e63505a6a02384c63316f2231a172c |
import sys
import os.path
import scipy
import numpy
import partial_terms as pt
import kernels
from numpy.linalg.linalg import LinAlgError
from scg_adapted import SCG_adapted
D = 3
Q = 2
M = 10
N = {}
Y = {}
X_mu = {}
X_S = {}
Kmm = {}
Kmm_inv = {}
accumulated_statistics = {}
flat_global_statistics_... | markvdw/GParML | scg_adapted-example.py | Python | bsd-3-clause | 13,706 | [
"Gaussian"
] | 6fb70fdf0c180fcdc9691bb80980030f934411ff1ce31377c57dcd0d24358d10 |
#! /usr/bin/env python
from openturns import *
TESTPREAMBLE()
RandomGenerator().SetSeed(0)
aCollection = DistributionCollection(0);
R = CorrelationMatrix(2)
R[0, 1] = -0.99
aCollection.add( Normal([-1.0, 1.0], [1.0, 1.0], R) )
R[0, 1] = 0.99
aCollection.add( Normal([1.0, 1.0], [1.0, 1.0], R) )
# Instanciate one di... | dbarbier/privot | python/test/t_ExpertMixture_std.py | Python | lgpl-3.0 | 975 | [
"MOE"
] | da6ccb60fcc96a5e1ab5a91824021fbd1c44d76a825b25fd888f5fe15842772c |
#!/usr/bin/env python
"""
ugrid classes
set of classes for working with unstructured model grids
The "ugrid" class is the base class: it stores everything in memory
It can read from and write to netcdf files in the UGRID format.
It may be able to reference a netcdf file at some point, rather than storing
directly ... | NOAA-ORR-ERD/gridded | gridded/pyugrid/ugrid.py | Python | unlicense | 44,524 | [
"NetCDF"
] | ba439e4bcdcccc6fcc28df7f58d14eb09da4cf9e0843d5c94d9e0666e7419ca0 |
# This is a Command Line SWD,BITS PILANI Searcher (Python)
# Make sure you are connected on BITS,Pilani LAN.
# Make Sure you are using LINUX
# Run the Python FIle from the Terminal as : python swd_query.py
from splinter import Browser
import os,splinter
def return_results(browser) :
# Find and click t... | devenbansod/SWD-Query | swd-query.py | Python | gpl-2.0 | 2,302 | [
"VisIt"
] | d0273637c753c551fabea703d6ecff71cfe0f9b767afdfadc444813c8450006e |
"""annotate fusion outputs from STAR and Tophat
Supported:
oncofuse: http://www.unav.es/genetica/oncofuse.html
github: https://github.com/mikessh/oncofuse
"""
from __future__ import print_function
import os
import pysam
from bcbio.utils import file_exists
from bcbio.distributed.transaction import file_transaction... | guillermo-carrasco/bcbio-nextgen | bcbio/rnaseq/oncofuse.py | Python | mit | 7,201 | [
"pysam"
] | a4a355fbc7d500dadf7f191b5ef2af84dd1aa3bef945d4fb7bdb5c873590e41f |
# -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
"""
Miscellaneous tools used by OpenERP.
"""
import cProfile
import collections
import datetime
import hmac as hmac_lib
import hashlib
import io
import os
import pickle as pickle_
import re
import socket
import subproce... | rven/odoo | odoo/tools/misc.py | Python | agpl-3.0 | 54,452 | [
"VisIt"
] | 1d733e45291c7ec89d4e40f421f339e230fa371099a639a92567deef320e06eb |
"""
Copyright (c) 2009 John Markus Bjoerndalen <jmb@cs.uit.no>,
Brian Vinter <vinter@nbi.dk>, Rune M. Friborg <rune.m.friborg@gmail.com>.
See LICENSE.txt for licensing details (MIT License).
"""
import sys
from pycsp_import import *
elements = 64
@process
def element(this_read, next_write):
while True:
... | runefriborg/pycsp | examples/TokenRing.py | Python | mit | 1,454 | [
"Brian"
] | 3b14d6540fc684b5aed441f54bf3338b7b2303e44f469763db782ac444e1aabc |
"""
CP decomposition by classic alternating least squares (ALS).
Author: N. Benjamin Erichson <erichson@uw.edu> and Alex H. Williams
"""
import numpy as np
from tensortools.operations import unfold, khatri_rao
from tensortools.tensors import KTensor
from tensortools.optimize import FitResult, optim_utils
def ncp_b... | ahwillia/tensortools | tensortools/optimize/ncp_bcd.py | Python | mit | 6,015 | [
"Gaussian"
] | 01d658cd440c3a89f5f0a4062947da44527a39a2aad385989360cd90cc651b7d |
import unittest
from pyramid import testing
class TutorialViewTests(unittest.TestCase):
def setUp(self):
self.config = testing.setUp()
def tearDown(self):
testing.tearDown()
def test_home(self):
from tutorial.views import home
request = testing.DummyRequest()
res... | FedericoStra/pyramid_tutorial | 07_views/tests/test_views.py | Python | mit | 869 | [
"VisIt"
] | 43d62fe5635249bfc1bbd35e0354cf4ef3cf2f886df740afe333a3fa8c8d4aa1 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2016
# Author(s):
# Thomas Leppelt <thomas.leppelt@dwd.de>
# This file is part of sauventory.
# Spatial Autocorrelated Uncertainty of Inventories
# sauventory is free software: you can redistribute it and/or modify
# it under the terms of the GNU Gener... | m4sth0/sauventory | tests/test_variogram.py | Python | gpl-3.0 | 13,270 | [
"Gaussian"
] | 45a9a11eb05e3160c3526184095c95ec16b84e90c224d2ffc703a72c4aad84e0 |
from brian import *
class AbstractNeuronGroup(NeuronGroup):
'''
Extends NeuronGroup to include additional methods
'''
def get_parameters(self):
'''Return a dictionary of parameter names and values'''
raise NotImplementedError('Not implemented yet')
def save_parameters(self, ou... | blennon/MLI_PKJ_net | MLI_PKJ_net/abstract_neuron_group.py | Python | mit | 509 | [
"Brian"
] | 02e7e171fc4bddeb30eccb67d9b62a8d502f2c5c497ef2eb7805a7729ed3d3b8 |
# class generated by DeVIDE::createDeVIDEModuleFromVTKObject
from module_kits.vtk_kit.mixins import SimpleVTKClassModuleBase
import vtk
class vtkBlankStructuredGridWithImage(SimpleVTKClassModuleBase):
def __init__(self, module_manager):
SimpleVTKClassModuleBase.__init__(
self, module_manager,
... | chrisidefix/devide | modules/vtk_basic/vtkBlankStructuredGridWithImage.py | Python | bsd-3-clause | 544 | [
"VTK"
] | 66e646e4e3b758074ae7bed9a4f32cb1a7bec6a94fdaad83be089ec8fbe58e04 |
import sys
import numpy as np
import time
import moose
print('Using moose from %s' % moose.__file__ )
compt = moose.CubeMesh( '/compt' )
compt.volume = 1e-20
pools = []
for r in range( 10 ):
a1 = moose.Pool( '/compt/a1%s' % r )
a1.concInit = 10
a2 = moose.Pool( '/compt/a2%s' % r )
a2.concInit = 5
... | subhacom/moose-core | tests/python/test_ksolve.py | Python | gpl-3.0 | 1,677 | [
"MOOSE"
] | 06f594d2b51d42d405c739ea56cf602b0fdc6eb40588efba41eb3309a332f2f3 |
#!/usr/bin/env python3
# License MIT
# Copyright 2016-2021 Alex Winkler
# Version 3.0.0
wikibaseurl = 'https://liquipedia.net/'
wikis = [
'ageofempires',
'apexlegends',
'arenafps',
'arenaofvalor',
'artifact',
'autochess',
'battalion',
'battlerite',
'brawlstars',
'callofduty',
'clashroyale',
'commons',
'... | FO-nTTaX/Liquipedia-Discord-Bot | ftsbot/data.py | Python | mit | 2,734 | [
"MOE"
] | 9737b9d4c5721e91dc5835b26c8d2f0cea284cfba7ffffd94ebed239d394b22e |
../../../../../../../share/pyshared/orca/scripts/apps/ekiga/script.py | Alberto-Beralix/Beralix | i386-squashfs-root/usr/lib/python2.7/dist-packages/orca/scripts/apps/ekiga/script.py | Python | gpl-3.0 | 69 | [
"ORCA"
] | 68a676fe914f9c00e236e33f39a055c69abb2b00e4140f9be0058b9106e7118b |
#
# Copyright (c) 2017 nexB Inc. and others. All rights reserved.
# http://nexb.com and https://github.com/nexB/scancode-toolkit/
# The ScanCode software is licensed under the Apache License version 2.0.
# Data generated with ScanCode require an acknowledgment.
# ScanCode is a trademark of nexB Inc.
#
# You may not use... | yashdsaraf/scancode-toolkit | src/commoncode/fileutils.py | Python | apache-2.0 | 18,906 | [
"VisIt"
] | 90bbd276555c94cbe366651aa7b8ebffc1a070b27efef295490d39beb47ff647 |
# Copyright 2021 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... | tensorflow/privacy | tensorflow_privacy/privacy/analysis/rdp_privacy_accountant.py | Python | apache-2.0 | 20,608 | [
"Gaussian"
] | 924c09bbfd4d8602085a9757a393353163b13baf743f7103832cfa95f7e43d96 |
"""Bayesian Gaussian Mixture Models and
Dirichlet Process Gaussian Mixture Models"""
from __future__ import print_function
# Author: Alexandre Passos (alexandre.tp@gmail.com)
# Bertrand Thirion <bertrand.thirion@inria.fr>
#
# Based on mixture.py by:
# Ron Weiss <ronweiss@gmail.com>
# Fabian Ped... | MechCoder/scikit-learn | sklearn/mixture/dpgmm.py | Python | bsd-3-clause | 35,901 | [
"Gaussian"
] | bddfe03e1ba3526cbbcc9aae9f1612d460a053726d248f1bec82288294b17452 |
import matplotlib
matplotlib.use('Agg')
import numpy as np
import netCDF4
from datetime import datetime
import pyroms
import pyroms_toolbox
import sys
def create_HYCOM_file(name, time, lon, lat, var):
#create netCDF file
nc = netCDF4.Dataset(name, 'w', format='NETCDF3_64BIT')
nc.Author = sys._getframe(... | dcherian/pyroms | examples/Arctic_HYCOM/get_hycom_GLBa0.08_ssh_2014.py | Python | bsd-3-clause | 4,297 | [
"NetCDF"
] | 2f9d8da07c1c826296b7ea7efdd629fb542a5f3f194cbdc5067da87ab9b81b66 |
import numpy as np
from ase.optimize.optimize import Optimizer
class MDMin(Optimizer):
def __init__(self, atoms, restart=None, logfile='-', trajectory=None,
dt=None):
Optimizer.__init__(self, atoms, restart, logfile, trajectory)
if dt is not None:
self.dt = dt
d... | grhawk/ASE | tools/ase/optimize/mdmin.py | Python | gpl-2.0 | 986 | [
"ASE"
] | 0f3be96a2dc108cd79c1e4000ebf7b9d5d1659c315b605546e8069a02296d5ed |
import logging
import logging.config
import struct
import threading
import traceback
import signal
from ambercommon.common import runtime
import os
from amberdriver.common import drivermsg_pb2
__author__ = 'paoolo'
LEN_SIZE = 2
LOGGER_NAME = 'AmberPipes'
pwd = os.path.dirname(os.path.abspath(__file__))
logging.c... | showmen15/testEEE | src/amberdriver/common/amber_pipes.py | Python | mit | 6,730 | [
"Amber"
] | c0121bcff2940868e7be54a741e2e0ad72812f59074721bd8465349754cec710 |
from __future__ import print_function, absolute_import, division
from future.builtins import *
from future import standard_library
standard_library.install_aliases()
# Copyright 2017 Autodesk Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with ... | Autodesk/molecular-design-toolkit | moldesign/interfaces/tleap_interface.py | Python | apache-2.0 | 12,300 | [
"Amber",
"NWChem"
] | 002610ecf7e306763beca6adc57ba1eda0c4d93e113a1d6202bf8f3686177125 |
# Mask Module
import numpy as np
def mask_classic(center, r, shape):
"""Return the mask function in the image space I defined by shape (see MIS). The classic mask takes the center of a
circle center = (xc,yc) and its radius r and put 1 if the image space is inside the circle and 0 outside. In
addition, ... | slimpotatoes/STEM_Moire_GPA | src/mask.py | Python | bsd-3-clause | 2,214 | [
"Gaussian"
] | e4383c6d48d37259b50aa188b5fbe17adcd904fe6e65f627b2eaa727fdc109ab |
# Copyright 2015 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | zlpmichelle/crackingtensorflow | cifar10/cifar10.py | Python | apache-2.0 | 14,729 | [
"Gaussian"
] | 88ac565279110f6b5a36ac41d0136b4f567f3fd18acda5473d0b6efaf49c294d |
#!/usr/bin/python3
from __future__ import print_function
from vizdoom import *
import sys
import threading
import math
from random import choice
from time import sleep
from matplotlib import pyplot as plt
sys.path.append('../../deep_feedback_learning')
import numpy as np
import cv2
import deep_feedback_learning
# ... | nlholdem/icodoom | ICO1/deep_feedback_learning_old/vizdoom/backprop1.py | Python | gpl-3.0 | 8,991 | [
"NEURON"
] | 96072eb3af3685288814fb3e7bfe3576f83c4e6c3f8614791ab2a8b419f2cf88 |
"""Labels PDB file with site entropies.
To run this script, open ``pymol`` in the directory where the script is found.
Then at the ``pymol`` command line type::
run entropy_label_PDB.py
This script was written by Jesse Bloom, 2014."""
import mapmuts.io
import mapmuts.bayesian
def main():
"""Main body of ... | jbloom/mapmuts | examples/WSN_HA_2014Analysis/entropy_label_PDB.py | Python | gpl-3.0 | 3,685 | [
"PyMOL"
] | 1cd2d35405b36bc603e4506cc71204a7c84096bcec5c313a67298ab3e7225905 |
import numpy as np
from rdkit import Chem
import os.path as osp
from mastic.selection import CoordArray, IndexedSelection, Selection, \
GenericSelection
from mastic.molecule import Bond, Molecule, Atom, \
MoleculeType, AtomType, BondType
from mastic.interfaces.rdkit import RDKitMoleculeWrapper
import mastic.... | salotz/mast | prototypes/molecule_example.py | Python | mit | 5,003 | [
"RDKit"
] | 513bba67ad258a571e804c4a2778a8c1b5b737112018bcdf1ae0b0414805f25d |
from openbabel import OBMol, OBConversion, pybel
import re
inchi_validator = re.compile('InChI=[0-9]S?\\/')
# This function only validates the first part. It does not guarantee
# that the entire InChI is valid.
def validate_start_of_inchi(inchi):
if not inchi_validator.match(inchi):
raise Exception('Inv... | OpenChemistry/mongochemserver | flask/openbabel/src/openbabel_api.py | Python | bsd-3-clause | 3,803 | [
"Open Babel",
"Pybel"
] | f72408618243eddec47e5e18e70d3e9da9025b565b11c2e08d011bac5646ac48 |
# -*-python-*-
#
# Copyright (C) 1999-2006 The ViewCVS Group. All Rights Reserved.
#
# By using this file, you agree to the terms and conditions set forth in
# the LICENSE.html file which can be found at the top level of the ViewVC
# distribution or at http://viewvc.org/license-1.html.
#
# For more information, visit h... | foresthz/fusion5.1 | www/scm/viewvc/lib/vclib/ccvs/rcsparse/texttools.py | Python | gpl-2.0 | 8,816 | [
"VisIt"
] | 370033af1c150e6582b28afaa5cacbc7fcbf1b1f38d9bebd66856f71ae59989d |
###############################################################################
# Implementation of kernel multi-view spectral algorithm of Song et al. (2014)
#
# Author: E.D. Gutierrez (edg@icsi.berkeley.edu)
# Created: 24 March 2016
# Last modified: 29 March 2016
#
# Sample usage: see knbTest.py. The main fun... | anapophenic/knb | kernelNaiveBayes.py | Python | cc0-1.0 | 16,306 | [
"DIRAC",
"Gaussian"
] | a01bf52fc35f05e86566a98fd1842e9ca66a58b18197b430c4b65b6be2879710 |
import sys
import os
import deepchem
import tempfile, shutil
import numpy as np
import numpy.random
from bace_datasets import load_bace
from deepchem.utils.save import load_from_disk
from deepchem.splits import SpecifiedSplitter
from deepchem.data import Dataset
from deepchem.hyper import HyperparamOpt
from deepchem im... | bowenliu16/deepchem | examples/bace/bace_dnn.py | Python | gpl-3.0 | 4,706 | [
"CRYSTAL"
] | 69ffbddf7aef1ba1f702f153c1eb708c5df89d42e227d68cc2c88a13c7faa287 |
from __future__ import unicode_literals
from test import TestCase
from web import app
from db import session, User
from nose.tools import eq_
class TestSignup(TestCase):
def test_sign_up(self):
app.test_client().post('/', data={'email': 'andrew@lorente.name'})
users = session().query(User.email)... | ErinCall/splinter_demo | flask/test/test_signup.py | Python | mit | 1,095 | [
"VisIt"
] | 102cdbc3a85a41bba14ace69b329a323147333a9e03f094833be847bef7edbe3 |
#!/usr/bin/env python
from itertools import groupby
import os
import re
import sys
from bokeh.io import output_file, show, save
from bokeh.layouts import gridplot, column
from bokeh.models import Range1d, ColumnDataSource, HoverTool, CrosshairTool
from bokeh.palettes import Category20, brewer, viridis
from bokeh.plot... | ricardog/raster-project | attic/hpd-check.py | Python | apache-2.0 | 7,605 | [
"NetCDF"
] | 9a046499fac20fc28849f5db0e5aa25ca63bbc6d36ae194d3bd20bffb6b5a063 |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2016 Johnathan "Shaggytwodope" Jenkins <twodopeshaggy@gmail.com>
#
# Distributed under terms of the GPL2 license.
import os
import sys
import urllib.request
import webbrowser
import subprocess
import fcntl
import tkinter
from configparser ... | linuxlite/litecontrolcenter | usr/share/litecc/lite-controlcenter.py | Python | gpl-2.0 | 15,981 | [
"Brian"
] | 19a89de19b09c4dfb52fa1d5ae27c4554ee925b00b89b1005fe74ea123da873a |
# -*- coding: utf-8 -*-
"""
This file contains methods for lorentzian-like fitting, these methods
are imported by class FitLogic.
Qudi 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 Licen... | drogenlied/qudi | logic/fitmethods/lorentzianlikemethods.py | Python | gpl-3.0 | 32,566 | [
"Gaussian"
] | 5b170faf03680df9f1f43972961c9688380bf6c4bea98d0df75389e5abf9a81e |
import numpy as np
import warnings
import GPy
def get_slices(input_list):
num_outputs = len(input_list)
_s = [0] + [ _x.shape[0] for _x in input_list ]
_s = np.cumsum(_s)
slices = [slice(a,b) for a,b in zip(_s[:-1],_s[1:])]
return slices
def build_XY(input_list,output_list=None,index=None):
n... | ptonner/GPy | GPy/util/multioutput.py | Python | bsd-3-clause | 3,588 | [
"Gaussian"
] | 014331d664d31bbbe9b612f02bc782c15ac1aa134ce35a867ba7955b7c94a9be |
# -----------------------------------------------------------------------------
# Copyright (c) 2016+ Buro Petr van Blokland + Claudia Mens & Font Bureau
# www.pagebot.io
#
# P A G E B O T
#
# Licensed under MIT conditions
# Made for usage in DrawBot, www.drawbot.com
# ------------------------------... | JaspervanBlokland/SandyApp | src/Toon/CartierMagazine_800_1018.py | Python | mit | 9,078 | [
"VisIt"
] | 5a94e625c5887858cb87e16cd7d3b4ff7d3c56fb335761b262c412b95a15e051 |
from django.apps import AppConfig
class ColumbusConfig(AppConfig):
name = "pyedf"
verbose_name = "Columbus Workflow Engine"
def ready(self):
pass
| jkachika/columbus | pyedf/apps.py | Python | mit | 169 | [
"COLUMBUS"
] | 8cbfde46546e6d306e2dd16d654477709ce45bdf6096189df1e2e020396dfb41 |
"""
Function-like objects that creates cubic clusters.
"""
import numpy as np
from ase.cluster.cubic import FaceCenteredCubic
from ase.cluster.compounds import L1_2
def Octahedron(symbol, length, cutoff=0, latticeconstant=None, alloy=False):
"""
Returns Face Centered Cubic clusters of the octahedral class de... | grhawk/ASE | tools/ase/cluster/octahedron.py | Python | gpl-2.0 | 1,805 | [
"ASE"
] | 998bfc7a92be91a4076f9d1ddff9d8a8384ce84d5b5282cc64ede395b1c3c236 |
import cython
cython.declare(PyrexTypes=object, Naming=object, ExprNodes=object, Nodes=object,
Options=object, UtilNodes=object, ModuleNode=object,
LetNode=object, LetRefNode=object, TreeFragment=object,
TemplateTransform=object, EncodedString=object,
error=ob... | larsmans/cython | Cython/Compiler/FlowControl.py | Python | apache-2.0 | 42,195 | [
"VisIt"
] | bcc1e088d1b61f88f3013c63ade1d905a6149a5cd922f28f7fdaf2cb1fa88676 |
# -*- coding: utf-8 -*-
'''
Python Client for MyVariant.Info services
'''
from __future__ import print_function
import sys
import time
import requests
import json
try:
from pandas import DataFrame
df_avail = True
except:
df_avail = False
__version__ = '2.2.1'
if sys.version_info[0] == 3:
str_types = s... | SuLab/fiSSEA | myvariant/src/myvariant.py | Python | apache-2.0 | 16,425 | [
"CDK"
] | e2994f0f1f22a8605a8062f3435f5f4a753bfd36d9c458fcf895d0790a6eea39 |
# Kevin van Rensburg 11/20/2021
# Copyright 2001
# Testing Startup Script version 0.19
# kstart19.py
# Working on Kvep8.
# added def's ALL(), ALI(), COMCODE(), core(), cipl() and AnotherCode().
# Adding rd(), Or(),bfot(),srr(),cft(),st(),ct(),rat(),wst(),fep(), esot(),seor()
# fixed, reworked, and added scipt to Kvep8 ... | kurg/KendyVerse | kstart19.py | Python | gpl-3.0 | 96,038 | [
"BLAST"
] | 0e2a2efb1de759c686efe445f92b8485baa9859c30c88295ee5f61bf012ae2dd |
#!/usr/bin/env python
'''Tree View/Tree Store
The GtkTreeStore is used to store data in tree form, to be used
later on by a GtkTreeView to display it. This demo builds a simple
GtkTreeStore and displays it. If you're new to the GtkTreeView widgets
and associates, look into the GtkListStore example first.'''
# pygtk ve... | chriskmanx/qmole | QMOLEDEV/pygtk-2.16.0/examples/pygtk-demo/demos/tree_store.py | Python | gpl-3.0 | 11,036 | [
"COLUMBUS"
] | 1e15c506b364f8d5dda6bb89a799cc7ccd8715b14e618d925f22f05a4551b024 |
from paraview.simple import *
from paraview import smtesting
smtesting.ProcessCommandLineArguments()
s = Sphere()
c =Cone(Resolution=10)
GroupDatasets(Input=[s,c])
GenerateIds()
r = Show()
r.ColorArrayName = None
SelectCells("Ids > 2")
RenderView1 = Render()
if not smtesting.DoRegressionTesting(RenderView1.SMProxy):... | HopeFOAM/HopeFOAM | ThirdParty-0.1/ParaView-5.0.1/ParaViewCore/ServerManager/Default/Testing/Python/PythonSelection.py | Python | gpl-3.0 | 388 | [
"ParaView",
"VTK"
] | 5ada78295dcc5311705b736ab5d7412456a625f9404ba6915ba12865d8e5b22d |
#!/usr/bin/env python
__author__ = 'Mike McCann'
__copyright__ = '2011'
__license__ = 'GPL v3'
__contact__ = 'mccann at mbari.org'
__doc__ = '''
Loader for all 2011 Dorado missions written for loading Vrijenhoek Lab SubSamples from Julio
Mike McCann
MBARI 15 January 2013
@var __date__: Date of last svn commit... | josephmfaulkner/stoqs | stoqs/loaders/MolecularEcology/load_dorado2011.py | Python | gpl-3.0 | 4,961 | [
"NetCDF"
] | 6303f1a7d442887508276e980846f089c735bd8456861ba08df1d372cd850499 |
#!/usr/bin/env python
#! -*- coding: utf-8 -*-
""" setup.py - rhaptos2.repo package setup
Author: Paul Brian
(C) 2012 Rice University
This software is subject to the provisions of the GNU Lesser General
Public License Version 2.1 (LGPL). See LICENSE.txt for details.
"""
from setuptools import setup, find_packages... | philschatz/rhaptos2.repo | setup.py | Python | lgpl-2.1 | 1,739 | [
"Brian"
] | 80206f2e5cf290a6c60e51f229aca5f57c2bbf415cdeb380ee6c684d6ec45f45 |
#
# @BEGIN LICENSE
#
# Psi4: an open-source quantum chemistry software package
#
# Copyright (c) 2007-2017 The Psi4 Developers.
#
# The copyrights for code used from other parties are included in
# the corresponding files.
#
# This file is part of Psi4.
#
# Psi4 is free software; you can redistribute it and/or modify
#... | rmcgibbo/psi4public | psi4/driver/qcdb/psivarrosetta.py | Python | lgpl-3.0 | 18,416 | [
"Psi4"
] | ad389ba82e4db63a7197cff5d2379f957e247281e5081f256df5facff5eb307b |
'''
demo9.py
Demo of a network of spiking neurons driven by synaptic inputs.
Written by Sungho Hong, Computational Neuroscience Unit, OIST, 2017
'''
from neuron import h, gui
h.load_file("stdrun.hoc")
h.load_file("CNSutils.hoc")
# The simulation will run for 100 ms.
h.tstop = 200
# Global sampling period will be 0... | shhong/a310_cns_2017 | Practice_4/demo9.py | Python | gpl-3.0 | 3,151 | [
"NEURON"
] | f61bc9d40dfd754b124789d79b35476672bbb6e4ef0a633ef63a9c4fc02e8e0c |
'''
Source code for an attention based image caption generation system described
in:
Show, Attend and Tell: Neural Image Caption Generation with Visual Attention
International Conference for Machine Learning (2015)
http://arxiv.org/abs/1502.03044
Comments in square brackets [] indicate references to the equations/
mo... | lakehanne/ensenso | ensenso_detect/manikin/utils/capgen.py | Python | mit | 56,722 | [
"Gaussian"
] | fffaa8a5727ec3ed4329c120b6b28b9c2e65ecbd37667a1dcf17b6261c51acb8 |
#!/usr/bin/env python
"""
Integrate a surface field
"""
from __future__ import print_function
import argparse
import time
import os
import re
import sys
from icqsol.shapes.icqShapeManager import ShapeManager
from icqsol import util
# time stamp
tid = re.sub(r'\.', '', str(time.time()))
parser = argparse.ArgumentPa... | gregvonkuster/icqsol | examples/integrateSurfaceField.py | Python | mit | 1,827 | [
"VTK"
] | 8529116983e759e249711bc9f7151c3cff269b1fb3e7da9113af1e07553d5e39 |
import cv2
import matplotlib.pyplot as plt
import numpy as np
import UltraLibrary as ul
from FrameType import f_type
def hist_despeckle(img,goodImg):
dsimg, homog = quickieHomo(img)
return ul.filtered_match(img,dsimg,goodImg)
def detection(im):
detector = cv2.SimpleBlobDetector_create()
# D... | KristopherJH/ENGI7854US | Despeckle.py | Python | gpl-3.0 | 10,592 | [
"Gaussian"
] | 570e853f38dc10ff67ecf72a8d98812a80c19dcddd4eb32f7c607e806603d184 |
#!/usr/bin/env python
""" MultiQC module to parse output from HTSeq Count """
from __future__ import print_function
from collections import OrderedDict
import logging
from multiqc import config
from multiqc.plots import bargraph
from multiqc.modules.base_module import BaseMultiqcModule
# Initialise the logger
log =... | ahvigil/MultiQC | multiqc/modules/htseq/htseq.py | Python | gpl-3.0 | 4,258 | [
"HTSeq"
] | a2e98cc34b98a647be479cb0bd064b793ac5c98abf6005bceb9de88552a2d53f |
# Copyright 2008 by Michiel de Hoon. All rights reserved.
# This code is part of the Biopython distribution and governed by its
# license. Please see the LICENSE file that should have been included
# as part of this package.
"""Parser for XML results returned by NCBI's Entrez Utilities. This
parser is used by the re... | LyonsLab/coge | bin/last_wrapper/Bio/Entrez/Parser.py | Python | bsd-2-clause | 21,089 | [
"Biopython"
] | ab2bd0e220bc062f305b307b1172837d7b3cade075453db44636315ef4d8f4ae |
# coding: utf-8
from __future__ import unicode_literals, division, print_function
import os
import tempfile
from pymatgen.util.testing import PymatgenTest
from pymatgen.io.abinitio.abiinspect import *
#test_dir = os.path.join(os.path.dirname(__file__), "..", "..", "..", "..", 'test_files')
class YamlTokenizerTest... | Dioptas/pymatgen | pymatgen/io/abinitio/tests/test_abiinspect.py | Python | mit | 2,376 | [
"pymatgen"
] | 3e1d2af3a6bedd9a1dad6f18372bdee2ea9ed8ead49f22865ee8721c5cbc7170 |
# -*- coding: utf-8 -*-
u"""SRW execution template.
:copyright: Copyright (c) 2015 RadiaSoft LLC. All Rights Reserved.
:license: http://www.apache.org/licenses/LICENSE-2.0.html
"""
from __future__ import absolute_import, division, print_function
from pykern import pkcompat
from pykern import pkio
from pykern.pkcollec... | radiasoft/sirepo | sirepo/template/srw.py | Python | apache-2.0 | 87,600 | [
"CRYSTAL",
"VTK"
] | a7e942a2e9e8391116b520e8b5121e9aeb215c180febcf922a1924372fa69853 |
#
# Copyright (C) 2010, 2015, 2016, 2017, 2018, 2019, 2020, 2021
# Smithsonian Astrophysical Observatory
#
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License,... | anetasie/sherpa | sherpa/astro/ui/utils.py | Python | gpl-3.0 | 574,542 | [
"Gaussian"
] | f4d2687b9668c344f9383da939e84b0eb482a7658be13c718dfb5e53c0beadec |
# Copyright 2017 The Forseti Security 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 ap... | forseti-security/forseti-security | google/cloud/forseti/services/inventory/base/resources.py | Python | apache-2.0 | 115,431 | [
"VisIt"
] | c74bd69f0762fca1082b9f7f8139eb8d37fde9c7c56608d66dc3d014a679a70b |
import pysal as ps
import json
from six.moves import urllib as urllib
import copy
import numpy as np
"""
Weights Meta Data
Prototyping meta data functions and classes for weights provenance
Based on Anselin, L., S.J. Rey and W. Li (2014) "Metadata and provenance for
spatial analysis: the case of spatial weights." I... | schmidtc/pysal | pysal/meta/wmd.py | Python | bsd-3-clause | 14,443 | [
"COLUMBUS"
] | cc9af17ca7d4f6b0511aa7aa4f4c1aff347e6f3b30d28531372a4e4a72a0b351 |
# See http://ipython.org/ipython-doc/1/interactive/public_server.html for more information.
# Configuration file for ipython-notebook.
import os
c = get_config()
c.NotebookApp.ip = '0.0.0.0'
c.NotebookApp.port = 6789
c.NotebookApp.open_browser = False
c.NotebookApp.profile = u'default'
c.IPKernelApp.matplotlib = 'inli... | bgruening/docker-ipython-notebook | ipython_notebook_config.py | Python | mit | 1,063 | [
"Galaxy"
] | 0151960767a4bf315d85464a99ec4241e2cbbc1410412c58a1bf0cbf93c6879b |
# -*- coding: utf-8 -*-
"""
Module for functions for mito network normalization
@author: sweel_rafelski
"""
import os
import os.path as op
import vtk
import vtk.util.numpy_support as vnpy
from numpy import ceil, mean, percentile
# pylint: disable=C0103
datadir = op.join(os.getcwd())
def vtk_read(fpath, readertype='vt... | moosekaka/sweepython | pipeline/pipefuncs.py | Python | mit | 6,347 | [
"VTK"
] | c73b3cddea4567036e7f76a2a8f51924d9a7046b6b4e1f5706ae36659a70980d |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
import sys
import math
import os.path as op
import numpy as np
import argparse
orgs = """HM101
HM058 HM125 HM056 HM129 HM060
HM095 HM185 HM034 HM004 HM050
HM023 HM010 HM022 HM324 HM340
HM056.AC HM034.AC HM340.AC""".split()
dirw = "/home/youngn/zh... | orionzhou/robin | old/gene.cluster.py | Python | gpl-2.0 | 3,707 | [
"BLAST"
] | 494702ccef65322c6f1e1a96ea35fcdcd51366a93928ddb8fef5af020da5384a |
##############################################################################
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-64... | lgarren/spack | var/spack/repos/builtin/packages/r-minfi/package.py | Python | lgpl-2.1 | 3,058 | [
"Bioconductor"
] | e3ad9a226dc0ee839de183f9c3f1dbcf70bd119482e361c88a800dbc1246d935 |
#!/usr/bin/env python
# ----------------------------------------------------------------------------
# Copyright 2015 Nervana Systems 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
#
# ... | nhynes/neon | examples/mnist_mlp.py | Python | apache-2.0 | 3,473 | [
"Gaussian"
] | 8eac18aeb7a5194addbb5712a2c0afbfcb83c0ae9a6cd7e4f12bdf4ffecaebf4 |
#!/usr/bin/env python
"""Copyright 2010 Phidgets Inc.
This work is licensed under the Creative Commons Attribution 2.5 Canada License.
To view a copy of this license, visit http://creativecommons.org/licenses/by/2.5/ca/
"""
__author__ = 'Adam Stelmack'
__version__ = '2.1.8'
__date__ = 'May 17 2010'
#Basi... | danielsuo/mobot | src/move/Python/InterfaceKit-simple.py | Python | mit | 4,650 | [
"VisIt"
] | 0e2af7f6c748dad8839486cca15987759e46847168ded07434762c012c51b88a |
#!/usr/bin/env python
'''
Before running any steps in the pipeline, check your data to see if the fastq input is in
Illumina 1.3-1.7 format, specificially that
* the @ line follows the format @stuff:with:colons#BARCODE/1 (or /2 for reverse reads)
* the quality line uses Sanger encoding (ascii offset 64, high s... | almlab/SmileTrain | check_fastq_format.py | Python | mit | 4,174 | [
"Biopython"
] | 30b1baf1d470acdcebbfcd4c4658a694b39ee96d4f3738a574092d391b92a0d7 |
#
# 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... | RyanSkraba/beam | sdks/python/apache_beam/pipeline_test.py | Python | apache-2.0 | 29,620 | [
"VisIt"
] | f3080d5ecb73aa2400a813e037e2152139523378e1bb3eda6c2b2efad47eb2c0 |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.conf import settings
from django.conf.urls import include, url
from django.conf.urls.static import static
from django.contrib import admin
from django.views.generic import TemplateView
from django.views import defaults as default_views
urlpat... | BCriswell/crud-fusion | config/urls.py | Python | bsd-3-clause | 1,315 | [
"VisIt"
] | d21abd9c4db038d94bc8b56bc4487b4e0e5462556d9ba9b46958f67eae7f8cbb |
#!/usr/bin/env python
'''
Optimize molecular geometry within the environment of QM/MM charges.
'''
import numpy
from pyscf import gto, scf, cc, qmmm
mol = gto.M(atom='''
C 1.1879 -0.3829 0.0000
C 0.0000 0.5526 0.0000
O -1.1867 -0.2472 0.0000
H -1.9237 0.3850 0.0000
H 2.0985 0.2306 ... | gkc1000/pyscf | examples/geomopt/10-with_qmmm.py | Python | apache-2.0 | 970 | [
"PySCF"
] | 2e9bce58d5a33a3e62d44c1a06e19db84dda3e3225baf07a6fa3b7d47401fc18 |
"""
==========================================
Statistical functions (:mod:`scipy.stats`)
==========================================
.. module:: scipy.stats
This module contains a large number of probability distributions as
well as a growing library of statistical functions.
Each included distribution is an instanc... | ygenc/onlineLDA | onlineldavb_new/build/scipy/scipy/stats/__init__.py | Python | gpl-3.0 | 8,519 | [
"Gaussian"
] | 0ce6a304441bf0f626c7883e53947b0db1cd5762641287d49df5b99a6a27acd5 |
"""
Linear Discriminant Analysis and Quadratic Discriminant Analysis
"""
# Authors: Clemens Brunner
# Martin Billinger
# Matthieu Perrot
# Mathieu Blondel
# License: BSD 3-Clause
from __future__ import print_function
import warnings
import numpy as np
from scipy import linalg
from .extern... | valexandersaulys/airbnb_kaggle_contest | venv/lib/python3.4/site-packages/sklearn/discriminant_analysis.py | Python | gpl-2.0 | 28,413 | [
"Gaussian"
] | 6efeb148d467125367c022ad84ad2ccb6fe2b884a524660e22fad1fb20f5895a |
""" Utility for prompting users
"""
from DIRAC import S_OK, S_ERROR
def promptUser( message, choices = [], default = 'n', logger = None ):
""" Prompting users with message, choices by default are 'y', 'n'
"""
if logger is None:
from DIRAC import gLogger
logger = gLogger
if not choices:
choices = ... | andresailer/DIRAC | Core/Utilities/PromptUser.py | Python | gpl-3.0 | 1,398 | [
"DIRAC"
] | 06bd35052f28e7408167f36696b165ae889d49d5d9945d384779513617a12f11 |
# PyParticles : Particles simulation in python
# Copyright (C) 2012 Simone Riva
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any late... | simon-r/PyParticles | pyparticles/utils/pypart_global.py | Python | gpl-3.0 | 2,638 | [
"VisIt"
] | f31bf3f2fb0ba6179dcb72c1a9fcbfef390089da240cddabb41e2b78c9971347 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.