text
stringlengths
5.09k
178k
domain
stringclasses
106 values
import unittest import re from datetime import datetime from glob import glob from os import (makedirs, statvfs, listdir, symlink, uname, remove, utime, environ, access, R_OK, W_OK) from os.path import exists, isdir, join from subprocess import call, check_output, STDOUT, TimeoutExpired from time impo...
codeparrot/github-code-clean
import pytest import time import re from selenium import webdriver from random import randint import selenium.webdriver.support.expected_conditions as EC from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.common.by import By from selenium.webdriver.support.ui import Select from s...
codeparrot/github-code-clean
# Orca # # Copyright 2005-2009 Sun Microsystems Inc. # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by the Free Software Foundation; either # version 2.1 of the License, or (at your option) any later version. # # This...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU...
codeparrot/github-code-clean
# # File: courseware/capa/responsetypes.py # """ Problem response evaluation. Handles checking of student responses, of a variety of types. Used by capa_problem.py """ # pylint: disable=attribute-defined-outside-init # standard library imports import abc # TODO: Refactor this code and fix this issue. import cgi im...
codeparrot/github-code-clean
# -*- encoding: utf-8 -*- ############################################################################## # # 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, either version 3 of the...
codeparrot/github-code-clean
""" Site description for rapd_test "site" """ __license__ = """ This file is part of RAPD Copyright (C) 2016-2018 Cornell University All rights reserved. RAPD 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 Foundati...
codeparrot/github-code-clean
# Copyright (c) 2013 VMware, 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...
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
""" Utility function to facilitate testing. """ from __future__ import division, absolute_import, print_function import os import sys import re import operator import warnings from functools import partial, wraps import shutil import contextlib from tempfile import mkdtemp, mkstemp from unittest.case import SkipTest ...
codeparrot/github-code-clean
# Copyright (c) 2012 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Top-level presubmit script for Chromium. See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts for more details about the presu...
codeparrot/github-code-clean
# Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> # Matti Hamalainen <msh@nmr.mgh.harvard.edu> # Martin Luessi <mluessi@nmr.mgh.harvard.edu> # Denis Engemann <denis.engemann@gmail.com> # Teon Brooks <teon.brooks@gmail.com> # Marijn van Vliet <w.m.vanvli...
codeparrot/github-code-clean
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # astrokep.py - Waqas Bhatti (wbhatti@astro.princeton.edu) - 05/2016 ''' Contains various useful tools for analyzing Kepler light curves. ''' ############# ## LOGGING ## ############# import logging from astrobase import log_sub, log_fmt, log_date_fmt DEBUG = False if...
codeparrot/github-code-clean
""" Test functions for linalg.decomp module """ __usage__ = """ Build linalg: python setup_linalg.py build Run tests if scipy is installed: python -c 'import scipy;scipy.linalg.test()' Run tests if linalg is not installed: python tests/test_decomp.py """ import numpy as np from numpy.testing import TestCase, as...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU...
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
r""" This module contains :py:meth:`~sympy.solvers.ode.dsolve` and different helper functions that it uses. :py:meth:`~sympy.solvers.ode.dsolve` solves ordinary differential equations. See the docstring on the various functions for their uses. Note that partial differential equations support is in ``pde.py``. Note t...
codeparrot/github-code-clean
# Copyright (c) Twisted Matrix Laboratories. # See LICENSE for details. """ Tests for L{twisted.web.client.Agent} and related new client APIs. """ import zlib from io import BytesIO from zope.interface.verify import verifyObject from twisted.trial.unittest import TestCase from twisted.web import client, error, htt...
codeparrot/github-code-clean
""" Package resource API -------------------- A resource is a logical file contained within a package, or a logical subdirectory thereof. The package resource API expects resource names to have their path parts separated with ``/``, *not* whatever the local path separator is. Do not use os.path operations to manipul...
codeparrot/github-code-clean
# coding: utf-8 # Copyright (c) Pymatgen Development Team. # Distributed under the terms of the MIT License. """ This module defines the VaspInputSet abstract base class and a concrete implementation for the parameters developed and tested by the core team of pymatgen, including the Materials Virtual Lab, Materials Pr...
codeparrot/github-code-clean
""" TopicStore class. Part of the StoryTechnologies project. February 24, 2017 Brett Alistair Kromkamp (brett.kromkamp@gmail.com) """ from __future__ import annotations from collections import namedtuple from datetime import datetime from typing import Optional, List, Union, Dict, Tuple import psycopg2 # type: ign...
codeparrot/github-code-clean
# --------------------------------------------------------------------------------- # # ULTIMATELISTCTRL wxPython IMPLEMENTATION # Inspired by and heavily based on the wxWidgets C++ generic version of wxListCtrl. # # Andrea Gavana, @ 08 May 2009 # Latest Revision: 26 Dec 2012, 21.00 GMT # # # TODO List # # 1)...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- import time from openerp import api, fields, models, _ from openerp.osv import expression from openerp.exceptions import RedirectWarning, UserError from openerp.tools.misc import formatLang from openerp.tools import float_compare, float_is_zero from openerp.tools.safe_eval import safe_eval fro...
codeparrot/github-code-clean
# import matplotlib.pyplot as plt import numpy as np # for scheme in ['jet', 'terrain', 'RdYlGn']: # cm = plt.get_cmap(scheme) # np.set_printoptions(precision=5, threshold='nan', suppress=True, formatter={'float_kind': lambda x: '{:.4,},'.format(x)}) # print scheme, '=', cm(np.arange(256)) las_classes = np.ones((2...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'mainwindow.ui' # # Created by: PyQt5 UI code generator 5.8 # # WARNING! All changes made in this file will be lost! from PyQt5 import QtCore, QtGui, QtWidgets class Ui_MainWindow(object): def setupUi(self, MainWindow): MainWind...
codeparrot/github-code-clean
# Copyright 2009-2013 Canonical Ltd. This software is licensed under the # GNU Affero General Public License version 3 (see the file LICENSE). """Person interfaces.""" __metaclass__ = type __all__ = [ 'IAdminPeopleMergeSchema', 'IAdminTeamMergeSchema', 'ICanonicalSSOAPI', 'ICanonicalSSOApplication',...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- # Amara, universalsubtitles.org # # Copyright (C) 2013 Participatory Culture Foundation # # 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, either version 3 of the #...
codeparrot/github-code-clean
# -*- 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...
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
# -*- coding: utf-8 -*- from contextlib import contextmanager from datetime import datetime from functools import partial import ConfigParser import json import os import re import shutil import tempfile from backports.tempfile import TemporaryDirectory import fcntl import mock import pytest import six import yaml f...
codeparrot/github-code-clean
from datetime import datetime, timedelta import operator from textwrap import dedent from typing import Union import warnings import numpy as np from pandas._libs import algos as libalgos, index as libindex, lib import pandas._libs.join as libjoin from pandas._libs.lib import is_datetime_array from pandas._libs.tslib...
codeparrot/github-code-clean
import copy import math import pytz from datetime import datetime from fnmatch import fnmatch from mock import patch, call, MagicMock from django.test import TestCase from django.conf import settings from graphite.render.datalib import TimeSeries from graphite.render import functions from graphite.render.functions i...
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. # All Rights Reserved. # Copyright 2013 Red Hat, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # no...
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 # # 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...
codeparrot/github-code-clean
""" Extended docstrings for functions.py """ pi = r""" `\pi`, roughly equal to 3.141592654, represents the area of the unit circle, the half-period of trigonometric functions, and many other things in mathematics. Mpmath can evaluate `\pi` to arbitrary precision:: >>> from mpmath import * >>> mp.dps = 50; m...
codeparrot/github-code-clean
from .constants import Classref, Fieldref, Methodref, InterfaceMethodref, String, Integer, Long, Float, Double, Constant # From: https://en.wikipedia.org/wiki/Java_bytecode_instruction_listings # Reference" http://docs.oracle.com/javase/specs/jvms/se7/html/jvms-6.html#jvms-6.2 ########################################...
codeparrot/github-code-clean
# Copyright (c) 2006-2012 Mitch Garnaat http://garnaat.org/ # Copyright (c) 2010, Eucalyptus Systems, Inc. # Copyright (c) 2013 Amazon.com, Inc. or its affiliates. All Rights Reserved # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files ...
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
# -*- coding: utf-8 -*- from __future__ import unicode_literals import os import time import numpy as np import inspect import copy import matplotlib as mpl from .. import raycing from . import sources as rs from . import myopencl as mcl from .physconsts import PI2, CH, CHBAR, SQRT2PI from .materials import EmptyMate...
codeparrot/github-code-clean
from consts import * from data import * from utils import * from stream import * try: import Image except ImportError: from PIL import Image import struct try: import cStringIO as StringIO except ImportError: import StringIO class TagFactory(object): @classmethod def create(cls, type): ...
codeparrot/github-code-clean
from numpy import * import numpy as np # to help in transition from safe_pylab import * import matplotlib.pyplot as plt # transitioning... import glob,types from numpy.random import random from numpy import ma from numpy.linalg import norm import tempfile import pdb from scipy import interpolate from scipy.stats im...
codeparrot/github-code-clean
## 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 2 of the ## License, or (...
codeparrot/github-code-clean
#!/usr/bin/env python # SamplePattern.py # Shaped hem trousers # Swank-1870-M-T-1 # # This is a sample pattern design distributed as part of the tmtp # open fashion design project. It contains a design for one piece # of the back of a trousers, and will be expanded in the future. # # In order to allow designers to cont...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- # Resource object code # # Created: mar. oct. 27 02:25:46 2015 # by: The Resource Compiler for PyQt (Qt v4.8.4) # # WARNING! All changes made in this file will be lost! from PyQt4 import QtCore qt_resource_data = "\ \x00\x00\x03\x50\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49...
codeparrot/github-code-clean
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Bottle is a fast and simple micro-framework for small web applications. It offers request dispatching (Routes) with URL parameter support, templates, a built-in HTTP Server and adapters for many third party WSGI/HTTP-server and template engines - all in a single file an...
codeparrot/github-code-clean
""" Create SQL statements for QuerySets. The code in here encapsulates all of the SQL construction so that QuerySets themselves do not have to (and could be backed by things other than SQL databases). The abstraction barrier only works one way: this module has to know all about the internals of models in order to get ...
codeparrot/github-code-clean
""" This module contains dsolve() and different helper functions that it uses. dsolve() solves ordinary differential equations. See the docstring on the various functions for their uses. Note that partial differential equations support is in pde.py. Note that ode_hint() functions have docstrings describing their vari...
codeparrot/github-code-clean
# (c) 2012, Michael DeHaan <michael.dehaan@gmail.com> # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any lat...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- # (setq py-indent-offset 4) import string import re import sys import lilylib _ = lilylib._ NOT_SMART = "\n" + _ ("Not smart enough to convert %s.") + "\n" UPDATE_MANUALLY = _ ("Please refer to the manual for details, and update manually.") + "\n" FROM_TO = _ ("%s has been replaced by %s") ...
codeparrot/github-code-clean
#!/usr/bin/env python # # vim: sw=2 ts=2 sts=2 # # Copyright 2007 The Python-Twitter Developers # # 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
# Authors: Peter Prettenhofer <peter.prettenhofer@gmail.com> (main author) # Mathieu Blondel (partial_fit support) # # License: BSD 3 clause """Classification, regression and One-Class SVM using Stochastic Gradient Descent (SGD). """ import numpy as np import warnings from abc import ABCMeta, abstractmethod ...
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 versio...
codeparrot/github-code-clean
#!/usr/bin/python -u # Copyright (c) 2010-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 ap...
codeparrot/github-code-clean
# Copyright (c) 2013 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. # Notes: # # This is all roughly based on the Makefile system used by the Linux # kernel, but is a non-recursive make -- we put the entire dependency # graph in fr...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """Tests for Beautiful Soup's tree traversal methods. The tree traversal methods are the main advantage of using Beautiful Soup over just using a parser. Different parsers will build different Beautiful Soup trees given the same markup, but all Beautiful Soup trees can be traversed with the m...
codeparrot/github-code-clean
""" Test functions for linalg module """ from __future__ import division, absolute_import, print_function import os import sys import itertools import traceback import textwrap import subprocess import numpy as np from numpy import array, single, double, csingle, cdouble, dot, identity from numpy import multiply, at...
codeparrot/github-code-clean
from Tkinter import * from tkFileDialog import * import tkSimpleDialog import tkMessageBox from dataset import getSeparatorValue from dataset import getDecimalValue import Analysis import configuration import datetime import os import os.path import pandas as pd import dateutil columnSeparator = "|" filterSeparator = ...
codeparrot/github-code-clean
#!/usr/bin/python # -*- coding: utf-8 -*- """ Variable store/dictionarys for use in AC_tools Use help(<name of function>) to get details on a particular function. Notes - This code will be updated to use a user configuration approach (*.rc file) shortly """ # - Required modules: # I/O / Low level import re import o...
codeparrot/github-code-clean
from Plugins.Plugin import PluginDescriptor from Screens.Screen import Screen from Components.MenuList import MenuList from Components.Label import Label from Components.ActionMap import ActionMap, NumberActionMap from Components.Pixmap import Pixmap from Components.AVSwitch import AVSwitch from Components.ServiceEvent...
codeparrot/github-code-clean
## This file is part of Invenio. ## Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 CERN. ## ## 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 2 of the ## License, ...
codeparrot/github-code-clean
#!/usr/bin/python # # Copyright (C) 2010, 2011, 2012 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 version. # # ...
codeparrot/github-code-clean
# Copyright (c) 2012 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Xcode project file generator. This module is both an Xcode project file generator and a documentation of the Xcode project file format. Knowledge of the proje...
codeparrot/github-code-clean
#! /usr/bin/env python2 # -*- coding: utf-8 -*- # # This file is part of the Bacterial and Archaeal Genome Analyser # Copyright (C) 2015-16 David Williams # david.williams.at.liv.d-dub.org.uk # License GPLv3+: GNU GPL version 3 or later # This is free software: you are free to change and redistribute it # There is NO W...
codeparrot/github-code-clean
#!/usr/bin/python # # Copyright 2016 Red Hat | Ansible # 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': '1.1', 'status': ['prev...
codeparrot/github-code-clean
""" ============ Windows DACL ============ This salt utility contains objects and functions for setting permissions to objects in Windows. You can use the built in functions or access the objects directly to create your own custom functionality. There are two objects, Flags and Dacl. If you need access only to flags,...
codeparrot/github-code-clean
# 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.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
codeparrot/github-code-clean
from distutils.version import LooseVersion from datetime import date, datetime, timedelta import pytest from pandas.compat import range from pandas import compat import numpy as np from pandas.compat.numpy import np_datetime64_compat from pandas.core.series import Series from pandas._libs.tslibs import conversion f...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- from __future__ import print_function from datetime import datetime, timedelta import functools import itertools import numpy as np import numpy.ma as ma import pytest from pandas.compat import ( PY3, PY36, OrderedDict, is_platform_little_endian, lmap, long, lrange, lzip, range, zip)...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- # Author: Nic Wolfe <nic@wolfeden.ca> # URL: http://code.google.com/p/sickbeard/ # # This file is part of SickRage. # # SickRage 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 v...
codeparrot/github-code-clean
# cython: auto_cpdef=True, infer_types=True, language_level=3, py2_import=True # # Parser # from __future__ import absolute_import # This should be done automatically import cython cython.declare(Nodes=object, ExprNodes=object, EncodedString=object, BytesLiteral=object, StringEncoding=object, ...
codeparrot/github-code-clean
""" Classes for interpolating values. """ from __future__ import division, print_function, absolute_import __all__ = ['interp1d', 'interp2d', 'spline', 'spleval', 'splmake', 'spltopp', 'ppform', 'lagrange', 'PPoly', 'BPoly', 'NdPPoly', 'RegularGridInterpolator', 'interpn'] import itertools imp...
codeparrot/github-code-clean
"""Unit tests for the io module.""" # Tests of io are scattered over the test suite: # * test_bufio - tests file buffering # * test_memoryio - tests BytesIO and StringIO # * test_fileio - tests FileIO # * test_file - tests the file interface # * test_io - tests everything else in the io module # * test_univnewlines - ...
codeparrot/github-code-clean
"""Python wrappers around TensorFlow ops. This file is MACHINE GENERATED! Do not edit. """ import collections as _collections from google.protobuf import text_format as _text_format from tensorflow.core.framework import op_def_pb2 as _op_def_pb2 # Needed to trigger the call to _set_call_cpp_shape_fn. from tensorfl...
codeparrot/github-code-clean
#!/usr/bin/env python3 #------------------------------------------------------------------- # tarfile.py #------------------------------------------------------------------- # Copyright (C) 2002 Lars Gustaebel <lars@gustaebel.de> # All rights reserved. # # Permission is hereby granted, free of charge, to any pers...
codeparrot/github-code-clean
# ----------------------------------------------------------------------------- # ply: yacc.py # # Copyright (C) 2001-2015, # David M. Beazley (Dabeaz LLC) # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions a...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- # Copyright (c) 2017-2021 Richard Hull and contributors # See LICENSE.rst for details. """ Fixed-width font definitions. The following fonts are available: +-------------------+-------------------------------------------------+-------------------------------------------------------------------...
codeparrot/github-code-clean
## -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GN...
codeparrot/github-code-clean
# -*- coding: utf-8; -*- # # This file is part of Superdesk. # # Copyright 2013, 2014 Sourcefabric z.u. and contributors. # # For the full copyright and license information, please see the # AUTHORS and LICENSE files distributed with this source code, or # at https://www.sourcefabric.org/superdesk/license import os i...
codeparrot/github-code-clean
#!/usr/bin/env python # pylint: disable=R0902,R0913 # # A library that provides a Python interface to the Telegram Bot API # Copyright (C) 2015-2021 # Leandro Toledo de Souza <devs@python-telegram-bot.org> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser Pu...
codeparrot/github-code-clean
import re import sys import time import types import fcntl import random import datetime import commands import ErrorCode import broker_util import PandaSiteIDs from taskbuffer import ProcessGroups from dataservice import DataServiceUtils from dataservice.DDM import toa from config import panda_config from pandalogger...
codeparrot/github-code-clean
# Copyright 2010 OpenStack Foundation # Copyright 2012 University Of Minho # # 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....
codeparrot/github-code-clean
import numpy as np import pandas as pd import matplotlib as mpl import matplotlib.pyplot as plt import pytest import numpy.testing as npt from numpy.testing import assert_array_equal try: import pandas.testing as tm except ImportError: import pandas.util.testing as tm from .._core import categorical_order fro...
codeparrot/github-code-clean
# coding: utf-8 """ ASN.1 type classes for universal types. Exports the following items: - load() - Any() - Asn1Value() - BitString() - BMPString() - Boolean() - CharacterString() - Choice() - EmbeddedPdv() - Enumerated() - GeneralizedTime() - GeneralString() - GraphicString() - IA5String() - InstanceO...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- from __future__ import print_function from __future__ import absolute_import import os import sys import tempfile from itertools import groupby import numpy as np from numpy import rec as records from numpy import testing as npt import tables from tables import ( Col, StringCol, BoolCol, ...
codeparrot/github-code-clean
# Copyright 2015 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
codeparrot/github-code-clean
# $Id: states.py 7958 2016-07-28 21:52:14Z milde $ # Author: David Goodger <goodger@python.org> # Copyright: This module has been placed in the public domain. """ This is the ``docutils.parsers.rst.states`` module, the core of the reStructuredText parser. It defines the following: :Classes: - `RSTStateMachine`: ...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- # PLEASE DO NOT EDIT THIS FILE, IT IS GENERATED AND WILL BE OVERWRITTEN: # https://github.com/ccxt/ccxt/blob/master/CONTRIBUTING.md#how-to-contribute-code from ccxt.async_support.base.exchange import Exchange from ccxt.base.errors import ExchangeError from ccxt.base.errors import Authenticatio...
codeparrot/github-code-clean
<<<<<<< HEAD <<<<<<< HEAD """Concrete date/time and related types. See http://www.iana.org/time-zones/repository/tz-link.html for time zone and DST data sources. """ import time as _time import math as _math def _cmp(x, y): return 0 if x == y else 1 if x > y else -1 MINYEAR = 1 MAXYEAR = 9999 _MAXORDINAL = 3652...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- """ Created on Fri Dec 2 17:10:19 2016 @author: tkc """ import pandas as pd import numpy as np import shutil, sys, fileinput, os, math, re import matplotlib.pyplot as plt import struct from PIL import Image, ImageDraw, ImageFont # needed for jpg creation from matplotlib.backend...
codeparrot/github-code-clean
""" Author: Justin Cappos Start Date: Sept 1st, 2008 Description: The advertisement functionality for the node manager """ # needed for getruntime from repyportability import * # needed to convert keys to strings #begin include rsa.repy """ <Program Name> random.repy <Started> 2008-04-23 <Author> Modified...
codeparrot/github-code-clean
import sys from StringIO import StringIO from collections import OrderedDict from itertools import chain import numpy import networkx as nx from zope.interface import implements # pylint: disable-msg=E0611,F0401 from openmdao.main.mpiwrap import MPI, MPI_info, PETSc, get_norm, make_idx_array,\ ...
codeparrot/github-code-clean
# -*- encoding: utf-8 -*- """ Factory object creation for all CLI methods """ import datetime import json import logging import os import random import time from fauxfactory import ( gen_alphanumeric, gen_choice, gen_integer, gen_ipaddr, gen_mac, gen_netmask, gen_string, ) from os import c...
codeparrot/github-code-clean
import copy import csv import datetime import json import mock import re import urllib import pyquery from cStringIO import StringIO from nose.tools import eq_, ok_, assert_raises from nose.plugins.skip import SkipTest from django.test.client import RequestFactory from django.test.utils import override_settings from ...
codeparrot/github-code-clean
# 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...
codeparrot/github-code-clean
# Windows Azure Linux Agent # # Copyright 2018 Microsoft Corporation # # 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 ...
codeparrot/github-code-clean
#!/usr/bin/env python3 """ Smoketest.py: Regression testing utility for Graphyne. Multiprocessing wrapper for Smokest, allowing multiple simultaneous tests against different persistence types. """ from tkinter.test.runtktests import this_dir_path from Graphyne.DatabaseDrivers.DriverTermplate import linkTypes __au...
codeparrot/github-code-clean
""" This module contain solvers for all kinds of equations: - algebraic or transcendental, use solve() - recurrence, use rsolve() - differential, use dsolve() - nonlinear (numerically), use nsolve() (you will need a good starting point) """ from __future__ import print_function, division f...
codeparrot/github-code-clean
# -*- coding: utf-8 -*- { '# of International Staff': '# अन्तराष्ट्रिय स्टाफ', '# of National Staff': '# राष्ट्रिय स्टाफ', '# selected': '# छानियो', '%(app)s not installed. Ask the Server Administrator to install on Server.': '%(app)s इन्स्टल हुन सकेन । सर्भरलाई इन्स्टल गर्नको निम्ति सर्भरको एडमिनिस्ट्राटरलाई सोध्नुहोस...
codeparrot/github-code-clean
# Copyright (c) 2014, Fundacion Dr. Manuel Sadosky # All rights reserved. # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # 1. Redistributions of source code must retain the above copyright notice, this # list of condit...
codeparrot/github-code-clean