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 |
|---|---|---|---|---|---|---|---|---|---|---|
atzengin/OCC | oc-utils/python/modtool/code_generator.py | 1 | 2298 | #
# Copyright 2013 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
# GNU Radio 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, or (at your option)
# any later version.
#
#... | gpl-3.0 | -1,651,171,289,484,127,200 | 41.555556 | 76 | 0.681027 | false |
mostaphaRoudsari/Honeybee | src/Honeybee_AskMe.py | 1 | 1992 | #
# Honeybee: A Plugin for Environmental Analysis (GPL) started by Mostapha Sadeghipour Roudsari
#
# This file is part of Honeybee.
#
# Copyright (c) 2013-2020, Mostapha Sadeghipour Roudsari <mostapha@ladybug.tools>
# Honeybee is free software; you can redistribute it and/or modify
# it under the terms of the GNU G... | gpl-3.0 | -3,768,216,618,678,705,700 | 35.218182 | 100 | 0.744478 | false |
wdv4758h/ZipPy | edu.uci.python.benchmark/src/benchmarks/euler31-timed.py | 1 | 1614 | #runas solve()
#unittest.skip recursive generator
#pythran export solve()
# 01/08/14 modified for benchmarking by Wei Zhang
import sys, time
COINS = [1, 2, 5, 10, 20, 50, 100, 200]
# test
def _sum(iterable):
sum = None
for i in iterable:
if sum is None:
sum = i
else:
su... | bsd-3-clause | 7,452,297,059,408,330,000 | 23.830769 | 115 | 0.576208 | false |
longde123/MultiversePlatform | lib/IPCE/Lib/ctypes.py | 1 | 5974 | # Copyright (c) 2006 Seo Sanghyeon
# 2006-06-08 sanxiyn Created
# 2006-06-11 sanxiyn Implemented .value on primitive types
# 2006-11-02 sanxiyn Support for multiple signatures
__all__ = [
'c_int', 'c_float', 'c_double', 'c_char_p', 'c_void_p',
'LibraryLoader', 'CDLL', 'cdll',
'byref', 'sizeof'
]
# --... | mit | -2,151,948,963,422,639,000 | 25.789238 | 70 | 0.571142 | false |
bm5w/second_dataS | test_quicksort.py | 1 | 1531 | import pytest
from quicksort import quicksort
def test_quicksort_simple():
input = [1, 3, 2]
assert quicksort(input) == [1, 2, 3]
def test_quicksort():
input = [54, 26, 93, 17, 71, 31, 44, 55, 20]
assert quicksort(input) == [17, 20, 26, 31, 44, 54, 55, 71, 93]
def test_quicksort_duplicate():
... | mit | -4,190,833,842,785,767,400 | 20.56338 | 79 | 0.613978 | false |
avsm/lifedb-server | client/python/lifedb/tests/client.py | 1 | 5909 | # -*- coding: utf-8 -*-
#
# Copyright (C) 2007 Christopher Lenz
# All rights reserved.
#
# This software is licensed as described in the file COPYING, which
# you should have received as part of this distribution.
import doctest
import os
import unittest
import StringIO
import time
import tempfile
from lifedb import ... | gpl-2.0 | 5,814,957,335,077,162,000 | 37.875 | 100 | 0.651379 | false |
bergolho1337/URI-Online-Judge | Basicos/Python/1061/main.py | 1 | 1292 | # -*- coding: utf-8 -*-
def converteString (dia, hora):
evento = []
# Parse do dia
num = dia[4:6]
evento.append(int(num))
# Parse da hora
num = hora[0:2]
evento.append(int(num))
# Parse dos minutos
num = hora[5:7]
evento.append(int(num))
# Parse dos segundos
num = hora[1... | gpl-2.0 | -1,258,978,114,268,866,600 | 25.387755 | 78 | 0.629257 | false |
google/material-design-icons | update/venv/lib/python3.9/site-packages/fontTools/varLib/plot.py | 5 | 4153 | """Visualize DesignSpaceDocument and resulting VariationModel."""
from fontTools.varLib.models import VariationModel, supportScalar
from fontTools.designspaceLib import DesignSpaceDocument
from matplotlib import pyplot
from mpl_toolkits.mplot3d import axes3d
from itertools import cycle
import math
import logging
impor... | apache-2.0 | -5,397,906,847,771,724,000 | 23.868263 | 80 | 0.642427 | false |
inonit/django-chemtrails | tests/testapp/migrations/0005_guild.py | 1 | 1061 | # -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-05-10 13:14
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('testapp', '0004_book_view_book_permission'),
]
ope... | mit | 6,104,085,431,111,180,000 | 34.366667 | 144 | 0.600377 | false |
alfred82santa/tarrabme2 | src/orgs/models.py | 1 | 1856 | from django.db import models
from common.models import CommonModel, AbstractContact, AbstractAddress
from django.contrib.auth.models import Group
from imagekit.models import ProcessedImageField, ImageSpecField
from imagekit.processors import ResizeToFill
class Organization(CommonModel):
name = models.CharField(max... | gpl-3.0 | -9,086,944,784,570,360,000 | 34.692308 | 77 | 0.634698 | false |
anneline/Bika-LIMS | bika/lims/utils/__init__.py | 1 | 13899 | from time import time
from AccessControl import ModuleSecurityInfo, allow_module
from bika.lims import logger
from bika.lims.browser import BrowserView
from DateTime import DateTime
from email import Encoders
from email.MIMEBase import MIMEBase
from plone.memoize import ram
from plone.registry.interfaces import IRegist... | agpl-3.0 | -5,184,133,056,224,156,000 | 29.818182 | 86 | 0.630189 | false |
zmarvel/slowboy | slowboy/util.py | 1 | 1753 |
import abc
from collections import namedtuple
Op = namedtuple('Op', ['function', 'cycles', 'description'])
class ClockListener(metaclass=abc.ABCMeta):
@abc.abstractmethod
def notify(self, clock: int, cycles: int):
"""Notify the listener that the clock has advanced.
:param clock: The new valu... | mit | 8,089,310,398,789,706,000 | 24.405797 | 75 | 0.590416 | false |
koreiklein/fantasia | ui/render/gl/distances.py | 1 | 1104 | # Copyright (C) 2013 Korei Klein <korei.klein1@gmail.com>
# Constants for gl rendering of basic are collected here.
from ui.render.gl import colors
epsilon = 0.0001
divider_spacing = 15.0
notThickness = 22.0
notShiftThickness = notThickness + 21.0
# Amount by which to shift the value contained inside a Not.
notShi... | gpl-2.0 | -6,752,107,023,383,802,000 | 19.444444 | 64 | 0.764493 | false |
shakfu/start-vm | default/bin/normalize.py | 1 | 1259 | #!/usr/bin/env python
import hashlib
import os
import sys
from datetime import datetime
HASH = hashlib.md5(str(datetime.now())).hexdigest()
def normalize(path, file_func=None, dir_func=None):
''' recursive normalization of directory and file names
applies the following changes to directory and filenames... | mit | -1,232,118,386,050,333,700 | 23.211538 | 65 | 0.597299 | false |
luci/luci-py | appengine/components/components/auth/change_log_test.py | 2 | 45674 | #!/usr/bin/env vpython
# Copyright 2014 The LUCI Authors. All rights reserved.
# Use of this source code is governed under the Apache License, Version 2.0
# that can be found in the LICENSE file.
import datetime
import sys
import unittest
from test_support import test_env
test_env.setup_test_env()
from google.appeng... | apache-2.0 | -6,992,933,365,418,927,000 | 38.238832 | 80 | 0.593073 | false |
HydrelioxGitHub/PiDDL | ZTPAGE.py | 1 | 2847 | # coding: utf-8
from urllib2 import urlopen
import urllib2
import bs4 as BeautifulSoup
class ZTPage:
def __init__(self, url):
self.url = url
self.update()
def update(self):
self.update_content()
self.parse_type()
self.parse_infos()
self.parse_links()
def ... | gpl-2.0 | 8,344,752,789,403,362,000 | 32.892857 | 95 | 0.556024 | false |
darknao/piOClock | ssd1351.py | 1 | 13500 | #!/bin/env python
# -*- coding: UTF-8 -*-
# ----------------------------------------------------------------------
# ssd1351.py from https://github.com/guyc/py-gaugette
# ported by Jason Porritt,
# and reworked by darknao,
# based on original work by Guy Carpenter for display.py
#
# This library works with
# Adafruit... | gpl-3.0 | 4,144,339,368,829,440,500 | 32.039216 | 96 | 0.548368 | false |
bnx05/pytest-selenium | test_parameters.py | 1 | 2603 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import pytest
import time
from selenium import webdriver
sample_email_address = "demo@engagespark.com"
sample_password = "Password123"
email_addresses = ["invalid_email", "another_invalid_email@", "not_another_invalid_email@blah"]
passwords = ["weak_password", "generic_p... | mit | -6,535,209,611,040,000,000 | 36.724638 | 96 | 0.717633 | false |
DonaldTrumpHasTinyHands/tiny_hands_pac | documents_gallery/models.py | 1 | 4091 | from django.db import models
from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger
from wagtail.wagtailcore.fields import RichTextField
from wagtail.wagtailcore.models import Page
from wagtail.wagtailadmin.edit_handlers import FieldPanel, MultiFieldPanel
from wagtail.wagtaildocs.models import Docume... | mit | 3,715,756,117,222,630,000 | 29.088235 | 104 | 0.676363 | false |
mrocklin/into | into/backends/sql_csv.py | 1 | 2811 |
from ..regex import RegexDispatcher
from ..append import append
from .csv import CSV
import os
import datashape
import sqlalchemy
import subprocess
copy_command = RegexDispatcher('copy_command')
execute_copy = RegexDispatcher('execute_copy')
@copy_command.register('.*sqlite')
def copy_sqlite(dialect, tbl, csv):
... | bsd-3-clause | -432,463,007,566,880,260 | 27.683673 | 82 | 0.630736 | false |
blenderben/lolstatbot | lolstatbot.py | 1 | 22559 | # Leauge of Legends Statistics Chat Bot
# A chat bot written in Python that provides match statistics right to your Twitch chat.
# 2015 Benjamin Chu - https://github.com/blenderben
import socket # imports module allowing connection to IRC
import threading # imports module allowing timing functions
import requests # im... | mit | 362,198,703,597,034,500 | 37.894828 | 164 | 0.675074 | false |
pacpac1992/mymockup | src/widgets/tab.py | 1 | 3754 | #!/usr/bin/python
# -*- coding: utf-8 -*-
import wx
import wx.lib.ogl as ogl
class Tab_dialog(wx.Dialog):
def __init__(self, parent, title):
super(Tab_dialog, self).__init__(parent, title=title,size=(410,220))
self.parent = parent
self.nombre = wx.TextCtrl(self,-1, pos=(10,10), size=(200,30),style=wx.TE_P... | mit | 5,063,618,514,684,932,000 | 23.86755 | 98 | 0.633724 | false |
Azure/azure-sdk-for-python | sdk/network/azure-mgmt-network/azure/mgmt/network/v2020_08_01/operations/_vpn_site_link_connections_operations.py | 1 | 5309 | # 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 | -8,327,537,274,828,321,000 | 46.401786 | 238 | 0.667922 | false |
caesar2164/edx-platform | lms/djangoapps/lti_provider/tests/test_tasks.py | 1 | 4437 | """
Tests for the LTI outcome service handlers, both in outcomes.py and in tasks.py
"""
import unittest
import ddt
from django.test import TestCase
from mock import patch, MagicMock
from student.tests.factories import UserFactory
from lti_provider.models import GradedAssignment, LtiConsumer, OutcomeService
import lti... | agpl-3.0 | 1,854,020,058,025,303,800 | 31.386861 | 87 | 0.608294 | false |
vegeclic/django-regularcom | blog/migrations/0001_initial.py | 1 | 14127 | # -*- 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 'TaggedItem'
db.create_table('blog_taggeditem', (
('id', self.gf('django.db.model... | agpl-3.0 | -4,488,898,404,940,486,700 | 65.328638 | 216 | 0.590784 | false |
Ultimaker/Cura | cura/XRayPass.py | 1 | 1577 | # Copyright (c) 2018 Ultimaker B.V.
# Cura is released under the terms of the LGPLv3 or higher.
import os.path
from UM.Resources import Resources
from UM.Application import Application
from UM.PluginRegistry import PluginRegistry
from UM.View.RenderPass import RenderPass
from UM.View.RenderBatch import RenderBatch
f... | lgpl-3.0 | -1,777,091,487,277,248,500 | 38.425 | 147 | 0.715916 | false |
the-nick-of-time/DnD | DnD/modules/resourceModule.py | 1 | 2471 | import tkinter as tk
from typing import Union
import lib.components as gui
import lib.resourceLib as res
import lib.settingsLib as settings
class ResourceDisplay(gui.Section):
"""Displays a resource like sorcery points or Hit Dice."""
def __init__(self, container: Union[tk.BaseWidget, tk.Tk], resource: res.... | gpl-2.0 | 771,843,469,293,149,600 | 34.811594 | 93 | 0.613112 | false |
lptorres/noah-inasafe | web_api/third_party/simplejson/decoder.py | 1 | 14670 | """Implementation of JSONDecoder
"""
from __future__ import absolute_import
import re
import sys
import struct
from .compat import fromhex, b, u, text_type, binary_type, PY3, unichr
from .scanner import make_scanner, JSONDecodeError
def _import_c_scanstring():
try:
from ._speedups import scanstr... | gpl-3.0 | 8,479,624,750,722,993,000 | 35.712082 | 79 | 0.519632 | false |
miaoski/bsideslv-plc-home | hmi.py | 1 | 1699 | # -*- coding: utf8 -*-
# This trivial HMI is decoupled from ModBus server
import gevent
from flask import Flask, render_template
from flask_sockets import Sockets
from pymodbus.client.sync import ModbusTcpClient
from time import sleep
import sys
app = Flask(__name__)
sockets = Sockets(app)
try:
myip = sys.argv[1... | gpl-2.0 | 4,138,471,727,828,687,000 | 23.623188 | 84 | 0.608005 | false |
houshengbo/nova_vmware_compute_driver | nova/virt/hyperv/vmops.py | 1 | 25971 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2012 Cloudbase Solutions Srl
# 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.ap... | apache-2.0 | -4,034,157,555,488,214,000 | 42.141196 | 79 | 0.576643 | false |
edx/course-discovery | course_discovery/apps/course_metadata/tests/test_emails.py | 1 | 14576 | import datetime
import re
from django.conf import settings
from django.contrib.auth.models import Group
from django.core import mail
from django.test import TestCase
from opaque_keys.edx.keys import CourseKey
from testfixtures import LogCapture, StringComparison
from course_discovery.apps.core.tests.factories import ... | agpl-3.0 | 4,705,774,580,766,771,000 | 39.94382 | 118 | 0.593235 | false |
mganeva/mantid | qt/applications/workbench/workbench/widgets/plotselector/presenter.py | 1 | 15293 | # Mantid Repository : https://github.com/mantidproject/mantid
#
# Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
# NScD Oak Ridge National Laboratory, European Spallation Source
# & Institut Laue - Langevin
# SPDX - License - Identifier: GPL - 3.0 +
# This file is part of the mantid workbench.... | gpl-3.0 | 4,486,501,413,745,917,000 | 36.760494 | 86 | 0.589028 | false |
DailyActie/Surrogate-Model | surrogate/sampling/samLatinHypercube.py | 1 | 8477 | # MIT License
#
# Copyright (c) 2016 Daily Actie
#
# 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 without limitation the rights
# to use, copy, modify, merge, ... | mit | 210,019,104,960,525,800 | 33.044177 | 99 | 0.572018 | false |
pyannote/pyannote-parser | tests/test_repere.py | 1 | 2075 | #!/usr/bin/env python
# encoding: utf-8
# The MIT License (MIT)
# Copyright (c) 2014-2015 CNRS
# 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 without limita... | mit | 1,854,699,619,890,575,400 | 31.920635 | 79 | 0.729508 | false |
Rdbaker/Mealbound | tests/models/test_transactions.py | 1 | 4543 | """Test the Transaction models."""
from unittest.mock import patch
import pytest
from ceraon.models.transactions import Transaction
@pytest.mark.usefixtures('db')
class TestTransaction:
"""Transaction tests."""
def test_get_by_id(self, meal, host, guest):
"""Get Transaction by id."""
transa... | bsd-3-clause | 5,709,859,063,645,114,000 | 41.064815 | 80 | 0.657495 | false |
xkmato/casepro | casepro/urls.py | 1 | 1472 | from __future__ import absolute_import, unicode_literals
from django.conf import settings
from django.conf.urls import include, url
from django.views import static
from casepro.backend import get_backend
from casepro.utils.views import PartialTemplate
urlpatterns = [
url(r'', include('casepro.cases.urls')),
... | bsd-3-clause | 4,833,736,216,706,264,000 | 36.74359 | 113 | 0.657609 | false |
wangkua1/sportvu | sportvu/detection_from_raw_pred.py | 1 | 3391 | """detection_from_raw_pred.py
* not super useful, a simple script that plots a) raw pred, b) gt pnr, c) detector output
at 1 single setting
Usage:
detection_from_raw_pred.py <fold_index> <f_data_config> <f_model_config> <f_detect_config> --train
Arguments:
Example:
"""
from __future__ import absolute_import
from ... | mit | 2,246,855,696,715,281,700 | 36.274725 | 111 | 0.648186 | false |
ptisserand/ansible | lib/ansible/modules/cloud/amazon/cloudfront_distribution.py | 1 | 85955 | #!/usr/bin/python
# Copyright (c) 2017 Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
ANSIBLE_METADATA = {'metadata_version': '1.1',
'status': ['preview'],
'supported_by': 'community'}
DOCUMENTATION = '''
---
module... | gpl-3.0 | 7,483,290,099,521,737,000 | 42.302267 | 159 | 0.610645 | false |
40223232/w16b_test | wsgi.py | 1 | 27797 | #@+leo-ver=5-thin
#@+node:2014fall.20141212095015.1775: * @file wsgi.py
# coding=utf-8
# 上面的程式內容編碼必須在程式的第一或者第二行才會有作用
################# (1) 模組導入區
# 導入 cherrypy 模組, 為了在 OpenShift 平台上使用 cherrypy 模組, 必須透過 setup.py 安裝
#@@language python
#@@tabwidth -4
#@+<<declarations>>
#@+node:2014fall.20141212095015.1776: ** <<declar... | gpl-3.0 | 421,274,124,816,849,400 | 29.535904 | 137 | 0.554152 | false |
DailyActie/Surrogate-Model | 00-courses/operators_as _functions.py | 1 | 1783 | # MIT License
#
# Copyright (c) 2016 Daily Actie
#
# 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 without limitation the rights
# to use, copy, modify, merge, ... | mit | 2,027,015,203,623,779,800 | 33.288462 | 80 | 0.692653 | false |
Unode/firefox_decrypt | tests/simpletap/__init__.py | 1 | 3764 | """
Test Anything Protocol extension to Python's unit testing framework
This module contains TAPTestRunner and TAPTestResult which are used to produce
a test report in a TAP compatible format. All remaining functionality comes
from Python's own unittest module.
The core of the tests does not need any change and is pu... | gpl-3.0 | 7,653,470,926,933,786,000 | 34.847619 | 107 | 0.688895 | false |
iwm911/plaso | plaso/parsers/plist_plugins/softwareupdate_test.py | 1 | 2465 | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright 2014 The Plaso Project Authors.
# Please see the AUTHORS file for details on individual authors.
#
# 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 L... | apache-2.0 | -6,657,414,589,122,883,000 | 36.923077 | 74 | 0.721704 | false |
NeerajM999/recap-python | LearnPython/data_structures/binary_tree.py | 1 | 1761 | class Node:
def __init__(self, value):
self.value = value
self.left = None
self.right = None
class BinaryTree(object):
def __init__(self, root_val):
self.root = Node(root_val)
def preorder_traversal(self, start, traversal):
""" Root -> left -> right """
if... | gpl-3.0 | 1,749,836,215,305,637,600 | 27.885246 | 75 | 0.571266 | false |
kret0s/gnuhealth-live | tryton/server/trytond-3.8.3/trytond/model/fields/one2one.py | 1 | 2080 | # This file is part of Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms.
from types import NoneType
from trytond.model.fields.field import Field
from trytond.model.fields.many2many import Many2Many
from trytond.pool import Pool
class One2One(Many... | gpl-3.0 | 4,749,240,343,853,297,000 | 32.015873 | 72 | 0.546635 | false |
Metonimie/Beaglebone | programs/server.py | 1 | 3147 | #!/usr/bin/env python
"""
A very simple server in python
used to control gpio pins on the beaglebone black.
The server listens for POST requests on port
6410. It has no security at all, which means
that it accepts post-data from everyone.
Send a GET request::
curl http://localhost
Send a POST request::
curl -... | gpl-3.0 | 3,281,151,376,845,631,500 | 28.688679 | 77 | 0.571973 | false |
arbrandes/edx-configuration | playbooks/roles/supervisor/files/pre_supervisor_checks.py | 1 | 12593 | import argparse
import boto.ec2
from boto.utils import get_instance_metadata, get_instance_identity
from boto.exception import AWSConnectionError
import hipchat
import os
import subprocess
import traceback
import socket
import time
# Services that should be checked for migrations.
MIGRATION_COMMANDS = {
'lms':... | agpl-3.0 | -2,843,304,026,179,480,000 | 45.640741 | 152 | 0.615262 | false |
cyanogen/uchroma | uchroma/traits.py | 1 | 11759 | #
# uchroma - Copyright (C) 2021 Stefanie Kondik
#
# This program 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, version 3.
#
# This program is distributed in the hope that it will be useful, but
# WIT... | lgpl-3.0 | 468,926,082,809,482,900 | 28.619647 | 97 | 0.615188 | false |
cardmagic/PyAMF | pyamf/adapters/_django_db_models_base.py | 1 | 8476 | # Copyright (c) 2007-2009 The PyAMF Project.
# See LICENSE.txt for details.
"""
`django.db.models` adapter module.
:see: `Django Project <http://www.djangoproject.com>`_
:since: 0.4.1
"""
from django.db.models.base import Model
from django.db.models import fields
from django.db.models.fields import related, files
... | mit | -6,217,738,496,913,844,000 | 28.430556 | 91 | 0.61975 | false |
CSC-IT-Center-for-Science/pouta-blueprints | pebbles/tests/test_docker_driver.py | 1 | 32367 | import json
import logging
import docker.errors
import pebbles.drivers.provisioning.docker_driver as docker_driver
from pebbles.tests.base import BaseTestCase
from pebbles.drivers.provisioning.docker_driver import NAMESPACE_CPU, NAMESPACE_GPU
from pebbles.drivers.provisioning.docker_driver import DD_STATE_ACTIVE, DD_ST... | mit | -5,674,086,952,452,258,000 | 38.043426 | 154 | 0.586987 | false |
ICOS-Carbon-Portal/data | src/main/python/update-restheart/Restheart.py | 1 | 2242 | import requests
class Restheart(object):
def __init__(self):
# self._baseUrl = 'http://127.0.0.1:8088/db/' # localhost
self._baseUrl = 'https://restheart.icos-cp.eu/db/' # production
self._verfify = True if self._baseUrl.__contains__('restheart') else False
def get_records_to_update(self, op, pagesize, coll... | gpl-3.0 | 5,153,336,162,370,622,000 | 37.655172 | 189 | 0.650758 | false |
domecraft/Games | RPG/classes.py | 1 | 3530 | class character:
def __init__(self, name, gender ,health, race, role, status, strength, defense, magic, bounty, income, reputation):
self.name = name
self.health = health
self.status = status
self.strength = strength
self.defense = defense
self.race = race
sel... | gpl-2.0 | 3,359,393,522,367,290,000 | 29.964912 | 119 | 0.545326 | false |
fbergmann/libSEDML | examples/python/create_sedml.py | 1 | 5521 | #!/usr/bin/env python
##
## @file create_sedml.py
## @brief cerates a SED-ML document.
## @author Frank T. Bergmann
##
## <!--------------------------------------------------------------------------
## This file is part of libSEDML. Please visit http://sed-ml.org for more
## information about SEDML, and the la... | bsd-2-clause | 3,096,274,935,878,346,000 | 32.05988 | 119 | 0.685926 | false |
molmod/yaff | yaff/pes/colvar.py | 1 | 13249 | # -*- coding: utf-8 -*-
# YAFF is yet another force-field code.
# Copyright (C) 2011 Toon Verstraelen <Toon.Verstraelen@UGent.be>,
# Louis Vanduyfhuys <Louis.Vanduyfhuys@UGent.be>, Center for Molecular Modeling
# (CMM), Ghent University, Ghent, Belgium; all rights reserved unless otherwise
# stated.
#
# This file is pa... | gpl-3.0 | -3,113,228,627,627,625,000 | 37.853372 | 102 | 0.611669 | false |
russorat/savage-leads | api/models/lead.py | 1 | 2649 | from elasticsearch import Elasticsearch,RequestsHttpConnection,NotFoundError
from flask import url_for
import config
import json
class Lead(object):
es = Elasticsearch(config.ES_HOSTS,connection_class=RequestsHttpConnection)
@staticmethod
def create_lead(lead_data):
try:
results = Lead.es.create(index... | apache-2.0 | -1,660,902,958,443,782,400 | 29.102273 | 86 | 0.559079 | false |
openstack/dragonflow | dragonflow/tests/unit/test_port_behind_port.py | 1 | 2387 | # 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 | 8,434,192,210,710,150,000 | 40.155172 | 78 | 0.584416 | false |
jaantollander/CrowdDynamics | crowddynamics/core/tests/test_interactions_benchmark.py | 1 | 1239 | import numpy as np
import pytest
from crowddynamics.core.interactions import agent_agent_block_list
from crowddynamics.core.vector2D import unit_vector
from crowddynamics.simulation.agents import Agents, Circular, ThreeCircle, \
AgentGroup
def attributes():
orientation = np.random.uniform(-np.pi, np.pi)
... | gpl-3.0 | 4,276,068,190,012,276,700 | 36.545455 | 80 | 0.684423 | false |
myshkov/bnn-analysis | models/bbb_sampler.py | 1 | 4851 | """
This module implements Bayes By Backprop -based sampler for NNs.
http://jmlr.org/proceedings/papers/v37/blundell15.pdf
"""
import numpy as np
from keras.models import Sequential
from keras.layers.core import Activation
from keras import backend as K
from keras.engine.topology import Layer
from sampler import Samp... | mit | -8,254,993,371,662,850,000 | 35.201493 | 111 | 0.556999 | false |
felixbr/nosql-rest-preprocessor | nosql_rest_preprocessor/models.py | 1 | 5131 | from __future__ import absolute_import, unicode_literals, print_function, division
from nosql_rest_preprocessor import exceptions
from nosql_rest_preprocessor.utils import non_mutating
class BaseModel(object):
required_attributes = set()
optional_attributes = None
immutable_attributes = set()
priv... | mit | 7,771,158,724,342,860,000 | 33.213333 | 161 | 0.524069 | false |
juliakreger/bifrost | playbooks/library/os_ironic_node.py | 1 | 12262 | #!/usr/bin/python
# coding: utf-8 -*-
# (c) 2015, Hewlett-Packard Development Company, L.P.
#
# This module 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 optio... | apache-2.0 | -5,918,725,627,129,297,000 | 35.933735 | 79 | 0.592399 | false |
BetterWorks/pysaml2 | src/saml2/client.py | 1 | 42487 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (C) 2009-2011 Umeå University
#
# 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... | bsd-2-clause | 4,292,489,896,724,211,000 | 36.235758 | 85 | 0.535612 | false |
math-a3k/django-ai | tests/test_models/migrations/0011_add_is_inferred_and_minor_tweaks.py | 1 | 2196 | # -*- coding: utf-8 -*-
# Generated by Django 1.11.5 on 2017-12-20 15:34
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('test_models', '0010_myunsupervisedlearningtechnique'),
]
operations = [
mig... | lgpl-3.0 | -7,274,611,177,119,370 | 33.857143 | 64 | 0.536885 | false |
Makeystreet/makeystreet | woot/apps/catalog/views/review.py | 1 | 5983 | from django.conf import settings
from django.core.urlresolvers import reverse
from django.http import HttpResponseRedirect, Http404
from django.shortcuts import render
from django.utils import timezone
from woot.apps.catalog.forms import CreateProductReviewForm,\
CreateShopReviewForm, CreateSpaceReviewForm
from wo... | apache-2.0 | 661,690,713,215,756,200 | 33.188571 | 77 | 0.563095 | false |
semplea/characters-meta | python/alchemy/examples/alchemy_vision_v1.py | 1 | 1466 | import json
from os.path import join, dirname
from watson_developer_cloud import AlchemyVisionV1
alchemy_vision = AlchemyVisionV1(api_key='c851400276c1acbd020210847f8677e6d1577c26')
# Face recognition
with open(join(dirname(__file__), '../resources/face.jpg'), 'rb') as image_file:
print(json.dumps(alchemy_vision... | mit | 1,583,828,267,179,628,300 | 47.866667 | 106 | 0.71487 | false |
mmclenna/engine | sky/tools/create_ios_sdk.py | 1 | 1820 | #!/usr/bin/env python
# Copyright 2016 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.
import argparse
import subprocess
import shutil
import sys
import os
def main():
parser = argparse.ArgumentParser(description='Crea... | bsd-3-clause | 4,522,966,620,628,158,000 | 26.575758 | 77 | 0.697802 | false |
gpg/gpgme | lang/python/tests/final.py | 1 | 1048 | #!/usr/bin/env python
# Copyright (C) 2016 g10 Code GmbH
#
# This file is part of GPGME.
#
# GPGME 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... | lgpl-2.1 | 4,358,481,701,361,559,000 | 31.75 | 79 | 0.745229 | false |
calinerd/AWS | LAMBDA/Lambda_AutoUpdate_SecurityGroup_to_Allow_inbound_All_CloudFront_IPs_443.py | 1 | 6268 | '''
Copyright 2015 Amazon.com, Inc. or its affiliates. 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. A copy of the License is located at http://aws.amazon.com/apache2.0/
or in the "license" file accompanying this fil... | unlicense | 4,925,142,042,631,168,000 | 34.619318 | 266 | 0.596522 | false |
Xdynix/PixivPixie | bundle_cli.py | 1 | 2691 | import os
import subprocess
import sys
from pixiv_pixie.cli import main as cli_main, NAME
BINARY_PATH = 'lib'
DATA_PATH = 'data'
def is_packaged():
# Return true if executing from packaged file
return hasattr(sys, 'frozen')
def get_path(path, package_prefix=DATA_PATH):
if os.path.isabs(path) or not is... | apache-2.0 | -7,565,490,886,109,477,000 | 24.628571 | 78 | 0.531401 | false |
tortugueta/multilayers | examples/radcenter_distribution.py | 1 | 8087 | # -*- coding: utf-8 -*-
"""
Name : radcenter_distribution
Author : Joan Juvert <trust.no.one.51@gmail.com>
Version : 1.0
Description : This script calculates the influence of the distribution of
: radiative centers in the active layer on the observed
: spectrum.
Copyright 2012 J... | gpl-3.0 | -2,529,649,230,264,011,300 | 36.967136 | 83 | 0.649808 | false |
linaro-technologies/jobserv | jobserv/storage/local_storage.py | 1 | 3989 | # Copyright (C) 2017 Linaro Limited
# Author: Andy Doan <andy.doan@linaro.org>
import hmac
import os
import mimetypes
import shutil
from flask import Blueprint, request, send_file, url_for
from jobserv.jsend import get_or_404
from jobserv.models import Build, Project, Run
from jobserv.settings import INTERNAL_API_KE... | agpl-3.0 | -3,963,570,515,246,286,300 | 33.094017 | 79 | 0.603159 | false |
jadref/buffer_bci | python/echoClient/eventForwarder.py | 1 | 2911 | #!/usr/bin/env python3
bufferpath = "../../python/signalProc"
fieldtripPath="../../dataAcq/buffer/python"
import os, sys, random, math, time, socket, struct
sys.path.append(os.path.join(os.path.dirname(os.path.abspath(__file__)),bufferpath))
import bufhelp
sys.path.append(os.path.join(os.path.dirname(os.path.abspath(_... | gpl-3.0 | -8,554,221,728,104,355,000 | 34.938272 | 103 | 0.605634 | false |
MTG/essentia | test/src/unittests/tonal/test_tonicindianartmusic.py | 1 | 7198 | #!/usr/bin/env python
# Copyright (C) 2006-2021 Music Technology Group - Universitat Pompeu Fabra
#
# This file is part of Essentia
#
# Essentia is free software: you can redistribute it and/or modify it under
# the terms of the GNU Afextentro General Public License as published by the Free
# Software Foundation (FSF... | agpl-3.0 | 7,944,952,061,579,169,000 | 48.30137 | 143 | 0.689497 | false |
shanot/imp | modules/saxs/test/test_surface.py | 1 | 3121 | from __future__ import print_function
import IMP
import IMP.test
import IMP.atom
import IMP.core
import IMP.saxs
import os
import time
class Tests(IMP.test.TestCase):
def test_surface_area(self):
"""Check protein surface computation"""
m = IMP.Model()
#! read PDB
mp = IMP.atom.re... | gpl-3.0 | -509,015,444,806,564,160 | 34.067416 | 77 | 0.582826 | false |
ozgurakgun/minion | mini-scripts/testallconstraints.py | 1 | 3983 | #!/usr/bin/python
# Generate two minion input files, run them then compare dumptree outputs to
# detect bugs in constraint propagators.
import sys, os, getopt
from constraint_test_common import *
from multiprocessing import Pool, Manager
import random
#from sendemail import *
import time
(optargs, other)=getopt.gnu_... | gpl-2.0 | -5,649,680,209,550,508,000 | 27.654676 | 152 | 0.651017 | false |
rabramley/telomere | app/model/batch.py | 1 | 2972 | from app import db
from sqlalchemy.ext.hybrid import hybrid_property
from sqlalchemy.sql import select, func
from app.model.outstandingError import OutstandingError
import numpy
import decimal
class Batch(db.Model):
id = db.Column(db.Integer, primary_key=True)
robot = db.Column(db.String(20))
temperature ... | mit | 7,113,725,852,751,646,000 | 37.102564 | 124 | 0.664536 | false |
DarioGT/OMS-PluginXML | org.modelsphere.sms/lib/jython-2.2.1/Lib/uu.py | 1 | 6092 | #! /usr/bin/env python
# Copyright 1994 by Lance Ellinghouse
# Cathedral City, California Republic, United States of America.
# All Rights Reserved
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose and without fee is hereby granted,
# ... | gpl-3.0 | 8,905,765,275,347,266,000 | 29.241026 | 72 | 0.559094 | false |
jhogg41/gm-o-matic | gom_server/gom_server/urls.py | 1 | 1187 | """gom_server URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/1.8/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: url(r'^$', views.home, name='home')
Class-... | bsd-2-clause | -3,051,245,291,478,614,500 | 36.09375 | 83 | 0.708509 | false |
kevin-coder/tensorflow-fork | tensorflow/python/keras/layers/normalization_test.py | 1 | 22900 | # 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... | apache-2.0 | 2,995,893,033,428,413,000 | 36.115073 | 80 | 0.650524 | false |
meisamhe/GPLshared | Programming/MPI — AMath 483 583, Spring 2013 1.0 documentation_files/s2.py | 1 | 1744 | import time
import threading
# @include
class SpellCheckService:
w_last = closest_to_last_word = None
lock = threading.Lock()
@staticmethod
def service(req, resp):
w = req.extract_word_to_check_from_request()
result = None
with SpellCheckService.lock:
if w == Spell... | gpl-3.0 | -6,428,526,257,127,913,000 | 22.567568 | 76 | 0.575115 | false |
gypsymauro/gestione-cantiere | build/lib.linux-x86_64-2.7/cantiere/admin.py | 1 | 1533 | from django.contrib import admin
# Register your models here.
from .models import Squadra
from .models import StatoSegnalazione
from .models import Segnalazione
from .models import StatoIntervento
from .models import Intervento
from .models import Risorsa
from .models import InterventoRisorsa
from .models import Cost... | gpl-2.0 | -2,517,305,136,308,949,000 | 32.326087 | 80 | 0.763862 | false |
SembeiNorimaki/Bioinformatics | EulerianCycle.py | 1 | 1903 | # Test passed :)
# TODO: split right here before the conditional.
import sys
def handle_input_output():
# handle input
graph = {}
while True:
try:
line = sys.stdin.readline().rstrip('\n')
left, right = line.split(' -> ')
if left in graph.keys():
... | mit | -4,300,464,103,968,979,000 | 33 | 115 | 0.553337 | false |
kittiu/account-payment | account_payment_return/models/payment_return.py | 1 | 15028 | # Copyright 2011-2012 7 i TRIA <http://www.7itria.cat>
# Copyright 2011-2012 Avanzosc <http://www.avanzosc.com>
# Copyright 2013 Pedro M. Baeza <pedro.baeza@tecnativa.com>
# Copyright 2014 Markus Schneider <markus.schneider@initos.com>
# Copyright 2016 Carlos Dauden <carlos.dauden@tecnativa.com>
# Copyright 2017 Luis M... | agpl-3.0 | 5,260,136,324,633,751,000 | 39.506739 | 79 | 0.544118 | false |
dpshelio/sunpy | examples/units_and_coordinates/planet_locations.py | 1 | 1252 | """
===================================
Getting the location of the planets
===================================
How to get the position of planetary bodies im the solar system using
`astropy's solar system ephemeris <http://docs.astropy.org/en/stable/coordinates/solarsystem.html#solar-system-ephemerides>`__ informatio... | bsd-2-clause | -3,296,977,724,421,778,000 | 42.172414 | 149 | 0.615815 | false |
kohout/djangocms-getaweb-topstory | djangocms_topstory/south_migrations/0008_auto__chg_field_topstoryitem_object_id.py | 1 | 5765 | # -*- coding: utf-8 -*-
from south.utils import datetime_utils as datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Changing field 'TopStoryItem.object_id'
db.alter_column(u'djangocms_to... | unlicense | 4,711,748,214,628,988,000 | 72.923077 | 161 | 0.572246 | false |
Khan/flask-wtf | tests/__init__.py | 1 | 9854 | from __future__ import with_statement
import re
from flask import Flask, Response, render_template, jsonify
from flaskext.uploads import UploadSet, IMAGES, TEXT, configure_uploads
from flaskext.testing import TestCase as _TestCase
from flaskext.wtf import Form, TextField, FileField, HiddenField, \
SubmitField... | bsd-3-clause | -3,217,176,349,144,430,600 | 28.240356 | 109 | 0.532576 | false |
Djimmer/obts | Fuzzer/function_scanner.py | 1 | 6412 | #!/usr/bin/python
# -*- coding: utf-8 -*-
import socket
import time
import binascii
import os
import sys
from libmich.formats import *
import gsm_um
import smarter_fuzzer_function_def as fuzzer
import itertools
from random import randint
from math import factorial
import logging
from pythonjsonlogger import jsonlogger... | agpl-3.0 | 7,928,618,940,592,154,000 | 29.980676 | 102 | 0.611822 | false |
jordiclariana/ansible | lib/ansible/modules/cloud/vmware/vmware_guest.py | 1 | 70396 | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# This module is also sponsored by E.T.A.I. (www.etai.fr)
#
# 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... | gpl-3.0 | -5,752,638,804,125,786,000 | 39.620889 | 172 | 0.571055 | false |
gyurisc/stackjobs | clean_data.py | 1 | 1758 | # Ad-hoc fixing of mongo database
from datetime import datetime
import pymongo
client = pymongo.MongoClient('localhost', 27017)
db = client['stackoverflow']
jobs = db['jobs']
# total jobs
total_jobs = jobs.count()
print "Total jobs: %s" % total_jobs
print "=== Fixing Date Stamp ==="
date_stamp = datetime(2016, 6, ... | mit | 6,723,297,113,947,829,000 | 31.555556 | 93 | 0.610353 | false |
nginx/unit | test/test_respawn.py | 1 | 3110 | import re
import subprocess
import time
from unit.applications.lang.python import TestApplicationPython
from unit.option import option
class TestRespawn(TestApplicationPython):
prerequisites = {'modules': {'python': 'any'}}
PATTERN_ROUTER = 'unit: router'
PATTERN_CONTROLLER = 'unit: controller'
def... | apache-2.0 | 8,054,660,929,248,665,000 | 29.792079 | 79 | 0.592605 | false |
rodo/ansible-tsung | ec2tool.py | 1 | 5117 | #!/usr/bin/env python
import boto.ec2
import jinja2
import sys
import json
import yaml
class Tsing(boto.ec2.instance.Instance):
def shortname(self):
return self.private_dns_name.split('.')[0]
@property
def private_short_name(self):
return self.private_dns_name.split('.')[0]
def get_spe... | gpl-3.0 | 6,011,133,720,753,712,000 | 24.713568 | 112 | 0.560876 | false |
ktbyers/netmiko | netmiko/cisco/cisco_viptela.py | 1 | 3093 | """Subclass specific to Cisco Viptela."""
from typing import Union, Sequence, TextIO, Any
import re
from netmiko.cisco_base_connection import CiscoSSHConnection
class CiscoViptelaSSH(CiscoSSHConnection):
"""Subclass specific to Cisco Viptela."""
def session_preparation(self) -> None:
"""Prepare the ... | mit | -8,207,812,357,518,117,000 | 37.6625 | 94 | 0.593922 | false |
nemesisdesign/openwisp2 | openwisp_controller/config/controller/views.py | 1 | 14788 | import json
from ipaddress import ip_address
from django.core.exceptions import FieldDoesNotExist, ValidationError
from django.db import transaction
from django.db.models import Q
from django.utils.decorators import method_decorator
from django.views.decorators.csrf import csrf_exempt
from django.views.generic.base im... | gpl-3.0 | 6,931,061,912,724,383,000 | 35.78607 | 88 | 0.61719 | false |
pinax/pinax-blog | pinax/blog/admin.py | 1 | 3056 | from functools import partial as curry
from django.contrib import admin
from django.utils import timezone
from django.utils.translation import ugettext_lazy as _
from pinax.images.admin import ImageInline
from pinax.images.models import ImageSet
from .conf import settings
from .forms import AdminPostForm
from .model... | mit | 7,357,990,425,241,163,000 | 29.56 | 97 | 0.659359 | false |
roberthodgen/thought-jot | src/utilities.py | 1 | 2732 | """
The MIT License (MIT)
Copyright (c) 2015 Robert Hodgen
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 without limitation the rights
to use, copy, modify, merge... | mit | 7,328,222,909,209,888,000 | 34.025641 | 80 | 0.712299 | false |
epuzanov/ZenPacks.community.CIMMon | ZenPacks/community/CIMMon/modeler/plugins/community/cim/SNIANetworkPortMap.py | 1 | 3274 | ################################################################################
#
# This program is part of the CIMMon Zenpack for Zenoss.
# Copyright (C) 2012 Egor Puzanov.
#
# This program can be used under the GNU General Public License version 2
# You can find full information here: http://www.zenoss.com/oss
#
###... | gpl-2.0 | -6,646,513,954,352,335,000 | 35.377778 | 83 | 0.419976 | false |
quokkaproject/quokka-classes | pipelines.py | 1 | 2318 | # coding: utf-8
from flask import request
from quokka.modules.cart.pipelines.base import CartPipeline
from quokka.utils import get_current_user
from .models import CourseSubscription, Subscriber
class SetSubscriber(CartPipeline):
def process(self):
name = request.form.get("name")
email = request... | mit | 7,357,983,847,842,146,000 | 33.088235 | 78 | 0.572045 | false |
walshjon/openmc | openmc/region.py | 1 | 18303 | from abc import ABCMeta, abstractmethod
from collections import OrderedDict
from collections.abc import Iterable, MutableSequence
from copy import deepcopy
import numpy as np
from openmc.checkvalue import check_type
class Region(metaclass=ABCMeta):
"""Region of space that can be assigned to a cell.
Region ... | mit | -4,142,554,628,031,096,300 | 30.233788 | 90 | 0.543845 | false |
squilter/ardupilot | Tools/autotest/arduplane.py | 1 | 85180 | #!/usr/bin/env python
# Fly ArduPlane in SITL
from __future__ import print_function
import math
import os
import time
from pymavlink import quaternion
from pymavlink import mavutil
from common import AutoTest
from common import AutoTestTimeoutException
from common import NotAchievedException
from common import Preco... | gpl-3.0 | -238,449,084,716,790,980 | 38.840973 | 161 | 0.547441 | false |
akinaru/ffmpeg-image-sequencer | ffmpeg-appender-test.py | 1 | 3157 | #!/usr/bin/python
#####################################################################################
#####################################################################################
#
# title : ffmpeg-appender-test.py
# authors : Bertrand Martel
# copyrights : Copyright (c) 2015 Bertrand Martel
# li... | mit | -8,222,219,400,538,782,000 | 30.58 | 193 | 0.602471 | false |
csangani/ReproducingSprout | extract_traces.py | 1 | 1317 | ## Create a network trace from the saturator output
import glob
import os
import sys
INPUT_PATH = 'raw_traces'
OUTPUT_PATH = 'cleaned_traces'
def extract_trace(filePath, targetFilePath):
with open(filePath) as f:
with open(targetFilePath, 'w+') as wf:
firstLine = True
for line in ... | mit | -2,875,549,895,375,812,000 | 27.630435 | 89 | 0.535308 | false |
meshulam/sly | deps/shapely/geos.py | 1 | 25191 | """
Proxies for the libgeos_c shared lib, GEOS-specific exceptions, and utilities
"""
import os
import re
import sys
import atexit
import logging
import threading
from ctypes import CDLL, cdll, pointer, c_void_p, c_size_t, c_char_p, string_at
from ctypes.util import find_library
from . import ftools
from .ctypes_decl... | mit | 9,089,816,898,955,361,000 | 32.277411 | 79 | 0.596403 | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.