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 |
|---|---|---|---|---|---|---|---|
# (c) 2012, Michael DeHaan <michael.dehaan@gmail.com>
#
# This file is part of Ansible
#
# Ansible 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 lat... | pilwon/ansible | lib/ansible/utils/__init__.py | Python | gpl-3.0 | 42,023 | [
"VisIt"
] | 06b360cb0f80f80a3f443156f0348009f52c25b4449ee66cd18336edf189fe37 |
from setuptools import setup
import pyneuroml
version = pyneuroml.__version__
jnml_version = pyneuroml.JNEUROML_VERSION
setup(
name='pyNeuroML',
version=version,
author='Padraig Gleeson',
author_email='p.gleeson@gmail.com',
packages = ['pyneuroml',
'pyneuroml.analysis',
... | rgerkin/pyNeuroML | setup.py | Python | lgpl-3.0 | 2,479 | [
"NEURON"
] | 965c438bb354e6edd03f2b9050b91872112790377d3a6b02ad5c95f0408d96e8 |
__version__="""M.Maris, 1.3 - - 27 Nov 2012 - 26 Dec 2016 -"""
__DESCRIPTION__="""
A grid 2d is a 2x2 array representing a grid
At the moment no DS9 support is directly provided
Private: _PIXEL_LIST a list of pixels and _CENTER for the center of a map
"""
class fast_histogram :
def __init__(self,x,levels=None,vm... | MicheleMaris/grid2d | grid2d.py | Python | gpl-2.0 | 81,449 | [
"Gaussian"
] | ce6c00a7287f878b04ed3bd9ab21f0860bc86ac7ea9e92c8b3cc037c78ccde13 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module provides objects describing the basic parameters of the
pseudopotentials used in Abinit, and a parser to instantiate pseudopotential objects..
"""
import abc
import collections
import json
impor... | dongsenfo/pymatgen | pymatgen/io/abinit/pseudos.py | Python | mit | 63,265 | [
"ABINIT",
"pymatgen"
] | 7446d63fd0e62d1ded0bc03491f8f9e835e94c0aaa690edaf8dc3350f498a4bc |
# Orca
#
# Copyright 2005-2008 Sun Microsystems Inc.
#
# This library 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 2.1 of the License, or (at your option) any later version.
#
# This... | ruibarreira/linuxtrail | usr/lib/python3/dist-packages/orca/scripts/apps/Mozilla/script.py | Python | gpl-3.0 | 1,252 | [
"ORCA"
] | 907ac9f69c0e0fdb20c82626ce32c36ae0a8ae416ef8a4de73f291a88a0719b5 |
# encoding: utf-8
"""
Module to set up run time parameters for Clawpack.
The values set in the function setrun are then written out to data files
that will be read in by the Fortran code.
"""
import os
import datetime
import numpy as np
import clawpack.geoclaw.surge as surge
# Need to adjust the date a bit due to... | mandli/surge-examples | karen/setrun.py | Python | mit | 22,748 | [
"NetCDF"
] | 10d28507fed3f661ec7d92b39d9778afe2f2e52e635e98356eba9bb46ad407b9 |
#
# ----------------------------------------------------------------------------------------------------
#
# Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify ... | mcberg2016/graal-core2 | mx.graal-core/mx_graal_core.py | Python | gpl-2.0 | 39,167 | [
"VisIt"
] | b62adf1d6d3e0a8cdced0a42e9477cd40c66f3cd608359bf30586ed567b28a4e |
#!/usr/bin/env python
# (C) Copyright IBM Corporation 2004, 2005
# All Rights Reserved.
#
# 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 without restriction, including without limitation
# ... | devlato/kolibrios-llvm | contrib/sdk/sources/Mesa/src/mapi/glapi/gen/gl_procs.py | Python | mit | 7,801 | [
"Brian"
] | 0a5e9dc4cbbc69c5f3c36bd1fb06dd12a37cb5e9e740f455dc7d31ec00609e97 |
# ----------------------------------------------------------------------
# LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
# http://lammps.sandia.gov, Sandia National Laboratories
# Steve Plimpton, sjplimp@sandia.gov
#
# Copyright (2003) Sandia Corporation. Under the terms of Contract
# DE... | rbberger/lammps | python/lammps/core.py | Python | gpl-2.0 | 68,759 | [
"LAMMPS"
] | 7e9602452969a565c407d11d89ec11b4d6e647f9bc7a4751127b58cfc84e810d |
import os
import os.path as op
import shutil
import logging
from . import conf, errors, helper
logger = logging.getLogger(__name__)
names_rows_stability = [
['dg', 1], # totalEnergy
['backbone_hbond', 2],
['sidechain_hbond', 3],
['van_der_waals', 4],
['electrostatics', 5],
['solvation_polar'... | ostrokach/elaspic | elaspic/call_foldx.py | Python | mit | 8,167 | [
"CRYSTAL",
"FoldX"
] | 116a51c12360c5d6ad9258477a3f7b9ed31f4f41786355e83f3c2285c5cdfd03 |
"""Non-parametric Bayesian phone-loop model."""
# NOTE:
# Differing from what has been described in the paper, we do not put any
# prior on the transition matrix as:
# * optimizing the states of the sub HMM does not help and is
# time consuming
# * transition between sub-HMMs are hanlded by weights taken
# fr... | OliverWalter/amdtk | amdtk/models/phone_loop.py | Python | bsd-2-clause | 10,352 | [
"Gaussian"
] | 56dfefa293c92ddabfd88443bb3e78b2132756a1c4a1658fce9fcfbdfc5e3b66 |
#
# Copyright (C) 2013,2014,2015,2016 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)... | KonradBreitsprecher/espresso | testsuite/magnetostaticInteractions.py | Python | gpl-3.0 | 2,118 | [
"ESPResSo"
] | a0fcaadaa89eff8f745bd6b7ce2e841df194951495a6e0b69fc2502550172b01 |
# -*- coding: utf-8 -*-
"""
Created on Fri Sep 18 17:54:10 2015
module to pick mom, bud ,neck positions
"""
import os
import os.path as op
import numpy as np
from mayavi import mlab
import pandas as pd
from tvtk.api import tvtk
from collections import defaultdict
from mombud.functions import vtkvizfuncs as vz
im... | moosekaka/sweepython | mombud/functions/deprecated/vtk_pick_mombud_pos.py | Python | mit | 6,766 | [
"Mayavi",
"VTK"
] | 2a733dd0559285bcf845c5a3c3e23c97cb98c5429c3fdabcdeaa8705615309b5 |
import ctn_benchmark
import nengo
import scipy.optimize
import scipy.stats
import numpy as np
class BioSpaunMemory(ctn_benchmark.Benchmark):
def params(self):
self.default('number of neurons', n_neurons=100)
self.default('number of dimensions', D=8)
self.default('maximum firing rate', max_r... | tcstewar/biospaun_memory | bio_mem.py | Python | gpl-2.0 | 2,288 | [
"Gaussian",
"NEURON"
] | fb3f28d8c58e735af70c40789c707684525e972a6ff434d459eddea0d68b4391 |
"""SCons.Util
Various utility functions go here.
"""
#
# Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 The SCons Foundation
#
# 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... | makinacorpus/mapnik2 | scons/scons-local-1.2.0/SCons/Util.py | Python | lgpl-2.1 | 52,597 | [
"VisIt"
] | d676274a6be39164b308dfb8583eb77636f620ae0aeaccf9b260ad38e3096209 |
#
# Copyright 2014 Universidad Complutense de Madrid
#
# This file is part of Numina
#
# Numina 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 ... | Pica4x6/numina | numina/modeling/gaussbox.py | Python | gpl-3.0 | 1,692 | [
"Gaussian"
] | 435d771e6205f87f21f3429a67efa71ea30af8c991a4ab9287cf9f3f0db6caf0 |
from .model_checker import ModelChecker, PathResult, PathMetric, NodesContainer
from .pysb import PysbModelChecker
from .signed_graph import SignedGraphModelChecker
from .unsigned_graph import UnsignedGraphModelChecker
from .pybel import PybelModelChecker
| johnbachman/indra | indra/explanation/model_checker/__init__.py | Python | bsd-2-clause | 256 | [
"Pybel"
] | 7a19624de1c7170d4ce24771edc897ecadedb6e0c83f2301ed6e95ceb121c471 |
# Hidden Markov Model Implementation
import pylab as pyl
import numpy as np
import matplotlib.pyplot as pp
#from enthought.mayavi import mlab
import scipy as scp
import scipy.ndimage as ni
import scipy.io
import roslib; roslib.load_manifest('sandbox_tapo_darpa_m3')
import rospy
#import hrl_lib.mayavi2_util as mu
imp... | tapomayukh/projects_in_python | sandbox_tapo/src/skin_related/AI_Surface_Recognition/src/hmm_crossvalidation_force_5_states.py | Python | mit | 14,979 | [
"Gaussian",
"Mayavi"
] | 17f42f44de129682c06561fdf8e654d2dcea3400137d46223bb58cc489553e6f |
#!/usr/bin/env python
import numpy
import numpy.linalg
import matplotlib.pyplot as plt
#
# Define the generic error for chemical shift data
#
errors={'N':0.1,'H':0.03,'HA':0.03}
#
# ----
#
def yasaraplot():
"""Make a plot of all ghosts on the structure"""
ghosts=getdata()
#
rescolor={}
tgco... | dmnfarrell/peat | Ghost/make_figs.py | Python | mit | 48,584 | [
"YASARA"
] | 9a4e9d92abd72c93ec0be3ab93919a7ed35c3bff5fef0b33b6bbd8e0a91580b8 |
# Copyright 2021, 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... | google-research/public-data-in-dpfl | mirror_descent_convex.py | Python | apache-2.0 | 22,367 | [
"Gaussian"
] | 5854db1c6a54611fc93e51360d4fe605e0daae57397511dbca948547ac56d887 |
# %load solutions/keras_adam_and_adadelta.py
model = Sequential()
model.add(Dense(hidden_dim, input_dim=input_dim,
activation="relu"))
model.add(Dense(hidden_dim, activation="relu"))
model.add(Dense(output_dim, activation="softmax"))
optimizer = optimizers.Adam(lr=0.001)
model.compile(optimizer=optimiz... | m2dsupsdlclass/lectures-labs | labs/01_keras/solutions/keras_adam.py | Python | mit | 1,145 | [
"NEURON"
] | 897cd1f7e22dc798cf725bacc819b6b59d522cf797372b6b4e81df3314e5549c |
# Copyright 2009 Brian Quinlan. All Rights Reserved.
# Licensed to PSF under a Contributor Agreement.
from __future__ import with_statement
import functools
import logging
import threading
import time
try:
from collections import namedtuple
except ImportError:
from ._compat import namedtuple
__author__ = 'Br... | blopker/PCLite | pclite/lib/concurrent/futures/_base.py | Python | mit | 19,638 | [
"Brian"
] | fb046e8363a93276e0f5db58c98eb3841c0c72bf3c120411ca43d48f49db9e0b |
#!/usr/bin/env python
'''
File name: main_make_map.py
Author: Guillaume Viejo
Date created: 28/09/2017
Python Version: 3.5.2
To make shank mapping
'''
import numpy as np
import pandas as pd
# from matplotlib.pyplot import plot,show,draw
import scipy.io
from functions import *
from pylab import *
from sklear... | gviejo/ThalamusPhysio | python/main_make_map.py | Python | gpl-3.0 | 7,830 | [
"NEURON"
] | cc07ba47588ba1cc96d28418bbb124c3fbc8bdbb02d0f3b5c81bb3f71dc89e7c |
#!/usr/bin/env python
"""
dirac-rss-set-status
Script that facilitates the modification of a element through the command line.
However, the usage of this script will set the element token to the command
issuer with a duration of 1 day.
"""
from datetime import datetime, timedelta
from DIRAC ... | Andrew-McNab-UK/DIRAC | ResourceStatusSystem/scripts/dirac-rss-set-status.py | Python | gpl-3.0 | 8,670 | [
"DIRAC"
] | 0e71f038a54e2e88c791cc8281f5ac7b1b7283fb357ec9977dda70aa885b1a4d |
# $HeadURL$
__RCSID__ = "$Id$"
import os
import types
import time
import GSI
from DIRAC.Core.Utilities.LockRing import LockRing
from DIRAC.Core.Utilities.ReturnValues import S_ERROR, S_OK
from DIRAC.Core.DISET.private.Transports.BaseTransport import BaseTransport
from DIRAC.FrameworkSystem.Client.Logger import gLogger... | sposs/DIRAC | Core/DISET/private/Transports/SSLTransport.py | Python | gpl-3.0 | 9,434 | [
"DIRAC"
] | fb554e655888edda6350572ae7b4d2fda360568b08602dd42daddc04a145dbe9 |
#!/usr/bin/env python
# Copyright (C) 2011 Ion Torrent Systems, Inc. All Rights Reserved
import os
import re
import sys
from optparse import OptionParser
import pysam
import string
#MATCH = 0
#INS = 1
#DEL = 2
#REF_SKIP = 3
#SOFT_CLIP = 4
#HARD_CLIP = 5
#PAD = 6
def get_qref(md, cigar, qseq):
... | nh13/TMAP | scripts/util/sam2aln.py | Python | gpl-2.0 | 6,630 | [
"pysam"
] | 458e975521238fa8986ccc386e049dbce17cce4d4198d772f599baa4a3dd4e2e |
# Copyright (C) 2010-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 v... | espressomd/espresso | testsuite/python/lb_boundary_velocity.py | Python | gpl-3.0 | 1,991 | [
"ESPResSo"
] | b47b2e81772daceddbb0345c16c81ea9d13a7788c1372f48b1f8fabb84d640ab |
# finite-difference implementation of the diffusion equation with first-order
# explicit time discretization
#
# We are solving phi_t = k phi_xx
#
# We run at several resolutions and compute the error. This uses a
# cell-centered finite-difference grid
#
# M. Zingale (2013-04-07)
import numpy
import pylab
import sys... | JeffDestroyerOfWorlds/hydro_examples | diffusion/diffusion-explicit.py | Python | bsd-3-clause | 5,762 | [
"Gaussian"
] | 4cdd0a7680ebc945ba14665d710e38a7cc6783d0f930136ee14732dd7ad7f405 |
#!/usr/bin/python3
# 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 License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it ... | Nymeria8/Rapsearch2Xml | RapsearchToXml.py | Python | gpl-3.0 | 8,475 | [
"BLAST"
] | 2e73b5e6bd8cce0715dce934ac7c991b2b8bea9a70947f4cd644adffe919560e |
""" GlobalEffects computes function effect on global state. """
from pythran.analyses.aliases import Aliases
from pythran.analyses.global_declarations import GlobalDeclarations
from pythran.passmanager import ModuleAnalysis
from pythran.tables import MODULES
from pythran.graph import DiGraph
import pythran.intrinsic a... | pombredanne/pythran | pythran/analyses/global_effects.py | Python | bsd-3-clause | 4,404 | [
"VisIt"
] | e6c84085d014e45b89a982acb0a2ecdc293af55990015142e86664153e8a25fa |
# Copyright 2019 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Assign IDs to resource_ids file based on usage, while preserving structure.
resource_ids assignment is divided into two parts:
(A) Coarse assignment: Assi... | chromium/chromium | tools/grit/grit/tool/update_resource_ids/assigner.py | Python | bsd-3-clause | 11,048 | [
"VisIt"
] | 6f19cb3a4d53d237ef8c4b56b218345a49f801fd9e8cc828718971c9c66fc298 |
#!/usr/bin/env python
#pylint: disable=missing-docstring
#################################################################
# DO NOT MODIFY THIS HEADER #
# MOOSE - Multiphysics Object Oriented Simulation Environment #
# #... | liuwenf/moose | python/chigger/tests/line/tracer.py | Python | lgpl-2.1 | 1,389 | [
"MOOSE"
] | cea2599148b0626aaacfa301cecac0f03ea31c0974a4944f8e00d98f111ed041 |
from WebAppDIRAC.Lib.WebHandler import WebHandler, WErr, WOK, asyncGen
from DIRAC.Core.DISET.RPCClient import RPCClient
from WebAppDIRAC.Lib.SessionData import SessionData
from DIRAC import gConfig, S_OK, S_ERROR, gLogger
from DIRAC.Core.Utilities import Time
import operator
import json
import ast
try:
from hashli... | chaen/WebAppDIRAC | WebApp/handler/FileCatalogHandler.py | Python | gpl-3.0 | 12,600 | [
"DIRAC"
] | e273bfa9f52655e3ead8e3df8215391c2cb42e3a6765aba2bc3162d34af07333 |
import logging
# from uuid import UUID
from weakref import WeakValueDictionary
from openpathsampling.netcdfplus.base import StorableNamedObject, StorableObject
from openpathsampling.netcdfplus.cache import MaxCache, Cache, NoCache, \
WeakLRUCache
from openpathsampling.netcdfplus.proxy import LoaderProxy
from futu... | choderalab/openpathsampling | openpathsampling/netcdfplus/stores/object.py | Python | lgpl-2.1 | 39,528 | [
"NetCDF"
] | 113a5a56de302f01819e18dad1309163035c22fa11743648c18199c4cbec1d71 |
#!/usr/bin/env python
import argparse
import logging
import os
import sys
from breakseq2 import breakseq_top
if __name__ == '__main__':
parser = argparse.ArgumentParser(description="BreakSeq2: Ultrafast and accurate nucleotide-resolution analysis of structural variants",
forma... | bioinform/breakseq2 | scripts/run_breakseq2.py | Python | bsd-2-clause | 1,231 | [
"BWA"
] | 4691bdabb8521bf36ace57bde1c3d9eae2de6831fb2c27344ccb31978cf36b4e |
import unittest
import pysal
import numpy as np
from pysal.spreg import error_sp_het_regimes as SP
from pysal.spreg.error_sp_het import GM_Error_Het, GM_Endog_Error_Het, GM_Combo_Het
from pysal.common import RTOL
class TestGM_Error_Het_Regimes(unittest.TestCase):
def setUp(self):
#Columbus:
db=pysa... | hasecbinusr/pysal | pysal/spreg/tests/test_error_sp_het_regimes.py | Python | bsd-3-clause | 14,513 | [
"COLUMBUS"
] | 4cfe28b624925396bd5c01603bcf296b52fd035b78ce3d9aeaf1721ea504a901 |
import numpy as np
from ase.atoms import Atoms
class VNL:
def __setstate__(self, data):
self.data = data
def ac(shape, typecode, data, endian):
x = np.fromstring(data, typecode)
try:
x.shape = shape
except ValueError:
x = x[::2].copy()
x.shape = shape
if ... | grhawk/ASE | tools/ase/io/vnl.py | Python | gpl-2.0 | 1,035 | [
"ASE"
] | 77ead7f2f9d170ae37aad006e3030b4db9ba009a657c4d1c173b456ff9d94bed |
"""
========================
Decimating scalp surface
========================
This can be useful to reduce computation time when
using a cloud of digitization points for coordinate alignment
instead of e.g. EEG-cap positions.
"""
# Authors: Denis Engemann <denis.engemann@gmail.com>
# Alexandre Gramfort <ale... | mne-tools/mne-tools.github.io | 0.15/_downloads/plot_decimate_head_surface.py | Python | bsd-3-clause | 1,066 | [
"Mayavi"
] | 30dfbcd62b73ccf570e78722d5316689c446463552b74f5e117c2ec612153030 |
#!/usr/bin/env python
"""
CsPython Tutorial Example 0
By Mark Gossage (mark@gossage.cjb.net)
Minimal pure-Python script to setup Crystal Space from Python.
To use this, ensure that your PYTHONPATH, CRYSTAL, and LD_LIBRARY_PATH
(or DYLD_LIBRARY_PATH for MacOS/X; or PATH for Windows) variables are set
approrpriately, a... | baoboa/Crystal-Space | scripts/python/tutorial0.py | Python | lgpl-2.1 | 2,905 | [
"CRYSTAL"
] | e2d6d8923a297201c4c9ffc9e27ed0fdc44b3aff7aff6170e24ae26f76c47e85 |
import pytest
import re
import capybara
from capybara.compat import urlparse
from capybara.session import Session
from capybara.tests.app import AppError
class TestVisit:
def test_fetches_a_response_from_the_driver_with_a_relative_url(self, session):
session.visit("/")
assert session.has_text("He... | elliterate/capybara.py | capybara/tests/session/test_visit.py | Python | mit | 3,472 | [
"VisIt"
] | 72fe38e1974030d3cfa66aded7637a931a184ab9e87d6da3738a6455c7e0136e |
import os
import re
import pytest
import yaml
import time
import string
import random
import fileinput
from datetime import datetime
from mock.mock import patch, Mock, ANY
try:
from urllib import quote as urlencode # python 2
except ImportError:
from urllib.parse import quote as urlencode # python 3
from ins... | RedHatInsights/insights-core | insights/tests/client/apps/test_malware_detection.py | Python | apache-2.0 | 114,609 | [
"BLAST"
] | c0bcae0b96a1947c7b4c9775e651f27150f97c7d62edff0593e662c99868e8d4 |
#!/usr/bin/env python
# Copyright (c) 2017, Henrique Miranda
# All rights reserved.
#
# This file is part of the phononwebsite project
#
"""
Read phonon dispersion from quantum espresso
http://www.quantum-espresso.org/
"""
from phononweb.qephonon import *
import argparse
import sys
if __name__ == "__main__":
p... | henriquemiranda/phononwebsite | scripts/read_qe_phonon.py | Python | bsd-3-clause | 1,790 | [
"ESPResSo",
"Quantum ESPRESSO"
] | 24eb90e10c11c8e19141525e4c7fe19d080b3512af51778aa26d4c58bbe29a1c |
########################################################################
# File: IRODSStorageElementHandler.py
########################################################################
"""
:mod: IRODSStorageElementHandler
.. module: IRODSStorageElementHandler
:synopsis: IRODSStorageElementHandler is the implementati... | miloszz/DIRAC | DataManagementSystem/Service/IRODSStorageElementHandler.py | Python | gpl-3.0 | 22,697 | [
"DIRAC"
] | 8c9332873eab388ec4fe08ed6ef579caf7886c2ed7c5b220861a8a7816d24203 |
#
# @BEGIN LICENSE
#
# Psi4: an open-source quantum chemistry software package
#
# Copyright (c) 2007-2018 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
#... | amjames/psi4 | psi4/driver/procrouting/dft_funcs/superfuncs.py | Python | lgpl-3.0 | 10,219 | [
"Psi4"
] | 89b1e63011c9a2584a84d2b888256eef4cb2d217556fb246f0f83255819ee7ee |
# -*- coding: utf-8 -*-
# Copyright 2006-2015 by Peter Cock. All rights reserved.
# Revisions copyright 2015 by Ben Woodcroft. All rights reserved.
# Modifications copyright 2016 by Simone Marsili.
#
# Biopython License Agreement
# ---------------------------
#
# Permission to use, copy, modify, and distribute this s... | simomarsili/scikit-msa | skmsa/bioparsers.py | Python | bsd-3-clause | 5,956 | [
"Biopython"
] | 87888c251d1783cca3d09abbaccb071211a4ee1c36ee31a23bbc7e91f8c6cb1b |
"""
GUI_ObserverClient.py
Copyright 2016 Brian Romanchuk
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... | brianr747/Simple4Xpygame | clients/GUI_observerclient.py | Python | apache-2.0 | 5,002 | [
"Brian"
] | 7932f8fc0df654d86105904b26237e3fe648d62375fd777db24871b9aa20b712 |
"""VASP calculator interface."""
# Copyright (C) 2011 Atsushi Togo
# All rights reserved.
#
# This file is part of phonopy.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# * Redistributions of source code must ret... | atztogo/phonopy | phonopy/interface/vasp.py | Python | bsd-3-clause | 45,793 | [
"CRYSTAL",
"VASP",
"phonopy"
] | 37f1bb3a2f85148c9a9693380d151e5c0e122c2e40a9e89690fab1a4811da0d9 |
##
# Copyright 2013-2017 Ghent University
#
# This file is part of EasyBuild,
# originally created by the HPC team of Ghent University (http://ugent.be/hpc/en),
# with support of Ghent University (http://ugent.be/hpc),
# the Flemish Supercomputer Centre (VSC) (https://www.vscentrum.be),
# Flemish Research Foundation (F... | ULHPC/easybuild-easyblocks | easybuild/easyblocks/d/dl_poly_classic.py | Python | gpl-2.0 | 4,787 | [
"DL_POLY"
] | c796270e5981e037925d7cd13941b2f8e0f96c61da9d1c6b972d4b0bde328120 |
#!/usr/bin/env python2.7
"""
Simple sequencing file statistics.
Gather the following numbers:
* Percentages of bases with quality at least Q40, Q30, and Q20 from FASTQ
files.
* Percentages of reads whose average quality is at least Q40, Q30, and Q20.
Requirements:
* Python == 2.7.x
* Biopython... | ablifedev/ABLIRC | ABLIRC/bin/Dataclean/seq_quality_stat.py | Python | mit | 3,381 | [
"Biopython"
] | 2f7e4725dcbb3e09c7eee77a2d999872f40daeb1efdbe06589775b31825b7f3c |
"""
This script generates Fig. 4 in Williams (2020). bioRxiv. 2020.03.02.974014
"""
from tensortools.cpwarp import ShiftedCP, fit_shifted_cp
from scipy.ndimage import gaussian_filter1d
import matplotlib.pyplot as plt
import numpy as np
np.random.seed(1234)
# Parameters defining synthetic dataset.
MAX_SHIFT = 0.15
N_T... | ahwillia/tensortools | examples/shift_cpd.py | Python | mit | 4,661 | [
"NEURON"
] | 0d3a4d12c92f474ce28f23208e36eb72417329fb33641a04f592adc1d1c7573c |
# $Id$
#
# Copyright (C) 2002-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.
#
"""unit testing code... | adalke/rdkit | rdkit/Chem/Suppliers/UnitTestSDMolSupplier.py | Python | bsd-3-clause | 4,676 | [
"RDKit"
] | ffdcbee15bdde2d055e892c733027051d202f0ddeeb8bfd9c6667f1809e4739a |
'''
optics elements
'''
from numpy import sin, cos, pi, sqrt, log, array, random, sign
#from numpy.linalg import norm
import numpy as np
def debug(*args):
print(' '.join( map(str, args) ))
def warn(*args):
print(' '.join( map(str, args) ))
def info(*args):
print(' '.join( map(str, args) ))
class OptE... | sserkez/ocelot | optics/elements.py | Python | gpl-3.0 | 8,556 | [
"CRYSTAL"
] | c693bedb78e1651d576ada9294bf9c25f022ef0bfc29d113f64bbb011373768a |
import matplotlib.pyplot as plt
import wavelet_funcs as wv
import numpy as np
import math
import pywt
###
from scipy import sparse
#from scipy.sparse.linalg import spsolve
#from numpy.linalg import solve, norm
###
test = True
##################################################
#
# Sampling multivariate normals:
#
# ... | pdbaines/KepleR | python/kepler_mcmc.py | Python | mit | 36,464 | [
"Gaussian"
] | 4cc9f225219e4b8bea8762be1d74a68ca843ae58b5c9602f8dfd454468dda2f3 |
tests = [
("python", "UnitTestSDMolSupplier.py", {}),
("python", "UnitTestSmilesMolSupplier.py", {}),
("python", "UnitTestDbMolSupplier.py", {}),
]
longTests = []
if __name__ == '__main__':
import sys
from rdkit import TestRunner
failed, tests = TestRunner.RunScript('test_list.py', 0, 1)
sys.exit(len(fai... | ptosco/rdkit | rdkit/Chem/Suppliers/test_list.py | Python | bsd-3-clause | 326 | [
"RDKit"
] | adc9ef2f6336d02be9150857ae836e45ae067e4bc03351fa504295962893ed3c |
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack import *
class Bioawk(MakefilePackage):
"""Bioawk is an extension to Brian Kernighan's awk, adding the su... | LLNL/spack | var/spack/repos/builtin/packages/bioawk/package.py | Python | lgpl-2.1 | 924 | [
"Brian"
] | b1f3476f2b5933342e8b85f2aa8ca020b404b571ce0dd40d43927d6822906784 |
"""Mayavi/traits GUI for converting data from KIT systems"""
# Authors: Christian Brodbeck <christianbrodbeck@nyu.edu>
#
# License: BSD (3-clause)
import os
import numpy as np
from scipy.linalg import inv
from threading import Thread
from ..externals.six.moves import queue
from ..io.meas_info import _read_dig_points... | alexandrebarachant/mne-python | mne/gui/_kit2fiff_gui.py | Python | bsd-3-clause | 20,707 | [
"Mayavi"
] | db5d29959dd919f94d1a31c4a78e6695101984594099b63e0b4ed8ed838c6903 |
import textwrap
import re
import subprocess
import os
import errno
import numpy as np
import sympy
from fractions import Fraction
# Version: 0.1
class LatexDocument:
def __init__(self, filename):
self.filename = filename
self.ext = "tex"
self.preambleTemplate = self.prepareLatex(r"""
... | PeterSR/DM554 | Util/latex.py | Python | mit | 5,197 | [
"Gaussian"
] | d1abe4dedacd955bc8bb394a54f143b1afaa8f940a785e2754195b7204551a47 |
import MDAnalysis as mda
import numpy as np
def create_test_trj(uni, fname):
n_atoms = uni.atoms.n_atoms
pos = np.arange(3 * n_atoms).reshape(n_atoms, 3)
uni.trajectory.ts.dt = 1
orig_box = np.array([81.1, 82.2, 83.3, 75, 80, 85], dtype=np.float32)
uni.trajectory.ts.dimensions = orig_box
print... | MDAnalysis/mdanalysis | testsuite/MDAnalysisTests/data/coordinates/create_data.py | Python | gpl-2.0 | 1,196 | [
"MDAnalysis"
] | a65dab4affe50d9b8486ed246a6e9c52779631f44a684d9f389537dab1f4528f |
# Bomb.py
# Aaron Taylor
# Moose Abumeeiz
#
# Bombs can be dropped or picked up, they will hurt enemies in range
#
from pygame import *
from time import time as cTime
from random import randint
from math import *
from Explosion import *
from Animation import *
from Item import *
class Bomb(Item):
"""Droppable bomb ... | ExPHAT/binding-of-isaac | Bomb.py | Python | mit | 2,229 | [
"MOOSE"
] | 418de7c12a9e52a16a9cebdcd465a554a89b6091d06ab39b0cf17bc61f0b0439 |
from ase import Atom, Atoms
from gpaw import GPAW, PoissonSolver
from gpaw.test import equal
from gpaw.xc.hybrid import HybridXC
a = 6. # Size of unit cell (Angstrom)
c = a / 2
# Hydrogen atom:
atom = Atoms([Atom('H', (c, c, c), magmom=1)],
cell=(a, a, a), pbc=False)
# gpaw calculator:
calc = GPAW... | ajylee/gpaw-rtxs | gpaw/test/atomize.py | Python | gpl-3.0 | 2,531 | [
"ASE",
"GPAW"
] | c0759a3cc4cce015ec5a567bdc84d3c86d227035397ca900647df835fd9557cb |
__all__ = ['GaussianProcess']
import numpy as np
import matplotlib.pyplot as pl
from . import cholInvert
import numpy.core.umath_tests
import scipy.optimize as opt
class GaussianProcess:
def __init__(self, xInput, lambdaGPInitial=1.0, sigmaGPInitial=1.0):
self.lambdaGP = lambdaGPInitial
self.sigmaGP = sigma... | aasensio/pyAndres | gpAndres.py | Python | mit | 2,810 | [
"Gaussian"
] | 8a1561f91e051e97e4972d299e606c442d2f5aa2731efc41f36194e82a54c94f |
from collections import deque
from collections import namedtuple
from enum import Enum
import glob
import itertools as it
import json
import numpy as np
import os
import sys
import sqlite3
from sqlite3 import Error as db_Error
import planargs
from abc import ABC, abstractmethod # abstract class support
from coll... | ECP-CANDLE/Supervisor | workflows/cp-leaveout/py/plangen.py | Python | mit | 53,118 | [
"VisIt"
] | 9d562cee5c531a1fac283199325494f8c8f3674b8b576749aa8e317a2f162e3e |
import logging
import os
from galaxy.webapps.tool_shed import model
from galaxy.web.framework.helpers import grids
from galaxy.model.orm import and_
from galaxy.model.orm import or_
from tool_shed.grids.repository_grids import RepositoryGrid
import tool_shed.util.shed_util_common as suc
from tool_shed.util import hg_ut... | mikel-egana-aranguren/SADI-Galaxy-Docker | galaxy-dist/lib/tool_shed/grids/repository_review_grids.py | Python | gpl-3.0 | 24,581 | [
"Galaxy"
] | ab8ef70dcfbe84d4c52a952932520e99b9116fb89fce65910889c41ab5c882fc |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Written by Lucas Sinclair.
MIT Licensed.
Contact at www.sinclair.bio
"""
# Built-in modules #
import multiprocessing, threading
# First party modules #
from autopaths.file_path import FilePath
from fasta import FASTA
################################################... | xapple/seqsearch | seqsearch/search/core.py | Python | mit | 3,600 | [
"BLAST"
] | 21a36605e0fbfcd485f1ad5ad6176005346336f5fa2dc014b72f3d1fbea64163 |
#!/usr/bin/python
import numpy as np
mdir = "mesh3d/"
fname = "out_p6-p4-p8"
####################
print "input mesh data file"
f1 = open(mdir+fname+".mesh", 'r')
for line in f1:
if line.startswith("Vertices"): break
pcount = int(f1.next())
xyz = np.empty((pcount, 3), dtype=np.float)
for t in range(pcount):
xyz... | jrugis/cell_mesh | mesh2vtk.py | Python | gpl-3.0 | 2,909 | [
"VTK"
] | b97a420f045b399136a505a734343356f5c7a85e0dccc8ce75e20083f1df457e |
# -*- coding: utf-8 -*-
# (c) Nelen & Schuurmans. GPL licensed, see LICENSE.rst.
# from lizard_mekong
from __future__ import (
print_function,
# unicode_literals, # gdal can't live with that, yet.
absolute_import,
division,
)
from django.core.management.base import BaseCommand, CommandError
from django.conf ... | lizardsystem/lizard-3ditask | lizard_3ditask/read_3di.py | Python | gpl-3.0 | 3,629 | [
"NetCDF"
] | 719a79a82d0869580fc200131e0d86b8d95d2945aa431990e3eaece20ceaf23c |
# sql/util.py
# Copyright (C) 2005-2016 the SQLAlchemy authors and contributors
# <see AUTHORS file>
#
# This module is part of SQLAlchemy and is released under
# the MIT License: http://www.opensource.org/licenses/mit-license.php
"""High level utilities which build upon other modules here.
"""
from .. import exc, u... | pcu4dros/pandora-core | workspace/lib/python3.5/site-packages/sqlalchemy/sql/util.py | Python | mit | 24,706 | [
"VisIt"
] | 00f5d776a34f88884c83965eba71187bc5c525bbfe21b3ae9ea812c6c99790ff |
"""
"""
from DIRAC import S_OK, S_ERROR
from DIRAC.Core.Utilities.CFG import CFG
from DIRAC.Core.Utilities import List
from DIRAC.ConfigurationSystem.Client.Helpers.Operations import Operations
from DIRAC.Core.Utilities.JDL import loadJDLAsCFG, dumpCFGAsJDL
from DIRAC.WorkloadManagementSystem.Agent.SiteDirector import... | andresailer/DIRAC | WorkloadManagementSystem/Client/JobState/JobManifest.py | Python | gpl-3.0 | 8,502 | [
"DIRAC"
] | e8f431112f17568fd4341e96eba61cbb11cf01351ae76b69d27c9d94b406e114 |
from __future__ import division, print_function, absolute_import
#from pnet.vzlog import default as vz
import numpy as np
import amitgroup as ag
import itertools as itr
import sys
import os
import gv
import pnet
import time
def test(ims, labels, net):
yhat = net.classify(ims)
return yhat == labels
if pnet.p... | amitgroup/parts-net | scripts/script.py | Python | bsd-3-clause | 6,561 | [
"Gaussian"
] | 2e5735f093f0ad35c54c409061512ac090c7a2d611ab71cd34f759316c7a7d7b |
from __future__ import absolute_import, division, print_function
import textwrap
import py
import pytest
from _pytest.config import PytestPluginManager
from _pytest.main import EXIT_NOTESTSCOLLECTED, EXIT_USAGEERROR
@pytest.fixture(scope="module", params=["global", "inpackage"])
def basedir(request, tmpdir_factory):... | davidszotten/pytest | testing/test_conftest.py | Python | mit | 16,754 | [
"VisIt"
] | 051d0f596f509b7cd6e57253b15ac52be691e904941edbcfc87c8f5657a997fd |
# -*- coding: utf-8 -*-
"""
Description:
Input: event / site data previously analyzed by photostim
Output:
- per-event probability of being direct / evoked / spont
- per-site probability of having evoked / direct input
- per-cell measurements of direct and presynaptic area
Whereas photostim largely o... | tropp/acq4 | acq4/analysis/modules/MapAnalyzer/MapAnalyzer.py | Python | mit | 42,614 | [
"Gaussian"
] | 0b05c9ee99a4027a34bfe79ef397ff733cf0c37c06219d93a9af209c0a459973 |
#!/usr/bin/env python
"""
Calculates distances between neighboring residues of a ligand molecule and produces a set of
unambiguous distance restraints for HADDOCK to keep it in place during semi-flexible refinement.
Produces, at most, one restraint per ligand atom.
Creates a file containing the restraints, named aft... | haddocking/haddock-tools | restrain_ligand.py | Python | apache-2.0 | 4,035 | [
"Biopython",
"PyMOL"
] | 910566d2db001669a1047af155223efd97c9b52802de8b4bb8bb18c133965d2c |
# (c) 2014, Brian Coca, Josh Drake, et al
# (c) 2017 Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
DOCUMENTATION = '''
cache: memcached
short_description: Use ... | alxgu/ansible | lib/ansible/plugins/cache/memcached.py | Python | gpl-3.0 | 7,483 | [
"Brian"
] | 9c46acb9db8571d2462f6d4d9687f34e55868bc3f6f9ef70c3197958d54de5c6 |
"""McGill Billboard Dataset Loader
.. admonition:: Dataset Info
:class: dropdown
The McGill Billboard dataset includes annotations and audio features corresponding to 890 slots from a random sample of Billboard chart slots.
It also includes metadata like Billboard chart date, peak rank, artist name, etc.
... | mir-dataset-loaders/mirdata | mirdata/datasets/billboard.py | Python | bsd-3-clause | 17,578 | [
"Brian"
] | 73b084636d411fbc1ae9901084dfbf023e698824f169414842fe66ec57c82043 |
# coding: utf-8
"""
MINDBODY Public API
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
OpenAPI spec version: v6
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
from __future__ import absolute_import
impo... | mindbody/API-Examples | SDKs/Python/test/test_client_api.py | Python | bsd-2-clause | 5,280 | [
"VisIt"
] | aea2eae67cad4941a7cbd4db5d6a03635de5c75559659df1655e25aecbb9729b |
# Lint as: python2, python3
# Copyright 2018 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
#
... | mlperf/training_results_v0.7 | Google/benchmarks/transformer/implementations/transformer-research-TF-tpu-v4-512/lingvo/core/rnn_layers.py | Python | apache-2.0 | 53,246 | [
"Gaussian"
] | 52b87af8f7e1360687986e69ac7f63b6a79e96dc1db41928c52af9eea19bb0cf |
#!/usr/bin/env python
import argparse
#import draw_world
import qworld
import moose
import moose_actions
import sys
import time
import world
from PyQt5 import QtCore
from PyQt5 import QtGui
from PyQt5 import QtWidgets
from PyQt5.Qt import Qt
if __name__ == '__main__':
parser = argparse.ArgumentParser(description... | jroivas/moose-mating | localmoose.py | Python | gpl-3.0 | 2,119 | [
"MOOSE"
] | 45221d97cffe25914368333fd0e177fac9890e61d73e7a2a41066020aa0b7f3a |
#!/usr/bin/env pvbatch
from paraview.simple import *
import pviz
import sys
oviz = pviz.viz(sys.argv) # instantiate viz object (and load data)
part = pviz.makeSlice( z = 0. ) # make slice
ResetCamera() # auto-adapt camera to part extent
for var in part.PointData: # loop over nod... | ruizanthony/pviz | examples/simple/cut_z0.py | Python | lgpl-3.0 | 503 | [
"ParaView"
] | e793373830857cdfa99e944a8c0c43b1f2f2952329b0d1fb670ca5351625fe6a |
##
## Composite pattern
##
class Item(object):
def __init__(self):
self.children = []
def add_child(self, child):
self.children.append(child)
def iterate(self, function):
for child in self:
function(child)
def traverse(self, visitor):
self.iterate(visitor.... | Adnn/GTD_Tasks | common_model.py | Python | mit | 634 | [
"VisIt"
] | 10ac4edb2514736f2c2d649779e04812d8640ce04717266035427da474e32b82 |
from rdkit import Chem
from rdkit.Chem import ChemicalForceFields
from rdkit import RDConfig
import unittest
import os
def feq(v1,v2,tol2=1e-4):
return abs(v1-v2)<=tol2
class TestCase(unittest.TestCase):
def setUp(self) :
self.dirName=os.path.join(RDConfig.RDBaseDir,'Code','GraphMol',
... | soerendip42/rdkit | Code/GraphMol/ForceFieldHelpers/Wrap/testHelpers.py | Python | bsd-3-clause | 8,883 | [
"RDKit"
] | 2c236f73e9c9eabc1603258b8cc3b26ad63d80b43b86dc4298ed1f16a3e79e76 |
# -*- coding: utf-8 -*-
"""
The BaseCase class is the main gateway for using The SeleniumBase Framework.
It inherits Python's unittest.TestCase class, and runs with Pytest or Nose.
All tests using BaseCase automatically launch WebDriver browsers for tests.
Usage:
from seleniumbase import BaseCase
class MyTest... | mdmintz/SeleniumBase | seleniumbase/fixtures/base_case.py | Python | mit | 311,022 | [
"VisIt"
] | 88fd6c88277a752bed8844e55395e46460732795734719deba6fd288fd00b7dd |
#! /usr/bin/env python
"""
Reads one or more sequence files from stdin or the argument list and outputs
a list of sequences.
"""
from Bio import SeqIO, SeqRecord
from Bio.Seq import Seq
from Bio.Alphabet import IUPAC
import argparse
import sys
import traceback
def main():
description = __doc__
# command lin... | jmeppley/py-metagenomics | get_sequences_from_gb.py | Python | mit | 7,647 | [
"Biopython"
] | 4d87aad226de37e6b7a4e5ff96839e6ea49902bf9cb1f561ce4168454988470b |
from spectral_cube import SpectralCube
import astropy.units as u
from scipy.ndimage import map_coordinates, binary_dilation
import numpy as np
import copy
import astropy.wcs as wcs
from astropy.io import fits
import os
import glob
mad_to_std_fac = 1.482602218505602
def mad_zero_centered(data, mask=None):
# Taken... | low-sky/degas | degas/masking.py | Python | gpl-3.0 | 20,433 | [
"Gaussian"
] | e0aaf9dbcc66285fc944b8993d4494b472ce2a75b5c4e1e7a8eea2d57377c261 |
# Measure EW function definition
# there's a lotta trash here, probably.
s2pi = sqrt(2 * pi)
s2 = sqrt(2.0)
def linear(x, slope, intercept):
return slope * x + intercept
def const(x, c):
return c
def voigt(x, amplitude, center, sigma, gamma):
if gamma is None:
gamma = sigma
z = (x - cente... | elvis1020/spex | legacy_functions/deblend-ew.py | Python | gpl-3.0 | 6,679 | [
"Gaussian"
] | 127cbcfbd1844f1ae47176c9f288edd8b6da898962c496abcfeaf444556f0620 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
import unittest
import os
import json
import warnings
import numpy as np
from pymatgen import Lattice, Structure, Specie
from pymatgen.transformations.standard_transformations import \
OxidationStateDecora... | dongsenfo/pymatgen | pymatgen/transformations/tests/test_advanced_transformations.py | Python | mit | 27,623 | [
"VASP",
"pymatgen"
] | 01581e57db65dab3c45499459802df519870143609313a267b8267b001207e5f |
# Copyright 2013 anthony cantor
# This file is part of pyc.
#
# pyc 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.
#
# pyc is distr... | cantora/pyc | pyc_localize.py | Python | gpl-3.0 | 4,576 | [
"VisIt"
] | 06c7975a3e307a7e456f943506be88be20c6ec3f1eb1b5301abf10370d745481 |
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'configuredialog.ui'
#
# Created: Thu Oct 24 14:38:01 2013
# by: pyside-uic 0.2.13 running on PySide 1.1.0
#
# WARNING! All changes made in this file will be lost!
from PySide import QtCore, QtGui
class Ui_ConfigureDialog(object):
... | MusculoskeletalAtlasProject/mapclient-tests | test_resources/updater_test/mayaviviewerstep-master/mapclientplugins/mayaviviewerstep/widgets/ui_configuredialog.py | Python | apache-2.0 | 4,663 | [
"Mayavi"
] | 33a4e3587fe89e50c1cbf038c77f1d49f12409e8a127806f94a0ad16afea31e5 |
# -*- coding: utf-8 -*-
# Copyright: (c) 2019-2021, Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
"""Installed collections management package."""
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import errno
import f... | ansible/ansible | lib/ansible/galaxy/collection/__init__.py | Python | gpl-3.0 | 65,265 | [
"Galaxy"
] | 6a37dae15793661599b39f6a68797ffea459d0834eecda3e4aba438238fcc43a |
import os, traceback
import xml.etree.ElementTree as xml
##
# Stores error information needed for printing diff messages
class XMLError(object):
##
# Constructor.
# @param err A one line error message
# @param msg A detailed message describing the error
def __init__(self, err, msg):
self.e... | Chuban/moose | python/TestHarness/XMLDiffer.py | Python | lgpl-2.1 | 11,878 | [
"VTK"
] | 9a46302bebf18ca569be3297ef1463f6971720fc4f037111a0c8dd575c2c4866 |
""" This is a test of the chain
ResourceStatus -> ResourceStatusHandler -> ResourceStatusDB
It supposes that the DB is present, and that the service is running
"""
# pylint: disable=invalid-name,wrong-import-position
from __future__ import print_function
from __future__ import absolute_import
from __future__ ... | ic-hep/DIRAC | tests/Integration/ResourceStatusSystem/Test_ResourceStatus.py | Python | gpl-3.0 | 20,363 | [
"DIRAC"
] | 2888bc0c7cded46f8c688e66f66fe19abc162b50755ba6c9fdf65ab6caa335e2 |
import os
import shutil
import subprocess
import sys
import toolz as tz
from bcbio import utils
from bcbio import bam
from bcbio.pipeline import config_utils
import bcbio.pipeline.datadict as dd
from bcbio.ngsalign import bowtie2, bwa
from bcbio.distributed.transaction import file_transaction
from bcbio.provenance impo... | vladsaveliev/bcbio-nextgen | bcbio/chipseq/__init__.py | Python | mit | 9,326 | [
"BWA"
] | 7e1ec4e9b4300075cfc324f80cdfc9d19140b48f7b837de24d315477a84947e6 |
# $HeadURL$
__RCSID__ = "$Id$"
from DIRAC.FrameworkSystem.private.logging.Logger import Logger
gLogger = Logger()
def getLogger():
return gLogger
| sposs/DIRAC | FrameworkSystem/Client/Logger.py | Python | gpl-3.0 | 158 | [
"DIRAC"
] | 44d0c76932456b72e8e3997ca10313150f7408616609b975a4544ac08703e3b0 |
#!/usr/bin/python3
from __future__ import absolute_import
from __future__ import print_function
#ensure# encoding: utf-8
"""
Module to set up run time parameters for Clawpack.
The values set in the function setrun are then written out to data files
that will be read in by the Fortran code.
"""
import os
# to exract... | mandli/surge-examples | isabel/setrun.py | Python | mit | 16,248 | [
"NetCDF"
] | 0570ee3753fb6abc41092021793287feaf34a61ccce1ae321bc9c096da0691c3 |
##############################################################################
# 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... | matthiasdiener/spack | var/spack/repos/builtin/packages/quantum-espresso/package.py | Python | lgpl-2.1 | 6,864 | [
"ESPResSo"
] | 5aca8c0637e20a3ebaddf713bbc7367f78130751ea5856939e30c2b8f729e5a6 |
from ase import Atoms
from gpaw import GPAW, FermiDirac, Mixer
from gpaw.wavefunctions.pw import PW
#This calculation is too heavy to run as an exercise!!
# Plane wave cutoff
pwcutoff = 600.0
# box length for isolated atom
L = 8.0
# Do the isolated calculation
isolated_silicon = Atoms(
symbols = ['... | robwarm/gpaw-symm | doc/exercises/rpa/atom/si.atom.rpa_init_pbe.py | Python | gpl-3.0 | 1,064 | [
"ASE",
"GPAW"
] | 3f22a8cc05fcb4314edbc9b562f3348647a6e72d5c1a9fdc1eb7bf3ee5f989f4 |
# Copyright (c) 2012 OpenStack Foundation
# 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 ... | ted-gould/nova | nova/tests/unit/compute/test_resource_tracker.py | Python | apache-2.0 | 60,618 | [
"exciting"
] | 786df9f1c467ac86652778200957389bde7381e5cefe9001a965d489356f2d02 |
# -*- coding: utf-8 -*-
"""Module that exposes a class for building a cyclic, directed graph, without the need
for special graph node objects. Part of the diskgraph utility.
Created and tested by Per Rovegård on a server running Ubuntu 11.04 with Python 2.7.1.
Distributed under the 3-Clause BSD license (http://openso... | provegard/diskgraph | diskgraph/sgraph.py | Python | bsd-3-clause | 3,210 | [
"VisIt"
] | 8bb261fe9f309622b12c5a146c717a47f43fe5c0932db7fbcaf4aaa4e7e5f30c |
# ============================================================================
#
# Copyright (C) 2007-2012 Conceptive Engineering bvba. All rights reserved.
# www.conceptive.be / project-camelot@conceptive.be
#
# This file is part of the Camelot Library.
#
# This file may be used under the terms of the GNU General... | jeroendierckx/Camelot | camelot/admin/table.py | Python | gpl-2.0 | 3,593 | [
"VisIt"
] | 0933c14a06208364f9f1746000e0b7df613361812a227eb24022e665356ab378 |
''' Provide a base class for all objects (called Bokeh Models) that can go in
a Bokeh |Document|.
'''
from __future__ import absolute_import, print_function
import logging
logger = logging.getLogger(__file__)
from json import loads
from operator import itemgetter
from six import iteritems
from .core.json_encoder i... | philippjfr/bokeh | bokeh/model.py | Python | bsd-3-clause | 24,874 | [
"VisIt"
] | d87afea16436ce1ca0c00ebb53b3b61fbdd17c75c180f4a7c53ad92c091f4b0c |
"""
LTE Molecule Modeling Tool
==========================
Uses astroquery to obtain molecular parameters.
Equations are based on Mangum & Shirley 2015 (2015PASP..127..266M)
Module API
^^^^^^^^^^
"""
from __future__ import print_function
import numpy as np
from astropy import units as u
from astropy import constants
... | pyspeckit/pyspeckit | pyspeckit/spectrum/models/lte_molecule.py | Python | mit | 23,645 | [
"Gaussian"
] | c9c724c11ffd156f30d9d4c82a01d2a646e2a17351a3334d21d5d8153e43b7ce |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.