gt
stringclasses
1 value
context
stringlengths
2.49k
119k
from abc import ABCMeta from util.reflection import deriving from util.functions import unique_id import special import attributes # pylint: disable=W0231 class Node(deriving('eq', 'show')): __metaclass__ = ABCMeta def __init__(self): self._attrs = attributes.Attributes() self._unique_name...
from test import support import time import unittest import locale import sysconfig import sys import warnings class TimeTestCase(unittest.TestCase): def setUp(self): self.t = time.time() def test_data_attributes(self): time.altzone time.daylight time.timezone time.tzn...
from __future__ import absolute_import import re import json import unittest from io import BytesIO from six.moves import cPickle as pickle import lxml.etree from scrapy.item import Item, Field from scrapy.utils.python import to_unicode from scrapy.exporters import ( BaseItemExporter, PprintItemExporter, PickleIt...
# # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not us...
# -*- coding: utf-8 -*- import pytest from sqlalchemy.orm import session from skosprovider.uri import UriPatternGenerator from skosprovider_sqlalchemy.models import Initialiser from skosprovider_sqlalchemy.providers import ( SQLAlchemyProvider ) from tests import DBTestCase from tests.conftest import create_dat...
#!/usr/bin/env python3 # Copyright 2020 Google LLC # # Licensed under the the Apache License v2.0 with LLVM Exceptions (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://llvm.org/LICENSE.txt # # Unless required by applicable law ...
from .testutils import FullStackTests import time import os from pywb.utils.loaders import load as load_test from webrecorder.models import User, Collection, Recording from webrecorder.models.base import BaseAccess from mock import patch from itertools import count load_counter = 0 # ==============================...
#!/usr/bin/env python # # Root command that delegates to all GreatFET subcommands. # This file is part of GreatFET. from __future__ import print_function import difflib import errno import sys import os # The prefix which all greatfet-subcommands start with. GREATFET_PREFIX = 'greatfet_' def looks_like_valid_great...
# -*- coding: utf-8 -*- import os from copy import deepcopy from functools import partial from functools import update_wrapper from io import StringIO from itertools import chain from tqdm import tqdm import click from sacremoses.tokenize import MosesTokenizer, MosesDetokenizer from sacremoses.truecase import Moses...
import random import itertools import sys lfalf=[ chr(i) for i in range(ord('a'),ord('z')) ]+[ chr(i) for i in range(ord('A'),ord('Z')) ] gencomment=""" Maddisson formula: DC(G,S) is the sum of k(v) over all nodes of G except the root, where k(v)=||M(v),M(parent(v))||-1, M:G->S is the lca-mapping and ||v,...
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models from website.models import Question class Migration(SchemaMigration): def forwards(self, orm): # Adding index on 'Question', fields ['reviewed'] db.create_index('websit...
# -*- coding: utf-8 -*- # # Copyright (C) 2009 Edgewall Software # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. The terms # are also available at http://trac.edgewall.com/license.html. # # This software consists of vo...
# # Copyright (c) SAS Institute 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 w...
"""Utilities for writing code that runs on Python 2 and 3""" # Copyright (c) 2010-2015 Benjamin Peterson # # 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 with...
#!/usr/bin/env python3 # pylint: disable=C0111, redefined-outer-name from collections import defaultdict, OrderedDict import os import time import tempfile import copy import numpy as np import xarray as xr import pandas as pd import pytest from pyndl import ndl, count, io TEST_ROOT = os.path.join(os.path.pardir,...
import unittest, time, re from selenium import selenium import sys import os import csv sys.path.append("actions") from authentication import Authenticate from search import Search from messages import Message from form import Form, FormTemplate, rHeaderTemplate ### TODO ### # Change addUser to use the addForm methods...
r""" Backrefs for the 'regex' module. Add the ability to use the following backrefs with re: - `\Q` and `\Q...\E` - Escape/quote chars (search) - `\c` and `\C...\E` - Uppercase char or chars (replace) - `\l` and `\L...\E` ...
import logging from django.core.exceptions import ValidationError from django.db.utils import IntegrityError from framework import sentry from framework.auth import Auth from framework.celery_tasks import app as celery_app from osf.exceptions import ( NodeStateError, RegistrationBulkCreationRowError, Use...
import copy import numpy as np import unittest import ray from ray.rllib.agents.callbacks import DefaultCallbacks import ray.rllib.agents.ppo as ppo from ray.rllib.agents.ppo.ppo_tf_policy import ( ppo_surrogate_loss as ppo_surrogate_loss_tf, ) from ray.rllib.agents.ppo.ppo_torch_policy import PPOTorchPolicy from ...
#!/usr/bin/env python # coding:utf-8 """ This file manage the ssl connection dispatcher Include http/1.1 and http/2 workers. create ssl socket, then run worker on ssl. if ssl suppport http/2, run http/2 worker. provide simple https request block api. caller don't need to known ip/ssl/http2/appid. performance: ge...
#File used for passing all parameters of text to speech script in the command line #Arguments in order of appearance on the command line: #1: User input of text to be synthesized #2: Voice ID, male or female (1 = male, 0 = female) #3: Stream or Download (1 = stream, 0 = download) # (At this point, if stream is chose...
""" Unified interface for performing file system tasks. Uses os, os.path. shutil and distutil to perform the tasks. The behavior of some functions is slightly contaminated with requirements from Hyde: For example, the backup function deletes the directory that is being backed up. """ import os import platform import...
#!/usr/bin/env python2 """ This tutorial introduces the multilayer perceptron using Theano. A multilayer perceptron is a logistic regressor where instead of feeding the input to the logistic regression you insert a intermediate layer, called the hidden layer, that has a nonlinear activation function (usually tanh or...
#!/usr/bin/python #24th May #take input DONE #create directory DONE #save to system variable #how to write a service #make an account in google drive import sys; import os; import subprocess; import json from celery.bin.celery import status print (sys.version) # x = raw_input("enter username") # print 'kaa be' # ...
import warnings try: # Python 3 import http.client as httplib from urllib.parse import parse_qsl from functools import partial to_bytes = lambda value, *args, **kwargs: bytes(value, "utf-8", *args, **kwargs) except ImportError: # Python 2 import httplib from urlparse import parse_qsl to_b...
#!/usr/bin/env python3 # Copyright 2016 The Johns Hopkins University Applied Physics Laboratory # # 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-...
from comanage_nacha import NachaFile from comanage_nacha.entries import FileControl, EntryDetail from comanage_nacha.parser import Parser parser = Parser() confirmation_parser = Parser(confirmation_file=True) rejection_parser = Parser(rejection_file=True) simple = ("101 9100001912737206971506161208A094101WELLSFARGO ...
# -*- 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...
#!/usr/bin/python # # Copyright (c) 2011 The Bitcoin developers # Distributed under the MIT/X11 software license, see the accompanying # file license.txt or http://www.opensource.org/licenses/mit-license.php. # import time import json import pprint import hashlib import struct import re import base64 import httplib im...
import shutil # Library For Work With File In High Level Like Copy import webbrowser from params import * import socket import requests import re import time import sys import urllib.request import platform import random import datetime from functools import reduce import doctest meta_input = "" def sample_browser(sam...
import pytest import numpy as np import scipy.sparse as sp from sklearn.base import clone from sklearn.utils._testing import assert_array_equal from sklearn.utils._testing import assert_array_almost_equal from sklearn.utils._testing import assert_almost_equal from sklearn.utils._testing import ignore_warnings from sk...
# Copyright (c) 2017-present, Facebook, Inc. # All rights reserved. # # This source code is licensed under the 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. import logging import sys import t...
""" Utilities for handling RAR and ZIP archives Provides wrapper archive and exception classes to simplify archive extraction """ import os import shutil import zipfile from loguru import logger try: import rarfile except ImportError: rarfile = None logger = logger.bind(name='archive') class ArchiveErro...
# -*- coding: utf-8 -*- from __future__ import unicode_literals import sys from winsys._compat import unittest import uuid import winerror import win32api import win32con import win32security import pywintypes from winsys.tests import utils as testutils from winsys import registry, utils GUID = str(uuid.uuid1()) TE...
#!/usr/bin/env python2 import binascii import json import os import ssl import sys try: import libnacl import requests __import__('pyasn1') # not using module itself except ImportError: sys.stderr.write( 'Please install all dependancies (pip install -r requirements.txt):\n') raise from re...
# 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 may ...
#!/usr/bin/env python3 import glooey import pyglet import autoprop # Import everything from glooey into this namespace. We'll overwrite the # widgets we want to overwrite and everything else will be directly available. from glooey import * # Create a resource loader that knows where the assets for this theme are ...
# Copyright 2015 The TensorFlow Authors. 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 applica...
from __future__ import unicode_literals from six.moves.urllib.request import urlopen from six.moves.urllib.error import HTTPError import boto from boto.exception import S3ResponseError from boto.s3.key import Key from boto.s3.connection import OrdinaryCallingFormat from freezegun import freeze_time import requests i...
# This file is part of Indico. # Copyright (C) 2002 - 2022 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. import posixpath from flask import current_app, render_template, request from sqlalchemy.orm import load_...
# Copyright (c) 2012-2015 Tycho Andersen # Copyright (c) 2013 xarvh # Copyright (c) 2013 horsik # Copyright (c) 2013-2014 roger # Copyright (c) 2013 Tao Sauvage # Copyright (c) 2014 ramnes # Copyright (c) 2014 Sean Vig # Copyright (c) 2014 Adi Sieker # # Permission is hereby granted, free of charge, to any person obtai...
# Copyright 2015 The TensorFlow Authors. 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 applica...
# Copyright 2017 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, s...
__author__ = 'frank' import os import os.path import traceback import zstacklib.utils.uuidhelper as uuidhelper from kvmagent import kvmagent from kvmagent.plugins.imagestore import ImageStoreClient from zstacklib.utils import jsonobject from zstacklib.utils import linux from zstacklib.utils import shell from zstackli...
import floto import floto.decisions import floto.specs import copy import gzip import logging logger = logging.getLogger(__name__) import json class DecisionBuilder: def __init__(self, *, activity_tasks, default_activity_task_list): self.workflow_fail = False self.workflow_complete = False ...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ This module implements a discovery function for Denon AVR receivers. :copyright: (c) 2016 by Oliver Goetz. :license: MIT, see LICENSE for more details. """ import logging import asyncio import socket import re import xml.etree.ElementTree as ET from typing import Di...
"""Test the bootstrapping.""" # pylint: disable=protected-access import asyncio import glob import os from unittest.mock import Mock, patch import pytest from homeassistant import bootstrap, core, runner from homeassistant.bootstrap import SIGNAL_BOOTSTRAP_INTEGRATONS import homeassistant.config as config_util from h...
#!/usr/bin/env python # -*- mode: python; encoding: utf-8 -*- """Test the flow_management interface.""" from grr.gui import runtests_test from grr.lib import action_mocks from grr.lib import flags from grr.lib import flow from grr.lib import test_lib from grr.lib.rdfvalues import client as rdf_client from grr.lib.r...
""" This is an auxiliary script that is used to compute valid PLL values to set the CPU frequency to a given value. The algorithm here appears as C code for the machine.freq() function. """ from __future__ import print_function import re def close_int(x): return abs(x - round(x)) < 0.01 # original version that ...
import hail as hl from hail.utils import wrap_to_list def import_gtf(path, key=None): """Import a GTF file. The GTF file format is identical to the GFF version 2 file format, and so this function can be used to import GFF version 2 files as well. See https://www.ensembl.org/info/we...
#!/usr/bin/env python # coding: utf-8 """ A spot setup using cmf for a simple 1 storage hydrological model This example can be easily extended with more storages """ from __future__ import division, print_function import datetime import cmf import spotpy from spotpy.parameter import Uniform import numpy as np # M...
# -*- coding: utf-8 -*- from __future__ import absolute_import, unicode_literals import pytest from bson import DBRef from pymongo.errors import DuplicateKeyError from nose import with_setup from .. import Collection, Index, Model class TestCollection(Collection): def custom(self): return 'It works!' ...
# -*- coding: utf-8 -*- ''' magento.api Generic API for magento :license: BSD, see LICENSE for more details ''' import sys from threading import RLock PROTOCOLS = [] try: if sys.version_info <= (2,): from xmlrpclib import ServerProxy else: from xmlrpc.client import ServerProxy exc...
"""Materialized Path Trees""" import sys import operator if sys.version_info >= (3, 0): from functools import reduce from django.core import serializers from django.db import models, transaction, connection from django.db.models import F, Q from django.utils.translation import ugettext_noop as _ from treebeard....
import os from django.http import HttpResponseRedirect from django.urls import reverse from django.utils.decorators import method_decorator from django.views.generic import * from corehq.apps.styleguide.example_forms import ( BasicCrispyForm, CheckboxesForm, ) def styleguide_default(request): return Htt...
import re import unittest from urlparse import urlsplit, urlunsplit from xml.dom.minidom import parseString, Node from django.conf import settings from django.core import mail from django.core.management import call_command from django.core.urlresolvers import clear_url_caches from django.db import transaction, connec...
################################################################## # Code for testing the variational Multi-Stage Generative Model. # ################################################################## from __future__ import print_function, division # basic python import cPickle as pickle from PIL import Image import ...
# Copyright (c) 2013 Dell Inc. # Copyright 2013 OpenStack 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 # # Unle...
""" sentry.tasks.deletion ~~~~~~~~~~~~~~~~~~~~~ :copyright: (c) 2010-2014 by the Sentry Team, see AUTHORS for more details. :license: BSD, see LICENSE for more details. """ from __future__ import absolute_import from celery.utils.log import get_task_logger from sentry.utils.query import bulk_delete_objects from se...
from __future__ import absolute_import, unicode_literals import logging import urlparse from mopidy import models from mopidy.audio import PlaybackState from mopidy.core import listener from mopidy.internal import deprecation, validation logger = logging.getLogger(__name__) class PlaybackController(object): py...
# Natural Language Toolkit: Tree Transformations # # Copyright (C) 2005-2007 Oregon Graduate Institute # Author: Nathan Bodenstab <bodenstab@cslu.ogi.edu> # URL: <http://www.nltk.org/> # For license information, see LICENSE.TXT """ A collection of methods for tree (grammar) transformations used in parsing natural lang...
# Copyright (c) 2012 Cloudera, Inc. All rights reserved. # # Talk to an impalad through beeswax. # Usage: # * impalad is a string with the host and port of the impalad # with which the connection should be established. # The format is "<hostname>:<port>" # * query_string is the query to be executed, as a st...
# Copyright (c) 2014 Alex Meade. All rights reserved. # Copyright (c) 2014 Clinton Knight. All rights reserved. # Copyright (c) 2015 Tom Barron. All rights reserved. # Copyright (c) 2015 Goutham Pacha Ravi. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not u...
""" mf module. Contains the ModflowGlobal, ModflowList, and Modflow classes. """ import os import sys from ..mbase import BaseModel from ..modflow import Modflow from ..version import __version__ class LgrChild(): def __init__(self, ishflg=1, ibflg=59, iucbhsv=0, iucbfsv=0, mxlgriter=20, iou...
""" Sliding-window-based job/task queue class (& example of use.) May use ``multiprocessing.Process`` or ``threading.Thread`` objects as queue items, though within Fabric itself only ``Process`` objects are used/supported. """ import time try: import Queue except ImportError: import queue as Queue from multip...
# Copyright 2014 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). import collections import json import os import re import shutil from datetime import datetime from pathlib import Path from pystache import Renderer from pants.backend.docgen.tasks.gene...
# Copyright (c) 2014 Rackspace, 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 wr...
import comtypes import comtypes.automation from comtypes.automation import IEnumVARIANT from comtypes.automation import DISPATCH_METHOD from comtypes.automation import DISPATCH_PROPERTYGET from comtypes.automation import DISPATCH_PROPERTYPUT from comtypes.automation import DISPATCH_PROPERTYPUTREF from comtypes.automa...
# Copyright 2018 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, s...
"""The tests for the MQTT sensor platform.""" import copy from datetime import datetime, timedelta import json from unittest.mock import patch import pytest from homeassistant.components.mqtt.sensor import MQTT_SENSOR_ATTRIBUTES_BLOCKED import homeassistant.components.sensor as sensor from homeassistant.const import ...
"""Turns a surface description into a panair network""" import numpy as np import sys from math import sin, cos, sqrt def axisymmetric_surf(data_x, data_r, N_theta): theta_start = np.pi # radians theta_end = np.pi/2. # radians data_t = np.linspace(theta_start, theta_end, N_theta) surf_coords = np...
#!/usr/bin/env python3 """ Open a shell over MAVLink. @author: Beat Kueng (beat-kueng@gmx.net) """ from __future__ import print_function import sys, select import termios from timeit import default_timer as timer from argparse import ArgumentParser import os try: from pymavlink import mavutil except ImportErro...
import asyncio from kafka.admin import NewTopic, NewPartitions from kafka.admin.config_resource import ConfigResource, ConfigResourceType from aiokafka.admin import AIOKafkaAdminClient from aiokafka.consumer import AIOKafkaConsumer from aiokafka.producer import AIOKafkaProducer from aiokafka.structs import TopicParti...
from django.core.urlresolvers import reverse from django.test import TestCase from .models import ZipCodeLocation, Location SAMPLE_POINT_1 = 'POINT(-92.289595 34.746481)' SAMPLE_POINT_2 = 'POINT(-92.273494 34.744487)' SAMPLE_POINT_3 = 'POINT(-92.489047 34.810632)' SAMPLE_POINT_4 = 'POINT(-94.251795 35.7813)' SAMPLE_...
import math def is_spaces(st): for x in st: if x == '#': return True if x != ' ' and x != '\t' and x != '\n': return False return True class BlankBeforeFunction: """ Number of blank lines before function in files. Verbose version doesn't require specific logic. ""...
#!/usr/bin/env python # # Licensed to the .NET Foundation under one or more agreements. # The .NET Foundation licenses this file to you under the MIT license. # See the LICENSE file in the project root for more information. # ########################################################################## ###################...
import logging import os from time import sleep from datetime import timedelta, datetime from snaptastic import exceptions from snaptastic import get_ec2_conn from snaptastic import metaclass from snaptastic.ebs_volume import EBSVolume from snaptastic.utils import get_userdata_dict, add_tags logger = logging.getLogg...
# Copyright (c) 2010, individual contributors (see AUTHORS file) # # Permission to use, copy, modify, and/or distribute this software for any # purpose with or without fee is hereby granted, provided that the above # copyright notice and this permission notice appear in all copies. # # THE SOFTWARE IS PROVIDED "AS IS" ...
from graphviz import Digraph import random import imageio imageio.plugins.ffmpeg.download() from moviepy.editor import * import numpy as np class ReactionPathDiagram(): """ Initializes the values of concentations, rates and species of a system of elementary reactions. INPUTS ======= targe...
import os.path import platform import sys import webbrowser from datetime import datetime import argparse try: import simplejson as json except ImportError: import json from dogshell.common import report_errors, report_warnings, CommandLineClient, print_err class DashClient(CommandLineClient): def setup...
#!/usr/bin/env python """Module with GRRWorker implementation.""" import pdb import time import traceback import logging from grr.lib import aff4 from grr.lib import config_lib from grr.lib import flags from grr.lib import flow from grr.lib import master from grr.lib import queue_manager as queue_manager_lib from ...
#!/usr/bin/env python from __future__ import (absolute_import, division, print_function, unicode_literals) def classify_pixel(input_data, classifier, threads=8, ram=4000): """ Runs a pre-trained ilastik classifier on a volume of data Adapted from Stuart Berg's example here: https:...
import os import sys import json import types import shutil import logging import tempfile import contextlib from pyblish import api from . import lib, schema self = sys.modules[__name__] self.log = logging.getLogger("pyblish-starter") self._registered_data = list() self._registered_families = list() self._registe...
import os import sys import json, socket, time # This makes sure the path which python uses to find things when using import # can find all our code. sys.path.insert(0, os.path.abspath('..')) sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))) # import qt modules (platform independant) ...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # name: test_website.py # author: Harold Bradley III # email: harold@bradleystudio.net # created on: 12/11/2015 # # pylint: disable=invalid-name,unused-argument """ Integration and unit tests for ww module's Website class ...
# Copyright 2013 Violin Memory, 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 requi...
''' Created on 26 May 2013 @author: lukasz.forynski @brief: Implementation of the multi-key dictionary. https://github.com/formiaczek/python_data_structures ___________________________________ Copyright (c) 2013 Lukasz Forynski <lukasz.forynski@gmail.com> Permission is hereby granted, free of charge, to any perso...
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. # Copyright (c) 2018, NVIDIA CORPORATION. All rights reserved. import numpy as np import torch from torch import nn from ..structures.bounding_box import BoxList from .utils import meshgrid import maskrcnn_benchmark._C as C # meshgrid = torch.m...
# # Jasy - Web Tooling Framework # Copyright 2010-2012 Zynga Inc. # Copyright 2013-2014 Sebastian Werner # # # License: MPL 1.1/GPL 2.0/LGPL 2.1 # Authors: # - Brendan Eich <brendan@mozilla.org> (Original JavaScript) (2004-2010) # - Sebastian Werner <info@sebastian-werner.net> (Python Port) (2010) # import re imp...
#!/usr/bin/env python import sys import os import threading import traceback import json import multiprocessing import subprocess import http import html import urllib import argparse from .aserver import AsyncCache, AsyncTCPServer, AsyncHTTPRequestHandler from ..fpbench import fpcparser from ..arithmetic import nat...
#!/usr/bin/env python3 from cum import config, exceptions, output from functools import wraps import click import concurrent.futures import requests class CumGroup(click.Group): def command(self, check_db=True, *args, **kwargs): def decorator(f): @wraps(f) def wrapper(*args, **kwar...
# Copyright 2018 The TensorFlow Authors. 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 applica...
data = ( 'jjyim', # 0x00 'jjyib', # 0x01 'jjyibs', # 0x02 'jjyis', # 0x03 'jjyiss', # 0x04 'jjying', # 0x05 'jjyij', # 0x06 'jjyic', # 0x07 'jjyik', # 0x08 'jjyit', # 0x09 'jjyip', # 0x0a 'jjyih', # 0x0b 'jji', # 0x0c 'jjig', # 0x0d 'jjigg', # 0x0e 'jjigs', # 0x0f 'jjin',...
#!/usr/bin/env python """WAL-E is a program to assist in performing PostgreSQL continuous archiving on S3 or Windows Azure Blob Service (WABS): it handles pushing and fetching of WAL segments and base backups of the PostgreSQL data directory. """ import sys def gevent_monkey(*args, **kwargs): import gevent.monke...
#!/usr/bin/python -u # 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 # ...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright (c) 2013 Hewlett-Packard Development Company, L.P. # Copyright (c) 2012 VMware, Inc. # Copyright (c) 2011 Citrix Systems, Inc. # Copyright 2011 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this f...
from pysnmp.hlapi import * from enum import Enum from pysnmp.error import PySnmpError from pysnmp.entity.rfc3413.oneliner import cmdgen import string import ipaddress Values = { "hostForwarding" : "1.3.6.1.2.1.4.1.0", "destRoute" : "1.3.6.1.2.1.4.24.4.1.1", "netmask" : "1.3.6.1.2.1.4.24.4.1.2", "nextHo...
""" Words and static data Please extend this file with more lvl=100 shibe wow. """ import random from collections import deque class DogeDeque(deque): """ A doge deque. A doqe, if you may. Because random is random, just using a random choice from the static lists below there will always be some re...
# Copyright (c) 2016 Dell Inc. or its subsidiaries. # 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 # # ...
# 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 # d...