text stringlengths 12 1.05M | repo_name stringlengths 5 86 | path stringlengths 4 191 | language stringclasses 1
value | license stringclasses 15
values | size int32 12 1.05M | keyword listlengths 1 23 | text_hash stringlengths 64 64 |
|---|---|---|---|---|---|---|---|
#!/usr/bin/env python
"""
skimr is a web application for streamlining reading of articles online.
It currently works for articles on Medium.com but could be adapted for articles
on other websites with minor adjustments to the html cleaning function.
The framework of skimr is:
- Use selenium webdriver to scrape full ... | cyucheng/skimr | skimr/skimr.py | Python | bsd-3-clause | 13,572 | [
"VisIt"
] | 89f8032d41edb57ddda4fb8652d3ba0ee504a2cfdefef914ef0c1ce4d1e0d948 |
# IM - Infrastructure Manager
# Copyright (C) 2011 - GRyCAP - Universitat Politecnica de Valencia
#
# 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... | grycap/im | IM/VirtualMachine.py | Python | gpl-3.0 | 48,765 | [
"Galaxy"
] | 3814744505cab636c257ce6199cab73b9b78e7607ac2504417141307c2bdfbe9 |
""" MySQL based WMSHistory accounting.
It's suggested to replace this with the ElasticSearch based WMSHistory monitoring.
Filled by the agent "WorkloadManagement/StatesAccountingAgent"
"""
from DIRAC.AccountingSystem.Client.Types.BaseAccountingType import BaseAccountingType
class WMSHistory(BaseAccountingTy... | DIRACGrid/DIRAC | src/DIRAC/AccountingSystem/Client/Types/WMSHistory.py | Python | gpl-3.0 | 1,360 | [
"DIRAC"
] | f70e8048c9d3493bd2ba14ab1466bcaa65c6f4013a4f611ce3ddd74789a9ea86 |
"""
=============================================================
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... | chenyyx/scikit-learn-doc-zh | examples/zh/gaussian_process/plot_gpr_noisy.py | Python | gpl-3.0 | 3,847 | [
"Gaussian"
] | 1f73b8d15aeefb742d2f3430a11f0981446351566c62a54dfa88ec646ba70cc9 |
import vtk
#import numpy as np
import os
vmtk_avail = True
try:
from vmtk import vtkvmtk
except ImportError:
print("unable to import vmtk module")
vmtk_avail = False
file1 = "/home/ksansom/caseFiles/mri/PAD_proj/case1/vmtk/TH_0_PATIENT7100_M_clean_0.vtp"
file2 = "/home/ksansom/caseFiles/mri/PAD_proj/case1... | kayarre/Tools | vtk/intersection_test.py | Python | bsd-2-clause | 2,684 | [
"VTK"
] | 0efc1f6f67b2865f31f49836ea99eb3403ef7c1afbacce7a55f0af6e357becf6 |
#
# Copyright (c) 2015 nexB Inc. and others. All rights reserved.
# http://nexb.com and https://github.com/nexB/scancode-toolkit/
# The ScanCode software is licensed under the Apache License version 2.0.
# Data generated with ScanCode require an acknowledgment.
# ScanCode is a trademark of nexB Inc.
#
# You may not use... | vinodpanicker/scancode-toolkit | src/scancode/__init__.py | Python | apache-2.0 | 1,380 | [
"VisIt"
] | 81083df6976051c45f7ab4dd3de878e33c39c93c5b44abcea1556ceadec080f4 |
# Developed by Redjumpman for Redbot.
# Standard Library
import asyncio
import calendar
import logging
import re
from typing import Union
from operator import itemgetter
# Casino
from . import utils
from .data import Database
from .games import Core, Blackjack, Double, War
# Red
from redbot.core.i18n import Transla... | Redjumpman/Jumper-Cogs | casino/casino.py | Python | gpl-3.0 | 50,269 | [
"CASINO"
] | 0079c81e79c5e7e35aea9b29ff3fa822ba3c1bee469e1c3a7eeb65eddec0ff2c |
# -*- Mode: python; tab-width: 4; indent-tabs-mode:nil; coding:utf-8 -*-
# vim: tabstop=4 expandtab shiftwidth=4 softtabstop=4
#
# 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)
#
# Released under th... | alejob/mdanalysis | package/MDAnalysis/coordinates/XDR.py | Python | gpl-2.0 | 9,410 | [
"Gromacs",
"MDAnalysis"
] | b91cd83f4178bf30dfd6fb90515dd3658ca75ea30125d1a1f493c5fb0f54b035 |
"""Gaussian processes classification."""
# Authors: Jan Hendrik Metzen <jhm@informatik.uni-bremen.de>
#
# License: BSD 3 clause
from operator import itemgetter
import numpy as np
from scipy.linalg import cholesky, cho_solve, solve
import scipy.optimize
from scipy.special import erf, expit
from ..base import BaseEst... | lesteve/scikit-learn | sklearn/gaussian_process/_gpc.py | Python | bsd-3-clause | 35,004 | [
"Gaussian"
] | 21dd1ca358825a24b453d31014e0d1a7cd6a9fc865a9650bada679a9c275a212 |
import types
import logging
import simplejson
from dirac.lib.base import *
from pylons.controllers.util import redirect_to
from pylons.decorators import jsonify
import dirac.lib.helpers as helpers
from dirac.lib.credentials import authorizeAction
from dirac.lib.diset import getRPCClient
import dirac.lib.credentials ... | DIRACGrid/DIRACWeb | dirac/controllers/systems/configuration.py | Python | gpl-3.0 | 19,257 | [
"DIRAC"
] | 5f9ec45f9eb41133398a280bb48d384171c9579d5d9678f284e9878490dff174 |
# coding: utf-8
from __future__ import division, unicode_literals
"""
This module defines filters for Transmuter object.
"""
__author__ = "Will Richards, Shyue Ping Ong, Stephen Dacek"
__copyright__ = "Copyright 2011, The Materials Project"
__version__ = "1.0"
__maintainer__ = "Will Richards"
__email__ = "wrichards... | rousseab/pymatgen | pymatgen/alchemy/filters.py | Python | mit | 11,559 | [
"pymatgen"
] | 00fd4e9122a0a5328062607c0b73e827a4a7aa559574826defee0bf83954aad1 |
#
# @BEGIN LICENSE
#
# Psi4: an open-source quantum chemistry software package
#
# Copyright (c) 2007-2017 The Psi4 Developers.
#
# The copyrights for code used from other parties are included in
# the corresponding files.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of ... | kratman/psi4public | psi4/driver/qcdb/molpro2.py | Python | gpl-2.0 | 27,551 | [
"CFOUR",
"Psi4"
] | 7bb2ecee6e6e024583165a72edef6a47a2efbc1de5c6cdae9219d521d001cf90 |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
import json
import glob
import itertools
import logging
import math
import os
import re
import warnings
from pathlib import Path
import xml.etree.cElementTree as ET
from collections import defaultdict
from io ... | blondegeek/pymatgen | pymatgen/io/vasp/outputs.py | Python | mit | 192,592 | [
"CRYSTAL",
"VASP",
"VisIt",
"pymatgen"
] | 9841d1ab96d878085f94f08c5c2d969cdc2b587cd2cba02c310d66ff9f085217 |
####################################################
#
# This script uses Py++ to create the Python
# wrappers for Sire. This script should be run
# in a directory that contains the results
# of scanheaders.py
#
#
import os
import sys
import pickle
import re
import logging
from glob import glob
sys.path.append("../A... | michellab/Sire | wrapper/AutoGenerate/create_wrappers.py | Python | gpl-2.0 | 29,114 | [
"OpenMM"
] | b046ddc1bc9491e2f800f362a660ead71eb636e54eebf34611df572ff5c3d8ef |
#!/usr/bin/env python3
#
# Randomize the (X,Y) position of each X-ray photon events according
# to a Gaussian distribution of given sigma.
#
# References:
# [1] G. Scheellenberger, T.H. Reiprich, L. Lovisari, J. Nevalainen & L. David
# 2015, A&A, 575, A30
#
#
# Aaron LI
# Created: 2016-03-24
# Updated: 2016-03-24
#... | liweitianux/atoolbox | astro/chandra/randomize_events.py | Python | mit | 2,207 | [
"Gaussian"
] | 28d31e08ccb11a7a50c979542d0c24c17c1f7c172e02ce5c0acd43e4e0fc90a8 |
# coding=utf-8
# Copyright 2022 Google LLC.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed ... | google-research/large_scale_mmdma | lsmmdma/mmdma_functions.py | Python | apache-2.0 | 11,951 | [
"Gaussian"
] | 17d9c2c25faddb713c1d0b270968c0f3002f8482595181b16e54dcf669a10c4c |
##################################################################
# Copyright 2018 Open Source Geospatial Foundation and others #
# licensed under MIT, Please consult LICENSE.txt for details #
##################################################################
import os
import sys
import click
import signal
imp... | bird-house/PyWPS | pywps/cli.py | Python | mit | 4,690 | [
"VisIt"
] | 5baa3a80f75ad5637344b112d8ce364c34f5f517ce6dfff9ea6441c923fa7707 |
# -*- coding: utf-8 -*-
"""
Created on Tue Apr 28 11:11:40 2015
@author: martin
"""
from DNAFromProt import DNAFromProt
from Bio.Seq import Seq
from Bio.Alphabet import IUPAC
def prepareDNAss(x,y,z):
# x est un objet Seq de Biopython, représentant une protéine
# y est un objet Seq de Biopython, représentant ... | MartinSilvert/overlappingGenesCreator | src/prepareDNAss.py | Python | apache-2.0 | 2,080 | [
"Biopython"
] | 1e685ae47dc92fdf0bdb99f792f17844d9dc589d21b378a4017957ea9d621c00 |
#!/usr/bin/python
import sys
import os
import re
import option_list as OL
import random
from afni_base import *
from db_mod import *
from math import pow
help_string = """
afni_restproc.py
This script takes care of preprocessing commonly done prior to resting state
analyses. The process is similar to ANATICOR and... | colmconn/rsfcGraphAnalysis | afni_restproc.py | Python | gpl-2.0 | 93,488 | [
"Gaussian"
] | b707cc5db743086f11ffe2498a03f31ca5f85d1ec686ad6f3989fc2e9d7a6d19 |
import numpy as np
import os
try:
import netCDF4 as netCDF
except:
import netCDF3 as netCDF
import matplotlib.pyplot as plt
import time
from datetime import datetime
from matplotlib.dates import date2num, num2date
import pyroms
import pyroms_toolbox
import _remapping
class nctime(object):
pass
def remap_clm_... | kshedstrom/pyroms | examples/Arctic_HYCOM/remap_clm_uv.py | Python | bsd-3-clause | 7,105 | [
"NetCDF"
] | 01a0242c09dd0595435bc5cc873af51c220af05a2eb77962191dcbbf435d5936 |
from pudzu.charts import *
FONT_SIZE = 16
BLUE = "#377eb8"
RED = "#e41a1c"
GREEN = "#4daf4a"
PINK = "#f781bf"
GREY = "#999999"
ORANGE = "#ff7f00"
BROWN = "#7F3300"
YELLOW = "#ECC850"
PURPLE = "#984ea3"
LEGEND = [
("Constitutional Union Party", "1860", "Big tent party whose main aim was to preserve the U... | Udzu/pudzu | dataviz/politics_usthird.py | Python | mit | 7,928 | [
"MOOSE"
] | d79e59c47812b2b574d83d52ad431ffcb680fae6493a164bfa080a44a7ac6c80 |
__doc_format__ = "reStructuredText"
'''
Shows info about netCDF on command line!
:Author: kmu
:Created: 18. jan. 2012
'''
''' Imports '''
# Built-in
import sys
execfile("../themes/set_pysenorge_path.py")
# Additional
# Own
from pysenorge.io.nc import NCreport
if len(sys.argv) != 2:
print "USAG... | kmunve/pysenorge | pysenorge/tools/NCreport.py | Python | gpl-3.0 | 401 | [
"NetCDF"
] | eb6f33efe76da989bada1ad445a6d21f20039578924605bf784a05aed2ed132f |
from rdkit import Chem
#from rdkit.Chem.Draw import IPythonConsole
#from IPython.display import SVG
import time
from rdkit.Chem import rdDepictor
from rdkit.Chem.Draw import rdMolDraw2D
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.cm as cm
import matplotlib
def moltosvg(mol,molSize=(1000,1000)... | debbiemarkslab/neural-fingerprint-theano | code/visualization/highlight_molecule_cnn.py | Python | mit | 2,737 | [
"RDKit"
] | 6d865b6b2651e5fda36391f7c8bcb4a98f73e27b9ac5f6b63c1a72f5de696d8e |
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
"""
Wrapper to trim and correct sequence data.
"""
import os
import os.path as op
import sys
import logging
from jcvi.formats.base import BaseFile, write_file, must_open
from jcvi.formats.fastq import guessoffset
from jcvi.utils.cbook import depends, human_size
from jcvi... | sgordon007/jcvi_062915 | assembly/preprocess.py | Python | bsd-2-clause | 22,843 | [
"BLAST",
"Bowtie"
] | acadea034298c2429ef6639505a70872ea854b0a0b9d59274d9ca23fa967d50b |
"""
init.py
Starting script to run NetPyNE-based model.
Usage: python init.py # Run simulation, optionally plot a raster
MPI usage: mpiexec -n 4 nrniv -python -mpi init.py
"""
from netpyne import sim
cfg, netParams = sim.readCmdLineArgs(simConfigDefault='cfg.py', netParamsDefault='netParams.py')
# sim.createSi... | Neurosim-lab/netpyne | examples/batchCell/init.py | Python | mit | 1,206 | [
"NEURON"
] | f872effb9ae08adfd651fc428cfb387a6327cb1e3b69c4d06ca39ce5128a5e02 |
#!/usr/bin/env python
# Filename: util.py
'''
util
@author: Andrew Philpot
@version 0.79
collection of misc utils
Usage: python util.py
Options:
\t-h, --help:\tprint help to STDOUT and quit
\t-v, --verbose:\tverbose output
'''
import sys
import inspect
import types
import getopt
import fileinput
import tempfile
impo... | philpot/pymod | util.py | Python | apache-2.0 | 55,112 | [
"VisIt"
] | 1764bef046dc6ca996e87fb143d0f183bf2453171c4484fcab105d61539ea0ac |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
from __future__ import division, unicode_literals
"""
Created on Feb 2, 2012
"""
__author__ = "Shyue Ping Ong"
__copyright__ = "Copyright 2012, The Materials Project"
__version__ = "0.1"
__maintainer__ = "Sh... | gpetretto/pymatgen | pymatgen/apps/battery/tests/test_conversion_battery.py | Python | mit | 3,875 | [
"pymatgen"
] | 9754119c339945057465cac3b3d2be8146a5439a2588059f81b788b1da1926b5 |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals, print_function
import os
from tempfile import mkdtemp
from shutil import rmtree
import locale
import logging
import subprocess
from pelican import Pelican
from pelican.settings import read_settings
from pelican.tests.support import LoggedTestCase, mute
... | justinmayer/pelican | pelican/tests/test_pelican.py | Python | agpl-3.0 | 6,560 | [
"exciting"
] | 76f4d2c9cedefa00ada74aac03cac1cabcb5006f8c7b30cba6b178c52bddfe0f |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module provides classes to interface with the Crystallography Open
Database. If you use data from the COD, please cite the following works (as
stipulated by the COD developers)::
Merkys, A., Vaitk... | matk86/pymatgen | pymatgen/ext/cod.py | Python | mit | 4,804 | [
"CRYSTAL",
"pymatgen"
] | 39c694e9d8032991d987aff2f3393eb128b93476dece3fcf06bfa3bd60fd2699 |
# This file is part of cclib (http://cclib.sf.net), a library for parsing
# and interpreting the results of computational chemistry packages.
#
# Copyright (C) 2006, the cclib development team
#
# The library is free software, distributed under the terms of
# the GNU Lesser General Public version 2.1 or later. Yo... | Clyde-fare/cclib_bak | src/cclib/method/opa.py | Python | lgpl-2.1 | 5,008 | [
"cclib"
] | 31292f789a68ba8c0d1bb8a745887bb7b44daaedac059266d985f8039ccb3034 |
''' Test_RSS_Command_CEAvailabilityCommand
'''
import unittest
import importlib
import mock
from DIRAC import gLogger
import DIRAC.ResourceStatusSystem.Command.CEAvailabilityCommand as moduleTested
__RCSID__ = '$Id: $'
################################################################################
class CEAvai... | andresailer/DIRAC | ResourceStatusSystem/Command/test/Test_RSS_Command_CEAvailabilityCommand.py | Python | gpl-3.0 | 23,461 | [
"DIRAC"
] | 7628fd45bb3c22bbbe875436a671883f5c0459cbf8ce39fc31a0caa51d0b8bf6 |
# (c) 2014, Brian Coca <bcoca@ansible.com>
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.... | jordiclariana/ansible | lib/ansible/plugins/filter/mathstuff.py | Python | gpl-3.0 | 4,042 | [
"Brian"
] | 27392b4b64a8159fa5e7f1555f08950c5d4ebf9150f482c37acc7e9246be937f |
# -*- coding: utf-8 -*-
"""
Part of the astor library for Python AST manipulation.
License: 3-clause BSD
Copyright (c) 2008 Armin Ronacher
Copyright (c) 2012-2017 Patrick Maupin
Copyright (c) 2013-2017 Berker Peksag
This module converts an AST into Python source code.
Before being version-controlled as part of... | berkerpeksag/astor | astor/code_gen.py | Python | bsd-3-clause | 31,834 | [
"VisIt"
] | 89fb54db4680ae10a3e3421e8f49b08a2b220839218d7dbfc106bd13f9ecf1d1 |
__author__ = 'sibirrer'
import numpy as np
import sys
import scipy.ndimage as ndimage
import scipy.signal as signal
from easylens.FunctionSet.shapelets import Shapelets
import easylens.util as util
class DeLens(object):
"""
class for the de-lensing algorithm
"""
def __init__(self):
self.sha... | DES-SL/EasyLens | easylens/DeLens/de_lens.py | Python | mit | 6,737 | [
"Gaussian"
] | 57d8a9b1d35df374b073a0dce6fe54a16ed9c947fb45b1797c8a5f3a2aeb0fba |
##
## Created : Mon May 14 23:04:44 IST 2012
## Last Modified : Mon Feb 25 00:53:40 PST 2019
##
## Copyright (C) 2012 Sriram Karra <karra.etc@gmail.com>
##
## This file is part of PRS
##
## PRS is free software: you can redistribute it and/or modify it under
## the terms of the GNU Affero General Public License a... | skarra/PRS | src/models.py | Python | agpl-3.0 | 18,818 | [
"VisIt"
] | a1f64c796f4e410a5f3ac5266327a5f09706099b61c9869dc735701d9c962bb5 |
#!/usr/bin/env python
"""
Calculate the angular distribution function (ADF) from files.
Take an average over atoms in a file or files.
Usage:
adf.py [options] INFILE [INFILE...]
Options:
-h, --help Show this help message and exit.
-w DEG Width of the angular degree. [default: 1.0]
-r RCUT Cutoff rad... | ryokbys/nap | nappy/adf.py | Python | mit | 8,577 | [
"ADF",
"Gaussian"
] | d993c2f910a3e775f7a076ad8bd10b05502ddfe2a61ca92af6760cd3cd2d37ca |
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack import *
class Libristra(CMakePackage):
""" The ristra library is a set of support utilities for
ris... | LLNL/spack | var/spack/repos/builtin/packages/libristra/package.py | Python | lgpl-2.1 | 1,666 | [
"ParaView"
] | 6f3c2903846fbac6ebc6afbff8bde951ecf6946d36972ee82e3058742a5906a3 |
#\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\#
'''Application handler for Gaudi applications in LHCb.'''
import os
import tempfile
import gzip
import pickle
from GangaCore.GPIDev.Schema import SimpleItem, FileItem
from GangaCore.Core.exceptions import ApplicationConfigurationError
impor... | ganga-devs/ganga | ganga/GangaGaudi/Lib/Applications/Gaudi.py | Python | gpl-3.0 | 8,152 | [
"DIRAC"
] | f45b75518b574b3fa10faf659d9c82d6872b0275cf2f3054530214addc256e26 |
# -*- coding: utf-8 -*-
from abc import ABC, abstractmethod
import argparse
from collections import defaultdict
import inspect
import logging
import progressbar
from typing import Any, DefaultDict, Dict, List, Set, Type
from catmaid.apps import get_system_user
from catmaid.control.annotationadmin import copy_annotati... | catmaid/CATMAID | django/applications/catmaid/management/commands/catmaid_import_data.py | Python | gpl-3.0 | 42,541 | [
"NEURON"
] | 186f8551cdc203bda78cb9a109bb16fcbae650b5926dc9ac48f45d3fa4196d4d |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
Low-level objects providing an abstraction for the objects involved in the calculation.
"""
import collections
import abc
import numpy as np
import pymatgen.core.units as units
from pprint import pformat
f... | montoyjh/pymatgen | pymatgen/io/abinit/abiobjects.py | Python | mit | 50,454 | [
"ABINIT",
"CRYSTAL",
"Gaussian",
"pymatgen"
] | e3d2f51fa44ebf8ede7a89535f725870577e29a1bf13ba413b4719c89a6161c0 |
#!/home/aubbwc/usr/bin/python3
import os,sys, shutil
import subprocess
from glob import glob
from time import time
starttime = time()
homedir = os.getcwd()
datafiles = os.path.join(homedir, 'datafiles')
infiles = os.path.join(datafiles, 'infiles')
slvzmats = os.path.join(datafiles, 'slvzmats')
cations = ['MMIM... | thebillywayne/research_utilities | boss/SinglePoints.py | Python | bsd-3-clause | 5,324 | [
"CHARMM"
] | 9aa2a0c906ccd30061fa28d7b94b3b27b664c6de06a10e922e1b1a3967564090 |
from setuptools import setup #, Extension
import os, os.path
import re
longDescription= ""
setup(name='flexgp',
version='1.',
description='Gaussian Process code with an emphasis on flexibility rather than speed',
author='Jo Bovy',
author_email='bovy@ias.edu',
license='New BSD',
lo... | jobovy/flexgp | setup.py | Python | bsd-3-clause | 602 | [
"Gaussian"
] | 4cd04d12248b2493b191380a4f08b46fbcc66d73e7765c96c20b66feb0451225 |
# Copyright (c) 2012, The Children's Hospital of Philadelphia
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification, are permitted provided that the
# following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this l... | chop-dbhi/django-dicom-models | dicom_models/core/models/data/encounter.py | Python | bsd-2-clause | 2,389 | [
"VisIt"
] | aabeefcb0807abfb04cc0dec8329eed6c5bd28993ed1cf152a1287b5d54debc4 |
from ase import *
from ase.utils.eos import *
configs = read('Ag.traj@0:5') # read 5 configurations
# Extract volumes and energies:
volumes = [ag.get_volume() for ag in configs]
energies = [ag.get_potential_energy() for ag in configs]
eos = EquationOfState(volumes, energies)
v0, e0, B = eos.fit()
print B / kJ * 1.0e24... | freephys/python_ase | doc/tutorials/eos/eos2.py | Python | gpl-3.0 | 351 | [
"ASE"
] | 25d259341585661280e8988e7de1cb77e8ad977d655db89ce3e388835e50acd4 |
"""Optimizer for inlining constant values."""
from __future__ import division
from __future__ import absolute_import
from __future__ import print_function
from __future__ import unicode_literals
import ast
from ..asttools import name as nametools
from ..asttools import visitor
from ..astwrappers import name as namew... | kevinconway/pycc | pycc/optimizers/constant.py | Python | apache-2.0 | 4,430 | [
"VisIt"
] | b8358255ecb326f2821c18651f3ee85f220cb84de36b0571800a5a6ac0ac5601 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
This file is part of web2py Web Framework (Copyrighted, 2007-2010).
Developed by Massimo Di Pierro <mdipierro@cs.depaul.edu>.
License: GPL v2
The widget is called from web2py.
"""
import sys
import cStringIO
import time
import thread
import re
import os
import stat
i... | henkelis/sonospy | web2py/gluon/widget.py | Python | gpl-3.0 | 27,199 | [
"VisIt"
] | aa401e804cb5282efb5fe5fd301f9cdd082f9a6c864698deff528c9a5da126ff |
""" The metapipe runtime.
author: Brian Schrader
since: 2015-01-13
"""
from time import sleep
from metapipe.models import JobTemplate
class Runtime(object):
def __init__(self, command_templates, queue_type, job_types,
job_type='local', sleep_time=1, max_jobs=10):
self.complete_jobs = []
... | Sonictherocketman/metapipe | metapipe/runtime.py | Python | mit | 1,263 | [
"Brian"
] | bdec747e1878e2caa21c87b5b87c3e380f01305acf52b7acc86dc52db168d321 |
"""I/O from symbolic expressions.
"""
from .symbolic import *
from .symbolic import _infix_operators,_prefix_operators,_builtin_functions
from ..io import loader
import json
from json import encoder
import weakref
import sys
import warnings
VAR_PREFIX = ''
USER_DATA_PREFIX = '$'
NAMED_EXPRESSION_TAG = '#'
NAMED_EXPRE... | krishauser/Klampt | Python/klampt/math/symbolic_io.py | Python | bsd-3-clause | 29,191 | [
"VisIt"
] | 685ae82abb7b164df1644cfc5bc842c4897cf258e3cf5c686015d0c7e3abe00a |
#!/usr/bin/env python
#
# This examples show how to use accessors to associate scalar data to mesh elements,
# and how to read and write those data from/to mesh files using ViennaGrid's readers
# and writers.
from __future__ import print_function
# In this example, we will illustrate how to read and write scalar dat... | jonancm/viennagrid-python | doc/examples/viennagrid/accessors.py | Python | mit | 4,168 | [
"VTK"
] | 1b508b639e17156ca01d3564cbd16d9ef8627b284b847b694db6846b4e85b89d |
# coding=utf8
from __future__ import absolute_import
import os
from sfepy import data_dir
import six
filename_meshes = ['/meshes/3d/cylinder.mesh',
'/meshes/3d/cylinder.vtk',
'/meshes/various_formats/small2d.mesh',
'/meshes/various_formats/small2d.vtk',
... | BubuLK/sfepy | tests/test_meshio.py | Python | bsd-3-clause | 14,310 | [
"VTK"
] | f398145fe97a308f88711415b41b1af0dc53034df03fd4f15d4cdaa91a1ba91b |
'''
Created on Aug 5, 2014
@author: gearsad
'''
import vtk
from SceneObject import SceneObject
from scene import Sphere
from scene import Cylinder
from user_update_t import user_update_t
from scene import MenuItem
from scene import MenuItemController
from scene import Hand
from math import sin
class User(SceneObject)... | GearsAD/semisorted_arnerve | arnerve/scene/User.py | Python | mit | 6,113 | [
"VTK"
] | 5b77221f740f5384befecc54edb5a2741f71d5d8574d351239c1330bc950a692 |
# Copyright (C) 2008 NSC Jyvaskyla
# Please see the accompanying LICENSE file for further information.
"""
ASE-calculator interface for HOTBIT.
(Hybrid Open-source Tight-Binding Tool)
"""
from __future__ import print_function
import os
import glob
import sys
import numpy as np
from .auxil import k_to_kappa_po... | pekkosk/hotbit | hotbit/aseinterface.py | Python | gpl-2.0 | 42,010 | [
"ASE",
"Gaussian"
] | dc6ec1177b77dc639a2c9b5b0a9443ebb58b5f45f8ce95378648569427d559b2 |
# -*- coding: UTF-8 -*-
"""
``Generic``
-----------------------
:Authors: Liron Levin
:Affiliation: Bioinformatics core facility
:Organization: National Institute of Biotechnology in the Negev, Ben Gurion University.
Short Description
~~~~~~~~~~~~~~~~~~~~~
A generic module that enables the user to design new module... | bioinfo-core-BGU/neatseq-flow_modules | neatseq_flow_modules/main_NSF_classes/Generic_module/30_12_2019_Generic.py | Python | gpl-3.0 | 46,584 | [
"BLAST"
] | 596a1842ba592d961b2e14b74c3fabaedcbf859103fdde32b7a92ec258a788a3 |
# Copyright (C) 2002, Thomas Hamelryck (thamelry@binf.ku.dk)
# This code is part of the Biopython distribution and governed by its
# license. Please see the LICENSE file that should have been included
# as part of this package.
import os.path
import Bio.PDB.mmCIF.MMCIFlex
from UserDict import UserDict
__doc__="Turn ... | dbmi-pitt/DIKB-Micropublication | scripts/mp-scripts/Bio/PDB/MMCIF2Dict.py | Python | apache-2.0 | 4,871 | [
"Biopython"
] | 6946cd9a78895b65ba9ae1a05f1a15bd1386acb87067599fe05d1630b43984e3 |
# Copyright 2015 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... | lucius-feng/yapf | yapf/yapflib/subtype_assigner.py | Python | apache-2.0 | 13,081 | [
"VisIt"
] | cfbb0eb415e39b325b08f55bedf99ad437c9a0e05d564cb034ed4cd82ed3880a |
# -*- coding: utf-8 -*-
"""
Created on Mon Feb 15 16:08:59 2016
@author: Radu
"""
from mpi4py import MPI
from neuron import h
pc = h.ParallelContext()
id = int(pc.id())
nhost = int(pc.nhost())
print "I am", id, "of", nhost | penguinscontrol/Spinal-Cord-Modeling | Python/testmpi.py | Python | gpl-2.0 | 224 | [
"NEURON"
] | 0e1943a192f307a2f0efb576f68a0c79e6654230f528896f2996b0f63c5a2f81 |
# mencoder "mf://mpg_288x288x24_lam15_t273_a0353140_0000_rv.dat_%d.png" -mf fps=20 -o anim.avi -ovc lavc -lavcopts vcodec=msmpeg4v2:vbitrate=500
import numpy
import sys
from mmdlab.datareader import get_parts_in_region
import pp
file_c = len(sys.argv[0])
all_nth = [];
ppservers = ()
job_server = pp.Server(ncpus = ... | detorto/mdvis | src/get_all_parts_in_reg.py | Python | mit | 1,026 | [
"Mayavi"
] | 49f542f5ea81f0bbfbba67c690c33b94626f4775d298b4dff7fec69bd3de19b1 |
# -*- coding: utf-8 -*-
#
#
# TheVirtualBrain-Scientific Package. This package holds all simulators, and
# analysers necessary to run brain-simulations. You can use it stand alone or
# in conjunction with TheVirtualBrain-Framework Package. See content of the
# documentation-folder for more details. See also http://www... | stuart-knock/tvb-library | tvb/simulator/models/stefanescu_jirsa.py | Python | gpl-2.0 | 29,130 | [
"Gaussian"
] | 3bbbbe8f17017f8b29335a80217c4437a393862629dcbadfce6d3678c28d4e61 |
import os, sys, re
from Bio import pairwise2
from Bio.Blast import NCBIXML
from Bio.SubsMat.MatrixInfo import blosum62
import gzip
import optparse
import subprocess
#-------------#
# Options #
#-------------#
def parse_options():
"""
This function parses the command line arguments and returns an optparse
... | asntech/jaspar | utils/motif_inferrer/motif_inferrer.py | Python | bsd-3-clause | 9,842 | [
"BLAST"
] | 2cbdde290d324c05b8a9cec6e8312715181cc4bca4a686f2e829f58ffba6186d |
"""
Keras implementation of word classifier
"""
import time
import os
import warnings
import numpy as np
import keras
from keras.layers.core import Dense, Activation, Dropout, Flatten, Reshape
from keras.layers.recurrent import LSTM
from keras.layers.convolutional import Conv2D
from keras.layers.normalization import Ba... | AlChiu/HandWriting-OCR-CNN-WebApp | NeuralNet/cnn_model_words.py | Python | mit | 2,666 | [
"NEURON"
] | afbb4a6a2db829f1e096c58589bd757bbf6ed47016d4f79c9cb03840dc06f5f8 |
import numpy as np
import scipy as scipy
import lxmls.classifiers.linear_classifier as lc
from lxmls.distributions.gaussian import *
class NaiveBayes(lc.LinearClassifier):
def __init__(self, xtype="gaussian"):
lc.LinearClassifier.__init__(self)
self.trained = False
self.xtype = xtype
... | LxMLS/lxmls-toolkit | lxmls/classifiers/naive_bayes.py | Python | mit | 2,890 | [
"Gaussian"
] | a271cd48841b256110ef69143413c549cb1c06698619fb61b6840c53a6042d31 |
"""
# Notes:
- This simulation seeks to emulate the CUBA benchmark simulations of (Brette
et al. 2007) using the Brian2 simulator for speed benchmark comparison to
DynaSim. However, this simulation does NOT include synapses, for better
comparison to Figure 5 of (Goodman and Brette, 2008).
- The time taken to si... | asoplata/dynasim-benchmark-brette-2007 | output/Brian2/brian2_benchmark_CUBA_nosyn_500/brian2_benchmark_CUBA_nosyn_500.py | Python | gpl-3.0 | 2,003 | [
"Brian"
] | e7dedce1a7d8cab00e4338f2814e0b39bc64a09c7cc7b2c946948f91e9c16d74 |
""" JobStateUpdateHandler is the implementation of the Job State updating
service in the DISET framework
The following methods are available in the Service interface
setJobStatus()
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import ti... | yujikato/DIRAC | src/DIRAC/WorkloadManagementSystem/Service/JobStateUpdateHandler.py | Python | gpl-3.0 | 16,976 | [
"DIRAC"
] | 6105d664fcd53e6b4d25150b3c182ed24ae16f1427304803c9a5158b488d17fd |
#!/usr/bin/env python
"""
Program to automatically print out CFS pager feeds.
Copyright 2010 - 2016 Michael Farrell <http://micolous.id.au/>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either ver... | Shaggs/cfsprinter | src/pagerprinter/pagerprinter.py | Python | gpl-3.0 | 5,171 | [
"ASE"
] | 1547de03fceeb884d97b815abbe085401c144fcb5e956ee5c9077b3033d0c361 |
"""
MOSEXTRACT
extract galaxy spectra from MOS image
"""
import os, sys, glob, shutil
import numpy as np
from astropy.io import fits
from scipy.ndimage.filters import median_filter
from PySpectrograph.Spectra import findobj, Spectrum
import pylab as pl
from extract import extract, write_extract
from calfunc imp... | crawfordsm/zSALT | zsalt/mosextract.py | Python | bsd-3-clause | 2,382 | [
"Galaxy"
] | 3598705e61bbe7c2c43531f3ff260e13a52251cc23c5101e31d24240368bee31 |
"""
Loadable subclass
"""
# This file is part of Munin.
# Munin is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
# Munin is distribut... | munin/munin | munin/mod/putships.py | Python | gpl-2.0 | 5,799 | [
"CRYSTAL"
] | f12c7294cdd36bf6b7e8225671f491b10ee88cb5f7d7b26117db3102dddde869 |
import ast
import inspect
from functools import wraps
import transpiler
from astpp import parseprint
def go(f):
@wraps(f)
def wrapper(*args, **kwargs):
source = inspect.getsource(f)
filename = inspect.getsourcefile(f)
print('==> source')
print(source.strip())
print()
... | jianyuan/py2go | py2go/__init__.py | Python | mit | 893 | [
"VisIt"
] | 0dbdd3e933848372ad5f9d62492cffb3ec9d45711e60f6fb8bcb18b3ce98e690 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
## GNU GENERAL PUBLIC LICENSE
## Version 2, June 1991
## Copyright (C) 1989, 1991 Free Software Foundation, Inc.
## 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
## Everyone is permitted to copy and distribute verbatim copies
... | CuonDeveloper/cuon | cuon_client/CUON/Cuon.py | Python | gpl-3.0 | 36,960 | [
"VTK"
] | 2cc83e6d9d89e65a3ca5614716dd1a2516c0c3e4817664b902b46a65beaefee0 |
# -*- coding: utf-8 -*-
from datetime import datetime, timedelta
from django.db.models import Q
import mock
import waffle
from nose import SkipTest
from nose.tools import eq_, raises
from taggit.models import Tag
import kitsune.sumo.models
from kitsune.flagit.models import FlaggedObject
from kitsune.karma.manager im... | dbbhattacharya/kitsune | kitsune/questions/tests/test_models.py | Python | bsd-3-clause | 20,867 | [
"VisIt"
] | 374209be1742b30b9f13e682ca08bd34f15f7fed1471e833241d2dff1f354172 |
#!/usr/bin/env python
# PYTHON_ARGCOMPLETE_OK
import os.path
import string
import sys
import time
import re
import argparse
import argcomplete
import json
from collections import OrderedDict
from sysexecute import *
from .banksync_common import *
__version__ = "0.9.8"
# ----------------------------------------------... | jasonfharris/banksync | banksync/banksync.py | Python | bsd-3-clause | 39,524 | [
"Octopus"
] | 5123a1bca87c66fc0d98360e172eb8a9d1d3327842ad3f945117c2a01a6c4358 |
#! /usr/bin/env python
import MDAnalysis
from MDAnalysis.analysis.leaflet import LeafletFinder
import numpy
from scipy import ndimage
from skimage import filter
import matplotlib.pyplot as plt
def render_image(image,colorMap,colorRange,ticks,filename):
plt.figure()
a=plt.imshow(image.transpose(), cmap=colorM... | philipwfowler/fd169-image-processing-example | detect-bilayer-phases.py | Python | mit | 6,774 | [
"Gaussian",
"MDAnalysis"
] | 41f50a5ed5842f0a99395a3f54d0feaed258021e80e4aab6b597616eece631c6 |
from __future__ import print_function, absolute_import, division
from future.builtins import *
from future import standard_library
standard_library.install_aliases()
# Copyright 2017 Autodesk Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with ... | Autodesk/molecular-design-toolkit | moldesign/fileio.py | Python | apache-2.0 | 16,197 | [
"Biopython",
"OpenMM"
] | 0cd71bbf88f24ebc302cd191e41bd3669139e17efabd63ae306625d97cb11f0f |
#!/usr/bin/env python
# Install.py tool to download, unpack, build, and link to the LATTE library
# used to automate the steps described in the README file in this dir
from __future__ import print_function
import sys,os,re,subprocess,hashlib
# help message
help = """
Syntax from src dir: make lib-latte args="-b"
... | yidongxiainl/lammps | lib/latte/Install.py | Python | gpl-2.0 | 6,017 | [
"LAMMPS"
] | 30ad54a2ea7491bae1bfcc9e45d0b966bac86d46dac0f23c10a2d9f666467e22 |
#
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2007-2008 Brian G. Matherly
# Copyright (C) 2008,2010 Gary Burton
# Copyright (C) 2008 Craig J. Anderson
# Copyright (C) 2009 Nick Hall
# Copyright (C) 2010 Jakim Friant
# Copyright (C) 2011 Adam Stein <adam@csh.rit.edu>
# Cop... | sam-m888/gramps | gramps/gui/plug/_guioptions.py | Python | gpl-2.0 | 76,163 | [
"Brian"
] | 616ee63c3b5fd516d6c3929e71810c4ac1edcd2d3afaf0e0ec05a1f4f86c4c53 |
"""
.. module:: services.py
:platform: Windows, Linux
:synopsis: Represents functions/classes used to control Feature Services,
Feature Service Layer, Map Service, etc...
.. moduleauthor:: Esri
"""
from __future__ import absolute_import
from __future__ import print_function
from __future__ import... | pLeBlanc93/ArcREST | src/arcrest/agol/services.py | Python | apache-2.0 | 121,046 | [
"VisIt"
] | 7a26ccde8fd284d2c0dde6b2d8e1021c88e60f0a99286539680af23bc02a1cf8 |
# Copyright (c) 2017-present, Facebook, Inc.
# All rights reserved.
# This source code is licensed under the BSD-style license found in the
# LICENSE file in the root directory of this source tree. An additional grant
# of patent rights can be found in the PATENTS file in the same directory.
from .agents import Teache... | calee88/ParlAI | parlai/core/dialog_teacher.py | Python | bsd-3-clause | 14,108 | [
"VisIt"
] | d59b2c26c0dbf916402118e608a86f7ff7e25922fd73f2ac3ba214e73e3cd7b1 |
# Version: 0.10
"""
The Versioneer
==============
* like a rocketeer, but for versions!
* https://github.com/warner/python-versioneer
* Brian Warner
* License: Public Domain
* Compatible With: python2.6, 2.7, and 3.2, 3.3
[](https://tr... | fastbot3d/Octoprint | versioneer.py | Python | agpl-3.0 | 41,886 | [
"Brian"
] | a3892f38b5216d3613f49698b960ea7cb746cd3d8ef682132b2e8e619ab7c4e4 |
"""
network.py
~~~~~~~~~~
A module to implement the stochastic gradient descent learning
algorithm for a feedforward neural network. Gradients are calculated
using backpropagation. Note that I have focused on making the code
simple, easily readable, and easily modifiable. It is not optimized,
and omits many... | bghughes/MNIST-neural-network | src/network.py | Python | mit | 6,229 | [
"Gaussian",
"NEURON"
] | 1cabbad20d2cc5e3350fa4d8bd2c693a9719116805114cea467ff0fbcac72159 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
## Description Visualize a SDFile as a web page
##
## Authors: Inés Martínez (mmartinez4@imim.es)
## Manuel Pastor (manuel.pastor@upf.edu)
##
## Copyright 2015 Manuel Pastor
##
## This file is part of PhiTools
##
##... | manuelpastor/phitools | phitools/viewSDF.py | Python | gpl-3.0 | 3,330 | [
"RDKit"
] | b960f31d80991051b22d61f0aae76683a1a45f8a6f5385c8c7fc481e457305a5 |
from dockerfile_parse import DockerfileParser
import requests
import sys
import os
import logging
import re
def send_comment(comment):
if 'GITHUB_STATUS_TOKEN' not in os.environ:
logging.info(str({
'comment': str(comment),
}))
return
logging.warn('Send comment: %s' % (str(co... | osallou/test1 | ci/jenkins_container_spec_check.py | Python | apache-2.0 | 6,957 | [
"Bioconda"
] | fb4e8c4797abe5097b1649644006f1b966188fd70660997efb91cf6d399d18c9 |
import unittest
from test import support
import sys
import random
import math
import array
# SHIFT should match the value in longintrepr.h for best testing.
SHIFT = sys.int_info.bits_per_digit
BASE = 2 ** SHIFT
MASK = BASE - 1
KARATSUBA_CUTOFF = 70 # from longobject.c
# Max number of base BASE digits to use in te... | brython-dev/brython | www/src/Lib/test/test_long.py | Python | bsd-3-clause | 55,133 | [
"Brian"
] | f4bf61d9c2c7e8c792c44608176f4b56acd328ff52229377fbe265637c34cecb |
import pylab as pyl
import cPickle as pickle
galaxies = pickle.load(open('galaxies.pickle','rb'))
galaxies = filter(lambda galaxy: galaxy.ston_I >10. and galaxy.Color_grad !=
None, galaxies)
arrow_right = [[0,0],[-1,1],[0,0],[-2,0],[0,0],[-1,-1],[0,0]]
f1 = pyl.figure(1, figsize=(6,4))
f1s1 = f1.add_subplot(... | boada/ICD | sandbox/lowerSN/plot_icd_colorgrad.py | Python | mit | 1,292 | [
"Galaxy"
] | 76730f7f8440c0673f2b5e861abc48b69690cbb515ef9f50ade1ad65a53fdaf4 |
# 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_log_mesh.py | Python | apache-2.0 | 5,998 | [
"GPAW",
"Gaussian",
"PySCF",
"SIESTA"
] | 10882e447c80365e040ffff09e4bb7dff1d3a5c384f5f6bb1e4d0395a5ddc858 |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
########################################################################
# Solves problem 66 from projectEuler.net.
# Finds the D whose Pell's equation minimal solution has the highest X.
# Copyright (C) 2010 Santiago Alessandri
#
# This program is free software:... | sanSS/programming-contests | project-euler/problem066.py | Python | gpl-3.0 | 2,470 | [
"VisIt"
] | 285d20d11a484e0ed605f0fe14684798b0ac5ef6d017ed883e222cfaca8d1276 |
########################################################################
# File : CPUNormalization.py
# Author : Ricardo Graciani
########################################################################
""" DIRAC Workload Management System Client module that encapsulates all the
methods necessary to handle CPU... | Andrew-McNab-UK/DIRAC | WorkloadManagementSystem/Client/CPUNormalization.py | Python | gpl-3.0 | 9,332 | [
"DIRAC"
] | d5939792d09093c46d182d2f71e0e37cf56e5ceb99ed4ca9c346dd7fb334181c |
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# --- BEGIN_HEADER ---
#
# fileman - File manager UI for browsing and manipulating files and folders
#
# Copyright (C) 2003-2009 The MiG Project lead by Brian Vinter
#
# This file is part of MiG.
#
# MiG is free software: you can redistribute it and/or modify
# it under the ... | heromod/migrid | mig/cgi-bin/fileman.py | Python | gpl-2.0 | 1,112 | [
"Brian"
] | b531ed87828130455706d54b0782aa1721eef9bf069e5a7094443ad16024326b |
import cv2
import numpy as np
def enhance_image(input_image):
# Read input image file
input_img = cv2.imread(input_image, cv2.IMREAD_COLOR)
# Apply open morphology to fill white dots in black characters
# https://docs.opencv.org/2.4/doc/tutorials/imgproc/opening_closing_hats/opening_closing_hats.html... | GreatDevelopers/MiniScripts | PythonScripts/RemoveRedColor/enhance_image.py | Python | gpl-3.0 | 1,804 | [
"Gaussian"
] | 0a7c7271aeb5089b36e4539a985ed6b4b4bfa17de85b50ceb66e2f58c95dc692 |
#generic python modules
import argparse
import operator
from operator import itemgetter
import sys, os, shutil
import os.path
##########################################################################################
# RETRIEVE USER INPUTS
###############################################################################... | jhelie/boltzmann_inversion | boltzmann_inversion.py | Python | gpl-2.0 | 10,297 | [
"Avogadro"
] | 550538b0574b4f0f23e19b2ab66bb144e243d42f8cece6d48c838e6d3dc890e9 |
# BEGIN_COPYRIGHT
#
# Copyright (C) 2014 CRS4.
#
# This file is part of hadoop-galaxy, released under the terms of the BSD
# 3-Clause License <http://opensource.org/licenses/BSD-3-Clause>.
#
# END_COPYRIGHT
import logging
import os
import subprocess
import sys
import urlparse
import pydoop
import pydoop.hdfs as phdfs... | crs4/hadoop-galaxy | hadoop_galaxy/utils.py | Python | bsd-3-clause | 4,680 | [
"Galaxy"
] | b7956eec3cfc65b9483d79e934dcd9b4e37c3abe6ace8098cb681b44c3c874e6 |
r"""
This module is a VTK Web server application.
The following command line illustrate how to use it::
$ vtkpython .../vtk_web_cone.py
Any VTK Web executable script come with a set of standard arguments that
can be overriden if need be::
--host localhost
Interfac... | timkrentz/SunTracker | IMU/VTK-6.2.0/Web/Applications/Cone/server/vtk_web_cone.py | Python | mit | 3,893 | [
"VTK"
] | 3627b9f43e7d3339d5c66c669c6c1bab5e5f5b762e8a59f66b24c4fd5935f411 |
# -*- coding: utf-8 -*-
# Author: github.com/madhavajay
"""
This is a test that answers the Udacity Quizzes for ud953
https://www.udacity.com/course/linear-algebra-refresher-course--ud953
"""
from decimal import Decimal, getcontext
from vector import Vector
from line import Line
from plane import Plane
from linsys impo... | madhavajay/ud953 | tests/udacity_test.py | Python | mit | 11,640 | [
"Gaussian"
] | 70c4b1f04ffca49dd183396bc007e66ee9dbaea16f56ae3622d2e1f0ce6c9cb9 |
import numpy as np
import glob
import sys,os
import gzip
def read_dump(FileName,Nfield,SnapShots,SaveSnap,gzipf=False,scaled=False):
"""read lammps dumpfile with header saved for specified file
number of atoms cannot change
format: id type x y z .....
"""
if gzipf == True:
File = gzip.open... | stefanb21487/AngleJulia | src/python/readdump.py | Python | gpl-3.0 | 3,193 | [
"LAMMPS"
] | 3a0643e52d0756504e126ea8950ee00c27e9ee16d005900a1e29c28c85fd7936 |
#
# Copyright 2019-2020 Johannes Hoermann (U. Freiburg)
#
# matscipy - Materials science with Python at the atomic-scale
# https://github.com/libAtoms/matscipy
#
# 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 Softw... | libAtoms/matscipy | examples/electrochemistry/pnp_batch/cell_1d/concentration_sweep/pnp_plot.py | Python | lgpl-2.1 | 7,314 | [
"Matscipy"
] | 8654c5f3e8e2d2174e119cf3be6082161de9bf7ca630441813e726fa52bc048e |
# -*- coding: utf-8 -*-
"""
A real simple app for using webapp2 with auth and session.
It just covers the basics. Creating a user, login, logout
and a decorator for protecting certain handlers.
Routes are setup in routes.py and added in main.py
"""
# standard library imports
import logging
import ran... | nortd/bomfu | boilerplate/handlers.py | Python | lgpl-3.0 | 65,168 | [
"VisIt"
] | 5ff843802693592232e0f300dab35df328a93903391b92d93e9c8585f0987c65 |
""" Compares several deseasonalization methods on pre-defined time-series from the Yahoo! dataset. """
import sys
sys.path.append('..')
import numpy as np
import matplotlib.pyplot as plt
from maxdiv import maxdiv_util, preproc
import datasets
def sample_gp(X, meany, sigma, n=1, noise=0.001):
""" sample a functi... | cvjena/libmaxdiv | experiments/deseasonalization.py | Python | lgpl-3.0 | 5,913 | [
"Gaussian"
] | 5a5a48636681dcd60abe1c7f64daad600593829294d4dbec9ef8c8010d799120 |
import six
import numpy as np
import xml.etree.ElementTree as ET
import xml
from xml.dom import minidom
import periodictable as pt
import subprocess
import os
import time
import re
import threading
try:
from little_helpers import convert_to_ordered
import solid_state_tools as sst
except ImportError:
from .l... | JannickWeisshaupt/OpenDFT | src/exciting_handler.py | Python | gpl-3.0 | 52,229 | [
"CRYSTAL",
"Mayavi",
"exciting"
] | 142d2a87b2032c8c6eb02a2e57fb8cb6222391507199a2b408807658d7d0711d |
##############################################################################
# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-64... | krafczyk/spack | var/spack/repos/builtin/packages/r-rots/package.py | Python | lgpl-2.1 | 1,787 | [
"Bioconductor"
] | 56e9dcfb72b8ba5ddf9abdbaec849e75d96b002b7bce2fec6cd01ef3275829fc |
from django.conf import settings
from django.conf.urls import include, url
from django.conf.urls.static import static
from django.contrib import admin
from django.views.generic import TemplateView
from django.views import defaults as default_views
urlpatterns = [
url(r'^$', TemplateView.as_view(template_name='pag... | IlyaTsiamchyk/ofeel_health | config/urls.py | Python | mit | 1,643 | [
"VisIt"
] | 3b4043241e79f7174b7f864837bfd2dc38142d050babd39dc4ced0b4639f0169 |
import math
import matplotlib.patches
import matplotlib.pyplot
import numpy.random
from matplotlib.path import Path
def calculate_angle(source, point):
x0, y0 = source
x1, y1 = point
dx = x1 - x0
dy = y1 - y0
angle = math.atan2(dy, dx)
return (angle, point)
def calculate_angles(source, points... | jeeyoungk/exercise | python/convexhull.py | Python | mit | 3,569 | [
"Gaussian"
] | 92afa665eef958d8935a54cf8d71c6b573e3fd78466496afbed4d3c4407eb463 |
'''
Created on Aug 3, 2011
@author: sean
'''
from __future__ import print_function
import unittest
import ast
from graphlab.meta.asttools.visitors.pysourcegen import SourceGen
from graphlab.meta.asttools.tests import AllTypesTested
from graphlab.meta.testing import py2only, py3only
tested = AllTypesTested()
def sim... | fmacias64/Dato-Core | src/unity/python/graphlab/meta/asttools/tests/test_sourcegen.py | Python | agpl-3.0 | 8,567 | [
"VisIt"
] | 71119ad5c1de81ff7e7bd623ce73d61b8da3b37c67f6e5a839712153317830c3 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.