repo_name stringlengths 5 92 | path stringlengths 4 232 | copies stringclasses 19
values | size stringlengths 4 7 | content stringlengths 721 1.04M | license stringclasses 15
values | hash int64 -9,223,277,421,539,062,000 9,223,102,107B | line_mean float64 6.51 99.9 | line_max int64 15 997 | alpha_frac float64 0.25 0.97 | autogenerated bool 1
class |
|---|---|---|---|---|---|---|---|---|---|---|
PLyczkowski/Sticky-Keymap | 2.74/scripts/addons/io_anim_bvh/__init__.py | 1 | 8032 | # ##### BEGIN GPL LICENSE BLOCK #####
#
# 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.
#
# This program is distrib... | gpl-2.0 | 8,315,018,521,340,759,000 | 35.017937 | 117 | 0.54868 | false |
desihub/desimodel | py/desimodel/weather.py | 1 | 15591 | # See LICENSE.rst for BSD 3-clause license info
# -*- coding: utf-8 -*-
"""
desimodel.weather
=================
Model of the expected weather conditions at KPNO during the DESI survey.
To generate a random time series of expected FWHM seeing in arcsecs and
atmospheric transparency, use, for example::
n = 10000
... | bsd-3-clause | -3,878,208,059,081,789,000 | 35.174014 | 88 | 0.635944 | false |
taoliu/taolib | Scripts/kmeans2image.py | 1 | 1598 | #!/usr/bin/env python
# Time-stamp: <2009-04-14 14:07:21 Tao Liu>
import os
import sys
import re
from PIL import Image, ImageDraw
# ------------------------------------
# Main function
# ------------------------------------
help_message = """
Draw the K-means clustering result.
need 6 parameter: %s <kmeans_file> <li... | bsd-3-clause | -4,875,349,459,735,880,000 | 25.196721 | 127 | 0.530663 | false |
TripleSnail/blender-zombie | python/text.py | 1 | 1754 | # ##### BEGIN GPL LICENSE BLOCK #####
#
# 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.
#
# This program is distrib... | gpl-2.0 | 8,312,866,228,532,016,000 | 28.728814 | 76 | 0.676739 | false |
renyi/drum | drum/links/templatetags/drum_tags.py | 1 | 1472 | from __future__ import unicode_literals
from collections import defaultdict
from django.template.defaultfilters import timesince
from mezzanine import template
from mezzanine.generic.models import ThreadedComment
from drum.links.utils import order_by_score
from drum.links.models import LinkCategory
from drum.links.v... | bsd-2-clause | -4,074,832,187,691,731,000 | 25.763636 | 79 | 0.724185 | false |
gdsfactory/gdsfactory | pp/layers.py | 1 | 9564 | """A GDS layer is a tuple of two integers.
You can:
- Define your layers in a dataclass
- Load it from Klayout XML file (.lyp)
LayerSet adapted from phidl.device_layout
load_lyp, name_to_description, name_to_short_name adapted from phidl.utilities
preview_layerset adapted from phidl.geometry
"""
import pathlib
from ... | mit | 7,863,857,862,018,327,000 | 30.564356 | 88 | 0.603199 | false |
alissonperez/django-onmydesk | onmydesk/utils.py | 1 | 1501 | """Module with common utilities to this package"""
import re
from datetime import timedelta
import importlib
def my_import(class_name):
"""
Usage example::
Report = my_import('myclass.models.Report')
model_instance = Report()
model_instance.name = 'Test'
model_instance.save()... | mit | -7,885,954,554,795,849,000 | 26.290909 | 73 | 0.578281 | false |
bradallred/gemrb | gemrb/GUIScripts/iwd2/Abilities.py | 1 | 7433 | # GemRB - Infinity Engine Emulator
# Copyright (C) 2003 The GemRB Project
#
# 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... | gpl-2.0 | 7,460,413,711,233,489,000 | 26.428044 | 81 | 0.727297 | false |
Southpaw-TACTIC/Team | src/python/Lib/site-packages/pythonwin/pywin/tools/browseProjects.py | 1 | 8295 | import hierlist, string, regutil, os
import win32con, win32ui, win32api
import commctrl
from pywin.mfc import dialog
import glob
import pyclbr
import pywin.framework.scriptutils
import afxres
class HLIErrorItem(hierlist.HierListItem):
def __init__(self, text):
self.text = text
hierlist.HierListItem.__... | epl-1.0 | 5,805,571,004,573,647,000 | 30.276265 | 146 | 0.66522 | false |
Commonists/SurfaceImageContentGap | surfaceimagecontentgap/rc.py | 1 | 2812 | from argparse import ArgumentParser
import datetime
import time
from surfaceimagecontentgap.imagegap import isthereanimage
from surfaceimagecontentgap.bot import SurfaceContentGapBot
def last_rc_time(site):
"""Datetime of last change."""
rc = site.recentchanges()
last_rev = rc.next()
return datetime... | mit | 8,370,749,980,757,185,000 | 26.568627 | 74 | 0.558677 | false |
vitalyvolkov/fontbakery | bakery/project/views.py | 1 | 16523 | # coding: utf-8
# Copyright 2013 The Font Bakery 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 re... | apache-2.0 | 2,932,717,679,689,174,000 | 34.230277 | 129 | 0.629486 | false |
Purg/SMQTK | python/smqtk/bin/classifyFiles.py | 1 | 5843 | """
Based on an input, trained classifier configuration, classify a number of media
files, whose descriptor is computed by the configured descriptor generator.
Input files that classify as the given label are then output to standard out.
Thus, this script acts like a filter.
"""
import glob
import json
import logging
i... | bsd-3-clause | -9,202,389,211,392,059,000 | 33.169591 | 80 | 0.610303 | false |
bgris/ODL_bgris | lib/python3.5/site-packages/odl/util/graphics.py | 1 | 15419 | # Copyright 2014-2016 The ODL development group
#
# This file is part of ODL.
#
# ODL 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 later version.
#... | gpl-3.0 | -3,538,194,548,052,486,700 | 33.037528 | 79 | 0.560672 | false |
kylejusticemagnuson/pyti | tests/test_stochastic.py | 1 | 15612 | from __future__ import absolute_import
import unittest
import numpy as np
from tests.sample_data import SampleData
from pyti import stochastic
class TestStochastic(unittest.TestCase):
def setUp(self):
"""Create data to use for testing."""
self.data = SampleData().get_sample_close_data()
... | mit | 5,619,512,950,334,885,000 | 61.951613 | 83 | 0.711248 | false |
edcast-inc/edx-platform-edcast | common/djangoapps/student/tests/test_login.py | 1 | 25194 | '''
Tests for student activation and login
'''
import json
import unittest
from unittest import skip
from django.test import TestCase
from django.test.client import Client
from django.test.utils import override_settings
from django.conf import settings
from django.core.cache import cache
from django.core.urlresolvers i... | agpl-3.0 | 888,919,011,720,206,700 | 45.828996 | 134 | 0.645114 | false |
yantrabuddhi/blocos | tabs/UploadTab.py | 1 | 13455 | # -*- coding: utf-8 -*-
# Este arquivo é parte do programa Monitor
# Monitor é um software livre; você pode redistribui-lo e/ou
# modifica-lo dentro dos termos da Licença Pública Geral GNU como
# publicada pela Fundação do Software Livre (FSF); na versão 3 da
# Licença, ou (na sua opinião) qualquer versão.
#
# Este... | gpl-3.0 | -6,296,304,755,429,825,000 | 33.242347 | 127 | 0.554943 | false |
AnumSheraz/IP-Controlled-Robotic-Car | Manual-IP-Controlled-Robotic-Car/Code.py | 1 | 1696 |
import sys
from PyQt4 import QtGui, QtCore
import time, socket, json
from main import Ui_MainWindow
s=socket.socket(socket.AF_INET,socket.SOCK_DGRAM)
IP = "localhost"
PORT = 8001
class main_menu(QtGui.QMainWindow):
def __init__(self):
super(main_menu, self).__init__()
self.ui=Ui_MainWindow()
... | gpl-2.0 | 5,014,913,625,355,572,000 | 23.228571 | 49 | 0.504717 | false |
be-cloud-be/horizon-addons | horizon/school_evaluations/wizard/evaluation_summary.py | 1 | 3973 | # -*- encoding: utf-8 -*-
##############################################################################
#
# Copyright (c) 2015 be-cloud.be
# Jerome Sonnet <jerome.sonnet@be-cloud.be>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU ... | agpl-3.0 | 5,508,467,179,672,360,000 | 36.490566 | 184 | 0.558017 | false |
chen2aaron/SnirteneCodes | JustForFUN/v2ex_mission.py | 1 | 1598 | # -*- coding: utf-8 -*-
import re
USE_SOCKS_PROXY = 0
if USE_SOCKS_PROXY:
import requesocks as requests
else:
import requests
# import socks, socket
# socks.set_default_proxy(socks.SOCKS5, "127.0.0.1", 1080)
# socket.socket = socks.socksocket
username = 'x@gmail.com'
password = 'xyz'
host = 'http://www.v2ex.... | gpl-2.0 | -2,073,786,518,579,206,100 | 24.433333 | 103 | 0.625819 | false |
migihajami/memin | memin/frontend.py | 1 | 10715 | __author__ = 'algol'
import cherrypy
from jinja2 import Environment, PackageLoader
import memin.core as mc
from configparser import ConfigParser
class Menu:
def __init__(self):
self.menu = [
{'name': 'Главная', 'link': '/'},
{'name': 'Персоны', 'link': '/persons'},
{'n... | bsd-3-clause | -6,257,122,399,343,155,000 | 29.134286 | 87 | 0.526216 | false |
Roshan2017/spinnaker | testing/citest/tests/openstack_smoke_test.py | 1 | 9447 | # Copyright 2017 Veritas Technologies, LLC All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appli... | apache-2.0 | -574,020,269,942,373,200 | 34.784091 | 84 | 0.638615 | false |
raintank/graphite-api | setup.py | 1 | 2147 | # coding: utf-8
import sys
from setuptools import setup, find_packages
install_requires = [
'Flask',
'PyYAML',
'cairocffi',
'pyparsing>=1.5.7',
'pytz',
'six',
'tzlocal',
]
if sys.version_info < (2, 7):
install_requires.append('importlib')
install_requires.append('logutils')
in... | apache-2.0 | 5,227,318,412,880,639,000 | 30.101449 | 66 | 0.60671 | false |
chrplr/AIP2015 | resources/python-scripts/icons.py | 1 | 9336 | goicon=[
"32 32 5 1",
". c None",
"b c #008000",
"a c #00c000",
"# c #00ff00",
"c c #ffffc0",
"................................",
"................................",
"................................",
"................................",
"................................",
"..........#.....................",
"............ | gpl-2.0 | -6,271,612,860,441,996,000 | 32.106383 | 48 | 0.269173 | false |
MShel/ttw | listener/packets/udpPacket.py | 1 | 1408 | from listener.packets.abstractPacket import AbstractPacket
from struct import unpack
class UdpPacket(AbstractPacket):
UNPACK_FORMAT = '!HHHH'
UDP_HEADER_LENGTH = 8
PROTOCOL_NAME = 'UDP'
def __init__(self, binPacket: bytes, margin: int):
self.binPacket = binPacket
self.headerMa... | mit | 2,091,908,008,284,972,500 | 36.078947 | 119 | 0.651989 | false |
aerler/WRF-Tools | Python/wrfavg/wrfout_average.py | 1 | 79431 | '''
Created on 2013-09-28, revised 2014-06-17, added daily output 2020-05-04
A script to average WRF output; the default settings are meant for my 'fineIO' output configuration and
process the smaller diagnostic files.
The script can run in parallel mode, with each process averaging one filetype and domain, producing... | gpl-3.0 | 659,906,441,429,333,200 | 64.054054 | 196 | 0.6327 | false |
Aloomaio/googleads-python-lib | examples/ad_manager/v201808/creative_wrapper_service/update_creative_wrappers.py | 1 | 2747 | #!/usr/bin/env python
#
# 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 requir... | apache-2.0 | 8,009,690,733,829,738,000 | 36.630137 | 78 | 0.705497 | false |
icomms/wqmanager | apps/domain/models.py | 1 | 6972 | from django.contrib.auth.models import User
from django.contrib.contenttypes.models import ContentType
from django.contrib.contenttypes import generic
from django.db import models
from domain import Permissions
from wqm.models import WqmAuthority
from locations.models import LocationType
##############################... | bsd-3-clause | 1,128,780,121,399,136,400 | 44.575163 | 152 | 0.613884 | false |
yarikoptic/seaborn | seaborn/tests/test_algorithms.py | 1 | 6588 | import numpy as np
from scipy import stats
from six.moves import range
import numpy.testing as npt
from numpy.testing import assert_array_equal
import nose.tools
from nose.tools import assert_equal, raises
from .. import algorithms as algo
rs = np.random.RandomState(sum(map(ord, "test_algorithms")))
a_norm = rs.rand... | bsd-3-clause | -8,255,307,290,111,198,000 | 31.294118 | 77 | 0.615209 | false |
ArcherSys/ArcherSys | Lib/opcode.py | 1 | 16466 | <<<<<<< HEAD
<<<<<<< HEAD
"""
opcode module - potentially shared between dis and other modules which
operate on bytecodes (e.g. peephole optimizers).
"""
__all__ = ["cmp_op", "hasconst", "hasname", "hasjrel", "hasjabs",
"haslocal", "hascompare", "hasfree", "opname", "opmap",
"HAVE_ARGUMENT", "EX... | mit | -3,256,446,462,933,646,000 | 26.171617 | 80 | 0.635005 | false |
benagricola/exabgp | lib/exabgp/bgp/message/update/nlri/evpn/multicast.py | 1 | 2426 | """
multicast.py
Created by Thomas Morin on 2014-06-23.
Copyright (c) 2014-2015 Orange. All rights reserved.
"""
from exabgp.protocol.ip import IP
from exabgp.bgp.message.update.nlri.qualifier import RouteDistinguisher
from exabgp.bgp.message.update.nlri.qualifier import EthernetTag
from exabgp.bgp.message.update.nl... | bsd-3-clause | 8,568,785,827,975,385,000 | 25.659341 | 86 | 0.54122 | false |
emoronayuso/beeton | asterisk-bee/asteriskbee/api_status/scripts_graficas/recoge_marcas_graficas.py | 1 | 2307 | #!/usr/bin/python
import matplotlib.pyplot as plt
import numpy as np
#import calendar
from datetime import datetime
from django.conf import settings
settings.configure()
import os
#para conexion con la bases de datos de beeton (asteriskbee)
import sqlite3 as dbapi
##Directorio de la aplicaion
### STATIC_ROOT = '/va... | gpl-3.0 | 2,008,526,283,982,816,800 | 24.633333 | 330 | 0.688773 | false |
suutari-ai/shoop | shuup_tests/core/test_rounding.py | 3 | 5376 | # -*- coding: utf-8 -*-
# This file is part of Shuup.
#
# Copyright (c) 2012-2017, Shoop Commerce Ltd. All rights reserved.
#
# This source code is licensed under the OSL-3.0 license found in the
# LICENSE file in the root directory of this source tree.
import pytest
from decimal import Decimal
from shuup.core.models... | agpl-3.0 | 2,804,682,339,294,635,500 | 35.571429 | 114 | 0.670387 | false |
diedthreetimes/VCrash | pybindgen-0.15.0.795/pybindgen/typehandlers/inttype.py | 1 | 29684 | # docstrings not needed here (the type handler interfaces are fully
# documented in base.py)
# pylint: disable-msg=C0111
import struct
assert struct.calcsize('i') == 4 # assumption is made that sizeof(int) == 4 for all platforms pybindgen runs on
from base import ReturnValue, Parameter, PointerParameter, PointerRetu... | gpl-2.0 | 8,058,617,483,119,672,000 | 41.164773 | 131 | 0.638997 | false |
SSSD/sssd | src/tests/intg/test_files_provider.py | 1 | 37497 | #
# SSSD files domain tests
#
# Copyright (c) 2016 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 3 of the License, or
# (at your option) any later version.
#
# T... | gpl-3.0 | -4,390,004,282,251,433,000 | 28.501967 | 79 | 0.61973 | false |
persandstrom/home-assistant | homeassistant/components/sensor/netatmo_public.py | 1 | 4390 | """
Support for Sensors using public Netatmo data.
For more details about this platform, please refer to the documentation at
https://home-assistant.io/components/sensor.netatmo_public/.
"""
from datetime import timedelta
import logging
import voluptuous as vol
from homeassistant.components.sensor import PLATFORM_SC... | apache-2.0 | -397,387,515,900,327,800 | 30.134752 | 75 | 0.591116 | false |
ryfeus/lambda-packs | pytorch/source/torch/nn/parallel/deprecated/distributed_cpu.py | 1 | 4290 | import torch
from torch._utils import _flatten_dense_tensors, _unflatten_dense_tensors
import torch.distributed.deprecated as dist
from torch.nn.modules import Module
from collections import defaultdict
from torch.autograd import Variable
import torch.utils.hooks
class DistributedDataParallelCPU(Module):
r"""Impl... | mit | -3,092,668,904,383,977,500 | 39.093458 | 94 | 0.648485 | false |
geky/pyOCD | pyOCD/target/target_lpc4330.py | 1 | 2872 | """
mbed CMSIS-DAP debugger
Copyright (c) 2006-2015 ARM Limited
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 ... | apache-2.0 | -5,108,212,287,236,866,000 | 38.342466 | 121 | 0.68071 | false |
opennode/nodeconductor-assembly-waldur | src/waldur_slurm/apps.py | 1 | 2931 | from django.apps import AppConfig
from django.db.models import signals
class SlurmConfig(AppConfig):
name = 'waldur_slurm'
verbose_name = 'SLURM'
service_name = 'SLURM'
def ready(self):
from waldur_core.quotas.fields import QuotaField, CounterQuotaField
from waldur_core.structure impo... | mit | -963,469,003,066,524,500 | 34.743902 | 90 | 0.606619 | false |
addisonElliott/SmartShopTouchScreen | Windows/ExpirationBox_ui.py | 1 | 8236 | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'ExpirationBox.ui'
#
# Created by: PyQt5 UI code generator 5.7.1
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_ExpirationBox(object):
def setupUi(self, ExpirationBox):
... | agpl-3.0 | -5,871,618,067,304,195,000 | 43.76087 | 119 | 0.662943 | false |
goddardl/gaffer | apps/gui/gui-1.py | 1 | 5810 | ##########################################################################
#
# Copyright (c) 2011-2012, John Haddon. All rights reserved.
# Copyright (c) 2011-2013, Image Engine Design Inc. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted ... | bsd-3-clause | -2,702,933,978,917,300,000 | 36.973856 | 154 | 0.704819 | false |
eonpatapon/contrail-controller | src/container/kube-manager/kube_manager/common/args.py | 1 | 7928 | #
# Copyright (c) 2016 Juniper Networks, Inc. All rights reserved.
#
import sys
import argparse
from vnc_api.vnc_api import *
from pysandesh.sandesh_base import Sandesh, SandeshSystem, SandeshConfig
from pysandesh.gen_py.sandesh.ttypes import SandeshLevel
from sandesh_common.vns.constants import (HttpPortKubeManager,... | apache-2.0 | 1,123,368,809,067,095,000 | 33.92511 | 78 | 0.611882 | false |
yousseb/django_pytds | tests/runtests.py | 1 | 14761 | #!/usr/bin/env python
import logging
import os
import shutil
import subprocess
import sys
import tempfile
import warnings
import django
from django import contrib
from django.utils._os import upath
from django.utils import six
CONTRIB_MODULE_PATH = 'django.contrib'
TEST_TEMPLATE_DIR = 'templates'
DJANGO_RUNTESTS_DI... | mit | -2,331,804,514,326,747,000 | 33.488318 | 148 | 0.622316 | false |
MaStanford/AnglishWordbook | Anglish/SyncWikia.py | 1 | 4522 | __author__ = 'm.stanford'
import string
from socket import error as SocketError
import json, httplib
STARTING_PAGE = 72;
ENDING_PAGE = 98;
invalidWords = ["un-English", "Anglish/English", "attested", "unattested", "Class"]
delimiter = "\'\'\'"
wierdfunkInSomeWords = ["\'\' \'\'\'", "\'\'\',", '\'\'\'\'\'', '\"\'\'']... | apache-2.0 | -7,765,113,058,141,094,000 | 28.363636 | 156 | 0.570102 | false |
jsirois/pants | src/python/pants/backend/python/goals/setup_py.py | 1 | 37779 | # Copyright 2019 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
import enum
import io
import itertools
import logging
import os
import pickle
from abc import ABC, abstractmethod
from collections import abc, defaultdict
from dataclasses import dataclass... | apache-2.0 | -2,219,731,043,789,042,400 | 39.710129 | 123 | 0.672675 | false |
azumimuo/family-xbmc-addon | plugin.video.bubbles/resources/lib/externals/hachoir/hachoir_parser/image/bmp.py | 1 | 6874 | """
Microsoft Bitmap picture parser.
- file extension: ".bmp"
Author: Victor Stinner
Creation: 16 december 2005
"""
from resources.lib.externals.hachoir.hachoir_parser import Parser
from resources.lib.externals.hachoir.hachoir_core.field import (FieldSet,
UInt8, UInt16, UInt32, Bits,
String, RawBytes, Enum,
... | gpl-2.0 | 6,517,626,528,385,999,000 | 34.251282 | 104 | 0.586267 | false |
urbn/kombu | t/unit/utils/test_functional.py | 1 | 9030 | from __future__ import absolute_import, unicode_literals
import pickle
import pytest
from itertools import count
from case import Mock, mock, skip
from kombu.five import (
items, PY3,
)
from kombu.utils import functional as utils
from kombu.utils.functional import (
ChannelPromise, LRUCache, fxrange, fxran... | bsd-3-clause | 7,319,310,932,030,114,000 | 25.715976 | 76 | 0.531561 | false |
msullivan/advent-of-code | 2020/17a.py | 1 | 1655 | #!/usr/bin/env python3
import copy
from collections import defaultdict
import sys
import re
def extract(s):
return [int(x) for x in re.findall(r'-?\d+', s)]
def first(grid, x, y, dx, dy):
while True:
x += dx
y += dy
if x < 0 or x >= len(grid[0]) or y < 0 or y >= len(grid):
... | mit | 4,169,982,579,958,940,000 | 24.859375 | 108 | 0.467674 | false |
asamerh4/mesos | support/push-commits.py | 1 | 4982 | #!/usr/bin/env python
#
# 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
# "... | apache-2.0 | -8,114,206,134,426,273,000 | 30.732484 | 80 | 0.545163 | false |
ATSTI/administra | open_myplace/boleto/boleto.py | 1 | 4123 | # -*- coding: utf-8 -*-
#################################################################################
# #
# Copyright (C) 2011 Vinicius Dittgen - PROGE, Leonardo Santagada - PROGE #
# ... | gpl-2.0 | -8,144,782,495,104,841,000 | 50.4375 | 223 | 0.531227 | false |
quixey/scrapy-cluster | crawler/tests/tests_online.py | 1 | 3938 | '''
Online link spider test
'''
import unittest
from unittest import TestCase
import time
import sys
from os import path
sys.path.append(path.dirname(path.dirname(path.abspath(__file__))))
import scrapy
import redis
from redis.exceptions import ConnectionError
import json
import threading, time
from crawling.spiders.... | mit | 2,532,433,231,757,263,000 | 33.243478 | 79 | 0.623667 | false |
yfauser/maxwindownotify | setup.py | 1 | 1252 | from setuptools import setup
import io
def read(*filenames, **kwargs):
encoding = kwargs.get('encoding', 'utf-8')
sep = kwargs.get('sep', '\n')
buf = []
for filename in filenames:
with io.open(filename, encoding=encoding) as f:
buf.append(f.read())
return sep.join(buf)
long_des... | mit | 2,280,797,815,360,075,000 | 33.777778 | 147 | 0.654153 | false |
hazybluedot/indie_helper | util.py | 1 | 2278 | import requests
import bleach
import sys
if sys.version < '3':
from urlparse import urlparse
text_type = unicode
text_types = [ str, unicode ]
binary_type = str
else:
from urllib.parse import urlparse
text_type = str
text_types = [ str ]
binary_type = bytes
def is_url(url):
try:
... | gpl-3.0 | 7,210,100,983,337,184,000 | 28.205128 | 124 | 0.611501 | false |
jenshenrik/destiny-trader | destiny.py | 1 | 3112 | import sys
import re
TYPE_BATTLEFIELD = "Battlefield"
def print_usage():
print("""
Star Wars: Destiny trade list builder
Usage:
$>python destiny.py <target-file>
where <target-file> is the text-file to process.
This file should be generated by logging into swdestiny.com, going to 'My coll... | gpl-3.0 | 8,064,256,526,302,666,000 | 24.719008 | 90 | 0.593509 | false |
bfarr/kombine | examples/kepler/correlated_likelihood.py | 1 | 2577 | import numpy as np
import numpy.linalg as nl
import numpy.random as nr
import rv_model as rv
import scipy.linalg as sl
import scipy.stats as ss
def generate_covariance(ts, sigma, tau):
r"""Generates a covariance matrix according to an
squared-exponential autocovariance
.. math::
\left\lang... | mit | -2,341,818,866,456,086,000 | 27.955056 | 212 | 0.498642 | false |
FrancescoRizzi/AWSomesauce | articles/BAS4-pws/custauth/custauth.py | 1 | 18186 | #!/usr/bin/env python
import os
import json
import StringIO
from contextlib import closing
import re
import time
import pprint
import boto3
from boto3.session import Session
import botocore
import jwt
from cryptography.x509 import load_pem_x509_certificate
from cryptography.hazmat.backends import default_backend
#... | mit | 3,410,329,240,392,538,600 | 38.027897 | 158 | 0.600352 | false |
CTSRD-SOAAP/chromium-42.0.2311.135 | native_client/buildbot/buildbot_selector.py | 1 | 18629 | #!/usr/bin/python
# Copyright (c) 2012 The Native Client Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import json
import os
import subprocess
import sys
sys.path.append(os.path.join(os.path.dirname(__file__), '..'))
import pynacl.p... | bsd-3-clause | 1,836,903,225,074,248,400 | 38.890792 | 83 | 0.617854 | false |
omemo/python-omemo | src/omemo/liteprekeystore.py | 1 | 2577 | # -*- coding: utf-8 -*-
#
# Copyright 2015 Tarek Galal <tare2.galal@gmail.com>
#
# This file is part of Gajim-OMEMO plugin.
#
# The Gajim-OMEMO plugin is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by the Free
# Software Foundation, either ver... | gpl-3.0 | 4,332,987,200,107,825,700 | 34.791667 | 80 | 0.648428 | false |
nitmir/django-cas-server | cas_server/admin.py | 1 | 6813 | # This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See the GNU General Public License version 3 for
# more details.
#
# You should have received a copy of the GNU General Public License... | gpl-3.0 | 5,034,193,972,385,483,000 | 32.895522 | 97 | 0.693821 | false |
classner/fertilized-devtools | binding_generator/ordered_set.py | 1 | 1936 | # See http://code.activestate.com/recipes/576694/.
import collections
class OrderedSet(collections.MutableSet):
def __init__(self, iterable=None):
self.end = end = []
end += [None, end, end] # sentinel node for doubly linked list
self.map = {} # key --> [key, pre... | bsd-2-clause | -3,656,923,377,244,034,600 | 25.520548 | 78 | 0.497934 | false |
googleapis/googleapis-gen | google/ads/googleads/v7/googleads-py/google/ads/googleads/v7/services/types/feed_item_target_service.py | 1 | 5926 | # -*- coding: utf-8 -*-
# Copyright 2020 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... | apache-2.0 | 2,457,467,938,042,463,700 | 32.862857 | 128 | 0.662842 | false |
ifaoe/daisi-tk | daisi_images.py | 1 | 5255 | #!/usr/bin/python3
import logging
import psycopg2
from argparse import ArgumentParser
from gdal_tif2geo import process
import multiprocessing
import subprocess
from joblib import Parallel, delayed
from math import ceil
import tempfile
import os
logging.basicConfig(level=logging.INFO)
logger = logging.getLogger(__name... | gpl-2.0 | 3,208,551,945,965,820,400 | 52.622449 | 150 | 0.654234 | false |
fnoorian/Free-buck-boost | drivers/json_server.py | 1 | 1329 | from werkzeug.wrappers import Request, Response
from werkzeug.serving import run_simple
# this use package json-rpc (not jsonrpc!)
from jsonrpc import JSONRPCResponseManager, dispatcher
from drivers.boost_driver import FCCBoostDriver
from drivers.buck_driver import FCCBuckDriver, FCCMPPTDriver
from drivers.mi... | bsd-2-clause | -2,386,581,520,251,007,000 | 32.973684 | 64 | 0.734387 | false |
googleinterns/cabby | cabby/model/datasets.py | 1 | 4391 | # coding=utf-8
# Copyright 2020 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 ... | apache-2.0 | 5,425,208,701,046,947,000 | 37.858407 | 102 | 0.675473 | false |
0sw4l/villas-de-san-pablo | apps/utils/views.py | 1 | 1899 | from django.contrib.auth.mixins import LoginRequiredMixin
from django.views.generic import CreateView
from django.views.generic import ListView
from django.views.generic import TemplateView
from django.views.generic import UpdateView, DetailView
from apps.utils.shortcuts import get_object_or_none
class BaseListView(L... | mit | -484,693,667,937,133,630 | 27.772727 | 83 | 0.699315 | false |
tekton/DocuCanvas | accounts/migrations/0007_auto__add_recordpermission__add_unique_recordpermission_contentType_us.py | 1 | 8125 | # -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'RecordPermission'
db.create_table(u'accounts_recordpermission', (
(u'id', self.g... | gpl-3.0 | -734,166,846,986,416,400 | 72.872727 | 187 | 0.571323 | false |
Jumpscale/jumpscale_portal8 | apps/portalbase/AYS81/.macros/wiki/aysservice/3_aysservice.py | 1 | 2580 | from collections import OrderedDict
def main(j, args, params, tags, tasklet):
try:
role = args.getTag('aysrole')
name = args.getTag('aysname')
ayspath = args.getTag('ayspath') or ''
repo = j.atyourservice.repoGet(ayspath)
service = repo.serviceGet(role, name, die=False)
... | apache-2.0 | 1,651,762,895,446,285,600 | 41.295082 | 123 | 0.526357 | false |
DailyActie/Surrogate-Model | 01-codes/scikit-learn-master/sklearn/externals/funcsigs.py | 1 | 29802 | # Copyright 2001-2013 Python Software Foundation; All Rights Reserved
"""Function signature objects for callables
Back port of Python 3.3's function signature tools from the inspect module,
modified to be compatible with Python 2.6, 2.7 and 3.2+.
"""
from __future__ import absolute_import, division, print_function
im... | mit | -1,135,423,231,880,870,100 | 35.432763 | 84 | 0.537648 | false |
cockroachdb/examples-orms | python/django/cockroach_example/settings.py | 1 | 3362 | """
Django settings for cockroach_example project.
Generated by 'django-admin startproject' using Django 2.2.6.
For more information on this file, see
https://docs.djangoproject.com/en/2.2/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/2.2/ref/settings/
"""
im... | apache-2.0 | -6,756,807,042,726,074,000 | 24.278195 | 91 | 0.678168 | false |
jbzdak/data-base-checker | bazydanych2/settingsdev.py | 1 | 1181 |
from bazydanych2.settingsshared import *
DEBUG=True
TEMPLATE_DEBUG=True
STATIC_ROOT = '/tmp/staticfiles'
LOGGING = {
'version': 1,
'disable_existing_loggers': False,
'filters': {
'require_debug_false': {
'()': 'django.utils.log.RequireDebugFalse'
},
'require_debug_tru... | gpl-3.0 | -979,873,808,556,966,700 | 21.730769 | 66 | 0.524979 | false |
ted-gould/nova | nova/tests/unit/compute/test_compute_mgr.py | 1 | 197801 | # 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... | apache-2.0 | 3,144,236,380,760,686,000 | 47.303053 | 79 | 0.589229 | false |
rcocetta/kano-profile | kano_profile/apps.py | 1 | 3777 | #!/usr/bin/env python
# apps.py
#
# Copyright (C) 2014, 2015 Kano Computing Ltd.
# License: http://www.gnu.org/licenses/gpl-2.0.txt GNU General Public License v2
#
import os
from kano.utils import read_json, write_json, get_date_now, ensure_dir, \
chown_path, run_print_output_error
from kano.logging import logge... | gpl-2.0 | -652,654,093,269,193,900 | 25.787234 | 80 | 0.639396 | false |
sbkro/alc | src/tests/unit/test_formatter.py | 1 | 2802 | # -*- coding:utf-8 -*-
import calendar
from mock import patch
from datetime import datetime
from alc.formatter import CalendarFormatter
class TestDatetime:
'''
Unit test for *CalendarFormatter.datetime()*.
'''
def test_default(self):
'''
:type: normal
:case: *datetime_format... | bsd-3-clause | 5,329,593,480,155,695,000 | 25.186916 | 66 | 0.570307 | false |
mF2C/COMPSs | tests/sources/python/1_decorator_mpi/src/modules/testMpiDecorator.py | 1 | 4569 | #!/usr/bin/python
# -*- coding: utf-8 -*-
"""
PyCOMPSs Testbench Tasks
========================
"""
# Imports
import unittest
import os
from pycompss.api.task import task
from pycompss.api.parameter import *
from pycompss.api.api import compss_barrier, compss_open, compss_wait_on
from pycompss.api.mpi import mpi
fr... | apache-2.0 | 5,971,662,384,461,707,000 | 27.735849 | 123 | 0.64084 | false |
s34rching/python_classes | tests/test_contact_data.py | 1 | 2053 | import re
import random
def test_contact_data_from_home_page(app):
r_index = random.randrange(len(app.contact.get_contact_list()))
data_from_home_page = app.contact.get_contact_list()[r_index]
data_from_edit_page = app.contact.get_contact_info_from_edit_page(r_index)
assert data_from_home_page.firstna... | apache-2.0 | 5,947,474,044,754,886,000 | 50.35 | 131 | 0.656113 | false |
phbradley/tcr-dist | tcrdist/parse_cdr3.py | 1 | 4891 | import logging
logger = logging.getLogger('parse_cdr3.py')
from .all_genes import all_genes, gap_character
def get_cdr3_and_j_match_counts( organism, ab, qseq, j_gene, min_min_j_matchlen = 3,
extended_cdr3 = False ):
#fasta = all_fasta[organism]
jg = all_genes[organism][j_gene... | mit | -8,223,407,647,342,972,000 | 34.963235 | 114 | 0.584339 | false |
QISKit/qiskit-sdk-py | test/python/test_qasm_parser.py | 1 | 2809 | # -*- coding: utf-8 -*-
# This code is part of Qiskit.
#
# (C) Copyright IBM 2017.
#
# This code is licensed under the Apache License, Version 2.0. You may
# obtain a copy of this license in the LICENSE.txt file in the root directory
# of this source tree or at http://www.apache.org/licenses/LICENSE-2.0.
#
# Any modif... | apache-2.0 | -5,361,655,547,522,064,000 | 31.287356 | 81 | 0.629405 | false |
Azure/azure-sdk-for-python | sdk/network/azure-mgmt-network/azure/mgmt/network/v2020_07_01/aio/operations/_public_ip_prefixes_operations.py | 1 | 27147 | # 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 ... | mit | 5,796,781,428,933,566,000 | 48.811009 | 200 | 0.644565 | false |
DevangS/CoralNet | accounts/migrations/0004_create_user_called_alleviate.py | 1 | 5492 | # -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import DataMigration
from django.db import models
from django.conf import settings
class Migration(DataMigration):
# Create a dummy user called "Alleviate".
# This is the user under which Alleviate-accepted annotations
# will be... | bsd-2-clause | -8,000,994,628,860,161,000 | 53.376238 | 182 | 0.545157 | false |
tuanvu216/udacity-course | intro_to_machine_learning/lesson/lesson_14_evaluation_metrics/evaluate_poi_identifier.py | 1 | 2588 | #!/usr/bin/python
"""
starter code for the evaluation mini-project
start by copying your trained/tested POI identifier from
that you built in the validation mini-project
the second step toward building your POI identifier!
start by loading/formatting the data
"""
import pickle
import sys
sys.p... | mit | -3,788,225,604,616,323,000 | 34.260274 | 180 | 0.721445 | false |
mitmedialab/MediaCloud-Web-Tools | server/util/request.py | 1 | 3666 | import logging
import os
from functools import wraps
from flask import jsonify, request
from mediacloud.error import MCException
logger = logging.getLogger(__name__)
def validate_params_exist(form, params):
for param in params:
if param not in form:
raise ValueError('Missing required value f... | apache-2.0 | -5,131,921,134,876,014,000 | 30.603448 | 99 | 0.621386 | false |
iwschris/ezodf2 | tests/test_pages.py | 1 | 3894 | #!/usr/bin/env python
#coding:utf-8
# Purpose: test spreadpage body
# Created: 29.01.2011
# Copyright (C) 2011, Manfred Moitzi
# License: MIT
from __future__ import unicode_literals, print_function, division
__author__ = "mozman <mozman@gmx.at>"
# Standard Library
import unittest
# trusted or separately t... | mit | -2,706,917,590,960,068,000 | 28.186047 | 79 | 0.592193 | false |
cbrucks/Federated_Python-Swiftclient | swiftclient/contrib/federated/protocols/rax.py | 1 | 2519 | import urllib
import urllib2
import json
import getpass
import BaseHTTPServer
import os
import webbrowser
from swiftclient.contrib.federated import federated_exceptions, federated_utils
import ssl
## Sends the authentication request to the IdP along
# @param idpEndpoint The IdP address
# @param idpRequest The authenti... | apache-2.0 | 9,062,573,529,326,963,000 | 37.166667 | 137 | 0.663358 | false |
NaturalHistoryMuseum/inselect | inselect/gui/views/boxes/box_item.py | 1 | 8872 | import sys
from itertools import chain
from PyQt5.QtCore import Qt, QRect, QRectF
from PyQt5.QtGui import QPen
from PyQt5.QtWidgets import QGraphicsItem, QGraphicsRectItem
from inselect.lib.utils import debug_print
from inselect.gui.colours import colour_scheme_choice
from inselect.gui.utils import painter_state
fr... | bsd-3-clause | -3,026,487,980,262,549,000 | 32.73384 | 118 | 0.593102 | false |
ragupta-git/ImcSdk | imcsdk/mometa/huu/HuuFirmwareCatalogComponent.py | 1 | 4134 | """This module contains the general information for HuuFirmwareCatalogComponent ManagedObject."""
from ...imcmo import ManagedObject
from ...imccoremeta import MoPropertyMeta, MoMeta
from ...imcmeta import VersionMeta
class HuuFirmwareCatalogComponentConsts:
pass
class HuuFirmwareCatalogComponent(ManagedObject... | apache-2.0 | 3,600,132,035,256,602,000 | 50.037037 | 217 | 0.604983 | false |
rouault/Quantum-GIS | tests/src/python/test_qgsserver_wms_getfeatureinfo.py | 1 | 17012 | # -*- coding: utf-8 -*-
"""QGIS Unit tests for QgsServer GetFeatureInfo WMS.
From build dir, run: ctest -R PyQgsServerWMSGetFeatureInfo -V
.. note:: 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; ... | gpl-2.0 | 1,467,075,829,748,212,500 | 57.439863 | 236 | 0.499353 | false |
oppia/oppia-ml | core/domain/remote_access_services.py | 1 | 4226 | # coding: utf-8
#
# Copyright 2017 The Oppia 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 requi... | apache-2.0 | 7,458,767,984,366,599,000 | 30.537313 | 79 | 0.6938 | false |
google/clif | examples/wrapfunc/python/default_args_test.py | 1 | 1214 | # Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,... | apache-2.0 | -2,786,963,431,532,792,000 | 30.947368 | 74 | 0.73888 | false |
carolFrohlich/nipype | nipype/interfaces/mrtrix3/preprocess.py | 2 | 7501 | # emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*-
# vi: set ft=python sts=4 ts=4 sw=4 et:
# -*- coding: utf-8 -*-
"""
Change directory to provide relative paths for doctests
>>> import os
>>> filepath = os.path.dirname(os.path.realpath(__file__ ))
>>> datadir = os.path.realpath(... | bsd-3-clause | -1,332,776,987,818,199,800 | 36.318408 | 87 | 0.614985 | false |
sam-m888/gramps | gramps/plugins/drawreport/ancestortree.py | 1 | 42337 | # Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2000-2007 Donald N. Allingham
# Copyright (C) 2007-2012 Brian G. Matherly
# Copyright (C) 2010 Jakim Friant
# Copyright (C) 2014 Paul Franklin
# Copyright (C) 2010-2015 Craig J. Anderson
#
# This program is free software; you can redistrib... | gpl-2.0 | 6,894,781,434,802,397,000 | 37.038634 | 79 | 0.546709 | false |
lgfausak/sqlbridge | sqlbridge/twisted/dbengine.py | 1 | 6399 | #!/usr/bin/env python
###############################################################################
##
## Copyright (C) 2014 Greg Fausak
##
## 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... | apache-2.0 | 2,118,608,279,539,695,600 | 42.828767 | 135 | 0.606188 | false |
cjaymes/pyscap | src/scap/model/ocil_2_0/ItemBaseType.py | 1 | 1052 | # Copyright 2016 Casey Jaymes
# This file is part of PySCAP.
#
# PySCAP 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 later version.
#
# PySCAP is ... | gpl-3.0 | 7,049,207,792,901,553,000 | 34.066667 | 96 | 0.680608 | false |
mancoast/CPythonPyc_test | fail/311_test_funcattrs.py | 1 | 9974 | from test import support
import types
import unittest
class FuncAttrsTest(unittest.TestCase):
def setUp(self):
class F:
def a(self):
pass
def b():
return 3
self.fi = F()
self.F = F
self.b = b
def cannot_set_attr(self, obj, name, v... | gpl-3.0 | 3,026,376,331,994,264,000 | 35.137681 | 84 | 0.579707 | false |
daniel1yuan/Persist | Persist/webapp/views.py | 1 | 6162 | from django.shortcuts import redirect,render
from django.http import Http404, JsonResponse, HttpResponseForbidden, HttpResponse
from django.contrib.auth import authenticate, login, logout
from webapp.models import User, Customer, Habit
from django.core import serializers
from django.views.decorators.csrf import csrf_ex... | mit | 303,794,903,503,346,800 | 31.431579 | 188 | 0.693281 | false |
alertedsnake/pycrust | pycrust/__init__.py | 1 | 5061 | """
Pycrust
A collection of CherryPy extensions
See also the following submodules:
pycrust.auth
pycrust.saplugin
pycrust.satool
pycrust.tools
"""
__author__ = 'Michael Stella <pycrust@thismetalsky.org>'
__version__ = '1.0.0'
import inspect, logging, os, sys
import cherrypy
import codecs
class Ba... | mit | 8,430,111,610,056,274,000 | 31.031646 | 107 | 0.610354 | false |
ayseyo/oclapi | django-nonrel/ocl/oclapi/settings/common.py | 1 | 10523 | import os
from configurations import Configuration
BASE_DIR = os.path.dirname(os.path.dirname(__file__))
class Common(Configuration):
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ADMINS = (
('Jon Payne', 'paynejd@gmail.com'),
('PK Shiu', 'pk@pkshiu.com'),
)
MANAGERS = ADMINS
DEFAULT... | mpl-2.0 | -5,339,695,786,148,565,000 | 35.922807 | 104 | 0.615699 | false |
stuart-knock/tvb-framework | tvb_test/adapters/visualizers/eegmonitor_test.py | 1 | 4412 | # -*- coding: utf-8 -*-
#
#
# TheVirtualBrain-Framework Package. This package holds all Data Management, and
# Web-UI helpful to run brain-simulations. To use it, you also need do download
# TheVirtualBrain-Scientific Package (for simulators). See content of the
# documentation-folder for more details. See also http:/... | gpl-2.0 | -6,400,699,188,668,995,000 | 41.028571 | 103 | 0.694923 | false |
lilydjwg/you-get | src/you_get/extractors/netease.py | 1 | 9738 | #!/usr/bin/env python
from json import loads
import hashlib
import base64
import os
import binascii
try:
from Crypto.Cipher import AES
import xml.etree.ElementTree as ET
has_crypto = True
except ImportError:
has_crypto = False
from ..common import *
from ..extractor import VideoExtractor
from ..util ... | mit | -3,439,591,755,401,592,300 | 35.548872 | 162 | 0.518103 | false |
jlaunonen/kirppu | kirppu/views/csv_utils.py | 1 | 1469 | # -*- coding: utf-8 -*-
import functools
import html
import io
from urllib.parse import quote
from django.conf import settings
from django.http import HttpResponse, StreamingHttpResponse
def strip_generator(fn):
@functools.wraps(fn)
def inner(output, event, generator=False):
if generator:
... | mit | 4,648,484,677,998,597,000 | 28.979592 | 105 | 0.605174 | false |
bossjones/scarlett | scarlett/listener/gstlistenerfsm.py | 1 | 17131 | # -*- coding: UTF-8 -*-
import scarlett
import pygst
pygst.require('0.10')
import gobject
gobject.threads_init()
import dbus
import dbus.service
# TODO: Figure out if we need this or not, re dbus threading
# from dbus.mainloop.glib import DBusGMainLoop
# dbus_loop = DBusGMainLoop(set_as_default=True)
# dsession = Se... | mit | -6,935,489,890,912,596,000 | 32.855731 | 104 | 0.566692 | false |
wbrp/dnsimple-zoneimport | setup.py | 1 | 1349 | # -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from dnsimple_zoneimport import meta
f = open('requirements.txt', 'r')
lines = f.readlines()
requirements = [l.strip().strip('\n') for l in lines if l.strip() and not l.strip().startswith('#')]
readme = open('README.rst').read()
setup(name='dnsimple... | mit | -6,276,857,376,273,034,000 | 32.725 | 100 | 0.594514 | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.