src
stringlengths
721
1.04M
from .channelgroup import * from .alert import * from ..util import sanitize from ..plugins import loadPlugin import logging import traceback class Server: def __init__(self, name, config): self._name = name self._driver = loadPlugin("drivers", config.get("driver"), config.get("config", {})) self._monitors = co...
""" Tests for imageio's freeimage plugin """ import os import sys import numpy as np from pytest import raises, skip from imageio.testing import run_tests_if_main, get_test_dir, need_internet import imageio from imageio import core from imageio.core import get_remote_file, IS_PYPY test_dir = get_test_dir() # Cre...
# Written by Eric Martin for COMP9021 import tkinter as tk import tkinter.messagebox class KMeansClustering(tk.Tk): def __init__(self): tk.Tk.__init__(self) self.title('k-means clustering') menubar = tk.Menu() help_menu = tk.Menu(menubar) menubar.add_cascade(label = 'k-me...
# -*- coding: UTF-8 -*- """ Task related commands. @author: Aurélien Gâteau <aurelien.gateau@free.fr> @author: Sébastien Renard <sebastien.renard@digitalfox.org> @license: GPL v3 or later """ import os import readline import re from datetime import datetime, timedelta from dateutil import rrule from sqlobject import L...
# FRAMEWORK # Barry Beagen, David Moses, Trygve Wastvedt, Robert White # Python script written by Trygve Wastvedt # 7/31/2015 import Rhino import scriptcontext as sc import rhinoscriptsyntax as rs # Import related files from post import * from pocket import * from joint import * from structure import * from toolpath ...
import json from django.core.urlresolvers import reverse from CTFmanager.tests.views.base import ViewTestCase class EventPageAJAXJoinEventTest(ViewTestCase): """ Tests that a user can join an event A user should be able to join upcoming events. And get a response without the page reloading """ ...
# -*- coding: utf-8 -*- from operator import attrgetter from pyangbind.lib.yangtypes import RestrictedPrecisionDecimalType from pyangbind.lib.yangtypes import RestrictedClassType from pyangbind.lib.yangtypes import TypedListType from pyangbind.lib.yangtypes import YANGBool from pyangbind.lib.yangtypes import YANGListTy...
import csv import datetime from decimal import Decimal import json import operator try: from urlparse import urlparse except ImportError: from urllib.parse import urlparse import sys from peewee import * from playhouse.db_url import connect from playhouse.migrate import migrate from playhouse.migrate import Sc...
# -*-coding:Utf-8 -* # Copyright (c) 2010 LE GOFF Vincent # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright notice, this # l...
import re from collections import OrderedDict from django.urls import reverse, resolve, NoReverseMatch from django.conf import settings from django.http import HttpResponseRedirect from ct.models import Course, CourseUnit, UnitLesson, Response from ctms.urls import urlpatterns as ctms_urls from .views import CourseCou...
# -*- coding: utf-8 -*- """ direct PAS Python Application Services ---------------------------------------------------------------------------- (C) direct Netware Group - All rights reserved https://www.direct-netware.de/redirect?pas;upnp The following license agreement remains valid unless any additions or changes a...
from collections import OrderedDict import ast from asttools import is_load_name, graph_walk class GatherGrapher: def __init__(self, code, **kwargs): self.gather_check = kwargs.pop('gather_check', is_load_name) self.gather_nodes = {} if isinstance(code, str): code = ast.parse(...
""" Python tests for the Survey models """ from collections import OrderedDict import ddt from django.contrib.auth.models import User from django.core.exceptions import ValidationError from django.test import TestCase from django.test.client import Client from survey.exceptions import SurveyFormNameAlreadyExists, Su...
# -*- coding: utf-8 -*- # # Poio Tools for Linguists # # Copyright (C) 2009-2013 Poio Project # Author: António Lopes <alopes@cidles.eu> # URL: <http://media.cidles.eu/poio/> # For license information, see LICENSE.TXT """ This document contain the responsible methods to write and parse the GrAF files. The p...
# -*- coding: utf-8 -*- #+---------------------------------------------------------------------------+ #| 01001110 01100101 01110100 01111010 01101111 01100010 | #| | #| Netzob : Inferring communication protocol...
from __future__ import absolute_import import torch.nn.functional as F import torch.nn.init as init from torch import nn from torchvision.models import resnet18, resnet34, resnet50, resnet101, \ resnet152 class ResNet_btfu(nn.Module): __factory = { 18: resnet18, 34: resnet34, 50: resne...
import logging import multiprocessing import os import logging from edalize.edatool import Edatool logger = logging.getLogger(__name__) CONFIG_MK_TEMPLATE = """#Auto generated by Edalize TOP_MODULE := {top_module} VC_FILE := {vc_file} VERILATOR_OPTIONS := {verilator_options} MAKE_OPTIONS := {m...
## Singly Linked List ## Each Node is relatively Head to the next node it refers to. ## The Linked List can be broken down into: ## Nodes. """ Single Linked List can: - Insert at Head, Tail, Inbetween - Delete at Head, Tail, Inbetween - Add another LinkedList to Existing """ class LinkedNode(object): ...
__author__ = 'Michael Andrew michael@hazardmedia.co.nz' class Config(object): """ Config class """ sound_path = 'assets/sounds' #path from src folder to sound assets point_of_origin_code = 0 #index of the point of origin address_data_file_path = "data/addresses.xml" #path from src folder to data file...
# Copyright (c) 2007 Mitchell N. Charity # Copyright (c) 2009-2012 Walter Bender # Copyright (c) 2012 Flavio Danesse # Copyright (c) 2013 Aneesh Dogra <lionaneesh@gmail.com> # # This file is part of Ruler. # # Ruler is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public L...
# 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...
# -*- coding: utf-8 -*- # Natural Language Toolkit: An Incremental Earley Chart Parser # # Copyright (C) 2001-2010 NLTK Project # Author: Peter Ljunglöf <peter.ljunglof@heatherleaf.se> # Rob Speer <rspeer@mit.edu> # Edward Loper <edloper@gradient.cis.upenn.edu> # Steven Bird <sb@csse.unimelb.edu...
# Copyright (C) 2014-2016 Andrey Antukh <niwi@niwi.nz> # Copyright (C) 2014-2016 Jesús Espino <jespinog@gmail.com> # Copyright (C) 2014-2016 David Barragán <bameda@dbarragan.com> # Copyright (C) 2014-2016 Alejandro Alonso <alejandro.alonso@kaleidos.net> # This program is free software: you can redistribute it and/or mo...
# -*- coding: utf-8 -*- from enum import Enum class Card(object): class Type(Enum): NUMBER = "card_number" JACK = "card_jack" QUEEN = "card_queen" KING = "card_king" ACE = "card_ace" symbols = ["♥", "♦", "♣", "♠"] value_str = ["2", "3", "4", "5", "6", "7", "8", "9...
""" Django settings for tobook project. Generated by 'django-admin startproject' using Django 1.11.3. For more information on this file, see https://docs.djangoproject.com/en/1.11/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.11/ref/settings/ """ import os ...
#!/usr/bin/python2 ''' Created on 18th July 2015 @author: Andrew Dean Motion Notify v1.0 - uploads images and video to Google Drive and sends notification via email. Detects whether someone is home by checking the local network for an IP address or MAC address and only sends email if nobody is home. Allows hours to b...
#! /usr/bin/env python import os import numpy as np from astrometry.util.fits import fits_table from common import run_calibs, DecamImage, Decals if __name__ == '__main__': import optparse parser = optparse.OptionParser() parser.add_option('--force', action='store_true', default=False, ...
# # # Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Google Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later...
import sys import os import inspect from PyQt5 import QtWidgets, QtCore, QtGui import plugnplay from uptime import boottime from TardisUtil import TardisOptions, TimeSubmitter class TardisDiff(QtWidgets.QMainWindow): def __init__(self): super(TardisDiff, self).__init__() self.difference = 0 ...
import unittest import sys import json import stackimpact from stackimpact.utils import timestamp from test_server import TestServer class MessageQueueTest(unittest.TestCase): def test_flush(self): server = TestServer(5005) server.start() stackimpact._agent = None agent = sta...
#!/usr/bin/python # # Copyright 2014 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 b...
#!/usr/bin/env python from numpy import * import os as os from scikits import audiolab from scipy import signal import sys def writeaudio(data, filename='test_in.wav'): audiolab.wavwrite(data, filename, 48000, 'float32') def readaudio(): return audiolab.wavread("test_out.wav")[0] def compareaudio(data1, d...
#!/usr/bin/env python # vim:fileencoding=UTF-8:ts=4:sw=4:sta:et:sts=4:ai from __future__ import (unicode_literals, division, absolute_import, print_function) __license__ = 'GPL v3' __copyright__ = '2012, Kovid Goyal <kovid@kovidgoyal.net>' __docformat__ = 'restructuredtext en' import json c...
# This file is part of the Juju GUI, which lets users view and manage Juju # environments within a graphical interface (https://launchpad.net/juju-gui). # Copyright (C) 2013 Canonical Ltd. # # This program is free software: you can redistribute it and/or modify it under # the terms of the GNU Affero General Public Lice...
#!/usr/bin/env python ############################################################################ # # Copyright (C) 2004-2005 Trolltech AS. All rights reserved. # # This file is part of the example classes of the Qt Toolkit. # # This file may be used under the terms of the GNU General Public # License version 2.0...
# -*- coding: utf-8 -*- # Copyright 2016 LasLabs Inc. # License GPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html). import mock from . import wizard_test_setup NEXT_SALE = 'odoo.addons.sale_medical_prescription.wizards.' \ 'medical_sale_wizard.MedicalSaleWizard._get_next_sale_wizard' class TestMed...
from test.support import run_unittest, open_urlresource import unittest import sys import os from unicodedata import normalize, unidata_version TESTDATAFILE = "NormalizationTest.txt" TESTDATAURL = "http://www.unicode.org/Public/" + unidata_version + "/ucd/" + TESTDATAFILE if os.path.exists(TESTDATAFILE): f = ope...
from typing import Sequence import logging import pytz import random import string import itertools from datetime import date, datetime from decimal import Decimal from django.db import models log = logging.getLogger(__name__) SEASON_START_MONTH = 4 SEASON_END_MONTH = 10 class CouponType(models.Model): id = mo...
# Copyright (c) 2016 Mirantis 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.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, so...
""" A Plex Media Server agent for using album art as artist posters """ import os import re import hashlib import unicodedata import mutagen # Settings lifted from localmedia agent IMAGE_EXTS = ['jpg', 'png', 'jpeg', 'tbn'] ART_EXTS = ['jpg', 'jpeg', 'png', 'tbn'] POSTER_FILES = ['poster', 'default', 'cover', 'movie'...
""" TimeFrameResults steals methods from oemof.outputlib adapted to the structure applied here. Most relevant difference is results data stored in self.data """ from oemof.outputlib import DataFramePlot, ResultsDataFrame import pickle from matplotlib import pyplot as plt import logging import pandas as pd class Ti...
#!python #OnlineAgesy/views.py from django.shortcuts import render, redirect, get_object_or_404 from django.contrib.auth.decorators import login_required from .forms import * @login_required(login_url="login/") def home(request): return render(request, "static_pages/home.html") #--------------------Clients Views--...
from numpy import zeros from gwlfe.Memoization import memoize try: from InitSnow_f_inner_compiled import InitSnow_f_inner except ImportError: print("Unable to import compiled InitSnow_inner, using slower version") from gwlfe.Input.WaterBudget.InitSnow_inner import InitSnow_f_inner def InitSnow(NYrs, Day...
# Copyright 2013 OpenStack Foundation # # 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...
# encoding: UTF-8 import re class Processor(object): """An abstract base class that defines the protocol for Processor objects. """ def __init__(self, iterable): """Given an iterable of objects, become an iterable of other objects. The two sets of objects need not be the same type. ...
import pygame import json import src.config as config from src.user_data import UserData class Game(object): def __init__(self, fps): self.done = False self.fps = fps self.clock = pygame.time.Clock() def run(self, scene): """Our main function call. inits pygame, starts our f...
# -*- coding: utf-8 -*- # Generated by Django 1.9 on 2017-02-28 07:12 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('decomposition', '0011_auto_20170221_1013'), ] operati...
import cinesync import sys, os from optparse import OptionParser class EventHandler: def __init__(self, argv=sys.argv, stdin=sys.stdin): try: self.session = cinesync.Session.load(stdin) except Exception: self.session = None parser = OptionParser() parser.a...
#!/usr/bin/env python import unittest import os.path import sys sys.path.insert(0, os.path.join(os.path.abspath(os.path.dirname(__file__)), "..")) import base from enki.core.core import core import enki.core.core import enki.core.defines class RestoreOldConfigs(base.TestCase): def setUp(self): base.T...
import sys import jinja2 from flask import Flask, render_template from flask_restful import Api from functools import lru_cache from wutu.util import * from wutu.compiler.common import create_base, create_stream, get_data class CustomFlask(Flask): """ Enchanted Flask module """ jinja_options = Flask....
from __future__ import (absolute_import, division, print_function, unicode_literals) import re from .. import Draft color_map = { 'A': (92, 140, 168), # azure / light blue 'G': (0, 104, 24), # green 'B': (44, 44, 128), # blue 'K': (0, 0, 0), # black 'W': (224, 224, 22...
#coding: iso-8859-1 ## Copyright 2003-2005 Luc Saffre ## This file is part of the Lino project. ## Lino 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 opti...
# Copyright (c) 2014-present PlatformIO <contact@platformio.org> # # 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 appli...
from app import db from createDB import Person, Chore from random import randint from interactDB import rotate, multiSelect from datetime import date def createPairs(): rotate() multiSelect() def seed(): if(len(Person.query.all())!=0): return #start the seeding people = [ Person("Mike Dillon", "Mik...
from math import exp from mxnet import gluon from mxnet import autograd from mxnet import nd from mxnet import image from mxnet.gluon import nn import mxnet as mx import numpy as np from time import time import matplotlib.pyplot as plt import matplotlib as mpl import random import pdb class DataLoader(object): """...
from ctypes import * from vcx.common import do_call, create_cb from vcx.api.connection import Connection from vcx.api.vcx_stateful import VcxStateful import json class IssuerCredential(VcxStateful): """ The object of the VCX API representing an Issuer side in the credential issuance process. Assumes that ...
# -*- coding: utf-8 -*- # This file is part of Shuup. # # Copyright (c) 2012-2019, Shoop Commerce Ltd. All rights reserved. # # This source code is licensed under the OSL-3.0 license found in the # LICENSE file in the root directory of this source tree. import re import pytest from bs4 import BeautifulSoup from djang...
#!/usr/bin/python3 """ logging.py: Log file setup helper functions """ # Import Required Libraries (Standard, Third Party, Local) ******************** import logging import logging.handlers import os import sys # Authorship Info ************************************************************* __author__ = "Christopher ...
"""This file defines the Board class.""" import pygame from src.Component import Component from src.Point import Point class Board(Component): """This class defines the board (a.k.a. map).""" def __init__(self, scenario): """Create the board.""" self.step = scenario.get_board_step() ...
#coding=utf-8 """ ------------------------------------------------------------------------------- Name: getsvrlog.py Purpose: Collect ArcGIS Server Site Logs Author: Sean.L (luwl@esrichina.com.cn) Created: 8/25/16 Copyright: (c) Sean.L 2016 ---------------------------------------------------------...
# 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...
""" REST API Documentation for the NRS TFRS Credit Trading Application The Transportation Fuels Reporting System is being designed to streamline compliance reporting for transportation fuel suppliers in accordance with the Renewable & Low Carbon Fuel Requirements Regulation. OpenAPI spec version: v1 ...
from flask import render_template, redirect, url_for, abort, flash, request,\ current_app from flask.ext.login import login_required, current_user from . import main from .forms import EditProfileForm, EditProfileAdminForm, PostForm from .. import db from ..models import Permission, Role, User, Post from ..decorato...
# Copyright 2018 Google 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.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing,...
#!/usr/bin/env python3 # Copyright (c) 2016-2019 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test the SegWit changeover logic.""" from decimal import Decimal from io import BytesIO from test_fra...
#!/usr/bin/env python import json import subprocess import sys oldf = sys.argv[1] newf = sys.argv[2] immutable_keys = ('property', 'input', 'expected') # Use jq to flatten the test data, and parse it old = json.loads(subprocess.run([f"jq -r '[.. | objects | select(.uuid != null)]' {oldf}"], stdout=subprocess.PIPE,...
# Code in this file is adapted from: # https://github.com/openai/evolution-strategies-starter. import gym import numpy as np import tree # pip install dm_tree import ray from ray.rllib.models import ModelCatalog from ray.rllib.policy.policy_template import build_policy_class from ray.rllib.policy.sample_batch import...
#coding=utf-8 import os import os.path import shutil import sys import getopt import string import fnmatch import md5 import hashlib import zipfile import time import threading import struct from pprint import pprint from struct import * projectdir = os.path.dirname(os.path.realpath(__file__)) compileBin = os.pa...
from unittesting import DeferrableTestCase from SublimeLinter.lint.linter import LintMatch class TestLooseLintMatch(DeferrableTestCase): def test_attribute_access(self): m = object() match = { "match": m, "line": 1, "col": 2, "error": "error_txt", ...
#!/usr/bin/env python # -*- coding: utf-8 -*- ''' Copyright (C) 2011-2014 German Aerospace Center DLR (Deutsches Zentrum fuer Luft- und Raumfahrt e.V.), Institute of System Dynamics and Control All rights reserved. This file is part of PySimulator. PySimulator is free software: you can redistribute it and/or modify...
from django.db import connections import multidb from celery import group import olympia.core.logger from olympia.amo import VALID_ADDON_STATUSES from olympia.amo.utils import chunked from .tasks import update_user_ratings_task task_log = olympia.core.logger.getLogger('z.task') def update_user_ratings(): """...
# -*- coding: utf-8 -*- pylint: disable-msg=R0801 # # Copyright (c) 2013 Rodolphe Quiédeville <rodolphe@quiedeville.org> # # 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...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2011 OpenStack LLC. # 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/...
import zstackwoodpecker.test_state as ts_header import os TestAction = ts_header.TestAction def path(): return dict(initial_formation="template5", checking_point=8, path_list=[ [TestAction.create_vm, 'vm1', 'flag=sblk'], [TestAction.create_volume, 'volume1', 'flag=ceph,scsi'], [TestAction.attach_volume, 'vm1...
# -*- coding: utf-8 -*- from operator import attrgetter from pyangbind.lib.yangtypes import RestrictedPrecisionDecimalType from pyangbind.lib.yangtypes import RestrictedClassType from pyangbind.lib.yangtypes import TypedListType from pyangbind.lib.yangtypes import YANGBool from pyangbind.lib.yangtypes import YANGListTy...
""" The AbstractApplication class will define all operations for application interaction. It is a singleton class, so calling cross3d.Application() will always return the same instance of Application. One of its main functions is connecting application callbacks to cross3d.Dispatch. The AbstractApplication is a QOb...
"creatures.py - Pyro creatures" from util import * import items import dungeons import astar class Bite(items.MeleeAttackType): name = "bite" verbs = lang.verbs_bite # no damage, hit, crit verbs_sp = lang.verbs_bite_2p damage = "1d4" class Claw(items.MeleeAttackType): name = "claw" ve...
from __future__ import absolute_import from __future__ import print_function import os, shutil, sys from sysconfig import get_path from glob import glob from pkgutil import get_loader from subprocess import call def get_library_location(package): # get abs path of a package in the library, rather than locally ...
""" Test fo http scheduler: """ from __future__ import print_function import asyncore from helpers import tempesta, deproxy, tf_cfg, chains from testers import functional class HttpRules(functional.FunctionalTest): """All requests must be forwarded to the right server groups according to sched_http_rules. ...
from __future__ import absolute_import import unittest from collections import namedtuple from mock import patch from simpleflow.swf.process.worker.base import ActivityPoller, ActivityWorker from swf.models import ActivityTask, Domain from tests.moto_compat import mock_swf FakeActivityType = namedtuple("FakeActivit...
from ambition_prn.constants import AZT_3TC_with_ATZ_r_or_Lopinavir_r from ambition_prn.constants import AZT_3TC_with_EFV_NVP_or_DTG from ambition_prn.constants import TDF_3TC_FTC_with_ATZ_r_or_Lopinavir_r from ambition_prn.constants import TDF_3TC_FTC_with_EFV_or_NVP from ambition_validators import HEADACHE, VISUAL_LOS...
# Written by John Hoffman, George Milescu # see LICENSE.txt for license information import sys from random import randint from urlparse import urlparse from httplib import HTTPConnection import urllib import time from threading import Thread,currentThread,Lock from traceback import print_exc, print_stack from collecti...
# httpclient.py # -*- coding: utf-8 -*- # Copyright (c) 2016 Fondazione Ugo Bordoni. # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any ...
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the Li...
# zetup.py # # Zimmermann's Python package setup. # # Copyright (C) 2014-2016 Stefan Zimmermann <zimmermann.code@gmail.com> # # zetup.py 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, either version 3 ...
"""Support for Nexia / Trane XL Thermostats.""" import asyncio from datetime import timedelta from functools import partial import logging from nexia.home import NexiaHome from requests.exceptions import ConnectTimeout, HTTPError import voluptuous as vol from homeassistant.config_entries import SOURCE_IMPORT, ConfigE...
################################################################################ # Copyright 2020-2021 Advanced Micro Devices, Inc. All rights reserved. # # 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 t...
# Mantid Repository : https://github.com/mantidproject/mantid # # Copyright &copy; 2018 ISIS Rutherford Appleton Laboratory UKRI, # NScD Oak Ridge National Laboratory, European Spallation Source # & Institut Laue - Langevin # SPDX - License - Identifier: GPL - 3.0 + from __future__ import (absolute_import, div...
import functools import logging import unittest from unittest import mock import pytest from socketio import base_manager from socketio import pubsub_manager class TestPubSubManager(unittest.TestCase): def setUp(self): id = 0 def generate_id(): nonlocal id id += 1 ...
from __future__ import division import sys # XXX how early a version can we get away with using the built-in module? if (sys.version_info[1] >= 7) : import subprocess else : try: from libtbx import subprocess_with_fixes as subprocess except ImportError: try : import subprocess_with_fixes as subproce...
#!python3 """ Predict protein pKa based on MCCE method. http://pka.engr.ccny.cuny.edu/ Require MCCE 3.0 to work: https://anaconda.org/SalahSalah/mcce/files """ import asyncio import glob import gzip import locale import logging import math import os import re import shutil import subprocess import sys...
# vim: ft=python fileencoding=utf-8 sts=4 sw=4 et: # Copyright 2014-2020 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...
# -*- coding: utf-8 -*- # Mathmaker Lib offers lualatex-printable mathematical objects. # Copyright 2006-2017 Nicolas Hainaux <nh.techn@gmail.com> # This file is part of Mathmaker Lib. # Mathmaker Lib is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as pu...
# -*- coding: utf-8 -*- # <nbformat>3.0</nbformat> # <markdowncell> # # Bipedal SLIP # # # ## LE: # May 5th, 2013 MM - forked from "Walking SLIP" notebook # May 16th, 2013 MM - bughunting: comparison between "wrapped" (circular-invariant) and "original" model gives slightly different results - this must not be ...
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
#!/usr/bin/env python3 # Copyright (c) 2018 The PIVX developers # Copyright (c) 2018 The Syndicate Ltd developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test RPC commands for BIP38 encrypting and decrypting addresses.""...
#!/usr/bin/env python3 # Copyright (c) 2014-2016 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. # # Test resurrection of mined transactions when # the blockchain is re-organized. # from test_framework...
# -*- coding: utf-8 -*- # Generated by Django 1.11.5 on 2017-11-10 00:12 from __future__ import unicode_literals from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ migrations.swappable_depende...
#------------------------------------------------------------------------------ # Copyright (C) 2009 Richard Lincoln # # This program is free software; you can redistribute it and/or modify it under # the terms of the GNU Affero General Public License as published by the Free # Software Foundation; version 2 dated June...
import pathlib from typing import Optional # NOQA MODULE_PATH = pathlib.Path(__file__).absolute().parent INTERNAL_CONSOLE_UI_PATH = MODULE_PATH / 'vendor' / 'swagger-ui' class ConnexionOptions(object): def __init__(self, options=None): self._options = {} if options: self._options.upd...