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 -*-
"""
This module defined controllers for CherryPy.
Updated since version 1.1:
1. Added support for postprocess and visualization.
2. Added support for quit.
Updated since version 1.2 (OpenWarp - Add Logging Functionality):
Added support for logging
Updated since version ... | NREL/OpenWARP | source/openwarpgui/openwarp/web.py | Python | apache-2.0 | 13,950 | [
"ParaView"
] | 32bcfb8109564c09443c26b595dda09a536b20b76759258959f09e081bb67fa1 |
#!/usr/bin/env python
# Copyright 2014-2019 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/dft/uks.py | Python | apache-2.0 | 5,469 | [
"PySCF"
] | 4cbeb7c2b7f70156c8e76712b240df3b5368875d179eadd1aea25c3291df2dbf |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import vtk
def main():
colors = vtk.vtkNamedColors()
# Set the colors.
colors.SetColor("AzimuthArrowColor", [255, 77, 77, 255])
colors.SetColor("ElevationArrowColor", [77, 255, 77, 255])
colors.SetColor("RollArrowColor", [255, 255, 77, 255])
colo... | lorensen/VTKExamples | src/Python/Visualization/CameraModel2.py | Python | apache-2.0 | 9,764 | [
"VTK"
] | 02984df887eca81ecac03998ff747e4574b4e063bd5e1fac7a3f08333a4c95a6 |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""\
Strongly connected components
composantes fortement connexes
jill-jênn vie et christoph dürr - 2015-2018
"""
__all__ = ["tarjan_recursif", "tarjan", "kosaraju", "reverse"]
# snip{ sccp-tarjan-recursif
# pylint: disable=global-variable-undefined
def tarjan_recursif(... | jilljenn/tryalgo | tryalgo/strongly_connected_components.py | Python | mit | 5,769 | [
"VisIt"
] | 3ee3e42482972ab7225a97ce4a134d17c14d8cdb6ce09d15d6ba4d76a36150d1 |
# shamelessly copied from pliExpertInfo (Vali, Mirakels, Littlesat)
from os import path
from enigma import iServiceInformation, iPlayableService
from Components.Converter.Converter import Converter
from Components.Element import cached
from Components.config import config
from Tools.Transponder import ConvertToHumanRe... | BlackHole/enigma2-obh10 | lib/python/Components/Converter/PliExtraInfo.py | Python | gpl-2.0 | 19,399 | [
"Galaxy"
] | 97f1c67de7ae554b7072f3c354f5425fdbe0bcc3cb656590937d3a0c7bb571ec |
# 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.
"""Provides an interface to start and stop Android emulator.
Emulator: The class provides the methods to launch/shutdown the emulator with
... | vadimtk/chrome4sdp | build/android/pylib/utils/emulator.py | Python | bsd-3-clause | 14,097 | [
"Galaxy"
] | b450ac4842d00716d3873b941f2506f1a06c4297945371085e3727eb97580bbf |
import clusterpy as _clusterpy
import pysal as ps
import struct
__author__ = "Sergio Rey <sjsrey@gmail.com>"
__ALL__= ['Layer', 'loadArcData', 'importCsvData', 'addRook2Layer', 'addQueen2Layer', 'addArray2Layer', 'addW2Layer']
def _importArcData(filename):
"""Creates a new Layer from a shapefile (<file>.shp)
... | TaylorOshan/pysal | pysal/contrib/clusterpy/clusterpy_ext.py | Python | bsd-3-clause | 8,259 | [
"COLUMBUS"
] | 78c30ba705157a26c002e31bfa2a3de2d687fdf98f52bb440357adc9cd623426 |
import unittest
from netcdf import netcdf as nc
from datetime import datetime
from models import JobDescription
import os
import glob
class TestHeliosat(unittest.TestCase):
def setUp(self):
os.system('rm -rf static.nc temporal_cache product')
os.system('cp -rf data mock_data')
self.files ... | ahMarrone/solar_radiation_model | tests/heliosat_test.py | Python | mit | 2,296 | [
"NetCDF"
] | 9960728d494d4afed8ac019fdb2f17ff783d22a754d2cc2b25c7b6540aa88ec7 |
from Bio import SearchIO
from sys import argv
def main(args):
if len(args) == 2:
filenameRoot = args[1].split(".")[0]
filenameXML = filenameRoot + ".xml"
SearchIO.convert(args[1], 'blast-tab', filenameXML, 'blast-xml')
elif len(args) == 3:
filenameRoot = args[1].split(".")[0]
filenameXML = args[2]
Se... | jameslz/MICA | scripts/convert-blastTab-to-blastXML.py | Python | gpl-2.0 | 515 | [
"BLAST"
] | 5e6f600d72d620d4ef9209fb43c1e67e8037808d1256d9d42003ccd927fe47f1 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# proteinExtractor.py
#
# Copyright 2015 Carlos Eduardo Sequeiros Borja <casebor@gmail.com>
#
# 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 Foundat... | casebor/labioscripts | python/proteinExtractor.py | Python | gpl-3.0 | 3,288 | [
"MDTraj",
"NetCDF"
] | f1d95da8703d8e3cf9e6c6a79409bf3af722e0278331fd95d1008f793c696114 |
#!/usr/bin/env python
"""
MODULE: r.out.pism
AUTHOR(S): Julien Seguinot <seguinot@vaw.baug.ethz.ch>.
PURPOSE: Export multiple raster maps to a single NetCDF file for
the Parallel Ice Sheet Model [1]
COPYRIGHT: (c) 2011-2018 Julien Seguinot
This program is free software: you can redistribut... | jsegu/r.out.pism | r.out.pism.py | Python | gpl-3.0 | 17,757 | [
"NetCDF"
] | af958ff950ccb20a0e1ae254e3efe2653fe573dfd8ef0c2f4593e28857605f5b |
from dropbox import session, client
from DTL.api import Path, apiUtils, loggingUtils
class Dropbox(object):
__metaclass__ = loggingUtils.LoggingMetaclass
def __init__(self, appKey, appSecret, appAccessType):
apiUtils.synthesize(self, "appKey", appKey)
apiUtils.synthesize(self, "appSecret"... | rocktavious/DevToolsLib | DTL/dropbox/core.py | Python | mit | 2,593 | [
"VisIt"
] | fdf184791620705d3f09d2685516b03f3f595fa511057235a3342def51385deb |
# Principal Component Analysis Code :
from numpy import mean,cov,double,cumsum,dot,linalg,array,rank,size,flipud
from pylab import *
import numpy as np
import matplotlib.pyplot as pp
#from enthought.mayavi import mlab
import scipy as scp
import scipy.ndimage as ni
import scipy.io
import roslib; roslib.load_manifes... | tapomayukh/projects_in_python | classification/Classification_with_HMM/Single_Contact_Classification/simulation_results/comparision_with_kNN_PCA/Combined/object_training/k_PC_categories_generalized.py | Python | mit | 6,403 | [
"Mayavi"
] | 045aae64aa2b015d8c1caa497ea378f1afba309446a00cda0e05ac8c46ef2062 |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# LAMMPS documentation build configuration file, created by
# sphinx-quickstart on Sat Sep 6 14:20:08 2014.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# aut... | pastewka/lammps | doc/utils/sphinx-config/conf.py | Python | gpl-2.0 | 10,901 | [
"LAMMPS"
] | 85a96a52c5806635029bb79c99502318d975f2952e34a0e9f28f676501422f3e |
# -*- coding: utf-8 -*-
"""
ORCA Open Remote Control Application
Copyright (C) 2013-2020 Carsten Thielepape
Please contact me by : http://www.orca-remote.org/
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as publi... | thica/ORCA-Remote | src/ORCA/widgets/core/TouchRectangle.py | Python | gpl-3.0 | 2,811 | [
"ORCA"
] | 87e2ee8ff450635665dc2e9d3b0f8587113f2d14d94b929dc9be72704bb52e77 |
#coding: utf-8
import unittest
import requests
import responses
from compropago import CompropagoAPI, Charge
class APITestCase(unittest.TestCase):
def test_api_constructor(self):
api = CompropagoAPI('My API Key')
assert(api.api_key == 'My API Key')
assert(api.url_base == 'https://api.compro... | tzicatl/compropago-python | compropago/tests.py | Python | mit | 5,662 | [
"Galaxy"
] | b6d51495159dd3d82601090a315a1bb93cf405c41c201670483556efea1e4f72 |
#-----------------------------------------------------------------------------
# Copyright (c) 2010-2012 Brian Granger, Min Ragan-Kelley
#
# This file is part of pyzmq
#
# Distributed under the terms of the New BSD License. The full license is in
# the file COPYING.BSD, distributed as part of this software.
#-----... | IsCoolEntertainment/debpkg_python-pyzmq | zmq/tests/test_device.py | Python | lgpl-3.0 | 5,710 | [
"Brian"
] | cf871699d6ac55f9d517a6f88d387dc7c3a801184556f173cdbca8c732230bc4 |
# Python modules
import pickle
import re
import string
from os import listdir, mkdir, path
from shutil import copyfile
from StringIO import StringIO
from time import time, localtime, strftime
# Python extension modules (requires extension installations)
import numpy as np
import pandas as pd
from patsy.bui... | GlobalEcologyLab/SARDM | MpFileExtractorAndGeneratorHelper.py | Python | gpl-3.0 | 99,594 | [
"Gaussian"
] | f3e69dc5497d39546e8f4f9a4c68938390dec25f7cc11e2c7246148fdcaa0d70 |
from __future__ import division, print_function
from __future__ import absolute_import
from __future__ import unicode_literals
import os, sys
import pysces, scipy
import scipy.io
import gc
from time import sleep
class Intersect:
dtype = scipy.double
def __init__(self, mod, data_dir):
self.mod = mod
... | bgoli/pysces | pysces/sandbox/Intersect.py | Python | bsd-3-clause | 12,084 | [
"PySCeS"
] | 85d63343959b6692b0afdb46bc2df5471dcbf64aac49d7bfa555af90a673ac94 |
#* 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/lgpl-2.1.html
"""Defines ... | nuclear-wizard/moose | python/MooseDocs/base/readers.py | Python | lgpl-2.1 | 6,423 | [
"MOOSE"
] | 30244458ad6a8835476ad7f8d49ecc86c0ca0b19ceba02ce0521a9071c50e246 |
"""
Module for managing data transfer jobs.
"""
import logging, urllib2, re, shutil
from galaxy import eggs
from sqlalchemy import and_
from galaxy.util.odict import odict
from galaxy.workflow.modules import module_factory
from galaxy.jobs.actions.post import ActionBox
from galaxy.jobs.deferred import FakeTrans
from... | mikel-egana-aranguren/SADI-Galaxy-Docker | galaxy-dist/lib/galaxy/jobs/deferred/data_transfer.py | Python | gpl-3.0 | 24,639 | [
"Galaxy"
] | 25ba3affa80c48e64b08b3060b2b264e3cd6119ab9c55fbb4d952511bc0dca08 |
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# --- BEGIN_HEADER ---
#
# logger - [insert a few words of module description on this line]
# Copyright (C) 2003-2011 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 ... | heromod/migrid | mig/grsfs-fuse/fs/core/specialized/logger.py | Python | gpl-2.0 | 3,401 | [
"Brian"
] | 7f477f2aa0eadf0e49c1535fa32d7cd6c568e7842024f2a75ef3e079a0686434 |
# Copyright 2014 PerfKitBenchmarker Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appli... | GoogleCloudPlatform/PerfKitBenchmarker | perfkitbenchmarker/linux_benchmarks/speccpu2006_benchmark.py | Python | apache-2.0 | 4,258 | [
"GAMESS",
"Gromacs",
"NAMD"
] | 5c6ac1349f8e70d3619ed44f6ebfe10d4fa3eb78994b4a5420bfcfe04f5704e3 |
'''
synbiochem (c) University of Manchester 2015
synbiochem is licensed under the MIT License.
To view a copy of this license, visit <http://opensource.org/licenses/MIT/>.
@author: neilswainston
'''
| neilswainston/development-py | synbiochemdev/test/__init__.py | Python | mit | 203 | [
"VisIt"
] | 5ded3ea5fc7da3a78d47b020a1d4519da38bc0f2c240b8c5b5a172e94a1aed39 |
"""
creates the pyNastranGUI
"""
# coding: utf-8
# pylint: disable=C0111
from __future__ import division, unicode_literals, print_function
#from six import string_types, iteritems
from six.moves import range
# standard library
import sys
import os.path
#import traceback
#import webbrowser
#webbrowser.open("http://xkcd... | saullocastro/pyNastran | pyNastran/gui/gui.py | Python | lgpl-3.0 | 10,230 | [
"VTK"
] | 6c038faf1f2fe475192110d651a2a4e8d1521f8e514948889aaa57f57db3b52b |
#!/usr/bin/env python
"""
ugrid classes
set of classes for working with unstructured model grids
The "ugrid" class is the base class: it stores everything in memory
It can read from and write to netcdf files in the UGRID format.
It may be able to reference a netcdf file at some point, rather than storing
directly ... | rsignell-usgs/notebook | pyugrid/pyugrid/ugrid.py | Python | mit | 30,355 | [
"NetCDF"
] | 8764ed028a859590c51073220df7d9930030deda020e429dc4eb3c0afe80f85a |
#!/usr/bin/python
#=============================================================================================
# MODULE DOCSTRING
#=============================================================================================
"""
Test 'yank prepare'.
"""
#===========================================================... | jchodera/yank | Yank/tests/test_prepare.py | Python | lgpl-3.0 | 3,475 | [
"Amber",
"Gromacs"
] | a87eb6a1be1e78ea41c9fda6bdfa4111aba6bc2747136de0cacacf4d24f21948 |
# GeneaCrystal Copyright (C) 2012-2013
# Christian Jaeckel, <christian.doe@gmail.com>
# Frederic Kerber, <fkerber@gmail.com>
# Pascal Lessel, <maverickthe6@gmail.com>
# Michael Mauderer, <mail@michaelmauderer.de>
#
# GeneaCrystal is free software: you can redistribute it and/or modify
# it under the ... | MichaelMauderer/GeneaCrystal | geneacrystal/menus/boxes.py | Python | gpl-3.0 | 44,869 | [
"CRYSTAL"
] | 9aa45c3271d2cffdd8ee8923af0563baced61d8dec45965fb37190dae5de7240 |
# 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
#
# Unless required by appl... | sunqm/pyscf | pyscf/pbc/df/test/test_df_jk.py | Python | apache-2.0 | 13,047 | [
"PySCF"
] | 324c277d7b56d68014186d9f7e40bf6a8f5e22a74ff9aef67285c343f7c89be4 |
#***Kalman in 1D practice***
#Matrix object class is created by An Hoang (2015)
#This Kalman filter is a reproduction of Greg Czerniak's sample code (http://greg.czerniak.info/node/5),
#incorporating Udacity's ideas on Kalman Filtering in AI. Uses pylab (needs numpi and other related modules to graph)
#---------------... | RedGeryon/Kalman_Voltmeter | Kalman1D.py | Python | gpl-2.0 | 10,123 | [
"Gaussian"
] | 8bbd9e39856f305fb87190e66c7347dadcf8a413ad2093abb78e6749a46645ae |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding:utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4
#
# MDAnalysis --- https://www.mdanalysis.org
# Copyright (c) 2006-2017 The MDAnalysis Development Team and contributors
# (see the file AUTHORS for the full list of names)
#
# Released under t... | MDAnalysis/mdanalysis | package/MDAnalysis/analysis/lineardensity.py | Python | gpl-2.0 | 8,512 | [
"MDAnalysis"
] | a287349448b64b3c97dfd3f31a22a7319ef29d4a7116a5fad235d0369050e973 |
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
Some reimplementation of Henkelman's Transition State Analysis utilities,
which are originally in Perl. Additional features beyond those offered by
Henkelman's utilities will be added.
This allows the usage and customizat... | materialsproject/pymatgen | pymatgen/analysis/transition_state.py | Python | mit | 15,974 | [
"VASP",
"pymatgen"
] | fbf21c116fc5f3930cfc7ef83839b4187a8dd18415aead075e3cbb767ff27f1d |
# -*- coding: utf-8 -*-
# This script runs both in 2.X and 3.X
from __future__ import print_function
import argparse
import os
import glob
import re
import sys
# Data sources from http://www-01.sil.org/iso639-3/iso-639-3.tab
# Included here for self-containment and compactness
# Thank you, sil.org
lang_data=u"""\
Id... | UniversalDependencies/tools | create_iso_639_3_symlinks.py | Python | gpl-2.0 | 179,873 | [
"ADF",
"ASE",
"BWA",
"Elk",
"MOE",
"MOOSE",
"VMD",
"xTB"
] | 983b888062407a39ad47fd4074bb4aa9a33dff16bda3f487e12223b12a21d492 |
import csv, logging, types, re, json, itertools, sys
import numpy as np
import openbabel
from StringIO import StringIO
from optparse import OptionParser
R = 8.31e-3 # kJ/(K*mol)
default_T = 298.15 # K
default_pH = 7.0
GROUP_CSV = StringIO(""""NAME","PROTONS","CHARGE","MAGNESIUMS","SMARTS","FOCAL_ATOMS","REMARK","SKIP... | almut-heinken/cobratoolbox | src/analysis/thermo/groupContribution/new/inchi2gv_new_groups.py | Python | gpl-3.0 | 66,229 | [
"Pybel",
"VisIt"
] | 2144b5c24b8443414720e438c2c8f53d59812705b864cfffc25ffd8b9fbe598f |
import unittest
import numpy
import chainer
from chainer.backends import cuda
from chainer import functions
from chainer import gradient_check
from chainer import testing
from chainer.testing import attr
@testing.parameterize(*testing.product({
'shape': [(3, 2), ()],
}))
class TestGaussian(unittest.TestCase):
... | aonotas/chainer | tests/chainer_tests/functions_tests/noise_tests/test_gaussian.py | Python | mit | 3,179 | [
"Gaussian"
] | d5188eaca17ee7919219aeea79b80f2cafe41e1b08a675f6ad36b5bedb6a2510 |
#! /usr/bin/env python
# vi:ts=4:tw=78:shiftwidth=4:expandtab
# vim600:fdm=marker
#
# orngMaxent.py - Python interface of the C++ MaxEnt for Orange lib
#
# Copyright (C) 2004 by Zhang Le <ejoy@users.sourceforge.net>
# Begin : 01-Nov-2004
# Last Change : 11-Jan-2005.
#
# This program is free software; ... | luuik/maxent | python/orange/orngMaxent.py | Python | lgpl-2.1 | 5,629 | [
"Gaussian"
] | f576d3ebb3753f3a4344cbf4216fbfc694fa9a650a2ee923bf34ef5d5e7da7bb |
""" Module for dealing with VOMS (Virtual Organization Membership Service)
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
__RCSID__ = "$Id$"
import os
import stat
import tempfile
import shutil
from DIRAC import S_OK, S_ERROR, gConfig, rootPath, gLogge... | yujikato/DIRAC | src/DIRAC/Core/Security/VOMS.py | Python | gpl-3.0 | 12,682 | [
"DIRAC"
] | 39cf4630252f8d733b1c470aa6ae9684e8d63001b9115287fea7287944ac9195 |
#!/usr/bin/env python2.7
"""
Shared stuff between different modules in this package. Some
may eventually move to or be replaced by stuff in toil-lib.
"""
import argparse, sys, os, os.path, random, subprocess, shutil, itertools, glob
import json, timeit, errno
import fcntl
import select
import time
import threading
fr... | vgteam/toil-vg | src/toil_vg/vg_common.py | Python | apache-2.0 | 49,989 | [
"BWA"
] | b7cbf4f81eaf9cdf54da3e88450ff2a43fe1573405f6d7e3c0fae3c7e2a7aa43 |
"""
This module defines export functions for decision trees.
"""
# Authors: Gilles Louppe <g.louppe@gmail.com>
# Peter Prettenhofer <peter.prettenhofer@gmail.com>
# Brian Holt <bdholt1@gmail.com>
# Noel Dawe <noel@dawe.me>
# Satrajit Gosh <satrajit.ghosh@gmail.com>
# Licence: BSD 3 ... | chaluemwut/fbserver | venv/lib/python2.7/site-packages/sklearn/tree/export.py | Python | apache-2.0 | 4,627 | [
"Brian"
] | a36edc401cc43796204189685a216f614b8c10e3bdaf26e3e09de4b2d5a3b8d5 |
#!/usr/bin/env python
#pylint: disable=missing-docstring
#################################################################
# DO NOT MODIFY THIS HEADER #
# MOOSE - Multiphysics Object Oriented Simulation Environment #
# #... | yipenggao/moose | python/chigger/tests/colorbar/colorbar_top.py | Python | lgpl-2.1 | 1,250 | [
"MOOSE"
] | 7e10e0f8d8169714ec50a1fda10c69cd6eab9b79690a799dc42e63d4b4126ab6 |
import unittest
from test import support
from itertools import *
import weakref
from decimal import Decimal
from fractions import Fraction
import operator
import random
import copy
import pickle
from functools import reduce
import sys
import struct
import threading
maxsize = support.MAX_Py_ssize_t
minsize = -maxsize-1
... | kikocorreoso/brython | www/src/Lib/test/test_itertools.py | Python | bsd-3-clause | 102,301 | [
"GULP"
] | 40709b1de50ae369ae0b5cc0f8f86f3bc4604e77229f63af81eac97b68f8b9dd |
"""Contains functions for making alignments between functional data and the surface, or, finding where the brain is.
"""
import os
import numpy as np
from builtins import input
import warnings
def manual(subject, xfmname, reference=None, **kwargs):
"""Open GUI for manually aligning a functional volume to the corti... | gallantlab/pycortex | cortex/align.py | Python | bsd-2-clause | 16,985 | [
"Mayavi"
] | dc1b2d808d8e9cfa99f9c2d6f684c9c535ef81f91b3685f30a592dddc0aa6e26 |
import click
from parsec.cli import pass_context, json_loads
from parsec.decorators import custom_exception, text_output
@click.command('delete_dataset')
@click.argument("history_id", type=str)
@click.argument("dataset_id", type=str)
@click.option(
"--purge",
help="if ``True``, also purge (permanently delete)... | galaxy-iuc/parsec | parsec/commands/histories/delete_dataset.py | Python | apache-2.0 | 823 | [
"Galaxy"
] | 0d920b2faa59ec0a6f19ba39ead53d8485fd89a4a4ea1dc13921cc3cd91dce0f |
# encoding:utf-8
'''
Exemplo Árvore Trie
Referências:
http://biopython.org/DIST/docs/api/Bio.trie-module.html
http://biopython.org/DIST/docs/api/Bio.triefind-module.html
https://www.youtube.com/watch?v=9U0ynguwoNA
http://bioinformatics.cvr.ac.uk/blog/trie-data-structure/
'''
from Bio.trie import trie
from Bio im... | marcoscastro/pybr11 | codigos/18_trie.py | Python | gpl-2.0 | 748 | [
"Biopython"
] | b585271e2cd2d2b676b665045b83f4a774dd17bd5f82c12a80fee3411863d980 |
from asp.codegen.ast_tools import *
from tinycu_sm import *
import asp.codegen.python_ast as ast
class TinyCuFrontend(NodeTransformer):
def __init__(self, should_trace=False):
super(TinyCuFrontend, self).__init__()
self.should_trace = should_trace
def parse(self, tree, rettype="double", locals... | richardxia/asp-multilevel-debug | specializers/tinycu/tinycu_frontend.py | Python | bsd-3-clause | 2,334 | [
"VisIt"
] | da00a121d0325f053df48ee44eafd6fca1e84b138003ad337382ed21a5041b1c |
"""
Collection of filters
"""
from scipy import signal
from scipy.interpolate import interp1d
import numpy as np
def smooth_data(y, window_size=None, order=2):
"""
Smooths data using the Savitzy Golay filter
Has some decent defaults
"""
if window_size is None:
# needs to be odd
w... | rohanisaac/spectra | spectra/filters.py | Python | gpl-3.0 | 3,539 | [
"Gaussian"
] | 460c7cb7600b4cd7971be61a1a6e3e212234f0f6ebb7492c4a2285ffbf3a2a19 |
# -*- mode: python; -*-
##
## Main MISO interface
##
import os
import csv
import time
import sys
import subprocess
from collections import defaultdict
import pysam
import misopy
import misopy.gff_utils as gff_utils
import misopy.as_events as as_events
import misopy.run_miso as run_miso
import misopy.misc_utils as mis... | kdaily/altanalyze | misopy/miso.py | Python | apache-2.0 | 25,560 | [
"pysam"
] | ec5946bcc21dff0a29faaf47dbb286b44cbeabc01480b97e5b27e873c91f08f8 |
from collections import deque, defaultdict
import itertools
from boltons.iterutils import chunked
from cycler import cycler
from lmfit.models import GaussianModel, LinearModel
import numpy as np
from .run_engine import Msg
from .utils import Struct, snake_cyclers
class ScanBase(Struct):
"""
This is a base cla... | sameera2004/bluesky | bluesky/scans.py | Python | bsd-3-clause | 28,436 | [
"Gaussian"
] | 6e27fe8d5ba7c4b175e1920000717d9d0da8916bc53150a0ec04e84827d78368 |
# 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,
FI... | FFMG/myoddweb.piger | monitor/api/python/Python-3.7.2/Lib/concurrent/futures/__init__.py | Python | gpl-2.0 | 1,497 | [
"Brian"
] | e6482d6b3bdb6e68156cbfd49b98564ddecd7655bed04542b449bab1813e25a8 |
import media
import fresh_tomatoes
# Avatar Movie: title, storyline, poster, movie trailer, and rating
avatar = media.Movie(
"Avatar",
"A marine on an alien planet",
"http://upload.wikimedia.org/wikipedia/id/b/b0/Avatar-Teaser-Poster.jpg",
"https://www.youtube.com/watch?v=5PSNL1qE6VY",
"PG-13")
# ... | jerseyhokie/Movie_Trailer_Website | entertainment_center.py | Python | mit | 3,081 | [
"Galaxy"
] | ad57f6e49cb66e46fb3067d577830981dfccc1e703bf71b8b422148ebdcd3851 |
# This script is executed in the main console namespace so
# that all the variables defined here become console variables.
import ddapp
import os
import sys
import PythonQt
import json
from PythonQt import QtCore, QtGui
from time import time
import imp
import ddapp.applogic as app
from ddapp import drcargs
from ddapp... | mithrandir123/director | src/python/ddapp/startup.py | Python | bsd-3-clause | 38,346 | [
"VTK"
] | d688815574c81942d9b48b27e2c5f534cdf004a7f939603f05be4bed351ef059 |
# GromacsWrapper: scaling.py
# Released under the GNU Public License 3 (or higher, your choice)
# See the file COPYING for details.
"""
:mod:`gromacs.scaling` -- Partial tempering
===========================================
:Author: Jan Domanski, @jandom
.. versionadded:: 0.5.0
Helper functions for scaling gromacs... | jandom/GromacsWrapper | gromacs/scaling.py | Python | gpl-3.0 | 9,869 | [
"Gromacs"
] | e220ed59566ad107c2e121e26d63a003cbd93c555ed569bb25045f5b61b2217e |
# Copyright 2021, The TensorFlow Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed t... | tensorflow/privacy | tensorflow_privacy/privacy/dp_query/tree_range_query.py | Python | apache-2.0 | 11,211 | [
"Gaussian"
] | 46e36c8cb2ee765d7cef97889b05fdc5e2a41271b9afdbece32df1c848fb91c0 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import time
from preggy import expect
from octopus.cache import Cache
from tests import TestCase
class TestCache(TestCase):
def test_can_create_cache(self):
cache = Cache(expiration_in_seconds=45)
expect(cache.expiration_in_seconds).to_equal(45)
... | heynemann/octopus | tests/test_cache.py | Python | mit | 1,056 | [
"Octopus"
] | 29aadcfccb199418eadbbf121832e975de8e2ca42ae3f0827f7c1f5a148bd92a |
"""This module contains the "Viz" objects
These objects represent the backend of all the visualizations that
Superset can render.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import copy
import hashlib
import l... | robert-digit/superset | superset/viz.py | Python | apache-2.0 | 50,659 | [
"VisIt"
] | 5d91c1a3b996cf7d2670b37ccc71f5f3ec20a63d1e2bf595e752830acc26050a |
from .utilities import *
from .mask import *
import numpy as np
def region_laplacian(mask, d = 3):
'''
Generate the laplacian matrix for a given region's voxels. This is the
graph laplacian of the neighborhood graph.
Parameters
----------
mask
Returns
-------
L: num voxel x n... | kharris/allen-voxel-network | voxnet/matrices.py | Python | bsd-2-clause | 30,068 | [
"Gaussian"
] | bc47b4bd54b2e47e18f0202b8083ea5b30ff673f5ae0205d9d8cd1bd28b60bab |
# pylint: disable=C0111
# pylint: disable=W0621
from lettuce import world, step
from nose.tools import assert_false, assert_equal, assert_regexp_matches # pylint: disable=E0611
from common import type_in_codemirror, press_the_notification_button, get_codemirror_value
KEY_CSS = '.key h3.title'
DISPLAY_NAME_KEY = "Cou... | dsajkl/reqiop | cms/djangoapps/contentstore/features/advanced_settings.py | Python | agpl-3.0 | 5,052 | [
"VisIt"
] | d171c9618de0cbbd8b90174522641a4614479b04bd8d8a6171b5680539ca8ac9 |
import sys, time
import os
import ccinit
import cclib
from instruction import *
ccinit.attach() # attach to transmod
ccinit.fastmode(False)
cclib.settimer(1000) # set timer event (1000ms interval)
cclib.logmask(0x1f)
cclib.write(ITMC_SYSCD, ITMS_LOGLV, 0x1f, '', 1)
while 1:
# receive eve... | skywind3000/cannon | cannon/channel/echoserver/echosvr.py | Python | apache-2.0 | 927 | [
"cclib"
] | 4daf63b1c791b28b7cf78c6c19815ac8bf987cdc130d01bc0a5091eee2f330b7 |
#!/usr/bin/env python
# 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.
"""Code for doing logistic regressions.
Classes:
LogisticRegression Holds information for a LogisticRegression classifier.
... | Ambuj-UF/ConCat-1.0 | src/Utils/Bio/LogisticRegression.py | Python | gpl-2.0 | 4,537 | [
"Biopython"
] | 82b519249a5d3ec7fa352592c5e2cb1e1090375320fc17ed2cbc4f537436b5b8 |
########################################################################
# File : SSHComputingElement.py
# Author : Dumitru Laurentiu, A.T.
########################################################################
""" SSH (Virtual) Computing Element: For a given IP/host it will send jobs directly through ssh
"""
from... | yujikato/DIRAC | src/DIRAC/Resources/Computing/SSHComputingElement.py | Python | gpl-3.0 | 28,695 | [
"DIRAC"
] | efaf7a9ec2a213fa9eb824cafcc6edac9167a4982d9712609356c2b7920e6bed |
from __future__ import absolute_import
from __future__ import print_function
from argparse import ArgumentParser, RawTextHelpFormatter
from typing import Any
from django.conf import settings
from django.core.management.base import BaseCommand
from django.db import ProgrammingError
from confirmation.models import gener... | christi3k/zulip | zerver/management/commands/generate_realm_creation_link.py | Python | apache-2.0 | 1,760 | [
"VisIt"
] | fa98ba7da1857769670cf11499170e229d1d0a84e08ed37ade8f1b197c84b88e |
"""
********************************************************************************
Learn Python the Hard Way Third Edition, by
Zed A. Shaw
ISBN: 978-0321884916
********************************************************************************
"""
# A mini-console game; to be completed
import time #modu... | msnorm/projects | zspy2/ex36/ex36.py | Python | mit | 8,354 | [
"VisIt"
] | 222c9a7246156680b33462ba9d984916f0994698ca0ca7a3933948e114265123 |
import os
from socket import gethostname
import time
import urllib
from uuid import getnode as getmac
import webbrowser
import httplib2 # included with oauth2client
from oauth2client.client import OAuth2WebServerFlow, TokenRevokeError
import oauth2client.file
import gmusicapi
from gmusicapi.clients.shared import _Ba... | KMarshland/MusicSync | gmusicapi/clients/musicmanager.py | Python | bsd-3-clause | 24,758 | [
"VisIt"
] | 3ab75dd1e51ee20e5cb182482b25e70fb5a7f9ce298ba051fb545eedac8b7da6 |
#!/usr/bin/env python
#
# Protein Engineering Analysis Tool DataBase (PEATDB)
# Copyright (C) 2010 Damien Farrell & Jens Erik Nielsen
#
# 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 ver... | dmnfarrell/peat | PEATDB/Actions.py | Python | mit | 32,057 | [
"PyMOL",
"RasMol",
"VMD",
"YASARA"
] | 4938be4a3c4be6de16329ff35f7cec39c2cf385921485bc1957741dd59b183c6 |
"""Useful utility methods for GTK."""
# Copyright (C) 2009, Thomas Leonard
# See the README file for details, or visit http://0install.net.
import gtk
import sys
from zeroinstall import _
class Template(object):
"""Wrapper for GtkBuilder widget tree that throws a sensible exception if the widget isn't found."""
de... | turtledb/0install | zeroinstall/gtkui/gtkutils.py | Python | lgpl-2.1 | 4,385 | [
"VisIt"
] | 1703f50c9ad860954b9643700f6c613f70c57f45dfe8b855d4a4f03ea77dcc72 |
#!/usr/bin/env python
from __future__ import print_function, division, unicode_literals
__version__ = "0.1.0"
__author__ = "Matteo Giantomassi"
import sys
import os
import argparse
import logging
logger = logging.getLogger(__name__)
# We don't install with setup.py hence we have to add the directory [...]/abinit/te... | jmbeuken/abinit | tests/Scripts/ncheck.py | Python | gpl-3.0 | 5,358 | [
"ABINIT",
"NetCDF"
] | 7c629a5be9fff91dd1a461f6b1e9b0a6a51a0aeeb3af7c1da9c34dcbc423c931 |
# -*- coding: utf-8 -*-
# <nbformat>3.0</nbformat>
# <codecell>
import os
import cmath
import math
import sys
import numpy as np
import glob
import subprocess
import re
from matplotlib_venn import venn2
import pandas as pd
from collections import defaultdict
from operator import itemgetter
import matplotlib as mpl
i... | enguy/FAST-iCLIP | bin/oldscripts/Fastclip_mm9_old.py | Python | gpl-2.0 | 62,409 | [
"Bowtie"
] | 18ce0230c3e7b8c2f30396c91c541c349f42aeebb49e811fcd4756064f49557f |
#!/usr/bin/env python3
############################################################################
#
# MODULE: i.cutlinesmod
# AUTHOR(S): Moritz Lennert, with help of Stefanos Georganos, modified by
# Piero Toffanin
#
# PURPOSE: Create tiles the borders of which do not cut across semantically
# ... | OpenDroneMap/OpenDroneMap | opendm/grass/addons/i.cutlinesmod.py | Python | gpl-3.0 | 22,306 | [
"Gaussian"
] | 671820450161a3135ce143496e28e86266afd2584a035ccac70fc501f4e63cb3 |
import sys
sys.path.append('/usr/local/lib/python2.7/dist-packages')
from flask import Flask, jsonify, render_template, request
import nest
import os
import json
import anyjson
import helpers as hh
app = Flask(__name__)
@app.template_filter('neurons')
def neurons_filter(nodes):
return filter(lambda node: 'gener... | babsey/nest-webapp | multiple_neurons_mm.py | Python | mit | 3,984 | [
"NEURON"
] | eb1e9f8c7a3de9ed1bc1b4e5f3c62a52e806f79dd1bfa487f71485c00633dcf5 |
#
# @file TestSBMLConvert.py
# @brief SBMLConvert unit tests
#
# @author Akiya Jouraku (Python conversion)
# @author Ben Bornstein
#
# ====== WARNING ===== WARNING ===== WARNING ===== WARNING ===== WARNING ======
#
# DO NOT EDIT THIS FILE.
#
# This file was generated automatically by converting the file locate... | TheCoSMoCompany/biopredyn | Prototype/src/libsbml-5.10.0/src/bindings/python/test/sbml/TestSBMLConvert.py | Python | bsd-3-clause | 16,751 | [
"VisIt"
] | 429c6adbdbe1ca48b3b76e4e5931efd3c8576e56a4621c2384e1d38758925e32 |
#!/usr/bin/env python3
# ******************************************************************************
# $Id: pct2rgb.py 124baa7f71f15396a661014a81b6c5b0c82c8004 2020-10-14 17:29:39 +0300 Idan Miara $
#
# Name: pct2rgb
# Project: GDAL Python Interface
# Purpose: Utility to convert paletted images into RGB (o... | grueni75/GeoDiscoverer | Source/Platform/Target/Android/core/src/main/jni/gdal-3.2.1/swig/python/osgeo/utils/pct2rgb.py | Python | gpl-3.0 | 7,441 | [
"NetCDF"
] | 30987656206f50099e759fc2799df991066bb017a17175eb60f88dc34934f9ca |
#! /usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright 2022 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 requi... | googleapis/python-scheduler | scripts/fixup_scheduler_v1beta1_keywords.py | Python | apache-2.0 | 6,223 | [
"VisIt"
] | b5682ec611fcec61a211cf58d5df41b32e99091302ecf54c828f7678f5ea1a00 |
#!/usr/bin/env python
#
# @file swigdoc.py
# @brief Creates documentation for C#, Java, Python, and Perl.
# @author Ben Bornstein
# @author Christoph Flamm
# @author Akiya Jouraku
# @author Michael Hucka
# @author Frank Bergmann
#
# $Id: swigdoc.py 10124 2009-08-28 12:04:51Z sarahkeating $
# $HeadURL: https://sbml.s... | alexholehouse/SBMLIntegrator | libsbml-5.0.0/src/bindings/swig/swigdoc.py | Python | gpl-3.0 | 47,330 | [
"VisIt"
] | cbd7d0989df93fdabcb84ca9011c63dce51feb89ceae2a3ad006916984ac1421 |
'''
Created on Feb 18, 2016
@author: ssudholt
'''
import numpy as np
import cv2
class AugmentationCreator(object):
'''
classdocs
'''
def __init__(self):
'''
Constructor
'''
pass
@staticmethod
def create_affine_transform_augmentation(img, random_limits=(0.8... | ssudholt/phocnet | src/phocnet/caffe/augmentation.py | Python | bsd-3-clause | 9,205 | [
"Gaussian"
] | db47cb0e951bad9bbf149675501b7e9d9378981b46925c7a9ef2e88f8daacad1 |
#!/usr/bin/env python
from setuptools import setup
import versioneer
commands = versioneer.get_cmdclass().copy()
setup(name="ecdsa",
version=versioneer.get_version(),
description="ECDSA cryptographic signature library (pure python)",
author="Brian Warner",
author_email="warner@lothar.com",
... | nedn/pybitcoin | third_party/python-ecdsa/setup.py | Python | mit | 989 | [
"Brian"
] | d1d3f1e164b1b5bef06f49e3b6640eeed7eaa358df9a6112157e6c6b50ba2428 |
import json
from random import choice, sample, randint
from plugincon import bot_command, easy_bot_command, get_message_target, get_bot_nickname, reload_all_plugins
def percent_chance(percentage):
trandom = randint(0, 100)
print trandom
return percentage >= trandom and percentage > 0
@easy_bot_command("hack")
d... | Gustavo6046/GusBot-2 | pluginbackup/funny.py | Python | mit | 14,312 | [
"Galaxy"
] | 971d6f0ea046c57be2d7d22e7d50f439a99ae88467b9b2204e393857163ce1b6 |
#!/usr/bin/python
# (c) 2013, Cove Schneider
# (c) 2014, Joshua Conner <joshua.conner@gmail.com>
# (c) 2014, Pavel Antonov <antonov@adwz.ru>
#
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = t... | Tatsh-ansible/ansible | lib/ansible/modules/cloud/docker/_docker.py | Python | gpl-3.0 | 74,503 | [
"VisIt"
] | d455497471d85a1dd5b43875b7f83b373cb195517d80a7e0cdf5a5c9822cf6d3 |
#!/usr/bin/env python
# $HeadURL: svn+ssh://svn.cern.ch/reps/dirac/DIRAC/trunk/DIRAC/Core/scripts/dirac-install.py $
"""
Do the initial installation and configuration of the DIRAC MySQL server
"""
__RCSID__ = "$Id: dirac-install.py 26844 2010-07-16 08:44:22Z rgracian $"
#
from DIRAC.Core.Base import Script
Script.disab... | avedaee/DIRAC | Core/scripts/dirac-stop-component.py | Python | gpl-3.0 | 1,357 | [
"DIRAC"
] | 272de604be2c048be66fed145338dafe2db4b555b71b81658c63aa94b9905d4d |
import sys
sys.path.insert(1,"../../../")
import h2o
from tests import pyunit_utils
def cars_checkpoint():
cars = h2o.upload_file(pyunit_utils.locate("smalldata/junit/cars_20mpg.csv"))
predictors = ["displacement","power","weight","acceleration","year"]
response_col = "economy"
distribution = "gaussi... | pchmieli/h2o-3 | h2o-py/tests/testdir_algos/gbm/pyunit_NOPASS_error_checkpointGBM.py | Python | apache-2.0 | 2,547 | [
"Gaussian"
] | 60975bb3f9b3dc7dd6136a9fc130d5f9fdbfc9e930101f2b78749c52803e88ba |
#!/usr/bin/env python2
from moke import *
from itertools import izip, chain
from multiprocessing import Pool
import pickle
import numpy as np
import scipy.stats as ss
from sklearn import decomposition, cross_validation, grid_search, linear_model, metrics
from sklearn.decomposition.nmf import nnls
from pysam import Sam... | mcieslik-mctp/epicode | bin/epicode.py | Python | mit | 26,899 | [
"pysam"
] | 708c401609bf7e8ce6396a69690677195ed8fa7a5c9b812e5a3007a439aba088 |
# vim: set et sw=4 sts=4 fileencoding=utf-8:
#
# Copyright 2014 Dave Jones <dave@waveform.org.uk>.
#
# This file is part of umansysprop.
#
# umansysprop 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 v... | waveform80/umansysprop | umansysprop/forms.py | Python | gpl-2.0 | 28,540 | [
"Pybel"
] | 9fcb6436c6cdf21d5c72c1e39c9714016d85dac815daf73338146d756e5e1c6b |
"""Models for the ``frequently`` app."""
from django.conf import settings
from django.db import models
from django.urls import reverse
from django.utils.encoding import python_2_unicode_compatible
from django.utils.translation import ugettext_lazy as _
from ckeditor.fields import RichTextField
@python_2_unicode_comp... | bitmazk/django-frequently | frequently/models.py | Python | mit | 5,486 | [
"VisIt"
] | 1652b4bbf5f2bf24961b47e32f00a734cd64d70986cf34ca8356f0216b44798e |
# #
# Copyright 2013-2019 Ghent University
#
# This file is part of EasyBuild,
# originally created by the HPC team of Ghent University (http://ugent.be/hpc/en),
# with support of Ghent University (http://ugent.be/hpc),
# the Flemish Supercomputer Centre (VSC) (https://www.vscentrum.be),
# Flemish Research Foundation (... | gppezzi/easybuild-framework | test/framework/options.py | Python | gpl-2.0 | 210,770 | [
"NetCDF"
] | d4796292482ddfcd9df28cacbcc697ed9b2f183fdf348e607755f0d921894d39 |
# -*- coding: utf-8 -*-
#BEGIN_HEADER
import simplejson
import sys
import shutil
import os
import ast
import glob
import json
import uuid
import numpy
import logging
import time
import subprocess
import threading, traceback
import multiprocessing
from collections import OrderedDict
from pprint import pprint,pformat
imp... | kbaseIncubator/KBaseRNASeq | lib/biokbase/RNASeq/KBaseRNASeqImpl.py | Python | mit | 52,750 | [
"Bowtie"
] | 88cd513b8414fc19e9b3e79316ed7112365f636292820c549817129832723029 |
#!/usr/bin/env python
# coding=utf8
#
# Copyright (c) Jakub Olczyk
# Published under GNU General Public License version 2 or above
# For full text of the license visit www.gnu.org/licenses/gpl.html
from src.Editor import Editor
import sys
def main(argv):
file_to_open = ''
if not (sys.argv[0] == 'minivimtuto... | jakub-olczyk/miniVim | main.py | Python | gpl-3.0 | 872 | [
"VisIt"
] | 5cbcb7194ed14eaae798c489472529e61fb8b33b7a99d2deacbba5e8e1a41e56 |
import numpy as np
from . import config as ttconf
from .distribution import Distribution
class BranchLenInterpolator (Distribution):
"""
This class defines the methods to manipulate the branch length probability
distributions.
"""
def __init__(self, node, gtr, one_mutation=None, min_width=ttconf.... | neherlab/treetime | treetime/branch_len_interpolator.py | Python | mit | 6,385 | [
"Gaussian"
] | 01fee8ae48cf5e1618033abb65223fc97eeccb3a1a0d44ee0c4c0701a1f34a13 |
job_block = 50
import argparse
parser = argparse.ArgumentParser()
parser.add_argument('--job_block', default=job_block, type=int, \
help='Number of dockings per job')
parser.add_argument('--dry', action='store_true', default=False, \
help='Does not actually submit the job to the queue')
args = parser.parse_args(... | gkumar7/AlGDock | Pipeline/run_dock6_to_nc.py | Python | mit | 1,478 | [
"NetCDF"
] | 8798dbb173d6a75d44df51c0251b73a6fa35009f8c971ebbc9fbcec8d266f39d |
import time
import numpy as np
from ase.transport.tools import dagger
from ase.transport.selfenergy import LeadSelfEnergy
from ase.transport.greenfunction import GreenFunction
from ase.parallel import world
class STM:
def __init__(self, h1, s1, h2, s2 ,h10, s10, h20, s20, eta1, eta2, w=0.5, pdos=[], logfile = N... | grhawk/ASE | tools/ase/transport/stm.py | Python | gpl-2.0 | 7,525 | [
"ASE"
] | 0eabfa8f266f2e7e1ff9e1110c06ea28f494699bb1fc438bbe56803cb5545050 |
########################################################################
# $HeadURL$
########################################################################
from DIRAC.Core.Utilities.List import intListToString, stringListToString
""" DIRAC FileCatalog component representing a directory tree with
a closure table
... | miloszz/DIRAC | DataManagementSystem/DB/FileCatalogComponents/WithFkAndPs/DirectoryClosure.py | Python | gpl-3.0 | 19,034 | [
"DIRAC"
] | d8dc523955262e6ec725cb8fffb2bd783f0d6af89f308efb1713e3c719feeade |
from python.src.neurons.neurons import Neuron
from python.src.neurons.activation_functions.linear_activation import LinearActivation
class OutputOnlyNeuron(Neuron):
"""This nueron has no inbound connections and always fires the same value.
"""
def __init__(self, activation = LinearActivation()):
... | DomenicD/dom_ml_playground | python/src/neurons/output_only_neuron.py | Python | mit | 620 | [
"NEURON"
] | a97fe0f47b351f66af599267ffd4f6afaa35ffe95c7922aa7eb677f17345bc65 |
# -*- coding: utf-8 -*-
"""
<DefineSource>
@Date : Fri Nov 14 13:20:38 2014 \n
@Author : Erwan Ledoux \n\n
</DefineSource>
The Doer defines instances that are going to decorate a big family of classes in this framework.
Staying on the idea, that one module should associate
one class, now a decorated class by a Doe... | Ledoux/ShareYourSystem | Pythonlogy/ShareYourSystem/Standards/Classors/Doer/Drafts/__init__do.py | Python | mit | 18,509 | [
"Brian",
"VisIt"
] | 54af085e07dd9552d97704ea85241de1519d3025f20413aceb4107b349f724bf |
import steps.interface
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
#
# Okinawa Institute of Science and Technology, Japan.
#
# This script runs on STEPS 2.x http://steps.sourceforge.net
#
# H Anwar, I Hepburn, H Nedelescu, W Chen and E De Schutter
# Stochastic calcium mechanisms cause... | CNS-OIST/STEPS_Example | publication_models/API_2/Anwar_J_Neurosci_2013/extra/constants_withampa.py | Python | gpl-2.0 | 9,988 | [
"Avogadro"
] | c5e03d73dfb44f64d0ae04ca960215c666f827593b53ba7448acc0ba175e2910 |
from ase.data.molecules import molecule
from gpaw import GPAW
a = 8.0
h = 0.2
energies = {}
resultfile = open('results-%.2f.txt' % h, 'w')
for name in ['H2O', 'H', 'O']:
system = molecule(name)
system.set_cell((a, a, a))
system.center()
calc = GPAW(h=h,
txt='gpaw-%s-%.2f.txt' % (name... | qsnake/gpaw | doc/exercises/water/h2o.py | Python | gpl-3.0 | 644 | [
"ASE",
"GPAW"
] | c1efc2f36eb5754c5a68bd851954dc88fac456db5d4725e79b160bb4bb43c70c |
# iCraft is Copyright 2010 both
#
# The Archives team:
# <Adam Guy> adam@adam-guy.com AKA "Adam01"
# <Andrew Godwin> andrew@aeracode.org AKA "Aera"
# <Dylan Lukes> lukes.dylan@gmail.com AKA "revenant"
# <Gareth Coles> colesgareth2@hotmail.com... | TheArchives/Nexus | core/plugins/tracking.py | Python | bsd-2-clause | 14,495 | [
"VisIt"
] | 7707adbfc62a1c4e7edfacec97fec26e9d6300f45f9af50c7fad99fb1bc7bb2d |
""" The Script class provides a simple way for users to specify an executable
or file to run (and is also a simple example of a workflow module).
"""
import os
import sys
import re
import stat
import shlex
import distutils.spawn # pylint: disable=no-name-in-module,no-member,import-error
from DIRAC import gLogger... | arrabito/DIRAC | Workflow/Modules/Script.py | Python | gpl-3.0 | 5,017 | [
"DIRAC"
] | bd1440af6a313e8738204c33c35bec9b064bc2719e10daaea1c385b853cd4227 |
# -*- coding: utf-8 -*-
from __future__ import print_function, division
# This program is part of 'MOOSE', the
# Messaging Object Oriented Simulation Environment.
# Copyright (C) 2013 Upinder S. Bhalla. and NCBS
# It is made available under the terms of the
# GNU Lesser General Public License version 2.1
# S... | dilawar/moose-core | tests/core/test_steady_state_solver.py | Python | gpl-3.0 | 5,107 | [
"MOOSE"
] | 30adfe1de7382771bdb8a39ad912ebad20cab9870075f60e3f6d98b4042d2571 |
"""
Generalized linear models currently supports estimation using the one-parameter
exponential families
References
----------
Gill, Jeff. 2000. Generalized Linear Models: A Unified Approach.
SAGE QASS Series.
Green, PJ. 1984. "Iteratively reweighted least squares for maximum
likelihood estimation, and some ... | rgommers/statsmodels | statsmodels/genmod/generalized_linear_model.py | Python | bsd-3-clause | 45,667 | [
"Gaussian"
] | d24a788fc12556c2e71918fb1950be60d3be7c6811fdd054b0e911c026247cdf |
import fcntl
import os
import random
import requests
import shutil
import subprocess
import time
import heroku
from will.mixins import StorageMixin
from will.utils import Bunch
from will import settings
STACK_NAMES = [
"alder",
"ash",
"aspen",
"basswood",
"birch",
"buckeye",
"buckthorn",
... | buddyup/our-will | plugins/devops/mixins/servers.py | Python | mit | 22,667 | [
"Brian"
] | cb0c78b383406e97d085517f5f7d06109c50c765a2ca2233564c8ef809b54aeb |
import os
import unittest
from textwrap import dedent
from ctree.templates.nodes import StringTemplate, FileTemplate
from ctree.c.nodes import Constant, While
import fixtures
class TestStringTemplates(unittest.TestCase):
def _check(self, tree, expected):
actual = tree.codegen()
self.assertEqual(a... | ucb-sejits/ctree | test/test_templates.py | Python | bsd-2-clause | 4,480 | [
"VisIt"
] | 38f6f86fd84be0e726962f73afd22245f805a69abbd66fca3d32da04dcfdea45 |
# -*- coding: utf-8 -*-
"""
Models used to implement SAML SSO support in third_party_auth
(inlcuding Shibboleth support)
"""
from __future__ import absolute_import
import json
import logging
import re
from config_models.models import ConfigurationModel, cache
from django.conf import settings
from django.contrib.sites... | lduarte1991/edx-platform | common/djangoapps/third_party_auth/models.py | Python | agpl-3.0 | 33,094 | [
"VisIt"
] | d3e59daea08acbfb66ce5b61169648cd2859ca60b929314609da305e957dbfdf |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.