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 |
|---|---|---|---|---|---|---|---|
"""
View for Courseware Index
"""
# pylint: disable=attribute-defined-outside-init
from datetime import datetime
from django.conf import settings
from django.contrib.auth.decorators import login_required
from django.contrib.auth.models import User
from django.core.context_processors import csrf
from django.core.urlreso... | fintech-circle/edx-platform | lms/djangoapps/courseware/views/index.py | Python | agpl-3.0 | 21,468 | [
"VisIt"
] | 5a97c11775c7637c361d9884e8b23de113c2bd7f9122d1fdf2693bfcb0820263 |
#!/usr/bin/python
#
# @author: Gaurav Rastogi (grastogi@avinetworks.com)
# Eric Anderson (eanderson@avinetworks.com)
# module_check: supported
# Avi Version: 17.1.1
#
# Copyright: (c) 2017 Gaurav Rastogi, <grastogi@avinetworks.com>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses... | thaim/ansible | lib/ansible/modules/network/avi/avi_sslprofile.py | Python | mit | 8,508 | [
"VisIt"
] | 8b8ec0a1ef2431f34ec517e5f5baf175ad43a891135b5a1828c16532caf91a9d |
# coding=utf-8
# Copyright 2020 The TF-Agents 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable la... | tensorflow/agents | tf_agents/policies/samplers/cem_actions_sampler_continuous.py | Python | apache-2.0 | 7,825 | [
"Gaussian"
] | 0a7a83041334f5dee23501036042a78c28bc4b53b45dd8871ee8bbe737ab297b |
# Licensed under MIT
# <tom@viabledata.co.uk>
"""The tests for space.py
"""
import pytest
from core.space import Spaceship
def setup():
"""This function will always run before any tests.\n
Use it to set up the test environment, as required.
"""
print("SETUP!")
def teardown():
"""This function w... | tomfitzherbert/pyexample | tests/test_space.py | Python | mit | 795 | [
"Firefly"
] | 2796a59e6fe08fca939ea21accc68dc7db3bda361f1740636ffb32670eed0965 |
#!/usr/bin/env python2
# Copyright (C) 2011-2012 by Imperial College London
# Copyright (C) 2013 University of Oxford
# Copyright (C) 2014 University of Edinburgh
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the... | pf4d/dolfin-adjoint | timestepping/python/timestepping/vtu_io.py | Python | lgpl-3.0 | 17,886 | [
"VTK"
] | d1859012000509b10a87296d05e52fc2eea7ab9e3e2aeee77d94ad812d2fb173 |
#
# Copyright 2018 Analytics Zoo Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to... | intel-analytics/analytics-zoo | pyzoo/zoo/chronos/use-case/network_traffic/network_traffic_autots_multivariant_example_deprecated.py | Python | apache-2.0 | 4,023 | [
"ORCA"
] | fc408c8c7b084adc692e5fe614151f551cd943bfbd76c60fd52dcdfc0f8b1ac5 |
# class generated by DeVIDE::createDeVIDEModuleFromVTKObject
from module_kits.vtk_kit.mixins import SimpleVTKClassModuleBase
import vtk
class vtkImageReader2(SimpleVTKClassModuleBase):
def __init__(self, module_manager):
SimpleVTKClassModuleBase.__init__(
self, module_manager,
vtk.v... | nagyistoce/devide | modules/vtk_basic/vtkImageReader2.py | Python | bsd-3-clause | 472 | [
"VTK"
] | dd5e8343b5baf9cc09fa57bae526238a705d77d7a9dba11e533225307ec0f59f |
#!/usr/bin/env python
# filename: abstar.py
#
# Copyright (c) 2015 Bryan Briney
# License: The MIT license (http://opensource.org/licenses/MIT)
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software
# and associated documentation files (the "Software"), to deal in the Softwar... | briney/abstar | abstar/core/abstar.py | Python | mit | 53,463 | [
"Biopython"
] | 958b45c3854d42faa60d130e999cba8ea924ff4fb727c67de00567026ad1f419 |
#!/usr/bin/env python
# Copyright (c) 2016 Terry D. Ott.
#
# You may use, distribute, and modify this code under the terms
# of the MIT License.
#
# You should have received a copy of the MIT License with this
# file. If not, please visit:
#
# https://github.com/TerryOtt/segmentcsv2kml/blob/master/LICENSE ... | TerryOtt/segmentcsv2kml | segmentcsv2kml.py | Python | mit | 8,306 | [
"VisIt"
] | bb4f12337ea43175bdc1839cb181d456975525362d5743741773428285b05e67 |
#!/usr/bin/env python
# Copyright 2014-2020 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/cc/test/test_gccsd.py | Python | apache-2.0 | 18,705 | [
"PySCF"
] | 43455b33617fa8ea6893628454e7e6f8f83c672aa9b351e60b75a6797d19caae |
#
# @BEGIN LICENSE
#
# Psi4: an open-source quantum chemistry software package
#
# Copyright (c) 2007-2019 The Psi4 Developers.
#
# The copyrights for code used from other parties are included in
# the corresponding files.
#
# This file is part of Psi4.
#
# Psi4 is free software; you can redistribute it and/or modify
#... | CDSherrill/psi4 | psi4/driver/procrouting/wrappers_cfour.py | Python | lgpl-3.0 | 36,345 | [
"CFOUR",
"Psi4"
] | 0c8559d66f10f81e11da61693da96930d3486066a0b699aa7e3b733e3be31ec9 |
import sys
import optparse
import numpy as np
from ase.io import read, write
from ase.db import connect
from ase.lattice import bulk
from ase.structure import molecule
from ase.atoms import Atoms, string2symbols
from ase.data import ground_state_magnetic_moments
from ase.data import atomic_numbers, covalent_radii... | grhawk/ASE | tools/ase/cli/build.py | Python | gpl-2.0 | 5,088 | [
"ASE",
"CRYSTAL"
] | a5970a16bbd0854d087fbd7478bb1be74754a70fca824089539dcf36ecc4ff44 |
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not us... | vikkyrk/incubator-beam | sdks/python/apache_beam/runners/runner.py | Python | apache-2.0 | 11,906 | [
"VisIt"
] | d9335f745e04126759876f9b66fe60bc8fa43f56e575125005ff240357b1cdf5 |
# -*- coding: utf-8 -*-
# Copyright: (c) 2019-2021, Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
"""Installed collections management package."""
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import errno
import f... | renard/ansible | lib/ansible/galaxy/collection/__init__.py | Python | gpl-3.0 | 66,348 | [
"Galaxy"
] | f9797fabf37ed147754a2af7ccb969ffba623d480d4943e21da988ab3536536f |
import numpy as np
import random as rand
import sys, os
import copy
import pickle
from mpi4py import MPI
from pymatgen import Lattice, Structure, Element
from pymatgen.io.vasp import Poscar, VaspInput
from pymatgen.analysis.structure_matcher import StructureMatcher, FrameworkComparator
from pymatgen.apps.borg.hive imp... | skasamatsu/py_mc | examples/HAp-bulk/HAp.py | Python | gpl-3.0 | 3,967 | [
"VASP",
"pymatgen"
] | abd6024b4724b119d2341e8cf03e983a641a57adac21b5e92607325756a6d6cc |
"""
#;+
#; NAME:
#; build_casbah_galaxies
#; Version 1.0
#;
#; PURPOSE:
#; Module for buildling CASBAH galaxy database
#; 02-Jan-2015 by JXP
#;-
#;------------------------------------------------------------------------------
"""
from __future__ import print_function, absolute_import, division, unicode_literal... | profxj/xastropy | xastropy/casbah/galaxies.py | Python | bsd-3-clause | 31,342 | [
"Galaxy"
] | b31b88c9055580636a4c82c0ed914fc6b219965d5caca679867298c9ff5bf466 |
"""
This app is intended to provide the core functionality for tracking user
engagement with content and Kolibri in general. As such, it is intended
to store details of user interactions with content, a summary of those
interactions, interactions with the software in general, as well as user
feedback on the content and... | 66eli77/kolibri | kolibri/logger/models.py | Python | mit | 4,032 | [
"VisIt"
] | ccb5614e5971e6aa8dfc13beaff32653cfd1d748810b0dd30741eafd9cd5a093 |
"""
This module contains scatterplot smoothers, that is classes
who generate a smooth fit of a set of (x,y) pairs.
"""
# pylint: disable-msg=C0103
# pylint: disable-msg=W0142
# pylint: disable-msg=E0611
# pylint: disable-msg=E1101
from __future__ import print_function
import numpy as np
from . import kernels
#import n... | hlin117/statsmodels | statsmodels/sandbox/nonparametric/smoothers.py | Python | bsd-3-clause | 12,607 | [
"Gaussian"
] | 0104907f53514731bc822fcb5ad3319861b065f36d9164a62c88a7265bb735ae |
import os
import sys
import subprocess
from .exceptions import PyperclipException
EXCEPT_MSG = """
Pyperclip could not find a copy/paste mechanism for your system.
For more information, please visit https://pyperclip.readthedocs.org """
PY2 = sys.version_info[0] == 2
text_type = unicode if PY2 else str
def i... | google/ci_edit | third_party/pyperclip/clipboards.py | Python | apache-2.0 | 4,145 | [
"VisIt"
] | 5a7c83820a3b3fb2fa27ee7bf0c0eb6b11cfb56014bd3352916c3f939780ae4d |
# Libraries
import pandas as pd
import editdist
import mmap
import os
import sys
import time
import itertools
import gzip
import numpy as np
from collections import Counter
import random
# ALIGNER BLAST
def rasl_probe_blast(read_file_path, blastn_path, db_path):
"""
This function returns blast results ... | erscott/RASLseqTools | RASLseqTools/RASLseqAnalysis_old.py | Python | mit | 24,561 | [
"BLAST"
] | 1fea6f9d5903747b619c8cbfda1d9d347e586f37e257327eb566a17d70b20a3e |
import warnings
import numpy as np
from numpy.testing import (assert_equal, assert_raises,
assert_allclose)
import numpy.testing as npt
from scipy.special import gamma, factorial, factorial2
import scipy.stats as stats
from statsmodels.distributions.edgeworth import (_faa_di_bruno_partiti... | statsmodels/statsmodels | statsmodels/distributions/tests/test_edgeworth.py | Python | bsd-3-clause | 6,440 | [
"Gaussian"
] | 3a99a5acd1582f630bb37fda4bb60c5b86de1284273f7181206146f96c9db784 |
"""Classes for configuring feature generation"""
from __future__ import annotations
import os
import re
import subprocess
from abc import abstractmethod
from typing import TYPE_CHECKING, Any, Dict, List, NamedTuple, Union
from montreal_forced_aligner.abc import KaldiFunction
from montreal_forced_aligner.utils import ... | MontrealCorpusTools/Montreal-Forced-Aligner | montreal_forced_aligner/corpus/features.py | Python | mit | 26,867 | [
"Gaussian"
] | 3fe3c13b6bb60146536c4a5e667d253c27f7d9ce4704dace827a34f4aa7437a6 |
from sqlalchemy import *
from sqlalchemy.orm import *
from sqlalchemy.exceptions import *
from migrate import *
from migrate.changeset import *
import datetime
now = datetime.datetime.utcnow
import sys, logging
log = logging.getLogger( __name__ )
log.setLevel(logging.DEBUG)
handler = logging.StreamHandler( sys.stdout... | dbcls/dbcls-galaxy | lib/galaxy/model/migrate/versions/0003_security_and_libraries.py | Python | mit | 41,566 | [
"Galaxy"
] | 2b2d28f4bc8aa3e9b999770c92654fba546d662a0c0b8c7b7fb4c8c5451f81a9 |
import matplotlib.pyplot as plt
import numpy as np
import seaborn as sns
import sqlite3 as sqlite
import pandas as pd
from scipy import stats
import pylab
from sklearn.neighbors import KernelDensity
from scipy.stats import mode
import json
from json2html import *
from scipy.stats import norm
from sklearn.preprocessing ... | selinerguncu/Yelp-Spatial-Analysis | analysis/analysisEDA.py | Python | mit | 31,668 | [
"Gaussian"
] | 9936936e7c0dba178d7fb9362f924f324e2526f2b63e087b595b120e8cf6864e |
#!/usr/bin/env python3
#* This file is part of the MOOSE framework
#* https://www.mooseframework.org
#*
#* All rights reserved, see COPYRIGHT for full restrictions
#* https://github.com/idaholab/moose/blob/master/COPYRIGHT
#*
#* Licensed under LGPL 2.1, please see LICENSE for details
#* https://www.gnu.org/licenses/lgp... | nuclear-wizard/moose | python/peacock/tests/input_tab/JsonData/test_JsonData.py | Python | lgpl-2.1 | 1,885 | [
"MOOSE"
] | 0019908d7046791542a6a31767634280aa46ca5b1f8d0c38af4946c2d5aadf26 |
import setuptools
from distutils.core import Extension
import os
# Read the markdown files for the long description
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
for filename in filenames:
if os.path.exists(filename):
... | linsalrob/PhiSpy | setup.py | Python | mit | 2,480 | [
"Biopython"
] | 01e5e01725dbe4f386040a5097b5f95ebb8fdd734dc8116fe32fb6851a059e05 |
#! /usr/bin/env python
# -*- encoding: utf-8 -*-
"""Get lattice vector in a, b, c, α, β, γ format from ase-compatible file"""
###############################################################################
# Copyright 2015 Adam Jackson
###############################################################################
# ... | ajjackson/mctools | mctools/vectors.py | Python | gpl-3.0 | 4,133 | [
"ASE"
] | 7358ab86b1c45e44a70d0f160544110c1f92f6f1b44653b47913d099ba2af2ab |
# ----------------------------------------------------------------------------
# Copyright (c) 2013--, scikit-bio development team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file COPYING.txt, distributed with this software.
# --------------------------------------------... | kdmurray91/scikit-bio | skbio/diversity/alpha/tests/test_base.py | Python | bsd-3-clause | 10,309 | [
"scikit-bio"
] | a8c77d12ab50c361e4508a9e3fe36553fa016dfb21cf7383b0848a0a04284425 |
# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.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) an... | ownport/ansiblite | src/ansiblite/constants.py | Python | gpl-3.0 | 28,761 | [
"Galaxy",
"MOOSE"
] | 8aa2a2f85905497d473999860b2034bba031de52cf6b3cd8d76b5ff4972f4d9a |
# -*- coding: utf-8 -*-
# Copyright 2009-2013, Peter A. Bigot
#
# 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... | CantemoInternal/pyxb | pyxb/xmlschema/structures.py | Python | apache-2.0 | 226,489 | [
"VisIt"
] | 0a8c43ba9f69a3fd174db60f8e5dc040625897a3c3471461f4f5c25867b20ee6 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# =============================================================================
## @file ostap/fitting/utils.py
# Set of useful technical utilities to build various fit models
# @author Vanya BELYAEV Ivan.Belyaeve@itep.ru
# @date 2011-07-25
# ===========================... | OstapHEP/ostap | ostap/fitting/utils.py | Python | bsd-3-clause | 121,376 | [
"Gaussian"
] | 6619d70eff4a5f2b908afeb306c186de2a9689387f373810fb0877bd8d4d292d |
# Copyright 2018 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# Recipe which runs the SKQP apk using docker and an Android Emulator
DEPS = [
'checkout',
'infra',
'recipe_engine/file',
'recipe_engine/path',
'r... | HalCanary/skia-hc | infra/bots/recipes/test_skqp_emulator.py | Python | bsd-3-clause | 3,019 | [
"Galaxy"
] | 8dd75cc0bbb6dd4cb4a89fc53267e8795be5670efdca27d41b3783cb3b272fa8 |
##############################################################################
# MDTraj: A Python Library for Loading, Saving, and Manipulating
# Molecular Dynamics Trajectories.
# Copyright 2012-2013 Stanford University and the Authors
#
# Authors: Tim Moore
# Contributors:
#
# MDTraj is free software: you can... | rmcgibbo/mdtraj | tests/test_hoomdxml.py | Python | lgpl-2.1 | 2,181 | [
"MDTraj"
] | d74b7b748f618e0e7896d349746215cbecc6cbdaa70335907f05ea0c721e1867 |
import pandas as pd
from sklearn.ensemble import RandomForestRegressor
from sklearn.ensemble import BaggingRegressor
from sklearn.ensemble import ExtraTreesRegressor
from sklearn.ensemble import AdaBoostRegressor
from sklearn.ensemble import GradientBoostingRegressor
from sklearn.ensemble import RandomTreesEmbedding
fr... | rupakc/Kaggle-Compendium | Blue Book for Bulldozers/blue-book-baseline.py | Python | mit | 4,779 | [
"Gaussian"
] | e49d91e83398c1b4b3d68eacfbaf8cd3dffecf6a390c85e1d392bd43f125cedf |
""" Classify the output based on the choice neuron in the last layer with the highest probability."""
import numpy as np
from chainer import cuda, Variable, Chain, optimizers, serializers
import chainer.links as L
import chainer.functions as F
class BaseNetwork(Chain):
"""
BaseNetwork is the underlying NN.... | ekatek/char-classify | chClassifier/base_classifier.py | Python | mit | 4,492 | [
"NEURON"
] | cd3a05aacdf83ec17e4676d2ada524534e19d826ff935ed8007e1626d921f6f3 |
#!/usr/bin/env python
# This example shows how to generate and manipulate texture coordinates.
# A random cloud of points is generated and then triangulated with
# vtkDelaunay3D. Since these points do not have texture coordinates,
# we generate them with vtkTextureMapToCylinder.
import vtk
from vtk.util.misc import ... | CMUSV-VisTrails/WorkflowRecommendation | examples/vtk_examples/VisualizationAlgorithms/GenerateTextureCoords.py | Python | bsd-3-clause | 2,156 | [
"VTK"
] | acde5ae805b60be34a16dfcd187874e82790932fdc5f05e36fd010ae283e361b |
# encoding: utf-8
from __future__ import unicode_literals
import mock
import datetime
import pytest
from nose.tools import * # noqa
from dateutil.parser import parse as parse_datetime
from addons.osfstorage.models import OsfStorageFileNode, OsfStorageFolder
from framework.auth.core import Auth
from addons.osfstorag... | aaxelb/osf.io | addons/osfstorage/tests/test_views.py | Python | apache-2.0 | 38,533 | [
"Galaxy"
] | 52ec0c1c13a1f7ae61f725e915c01de0de8f5f9684b65ea27fc364ddfbb1aa2b |
"""
Translate a BAM file
"""
import contextlib
import logging
import sys
import pysam
from .. import codons, util
from .adaptive_tsv import TAG_CDR3_START
log = logging.getLogger(__name__)
def build_parser(p):
p.add_argument('bam_files', nargs='+')
p.add_argument('-o', '--outfile', default=sys.stdout, type=... | cmccoy/ighutil | python/vdjalign/subcommands/translate_bam.py | Python | gpl-3.0 | 1,218 | [
"pysam"
] | 9db41a65c656902d3f1ffda3a4a024304788909505bc9690d811e18dfbb935b2 |
# -*- coding: utf-8 -*-
# Replicate the graphs from Xu_3fields_hands-on.pdf (BOUT++ workshop 2013)
# needs runs in data & data0 folders
# After running the cases define path0 and path1 accordingly
from __future__ import division
from past.utils import old_div
import numpy as np
from boututils import file_import
from bo... | kevinpetersavage/BOUT-dev | examples/elm-pb/Python/post.py | Python | gpl-3.0 | 3,011 | [
"Mayavi"
] | 1db2ae0772d8a3d29e0319d19947de29a9056991bcabc0e89800db63a67a0362 |
#
# @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 file is part of Psi4.
#
# Psi4 is free software; you can redistribute it and/or modify
#... | rmcgibbo/psi4public | psi4/driver/qcdb/jajo.py | Python | lgpl-3.0 | 18,018 | [
"Avogadro",
"CFOUR",
"Psi4"
] | 5b213ac948639c6c6f0e9ad480352a42bad1beb4f6b1afdb7080e92a74a81989 |
# Licensed under a 3-clause BSD style license - see LICENSE.rst
import numpy as np
from numpy.testing import assert_allclose
import pytest
from astropy import coordinates
from astropy.table import Table
from six.moves.urllib_error import URLError
from ... import sdss
from ...exceptions import TimeoutError
@pytest.... | imbasimba/astroquery | astroquery/sdss/tests/test_sdss_remote.py | Python | bsd-3-clause | 6,737 | [
"Galaxy"
] | 02b2fb82de8d5d85496e7c37af43f47c6370dce8a17c207504e00304d915df9c |
# coding=utf-8
"""Utilities module."""
import re
import codecs
import json
import logging
import platform
import sys
import traceback
import unicodedata
import webbrowser
from PyQt4.QtCore import QPyNullVariant
from safe.common.exceptions import NoKeywordsFoundError, MetadataReadError
from safe.definitions.versions... | Gustry/inasafe | safe/utilities/utilities.py | Python | gpl-3.0 | 11,997 | [
"VisIt"
] | 0d085b7e70de067c83ee4c00aefed9b5c1bd30b69ca60d04fcd2658f859fb3dd |
# -*- coding: utf-8 -*-
"""
Source alignment and coordinate frames
======================================
The aim of this tutorial is to show how to visually assess that the data are
well aligned in space for computing the forward solution, and understand
the different coordinate frames involved in this process.
.. c... | teonlamont/mne-python | tutorials/plot_source_alignment.py | Python | bsd-3-clause | 9,094 | [
"Mayavi"
] | e5fa52cb0cdda05066f445cc2c2d628da6a2a4389692ad54d13ce7b385609c1c |
"""
The following functions provide additional mock observing features for use with
the coronagraph model.
"""
from __future__ import (division as _, print_function as _,
absolute_import as _, unicode_literals as _)
import numpy as np
import matplotlib as mpl
import matplotlib.pyplot as plt
from matpl... | jlustigy/coronagraph | coronagraph/observe.py | Python | mit | 25,920 | [
"Gaussian"
] | 98743f2d7e79144adf9a41aad2f6570e53969fdb8e2317d77ed0e9c2e329895d |
#!/usr/bin/env python
#-*- coding:utf-8 -*-
#
# This file is part of the NNGT project to generate and analyze
# neuronal networks and their activity.
# Copyright (C) 2015-2019 Tanguy Fardet
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License a... | Silmathoron/NNGT | nngt/simulation/nest_activity.py | Python | gpl-3.0 | 23,441 | [
"NEURON"
] | 2057a74984fbd366cd8f39f210fcd5483550ee493efe38fd6614cdc4f2d17e27 |
#! /usr/bin/env python
# ----------------------------------------------------------------------------
# Copyright (c) 2013--, scikit-bio development team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file COPYING.txt, distributed with this software.
# --------------------... | JWDebelius/scikit-bio | skbio/stats/distance/_anosim.py | Python | bsd-3-clause | 2,953 | [
"scikit-bio"
] | d82846ce36316e8561463ca9bbc800db5905e157ca92ea6c0080af837031e0be |
import textwrap
from typing import Dict, Optional, Tuple
import inflect
from dis_snek.client import Snake
from dis_snek.models import (TYPE_MESSAGEABLE_CHANNEL, OptionTypes, Scale, message_command,
slash_command, slash_option)
from discordbot import command
from discordbot.command import ... | PennyDreadfulMTG/Penny-Dreadful-Tools | discordbot/commands/explain.py | Python | gpl-3.0 | 12,604 | [
"CRYSTAL"
] | dba8a88275da88f4557808bfac7a6c215a48de8adceed640e61a673dde1d0e63 |
from subprocess import call
call(["npm", "install"])
call(["bower", "i"])
call(["gulp"])
| magtu/backend | deploy.py | Python | mit | 89 | [
"GULP"
] | b856550fbf975dbd1363446449cfa1b1cb197c04f8ff7074cca6a4653c5042da |
#!/usr/bin/python
"""
This script asks cdash to give it a summary of all of the failing tests
on the nightly expected section. It presents the tests ranked by the number
of failing machines. From this view you can more easily see what is in
the greatest need of fixing.
"""
import sys
import time
import datetime
import... | berendkleinhaneveld/VTK | Utilities/Maintenance/vtk_fail_summary.py | Python | bsd-3-clause | 2,764 | [
"VTK"
] | 7bc7efef8e19ff3580344aa085cf199cb043f3a85c8cae322e39d1822a849a57 |
# list of random English nouns used for resource name utilities
words = ['People', 'History', 'Way', 'Art', 'World', 'Information', 'Map', 'Two',
'Family', 'Government', 'Health', 'System', 'Computer', 'Meat', 'Year', 'Thanks',
'Music', 'Person', 'Reading', 'Method', 'Data', 'Food', 'Understanding', ... | GoogleCloudPlatform/sap-deployment-automation | third_party/github.com/ansible/awx/awxkit/awxkit/words.py | Python | apache-2.0 | 17,093 | [
"VisIt"
] | e14c154996e6b3fdae7c9883bf0e8bce66658d4097eaa83f5cf5cae70faf3978 |
import new, sys
import galaxy.util
import parameters
class ToolTestBuilder( object ):
"""
Encapsulates information about a tool test, and allows creation of a
dynamic TestCase class (the unittest framework is very class oriented,
doing dynamic tests in this was allows better integration)
"""
... | jmchilton/galaxy-central | galaxy/tools/test.py | Python | mit | 814 | [
"Galaxy"
] | d6d5a0261495456bb857cb39ee502b8444287a1f0c9f501070fe5b1a409ebc80 |
# -*- coding: utf-8 -*-
# Copyright 2007-2018 The HyperSpy developers
#
# This file is part of HyperSpy.
#
# HyperSpy 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... | sem-geologist/hyperspy | hyperspy/tests/drawing/test_plot_model.py | Python | gpl-3.0 | 5,246 | [
"Gaussian"
] | c0b568ca435767ab48f0c9a92c4f3ff6713d669f41ea909c978e4165385b00d9 |
import numpy as np
from scipy import special
# some variables
sq2 = np.sqrt(2)
eps = np.finfo(np.float32).eps
l2p = np.log(2) + np.log(np.pi)
def joint_min(mu, var, with_derivatives=False, **kwargs):
"""
Computes the probability of every given point to be the minimum
based on the EPMGP[1] algorithm.
... | aaronkl/RoBO | robo/util/epmgp.py | Python | bsd-3-clause | 7,569 | [
"Gaussian"
] | 9d7dd9b27f66103e41c6bb641d0e2bf79e7341a46071a2e1f9731e90c00701e4 |
"""
Phonon unfolding: Reciprocal space method. The method is described in
P. B. Allen et al. Phys Rev B 87, 085322 (2013).
This method should be also applicable to other bloch waves on discrete grid, eg. electrons wave function in wannier basis set, magnons, etc. Now only phonon istested.
"""
from ase.build import make... | mailhexu/pyDFTutils | pyDFTutils/unfolding/unfolding/unfolder.py | Python | lgpl-3.0 | 4,882 | [
"ASE"
] | 1ee53c2c33b897c39066fedac1c01777decc7345b4382890f92ac75e5219a0b6 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import numpy as np
import scipy.spatial
import scipy.stats
import matplotlib.lines
import matplotlib.patches
import matplotlib.collections
import matplotlib.pyplot as plt
import pandas as pd
import seaborn as sns
from antlia import filter as ff
from antlia import util
met... | oliverlee/antlia | python/antlia/plot_braking.py | Python | bsd-2-clause | 14,032 | [
"Gaussian"
] | 92b8eb1cf5c5d70e1bf7c19df4448de19b12a5cacad4e2e3b879ee058b31fc97 |
# ######################################################################
# Copyright (c) 2014, Brookhaven Science Associates, Brookhaven #
# National Laboratory. All rights reserved. #
# #
# @author: Li Li (lili@bnl.g... | Nikea/scikit-xray | skbeam/core/fitting/lineshapes.py | Python | bsd-3-clause | 15,093 | [
"Gaussian"
] | 781355833c65e036b319fce1a3e7eb190e5ad66b59cb071589c61f6928928a0c |
import functools
from math import log
import numpy as np
import tree # pip install dm_tree
import gym
from ray.rllib.models.action_dist import ActionDistribution
from ray.rllib.models.torch.torch_modelv2 import TorchModelV2
from ray.rllib.utils.annotations import override
from ray.rllib.utils.framework import try_imp... | pcmoritz/ray-1 | rllib/models/torch/torch_action_dist.py | Python | apache-2.0 | 21,483 | [
"Gaussian"
] | 450691dc6a2493a7783ba5a9d0995a0f997f7ed7518cf0495220745e985ba3da |
"""Generate Java code from an ASDL description."""
# TO DO
# handle fields that have a type but no name
import os, sys, traceback
import asdl
TABSIZE = 4
MAX_COL = 76
def reflow_lines(s, depth):
"""Reflow the line s indented depth tabs.
Return a sequence of lines where no line extends beyon... | Spacecraft-Code/SPELL | src/spel-gui/com.astra.ses.spell.language/src/com/astra/ses/spell/language/model/ast/asdl_java.py | Python | lgpl-3.0 | 12,499 | [
"VisIt"
] | 547e38b612621ee0fce282a082db53838c832bab4d0caa72b295c0d101b9f8bb |
# FIXME: serial number...
# reading the data: unpack the data using the ratio.
__version__ = "0.1.1"
__author__ = "Pierre Legrand (pierre.legrand@synchrotron-soleil.fr)"
__date__ = "23-09-2012"
__copyright__ = "Copyright (c) 2005-2012 Pierre Legrand"
__license__ = "New BSD, http://www.opensource.org/licenses/bsd-lice... | keitaroyam/yamtbx | yamtbx/dataproc/XIO/plugins/raxis_interpreter.py | Python | bsd-3-clause | 9,313 | [
"CRYSTAL"
] | 7ee10b52b9b0bbaa744cbf7e0fd96749d3519ec3280052defce6b24fce2460f4 |
###########################################################################
#
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/l... | google/starthinker | dags/dcm_to_sheets_dag.py | Python | apache-2.0 | 4,447 | [
"VisIt"
] | ee64b0958ada8c1605a84b5dfe68c8bbf9bfed191cf4401ec31b266580b2b838 |
# coding: utf-8
"""
Vericred API
Vericred's API allows you to search for Health Plans that a specific doctor
accepts.
## Getting Started
Visit our [Developer Portal](https://developers.vericred.com) to
create an account.
Once you have created an account, you can create one Application for
Production and an... | vericred/vericred-python | vericred_client/models/plan_show_response.py | Python | apache-2.0 | 12,063 | [
"VisIt"
] | 65408810222ab5d2b0232112ff695806d52c664b9c2eb335f06cef9a2241afe5 |
"""
Filename: stochmatrix.py
Author: Daisuke Oyama
Tools for dealing with a stochastic matrix.
"""
import numpy as np
from scipy import sparse
from scipy.sparse import csgraph
try:
xrange
except: # python3
xrange = range
class StochMatrix(np.ndarray):
r"""
Add structure as a directed graph to a n... | oyamad/stochmatrix | stochmatrix.py | Python | bsd-3-clause | 8,969 | [
"Gaussian"
] | b93291121e1fe82c5619fbe673323d22d96f57ca028719bfd42a96cb5d607a33 |
# This file is part of MOOSE simulator: http://moose.ncbs.res.in.
# MOOSE 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.
# MOOSE is ... | subhacom/moose-core | python/moose/moose_constants.py | Python | gpl-3.0 | 2,135 | [
"MOOSE"
] | a386f91d3e3318d5a58ffa5c89453e1fbd8d594ff5254668a5fa2f6bf98cad6a |
##############################################################################
#
# Copyright (c) 2001, 2002 Zope Corporation and Contributors.
# All Rights Reserved.
#
# This software is subject to the provisions of the Zope Public License,
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
# T... | Donkyhotay/MoonPy | zope/exceptions/interfaces.py | Python | gpl-3.0 | 3,655 | [
"VisIt"
] | 00f5f91f5214d79bcac62c896b5307142828d8afa4bbc3a5a6d59901ce5e3cf0 |
"""
Calculate spectroscopy limited maximum efficiency (SLME) given dielectric function data
Forked and adjusted from :
https://github.com/usnistgov/jarvis
References: 1) https://doi.org/10.1021/acs.chemmater.9b02166 &
2) http://dx.doi.org/10.1103/PhysRevLett.108.068701
"""
import os
from math import pi
... | gmatteo/pymatgen | pymatgen/analysis/solar/slme.py | Python | mit | 9,531 | [
"VASP",
"pymatgen"
] | a61d59d771e1ba6c5cefa3ac8ab2cce50cdb5491b83c4ad28487425aba5ba997 |
#!/usr/bin/env python
"""
Retrieve status of DIRAC jobs
"""
__RCSID__ = "$Id$"
import os
import json
import DIRAC
from DIRAC import S_OK, S_ERROR
from DIRAC import exit as DIRACExit
from DIRAC.Core.Base import Script
from DIRAC.Core.Utilities.Time import toString, date, day
from DIRAC.Core.DISET.RPCClient import ... | pigay/COMDIRAC | Interfaces/scripts/dstat.py | Python | gpl-3.0 | 5,373 | [
"DIRAC"
] | c985ed4501672b944830374503aaea9724ce3dddbf1fd2b2d8f6df9366b3f435 |
#
# The Python Imaging Library.
# $Id$
#
# Binary input/output support routines.
#
# Copyright (c) 1997-2003 by Secret Labs AB
# Copyright (c) 1995-2003 by Fredrik Lundh
# Copyright (c) 2012 by Brian Crowell
#
# See the README file for information on usage and redistribution.
#
from struct import unpack, pack
if byte... | sumedh123/debatify | venv/lib/python2.7/site-packages/PIL/_binary.py | Python | mit | 1,393 | [
"Brian"
] | 87c6c08cfd1ac050465dd8d05ef5d1c41d6599b4ac7447a177117f91bd34e0c4 |
# -*- coding: utf-8 -*-:
# Copyright 2012 splinter authors. All rights reserved.
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
"""
This module contains the basic API for splinter drivers and elemnts.
"""
from splinter.meta import InheritedDocs
from splinter.req... | gjvis/splinter | splinter/driver/__init__.py | Python | bsd-3-clause | 21,864 | [
"VisIt"
] | b371c25822f47dc6a35245eea3a2b8d22af186921401d552c2af5d3236445276 |
#!/usr/bin/env python3
import os,sys,string,subprocess,signal,shutil
#psutil
import argparse
mcdir = sys.path[0]
parser = argparse.ArgumentParser(description='snakemake and metacompass params')
group1 = parser.add_argument_group('required')
#group1.add_argument("-s",'--snakefile', help='metacompass rules file',defau... | marbl/MetaCompass | workflows/assembly.py | Python | artistic-2.0 | 20,564 | [
"BLAST"
] | a29806848d74616e1bb935818dcc50c7036322e85a50ceca1f4825a70419e053 |
from electrum_ixc.util import print_error
import httplib, urllib
import socket
import threading
import hashlib
import json
from urlparse import urlparse, parse_qs
try:
import PyQt4
except Exception:
sys.exit("Error: Could not import PyQt4 on Linux systems, you may try 'sudo apt-get install python-qt4'")
from ... | electrumalt/electrum-ixc | plugins/labels.py | Python | gpl-3.0 | 9,164 | [
"VisIt"
] | 6b98598c6182d856be39f0d5a105b97854f9c3552ea75acff931e917b3e4dfeb |
""" Contains the ShotProfileManager class."""
# shot_profile_manager.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
from collections import... | spierepf/mpf | mpf/system/shot_profile_manager.py | Python | mit | 9,297 | [
"Brian"
] | 16965292479c7a3454aaace0478b4aceed34775359a754dcbe6b48d806189c21 |
""" This is a test of the parametric job generation tools
"""
# pylint: disable=protected-access, missing-docstring, invalid-name, line-too-long
import unittest
from DIRAC.WorkloadManagementSystem.Utilities.ParametricJob import generateParametricJobs, \
... | arrabito/DIRAC | WorkloadManagementSystem/Utilities/test/Test_ParametricJob.py | Python | gpl-3.0 | 4,688 | [
"DIRAC"
] | 9ab08f0c0d4c4ca98341a49ee0a62dc8f0faea5ac1d683a85db6556a5bbc775b |
########################################################################
# File: RequestExecutingAgent.py
# Author: Krzysztof.Ciba@NOSPAMgmail.com
# Date: 2013/03/12 15:36:47
########################################################################
""" :mod: RequestExecutingAgent
===========================
.... | fstagni/DIRAC | RequestManagementSystem/Agent/RequestExecutingAgent.py | Python | gpl-3.0 | 17,032 | [
"DIRAC"
] | e24553e1e389f56c7a345536d15e0a5b500f6b0fa2150c2680ab7ab191ddf9f7 |
# Copyright (C) 2012 Alex Nitz
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation; either version 3 of the License, or (at your
# option) any later version.
#
# This program is distributed in the... | sfairhur/pycbc | pycbc/waveform/waveform.py | Python | gpl-3.0 | 43,950 | [
"Gaussian"
] | 3b647be5f4b13dfd66840623318bbd34482afc52810f7e7665354da24f1492f4 |
#!/usr/bin/env python
##########################################################################
# Molecule Class
# Atom Class
##########################################################################
version=0.3
versiontext='# class_molecule.py version {:.1f}'.format(version)
#----------------------------------------... | koniweb/molecule | class_molecule_crystal.py | Python | gpl-2.0 | 2,685 | [
"CRYSTAL"
] | 2c0629869067d4947ad9eb8204e1ab6e607a23c1e3e02cd6260ec33605ac379a |
# coding: utf8
{
' Quotas: %(quotas)s x%(quota_amount).2f': ' Quotas: %(quotas)s x%(quota_amount).2f',
' Transaction number: %s': ' Transaction number: %s',
'"update" is an optional expression like "field1=\'newvalue\'". You cannot update or delete the results of a JOIN': '"update" is an optional expression like "field... | reingart/gestionlibre | languages/fr-fr.py | Python | agpl-3.0 | 15,645 | [
"VisIt"
] | 91d88c92432285c28790f944f703aa55c08c2ae2f24443215a5cc78c8cabe2db |
import sys
import os
import re
import subprocess
import clang.cindex
if 'MOOSE_CLANG_LIB' not in os.environ:
raise EnvironmentError("Using the MooseSourceParser requires setting 'MOOSE_CLANG_LIB' environment variable to point to the clang library.")
clang.cindex.Config.set_library_path(os.getenv('MOOSE_CLANG_LIB')... | vityurkiv/Ox | python/utils/MooseSourceParser.py | Python | lgpl-2.1 | 4,712 | [
"MOOSE"
] | 2fd4c958fd9f8971e9ce4b6329a3d8fa79b7c17dc8065beb995d0d617ace632a |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
TODO: Modify unittest doc.
"""
__author__ = "Shyam Dwaraknath"
__copyright__ = "Copyright 2016, The Materials Project"
__version__ = "0.1"
__maintainer__ = "Shyam Dwaraknath"
__email__ = "shyamd@lbl.gov"
... | davidwaroquiers/pymatgen | pymatgen/analysis/tests/test_substrate_analyzer.py | Python | mit | 2,715 | [
"pymatgen"
] | af127aff00cea34b271a0d50828bfb42bb443eb66a266b291883aed277627923 |
#! /usr/bin/python
import os, argparse, sys
from engine.router import Router
scriptPath = os.path.dirname(os.path.realpath(__file__))
version = "0.1"
releaseDate = "2012-03-14"
description = "Blast for Basis! v%s" % version
license = open(scriptPath + "/LICENSE")
#
# Get the command from the command line. Determine... | adampresley/Blast-for-Basis | blast/blast.py | Python | bsd-2-clause | 779 | [
"BLAST"
] | 2089ed13eae0655e16b7f7be075d15241178f4240c519080f98c7ad9c4156b8f |
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not us... | lukecwik/incubator-beam | sdks/python/apache_beam/io/gcp/experimental/spannerio.py | Python | apache-2.0 | 42,384 | [
"VisIt"
] | 6ec08a7362af9590e015fb6466654b44f453b88fe6580795e61af6ae73eff62b |
# From: Bayesian Models for Astrophysical Data, Cambridge Univ. Press
# (c) 2017, Joseph M. Hilbe, Rafael S. de Souza and Emille E. O. Ishida
#
# you are kindly asked to include the complete citation if you used this
# material in a publication
# Code 5.11 - Inverse Gaussian model in Python using Stan
# 1 response... | astrobayes/BMAD | chapter_5/code_5.11.py | Python | gpl-3.0 | 2,122 | [
"Gaussian"
] | 1edbc26a780e169b1b709c06b03aa038b098a674ba637c7fa6b823b6e2273745 |
#!/usr/bin/env python
import vtk
from vtk.test import Testing
from vtk.util.misc import vtkGetDataRoot
VTK_DATA_ROOT = vtkGetDataRoot()
# this script tests vtkImageReslice with different interpolation modes,
# with the wrap-pad feature turned on and with a rotation
# Image pipeline
reader = vtk.vtkImageReader()
reader... | HopeFOAM/HopeFOAM | ThirdParty-0.1/ParaView-5.0.1/VTK/Imaging/Core/Testing/Python/ResliceLanczosKaiser.py | Python | gpl-3.0 | 3,344 | [
"VTK"
] | 7fa1b8cbeb2c2b037ede15c9886aa5305c562b4df65579ba7d7b1f33bcf44e61 |
# ADALINE MODULE
######################################################
DEBUG_W = 0;
class Adaline:
# > Global constants
# > Constructor
# > > n = number of dendrites of the neuron
# > > r = neuron learning rate in (0,1]
# > > inf = lower value of activation function (-1 or 0), defaul... | cabraile/RNA-Modules | rna_module.py | Python | mit | 2,292 | [
"NEURON"
] | 67a4e9877f0930c3cb162484a58d421b384642fbfd1c8f9f6244fa5c34deda0d |
"""add default nurture tubes values
Revision ID: c747d6f9d206
Revises: c9b69c2c665d
Create Date: 2017-05-16 10:21:00.181786
"""
from alembic import op
import sqlalchemy as sa
from sqlalchemy.dialects import postgresql
from radar.models.nurture_tubes import PROTOCOL_OPTION_TYPE, SampleOption
# revision identifiers, ... | renalreg/radar | migrations/versions/c747d6f9d206_add_default_nurture_tubes_values.py | Python | agpl-3.0 | 4,010 | [
"VisIt"
] | 4eb06b61d7206cdde3f7beab91e7f9a1bd5d050d9e4214d6d9b770e77af11d6a |
# Copyright 2010-2017, The University of Melbourne
# Copyright 2010-2017, Brian May
#
# This file is part of Karaage.
#
# Karaage 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... | Karaage-Cluster/karaage | karaage/common/decorators.py | Python | gpl-3.0 | 3,403 | [
"Brian"
] | 59deec078baa382c1c2f1cc8144df6dcb7516018a1faeaeebb9b17cca4cf893f |
# -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=120 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# ------------------------------------------------------... | marmyshev/item_title | openlp/core/utils/applocation.py | Python | gpl-2.0 | 7,483 | [
"Brian"
] | 0c1be9b5d7587a51d2a36c4b0602095f06003155a1bb91e562ea7e26b5e918dc |
# Copyright (C) 2009, Thomas Leonard
# See the README file for details, or visit http://0install.net.
import gtk
import os
from zeroinstall.gtkui import gtkutils
last_error = None
builderfile = os.path.join(os.path.dirname(__file__), 'zero-install.ui')
class Template(gtkutils.Template):
def __init__(self, root):
... | linuxmidhun/0install | zeroinstall/gui/dialog.py | Python | lgpl-2.1 | 1,173 | [
"VisIt"
] | 1dc9f31ad65a71b53ad3e133185e71d164740ab00d41edd5d008fb450a347af5 |
"""
Test courseware search
"""
import os
import json
from ..helpers import UniqueCourseTest
from ...pages.common.logout import LogoutPage
from ...pages.studio.utils import add_html_component, click_css, type_in_codemirror
from ...pages.studio.auto_auth import AutoAuthPage
from ...pages.studio.overview import CourseOut... | beni55/edx-platform | common/test/acceptance/tests/lms/test_lms_courseware_search.py | Python | agpl-3.0 | 7,158 | [
"VisIt"
] | d01552f63dab860a890e0d790e4ec882eb9db07517097e5545cc3b509d40fd3e |
""" ElasticDB is a base class used to connect an Elasticsearch database and manages queries.
"""
__RCSID__ = "$Id$"
from DIRAC import gLogger
from DIRAC.Core.Utilities.ElasticSearchDB import ElasticSearchDB
from DIRAC.ConfigurationSystem.Client.Utilities import getElasticDBParameters
class ElasticDB(ElasticSearchDB... | fstagni/DIRAC | Core/Base/ElasticDB.py | Python | gpl-3.0 | 3,470 | [
"DIRAC"
] | 7759bafe59d8772ef11e05b6c82f0474b9f0ff8de23f0b73793f8da4c2d42978 |
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
import functools
import json
import os
import random
import unittest
import warnings
from monty.json import MontyDecoder
from monty.os.path import which
from pymatgen.core.lattice import Lattice
from pymatgen.core.periodic_t... | vorwerkc/pymatgen | pymatgen/transformations/tests/test_standard_transformations.py | Python | mit | 24,714 | [
"VASP",
"pymatgen"
] | fc8b1dabce7ebb40727e67bfb5964571f45322db9c9984c69d622b84ba140f8f |
# -*- coding: utf-8 -*-
import re
from .xn_data import XNCoords, XNPlanet
from .xn_parser import XNParserBase, safe_int, get_attribute, get_tag_classes
from . import xn_logger
logger = xn_logger.get(__name__, debug=False)
class ImperiumParser(XNParserBase):
def __init__(self):
super(ImperiumParser, self... | minlexx/xnovacmd | ui/xnova/xn_parser_imperium.py | Python | gpl-2.0 | 32,454 | [
"Galaxy"
] | 75f972104934e105136cb524ad460d8b96f3664f507abc1f138c2504a37962b6 |
from numpy.testing import assert_equal, assert_array_equal, assert_allclose
from nose.tools import assert_true, assert_raises, assert_not_equal
from copy import deepcopy
import os.path as op
import numpy as np
from scipy import sparse
import os
import warnings
from mne.utils import (set_log_level, set_log_file, _TempD... | rajegannathan/grasp-lift-eeg-cat-dog-solution-updated | python-packages/mne-python-0.10/mne/tests/test_utils.py | Python | bsd-3-clause | 17,594 | [
"Mayavi"
] | ee1881e7f5f394eb3205c5da57f2920f631becf0074e31ce120d40cf4981cc64 |
"""
=============================================================
Gaussian process regression (GPR) with noise-level estimation
=============================================================
This example illustrates that GPR with a sum-kernel including a WhiteKernel can
estimate the noise level of data. An illustration... | RPGOne/Skynet | scikit-learn-0.18.1/examples/gaussian_process/plot_gpr_noisy.py | Python | bsd-3-clause | 3,778 | [
"Gaussian"
] | e74b3b8b2dca81f5ce67f15476eeee2ec44b371ef35843b3ac6112bae6a1f298 |
#!/usr/bin/env python
# ----------------------------------------------------------------------------
# Copyright (c) 2015--, The Horizomer Development Team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file LICENSE, distributed with this software.
# ----------------------... | qiyunzhu/horizomer | horizomer/benchmark/parse_output.py | Python | bsd-3-clause | 11,849 | [
"scikit-bio"
] | 34b7f3e6a17e517778e297910d8efd2d7168ab9c6801c029a8ebdb7cfee5ccbc |
# Natural Language Toolkit: Discourse Representation Theory (DRT)
#
# Author: Dan Garrette <dhgarrette@gmail.com>
#
# Copyright (C) 2001-2016 NLTK Project
# URL: <http://nltk.org/>
# For license information, see LICENSE.TXT
from __future__ import print_function, unicode_literals
import operator
from functool... | adazey/Muzez | libs/nltk/sem/drt.py | Python | gpl-3.0 | 51,630 | [
"VisIt"
] | 98fd78c9699289f69e318c732a05f87e549dec777cecb2eca33ca7baf8178cb0 |
from comics.aggregator.crawler import CrawlerBase, CrawlerImage
from comics.meta.base import MetaBase
class Meta(MetaBase):
name = '8-Bit Theater'
language = 'en'
url = 'http://www.nuklearpower.com/'
active = False
start_date = '2001-03-02'
end_date = '2010-06-01'
rights = 'Brian Clevinger'... | klette/comics | comics/comics/8bittheater.py | Python | agpl-3.0 | 422 | [
"Brian"
] | 0ca4fb4d9477de820478e913e9963f11a1fc5300a22ce2655229b8b4a0aee147 |
import numpy as np
import matplotlib.pyplot as plt
from matplotlib.colors import LogNorm
from sklearn import mixture
n_samples = 300
# generate random sample, two components
np.random.seed(0)
# generate spherical data centered on (20, 20)
shifted_gaussian = np.random.randn(n_samples, 2) + np.array([20, 0])
shifted_g... | ronnyb29/kmeans-theory | code/gmm_fit_example.py | Python | apache-2.0 | 1,319 | [
"Gaussian"
] | 33dae54143ad920264f373d9f82dab78ea7cfd97d4e8e41446f87d51140664c5 |
from __future__ import unicode_literals
"""
This package contains various command line interfaces to programs used in
pymatgen that do not have Python equivalents.
"""
| rousseab/pymatgen | pymatgen/command_line/__init__.py | Python | mit | 168 | [
"pymatgen"
] | 6f6c0bf12165afcbbbd9be7ee4347a7aadee01d9850a350839b4f6da9407978f |
from chainer import Chain
from chainer import links as L
from chainer import functions as F
from chainer import reporter
from chainer import cuda
import numpy as np
def dot(a, b):
""" Simple dot product"""
return F.sum(a * b, axis=-1)
def batch_interactions(x):
xp = cuda.get_array_module(x.data)
bat... | cemoody/vfm | auto_vfm.py | Python | mit | 10,172 | [
"Gaussian"
] | dfee94f1b1230cdf6b1b017b10b36ace106be10f3bee4d9f924d0bb8ce38de86 |
from __future__ import print_function
from yambopy import *
lower_vb = 1
upper_vb = 232
final_vb = 161
lower_cb = upper_vb + 1
upper_cb = 1000
final_cb = 256
jobname='ssGW_kdep'
yambo_exe = '/home/pr1eeh00/pr1eeh01/program/yambo-4.2.0/bin/yambo'
ypp_exe = '/home/pr1eeh00/pr1eeh01/program/yambo-4.2.0/bin/ypp'
yambo = ... | mmdg-oxford/papers | Schlipf-PRL-2018/ab_initio/yambo/ssGW_kdep.py | Python | gpl-3.0 | 2,651 | [
"NetCDF",
"Yambo"
] | 87d7447395bdfcd506144fd95b4a4b4106f65fa6c30136b9add77517b5756119 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.