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 |
|---|---|---|---|---|---|---|---|
from __future__ import absolute_import
from StringIO import StringIO
import mock
import requests
from boto.s3.key import Key
EXPECTED_TASK_STATUS_FAILED_RESPONSE = {
"s3_urls": {},
"src_url": "",
"state": "FAILURE",
"status": "{u'exc_message': u'fp is at EOF. Use rewind option or seek() to data start... | hwine/build-relengapi | relengapi/blueprints/archiver/test_util.py | Python | mpl-2.0 | 3,879 | [
"Brian"
] | a0ed09863c4d5788a4b26c17aaa64059489cd1775ef1014478aa581ee0c3e080 |
#!/usr/bin/env python
# -*- mode: python; coding: utf-8; -*-
##---------------------------------------------------------------------------##
##
## Copyright (C) 1998-2003 Markus Franz Xaver Johannes Oberhumer
## Copyright (C) 2003 Mt. Hood Playing Card Co.
## Copyright (C) 2005-2009 Skomoroh
##
## This program is free ... | TrevorLowing/PyGames | pysollib/tk/tkstats.py | Python | gpl-2.0 | 40,892 | [
"CASINO"
] | d3c77c77d0d1e468ef81e779e12ad106c149cc53b34850308e26040c8e2557fe |
# vim: set expandtab ts=4 sw=4 filetype=python fileencoding=utf8:
import logging
import textwrap
import psycopg2.extras
log = logging.getLogger(__name__)
fighters_and_moves = dict({
"Liu Kang": [
("Fire blast", 20),
("Flying kick", 30),
],
'Scorpion': [
("Harpoon", 30),
... | 216software/psycopg2-special-moves | ericlib.py | Python | bsd-2-clause | 10,053 | [
"BLAST"
] | d8950c0cd5bc57b639d9fae4d51b937d7a365f672049b68d88615e0badd9c018 |
# -c
print "BEGIN-LOG"
import pymol
import cmd
# need to do this for all supported file types because the load routines diverge...
def x(st):
print st
cmd.set("raise_exceptions",0)
valu = eval(st)
print valu
if cmd.is_error(valu):
cmd.set("raise_exceptions",1)
try:
print eval(st)... | gratefulfrog/lib | python/pymol/pymol_path/test/inp/C2000returns.py | Python | gpl-2.0 | 12,632 | [
"PyMOL"
] | 0129cae12b90b96ad0989a4723f54890f7bab1725372e57412dcd5f3e32e2c63 |
"""Classes for use with the XYZ format
Provides a Xyz class with reading and writing functions
"""
import copy as cp
from ase.atoms import Atoms
class Xyz(object):
"""Stores data of an xyz file.
"""
def __init__(self, filename=None, comment=None,
frames=None):
"""Standard con... | cpignedoli/asetk | asetk/format/xyz.py | Python | mit | 2,839 | [
"ASE"
] | c97c5d9e7823345aaab49c03142dcc4c6a27ff301233fbcba2f3c54f028ed605 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys
import logging
from uuid import uuid4
from datetime import datetime, timedelta
from ujson import dumps
from colorama import Fore, Style
from octopus import TornadoOctopus
from octopus.limiter.redis.per_domain import Limiter
from retools.lock import Lock, LockTi... | holmes-app/holmes-api | holmes/worker.py | Python | mit | 9,785 | [
"Octopus"
] | 373fca7a8b272d3a5e9cb5c846bd71ead3c6c3963546b30c10bcf02ae90a0f62 |
#!/usr/bin/env python2
# vim:fileencoding=utf-8
# License: GPLv3 Copyright: 2015, Kovid Goyal <kovid at kovidgoyal.net>
from __future__ import (unicode_literals, division, absolute_import,
print_function)
from collections import OrderedDict
from functools import partial
from PyQt5.Qt import (... | hazrpg/calibre | src/calibre/gui2/tag_mapper.py | Python | gpl-3.0 | 14,651 | [
"MOOSE"
] | 7ff9a1cf23a4c839eba388a823885a0f08470685401dbb3a1f4c268fb8e1cf1a |
"""
*******************************************************
*
* psyFunction - GENERATE GENERAL FORMULATION OF PSYCHOMETRIC FUNCTION
*
* License: Apache 2.0
* Written by: Michael Slugocki
* Created on: April 18, 2018
* Last updated: August 30, 2018
*
*******************************************************
... | SlugocM/bayesfit | bayesfit/psyFunction.py | Python | apache-2.0 | 2,658 | [
"Gaussian"
] | e81cc5196fcca36d97cce717aac8017d773256776c86f3bc3b8f733e8e9af32e |
import mdp
# import numeric module (scipy, Numeric or numarray)
numx, numx_rand, numx_linalg = mdp.numx, mdp.numx_rand, mdp.numx_linalg
numx_description = mdp.numx_description
import random
import itertools
def timediff(data):
"""Returns the array of the time differences of data."""
# this is the fastest way... | ME-ICA/me-ica | meica.libs/mdp/utils/routines.py | Python | lgpl-2.1 | 15,909 | [
"Gaussian"
] | f56a30a30a1f89c6ae76b9ca3c3450dcfd9a9a322c117eab38b69422fd148680 |
#!/usr/bin/env python
# Copyright 2014-2018 The PySCF Developers. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# U... | gkc1000/pyscf | pyscf/geomopt/test/test_berny_solver.py | Python | apache-2.0 | 1,843 | [
"PySCF"
] | e8f3866d7fb23f7890567c5e522d635a6ab2410452847cc195b897e34f53632d |
# This Python file uses the following encoding: utf-8
# Create your views here.
from django.http import HttpResponse, HttpResponseRedirect, Http404
from django.template.loader import get_template
from django.template import Context
from django.utils.safestring import SafeString
from django.utils.html import strip_tags... | hr4e/QuestionnaireQx | multiquest/views.py | Python | apache-2.0 | 250,803 | [
"VisIt"
] | d06ad0bd8a5a65eefc427ec959ef8a9d197a0b43769cba2f5426c0cb53057d82 |
from rdkit import Chem
from rdkit.Chem import AllChem
import copy
import sys
from sygma.treenode import TreeNode
import logging
logger = logging.getLogger('sygma')
class Tree(object):
"""
Class to build and analyse a metabolic tree
:param parentmol:
An RDKit molecule
"""
def __init__(self... | 3D-e-Chem/sygma | sygma/tree.py | Python | gpl-3.0 | 6,343 | [
"RDKit"
] | 3cd0d66121375dd15a98cd01b0ce7116ca9958c0e39ea69358f7d6edc791a762 |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding: utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4
from __future__ import print_function
from MDAnalysis.core.groups import Atom, AtomGroup, Residue, ResidueGroup
from abc import ABCMeta, abstractmethod
import numpy as np
class Observable(o... | Marcello-Sega/pytim | pytim/observables/observable.py | Python | gpl-3.0 | 6,549 | [
"MDAnalysis"
] | 94cc669f5294cf6185b1d503485fb075c04fb6e8b0b42b4b11314110c899d211 |
# (c) 2014, Brian Coca, Josh Drake, et al
#
# 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 later version.
... | M0ses/ansible | v2/ansible/plugins/cache/base.py | Python | gpl-3.0 | 1,241 | [
"Brian"
] | 2b69061fa7869f374fcd930cff691b7b537b207dfb06a9b8329a1b5bf9c39ba8 |
from __future__ import division, print_function, unicode_literals
# This code is so you can run the samples without installing the package
import sys
import os
sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..'))
#
testinfo = "f 10 0.033, s, f 20 0.033, s, f 30 0.033, s, f 30 0.033, s, q"
tags = "particl... | dangillet/cocos | test/test_particle_fire.py | Python | bsd-3-clause | 976 | [
"Galaxy"
] | fca8957c2a3a6c8fdb435f751b70444b842c7680f2e1395d25e15b9efd1ddeed |
# -*- coding: utf-8 -*-
#
# Calls tracer after every successful transaction.
# Also supplies the 'tracer' command.
#
# Copyright (C) 2015 Jakub Kadlčík
#
# 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 Pu... | esmil/dnf-plugins-extras | plugins/tracer.py | Python | gpl-2.0 | 3,753 | [
"VisIt"
] | f7cc37c484d1ed173e8323a09f0e5f57a88ca8ceb15f6950f3be246cffb48ca3 |
from PyGMO.problem._problem_space import cassini_1, gtoc_1, gtoc_2, cassini_2, rosetta, messenger_full, tandem, laplace, sagas, mga_1dsm_alpha, mga_1dsm_tof, mga_incipit, mga_incipit_cstrs, mga_part, _gtoc_2_objective
# Redefining the constructors of all problems to obtain good documentation
# and allowing kwargs
de... | kartikkumar/pagmo | PyGMO/problem/_gtop.py | Python | gpl-3.0 | 32,258 | [
"VisIt"
] | e1d9baa1da97b406868cf68911f774ff21042965017024a737cd4436dc49ae15 |
#
# @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
#... | ashutoshvt/psi4 | psi4/driver/driver_nbody.py | Python | lgpl-3.0 | 34,436 | [
"Psi4"
] | 3e57d41bde2722598de85e93ec3e776a12d179533093e170e2566d21449d467c |
from hercule import Request
from config import api_key #This assumes you have an external config file that houses your API key. If you do not, to run this example, delete this line and input your API key when we initialize the Request object
def main():
# Initialize your Request class by passing in the api key - vis... | Greedoid/Hercule | example.py | Python | mit | 2,005 | [
"VisIt"
] | 7bee984af214b02a25a2a5d28646c6e089f72bd39613a5d9deed19afa8572a3e |
from __future__ import division
import collections
import importlib
import networkx as nx
import numpy as np
PI = np.pi
from neurokernel.pattern import Pattern
from .geometry.opticaxis import opticaxisFactory, RuleHexArrayMap, OpticAxisRule
def divceil(x, y):
return (x+y-1)//y
class Ommatidium(object):
d... | neurokernel/retina | retina/retina.py | Python | bsd-3-clause | 24,043 | [
"NEURON"
] | 1923806821b733c5ea936126c46419a0083d0076fb721ecaa2304d40499f4671 |
# (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... | hlieberman/debian-ansible | lib/ansible/utils/__init__.py | Python | gpl-3.0 | 41,324 | [
"VisIt"
] | 2892de42246acab4e7603cc410282e18bece06e4b68d1dfd3009f770ba571a6e |
# -*- coding: utf-8 -*-
"""
End-to-end tests for survey feature
"""
import bok_choy.browser
from ...fixtures.course import CourseFixture, XBlockFixtureDesc
from ...pages.lms.auto_auth import AutoAuthPage
from ...pages.lms.courseware import CoursewarePage
from ...pages.lms.course_nav import CourseNavPage
from ...pages.... | nttks/edx-platform | common/test/acceptance/tests/lms/test_ga_survey.py | Python | agpl-3.0 | 5,069 | [
"VisIt"
] | 8f2b6ebb24369e936ac9e5b6e764330e5683fba7b16a8cae6e620b1b3f934538 |
""" This is the StorageElement class.
"""
import re
# # custom duty
import time
import datetime
import copy
import errno
import threading
import sys
# # from DIRAC
from DIRAC import gLogger, gConfig, siteName
from DIRAC.Core.Utilities import DErrno
from DIRAC.Core.Utilities.ReturnValues import S_OK, S_ERROR, returnSi... | Andrew-McNab-UK/DIRAC | Resources/Storage/StorageElement.py | Python | gpl-3.0 | 46,988 | [
"DIRAC"
] | 48d65861d10179ca3995cccd9aecc40adcb5a4528baab9858f9f828afb4984de |
#-----------------------------------
# MAL Bot Configuration
#-----------------------------------
VERSION = '0.7'
USER_AGENT = 'myanimelist_bot v' + VERSION + ' by /u/linkian209'
USERNAME = ''
PASSWORD = ''
MAL_UN = b''
MAL_PW = b''
MIN_ACCEPTABLE_CLOSENESS = .8
FOOTER = '^^^This ^^^comment ^^^was ^^^automatically ^^^c... | linkian209/MAL-Bot | mal_bot_skel.py | Python | mit | 541 | [
"VisIt"
] | 14653628cf05bf4de13ddbbec3760c6f245e557a13a0aec1cbae28e28401cc18 |
# -*- coding: utf-8 -*-
{
'# selected': '# được lựa chọn',
"'Cancel' will indicate an asset log entry did not occur": "'Hủy' sẽ chỉ dẫn một lệnh nhập không thực hiện được",
"A location that specifies the geographic area for this region. This can be a location from the location hierarchy, or a 'group location', or a... | sahana/Turkey | languages/vi.py | Python | mit | 374,100 | [
"VisIt"
] | f9e3cbbbffadd3b37069f9c85d62fd53f1144ca6eb160110462707853edde946 |
##############################################################################
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-64... | lgarren/spack | var/spack/repos/builtin/packages/r-alsace/package.py | Python | lgpl-2.1 | 2,081 | [
"Bioconductor"
] | 447dff53da8ba037fbaed5b8c7bc34d904ec281a598456e1f34115b0f4ad44c4 |
### ############################################################################################################
### #
### # Project: # teh_tools - by The Highway 2013.
### # Author: # The Highway
### # Version: # (ever changing)
### # Description: # My collection of common tools.
### #
### #############... | HIGHWAY99/plugin.audio.ukradio | teh_tools.py | Python | gpl-3.0 | 100,415 | [
"VisIt"
] | 00a667ae2fa3c9c6ba5c607e13fc737fd0fb3dbdfefdedac0c777d2a6e92335e |
from __future__ import print_function
import sys
import os
import numpy as np
from collections import OrderedDict
from astrometry.util.fits import fits_table
from astrometry.util.file import trymakedirs
from common import Decals, DecamImage
from astrometry.libkd.spherematch import match_radec
'''
This script is use... | gregreen/legacypipe | py/legacypipe/queue-calibs.py | Python | gpl-2.0 | 12,890 | [
"Galaxy"
] | 0f0781fd9a977502e0bfa4a71b174e62337aeb7eabb537ab278e394d5ad00551 |
import sys
import ast
import constants as c
import datetime
import inspect
from matplotlib.dates import date2num
import meteorologicalfunctions as mf
import numpy
import os
import qcck
import qcfunc
import qcio
import qcutils
from scipy import interpolate, signal
import time
import xlrd
from matplotlib.mlab import grid... | OzFlux/OzFluxQC | scripts/qcts.py | Python | gpl-3.0 | 133,038 | [
"NetCDF"
] | df051679f1726d4c656c44e697f4088a4f8ddf4438a49304d0a03af1caf406f7 |
# -*- coding: utf-8 -*-
# TAMkin is a post-processing toolkit for normal mode analysis, thermochemistry
# and reaction kinetics.
# Copyright (C) 2008-2012 Toon Verstraelen <Toon.Verstraelen@UGent.be>, An Ghysels
# <An.Ghysels@UGent.be> and Matthias Vandichel <Matthias.Vandichel@UGent.be>
# Center for Molecular Modeling... | molmod/tamkin | tamkin/io/trajectory.py | Python | gpl-3.0 | 10,931 | [
"Avogadro",
"Gaussian"
] | 8c1d7566ef71f5b3b074c47e3cfb72028f3fa007dee6e1154c60e8136226e40a |
"""Test functions for linalg._solve_toeplitz module
"""
from __future__ import division, print_function, absolute_import
import numpy as np
from scipy.linalg._solve_toeplitz import levinson
from scipy.linalg import solve, toeplitz, solve_toeplitz
from numpy.testing import (run_module_suite, assert_equal, assert_allclos... | valexandersaulys/airbnb_kaggle_contest | venv/lib/python3.4/site-packages/scipy/linalg/tests/test_solve_toeplitz.py | Python | gpl-2.0 | 3,975 | [
"Gaussian"
] | c7a0167d8422c100aa63563cd5f1748ed985e7465793614d98054c94cff2f60c |
"""
.. _statsrefmanual:
==========================================
Statistical functions (:mod:`scipy.stats`)
==========================================
.. currentmodule:: scipy.stats
This module contains a large number of probability distributions as
well as a growing library of statistical functions.
Each univari... | arokem/scipy | scipy/stats/__init__.py | Python | bsd-3-clause | 10,098 | [
"Gaussian"
] | 2cb61c75a87bfa15e50f6958252642c31f49fa538a82d08441e97938658facae |
""" Test class for Stalled Job Agent
"""
# imports
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from mock import MagicMock
# DIRAC Components
from DIRAC.WorkloadManagementSystem.Agent.StalledJobAgent import StalledJobAgent
from DIRAC import gLogger
# Mo... | yujikato/DIRAC | src/DIRAC/WorkloadManagementSystem/Agent/test/Test_Agent_StalledJobAgent.py | Python | gpl-3.0 | 4,056 | [
"DIRAC"
] | a85df69525c16d46a3a4f826ec7c8505888a0c913c3188c87579bdd119cc83b5 |
# !usr/bin/env python2
# -*- coding: utf-8 -*-
#
# Licensed under a 3-clause BSD license.
#
# @Author: Brian Cherinka
# @Date: 2017-05-07 16:40:21
# @Last modified by: Brian Cherinka
# @Last Modified time: 2017-09-28 17:17:58
from __future__ import print_function, division, absolute_import
from marvin.tests.api.co... | albireox/marvin | python/marvin/tests/api/test_query.py | Python | bsd-3-clause | 3,570 | [
"Brian"
] | 6b297075b490f88be7a5e2e73d9c2b185b1460926569303ad8936a4ac245b5ab |
#!/usr/bin/python
from ase import Atoms
from ase.visualize import view
from ase.calculators.emt import EMT
from ase.constraints import FixAtoms
from ase.io import write
from ase.io import read
import sys
nargs = len(sys.argv)
argv = sys.argv[1]
print 'argv: ',argv
fname = 'structure'+argv
slab = read(fname)
slab.set_... | ZimmermanGroup/molecularGSM | GSM/grad.py | Python | mit | 522 | [
"ASE"
] | 8b7a0023f84609961255759284d00fb94e1ef53ed83b8bedad963e387e1ec067 |
#!/usr/bin/env python
# encoding: utf-8
from ast import literal_eval
import codecs
import io
from nose.tools import *
from nose import SkipTest
import networkx as nx
from networkx.readwrite.gml import literal_stringizer, literal_destringizer
import os
import tempfile
try:
unicode
except NameError:
unicode = s... | kenshay/ImageScript | ProgramData/SystemFiles/Python/Lib/site-packages/networkx/readwrite/tests/test_gml.py | Python | gpl-3.0 | 13,834 | [
"Cytoscape"
] | bda17853b85365df7a7c3b6dabbab17ba78613487b64d13387e3bbb161f2ce98 |
input_name = '../examples/biot/biot.py'
output_name = 'test_biot.vtk'
from testsBasic import TestInput
class Test( TestInput ):
pass
| olivierverdier/sfepy | tests/test_input_biot.py | Python | bsd-3-clause | 139 | [
"VTK"
] | aab6b2f66ba535f6f756432a1e2b454e39ec2a649e96a59b79f0facd25e10ed8 |
# Natural Language Toolkit: Feature Structures
#
# Copyright (C) 2001-2013 NLTK Project
# Author: Edward Loper <edloper@gradient.cis.upenn.edu>,
# Rob Speer,
# Steven Bird <stevenbird1@gmail.com>
# URL: <http://nltk.sourceforge.net>
# For license information, see LICENSE.TXT
"""
Basic data classes for ... | bbengfort/TextBlob | textblob/nltk/featstruct.py | Python | mit | 102,193 | [
"VisIt"
] | 522a3501b60955271e0d1d13937aa3f1d834f15d4f8425c27a7f97334b5c0c0d |
import json
from pathlib import Path
from ._schemata import (
TomvizSchema,
)
from ._models import ( # noqa
Pipeline,
DataSource,
init_operators,
init_modules,
)
from ._jsonpatch import (
sync_state_to_app,
sync_state_to_python
)
from ._pipeline import PipelineStateManager
from ._views ... | OpenChemistry/tomviz | tomviz/python/tomviz/state/__init__.py | Python | bsd-3-clause | 2,402 | [
"ParaView"
] | 437b2f1e74e0d94648f25aa3893878d66f73fefffbc64d18bf95634db1401717 |
"""Options manager for :class:`Poly` and public API functions. """
from sympy.core import S, Basic, sympify
from sympy.utilities import any, all, numbered_symbols, topological_sort
from sympy.polys.polyerrors import (
GeneratorsError,
OptionError,
FlagError,
)
import sympy.polys
import re
class Option(... | minrk/sympy | sympy/polys/polyoptions.py | Python | bsd-3-clause | 19,349 | [
"Gaussian"
] | 04c88bd901e56dd7315b1bb6977e37d2d18ecd4dad26f9db7602874e5329d7ad |
#!/usr/bin/env python
# Copyright 2014-2018 The PySCF Developers. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# U... | gkc1000/pyscf | pyscf/cc/test/test_eom_rccsd.py | Python | apache-2.0 | 38,148 | [
"PySCF"
] | c1ee19a3a21f58ca391c26487d9185c294c08539af37e908388c12276c4a940e |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding:utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4
#
# 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)
#
# Released under th... | alejob/mdanalysis | package/MDAnalysis/coordinates/memory.py | Python | gpl-2.0 | 14,502 | [
"MDAnalysis"
] | 2e1d6406e0f47fe9fe525a07aa7b0e004a931f125a06764b9d13c63812957838 |
"""
This OVITO script exports the dislocation lines extracted by the
DXA analysis modifier to a file.
You should run this script from within the graphical user interface
using the Scripting->Run Script File menu option.
"""
from ovito import *
from ovito.data import *
def export_dislocations(disl... | srinath-chakravarthy/ovito | examples/scripts/export_dislocations.py | Python | gpl-3.0 | 914 | [
"OVITO"
] | 9ec00e28cccc53cb14ec8a6e3acf14952a8e20fa5e7df217c2c6f8759c32c30a |
#!/usr/bin/python2.7
# encoding: utf-8
#Libs import
from __future__ import division
import numpy as np
import sys
from utide import solve, reconstruct
#TR comment: 2 alternatives
#import netCDF4 as nc
from scipy.io import netcdf
from scipy.io import savemat
from scipy.io import loadmat
from pydap.client import open_ur... | rsignell-usgs/PySeidon | pyseidon/fvcomClass/fvcomClass.py | Python | agpl-3.0 | 15,044 | [
"NetCDF"
] | 7737a189d7956a9005037fe6ba155879612ddab4154e2348a7cf9e34b2c5c266 |
"""
Copyright (c) 2015 Andreea Georgescu
Created on Wed Nov 19 00:18:55 2014
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.
... | SamWitte/Codds_DarkMatter | src/Data/PICO_500.py | Python | gpl-2.0 | 1,807 | [
"DIRAC"
] | 98fa228e9cbc3ec296540cc4c1243fbc931aa0dc8a26b45c6f0ab36b0571b66d |
# Author: Samuel Genheden samuel.genheden@gmail.com
"""
Routines to parse files and streams
"""
import fileinput
import re
import numpy as np
from units import *
def stdin2ndarray() :
"""
Parse columns and rows of data from standard input into a numpy.ndarray
"""
data = []
for line in fileinput... | SGenheden/Scripts | sgenlib/parsing.py | Python | mit | 9,364 | [
"Gromacs",
"LAMMPS"
] | c19761bf204cc07348f6b77b78fec95284fc53f2877f3df315dd95c78eb9b314 |
#!/usr/bin/env python
##################################################
## DEPENDENCIES
import sys
import os
import os.path
try:
import builtins as builtin
except ImportError:
import __builtin__ as builtin
from os.path import getmtime, exists
import time
import types
from Cheetah.Version import MinCompatib... | MOA-2011/e2openplugin-OpenWebif | plugin/controllers/views/web/epgsearch.py | Python | gpl-2.0 | 7,504 | [
"VisIt"
] | 573655f60423e4735b540d976e055a34d95efdd0074be5ad20242d2ff6a2b916 |
"""
User policy settings
"""
from askbot.conf.settings_wrapper import settings
from askbot.conf.super_groups import LOGIN_USERS_COMMUNICATION
from askbot.deps import livesettings
from django.conf import settings as django_settings
from askbot.skins import utils as skin_utils
from django.utils.translation import ugettex... | rosihorrorshow/askbot-devel | askbot/conf/user_settings.py | Python | gpl-3.0 | 3,162 | [
"VisIt"
] | 1ae8266009056c37d570b88e7b3e8f2ba5411baae618f30a200f1c3a088dd448 |
#!/usr/bin/python2.4
#
# Copyright 2007 Google Inc. 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 require... | digideskio/transitfeed | transitfeed/shapelib.py | Python | apache-2.0 | 19,617 | [
"VisIt"
] | d945eb9a8c231eacdc04ed5e6a7c0b912d87a419ae7333bb5c8946011d4cb68d |
# Copyright (c) 2012 - 2014, GPy authors (see AUTHORS.txt).
# Licensed under the BSD 3-clause license (see LICENSE.txt)
import numpy as np
from scipy.special import gammaln, digamma
from ...util.linalg import pdinv
from domains import _REAL, _POSITIVE
import warnings
import weakref
class Prior(object):
domain =... | gusmaogabriels/GPy | GPy/core/parameterization/priors.py | Python | bsd-3-clause | 26,352 | [
"Gaussian"
] | a1efb10279a74bf604f9a43127e676cb0bb784d8ba626a674e58b4974487ba85 |
from __future__ import print_function
import os, shutil, fileinput
import numpy
import yaml
import read_config
import file_io
# get default timestep
def get_default_timestep(configs):
this_file = 'Scene.main.mdl'
this_path = os.path.join(configs['model_dir'],this_file)
with open(this_path) as f:
... | donovanr/weighted-ensemble-izer | weightedensemblizer/file_io.py | Python | gpl-2.0 | 5,710 | [
"MCell"
] | 5e408f2ed9a0ee98055bbf305fcda2b576c6b350a38612a61a4192c3b8d0e93d |
#!/usr/bin/env python
'''
Optimize the geometry of excited states using CASSCF or CASCI
Note when optiming the excited states, states may flip and this may cause
convergence issue in geometry optimizer.
'''
from pyscf import gto
from pyscf import scf, mcscf
mol = gto.Mole()
mol.atom="N; N 1, 1.1"
mol.basis= "6-31g"... | gkc1000/pyscf | examples/geomopt/12-mcscf_excited_states.py | Python | apache-2.0 | 1,744 | [
"PySCF"
] | 08726ba82b028169d1f964c9b4bee14ad6b500aa8d245023c18781b17433fdd8 |
from __future__ import print_function, division
import os
from pathlib import Path
from datetime import datetime
import inspect
import warnings
import platform
import numpy as np
import pandas as pd
import pyemu
from ..pyemu_warnings import PyemuWarning
import copy
import string
# the tolerable percent difference (10... | jtwhite79/pyemu | pyemu/utils/pst_from.py | Python | bsd-3-clause | 164,481 | [
"Gaussian"
] | d73c5df9bc0d2b97d6103ca2be056f16dea60a18b93183cb65fe1e7d7afb3b1e |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys
from distutils.util import strtobool
def yn_prompt(query):
"""Generic Y/N Prompt"""
sys.stdout.write('%s [y/n]: ' % query)
val = raw_input()
try:
ret = strtobool(val)
except ValueError:
sys.stdout.write('Please answer with a... | danielpalstra/train | train/labs/ucp/scripts/ubuntu-14.04.py | Python | apache-2.0 | 2,641 | [
"ORCA"
] | 5641a72619bea999791decb2f4683ed861443497a6d62669efc7de431e76231d |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.conf import settings
from django.conf.urls import include, url
from django.conf.urls.static import static
from django.contrib import admin
from django.views.generic import TemplateView
from django.views import defaults as default_views
urlpat... | akarambir/reddit-clone | config/urls.py | Python | mit | 1,435 | [
"VisIt"
] | 55dd98a9241de77ff253eb8bbf2e0f3b136859253c48492eac91fda94325f340 |
"""User-friendly public interface to polynomial functions. """
from sympy.core import (
S, Basic, Expr, I, Integer, Add, Mul, Dummy, Tuple, Rational
)
from sympy.core.mul import _keep_coeff
from sympy.core.sympify import (
sympify, SympifyError,
)
from sympy.core.decorators import (
_sympifyit,
)
from ... | flacjacket/sympy | sympy/polys/polytools.py | Python | bsd-3-clause | 151,151 | [
"Gaussian"
] | 4721a81a5ada0f355410bfa60094fbfde8f0ca4f1520b9f1c7ac1489a7694b04 |
#!/usr/bin/env python3
import numpy as np
from matplotlib import pyplot as plt
from LoLIM.utilities import processed_data_dir, v_air
from LoLIM.interferometry import read_interferometric_PSE as R_IPSE
from LoLIM.interferometry import impulsive_imager_tools as inter_tools
from LoLIM.signal_processing import half_hann... | Bhare8972/LOFAR-LIM | LIM_scripts/interferometry/examples/image_source.py | Python | mit | 10,342 | [
"Brian"
] | 383d34ffeb5a42b0830fe6b706184193f86c4ebb3b6746f5ae342ef6ed1af2a5 |
# ----------------------------------------------------------------------
# LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
# https://www.lammps.org/ Sandia National Laboratories
# Steve Plimpton, sjplimp@sandia.gov
#
# Copyright (2003) Sandia Corporation. Under the terms of Contract
# DE-A... | akohlmey/lammps | python/lammps/pylammps.py | Python | gpl-2.0 | 30,546 | [
"LAMMPS"
] | 2e258cb4a107883b59785ebbf44ef83c253f4ea81e88ef9bcdb243e6d8c8d612 |
# Copyright 2017 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | kobejean/tensorflow | tensorflow/contrib/data/python/kernel_tests/resample_test.py | Python | apache-2.0 | 6,486 | [
"DIRAC"
] | 9a4b0e50313755b9e0238b6f6496dfea7a86d7ddacf7492bcf38e808e52e8f74 |
import scipy.io as sio
import matplotlib.pyplot as plt
from v1_lstm import *
from costs_v1 import *
from layers_v1 import *
from neon.backends import gen_backend
from neon.initializers import GlorotUniform
from neon.layers import GeneralizedCost, LSTM, Affine, RecurrentLast, Dropout, GRU, RecurrentSum
from neon.models ... | elijahc/ml_v1 | rnn/neon/test_v1_lstm.py | Python | mit | 5,537 | [
"Gaussian"
] | 711926648c810134a3cd8d86a368469df184eabe8a016dd3e12493ce60bb6352 |
import unittest
import os
import ruamel.yaml as yaml
from pymatgen import SETTINGS_FILE, _load_pmg_settings, get_structure_from_mp, \
SETTINGS, loadfn
from pymatgen import Structure
from pymatgen.io.vasp import Vasprun
import warnings
test_dir = os.path.join(os.path.dirname(__file__), "..", "..", 'test_files')
... | gVallverdu/pymatgen | pymatgen/tests/test_init.py | Python | mit | 1,797 | [
"VASP",
"pymatgen"
] | a8efb58ec6e9251d99048e0e395ea3865f856eaa4f59ef57c22ebac2311c7736 |
#-------------------------------------------------------------------------------
# Name: results_analysis
# Purpose: Contains graphing and analysis functions to look at results
#
# Author: dd
#
# Created: 12/02/2015
# Copyright: (c) dd 2015
# Licence: <your licence>
#--------------------------... | danieldmm/minerva | evaluation/results_analysis.py | Python | gpl-3.0 | 12,728 | [
"Amber"
] | 954efdbf6ccace9d864ac0ba6f0fb4e1c3213728fd26be2f26c62d27e361f3dd |
import pysal
from pysal.common import *
import pysal.weights
import numpy as np
from scipy import sparse, float32
import scipy.spatial
import os
import operator
import scipy
__all__ = ['lat2W', 'block_weights', 'comb', 'order', 'higher_order',
'shimbel', 'remap_ids', 'full2W', 'full', 'WSP2W',
'i... | volaya/processing_pysal | ext-libs/pysal/weights/util.py | Python | gpl-2.0 | 31,890 | [
"COLUMBUS"
] | 5cbb737c1dedfd8015b7a1d224eaba7f3225822a3f5eafc8f76e346ca2abf6ad |
"""Routines for manipulating restart files"""
from __future__ import print_function
from __future__ import division
try:
from builtins import str
from builtins import range
except:
pass
try:
from boututils.datafile import DataFile
except ImportError:
raise ImportError("ERROR: restart module needs ... | erikgrinaker/BOUT-dev | tools/pylib/boutdata/restart.py | Python | gpl-3.0 | 26,712 | [
"Gaussian"
] | cc6b90725e8363d4c449311a7ffc6a8082f23c9e225edfb4e7a3bc32743c2421 |
########################################################################
# $HeadURL$
# File : CSGlobals.py
# Author : Ricardo Graciani
########################################################################
"""
Some Helper functions to retrieve common location from the CS
"""
__RCSID__ = "$Id$"
#from DIRAC import... | calancha/DIRAC | ConfigurationSystem/Client/Helpers/CSGlobals.py | Python | gpl-3.0 | 1,556 | [
"DIRAC"
] | 8aeb5ec25dfffd4dee9438449f1111edf94eb41cdf9979553f54ecf4ce74d6c9 |
"""
This file is part of the RepeatDesigner package
"""
import os
import sys
import tempfile
import itertools
import random
import numpy as np
import Bio.pairwise2
import Bio.SeqUtils
import Bio.SeqIO
import Bio.SeqRecord
import modellerlib as mdlib
def model_mc_worker(mc_input):
"""
Simple modelling worke... | daviddesancho/RepeatDesigner | repeatdesigner/designlib.py | Python | lgpl-3.0 | 10,228 | [
"Biopython"
] | 354fe6ba0461edba6879f1c558ff33db08ddf580b908358828fe897230e0a820 |
# -*- coding: utf-8 -*-
"""
This file contains the general Qudi trace analysis logic.
Qudi is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
... | drogenlied/qudi | logic/trace_analysis_logic.py | Python | gpl-3.0 | 33,335 | [
"Gaussian"
] | b8a6e7e871214a6f0f20757082d059d295207f42cdfcf4056ee736177c3f4608 |
"""Tests for algorithms for partial fraction decomposition of rational
functions. """
from sympy.polys.partfrac import (
apart_undetermined_coeffs,
apart,
apart_list, assemble_partfrac_list
)
from sympy import (S, Poly, E, pi, I, Matrix, Eq, RootSum, Lambda,
Symbol, Dummy, factor, toget... | grevutiu-gabriel/sympy | sympy/polys/tests/test_partfrac.py | Python | bsd-3-clause | 5,244 | [
"Gaussian"
] | 721eacd3b6b6e36cdee6d143d817366abb523f1bd4f7ac607ed8866a8cf60a77 |
from os import getenv
import json
import requests
import responses
from behave import *
from app import server
from compare import expect, ensure
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions
BASE_URL = g... | nyu-devops-golf-team/wishlist | features/steps/wishlist_steps.py | Python | mit | 4,484 | [
"VisIt"
] | d92129862e014cddd13f92412ff05e51ca015873837d6ce451559c03c4c63203 |
# Copyright (c) 2013, GlaxoSmithKline Research & Development Ltd.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistributions of source code must retain the above copyright
# ... | rdkit/rdkit | Contrib/fraggle/rdkit_tversky.py | Python | bsd-3-clause | 3,883 | [
"RDKit"
] | fa90a32d388099fcc5bb06616a1fc8e8092d9e90c7c1a51f23fbcf27800ce9a8 |
r"""
Nearly incompressible linear elasticity in mixed displacement-pressure
formulation with comments.
Find :math:`\ul{u}`, :math:`p` such that:
.. math::
\int_{\Omega} D_{ijkl}\ e_{ij}(\ul{v}) e_{kl}(\ul{u})
- \int_{\Omega} p\ \nabla \cdot \ul{v}
= 0
\;, \quad \forall \ul{v} \;,
- \int_{\Omega} ... | RexFuzzle/sfepy | examples/linear_elasticity/linear_elastic_up.py | Python | bsd-3-clause | 3,356 | [
"VTK"
] | 271383b65a8b623b4a4d3dc39e418c508ab299f939aff61809ecdb0e3669cae6 |
#!/usr/bin/env python
"""Setup configuration for the python grr modules."""
# pylint: disable=unused-variable
# pylint: disable=g-multiple-import
# pylint: disable=g-import-not-at-top
import ConfigParser
import os
import subprocess
from setuptools import find_packages, setup, Extension
from setuptools.command.develop... | pidydx/grr | setup.py | Python | apache-2.0 | 6,041 | [
"GULP"
] | dcda6baf41dc70058b80d5686b6f42bf583923eaa8b123388cda85c75b80072e |
# Orca
#
# Copyright 2004-2008 Sun Microsystems Inc.
# Copyright 2010 Joanmarie Diggs
#
# 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 op... | GNOME/orca | src/orca/scripts/apps/pidgin/script.py | Python | lgpl-2.1 | 7,810 | [
"ORCA"
] | ede48fceaf2e3bdfb088adbbe1a7796d8a2983f07fab97ecdb2f9ff98ff6e4a8 |
import os
import logging
import stat
import collections
import uuid
import urlparse
from functools import partial
from typing import Any, Callable, Set, Text, Tuple, Union
import schema_salad.validate as validate
_logger = logging.getLogger("cwltool")
MapperEnt = collections.namedtuple("MapperEnt", ["resolved", "targ... | jeremiahsavage/cwltool | cwltool/pathmapper.py | Python | apache-2.0 | 8,169 | [
"VisIt"
] | 205728ec623f2353195dd6d428c5d59bc4bf9a38939194971eeeb9b42d135ebb |
# beam_search.py - progressive widening beam search
#
# Copyright 2016-2018 NetworkX developers.
"""
===========
Beam Search
===========
Beam search with dynamic beam width.
The progressive widening beam search repeatedly executes a beam search
with increasing beam width until the target node is found.
"""
import mat... | kenshay/ImageScript | ProgramData/SystemFiles/Python/share/doc/networkx-2.2/examples/algorithms/beam_search.py | Python | gpl-3.0 | 3,830 | [
"VisIt"
] | 6f3318cfa74336095408a8e121d66f92803f5ef38e2d6e9c53d0b20ccc51d478 |
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not us... | ptkool/spark | python/pyspark/ml/clustering.py | Python | apache-2.0 | 60,729 | [
"Gaussian"
] | f9b970df6a6a30656c81f679fe7666a996163090eb6f269027c97e4fa8aceff5 |
#!/usr/bin/env python3
#pylint: disable=missing-docstring
#* This file is part of the MOOSE framework
#* https://www.mooseframework.org
#*
#* All rights reserved, see COPYRIGHT for full restrictions
#* https://github.com/idaholab/moose/blob/master/COPYRIGHT
#*
#* Licensed under LGPL 2.1, please see LICENSE for details
... | nuclear-wizard/moose | python/chigger/tests/exodus/blocks/blocks.py | Python | lgpl-2.1 | 945 | [
"MOOSE",
"VTK"
] | 8e6dc58d94d37894441ad9f71877d2469d699c2d7f935c37b4566fd77a7de9ee |
"""
Module that parses global parameters from a configuration
file at first import, to make them available to the other
parts of the program.
"""
import ConfigParser
import os
import glob
import json
import datetime as dt
import numpy as np
# cPickle is faster than pickle but doesn't always import correctly.
try:
... | boland1992/seissuite_iran | build/lib/seissuite/ant/psconfig.py | Python | gpl-3.0 | 19,875 | [
"Gaussian"
] | 18cb4afb74782b87e1f6aa6f44d159f15c34bf6fca89e2f9896558a090a36acb |
# AvsP - an AviSynth editor
#
# Copyright 2012, 2013 the AvsPmod authors <https://github.com/avspmod/avspmod>
#
# 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 Licens... | AvsPmod/AvsPmod | global_vars.py | Python | gpl-2.0 | 1,359 | [
"VisIt"
] | 77b7a5c2c10598c6e3cc6d77b4cc99d6eea5d120b8e539c3cf3daab5edd5d731 |
"""
PySCeS - Python Simulator for Cellular Systems (http://pysces.sourceforge.net)
Copyright (C) 2004-2020 B.G. Olivier, J.M. Rohwer, J.-H.S Hofmeyr all rights reserved,
Brett G. Olivier (bgoli@users.sourceforge.net)
Triple-J Group for Molecular Cell Physiology
Stellenbosch University, South Africa.
Permission to us... | bgoli/pysces | pysces/PyscesScan.py | Python | bsd-3-clause | 20,294 | [
"PySCeS"
] | 4ac1a25207a42b554c112565540b4d98d02facb44467ad0619dd23371c3bd05a |
# ----------------------------------------------------------------------
# Numenta Platform for Intelligent Computing (NuPIC)
# Copyright (C) 2016, Numenta, Inc. Unless you have an agreement
# with Numenta, Inc., for a separate license for this software code, the
# following terms and conditions apply:
#
# This progra... | ywcui1990/nupic.research | projects/sdr_paper/sdr_paper_unions.py | Python | agpl-3.0 | 12,274 | [
"NEURON"
] | 41f3be41605e215ebe8590b05be21bdadce2e98bc04b3597c0e305b6454f48f0 |
""" Class that contains client access to the transformation DB handler. """
__RCSID__ = "$Id$"
from DIRAC import S_OK, gLogger
from DIRAC.Core.Base.Client import Client
from DIRAC.Core.Utilities.List ... | vmendez/DIRAC | TransformationSystem/Client/TransformationClient.py | Python | gpl-3.0 | 19,373 | [
"DIRAC"
] | 82fbdca73febfd75088292216a39979dc71130cfba74cc08e7a81258b454f68a |
from typing import List, Any
import stim
class ExternalStabilizer:
"""An input-to-output relationship enforced by a stabilizer circuit."""
def __init__(self, *, input: stim.PauliString, output: stim.PauliString):
self.input = input
self.output = output
@staticmethod
def from_dual(du... | quantumlib/Stim | glue/zx/stimzx/_external_stabilizer.py | Python | apache-2.0 | 3,343 | [
"Gaussian"
] | 468a40118d09eb974df5fda135a6e6f18650e11df2e0afab33821ae8906a62e3 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
What it does
============
This optional tool will put unsolvated node configurations (e.g. obtained by high-temperature presampling in vacuum) into equally sized solvent boxes.
All solvent boxes will be filled with the same number of solvent molecules. The node topol... | CMD-at-ZIB/ZIBMolPy | tools/zgf_solvate_nodes.py | Python | lgpl-3.0 | 7,226 | [
"Gromacs"
] | 5e69f393d7abd1b2f88ed518bba60a9e8a042c6b988438d881ffc296f2f4886d |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding: utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4
#
# 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)
#
# Released under t... | kain88-de/mdanalysis | package/MDAnalysis/topology/HoomdXMLParser.py | Python | gpl-2.0 | 5,182 | [
"HOOMD-blue",
"MDAnalysis"
] | f830209c3eecfcd51a35ea2d0789fb23ab39f84875caafb056c9378b81e6cb63 |
from __main__ import vtk, qt, ctk, slicer
import string
import numpy
import math
import operator
import collections
from functools import reduce
class MorphologyStatistics:
def __init__(self, labelNodeSpacing, matrixSA, matrixSACoordinates, matrixSAValues, allKeys):
self.morphologyStatistics = collections... | acil-bwh/SlicerCIP | Scripted/CIP_LesionModel/FeatureExtractionLib/MorphologyStatistics.py | Python | bsd-3-clause | 7,867 | [
"VTK"
] | eb31f14c153c549d8b01f5c8560852039ca9408df58b0dbf869b130d0fab560c |
"""
Unit tests for base DataProviders.
.. seealso:: galaxy.datatypes.dataproviders.base
"""
# currently because of dataproviders.dataset importing galaxy.model this doesn't work
#TODO: fix imports there after dist and retry
#TODO: fix off by ones in FilteredDataProvider counters
import imp
import os
import unittest
i... | mikel-egana-aranguren/SADI-Galaxy-Docker | galaxy-dist/test/unit/datatypes/dataproviders/test_line_dataproviders.py | Python | gpl-3.0 | 12,462 | [
"Galaxy"
] | fe617c812d2da296d342e4cee36e10045059173a01deb0b8971a923b0526d7b9 |
# Version: 0.10
"""
The Versioneer
==============
* like a rocketeer, but for versions!
* https://github.com/warner/python-versioneer
* Brian Warner
* License: Public Domain
* Compatible With: python2.6, 2.7, and 3.2, 3.3
[](https://tr... | dragondgold/OctoPrint | versioneer.py | Python | agpl-3.0 | 42,531 | [
"Brian"
] | 73c03de6f1aecb42147be0344cbea98982df0cf53292d5cf69a5bece31efdf23 |
from __future__ import division
from pybec.fit1D import gauss_peak_1D, parab_peak_1D, sigmoid,\
peakguess1D, sigguess, fit1D, check_1Dfit
from numpy import array, arange
from numpy.random import poisson
import matplotlib.pyplot as plt
plt.close('all')
rng = 200
X = arange(0, rng+1)... | kevincwright/quagmire | test_pybec/test_fit1D.py | Python | gpl-3.0 | 1,354 | [
"Gaussian"
] | 9e512439cb8a93b074f6a98918bb7d1d80ad33bdb1a84ed2dd9778da5bf47255 |
import os, pickle, random, time
from scipy.linalg import norm, eigh, inv, pinv, pinv2, pinvh
import numpy as np
from sklearn.gaussian_process import GaussianProcess
ttt = time.clock()
if not os.path.exists('qm7.pkl'): os.system('wget http://www.quantum-machine.org/data/qm7.pkl')
dataset = pickle.load(open('qm7.pkl','... | marcocaccin/MarcoGP | scikit-gp.py | Python | apache-2.0 | 2,114 | [
"Gaussian"
] | 101cf12eb5793a2eaa8dbd2330c710af70ee896efef5243d2afadf664b7c5386 |
"""
intro_3_02_example.py
First example code from Section 3.2 of "Introduction to SFC Models With Python."
Implements model SIM from Godley and Lavoie.
Copyright 2017 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... | brianr747/SFC_models | sfc_models/examples/scripts/intro_3_02_example.py | Python | apache-2.0 | 2,492 | [
"Brian"
] | 9024c7a0471c3fc95a1075538b1866badc85669d7c159a0f319fd73dbf29d15c |
"""
Acceptance tests for the Import and Export pages
"""
from nose.plugins.attrib import attr
from datetime import datetime
from abc import abstractmethod
from common.test.acceptance.tests.studio.base_studio_test import StudioLibraryTest, StudioCourseTest
from common.test.acceptance.pages.studio.import_export import ... | romain-li/edx-platform | common/test/acceptance/tests/studio/test_import_export.py | Python | agpl-3.0 | 17,465 | [
"VisIt"
] | 8ad9dd28b9f367419cca474ea579e321bfaeb5b28aef8b624bd8cf9435d8b9f1 |
#! /usr/bin/env python
# -*- coding: utf-8 -*-
#rvo.py
# Copyright 2015 Jonathan M. Skelton and Adam J. Jackson
#COMMENT: EoS data should be a CSV file with each row containing (V, E, p), and no header rows.
#COMMENT: We use VASP, so we assume V is in A^3, E is in eV, and p is in kbar.
#COMMENT: An example :-
# For... | WMD-Bath/dvxc | rvo.py | Python | gpl-3.0 | 14,340 | [
"VASP"
] | 2a67e4b10bcf1ae50c25ba477281eada8c2da9bde26e011267b4f5e1162cce55 |
# -*- coding: utf-8 -*-
from __future__ import absolute_import, division, print_function, unicode_literals
from six.moves import zip, range, map # NOQA
import numpy as np
import utool as ut
import ubelt as ub
import cv2
from vtool_ibeis import coverage_kpts
# TODO: integrate more
COVGRID_DEFAULT = ut.ParamInfoList('... | Erotemic/vtool | vtool_ibeis/coverage_grid.py | Python | apache-2.0 | 13,416 | [
"Gaussian"
] | f6bd576ee290273bacf71fee3e7953aa31e0b3f7e26469ecf02e6e207034a844 |
from logging import getLogger
logger = getLogger(__name__)
class DominatorTree(object):
def __init__(self):
self.nodes = []
self.edges = []
def add_node(self, n):
if n not in self.nodes:
self.nodes.append(n)
def add_edge(self, n1, n2):
edge = (n1, n2)
... | ktok07b6/polyphony | polyphony/compiler/dominator.py | Python | mit | 5,011 | [
"VisIt"
] | 07efdad63e16e289bb950ca22d3eda9c4e04c778102fe7f3b93f578c923b8269 |
# Copyright (C) 2012,2013
# Max Planck Institute for Polymer Research
# Copyright (C) 2008,2009,2010,2011
# Max-Planck-Institute for Polymer Research & Fraunhofer SCAI
#
# This file is part of ESPResSo++.
#
# ESPResSo++ is free software: you can redistribute it and/or modify
# it under the terms of t... | BackupTheBerlios/espressopp | src/integrator/LBInitPeriodicForce.py | Python | gpl-3.0 | 1,943 | [
"ESPResSo"
] | 191a5239939634b17e2c742d7ef379fc84c277963b06d81ba6e331df3bf2aaa0 |
from __future__ import print_function
import os
import sys
import glob
import argparse
import itertools
import collections
sys.path.append('/Users/loriab/linux/qcdb')
sys.path.append('/Users/loriab/linux/qcdb/databases')
import qcdb
from qcdb.psivarrosetta import useme2psivar, optclue2psivar
from qcdb.modelchems import... | loriab/qcdb | bin/reap-DB.py | Python | lgpl-3.0 | 90,226 | [
"CPMD"
] | 55097f5097b716aaca4de31b09d0ec0cdf508f2b6c20b587c894bcd5584b3b74 |
from __future__ import absolute_import
import shutil
from subprocess import call
import numpy
import pytest
from click.testing import CliRunner
from pathlib import Path
import datacube.scripts.cli_app
from datacube.compat import string_types
import imp
PROJECT_ROOT = Path(__file__).parents[1]
CONFIG_SAMPLES = PRO... | ceos-seo/Data_Cube_v2 | agdc-v2/integration_tests/test_end_to_end.py | Python | apache-2.0 | 21,264 | [
"NetCDF"
] | 5585ce7d8a9e78f8d6fcf7a1238837f8f3f14a26ec65ae49cdd75b1fa9824eb5 |
# -*- coding: utf-8 -*-
# system
import os
import socket
# graphics interface
import gtk
import pango
import cairo
import glib
try:
import Image
except:
from PIL import Image
# calculational help
import datetime
# self made modules
import thumbnailer
import checklist
import quick
from subprocess import *... | JYamihud/blender-organizer | py_data/modules/render_lists.py | Python | gpl-2.0 | 30,411 | [
"FLEUR"
] | 47f27837beeca9b533bb9c5f81a71b12576e8e109bd4cd2fc1bc00a6e84e7356 |
# -*- coding: utf-8 -*-
"""
Created on Wed Mar 9 16:05:59 2016
@author: dongyu
https://github.com/nasa/PyAMPR/blob/master/pyampr/google_earth_tools.py
https://ocefpaf.github.io/python4oceanographers/blog/2014/03/10/gearth/
https://github.com/hetland/octant/blob/master/octant/sandbox/googleearth.py
"""
from netCDF4 i... | UT-CWE/Hyospy | Hyospy_ensemble/lib/Probability_map.py | Python | mit | 11,874 | [
"NetCDF"
] | cf242929dac30d26ce157f5bdf435313b16e4be44ddf7484252c2477a8cb7f87 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.