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 |
|---|---|---|---|---|---|---|---|
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
import json
from datetime import timedelta
from django.core.cache import cache
from django.core.urlresolvers import reverse
from django.utils import timezone
from smartmin.tests import SmartminTest, _CRUDLTest
from temba.contacts.models import ContactFie... | Stanford-Legal-Tech-Design/legaltech-rapidpro | temba/msgs/tests.py | Python | agpl-3.0 | 65,125 | [
"VisIt"
] | cc0cd9444ee2b355fe80308a5e19749202382c2e75d909f270cbf0da28586936 |
"""
Python ICE-CASCADE combined glacial-fluvial-hillslope landscape evolution model
"""
import argparse
import numpy as np
import matplotlib.pyplot as plt
import netCDF4
import sys
import logging
from . import __version__ as py_ice_cascade_version
class main_model():
"""
Composite landscape evolution model. I... | keithfma/py_ice_cascade | py_ice_cascade/main.py | Python | mit | 7,006 | [
"NetCDF"
] | 07202598bc6ee5354aaacbdd4034978e4228462762d9358751add53ca70af8ca |
def straight_line_log_likelihood(theta, x, y, sigmay):
'''
Returns the log-likelihood of drawing data values *y* at
known values *x* given Gaussian measurement noise with standard
deviation with known *sigmay*, where the "true" y values are
*y_t = m * x + b*
x: list of x coordinates
y: list... | parejkoj/AstroHackWeek2015 | inference/straightline_log_likelihood.py | Python | gpl-2.0 | 604 | [
"Gaussian"
] | 88e1889f1dfc84546bdb81c4546f5503531198dd6402bd5042ae6eedff4b8c86 |
'''Drafts for vmd network files'''
#: Draft for the depiction of a single molecular orbital
mo_string= '''mol new %(n1)s type cube first 0 last -1 step 1 fidbonds 1 autobonds 1 waitfor all
mol delrep 0 top
mol representation CPK 1.000000 0.300000 100.000000 100.000000
mol color Name
mol selection {all}
mol material Op... | orbkit/orbkit | orbkit/output/vmd_network_draft.py | Python | lgpl-3.0 | 7,918 | [
"VMD"
] | 5c8697407077913d15c9c8fefb3038a3908e901be64b007c052b142b1c34be57 |
"""Utility functions for plotting M/EEG data
"""
from __future__ import print_function
# Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr>
# Denis Engemann <denis.engemann@gmail.com>
# Martin Luessi <mluessi@nmr.mgh.harvard.edu>
# Eric Larson <larson.eric.d@gmail.com>
# ... | cmoutard/mne-python | mne/viz/utils.py | Python | bsd-3-clause | 32,183 | [
"Mayavi"
] | 91889e000e93725880b61cf609529a030b15894548e58467520f5672fab85f08 |
# extract_fasta.py
# extracts a fasta alignment for a query sequence and its hits in a BLAST database
# TO RUN EXECUTE
# python extract_fasta.py [input_fasta] [DB]
from Bio.Blast.Applications import NcbiblastxCommandline
from Bio.Blast import NCBIXML
from Bio.SeqRecord import SeqRecord
from Bio import SeqIO
from Bio.S... | hsamleandro/Salmonella_pub | scripts/extract_fasta.py | Python | gpl-2.0 | 1,531 | [
"BLAST"
] | cefd0e83caafae7acbd18968f1862d58e5a583b20f30cb387e5bfdc5809c8b83 |
#
# Copyright (C) 2013,2014,2015,2016 The ESPResSo project
#
# This file is part of ESPResSo.
#
# ESPResSo is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option)... | KonradBreitsprecher/espresso | src/python/espressomd/checkpointing.py | Python | gpl-3.0 | 8,784 | [
"ESPResSo"
] | 4dcff7e51fc3ba8034b6a5ee5bede0f9af4b81b5af1fe0961f4be51445030dc6 |
"""setuptools.command.bdist_egg
Build .egg distributions"""
# This module should be kept compatible with Python 2.3
import sys, os, marshal
from setuptools import Command
from distutils.dir_util import remove_tree, mkpath
from distutils.sysconfig import get_python_version, get_python_lib
from distutils import log
fro... | stanbellcom/webapp_politik | sites/all/modules/annotator/lib/store-plugin/pyenv/lib/python2.7/site-packages/distribute-0.6.10-py2.7.egg/setuptools/command/bdist_egg.py | Python | gpl-2.0 | 17,993 | [
"VisIt"
] | c00d4995d9514898166b674b3c4d3a16e9c5db3513ade430dbca429a700792a1 |
#!/usr/bin/env python
# -*- coding: utf8 -*-
# *****************************************************************
# ** PTS -- Python Toolkit for working with SKIRT **
# ** © Astronomical Observatory, Ghent University **
# *****************************************************************
##... | Stargrazer82301/CAAPR | CAAPR/CAAPR_AstroMagic/PTS/pts/do/eagle/catalog.py | Python | mit | 2,338 | [
"Galaxy"
] | c4692e7a9d75208f2596077f6289e949b448bb08f51225808dd2e08a2f51306c |
''' EmailAction
This action writes all the necessary data to a cache file ( cache.db ) that
will be used later by the EmailAgent in order to send the emails for each site.
'''
__RCSID__ = '$Id$'
import os
import sqlite3
from DIRAC import S_ERROR, S_OK
from DIRAC.ResourceStatusSystem.PolicySystem.Actions.BaseAct... | arrabito/DIRAC | ResourceStatusSystem/PolicySystem/Actions/EmailAction.py | Python | gpl-3.0 | 3,534 | [
"DIRAC"
] | 97b1d1254acf47b9bfa8a61c427e438328f2f53825b384730560db595bb8afee |
"""
Authors: Tim Bedin
Copyright 2015 CSIRO, Australian Government Bureau of Meteorology
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 ... | CWSL/cwsl-mas | cwsl/vt_modules/json_extract.py | Python | apache-2.0 | 2,350 | [
"NetCDF"
] | 9f017329d587ecd4eed9a618c306cb6aaa1bb204ad7ae0ccc159988024e494b2 |
# ----------------------------------------------------------------------------
# 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.
# --------------------------------------------... | gregcaporaso/scikit-bio | skbio/stats/distance/tests/test_base.py | Python | bsd-3-clause | 41,977 | [
"scikit-bio"
] | 2379810f3bd729fcbc1060f9e6a752fc02de000f5cb5f713be9b67999818db35 |
# coding=utf8
#
# Copyright 2013 Dreamlab Onet.pl
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation;
# version 3.0.
# This library is distributed in the hope that it will be useful,
# bu... | tikan/rmock | src/rmock/runners/smtp/__init__.py | Python | lgpl-3.0 | 689 | [
"VisIt"
] | 36cc4bf0a5ee1cda59cd40d48cb0b0bcee17e0aa110c1f64908fe16bdea42b5e |
"""Approximate bilateral rank filter for local (custom kernel) mean.
The local histogram is computed using a sliding window similar to the method
described in [1]_.
The pixel neighborhood is defined by:
* the given structuring element
* an interval [g-s0, g+s1] in greylevel around g the processed pixel greylevel
Th... | paalge/scikit-image | skimage/filters/rank/bilateral.py | Python | bsd-3-clause | 7,626 | [
"Gaussian"
] | 84de2ab763c8fcc82abd89241a057bd709ed914504157d64e69a0163b3e76b6b |
from tp.netlib.objects import OrderDescs
from tp.client.objectutils import getResources
constraints = """player(int,unicode)
subtype(int,int)
name(int,unicode)
size(int,int)
pos(int,int,int,int)
vel(int,int,int,int)
contains(int,int)
universe(int)
galaxy(int)
star(int)
planet(int)
fleet(int)
wormhole(int)
start(int,in... | Null000/daneel-ai | daneel/basic.py | Python | gpl-2.0 | 3,301 | [
"Galaxy"
] | 6a79e556997e3539a06db9af8e8cc7dfb78cda23a846d1e5de35f0e0ae33e3bd |
import os
import time
import digitalocean
from digitalocean import Domain
import requests as rq
import paramiko
from paramiko.client import SSHClient
token = os.getenv("do_token")
domain_name = os.getenv("steamweb_domain")
manager = digitalocean.Manager(token=token)
keys = manager.get_all_sshkeys()
droplet = digita... | PiotrZakrzewski/steamweb | deployment/start_droplet.py | Python | mit | 2,255 | [
"GULP"
] | dd86a527111e527f9fcadc03f8338704e7235d0a9ca16d9f12820b5acd46568d |
#!/usr/bin/env python3
import configparser
import backend
import json
from flask import Flask
from flask_restful import Resource, Api, reqparse
config = configparser.ConfigParser()
config.read('config.ini')
print(config.sections())
recommender = backend.Recommender(config)
#first_places = recommender.get_places("Wh... | giocatori86/AdamGoodPlanner | bluemix/bluemix/__main__.py | Python | mit | 2,373 | [
"VisIt"
] | 69e272eb86ce3fa305a884b458e0fe0c9800897759dfbe78f8145c357138c36b |
# $HeadURL: $
""" StateMachine
This module contains the basic blocks to build a state machine ( State and
StateMachine ). And the RSS implementation of it, using its own states map.
"""
from DIRAC import S_OK, S_ERROR
__RCSID__ = '$Id: $'
class State( object ):
"""
State class that represents a single... | calancha/DIRAC | ResourceStatusSystem/PolicySystem/StateMachine.py | Python | gpl-3.0 | 9,409 | [
"DIRAC"
] | 2daa5fe8bdf6952cc15b9d1080d501a2643c7a885b2c2dfdc633c7325645d031 |
## numpy-oldnumeric calls replaced by custom script; 09/06/2016
## Automatically adapted for numpy-oldnumeric Mar 26, 2007 by alter_code1.py
##
## Biskit, a toolkit for the manipulation of macromolecular structures
## Copyright (C) 2004-2018 Raik Gruenberg & Johan Leckner
##
## This program is free software; you can r... | graik/biskit | archive_biskit2/Biskit/deprecated/WhatIf.py | Python | gpl-3.0 | 11,485 | [
"PyMOL"
] | ddd2a6685a84b5f4940e824852bda88d5677b38bf4182217ee254ca66596e203 |
# -*- coding: utf-8 -*-
#
# 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 "L... | sahilTakiar/spark | python/pyspark/ml/tests.py | Python | apache-2.0 | 118,862 | [
"Gaussian"
] | a11352b4a3fca5beb0e268ed972f9b171d1ca103de5057e34d365a9b60f35cc7 |
import os
import re
import sys
import os.path
import tempfile
import functools
import ase.db
from ase.db.table import Table, all_columns
from ase.visualize import view
from ase.io.png import write_png
from ase.db.summary import Summary
from flask import Flask, render_template, request, send_from_directory
app = Fla... | PHOTOX/fuase | ase/ase/db/app.py | Python | gpl-2.0 | 4,895 | [
"ASE"
] | e914b986c3723958b23ea1d19c79480f91c9c7a71573b86796df593e3546419e |
#!/usr/bin/env python
#
"""oocgcm.nemo.io
Define tools that help dealing with the creation of xarray objects from
NEMO netcdf files and creating NEMO-like netcdf files from xarray objects.
"""
from ...core.io import return_xarray_dataset as _return_xarray_dataset
from ...core.io import return_xarray_mfdataset as _ret... | lesommer/oocgcm | oocgcm/oceanmodels/nemo/io.py | Python | apache-2.0 | 1,902 | [
"NetCDF"
] | a81435130317603329434afefe362461dc91d86569409c8652bd3dc16aa7a683 |
"""
Main class of the phone loop model.
Copyright (C) 2017, Lucas Ondel
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 rights to use, copy, ... | iondel/amdtk | amdtk/models/phone_loop.py | Python | mit | 9,732 | [
"Gaussian"
] | 4c5e10776b7539adddf93fe9ee2848d7be70e6a2fa0bb695c82ae6660e55549d |
import logging
import time
import random
import urllib
import base64
import cgi
try:
from hashlib import md5
except:
from md5 import md5
from dirac.lib.base import *
from dirac.lib.credentials import getUserDN, getSelectedGroup, getSelectedSetup
from dirac.lib.webBase import defaultRedirect
from RESTDIRAC.RESTSy... | DIRACGrid/RESTDIRAC | Web/controllers/OAuth2.py | Python | gpl-3.0 | 5,209 | [
"DIRAC"
] | 9eb1f8247046604370d5fa766d932bac8c30dae562e4aeda289796f840ae42ec |
#!/usr/bin/env python3
# @Author: Tasdik Rahman
# @Date: 2016-04-19 12:29:20
# @Last Modified by: Tasdik Rahman
# @Last Modified time: 2016-04-19 14:03:33
# @MIT License
# @http://tasdikrahman.me
# @https://github.com/prodicus
import argparse
from subprocess import call
import glob
import shutil
import json
import... | BlitzKraft/xkcd-dl | xkcd_dl/cli.py | Python | mit | 10,394 | [
"VisIt"
] | 848caf4619b14e085bc62dfae33ee565ab38aa504db84bb4b2e4063f39d69ae4 |
# class generated by DeVIDE::createDeVIDEModuleFromVTKObject
from module_kits.vtk_kit.mixins import SimpleVTKClassModuleBase
import vtk
class vtkClipVolume(SimpleVTKClassModuleBase):
def __init__(self, module_manager):
SimpleVTKClassModuleBase.__init__(
self, module_manager,
vtk.vtk... | nagyistoce/devide | modules/vtk_basic/vtkClipVolume.py | Python | bsd-3-clause | 512 | [
"VTK"
] | c858d72e18b6b11950f5bcac13259e14acda27c4990da42e8ded59c42d1b9553 |
# Copyright 2017 Hugh Salimbeni
#
# 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, s... | ICL-SML/Doubly-Stochastic-DGP | doubly_stochastic_dgp/model_zoo.py | Python | apache-2.0 | 3,688 | [
"Gaussian"
] | e0a70275af18eae08dcb608909948e0354d0e2dd47473a26002189833b19f98d |
# sql/compiler.py
# Copyright (C) 2005-2016 the SQLAlchemy authors and contributors
# <see AUTHORS file>
#
# This module is part of SQLAlchemy and is released under
# the MIT License: http://www.opensource.org/licenses/mit-license.php
"""Base SQL and DDL compiler implementations.
Classes provided include:
:class:`.c... | bdupharm/sqlalchemy | lib/sqlalchemy/sql/compiler.py | Python | mit | 103,481 | [
"VisIt"
] | 7e07095d1c20aec4551075ab98971215f56596287c3b7ebaf8028d90e70a6011 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
################################################################################
#
# ChemPy - A chemistry toolkit for Python
#
# Copyright (c) 2010 by Joshua W. Allen (jwallen@mit.edu)
#
# Permission is hereby granted, free of charge, to any person obtaining a
# co... | jwallen/ChemPy | chempy/element.py | Python | mit | 10,783 | [
"ChemPy"
] | 1565d9cef0a61aa70d55462f7b9a69142143b9cb0be9a5a55a2124e22fae00e5 |
import os
import vtkAll as vtk
from ddapp import botpy
import math
import time
import numpy as np
from ddapp import transformUtils
from ddapp import lcmUtils
from ddapp.timercallback import TimerCallback
from ddapp import objectmodel as om
from ddapp import visualization as vis
from ddapp import applogic as app
from d... | rdeits/director | src/python/ddapp/handdriver.py | Python | bsd-3-clause | 6,730 | [
"VTK"
] | f959c1eab23a10e11277cca6546cfd2948d24d2e59d97ac2cbabb6f335cdfece |
""" Starting from the PDP object, it makes the full chain of policies
It requires
ResourceStatus
{
Policies
{
AlwaysActiveForResource
{
matchParams
{
element = Resource
}
policyType = AlwaysActive
}
AlwaysBanne... | ic-hep/DIRAC | tests/Integration/ResourceStatusSystem/Test_FullChain.py | Python | gpl-3.0 | 4,110 | [
"DIRAC"
] | 4554ff7667a93e838a1bf54286bcebc42afed3444283960825c43080cc267992 |
# -*- coding: utf-8 -*-
# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or... | googleapis/python-compute | tests/unit/gapic/compute_v1/test_firewall_policies.py | Python | apache-2.0 | 233,044 | [
"Octopus"
] | 186473f6dc934a18ae08f72eb90daba3668bd31f137478f7a5380fa6f31e361c |
#!/usr/bin/env
"""
SS_Winds_HovmellerIMG.py
Hovmoller diagram of wind speed vs time (as an imgsec plot)
GorePoint - 58deg 58min N, 150deg 56min W
and Globec3 59.273701N, 148.9653W
Files are created by GOA_Winds_NARR_model_prep.py
-Filtered NARR winds with a triangular filter (1/4, 1/2, 1/4) and outpu... | shaunwbell/FOCI_Analysis | ReanalysisRetreival_orig/SS_Winds/SS_Winds_HovmellerIMG.py | Python | mit | 5,992 | [
"NetCDF"
] | f96a50eabec68f3cf7943fc075d69933bd8fe34d01aa3c7e20577a3b66f77fda |
import pandas as pd
# Will also use the json library.
import json
import ujson
import uuid
import cPickle as pkl
import os
import time
# python-twitter library
# you can obtain this by using pip python-twitter
# documentation at https://pypi.python.org/pypi/python-twitter/
import twitter
# library that makes reque... | datacommunitydc/data_lake_api | database/Twitter_Meetup_Utility.py | Python | mit | 20,376 | [
"VisIt"
] | e22ba45cf703f6490c4580984bd7973553920ee0988c5a7dc62d44f56f1ea55d |
# ----------------------------------------------------------------------------
# cocos2d
# Copyright (c) 2008-2011 Daniel Moisset, Ricardo Quesada, Rayentray Tappa,
# Lucio Torre
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the... | eevee/cocos2d-mirror | cocos/particle_systems.py | Python | bsd-3-clause | 10,317 | [
"Galaxy"
] | 05893d18dabcd972af419e9826873efe7eeeb8838c117c09e03eb162ca29ce74 |
import re
import pytz
import datetime
from collections import defaultdict
import lxml.html
import scrapelib
from pupa.scrape import Scraper, Bill, VoteEvent
from .common import SESSION_TERMS, SESSION_SITE_IDS
motion_classifiers = {
'(Assembly|Senate)( substitute)? amendment': 'amendment',
'Report (passage|co... | cliftonmcintosh/openstates | openstates/wi/bills.py | Python | gpl-3.0 | 15,032 | [
"VisIt"
] | 8ea033cb9a5bddd90d59cc10301a09366614be2cc9d233b8fba576f7d84fa906 |
# standard modules
import re
import types
# third-party modules
import numpy as np
import pandas as pd
import pint
class Map(dict):
def __init__(self, *args, **kwargs):
super(Map, self).__init__(*args, **kwargs)
for arg in args:
if isinstance(arg, dict):
for k, v in arg.iteritems():
if isinstance(v,... | ferchault/iago | src/iago/utils.py | Python | mit | 8,042 | [
"Gromacs"
] | 24b96f93aea220fa6827e57656e5ffb8ecf70ad5d146e03a4be1d177a74a9e2e |
#!/usr/bin/env python
############################################################################
# Copyright (c) 2015 Saint Petersburg State University
# All Rights Reserved
# See file LICENSE for details.
############################################################################
import gzip
import logging
import... | dorbarker/INNUca | src/SPAdes-3.9.0-Linux/bin/truspades.py | Python | gpl-3.0 | 8,761 | [
"BWA"
] | 9ccfe8fb76b031e71c97d357bf9bd571db6f066e153a33019266cac4347b79b6 |
from eWUDAPT_analysis.utils import *
from pylab import *
from netCDF4 import Dataset, num2date
import datetime
import matplotlib.pyplot as plt
import matplotlib.dates as mdates
class analysis_single:
def __init__(self, args, json):
self.filename = args.filename
self.outputdir = args.outputdir
self.ncdf_... | eWUDAPT/eWUDAPT-analysis | eWUDAPT_analysis/analysis_single.py | Python | apache-2.0 | 5,899 | [
"NetCDF"
] | 9f88c7db37cf16a01cba71e493587ef3c33c416da62a23b20a120d3a5cc17b33 |
import re
from DIRAC import S_OK, S_ERROR
from DIRAC.Core.DISET.RPCClient import RPCClient
from DIRAC.Core.Utilities import DEncode, Time
class UserProfileClient:
def __init__( self, profile, rpcClientFunctor = False ):
if rpcClientFunctor:
self.rpcClientFunctor = rpcClientFunctor
else:
self.rp... | Andrew-McNab-UK/DIRAC | FrameworkSystem/Client/UserProfileClient.py | Python | gpl-3.0 | 4,566 | [
"DIRAC"
] | 19e5ebe08f2aeca065d4f129115f37e2500a314f74757fb9104d7d687cb65539 |
#
# @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 ... | andysim/psi4 | psi4/driver/qcdb/jajo.py | Python | gpl-2.0 | 18,053 | [
"Avogadro",
"CFOUR",
"Psi4"
] | 014de94082ebba7ecad0dfb9750ddad05ff4fb1afd3f5cc7bdba0a5f2612a069 |
from data_importers.management.commands import BaseXpressDemocracyClubCsvImporter
class Command(BaseXpressDemocracyClubCsvImporter):
council_id = "WLA"
addresses_name = "2021-04-20T12:09:13.316028/WLBC-Democracy_Club__06May2021.tsv"
stations_name = "2021-04-20T12:09:13.316028/WLBC-Democracy_Club__06May202... | DemocracyClub/UK-Polling-Stations | polling_stations/apps/data_importers/management/commands/import_west_lancashire.py | Python | bsd-3-clause | 2,452 | [
"Dalton"
] | 10f6069bbe0a48e37b7d918aecdc7a2e72f6fb1ce2c6fc4f989b71915505a585 |
import os
import stat
import re
import errno
from mercurial import (
dirstate,
match as matchmod,
osutil,
scmutil,
util,
)
try:
from mercurial import ignore
ignore.readpats
ignoremod = True
except (AttributeError, ImportError):
# ignore module was removed in Mercurial 3.5
ignor... | seewindcn/tortoisehg | src/ext/hggit/gitdirstate.py | Python | gpl-2.0 | 9,323 | [
"VisIt"
] | e4a4f5054af456994122bb9f6c1175c300c3c17e360e14ffac53bf8a62bb8067 |
#!/usr/bin/env python
from argparse import ArgumentParser
from numpy import logspace, array
from matplotlib.pyplot import show
from gridaurora.eFluxGen import maxwellian, fluxgen, writeh5
from gridaurora.plots import plotflux
import seaborn as sns
sns.set_context("paper", font_scale=1.75)
sns.set_style("whitegrid")
... | scienceopen/gridaurora | FluxGenerator.py | Python | gpl-3.0 | 1,746 | [
"Gaussian"
] | fcc69cc29ca8ec46c1d885c6d9882a23c40aabe2de1e5e25e2bdd118ff78098f |
"""
Artificial Intelligence for Humans
Volume 1: Fundamental Algorithms
Python Version
http://www.aifh.org
http://www.jeffheaton.com
Code repository:
https://github.com/jeffheaton/aifh
Copyright 2013 by Jeff Heaton
Licensed under the Apache License, Version 2.0 (the "License");
... | trenton3983/Artificial_Intelligence_for_Humans | vol1/python-examples/lib/aifh/rbf.py | Python | apache-2.0 | 2,775 | [
"VisIt"
] | 3840f52f95a58d3e68ae62e420b04f60eb8e1e988aa6fa8ba004dfaa6182375e |
# -*- coding: utf-8 -*-
# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or... | googleapis/python-org-policy | tests/unit/gapic/orgpolicy_v2/test_org_policy.py | Python | apache-2.0 | 112,030 | [
"Octopus"
] | 2402b2ed478b5bedf709e01bb1702f2fdee2c7ec39e21eac0b58e4d868fc0183 |
input_name = '../examples/diffusion/cube.py'
output_name = 'test_cube.vtk'
from tests_basic import TestInput
class Test( TestInput ):
pass
| RexFuzzle/sfepy | tests/test_input_cube.py | Python | bsd-3-clause | 144 | [
"VTK"
] | 2f2c278783239ead4d23cf2b92560f136c32fd0d3bee4cf9e00e75b95951e039 |
'''A file for debugging.'''
from src import APP
APP.secret_key = 'A0Zr98j/?adf)a&cNm%T'
APP.run(debug=False, port=1235)
| HoshinoTouko/ActivityRoomReservationSystem | run.py | Python | gpl-3.0 | 121 | [
"ADF"
] | cd29725822773ac3b6a6760d7fa8908b1b50f430b0094dfd7d0ad197f3a041ce |
# -*- 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 t... | alejob/mdanalysis | package/MDAnalysis/topology/TOPParser.py | Python | gpl-2.0 | 10,378 | [
"Amber",
"MDAnalysis"
] | e593f5604c6441723de9b2de1debfc17da69c036ec36cbe903166b6e63ac8ffa |
# $HeadURL $
''' ResourceStatusDB
Module that provides basic methods to access the ResourceStatusDB.
'''
from datetime import datetime
from DIRAC import S_OK, S_ERROR
from DIRAC.Core.Base.DB ... | calancha/DIRAC | ResourceStatusSystem/DB/ResourceStatusDB.py | Python | gpl-3.0 | 15,875 | [
"DIRAC"
] | 331f76d1329b8f7e684bbd7e5da7953ce802e570f25b990f0106ee3269eff57e |
# ----------------------------------------------------------------------------
# Copyright 2014 Nervana Systems Inc.
# 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.o... | DougFirErickson/neon | neon/layers/layer.py | Python | apache-2.0 | 61,041 | [
"Gaussian"
] | a6b6072aa8551dcc0914d2c8ba18605f3eac5927567b46d344398dd724f7ea3c |
#!/usr/bin/env python
#
# Copyright 2011-2013 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
# GNU Radio 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, or (at your opt... | Gabotero/GNURadioNext | gr-digital/python/qa_mpsk_snr_est.py | Python | gpl-3.0 | 4,170 | [
"Gaussian"
] | fe2f5c8a4b21a672de480375cce909c5ef30b51cf9ee45059d97bf6eed67d082 |
tests = [("python", "UnitTestUtils.py", {}), ]
longTests = []
if __name__ == '__main__':
import sys
from rdkit import TestRunner
failed, tests = TestRunner.RunScript('test_list.py', 0, 1)
sys.exit(len(failed))
| ptosco/rdkit | rdkit/utils/test_list.py | Python | bsd-3-clause | 220 | [
"RDKit"
] | f2774948f30d38693231e5c52c27c39ef7c5ac1f87348a40e2560b7eb5c4c9bc |
# vim: ft=python fileencoding=utf-8 sts=4 sw=4 et:
# Copyright 2016-2021 Florian Bruhin (The Compiler) <mail@qutebrowser.org>
#
# This file is part of qutebrowser.
#
# qutebrowser 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 S... | forkbong/qutebrowser | qutebrowser/browser/browsertab.py | Python | gpl-3.0 | 42,473 | [
"VisIt"
] | 204cd36d041e21195b36eeb67798da1c0a136ac3c2cb31bdabfcb686e7a15e22 |
# 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... | Huyuwei/tvm | python/tvm/relay/transform.py | Python | apache-2.0 | 30,198 | [
"VisIt"
] | a93d15170b3e2103117533cebcc0a485861659fef81f50931bcd643fc71dcbe1 |
# -*- coding: utf-8 -*-
#
# test_regression_issue-1034.py
#
# This file is part of NEST.
#
# Copyright (C) 2004 The NEST Initiative
#
# NEST is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 of ... | alberto-antonietti/nest-simulator | pynest/nest/tests/test_regression_issue-1034.py | Python | gpl-2.0 | 13,043 | [
"NEURON"
] | d584415a72a9f7e728464b3768b5ddf4eaf4e15acc537af73dd6db28e2c246c3 |
# Sample module in the public domain. Feel free to use this as a template
# for your modules (and you can remove this header and take complete credit
# and liability)
#
# Contact: Brian Carrier [carrier <at> sleuthkit [dot] org]
#
# This is free and unencumbered software released into the public domain.
#
# Anyone is f... | sleuthkit/autopsy | pythonExamples/fileIngestModule.py | Python | apache-2.0 | 8,379 | [
"Brian"
] | 5359b561035453ef7b64c9e0fd7c3d064f8f29ab2fbae915cd2c7d9728afaf11 |
#!/usr/bin/env python
# Licensed to Pioneers in Engineering under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. Pioneers in Engineering licenses
# this file to you under the Apache License, Version 2.0 (the
#... | tobinsarah/tenshi | tools/typpo_c_generator.py | Python | apache-2.0 | 17,086 | [
"VisIt"
] | 224e8a39e4cfe9e9352611825649b48fd73d5014b943d11453265c594d7f0803 |
#!/usr/bin/python
#FILE DESCRIPTION=======================================================
#~ Python script used for foam case construction (as automatic, as
#~ possible)
#~
#~ NOTES:
#~ - mesh grading in z direction
#~ USAGE:
#~ - modify and run the script
#~ TO DO:
#LICENSE=======================... | MartinIsoz/CFD_oF | 03_texturedPlate/01_longTexture/00_Scripts/caseConstructorV3.py | Python | gpl-2.0 | 25,409 | [
"ParaView"
] | beb134a7dd889c18eb3c85b3a7b0c67118e4bb6fe9ecc19d71fe0de2ef9b43fd |
"""
ConnectionField and associated classes.
This module defines some basic classes of objects used to create
simulations of cortical sheets that take input through connection
fields that project from other cortical sheets (or laterally from
themselves).
ConnectionField: Holds a single connection field within a
CFProj... | ioam/svn-history | topo/base/cf.py | Python | bsd-3-clause | 42,334 | [
"NEURON"
] | b222eb9de0ecc70870a8f9a08361c15d9f4bd25a18028c8aa10f064e2e0af182 |
"""
This Module is the graphic user interface wrapper for accessing the all small molecules database
Things to do,
1. clean up print statments
2. config files
3. comments
4. dependencies. reduce code blob.
5. more dynamic plotting options like add, remove specific molecule
6. add spectra analysis tools like area un... | azariven/BioSig_SEAS | SEAS_Aux/Visualizer/Small_Molecules_Gui.py | Python | gpl-3.0 | 20,066 | [
"RDKit"
] | 20c0c4e4d0ee14983fc7059579c3565749de05ce54f8f462b31d6950a2f4052f |
import numpy as np
import math
from mpl_toolkits.mplot3d.art3d import Poly3DCollection
from geometry_cpp import intersects_scene, intersect_ray_scene, Ray, intersect_ray_fakerect, rotate_3d
def plotP(ax, p, marker='.', color=None):
"""Plot point"""
ax.plot([p[0]], [p[1]], marker=marker, zs=[p[2]], color=color)... | dario-wat/raycaster-stereo-generator | src/geometry.py | Python | gpl-3.0 | 3,917 | [
"Gaussian"
] | f24342fb08170dda0f6830290a5877f3eb7a43530ced17f5e13bd8aeb5cf4282 |
###############################
# 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/decorations/test_generator.py | Python | gpl-3.0 | 2,107 | [
"CRYSTAL",
"VASP"
] | 8a818f27654ea1638c138007745bb21c62a36d38596831d9dc6a6a1c17c98ea4 |
import re
import pytest
import urllib
import datetime
from redwind.models import User
from testutil import FakeResponse, assert_urls_match
from werkzeug.datastructures import MultiDict
def test_empty_db(client):
"""Make sure there are no articles when the database is empty"""
rv = client.get('/')
assert ... | thedod/redwind | tests/views_test.py | Python | bsd-2-clause | 8,182 | [
"Firefly"
] | 45a91b1981bda9048b2a80a626cb87c6cb374e3d4fd0118529bb542aae76fb53 |
#
# Copyright 2016 The BigDL Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in ... | intel-analytics/BigDL | python/orca/src/bigdl/orca/tfpark/text/keras/intent_extraction.py | Python | apache-2.0 | 3,695 | [
"ORCA"
] | 68adfabc1df514976f3aa20c8cb97d4f743a942f8cefddb352776136246ab0ad |
# -*- coding: utf-8 -*-
#
# ftp_ecmwf_download.py
# spt_compute
#
# Created by Alan D. Snow.
# License: BSD-3 Clause
from __future__ import unicode_literals
from calendar import isleap
import datetime
from dateutil.parser import parse
from glob import glob
from io import open
from netCDF4 import Dataset
import num... | erdc-cm/spt_ecmwf_autorapid_process | spt_compute/imports/streamflow_assimilation.py | Python | bsd-3-clause | 24,310 | [
"NetCDF"
] | 3d21ec2101e02d1307350e6984d44c433211009d4cdc08d01dbac9b85a43960e |
from __future__ import print_function, division
import copy, pickle, re, os, time, subprocess, datetime, itertools, sys, abc, argparse, matplotlib, glob
matplotlib.use('agg')
sys.path.append('/home/kengyangyao/Dropbox/temp_Linux/temp_research_proj/cluster_management/cm/src')
sys.path.append('/home/kengyangyao/Dropbox/t... | weiHelloWorld/accelerated_sampling_with_autoencoder | MD_simulation_on_alanine_dipeptide/current_work/src/config.py | Python | mit | 12,463 | [
"MDAnalysis",
"OpenMM"
] | 1edb194cc4dfe86f021cda74ce8fea45da19c0e544d2c1527645a210af015d04 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
import random
import datetime as dt
import pytest
from marshmallow import Schema, fields, utils, MarshalResult, UnmarshalResult
from marshmallow.exceptions import MarshallingError, UnmarshallingError, ValidationError
from marshmallow.compat import unicode, Or... | 0xDCA/marshmallow | tests/test_schema.py | Python | mit | 65,226 | [
"Brian"
] | 4987962d32a207b34d086333b26545a0c3a284ac1f5107f091e768eb24622c52 |
from __future__ import absolute_import, print_function
import logging
logger = logging.getLogger(__file__)
from json import loads
from six import iteritems
from .properties import Any, HasProps, List, MetaHasProps, String
from .query import find
from .util.callback_manager import CallbackManager
from .util.future i... | htygithub/bokeh | bokeh/model.py | Python | bsd-3-clause | 13,736 | [
"VisIt"
] | ef8ddaa244d2a7db49dc98e74eeef50bd038ef5c1471e1eb56543ba22dd52d81 |
"""test_table_streaming_support.py:
Test the streaming support in moose.Table.
"""
__author__ = "Dilawar Singh"
__copyright__ = "Copyright 2016, Dilawar Singh"
__credits__ = ["NCBS Bangalore"]
__license__ = "GNU GPL"
__version__ = "1.0.0"
__maintainer__ = "Dilaw... | subhacom/moose-core | tests/python/test_table_streaming_support.py | Python | gpl-3.0 | 2,187 | [
"MOOSE"
] | 0d8a2d93d5b083e7c82b4a525f3860aeb7cfa862bdd1b32640bd7ee4baba307e |
from astropy.io import fits
import numpy as n
import glob
import os
import sys
vv = sys.argv[1]
#plates = n.array(os.listdir("/home/comparat/SDSS/26/stellarpop"))
top_dir = "/data36s/comparat/SDSS/"+vv
cat_dir = top_dir+"/catalogs"
cat_file = cat_dir+'/FireFly.fits'
#cat_file = cat_dir+'/FireFly_672.fits'
mag_file... | JohanComparat/pySU | spm/bin_SMF/summary_table_merge_firefly_MAG.py | Python | cc0-1.0 | 746 | [
"Firefly"
] | cd783beb04b86cfd96fccd7120ea29cd33190ebd539ffc86d0c51347d95263d7 |
#!/usr/bin/python
# File created on 27 Jan 2012.
from __future__ import division
__author__ = "Kishori M Konwar"
__copyright__ = "Copyright 2013, MetaPathways"
__credits__ = ["r"]
__version__ = "1.0"
__maintainer__ = "Kishori M Konwar"
__status__ = "Release"
try:
from os import makedirs, sys, remove, rename
... | kishori82/MetaPathways_Python.3.0 | libs/python_scripts/MetaPathways_parse_blast.py | Python | mit | 23,491 | [
"BLAST"
] | 7fb7c5560be25ca8b426d60a48ad6927f44cf2b1ad8daf7bf01736ce0dd62440 |
#!/usr/bin/env python
"""
Combine shape objects to create a composite object
"""
from __future__ import print_function
import argparse
import time
import sys
import re
from icqsol.shapes.icqShapeManager import ShapeManager
from icqsol import util
# time stamp
tid = re.sub(r'\.', '', str(time.time()))
parser = argp... | gregvonkuster/icqsol | examples/composeShapes.py | Python | mit | 2,153 | [
"VTK"
] | 61c1d7e6f22881b411d5996c444a40a5e71f0629dca5829cac2796314c028a90 |
import numpy as np
def rx1(z_w,rmask):
"""
function rx1 = rx1(z_w,rmask)
This function computes the bathymetry slope from a SCRUM NetCDF file.
On Input:
z_w layer depth.
rmask Land/Sea masking at RHO-points.
On Output:
rx1 Haney stiffness ratios.
... | dcherian/pyroms | pyroms_toolbox/pyroms_toolbox/rx1.py | Python | bsd-3-clause | 1,773 | [
"NetCDF"
] | 515b7f7b3cf05665d48b4ffef707042b868b2be9bd3ca56001acdab9b42e497b |
import numpy as np
from scipy import ndimage
from scipy import stats
from skimage.color import rgb2grey
from skimage.util import img_as_float, pad
from skimage.feature import peak_local_max
def _compute_derivatives(image):
"""Compute derivatives in x and y direction using the Sobel operator.
Parameters
-... | almarklein/scikit-image | skimage/feature/corner.py | Python | bsd-3-clause | 16,451 | [
"Gaussian"
] | 05670e2bbaf747b0017f31796ad2bedb6727bf7aadfad1fcc9b18e45edf9b349 |
#!/usr/bin/env python
""" This template will become the job wrapper that's actually executed.
The JobWrapperTemplate is completed and invoked by the jobAgent and uses functionalities from JobWrapper module.
It has to be an executable.
The JobWrapperTemplate will reschedule the job according to certain cri... | DIRACGrid/DIRAC | src/DIRAC/WorkloadManagementSystem/JobWrapper/JobWrapperTemplate.py | Python | gpl-3.0 | 11,200 | [
"DIRAC"
] | 6b72a45b1df0462d6e7ab2e913ea11c79c5e0a361eba2bfb40d63e36762eebb9 |
# -*- coding: utf-8 -*-
#!/usr/bin/env python
#
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2000-2007 Donald N. Allingham
# Copyright (C) 2007 Johan Gonqvist <johan.gronqvist@gmail.com>
# Copyright (C) 2007-2009 Gary Burton <gary.burton@zen.co.uk>
# Copyright (C) 2007-2009 Stephane Charet... | sam-m888/gramps | gramps/plugins/webreport/contact.py | Python | gpl-2.0 | 5,657 | [
"Brian"
] | 52c65d742279d702bbaa12657b7bbbd706891180d73047323c57dde2f0dff72c |
from __future__ import division, print_function, absolute_import
import numpy as np
import math
import warnings
# trapz is a public function for scipy.integrate,
# even though it's actually a numpy function.
from numpy import trapz
from scipy.special.orthogonal import p_roots
from scipy.special import gammaln
from sc... | sriki18/scipy | scipy/integrate/quadrature.py | Python | bsd-3-clause | 28,092 | [
"Gaussian"
] | 626e026bc92d8c34d30686a68d731d88f9226dda0b653b04bd846373e30dfd72 |
import numpy as np, SimPEG as simpeg, vtk
import vtk.util.numpy_support as npsup
import io
# Calculate normals for polygons
def normFilter(vtkPoly):
'''
Calcluates normals and makes the ordering of the cells consistent (positive outwards).
'''
polyNormFilter = vtk.vtkPolyDataNormals()
polyNormFilte... | grosenkj/telluricpy | telluricpy/vtkTools/polydata.py | Python | mit | 10,543 | [
"VTK"
] | 073485db2b84462230e3bdfe09eaf8ed123d2dc0c8c501190613e23367cbaed1 |
import re, htmlentitydefs
import urllib2
import string
import traceback
try:
import simplejson as json
except ImportError:
import json
from unidecode import unidecode
from piebot import settings
class Bitly(object):
"""Checks incoming messages for possible urls. If a url is found then
visit the site... | billyvg/piebot | piebot/modules/urlparser/bitly.py | Python | mit | 4,437 | [
"VisIt"
] | 7c47e01027a2e2d3fd4474e88028896817c6b9736423bfc95bc8652fb60a3323 |
import os
import json
import tempfile
import shutil
from django.core.files.uploadedfile import UploadedFile
from django.test import TestCase, RequestFactory
from django.contrib.auth.models import Group
from django.core.urlresolvers import reverse
from rest_framework import status
from hs_core import hydroshare
from ... | ResearchSoftwareInstitute/MyHPOM | hs_file_types/tests/test_view_functions.py | Python | bsd-3-clause | 57,040 | [
"NetCDF"
] | 656a6f5455f95a570b2e9854a06ac479ed5fc00d0e5aed858f5ee9e3dcbf724b |
# -*- coding: utf-8 -*-
"""
Created on Thu Apr 27 17:28:47 2017
@author: Ian
"""
import math
def thetas():
#//int numThetas = 10; // guess
#//double[] cosTheta = new double[numThetas];
#// Try equal distribution in cos(theta) space (rather than Gaussian quadrature)
""" /*
double i... | sevenian3/ChromaStarPy | Thetas.py | Python | mit | 7,586 | [
"Gaussian"
] | 55fad60d5a8d669aa872eccc7150e293e419d7f392d1e4de0909fbc4f844b399 |
"""Different kinds of laser pulses.
"""
import sys
import time
from math import log
import numpy as np
from ase.units import Bohr, Hartree
import gpaw.io
from gpaw.tddft.units import attosec_to_autime, autime_to_attosec, \
eV_to_aufrequency, aufrequency_to_eV
###########################... | qsnake/gpaw | gpaw/tddft/laser.py | Python | gpl-3.0 | 1,177 | [
"ASE",
"GPAW"
] | 3b4753cca0eb70320a855aff7800f1e7f5acb300459ee43d5ebc51c19304e0a5 |
import numpy as np
import pandas as pd
import scipy as sp
import pickle
from scipy import fft
from time import localtime, strftime
import matplotlib.pyplot as plt
from skimage.feature import match_template
import wave
###########################
# Folder Name Setting
###########################
folder = 'J:/DATAMIN... | jonathanwoodard/MLSP_2013 | 2a_data_preparation.py | Python | mit | 7,184 | [
"Gaussian"
] | c4def0e7b3677a441993b1b30731aa19356741fe1308fc6bce5bb6ce717ae7c6 |
"""
To implement Monte Carlo Tree Search, we'll define a new kind of FunctionNode that stores the weights for each rule
that could be applied to each of its args
"""
from math import log, exp, sqrt
from copy import copy
from collections import defaultdict
from LOTlib.Miscellaneous import Infinity, lambdaAssertFalse,... | ebigelow/LOTlib | LOTlib/Inference/MCTS/LOTHypothesisState.py | Python | gpl-3.0 | 7,038 | [
"VisIt"
] | 3f1faca97683adb9f06c23e4a898009680136738e7112fb40a5c28a4995c4219 |
# !/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Filename: MPL11.py
# Project: dap
# Author: Brian Cherinka
# Created: Friday, 26th February 2021 9:23:41 am
# License: BSD 3-clause "New" or "Revised" License
# Copyright (c) 2021 Brian Cherinka
# Last Modified: Friday, 26th February 2021 9:23:42 am
# Modified By: Bria... | sdss/marvin | python/marvin/utils/datamodel/dap/MPL11.py | Python | bsd-3-clause | 1,935 | [
"Brian"
] | bb853fe0e0d359d179ccef99bb6fd7a827305125e0f0c2fb8e17fb231183c91d |
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module provides a class to predict and analyze interfacial reactions between two
solids, with or without an open element (e.g., flowing O2).
Please consider citing one or both of the following papers if you use this
... | vorwerkc/pymatgen | pymatgen/analysis/interface_reactions.py | Python | mit | 29,183 | [
"pymatgen"
] | de0c1f6af43ed5843eb3c392861157aae1f70799993e2225de29f0037f8bd3b6 |
#!/usr/bin/env python
from __future__ import print_function
from dark.blast import BlastRecords
from dark.blast.records import printBlastRecordForDerek
if __name__ == '__main__':
import sys
if len(sys.argv) < 2:
print('Usage: %s hitfiles...' % sys.argv[0], file=sys.stderr)
else:
blastReco... | acorg/dark-matter | bin/print-blast-xml-for-derek.py | Python | mit | 519 | [
"BLAST"
] | 8e005cde710dfdda673848c27097e87bba7ced0d8e168ea9d191d5690e5bfb32 |
########################################################################
# $HeadURL$
# File : CSCLI.py
# Author : Adria Casajus
########################################################################
__RCSID__ = "$Id$"
import cmd
import sys
import signal
import types
import atexit
import os
import readline
from DI... | calancha/DIRAC | ConfigurationSystem/Client/CSCLI.py | Python | gpl-3.0 | 18,345 | [
"DIRAC"
] | 5a711a84ba1a33559037bbeb7b614f242fad7057ea689fa8e1a1f5e74f8d1937 |
"""
Change directory to provide relative paths for doctests
>>> import os
>>> filepath = os.path.dirname( os.path.realpath( __file__ ) )
>>> datadir = os.path.realpath(os.path.join(filepath, '../../testing/data'))
>>> os.chdir(datadir)
"""
from nipype.interfaces.base import (CommandLineInputSpec, C... | dmordom/nipype | nipype/interfaces/camino/dti.py | Python | bsd-3-clause | 41,922 | [
"DIRAC",
"Gaussian"
] | b6d145a193fa39a28da09268a44bd8457d19836ac56a5479149a071f99480548 |
# @MUNTJAC_COPYRIGHT@
# @MUNTJAC_LICENSE@
"""Defines a class that can figure out mime-types and icons related to
files."""
from os.path import isdir
from muntjac.terminal.theme_resource import ThemeResource
class FileTypeResolver(object):
"""Utility class that can figure out mime-types and icons related to fil... | rwl/muntjac | muntjac/service/file_type_resolver.py | Python | apache-2.0 | 16,153 | [
"NetCDF"
] | 2684798720b5d73d795f1a81a50cb40a2bd83def3764daa3001f300a3e2907ef |
# -*- coding: utf-8 -*-
"""
Created on Mon Apr 06 10:43:23 2015
Functions for analyzing thermodynamic output of lammps simulations
@author: Samuel
"""
import numpy
from scipy.optimize import curve_fit
import matplotlib.pyplot as plt
import os
import sys
def Poly10(x,a,b,c,d,e,f,h,g,i,k):
return a*x**10 + b*x**9 + c*... | sipjca/cmlparser_py | outputs/plot/pStressStrain.py | Python | apache-2.0 | 2,729 | [
"LAMMPS"
] | 5d8f0bbb5d09bf002972f13e391a69dda16303078d515893005fafa3b36f8ac0 |
# 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 ... | GirlsCodePy/girlscode-coursebuilder | modules/analytics/clustering.py | Python | gpl-3.0 | 47,660 | [
"VisIt"
] | b4c8dcf3f050b71988f6f8bbbbe1fbdc64efbbc84cd4c7b79f7abb862b46deb2 |
#
# Copyright 2001 - 2016 Ludek Smid [http://www.ospace.net/]
#
# This file is part of Outer Space.
#
# Outer Space is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (... | ospaceteam/outerspace | client/osci/dialog/GalaxyFinishDlg.py | Python | gpl-2.0 | 3,346 | [
"Galaxy"
] | 1a22f828bcf99f9cb0efe73bcf4356671b60fa4eae4cf98431df6038e51a7a43 |
import tornado.web
from base import BaseHandler, require_membership
from models import Conversation, Notification, Comment, Sharedfile
class IndexHandler(BaseHandler):
@tornado.web.authenticated
@require_membership
def get(self, show_only=None, page=None):
current_user_object = self.get_current_us... | MLTSHP/mltshp | handlers/conversations.py | Python | mpl-2.0 | 3,560 | [
"VisIt"
] | b053c6dc3013406db17888aa50efe663dcb6162ab68886c4bce9913bc92f825c |
# coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
import unittest
from pathlib import Path
from pymatgen.io.cp2k.outputs import Cp2kOutput
from pymatgen.util.testing import PymatgenTest
class SetTest(PymatgenTest):
def setUp(self):
self.TEST_FIL... | gmatteo/pymatgen | pymatgen/io/cp2k/tests/test_outputs.py | Python | mit | 881 | [
"CP2K",
"pymatgen"
] | 51c2e049a42d0eef7f49b739e4fd325ac088ded3231611c43c8f56c34a263d1b |
""" The TokenManagerClient is a class representing the client of the DIRAC
:py:mod:`TokenManager <DIRAC.FrameworkSystem.Service.TokenManagerHandler>` service.
"""
from DIRAC import S_OK, S_ERROR
from DIRAC.Core.Utilities import ThreadSafe
from DIRAC.Core.Utilities.DictCache import DictCache
from DIRAC.Core.Base.Client ... | DIRACGrid/DIRAC | src/DIRAC/FrameworkSystem/Client/TokenManagerClient.py | Python | gpl-3.0 | 3,645 | [
"DIRAC"
] | b74e7f08e2842e59a1a40ad1cfb324d5a4811297906716dbedf1dcf4ca839964 |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('backend', '0004_auto_20160221_1905'),
]
operations = [
migrations.AlterField(
model_name='automatedmessage',
... | I-TECH-UW/mwachx | backend/migrations/0005_auto_20160419_1803.py | Python | apache-2.0 | 684 | [
"VisIt"
] | 89581d67c70f552ff0f1c9cd6e9b3fe9a8461cf6b00e734414649f9e615d2bec |
from __future__ import division, print_function
import logging
import numpy
import theano
from theano import tensor
from blocks.bricks.base import application, lazy
from blocks.roles import add_role, WEIGHT, BIAS
from blocks.bricks import Random, Initializable, Linear
from blocks.utils import shared_floatx_zeros
... | dribnet/draw | draw/prob_layers.py | Python | mit | 8,754 | [
"Gaussian"
] | 9e1688a60967e9c2c6cd95d9cf3e2a9e63bcac3e2d03279ced8e886e9de68e1d |
#!/usr/bin/env python3
import itertools
from collections import defaultdict
import logging
from operator import mul
import networkx as nx
import numpy as np
import pandas as pd
from pgmpy.base import DirectedGraph
from pgmpy.factors.discrete import TabularCPD, JointProbabilityDistribution, DiscreteFactor
from pgmpy.... | dungvtdev/upsbayescpm | pgmpy/models/BayesianModel.py | Python | mit | 28,998 | [
"VisIt"
] | 5713499b488a6e70f52544cd3e4cc291f067776d23d175fb3ff69b6d9fe8be5b |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.