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 |
|---|---|---|---|---|---|---|---|
# -*- coding: utf-8 -*-
# Copyright (c) 2006-2011, 2013-2014 LOGILAB S.A. (Paris, FRANCE) <contact@logilab.fr>
# Copyright (c) 2011-2014 Google, Inc.
# Copyright (c) 2012 Tim Hatch <tim@timhatch.com>
# Copyright (c) 2013-2017 Claudiu Popa <pcmanticore@gmail.com>
# Copyright (c) 2014 Brett Cannon <brett@python.org>
# Co... | AtomLinter/linter-pylama | bin/deps/pylint/checkers/exceptions.py | Python | mit | 17,545 | [
"VisIt"
] | b38ba53e0e929d3a0a6345957750fe0e55c12cb02610ecf6ae77bd2ad299b6ce |
"""
Definition of default parameters (and hence, standard parameter names) for
standard cell models.
Plain integrate-and-fire models:
IF_curr_exp
IF_curr_alpha
IF_cond_exp
IF_cond_alpha
Integrate-and-fire with adaptation:
IF_cond_exp_gsfa_grr
EIF_cond_alpha_isfa_ista
EIF_cond_exp_isfa_... | anupkdas-nus/global_synapses | pyNN-dispackgaes/standardmodels/cellannotated.py | Python | gpl-3.0 | 75,458 | [
"NEURON"
] | ce51c459ec45156b7afdebd7cc4351bdc5f8449722b63070ff879dea3a2229cb |
import sys
import pytest
from flask import current_app,url_for
from flask_wtf import Form
from wtforms import TextField
from faker import Faker
import arrow
import uuid
from sqlalchemy import and_,or_
from unifispot.modules.email.models import Emailconfig,Emailauth
from unifispot.modules.email.main import validate_em... | Spotipo/spotipo | tests/modules/email/test_main.py | Python | agpl-3.0 | 21,889 | [
"VisIt"
] | 656b5391fc1ea7a9c713352afd61d3484415652854e05f1603cc683166b82328 |
# -*- 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... | EliotBerriot/nomnom | config/urls.py | Python | bsd-3-clause | 1,276 | [
"VisIt"
] | b53df4900b23dcbe3683c8d661dfe9e02ea127b2cb8e959e7bb39cecab40b705 |
class DataPoint:
def __init__(self, dataValueBytes):
self._dataValueBytes = dataValueBytes
class PoorSignalLevelDataPoint(DataPoint):
def __init__(self, dataValueBytes):
DataPoint.__init__(self, dataValueBytes)
self.amountOfNoise = self._dataValueBytes[0];
def h... | gubertoli/hackrun-eeg | mindwave/MindwaveDataPoints.py | Python | gpl-2.0 | 3,852 | [
"ASE"
] | 8147b03a5b6edef8ffbbfd773130f1d25f79eec57cd867bf84c2a337a35a7d41 |
# constant objects
import cmd
import parsing
import re
import string
from cmd import Shortcut
gz_ext_re = re.compile(r"(\.?gz|\.bz2)$", re.I)
file_ext_re = re.compile(string.join([
"\.pdb$|\.pdb1$|\.ent$|\.mol$|\.p5m$|",
r"\.mmod$|\.mmd$|\.dat$|\.out$|\.mol2$|",
r"\.xplor$|\.pkl$|\.sdf$|\.pqr|",
r... | gratefulfrog/lib | python/pymol/constants.py | Python | gpl-2.0 | 9,542 | [
"Amber",
"ChemPy",
"Desmond",
"Gaussian",
"MOE",
"PyMOL",
"TINKER"
] | 4b27c0a3641de55309cc0483cb3ccdb9587bf1e24d7019d7f101c1cadec7e9d1 |
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=120 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# ------------------------------------------------------... | marmyshev/transitions | openlp/core/lib/htmlbuilder.py | Python | gpl-2.0 | 22,541 | [
"Brian"
] | ca075b210cc159c31cae6b4277fa15e82d85a7039ffb23803422ead157c1c818 |
# -*- coding: utf-8 -*-
# HORTON: Helpful Open-source Research TOol for N-fermion systems.
# Copyright (C) 2011-2017 The HORTON Development Team
#
# This file is part of HORTON.
#
# HORTON is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by th... | theochem/horton | horton/espfit/cost.py | Python | gpl-3.0 | 7,402 | [
"CRYSTAL"
] | 9d12348cbad65804f9a964ff606f9f4dd380728bc667b141c4c0b714068bc694 |
# -*- coding:Utf-8 -*-
#from numpy import *
from __future__ import print_function
"""
.. currentmodule:: pylayers.antprop.loss
.. autosummary::
:members:
"""
import doctest
import os
import glob
import doctest
import logging
import numpy as np
from scipy import io
import mayavi.mlab as mlab
import matplotlib.pyla... | dialounke/pylayers | pylayers/antprop/loss.py | Python | mit | 53,498 | [
"Mayavi"
] | 5a3c359b8f936084cc15d304cc84aac50058a5478939d3ab082cb2b305f430b2 |
#!/usr/bin/env python
# by teknohog, iki.fi
# Provides simple access to some of the bitcoind functions, with some
# extras like difficulty calculations for other miners/difficulties.
# Payment has extra warnings and confirmations to guard against dupes,
# which may easily happen on the command line. At the moment, t... | teknohog/bittools | scripts/coinfo.py | Python | gpl-3.0 | 40,204 | [
"DIRAC"
] | 65decc56c3a817a0e80a3a2c5a6df374e553ae6a39846512cedb78b42e424d6b |
########################################################################
# File : HttpStorageAccessHandler.py
# Author : A.T.
########################################################################
""" The HttpStorageAccessHandler is a http server request handler to provide a secure http
access to the DIRAC... | ic-hep/DIRAC | src/DIRAC/DataManagementSystem/private/HttpStorageAccessHandler.py | Python | gpl-3.0 | 2,770 | [
"DIRAC"
] | a216af6aa1a07070981c0fe82788f1805ec70db5e1fd5c8e73325c3f15b7c5ed |
# -*- coding: utf-8 -*-
#
#
# TheVirtualBrain-Scientific Package. This package holds all simulators, and
# analysers necessary to run brain-simulations. You can use it stand alone or
# in conjunction with TheVirtualBrain-Framework Package. See content of the
# documentation-folder for more details. See also http://ww... | rajul/tvb-library | tvb/simulator/demos/surface_deterministic_custom_local_connectivity.py | Python | gpl-2.0 | 4,818 | [
"Mayavi"
] | aa1c751ba07d9b9439708dcfb5f185193eaa9126311d93b20fd2a38c6acc4b21 |
# Subject models to explicit solvent simulation.
#
# John D. Chodera <choderaj@mskcc.org> - 17 Feb 2013
#
# PREREQUISITES
#
# * OpenMM
# http://simtk.org/home/openmm
#
# TODO
# * use ff99sb-ildn-star
# * trim all systems to have the same number of waters?
# PARAMETERS
import sys
from ast import literal_eval
# Proces... | choderalab/Ensembler2 | scripts/attic/determine-nwaters.py | Python | gpl-2.0 | 3,519 | [
"OpenMM"
] | b04ad9e419eed2f83f45d271b8df56a7501096f6d89b5d78749ae506a23136b8 |
##########################
#dr.mark.schultz@gmail.com
#github schultzm
#date 18/02/15
#requires python and biopython to run, can be installed by typing on the command line:
#'sudo pip install biopython'
##########################
#import the modules
from Bio import Entrez
import argparse
#set up the arguments
parser ... | mht85/MitoPhAST | V2.0/scripts/pull_genomes_as_genbank.py | Python | gpl-2.0 | 2,174 | [
"Biopython"
] | 9243fa079c77fce61007e720f028cbeecc251ae5cb15ff9b32ae7fe246fda49b |
#!/usr/bin/env python
import vtk
from vtk.test import Testing
from vtk.util.misc import vtkGetDataRoot
VTK_DATA_ROOT = vtkGetDataRoot()
# A script to test the stencil filter with a polydata stencil.
# Image pipeline
reader = vtk.vtkPNGReader()
reader.SetDataSpacing(0.8,0.8,1.5)
reader.SetDataOrigin(0.0,0.0,0.0)
reader... | HopeFOAM/HopeFOAM | ThirdParty-0.1/ParaView-5.0.1/VTK/Filters/Hybrid/Testing/Python/TestImageStencilWithPolydata.py | Python | gpl-3.0 | 2,268 | [
"VTK"
] | 3b341c0ffd4d2d3c0c40fea9f5d8cabc7571118ae0894f78b1e817fe8e4eaff8 |
debug = 0
netConfig = {
}
networkParams = {
"packetSize" : "2048B",
"link_bw" : "4GB/s",
"link_lat" : "40ns",
"input_latency" : "50ns",
"output_latency" : "50ns",
"flitSize" : "8B",
"buffer_size" : "14KB",
}
nicParams = {
"detailedCompute.name" : "thornhill.SingleThread",
"module" :... | minyee/sst-macro | python/emberDefaultParams.py | Python | bsd-3-clause | 2,076 | [
"Firefly"
] | 18b2dbbd8ec2942f7fa1362e23c5de2eadc427c5e44cff798d5b1ea6c3242f94 |
#
# Copyright (C) 2010-2018 The ESPResSo project
# Copyright (C) 2002,2003,2004,2005,2006,2007,2008,2009,2010
# Max-Planck-Institute for Polymer Research, Theory Group
#
# 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... | mkuron/espresso | doc/tutorials/02-charged_system/scripts/nacl_units_vis.py | Python | gpl-3.0 | 5,419 | [
"ESPResSo"
] | 2dbd4cbda32c6854297565c02e9e20d8a9ae1377abb1832936df864a20ec0551 |
# -*- coding: utf-8 -*-
"""
@namespace Area
Tools and events manipulation
Copyright 2007, NATE-LSI-EPUSP
Oficina is developed in Brazil at Escola Politécnica of
Universidade de São Paulo. NATE is part of LSI (Integrable
Systems Laboratory) and stands for Learning, Work and Entertainment
Research Group. Visit o... | native93/Sugar-paint-activity | Area.py | Python | gpl-2.0 | 68,020 | [
"FLEUR",
"VisIt"
] | c54054c96c71318f27cd10cd2d26412083cc4d96040543b841a0227f8002884c |
import numpy as np
from matplotlib import pyplot
from spm1d import rft1d
eps = np.finfo(float).eps #smallest float
#(0) Set parameters:
np.random.seed(0)
nResponses = 2000
nNodes = 101
FWHM = 10.0
interp = True
wrap = True
heights = [2.2, 2.4, 2.6, 2.8]
### generate data:... | 0todd0000/spm1d | spm1d/rft1d/examples/val_upx_0_gauss_cluster.py | Python | gpl-3.0 | 1,383 | [
"Gaussian"
] | f0cc908732fb726fd8cca80f2975f4876768946919a7c58ef9812951013cb293 |
# encoding: utf-8
"""sys.excepthook for IPython itself, leaves a detailed report on disk.
Authors:
* Fernando Perez
* Brian E. Granger
"""
#-----------------------------------------------------------------------------
# Copyright (C) 2001-2007 Fernando Perez. <fperez@colorado.edu>
# Copyright (C) 2008-2011 The IP... | Foxfanmedium/python_training | OnlineCoursera/mail_ru/Python_1/env/Lib/site-packages/IPython/core/crashhandler.py | Python | apache-2.0 | 8,196 | [
"Brian"
] | 1dd7c91f512f27e0465504acecde7a6ce6f5a123dc64cc37217b51cd4a93c00e |
import os, sys; sys.path.insert(0, os.path.join(os.path.dirname(__file__), "..", ".."))
from pattern.graph.commonsense import Commonsense
# A semantic network is a graph in which each node represents a concept
# (e.g., flower, red, rose) and each edge represents a relation between
# concepts, for example rose is-a fl... | krishna11888/ai | third_party/pattern/examples/06-graph/06-commonsense.py | Python | gpl-2.0 | 2,455 | [
"Octopus"
] | 9101c4e6e48a1a9cf8148282c3c76f7e276d49404c0e52de87055f62809e3fde |
# ----------
#
# In this exercise, you will update the perceptron class so that it can update
# its weights.
#
# Finish writing the update() method so that it updates the weights according
# to the perceptron update rule. Updates should be performed online, revising
# the weights after each data point.
#
# YOUR CODE WI... | ZhukovGreen/UMLND | Lectures/perceptron_1.py | Python | gpl-3.0 | 3,599 | [
"NEURON"
] | 1eccb6685b3e3015ab20b03673c7a6ad285479b760589945cca74bbde826fdc7 |
"""
GROMACS EEX I/O
"""
import pandas as pd
import os
import numpy as np
import eex
import logging
logger = logging.getLogger(__name__)
def read_gromacs_gro_file(dl, gro_folder, ffdir=None):
if ffdir is None:
if "GROMACS_DIR" in os.environ:
ffdir = os.environ["GROMACS_DIR"]
else:
... | dgasmith/EEX_scratch | eex/translators/gromacs/gromacs_read.py | Python | bsd-3-clause | 2,673 | [
"Gromacs"
] | 744bae9f8c647f584b62a87379ccc9d6ad2f673848fea7dbed86d202943e9e86 |
#################################################################################
## $HeadURL $
#################################################################################
#__RCSID__ = "$Id: $"
#
#'''
# Set the fixture needed to run this test.
#'''
#from DIRAC.ResourceStatusSystem.Service.test.Test_ResourceStat... | Sbalbp/DIRAC | ResourceStatusSystem/Service/test/Test_ResourceStatusHandler/Test_Unit.py | Python | gpl-3.0 | 814 | [
"DIRAC"
] | 75f13b7833afb6abf7b6a0915b7a33cda8ed946f51462a060c1488862782d70a |
"""
Controller for integration with the Biostar application
"""
from galaxy.web.base.controller import BaseUIController, url_for, error, web
from galaxy.util import biostar
class BiostarController( BaseUIController ):
"""
Provides integration with Biostar through external authentication, see: http://liondb.c... | mikel-egana-aranguren/SADI-Galaxy-Docker | galaxy-dist/lib/galaxy/webapps/galaxy/controllers/biostar.py | Python | gpl-3.0 | 4,385 | [
"Galaxy"
] | 946fb2dffb8f18e241315b5b483acbe66f5acbe0e7aba1b6e5e5b3e22a589bd3 |
""" Basic plugin system
"""
__author__ = "Brian Stidsen"
__version_info__ = (0, 1, 2)
__version__ = '.'.join(map(str, __version_info__))
__email__ = "brianstidsen@gmail.com"
#__version__ = "v0.1a"
#from . import _version as version
| bristi/blasy | blasy/__init__.py | Python | mit | 236 | [
"Brian"
] | c26238830934ccea89df0aefc37d4b9dd125e4bff1804e3c545c2986496c70ca |
# -*- coding: utf-8 -*-
# -*- mode: python -*-
"""
This is ARF, a python library for storing and accessing audio and ephys data in
HDF5 containers.
"""
from __future__ import division
from __future__ import unicode_literals
spec_version = "2.1"
__version__ = version = "2.6.2"
def version_info():
from h5py.versio... | melizalab/arf | arf.py | Python | gpl-2.0 | 14,872 | [
"VisIt"
] | 2d063ad916cb6777e3f8e904ad1f3fb31ab20d93a605a4d68115dc3b10533b72 |
__author__ = "HarshaRani"
__credits__ = ["Upi Lab"]
__license__ = "GPL3"
__version__ = "1.0.0"
__maintainer__ = "HarshaRani"
__email__ = "hrani@ncbs.res.in"
__status__ = "Development"
__updated__ = "Feb 22 2019"
#Change log:
#2019
#Feb 22: cross compartment molecules a... | BhallaLab/moose | moose-gui/plugins/kkit.py | Python | gpl-3.0 | 61,284 | [
"MOOSE"
] | 09d517fe63fcb53627066712dcfee17bcf291782a2999a6b4f862b5dbd546e11 |
from django.core.management.base import BaseCommand
from django.conf import settings
from django.template.loader import find_template
from django.template import TemplateDoesNotExist
import inspect
class Command(BaseCommand):
help = ('Validates the configuration settings against production '
'complia... | agiliq/django-production-ready | prodready/management/commands/is_it_ready.py | Python | bsd-3-clause | 5,464 | [
"VisIt"
] | 3b18159fb94c3b834de06a0d5ccfe30735d62e436e6f280c6bf7db37e99fb977 |
# gearbar_macro.py
# the macro to generate a gearbar
# created by charlyoleg on 2013/10/02
#
# (C) Copyright 2013 charlyoleg
#
# This file is part of the Cnc25D Python package.
#
# Cnc25D is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# th... | charlyoleg/Cnc25D | cnc25d/tests/gearbar_macro.py | Python | gpl-3.0 | 7,219 | [
"VisIt"
] | 4b8f7b437da351c8da8d1f5f57430313123ccccb3aa738862efb610105583fa3 |
import os
import sys
import nest
import time
import logging
import datetime
import numpy as np
import nest.topology as tp
import matplotlib.pyplot as plt
from collections import defaultdict
from parameters import *
from time import clock
from data import *
dictPosition_NeuronID = {} # position (1,0,1) : 6 neuron ID
... | research-team/NEUCOGAR | NEST/visual/V3/scripts/func.py | Python | gpl-2.0 | 9,232 | [
"NEURON"
] | 5e81eb4bc1bb56fdb1fe67bdd104f1c4024cf4ed25de2332cac9b6b91a8d9262 |
# Author: Samuel Genheden samuel.genheden@gmail.com
"""
Scripts used to convert the provided all-atom system input in Lammps format
to a hybrid description. The solute is retained as all-atom, whereas the
solvent molecules are made into CG.
The script creates the following files:
1) A PDB-file for the solute
2) A Lam... | SGenheden/Scripts | Projects/Sampl5/convert_aa.py | Python | mit | 7,344 | [
"LAMMPS"
] | f33ac47879d55f8a977a9cc1bb64cfa12d40358ccb60bb6f6b8d722c25fa1910 |
"""Test OpenBabel Python bindings
On Windows or Linux, you can run these tests at the commandline
in the build folder with:
"C:\Program Files\CMake 2.6\bin\ctest.exe" -C CTestTestfile.cmake
-R pybindtest -VV
The runtime directory is ${CMAKE_SRC_DIR}/test.
You could also "ch... | serval2412/openbabel | test/testbindings.py | Python | gpl-2.0 | 36,003 | [
"Pybel"
] | d0bdad5dfc28038f1664a4d5e35f696fcfb676c7b6169344b96d4207e9d6bd9b |
# Sample configuration file
# You need a Trello API key.
#
# Go here to generate an API key:
# https://trello.com/1/appKey/generate
# (the API secret is not needed).
TRELLO_API_KEY = "fill-in-as-explained-above"
# If you need trello-hipchat to access private boards,
# you need a OAuth token that authenticates an use... | LuminosoInsight/trello-hipchat | trello_hipchat_config_sample.py | Python | unlicense | 2,495 | [
"VisIt"
] | 34aa90a5844d3f7cec7c44009d673a42c751cdc845e9a9dd8c0854b2674d0576 |
########################################################################
# File: RequestExecutingAgent.py
# Author: Krzysztof.Ciba@NOSPAMgmail.com
# Date: 2013/03/12 15:36:47
########################################################################
""" :mod: RequestExecutingAgent
===========================
..... | fibbo/DIRAC | RequestManagementSystem/Agent/RequestExecutingAgent.py | Python | gpl-3.0 | 15,120 | [
"DIRAC"
] | 64d0dd47a0d5a7ea0015637009fcf02c59bfe7524e615a68e46a9101ca473f38 |
# 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... | fweik/espresso | src/python/object_in_fluid/oif_classes.py | Python | gpl-3.0 | 65,647 | [
"ESPResSo",
"VTK"
] | be5a9f75566aa339bb49a5f93c6d3c99be4bfaef0be95370e445914add5afeca |
"""
Terminal colors.
"""
import colored
AMBER = colored.fg('yellow')
BLUE = colored.fg('blue')
RED = colored.fg('red')
TEAL = colored.fg('spring_green_1')
def amber(text):
""" Shortcut for colored.stylize(). """
return colored.stylize(text, AMBER)
def blue(text):
""" Shortcut for colored.stylize(). """... | amancevice/dip | dip/colors.py | Python | mit | 560 | [
"Amber"
] | 24a336e1960d8f538bd624f226d78381d31b0e57d7ff98eb705b5c7c784b7728 |
# -*- coding: utf-8 -*-
"""
End-to-end tests for the LMS.
"""
import urllib
from datetime import datetime, timedelta
from textwrap import dedent
from unittest import skip
import pytz
from bok_choy.promise import EmptyPromise
from nose.plugins.attrib import attr
from common.test.acceptance.fixtures.course import Cours... | pepeportela/edx-platform | common/test/acceptance/tests/lms/test_lms.py | Python | agpl-3.0 | 56,416 | [
"VisIt"
] | 9a705f342a92f3f6a2f99366b4d5b7b3d52f21bff6a9d427b2a985ed674baba7 |
#!/usr/bin/python
from datetime import datetime, timedelta
import httplib2
import os
import sys
import pandas as pd
from pprint import pprint as pp
from apiclient.discovery import build
from apiclient.errors import HttpError
from oauth2client.client import flow_from_clientsecrets
from oauth2client.file import Storage... | facemelters/data-science | Atlas/test-youtube.py | Python | gpl-2.0 | 5,599 | [
"VisIt"
] | 0266f6a6902195b063441355bb1b8aefb0c72d2ccbc7120ccfbea79cb2049dc4 |
########################################################################
# $HeadURL$
# File : HttpStorageAccessHandler.py
# Author : A.T.
########################################################################
""" The HttpStorageAccessHandler is a http server request handler to provide a secure http
access ... | sposs/DIRAC | DataManagementSystem/private/HttpStorageAccessHandler.py | Python | gpl-3.0 | 2,414 | [
"DIRAC"
] | 2539c6bbf4b59fd88eab4425a2ff2f149d9ab53fc60cbdeab4a447b3e5d5d23b |
"""
Test functions for GEE
External comparisons are to R and Stata. The statmodels GEE
implementation should generally agree with the R GEE implementation
for the independence and exchangeable correlation structures. For
other correlation structures, the details of the correlation
estimation differ among implementat... | DonBeo/statsmodels | statsmodels/genmod/tests/test_gee.py | Python | bsd-3-clause | 51,001 | [
"Gaussian"
] | 0adb6e90880914dd0a3519cdc1a689a62bc04e32d9bed421bee09e0266b12beb |
import numpy
import neuroelectro.models as m
from neurotree.neuroelectro_integration import define_ephys_grandfathers
from neurotree.author_search import get_article_last_author, get_neurotree_author
from django.db.models import Count, Min, Q
from get_ephys_data_vals_all import filterNedm
import re
import numpy as np
... | lessc0de/neuroelectro_org | db_functions/data_qc_validation.py | Python | gpl-2.0 | 16,773 | [
"NEURON"
] | 34cae354b09640e7a74178e7222f04b9221e9efdb49a6c4af3a67927d758e7b4 |
"""
Approximate finite-dimensional samples from a GP.
"""
from __future__ import division
from __future__ import absolute_import
from __future__ import print_function
import numpy as np
from ...utils import linalg as la
from ...utils.misc import rstate
class FourierSample(object):
"""
Encapsulation of a co... | mwhoffman/reggie | reggie/models/gp/fourier.py | Python | bsd-2-clause | 1,946 | [
"Gaussian"
] | 51771ef717335d37c6d4b153f805af30f62a37c57f6bff2a3c18fb421f811a20 |
##############################################################################
# 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... | mfherbst/spack | var/spack/repos/builtin/packages/r-geneplotter/package.py | Python | lgpl-2.1 | 1,920 | [
"Bioconductor"
] | d22d5b3e23982287cb17a2b7efba484112bc657744691da3ea65fcd2d0e79fb6 |
#!/bin/env python
# -*- coding: utf-8 -*-
import cPickle
import os
import gzip
import matplotlib.pyplot as plt
import mnist_loader
import pylab
import numpy as np
#### Libraries
# Standard library
import gzip
import pylab
# Third-party libraries
import numpy as np
weights=[]
biases=[]
outs=[]
"""
network.py
~~~~~~... | ak4778/neural-network | nnetwork.py | Python | bsd-3-clause | 20,808 | [
"Gaussian",
"NEURON"
] | 4a8914da61cb3efb61bb6ef80366d08d8671153039b43a4497302dcc674bd9c5 |
#!/usr/bin/env python
# Copyright (c) 2012 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.
"""Moves C++ files to a new location, updating any include paths that point
to them, and re-ordering headers as needed. If multipl... | lihui7115/ChromiumGStreamerBackend | tools/git/move_source_file.py | Python | bsd-3-clause | 9,317 | [
"VisIt"
] | 088b3f3efe470516fdbcc6c2e537c1673ef6f83b7552763d6bb3e025400bede8 |
"""The config flow tests for the forked_daapd media player platform."""
import pytest
from homeassistant import data_entry_flow
from homeassistant.components.forked_daapd.const import (
CONF_LIBRESPOT_JAVA_PORT,
CONF_MAX_PLAYLISTS,
CONF_TTS_PAUSE_TIME,
CONF_TTS_VOLUME,
DOMAIN,
)
from homeassistant.... | nkgilley/home-assistant | tests/components/forked_daapd/test_config_flow.py | Python | apache-2.0 | 7,957 | [
"Firefly"
] | 526c36d010815798368b6e0a6aa0e3b452d87d079826cd3ec7fca17862f277b2 |
import logging
import urllib
from functools import partial
from django.conf import settings
from django.core.context_processors import csrf
from django.core.exceptions import PermissionDenied
from django.core.urlresolvers import reverse
from django.contrib.auth.models import User
from django.contrib.auth.decorators i... | TangXT/GreatCatMOOC | lms/djangoapps/courseware/views.py | Python | agpl-3.0 | 27,074 | [
"VisIt"
] | e92bb5053ef871cdeeb24796dec5e1736c1dc077c13d7737925cf0873ad2a1d0 |
##
## Script that showcases a flight to the Hyades, proper motions and
## a zoom out of the galaxy
##
from time import sleep
from gaia.cu9.ari.gaiaorbit.script import EventScriptingInterface
from gaia.cu9.ari.gaiaorbit.util import GlobalConf
gs = EventScriptingInterface.instance()
## PREPPING
gs.disableInput()
gs.... | vga101/gaiasky | assets/scripts/showcases/flight_hyades_mw.py | Python | mpl-2.0 | 3,574 | [
"Galaxy"
] | ef7c7ad00d24131192840972706ee90ff312702ac722fd2747ac6df14818a498 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
#******************************************************************************
#*
#* Copyright (C) 2015 Kiran Karra <kiran.karra@gmail.com>
#*
#* This program is free software: you can redistribute it and/or modify
#* it under the terms of the GNU General Public Licens... | kkarrancsu/copula-bayesian-networks | copularnd.py | Python | gpl-3.0 | 10,220 | [
"Gaussian"
] | 045f7709c8b276af46e955b9fd0c106098b3c810ded59fa8694ac4ad0007da8a |
#!/usr/bin/env python
import lsst.daf.persistence as dp
import lsst.afw.image as afw_image
import numpy
import matplotlib.pylab as plt
from calc_snr import make_invsnr_arr
def make_dataId(options):
dataId = {}
if options is None:
return None
for item in options:
key, value = item.split('='... | rbiswas4/Twinkles | bin/plot_point_mags.py | Python | mit | 3,422 | [
"VisIt"
] | 91f661deedc832cd4e80b9cfefa62ad403f81dcd1a0940dda69e55608ce7ed1e |
from __future__ import annotations
import pytest
import scitbx.matrix
from cctbx import crystal, sgtbx, uctbx
from cctbx.sgtbx import bravais_types
from dxtbx.model import Crystal
from dials.algorithms.indexing import symmetry
@pytest.mark.parametrize("space_group_symbol", bravais_types.acentric)
def test_Symmetry... | dials/dials | tests/algorithms/indexing/test_symmetry.py | Python | bsd-3-clause | 7,130 | [
"CRYSTAL"
] | 1a89308547b33bb3c7874673d51447c284ef3848033c8b36011ebbfda9c6074f |
# $Id$
#
# Copyright (C) 2003-2008 Greg Landrum and Rational Discovery LLC
# All Rights Reserved
#
from __future__ import print_function
from rdkit import RDConfig
from rdkit import DataStructs
from rdkit.DataStructs.TopNContainer import TopNContainer
import bisect
class GenericPicker(object):
_picks = None
def... | jandom/rdkit | rdkit/SimDivFilters/SimilarityPickers.py | Python | bsd-3-clause | 7,303 | [
"RDKit"
] | e5e43417219b7fcb0f94a5a8bf596eb54516fa6f839d98c10ea4072213da8ca3 |
# coding=utf-8
"""
Contains code for parsing a stadic json file.
StadicProject is the main class, generated once for every STADIC json file. It can contain one or more __StadicSpace__s
"""
import json
import os
def fixPaths(details, spaceDirectory, subDirectory=None, fileName=None):
"""
:param details:
... | sariths/stadicViewer | StadicViewer/gui/readStadicData/parseJson.py | Python | mit | 19,412 | [
"EPW"
] | 16ef89c9bd25385644390282495fffef4165cbea7ee18df63e2ef4c12dffdd12 |
#!/usr/bin/env python3
#* 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
#* https://www.gnu.org/licenses/lgp... | harterj/moose | scripts/tests/test_authors.py | Python | lgpl-2.1 | 1,841 | [
"MOOSE"
] | dff84c2e920532c1fbc2b3993847ecb3b55cedb1675e934ce4d3e910fc4bb28a |
# vim: tabstop=4 shiftwidth=4 softtabstop=4
# 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.a... | zestrada/nova-cs498cc | nova/tests/compute/test_resource_tracker.py | Python | apache-2.0 | 33,854 | [
"exciting"
] | ccc3c045b2357487d93ea092724a327018c3428d0de15b5de89685fb76124083 |
"""
Test Conn.I.ClientTypes
"""
from functools import partial
from servicetest import (EventPattern, assertEquals, assertLength,
assertContains, assertSameSets, call_async)
from gabbletest import exec_test, make_presence, sync_stream
import constants as cs
import ns
from caps_helper import (
presence_and_d... | Ziemin/telepathy-gabble | tests/twisted/client-types.py | Python | lgpl-2.1 | 9,873 | [
"VisIt"
] | 16ef73aafe98c6ae1c775848161a9c23e4dbf5c818eb5bf5227422bda513ca4e |
# coding: utf-8
# This notebook is the implementation of the [Welch Labs](http://www.welchlabs.com/) excellent video tutorials series (links inside the notebook below).
# To read the original code from the videos' author, visit this link: https://github.com/stephencwelch/Neural-Networks-Demystified
# In[1]:
import... | yassineAlouini/ml-experiments | deep-learning/simple-neural-networks/neural_networks_demystified.py | Python | mit | 8,040 | [
"VisIt"
] | fd6517f2841a4220ab01457ae84fcf42d98284ec76f8ea9599baf1eec1232769 |
"""
:mod:`topomult` -- Calculate topographic multiplier
===============================================================================
This module is called by the module
:term:`all_multipliers` to calculate the topographic multiplier for an input
tile for 8 directions and output as NetCDF format.
:References:
Y... | dynaryu/Wind_multipliers | topographic/topomult.py | Python | gpl-3.0 | 4,569 | [
"NetCDF"
] | 0e347752a26605e578110e0eb5a08745e961dfc33f68b57bb2208aa18966bef9 |
#!/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/rt/test/01_rt_tddft.py | Python | apache-2.0 | 1,459 | [
"PySCF"
] | 1950bc75b0a69b4f73fa48b40a3e916484116f663ed7d40a2de1e3a728a67188 |
# Include the Dropbox SDK libraries
import sys
sys.path.append('D:/Dropbox/dropbox-python-sdk-1.5.1')
from dropbox import client, rest, session
import webbrowser
'''
# Get your app key and secret from the Dropbox developer website
APP_KEY = '5pspell9t3vuqlb'
APP_SECRET = 'kc8isieyc13vdti'
# ACCESS_TYPE should be 'dr... | zaqwes8811/coordinator-tasks | projects/python-desk/shadow/dropbox_api/core/salv-api-test.py | Python | apache-2.0 | 1,390 | [
"VisIt"
] | 5efc9e9c46548198aa8b585e1ca5a5083d60e34daea9ce21a8ba1153d5d48c41 |
"""
This module contains the methods used by the Transcript class to retrieve information
from the database/dictionary provided during the pick operation.
"""
import operator
from itertools import groupby
from typing import List
from sqlalchemy import and_
from sqlalchemy.orm.session import sessionmaker
from ...parser... | lucventurini/mikado | Mikado/transcripts/transcript_methods/retrieval.py | Python | lgpl-3.0 | 26,849 | [
"BLAST"
] | b1358b61cda18db89643f6fbfa35a6631fe11bb587f95ec2b4057912d8b84408 |
#!/usr/bin/env python
# -*- coding: utf8 -*-
# *****************************************************************
# ** PTS -- Python Toolkit for working with SKIRT **
# ** © Astronomical Observatory, Ghent University **
# *****************************************************************
##... | SKIRT/PTS | modeling/misc/deprojector.py | Python | agpl-3.0 | 26,991 | [
"Galaxy"
] | 865160c9ed67b15b7759aefe76db8df2f3cfa081f681be5a26fcba35c1e165d1 |
#!/usr/bin/env pythonw
import tkinter as Tk
from tkinter import ttk
import matplotlib
import numpy as np
import numpy.ma as ma
import new_cmaps
from new_cnorms import PowerNormWithNeg
from Numba2DHist import Fast2DHist, Fast2DWeightedHist, vecLog10Norm
import matplotlib.colors as mcolors
import matplotlib.gridspec as g... | pcrumley/Iseult | src/phase_plots.py | Python | gpl-3.0 | 50,141 | [
"Gaussian"
] | 8bd12d2675f84323c9b38409417833ff255b57786f3f3d2fcac80686addd6b8e |
# -*- coding: utf-8 -*-
#
# Copyright © 2008 Red Hat, Inc.
# Copyright © 2008 Ricky Zhou
#
# This copyrighted material is made available to anyone wishing to use, modify,
# copy, or redistribute it subject to the terms and conditions of the GNU
# General Public License v.2. This program is distributed in the hope th... | ccoss/fas | fas/model/fasmodel.py | Python | gpl-2.0 | 22,980 | [
"VisIt"
] | 464a50753c47987178ed0c78da2ad38f49eee97154ca18af3d7c5eba4c1b2c96 |
#!/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/movielisthtml.py | Python | gpl-2.0 | 6,745 | [
"VisIt"
] | 0cca064c999145a510acd2440a92a9501ab046c7b388b434b4e973b18d0bcbb6 |
#
# Copyright (C) 2013 EMBL - European Bioinformatics Institute
#
# This program is free software: you can redistribute it
# and/or modify it under the terms of the GNU General
# Public License as published by the Free Software
# Foundation, either version 3 of the License, or (at your
# option) any later version.
#
# ... | sbotond/rlsim | tools/effest_src/parse.py | Python | gpl-3.0 | 8,466 | [
"HTSeq"
] | 8cccc29397c6b23d0dc72fae28f526ea364f402b8738d32811df824553a9b2ff |
"""Support for Ecobee binary sensors."""
from homeassistant.components.binary_sensor import (
DEVICE_CLASS_OCCUPANCY,
BinarySensorDevice,
)
from .const import _LOGGER, DOMAIN, ECOBEE_MODEL_TO_NAME, MANUFACTURER
async def async_setup_entry(hass, config_entry, async_add_entities):
"""Set up ecobee binary (... | Teagan42/home-assistant | homeassistant/components/ecobee/binary_sensor.py | Python | apache-2.0 | 3,966 | [
"VisIt"
] | 8e79838d59351d7fe352972d4ef5d50493fdaa67d55bae60badf475665a7ea5e |
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# --- BEGIN_HEADER ---
#
# vmrequest - request new virtual machine
# Copyright (C) 2003-2012 The MiG Project lead by Brian Vinter
#
# This file is part of MiG.
#
# MiG is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public Lice... | heromod/migrid | mig/cgi-bin/vmrequest.py | Python | gpl-2.0 | 1,078 | [
"Brian"
] | ec821e137370ad2679e3ccd4421cb28b6f96d5350d4b67ba8960e89785f48e03 |
########################################################################
# File: RequestExecutingAgent.py
# Author: Krzysztof.Ciba@NOSPAMgmail.com
# Date: 2013/03/12 15:36:47
########################################################################
""" :mod: RequestExecutingAgent
===========================
..... | Sbalbp/DIRAC | RequestManagementSystem/Agent/RequestExecutingAgent.py | Python | gpl-3.0 | 15,236 | [
"DIRAC"
] | baa536983fd5a81a63616b5f420e9548f654e4beeb362147bc9b074226414cd4 |
# coding: utf-8
# Copyright 2013 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 required by a... | ksh/gpitraining | tests/functional/tests.py | Python | apache-2.0 | 44,026 | [
"VisIt"
] | e921d3a38faeee2764ae39bdb7b66face913cecc9aaae488788769eae7874643 |
import unittest
from barista.coffee import *
class TestCoffee(unittest.TestCase):
def test_coffee(self):
names = [c.name for c in COFFEES]
self.assertTrue('Americano' in names)
self.assertTrue('Cappuccino' in names)
self.assertTrue('Espresso' in names)
self.assertTrue('Lat... | thk-emq-16/team1 | tests/coffee_test.py | Python | mit | 1,877 | [
"ESPResSo"
] | 996b77629b4454879cc007658a4a8d86e111eefb7f89f7f1f00a5aaf34d60eea |
# 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 RKeggrest(RPackage):
"""Client-side REST access to KEGG
A package that provides a ... | LLNL/spack | var/spack/repos/builtin/packages/r-keggrest/package.py | Python | lgpl-2.1 | 1,274 | [
"Bioconductor"
] | 03aa84cb1199f510e0f86c014bd4f8f0ab0d13c70be51a9a3c686ac115ad6ad1 |
try:
import elementtree.ElementTree as ET
except:
import xml.etree.ElementTree as ET
from xml.dom.minidom import parseString
#import time, types, re, sys
from PyQt4 import QtCore, QtGui
#from Queue import Queue
#import copy
class TreeItem:
def __init__(self, xmlElt, parent, row):
self.mParent = parent
... | patrickhartling/maestro | playpen/cluster_options/ClusterModel.py | Python | gpl-2.0 | 27,419 | [
"VisIt"
] | 7d36ed2b4c621a8ed6fc1dc12e512a96267c2bdabff60b32c3039834237b9792 |
#
# gPrime - A web-based genealogy program
#
# Copyright (C) 2008 Brian G. Matherly
# Copyright (C) 2008 Jerome Rapinat
# Copyright (C) 2008 Benny Malengier
#
# 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 Softw... | sam-m888/gprime | gprime/filters/rules/family/_hasgallery.py | Python | gpl-2.0 | 1,817 | [
"Brian"
] | 7c813a2c3e7d0ce2fbcc1eb8c5c1d6eeac73d5453926fd060e51303086cdb7e7 |
#! /usr/bin/env python
"""Unit tests for landlab.io.netcdf module."""
import os
import netCDF4 as nc
import numpy as np
import pytest
from numpy.testing import assert_array_equal
from landlab import RasterModelGrid
from landlab.io.netcdf import NotRasterGridError, write_netcdf
from landlab.io.netcdf.read import _get_... | cmshobe/landlab | tests/io/netcdf/test_write_netcdf.py | Python | mit | 10,005 | [
"NetCDF"
] | a1a3624476338e1bbdc17b35af273b21205b879737adf37d5c597690978f1704 |
###############################################################################
##
## Copyright (C) 2014-2015, New York University.
## Copyright (C) 2011-2014, NYU-Poly.
## Copyright (C) 2006-2011, University of Utah.
## All rights reserved.
## Contact: contact@vistrails.org
##
## This file is part of VisTrails.
##
## ... | hjanime/VisTrails | vistrails/packages/vtk/vtk_wrapper/class_tree.py | Python | bsd-3-clause | 10,018 | [
"VTK"
] | dd6aa24d18b40b6b3e77a14f8bbe90ea843cedee3343c2ecc9c28abdba032fe3 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
from __future__ import unicode_literals
import numpy as np
import unittest
import os
from pymatgen.analysis.structure_analyzer import VoronoiCoordFinder, \
solid_angle, contains_peroxide, RelaxationAnalyz... | sonium0/pymatgen | pymatgen/analysis/tests/test_structure_analyzer.py | Python | mit | 8,232 | [
"VASP",
"pymatgen"
] | dd8028319303b434206aa9f152f83f4785fb29bb4dad056b5012e4aa24895dcc |
# -*- coding: utf-8 -*-
#!/usr/bin/python
#
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2007 Thom Sturgill
# Copyright (C) 2007-2009 Brian G. Matherly
# Copyright (C) 2008-2011 Rob G. Healey <robhealey1@gmail.com>
# Copyright (C) 2008 Jason Simanek
# Copyright (C) 2010 Jakim Friant
... | Nick-Hall/gramps | gramps/plugins/webreport/calendar.py | Python | gpl-2.0 | 60,028 | [
"Brian"
] | 0a91176b9cd758f9e2fa40517536c5a91a31e3c7cf980a8bc0e9e08d59d45eab |
# -*- coding: utf-8 -*-
#
# test_vogels_sprekeler_synapse.py
#
# This file is part of NEST.
#
# Copyright (C) 2004 The NEST Initiative
#
# NEST is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 ... | weidel-p/nest-simulator | pynest/nest/tests/test_vogels_sprekeler_synapse.py | Python | gpl-2.0 | 8,504 | [
"NEURON"
] | 39b69b5cbefd38fccab72fad9306d44789c46d1991d96317b8fb2ab996a81847 |
# Copyright (C) 2010-2018 The ESPResSo project
#
# This file is part of ESPResSo.
#
# ESPResSo is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later v... | mkuron/espresso | samples/save_checkpoint.py | Python | gpl-3.0 | 2,301 | [
"ESPResSo"
] | 4e83d5e3786e14a8ab806cf67f5c7226312f4efb0d0daeb45e158769a2dd005d |
#
# Author: Travis Oliphant 2002-2011 with contributions from
# SciPy Developers 2004-2011
#
from __future__ import division, print_function, absolute_import
import warnings
from scipy.special import comb
from scipy.misc.doccer import inherit_docstring_from
from scipy import special
from scipy import optim... | jonycgn/scipy | scipy/stats/_continuous_distns.py | Python | bsd-3-clause | 119,039 | [
"Gaussian"
] | 243b17b7760c4c7a38afdb1c10104635456a3da234af702cfeb89bcd3b5cfe0d |
#!/usr/bin/env python3
# (C) 2016, Markus Wildi, wildi.markus@bluewin.ch
#
# 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, or (at your option)
# any later version.
#
# ... | zguangyu/rts2 | scripts/u_point/u_select.py | Python | gpl-2.0 | 7,976 | [
"VisIt"
] | eecdda239c454805721869485da17dc436c5cfda2974ac950c65c3d750f6ee23 |
"""
desispec.io.fibermap
====================
IO routines for fibermap.
"""
import os
import sys
import glob
import warnings
import time
from pkg_resources import resource_filename
import fitsio
import yaml
import numpy as np
from astropy.table import Table, Column, join
from astropy.io import fits
from desitarget.... | desihub/desispec | py/desispec/io/fibermap.py | Python | bsd-3-clause | 52,558 | [
"Galaxy"
] | 65e057990fa61606b9870e1b04a141773d879aacde8f2c079af02793cfe71c52 |
"""Build an index of top-level symbols from Python modules and packages."""
import ast
import json
import logging
import os
import re
import sys
from contextlib import contextmanager
from distutils import sysconfig
from importmagic.util import get_cache_dir, parse_ast
LIB_LOCATIONS = sorted(set((
(sysconfig.get... | alecthomas/importmagic | importmagic/index.py | Python | bsd-2-clause | 15,659 | [
"VisIt"
] | a116c908f49d7070e13f4f21d3a15aedfeb7f84ab8caa4931f9988d7a768de1b |
# Licensed under a 3-clause BSD style license - see LICENSE.rst
"""
Tests that relate to evaluating models with quantity parameters
"""
import numpy as np
import pytest
from numpy.testing import assert_allclose
from astropy.modeling.core import Model
from astropy.modeling.models import Gaussian1D, Shift, Scale, Pi... | MSeifert04/astropy | astropy/modeling/tests/test_quantities_evaluation.py | Python | bsd-3-clause | 13,815 | [
"Gaussian"
] | beae73c088bcaa3c50c40fd926c4d683d7b5da8bc051b249febaab8b001b9fa3 |
# -*- coding: utf-8 -*-
import string
import random
import time
import urllib.request
import urllib.parse
import hmac
import hashlib
import base64
import json
def random_chr(len):
return ''.join(random.choice(string.ascii_letters) for x in range(len))
class Twitter:
oauth_token = {}
apik... | RollMan/Hydra | util.py | Python | mit | 6,470 | [
"VisIt"
] | 14ccfcb2ca6bd25f4dc9a6cf88b802e3e828245f831416d8e9d82269da6cd088 |
import pytest
from stix2 import exceptions, parse
from stix2.v21 import (
TLP_AMBER, TLP_GREEN, TLP_RED, TLP_WHITE, MarkingDefinition, TLPMarking,
)
def test_bad_id_marking_tlp_white():
with pytest.raises(exceptions.TLPMarkingDefinitionError):
MarkingDefinition(
id='marking-definition--4... | oasis-open/cti-python-stix2 | stix2/test/v21/test_marking_definition.py | Python | bsd-3-clause | 5,432 | [
"Amber"
] | 099126a443822ff6c975e347ba17019e9827c5c52bcfea089a874e86eecdac6d |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
from __future__ import division, unicode_literals
"""
This module defines the abstract base classes for battery-related classes.
Regardless of the kind of electrode, conversion or insertion, there are many
com... | migueldiascosta/pymatgen | pymatgen/apps/battery/battery_abc.py | Python | mit | 12,255 | [
"pymatgen"
] | c988fc501408a0ab44b4d114b4b9debf3c36b1f23756e7923576106ed533a525 |
"""Implements a Gaussian mixture model, in which parameters are fit using
gradient descent. This example runs on 2-dimensional data, but the model
works on arbitrarily-high dimension."""
from __future__ import absolute_import
from __future__ import print_function
import matplotlib.pyplot as plt
import autograd... | HIPS/autograd | examples/gmm.py | Python | mit | 3,065 | [
"Gaussian"
] | 71f45c02408d6020b8e7bd2b810f5fe836def3f5c81b8ac67744fb14af50ae00 |
#!/usr/bin/env python
##
## Biskit, a toolkit for the manipulation of macromolecular structures
## Copyright (C) 2004-2018 Raik Gruenberg & Johan Leckner
##
## This program is free software; you can redistribute it and/or
## modify it under the terms of the GNU General Public License as
## published by the Free Softwar... | graik/biskit | archive_biskit2/scripts/Dock/contacter.py | Python | gpl-3.0 | 10,749 | [
"FoldX"
] | 492b60e13643e207caac6a138659d9704ae58824f3b0ad0077e2841f7ce8d950 |
# -*- coding: utf-8 -*-
# vi:si:et:sw=4:sts=4:ts=4
##
## Copyright (C) 2010 Async Open Source <http://www.async.com.br>
## All rights reserved
##
## 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 Foundati... | andrebellafronte/stoq | stoqlib/domain/test/test_event.py | Python | gpl-2.0 | 1,432 | [
"VisIt"
] | fc8f41ccee433d6989eb3bc9c1097136c2e7c5bdcd877c1a7ff97aa2ff71bdc8 |
import random
from datetime import *
import dateutil.parser
import logging
import dblog
class historian( ):
"""
Manage searching / fetching of the url/browser history database
"""
# class consts
MAX_SEED_RESULTS = 100
SUB_SEED_RESULTS = 50
DAY_FACTOR = 0.75
HHR_FACTOR = 1.25
# se... | m-kal/DirtyBoots | src/historian.py | Python | gpl-3.0 | 9,040 | [
"VisIt"
] | eee29b208287ee02fbb59580bffa540750f69f82e9c24ad66699b9d410ddb7a3 |
# -*- coding: utf-8 -*-
""" The aim of this script will be to fit 1d gaussians or von Mises curves to
the beta parameter tuning curves. This is to get an idea of the tuning spread.
Not completed.
"""
# Part of py_pRF_motion library
# Copyright (C) 2016 Marian Schneider
#
# This program is free software: you can r... | MSchnei/py_pRF_motion | pyprf_feature/analysis/old/pRF_fitBetaCurve.py | Python | gpl-3.0 | 3,281 | [
"Gaussian"
] | 7903fb797897ddd5343de9e4d449b341d91cf4468dcbf882d8d92f253091ed2a |
import galsim
import os
class COSMOSChromaticCatalog(galsim.scene.COSMOSCatalog):
'''
Modified COSMOSCatalog class to allow chromatic objects when using configs.
'''
_req_params = {}
_opt_params = { 'file_name' : str, 'sample' : str, 'dir' : str,
'preload' : bool, 'use_real' : b... | sweverett/Balrog-GalSim | balrog/scene_chromatic.py | Python | mit | 11,518 | [
"Galaxy"
] | 0affff9c35715e8f77861b6cd4d4807112ffcbafe9caeaa3abb61f25cd17b73d |
#!/usr/bin/env python
#
# @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 redistri... | lothian/psi4 | psi4/share/psi4/fsapt/fsaptdiff.py | Python | lgpl-3.0 | 4,193 | [
"Psi4"
] | 4a1c823732b1b3954af0471a536c212801f97e9e718805d3d42d91fedd5e0d5e |
"""
Bent Plume Model
================
Simulate a buoyant plume in crossflowing ambient conditions
This module defines the classes, methods, and functions necessary to simulate
the buoyant plume behavior in crossflowing ambient conditions, where the
intrusion layer is not expected to interact with the rising stage of ... | socolofs/tamoc | tamoc/bent_plume_model.py | Python | mit | 70,355 | [
"NetCDF"
] | 74a988bc9fc6ca19184dba680785d1746c2ef609383d664cbc141188b188f0c0 |
import os
import numpy as np
from astropy.cosmology import FlatLambdaCDM
from astropy.table import Table, vstack
from . import get_data_home
# We store the data in two parts to comply with GitHub 100Mb file size limit
DATA_URL1 = ("https://github.com/astroML/astroML-data/raw/main/datasets/"
"SDSSspecgal... | astroML/astroML | astroML/datasets/sdss_specgals.py | Python | bsd-2-clause | 7,221 | [
"Galaxy"
] | fd646b11ec5d5c6b4d84d127d6d3b6c64015eff507ee9223928bfe3f8a3eacbe |
#pylint: disable=W0403,C0103,R0901,R0904,R0913,C0302
from __future__ import (absolute_import, division, print_function)
from six.moves import range
import numpy
import sys
from HFIR_4Circle_Reduction import fourcircle_utility
from HFIR_4Circle_Reduction import guiutility
import HFIR_4Circle_Reduction.NTableWidget as t... | ScreamingUdder/mantid | scripts/HFIR_4Circle_Reduction/hfctables.py | Python | gpl-3.0 | 55,708 | [
"Gaussian"
] | cbda286dc277098cc8422076d5952e9ddf522bc594e313aaf72baef34750e4a7 |
##############################################################################
# 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... | wscullin/spack | var/spack/repos/builtin/packages/eccodes/package.py | Python | lgpl-2.1 | 3,216 | [
"NetCDF"
] | 2de1358eec04e7f27a84e996e2ffa0499e25ead2f955c0000a68022f9625c2ab |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.