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 |
|---|---|---|---|---|---|---|---|
# $Id$
#
# Copyright (C) 2001-2011 greg Landrum and 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.
#
""" SMARTS definitions ... | rdkit/rdkit-orig | rdkit/Chem/MACCSkeys.py | Python | bsd-3-clause | 11,177 | [
"RDKit"
] | df565a8828c12eabfc776892d559b5b647d04a64911af758834312b66be95643 |
import unittest
from ircu import consts
from ircu import util
from ircu.util import string
class TestStringMethods(unittest.TestCase):
def test_irc_split(self):
cases = [
('PASS :muse',
['PASS', 'muse']),
('SERVER unit.test 1 1469157290 1469598599 J10 MHAD] +h6 :test... | briancline/ircu-python | tests/test_util.py | Python | mit | 4,996 | [
"Brian"
] | 5586c6b3017b28987c065b84add200267318f67718bbed2da1def711928f91de |
# -*- coding: utf-8 -*-
u"""SILAS execution template.
:copyright: Copyright (c) 2020 RadiaSoft LLC. All Rights Reserved.
:license: http://www.apache.org/licenses/LICENSE-2.0.html
"""
from __future__ import absolute_import, division, print_function
from pykern import pkio
from pykern import pkjson
from pykern.pkcollec... | radiasoft/sirepo | sirepo/template/silas.py | Python | apache-2.0 | 11,599 | [
"CRYSTAL"
] | d80d15acbe9717ba1d93f566132cce13219ee0a36e10b72abff7edaf0f9123ca |
"""
Acceptance tests for the teams feature.
"""
import json
import random
import time
from dateutil.parser import parse
import ddt
from nose.plugins.attrib import attr
from selenium.common.exceptions import TimeoutException
from uuid import uuid4
from ..helpers import get_modal_alert, EventsTestMixin, UniqueCourseTes... | ubc/edx-platform | common/test/acceptance/tests/lms/test_teams.py | Python | agpl-3.0 | 81,478 | [
"VisIt"
] | f894ca94fe68fb31fc36e3284abb2f210885d2d8baff31c904f7dd4f457262c0 |
#-----------------------------------------------------------------------------
# File Name : sympyParams.py
# Purpose:
#
# Author: Emre Neftci
#
# Creation Date :
# Last Modified : Tue 15 Mar 2011 06:11:41 PM CET
#
# Copyright : (c) 2011
# Licence : GPLv4
#--------------------------------------------------------------... | inincs/pyNCS | src/pyNCS/api/paramTranslation.py | Python | gpl-2.0 | 5,513 | [
"NEURON"
] | d35bd1ac85861add4d01a1187c077bb94a8fe5efcd7c1fa92c633aaf34a609d9 |
"""
Support for package tracking sensors from 17track.net.
For more details about this platform, please refer to the documentation at
https://home-assistant.io/components/sensor.seventeentrack/
"""
import logging
from datetime import timedelta
import voluptuous as vol
from homeassistant.components.sensor import PLAT... | jamespcole/home-assistant | homeassistant/components/seventeentrack/sensor.py | Python | apache-2.0 | 10,344 | [
"VisIt"
] | 539170e650abdf82dba08174e3b3193b8742219844cb28fe2f5de6d27a2b109b |
import ctypes
import sys
from ctree.transforms.declaration_filler import DeclarationFiller
from ctree.types import get_ctype, get_common_ctype
from util import CtreeTest
from ctree.c.nodes import SymbolRef, FunctionDecl, Assign, ArrayRef, \
Constant, MultiNode, Dot
class TestTypeRecognizer(CtreeTest):
def te... | ucb-sejits/ctree | test/test_types.py | Python | bsd-2-clause | 3,534 | [
"VisIt"
] | dce54023fb5325e2ad18a34fd193cbd9d8eddcef325369a9393d856556c829f2 |
"""
vtk extract runner
"""
import enaml
from enaml.qt.qt_application import QtApplication
def run():
with enaml.imports():
from vtk_grid_view import Main
app = QtApplication()
view = Main(custom_title='VTK Geometry Extract Example')
view.show()
# Start the application event loop
ap... | viz4biz/PyDataNYC2015 | tutorial/vtk_grid_run.py | Python | apache-2.0 | 338 | [
"VTK"
] | b6c969ba95a949ca1f72d062a8ea42e4c8b2b6e57493bf8a206a547aa2c76985 |
from asap3 import *
from numpy import *
from asap3.testtools import ReportTest
from ase.lattice.cubic import *
from ase.lattice.compounds import *
def check(a1, e):
a2 = a1.copy()
a1.set_calculator(EMT(EMTStandardParameters()))
a2.set_calculator(EMT())
ReportTest("Energy (%s)" % (e,), a2.get_potential_... | auag92/n2dm | Asap-3.8.4/Test/StdParamProv.py | Python | mit | 1,027 | [
"ASE"
] | 160dc916034218bc3304d22937645b44f03c50ebf832239486847e741d18e1aa |
"""A base class notebook manager.
Authors:
* Brian Granger
* Zach Sailer
"""
#-----------------------------------------------------------------------------
# Copyright (C) 2011 The IPython Development Team
#
# Distributed under the terms of the BSD License. The full license is in
# the file COPYING, distributed... | WillisXChen/django-oscar | oscar/lib/python2.7/site-packages/IPython/html/services/notebooks/nbmanager.py | Python | bsd-3-clause | 9,608 | [
"Brian"
] | 246a3b06fe51706f660e42e15f14c34f17ce574bc47119a4621ae4196fbf8118 |
#
# Copyright (C) 2009 Niek Linnenbank
#
# 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 distribute... | armizh/Fnx | site_scons/dist.py | Python | gpl-3.0 | 6,841 | [
"VisIt"
] | 0c41c360bba722d89d557ab482a3f79b1fdf1e41985bec047df394c08d21e2b0 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module provides classes used to enumerate surface sites
and to find adsorption sites on slabs
"""
import itertools
import os
import numpy as np
from matplotlib import patches
from matplotlib.path im... | richardtran415/pymatgen | pymatgen/analysis/adsorption.py | Python | mit | 31,238 | [
"Jmol",
"pymatgen"
] | 81e899cdbe8c657a9f8571170c859975c4d7dd8cbc72ad8f13e40d54675407de |
__author__="brian"
__date__ ="$Aug 20, 2010 11:11:39 PM$"
# Show current LOLs. For now, only Cats are supported. Others will follow.
import os
import sys
import xbmc
import xbmcgui
import xbmcplugin
import feedparser
import urllib
from BeautifulSoup import BeautifulStoneSoup
import xbmcaddon
__settings__ = xbmcad... | bmillham/plugin.pictures.icanhascheezburger.com | resources/lib/current_cheez_list.py | Python | gpl-3.0 | 3,410 | [
"Brian"
] | 9a707c64470f8329a1202062fef668182b71fd3dbe083b176d03127b1ae9f472 |
#! /usr/bin/python2
import subprocess
import sys
import os
import time
from subprocess import PIPE
import socket
default_params = ''
output_file_prefix = 'output'
if len(sys.argv) > 1:
output_file_prefix = sys.argv[1]
#
# http://stackoverflow.com/questions/4675728/redirect-stdout-to-a-file-in-python
#
class Logg... | schreiberx/sweet | archive/benchmarks_plane/rexi_tests_numerical/2015_12_26_search_eps_M/run.py | Python | mit | 4,428 | [
"Gaussian"
] | f1cc34e6818099ebde136acbfdd4c4d7e6a6b1d7494a1433e318b619a3468a7b |
# 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 u... | tqchen/tvm | python/tvm/contrib/target/onnx.py | Python | apache-2.0 | 32,993 | [
"VisIt"
] | 493027351dc11153799c17b56a70c26df3f0c6da870bd7f70927a597a1e8bcf8 |
# -*- coding: utf-8 -*-
import logging
import os
import time
from concurrent.futures import ThreadPoolExecutor, as_completed
from random import randrange
from collections import namedtuple, deque
from copy import deepcopy
from urllib.parse import urljoin, urlparse
import requests
from .decorators import with_histor... | nuncjo/Delver | delver/crawler.py | Python | mit | 16,708 | [
"VisIt"
] | 429a2b58168e717a81467ef988ef06c8e611e59104fecc33dcf2b6a81362f4f1 |
"""
Test course discovery.
"""
import datetime
import json
import uuid
from bok_choy.web_app_test import WebAppTest
from ..helpers import remove_file
from ...pages.common.logout import LogoutPage
from ...pages.studio.auto_auth import AutoAuthPage
from ...pages.lms.discovery import CourseDiscoveryPage
from ...fixtures.... | ZLLab-Mooc/edx-platform | common/test/acceptance/tests/lms/test_lms_course_discovery.py | Python | agpl-3.0 | 2,124 | [
"VisIt"
] | e4072e1eb3d73d13ca1c933000a06257cd0f61eea7cfb5996caeef477ee1b9b9 |
#!/usr/bin/python
import os
cwd=os.getcwd()
cwd = cwd + '/'
f2= open(cwd +'as2_temp_script.py',"r")
file_1=open(cwd +'Active_site1', "r")
ar=[]
data=[]
ar=f2.read()
temp= 'Ligand'
##pdbfile name incorporation
inf_t=[]
inp= open(cwd +'inputfile.txt',"r")
with inp as ins:
ins = [line.rstrip('\n') for line in ins]
fo... | S-John-S/MAT | as2_main.py | Python | mit | 3,769 | [
"PyMOL"
] | 71cda33b65ccbc8379b11013069e4a1129c84f6687552716ffb6b5f275c05e3b |
#!/usr/bin/python2.7
# coding: utf8
"""
Contains the VisitorRangeAbstract class.
"""
from range_semantic import ast
from range_semantic import ExtractRangeSemantic
class VisitorRangeAbstract(ast.NodeVisitor):
"""
Visits the AST and track the range of values for each numeric variable
"""
semantic =... | AngelinNjakasoa/Range-analysis-experiments | visitor_iteration.py | Python | mit | 3,224 | [
"VisIt"
] | ee729c06ab5eb8b2870731557b46b89502f2ecce9a07ab2244c5996f87a8c302 |
# Copyright 2014-2018 The PySCF Developers. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appl... | gkc1000/pyscf | pyscf/nao/m_vnucele_coo_subtract.py | Python | apache-2.0 | 1,215 | [
"PySCF"
] | 486eb17911019fa4b2bc2af3ca3d62e51f9337789f971f5ccc01c8dc32e693d6 |
# -*- coding: utf-8 -*-
# Copyright 2007-2016 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... | to266/hyperspy | hyperspy/io_plugins/__init__.py | Python | gpl-3.0 | 1,909 | [
"NetCDF"
] | acee1c9b4c8e48110ef206044e7768701664b2e33f9d088a07d6e4b57d122d99 |
"""
Download and parse data from CDEC, California Data Exchange Center, cdec.water.ca.gov
cdec_dataset(...) is the main entry point.
"""
import datetime
import os
import logging
import re
import six
import numpy as np
import xarray as xr
import pandas as pd
from six.moves import StringIO
import requests
log=logging.... | rustychris/stompy | stompy/io/local/cdec.py | Python | mit | 8,801 | [
"NetCDF"
] | 3a56243800c0dce1f9e06bbf45333975c9f877f74bbce6347319d27742c0085a |
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module implements the Zur and McGill lattice matching algorithm
"""
from dataclasses import dataclass
from itertools import product
from typing import Iterator, List
import numpy as np
from monty.json import MSONabl... | materialsproject/pymatgen | pymatgen/analysis/interfaces/zsl.py | Python | mit | 12,013 | [
"pymatgen"
] | 351f8df7ed2a04f5142f7446e7443347216868a171999d31a818df7ba7e54a70 |
# $Id$
#
# Copyright (C) 2005-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.
#
""" uses DSViewer to interact with molec... | soerendip42/rdkit | rdkit/Chem/DSViewer.py | Python | bsd-3-clause | 12,172 | [
"PyMOL",
"RDKit"
] | a9113a08a0a35c33167596c16363691bfc9e46dc23e6ab6f6893197c2ac5ca01 |
#!/usr/local/bin/env python
#=============================================================================================
# MODULE DOCSTRING
#=============================================================================================
"""
Run a YANK calculation.
"""
#==============================================... | sonyahanson/yank | Yank/commands/run.py | Python | lgpl-3.0 | 3,617 | [
"OpenMM"
] | 1ce9c133bf91616e21d77cce922a99646a4717a0f7c698ede3c06e1d0736aa77 |
###############################
# This file is part of PyLaDa.
#
# Copyright (C) 2013 National Renewable Energy Lab
#
# PyLaDa is a high throughput computational platform for Physics. It aims to make it easier to submit
# large numbers of jobs on supercomputers. It provides a python interface to physical input, suc... | pylada/pylada-light | tests/vasp/incar/test_others.py | Python | gpl-3.0 | 6,475 | [
"CRYSTAL",
"VASP"
] | 7c0f55b78eecff458b6298387549dc89dacfcc6046a2245d227c9729736e2ee8 |
import os
os.environ['PATH'] = '../caffe/build/tools:'+os.environ['PATH']
import sys
sys.path = ['../caffe/python'] + sys.path
import cv2
import cv
import numpy as np
import shutil
import random
import leveldb
import caffe
from google import protobuf
from caffe.proto import caffe_pb2
from xml.dom import minidom
import... | piiswrong/dec | dec/dec.py | Python | mit | 20,889 | [
"Gaussian"
] | eb6ed719bdb8e9a5a06ec06c0ea82a2212f318b829d5800368e5981fee6d9cbb |
# Copyright 2014-2018 The PySCF Developers. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appl... | gkc1000/pyscf | pyscf/nao/m_get_sp_mu2s.py | Python | apache-2.0 | 1,022 | [
"PySCF"
] | 6c998e6215dc221ac1e8d7075259edc2d8617819abe8c0b2dd4197596a5f0df0 |
""" Base Storage Class provides the base interface for all storage plug-ins
exists()
These are the methods for manipulating files:
isFile()
getFile()
putFile()
removeFile()
getFileMetadata()
getFileSize()
prestageFile()
getTransportURL()
These are the methods for... | fibbo/DIRAC | Resources/Storage/StorageBase.py | Python | gpl-3.0 | 10,948 | [
"DIRAC"
] | 9ff351837d2aaa221037b5f6d251f4bb28df09f8e956f750f88f0e32c05c2318 |
""" SlackAction
This action posts the status change to a Slack channel
It uses Slack Webhooks.
Also compatible with Mattermost, which is an open source alternative to Slack.
To create a webhook URL refer the following :
* Slack : https://api.slack.com/incoming-webhooks
* Mattermost : https://docs.mattermo... | yujikato/DIRAC | src/DIRAC/ResourceStatusSystem/PolicySystem/Actions/SlackAction.py | Python | gpl-3.0 | 4,501 | [
"DIRAC"
] | 05979eb6108c1a72fb2a5d28dd19df9887982ef29544252343eeabcf4e5e1b4f |
import os, shutil
import subprocess
SLURMJobTemplate = """#!/bin/bash -l
##execution shell environment
## name of your job
#SBATCH -J %job
## system error message output file
#SBATCH -e %outDir/stderr.txt
## system message output file
#SBATCH -o %outDir/stdout.txt
## a per-process (soft) memory limit
## limit is sp... | TurkuNLP/CAFA3 | learning/submit.py | Python | lgpl-3.0 | 3,231 | [
"Biopython"
] | c758a5a698ed1970f0053fd1d1a29e2a76d7db7c4df86d54c2d3d6010e8f1b6c |
# Create a probability density map over a single path/row
# Given a stack of L8 scenes in a parent directory,
# analyze the stack of pixels for changes in (blue - red) vs (green - nir)
import os
import re
import numpy as np
import pyproj
import rasterio as rio
from sklearn.neighbors import KernelDensity
from l8 i... | kapadia/l8 | l8/change.py | Python | mit | 3,597 | [
"Gaussian"
] | bbcf12ad9510574f3cf2e6cd16a5c53c59737a9c61f5ce5c6c9e86056c198fdc |
import random
import itertools
import string
import os
import tempfile
import logging
import subprocess
from pkg_resources import resource_filename
import contextlib
import shutil
import mdtraj as md
from mdtraj.utils import enter_temp_directory
from mdtraj.utils.delay_import import import_
import simtk.openmm
from si... | andrrizzi/openmoltools | openmoltools/utils.py | Python | gpl-2.0 | 19,804 | [
"Amber",
"Gromacs",
"MDTraj",
"OpenMM",
"RDKit"
] | 9004bc26f3248cce264631dc60349e0a1428e060a020e0cd6bcdd66d6187024b |
"""Calculator for the Embedded Atom Method Potential"""
# eam.py
# Embedded Atom Method Potential
# These routines integrate with the ASE simulation environment
# Paul White (Oct 2012)
# UNCLASSIFIED
# License: See accompanying license files for details
import os
import numpy as np
from ase.test import NotAvailable
f... | grhawk/ASE | tools/ase/calculators/eam.py | Python | gpl-2.0 | 30,391 | [
"ASE",
"LAMMPS"
] | 5ae57d3b7756697fd76c2960d57522574c0a5d655bb6970a46c4980e3c578450 |
"""Github 'Require pull request reviews before merging' was disabled for a repo."""
from streamalert.shared.rule import rule
@rule(logs=['ghe:general'])
def github_disable_required_pull_request_reviews(rec):
"""
author: @mimeframe
description: Setting 'Require pull request reviews before merging' w... | airbnb/streamalert | rules/community/github/github_disable_required_pull_request_reviews.py | Python | apache-2.0 | 1,100 | [
"VisIt"
] | 1a8e4a3c496ac7c5f5cccbcf0402a6f8a52df3d51f1b225cce03a79baea057e0 |
#!/usr/bin/env python
import glob
import subprocess
import shutil
import re
import yaml
import sys
import os
import argparse
def main(package, version='default', image=None, dryrun=False, clone=False, quiet=False):
parent_dir = os.path.dirname(os.path.abspath(__file__))
build_dir = os.path.join(parent_dir, pa... | galaxyproject/starforge | build.py | Python | mit | 8,387 | [
"Galaxy"
] | 134534479a7cdb20fa18b68e84fa1980a93c46e25c7ef416c7639774a38fc1bc |
'''A reporter class to prepare reports and network accounting plots.
Supports:
* packet loss rate (standard and magnified),
* one-way delay, jitter, jitter over one-way delay
'''
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
__RCSID__ = "$Id$"
import n... | yujikato/DIRAC | src/DIRAC/AccountingSystem/private/Plotters/NetworkPlotter.py | Python | gpl-3.0 | 9,155 | [
"DIRAC"
] | 390a5ff8d3e0c04eccc906baf8ff30ac2a269b1894a2f79a34a676a4366092e7 |
#!/usr/bin/env python
import vtk
from vtk.test import Testing
from vtk.util.misc import vtkGetDataRoot
VTK_DATA_ROOT = vtkGetDataRoot()
# A script to test the vtkROIStencilSource
reader = vtk.vtkPNGReader()
reader.SetDataSpacing(0.8,0.8,1.5)
reader.SetDataOrigin(0.0,0.0,0.0)
reader.SetFileName("" + str(VTK_D... | hlzz/dotfiles | graphics/VTK-7.0.0/Imaging/Core/Testing/Python/TestROIStencil.py | Python | bsd-3-clause | 3,470 | [
"VTK"
] | ad2e3cde692d040457fd5659af8b24550373231350cfd1eb1a98b99d1f66d8de |
# TODO: Parallelize by chromosome.
# Spawn a pheweb process to do each chromosome. Each one must do:
# + For every `pheno_gz/*.gz` and `sites/sites.tsv`, find the byte offset to the block that begins our chromosome.
# + Now cffi down into a function just like our normal one, but which starts at that offset, discar... | statgen/pheweb | pheweb/load/matrix.py | Python | agpl-3.0 | 4,144 | [
"pysam"
] | 0c7c14efde911de5a8899da59f665fcd3776960e1da58443d1c55e8a32a22c29 |
# ----------------------------------------------------------------------------
# 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/ordination/_utils.py | Python | bsd-3-clause | 6,345 | [
"scikit-bio"
] | 476406aefd034bbd79b6053941d07fd81bea2af7b930a12adfbd6dead51b1c46 |
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... | google-research/graph-attribution | graph_attribution/__init__.py | Python | apache-2.0 | 833 | [
"RDKit"
] | 6de33e38208f2c11fd992217326f54da975daf0f147a4841499a29b7c24ec711 |
# -*- coding: utf-8 -*-
"""
***************************************************************************
dataobject.py
---------------------
Date : August 2012
Copyright : (C) 2012 by Victor Olaya
Email : volayaf at gmail dot com
****************************... | NINAnor/QGIS | python/plugins/processing/tools/dataobjects.py | Python | gpl-2.0 | 16,128 | [
"NetCDF"
] | 11ff32013fe068aded7c2f4bdc6c72fb7cd78214665321abc8f6bc975b9b1ba0 |
import numpy as np
import scipy
import scipy.optimize as opt
import scipy.ndimage as ndimage
import scipy.ndimage.filters as filters
import matplotlib.pyplot as plt
import glob, os, sys, fnmatch
from astropy.io import fits as pyfits
from astropy.io import ascii
#define model Gaussian function and pass independent var... | kkozarev/mwacme | src/find_local_maxima_multi_integrated_2gaussian.py | Python | gpl-2.0 | 11,734 | [
"Gaussian"
] | cd3b0819a2d381b9ce0aa429a80a2e5cda2f162857509959746fe2de49e543d7 |
"""
Stubs and other tricks used across many tests to get make things quack like
a duck.
@author David W.H. Swenson
"""
import os
from functools import wraps
import numpy as np
import numpy.testing as npt
import simtk.unit as u
from nose.tools import assert_equal, assert_in, assert_true
#from nose.tools import assert... | jhprinz/openpathsampling | openpathsampling/tests/test_helpers.py | Python | lgpl-2.1 | 10,019 | [
"OpenMM"
] | 67ca5d72e0aaeafe19fd474083228868c9159f8596d28c658abceec446dd2668 |
#!/usr/bin/python
import sys
import struct
import os
from numpy import *
import datetime
from re import *
from copy import *
import threading
import string
import commands
def log_print(print_str):
os.system("echo '" + str(print_str) + "'")
def log_command(print_str):
os.system("echo " + str(print_str))
... | jason-weirather/Au-public | iron/code/pre-IDP/LSC_1_beta/bin/runLSC.py | Python | apache-2.0 | 25,339 | [
"BWA"
] | bf16659d81d6ec5e4848a1ea4302045712a16e4c423d5cf8648b743e43fa2aeb |
#! /usr/bin/python
"""versioneer.py
(like a rocketeer, but for versions)
* https://github.com/warner/python-versioneer
* Brian Warner
* License: Public Domain
* Version: 0.8+
This file helps distutils-based projects manage their version number by just
creating version-control tags.
For developers who work from a V... | pyannote/pyannote-server | versioneer.py | Python | mit | 24,306 | [
"Brian"
] | bd112d06535ff9b05d87902d9058541840f3a088a055ed3b76698b3da78fb49a |
# Copyright 2003-2008 by Leighton Pritchard. All rights reserved.
# This code is part of the Biopython distribution and governed by its
# license. Please see the LICENSE file that should have been included
# as part of this package.
#
# Contact: Leighton Pritchard, Scottish Crop Research Institute,
# ... | asherkhb/coge | bin/last_wrapper/Bio/Graphics/GenomeDiagram/_Colors.py | Python | bsd-2-clause | 8,438 | [
"Biopython"
] | e8b391f0c6109a1a7169fd74dbd17b1394b3babb27d7257d104022d438df2928 |
"""
mbed SDK
Copyright (c) 2011-2019 ARM Limited
SPDX-License-Identifier: Apache-2.0
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 ... | kjbracey-arm/mbed | tools/toolchains/arm.py | Python | apache-2.0 | 30,053 | [
"VisIt"
] | 0ad6a9449efc67f1a17ba7d9ba6726921dd7ae2fee46d284b2e7fd7927463c14 |
import pandas as pd
import timeit
import numpy as np
import pickle
import os, sys, time, random
from sklearn import gaussian_process
from ..sphere import sphere
def train_gp(calibration, alpha=1e-2):
"""Train a squared-exponential Gaussian process to predict offsets
in azimuthal equidistant space. The GPs are ... | johnhw/pypuffersphere | pyspheregl/touch/touch_calibration.py | Python | bsd-2-clause | 5,911 | [
"Gaussian"
] | 24413c6cde50aefeaa05a595b3fcdbbcb00fa56077e05b394a7f4a3293021c63 |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding:utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4 fileencoding=utf-8
#
# MDAnalysis --- https://www.mdanalysis.org
# Copyright (c) 2006-2017 The MDAnalysis Development Team and contributors
# (see the file AUTHORS for the full list of names)
#... | MDAnalysis/mdanalysis | testsuite/MDAnalysisTests/transformations/test_rotate.py | Python | gpl-2.0 | 10,100 | [
"MDAnalysis"
] | 033c153d7daf8fa9ca53a0c03d94719669e2bc25b6e50e2197a6de5f38113600 |
#!/usr/bin/env python
from peacock.ExodusViewer.plugins.MeshPlugin import MeshPlugin
from peacock.ExodusViewer.plugins.BackgroundPlugin import BackgroundPlugin
from BlockHighlighterPlugin import BlockHighlighterPlugin
from peacock.base.PluginManager import PluginManager
from peacock.base.TabPlugin import TabPlugin
from... | Chuban/moose | python/peacock/Input/InputFileEditorWithMesh.py | Python | lgpl-2.1 | 9,926 | [
"VTK"
] | 3038e52390328b7ef9df78b945d5c2effafb1510f8e25aa766838818a5bb99f6 |
from director import imageview
from director import vtkAll as vtk
from director import transformUtils
from director import visualization as vis
from director import viewbehaviors
from director import vtkNumpy as vnp
from director.debugVis import DebugData
from director.timercallback import TimerCallback
import PythonQt... | mitdrc/director | src/python/director/depthscanner.py | Python | bsd-3-clause | 6,311 | [
"VTK"
] | 430b7d34b567313c3acd9824f348da94c5271d80750400b8be02a16529c98e58 |
"""Copy number detection using read counts, with cn.mops.
http://www.bioconductor.org/packages/release/bioc/html/cn.mops.html
"""
from contextlib import closing
import os
import re
import shutil
import subprocess
import pysam
import toolz as tz
from bcbio import bam, install, utils
from bcbio.distributed.multi impor... | hjanime/bcbio-nextgen | bcbio/structural/cn_mops.py | Python | mit | 11,189 | [
"Bioconductor",
"pysam"
] | ff3d39a30815fae8cb4e81e870a25b087a1ff07a2f72c2b8417290f43297caa0 |
#!/usr/bin/env python
#
# Wrapper script for starting the Biopet JAR package
#
# This script is written for use with the Conda package manager and is copied
# from the peptide-shaker wrapper. Only the parameters are changed.
# (https://github.com/bioconda/bioconda-recipes/blob/master/recipes/peptide-shaker/peptide-shak... | hardingnj/bioconda-recipes | recipes/biopet/0.7.0/biopet.py | Python | mit | 3,302 | [
"Bioconda"
] | e737c73ccf725baa09d8d98163477b3deca4987f8e5e925bec0b7ab46e15836d |
import os
import ngsutils.support.ngs_utils
import pysam
class BedStreamer(object):
'''
Streams BedRegions from a BED file
Note - this can only be used once! There is no mechanism to seek the stream.
'''
def __init__(self, fname=None, fileobj=None, quiet=False):
if not fname and not file... | ngsutils/ngsutils | ngsutils/bed/__init__.py | Python | bsd-3-clause | 8,675 | [
"pysam"
] | 09b602f3db61b613fbb6e346e7a6b2837538b105235d9dc97e6c096462a22a44 |
import pandas as pd
import os,sys
import numpy as np
import argparse
import inspect
source_dir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
source_dir = '/'.join(source_dir.split('/')[:-1])
sys.path.append(source_dir)
from RASLseqTools import *
class RASLseqAnalysis_BLAST(object):
... | erscott/RASLseqTools | RASLseqTools/RASLseqAnalysis_BLAST.py | Python | mit | 10,772 | [
"BLAST"
] | ab25783a35e7c95bc568712e6f74b595327acdde5ddfa8f09f8a30fb3f0990dc |
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
__RCSID__ = "$Id$"
import importlib
from DIRAC import S_OK
from DIRAC.Core.Utilities.Extensions import extensionsByPriority
def getCurrentVersion():
""" Get a string corresponding to the current version of... | yujikato/DIRAC | src/DIRAC/Core/Utilities/Version.py | Python | gpl-3.0 | 1,022 | [
"DIRAC"
] | b0e89a5ebf6c5f72fa5bf04fcc181c939a1fbb6615d4a12ebe89519fa86089d9 |
#!/usr/bin/python
import sys
sys.path.append("./scripts")
import blasthittaxonomy
def checkarguments():
if len(sys.argv) != 2:
print "usage: ./addTaxonomyToBlastOutput.py <blast output file>"
sys.exit(-1)
def main():
checkarguments()
taxfetcher = blasthittaxonomy.TaxonomyFetcher()
filename = sys.ar... | bartaelterman/BlastTaxonomy | addTaxonomyToBlastOutput.py | Python | mit | 1,297 | [
"BLAST"
] | d97ab8234f609fc0a03901926523831ff07a75681f5ba74e5d8cbea2abf5b9b6 |
"""
Adds the tool_rating_association table, enabling tools to be rated along with review comments.
"""
from sqlalchemy import *
from sqlalchemy.orm import *
from sqlalchemy.exc import *
from migrate import *
from migrate.changeset import *
import datetime
now = datetime.datetime.utcnow
import sys, logging
log = loggi... | mikel-egana-aranguren/SADI-Galaxy-Docker | galaxy-dist/lib/galaxy/webapps/tool_shed/model/migrate/versions/0003_review_and_review_association_tables.py | Python | gpl-3.0 | 1,748 | [
"Galaxy"
] | fae91da4c2a5e504cbe99bfa69e459e7f3cf4f65256eec1d74d7080b81408cf2 |
# coding=utf-8
"""
A class to manage neuroimage files. A wrapper around nibabel, nipy and the rest of boyle for own purposes.
"""
# ------------------------------------------------------------------------------
# Author: Alexandre Manhaes Savio <alexsavio@gmail.com>
# Klinikum rechts der Isar, TUM, Munich
#
# 2016, Ale... | Neurita/boyle | boyle/image/base.py | Python | bsd-3-clause | 12,702 | [
"Gaussian"
] | 03f38fd9dd904e65034a85a7b94c9723584cdfad6c6dd7d9809e3b77a7e6e838 |
#!/usr/bin/python
"""
Copyright 2010 Paul Willworth <ioscode@gmail.com>
This file is part of Galaxy Harvester.
Galaxy Harvester is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of th... | clreinki/GalaxyHarvester | getUserHistory.py | Python | agpl-3.0 | 4,227 | [
"Galaxy"
] | 8982348103f58ebcf713a1417453bb7efc695b41d75789a3026ae62c024dbbfd |
#Redacted information as requested.
#It does so by placing the data into a pandas dataframe and processing the data sch that data types
# are correct and anomalous domains are removed.
#Of interest is how since there was not much data - nor many features - natural language processing of
# the domain names was a... | MichaelMKKang/Projects | Online_Marketing_Analysis/dataset-classification.py | Python | mit | 13,509 | [
"Gaussian"
] | f2c9c70a28a260a1fa7b87daf42ffaf6c0554edd79e3e35ce0cad778c728111d |
from bf1.battlefield import Battlefield
from .utils import API_KEY
def weapon_call(weapon):
bf = Battlefield('girbons', API_KEY, 'Pc')
response = bf.progression_service.get_weapon(weapon=weapon)
return response
def test_p08_pistol():
response = weapon_call("p08 pistol")
assert response.status_c... | Girbons/battlefield1-sdk | tests/test_weapon_resolver.py | Python | mit | 20,505 | [
"FLEUR"
] | 6bed7bc02457d2d369fd3ab0905882c1076aca08e4d5af0309687a27e4df3fd2 |
#!/usr/bin/python
# -*- coding: utf-8 -*-
from yade import plot, pack, qt, export, ymport, bodyHeat, cellHeat, sorption, utils
from yade.pack import *
import numpy as np
import os
#import heat
#import reaction2 as reaction
fric_Salt = 1.
fric_Wall= 1.
massScaling = 1e12
mn,mx=Vector3(-2.5,-2.5,0.),Vector3(2.5,2... | bcharlas/mytrunk | examples/heat/heat in py/02-heat in solid and flow/testcase.py | Python | gpl-2.0 | 6,375 | [
"VTK"
] | be616c45b05f6d66497bf0639d33afbf5a76c29b04eb5493e67f9fcab8212309 |
from __future__ import print_function
## Automatically adapted for numpy.oldnumeric Sep 06, 2007 by alter_code1.py
import numpy as np
import logging
DEBUG = False
def m_from_string(s):
"""
Creates a symmetry operator from a string
"""
m = []
t = np.array(eval("lambda x,y,z: ( %s )"%(s))(0,0,... | jonwright/ImageD11 | ImageD11/sym_u.py | Python | gpl-2.0 | 10,645 | [
"CRYSTAL"
] | 2ce8f57bd724f9c0790014b60a07dc2fb1b3af2917655014e3723a438a628e95 |
#!/usr/bin/python
import sys
import string
if len(sys.argv)<2 or len(sys.argv)>11:
print ('Usage: python band_comp_abinit2abinit.py [abinit _EIG file1] ...')
print (' ... [abinit _EIG file2] [align #kpt #band] ...')
print (' ... [nbdbuf #] [Fermi #abinit_file_1 #abinit_file_2] [eV]')
... | abinit/abinit | doc/tutorial/paw3_assets/scripts/comp_bands_abinit2abinit.py | Python | gpl-3.0 | 10,054 | [
"ABINIT"
] | 9e0cc5edddd80a25828791ff7cccae7cf8a5d23eb58ba2bd96da33be0a5b0b05 |
#!/usr/bin/env python
#
# Name: Galaxy2Cummerbund.py
# Date: 2014-06-30
# Author: Dan Shea <daniel.john.shea@gmail.com>
# Description:
#
# Galaxy does not use the same file naming convention as cummeRbund
# So, we need to rename the files
#
# Galaxy Name cummeRbund Name
#----------... | danshea/MoazedLab | Paper/Scripts/Galaxy2Cummerbund.py | Python | bsd-3-clause | 2,954 | [
"Galaxy"
] | 46ba7fda626d58cd29139b5ee2f5178f5e80125ec5842532aa275bca5c9c3fa2 |
# -*- coding: utf-8 -*-
# vi:si:et:sw=4:sts=4:ts=4
##
## Copyright (C) 2005-2007 Async Open Source <http://www.async.com.br>
## All rights reserved
##
## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU Lesser General Public License as published by
## the Free Softw... | andrebellafronte/stoq | stoqlib/lib/test/test_parameters.py | Python | gpl-2.0 | 8,310 | [
"VisIt"
] | f0b3f02b2c542038c79afe897b516500b9574084c1bc387dab480d0c28100a14 |
import unittest
import numpy as np
import cpnest.model
class GaussianModel(cpnest.model.Model):
"""
A simple gaussian model with parameters mean and sigma
"""
names=['mean','sigma']
bounds=[[-5,5],[0.05,1]]
data = np.array([x for x in np.random.normal(0.5,0.5,size=10)])
analyticZ = np.log(0... | johnveitch/cpnest | tests/test_gaussian.py | Python | mit | 1,178 | [
"Gaussian"
] | e189de91ea8ee1418761fc31d3e0ff623c550dc2bd89b1249e8b8d6c21787d68 |
#Some methods for calculating linear response functions
import numpy as np
from scipy import signal
from scipy import fftpack as fp
import spec
import Gnuplot
from scipy import signal
def response(xcm, a1, a2, tc, tw, dt):
"""Calculates and returns the linear response function corresponding to Cr
and Cl, the ... | Smattacus/data-analysis | python/modules/linresp.py | Python | gpl-2.0 | 2,872 | [
"Gaussian"
] | dc6b15b161e76f5484713fc85c535ed35dc7eb8947a3b8595fc34b2cd752c7cc |
#!/usr/bin/env python
# MIT License
#
# Copyright (c) 2017 Francesco Evangelista
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the right... | psi4/psi4 | psi4/share/psi4/scripts/vmd_cube.py | Python | lgpl-3.0 | 16,500 | [
"Psi4",
"VMD"
] | f9308ca52ccc817b770a0cf3a1bc2beb156f6a4485418abe99c27a522bcbad6d |
# Copyright (C) 2012,2013,2015,2016
# 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 term... | espressopp/espressopp | src/interaction/CoulombTruncated.py | Python | gpl-3.0 | 6,568 | [
"ESPResSo"
] | b8b65cb050e6749865539c497c67542d414e53ac3db92ccc262ce24fe0f9e3b5 |
#!/usr/bin/env python
# generate Python Manifest for the OpenEmbedded build system
# (C) 2002-2010 Michael 'Mickey' Lauer <mlauer@vanille-media.de>
# (C) 2007 Jeremy Laine
# licensed under MIT, see COPYING.MIT
#
# June 22, 2011 -- Mark Hatle <mark.hatle@windriver.com>
# * Updated to no longer generate special -dbg pa... | wwright2/dcim3-angstrom1 | sources/openembedded-core/scripts/contrib/python/generate-manifest-2.7.py | Python | mit | 16,327 | [
"VisIt"
] | bc00fd528657644d01c437ae9642d28c27305f6da566818d63d9df594bc51af2 |
""" NOTA BENE: This agent should NOT be run alone. Instead, it serves as a base class for extensions.
The TaskManagerAgentBase is the base class to submit tasks to external systems,
monitor and update the tasks and file status in the transformation DB.
This agent is extended in WorkflowTaskAgent and Reque... | ic-hep/DIRAC | src/DIRAC/TransformationSystem/Agent/TaskManagerAgentBase.py | Python | gpl-3.0 | 32,115 | [
"DIRAC"
] | c30bf2c052aa8057ceb280aedccf21e85fcebfb8b66e8d676e0228eaa3060233 |
#!/usr/bin/env python
"""
This is a master vasp running script to perform various combinations of VASP
runs.
"""
from __future__ import division
import logging
import sys
import ruamel.yaml as yaml
from custodian.custodian import Custodian
from custodian.vasp.jobs import VaspJob
from pymatgen.io.vasp import VaspInp... | specter119/custodian | custodian/cli/run_vasp.py | Python | mit | 12,262 | [
"VASP",
"pymatgen"
] | a48b13a10d4c1939efc7a6c86a5c2e742204eaf6269ab9741f405c81b11e30b3 |
import numpy as np
from scipy.ndimage import gaussian_filter1d
from scipy.ndimage.filters import laplace
try:
from skimage import filters
except ImportError:
from skimage import filter as filters
from tqdm import tqdm
from functools import reduce
from scipy.interpolate import RegularGridInterpolator
import skfm... | RivuletStudio/rivuletpy | filtering/morphology.py | Python | bsd-3-clause | 7,344 | [
"Gaussian"
] | 342acceb12cdf4b65e0a3e886c054d3b7689494e5a3226bd044d8fcd12fdfc6c |
# shamelessly copied from pliExpertInfo (Vali, Mirakels, Littlesat)
from enigma import iServiceInformation, iPlayableService
from Components.Converter.Converter import Converter
from Components.Element import cached
from Components.config import config
from Tools.Transponder import ConvertToHumanReadable
from Tools.Ge... | opendroid-Team/enigma2-4.1 | lib/python/Components/Converter/PliExtraInfoNobile.py | Python | gpl-2.0 | 24,718 | [
"Galaxy"
] | 55d543125bb49a692b4fe8e0261e499d0536c36688f6948922e4613705e9b351 |
#!/usr/bin/env python
"""
lib.py
General ROMS utils
Written by Brian Powell on 05/24/13
Copyright (c)2017 University of Hawaii under the MIT-License.
"""
import numpy as np
import seapy
from seapy.lib import default_epoch, secs2day
import netCDF4
fields = {"zeta": {"grid": "rho", "dims": 2},
"ubar... | ocefpaf/seapy | seapy/roms/lib.py | Python | mit | 15,092 | [
"Brian",
"NetCDF"
] | 1ec509cc791b2f2098b967a5908b3cf39415299e2629b4ec223bac00c4b2a05b |
################################################################################
# Copyright (C) 2011-2012,2014 Jaakko Luttinen
#
# This file is licensed under the MIT License.
################################################################################
"""
Module for the mixture distribution node.
"""
import wa... | dungvtdev/upsbayescpm | bayespy/inference/vmp/nodes/mixture.py | Python | mit | 20,776 | [
"Gaussian"
] | e8273025aa0a5a6be48c3eb32cd54299a80ab7da60a4362106a541e42f2dc8c8 |
""" Module holding function(s) creating the pilot wrapper.
This is a DIRAC-free module, so it could possibly be used also outside of DIRAC installations.
The main client of this module is the SiteDirector, that invokes the functions here more or less like this::
pilotFilesCompressedEncodedDict = getP... | DIRACGrid/DIRAC | src/DIRAC/WorkloadManagementSystem/Utilities/PilotWrapper.py | Python | gpl-3.0 | 11,079 | [
"DIRAC"
] | 8560ac0602703cc6c4943f6a6e054d651e5c14ba784c5497e368180e775a53bb |
""" The SiteSEMapping module performs the necessary CS gymnastics to
resolve site and SE combinations. These manipulations are necessary
in several components.
Assumes CS structure of: /Resources/Sites/<GRIDNAME>/<SITENAME>
"""
__RCSID__ = "$Id$"
from DIRAC import gLogger, S_OK
from DIRAC.DataManag... | andresailer/DIRAC | Core/Utilities/SiteSEMapping.py | Python | gpl-3.0 | 5,364 | [
"DIRAC"
] | f4a9138758dca2eada7bacb6a8898045f84934d5c187b8d60956b479002875b3 |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding:utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4 fileencoding=utf-8
#
# MDAnalysis --- http://www.mdanalysis.org
# Copyright (c) 2006-2016 The MDAnalysis Development Team and contributors
# (see the file AUTHORS for the full list of names)
#
... | kain88-de/mdanalysis | testsuite/MDAnalysisTests/topology/test_xpdb.py | Python | gpl-2.0 | 1,572 | [
"MDAnalysis"
] | c758de40d0e66eb6fffc80c11989e88cd0443ee94d07537cca915537f9a02f30 |
#!/usr/bin/env python
#
# Copyright 2014-2016 Peter Bittner <django@bittner.it>
#
# 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 re... | Organice/django-organice | organice/bin/organice_setup.py | Python | apache-2.0 | 26,638 | [
"VisIt"
] | 2a54fef5b0dcade10ac08fb9b6fd42a4dac9b62975f9894eb7957294d15747cf |
"""
GUI module.
"""
from __future__ import absolute_import, division
import os
try:
# python 2.x
from Tkinter import *
from ttk import *
from tkFileDialog import askopenfilenames, asksaveasfilename
from tkMessageBox import showerror, showinfo
from tkSimpleDialog import Dialog
except ImportError... | HuiLiuCode/pymdlog | pymdlog/gui.py | Python | gpl-3.0 | 17,722 | [
"Amber",
"NAMD"
] | 7bb3225d80910c71850a1354254f5644bee0ae33058789bcb110b6b989616a1e |
# -*- coding: utf-8 -*-
"""
Unit tests for instructor.api methods.
"""
import datetime
import functools
import io
import json
import random
import shutil
import tempfile
import ddt
import pytest
import six
from boto.exception import BotoServerError
from django.conf import settings
from django.contrib.auth.models imp... | msegado/edx-platform | lms/djangoapps/instructor/tests/test_api.py | Python | agpl-3.0 | 191,698 | [
"VisIt"
] | ea32393c285f28eb3f7cf1528b12514581b407b92168be37275333002d0fc6fd |
"""
30 Oct 2012
unittest for pytadbit functions
"""
from __future__ import print_function
import matplotlib
from functools import reduce
from collections import OrderedDict
matplotlib.use('Agg')
import unittest
from pytadbit import Chromosome, load_chromosome
from pytadbit ... | 3DGenomes/tadbit | test/test_all.py | Python | gpl-3.0 | 45,593 | [
"pysam"
] | 06ac63f5cda0042fb7d7a511593037eb7678cd16907f346a5b6c275f577a4b2a |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding: utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4
from __future__ import print_function
from . import utilities
import numpy as np
Bohr = .52917721067
def consecutive_filename(universe, basename):
if basename.endswith('.cube'):
... | balazsfabian/pytim | pytim/cube.py | Python | gpl-3.0 | 4,116 | [
"CPMD"
] | c89257af2831365391c97aefce4bef7fe006934b25f01991ce388ebac8043365 |
# pylint: disable=no-init,invalid-name,too-many-locals,too-few-public-methods
from __future__ import (absolute_import, division, print_function)
import stresstesting
from mantid.simpleapi import *
import numpy as np
class POLDIFitPeaks2DTest(stresstesting.MantidStressTest):
"""The system test currently checks tha... | wdzhou/mantid | Testing/SystemTests/tests/analysis/POLDIFitPeaks2DTest.py | Python | gpl-3.0 | 7,263 | [
"Gaussian"
] | c9395e1ad023d0874f9c99d7921e6d22136e8ade714ef913ab91fe3406ece44b |
# -*- coding: utf-8 -*-
"""Utilities for displaying graphs with inline HTML in Jupyter Notebooks."""
from random import sample
from typing import Mapping, Optional
from .constants import DEFAULT_COLOR_MAP
from ..jinja_utils import build_template_renderer
from ..nodelink import to_nodelink_jsons
from ...struct import... | pybel/pybel | src/pybel/io/jupyter/inline.py | Python | mit | 2,577 | [
"Pybel"
] | af9cd7c588a68d10247b78727a67ac241441d1976816464da7c9d0e4badc9d6a |
"""
Automatically generates the QCArchive environments
"""
import copy
from ruamel.yaml import YAML
yaml = YAML()
yaml.indent(mapping=2, sequence=2, offset=2)
template = """
name: qcarchive
channels:
- defaults
- conda-forge
dependencies:
- pip
# Core dependencies
- msgpack-python >=0.6.1
- numpy
- py... | psi4/DatenQM | devtools/conda-envs/generate_envs.py | Python | bsd-3-clause | 4,000 | [
"OpenMM",
"Psi4",
"RDKit"
] | e6bffa297e4882487edfc4a8d505c0479d543a8c7e29f7758261515969147ac1 |
#!/usr/bin/env python
#-----------------------------------------------------------------------------
# Copyright (c) 2013--, biocore development team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file COPYING.txt, distributed with this software.
#-------------------------... | biocore/burrito-fillings | setup.py | Python | bsd-3-clause | 1,694 | [
"scikit-bio"
] | 439725898c1195f7b2dc68e3aa60c12a0988a2769bbd42a8352d2eb38443b9f0 |
# coding: utf-8
from __future__ import unicode_literals, division
"""
Created on Jun 1, 2012
"""
__author__ = "Shyue Ping Ong, Stephen Dacek"
__copyright__ = "Copyright 2012, The Materials Project"
__version__ = "0.1"
__maintainer__ = "Shyue Ping Ong"
__email__ = "shyue@mit.edu"
__date__ = "Jun 1, 2012"
import uni... | specter119/custodian | custodian/vasp/tests/test_handlers.py | Python | mit | 26,773 | [
"VASP",
"pymatgen"
] | c5b88d6b873bb8a5b930ab8268d75bf03849af5eae75e2f602d28a1c88a5f17b |
from pathlib import Path
def visit(path: Path, depth: int = 0) -> None:
for item in path.iterdir():
s = f"{' ' * depth}{item.name}:"
if item.is_dir():
print(s)
visit(item, depth + 1)
else:
print(f"{s} {item.stat().st_size:,} bytes")
visit(Path("."))
| cclauss/Ten-lines-or-less | walking_the_path.py | Python | apache-2.0 | 319 | [
"VisIt"
] | 11c219a6c886dc2c3555068a86b79cbd15f43d2b4ec0ab81932f4480c311846a |
"""
Tests for discussion pages
"""
import datetime
from pytz import UTC
from uuid import uuid4
from nose.plugins.attrib import attr
from .helpers import BaseDiscussionTestCase
from ..helpers import UniqueCourseTest
from ...pages.lms.auto_auth import AutoAuthPage
from ...pages.lms.courseware import CoursewarePage
from... | motion2015/a3 | common/test/acceptance/tests/discussion/test_discussion.py | Python | agpl-3.0 | 41,768 | [
"VisIt"
] | e8325e3e0a80049dfd3451141c0fb6dfb8c892a8d1fa223bba527d33ca1694b0 |
#===============================================================================
# Set up
#===============================================================================
# Standard:
from config import *
import logging.config
import unittest
from ExergyUtilities.utility_inspect import get_self
#from utility_pathOL... | MarcusJones/EnergyParser | idf/tests/tests_old.py | Python | lgpl-3.0 | 9,050 | [
"EPW"
] | 8562de0490fb9032df9da0835b59de39b4008490f7e50cc0edf498533fbdbe9b |
from aces.materials import Material
from ase import Atoms,Atom
from math import pi,sqrt,cos,sin
from aces.materials.graphene import structure as graphene
from aces.materials.GNT import structure as GNT
import numpy as np
from aces.runners import Runner
from aces.runners.phonopy import RotateVector
from aces.tools impo... | vanceeasleaf/aces | aces/materials/graphene_pair.py | Python | gpl-2.0 | 5,275 | [
"ASE",
"Gaussian",
"LAMMPS",
"phonopy"
] | 1b86bbd40a61ea049cb02bbe527061e8bb5a6594d435c3f413f3735ec4e5fe8b |
from nipype import logging
from nipype.interfaces import ants
logger = logging.getLogger('nipype.workflow')
from CPAC.pipeline import nipype_pipeline_engine as pe
import nipype.interfaces.fsl as fsl
import nipype.interfaces.utility as util
from nipype.interfaces import afni
from nipype.interfaces.afni import preproce... | FCP-INDI/C-PAC | CPAC/func_preproc/func_preproc.py | Python | bsd-3-clause | 88,098 | [
"Brian"
] | 5d87812dfd4c06bf91e9dcb68186ab995652577d3c3f10f09b1d6b372f086d61 |
__author__ = 'jchugh'
from multiprocessing import Process
from ConfigParser import NoOptionError
from simple_kafka import kafka_client
from simple_oauth.oauth import Oauth
from simple_oauth.oauth_request import Request
from simple_oauth.oauth_token import Token
from twitter import TwitterStream
from config import confi... | joychugh/learning-kafka | main.py | Python | mit | 3,725 | [
"VisIt"
] | a42e12027a9f1c1fb2a56d3cf0cc89f2520a1b66096a1282ce943bb500b2cfb1 |
#! /usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless requi... | googleapis/python-appengine-admin | scripts/fixup_appengine_admin_v1_keywords.py | Python | apache-2.0 | 7,923 | [
"VisIt"
] | 50bd4d15979f752280b9584c8fe069a4ee08a12b1c49c47d33d4bd5bd18dbf6c |
# 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 u... | rahul003/mxnet | python/mxnet/gluon/model_zoo/vision/vgg.py | Python | apache-2.0 | 9,352 | [
"Gaussian"
] | 07f163773e6e9c054ea66c9095c75cbf295eaddbf1b93c186e59d18a24992e5a |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.