text
stringlengths
5.09k
178k
domain
stringclasses
106 values
import collections import re import sys import time import traceback import pytest import threading import logging from flaky import flaky from enum import Enum from queue import Empty from functools import partial from multiprocessing import Process, Queue from cassandra import ConsistencyLevel, InvalidRequest, Writ...
codeparrot/github-code-clean
"""Generated message classes for servicemanagement version v1. Google Service Management allows service producers to publish their services on Google Cloud Platform so that they can be discovered and used by service consumers. """ # NOTE: This file is autogenerated and should not be edited by hand. from apitools.base...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """ pygments.lexers._phpbuiltins ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This file loads the function names and their modules from the php webpage and generates itself. Do not alter the MODULES dict by hand! WARNING: the generation transfers quite much data over your ...
codeparrot/github-code-clean
#!/usr/bin/env python # -*- coding: utf-8 -*- import re myString = """eiffeltower 1 eiffeltower 0 https://farm6.staticflickr.com/5613/15782490471_d94bc1a088_z.jpg blackandwhite paris france europe eiffeltower toureiffel eiffeltower 1 https://farm8.staticflickr.com/7469/15597563587_1bd77139cd_z.jpg sky paris france ni...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """Main IPython class.""" #----------------------------------------------------------------------------- # Copyright (C) 2001 Janko Hauser <jhauser@zscout.de> # Copyright (C) 2001-2007 Fernando Perez. <fperez@colorado.edu> # Copyright (C) 2008-2011 The IPython Development Team # # Distribu...
codeparrot/github-code-clean
from __future__ import division # pylint: disable-msg=W0402 import re import string import sys import tempfile import warnings import inspect import os import subprocess import locale import traceback from datetime import datetime from functools import wraps, partial from contextlib import contextmanager from distuti...
codeparrot/github-code-clean
#!/usr/bin/env python #-*- coding: utf-8 -*- ### 2008-2015 Charlie Barnes. ### 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 la...
codeparrot/github-code-clean
# deps.py -- Portage dependency resolution functions # Copyright 2003-2010 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 __all__ = [ 'Atom', 'best_match_to_list', 'cpvequal', 'dep_getcpv', 'dep_getkey', 'dep_getslot', 'dep_getusedeps', 'dep_opconvert', 'flatten', 'get_operato...
codeparrot/github-code-clean
# Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 from __future__ import division, print_function, unicode_literals import collections import errno import io import logging import stat import sys import textwrap import warnings from collections import deque fro...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- ''' Task Coach - Your friendly task manager Copyright (C) 2004-2013 Task Coach developers <developers@taskcoach.org> Task Coach 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 vers...
codeparrot/github-code-clean
#!/usr/bin/python import logging logging.basicConfig(level=logging.INFO, format="%(asctime)s - %(name)s - %(levelname)s - %(message)s") import procgame.game, sys, os import procgame.config import random import procgame.sound sys.path.insert(0,os.path.pardir) import bingo_emulator.common.units as units import bingo_em...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- import copy import shutil from datetime import timedelta from functools import wraps from json import loads from textwrap import dedent from unittest import SkipTest from uuid import uuid4 import ddt import lxml.html import mock from django.conf import settings from django.contrib.auth.models ...
codeparrot/github-code-clean
""" Provides full versioning CRUD and representation for collections of xblocks (e.g., courses, modules, etc). Representation: * course_index: a dictionary: ** '_id': a unique id which cannot change, ** 'org': the org's id. Only used for searching not identity, ** 'course': the course's catalog number ...
codeparrot/github-code-clean
#!/usr/bin/env python # # This is the API builder, it parses the C sources and build the # API formal description in XML. # # See Copyright for the status of this software. # # daniel@veillard.com # from __future__ import print_function import os import sys import glob import re quiet = True warnings = 0 debug = Fal...
codeparrot/github-code-clean
import re import collections from enum import Enum from ydk._core._dm_meta_info import _MetaInfoClassMember, _MetaInfoClass, _MetaInfoEnum from ydk.types import Empty, YList, YLeafList, DELETE, Decimal64, FixedBitsDict from ydk._core._dm_meta_info import ATTRIBUTE, REFERENCE_CLASS, REFERENCE_LIST, REFERENCE_LEAFLI...
codeparrot/github-code-clean
# Copyright 2015 Cisco Systems, 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...
codeparrot/github-code-clean
#!/usr/bin/python # $Id: $ """ Databank submission test cases $Rev: $ """ import os, os.path from datetime import datetime, timedelta import sys import unittest import logging import httplib import urllib try: # Running Python 2.5 with simplejson? import simplejson as json except ImportError: import json ...
codeparrot/github-code-clean
########################################################### # # Copyright (c) 2005-2008, Southpaw Technology # All Rights Reserved # # PROPRIETARY INFORMATION. This software is proprietary to # Southpaw Technology, and is not to be reproduced, transmitted, # or disclosed in any way without written ...
codeparrot/github-code-clean
#START_LICENSE########################################################### #END_LICENSE############################################################# from PyQt4.QtGui import (QGraphicsRectItem, QGraphicsLineItem, QGraphicsPolygonItem, QGraphicsEllipseItem, QPen, QColor, ...
codeparrot/github-code-clean
import warnings from distutils.version import LooseVersion import numpy as np from numpy.testing import (assert_array_almost_equal, assert_array_equal, assert_array_less, assert_equal, assert_, assert_approx_equal, assert_allclose, assert...
codeparrot/github-code-clean
# 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...
codeparrot/github-code-clean
# Copyright 2012 Hewlett-Packard Development Company, L.P. # Copyright 2012 Varnish Software AS # # 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 ...
codeparrot/github-code-clean
# 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 ...
codeparrot/github-code-clean
""" :created: 2017-11 :author: Alex BROSSARD <abrossard@artfx.fr> """ from PySide2 import QtWidgets, QtCore, QtGui from pymel import core as pmc from auri.auri_lib import AuriScriptView, AuriScriptController, AuriScriptModel, is_checked, grpbox from auri.scripts.Maya_Scripts import rig_lib from auri.scripts.Maya_Scri...
codeparrot/github-code-clean
""" Mappings from Adobe glyph names to Unicode characters. In some CMap tables, Adobe glyph names are used for specifying Unicode characters instead of using decimal/hex character code. The following data was taken by $ wget https://partners.adobe.com/public/developer/en/opentype/glyphlist.txt $ python tools/con...
codeparrot/github-code-clean
from enigma import getPrevAsciiCode from Tools.NumericalTextInput import NumericalTextInput from Tools.Directories import resolveFilename, SCOPE_CONFIG, fileExists from Components.Harddisk import harddiskmanager from Tools.LoadPixmap import LoadPixmap from copy import copy as copy_copy from os import path as os_path fr...
codeparrot/github-code-clean
#!/usr/bin/env python3 # THIS FILE IS PART OF THE CYLC SUITE ENGINE. # Copyright (C) 2008-2019 NIWA & British Crown (Met Office) & Contributors. # # 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...
codeparrot/github-code-clean
"""Execute Ansible tests.""" from __future__ import (absolute_import, division, print_function) __metaclass__ = type import json import os import datetime import re import time import textwrap import functools import hashlib import difflib import filecmp import random import string import shutil from . import types a...
codeparrot/github-code-clean
# ---------------------------------------------------------------------------- # -- Components # -- comps library # -- Python classes that creates useful parts for FreeCAD # ---------------------------------------------------------------------------- # -- (c) Felipe Machado # -- Area of Electronics. Rey Juan Carlos Uni...
codeparrot/github-code-clean
# Copyright 2012 OpenStack Foundation # 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 req...
codeparrot/github-code-clean
#!/usr/bin/env python """ Copyright (c) 2014, Google Inc. 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 list of ...
codeparrot/github-code-clean
############################################################################### ## ## Copyright 2011-2013 Tavendo GmbH ## ## 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 ## ## ...
codeparrot/github-code-clean
import re import cgi import datetime import json import urllib from cStringIO import StringIO from nose.tools import eq_, ok_ import mock import pyquery from django.conf import settings from django.contrib.auth.models import User, Group, Permission from django.core import mail from django.utils import timezone from d...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- # # PySPED - Python libraries to deal with Brazil's SPED Project # # Copyright (C) 2010-2012 # Copyright (C) Aristides Caldeira <aristides.caldeira at tauga.com.br> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Library General Public Lic...
codeparrot/github-code-clean
# Copyright 2016 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...
codeparrot/github-code-clean
#!/usr/bin/env python """ sage_server.py -- unencrypted forking TCP server. Note: I wrote functionality so this can run as root, create accounts on the fly, and serve sage as those accounts. Doing this is horrendous from a security point of view, and I'm definitely not doing this. None of that functionality is actua...
codeparrot/github-code-clean
# Copyright (c) 2014 Christian Schwede <christian.schwede@enovance.com> # # 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...
codeparrot/github-code-clean
"""Utilities for saving/loading Checkpointable objects.""" # Copyright 2017 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.apa...
codeparrot/github-code-clean
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2012, Stephen Fromm <sfromm@gmail.com> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': ...
codeparrot/github-code-clean
from __future__ import division, absolute_import, print_function import copy import pickle import sys import platform import gc import warnings import tempfile from os import path from io import BytesIO from itertools import chain import numpy as np from numpy.testing import ( run_module_suite, TestCase, asse...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """ Tests of responsetypes """ from datetime import datetime import json import os import pyparsing import random import unittest import textwrap import requests import mock from . import new_loncapa_problem, test_capa_system, load_fixture import calc from capa.responsetypes import LoncapaPro...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- from __future__ import unicode_literals import copy import datetime import json import uuid from django.core.exceptions import NON_FIELD_ERRORS from django.core.files.uploadedfile import SimpleUploadedFile from django.core.validators import RegexValidator from django.forms import ( Boolean...
codeparrot/github-code-clean
# 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 ...
codeparrot/github-code-clean
################################################################ # File: ch.py # Title: Chatango Library # Original Author: Lumirayz/Lumz <lumirayz@gmail.com> # Current Maintainers and Contributors: # Nullspeaker <import codecs;codecs.encode('aunzzbaq129@tznvy.pbz','rot_13')> # asl97 <asl97@outlook.com> # pystub # ...
codeparrot/github-code-clean
# 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 ...
codeparrot/github-code-clean
import copy import datetime import json import logging import os import re import time import warnings from collections import defaultdict from typing import List import pandas as pd import requests from pyshex import ShExEvaluator from rdflib import Graph from shexer.shaper import Shaper from wikidataintegrator.wdi_...
codeparrot/github-code-clean
<<<<<<< HEAD <<<<<<< HEAD import functools import hmac import hashlib import unittest import warnings from test import support def ignore_warning(func): @functools.wraps(func) def wrapper(*args, **kwargs): with warnings.catch_warnings(): warnings.filterwarnings("ignore", ...
codeparrot/github-code-clean
#!/usr/bin/env python # -*- coding: utf8 -*- """Windows Registry Fixer This is a module composed by functions that are used to create a file with entries to Windows' Regedit. After the file's creation, the user is able to import-it in Regedit. """ __author__ = "José Lopes de Oliveira Júnior <jlojunior (at) gmail....
codeparrot/github-code-clean
#!/usr/bin/env python # -*- coding: utf-8 -*- LICENSE = '''manageR - Interface to the R statistical programming language Copyright (C) 2009-2010 Carson J. Q. Farmer This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public Licence as published by the Free Softw...
codeparrot/github-code-clean
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. from __future__ import absolute_import, division, print_function import collections import contextlib import itertools import warnings fro...
codeparrot/github-code-clean
#!/usr/bin/env ambari-python-wrap """ 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...
codeparrot/github-code-clean
# Copyright 2010 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # Copyright 2011 Piston Cloud Computing, Inc. # Copyright 2012-2013 Red Hat, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # ...
codeparrot/github-code-clean
# Copyright (c) 2012 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 agreed to ...
codeparrot/github-code-clean
''' from pystatsmodels mailinglist 20100524 Notes: - unfinished, unverified, but most parts seem to work in MonteCarlo - one example taken from lecture notes looks ok - needs cases with non-monotonic inequality for test to see difference between one-step, step-up and step-down procedures - FDR doesn't look rea...
codeparrot/github-code-clean
from pybindgen import Module, FileCodeSink, param, retval, cppclass, typehandlers import pybindgen.settings import warnings class ErrorHandler(pybindgen.settings.ErrorHandler): def handle_error(self, wrapper, exception, traceback_): warnings.warn("exception %r in wrapper %s" % (exception, wrapper)) ...
codeparrot/github-code-clean
#!/usr/bin/env python """Create a "virtual" Python installation""" import os import sys # If we are running in a new interpreter to create a virtualenv, # we do NOT want paths from our existing location interfering with anything, # So we remove this file's directory from sys.path - most likely to be # the previous in...
codeparrot/github-code-clean
"""Module containing non-deprecated functions borrowed from Numeric. """ from __future__ import division, absolute_import, print_function import types import warnings import numpy as np from .. import VisibleDeprecationWarning from . import multiarray as mu from . import umath as um from . import numerictypes as nt ...
codeparrot/github-code-clean
# python version 1.0 DO NOT EDIT # # Generated by smidump version 0.4.7: # # smidump -f python IPV6-MIB FILENAME = "/usr/share/mibs/ietf/IPV6-MIB" MIB = { "moduleName" : "IPV6-MIB", "IPV6-MIB" : { "nodetype" : "module", "language" : "SMIv2", "organization" : """...
codeparrot/github-code-clean
# Copyright 2012 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
codeparrot/github-code-clean
import datetime import os from decimal import Decimal from unittest import mock, skipUnless from django import forms from django.core.exceptions import ( NON_FIELD_ERRORS, FieldError, ImproperlyConfigured, ) from django.core.files.uploadedfile import SimpleUploadedFile from django.core.validators import Validation...
codeparrot/github-code-clean
#!/usr/bin/env python ## WARNING: This file is generated #!/usr/bin/env python """Create a "virtual" Python installation """ __version__ = "1.10.1" virtualenv_version = __version__ # legacy import base64 import sys import os import codecs import optparse import re import shutil import logging import tempfile import ...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """Grading Open Service Interface Definitions grading version 3.0.0 The Grading OSID defines a service to apply grades or ratings. Grade Systems The grade system sessions provide the means to retrievs and manage ``GradeSystem`` definitions. A ``GradeSystem`` is a fixed set of ``Grades`` . ``G...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """ Objects representing various types of MediaWiki, including Wikibase, pages. This module also includes objects: * Property: a type of semantic data. * Claim: an instance of a semantic assertion. * Revision: a single change to a wiki page. * FileInfo: a structure holding imageinfo of latest...
codeparrot/github-code-clean
from __future__ import with_statement from itertools import chain import datetime import sys import warnings import time import threading import time as mod_time from redis._compat import (b, basestring, bytes, imap, iteritems, iterkeys, itervalues, izip, long, nativestr, unicode, ...
codeparrot/github-code-clean
# Copyright 2005 Duke University # Copyright (C) 2012-2015 Red Hat, 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 versi...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """ Created on Thu May 30 17:02:39 2013 @author: jpeacock-pr """ #============================================================================ import matplotlib.pyplot as plt import numpy as np from matplotlib.ticker import MultipleLocator import matplotlib.colors as colors import matplotlib....
codeparrot/github-code-clean
#!/usr/bin/env python ######################################################################## # $HeadURL$ ######################################################################## """ File Catalog Client Command Line Interface. """ __RCSID__ = "$Id$" import stat import cmd import commands import os.path import time i...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """ Created on Wed Sep 21 11:49:00 2016 @author: acollin """ import os import datetime from collections import Counter from dateutil.parser import parse import utm import numpy as np import pandas as pd from shapely.geometry import Point this_dir = os.path.dirname(os.path.realpath(__file__))...
codeparrot/github-code-clean
#---------------------------------------------------------------------- # This file was generated by ./img2py # from wx import ImageFromStream, BitmapFromImage, EmptyIcon import cStringIO, zlib def getData(): return zlib.decompress( 'x\xda\x00\x1f@\xe0\xbf\x89PNG\r\n\x1a\n\x00\x00\x00\rIHDR\x00\x00\x00\x80\ \x00\...
codeparrot/github-code-clean
import os.path import xml.etree.ElementTree as ET import pytest import salt.modules.virt as virt import salt.syspaths import salt.utils.xmlutil as xmlutil from salt.exceptions import CommandExecutionError, SaltInvocationError from tests.support.mock import MagicMock, patch from .conftest import loader_modules_config ...
codeparrot/github-code-clean
#!/usr/bin/env python """ vg_pedigree.py: pedigree map and calling pipeline to produce parental-enhanced mapping and calling output. """ import argparse, sys, os, os.path, errno, random, subprocess, shutil, itertools, glob, tarfile import doctest, re, json, collections, time, timeit import logging, logging.handlers, s...
codeparrot/github-code-clean
import json import datetime import time import pytest import mock import botocore.exceptions from botocore.vendored.requests import ConnectionError as \ RequestsConnectionError from botocore.vendored.requests.exceptions import ReadTimeout as \ RequestsReadTimeout from botocore import stub from botocore.utils i...
codeparrot/github-code-clean
# # 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...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- '''Unit tests for models and their factories.''' import mock import unittest from nose.tools import * # noqa (PEP8 asserts) import pytz import datetime import urlparse import itsdangerous import random import string from dateutil import parser from modularodm import Q from modularodm.exceptio...
codeparrot/github-code-clean
# Copyright 2015 IBM Corp. # 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 app...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- from __future__ import unicode_literals import copy import datetime import json import uuid from django.core.exceptions import NON_FIELD_ERRORS from django.core.files.uploadedfile import SimpleUploadedFile from django.core.validators import RegexValidator from django.forms import ( Boolean...
codeparrot/github-code-clean
# Copyright 2012 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2012 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the...
codeparrot/github-code-clean
from __future__ import division, absolute_import, print_function import warnings import sys import numpy as np from numpy.testing import ( run_module_suite, TestCase, assert_, assert_equal, assert_array_equal, assert_almost_equal, assert_array_almost_equal, assert_raises, assert_allclose, assert_array_max...
codeparrot/github-code-clean
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Wed Jul 24 19:16:51 2019 @author: mostafamousavi last update: 06/06/2020 """ from __future__ import division, print_function import numpy as np import h5py import matplotlib matplotlib.use('agg') from tqdm import tqdm import os os.environ['KERAS_BACKEND']='...
codeparrot/github-code-clean
# coding: utf-8 from sqlalchemy.testing.assertions import eq_, assert_raises, \ assert_raises_message, is_, AssertsExecutionResults, \ AssertsCompiledSQL, ComparesTables from sqlalchemy.testing import engines, fixtures from sqlalchemy import testing import datetime from sqlalchemy import Table, MetaData, Column...
codeparrot/github-code-clean
# Tweepy # Copyright 2009-2022 Joshua Roesslein # See LICENSE for details. import contextlib import functools import imghdr import logging import mimetypes from platform import python_version import sys import time from urllib.parse import urlencode import requests import tweepy from tweepy.errors import ( BadRe...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- ## This file is part of CDS Invenio. ## Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 CERN. ## ## CDS Invenio 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 ...
codeparrot/github-code-clean
#ryan g. coleman ryangc ATSYMBOL mail.med.upenn.edu crystal.med.upenn.edu #Copyright 2006, Ryan G Coleman, Kim A Sharp #primitives for topology of tst files import tstdata # data structure import sys # for exiting import priodict import geometry import tstdebug # for debugging import mesh import math def fillInHo...
codeparrot/github-code-clean
#!/usr/bin/python2 # # Copyright (c) 2009 Google Inc. 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 list of...
codeparrot/github-code-clean
# orm/relationships.py # Copyright (C) 2005-2014 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 """Heuristics related to join conditions as used in :func:`.relationship`. Pro...
codeparrot/github-code-clean
""" This module contains various functions that are special cases of incomplete gamma functions. It should probably be renamed. """ from __future__ import print_function, division from sympy.core import Add, S, C, sympify, cacheit, pi, I from sympy.core.function import Function, ArgumentIndexError from sympy.func...
codeparrot/github-code-clean
""" ---------------------------------------------------- An Artificial Neural Network System Implementing Backprop. Part of the Pyrobot Robotics Project. Provided under the GNU General Public License. ---------------------------------------------------- (c) 2001-2006, Developmental Robotics Research Group -------------...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- from __future__ import absolute_import from __future__ import print_function from typing import Any, Callable, Dict, Iterable, List, Mapping, Optional, Tuple, TypeVar, Text from mock import patch, MagicMock from django.http import HttpResponse from django.test import TestCase, override_setting...
codeparrot/github-code-clean
"""Test the config manager.""" import asyncio from datetime import timedelta from unittest.mock import AsyncMock, patch import pytest from homeassistant import config_entries, data_entry_flow, loader from homeassistant.const import EVENT_HOMEASSISTANT_STARTED from homeassistant.core import CoreState, callback from ho...
codeparrot/github-code-clean
import warnings from sympy import Basic, Symbol, Integer from sympy.core import sympify from sympy.core.basic import S, C from sympy.polys import Poly, roots from sympy.simplify import simplify from sympy.utilities import any # from sympy.printing import StrPrinter /cyclic/ import random class NonSquareMatrixExcept...
codeparrot/github-code-clean
"""Test whether all elements of cls.args are instances of Basic.""" # NOTE: keep tests sorted by (module, class name) key. import inspect import os import re import warnings from diofant import (ITE, Add, Adjoint, And, Atom, AtomicExpr, Basic, BlockDiagMatrix, BlockMatrix, Complement, Contains, ...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """ auibar contains an implementation of AuiToolBar, which is a completely owner-drawn toolbar perfectly integrated with the AUI layout system. This allows drag and drop of toolbars, docking/floating behaviour and the possibility to define "overflow" items in the toolbar itself. The default the...
codeparrot/github-code-clean
#!/usr/bin/env python3 """ Overview ======== A curses-based menuconfig implementation. The interface should feel familiar to people used to mconf ('make menuconfig'). Supports the same keys as mconf, and also supports a set of keybindings inspired by Vi: J/K : Down/Up L : Enter menu/Toggle item H ...
codeparrot/github-code-clean
from pybindgen import Module, FileCodeSink, param, retval, cppclass, typehandlers import pybindgen.settings import warnings class ErrorHandler(pybindgen.settings.ErrorHandler): def handle_error(self, wrapper, exception, traceback_): warnings.warn("exception %r in wrapper %s" % (exception, wrapper)) ...
codeparrot/github-code-clean
'''"Executable documentation" for the pickle module. Extensive comments about the pickle protocols and pickle-machine opcodes can be found here. Some functions meant for external use: genops(pickle) Generate all the opcodes in a pickle, as (opcode, arg, position) triples. dis(pickle, out=None, memo=None, indentl...
codeparrot/github-code-clean
# 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...
codeparrot/github-code-clean
#!/usr/bin/env python # # asn2wrs.py # ASN.1 to Wireshark dissector compiler # Copyright 2004 Tomas Kukosa # # 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 # ...
codeparrot/github-code-clean
#! /usr/bin/env python # # Protocol Buffers - Google's data interchange format # Copyright 2008 Google Inc. All rights reserved. # https://developers.google.com/protocol-buffers/ # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions ...
codeparrot/github-code-clean
"""OS Modules environ method to get the setup vars from the Environment""" # import built-in & third-party modules import time import random import os import csv import json import requests import unicodedata import logging import logging.handlers from datetime import datetime from datetime import timedelta from math ...
codeparrot/github-code-clean
# This module is intended to be used by the build/installation scripts of # extension modules created with SIP. It provides information about file # locations, version numbers etc., and provides some classes and functions. # # Copyright (c) 2013 Riverbank Computing Limited <info@riverbankcomputing.com> # # This file i...
codeparrot/github-code-clean