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 |
|---|---|---|---|---|---|---|---|
# Copyright 2018 The TensorFlow Probability Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law o... | tensorflow/probability | tensorflow_probability/examples/disentangled_vae.py | Python | apache-2.0 | 50,234 | [
"Gaussian"
] | 2c1c8f6493fcc0130f85b4d8816cae6c107690c8716fa4b269949dc111826db4 |
# Copyright (c) 2015 Howard Hughes Medical Institute.
# All rights reserved.
# Use is subject to Janelia Farm Research Campus Software Copyright 1.1 license terms.
# http://license.janelia.org/license/jfrc_copyright_1_1.html
"""
This script creates a cycle of connected neurons.
"""
# Create 5 neurons
neuron1 = n... | JaneliaSciComp/Neuroptikon | Source/Scripts/NeuronNeuronConnections.py | Python | bsd-3-clause | 1,262 | [
"NEURON"
] | 18fa1d9357744a51213c0ea7fe9097cf41b1b7819aeb35eae442806e07a1c5a8 |
#!/usr/bin/python
import os
os.path.dirname(os.path.abspath(__file__))
import sys
import numpy
data = "X_train.2.csv"
if(len(sys.argv) >= 2):
data = sys.argv[1]
print(data)
def printMatrixShape(name, M):
print(name + ": " + str(numpy.shape(M)) + " (rows,columns)")
def I(n):
return numpy.matrix(nu... | xunilrj/sandbox | courses/course-edx-datamining/hw3_clustering.py | Python | apache-2.0 | 6,429 | [
"Gaussian"
] | 912d9de477e00a65a45e241e9f146020cb51e0f94bfc2ed76799a816835d9997 |
from scipy.stats import gaussian_kde
import numpy as np
def zFPKM(log_fpkm, resolution=100):
"""
Should we consider a gene "expressed" or not?
Implements algorithm from Hart et al 2013 (DOI:10.1186/1471-2164-14-778).
In that paper, using human data they conclude that zFPKM < -3 is
a reasonable cut... | lcdb/lcdblib | lcdblib/expression/expression_utils.py | Python | mit | 1,285 | [
"Gaussian"
] | 2d994cba415b01e7485da1aafd923adfa81372cedbb10c7f9b06d604446d9212 |
"""Classes for managing neurons."""
import math
import random
def sigmoid(x):
return 1 / (1 + math.e ** -x)
class InputNeuron:
"""InputNeuron."""
def __init__(self):
"""Create new InputNeuron."""
self.output = 0
return
def process(self):
"""Process this input."""
... | stevepryde/spnaughts | bots/nbot1/neurons.py | Python | gpl-3.0 | 2,673 | [
"NEURON"
] | 00787787b1a1c44d2cd471ef1418a039732ff8be0b40939000983fa346f63c94 |
#!/usr/bin/env python3
# -*-coding:Utf-8 -*
"""Script to plot MhaloPeak found with different scripts"""
import numpy as np
import matplotlib.pyplot as plt
import sys
from scipy.interpolate import InterpolatedUnivariateSpline
"""Load different MhaloPeak values"""
# MhaloTinker = np.loadtxt("../Plots/MhPeak/Tinker08_... | Gorbagzog/StageIAP | Plot_MhaloPeak.py | Python | gpl-3.0 | 17,134 | [
"TINKER"
] | 9b494ff3d2c1986a9efb45023e75cfb9739a3b61ee9b1c185c0ed52c11d4e5ca |
../../../../../../../share/pyshared/orca/scripts/toolkits/J2SE-access-bridge/formatting.py | Alberto-Beralix/Beralix | i386-squashfs-root/usr/lib/python2.7/dist-packages/orca/scripts/toolkits/J2SE-access-bridge/formatting.py | Python | gpl-3.0 | 90 | [
"ORCA"
] | c8df1e646f94d56eda50abafc9caec61149138a7a4b0ab72209803e8b47808b7 |
"""
Views for the verification flow
"""
import datetime
import decimal
import json
import logging
from collections import namedtuple
from pytz import UTC
from ipware.ip import get_ip
from django.conf import settings
from django.contrib.auth.decorators import login_required
from django.core.mail import send_mail
from ... | shubhdev/openedx | lms/djangoapps/verify_student/views.py | Python | agpl-3.0 | 51,034 | [
"VisIt"
] | 6e22df608fa25fe358f4129b5d33d060a2aa3a0f5b706d9d323f7cc8ad4f4d13 |
########################################################################
# $HeadURL$
########################################################################
__RCSID__ = "$Id$"
import types
from DIRAC.ConfigurationSystem.private.Modificator import Modificator
from DIRAC.Core.DISET.RPCClient import RPCClient
from DIRAC.... | sposs/DIRAC | ConfigurationSystem/Client/CSAPI.py | Python | gpl-3.0 | 26,993 | [
"DIRAC"
] | 238a3a41529be849428ac874ba9df4b11303f8235365c6f9e719d0ec8a9b7544 |
# -*- coding: utf-8 -*-
import ast
import base64
import csv
import glob
import itertools
import logging
import operator
import datetime
import hashlib
import os
import re
import simplejson
import time
import urllib
import urllib2
import urlparse
import xmlrpclib
import zlib
from xml.etree import ElementTree
from cStri... | aricchen/openHR | openerp/addons/web/controllers/main.py | Python | agpl-3.0 | 68,469 | [
"VisIt"
] | a5e9e295811df5fa622273b93a2941cf7edb1655f97638cbd1596388d5621edb |
#!/usr/bin/env python
"""
@package coverage_model.test.plexamples
@file coverage_model/test/plexamples.py
@author James Case
@brief Exemplar functions for creation and manipulation of the persistence layer between Coverages (memory) and HDF5 (disk)
"""
from pyon.public import log
from netCDF4 import Dataset
from cove... | ooici/coverage-model | coverage_model/test/plexamples.py | Python | bsd-2-clause | 26,978 | [
"NetCDF"
] | f89db31fb0dc6cde7b98528e46a407f3309486a88551cdc98c7a62f4269d2aac |
#! /usr/bin/env python
# -*- coding: utf-8 -*-
#======================================================================
#
# ccinit.py
#
# 初始化服务
#
#======================================================================
import sys, time, struct, os, subprocess
try:
import cclib # 如果使用 Python则正常使用 cclib
C... | skywind3000/cannon | cannon/lib/ccinit.py | Python | apache-2.0 | 8,427 | [
"cclib"
] | 4a90446af35ea66ce7fc24608974751a0957efb79fded8d845458ad6f1f8a20b |
# Copyright (C) 2010 CAMd
# Copyright (C) 2010 Argonne National Laboratory
# Please see the accompanying LICENSE file for further information.
import numpy as np
from gpaw.mpi import SerialCommunicator, serial_comm
from gpaw.matrix_descriptor import MatrixDescriptor, \
BandMatrixDescriptor, \
BlacsBandMatrix... | robwarm/gpaw-symm | gpaw/kohnsham_layouts.py | Python | gpl-3.0 | 26,319 | [
"GPAW"
] | 92c0650b012a11e5a744b78d342a308af148add640823e6a3b50017040514ff6 |
"""
cclib (http://cclib.sf.net) is (c) 2006, the cclib development team
and licensed under the LGPL (http://www.gnu.org/copyleft/lgpl.html).
"""
__revision__ = "$Revision: 742 $"
import copy
import numpy
try:
from PyQuante.CGBF import CGBF
module_pyq = True
except:
module_pyq = False
try:
from pyvt... | faribas/RMG-Java | source/cclib/method/volume.py | Python | mit | 9,507 | [
"Gaussian",
"VTK",
"cclib"
] | b90975c2a96776ce2528d4906fa0f9da452db8856e60787655ff533d8a9e00ff |
from __future__ import absolute_import
#######################################################################
#
#
# Volume Text Renderer for Dreambox/Enigma-2
# Coded by Vali (c)2010
# Support: www.dreambox-tools.info
#
#
# This plugin is licensed under the Creative Commons
# Attribution-NonCommercial-Shar... | atvcaptain/enigma2 | lib/python/Components/Renderer/VolumeText.py | Python | gpl-2.0 | 1,613 | [
"VisIt"
] | 0884b1788fe432559bea902706e516224add6b1384e3a8378bba7d855749fe66 |
# -*- coding: utf-8 -*-
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or... | googleads/google-ads-python | google/ads/googleads/v8/resources/types/remarketing_action.py | Python | apache-2.0 | 2,159 | [
"VisIt"
] | 0517634aa5ff08bf9dfc74c4f38fa1bea0f83e223bda439cf1e46c2ebfeb1f47 |
'''canny.py - Canny Edge detector
Reference: Canny, J., A Computational Approach To Edge Detection, IEEE Trans.
Pattern Analysis and Machine Intelligence, 8:679-714, 1986
Originally part of CellProfiler, code licensed under both GPL and BSD licenses.
Website: http://www.cellprofiler.org
Copyright (c) 2003-2009 Ma... | emmanuelle/scikits.image | skimage/filter/_canny.py | Python | bsd-3-clause | 10,091 | [
"Gaussian"
] | ddb8f103aec5d020e8c3f27826a05609837e79ef9529478f7bc9473cd8847f0a |
# ============================================================================
#
# Copyright (C) 2007-2012 Conceptive Engineering bvba. All rights reserved.
# www.conceptive.be / project-camelot@conceptive.be
#
# This file is part of the Camelot Library.
#
# This file may be used under the terms of the GNU General... | jeroendierckx/Camelot | camelot/view/controls/editors/textlineeditor.py | Python | gpl-2.0 | 2,704 | [
"VisIt"
] | ad6a4ecaa3480292d47e15afbee0b9bf4e5d48c740e39bcbb503ad86ab25c2fa |
# emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*-
# vi: set ft=python sts=4 ts=4 sw=4 et:
import numpy as np
from scipy import ndimage as nd
from skimage import feature as skft
from scipy.spatial import distance
from nibabel.affines import apply_affine
def mesh_3d_grid(x, y, z):
"""Create ... | sealhuang/FreeROI | froi/algorithm/imtool.py | Python | bsd-3-clause | 8,010 | [
"Gaussian"
] | 3deed7413ba6c55504618fd9b858aa24b82c09761023c8731bba11f69ea2aadd |
#!/usr/bin/env python
# File: plot_icd_vs_mass.py
# Created on: Mon 12 Mar 2012 11:50:09 AM CDT
# Last Change: Mon Oct 29 11:08:34 2012
# Purpose of script: <+INSERT+>
# Author: Steven Boada
import pylab as pyl
from mk_galaxy_struc import mk_galaxy_struc
def plot_icd_vs_mass():
galaxies = mk_galaxy_struc()
#... | boada/ICD | sandbox/legacy_plot_code/plot_icd_vs_mass_vs_GM20.py | Python | mit | 2,296 | [
"Galaxy"
] | 315d4a26e20abbc0146932e71fb200b350b7a7477df20056aa217457fcb97333 |
from pyeels.crystal import Crystal
from pyeels.band import Band
import matplotlib.pyplot as plt
import spglib as spg
import pythtb as tb
import numpy as np
class ParabolicBand:
""" Parabolic band class constructed for simple simulations """
_HBAR_C = 1973 #eV AA
_M_E = .511e6 #eV/c^2
def __init__... | sindrerb/VecDiSCS | eels/pyeels/parabolicband.py | Python | gpl-3.0 | 6,017 | [
"CRYSTAL"
] | aba2cd9bc7af57577399a3a5abdbb86ac20eba6af767ccc644f5e32442d57041 |
from filtering.anisotropic import *
from rivuletpy.utils.io import *
import matplotlib.pyplot as plt
from scipy import io as sio
try:
from skimage import filters
except ImportError:
from skimage import filter as filters
# plot the gaussian kernel
nsig = 5
nmu = 5
kerlen = 101
kr = (kerlen - 1) / 2
X, Y, Z =... | RivuletStudio/rivuletpy | tests/testbg.py | Python | bsd-3-clause | 1,287 | [
"Gaussian"
] | 1c8695b636c935412951dc121e324e353f5f3f98aa57a811e562a0fa88a425fa |
#! /usr/bin/env python
from youtubeAuthenticate import *
# Default Variables
DEFAULT_VIDEO_CATEGORY = 28
DEFAULT_THUMBNAIL = "thumbnail.png"
DEFAULT_TAGS = """{}, FIRST, omgrobots, FRC, FIRST Robotics Competition, robots, Robotics, FIRST STEAMworks"""
QUAL = "Qualification Match {}"
QUARTER = "Quarterfinal Match {}"
... | akilan98/FRC-YouTube-Uploader | consts.py | Python | gpl-3.0 | 1,966 | [
"VisIt"
] | d3717a12ea1a43c3a09583c87bcbaba4d30c952d3d54f7b743456cef1bc12da2 |
from collections import OrderedDict
from typing import ClassVar, Dict, Iterator, Optional
from lhc.binf.genomic_coordinate import GenomicInterval
from lhc.binf.variant import Variant
from lhc.io import open_file
class VariantFile:
REGISTERED_EXTENSIONS = {}
REGISTERED_FORMATS = {} # type: Dict[str, ClassVar... | childsish/lhc-python | lhc/io/variant/variant_file.py | Python | gpl-2.0 | 3,409 | [
"pysam"
] | 0f6d07321a71b66ebfc47241f65459843ec52e0ed357609df557505ecf93f0be |
from paraview import servermanager
from paraview.servermanager import CreateProxy
def CreateRepresentation(aProxy, view, **extraArgs):
"""Creates a representation for the proxy and adds it to the render module.
XXX Special workaround to avoid segfault on exit as as seen in
http://www.paraview.org/Bug/vie... | simphony/simphony-paraview | simphony_paraview/core/fixes.py | Python | bsd-2-clause | 1,746 | [
"ParaView"
] | c159020787a071aefc2be8e04174fb889bacda1708d730c391828c6fd9c28db2 |
import os
from os.path import dirname, join
import h5py
from bokeh.io import curdoc
from bokeh.layouts import row, widgetbox
from bokeh.models import ColumnDataSource
from bokeh.models.widgets import Select
from bokeh.plotting import figure
app_dir = dirname(__file__)
if 'demo_data.hdf5' not in os.listdir(app_dir):... | mindriot101/bokeh | examples/app/simple_hdf5/main.py | Python | bsd-3-clause | 1,266 | [
"Gaussian"
] | 6959975c032cad5358bb9634606d01185d00f06f3d457d6a4885821d3fbebfb5 |
#!/usr/bin/env python
# ui.py
#
# Copyright (C) 2014 Kano Computing Ltd.
# License: http://www.gnu.org/licenses/gpl-2.0.txt GNU General Public License v2
#
#
# Kano Burner UI back-end
#
# The UI base class handles all the PyQt front-end and uses a VerticalContainer
# as a layout manager.
#
# The application's window c... | KanoComputing/kano-burners | src/common/ui.py | Python | gpl-2.0 | 7,528 | [
"VisIt"
] | 919390baafce85f6f32b24b42f323d25a6994a37d2d8b6eb0cf1aafeeda24ca7 |
# coding: utf-8
import numpy as np
from .. import img_as_float
from ..restoration._denoise_cy import _denoise_bilateral, _denoise_tv_bregman
from .._shared.utils import _mode_deprecations
def denoise_bilateral(image, win_size=5, sigma_range=None, sigma_spatial=1,
bins=10000, mode='constant', cva... | WarrenWeckesser/scikits-image | skimage/restoration/_denoise.py | Python | bsd-3-clause | 11,767 | [
"Gaussian"
] | 050ac545c290221ab8c108d83df6831cccad5eefe7cdc56b28a8a41c72d61b97 |
# Copyright 2010 CAMd
# (see accompanying license files for details).
from optparse import OptionParser
import numpy as np
from ase.lattice.surface import fcc111, hcp0001, bcc110, bcc100, diamond111, \
add_adsorbate
from ase.structure import estimate_lattice_constant, molecule
from ase.data import reference_sta... | askhl/ase | ase/utils/adsorb.py | Python | gpl-2.0 | 6,469 | [
"ASE",
"CRYSTAL"
] | 8918b1d5cbe19972322ca01cbceee6c07cab3a7b7bf10e5aff627cbaef978f84 |
from setuptools import setup, find_packages
import sys, os, glob
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
version = '0.9.14'
if sys.version_info < (2,7):
print('SDST requires python 2.7 or higher')
exit(1)
setup(name='SDST',
version=version,
descrip... | seandavi/SDST | setup.py | Python | mit | 1,052 | [
"pysam"
] | 1d0b5dc2017934c617fc27758b11fc962ea4be61d2f4415f38f35b9dd2f26dd3 |
# -*- coding: utf-8 -*-
"""
Created on Mon Apr 30 10:29:42 2012
@author: Muenker_2
"""
#
# Copyright (c) 2011 Christopher Felton, Christian Münker
#
# This program 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 F... | honahursey/pyFDA | pyfda/pyfda_lib.py | Python | apache-2.0 | 35,844 | [
"DIRAC"
] | a5d06704a1f0b23761b04363c7cf7a6f0cd7fa10401d000a382058bf496267fe |
"""
Interpies - a libray for the interpretation of gravity and magnetic data.
@author: Joseph Barraud
Geophysics Labs, 2018
"""
__version__ = "0.3.1"
import rasterio
from interpies.grid import Grid, from_dataset
def open(inputFile, crs=None, name=None, nodata_value=None,
scale_factor=None, **kwargs):
... | jobar8/interpies | interpies/__init__.py | Python | bsd-3-clause | 1,843 | [
"NetCDF"
] | 5d4d59e1142104661c672e0f278718e0656e1fffd2f2ce4dd19ce6d082f21271 |
import numpy as np
import math
from scipy.stats import sem
from uncertainties import ufloat
import uncertainties.unumpy as unp
import matplotlib.pyplot as plt
from scipy.optimize import curve_fit
import scipy.constants as const
from uncertainties.unumpy import (nominal_values as noms, std_devs as stds)
from pint import... | smjhnits/Praktikum_TU_D_16-17 | Anfängerpraktikum/Protokolle/V503_Der_Milikan_Versuch/Python/auswertung.py | Python | mit | 7,943 | [
"Avogadro"
] | 8e1591342d6252bf3d49178bd8eb495a1f923f06af6c0e5692d9bf4fe6a1fd4f |
__all__ = ['workflow_stddft']
from .tools import number_spherical_functions_per_atom
from nac.common import (
DictConfig, angs2au, change_mol_units,
is_data_in_hdf5, h2ev,
hardness, retrieve_hdf5_data,
store_arrays_in_hdf5, xc)
from nac.integrals.multipole_matrices import get_multipole_matrix
from nac... | felipeZ/nonAdiabaticCoupling | nac/workflows/workflow_stddft_spectrum.py | Python | mit | 19,964 | [
"CP2K"
] | bf148db997f0e02f581dcf897b2c0872ac253c980cfe6dad875890a1bbc82f55 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module define a WulffShape class to generate the Wulff shape from
a lattice, a list of indices and their corresponding surface energies,
and the total area and volume of the wulff shape,the weighted su... | gVallverdu/pymatgen | pymatgen/analysis/wulff.py | Python | mit | 27,793 | [
"pymatgen"
] | 4acd1b6d889be826aaa6ae61137f4ec82c712ce1d2f2f0781b4ec44690d368ba |
"""
Compute optical responses with OPTpy
"""
from OPTpy import OPTflow,Structure, lrc_mk_paraljob
nproc = 4
flow = OPTflow(
dirname = './',
#
# Common variables:
#
prefix = 'gaas', # Root name for files required by Tiniba
# Structure from file:
structure=Structure.from_file('GaAs.... | trangel/OPTpy | examples/flows/GaAs-paral-lrc.py | Python | gpl-3.0 | 2,204 | [
"ABINIT"
] | 6c1b60a21a9833f1efd2c2c6d24c924562025a767bf763903af0ca26bf677c46 |
# -*- coding: utf-8 -*-
#
# This file is part of Invenio-Query-Parser.
# Copyright (C) 2014 CERN.
#
# Invenio-Query-Parser 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 ... | jalavik/invenio-query-parser | invenio_query_parser/walkers/printer.py | Python | gpl-2.0 | 2,292 | [
"VisIt"
] | e2c1521d8aa59f1882732bd214cb1fd35194f5ac54289bf5a73aff4e0cb1b2a0 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
Utilities for defects module.
"""
import math
from monty.json import MSONable
import itertools
import pandas as pd
import numpy as np
from numpy.linalg import norm
import logging
from collections import... | gVallverdu/pymatgen | pymatgen/analysis/defects/utils.py | Python | mit | 57,308 | [
"CRYSTAL",
"Gaussian",
"VASP",
"VTK",
"pymatgen"
] | 0f1b8ea26d89dd3c1753f2357bf7e43ef0cce8ba2281aae2542fb053dd0f61f6 |
# Copyright (c) 2009-2021 The Regents of the University of Michigan
# This file is part of the HOOMD-blue project, released under the BSD 3-Clause License.
# Maintainer: mphoward
R""" Multiparticle collision dynamics.
Simulating complex fluids and soft matter using conventional molecular dynamics
methods (:py:mod:`h... | joaander/hoomd-blue | hoomd/mpcd/__init__.py | Python | bsd-3-clause | 11,318 | [
"HOOMD-blue"
] | e1a131c696785c06b2592e62a9f8d0c947fd31f9f1bad71b3aec2fe230747841 |
# proxy module
from __future__ import absolute_import
from mayavi.modules.labels import *
| enthought/etsproxy | enthought/mayavi/modules/labels.py | Python | bsd-3-clause | 90 | [
"Mayavi"
] | cc2595ae5f4eb8f9c0bf1560f343081154818e44bd5507f11ec734b89ab363a8 |
"""This file contains code for use with "Think Bayes",
by Allen B. Downey, available from greenteapress.com
Copyright 2012 Allen B. Downey
License: GNU GPLv3 http://www.gnu.org/licenses/gpl.html
"""
"""This file contains class definitions for:
Hist: represents a histogram (map from values to integer frequencies).
P... | jtrussell/think-bayes-workspace | src/vendor/AllenDowney/thinkbayes.py | Python | mit | 42,406 | [
"Gaussian"
] | 75edb07070d6178b1c318899f88f6e6c3dddf34c574817f6ffbb7ed40dd67fbe |
# Kevin van Rensburg 6/11/2021
# Copyright 2001
# Testing Startup Script version 0.15
# kstart15.py
# Completed Kvep6 and working on Kvep7!!
# adding Game menu def KVersMenu() and chooser def KVersChoice()
# fixed clearScreen with def cls()
# added def ALL(), def ALI(), and def COMCODE()
# fixed and added Kvep7 and acc... | kurg/KendyVerse | kstart15.py | Python | gpl-3.0 | 65,847 | [
"BLAST"
] | 5712f1636efc8f94210e36a42022dc05e032ca3224a52940782ab9fdeae191f2 |
import moose
import rdesigneur as rd
rdes = rd.rdesigneur(
stimList = [['soma', '1', '.', 'vclamp', '-0.065 + (t>0.1 && t<0.2) * 0.02' ]],
plotList = [
['soma', '1', '.', 'Vm', 'Soma membrane potential'],
['soma', '1', 'vclamp', 'current', 'Soma holding current'],
]
)
rdes.buildModel()
moose... | BhallaLab/moose-examples | tutorials/Rdesigneur/ex2.1_vclamp.py | Python | gpl-2.0 | 365 | [
"MOOSE"
] | ba736620fd91aa375901aad16bb7a156d651fc4b03672d442f5e8ad094823677 |
# Global variables to pass database contexts around. Fairly hackish that they
# are shared this way, but at least they have been moved out of Galaxy's lib/
# code base.
galaxy_context = None
tool_shed_context = None
install_context = None
| mikel-egana-aranguren/SADI-Galaxy-Docker | galaxy-dist/test/functional/database_contexts.py | Python | gpl-3.0 | 239 | [
"Galaxy"
] | 39b40d144d99068f7fef7ae73fb5ca4053a1415f044e13b4f9bee2dd22e58931 |
# 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 the G... | espressopp/espressopp | src/check/System.py | Python | gpl-3.0 | 1,349 | [
"ESPResSo"
] | d719b71771521857cbf7e031f26b3811df9cf9755dbabe0b044f7dca60df6591 |
"""
Utilities for ComponentMonitoring features
"""
import datetime
import socket
from DIRAC import S_OK
from DIRAC.FrameworkSystem.Client.ComponentMonitoringClient import ComponentMonitoringClient
from DIRAC.Core.Security.ProxyInfo import getProxyInfo
def monitorInstallation( componentType, system, component, module ... | vmendez/DIRAC | FrameworkSystem/Utilities/MonitoringUtilities.py | Python | gpl-3.0 | 3,226 | [
"DIRAC"
] | 285b176d5720229f9ef4bfe75c4e425b92485087ade6ca3174c9e65561e22d38 |
#!/usr/bin/env python
import os
import sys
from glob import glob
sys.path.insert(0, os.path.abspath('lib'))
from ansible import __version__, __author__
try:
from setuptools import setup, find_packages
except ImportError:
print("Ansible now needs setuptools in order to build. Install it using"
" yo... | a13m/ansible | setup.py | Python | gpl-3.0 | 1,189 | [
"Galaxy"
] | 7447610fef486756a319efd1753513e4c53b35353274d1febb3fd30ca6c52f9d |
#!/usr/bin/env python3
import os
import sys
import argparse
from src.gff import read_gff, write_gff
from src.annotation import read_annotations, annotate_genes
from src.sequence import Sequence, read_fasta
from src.sequtil import get_subsequence, translate
from src.transcript import Rsem
from src.transcript_builder imp... | genomeannotation/transvestigator | transvestigator.py | Python | mit | 9,335 | [
"BLAST"
] | b2052a753f90b4265f3c646e64e4667a92460f4f8da2eef12346b823e6a66d7a |
#!/usr/bin/env python3.3
#import Pyro4
class Reader(object):
def __init__(self, client):
self.client = client
def visit(self, library):
print("To jest {0}.".format(self.client))
self.give_back(library)
self.borrow(library)
print("Dziekujemy.")
def give_back(self, l... | asiagit/library | Reader.py | Python | mit | 777 | [
"VisIt"
] | 2de49d8098d44319c05aed73b7893f9942dddfb82998c799dc0dab0efc6b34cf |
# coding=utf-8
# 1. generate velocity and force nodes of sphere using MATLAB,
# 2. for each force node, get b, solve surrounding velocity boundary condition (pipe and cover, named boundary velocity) using formula from Liron's paper, save .mat file
# 3. read .mat file, for each boundary velocity, solve associated bounda... | pcmagic/stokes_flow | helixInPipe/helixInPipe.py | Python | mit | 12,596 | [
"VTK"
] | 94ee2988cdcf446b3be1371f2d69d12970b440f8332fd22c7d4bd09ff78f3da9 |
# -*- coding: UTF-8 -*-
"""
``bwa_mapper`` :sup:`*`
-----------------------------------------------------------------
:Authors: Menachem Sklarz
:Affiliation: Bioinformatics core facility
:Organization: National Institute of Biotechnology in the Negev, Ben Gurion University.
A module for running bwa mapper:
The reads... | bioinfo-core-BGU/neatseq-flow_modules | neatseq_flow_modules/main_NSF_classes/mapping/bwa_mapper.py | Python | gpl-3.0 | 15,944 | [
"BWA"
] | d3ad3994a46d20235c83c884ea7412f07e1984fb100aa574c6226a4394a0a711 |
#!/usr/bin/python
# Copyright (C) 2011 Tianyang Li
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This pro... | tianyang-li/meta-transcriptome | sample_compare_1/blast_relate.py | Python | gpl-3.0 | 3,108 | [
"BLAST"
] | e77f99a1173bdd7e810bbeccbfd1c8759cbcfa97d902eb281eaa64017f2927e8 |
from __future__ import (absolute_import, division, print_function)
import numpy as np
from CrystalField.energies import energies as CFEnergy
from six import iteritems
from six import string_types
def _get_normalisation(nre, bnames):
""" Helper function to calculate the normalisation factor.
Defined as: ||... | wdzhou/mantid | scripts/Inelastic/CrystalField/normalisation.py | Python | gpl-3.0 | 9,561 | [
"CRYSTAL",
"Gaussian"
] | 093aed333277b653352df81deb194532ba62898dc13adb4f3fbad45eb4dc8736 |
import numpy as np
import mdtraj as md
import msmbuilder.featurizer, msmbuilder.utils
t = md.load("./trajectories/run0-clone1.h5")[0]
atom_indices, pair_indices = msmbuilder.featurizer.subset_featurizer.get_atompair_indices(t, keep_atoms=None, exclude_atoms=np.array([]))
dih_model = msmbuilder.utils.load("./dihedral... | choderalab/MSMs | code/sandbox/build_atompairs.py | Python | gpl-2.0 | 807 | [
"MDTraj"
] | 6a9ffa239551375a3360910f2360e0a702fa4f4de427a82f887e41d3e0cce958 |
# encoding: utf-8
"""surfaceslab.py - Window for setting up surfaces
"""
import gtk
from gettext import gettext as _
from ase.gui.widgets import pack, cancel_apply_ok, oops
from ase.gui.pybutton import PyButton
from ase.gui.setupwindow import SetupWindow
import ase.lattice.surface as _surf
import ase
import numpy as n... | grhawk/ASE | tools/ase/gui/surfaceslab.py | Python | gpl-2.0 | 10,311 | [
"ASE",
"CRYSTAL"
] | 51007bdf81fc358e5ea1c5d6d1aa900b35a403f75d0c9fd0775a34ab6471cf1c |
# Copyright: (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.com>
# Copyright: (c) 2016, Toshio Kuratomi <tkuratomi@ansible.com>
# Copyright: (c) 2018, Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
# Make coding more python3-ish
from __future__ import ... | kvar/ansible | lib/ansible/cli/__init__.py | Python | gpl-3.0 | 20,562 | [
"Galaxy"
] | 6ac2e73917cc6ef99b6b3bf8092f5a12874a4a72cda883c63f6ed62ecc921fab |
# -*- Mode: Python; coding: utf-8 -*-
# vi:si:et:sw=4:sts=4:ts=4
##
## Copyright (C) 2005-2013 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 Fre... | tiagocardosos/stoq | stoq/gui/shell/shellapp.py | Python | gpl-2.0 | 14,702 | [
"VisIt"
] | dbfa2af90046bde1b8db52d646fb23fc5bdc7c7d2fa61d9bc474e3374e97f4b9 |
"""Generate SWAT realtime files workflow.
See akrherz/iem#285.
We are generating the format directly used by the distrubuted SWAT. Notes:
- 1800 HUCs per file, we generate four total files to cover the 5729 HUC12s
- While the SWATID column is unique, the HUC12 column is not.
Run from RUN_2AM.sh
"""
# stdlib
from da... | akrherz/iem | scripts/swat/swat_realtime.py | Python | mit | 5,493 | [
"NetCDF"
] | 6ff43b25805223296fd1f32deea276f95860ded2b6dd03d022f8ae0e7eeb3997 |
"""Tests for user-friendly public interface to polynomial functions. """
from sympy.polys.polytools import (
Poly, PurePoly, poly,
parallel_poly_from_expr,
degree, degree_list,
LC, LM, LT,
pdiv, prem, pquo, pexquo,
div, rem, quo, exquo,
half_gcdex, gcdex, invert,
subresultants,
resu... | wdv4758h/ZipPy | edu.uci.python.benchmark/src/benchmarks/sympy/sympy/polys/tests/test_polytools.py | Python | bsd-3-clause | 105,444 | [
"Gaussian"
] | 70db6711630e5c31267f2cc4a6ea41c68d88e0c2d0d62a0ae37b80d462dbaabd |
from nanopores import *
from dolfin import *
geo_name = "P_geo"
geo_params = {"x0": [0.,0.,0.]} # any parameter change here will not affect mesh generation yet
phys_params = {"bV":0.1, "MembraneSiNqs":-30e-3, "bulkcon":1e3, "DNAqs": -0.1362}
clscale = 1.
meshgen_dict = generate_mesh(clscale, geo_name, **geo_params)
... | mitschabaude/nanopores | scripts/test2DP.py | Python | mit | 1,613 | [
"FEFF"
] | 65658ccf151b35213c991eb6a36869d13c70a7167d68224e39cd07e47b66e409 |
# modified mexican hat wavelet test.py
# spectral analysis for RADAR and WRF patterns
import os, shutil
import time, datetime
import pickle
import numpy as np
from scipy import signal, ndimage
import matplotlib.pyplot as plt
from armor import defaultParameters as dp
from armor import pattern
from armor import objec... | yaukwankiu/armor | tests/modifiedMexicanHatTest7.py | Python | cc0-1.0 | 5,879 | [
"Gaussian"
] | 05c820961eb6a02ac705ba74f94f13d0c6b76f5b712b001df6a70696b81af844 |
#pylint: disable=invalid-name
"""
Some of the sphinx warnings come from the C++ code, from the properties of the algorithms or from the summary string
This test tries to detect the most common such errors.
It also detects if a new category is created (i.e. someone uses Utilities instead of Utility)
"""
from __future__ ... | ScreamingUdder/mantid | Testing/SystemTests/tests/analysis/SphinxWarnings.py | Python | gpl-3.0 | 4,946 | [
"CRYSTAL"
] | ae5008d882dbb1bac8aedc818505b73ba513ab3ffba350da0e5ff2c0a42e41ee |
# Copyright 1999 by Cayte Lindner. All rights reserved.
# This code is part of the Biopython distribution and governed by its
# license. Please see the LICENSE file that should have been included
# as part of this package.
#
# NOTE - This file has been split in two as a work arround for Jython JVM limits.
import os
... | updownlife/multipleK | dependencies/biopython-1.65/Tests/test_prosite1.py | Python | gpl-2.0 | 196,949 | [
"Biopython"
] | e398ebc75e5ec9488c1be4b7daacf1e41c15126faf8113f881df6af5ad6f2c90 |
# -*- coding: utf-8 -*-
from __future__ import division
import numpy as np
from pgmpy.factors.distributions import BaseDistribution
from pgmpy.factors.distributions import GaussianDistribution
class CanonicalDistribution(BaseDistribution):
u"""
The intermediate factors in a Gaussian network can be describe... | jhonatanoliveira/pgmpy | pgmpy/factors/continuous/CanonicalDistribution.py | Python | mit | 19,136 | [
"Gaussian"
] | 52c9ffcffc865ef29eebe19c4b13378e43933ba7ef5eaf0647192e8382661aee |
from __future__ import division, print_function, absolute_import
from sklearn.utils.extmath import logsumexp
from sklearn.utils import check_random_state
from sklearn.base import BaseEstimator
import numpy as np
import random, collections
import scipy.sparse
# Author: Gustav Larsson
# Mark Stoehr <stoehr.mark... | amitgroup/parts-net | pnet/bernoulli_mm.py | Python | bsd-3-clause | 19,546 | [
"Gaussian"
] | a915fa3387e509fcd34c47e520524fb9501896b4273eb088b2dc2547a97ae3af |
# Copyright Contributors to the Pyro project.
# SPDX-License-Identifier: Apache-2.0
from collections import namedtuple
import functools
from functools import partial
from itertools import chain
import operator
from typing import Callable
import jax
import jax.numpy as jnp
import jax.random
from jax.tree_util import t... | pyro-ppl/numpyro | numpyro/contrib/einstein/steinvi.py | Python | apache-2.0 | 18,091 | [
"Gaussian"
] | 71bebfac1d7c494cebd5d6f9d411d4d18d796cf0d80a77df0a0b8dfa53d3d19e |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# gpload - load file(s) into Greenplum Database
# Copyright Greenplum 2008
'''gpload [options] -f configuration file
Options:
-h hostname: host to connect to
-p port: port to connect to
-U username: user to connect as
-d database: database to connect to
... | randomtask1155/gpdb | gpMgmt/bin/gpload.py | Python | apache-2.0 | 99,688 | [
"ADF"
] | 983748d3be5ca0bfa7f3a55e1f094119f3604b9ab54d340f873fcb4f0a9548b3 |
""" General untilities used throughout the package """
from __future__ import print_function
import numpy as np
__all__ = ['add_data', 'count_uncert_ratio', 'between', 'brighter',
'closest_match', 'closest_match2d', 'double_gaussian', 'extrap1d',
'find_peaks', 'gaussian', 'get_verts', 'is_numeric... | philrosenfield/ResolvedStellarPops | utils/utils.py | Python | bsd-3-clause | 11,500 | [
"Gaussian"
] | 5cbd35e24e6a8d2fe4980a8fb7b077651d8d3918230e1cd23a9fd3ed814be138 |
"""
Create a profile from arbitrary ASCII text files
================================================
Script profile_from_txt
-----------------------
Use the TAMOC ambient module to create profiles in netCDF format for use by
TAMOC from data in text files. This file demonstrates working with data
digitized from plot... | socolofs/tamoc | bin/ambient/nc_profile_from_txt.py | Python | mit | 4,690 | [
"NetCDF"
] | ac2f0078a7ec9ea37e7237c272da2c9dde217474c5dbd82c231a652e977f1502 |
import numpy as np
from scipy.optimize import minimize
import GPy
from GPy.kern import Kern
from GPy.core import Param
from sklearn.metrics import pairwise_distances
from sklearn.metrics.pairwise import euclidean_distances
class TV_SquaredExp(Kern):
""" Time varying squared exponential kernel.
For more i... | pcmoritz/ray-1 | python/ray/tune/schedulers/pb2_utils.py | Python | apache-2.0 | 5,923 | [
"Gaussian"
] | d1d12a4217898b7a728c63d56283048b291b05665057da91c6aa67b9d44ad509 |
#!/usr/bin/python
"""
Definition of the wflow_W3RA model.
---------------------------------------
The model is modified from the Australian Water Resources Assessment
Landscape (AWRA-L) model version 0.5
W3RA is documented in
van Dijk et al. (2013), Water Resour. Res., 49, 2729-2746, doi:10.1002/wrcr.20251
URL: http:/... | OpenDA-Association/OpenDA | model_bmi/java/test/org/openda/model_bmi/testData/wflow_bin/wflow/wflow_W3RA.py | Python | lgpl-3.0 | 36,266 | [
"NetCDF"
] | 07bb1082b7abf1874d93dbab2fbae4deb6d6adf3f14fb0338af7d31dda68e504 |
from math import sqrt, pi
import numpy as np
from gpaw.xc.functional import XCFunctional
from gpaw.xc.lda import LDA
from gpaw.xc.libxc import LibXC
from gpaw.lcao.eigensolver import LCAO
from gpaw.wavefunctions.lcao import LCAOWaveFunctions
from gpaw.utilities import unpack
from gpaw.utilities.blas import gemm
from ... | robwarm/gpaw-symm | gpaw/xc/noncollinear.py | Python | gpl-3.0 | 13,580 | [
"GPAW"
] | 62cfc4c4e900561e6410616301566364bca58707ff828b07eb08cd39bb173bc2 |
#!/usr/bin/env python
# -- python2.7+ --
import sys
import os
import time
from Bio import SeqIO
import tempfile
import subprocess
import module_locator
import ntpath
import argparse
rundir = os.path.dirname(os.path.realpath(__file__))
basedir = os.path.realpath("%s/../"%(rundir)) #path to topcons2_webserver
os.envir... | ElofssonLab/TOPCONS2 | topcons2_webserver/workflow/pfam_workflow.py | Python | gpl-2.0 | 17,962 | [
"Octopus"
] | 63a99567d60b56e7fb26530ddd820b0929f65fd6f8696ca60d1566a3006573a9 |
"""
Class for the height of the geoid.
"""
import numpy as _np
import copy as _copy
import xarray as _xr
from .shgrid import SHGrid as _SHGrid
from .shgrid import _pygmt_module
class SHGeoid(object):
"""
Class for the height of the geoid. The class is initialized from a class
instance of SHGravCoeffs... | SHTOOLS/SHTOOLS | pyshtools/shclasses/shgeoid.py | Python | bsd-3-clause | 15,251 | [
"NetCDF"
] | aff1e7ad8f0bf6ecbc5a64d120d56464fa6c5e90e04bfc18f666a6d6416f74a7 |
"""
Define common steps for instructor dashboard acceptance tests.
"""
# pylint: disable=C0111
# pylint: disable=W0621
from __future__ import absolute_import
from django.conf import settings
from lettuce import world, step
from mock import patch
from nose.tools import assert_in # pylint: disable=E0611
from coursew... | echanna/EdxNotAFork | lms/djangoapps/instructor/features/common.py | Python | agpl-3.0 | 4,629 | [
"VisIt"
] | 11a3bb6be5ca467d09bc7b5237b6e5b952c8e99716d98afba11e1c0e222b01c4 |
# Copyright 2013-2020 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 RAnnotationhub(RPackage):
"""Client to access AnnotationHub resources.
This packag... | iulian787/spack | var/spack/repos/builtin/packages/r-annotationhub/package.py | Python | lgpl-2.1 | 2,176 | [
"Bioconductor"
] | 377ae4cb58e2894685f3626fa64df90afdc03143f2c86707c5e8057f2ebe83db |
#!/usr/bin/env python
#
# $File: DiscardIf.py $
#
# This file is part of simuPOP, a forward-time population genetics
# simulation environment. Please visit http://simupop.sourceforge.net
# for details.
#
# Copyright (C) 2004 - 2010 Bo Peng (bpeng@mdanderson.org)
#
# This program is free software: you can redistribute ... | BoPeng/simuPOP | docs/DiscardIf.py | Python | gpl-2.0 | 1,831 | [
"VisIt"
] | 04b9137078c620211a098e4e8390f3f49b0dcdf9df3913a285fcdcf6fe61dd79 |
""" PilotAgentsDB class is a front-end to the Pilot Agent Database.
This database keeps track of all the submitted grid pilot jobs.
It also registers the mapping of the DIRAC jobs to the pilot
agents.
Available methods are:
addPilotTQReference()
setPilotStatus()
deletePilot()
clearPilo... | yujikato/DIRAC | src/DIRAC/WorkloadManagementSystem/DB/PilotAgentsDB.py | Python | gpl-3.0 | 43,047 | [
"DIRAC"
] | 1e7a873efafa03e727d74ad74dba02cbcf29e17ba3805e791d9d7c90ea02f277 |
#########################################################################################
# #
# integrated_denovo_pipeline.py: a denovo pipeline for processing DBR RADseq Data #
# Copyright (C) 2016 Kelly Anne Pierce (kellyan... | kellyp2738/RADseqDuplicateFiltering | integrated_denovo_pipeline.py | Python | gpl-3.0 | 39,908 | [
"BWA"
] | 1917db2f404814d0bde218bcb7154ef0070fdc180d66517bf3d1f89513b8d021 |
# $Id$
#
# Copyright (C) 2004-2008 Greg Landrum and Rational Discovery LLC
# All Rights Reserved
#
""" Defines Naive Baysean classification model
Based on development in: Chapter 6 of "Machine Learning" by Tom Mitchell
"""
import numpy
from rdkit.ML.Data import Quantize
def _getBinId(val, qBounds):
bid ... | bp-kelley/rdkit | rdkit/ML/NaiveBayes/ClassificationModel.py | Python | bsd-3-clause | 10,123 | [
"RDKit"
] | 59d76345df7ae70f3c628fa6c7250710d22527ea5e261f65fa6aef9560e1e899 |
<<<<<<< HEAD
<<<<<<< HEAD
# Copyright 2009 Brian Quinlan. All Rights Reserved.
# Licensed to PSF under a Contributor Agreement.
"""Execute computations asynchronously using threads or processes."""
__author__ = 'Brian Quinlan (brian@sweetapp.com)'
from concurrent.futures._base import (FIRST_COMPLETED,
... | ArcherSys/ArcherSys | Lib/concurrent/futures/__init__.py | Python | mit | 2,540 | [
"Brian"
] | 7f4857c21b56fa13ce197bedc9bfe61598d3c481d49ae57d74a67e42133f9ade |
import unittest
import pysal
import numpy as np
from pysal.spreg import error_sp_het_regimes as SP
from pysal.spreg.error_sp_het import GM_Error_Het, GM_Endog_Error_Het, GM_Combo_Het
class TestGM_Error_Het_Regimes(unittest.TestCase):
def setUp(self):
#Columbus:
db=pysal.open(pysal.examples.get_path... | dfolch/pysal | pysal/spreg/tests/test_error_sp_het_regimes.py | Python | bsd-3-clause | 14,611 | [
"COLUMBUS"
] | 3e6bbcbce38f48ab33f541821a7388dacd8a092450898402399a18f8c6b5b7e8 |
""" Runs few integrity checks
The following options can be set for the ValidateOutputDataAgent.
.. literalinclude:: ../ConfigTemplate.cfg
:start-after: ##BEGIN ValidateOutputDataAgent
:end-before: ##END
:dedent: 2
:caption: ValidateOutputDataAgent options
"""
__RCSID__ = "$Id$"
import re
import ast
from DI... | fstagni/DIRAC | TransformationSystem/Agent/ValidateOutputDataAgent.py | Python | gpl-3.0 | 9,401 | [
"DIRAC"
] | 8076757cf4ca53b391505ce410d54b8b66ca6908bc9a1f4f4451063018d90c72 |
# $Id: SD.py,v 1.10 2008-08-05 00:20:44 gosselin_a Exp $
# $Log: not supported by cvs2svn $
# Revision 1.9 2008/06/30 02:59:57 gosselin_a
# Fixed definition of equivNumericTypes list.
#
# Revision 1.8 2008/06/30 02:41:44 gosselin_a
# Preleminary check-in of changes leading to the 0.8 revision.
# - switch to numpy... | fhs/pyhdf | pyhdf/SD.py | Python | mit | 115,576 | [
"NetCDF"
] | 2c4d80313ccd2d7ebd569df8b66c094fd37fc94649869f5b25b72f68a0988e86 |
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=120 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# ------------------------------------------------------... | marmyshev/transitions | openlp/plugins/songs/forms/editsongform.py | Python | gpl-2.0 | 42,481 | [
"Brian"
] | 14db7cd7c0afc3604f909d2e2d079696628a45b18f6d574f8a353831b604dc4e |
# Licensed under a 3-clause BSD style license - see LICENSE.rst
import itertools
import pytest
import numpy as np
from numpy.testing import assert_allclose
from ..utils import discretize_model
from ...modeling.functional_models import (
Gaussian1D, Box1D, MexicanHat1D, Gaussian2D, Box2D, MexicanHat2D)
from ...mo... | funbaker/astropy | astropy/convolution/tests/test_discretize.py | Python | bsd-3-clause | 6,089 | [
"Gaussian"
] | 8e47004cb750a65dd0f4cb602d4c03091d8cef8338fe5092646d10b01cfcc728 |
#!/usr/bin/env python
#EXAMINE_ONLY = True
EXAMINE_ONLY = False
DISABLE_MULTI = False
#DISABLE_MULTI = True
import os
import sys
sys.path.append('../../build/swig')
sys.path.append('../../build/.libs')
sys.path.append('../shared')
import artifastring_instrument
ARTIFASTRING_SAMPLE_RATE = artifastring_instrument.ARTIF... | gperciva/artifastring | research/schelleng/check_slips.py | Python | gpl-3.0 | 12,574 | [
"Gaussian"
] | 3ba03b3ff4987a051fcbc233f1e32c5b9cc5a7a92c2fc121dad8dec6b12bdfaf |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals, absolute_import
from django.conf.urls import include, url
from django.contrib import admin
from django.conf import settings
from django.conf.urls.static import static
from django.views.generic import TemplateView
from rest_framework.routers import Defaul... | gengue/django-new-marana | {{cookiecutter.github_repository_name}}/{{cookiecutter.app_name}}/config/urls.py | Python | bsd-3-clause | 1,539 | [
"VisIt"
] | f26726d075d42089a79938ce27dbf98c7af73feaf05b4373366170b2597943fa |
# Copyright 2020 Google Research. 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 applicable law... | google/automl | efficientdet/tf2/postprocess.py | Python | apache-2.0 | 24,251 | [
"Gaussian"
] | effa0889b910bfd556face11f9a6ef14d01d0ed318b0968056821472e53d23b0 |
from rest_framework.throttling import UserRateThrottle
from rest_framework.exceptions import PermissionDenied
from django.conf import settings
from django.contrib.sites.models import Site
class PerUserThrottlingRatePerGroup(UserRateThrottle):
def allow_request(self, request, view):
"""
Implement ... | oriel-hub/api | django/idsapi/openapi/permissions.py | Python | gpl-2.0 | 1,176 | [
"VisIt"
] | 25f6148961cc81458cdda8adcb6839cb18b3f3e77900858b06fabe671df5efd4 |
#!/usr/local/bin/python2.7
import urllib2
import pdb
import pyperclip
import json
import datetime
import time
class Game:
""" holds data about a game
Attributes
date:
gameID:
homeTeamID:
awayTeamID:
homeTeamStream:
awayTeamStream:
"""
def __init__(... | proverbialsunrise/hockeyScript | getStreamURL.py | Python | bsd-2-clause | 4,193 | [
"COLUMBUS"
] | a84e40063515f6e92a6aea73bcf1cb1a9c5a8f0489bd3aa4be369e2bc479b8b8 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module implements more advanced transformations.
"""
from typing import Optional, Dict
import numpy as np
from fractions import Fraction
from math import gcd
from itertools import groupby, product
fro... | mbkumar/pymatgen | pymatgen/transformations/advanced_transformations.py | Python | mit | 91,214 | [
"ASE",
"CRYSTAL",
"pymatgen"
] | 3ce5c1b2b1a42325ee3e6d077a4dfc4a7be5216fbc998db28b2024d97aee118a |
# -*- coding: utf-8 -*-
# Copyright (C) 2012, Almar Klein, Ant1, Marius van Voorden
#
# This code is subject to the (new) BSD license:
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of s... | saullocastro/pyNastran | pyNastran/gui/images2gif.py | Python | lgpl-3.0 | 37,808 | [
"NEURON"
] | 436e2e3782549dd298f16fefdfc611b93d74e41e2140bb9b1fd5df58bfdba158 |
#
# This script reads Genome Data files in BAM format and converts to SAM format
#
import os
import sys
import swiftclient.client
import pysam
# Replace user and key with username and password
config = {'user':'xxxxxx',
'key':'xxxxxx',
'tenant_name':'g2015016',
'authurl':'http://smog.upp... | hkominos/PySpark_Project | getbams.py | Python | apache-2.0 | 3,149 | [
"BWA",
"pysam"
] | d9eacd055442fe5ce1a6a1fd1a61ef92c0f5dbfadc58078240ad2c761d6d937c |
# Copyright 2015 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 applicable law or ag... | Sorsly/subtle | google-cloud-sdk/lib/googlecloudsdk/core/resource/resource_expr.py | Python | mit | 20,543 | [
"VisIt"
] | a70b2b787e8965aee2fcddc18d7f4357159bb83ad59ccacfc0fae4511ce165e8 |
print(data_view_config)
# { 'dataset_ids': ['1160'],
# 'group_by': [],
# 'model_type': 'default',
# 'descriptors': [
# {
# 'category': 'Real',
# 'descriptor_key': 'Temperature (Property Band gap)',
# 'units': '',
# 'lower_bound': 0.0,
# '... | CitrineInformatics/python-citrination-client | docs/source/code_samples/views/fetching_ml_config_defaults_3.py | Python | apache-2.0 | 1,943 | [
"Amber"
] | 965c626e804319c0f2d8da7bf925e0977cb703c366e0477df6314048eed0d330 |
#!/usr/bin/env python
#
# Copyright (C) 2014
# Brian Caswell <bmc@lungetech.com>
# Narf Industries <info@narfindustries.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
# to deal in the Software without res... | f0rki/cb-multios | original-challenges/EternalPass/poller/for-release/machine.py | Python | mit | 3,488 | [
"Brian"
] | 6dfea4d552ef089aae8c8099c5463889a41ceb5deac07b8475b23df1c888c029 |
"""
Copyright (c) 2012-2019 RockStor, Inc. <http://rockstor.com>
This file is part of RockStor.
RockStor 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 lat... | phillxnet/rockstor-core | src/rockstor/storageadmin/tests/test_config_backup.py | Python | gpl-3.0 | 59,793 | [
"VisIt"
] | 77ba745246a8016729001c876e43ce6077637ad07d0cec5d15a3c40d02a1a082 |
#!/usr/bin/env python
# Copyright 2015 The Kubernetes Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appli... | dchen1107/test-infra | verify/verify-boilerplate.py | Python | apache-2.0 | 5,565 | [
"VisIt"
] | 19e7dd6669e927845b0ed7eb0f80843472a5df437445d95145e18b3ac98461a1 |
"Test the RawRadialDistributionFunction function."
from numpy import *
from asap3 import *
from asap3.analysis.rdf import RadialDistributionFunction
from ase.lattice.cubic import FaceCenteredCubic
from asap3.testtools import *
print_version(1)
# testtypes: latticeconst, maxRDF, bins, useEMT
testtypes = ((3.6, 6.001,... | auag92/n2dm | Asap-3.8.4/Test/RDF.py | Python | mit | 1,972 | [
"ASE"
] | 463035e68af30490875e34648d694d7686e0f55550a92e9827184eb58ea4c772 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.