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 |
|---|---|---|---|---|---|---|---|
################################
## Set diagnostics to True ##
## If you want display the ##
## Tracking process. ##
################################
diagnostics=False
#################################
## Import packages ##
#################################
import sys
from trackeddy.tracki... | Josue-Martinez-Moreno/trackeddy | tests/test_2d_assemble.py | Python | mit | 4,093 | [
"Gaussian"
] | 627c48c76dc6ce9116141e0e424f44b318841cfbc80c75b674d6d55541f29a73 |
#
# ----------------------------------------------------------------------------------------------------
#
# Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify ... | zapster/graal-core | mx.graal-core/mx_graal_benchmark.py | Python | gpl-2.0 | 39,136 | [
"VisIt"
] | dc82b509fb921a9f8a8d625875eb2065c6efb95ce6b36e0fca2bd2f7c0f03a1b |
# Copyright (C) 2012,2013
# Max Planck Institute for Polymer Research
# Copyright (C) 2008,2009,2010,2011
# Max-Planck-Institute for Polymer Research & Fraunhofer SCAI
#
# This file is part of ESPResSo++.
#
# ESPResSo++ is free software: you can redistribute it and/or modify
# it under the terms of t... | BackupTheBerlios/espressopp | src/analysis/Velocities.py | Python | gpl-3.0 | 1,919 | [
"ESPResSo"
] | cc066eaecc8df0fdc4b00e7edf2ba323eb08de86c4124d40c4cf9bbfe8307d42 |
import scipy
import scipy.interpolate
import numpy
import os
import sys
import SpectralTools
import AstroUtils
import astropy.io.fits as pyfits
import time
import Moog960
class MARCS_Atmosphere( object ):
def __init__(self, df):
data = open(df, 'r')
model = data.readlines()
self.Teff = int(... | JNMcLane/MoogPy | MoogTools/MoogTools.py | Python | mit | 95,515 | [
"Gaussian"
] | 0a4984df4d68d5d0d22a71e1713f69733554d5ffe9f2ff745375b7ed24de8482 |
# Copyright (C) 2011, 2012, 2013, 2015 David Maxwell
#
# This file is part of PISM.
#
# PISM 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
# ver... | talbrecht/pism_pik07 | site-packages/PISM/util.py | Python | gpl-3.0 | 2,829 | [
"NetCDF"
] | 1fa5c733718f12ee3092a338eec85fcddda0ecc0362fe92a4701e5cc2b5b9ac8 |
def read_aims(filename):
"""Import FHI-aims geometry type files.
Reads unitcell, atom positions and constraints from
a geometry.in file.
"""
from ase import Atoms
from ase.constraints import FixAtoms, FixCartesian
import numpy as np
atoms = Atoms()
fd = open(filename, 'r')
li... | suttond/MODOI | ase/io/aims.py | Python | lgpl-3.0 | 10,742 | [
"ASE",
"FHI-aims"
] | 5c29aeaa58cfb7ca4eda16ba3cf150d669037f70f3f58a6720661b26c210f59e |
#!/usr/bin/env python
# Copyright 2014-2018 The PySCF Developers. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# U... | gkc1000/pyscf | pyscf/prop/nmr/test/test_hf_msc.py | Python | apache-2.0 | 4,358 | [
"PySCF"
] | 648d2591875b85bf00a910cb63dff322104e839c4d822fef0de6bd13180c9c21 |
#
# Copyright (C) 2004-2006 Rational Discovery LLC
#
# @@ All Rights Reserved @@
# This file is part of the RDKit.
# The contents are covered by the terms of the BSD license
# which is included in the file license.txt, found at the root
# of the RDKit source tree.
#
import argparse
import csv
import os
import sys... | rvianello/rdkit | rdkit/Chem/ChemUtils/SDFToCSV.py | Python | bsd-3-clause | 2,530 | [
"RDKit"
] | 52edacc2c7f65f8ab8c0f69663c5c3dcade3fe2917f0dd5652bf3fc827ea6060 |
class ThreatExchange(object):
"""
General vocabulary for ThreatExchange.
"""
URL = 'https://graph.facebook.com/'
VERSION = 'v2.6/'
ACCESS_TOKEN = 'access_token'
DEFAULT_LIMIT = 25
# GET
MALWARE_ANALYSES = 'malware_analyses/'
MALWARE_FAMILIES = 'malware_families/'
THREAT_EX... | RyPeck/ThreatExchange | pytx/pytx/vocabulary.py | Python | bsd-3-clause | 14,656 | [
"Amber"
] | 13a4380e76b15824bd6a61852b76f2fa4505324b8f4418d3f543a41363257769 |
"""socket interactions for gadfly client and server"""
from select import select
# responses
SUCCESS = "SUCCESS"
EXCEPTION = "EXCEPTION"
def reply_exception(exception, info, socket):
"""send an exception back to the client"""
# any error is invisible to client
from gfserve import ServerError
impor... | Donkyhotay/MoonPy | zope/rdb/gadfly/gfsocket.py | Python | gpl-3.0 | 6,946 | [
"BLAST"
] | 8db6e748e79f9b198680204add0c35461709797d1e177ce5f907cf655fd997a6 |
# Copyright (C) 2020 Atsushi Togo
# All rights reserved.
#
# This file is part of phono3py.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# * Redistributions of source code must retain the above copyright
# noti... | atztogo/phono3py | phono3py/phonon3/interaction.py | Python | bsd-3-clause | 21,035 | [
"phonopy"
] | a1cd1cac0b75a522649744c1418942fc751053f96eaf6d93888b766e5dc90727 |
##
# Copyright 2009-2018 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 (F... | bartoldeman/easybuild-easyblocks | easybuild/easyblocks/w/wrf_fire.py | Python | gpl-2.0 | 10,206 | [
"NetCDF"
] | 7b55cabda3ffac5f15d5d38de7b7ff33eb3a58a75987442be8d697a7eb395688 |
#!/usr/bin/python
#
# This source file is part of appleseed.
# Visit https://appleseedhq.net/ for additional information and resources.
#
# This software is released under the MIT license.
#
# Copyright (c) 2017-2018 Esteban Tovagliari, The appleseedhq Organization
#
# Permission is hereby granted, free of charge, to ... | dictoon/blenderseed | scripts/blenderseed.package.py | Python | mit | 26,912 | [
"VisIt"
] | 8c4e125b5c2431111a0e6ebcea5b3a6870617ea7adf898110808bdf60b9cb543 |
# This wizard contributed by Ezequiel "Zac" Panepucci 011114
# modified by Warren L. DeLano
from pymol.wizard import Wizard
from pymol import cmd
import pymol
class Label(Wizard):
atom=None
messages=1
labeling=1
obj_name=None
def __init__(self,_self=cmd):
Wizard.__init__(self,_self)
... | gratefulfrog/lib | python/pymol/wizard/label.py | Python | gpl-2.0 | 2,783 | [
"PyMOL"
] | ac35ea0a93f948baf70e1614626eb3b1cde64aef712bd839b4efcfba3a047ecd |
# 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 to in writing, software
# distributed under the Li... | openstack/heat-translator | translator/hot/syntax/hot_resource.py | Python | apache-2.0 | 27,182 | [
"Galaxy"
] | f7a65b708a5a7609ebe3da3cae22bac401539fc465e92e814767dc21c8a4cceb |
#pylint: disable=missing-docstring
#################################################################
# DO NOT MODIFY THIS HEADER #
# MOOSE - Multiphysics Object Oriented Simulation Environment #
# #
# (c) 2010... | Chuban/moose | python/chigger/__init__.py | Python | lgpl-2.1 | 1,047 | [
"MOOSE"
] | 0a7335eb0d28ecbc57c2eec2d93abc5460ec56b9bb3df75f1836076b8c833b59 |
"""
API for initiating and tracking requests for credit from a provider.
"""
import datetime
import logging
import pytz
import uuid
from django.db import transaction
from openedx.core.djangoapps.credit.exceptions import (
UserIsNotEligible,
CreditProviderNotConfigured,
RequestAlreadyCompleted,
Credit... | martynovp/edx-platform | openedx/core/djangoapps/credit/api/provider.py | Python | agpl-3.0 | 14,252 | [
"VisIt"
] | 1ba96380a1675466e15d92715f2e9c4bab4c4840f08b40cc7d783fddf5f365d2 |
#!/galaxy/home/mgehrin/hiclib/bin/python
"""
Script to select random lines from a file. Reads entire file into
memory!
TODO: Replace this with a more elegant implementation.
"""
import sys
import random
ndesired = int( sys.argv[1] )
for line in random.sample( sys.stdin.readlines(), ndesired ):
print line,
| bxlab/HiFive_Paper | Scripts/HiCLib/bx-python-0.7.1/build/scripts-2.7/random_lines.py | Python | bsd-3-clause | 316 | [
"Galaxy"
] | 8a1ae7ea3e965f77bef883917321fecc5e60761a0280a0ddcc6ef914c3b56ab1 |
import os
import math
import torch
import shutil
import numpy as np
import matplotlib.pyplot as plt
import pyprob
from pyprob import Model
from pyprob.distributions import Uniform, Normal
class GaussianWithUnknownMean(Model):
def __init__(self):
super().__init__('Gaussian with unknown mean')
self... | probprog/pyprob | tests/extra/inference_compilation/rejection_sampling.py | Python | bsd-2-clause | 5,023 | [
"Gaussian"
] | 33e6ea6b286c01afbb6d987227232442894a0d2548420c4f587770c6f3800a33 |
"""User-friendly public interface to polynomial functions. """
from __future__ import print_function, division
from sympy.core import (
S, Basic, Expr, I, Integer, Add, Mul, Dummy, Tuple
)
from sympy.core.mul import _keep_coeff
from sympy.core.symbol import Symbol
from sympy.core.basic import preorder_traversal
... | kaichogami/sympy | sympy/polys/polytools.py | Python | bsd-3-clause | 174,060 | [
"Gaussian"
] | d2b3b1b2c25dc5809c1a85c867a1c61df11cf94612225e1916ed30d4083d2cb6 |
from math import sqrt, pi
import numpy as np
from ase.units import Bohr
from gpaw.utilities import pack, pack2
from gpaw.analyse.hirshfeld import HirshfeldDensity
from gpaw.utilities.tools import coordinates
from gpaw.mpi import MASTER
def wignerseitz(gd, atoms, scale=None):
"""Determine which atom is closest to... | qsnake/gpaw | gpaw/analyse/wignerseitz.py | Python | gpl-3.0 | 5,301 | [
"ASE",
"GPAW"
] | 768c8e3e26a7c92d3fe5110492271559398d9e359beda84ce01163f6ac53dd13 |
#
# Copyright (C) 2013,2014 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... | KonradBreitsprecher/espresso | samples/store_properties.py | Python | gpl-3.0 | 5,107 | [
"ESPResSo"
] | 3502fe52fa2a0bdecf8c1c2fe48e53e9e9312b8e80d324851c5f85357b46d78d |
########################################################################
# $HeadURL$
# File : JobCleaningAgent.py
# Author : A.T.
########################################################################
""" The Job Cleaning Agent controls removing jobs from the WMS in the end of their life cycle.
This agent wi... | Sbalbp/DIRAC | WorkloadManagementSystem/Agent/JobCleaningAgent.py | Python | gpl-3.0 | 10,095 | [
"DIRAC"
] | 1e3fb7edec9a6815ab1145a8b29f7be80881235b57e799bc09d02d30d1ed51a0 |
#!/usr/bin/env python
#encode=utf-8
#vim: tabstop=4 shiftwidth=4 softtabstop=4
#Created on 2013-6-24
#Copyright 2013 nuoqingyun xuqifeng
from bson.code import Code
traffic_map = Code("function () {"
"emit(this.domain, this.bytes);"
"}")
traffic_reduce = Code("function (key, values) {"
... | homhei/glance | glance/db/js.py | Python | apache-2.0 | 1,449 | [
"VisIt"
] | c9e0d407c06b574f446d725d017667ea85d6e3300800b934a0b9245bf862a7cb |
# encoding: utf-8
"""
A base class for a configurable application.
Authors:
* Brian Granger
* Min RK
"""
from __future__ import print_function
#-----------------------------------------------------------------------------
# Copyright (C) 2008-2011 The IPython Development Team
#
# Distributed under the terms of th... | alephu5/Soundbyte | environment/lib/python3.3/site-packages/IPython/config/application.py | Python | gpl-3.0 | 21,862 | [
"Brian"
] | 3c1546f248c954f3b80d330cee047e8762496c969259bb6970fb81371f58e7b6 |
#
# Copyright 2001 - 2006 Ludek Smid [http://www.ospace.net/]
#
# This file is part of IGE - Outer Space.
#
# IGE - Outer Space is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the Lice... | Lukc/ospace-lukc | client-pygame/lib/osci/dialog/MessagesDlg.py | Python | gpl-2.0 | 17,967 | [
"Galaxy"
] | 6b0a49c5ca9aee35574cf3ff20a940420d055e5b83eb3d63bd846a577753073a |
# Copyright (C) 2004-2009 Paul Cochrane
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distribut... | paultcochrane/pyvisi | pyvisi/camera.py | Python | gpl-2.0 | 5,343 | [
"VTK"
] | 6be4aae38f47759c64a2ebf48d8c12804ea81c94204b4a11f6515eaa85120811 |
# -*- 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 required by applicable law or... | googleapis/python-game-servers | tests/unit/gapic/gaming_v1beta/test_game_server_clusters_service.py | Python | apache-2.0 | 123,914 | [
"Octopus"
] | ee3e84267a4ca5f8f7e822e069430a9ec604f91a48d5813a8926aef7c27273e1 |
"""rbf - Radial basis functions for interpolation/smoothing scattered Nd data.
Written by John Travers <jtravs@gmail.com>, February 2007
Based closely on Matlab code by Alex Chirokov
Additional, large, improvements by Robert Hetland
Some additional alterations by Travis Oliphant
Permission to use, modify, and distrib... | jlcarmic/producthunt_simulator | venv/lib/python2.7/site-packages/scipy/interpolate/rbf.py | Python | mit | 9,536 | [
"Gaussian"
] | 24efda41ea8f4e4ea4ab3dc20647d766fee82dc2429588daf951663f69cf992c |
#!/usr/bin/env python
from __future__ import division, print_function
import os
from math import log
from collections import namedtuple, OrderedDict, deque
import time
import threading
import json
import gc
try:
from Queue import Queue
except ImportError:
from queue import Queue
import io
import logging
from fr... | kif/yocto-meteo-plugin | camera.py | Python | mit | 24,206 | [
"Gaussian"
] | d6a5e34acb95aa011eab968615b9530f2171baaa7d9d68dd68e1fc6ba9479184 |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import pootle.core.mixins.treeitem
class Migration(migrations.Migration):
dependencies = [
("pootle_app", "0001_initial"),
]
operations = [
migrations.CreateModel(
name="... | evernote/zing | pootle/apps/pootle_language/migrations/0001_initial.py | Python | gpl-3.0 | 3,360 | [
"VisIt"
] | d6f7927d3c7506c9b49962e8885bf27cbc9e76103de05e019a0d847bf08b2706 |
# coding utf8
import setuptools
from setuptools import setup
from GetOrganelleLib.versions import get_versions
import platform
import sys
import os
# system info
SYSTEM_NAME = ""
if platform.system() == "Linux":
SYSTEM_NAME = "linux"
elif platform.system() == "Darwin":
SYSTEM_NAME = "macOS"
else:
sys.stdo... | Kinggerm/GetOrganelle | setup.py | Python | gpl-3.0 | 9,179 | [
"BLAST",
"BWA"
] | 90c6e3365dcf77e6947ac9c01be1d3e28fe1307271c196dda18f335e6e2b1afd |
import numpy as np
from sklearn.base import BaseEstimator, TransformerMixin
from sklearn.utils.validation import check_array
from .utils import (orthonormalize, random_orthonormal, weighted_mean,
solve_weighted, check_array_with_weights)
class EMPCA(BaseEstimator, TransformerMixin):
"""Expect... | jakevdp/wpca | wpca/empca.py | Python | bsd-3-clause | 8,136 | [
"Gaussian"
] | d7cc91e3624ea656acb44693ed85c26e8e4459104fe9cfb60ff0bfce07a3090b |
# Copyright (c) 2007 The Regents of The University of Michigan
# Copyright (c) 2010 The Hewlett-Packard Development Company
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met: redistributions of sou... | samueldotj/TeeRISC-Simulator | src/python/m5/stats/__init__.py | Python | bsd-3-clause | 4,468 | [
"VisIt"
] | 7ab1a8f20ef7efe2da0b4aec1cc6dfad1f9ed951aef33795c2db641f4e7f7d68 |
"""Copy database grids to netcdf.
Example: python db_to_netcdf.py <year> <month> <day> <utchour>
If hour and minute are omitted, this is a daily copy, otherwise hourly.
see: akrherz/iem#199
"""
import sys
import datetime
import numpy as np
from pyiem.util import utc, ncopen, logger
from pyiem import iemre
LOG ... | akrherz/iem | scripts/iemre/db_to_netcdf.py | Python | mit | 1,213 | [
"NetCDF"
] | 2f8f25f4df23ea9474aadb02c080d1b764685bb7dd3e00bd2ff0ac8e67c9a6a2 |
########################################################################
# File: FTSAgent.py
# Author: Krzysztof.Ciba@NOSPAMgmail.com
# Date: 2013/05/31 10:00:13
########################################################################
""" :mod: FTSAgent
==============
.. module: FTSAgent
:synopsis: agent... | arrabito/DIRAC | DataManagementSystem/Agent/FTSAgent.py | Python | gpl-3.0 | 51,312 | [
"DIRAC"
] | 108b2c974607949bb3d5f5dd6fb7600777502824f5455a8fc3148fb1a71cf02e |
from galaxy.jobs import runners
def test_default_specs():
# recheck_missing_job_retries is integer >= 0
params = runners.RunnerParams( specs=runners.BaseJobRunner.DEFAULT_SPECS, params=dict( recheck_missing_job_retries="1" ) )
assert params.recheck_missing_job_retries == 1
assert params["recheck_missi... | mikel-egana-aranguren/SADI-Galaxy-Docker | galaxy-dist/test/unit/jobs/test_runner_params.py | Python | gpl-3.0 | 1,705 | [
"Galaxy"
] | f6a18f8aa5b5fb4927035fd878aeb8b12fb007cbee845aa744c6cb6b5c2ec4e8 |
#!/usr/bin/env python
# Copyright 2014-2018 The PySCF Developers. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# U... | sunqm/pyscf | pyscf/scf/stability_slow.py | Python | apache-2.0 | 9,365 | [
"PySCF"
] | 5793d1934aaf9912bf82f85f9b0987b3f3fc1be9c024c1ab9ad7f7128455134e |
#! /usr/bin/python
###### SUM STATES #######
# Python script for summing and ploting the data from the Density Of States
# files obtained from projwfc.x. It can sum also k-solved dos, and make a plot
# with mathplotlib (if not available, gnuplot, if not avaible, print to file)
# if there is not X11 forwarding, plots ... | qiaojunfeng/q-e | PP/tools/sum_states.py | Python | gpl-2.0 | 8,217 | [
"ESPResSo"
] | 1fb69c2d28f88dd6ad36ef5d9186a4f63446f773ec182091f0f89922938331cd |
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distrib... | Microvellum/Fluid-Designer | win64-vc/2.78/Python/bin/2.78/scripts/addons_contrib/add_mesh_clusters/add_mesh_cluster.py | Python | gpl-3.0 | 49,648 | [
"CRYSTAL"
] | 69b948782dfcd39dde0843dacecc9e17b185347d32b371c37b30fe234fd9cfec |
# Copyright (c) 2003-2013 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 the Free Software
# Foundation; either version 2 of the License, o... | lukaszpiotr/pylama_with_gjslint | pylama/checkers/pylint/utils.py | Python | lgpl-3.0 | 26,254 | [
"VisIt"
] | 80859c3241fe28587e26379bd5099adaa31cb96bcfb2dc11a742a41721d0be0d |
import os
import sys
from argparse import ArgumentParser, RawDescriptionHelpFormatter
import shutil
from generate_tool_list_from_ga_workflow_files import generate_tool_list_from_workflow
from string import Template
INVENTORY_FILE_TEMPLATE = '''
[GKSfromWorkflow]
localhost ansible_connection=local
# if remote target, ... | afgane/GalaxyKickStart | scripts/galaxykickstart_from_workflow.py | Python | gpl-3.0 | 4,495 | [
"Galaxy"
] | 3d9cce7ab0c36bd1e702850581821d2869a5dec41b8486d3f5a0c4bc0f3369ee |
# TODO: Add tests based on taxonomy, once we know how to mock mysql.
import six
import platform
from six.moves import builtins
from copy import deepcopy
from json import dumps
from unittest import TestCase
import sqlite3
try:
from unittest.mock import patch
except ImportError:
from mock import patch
from six... | bamueh/dark-matter | test/blast/test_alignments.py | Python | mit | 68,467 | [
"BLAST"
] | de18fdd4d56760b4bed594a964b4f1d5d97a5e419e041870b5d9ceac42bac445 |
import numpy
import sys
import time
from mceditlib.selection import BoundingBox
from mceditlib.worldeditor import WorldEditor
from mceditlib.test import templevel
from mceditlib import relight
def do_copy(dim, station, relight):
times = 1
boxes = []
for x in range(times):
for z in range(times):
... | vorburger/mcedit2 | src/mceditlib/bench/time_relight_manmade.py | Python | bsd-3-clause | 11,374 | [
"VisIt"
] | b9146850b83196eb224704a94ad09354c45fe88d7a5eaf5249bd2f2a389f5816 |
import os, sys, re
import distutils.dir_util
class CreateApp:
__args = {}
__path = ""
__cwd = ""
__scriptPath = ""
def __init__(self, args, scriptPath):
self.__args = args.command
self.__cwd = os.getcwd()
self.__scriptPath = scriptPath
def validate(self):
if len(self.__args) <= 1:
print "You must p... | adampresley/Blast-for-Basis | blast/commands/CreateApp.py | Python | bsd-2-clause | 1,724 | [
"BLAST"
] | b5800b8606e370303ffc7e87178db1bb7099cac21aa958c1bde2a4e2abb64f52 |
# -*- coding: utf-8 -*-
"""Unit tests for functions calling combinations of tools externally."""
from pathlib2 import Path
import pytest
from imfusion.external import compound
class TestSortBam(object):
"""Unit tests for the sambamba_sort function."""
def test_sambamba_call(self, mocker):
"""Tests... | jrderuiter/im-fusion | tests/imfusion/external/test_ext_compound.py | Python | mit | 1,027 | [
"pysam"
] | 3849e06d28880fdf4abd556dd707d06344ec23d1ee7715133341faba6fb5de83 |
import pickle
from io import BytesIO
import numpy as np
import scipy.sparse
from sklearn.utils.testing import assert_almost_equal
from sklearn.utils.testing import assert_array_equal
from sklearn.utils.testing import assert_array_almost_equal
from sklearn.utils.testing import assert_equal
from sklearn.utils.testing im... | florian-f/sklearn | sklearn/tests/test_naive_bayes.py | Python | bsd-3-clause | 5,716 | [
"Gaussian"
] | f72ee16dfc0a97ee6c73c698dbda1bb0a8c59b58dc8b443b5fa8b5f372cc95cb |
from datetime import datetime
import re
import traceback
import warnings
import numpy as np
import pandas as pd
from collections import defaultdict
from pandas.tslib import OutOfBoundsDatetime
from .core import indexing, ops, utils
from .core.formatting import format_timestamp, first_n_items
from .core.variable impor... | NicWayand/xray | xarray/conventions.py | Python | apache-2.0 | 37,760 | [
"NetCDF"
] | e57239920d3a1ccbe310d9fcc90a145fa70cd6a6e84f6e592a176111b5aa5e54 |
#!/usr/bin/env python
"""
DragonPy - sbc09 memory info
~~~~~~~~~~~~~~~~~~~~~~~~~~~
:created: 2013 by Jens Diemer - www.jensdiemer.de
:copyleft: 2013 by the DragonPy team, see AUTHORS for more details.
:license: GNU GPL v3 or above, see LICENSE for more details.
"""
from __future__ import absolute... | JuhaniImberg/DragonPy | dragonpy/sbc09/mem_info.py | Python | gpl-3.0 | 28,376 | [
"VisIt"
] | 4134c73d354e4d1e8cf46a9bcc1a468a24b5c533a0a67a9edd551f18ae934015 |
import re
import os
from markdown.util import etree
import logging
log = logging.getLogger(__name__)
import MooseDocs
from markdown.inlinepatterns import Pattern
from MooseCommonExtension import MooseCommonExtension
import utils
class MooseImageFile(MooseCommonExtension, Pattern):
"""
Markdown extension for h... | katyhuff/moose | python/MooseDocs/extensions/MooseImageFile.py | Python | lgpl-2.1 | 3,724 | [
"MOOSE"
] | 7c78a1476b281545731f59c15fce9b126e0e1dab5c8ef2e2181d6b3373a3d3a7 |
from __future__ import print_function
import sys
if sys.version_info[0] < 3:
print('This package does not support python2. Try `python3 setup.py`', file=sys.stderr)
sys.exit(1)
import subprocess
from setuptools import setup
from setuptools import find_packages
setup(
name='vaspmd',
version = '0.0',
description... | ExpHP/vaspmd | setup.py | Python | mit | 730 | [
"VASP"
] | 41b99d8dc299c99c62aca9dbfd2f23705563cb8ae2a91cc8ebdb7e6e0e868f40 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (C) 2013 Radim Rehurek <me@radimrehurek.com>
# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html
"""
Deep learning via word2vec's "skip-gram and CBOW models", using either
hierarchical softmax or negative sampling [1]_ [2]_.
The train... | krishna11888/ai | third_party/gensim/gensim/models/word2vec.py | Python | gpl-2.0 | 74,478 | [
"VisIt"
] | e0ecd854503a05067cbf70041c583ea7b81093bced356468d7c66c6f94be3229 |
# -*- coding: utf-8 -*-
# ***********************************************************************
# Copyright (C) 2016 - 2017 Oscar Gerardo Lazo Arjona *
# <oscar.lazoarjona@physics.ox.ac.uk> *
# ***********************************************************************
... | oscarlazoarjona/quantum_memories | examples/orca/doppler_dephasing/doppler_dephasing.py | Python | gpl-3.0 | 7,853 | [
"Gaussian",
"ORCA"
] | 34f7713d73e2da5782de0b779af881245b5ff6467e197a18530f48a88a54c6e1 |
""" Algorithm for clustering : Adaptive Affinity propagation
"""
# Author: Ilya Patrushev ilya.patrushev@gmail.com
# License: BSD clause 3
import numpy as np
import warnings
from sklearn.base import BaseEstimator, ClusterMixin
from sklearn.utils import as_float_array
from sklearn.utils import check_random_state
fro... | ilyapatrushev/isimage | isimage/adaptive_affinity_propagation_.py | Python | gpl-2.0 | 14,868 | [
"Gaussian"
] | d9cda5f8a7433ef80fd49b75c5d49ae942de468cb962d156c78c2060f3d75b2b |
##
## Session 5: Generative Models
##
#
#
# Learning Goals
#
#
# - [Introduction]
# - [Generative Adversarial Networks]
# - [Input Pipelines]
# - [GAN/DCGAN]
# - [Extensions]
# - [Recurrent Networks]
# - [Basic RNN Cell]
# - [LSTM RNN Cell]
# - [GRU RNN Cell]
#
# - [Character Langauge Model]
# - [Set... | dariox2/CADL | session-5/l5b01.py | Python | apache-2.0 | 27,030 | [
"exciting"
] | a96cb87d653d97f7a336d31e40348108c601e5ec75c8e3a46dce45a74ae68299 |
"""
Contains functionality needed in every web interface
"""
import logging
import operator
import os
import re
from gettext import gettext
import pkg_resources
pkg_resources.require("SQLAlchemy >= 0.4")
from sqlalchemy import func, and_, select
from paste.httpexceptions import HTTPBadRequest, HTTPInternalServerError... | mikel-egana-aranguren/SADI-Galaxy-Docker | galaxy-dist/lib/galaxy/web/base/controller.py | Python | gpl-3.0 | 142,060 | [
"Galaxy"
] | be111a634b6344ae2899b8ff385f867b435aae7e217cafa206ff9a08b874cbd7 |
#!/bin/env python
""" dummy testing for RequestContainer
:deprecated:
"""
import xml.dom.minidom
from DIRAC.RequestManagementSystem.Client.RequestContainer import RequestContainer
def getRequest( operation ):
""" fake requestDict
:param str operation: sub-request operation attribute
"""
requestConta... | avedaee/DIRAC | RequestManagementSystem/test/RequestContainerTests.py | Python | gpl-3.0 | 2,567 | [
"DIRAC"
] | 38c2b0db7ef83e29090cf1845622eef2ae12083ed351543f6c1f2b82c159540f |
from selenium.common.exceptions import NoSuchElementException
from e2e.config import LMS_URL_ROOT, MARKETING_URL_ROOT
from e2e.helpers import EcommerceHelpers, LmsHelpers
import pytest # isort:skip
def test_login_and_logout(selenium):
""" Authenticating with the identity provider (LMS) should authenticate us... | eduNEXT/edunext-ecommerce | e2e/test_auth.py | Python | agpl-3.0 | 2,030 | [
"VisIt"
] | 4d37c5645fb8e2592cfc5765c0d1e4c2fa3b3d04d7692f5aee44a62a3b3e4d93 |
# class generated by DeVIDE::createDeVIDEModuleFromVTKObject
from module_kits.vtk_kit.mixins import SimpleVTKClassModuleBase
import vtk
class vtkMetaImageReader(SimpleVTKClassModuleBase):
def __init__(self, module_manager):
SimpleVTKClassModuleBase.__init__(
self, module_manager,
vt... | chrisidefix/devide | modules/vtk_basic/vtkMetaImageReader.py | Python | bsd-3-clause | 488 | [
"VTK"
] | a07f625127176615d0f3997fba49c8e24523eeef5b7947d0d232bce9db4216c6 |
# Copyright 2008 Brian Boyer, Ryan Mark, Angela Nitzke, Joshua Pollock,
# Stuart Tiffen, Kayla Webley and the Medill School of Journalism, Northwestern
# University.
#
# This file is part of Crunchberry Pie.
#
# Crunchberry Pie is free software: you can redistribute it and/or modify
# it under the terms of the GNU Gene... | brianboyer/newsmixer | social/questions/admin.py | Python | gpl-3.0 | 989 | [
"Brian"
] | 52ffe15c42d6604395344c66580f1a72560fa349552ee628617faf6f5e46fbb0 |
#########################################################################################
#
# Script to populate the DIRAC FileCatalog with the information from the LFC
# FileCatalog using multiple LFC sources
#
# Author: A.Tsaregorodtsev
# Last Modified: 9.01.2012
#
###################################################... | andresailer/DIRAC | DataManagementSystem/Utilities/lfc_dfc_copy.py | Python | gpl-3.0 | 8,617 | [
"DIRAC",
"exciting"
] | e213f56cd95be00a966219bc6d558613fc678412bbd9ddf1b9fceeb9f75f4e2c |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Detect objects on the image."""
import copy
import numpy as np
import scipy.stats as st
import scipy.ndimage as ndimage
from scipy.ndimage.filters import gaussian_filter
from astropy.io import fits
from astropy.table import Table, Column
import sep
from kungpao.imt... | dr-guangtou/KungPao | kungpao/detection.py | Python | gpl-3.0 | 11,610 | [
"Gaussian"
] | 5b68372b958b4bf07e8d698e360913b8ae297a59ca6611a4a2d8f0e4ebe9e4af |
# -*- coding: utf-8 -*-
"""
Regression tests for the Test Client, especially the customized assertions.
"""
from __future__ import unicode_literals
import os
from django.conf import settings
from django.core.exceptions import SuspiciousOperation
from django.core.urlresolvers import reverse
from django.template import... | openhatch/new-mini-tasks | vendor/packages/Django/tests/regressiontests/test_client_regress/tests.py | Python | apache-2.0 | 48,934 | [
"VisIt"
] | 52c035af4f011775fce69bf5c386bfa5270b06b336933e0a070a309f02cb79c8 |
# -*- coding: utf-8 -*-
#
# one_neuron_with_noise.py
#
# This file is part of NEST.
#
# Copyright (C) 2004 The NEST Initiative
#
# NEST is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 of the L... | SepehrMN/nest-simulator | pynest/examples/one_neuron_with_noise.py | Python | gpl-2.0 | 3,147 | [
"NEURON"
] | 66fd4a234190ecfbc0786b21623bcbb3b4bbd2fbb66ff6796c3ed52fc9c17528 |
from .check import assert_subclass
class Visitor(object):
def resolve_method(self, item):
for cls in item.__class__.__mro__:
name = 'visit_' + cls.__name__
method = getattr(self, name, None)
if method:
return method
raise ValueError('no method f... | bureaucratic-labs/yargy | yargy/visitor.py | Python | mit | 823 | [
"VisIt"
] | 9da509c59cdd86973521c3147be16fa5c29f669daac4a268d1bb0a4995291247 |
#! /usr/bin/env python
# -*- coding: utf-8 -*-
###############################################################################
## ##
## Copyright 2010-2012, Neil Wallace <neil@openmolar.com> ##
## ... | rowinggolfer/openmolar2 | src/lib_openmolar/common/import_export/export_xls.py | Python | gpl-3.0 | 5,111 | [
"VisIt"
] | f0f0c91a5db718c6e19880bf469e1e880677affdf2a0f457a677545bdc4364b4 |
"""
Basic functions for working with images.
"""
from __future__ import division, print_function, absolute_import
import itertools as itr
import numpy as np
def _import_skimage():
"""Import scikit-image, with slightly modified `ImportError` message"""
try:
import skimage
except ImportError:
... | agarbuno/deepdish | deepdish/image.py | Python | bsd-3-clause | 9,113 | [
"Gaussian"
] | 20e6f611ccf5d3b708363ee5b524642d0a88314c7d3c6ff737eb43d99e88a829 |
#!/usr/bin/env python
#PBS -N HooverNPT
#PBS -m ae
#PBS -q long
#PBS -l nodes=1:opteron
from numpy import *
from Scientific.Statistics import *
from asap3 import *
from asap3.md.npt import *
from asap3.md.langevin import *
from ase.md.velocitydistribution import *
from ase.lattice.cubic import FaceCenteredCubic
from ... | auag92/n2dm | Asap-3.8.4/Test/HooverNPT.py | Python | mit | 5,068 | [
"ASE"
] | 43b95e968307956230c4ee14fc14850427e3e8f0b5caa039519e50f1578d76f1 |
# 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/constraint_shape_based.py | Python | gpl-3.0 | 43,664 | [
"ESPResSo"
] | cd8caf14bd8b486e2990c64daa15e42b164ef97799549d852aa2532e8885b802 |
# coding: utf-8
from __future__ import print_function#, unicode_literals
from six import iteritems
#from struct import pack
from pyNastran.bdf.bdf import BDF
from pyNastran.op2.op2 import OP2
from numpy import zeros, searchsorted, arange
#def pack_nodes(fmt, data):
#return ''
def pack_int_array(fmt, data):
r... | saullocastro/pyNastran | pyNastran/op2/export_to_vtk.py | Python | lgpl-3.0 | 11,895 | [
"VTK"
] | 2b1c1615c4be8059cc5bae2f7cd405f9756e9c5874828542b8df7951231395b5 |
"""
BayesFlare
==========
Provides:
1. A number of pythonic means for handling lightcurve data from the Kepler spacecraft
2. A set of functions for conducting analysis of the lightcurve data to find flaring events
Using the documentation
-----------------------
Documentation for pyFlare is available in the for... | BayesFlare/bayesflare | bayesflare/__init__.py | Python | gpl-2.0 | 1,479 | [
"Gaussian"
] | 4ae08cef7129e6bbd39fa21e239a6967a5a922909c8a9299bbab1cf5c658121e |
#!/usr/bin/env python
##
## Biskit, a toolkit for the manipulation of macromolecular structures
## Copyright (C) 2004-2012 Raik Gruenberg & Johan Leckner
##
## This program is free software; you can redistribute it and/or
## modify it under the terms of the GNU General Public License as
## published by the Free Softwar... | ostrokach/biskit | scripts/Biskit/amberConcat.py | Python | gpl-3.0 | 6,116 | [
"Amber"
] | 1e4eb71df3130b8cabe0d75b076ead760039a0658e9874a93b1e137377632045 |
# imports needed
import matplotlib as mpl
mpl.use('Agg')
from smarty.forcefield import *
import openeye
from openeye import oechem
import smarty
from smarty.utils import get_data_filename
from simtk import openmm
from simtk import unit
import numpy as np
import netCDF4 as netcdf
import collections as cl
import panda... | bmanubay/open-forcefield-tools | single-molecule-property-generation/manipulateparameters.py | Python | mit | 59,104 | [
"NetCDF",
"OpenMM"
] | fdd6dd44499b83a681f5dff46c278b428af827864edea23d5fedf54bd15509e3 |
# pylint: disable=arguments-differ
""" Models for the shopping cart and assorted purchase types """
import csv
import json
import logging
import smtplib
from collections import namedtuple
from datetime import datetime, timedelta
from decimal import Decimal
import pytz
import six
from boto.exception import BotoServer... | edx-solutions/edx-platform | lms/djangoapps/shoppingcart/models.py | Python | agpl-3.0 | 90,364 | [
"VisIt"
] | dccd900365183123be613e05de4f3bd7a81c7222a5bcf8c71666bc68f86e0456 |
# -*- coding: utf-8 -*-
from ase.neb import get_NEB_plot
def NudgedElasticBand(images):
fig = get_NEB_plot(images)
fig.show()
| askhl/ase | ase/gui/neb.py | Python | gpl-2.0 | 137 | [
"ASE"
] | 8ba6f5938bc4e7551ec73e9bf3cc96b1c216ea809776ec7aed8c6b5e16d0706e |
# -*- coding: utf-8 -*-
# (c) The James Hutton Institute 2019
# (c) University of Strathclyde 2019
# Author: Leighton Pritchard
#
# Contact:
# leighton.pritchard@strath.ac.uk
#
# Leighton Pritchard,
# Strathclyde Institute for Pharmacy and Biomedical Sciences,
# Cathedral Street,
# Glasgow,
# G1 1XQ
# Scotland,
# UK
#
... | widdowquinn/pyani | pyani/blast.py | Python | mit | 2,541 | [
"BLAST"
] | 992cc85cee63ff2cc18c5edf38472b52a3fe46f997cd2b1738c530c149bc3d86 |
################################################################################
#
# Copyright 2015-2021 Félix Brezo and Yaiza Rubio
#
# This program is part of OSRFramework. You can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Softwa... | i3visio/osrframework | osrframework/domainfy.py | Python | agpl-3.0 | 22,372 | [
"VisIt"
] | d21593562037fda55d4f4f786179c3ef833a7d92fa75725a58693e7a11a8321b |
#!/usr/bin/env python
'''
Hartree-Fock/DFT with k-points sampling for all-electron calculations
GDF (Gaussian density fitting), MDF (mixed density fitting), RSGDF
(range-separated Gaussian density fitting), or RS-JK builder
can be used in all electron calculations. They are more efficient than the
default SCF JK buil... | sunqm/pyscf | examples/pbc/21-k_points_all_electron_scf.py | Python | apache-2.0 | 2,174 | [
"Gaussian",
"PySCF"
] | b26b9e5ec72427b46fa89fd2cae2db95fa9a7fa5ea23a7a856f67da7cb1eb3b1 |
import numpy as np
import matplotlib.pyplot as plt
from numpy import atleast_2d as twod
################################################################################
## PLOTTING FUNCTIONS #########################################################
###################################################################... | sameersingh/ml-discussions | week3/mltools/plot.py | Python | apache-2.0 | 4,914 | [
"Gaussian"
] | 300450089e4af615768ae315d3177d1ec182b1ef12bd0108b606500c9a5f5404 |
import numpy as np
from astropy import units as u
import pyspeckit
xaxis = np.linspace(-50,150,100.) * u.km/u.s
sigma = 10. * u.km/u.s
center = 50. * u.km/u.s
synth_data = np.exp(-(xaxis-center)**2/(sigma**2 * 2.))
# Add noise
stddev = 0.1
noise = np.random.randn(xaxis.size)*stddev
error = stddev*np.ones_like(synth_d... | low-sky/pyspeckit | docs/basic_plot.py | Python | mit | 2,651 | [
"Gaussian"
] | 617f6d3fa6db08ce6e0e8e7b4d2f262454ab8f5ada4821be98da8042853a3d5b |
# -*- coding: utf-8 -*-
import numpy as np
import datetime
import pytest
import pysteps
from pysteps import cascade, blending
steps_arg_names = (
"n_models",
"n_timesteps",
"n_ens_members",
"n_cascade_levels",
"mask_method",
"probmatching_method",
"blend_nwp_members",
"weights_method"... | pySTEPS/pysteps | pysteps/tests/test_blending_steps.py | Python | bsd-3-clause | 9,737 | [
"Gaussian"
] | 7a04152847fde05c14e181ed6f4c484258f969ed3f192016c6028c234979955e |
# Copyright Iris contributors
#
# This file is part of Iris and is released under the LGPL license.
# See COPYING and COPYING.LESSER in the root of the repository for full
# licensing details.
"""
Test pickling of Iris objects.
"""
# Import iris tests first so that some things can be initialised
# before importing an... | SciTools/iris | lib/iris/tests/test_pickling.py | Python | lgpl-3.0 | 4,558 | [
"NetCDF"
] | 86d3eb62fce352d95b5213e6db46a839f933748643390fbfdbc792a92c866205 |
# -*- coding: utf-8 -*-
# (c) 2016 Andreas Motl <andreas.motl@elmyra.de>
import types
import tempfile
from pprint import pprint
from string import Template
from pkg_resources import resource_string
from twisted.web.template import renderElement
from twisted.logger import Logger
from kotori.io.export.html import Dygraph... | zerotired/kotori | kotori/io/export/plot.py | Python | agpl-3.0 | 14,575 | [
"NetCDF"
] | 162197733836d2fa0127d4e71ac2a2c56479ebff691775bc4121a0408c00d546 |
# Copyright (c) 2015 Ansible, Inc.
# All Rights Reserved.
# Python
import inspect
import logging
import time
import uuid
import urllib.parse
# Django
from django.conf import settings
from django.core.cache import cache
from django.db import connection
from django.db.models.fields import FieldDoesNotExist
from django.... | GoogleCloudPlatform/sap-deployment-automation | third_party/github.com/ansible/awx/awx/api/generics.py | Python | apache-2.0 | 43,854 | [
"VisIt"
] | 99576a4541001357b74b26e6a314eff884f00793c580238a4af33216b01a6c40 |
# -*- coding: utf-8 -*-
#
# gPrime - A web-based genealogy program
#
# Copyright (C) 2000-2006 Donald N. Allingham, A. Roitman
# Copyright (C) 2007-2009 B. Malengier
# Copyright (C) 2008 Lukasz Rymarczyk
# Copyright (C) 2008 Raphael Ackermann
# Copyright (C) 2008 Brian G. Matherly
# Copyright (C) 20... | sam-m888/gprime | gprime/cli/argparser.py | Python | gpl-2.0 | 20,299 | [
"Brian"
] | 27e2e532052d6b88ef0533b6092f97706a678172f333a3c422193ebbef8ffa08 |
#
# Copyright (C) 2013-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... | fweik/espresso | testsuite/python/coulomb_cloud_wall_duplicated.py | Python | gpl-3.0 | 3,375 | [
"ESPResSo"
] | 41c89e5b4906dbd3f331852a8be5f5cdeab6ed5fb7bbbdcadaf14cc4a4bceccf |
#!/usr/local/bin/python -i
# preceeding line should have path for Python on your machine
# vizplotgui_vmd.py
# Purpose: viz running LAMMPS simulation via VMD with plot and GUI
# Syntax: vizplotgui_vmd.py in.lammps Nfreq compute-ID
# in.lammps = LAMMPS input script
# Nfreq = plot data point and viz s... | val-github/lammps-dev | python/examples/vizplotgui_vmd.py | Python | gpl-2.0 | 4,392 | [
"LAMMPS",
"VMD"
] | 7a291fcb85727dd3d51e04ae106e5d5d28a4a7e940206a554ae2186da7ba82ea |
#!/usr/bin/env python3
# Computes exact similarity solution "test Q" at an initial time and after
# a specified runtime. Suggests a PISM run for this runtime. The exact
# solution for velocity and for thickness can be compared to PISM output.
#
# For the similarity solution see equation (3.19) in
# [\ref PeglerListe... | pism/pism | src/verification/tests/exactQ.py | Python | gpl-3.0 | 6,138 | [
"NetCDF"
] | 7a104b5220a6e3ccc9d2773417727997279917ba73a8022fb15f1039519a84cb |
# -*- coding: utf-8 -*-
import datetime
import hashlib
import json
import os
import tarfile
from copy import deepcopy
from tempfile import mkdtemp
from django.conf import settings
from django.core import mail
from django.core.management import call_command
from django.core.urlresolvers import reverse
import mock
from... | washort/zamboni | mkt/webapps/tests/test_tasks.py | Python | bsd-3-clause | 27,242 | [
"exciting"
] | 36479b61bfb382d326f474970d6507666f834b5e81627ad197e9bec0290d8bbe |
from __future__ import annotations
import os
import procrunner
import pytest
from dxtbx.model.experiment_list import ExperimentListFactory
def plot_beam_centre_error(ideal_bc, obs_bc):
import matplotlib.pyplot as plt
ideal_x, ideal_y = zip(*ideal_bc)
obs_x, obs_y = zip(*obs_bc)
del_x = [a - b for ... | dials/dials | tests/algorithms/refinement/test_scan_varying_beam_refinement.py | Python | bsd-3-clause | 2,914 | [
"CRYSTAL"
] | 14df39e6f066a819c32ec722e1c167b74f2491204b41b81686c41e7a2cb7805f |
import os
from ase import Atom, Atoms
from ase.units import Bohr
from gpaw import GPAW
from gpaw.test import equal
a = 7.5 * Bohr
n = 16
atoms = Atoms([Atom('He', (0.0, 0.0, 0.0))], cell=(a, a, a), pbc=True)
calc = GPAW(gpts=(n, n, n), nbands=1, xc='LDA')
atoms.set_calculator(calc)
e1 = atoms.get_potential_energy()
ni... | qsnake/gpaw | gpaw/test/nonselfconsistentLDA.py | Python | gpl-3.0 | 1,173 | [
"ASE",
"GPAW"
] | a3226edb78a4a63fa88d9fa3c17a5eca8982b0983618265ef2a4da0e8f952df7 |
#TFLOW Segment: Find Gene Annotations for Query Sequence File useing Reference Nucleotide or
# Protein Sequence File
#
#Dan Stribling
#Florida State University
#Center for Genomics and Personalized Medicine
#Version 0.9, 05/22/2015
#Project URL: http://www.github.com/fsugenomics/tflow
import os.path
imp... | FSUgenomics/TFLOW | tflow/segments/Prototype_Find_Annotations.py | Python | gpl-2.0 | 38,150 | [
"BLAST"
] | 9e90862ffba083a41f11a0eedb61a86e1f6da0922b5997892fa7e42a6cc7e0ea |
# -*- coding: utf-8 -*-
"""Algorithms for spectral clustering"""
# Author: Gael Varoquaux gael.varoquaux@normalesup.org
# Brian Cheung
# Wei LI <kuantkid@gmail.com>
# License: BSD 3 clause
#import warnings
class warnings:None
warnings.warn=lambda x:1
import warnings
import numpy as np
from spectral_em... | wolfiex/DSMACC-testing | dsmacc/examples/_spectral.py | Python | gpl-3.0 | 22,357 | [
"Brian",
"Gaussian"
] | c131f1b9fa864aa018ea78f3bc7d85efff47adbefab85d58867e6a72c07e527b |
"""
Generate samples of synthetic data sets.
"""
# Authors: B. Thirion, G. Varoquaux, A. Gramfort, V. Michel, O. Grisel,
# G. Louppe, J. Nothman
# License: BSD 3 clause
import numbers
import warnings
import numpy as np
from scipy import linalg
from ..preprocessing import MultiLabelBinarizer
from ..utils imp... | chaluemwut/fbserver | venv/lib/python2.7/site-packages/sklearn/datasets/samples_generator.py | Python | apache-2.0 | 52,427 | [
"Gaussian"
] | 49445f2caefe5611b22fa877921dbe30198fe3d09a6697dbd69cd9f3a49a9216 |
#!/usr/bin/env python
import matplotlib
matplotlib.rcParams['legend.fancybox'] = True
import matplotlib.pyplot as plt
import numpy as np
#define some data
x = [32, 5032, 10032, 15032, 20032]
pc_mean = [0.946, 3.014, 3.903, 4.228, 4.539]
s3mini_mean = [2.764, 59.412, 30.321, 86.975, 183.882]
s3_mean = [1.649, 36.336... | edlectrico/dissertation | graphics/pellet_abox.py | Python | apache-2.0 | 2,927 | [
"Galaxy"
] | 79d10999b5efdab7c084a92bb802827ecab5d0b482f1353ce6190b2ebb8533d9 |
#
# (c) 2015 Brian Ccoa, <bcoca@ansible.com>
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later versio... | camradal/ansible | lib/ansible/module_utils/api.py | Python | gpl-3.0 | 3,560 | [
"Brian"
] | 7e1a9b7f07a5fc48206a923d35b6cfe5edc3c73035011bc040204e21af452e12 |
from collections import deque
import time
import requests
# Constants
BRAZIL = 'br'
EUROPE_NORDIC_EAST = 'eune'
EUROPE_WEST = 'euw'
KOREA = 'kr'
LATIN_AMERICA_NORTH = 'lan'
LATIN_AMERICA_SOUTH = 'las'
NORTH_AMERICA = 'na'
OCEANIa = 'oce'
RUSSIA = 'ru'
TURKEY = 'tr'
queue_types = [
'CUSTOM', # Cu... | yilinhe/MOBA-TeamCompDecoding | lol-data-collection/riotwatcher.py | Python | mit | 18,933 | [
"CRYSTAL"
] | a04f7096a341b9f80cd574ac8d4d48776732168e09bbcd5511ce64bfb0769a53 |
#
# @BEGIN LICENSE
#
# Psi4: an open-source quantum chemistry software package
#
# Copyright (c) 2007-2017 The Psi4 Developers.
#
# The copyrights for code used from other parties are included in
# the corresponding files.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of ... | kratman/psi4public | psi4/driver/qcdb/cfour.py | Python | gpl-2.0 | 46,066 | [
"CFOUR",
"Psi4"
] | 27b671c5127e22fd6f537d7425141955eb4e055e2b71587646a9b7c5b68b0d68 |
#!/usr/bin/env python
import logging
import sys
import argparse
import vcf
import pysam
from metasv.breakdancer_reader import BreakDancerReader
from metasv.pindel_reader import PindelReader
from metasv.cnvnator_reader import CNVnatorReader
from metasv.breakseq_reader import BreakSeqReader
from metasv.vcf_utils import... | chapmanb/metasv | scripts/svtool_to_vcf.py | Python | bsd-2-clause | 3,249 | [
"pysam"
] | c22c56e6e7a17746946d80e0fce0da7e2c1642967ab244c267b7bffd1c9c4272 |
# coding=utf-8
# Copyright 2022 The Mesh 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 applicab... | tensorflow/mesh | mesh_tensorflow/transformer/transformer_layers.py | Python | apache-2.0 | 91,110 | [
"MOE"
] | 9f2463fd3aaead0997ab741624977a91a6a9f27cb1b324ee32a061f7c36b4135 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.