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
import pysam
import sys
from re import sub
from random import random
from uuid import uuid4
if len(sys.argv) == 2:
assert sys.argv[1].endswith('.bam')
inbamfn = sys.argv[1]
outbamfn = sub('.bam$', '.renamereads.bam', inbamfn)
inbam = pysam.Samfile(inbamfn, 'rb')
outbam = pys... | adamewing/bamsurgeon | scripts/rename_reads.py | Python | mit | 1,358 | [
"pysam"
] | 404c9748007142514a723ddf27cc4d9af5a0d7404e7f0ed854f2694315c141b5 |
"""Tests for BrillouinZone class."""
import numpy as np
from spglib import get_stabilized_reciprocal_mesh, relocate_BZ_grid_address
from phonopy.structure.brillouin_zone import BrillouinZone
def test_FCC():
"""Test BrillouinZone with FCC lattice."""
direct_lat = [[0, 2.73, 2.73], [2.73, 0, 2.73], [2.73, 2.73... | atztogo/phonopy | test/structure/test_brillouin_zone.py | Python | bsd-3-clause | 1,984 | [
"phonopy"
] | 7ca64cf66a8df6515a020f26a33717da3145aa415e9db8b50a7b5e078442aed7 |
# 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 u... | apache/climate | ocw/tests/test_dap.py | Python | apache-2.0 | 3,042 | [
"NetCDF"
] | ee250711370381989b03c8194fcc6ecd48110e60707bfb09a5f380053db4d759 |
#!/Library/Frameworks/Python.framework/Versions/2.7/bin/python
##!/mnt/lustre_fs/users/mjmcc/apps/python2.7/bin/python
# ----------------------------------------
# USAGE:
# ----------------------------------------
# PREAMBLE:
import sys
import numpy as np
from numpy.linalg import *
import MDAnalysis
from distance_fun... | rbdavid/Distance_matrix | pro_pro_distance_matrix_calc_shapiro_wilks.py | Python | gpl-3.0 | 2,370 | [
"MDAnalysis"
] | 996931d4139407e7fe1f202b09eb23b88af8340493685f9d2369246927ee1aa9 |
#!/usr/bin/python
#
# @author: Gaurav Rastogi (grastogi@avinetworks.com)
# Eric Anderson (eanderson@avinetworks.com)
# module_check: supported
# Avi Version: 17.1.1
#
# Copyright: (c) 2017 Gaurav Rastogi, <grastogi@avinetworks.com>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses... | anryko/ansible | lib/ansible/modules/network/avi/avi_systemconfiguration.py | Python | gpl-3.0 | 7,091 | [
"VisIt"
] | be0dbd955e2eec3949a639d22fa84f7549051ccabe2b600071aa62c6fe95fbf3 |
# User creation spoke
#
# Copyright (C) 2013-2014 Red Hat, Inc.
#
# This copyrighted material is made available to anyone wishing to use,
# modify, copy, or redistribute it subject to the terms and conditions of
# the GNU General Public License v.2, or (at your option) any later version.
# This program is distributed i... | atodorov/anaconda | pyanaconda/ui/gui/spokes/user.py | Python | gpl-2.0 | 28,258 | [
"VisIt"
] | f2312d48913d37953fb06cf45859e81975725592dde63b64b7303a2f92397bca |
#
# examples for SourceUndulator to be used in ShadowOui
#
import numpy
from syned.storage_ring.electron_beam import ElectronBeam
from shadow4.sources.undulator.s4_undulator import S4Undulator
from shadow4.sources.undulator.s4_undulator_light_source import S4UndulatorLightSource
if __name__ == "__main__":
from ... | srio/minishadow | examples/sources/example_source_undulator.py | Python | mit | 4,007 | [
"Gaussian"
] | a5008cb5243dfcc728dddc163babf9b993e4faa993a8a1fbbba62a5ae5667779 |
#!/usr/bin/env python
# -*- encoding: utf-8 -*-
#CREATED:2016-02-01 16:50:04 by Brian McFee <brian.mcfee@nyu.edu>
'''Deprecation utilities'''
import inspect
import warnings
class Deprecated(object):
'''A dummy class to catch usage of deprecated variable names'''
def __repr__(self):
return '<DEPRECATE... | craffel/librosa | librosa/util/deprecation.py | Python | isc | 1,812 | [
"Brian"
] | cb4b8638797a5a0b2194d5aec5568c809918cf917bc6b3469754a22d2232e3cb |
# coding: utf-8
from __future__ import unicode_literals
import unittest
import os
import numpy as np
from pymatgen.phasediagram.entries import PDEntryIO
from pymatgen.phasediagram.pdmaker import PhaseDiagram
from pymatgen.phasediagram.plotter import PDPlotter, uniquelines, \
triangular_coord, tet_coord
module... | Dioptas/pymatgen | pymatgen/phasediagram/tests/test_plotter.py | Python | mit | 2,182 | [
"pymatgen"
] | 08d5535e3055445559e407601b7d417fcde80700e2a5ffd5a073fcd79bcbe707 |
# -*- coding: utf-8 -*-
# Copyright 2013-2014 Victor Amin, http://vamin.net/
"""MESS.DB balloon method
This module contains the balloon method class and load function.
"""
from __future__ import print_function
from __future__ import unicode_literals
import binascii
import codecs
import os
import subprocess
import s... | vamin/MESS.DB | mess/methods/balloon.py | Python | agpl-3.0 | 7,848 | [
"Open Babel",
"Pybel"
] | 0c1cc9035173eacd42d292c75a98a8019a18d96ff03b04c5c58eb5a220e82e75 |
# Copyright (c) Twisted Matrix Laboratories.
# See LICENSE for details.
"""
This is a resource file that renders a static web page.
To test the script, rename the file to hello.rpy, and move it to any directory,
let's say /var/www/html/.
Now, start your Twisted web server:
$ twistd -n web --path /var/www/html/
... | EricMuller/mynotes-backend | requirements/twisted/Twisted-17.1.0/docs/web/examples/hello.rpy.py | Python | mit | 685 | [
"VisIt"
] | 6038ea3eb6c745d21899c06018cefeee669bdf764b56843ed18f892b726cd655 |
""" RemoveLambdas turns lambda into regular functions. """
from pythran.analyses import GlobalDeclarations, ImportedIds
from pythran.passmanager import Transformation
from pythran.tables import MODULES
from pythran.conversion import mangle
import pythran.metadata as metadata
from copy import copy
import gast as ast... | pombredanne/pythran | pythran/transformations/remove_lambdas.py | Python | bsd-3-clause | 3,311 | [
"VisIt"
] | c4099cacaa6f1c9774b4b5b261b3027d2d7b35c73d8a58f39c8cf6cbc93e14c6 |
#!/usr/bin/python
import os
import math
import re
import numpy as nm
import pandas as pd
import xml.etree.ElementTree
import pickle
import SAP
from Bio import SeqIO
from Bio.Blast.Applications import NcbiblastnCommandline
from Bio.Blast import NCBIXML
import urllib
def similarityScore(seq1, seq2):
# Source: SAP codeba... | ekrell/evaluateSAP | evaluateSAP.py | Python | gpl-3.0 | 16,033 | [
"BLAST"
] | 11395af9e02e18f00072c8b8f4c337fc06afdef7de44d4de813a17c07b7ea27f |
import os
import gc
import sys
import time
import signal
import traceback
import numpy as np
from gpaw.atom.generator import Generator
from gpaw.atom.configurations import parameters
from gpaw.utilities import devnull
from gpaw import setup_paths
from gpaw import mpi
import gpaw
def equal(x, y, tolerance=0, fail=Tr... | qsnake/gpaw | gpaw/test/__init__.py | Python | gpl-3.0 | 12,064 | [
"GPAW"
] | bdf72f67de060c19138c0be692c188c0e7dd02d3f27532bb6b04e9eba1c46503 |
# -*- coding: utf-8 -*-
#
# brunel_alpha_nest.py
#
# This file is part of NEST.
#
# Copyright (C) 2004 The NEST Initiative
#
# NEST 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 2 of the Licen... | stinebuu/nest-simulator | pynest/examples/brunel_alpha_nest.py | Python | gpl-2.0 | 13,729 | [
"NEURON"
] | 3cda375ba464544de2048b7cebc17fdc14a64c08d4889260d2911113e4cbfb72 |
#!/usr/bin/env python
##
## Biskit, a toolkit for the manipulation of macromolecular structures
## Copyright (C) 2004-2012 Raik Gruenberg & Johan Leckner
##
## 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 Softwar... | ostrokach/biskit | scripts/Biskit/am_restartMD.py | Python | gpl-3.0 | 4,056 | [
"Amber"
] | ccff5b70c7a7218b534759896e3b59ed79e10d9d4a00dff392345058d88d0951 |
#!/usr/bin/env python3
#
# Copyright (c) 2014, Scott Silver Labs, 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... | scottsilverlabs/raspberrystem-ide | setup.py | Python | apache-2.0 | 5,092 | [
"Brian"
] | 9768b110d14dfebfd140ac516b02d8ce1b5cb02fbf9121a6159e997653c6c0e5 |
from __future__ import print_function, division
import os,unittest,numpy as np
from pyscf.nao import mf
class KnowValues(unittest.TestCase):
def test_dft_sv(self):
""" Try to compute the xc potential """
sv = mf(label='water', cd=os.path.dirname(os.path.abspath(__file__)))
vxc = sv.vxc_lil()
if ... | gkc1000/pyscf | pyscf/nao/test/test_0027_dft_sv_nao.py | Python | apache-2.0 | 360 | [
"PySCF"
] | 8f9bf037a5eb6fc7435fc7b2e04ab7a3eda75572d788fd8b7dc718580c9828b4 |
#
# Copyright 2018 Analytics Zoo Authors.
#
# 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... | intel-analytics/analytics-zoo | pyzoo/test/zoo/orca/learn/jep/test_pytorch_estimator_for_dataframe.py | Python | apache-2.0 | 4,995 | [
"ORCA"
] | f888206e0c4502373a26ad754e39b4726ccb5d03312470e43964740ca1101a07 |
class TrrHeader:
"""Container for header info from Gromacs' TRR file"""
# Header format (after tag, positions 24:84)
# > - big endian
# l - input record size (usually 0) ---
# l - energy record size (usually 0) |
# l - box size (9*4 = 36 byte... | Tsjerk/MartiniTools | gmx/trr/header.py | Python | gpl-2.0 | 2,072 | [
"Gromacs"
] | 134dbab5a6e3572c67692d177d84cd28b782917f61ad2265308eda75eb47d1d2 |
# -*- coding: utf-8 -*-
"""Module for low-level parsing of nagios-style configuration files."""
import os
import re
import sys
import time
import pynag.Utils
from pynag.Utils import paths
# TODO: Raise more specific errors in this module.
from pynag.Parsers.errors import ParserError
class ConfigFileNotFound(Parser... | llange/pynag | pynag/Parsers/config_parser.py | Python | gpl-2.0 | 69,210 | [
"MOE"
] | adae88b9bd61a12b8861efe01d005a67c7576aff076a4e9297c52ac1506bba25 |
import requests
import os
import json
from flask import request, render_template, send_from_directory
from bs4 import BeautifulSoup
from jobcert import app, db, models
import job_posting
from parser import Parser
@app.route('/')
def index():
jobsposting_support_file = os.path.join(os.path.dirname(os.path.absp... | Doteveryone/BetterJobAdverts | jobcert/views.py | Python | agpl-3.0 | 2,177 | [
"VisIt"
] | 4401f5043f79a4d873e9002d8c456c8e9ccf2ec8c29fcd4b4469ece901768d47 |
#
# Copyright 2014 CIRAD
#
# 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 later version.
#
# This program is distributed in the... | SouthGreenPlatform/scaffhunter | bin/BLAT_gros.py | Python | gpl-3.0 | 5,210 | [
"BLAST"
] | 3137fc02a0909838fa7c3a2f7c92f2d556ff5346058b4b14b129aae4ccf12842 |
# -*- coding: utf-8 -*-
# General Django settings for mysite project.
import os
import sys
import django.conf.global_settings as DEFAULT_SETTINGS
import logging
import mysite.pipelinefiles as pipelinefiles
import mysite.utils as utils
from celery.schedules import crontab
try:
import psycopg2
except ImportError:
... | catmaid/CATMAID | django/projects/mysite/settings_base.py | Python | gpl-3.0 | 19,870 | [
"NEURON"
] | 0e3e82784678eb6cdf24444a1ca6b50e3f6d746c21354db113cd2fed11a4a446 |
"""
This example shows the reconstruction of a binary image from a reduced set of
tomographic projections. Synthetic binary data of size 128x128 are generated,
and 40 projections along regularly-spaced angles are computed.
Different versions of the BP-tomo algorithm are compared:
- the uncoupled version: interactio... | eddam/bp-for-tomo | demo_bp_flavors.py | Python | bsd-3-clause | 6,604 | [
"Gaussian"
] | d361a8b6a21e34b45fddbb29309f951f932e0442038271c956f95ab0dc94460e |
# Copyright 2011 Rackspace
# Copyright (c) 2011 X.commerce, a business unit of eBay Inc.
# Copyright 2013 IBM Corp.
# 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
#
# ... | saleemjaveds/https-github.com-openstack-nova | nova/tests/network/test_manager.py | Python | apache-2.0 | 149,206 | [
"FEFF"
] | dbf5b9ed708ded3d6b32f39b2a75402b3aae399ff2b169659942fb41b4e8e1fc |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding:utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4 fileencoding=utf-8
#
# MDAnalysis --- http://www.mdanalysis.org
# Copyright (c) 2006-2016 The MDAnalysis Development Team and contributors
# (see the file AUTHORS for the full list of names)
#
... | alejob/mdanalysis | testsuite/MDAnalysisTests/core/test_segmentgroup.py | Python | gpl-2.0 | 3,296 | [
"MDAnalysis"
] | 754cae3b8f6d0dcba88dbdd9e49f1abc8231fa610fdcaa18dbc01f197ce5341f |
# Copyright (C) 2010-2018 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 v... | hmenke/espresso | samples/immersed_boundary/addSoft.py | Python | gpl-3.0 | 1,916 | [
"ESPResSo"
] | 8848f361973a5e19a9dd793e57518b99f475a3fa02635c8b2fc828d74d59e530 |
import calendar
import json
import re
import uuid
import mock
from django.core.cache import cache
from django.test import TestCase
from django.contrib.auth.models import User
from django.core import mail
from funfactory.urlresolvers import reverse
from nose.tools import eq_, ok_
from airmozilla.main.models import E... | bugzPDX/airmozilla | airmozilla/comments/tests/test_views.py | Python | bsd-3-clause | 22,064 | [
"CASINO",
"VisIt"
] | 84a71e048f17b478950180ee90f1fe43e70baa5acc6a30dbf8e6a83206e96d09 |
from __future__ import division, print_function, absolute_import
from scipy.lib.six import xrange
import scipy.special
from numpy import (logical_and, asarray, pi, zeros_like,
piecewise, array, arctan2, tan, zeros, arange, floor)
from numpy.core.umath import (sqrt, exp, greater, less, cos, add, sin,... | jsilter/scipy | scipy/signal/bsplines.py | Python | bsd-3-clause | 11,622 | [
"Gaussian"
] | 324a8d32248958d69ca5266631d7d3974dce2c5a01b2fc1042eeb1405d3c3837 |
import json
import re
from string import upper
from itertools import izip
from django.http import HttpResponse
from django.shortcuts import get_object_or_404
from django.db import connection
from catmaid.models import UserRole, Project, Class, ClassInstance, \
ClassInstanceClassInstance, Relation
from catmaid... | fzadow/CATMAID | django/applications/catmaid/control/neuron_annotations.py | Python | agpl-3.0 | 35,408 | [
"NEURON"
] | e28c14c9aca9f854ddb5d6919830ed177a91229411cf7da6d0719929fed42aae |
# Begin: Python 2/3 compatibility header small
# Get Python 3 functionality:
from __future__ import\
absolute_import, print_function, division, unicode_literals
from future.utils import raise_with_traceback, raise_from
# catch exception with: except Exception as e
from builtins import range, map, zip, filter
from i... | pikinder/nn-patterns | examples/all_methods.py | Python | mit | 6,964 | [
"NEURON"
] | cc8249e99d5fb04c1a637ed239f1ed8eddc9b691deb1322522ae0d0db4ec320d |
# -*- coding: utf-8 -*-
"""
@author: Fabio Erculiani <lxnay@sabayon.org>
@contact: lxnay@sabayon.org
@copyright: Fabio Erculiani
@license: GPL-2
B{Entropy Package Manager Client Core Interface}.
"""
import os
import shutil
import threading
from entropy.core import Singleton
from entropy.locks im... | Sabayon/entropy | lib/entropy/client/interfaces/client.py | Python | gpl-2.0 | 19,884 | [
"Galaxy"
] | 85c67e23cd603b2cdda5af84eb39c868c6d46fef0355ebda9730ff820ba13971 |
""" The Job Scheduling Executor takes the information gained from all previous
optimizers and makes a scheduling decision for the jobs.
Subsequent to this jobs are added into a Task Queue and pilot agents can be submitted.
All issues preventing the successful resolution of a site candidate are dis... | fstagni/DIRAC | WorkloadManagementSystem/Executor/JobScheduling.py | Python | gpl-3.0 | 26,829 | [
"DIRAC"
] | 161a1cbdd18f14ed9b8f44d0f56cf37b1870aa81f00019dfea78670f091a6faf |
# (C) British Crown Copyright 2010 - 2013, Met Office
#
# This file is part of Iris.
#
# Iris is free software: you can redistribute it and/or modify it under
# the terms of the GNU Lesser General Public License as published by the
# Free Software Foundation, either version 3 of the License, or
# (at your option) any l... | kwilliams-mo/iris | lib/iris/tests/stock.py | Python | gpl-3.0 | 20,802 | [
"NetCDF"
] | 8dcd049e5168db58334392d49d889d73381bb8337849d47dc0d634aeebafb0aa |
from __future__ import annotations
import logging
import os
import sys
import time
import traceback
from libtbx import Auto
import xia2.Handlers.Streams
from xia2.Applications.xia2_main import check_environment, write_citations
from xia2.Handlers.Citations import Citations
from xia2.Handlers.Files import cleanup
fro... | xia2/xia2 | src/xia2/cli/rescale.py | Python | bsd-3-clause | 2,145 | [
"CRYSTAL"
] | a3a1b0f6c1fdacb2518f986e36ee090de765ad89299362e8e2f87234b230b0ab |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import galaxy.main.mixins
from django.conf import settings
import galaxy.main.fields
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),... | chouseknecht/galaxy | galaxy/main/migrations/0030_auto_20151127_0824.py | Python | apache-2.0 | 2,776 | [
"Galaxy"
] | 3335357232eb0066b791f86f5dcf58a51dd65e506292f96a631e4089778f28ae |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Views tests for the OSF."""
from __future__ import absolute_import
import datetime as dt
import httplib as http
import json
import time
import unittest
import urllib
from flask import request
import mock
import pytest
from nose.tools import * # noqa PEP8 asserts
from... | pattisdr/osf.io | tests/test_views.py | Python | apache-2.0 | 212,089 | [
"Brian",
"VisIt"
] | 50054c84e42246df4ac8376dbf4eb5e78e93d0a964a509de6315a949b30622be |
##############################################################################
# Copyright (c) 2013-2018, 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... | EmreAtes/spack | var/spack/repos/builtin/packages/r-seqlogo/package.py | Python | lgpl-2.1 | 1,762 | [
"Bioconductor"
] | e11bb2863bdcfd351a088d17679aad9d8128229e2e20bfaaca968abc6cb3720e |
"""
=================
Lorentzian Fitter
=================
"""
import numpy
from numpy.ma import median
from numpy import pi
from ...mpfit import mpfit
from . import fitter
from astropy.extern.six.moves import xrange
class LorentzianFitter(fitter.SimpleFitter):
def __init__():
self.npars = 3
self.n... | mikelum/pyspeckit | pyspeckit/spectrum/models/lorentzian.py | Python | mit | 1,902 | [
"Gaussian"
] | 440c79e90e0ed2519ca73f5bb613476a56470ad8242c8ab25d1c85c595693a31 |
# Copyright (c) 2015, Scott J Maddox. All rights reserved.
# Use of this source code is governed by the BSD-3-Clause
# license that can be found in the LICENSE file.
'''
Combine everything into `_fdint.pyx` and `_fdint.pxd`, in order to take advantage
of inlining.
'''
import os
import sys
fdint_dir = os.path.join(os.p... | scott-maddox/fdint | scripts/gen__fdint.py | Python | bsd-3-clause | 2,706 | [
"DIRAC"
] | e3f60b31b675b78735370f25671cbc35986c28d9b438415edc909f1b329417dd |
import warnings
warnings.simplefilter('always', DeprecationWarning)
import os
import functools
import os.path
import re
import urllib
import urllib2
import json
import imp
import random
import tabulate
from connection import H2OConnection
from job import H2OJob
from expr import ExprNode
from frame import H2OFrame, _py_... | PawarPawan/h2o-v3 | h2o-py/h2o/h2o.py | Python | apache-2.0 | 75,865 | [
"Gaussian"
] | 1b7ad9be1355b19055780eb33b00c62fa8757595cdab7f97194ffc9e851b9b5f |
#!/usr/bin/env python
"""
refguide_check.py [OPTIONS] [-- ARGS]
Check for a Scipy submodule whether the objects in its __all__ dict
correspond to the objects included in the reference guide.
Example of usage::
$ python refguide_check.py optimize
Note that this is a helper script to be able to check if things ar... | gfyoung/scipy | tools/refguide_check.py | Python | bsd-3-clause | 31,064 | [
"Gaussian"
] | 080f61ac906e78cc22ebdf4cc69701dede94b79175fdefedcb263de83e72fdc6 |
import sys
import os.path
#sys.path.insert(0, '/home/andy/theano/tool_examples/theano-lstm-0.0.15')
from theano_lstm import Embedding, LSTM, RNN, StackedCells, Layer, create_optimization_updates, masked_loss
from utilities import *
import dill
import argparse
#import cPickle
import pickle
import numpy
from collections... | darongliu/Lstm_Turing_LM | lstm-neural-turing-machines-lm/v2-no-beta-gamma/lm_v4.py | Python | mit | 25,515 | [
"NEURON"
] | e156548a2d21398fc6965d7cbdee10425a636b7d1f1d15d2ff117d59b51ee7a5 |
#!/usr/bin/env python
'''
Convert the k-sampled MO/integrals to corresponding Gamma-point supercell
MO/integrals.
Zhihao Cui <zcui@caltech.edu>
See also the original implementation at
https://github.com/zhcui/local-orbital-and-cdft/blob/master/k2gamma.py
'''
import numpy as np
from pyscf.pbc import gto, dft
from py... | gkc1000/pyscf | examples/pbc/42-k2gamma.py | Python | apache-2.0 | 1,630 | [
"PySCF"
] | 02b11babd100a379433375a51df1aee895db78af63b102a580a3fe5402ce8e57 |
import numpy as np
from ase import Atoms
from gpaw import GPAW
from gpaw.wavefunctions.pw import PW
from gpaw.test import equal
bulk = Atoms('Li', pbc=True)
k = 4
calc = GPAW(mode=PW(200), kpts=(k, k, k))
bulk.set_calculator(calc)
e = []
niter = []
A = [2.6, 2.65, 2.7, 2.75, 2.8]
for a in A:
bulk.set_cell((a, a, a... | ajylee/gpaw-rtxs | gpaw/test/pw/bulk.py | Python | gpl-3.0 | 461 | [
"ASE",
"GPAW"
] | f46b94591d15d418f152332e00798091e0938c40a1ad9a6daddced237c4a6a68 |
""" This is a test of the chain
SiteStatus -> ResourceStatusClient -> ResourceStatusDB
It supposes that the DB is present, and that the service is running
"""
# pylint: disable=invalid-name,wrong-import-position
from datetime import datetime
import unittest
from DIRAC.Core.Base.Script import parseCommandLin... | arrabito/DIRAC | tests/Integration/ResourceStatusSystem/Test_SiteStatus.py | Python | gpl-3.0 | 5,316 | [
"DIRAC"
] | d85b6caae08b657842972f4a041e10336fbf0e952c1f2460b6a6b1c6999faa51 |
# Copyright 2018 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... | lablup/sorna-repl | vendor/benchmark/minigo/tests/test_mcts.py | Python | lgpl-3.0 | 10,518 | [
"VisIt"
] | d7bc1d6cc70125eed453186c3c13880d8d1cfab3ccd2b1e545b27fddd89386b6 |
# 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 u... | Laurawly/tvm-1 | python/tvm/relay/analysis/analysis.py | Python | apache-2.0 | 10,670 | [
"VisIt"
] | ec88e6f9cdeb3e2f719e978dd3218f60361e310328fcce2841e728cc118569ca |
# Copyright (C) 2009, Thomas Leonard
# See the README file for details, or visit http://0install.net.
from __future__ import print_function
import os, sys
import logging
import warnings
import locale
from zeroinstall import localedir
if localedir:
# Tell GTK where to find the translations, if they're not in
# the... | linuxmidhun/0install | zeroinstall/gui/main.py | Python | lgpl-2.1 | 6,992 | [
"VisIt"
] | 9c600c9b9cdc458f5a1d0b250c0a579f167c47dee15aac94609618e4beba9c6d |
''' DIRAC.ResourceStatusSystem.Service package
'''
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
__RCSID__ = '$Id$'
| yujikato/DIRAC | src/DIRAC/ResourceStatusSystem/Service/__init__.py | Python | gpl-3.0 | 180 | [
"DIRAC"
] | 2f7fc20c23a5c8b36db764ffa9ef61718863e2229857e2bf472a9a946c24234d |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
import unittest
from pathlib import Path
from monty.serialization import loadfn, dumpfn
import os
from pymatgen.core.periodic_table import Element
from pymatgen.entries.entry_tools import group_entries_by_stru... | mbkumar/pymatgen | pymatgen/entries/tests/test_entry_tools.py | Python | mit | 1,996 | [
"pymatgen"
] | e51b9938c1747e0336805fc3d2e97d2f7f10aed1eeaa42ac59a59f4dad91c8f7 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module is used to estimate the cost of various compounds. Costs are taken
from the a CostDB instance, for example a CSV file via CostDBCSV.
For compounds with no cost listed, a Phase Diagram style conv... | czhengsci/pymatgen | pymatgen/analysis/cost/cost.py | Python | mit | 6,002 | [
"pymatgen"
] | fb06a549f7e9b376f7329cae5d3a52586a63670c923d45b1963f42f41c5e6516 |
#!/usr/bin/python
"""
These function can be used to calculate the average end to end distances of a backbone from a lammmps output.
Usage:
# dump_dataframe must be in pythonpath or working directory
from endtoend_distance import rf
rf,rf_std = rf(first_frame=-1000, last_frame=-1, trajectory_step=10,atoms_per_polymer=1... | EtiCui/Msc-UdeS | dataAnalysis/endtoend_distance.py | Python | mit | 3,264 | [
"LAMMPS"
] | a72e7dedf538a2c2f5045fc0048b892527d74fc720d3968c8670f34f013bc99d |
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
Module implementing an XYZ file object class.
"""
import re
from io import StringIO
import pandas as pd
from monty.io import zopen
from pymatgen.core.structure import Molecule
class XYZ:
"""
Basic class for im... | materialsproject/pymatgen | pymatgen/io/xyz.py | Python | mit | 4,754 | [
"pymatgen"
] | 005d9249a02079c36cc6332f93edfdcca206bbe1f632d1a6d2e6b64f2c885d60 |
#!/usr/bin/env jython
# copyright 2002 the Brothers Wilcox
# <mailto:zooko@zooko.com>
#
# This file is part of OvP.
#
# OvP is open source 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 2 of the Lic... | zooko/ogresvpixies | Game.py | Python | gpl-2.0 | 2,984 | [
"VisIt"
] | 61674bf09cb4f3917eff4eab779d2e88f578b5a5a8d556944e2a1a06267e6a9b |
#### Convenience Functions to be moved to kerneltools ####
from statsmodels.compat.python import range
import numpy as np
def forrt(X,m=None):
"""
RFFT with order like Munro (1976) FORTT routine.
"""
if m is None:
m = len(X)
y = np.fft.rfft(X,m)/m
return np.r_[y.real,y[1:-1].imag]
def ... | detrout/debian-statsmodels | statsmodels/nonparametric/kdetools.py | Python | bsd-3-clause | 1,357 | [
"Gaussian"
] | ca2680802f0e98620c6fbca20eef5aa1ce0421887b454e0c34fd9ce031df122c |
#
# Copyright 2021 Lars Pastewka (U. Freiburg)
# 2020 Thomas Reichenbach (Fraunhofer IWM)
#
# matscipy - Materials science with Python at the atomic-scale
# https://github.com/libAtoms/matscipy
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Pub... | libAtoms/matscipy | examples/pressure_coupling/slide.py | Python | lgpl-2.1 | 3,242 | [
"ASE",
"Matscipy"
] | 298c21d22021bb3aa92e30594fdba680f1fd40e4c332de6559755272ee2f9deb |
# This file is part of wger Workout Manager.
#
# wger Workout Manager 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 Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# wger W... | rolandgeider/wger | wger/manager/tests/test_weight_log.py | Python | agpl-3.0 | 18,794 | [
"VisIt"
] | 9d58a0a59ec768f3327d7f69dbf53471a4658c88cdfb752e10750623f6048376 |
import numpy as np
import math
from pylab import *
from palettable.wesanderson import Zissou_5 as wsZ
import matplotlib.ticker as mtick
from scipy.interpolate import interp1d
from scipy.interpolate import griddata
import scipy.ndimage as ndimage
#read JP and TH files
#def read_JP_files(fname):
# da = np.genfromt... | natj/bender | paper/figs/fig8.py | Python | mit | 6,241 | [
"Gaussian"
] | fbd1495095295515b12f5a85e4a281cedfff20828cda9396e9234e1a57571982 |
# (c) 2012-2016, Ansible by Red Hat
#
# This file is part of Ansible Galaxy
#
# Ansible Galaxy is free software: you can redistribute it and/or modify
# it under the terms of the Apache License as published by
# the Apache Software Foundation, either version 2 of the License, or
# (at your option) any later version.
#
... | chouseknecht/galaxy | galaxy/main/management/commands/rebuild_galaxy_indexes.py | Python | apache-2.0 | 4,297 | [
"Galaxy"
] | 89d5af80e7494098414b0ac8845680a9127547cebc78fd87b7c860f368227367 |
import base64
import binascii
import hashlib
import hmac
import rsa
from bs4 import BeautifulSoup
from kik_unofficial.datatypes.xmpp.base_elements import XMPPElement
from kik_unofficial.device_configuration import device_id, kik_version_info, android_id
from kik_unofficial.utilities.cryptographic_utilities import Cryp... | tomer8007/kik-bot-api-unofficial | kik_unofficial/datatypes/xmpp/login.py | Python | mit | 8,300 | [
"Galaxy"
] | 738f03d29d508efdabc399ffec3d58d661200b0c37a3fc5acceb0df2904342fc |
import os.path
from lwr.lwr_client import PathMapper
from lwr.lwr_client.action_mapper import path_type
from .test_utils import TempDirectoryTestCase
from galaxy.util.bunch import Bunch
class PathMapperTestCase(TempDirectoryTestCase):
def test_input(self):
local_path = os.path.join(os.path.dirname(self... | jmchilton/lwr | test/path_mapper_test.py | Python | apache-2.0 | 3,503 | [
"Galaxy"
] | 22e05b97e70e8949b6b43e89f851bc2c9367afb2413e665b4a0304dcd746f390 |
#!/usr/bin/env python3
# encoding: utf-8
#
# datamodel.py
#
# Created by José Sánchez-Gallego on 18 Sep 2016.
from __future__ import division
from __future__ import print_function
from __future__ import absolute_import
from marvin import config
__all__ = ('MapsProperty', 'MapsPropertyList', 'dap_datamodel',
... | bretthandrews/marvin | python/marvin/utils/dap/datamodel.py | Python | bsd-3-clause | 16,189 | [
"Galaxy",
"Gaussian"
] | 47c9e6cbe24a590efdf5a4faa0cafc7551ac5a96af16032226438ba6b543e673 |
import vtk
class Cut:
def __init__(self, volume, plane, z):
self.volume = volume
self.color = volume.color
self.cutEdges = vtk.vtkCutter()
self.cutEdges.SetInputConnection(self.volume.normal.GetOutputPort())
self.cutEdges.SetCutFunction(plane)
self.cutEdges.Generate... | FedericoV/FractalMammaryLobule | modeler/view/elements/Cut.py | Python | gpl-3.0 | 1,229 | [
"VTK"
] | bfb92936d7279681de1dc11733842709bb5f7727eb7ef4918ac150b8e81735a6 |
# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
import json
import frappe.utils
from frappe.utils import cstr, flt, getdate, comma_and
from frappe import _
from frappe.model.mapper impor... | reddymeghraj/showroom | erpnext/selling/doctype/sales_order/sales_order.py | Python | agpl-3.0 | 16,347 | [
"VisIt"
] | 66d5e64d17119c3d317dfa589848d09117504a5d80a6596ce71cae774400d2b7 |
"""plotting fields defined on atoms during a simulation."""
from ase.visualize.primiplotter import PostScriptFile, PnmFile, GifFile, JpegFile, X11Window
from ase.visualize.primiplotter import PrimiPlotter as _PrimiPlotter
import numpy
import time
class FieldPlotter(_PrimiPlotter):
def __init__(self, atoms, dataso... | grhawk/ASE | tools/ase/visualize/fieldplotter.py | Python | gpl-2.0 | 11,124 | [
"ASE"
] | 1b68376eddce0798a3ab9a3a83e9fd62e41d14e86081bbd20884e31068661dd4 |
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
Module containing classes to generate grain boundaries.
"""
import itertools
import logging
import warnings
from fractions import Fraction
from functools import reduce
from math import cos, floor, gcd
import numpy as np
... | vorwerkc/pymatgen | pymatgen/analysis/gb/grain.py | Python | mit | 115,781 | [
"CRYSTAL",
"pymatgen"
] | 2c9a523484ddd369d782be39f57931f85977bf45f7d0db40a0421bdab7ae7d3c |
"""
Maximum likelihood covariance estimator.
"""
# Author: Alexandre Gramfort <alexandre.gramfort@inria.fr>
# Gael Varoquaux <gael.varoquaux@normalesup.org>
# Virgile Fritsch <virgile.fritsch@inria.fr>
#
# License: BSD 3 clause
# avoid division truncation
import warnings
import numpy as np
from scipy... | shyamalschandra/scikit-learn | sklearn/covariance/_empirical_covariance.py | Python | bsd-3-clause | 11,053 | [
"Gaussian"
] | 4aef5923a7fcce5b695ace98625c3ec0539d3cc6b57edb8ab3798e7ba89ce879 |
#
# Copyright (c) 2009-2015, Jack Poulson
# All rights reserved.
#
# This file is part of Elemental and is under the BSD 2-Clause License,
# which can be found in the LICENSE file in the root directory, or at
# http://opensource.org/licenses/BSD-2-Clause
#
import El
m = 10000
n = 5000
display = False
worldRank... | mcopik/Elemental | examples/interface/NNLS.py | Python | bsd-3-clause | 2,419 | [
"Gaussian"
] | 67a339644af77d01aa23580c6d81c67b68de4094405cf243d53364f87a8c3c4e |
#!/usr/bin/env python
# -*- coding: utf-8
"""
Example generation modified from the scikit learn
Generate the rst files for the examples by iterating over the python
example files.
Files that generate images should start with 'plot'
"""
from time import time
import os
import shutil
import traceback
import glob
impor... | diego0020/PySurfer | doc/sphinxext/gen_rst.py | Python | bsd-3-clause | 25,194 | [
"Mayavi"
] | 27847c5db110b2d247ca5eda0f20463a00e845c5421dfc655311dcc616310d53 |
#! /usr/bin/env python
## Written for python2.6
import pysam
import random
import sys
if len(sys.argv) != 9:
print "\n**** USAGE ERROR **** \n"
print "python script.py number_iterations minimum_coverage maximum_coverage sites_file chromosome sampleid bamfile outfilename "
sys.exit("exiting ERROR !!!!")
###########... | LohmuellerLab/FourSite | CountReadFoursite/CountReadFoursite.py | Python | mit | 5,921 | [
"pysam"
] | f7e625edf836749560ddf04b3805bad4153ee449aeb98fe5663c0ff822669c93 |
"""Provide functions for pruning reactions, metabolites and genes."""
from ast import And, BoolOp, Module, Name, NodeTransformer
from typing import TYPE_CHECKING, Dict, List, Optional, Set, Tuple, Union
from warnings import warn
from cobra.core import GPR
if TYPE_CHECKING:
from cobra import Gene, Metabolite, Mod... | opencobra/cobrapy | src/cobra/manipulation/delete.py | Python | gpl-2.0 | 11,356 | [
"VisIt"
] | 79f0471db8622f9bbd62d64c21d58c1ae6f88224bdfdb83394632dcc2eaa5a57 |
import numpy as np
from math import sqrt
import time, operator
from ase.optimize import Dynamics
from ase import BFGS
from ase.optimize.gxoptimizer import GxOptimizer
class LiuTSsearch(Dynamics):
def __init__(self, atoms, restart=None, logfile='-' , trajectory=None, soften = 0, factsoft = 0.7,
out... | alexei-matveev/ase-local | ase/liutssearch.py | Python | gpl-2.0 | 31,652 | [
"ASE"
] | deec797027dc86c5036437f43b804800965482f1a9c85441ba370112c637a5cd |
import glob
import pandas as pd
import numpy as np
import os
os.chdir("/gpfs/commons/home/biederstedte-934/evan_projects/correct_phylo_files")
mcell = glob.glob("binary_position_RRBS_NormalBCD19pCD27mcell1_22*")
print(len(mcell))
trito = glob.glob("binary_position_RRBS_trito_pool_1*")
print(len(trito))
totalfiles =... | evanbiederstedt/RRBSfun | epiphen/tests/normalCll9.py | Python | mit | 3,672 | [
"MCell"
] | 63977185fd0b275312777b7feb1a4eade795583d22d8a8cd50e742c0a70cef6f |
# Copyright 2008 Brian Boyer, Ryan Mark, Angela Nitzke, Joshua Pollock,
# Stuart Tiffen, Kayla Webley and the Medill School of Journalism, Northwestern
# University.
#
# This file is part of Crunchberry Pie.
#
# Crunchberry Pie is free software: you can redistribute it and/or modify
# it under the terms of the GNU Gene... | brianboyer/newsmixer | social/letters/models.py | Python | gpl-3.0 | 2,816 | [
"Brian"
] | aeea14e02a0b6345588b393da5adb1a35168f1baeeae088d83594f50ea5f17cf |
'''This will take an aligned multiple FASTA file with multiple genes
and create individual FASTA alignment files for each gene and simplify the
fasta headers.
Copyright 2016 by Shawn Rupp'''
import argparse
from glob import glob
def splitFasta(infile, outdir):
# Open input file and split into one alignment per... | WilsonSayresLab/AlignmentProcessor | bin/01_SplitFasta.py | Python | gpl-3.0 | 3,584 | [
"Galaxy"
] | 1426d7328a4fe11146a06e710eca9bc0b4a559946f65593d60dd3f6012c9654f |
# Copyright (c) 2014 Intel Corporation.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# * Redistributions of works must retain the original copyright notice, this list
# of conditions and the following disclaimer.... | cicili/tools | atip/atip/web/web.py | Python | mit | 22,534 | [
"VisIt"
] | 1e30e2d9df2f04b385ea7474a7ed484ed789eca9208c9745da0895771792a5c2 |
#!/usr/bin/env python3
import argparse
import os
from pyxpad import PyXPad
from Qt.QtWidgets import QApplication
import sys
def main():
"""
Data visualisation and analysis tool in Python,
intended to be familiar to users of XPAD.
Primarily for IDAM data from the MAST tokamak experiment,
but can ... | bendudson/pyxpad | pyxpad/__main__.py | Python | gpl-3.0 | 1,015 | [
"NetCDF"
] | aa07244f24a19ea28a42749ad3abb79394560151ac4d1abdfcd545917d5b9770 |
#!/usr/local/epd/bin/python
#------------------------------------------------------------------------------------------------------
#
# Dirac propagator in the phase space x-px
#
#------------------------------------------------------------------------------------------------------
import numpy as np
import scipy.fft... | cabrer7/PyWignerCUDA | GPU_WignerDirac2D_MassPotential_4x4.py | Python | mit | 128,968 | [
"DIRAC",
"Gaussian",
"Psi4"
] | 45e7c2f7ccc0d805a4fde539182ed8d0c46e8b6a5fa20a389fc40011762c23e7 |
#!/usr/bin/python
from __future__ import print_function
import espressomd
from espressomd import thermostat
from espressomd import analyze
from espressomd import integrate
from espressomd import electrostatics
from espressomd import minimize_energy
from espressomd.interactions import *
import numpy as np
from threadin... | KonradBreitsprecher/espresso | samples/billard.py | Python | gpl-3.0 | 8,188 | [
"ESPResSo"
] | ce20b8a426afd5f63986744bfc23e7a544e3d1ec53f727cd309a0a951f6332a1 |
#
# @BEGIN LICENSE
#
# Psi4: an open-source quantum chemistry software package
#
# Copyright (c) 2007-2021 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
#... | lothian/psi4 | psi4/driver/procrouting/mcscf/__init__.py | Python | lgpl-3.0 | 953 | [
"Psi4"
] | 961cc75089d45a948efee149a2b4c6567d00fac5b450397b65e68c6928ab8b4c |
# Mantid Repository : https://github.com/mantidproject/mantid
#
# Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
# NScD Oak Ridge National Laboratory, European Spallation Source
# & Institut Laue - Langevin
# SPDX - License - Identifier: GPL - 3.0 +
import unittest
from mantid.simpleapi import... | mganeva/mantid | scripts/test/VesuvioFittingTest.py | Python | gpl-3.0 | 4,280 | [
"Gaussian"
] | ab75243848030047b03e118c3b622e2dc35fee74dc3d4aa796bcf346327b6ebe |
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes ... | AutorestCI/azure-sdk-for-python | azure-mgmt-datafactory/azure/mgmt/datafactory/models/distcp_settings.py | Python | mit | 1,861 | [
"ADF"
] | a15b3c28cfc5901beb1f7aab2eda1bd40cef15a2858bb2b675f8a4a89847f3fe |
import numpy as np
import matplotlib.pyplot as plt
import sys
sys.path.append('../src')
import Steppers as Step
import Fluxes as Flux
from PyRsw import Simulation
from constants import minute, hour, day
def test():
sim = Simulation()
# Geometry and Model Equations
sim.geomy = 'walls'
sim.s... | PyRsw/PyRsw | testing/test_does_1d_run/test_walls.py | Python | mit | 1,087 | [
"Gaussian"
] | 278dffb36737b63857b1e3863635281633b4d5df11b0068fd3731aee95a58786 |
"""Matlab(tm) compatibility functions.
This will hopefully become a complete set of the basic functions available in
matlab. The syntax is kept as close to the matlab syntax as possible. One
fundamental change is that the first index in matlab varies the fastest (as in
FORTRAN). That means that it will usually pe... | fxia22/ASM_xf | PythonD/site_python/numarray/linear_algebra/mlab.py | Python | gpl-2.0 | 12,223 | [
"Gaussian"
] | 7a178115849f30de2b3f16410024a542837bda578b881db746900ab16c1a6dd7 |
'''
MeneScraper is a big data project that monitors the social interactions of Meneame.
Copyright (C) 2015 Arnau Villoslada
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 2 of the Li... | TheDegree0/menescraper | scraper/management/commands/social_sync.py | Python | gpl-2.0 | 17,964 | [
"VisIt"
] | 48fc26a88c5e8bcaa5cf139d262ccf8842545191dd8267d9a88f5c3dfd1127d2 |
# -*- coding: utf-8 -*-
""" Sahana Eden Climate Model
@copyright: 2011-2021 (c) Sahana Software Foundation
@license: MIT
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software witho... | flavour/eden | modules/templates/historic/Climate/climate.py | Python | mit | 27,767 | [
"NetCDF"
] | 703a60c7324b9d6b098bca58ecb2320a6d3843cb75b0185dbf45e8555109977b |
import sys
import pytest
import numpy as np
from numpy.testing import (
assert_, assert_raises, assert_equal,
assert_warns, assert_no_warnings, assert_array_equal,
assert_array_almost_equal, suppress_warnings)
from numpy.random import Generator, MT19937, SeedSequence
random = Generator(MT19937())
@pyt... | ahaldane/numpy | numpy/random/tests/test_generator_mt19937.py | Python | bsd-3-clause | 84,506 | [
"Gaussian"
] | 7ca0ad94cf33881c4c7fe4b579513780ffdeab4cbcbbf07ba0ba77a54a28251c |
import numpy as np
from .control import model_setup
from .cp_confocal import twod, threed
from .cp_mix import double_pnum
# 3D + 2D + T
def CF_Gxyz_3d2d_gauss(parms, tau):
u""" Two-component, two- and three-dimensional diffusion
with a Gaussian laser profile.
particle2D = (1-F)/ (1+τ/τ_2D)
... | paulmueller/PyCorrFit | pycorrfit/models/model_confocal_3d_2d.py | Python | gpl-2.0 | 3,282 | [
"Gaussian"
] | be08851fdddf37fcd795e1b4d83f813f0e0c29ba0e9a23e90b10638657d41cbf |
# coding: utf-8
"""
Vericred API
Vericred's API allows you to search for Health Plans that a specific doctor
accepts.
## Getting Started
Visit our [Developer Portal](https://developers.vericred.com) to
create an account.
Once you have created an account, you can create one Application for
Production and an... | vericred/vericred-python | vericred_client/models/provider_show_response.py | Python | apache-2.0 | 12,182 | [
"VisIt"
] | 4891365c19738df04121368c49eb868e30f1e9793bece213e23910be8f5a90d4 |
from __future__ import absolute_import, division, print_function
from .common import Benchmark
import numpy as np
class LaplaceInplace(Benchmark):
params = ['inplace', 'normal']
param_names = ['update']
def setup(self, update):
N = 150
Niter = 1000
dx = 0.1
dy = 0.1
... | mingwpy/numpy | benchmarks/benchmarks/bench_app.py | Python | bsd-3-clause | 2,716 | [
"NEURON"
] | e6842391fd4c00cec34f08ac1fe1d9bd2f1169d8655958784b84e21956fe1099 |
# Copyright 2009 Brian Quinlan. All Rights Reserved.
# Licensed to PSF under a Contributor Agreement.
"""Implements ProcessPoolExecutor.
The follow diagram and text describe the data-flow through the system:
|======================= In-process =====================|== Out-of-process ==|
+----------+ +----------... | mj3-16/mjtest | mjtest/util/concurrent/futures/process.py | Python | mit | 14,280 | [
"Brian"
] | 45418f3449a5f0a29ae3a78a1a9d68efe131fb01153099585f2399111205edd8 |
#
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2000-2005 Donald N. Allingham
# Copyright (C) 2008 Brian G. Matherly
#
# 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; ... | sam-m888/gramps | gramps/gui/pluginmanager.py | Python | gpl-2.0 | 8,526 | [
"Brian"
] | 97d0b9f30ce5ce94b83dbca7d59e8c03d25cc2c258ad485e1d677332e0de0c71 |
# -*- coding: utf-8 -*-
r"""
.. _tut_background_filtering:
===================================
Background information on filtering
===================================
Here we give some background information on filtering in general,
and how it is done in MNE-Python in particular.
Recommended reading for practical app... | alexandrebarachant/mne-python | tutorials/plot_background_filtering.py | Python | bsd-3-clause | 42,317 | [
"Gaussian"
] | 47f5bd416d472d93f2339f310666719725a038f59432e29987771730a8c400a1 |
from django.shortcuts import render
# Create your views here.
import logging
from django.contrib.auth.decorators import login_required
from django.shortcuts import render
from cenet.models import Neuron, SynapticConn, CENetwork
from django.db.models import Q
from django.http import HttpResponse
from django.views.decor... | Si-elegans/Web-based_GUI_Tools | rtw_ui/views.py | Python | apache-2.0 | 4,292 | [
"NEURON"
] | d5b2a2616fb1a0091b99e741e28a684d504ef633b287ef226310cec4e4959479 |
"""
@name: PyHouse/src/Modules/Computer/Web/_test/test_web_mainpage.py
@author: D Brian Kimmel
@contact: D.BrianKimmel@gmail.com>
@copyright: (c) 2014-2019 by D. Brian Kimmel
@license: MIT License
@note: Created on Jun 6, 2014
@Summary:
"""
__updated__ = '2019-03-01'
# Import system type stuff
impor... | DBrianKimmel/PyHouse | Project/src/Modules/Computer/Web/test/test_web_mainpage.py | Python | mit | 1,391 | [
"Brian"
] | 1d799e00dc39f45273256f47342f102a34c94543ebf5bbd11c79adf1db4b5eef |
# -*- coding: utf-8 -*-
from __future__ import print_function, division, absolute_import
import ast
from numba import templating
from numba import error, pipeline, nodes, ufunc_builder
from numba.minivect import specializers, miniast, miniutils
from numba import utils, functions
from numba import typesystem
from numba... | shiquanwang/numba | numba/array_expressions.py | Python | bsd-2-clause | 10,462 | [
"VisIt"
] | 6826a77983683e6ec14007ccf6860473442fff8d8fef69f1690424f20669d7cc |
import astropy.units as uu
import astropy.cosmology as co
aa = co.Planck13
from scipy.interpolate import interp1d
import numpy as n
import matplotlib
#matplotlib.use('pdf')
matplotlib.rcParams['font.size']=12
import matplotlib.pyplot as p
import glob
import sys
from scipy.optimize import curve_fit
import cPickle
from o... | JohanComparat/nbody-npt-functions | bin/bin_onePT/halo-bias-1-fit.py | Python | cc0-1.0 | 18,224 | [
"TINKER"
] | 718c373a21c4d87006558463cdb5be8f4ae6711d2cb814825f995ab3ef2a5160 |
import os
import sys
import numpy as np
def calc_accuracy_objective(f_soc, allelectron_forces_file):
"""
Calculates accuracy objective by comparing socorro and
all electron forces at each atomic structure tested.
"""
f_allelectron = read_allelectron_forces(filename=allelectron_forces_file)
ret... | caseynbrock/opal2 | calc_accuracy.py | Python | mit | 2,508 | [
"CRYSTAL",
"Elk"
] | 59121556b13fb0ec94c6f0a26c5e859c41cd682e372bb23c67d572ec50ef92f7 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.