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 |
|---|---|---|---|---|---|---|---|
#!/usr/bin/python
# -*- coding: utf-8 -*-
# (c) Nelen & Schuurmans. GPL licensed, see LICENSE.rst.
"""
Created on Wed Feb 12 16:10:32 2014
Tom van Steijn, RHDHV
"""
import datetime as dt
import glob
import logging
import os
import sys
import psycopg2
import pandas as pd
from openradar import arguments
from openrad... | nens/openradar | openradar/scripts/report.py | Python | gpl-3.0 | 8,173 | [
"ASE"
] | 197a75107b0d7cbfc9248d83cb05abe0d0d4ecba0ad43e2f8b5709eff0b4919f |
#!/usr/bin/env python
#################################################
## PTDNN - Python Toolkit for Deep Neural Network
## Author: Yajie Miao
#################################################
import os
import sys
from utils.learn_rates import LearningRateExpDecay
class BnfExpConfig(object):
def __init__(self... | michellemorales/OpenMM | kaldi/egs/babel/s5d/conf/bnf/config_full.py | Python | gpl-2.0 | 3,202 | [
"Gaussian"
] | d70e82864404fb0dedd920f4a886a645c73e8cb3f5244cddb00a63539235c54c |
import pdb, sys, os, glob, pickle, time, re
import numpy as np
import scipy.ndimage
from bayes.pyhm_dev import pyhm
import numexpr
def residsRMSVsBinSize( thrs, resids ):
"""
Given an array of residuals, computes the rms as a function
of bin size. For checking how the noise bins down compared
to whit... | tomevans/wfc3 | UtilityRoutines.py | Python | mit | 25,934 | [
"Gaussian"
] | 8389a66702a3dfc5b308708c3caacdf183a2f039d6622891233b8c9b52d6b49f |
"""
Provide authentication using YubiKey.
.. versionadded:: 2015.5.0
:depends: yubico-client Python module
To get your YubiKey API key you will need to visit the website below.
https://upgrade.yubico.com/getapikey/
The resulting page will show the generated Client ID (aka AuthID or API ID)
and the generated API ke... | saltstack/salt | salt/auth/yubico.py | Python | apache-2.0 | 1,995 | [
"VisIt"
] | d676d6ced6a5e99bbee9c6e6cef18b07f3a66ce68c5bf2004dc4526cea7987ce |
import numpy
from scipy.special import expit, softmax
import math
'''
VMLP: Vectorised Multilayer Perceptron
a neuron is represented as a vector;
a the neural network is represented as an array of a matrix of vectors
this helps making the training process faster;
todo: use MinPy to leverage GPU suppor... | dakoto747/Machine-Learning-Algorithms | vmlp_multiclass.py | Python | mit | 15,305 | [
"NEURON"
] | 3e24fbf45a72123952f373d4a7dee9ec83a38954872119c62a710a9be2b9d0e3 |
# This module provides classes that represent graphics objects to be
# output to PyMOL. This module is as compatible as possible with module
# VRML. Important differences:
# - No general polygon objects (yet)
# - Only the 'diffuse color' attribute of materials is used for rendering.
#
# Written by: Konrad Hinsen <hinse... | OS2World/DEV-PYTHON-UTIL-ScientificPython | src/Lib/site-packages/Scientific/Visualization/PyMOL.py | Python | isc | 12,515 | [
"PyMOL"
] | 238bad0a55f2c30ceefcd735e13af23cc696dc4659c73ae5116492292ee669db |
"""
Efficient computation of kernels between between dense vectors of floats (double precision)
===========================================================================================
"""
from functools import wraps
import numpy as np
import numexpr as ne
from numpy import exp
from scipy import sparse
from .de... | daien/ekovof | ekovof/dense/dense_kernels.py | Python | mit | 18,000 | [
"Gaussian"
] | 7bd061ed7af7a8ca2a283e79568f31e146d65ee172b6fc0826db504873677a03 |
import random
import itertools
from scipy import linalg
import numpy as np
from sklearn.mixture import GaussianMixture as EM
import matplotlib.pyplot as plt
import matplotlib as mpl
from sklearn import mixture
color_iter = itertools.cycle(['navy', 'c', 'cornflowerblue', 'gold',
'darkoran... | GabrielTrev/ufscar-ammd-2016-2 | src/clustering/em/em.py | Python | mit | 6,227 | [
"Gaussian"
] | 89a8535b83d123aa0d1e0d13dd9bb303471dc597a4752dfba173b55d2c577c95 |
# -*- coding: utf-8 -*-
# Wake-On-LAN
#
# Parts of Code take from Copyright notice below
#
# Copyright (C) 2002 by Micro Systems Marc Balmer
# Written by Marc Balmer, marc@msys.ch, http://www.msys.ch/
# This code is free software under the GPL
"""
ORCA Open Remote Control Application
Copyright (C) 2... | thica/ORCA-Remote | src/interfaces/wake_on_lan/interface.py | Python | gpl-3.0 | 5,174 | [
"ORCA"
] | 836283e5d4eaad54a895af611430e7df6d64d7375c2e98308607bfcfc6939834 |
#
# Copyright (c) 2017 Intel Corporation
# SPDX-License-Identifier: BSD-2-Clause
#
"""
This module transforms data-parallel operations such as Numpy calls into
'Parfor' nodes, which are nested loops that can be parallelized.
It also implements optimizations such as loop fusion, and extends the rest of
compiler analysi... | cpcloud/numba | numba/parfors/parfor.py | Python | bsd-2-clause | 197,034 | [
"VisIt"
] | c73bbe8c3e3f332b7163250f42c54c9f7af6ddfeca6450d6bebb6b45d03cf0bf |
from django.contrib.auth.decorators import permission_required, login_required
from django.contrib.auth.models import User
from django.urls import reverse
from django.http import HttpRequest
from django.shortcuts import redirect, render_to_response, render
from django.utils.translation import ugettext as _
from django.... | fsr/course-management | course/views/course.py | Python | bsd-3-clause | 11,921 | [
"Galaxy"
] | 5402032148a56093f4e7954a4b5f73e7e240d27d0258f7138134664d1d9a356e |
"""Job Information"""
from pprint import pformat
from itertools import zip_longest
from DIRAC import gLogger
from DIRAC.ConfigurationSystem.Client.Helpers.Operations import Operations
from DIRAC.Core.Utilities.List import fromChar
ASSIGNEDSTATES = ["Assigned", "Processed"]
LOG = gLogger.getSubLogger(__name__)
clas... | DIRACGrid/DIRAC | src/DIRAC/TransformationSystem/Utilities/JobInfo.py | Python | gpl-3.0 | 10,749 | [
"DIRAC"
] | 91e394902095f94712b511e10da426f4469b9e4ed816d0f7de8aa11e5ba9a5c9 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright 2013 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-... | imzers/gsutil-with-php | gslib/__main__.py | Python | apache-2.0 | 27,740 | [
"VisIt"
] | 2b5f68d6182c8572ec251bd0e9aa46c77c74b07d32e1bf62d3d664315960464d |
# -*- coding: utf-8 -*-
"""Evaluators module of the nc2map package.
This module (currently) contains two evaluators of MapBase instances plus the
base class.
Classes are:
- EvaluatorBase: (Subclass of MapsManager). Base class for all evaluators
(this class itself does nothing but provide the general framework... | Chilipp/nc2map | evaluators.py | Python | gpl-2.0 | 32,393 | [
"NetCDF"
] | 194b4ddd215304d881b546c2a1ccd9eb25330fc34c3e6c4f0d76472c51b24a25 |
#!python
# Load libraries
import sys, getopt
import pysam
import libPipeline
# Set constants
helpMsg ='''
SYNOPSIS
parseSAMOutput
parseSAMOutput [OPTIONS] SAMFILE
#
DESCRIPTION
parseSAMOutput.py
Parses SAM alignments into paired-end read summaries.
Prints results to stdout.
If SAMFILE has a .sam or .S... | awblocker/paired-end-pipeline | parseSAMOutput.py | Python | apache-2.0 | 1,529 | [
"pysam"
] | 4f374396a2b786e31e20cc79aaf68f8649f592a7aced88e6af97a768772f8548 |
""" CSAPI exposes update functionalities to the Configuration.
Most of these functions can only be done by administrators
"""
from DIRAC import gLogger, gConfig, S_OK, S_ERROR
from DIRAC.ConfigurationSystem.Client.ConfigurationClient import ConfigurationClient
from DIRAC.Core.Utilities import List, Time
from DIRAC... | DIRACGrid/DIRAC | src/DIRAC/ConfigurationSystem/Client/CSAPI.py | Python | gpl-3.0 | 37,485 | [
"DIRAC"
] | 60c0fa886abe222f9fac40ebbca0b32f3f664760422b57f27b165be1edcfe87a |
"""Minimal Python 2 & 3 shim around all Qt bindings
DOCUMENTATION
Qt.py was born in the film and visual effects industry to address
the growing need for the development of software capable of running
with more than one flavour of the Qt bindings for Python - PySide,
PySide2, PyQt4 and PyQt5.
1. Bu... | stickypants/asset_manager | Qt.py | Python | gpl-3.0 | 49,017 | [
"VisIt"
] | 2842a9e3bcf6e3ebd066eed4a45990fa4af677847f1799f71c804ec0c6a36619 |
# This file is part of cclib (http://cclib.github.io), a library for parsing
# and interpreting the results of computational chemistry packages.
#
# Copyright (C) 2015, the cclib development team
#
# The library is free software, distributed under the terms of
# the GNU Lesser General Public version 2.1 or later. You s... | jchodera/cclib | test/test_writer.py | Python | lgpl-2.1 | 671 | [
"cclib"
] | 4740009206adf72fed156eeb209767343101ad7ee28bf2ba9a9a4b314fe44fe3 |
# Copyright (C) 2002, Thomas Hamelryck (thamelry@binf.ku.dk)
# 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.
# My Stuff
from PDBExceptions import PDBConstructionException
from Entity import Entity,... | NirBenTalLab/proorigami-cde-package | cde-root/usr/lib64/python2.4/site-packages/Bio/PDB/Residue.py | Python | mit | 4,942 | [
"Biopython"
] | aa08c1fa00ff3f09baa207a444f5b5bc35aae65fb6967ce5a671d4f395d4b33a |
'''
Created on 28/09/2012
@author: Amr Hassan
'''
import os
import sys
import struct
import string
import PGDBInterface
class SAGEDataReader:
#The Module handles the data reading from SAGE output to a memory data structure.
DebugToFile=False
CurrentFolderPath=""
CurrentGlobalTreeID=0
FormatMa... | IntersectAustralia/asvo-tao | core/sageimport_mpi/SAGEReader.py | Python | gpl-3.0 | 7,043 | [
"Galaxy"
] | 7a7441b652c8a910dd52ceff01c12458aadd075e373d6f5f913f42be5da58e78 |
import sys
from math import sqrt
from collections import namedtuple
import numpy as NP
import scipy.stats
def mad( l ):
"""Compute the median absolute deviation (a robust measure of spread) of the list of
values *l*."""
median = NP.median(l)
return NP.median([abs(x - median) for x in l])
def robust... | dataplumber/nexus | climatology/clim/util/stats.py | Python | apache-2.0 | 7,130 | [
"Brian"
] | bdb9ffb9206aafabc0841ffd354ac7b67b8e9dd083808cee61bb43bfd3fdd546 |
#!/usr/bin/env python
#
# $File: MapPenetrance.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 redistrib... | BoPeng/simuPOP | docs/MapPenetrance.py | Python | gpl-2.0 | 1,548 | [
"VisIt"
] | 85689bc988cf79e4645e909be64311e77a8d02c9c368f84f4565dd54bb28f3cd |
import random
def generate(ranges):
'''Generate a random float gtype based on ranges ((high, low) list)'''
return [random.uniform(high, low) for high, low in ranges]
def mutate_gaussian(gtype, ranges, prob, sigma):
'''Mutate a gtype by adding gaussian random values. Results are clipped to fit range.'''
... | imre-kerr/better-ea | delivery/ea/float_gtype.py | Python | mit | 2,398 | [
"Gaussian"
] | ad948e15e4be989305e1d3684e5dce09df084726cad3f00b2a2faf9777fe34a2 |
#!/usr/bin/env python
"""
Test creation of cone
@author alexander@gokliya.net
"""
from __future__ import print_function
import argparse
from icqsol.shapes.icqShapeManager import ShapeManager
from icqsol import util
parser = argparse.ArgumentParser(description='Create cone')
parser.add_argument('--output', type=str,... | gregvonkuster/icqsol | tests/testCreateCone.py | Python | mit | 1,629 | [
"VTK"
] | ee1b13e6458c4ff3f866b957da6861311f624d1c36677fd6c2ddce66a2b1a4fc |
from behave import *
import json
from app import server
@when(u'I visit the "home page"')
def step_impl(context):
context.resp = context.app.get('/')
@then(u'I should see "{message}"')
def step_impl(context, message):
assert message in context.resp.data
@then(u'I should not see "{message}"')
def step_impl(co... | NYU-DevOps-S17/Orders | old-files/features/steps/pet_steps.py | Python | apache-2.0 | 1,758 | [
"VisIt"
] | 0236f6613d2167ac95f1000479fadc94456081d46ecd5c9216f3b42030680b9f |
# -*- coding: utf-8 -*-
"""Utility functions for plotting M/EEG data."""
# Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr>
# Denis Engemann <denis.engemann@gmail.com>
# Martin Luessi <mluessi@nmr.mgh.harvard.edu>
# Eric Larson <larson.eric.d@gmail.com>
# Mainak Jas <mainak... | drammock/mne-python | mne/viz/utils.py | Python | bsd-3-clause | 91,242 | [
"Mayavi",
"VTK"
] | 114c345a1b3f434983cdd27080a2cad226f7426fb0a562e65668620fa73e0259 |
"""A separate Flask app that serves fake endpoints for demo purposes."""
# -*- coding: utf-8 -*-
from itertools import combinations
import json
import locale
import os
from datetime import timedelta as td
from datetime import datetime as dt
from random import randrange as rr
from random import choice, random
import t... | christabor/flask_jsondash | example_app/endpoints.py | Python | mit | 19,032 | [
"Cytoscape"
] | 68ff407de72ef9248dcc627d73bfd355d6d4c29d319986051c70e283bc6b43f4 |
# Python examples script that uses the R calculator filter to find the
# maxiumum spanning tree of a random input graph by inverting the edge
# weights of the graph in R. The MST algorithm then finds the maximum
# spanning tree instead of the minimum spanning tree.
# VTK must be built with VTK_USE_GNU_R turned on fo... | b3c/VTK-5.8 | Examples/Infovis/Python/Rcalculator_mst.py | Python | bsd-3-clause | 2,502 | [
"VTK"
] | cc3cbf8ef35acdfc289d7ea34034cdfd8580893f051bc81cc112cd2eef030478 |
#!/usr/bin/env python
##
## Copyright 2016 SRI International
## See COPYING file distributed along with the package for the copyright and license terms.
##
import re
import os
import subprocess
import shutil
import sys
import sibis
from export_mr_sessions_spiral import export_spiral_files
#
# Checker whether an E... | abonil91/ncanda-data-integration | scripts/redcap/export_mr_sessions_pipeline.py | Python | bsd-3-clause | 20,602 | [
"VisIt"
] | 8502f8f9cb07ef6347128886b5f68ab8ff7b32735991b5ac040d528a1c081979 |
# (C) British Crown Copyright 2011 - 2016, Met Office
#
# This file is part of cartopy.
#
# cartopy is free software: you can redistribute it and/or modify it under
# the terms of the GNU Lesser General Public License as published by the
# Free Software Foundation, either version 3 of the License, or
# (at your option)... | timmie/cartopy | setup.py | Python | gpl-3.0 | 15,071 | [
"NetCDF"
] | 38d8934b63493771814b2dc49aaba07b548c4dcf34b964b919d443ba71cd4dbc |
import os
from Bio import PDB
from Bio.SeqUtils import seq1
import warnings
import numpy as np
import cPickle
from collections import defaultdict
from difflib import SequenceMatcher
from sklearn.neighbors.kde import KernelDensity
def get_CA_distances(model, selection):
(pdb_id, chains, start_res, end_res, sequenc... | biocryst/IF | Fragments/cc_position_index.py | Python | mit | 4,018 | [
"Gaussian"
] | 63372e2e0bfb047722a6de09baf55061cd9558774f37e3aca5d272b224e42bf6 |
from __future__ import unicode_literals
from frappe import _
app_name = "erpnext"
app_title = "ERPNext"
app_publisher = "Frappe Technologies Pvt. Ltd."
app_description = """ERP made simple"""
app_icon = "fa fa-th"
app_color = "#e74c3c"
app_email = "info@erpnext.com"
app_license = "GNU General Public License (v3)"
sour... | saurabh6790/erpnext | erpnext/hooks.py | Python | gpl-3.0 | 27,341 | [
"VisIt"
] | b3aa8fddfc7b31ab5b38a2870639ab485010e5113f80571685f490d9a46810c1 |
"""
Module for show_help command.
"""
from . import command
class show_help(command.Command):
"""Command to display help message."""
def __init__(self, version, cmds, aliases, termKind):
super(show_help, self).__init__()
self._parser = command.Command.Parser(description="Show a help message.... | jl-wynen/h5shell | h5sh/commands/show_help.py | Python | mit | 1,564 | [
"VisIt"
] | f3a632880416632674a9fca8a978811f09bec552010781cf83a9feddf400f58d |
"""Module managing examples and toy datasets."""
import os
import time
import numpy as np
import pyvista
# get location of this folder and the example files
dir_path = os.path.dirname(os.path.realpath(__file__))
antfile = os.path.join(dir_path, 'ant.ply')
planefile = os.path.join(dir_path, 'airplane.ply')
hexbeamfi... | akaszynski/vtkInterface | pyvista/examples/examples.py | Python | mit | 9,262 | [
"VTK"
] | 785203616c01718f96983843ce497ee02df1d70f6d406940646f60012eb48ad2 |
# try using distribute or setuptools or distutils.
try:
import distribute_setup
distribute_setup.use_setuptools()
except ImportError:
pass
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
import os
import sys
import re
# parse version from package/module with... | widdowquinn/THAPBI-pycits | setup.py | Python | mit | 1,999 | [
"Biopython"
] | b15fa80f79bbeba4f9d7596346beaf624f738ea22c2b718c000b1735a08a3717 |
"""
Source: https://github.com/kerguler/hoppMCMC (01/12/18)
adaptive basin-hopping Markov-chain Monte Carlo for Bayesian optimisation
This is the python (v2.7) implementation of the hoppMCMC algorithm aiming to
identify and sample from the high-probability regions of a posterior
distribution. The algorithm combines t... | asteca/ASteCA | packages/best_fit/DEPRECATED/hopp_DEPRECATED/hoppMCMC.py | Python | gpl-3.0 | 30,000 | [
"Gaussian"
] | ba65ed780d7d70b9ac9e2b3bc0430b4131c2e9d69dd4a053e1cc52e538a1a1d6 |
#!/usr/bin/env python
# This example shows how to extract a piece of a dataset using an
# implicit function. In this case the implicit function is formed by
# the boolean combination of two ellipsoids.
import vtk
# Here we create two ellipsoidal implicit functions and boolean them
# together tto form a "cross" shape... | HopeFOAM/HopeFOAM | ThirdParty-0.1/ParaView-5.0.1/VTK/Examples/VisualizationAlgorithms/Python/ExtractGeometry.py | Python | gpl-3.0 | 2,326 | [
"VTK"
] | 96378c0b5645046aaf53494a59e6fd17528ce2e0b3faf4ba6fca9e8db7e326de |
# Copyright (c) 2003-2010 Sylvain Thenault (thenault@gmail.com).
# Copyright (c) 2003-2010 LOGILAB S.A. (Paris, FRANCE).
# http://www.logilab.fr/ -- mailto:contact@logilab.fr
#
# 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 t... | isohybrid/dotfile | vim/bundle/git:--github.com-klen-python-mode/pylibs/pylint/utils.py | Python | bsd-2-clause | 19,794 | [
"VisIt"
] | c846a7834b3aad9bdcdda32421837cc7cf13da058d7dc21a7c681f2d5bbe5b32 |
#!/usr/bin/env python
# Test for NO using UHF
# Jaguar ROHF: Rno = 1.125057 A = 2.12604 au; E=-129.24135247609
# UHF: Rno = 1.126917 A = 2.12955 au; E=-129.24788298992
# GAMESS-UK
# Energy -129.2478829288 (uhf at 2.12955 bohr)
import unittest, sciunittest
from PyQuante.hartree_fock import uhf
from PyQuante.Mo... | certik/pyquante | Tests/no_uhf.py | Python | bsd-3-clause | 906 | [
"GAMESS",
"Jaguar"
] | 7caca76f17f3db1ade8569000045905aa99e27b3490f4407e2f89ccab2628d5f |
from tempfile import mkstemp
from os import remove
import numpy as N
from audiolab import formatinfo as format
import audiolab as audiolab
# Create a temp file in the system temporary dir, and always remove
# it at the end
cd, filename = mkstemp('tmptest.wav')
try:
fmt = format('wav', 'pcm24')
ncha... | cournape/audiolab | docs/src/examples/obsolete/write1.py | Python | lgpl-2.1 | 1,071 | [
"Gaussian"
] | 5675dbd783182d8db4a7aacfdb60f17b4bf9c68ce5b38c343a275bcbffa8cb55 |
import os
import re
import shutil
import sys
if sys.version_info[:2] < (2, 6):
sys.exit('virtualenv requires Python 2.6 or higher.')
try:
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
user_options = [('pytest-args=', 'a', "Argu... | Lyleo/virtualenv | setup.py | Python | mit | 3,789 | [
"Brian"
] | 0bdce2f1d41c3d12e12cfec89cf75001d7d71135285d3f135ecd55df78a137dc |
import ast
import inspect
import traceback
import warnings
from copy import deepcopy
from threading import current_thread
from uuid import uuid4
from executing import only, future_flags
from snoop.formatting import Event, Source
from snoop.tracer import FrameInfo
from snoop.utils import NO_ASTTOKENS, optional_numeric... | alexmojaki/snoop | snoop/pp_module.py | Python | mit | 7,491 | [
"VisIt"
] | d42d98b8c7e40a3a4c56966d0cfac61a556a8fa1a1c83c3f95e06fd53fbfbb58 |
from __future__ import print_function
import os.path
import tempfile
import shutil
from pype9.cmd import convert
import ninemlcatalog
from nineml import read
from lxml import etree
import yaml
if __name__ == '__main__':
from pype9.utils.testing import DummyTestCase as TestCase # @UnusedImport
else:
from unitte... | tclose/PyPe9 | test/unittests/test_cmds/test_convert.py | Python | mit | 2,033 | [
"NEURON"
] | 35df5a7e90b60de2dcd438e726dac8dc4258eb96cf1a3f13b75fad9b4f720c1c |
"""Contains the MachineController base class"""
# machine.py
# Mission Pinball Framework
# Written by Brian Madden & Gabe Knuth
# Released under the MIT License. (See license info at the end of this file.)
# Documentation and more info at http://missionpinball.com/mpf
import logging
import os
import time
import sys
i... | spierepf/mpf | mpf/system/machine.py | Python | mit | 24,921 | [
"Brian"
] | c214402d9af36eb1f22605f55db5d35723c892e38d6b886786cfeda0914ac6db |
# Copyright (C) 2010-2019 The ESPResSo project
#
# This file is part of ESPResSo.
#
# ESPResSo is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later v... | fweik/espresso | testsuite/python/drude.py | Python | gpl-3.0 | 10,970 | [
"Avogadro",
"ESPResSo",
"LAMMPS"
] | 5720858f1f12f5c166021032c35e019b6d6865b1790510990427777e5db5d7a6 |
# Copyright 2015 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | hang-qi/models | inception/inception/allcnn_model.py | Python | apache-2.0 | 12,459 | [
"Gaussian"
] | acaf02b56e37253e71aeefd85c6d9a000f67cf56bdf041c35a580b0caa3eaf00 |
# coding=UTF-8
"""Copyleft 2010-2015 Forrest Sheng Bao http://fsbao.net
Copyleft 2010 Xin Liu
Copyleft 2014-2015 Borzou Alipour Fard
PyEEG, a Python module to extract EEG feature.
Project homepage: http://pyeeg.org
**Data structure**
PyEEG only uses standard Python and numpy data structures,
so you need to i... | johntanz/ROP | pyeeg2.py | Python | gpl-2.0 | 32,303 | [
"VisIt"
] | 2ede2b66a31d0a1c778386be3b27a1284c7a31bec5a0c380a711dbc54beab255 |
#-*- coding:utf-8 -*-
"""
This file is part of OpenSesame.
OpenSesame 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.
OpenSesame is distri... | SCgeeker/OpenSesame | libqtopensesame/dialogs/patch_settings.py | Python | gpl-3.0 | 2,281 | [
"Gaussian"
] | 226515e119aaa0be84368e25d24f1a8dc37b50bca15d004b6321a78cc1b49082 |
""" Unit Test of Workflow Modules
"""
import unittest
import os
import copy
import shutil
from mock import MagicMock as Mock
from DIRAC import gLogger
class ModulesTestCase(unittest.TestCase):
"""Base class for the Modules test cases"""
def setUp(self):
gLogger.setLevel("ERROR")
# impor... | DIRACGrid/DIRAC | src/DIRAC/Workflow/Modules/test/Test_Modules.py | Python | gpl-3.0 | 32,368 | [
"DIRAC"
] | 084bafc32d15c340578e428a4697a16b8443324a5ecbf8bfc7a7460a0446e324 |
#!/usr/bin/env python
import collections
import vtk
def get_program_parameters():
import argparse
description = 'Use a vtkTableBasedClipDataSet to clip a vtkUnstructuredGrid.'
epilogue = '''
Use a vtkTableBasedClipDataSet to clip a vtkUnstructuredGrid.
The resulting output and clipped output are prese... | lorensen/VTKExamples | src/Python/UnstructuredGrid/ClipUnstructuredGridWithPlane.py | Python | apache-2.0 | 5,080 | [
"VTK"
] | cda48f9314aa75104dfe72f0e02dd12298a210a024c86abcbc9ef877df5953b0 |
import matplotlib as mpl
mpl.use('Agg')
import math
import scipy.optimize as sci
import matplotlib.pyplot as plt
import numpy as np
import openeye
from openeye import oechem
from smarty import *
from smarty.utils import *
from smarty.forcefield import *
from simtk import unit
import pandas as pd
import netCDF4 as net... | bmanubay/open-forcefield-tools | single-molecule-property-generation/tors_change_k1.py | Python | mit | 17,905 | [
"NetCDF"
] | 4aa721ae13a48ff46e00633a6ff204988de29205b212ac81be86d28f8b5f69af |
#/usr/bin/python
#
# 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.
#
# Written (W) 2009-2014 Andre Kahles, Jonas Behr, G... | warrenmcg/spladder | python/spladder.py | Python | bsd-3-clause | 14,342 | [
"pysam"
] | 5056190d287299f973cd904098612cb5e8f63fbe74149645f4357557a65c538a |
# Generated from ../FullForm.g4 by ANTLR 4.7
from antlr4 import *
if __name__ is not None and "." in __name__:
from .FullFormParser import FullFormParser
else:
from FullFormParser import FullFormParser
# This class defines a complete generic visitor for a parse tree produced by FullFormParser.
class FullFormV... | rljacobson/FoxySheep | python_target/FoxySheep/generated/FullFormVisitor.py | Python | bsd-2-clause | 2,754 | [
"VisIt"
] | fe647c7b6dd67997ab1c1d9279c38cf988a7e3aacf1fdf355de5197f2f647efe |
#!/usr/bin/env python
# megamapper executer
# by Nikolaus Obholzer, Jan 2012
import sys, re, tempfile, subprocess
import os, shutil
from galaxy import eggs
def stop_err(msg):
sys.stderr.write(msg)
sys.exit()
def main():
# Handle input params
in_fname = sys.argv[1]
in_fname_wt = sys.argv[2]
... | maxplanck-ie/Megamapper | custom/hetmap_sd.py | Python | bsd-3-clause | 1,135 | [
"Galaxy"
] | 9f6fec2e53f4b1bab82b8327d1bd56642e9cfc641a8bcbaa039ffc087ea8701e |
# -*- coding: utf-8 -*-
"""
The :mod:`sklearn.naive_bayes` module implements Naive Bayes algorithms. These
are supervised learning methods based on applying Bayes' theorem with strong
(naive) feature independence assumptions.
"""
# Author: Vincent Michel <vincent.michel@inria.fr>
# Minor fixes by Fabian Pedre... | glemaitre/scikit-learn | sklearn/naive_bayes.py | Python | bsd-3-clause | 50,794 | [
"Gaussian"
] | 335a7afc863f46951967f14a28bba7d92804803d6065ad584fc7ae69c978379e |
"""
Tests for geography support in PostGIS
"""
from __future__ import unicode_literals
import os
from unittest import skipUnless
from django.contrib.gis.db.models.functions import Area, Distance
from django.contrib.gis.gdal import HAS_GDAL
from django.contrib.gis.measure import D
from django.test import Te... | yephper/django | tests/gis_tests/geogapp/tests.py | Python | bsd-3-clause | 6,490 | [
"VisIt"
] | 26bb98361d434d56f401684d8938484eae69e26fa2052c4c1a72b8bcf1e78473 |
#!/usr/bin/env python
"""
Class that constructs a MultiplexMarkovchain given the counts. Also
has methods to get the null model and the parameters of the
probability distribution associated with the Markov chain. Currently
handles only 4-state Markov chains (i.e. two layer networks).
"""
from __future__ import divisi... | vkrmsv/MultiplexMarkovChain | MultiplexMarkovChain.py | Python | bsd-3-clause | 9,185 | [
"Gaussian"
] | 9b2f62021a7e09ec22a1bc0aaea3c58028e0138d4a979975cf53478b5f8a6e20 |
#!/usr/bin/env python
"""
Artificial Intelligence for Humans
Volume 3: Deep Learning and Neural Networks
Python Version
http://www.aifh.org
http://www.jeffheaton.com
Code repository:
https://github.com/jeffheaton/aifh
Copyright 2015 by Jeff Heaton
Licensed under the Apache License, V... | trenton3983/Artificial_Intelligence_for_Humans | vol3/vol3-python-examples/examples/example_timeseries.py | Python | apache-2.0 | 1,695 | [
"VisIt"
] | 1dd0f4b99b8a0c6a7fcbb612abfc500ced450243617779e9f44e9eee71d99e7d |
# -*- coding: utf-8 -*-
from __future__ import absolute_import, unicode_literals
from __future__ import division, print_function
from PhloxAR.core.image import Image
from PhloxAR.features.blob import BlobMaker
from PhloxAR.segmentation.segmentation_base import SegmentationBase
__all__ = [
'MOGSegmentation'
]
cl... | PhloxAR/phloxar | PhloxAR/segmentation/mog_segmentation.py | Python | apache-2.0 | 4,329 | [
"Gaussian"
] | 5c3630f06f4184715e505d1d1992922fd2012d1ea003528517685efa925743e3 |
from __future__ import print_function, division
import os,unittest,numpy as np
from pyscf.nao import mf
dname = os.path.dirname(os.path.abspath(__file__))
dft = mf(label='water', cd=dname)
class KnowValues(unittest.TestCase):
def test_dos(self):
""" This is DoS with the KS eigenvalues """
omegas = np.linsp... | gkc1000/pyscf | pyscf/nao/test/test_0050_dos_pdos.py | Python | apache-2.0 | 1,041 | [
"PySCF",
"SIESTA"
] | d4c01823cde1d9cabf4e335dcf01bc3bba8d5cc64fee46b640906363a324d428 |
# This script is a modified implementation of an official NEST example
# that is able to run as task on the Unified Portal,
# see www.nest-simulator.org
#
# Contributors:
# Johanna Senk (j.senk@fz-juelich.de)
# Long Phan (l.phan@fz-juelich.de
#
# ###################################################################... | jakobj/UP-Tasks | NEST/brunel_delta_nest_task/brunel_delta_nest_task.py | Python | gpl-2.0 | 13,387 | [
"NEURON"
] | 270051a78b7668027e8ae71055a7d46edaa2b59bc29382821fa38722778bb875 |
#!/usr/bin/env python
########################################################################
# File : dirac-wms-job-reschedule
# Author : Stuart Paterson
########################################################################
"""
Reschedule the given DIRAC job
Usage:
dirac-wms-job-reschedule [options] ... Job... | yujikato/DIRAC | src/DIRAC/Interfaces/scripts/dirac_wms_job_reschedule.py | Python | gpl-3.0 | 1,332 | [
"DIRAC"
] | facf00e84f7dc8d9efc09a687a378b7e6351e775e5859dcb9cb79e7b5ad4db4f |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Models for the example integration application.
# Copyright (C) 2009 Yesudeep Mangalapilly.
#
# The MIT License
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to dea... | yesudeep/pyebs | models.py | Python | mit | 11,260 | [
"BWA"
] | 1725beb3c7a12b40fb218953c5dce3f48b868657cc42a2efdd00dae38000ff8c |
""" DataStore is the service for inserting accounting reports (rows) in the Accounting DB
This service CAN be duplicated iff the first is a "master" and all the others are slaves.
"""
import datetime
from DIRAC import S_OK, S_ERROR, gConfig, gLogger
from DIRAC.AccountingSystem.DB.MultiAccountingDB import MultiA... | arrabito/DIRAC | AccountingSystem/Service/DataStoreHandler.py | Python | gpl-3.0 | 8,068 | [
"DIRAC"
] | 2d25ba87a5eba316e6b892400fccd52d99bca386eb87ee5fc21782743486d6d1 |
# encoding: utf-8
"""
System command aliases.
Authors:
* Fernando Perez
* Brian Granger
"""
#-----------------------------------------------------------------------------
# Copyright (C) 2008-2011 The IPython Development Team
#
# Distributed under the terms of the BSD License.
#
# The full license is in the file... | wolfram74/numerical_methods_iserles_notes | venv/lib/python2.7/site-packages/IPython/core/alias.py | Python | mit | 9,807 | [
"Brian"
] | f09e68098325a257794526c94cbf881fd8331becef53341a05059781029569a6 |
"""Check that we can read old version 1 Trajectories."""
import functools
import pickle
import sys
from io import BytesIO
from ase import Atoms
from ase.constraints import FixAtoms
from ase.io.pickletrajectory import PickleTrajectory
from ase.test import NotAvailable
if sys.version_info[0] == 3:
raise NotAvailabl... | suttond/MODOI | ase/test/fio/oldtraj.py | Python | lgpl-3.0 | 1,598 | [
"ASE"
] | 50872284bbac50635fbcf02475e7af5b5b8d51e659b568daf7af01a09f045746 |
from typing import Optional
# Zulip Settings intended to be set by a system administrator.
#
# See http://zulip.readthedocs.io/en/latest/settings.html for
# detailed technical documentation on the Zulip settings system.
#
### MANDATORY SETTINGS
#
# These settings MUST be set in production. In a development environment... | Galexrt/zulip | zproject/prod_settings_template.py | Python | apache-2.0 | 19,830 | [
"VisIt"
] | c0d43f9030c71388f13a1885901426e2911f99557b8ba77b9528f3113e594cd9 |
# -*- coding: UTF-8 -*-
# Copyright (C) 2005 Luis Arturo Belmar-Letelier <luis@itaapy.com>
# Copyright (C) 2005-2009 J. David Ibáñez <jdavid.ibp@gmail.com>
# Copyright (C) 2008 David Versmisse <versmisse@lil.univ-littoral.fr>
# Copyright (C) 2008 Matthieu France <matthieu@itaapy.com>
# Copyright (C) 2008 Sylvain Tavern... | bepatient-fr/itools | itools/python/python.py | Python | gpl-3.0 | 2,872 | [
"VisIt"
] | 8cf5f59269f1d1aa18a3a4e022283f2e357716dcbc56a1310daf495984fbedf3 |
"""
Various bayesian regression
"""
# Authors: V. Michel, F. Pedregosa, A. Gramfort
# License: BSD 3 clause
from math import log
import numpy as np
from scipy import linalg
from .base import LinearModel
from ..utils.extmath import fast_logdet
########################################################################... | ominux/scikit-learn | sklearn/linear_model/bayes.py | Python | bsd-3-clause | 15,550 | [
"Gaussian"
] | 42799d3597b5d349cf93f8fc2f65a0806336959f5021e89cfe2367fb1b5be0c3 |
import numpy
import matplotlib.pyplot
import scipy.io.netcdf
from . import _find_nearest_idx
from mpl_toolkits.basemap import shiftgrid, addcyclic
def _decorate_x_axes_for_ymonmean(ax):
# Some decoration stuff
ax.set_xlabel("Month")
ax.set_xlim(-1, 12)
ax.xaxis.set_ticks(numpy.arange(12))
ax.xaxis... | pgierz/MyPythonModules | plot_tools/seasonal_amplitude.py | Python | gpl-2.0 | 7,150 | [
"NetCDF"
] | 6d83785ce524a78424b1624d46334e1f73710738cac196c210d5ad51200cc517 |
# -*- coding: utf-8 -*-
import matplotlib.pyplot as plt
import gdal
from skimage import filter
import numpy as np
from numpy.lib.function_base import histogram
import skimage
def CalMI(a,b):
"""
Calculate the MI
"""
reference = np.array(a)
query = np.array(b)
L=256
miMat = np.zeros((L,L))
... | WindWang2/pyregistration | source/mi_new.py | Python | mit | 7,927 | [
"Gaussian"
] | 906a3f1e178354903a12331a1bf266daf140b66f7b10b97a2e8a7fb223109943 |
"""This demo uses PETSc's TAO solver for nonlinear (bound-constrained)
optimisation problems to solve a contact mechanics problem in FEniCS.
We consider here a heavy hyperelastic circle under body force
in a box of the same size."""
# Copyright (C) 2012 Corrado Maurini
#
# This file is part of DOLFIN.
#
# DOLFIN is fr... | FEniCS/dolfin | demo/undocumented/contact-vi-tao/python/demo_contact-vi-tao.py | Python | lgpl-3.0 | 4,480 | [
"VTK"
] | d16929a556fd1554714e57b723931a8d2fdbf548d611f3279014a407d1861b0a |
import unittest
import numpy
import theano
from yann.layers.random import random_layer as rl
try:
from unittest.mock import Mock
except ImportError:
from mock import Mock,patch
from theano.sandbox.rng_mrg import MRG_RandomStreams as RandomStreams
class TestRandom(unittest.TestCase):
def setUp(self):
... | ragavvenkatesan/Convolutional-Neural-Networks | tests/layers/test_random.py | Python | mit | 7,405 | [
"Gaussian"
] | afb7f36efdefc8deb079cbe4bc254a13d41d1084a8af519485959fe7ae40e6cc |
# This module manages the chemical database, which contains
# definitions for atoms, groups, molecules, and complexes.
#
# Each definition is a Python file that is executed in the
# global environment of the module "XEnvironment" (X standing
# for 'Atom', 'Group', 'Molecule', or 'Complex'). Definitions
# made in that f... | fxia22/ASM_xf | PythonD/site_python/MMTK/Database.py | Python | gpl-2.0 | 12,569 | [
"CRYSTAL"
] | 4b187f093208fdd9523fa9ef0d2031e8efb6fb288fa58bb6dc8f85ec338d021d |
"""Example creating minimal model.
This demonstrates just the very core SBML functionality.
"""
from pathlib import Path
from typing import List
from sbmlutils import EXAMPLES_DIR
from sbmlutils.cytoscape import visualize_sbml
from sbmlutils.examples import templates
from sbmlutils.factory import *
from sbmlutils.met... | matthiaskoenig/sbmlutils | src/sbmlutils/examples/linear_chain.py | Python | lgpl-3.0 | 1,407 | [
"Cytoscape"
] | 3b69b41f62c3ce3160844be209b37e629dd3f4f2a175ecbf3aadb28ef45d002d |
"""
HTTP Views (accepts and parses webhooks)
"""
import logging
from aiohttp import web
from aiohttp_session import get_session
from aiohttp_security import check_authorized, forget, permits, remember, authorized_userid
from aiohttp_jinja2 import template, render_template
from .events import event_routes
from ..gith... | bioconda/bioconda-utils | bioconda_utils/bot/views.py | Python | mit | 8,448 | [
"Bioconda"
] | 7ffcf620beaff8265d1f68d4767fa0cc07d1f6c8869b89ac4c9106ef5f9d2949 |
"""
Demonstration application for nearest neighbor using kd tree
"""
import tkinter
from adk.kd import KDTree, X, Y, VERTICAL
from adk.region import minValue, maxValue
RectangleSize = 4
shortline = 'shortline'
closest = 'closest'
class KDTreeApp:
def __init__(self):
"""App for cre... | heineman/algorithms-nutshell-2ed | PythonCode/demo/app_kd_nearest.py | Python | mit | 4,575 | [
"VisIt"
] | 8407e8f0039e38274da8c95b113956a6b51c427be44849d94c66972b49ab1bba |
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""Setup.py for pymatgen."""
import sys
import platform
import numpy
from setuptools import setup, find_namespace_packages, Extension
extra_link_args = []
if sys.platform.startswith("win") and platform.machine().endswith("... | vorwerkc/pymatgen | setup.py | Python | mit | 8,215 | [
"ABINIT",
"ASE",
"CP2K",
"CRYSTAL",
"FEFF",
"Gaussian",
"LAMMPS",
"NWChem",
"VASP",
"VTK",
"pymatgen"
] | 200a4c08d771b7741c330d23041f0d6591aa28f150ed9c4b2fa361770b5776e1 |
import h5py
import numpy
from rdkit import Chem
from rdkit.Chem import MACCSkeys
from util import data_validation, misc, file_structure, file_util, logger, process_pool, constants, hdf5_util, \
multi_process_progressbar
class MaccsFingerprint:
@staticmethod
def get_id():
return 'maccs_fingerprin... | patrick-winter-knime/mol-struct-nets | molstructnets/steps/featuregeneration/maccsfingerprint/maccs_fingerprint.py | Python | gpl-3.0 | 3,529 | [
"RDKit"
] | 629837cc17dbe3b4267565e19f34a2cf97aecf59e313cebfd50349b890eca332 |
"""
09 Jun 2015
"""
from __future__ import print_function
from builtins import next
import os
import re
import copy
import multiprocessing as mu
from warnings import warn
from tempfile import gettempdir, mkstemp
from subprocess import CalledProcessError, PIPE, STDOUT, Popen
from pysam import Samfile
from pytadbit.... | 3DGenomes/tadbit | _pytadbit/mapping/full_mapper.py | Python | gpl-3.0 | 41,124 | [
"pysam"
] | 3b879e2339637737b5236854fadf4e603296a0fa0ef3e1a1a0874b0bce7c2ce5 |
import vtk
import inspect
def parseClassTree(classtree, tree, names, parentId):
"""
This function convertes a nested list generated by
inspect.getclasstree() to a vtkTree.
"""
childId = None
for i in classtree:
# element showing the parent
if type(i) == type(()):
... | b3c/VTK-5.8 | Examples/Infovis/Python/displayVTKHierarchy.py | Python | bsd-3-clause | 2,010 | [
"VTK"
] | 85c5880f108d8a0f69f32fee4f900aeb29f51b8aac0ef3fce028bdf02fd350f9 |
#! /usr/bin/env python
"""Complements the given RNA/DNA sequences.
The specified input CSV file should have one column (with header) consisting
of valid RNA/DNA sequences."""
# We'll use Biopython for the actual substance of the code
from Bio.Seq import Seq;
import argparse;
import csv;
import sys;
parser = argpar... | cfe-lab/Kive | samplecode/test_cr.py | Python | bsd-3-clause | 1,059 | [
"Biopython"
] | bfcb915beba2a7170482eb9652e9028c37f33a59a64c4a339924cf0833fa276f |
# $Id$
#
# Copyright (C) 2004-2006 Rational Discovery LLC
#
# @@ All Rights Reserved @@
#
from rdkit import RDConfig
import os, sys, copy
import unittest
import math
from rdkit import Chem
from rdkit.Chem import rdMolAlign, rdMolTransforms, rdMolDescriptors, rdDistGeom, ChemicalForceFields
def lstFeq(l1, l2, ... | rdkit/rdkit | Code/GraphMol/MolAlign/Wrap/testMolAlign.py | Python | bsd-3-clause | 18,475 | [
"RDKit"
] | dfa110b343612ad30600175b88fd6db3097dc46da95f05fed8d690aeb35d26dc |
# Copyright 2020 DeepMind Technologies Limited.
# 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
# https://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agreed t... | deepmind/active_ops | arm_model.py | Python | apache-2.0 | 8,839 | [
"Gaussian"
] | 44603f0f33902a4868f8f41ba6145b341647ac23b2b16e678afd5eba6524c3f2 |
#!/usr/bin/env python2
# Copyright 2011, 2012 Alexandre Gravier (al.gravier@gmail)
# This file is part of PyCogMo.
# PyCogMo 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, o... | agravier/pycogmo | attention_net.py | Python | gpl-3.0 | 5,794 | [
"Brian"
] | f03dda00c35c77916e150337f144b3de3f19f6fde30cac3076fed746dfabe10f |
# -*- coding: utf-8 -*-
# vi:si:et:sw=4:sts=4:ts=4
##
## Copyright (C) 2012 Async Open Source <http://www.async.com.br>
## All rights reserved
##
## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
## the Free Software Foundati... | tiagocardosos/stoq | stoqlib/gui/test/test_purchasedetails.py | Python | gpl-2.0 | 3,604 | [
"VisIt"
] | a9fb81fbde08aa83a918b3601f3e2ebef22a429f6c862c8e6433257555f2477c |
# Copyright 2015 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | aam-at/tensorflow | tensorflow/python/keras/activations.py | Python | apache-2.0 | 18,475 | [
"Gaussian"
] | 080e387d01bc910f2e10d6acf267b0944e8c00ca66a5c5f9201b178886ac2a8e |
#------------------------------------------------------------------------------
# Copyright 2013 Esri
# 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/LICENS... | JudTown17/solutions-geoprocessing-toolbox | suitability/toolboxes/scripts/ParseNetCDFToMultiBandRasters.py | Python | apache-2.0 | 7,679 | [
"NetCDF"
] | b88bd93e5bfde36718f6a749e9abc53b9d846ebfb87b49cf2e6c10ebabc5f8a3 |
#!/usr/bin/python
# -*- coding: utf-8 -*-
dimensions= 2
size1d = 6
halfSize1 = [size1d,size1d,0.1]
halfSize2 = halfSize1
# wavepacket parameters
k0_x = 0
k0_y = 0
gaussWidth_x = 1.5
gaussWidth_y = 1.5
potentialCoefficient= [2.0,2.0,0.5]
O.engines=[
StateDispatcher([
St1_QMPacketGaussianWave(),
... | cosurgi/trunk | examples/qm/2d-harmonic-interaction.py | Python | gpl-2.0 | 3,007 | [
"Gaussian"
] | 7c2c22f73e84ed6eaab65f9610393001e34d89af74dd9568060508f22291f28e |
'''
Common methods for beamtools package
Created Fri May 12
@author: cpkmanchee
'''
import numpy as np
from beamtools.file_formats import file_formats
import dill
__all__ = ['saveObj','loadObj','normalize','rmbg','gaussian','sech2','lorentzian',
'gaussian2D','rk4','moments','d4sigma','roi','alias_dict']... | kikimaroca/beamtools | beamtools/common.py | Python | mit | 8,964 | [
"Gaussian"
] | 2cbb9b233d9f671e70f86e24db260f17e5316f3656adc5f51a840fd4981a58c9 |
# Copyright 2020 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/python/math/special.py | Python | apache-2.0 | 67,113 | [
"Gaussian"
] | 364278432f000897c60ea634ff9ee2f95d1ff0c1e5c09d7ed5e37987456636ce |
#!/usr/bin/env python
########################################################################
# $HeadURL$
# File : dirac-admin-get-pilot-logging-info.py
# Author : Stuart Paterson
########################################################################
"""
Retrieve logging info of a Grid pilot
"""
__RCSID__ = "$... | Sbalbp/DIRAC | Interfaces/scripts/dirac-admin-get-pilot-logging-info.py | Python | gpl-3.0 | 1,322 | [
"DIRAC"
] | 2a1dbcf1ab27e8aab8dbba92fd8f34b7e61f036e2c170c3dd79f0e8bb2d1c0f4 |
from __future__ import absolute_import
from enum import Enum
import itertools
import numpy as np
from scipy.signal import gaussian
class PositionOffset(Enum):
UpperLeft = (0, 0)
UpperRight = (0, 1)
LowerLeft = (1, 0)
LowerRight = (1, 1)
def get_distance_matrix(measure=gaussian(7, 1)):
"""
... | Scan-o-Matic/scanomatic | scanomatic/data_processing/vector_norm.py | Python | gpl-3.0 | 4,791 | [
"Gaussian"
] | 9bedc9df1b7faffa0dbda68312b85014c3089946357fb7285b2a37be8fb6ef97 |
import functools
import numpy as np
import regreg.api as rr
from ..algorithms.cv import CV
from ..algorithms.cv_glmnet import CV_glmnet, have_glmnet
from .query import query
from ..glm import bootstrap_cov
from .randomization import randomization
### TODO: this is just a topK view now, modify it
class CV_view(query... | selective-inference/selective-inference | selectinf/randomized/cv_view.py | Python | bsd-3-clause | 5,232 | [
"Gaussian"
] | db67ac884a5851bfa8cf1f39a9a37dec4b3b458e450ed9b78cc94d4831bfa657 |
#! /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-memcache | scripts/fixup_memcache_v1_keywords.py | Python | apache-2.0 | 6,329 | [
"VisIt"
] | 49586e72e2c60843bffba85ee84420156a57265571accf21d15d3552b011f743 |
""" pytest for WorkflowTasks
"""
# pylint: disable=protected-access,missing-docstring,invalid-name
import json
import six
import sys
from mock import MagicMock
from pytest import mark
parametrize = mark.parametrize
from hypothesis import given, settings
from hypothesis.strategies import (
composite,
integers... | DIRACGrid/DIRAC | src/DIRAC/TransformationSystem/Client/test/Test_Client_RequestTasks.py | Python | gpl-3.0 | 11,271 | [
"DIRAC"
] | a05efde42aa9ef7790e73731ed31a696cce7c2b2ab2ea80698e5fd0926e5a9b0 |
"""
ExpandGlobals replaces globals variables by function call.
It also turn globals assignment in function definition.
"""
from pythran.analyses import LocalNameDeclarations
from pythran.passmanager import Transformation
from pythran.syntax import PythranSyntaxError
from pythran import metadata
import ast
class E... | pbrunet/pythran | pythran/transformations/expand_globals.py | Python | bsd-3-clause | 3,014 | [
"VisIt"
] | a15353c3c212f8f44dfc8c12736dea63e0c1a2d61e6f5473c1f4c89061f504f3 |
#!/usr/bin/python
# -*- coding: utf-8 -*-
# freeseer - vga/presentation capture software
#
# Copyright (C) 2014 Free and Open Source Software Learning Centre
# http://fosslc.org
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published ... | Freeseer/freeseer | src/freeseer/tests/test_settings.py | Python | gpl-3.0 | 1,852 | [
"VisIt"
] | eb3940ee80097d7e5375701a4f2bc9a700fd9ec5b9d7a534f382ef22c6202b75 |
#!/usr/bin/python2
"""Extracts data from National Water Model files into new files."""
import os
from netCDF4 import Dataset, date2num
import numpy as np
import pytz
import pynwm.constants as constants
import pynwm.nwm_data as nwm_data
def subset_channel_file(in_nc_filename, out_nc_filename, river_ids,
... | twhiteaker/pynwm | src/pynwm/nwm_subset.py | Python | mit | 6,890 | [
"NetCDF"
] | 29155f5fa3de960f5d28a202f1b14de4ad4dda13d02ca20f8b06460cf24e4225 |
"""
Signal Processing Tools
=======================
Convolution:
convolve -- N-dimensional convolution.
correlate -- N-dimensional correlation.
fftconvolve -- N-dimensional convolution using the FFT.
convolve2d -- 2-dimensional convolution (more options).
correlate2d -- 2-dim... | huard/scipy-work | scipy/signal/info.py | Python | bsd-3-clause | 4,275 | [
"Gaussian"
] | 3f6b25b148895449f6055fb857ef4ddb8583ef87f41298a43dc88cebfaa4ddfc |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.