hexsha
stringlengths
40
40
size
int64
5
2.06M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
248
max_stars_repo_name
stringlengths
5
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
248
max_issues_repo_name
stringlengths
5
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
248
max_forks_repo_name
stringlengths
5
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
5
2.06M
avg_line_length
float64
1
1.02M
max_line_length
int64
3
1.03M
alphanum_fraction
float64
0
1
count_classes
int64
0
1.6M
score_classes
float64
0
1
count_generators
int64
0
651k
score_generators
float64
0
1
count_decorators
int64
0
990k
score_decorators
float64
0
1
count_async_functions
int64
0
235k
score_async_functions
float64
0
1
count_documentation
int64
0
1.04M
score_documentation
float64
0
1
f6771eb1bdef0d5a9fe61445482e89e720f0f91d
522
py
Python
sources/deepzoom/large_image_source_deepzoom/girder_source.py
naglepuff/large_image
4e928166f228fe894c38e4b01af5370e72f7229c
[ "Apache-2.0" ]
85
2017-03-10T09:48:17.000Z
2022-03-31T18:55:58.000Z
sources/deepzoom/large_image_source_deepzoom/girder_source.py
naglepuff/large_image
4e928166f228fe894c38e4b01af5370e72f7229c
[ "Apache-2.0" ]
248
2017-01-27T16:11:13.000Z
2022-03-31T14:05:18.000Z
sources/deepzoom/large_image_source_deepzoom/girder_source.py
naglepuff/large_image
4e928166f228fe894c38e4b01af5370e72f7229c
[ "Apache-2.0" ]
33
2017-03-10T14:06:35.000Z
2022-03-19T08:32:06.000Z
# -*- coding: utf-8 -*- from girder_large_image.girder_tilesource import GirderTileSource from . import DeepzoomFileTileSource class DeepzoomGirderTileSource(DeepzoomFileTileSource, GirderTileSource): """ Deepzoom large_image tile source for Girder. Provides tile access to Girder items with a Deepzoom ...
24.857143
76
0.741379
390
0.747126
0
0
0
0
0
0
271
0.519157
f67731f5fc0850e27929602df508ab390137d452
194
py
Python
trac/Lib/site-packages/projectplan-0.93.0-py2.7-patched.egg/projectplan/renderer/__init__.py
thinkbase/PortableTrac
9ea0210f6b88f135ef73f370b48127af0495b2d7
[ "BSD-3-Clause" ]
2
2015-08-06T04:19:21.000Z
2020-04-29T23:52:10.000Z
trac/Lib/site-packages/projectplan-0.93.0-py2.7-patched.egg/projectplan/renderer/__init__.py
thinkbase/PortableTrac
9ea0210f6b88f135ef73f370b48127af0495b2d7
[ "BSD-3-Clause" ]
null
null
null
trac/Lib/site-packages/projectplan-0.93.0-py2.7-patched.egg/projectplan/renderer/__init__.py
thinkbase/PortableTrac
9ea0210f6b88f135ef73f370b48127af0495b2d7
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from ppchartrenderer import * from ppticketsperuserday import * #from pphierarchicalrenderer import * from ppreportrenderer import * from ppgroupstatsrenderer import *
21.555556
37
0.783505
0
0
0
0
0
0
0
0
60
0.309278
f67772509b463ffdb32e8b1ff18b59f81eb3ecda
2,674
py
Python
tests/sources/zuul/test_api.py
bregman-arie/cibyl
41132c1cb885f3306fe6aff59225cfafb6563207
[ "Apache-2.0" ]
null
null
null
tests/sources/zuul/test_api.py
bregman-arie/cibyl
41132c1cb885f3306fe6aff59225cfafb6563207
[ "Apache-2.0" ]
null
null
null
tests/sources/zuul/test_api.py
bregman-arie/cibyl
41132c1cb885f3306fe6aff59225cfafb6563207
[ "Apache-2.0" ]
null
null
null
""" # Copyright 2022 Red Hat # # 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 agr...
27.854167
79
0.636874
1,908
0.713538
0
0
126
0.04712
0
0
1,289
0.482049
f67860e5e860f7dd53b1e0dfd7d2593031b44100
3,735
py
Python
src/cihpc/core/structures/project_step.py
janhybs/ci-hpi
293740c7af62ecada5744ff663266de2e3d37445
[ "MIT" ]
1
2020-01-09T13:00:18.000Z
2020-01-09T13:00:18.000Z
src/cihpc/core/structures/project_step.py
janhybs/ci-hpi
293740c7af62ecada5744ff663266de2e3d37445
[ "MIT" ]
null
null
null
src/cihpc/core/structures/project_step.py
janhybs/ci-hpi
293740c7af62ecada5744ff663266de2e3d37445
[ "MIT" ]
2
2018-08-12T01:13:28.000Z
2018-08-13T14:37:28.000Z
#!/usr/bin/python # author: Jan Hybs import cihpc.core.structures as structures_init from cihpc.cfg.config import global_configuration from cihpc.core.structures.project_step_collect import ProjectStepCollect from cihpc.core.structures.project_step_container import ProjectStepContainer from cihpc.core.structures.proje...
41.966292
94
0.668273
3,086
0.826238
0
0
176
0.047122
0
0
1,735
0.464525
f678eb53ea8b81db409d272313d26c5cd3f11ca6
3,747
py
Python
maha/parsers/functions/parse_dimensions.py
MuhammadAlBarham/Maha
c28e0b7ca69942905548f013a1e35208ef8de7e7
[ "BSD-3-Clause" ]
1
2021-11-02T08:25:12.000Z
2021-11-02T08:25:12.000Z
maha/parsers/functions/parse_dimensions.py
vikrambala/Maha
67020437e745b8fca4770186608326b81073d4b7
[ "BSD-3-Clause" ]
null
null
null
maha/parsers/functions/parse_dimensions.py
vikrambala/Maha
67020437e745b8fca4770186608326b81073d4b7
[ "BSD-3-Clause" ]
null
null
null
__all__ = ["parse_dimension"] from typing import List from maha.parsers.rules import ( RULE_DURATION, RULE_NAME, RULE_NUMERAL, RULE_ORDINAL, RULE_TIME, ) from maha.parsers.templates import Dimension, DimensionType from maha.rexy import Expression def parse_dimension( text: str, amount_of...
28.603053
83
0.619696
0
0
0
0
0
0
0
0
1,640
0.437683
f679aca9364b8dc5091f23223316413bce1eb328
16,854
py
Python
pcbdraw.py
Gasman2014/PcbDraw
06920b8676a1a6f9d585111769b4785e9b7687fc
[ "MIT" ]
1
2019-04-04T09:36:28.000Z
2019-04-04T09:36:28.000Z
pcbdraw.py
arturo182/PcbDraw
06920b8676a1a6f9d585111769b4785e9b7687fc
[ "MIT" ]
null
null
null
pcbdraw.py
arturo182/PcbDraw
06920b8676a1a6f9d585111769b4785e9b7687fc
[ "MIT" ]
1
2018-10-16T02:16:27.000Z
2018-10-16T02:16:27.000Z
#!/usr/bin/env python import argparse import json import math import os import re import shutil import sys import tempfile import pcbnew from lxml import etree default_style = { "copper": "#417e5a", "board": "#4ca06c", "silk": "#f0f0f0", "pads": "#b5ae30", "outline": "#000000" } class SvgPathIte...
38.217687
104
0.572742
1,423
0.084431
0
0
134
0.007951
0
0
3,471
0.205945
f679b14fc387f30bc2bc6b965bd6ffea44f1f036
2,189
py
Python
src/lib/selectors/Local/core.py
williamwmarx/mtx
31548b60a4e88124b0384350cbec8df1d88975cb
[ "CC0-1.0" ]
null
null
null
src/lib/selectors/Local/core.py
williamwmarx/mtx
31548b60a4e88124b0384350cbec8df1d88975cb
[ "CC0-1.0" ]
null
null
null
src/lib/selectors/Local/core.py
williamwmarx/mtx
31548b60a4e88124b0384350cbec8df1d88975cb
[ "CC0-1.0" ]
null
null
null
import os from pathlib import Path from shutil import copyfile from lib.common.selector import Selector from lib.common.etypes import Etype, Index from lib.common.exceptions import SelectorIndexError BASE = Path("/mtriage") class Local(Selector): """A simple selector for importing local files into mtriage. It ...
31.271429
101
0.703518
1,944
0.888077
0
0
0
0
0
0
861
0.39333
f67a7ad9d7958716c654a9de8d7055db963e7764
620
py
Python
cohorts_proj/api/migrations/0002_auto_20201118_0125.py
zferic/harmonization-website
f6a081481df3a3a62cb075fbb63ad0470b0d4e06
[ "MIT" ]
1
2020-09-20T02:32:01.000Z
2020-09-20T02:32:01.000Z
cohorts_proj/api/migrations/0002_auto_20201118_0125.py
zferic/harmonization-website
f6a081481df3a3a62cb075fbb63ad0470b0d4e06
[ "MIT" ]
20
2020-04-17T14:01:41.000Z
2022-03-12T00:30:23.000Z
cohorts_proj/api/migrations/0002_auto_20201118_0125.py
zferic/harmonization-website
f6a081481df3a3a62cb075fbb63ad0470b0d4e06
[ "MIT" ]
3
2020-10-08T00:24:51.000Z
2021-06-02T20:07:30.000Z
# Generated by Django 3.0.7 on 2020-11-18 01:25 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('api', '0001_initial'), ] operations = [ migrations.AlterField( model_name='datasetuploadmodel', name='dataset_type',...
32.631579
281
0.648387
527
0.85
0
0
0
0
0
0
284
0.458065
f67b5cd19685b6f6168adfcb635e7a19ce5a128b
11,335
py
Python
simulateur/rn/Rn.py
thearsenik/sport-ironcar
bc48ee842bccbe4657216f3ef559c3f00a0fe944
[ "MIT" ]
null
null
null
simulateur/rn/Rn.py
thearsenik/sport-ironcar
bc48ee842bccbe4657216f3ef559c3f00a0fe944
[ "MIT" ]
null
null
null
simulateur/rn/Rn.py
thearsenik/sport-ironcar
bc48ee842bccbe4657216f3ef559c3f00a0fe944
[ "MIT" ]
null
null
null
import logging import sys sys.path.insert(0, '../') import config from tensorflow.python.tools import inspect_checkpoint as chkp import tensorflow as tf import numpy as np import random logging.basicConfig(filename=config.logFile,level=config.logLevelPlayer, format='%(asctime)s %(message)s') ...
42.935606
163
0.610763
10,995
0.969833
0
0
0
0
0
0
4,758
0.419688
f67c5e99f8382f72d21656638e76066a8f6362fa
1,096
py
Python
web/api/maestro_api/db/models/agent.py
Farfetch/maestro
837d93866123aea8b90ad0e2aaf3f13bf3ef6907
[ "MIT" ]
21
2022-02-02T11:52:14.000Z
2022-02-06T02:44:16.000Z
web/api/maestro_api/db/models/agent.py
Farfetch/maestro
837d93866123aea8b90ad0e2aaf3f13bf3ef6907
[ "MIT" ]
78
2022-02-02T12:13:12.000Z
2022-03-29T08:10:42.000Z
web/api/maestro_api/db/models/agent.py
Farfetch/maestro
837d93866123aea8b90ad0e2aaf3f13bf3ef6907
[ "MIT" ]
null
null
null
from maestro_api.libs.extended.enum import ExtendedEnum from mongoengine import StringField from maestro_api.db.mixins import CreatedUpdatedDocumentMixin from maestro_api.libs.datetime import strftime class AgentStatus(ExtendedEnum): """ Agents sends their status from time to time. If Agent stop sending s...
30.444444
85
0.684307
889
0.811131
0
0
0
0
0
0
261
0.238139
f67cb57866ffbaf57adcdd2f642ca09d35ff5b0c
521
py
Python
fanscribed/management/commands/rssfetchall.py
fanscribed/fanscribed
89b14496459f81a152df38ed5098fba2b087a1d7
[ "MIT" ]
8
2015-01-05T07:04:02.000Z
2016-07-19T17:56:46.000Z
fanscribed/management/commands/rssfetchall.py
fanscribed/fanscribed
89b14496459f81a152df38ed5098fba2b087a1d7
[ "MIT" ]
32
2015-03-18T18:51:00.000Z
2021-06-10T20:37:33.000Z
fanscribed/management/commands/rssfetchall.py
fanscribed/fanscribed
89b14496459f81a152df38ed5098fba2b087a1d7
[ "MIT" ]
5
2015-02-10T21:15:32.000Z
2016-06-02T17:26:14.000Z
from django.core.management.base import BaseCommand from ...apps.podcasts.models import Podcast class Command(BaseCommand): help = "Load initial data" def handle(self, *args, **options): verbose = (options['verbosity'] > 0) if verbose: self.stdout.write('Fetching all RSS feeds.\n...
30.647059
60
0.614203
421
0.808061
0
0
0
0
0
0
76
0.145873
f67d51e4d04cf2aabb8deef1712b57f7257ceacc
1,003
py
Python
HW8/EX2/fairpy/items/min_sharing_impl/time_limit.py
ShmuelLa/research-algorithms
43cab0e9c13ce9ddb9646f7539f1a865e86f9841
[ "MIT" ]
null
null
null
HW8/EX2/fairpy/items/min_sharing_impl/time_limit.py
ShmuelLa/research-algorithms
43cab0e9c13ce9ddb9646f7539f1a865e86f9841
[ "MIT" ]
null
null
null
HW8/EX2/fairpy/items/min_sharing_impl/time_limit.py
ShmuelLa/research-algorithms
43cab0e9c13ce9ddb9646f7539f1a865e86f9841
[ "MIT" ]
null
null
null
#!python3 """ A context for running functions with a time-limit. Throws an exception if the function does not finish within the limit. USAGE: with time_limit(10): foo() NOTE: This does not work on Windows. See: https://stackoverflow.com/a/8420498/827927 """ import signal import contextlib class TimeoutExceptio...
22.795455
75
0.684945
39
0.038883
332
0.331007
359
0.357926
0
0
370
0.368893
f67e76c93cfde02c31983edf748ae38341b647b9
4,969
py
Python
accounts/views.py
Jaheen/CrazyCart
bb72ed71edfe90580482c47d90bcd7ecaa302970
[ "MIT" ]
null
null
null
accounts/views.py
Jaheen/CrazyCart
bb72ed71edfe90580482c47d90bcd7ecaa302970
[ "MIT" ]
10
2021-03-18T22:40:53.000Z
2022-03-11T23:50:51.000Z
accounts/views.py
Jaheen/CrazyCart
bb72ed71edfe90580482c47d90bcd7ecaa302970
[ "MIT" ]
null
null
null
from django.shortcuts import render, redirect from django.contrib.auth.decorators import login_required from django.contrib.auth import login as UserLogin, logout as UserLogout, authenticate from django.contrib import messages from .models import * from .verification import sendVerificationEmail #SUGGESTED TO USE CLA...
39.436508
120
0.623063
0
0
0
0
2,447
0.492453
0
0
1,074
0.21614
f67fc9d4d95893aeeecd1c5378c7a47c828c7677
5,476
py
Python
depth_tests.py
AhmedAlaa10/Consistent_Video_Depth_Estimation
1a8868eadcf0b2082cdfea8ed339865f0ba8ea01
[ "MIT" ]
null
null
null
depth_tests.py
AhmedAlaa10/Consistent_Video_Depth_Estimation
1a8868eadcf0b2082cdfea8ed339865f0ba8ea01
[ "MIT" ]
null
null
null
depth_tests.py
AhmedAlaa10/Consistent_Video_Depth_Estimation
1a8868eadcf0b2082cdfea8ed339865f0ba8ea01
[ "MIT" ]
null
null
null
import os import re import sys from posix import listdir from shutil import copyfile from pathlib import Path import numpy as np from PIL import Image from skimage.transform import resize import utils.image_io TAG_FLOAT = 202021.25 TAG_CHAR = 'PIEH' name="shaman_3" if len(sys.argv) > 1: name = str(sys.argv[1]) ...
33.595092
153
0.721695
0
0
0
0
0
0
0
0
1,514
0.276479
9c8668c7c7bb6c29a806eaa8d8f7bd5230f9648a
24,684
py
Python
mountain_cartographer.py
Naburimannu/beyaz-dag
50dbe54c8cffecafcf209b30f44bd326d84a424c
[ "BSD-3-Clause" ]
1
2018-02-23T17:31:08.000Z
2018-02-23T17:31:08.000Z
mountain_cartographer.py
Naburimannu/beyaz-dag
50dbe54c8cffecafcf209b30f44bd326d84a424c
[ "BSD-3-Clause" ]
2
2016-03-15T04:39:46.000Z
2016-03-15T04:43:00.000Z
mountain_cartographer.py
Naburimannu/beyaz-dag
50dbe54c8cffecafcf209b30f44bd326d84a424c
[ "BSD-3-Clause" ]
null
null
null
# Copyright 2016 Thomas C. Hudson # Governed by the license described in LICENSE.txt import libtcodpy as libtcod import cProfile import scipy.spatial.kdtree import config import algebra import map import log from components import * import miscellany import bestiary import ai import actions import spells import quest...
36.677563
122
0.624777
0
0
0
0
0
0
0
0
4,318
0.174931
9c869ea13c57d3dfb524eb647b6f3d5f86eafa6e
7,307
py
Python
test_scripts/ns_instance/duan/service/vfc/nfvo/lcm/lcm/ns_vnfs/biz/grant_vnf.py
lremember/VFC
837559db1396091811382359100bfc60e1aab5b2
[ "MIT" ]
1
2019-10-10T00:52:18.000Z
2019-10-10T00:52:18.000Z
test_scripts/ns_instance/duan/service/vfc/nfvo/lcm/lcm/ns_vnfs/biz/grant_vnf.py
lremember/VFC-Files
837559db1396091811382359100bfc60e1aab5b2
[ "MIT" ]
null
null
null
test_scripts/ns_instance/duan/service/vfc/nfvo/lcm/lcm/ns_vnfs/biz/grant_vnf.py
lremember/VFC-Files
837559db1396091811382359100bfc60e1aab5b2
[ "MIT" ]
null
null
null
# Copyright 2018 ZTE Corporation. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
41.754286
116
0.575065
5,785
0.791707
0
0
0
0
0
0
2,127
0.291091
9c86fc3cc7d33b4cf70c509d1568b79a22d1d208
5,877
py
Python
tests/test_oyashiki.py
maidnomad/maidchan-slackbot
42364c2ffef60211a1d5be53f7d3ff1922418abd
[ "MIT" ]
null
null
null
tests/test_oyashiki.py
maidnomad/maidchan-slackbot
42364c2ffef60211a1d5be53f7d3ff1922418abd
[ "MIT" ]
null
null
null
tests/test_oyashiki.py
maidnomad/maidchan-slackbot
42364c2ffef60211a1d5be53f7d3ff1922418abd
[ "MIT" ]
null
null
null
from unittest import mock import freezegun import pytest @pytest.fixture def target(): from maidchan.tasks import お屋敷のお仕事をする return お屋敷のお仕事をする @pytest.mark.parametrize( "text, expected", [ ("メイドちゃん!褒めて!", "<@00000000>さん!すごーい!"), ("メイドちゃん!私を褒めて!", "<@00000000>さん!すごーい!"), ("メ...
34.570588
86
0.532244
0
0
0
0
6,535
0.832802
0
0
4,382
0.55843
9c88328d2f2e6bbd1db0fc76c3be87f48859e1ad
65,821
py
Python
robotcode/language_server/robotframework/diagnostics/namespace.py
mardukbp/robotcode
0b34cf6e7931423117036fcf70f74e27da0cfb0f
[ "Apache-2.0" ]
null
null
null
robotcode/language_server/robotframework/diagnostics/namespace.py
mardukbp/robotcode
0b34cf6e7931423117036fcf70f74e27da0cfb0f
[ "Apache-2.0" ]
null
null
null
robotcode/language_server/robotframework/diagnostics/namespace.py
mardukbp/robotcode
0b34cf6e7931423117036fcf70f74e27da0cfb0f
[ "Apache-2.0" ]
null
null
null
from __future__ import annotations import ast import asyncio import itertools import weakref from collections import OrderedDict from dataclasses import dataclass, field from enum import Enum from pathlib import Path from typing import ( Any, AsyncIterator, Callable, Dict, Iterable, List, N...
40.356223
120
0.519925
64,410
0.978563
231
0.00351
9,308
0.141414
55,895
0.849197
2,781
0.042251
9c8aa12d673cf3649dc9201dd6e2e41e93e6b37f
2,513
py
Python
graph.py
monopolize-all/Wave-Sim
f78cfc3195fcf545d585f3dbdfc9c1b9e59798cc
[ "BSD-3-Clause" ]
1
2022-03-31T03:15:02.000Z
2022-03-31T03:15:02.000Z
graph.py
monopolize-all/Wave-Sim
f78cfc3195fcf545d585f3dbdfc9c1b9e59798cc
[ "BSD-3-Clause" ]
null
null
null
graph.py
monopolize-all/Wave-Sim
f78cfc3195fcf545d585f3dbdfc9c1b9e59798cc
[ "BSD-3-Clause" ]
1
2022-03-18T09:56:50.000Z
2022-03-18T09:56:50.000Z
import tkinter from util import Variable_Slider_Widget class Graph(tkinter.Toplevel): PLOTTER_SIZE = (400, 400) PLOTTER_WIDTH, PLOTTER_HEIGHT = PLOTTER_SIZE BACKGROUND_COLOUR = "#ffffff" POINTS_COLOUR = "#000000" POINTS_OFFSET = PLOTTER_SIZE[0] // 2, PLOTTER_SIZE[1] // 2 def __init__(self,...
32.636364
97
0.619976
2,455
0.97692
0
0
0
0
0
0
115
0.045762
9c8c2ec534ad96bf825fbadbde34d2692ea3214c
10,275
py
Python
src/FLI/camera.py
astroufsc/python-FLI
e5fc8802bca100433802e03915edd2cd0bd62b05
[ "MIT" ]
1
2015-05-29T00:38:00.000Z
2015-05-29T00:38:00.000Z
src/FLI/camera.py
astroufsc/python-FLI
e5fc8802bca100433802e03915edd2cd0bd62b05
[ "MIT" ]
null
null
null
src/FLI/camera.py
astroufsc/python-FLI
e5fc8802bca100433802e03915edd2cd0bd62b05
[ "MIT" ]
null
null
null
""" FLI.camera.py Object-oriented interface for handling FLI USB cameras author: Craig Wm. Versek, Yankee Environmental Systems author_email: cwv@yesinc.com """ __author__ = 'Craig Wm. Versek' __date__ = '2012-08-08' import sys, time, warnings try: from collections import OrderedDict except Impor...
40.936255
120
0.605742
8,538
0.830949
0
0
0
0
0
0
2,863
0.278637
9c8d73a16d474beccfcd4957adb9d6ffb14b93ca
4,388
py
Python
segment trees/Tree33_update(add lr)_query(weighted sum)_v2.py
DreamShaded/flykiller.github.io
37b7abc44544613f56ec994452ddd8d2a4ac8df2
[ "MIT" ]
5
2021-08-10T18:07:39.000Z
2022-03-26T08:16:24.000Z
segment trees/Tree33_update(add lr)_query(weighted sum)_v2.py
DreamShaded/flykiller.github.io
37b7abc44544613f56ec994452ddd8d2a4ac8df2
[ "MIT" ]
null
null
null
segment trees/Tree33_update(add lr)_query(weighted sum)_v2.py
DreamShaded/flykiller.github.io
37b7abc44544613f56ec994452ddd8d2a4ac8df2
[ "MIT" ]
2
2021-03-31T18:14:06.000Z
2021-08-23T04:15:30.000Z
# we can use Segment Tree 24 and Segment Tree 31 and combine them. class SegmentTree1: # add arithmetic progressions def __init__(self, n): self.size = 1 while self.size < n: self.size *= 2 self.NO_OPERATION = (0, 0) # it should be neutral with respect to op_modify ...
34.551181
103
0.459435
3,501
0.797858
0
0
0
0
0
0
327
0.074521
9c8d9632b51002742a71d2968e1021ca4aac37d9
761
py
Python
tests/client/lcd/api/feegrant_test.py
terra-money/terra.py
d66de6bb4d9d78f08ad8ffe05ae72d847fc5099d
[ "MIT" ]
66
2021-10-21T23:29:38.000Z
2022-03-30T15:58:13.000Z
tests/client/lcd/api/feegrant_test.py
terra-money/terra.py
d66de6bb4d9d78f08ad8ffe05ae72d847fc5099d
[ "MIT" ]
50
2021-10-19T06:11:56.000Z
2022-03-31T17:06:57.000Z
tests/client/lcd/api/feegrant_test.py
terra-money/terra.py
d66de6bb4d9d78f08ad8ffe05ae72d847fc5099d
[ "MIT" ]
39
2021-11-07T17:28:31.000Z
2022-03-31T15:03:57.000Z
from terra_sdk.client.lcd import LCDClient, PaginationOptions terra = LCDClient( url="https://pisco-lcd.terra.dev/", chain_id="pisco-1", ) pagOpt = PaginationOptions(limit=2, count_total=True) def test_allowances(): result, _ = terra.feegrant.allowances( "terra17lmam6zguazs5q5u6z5mmx76uj63gldns...
26.241379
78
0.73456
0
0
0
0
0
0
0
0
287
0.377135
9c8e3ad5fa1769d9fb66fb1f9d1bd81f7b58b1e3
586
py
Python
letters/sort_by.py
clairempr/letterpress
05af199018b00ecff847789c71adbf9abc53b3a7
[ "Apache-2.0" ]
5
2017-04-27T19:36:41.000Z
2020-10-04T15:03:46.000Z
letters/sort_by.py
clairempr/letterpress
05af199018b00ecff847789c71adbf9abc53b3a7
[ "Apache-2.0" ]
14
2017-06-17T14:12:34.000Z
2022-03-11T23:15:32.000Z
letters/sort_by.py
clairempr/letterpress
05af199018b00ecff847789c71adbf9abc53b3a7
[ "Apache-2.0" ]
null
null
null
# Used for user-selected sort order from letter_sentiment.custom_sentiment import get_custom_sentiments DATE = 'DATE' RELEVANCE = 'RELEVANCE' SENTIMENT = 'SENTIMENT' def get_selected_sentiment_id(filter_value): if not filter_value.startswith(SENTIMENT): return 0 sentiment_id = int(filter_value.strip...
27.904762
114
0.773038
0
0
0
0
0
0
0
0
102
0.174061
9c8f54bbbfe1e98306867cca1e589d5209ed5cee
1,419
py
Python
core/pycopia/inet/packet/inet.py
kdart/pycopia
1446fabaedf8c6bdd4ab1fc3f0ea731e0ef8da9d
[ "Apache-2.0" ]
89
2015-03-26T11:25:20.000Z
2022-01-12T06:25:14.000Z
core/pycopia/inet/packet/inet.py
kdart/pycopia
1446fabaedf8c6bdd4ab1fc3f0ea731e0ef8da9d
[ "Apache-2.0" ]
1
2015-07-05T03:27:43.000Z
2015-07-11T06:21:20.000Z
core/pycopia/inet/packet/inet.py
kdart/pycopia
1446fabaedf8c6bdd4ab1fc3f0ea731e0ef8da9d
[ "Apache-2.0" ]
30
2015-04-30T01:35:54.000Z
2022-01-12T06:19:49.000Z
"""Internet packet basic Simple operations like performing checksums and swapping byte orders. """ # Copyright 1997, Corporation for National Research Initiatives # written by Jeremy Hylton, jeremy@cnri.reston.va.us #from _ip import * import array import struct from socket import htons, ntohs def cksum(s): if len(...
22.887097
69
0.627907
0
0
0
0
0
0
0
0
441
0.310782
9c92762d98989b0ae4eb5388e7e45d799bef4d27
445
py
Python
catalog/migrations/0009_auto_20180929_1001.py
mentatij/otus_catalog_dj
46bb1fc148bb436743d170176e5103282dfb6cc3
[ "MIT" ]
null
null
null
catalog/migrations/0009_auto_20180929_1001.py
mentatij/otus_catalog_dj
46bb1fc148bb436743d170176e5103282dfb6cc3
[ "MIT" ]
null
null
null
catalog/migrations/0009_auto_20180929_1001.py
mentatij/otus_catalog_dj
46bb1fc148bb436743d170176e5103282dfb6cc3
[ "MIT" ]
null
null
null
# Generated by Django 2.1.1 on 2018-09-29 10:01 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('catalog', '0008_auto_20180928_1244'), ] operations = [ migrations.AlterField( model_name='product', name='image', ...
23.421053
109
0.613483
352
0.791011
0
0
0
0
0
0
125
0.280899
9c92bba166a952628d0c7f796fdb4a115c5fe618
1,865
py
Python
test/test_modify_group.py
Docent321/python_traning
eb4b9f6ba9821f6e32dce954c83754d40b8f66c5
[ "Apache-2.0" ]
null
null
null
test/test_modify_group.py
Docent321/python_traning
eb4b9f6ba9821f6e32dce954c83754d40b8f66c5
[ "Apache-2.0" ]
null
null
null
test/test_modify_group.py
Docent321/python_traning
eb4b9f6ba9821f6e32dce954c83754d40b8f66c5
[ "Apache-2.0" ]
null
null
null
from model.group import Group from random import randrange def test_modify_first_groop(app): if app.group.count() == 0: app.group.create(Group(name="qweqwe", header="qweqwe", footer="qweqwe")) old_groups = app.group.get_group_list() index = randrange(len(old_groups)) group = Group(name="1", h...
41.444444
94
0.692225
0
0
0
0
0
0
0
0
1,227
0.657909
9c94c23785142e08b30342809bc3b549b76dac91
946
py
Python
Graph/357 DFS on graph.py
ikaushikpal/DS-450-python
9466f77fb9db9e6a5bb3f20aa89ba6332f49e848
[ "MIT" ]
3
2021-06-28T12:04:19.000Z
2021-09-07T07:23:41.000Z
Graph/357 DFS on graph.py
SupriyoDam/DS-450-python
5dc21ce61b3279e9bd9d6ef3ad236667227ca283
[ "MIT" ]
null
null
null
Graph/357 DFS on graph.py
SupriyoDam/DS-450-python
5dc21ce61b3279e9bd9d6ef3ad236667227ca283
[ "MIT" ]
1
2021-06-28T15:42:55.000Z
2021-06-28T15:42:55.000Z
from collections import defaultdict class Graph: def __init__(self): self.graph = defaultdict(list) def addEdge(self, starting_vertex, end_vertex): self.graph[starting_vertex].append(end_vertex) def dfs(self, starting_vertex): visitedVertices = defaultdict(bool) v...
24.894737
56
0.612051
746
0.788584
0
0
0
0
0
0
74
0.078224
9c950d2a39976a79ca933929f87f958add0fa87e
7,312
py
Python
transform/support/docxRenderer.py
openenglishbible/USFM-Tools
8438b29037d7b413d59d6ba7507c473bbda2da8c
[ "MIT" ]
14
2016-02-01T15:02:35.000Z
2022-01-18T06:21:56.000Z
transform/support/docxRenderer.py
openenglishbible/USFM-Tools
8438b29037d7b413d59d6ba7507c473bbda2da8c
[ "MIT" ]
2
2021-02-27T10:05:58.000Z
2022-02-26T19:10:46.000Z
transform/support/docxRenderer.py
openenglishbible/USFM-Tools
8438b29037d7b413d59d6ba7507c473bbda2da8c
[ "MIT" ]
6
2015-02-11T22:41:12.000Z
2021-01-03T09:13:58.000Z
# -*- coding: utf-8 -*- # import codecs import os from docx import Document from docx.shared import Inches, Pt, RGBColor import abstractRenderer # # Renders to Word .docx # class Renderer(abstractRenderer.AbstractRenderer): def __init__(self, inputDir, outputDir, outputName, config): abstractRe...
34.490566
149
0.591493
7,130
0.975109
0
0
0
0
0
0
711
0.097237
9c95da0f17b2e834d70853f308abd5efe0eb37b4
357
py
Python
merge_csv.py
RicherMans/Dcase2018_pooling
10540502bba7215a1ba157614b39fedecb079d9b
[ "Apache-2.0" ]
13
2019-04-14T08:10:59.000Z
2021-04-01T08:36:35.000Z
merge_csv.py
RicherMans/Dcase2018_pooling
10540502bba7215a1ba157614b39fedecb079d9b
[ "Apache-2.0" ]
null
null
null
merge_csv.py
RicherMans/Dcase2018_pooling
10540502bba7215a1ba157614b39fedecb079d9b
[ "Apache-2.0" ]
3
2019-04-22T10:40:27.000Z
2020-05-14T11:27:09.000Z
import argparse import pandas as pd parser = argparse.ArgumentParser() parser.add_argument('csvs', type=argparse.FileType('r'), nargs='+') parser.add_argument('-out', type=argparse.FileType('w'), default='out.csv') args = parser.parse_args() pd.concat([pd.read_csv(f, sep='\t') for f in args.csvs], axis=0).to_...
39.666667
75
0.70028
0
0
0
0
0
0
0
0
38
0.106443
9c9783eb738d90cec205f76bc47ef31bc9e4981c
1,867
py
Python
tests/test_generate_histogram_plot.py
laelbarlow/amoebae
3c6607bcb64a60baee2f19f0a25e14b325e9725d
[ "Apache-2.0" ]
8
2020-07-16T21:36:38.000Z
2021-11-28T08:32:05.000Z
tests/test_generate_histogram_plot.py
laelbarlow/amoebae
3c6607bcb64a60baee2f19f0a25e14b325e9725d
[ "Apache-2.0" ]
null
null
null
tests/test_generate_histogram_plot.py
laelbarlow/amoebae
3c6607bcb64a60baee2f19f0a25e14b325e9725d
[ "Apache-2.0" ]
1
2020-07-31T21:21:15.000Z
2020-07-31T21:21:15.000Z
#!/usr/bin/env python3 """PyTest tests for the generate_histogram_plot.py module. """ import os import sys sys.path.append(os.path.join(os.path.dirname(sys.path[0]),'amoebaelib')) # Customize. from generate_histogram_plot import \ generate_histogram, \ generate_double_histogram, \ autolabel_bars, \ generate_bar_chart ...
22.22619
90
0.528656
0
0
0
0
0
0
0
0
1,172
0.627745
9c98525fcb0d0b1802ff821f7d1db0119cf52338
10,149
py
Python
src/tools/convert_airsimcam_to_coco.py
PhyllisH/CenterNet
dc17ed79329a7a8faeffbd44be85019b4779a371
[ "MIT" ]
null
null
null
src/tools/convert_airsimcam_to_coco.py
PhyllisH/CenterNet
dc17ed79329a7a8faeffbd44be85019b4779a371
[ "MIT" ]
null
null
null
src/tools/convert_airsimcam_to_coco.py
PhyllisH/CenterNet
dc17ed79329a7a8faeffbd44be85019b4779a371
[ "MIT" ]
null
null
null
from __future__ import absolute_import from __future__ import division from __future__ import print_function import pickle import json import numpy as np import math import cv2 import os import random import matplotlib.pyplot as plt from pyquaternion import Quaternion import pycocotools.coco as coco # DATA_PATH = '.....
42.822785
122
0.515913
0
0
0
0
0
0
0
0
2,311
0.227707
9c9944bcc47bf407be2e97f0b042b46e0079024f
36
py
Python
tests/test_multi/views.py
cacahootie/deckmaster
6f8585ee35b8cfc2fb0b68adefc1308322da618d
[ "MIT" ]
null
null
null
tests/test_multi/views.py
cacahootie/deckmaster
6f8585ee35b8cfc2fb0b68adefc1308322da618d
[ "MIT" ]
null
null
null
tests/test_multi/views.py
cacahootie/deckmaster
6f8585ee35b8cfc2fb0b68adefc1308322da618d
[ "MIT" ]
null
null
null
def c(): return "HappyFilmore"
9
25
0.611111
0
0
0
0
0
0
0
0
14
0.388889
9c9a821cc281b228396f8b843b5b439e1cb8ce61
14,355
py
Python
dataset_production/extract_ear_tail_segmentations.py
OllieBoyne/dog-dynamics
c472f984cb04e6dea932be6a42f4daaf174fb44c
[ "Apache-2.0" ]
1
2020-10-04T18:40:23.000Z
2020-10-04T18:40:23.000Z
dataset_production/extract_ear_tail_segmentations.py
OllieBoyne/dog-dynamics
c472f984cb04e6dea932be6a42f4daaf174fb44c
[ "Apache-2.0" ]
null
null
null
dataset_production/extract_ear_tail_segmentations.py
OllieBoyne/dog-dynamics
c472f984cb04e6dea932be6a42f4daaf174fb44c
[ "Apache-2.0" ]
null
null
null
"""Scripts for second stage of labelling - ear and tail segmentations""" from vis.utils import * from dataset_production.mturk_processor import * from scipy.ndimage import center_of_mass as COM from matplotlib import colors def extract_colours(rgb_array): """Given an array of (r,g,b) values, returns list of unique ...
34.927007
126
0.676419
0
0
0
0
0
0
0
0
5,155
0.359108
9c9ab6d958bddc118fb34cac20ce0e74d1c7b8ce
664
py
Python
dl_jp_geojson/data/makecsv.py
mski-iksm/dl_jp_geojson
64edaa3f6200994c4d8fb61b52ecc0bae9da6842
[ "MIT" ]
null
null
null
dl_jp_geojson/data/makecsv.py
mski-iksm/dl_jp_geojson
64edaa3f6200994c4d8fb61b52ecc0bae9da6842
[ "MIT" ]
null
null
null
dl_jp_geojson/data/makecsv.py
mski-iksm/dl_jp_geojson
64edaa3f6200994c4d8fb61b52ecc0bae9da6842
[ "MIT" ]
null
null
null
import pandas as pd savename = "prefecture_city.csv" savedf = False for num in range(1, 48): strnum = '{0:02d}'.format(num) filename = "prefecture{}.txt".format(strnum) df = pd.read_csv(filename, sep='|', skiprows=[1]) df.columns = ["nan0", 'prefecture_name', 'prefecture_code', ...
27.666667
64
0.575301
0
0
0
0
0
0
0
0
127
0.191265
9c9b7594766494a397545f4d3091de4ab4059dcb
2,396
py
Python
extras/tests/test_views.py
2bithacker/peering-manager
5953c4b1f2cff2a370b68d418a98c5c9e3037de8
[ "Apache-2.0" ]
null
null
null
extras/tests/test_views.py
2bithacker/peering-manager
5953c4b1f2cff2a370b68d418a98c5c9e3037de8
[ "Apache-2.0" ]
1
2021-11-11T22:08:22.000Z
2021-11-11T22:08:22.000Z
extras/tests/test_views.py
2bithacker/peering-manager
5953c4b1f2cff2a370b68d418a98c5c9e3037de8
[ "Apache-2.0" ]
null
null
null
from unittest.mock import patch from funcy.funcs import identity from extras.models import IXAPI from utils.testing import ViewTestCases class IXAPITestCase(ViewTestCases.PrimaryObjectViewTestCase): model = IXAPI test_bulk_edit_objects = None @classmethod def setUpTestData(cls): IXAPI.obje...
30.329114
61
0.466611
2,254
0.940735
0
0
1,127
0.470367
0
0
624
0.260434
9c9bab4583ba12cbca4b9bc83f9587b603f8df68
405
py
Python
refinery/units/obfuscation/ps1/escape.py
bronxc/refinery
9448facf48a0008f27861dd1a5ee8f5218e6bb86
[ "BSD-3-Clause" ]
1
2022-02-13T20:57:15.000Z
2022-02-13T20:57:15.000Z
refinery/units/obfuscation/ps1/escape.py
bronxc/refinery
9448facf48a0008f27861dd1a5ee8f5218e6bb86
[ "BSD-3-Clause" ]
null
null
null
refinery/units/obfuscation/ps1/escape.py
bronxc/refinery
9448facf48a0008f27861dd1a5ee8f5218e6bb86
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import re from refinery.units.obfuscation import Deobfuscator from refinery.units.obfuscation.ps1 import Ps1StringLiterals class deob_ps1_escape(Deobfuscator): def deobfuscate(self, data): strlit = Ps1StringLiterals(data) @strlit.outside def...
25.3125
62
0.671605
231
0.57037
0
0
48
0.118519
0
0
72
0.177778
9c9bed51d7ce9e6e6a8e36ed3a6d340243c9131e
7,399
py
Python
torchshard/nn/modules/linear.py
KaiyuYue/torchshard
89e21def180bf6063ceb2e312a61631173abc7e7
[ "Apache-2.0" ]
265
2021-04-27T12:06:45.000Z
2022-03-17T11:13:17.000Z
torchshard/nn/modules/linear.py
poodarchu/torchshard
667cfce9ed3e2170c7768d910a71aa07897857e7
[ "Apache-2.0" ]
7
2021-05-24T06:54:44.000Z
2022-01-01T18:47:38.000Z
torchshard/nn/modules/linear.py
KaiyuYue/torchshard
89e21def180bf6063ceb2e312a61631173abc7e7
[ "Apache-2.0" ]
11
2021-04-28T04:15:44.000Z
2022-01-26T04:29:30.000Z
import warnings import math from typing import Optional, TypeVar import torch import torch.nn as nn from torch import Tensor from torch.nn import Module from torch.nn import init from torch.nn.parameter import Parameter import torchshard from .. import functional as F from ...distributed import get_world_size, get_...
35.066351
114
0.602784
6,619
0.89458
0
0
3,350
0.452764
0
0
1,386
0.187323
9c9c1b01207c7561b9e6a131ab0ef5cd461c221f
635
py
Python
hood/forms.py
magechaP/WayaHoodie
3138f72bee9e6326390ed808da7958a96019b2f4
[ "MIT" ]
null
null
null
hood/forms.py
magechaP/WayaHoodie
3138f72bee9e6326390ed808da7958a96019b2f4
[ "MIT" ]
4
2020-06-05T22:58:00.000Z
2021-09-08T01:17:04.000Z
hood/forms.py
magechaP/WayaHoodie
3138f72bee9e6326390ed808da7958a96019b2f4
[ "MIT" ]
null
null
null
from django import forms from .models import Profile,Post,Neighbourhood,Business from django.contrib.auth.models import User class UpdateProfileForm(forms.ModelForm): class Meta: model = Profile exclude = ['user','neighbourhood'] class NewHoodForm(forms.ModelForm): class Meta: model ...
25.4
56
0.677165
501
0.788976
0
0
0
0
0
0
98
0.154331
9c9cabc6e5e7bcca6db0d16855af1de0a476a452
234
py
Python
k_means_clustering/data.py
awesome-archive/Machine-Learning-with-Python
898ebbf2d7c780cb5a89bad51d0b7e043e25879f
[ "MIT" ]
2
2020-08-11T03:59:26.000Z
2020-11-04T21:52:48.000Z
k_means_clustering/data.py
skylaronomics/Machine-Learning-with-Python
186a6f38f6719e5610e0143aecdf170c842ff107
[ "MIT" ]
2
2021-06-02T02:30:02.000Z
2021-11-15T17:51:42.000Z
k_means_clustering/data.py
skylaronomics/Machine-Learning-with-Python
186a6f38f6719e5610e0143aecdf170c842ff107
[ "MIT" ]
1
2020-07-21T18:36:03.000Z
2020-07-21T18:36:03.000Z
inputs = [[-14, -5], [13, 13], [20, 23], [-19, -11], [-9, -16], [21, 27], [-49, 15], [26, 13], [-46, 5], [-34, -1], [11, 15], [-49, 0], [-22, -16], [19, 28], [-12, -8], [-13, -19], [-41, 8], [-11, -6], [-25, -9], [-18, -3]]
78
117
0.324786
0
0
0
0
0
0
0
0
0
0
9c9d795d7478f8874ad3e2278920a0dbad64e675
1,639
py
Python
NiaPy/tests/test_ba.py
kivancguckiran/NiaPy
06d3699c1466bfc54c4220a4aabe97cad50f75e4
[ "MIT" ]
2
2018-10-07T08:41:44.000Z
2019-04-05T15:30:56.000Z
NiaPy/tests/test_ba.py
kivancguckiran/NiaPy
06d3699c1466bfc54c4220a4aabe97cad50f75e4
[ "MIT" ]
null
null
null
NiaPy/tests/test_ba.py
kivancguckiran/NiaPy
06d3699c1466bfc54c4220a4aabe97cad50f75e4
[ "MIT" ]
null
null
null
# pylint: disable=old-style-class, line-too-long from NiaPy.tests.test_algorithm import AlgorithmTestCase, MyBenchmark from NiaPy.algorithms.basic import BatAlgorithm class BATestCase(AlgorithmTestCase): def test_parameter_type(self): d = BatAlgorithm.typeParameters() self.assertTrue(d['Qmax'](10...
49.666667
157
0.661379
1,469
0.896278
0
0
0
0
0
0
122
0.074436
9c9d85a146755f67b9bdd4855fe645173983f2c8
223
py
Python
tests/run_tests.py
in-toto/layout-web-tool
cbadd131a692e8457d548da2d37012306ba4a7b9
[ "MIT" ]
1
2020-04-01T15:05:54.000Z
2020-04-01T15:05:54.000Z
tests/run_tests.py
in-toto/layout-web-tool
cbadd131a692e8457d548da2d37012306ba4a7b9
[ "MIT" ]
42
2017-05-23T17:19:19.000Z
2021-04-26T12:28:47.000Z
tests/run_tests.py
in-toto/layout-web-tool
cbadd131a692e8457d548da2d37012306ba4a7b9
[ "MIT" ]
7
2017-05-04T02:13:07.000Z
2020-07-09T10:56:03.000Z
from unittest import defaultTestLoader, TextTestRunner import sys suite = defaultTestLoader.discover(start_dir=".") result = TextTestRunner(verbosity=2, buffer=True).run(suite) sys.exit(0 if result.wasSuccessful() else 1)
31.857143
60
0.802691
0
0
0
0
0
0
0
0
3
0.013453
9c9e5420532409a23c5fc534b2790fbcc02c3ff3
3,104
py
Python
solstice/core/shot.py
tpoveda/solstice
ccccc376cebd6701d038fdd6ebaabc33ebdf259f
[ "MIT" ]
null
null
null
solstice/core/shot.py
tpoveda/solstice
ccccc376cebd6701d038fdd6ebaabc33ebdf259f
[ "MIT" ]
null
null
null
solstice/core/shot.py
tpoveda/solstice
ccccc376cebd6701d038fdd6ebaabc33ebdf259f
[ "MIT" ]
null
null
null
#! /usr/bin/env python # -*- coding: utf-8 -*- """ Base class that defines Artella Shot for Solstice """ from __future__ import print_function, division, absolute_import __author__ = "Tomas Poveda" __license__ = "MIT" __maintainer__ = "Tomas Poveda" __email__ = "tpovedatd@gmail.com" import logging import artellapi...
31.353535
107
0.662371
2,544
0.819588
0
0
0
0
0
0
873
0.28125
9c9e6fd73ba9c604609823280549a5b9ea38d594
764
py
Python
tests/integration/conftest.py
pshelby/boto3_paginator
9680e6f2f4075e1c3bb7a082f913a514e0d912f5
[ "MIT" ]
null
null
null
tests/integration/conftest.py
pshelby/boto3_paginator
9680e6f2f4075e1c3bb7a082f913a514e0d912f5
[ "MIT" ]
null
null
null
tests/integration/conftest.py
pshelby/boto3_paginator
9680e6f2f4075e1c3bb7a082f913a514e0d912f5
[ "MIT" ]
null
null
null
"""Fixtures for integration tests.""" from pytest import fixture @fixture(scope="module") def test_bucket(): """Create an S3 bucket for integration tests.""" import boto3 bucket_name = 'boto3-paginator-integration-test' s3_client = boto3.client('s3') _ = s3_client.create_bucket(Bucket=bucket_na...
27.285714
57
0.659686
0
0
670
0.876963
695
0.909686
0
0
221
0.289267
9c9f0bd5bac5004d0be7ff13716a4af3686f9d6a
17,094
py
Python
src/shaders/MaterialX/build_materialX_osl.py
FrankFirsching/OpenShadingLanguage
2789d4345a2865af669c8b3bb402a5bff9faf927
[ "BSD-3-Clause" ]
2
2019-10-05T20:01:05.000Z
2021-07-29T19:28:18.000Z
src/shaders/MaterialX/build_materialX_osl.py
brechtvl/OpenShadingLanguage
71c4fb263fcdc88decf2b86d346836f7a2b4d463
[ "BSD-3-Clause" ]
null
null
null
src/shaders/MaterialX/build_materialX_osl.py
brechtvl/OpenShadingLanguage
71c4fb263fcdc88decf2b86d346836f7a2b4d463
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python ''' Generate compilable .osl files from .mx templates Adam Martinez TODO: Some functionalization in place, can it be expanded? Add ability to specify shader and shader type to compile to osl Is there a more compact representation of the BUILD_DICT we can employ? ''' import os imp...
40.507109
155
0.514333
0
0
0
0
0
0
0
0
8,650
0.506026
9ca0a45bddeef0f2653047fb40011df6a5d96a62
782
py
Python
QuickStarts/HM.py
nj-czy/UCTB
bddb8b47953bef1f44cb06f1a57a3d7efbd31c3a
[ "MIT" ]
28
2020-02-28T03:16:43.000Z
2022-03-31T07:24:47.000Z
QuickStarts/HM.py
nj-czy/UCTB
bddb8b47953bef1f44cb06f1a57a3d7efbd31c3a
[ "MIT" ]
8
2020-06-30T09:34:56.000Z
2022-01-17T12:20:28.000Z
QuickStarts/HM.py
nj-czy/UCTB
bddb8b47953bef1f44cb06f1a57a3d7efbd31c3a
[ "MIT" ]
13
2020-06-04T09:47:36.000Z
2022-02-25T09:50:52.000Z
from UCTB.dataset import NodeTrafficLoader from UCTB.model import HM from UCTB.evaluation import metric from UCTB.utils import save_predict_in_dataset data_loader = NodeTrafficLoader(dataset='Bike', city='NYC', closeness_len=0, period_len=0, trend_len=4, with_lm=False, normalize=F...
41.157895
104
0.704604
0
0
0
0
0
0
0
0
73
0.09335
9ca2a39bfe7f388015f1c315841d7c7f13c699eb
14,764
py
Python
contrib/grv_proxy_model/proxy_model.py
PierreZ/foundationdb
d97d9681766766836f991ec65f64b66b654b966c
[ "Apache-2.0" ]
11,024
2018-04-19T16:06:46.000Z
2022-03-31T23:43:55.000Z
contrib/grv_proxy_model/proxy_model.py
PierreZ/foundationdb
d97d9681766766836f991ec65f64b66b654b966c
[ "Apache-2.0" ]
4,430
2018-04-19T17:12:33.000Z
2022-03-31T23:56:34.000Z
contrib/grv_proxy_model/proxy_model.py
PierreZ/foundationdb
d97d9681766766836f991ec65f64b66b654b966c
[ "Apache-2.0" ]
1,146
2018-04-19T16:45:57.000Z
2022-03-30T10:43:57.000Z
# # proxy_model.py # # This source file is part of the FoundationDB open source project # # Copyright 2013-2020 Apple Inc. and the FoundationDB project 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 o...
43.551622
260
0.684503
13,904
0.94175
0
0
188
0.012734
0
0
2,353
0.159374
9ca4c6440cb1de8f401d9054c72769d131e5b57a
2,808
py
Python
zookeeper-contrib/zookeeper-contrib-rest/src/python/demo_queue.py
lzk630/zookeeper
424631f0361ef9c97c439f2e2570bdadfb47f774
[ "Apache-2.0" ]
255
2015-07-16T06:23:51.000Z
2022-03-22T06:43:23.000Z
src/contrib/rest/src/python/demo_queue.py
phunt/zookeeper
8bf467bca26079ce6fca94dfef96efa13d4df664
[ "Apache-2.0" ]
46
2015-11-18T01:46:53.000Z
2022-03-21T21:19:55.000Z
src/contrib/rest/src/python/demo_queue.py
phunt/zookeeper
8bf467bca26079ce6fca94dfef96efa13d4df664
[ "Apache-2.0" ]
132
2015-01-07T08:54:50.000Z
2021-06-23T07:48:34.000Z
#! /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 # "...
28.08
86
0.633903
1,180
0.420228
0
0
0
0
0
0
1,575
0.560897
9ca51e950be017b28a0d4cdd38cd2171db8c47ae
6,010
py
Python
trade_remedies_api/core/migrations/0001_initial.py
uktrade/trade-remedies-api
fbe2d142ef099c7244788a0f72dd1003eaa7edce
[ "MIT" ]
1
2020-08-13T10:37:15.000Z
2020-08-13T10:37:15.000Z
trade_remedies_api/core/migrations/0001_initial.py
uktrade/trade-remedies-api
fbe2d142ef099c7244788a0f72dd1003eaa7edce
[ "MIT" ]
4
2020-09-10T13:41:52.000Z
2020-12-16T09:00:21.000Z
trade_remedies_api/core/migrations/0001_initial.py
uktrade/trade-remedies-api
fbe2d142ef099c7244788a0f72dd1003eaa7edce
[ "MIT" ]
null
null
null
# Generated by Django 2.0.1 on 2018-10-15 14:44 from django.conf import settings import django.contrib.postgres.fields.jsonb from django.db import migrations, models import django.db.models.deletion import django.utils.timezone import django_countries.fields import security.models import timezone_field.fields import u...
39.281046
134
0.450749
5,683
0.945591
0
0
0
0
0
0
958
0.159401
9ca773ac0f073470bf450494c33f4940782589f8
4,857
py
Python
apps/quiz/graphql/querys.py
nxexox/questionnaire-site
9598e64c950da42d8282bb438f4498f854ea698a
[ "MIT" ]
null
null
null
apps/quiz/graphql/querys.py
nxexox/questionnaire-site
9598e64c950da42d8282bb438f4498f854ea698a
[ "MIT" ]
null
null
null
apps/quiz/graphql/querys.py
nxexox/questionnaire-site
9598e64c950da42d8282bb438f4498f854ea698a
[ "MIT" ]
null
null
null
""" ALL Query для GraphQL. """ import logging import datetime import graphene from graphql import GraphQLError from .types import ( AccountTestType, TestCaseType, StartTestType ) from ..models import ( AccountTest, TestCase, Test ) logger = logging.getLogger(__name__) class RootQuery(graphene.AbstractType...
30.54717
111
0.624665
5,179
0.926144
0
0
0
0
0
0
2,943
0.526288
9ca89f63a6d302d06960f1d3111151094f3756f2
218
py
Python
Bioinformatics Stronghold/Global Alignment with Scoring Matrix.py
Vinay-Vinod/Rosalind
6818a38d1378a55e84e9f75636bacce2c274d24c
[ "MIT" ]
null
null
null
Bioinformatics Stronghold/Global Alignment with Scoring Matrix.py
Vinay-Vinod/Rosalind
6818a38d1378a55e84e9f75636bacce2c274d24c
[ "MIT" ]
null
null
null
Bioinformatics Stronghold/Global Alignment with Scoring Matrix.py
Vinay-Vinod/Rosalind
6818a38d1378a55e84e9f75636bacce2c274d24c
[ "MIT" ]
null
null
null
from Bio import pairwise2 from Bio import SeqIO from Bio.SubsMat.MatrixInfo import blosum62 s = 'PLEASANTLY' t = 'MEANLY' a = pairwise2.align.globalds(s, t, blosum62, -5, -5) print(pairwise2.format_alignment(*a[0]))
21.8
52
0.747706
0
0
0
0
0
0
0
0
20
0.091743
9ca98cc0d23366e6e53f54eb84870f9bb11bce99
42
py
Python
netijen/lazuardyk/findmin.py
yesyou11/hacktoberfest-2019
8f05b9b2453577d589c63f196c916a95377da98a
[ "WTFPL" ]
1
2019-10-01T16:30:00.000Z
2019-10-01T16:30:00.000Z
netijen/lazuardyk/findmin.py
yesyou11/hacktoberfest-2019
8f05b9b2453577d589c63f196c916a95377da98a
[ "WTFPL" ]
null
null
null
netijen/lazuardyk/findmin.py
yesyou11/hacktoberfest-2019
8f05b9b2453577d589c63f196c916a95377da98a
[ "WTFPL" ]
null
null
null
def findmin(angka): return min(angka)
14
21
0.690476
0
0
0
0
0
0
0
0
0
0
9cab50c58e4f3c4b31b27fba5d18763090e63b20
4,547
py
Python
source_optics/models/author.py
mpdehaan/source_optics
ce0215ad63e47f0ab645c765129bac3c7236aff1
[ "Apache-2.0" ]
1
2021-08-24T03:41:34.000Z
2021-08-24T03:41:34.000Z
source_optics/models/author.py
mpdehaan/source_optics
ce0215ad63e47f0ab645c765129bac3c7236aff1
[ "Apache-2.0" ]
null
null
null
source_optics/models/author.py
mpdehaan/source_optics
ce0215ad63e47f0ab645c765129bac3c7236aff1
[ "Apache-2.0" ]
null
null
null
# Copyright 2018-2019 SourceOptics Project Contributors # # 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...
36.087302
116
0.632065
3,773
0.829778
0
0
2,381
0.523642
0
0
885
0.194634
9cab8d3a411dd7c4773e6e7308b7a8e97ceb31d6
2,820
py
Python
commands/image.py
mhwdvs/MITSBot
a0b3899b24df61976b0a6c98c61a75b9e8fa32a0
[ "MIT" ]
null
null
null
commands/image.py
mhwdvs/MITSBot
a0b3899b24df61976b0a6c98c61a75b9e8fa32a0
[ "MIT" ]
null
null
null
commands/image.py
mhwdvs/MITSBot
a0b3899b24df61976b0a6c98c61a75b9e8fa32a0
[ "MIT" ]
null
null
null
import random import requests from mitsbot_globals import bingAPIKey, animals, animalFilter, addEventListener from discordHelpers import sendImageEmbed async def getImage(searchTerm, imageType): randomPage = random.randint(0, 200) searchURL = "https://api.bing.microsoft.com/v7.0/images/search" headers = ...
42.089552
120
0.620567
0
0
0
0
0
0
2,451
0.869149
611
0.216667
9cae496e1b2f412f1fae88cb2da5c9ceee2ccec9
2,020
py
Python
influxdb-2.0/data_recv.py
anubhavs9/iot-reference-codes
032802152976b7dea9d9e6cb0e60659efb82c295
[ "MIT" ]
null
null
null
influxdb-2.0/data_recv.py
anubhavs9/iot-reference-codes
032802152976b7dea9d9e6cb0e60659efb82c295
[ "MIT" ]
null
null
null
influxdb-2.0/data_recv.py
anubhavs9/iot-reference-codes
032802152976b7dea9d9e6cb0e60659efb82c295
[ "MIT" ]
null
null
null
import json import influxdb_client from influxdb_client.client.write_api import SYNCHRONOUS class QueryData(): CONFIG_FILE = "./config.json" def __init__(self): self.readConfigFile() self.createInfluxClient() def readConfigFile(self): try: with open(self.CONFIG_FILE, 'r...
33.114754
72
0.562871
1,548
0.766337
0
0
0
0
0
0
426
0.210891
9caf022c3f2864b15bee88ecc375d06b4492e187
1,839
py
Python
filesystem.py
mvdnes/mdms
95f80efaf9c1b527515d7fd6155f3e9245e86164
[ "MIT" ]
null
null
null
filesystem.py
mvdnes/mdms
95f80efaf9c1b527515d7fd6155f3e9245e86164
[ "MIT" ]
null
null
null
filesystem.py
mvdnes/mdms
95f80efaf9c1b527515d7fd6155f3e9245e86164
[ "MIT" ]
1
2018-07-25T10:01:07.000Z
2018-07-25T10:01:07.000Z
import os import shutil def get_instance(configuration): return Filesystem(configuration) class Filesystem: def __init__(self, configuration): if "filesystem" not in configuration: raise KeyError("Filesystem not found in configuration") if "location" not in configuration['filesyste...
28.734375
67
0.585644
1,742
0.947254
0
0
0
0
0
0
174
0.094617
9caf05395c79fc2af4c7564cdcfd716e7e6bd154
2,049
py
Python
omniscient/kg/triple_store.py
Impavidity/Omniscient
4e51791739dc9c1b1399df42ff36e0920b4c1c5c
[ "Apache-2.0" ]
2
2018-11-14T05:29:52.000Z
2019-05-21T03:42:28.000Z
omniscient/kg/triple_store.py
Impavidity/Omniscient
4e51791739dc9c1b1399df42ff36e0920b4c1c5c
[ "Apache-2.0" ]
null
null
null
omniscient/kg/triple_store.py
Impavidity/Omniscient
4e51791739dc9c1b1399df42ff36e0920b4c1c5c
[ "Apache-2.0" ]
2
2019-08-08T00:41:26.000Z
2020-03-17T18:12:31.000Z
from omniscient.base.constants import * from omniscient.base.logger import Log from elasticsearch import Elasticsearch, helpers import json logger = Log("info") class ESTripleStore(object): """ Triple store backend. """ def __init__(self, host, port, settings): self.es = Elasticsearch(['{}:{}'.format(hos...
28.068493
124
0.630063
1,881
0.918009
0
0
0
0
0
0
290
0.141532
9caf406a1ea001c308fc80f8ba7e257e04a231a5
1,223
py
Python
commands/joinserver.py
Heufneutje/DideRobot
acbb608d5c73cef8739d9dd3149d781afc75acae
[ "MIT" ]
null
null
null
commands/joinserver.py
Heufneutje/DideRobot
acbb608d5c73cef8739d9dd3149d781afc75acae
[ "MIT" ]
null
null
null
commands/joinserver.py
Heufneutje/DideRobot
acbb608d5c73cef8739d9dd3149d781afc75acae
[ "MIT" ]
null
null
null
from CommandTemplate import CommandTemplate import GlobalStore from IrcMessage import IrcMessage class Command(CommandTemplate): triggers = ['joinserver'] helptext = "Makes me join a server, if it's preconfigured." adminOnly = True def execute(self, message): """ :type message: IrcMessage """ replytext =...
42.172414
200
0.745707
1,124
0.919052
0
0
0
0
0
0
596
0.487326
9cafc3e6882c69b4dd9c6fff6f58dcd2b8f75de5
398
py
Python
onegreek/old.comments/old.comments/__init__.py
goldhand/onegreek
1ad105f15608284a9e80802734f0c6222413a4a0
[ "BSD-3-Clause" ]
1
2019-06-13T11:46:08.000Z
2019-06-13T11:46:08.000Z
onegreek/old.comments/old.comments/__init__.py
goldhand/onegreek
1ad105f15608284a9e80802734f0c6222413a4a0
[ "BSD-3-Clause" ]
null
null
null
onegreek/old.comments/old.comments/__init__.py
goldhand/onegreek
1ad105f15608284a9e80802734f0c6222413a4a0
[ "BSD-3-Clause" ]
null
null
null
from django.core.urlresolvers import reverse_lazy from .models import PComment as Comment from .forms import PCommentForm as CommentForm def get_model(): """ Return the model to use for commenting. """ return Comment def get_form(): """ Return the form to use for commenting. """ retur...
20.947368
49
0.70603
0
0
0
0
0
0
0
0
124
0.311558
9cb19cdf8855026084363e3183821b88d0d91181
1,361
py
Python
src/panoptes/pocs/state/states/default/observing.py
programatt/POCS
6450a27e3d3a9bb33e251f5d3508266445fe8136
[ "MIT" ]
null
null
null
src/panoptes/pocs/state/states/default/observing.py
programatt/POCS
6450a27e3d3a9bb33e251f5d3508266445fe8136
[ "MIT" ]
null
null
null
src/panoptes/pocs/state/states/default/observing.py
programatt/POCS
6450a27e3d3a9bb33e251f5d3508266445fe8136
[ "MIT" ]
null
null
null
from multiprocessing import Process from panoptes.utils import error def on_enter(event_data): """Take an observation image. This state is responsible for taking the actual observation image. """ pocs = event_data.model current_obs = pocs.observatory.current_observation pocs.say(f"🔭🔭 I'm ...
40.029412
97
0.68626
0
0
0
0
0
0
0
0
636
0.463219
9cb3b866b240fca4b686d2dbdbde5c913b7e9e68
4,183
py
Python
src/datasets/cityscape.py
Brazilian-Institute-of-Robotics/autonomous_perception
5645a2bc6811b33e9e6bf0f6873f496dff45ad94
[ "MIT" ]
null
null
null
src/datasets/cityscape.py
Brazilian-Institute-of-Robotics/autonomous_perception
5645a2bc6811b33e9e6bf0f6873f496dff45ad94
[ "MIT" ]
null
null
null
src/datasets/cityscape.py
Brazilian-Institute-of-Robotics/autonomous_perception
5645a2bc6811b33e9e6bf0f6873f496dff45ad94
[ "MIT" ]
1
2020-12-23T23:27:30.000Z
2020-12-23T23:27:30.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Mon Jun 23 00:54:08 2019 @author: nelson """ import tensorflow_datasets.public_api as tfds import os import tensorflow as tf classes = [{'name': 'road' , 'color': [128, 64,128]}, {'name': 'sidewalk' , 'color': [244, 35,232]}, ...
39.838095
89
0.491274
2,730
0.652642
571
0.136505
0
0
0
0
1,501
0.358833
9cb42d7e7d29bdef3eb52b0cd527e745541b8523
4,697
py
Python
scripts/utils.py
JIC-Image-Analysis/leaf-cell-polarisation-tensors
cf5495a77a0bb77aa99206146267e41995ee5ebd
[ "MIT" ]
null
null
null
scripts/utils.py
JIC-Image-Analysis/leaf-cell-polarisation-tensors
cf5495a77a0bb77aa99206146267e41995ee5ebd
[ "MIT" ]
null
null
null
scripts/utils.py
JIC-Image-Analysis/leaf-cell-polarisation-tensors
cf5495a77a0bb77aa99206146267e41995ee5ebd
[ "MIT" ]
null
null
null
"""Utility functions.""" import os.path import logging import numpy as np from jicbioimage.core.image import MicroscopyCollection from jicbioimage.core.transform import transformation from jicbioimage.core.io import ( AutoWrite, FileBackend, DataManager, _md5_hexdigest_from_file, ) from jicbioimage.t...
30.303226
76
0.70875
0
0
0
0
690
0.146902
0
0
599
0.127528
9cb4e7e16692d11e46d9cf8f2373fcd636831fcc
831
py
Python
cos/patches.py
baylee-d/cos.io
3f88acb0feb7a167bf9e81c42e28f9d2d38bbd43
[ "Apache-2.0" ]
null
null
null
cos/patches.py
baylee-d/cos.io
3f88acb0feb7a167bf9e81c42e28f9d2d38bbd43
[ "Apache-2.0" ]
null
null
null
cos/patches.py
baylee-d/cos.io
3f88acb0feb7a167bf9e81c42e28f9d2d38bbd43
[ "Apache-2.0" ]
null
null
null
from django.utils.html import strip_tags def highlightingapply(): def highlight(self, text_block): if not text_block: return '' self.text_block = strip_tags(text_block) highlight_locations = self.find_highlightable_words() found = False for k, v in highlight_lo...
30.777778
75
0.616125
0
0
0
0
0
0
0
0
2
0.002407
9cb6b2fa52f4755d592b0155718670f52aeb9f41
5,242
py
Python
tests/unit/data/metadataset_test.py
Brikwerk/learn2learn
7997c13c26ec627d13ce77ba98427260df78ada8
[ "MIT" ]
1
2021-07-07T17:03:45.000Z
2021-07-07T17:03:45.000Z
tests/unit/data/metadataset_test.py
Brikwerk/learn2learn
7997c13c26ec627d13ce77ba98427260df78ada8
[ "MIT" ]
null
null
null
tests/unit/data/metadataset_test.py
Brikwerk/learn2learn
7997c13c26ec627d13ce77ba98427260df78ada8
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import unittest from unittest import TestCase import learn2learn as l2l import numpy as np from numpy.testing import assert_array_equal from learn2learn.data import MetaDataset from .util_datasets import TestDatasets class TestMetaDataset(TestCase): @classmethod def setUpClass(cls) -...
44.803419
112
0.643457
4,947
0.943724
0
0
405
0.077261
0
0
290
0.055322
9cb773294b5f9609161513dcd00107f097b6bbc0
4,974
py
Python
shutter.py
devgiants/home-automation-items
c516e344d24649746af501d46b88fc1bc0ab3368
[ "MIT" ]
null
null
null
shutter.py
devgiants/home-automation-items
c516e344d24649746af501d46b88fc1bc0ab3368
[ "MIT" ]
null
null
null
shutter.py
devgiants/home-automation-items
c516e344d24649746af501d46b88fc1bc0ab3368
[ "MIT" ]
null
null
null
#!/usr/bin/python3 import logging import sys import threading from gpiozero import LED, Button from signal import pause class Shutter: UP = 'open' DOWN = 'close' STOP = 'stop' name = None logger = None buttonUp = None buttonDown = None relayUp = None relayDown = None timeout ...
34.068493
146
0.608162
4,852
0.975472
0
0
0
0
0
0
432
0.086852
9cb7c784e0a6d8c1980b922a58d1d3caf3ac317b
1,094
py
Python
project/apps/registration/migrations/0003_auto_20190904_0615.py
dbinetti/barberscore
13c3d8193834bd2bb79922e28d3f5ab1675bdffd
[ "BSD-2-Clause" ]
13
2017-08-07T15:45:49.000Z
2019-07-03T13:58:50.000Z
project/apps/registration/migrations/0003_auto_20190904_0615.py
barberscore/barberscore-api
2aa9f8598c18c28ba1d4a294f76fd055619f803e
[ "BSD-2-Clause" ]
309
2017-07-14T02:34:12.000Z
2022-01-14T21:37:02.000Z
project/apps/registration/migrations/0003_auto_20190904_0615.py
dbinetti/barberscore-django
16fbd9945becda0a765bbdf52ad459a63655128f
[ "BSD-2-Clause" ]
5
2017-08-07T14:01:07.000Z
2019-06-24T19:44:55.000Z
# Generated by Django 2.2.4 on 2019-09-04 13:15 from django.db import migrations def forward(apps, schema_editor): Entry = apps.get_model('registration.entry') Group = apps.get_model('bhs.group') Chart = apps.get_model('bhs.chart') es = Entry.objects.all() for e in es: try: g ...
26.682927
52
0.581353
184
0.16819
0
0
0
0
0
0
128
0.117002
9cb8db803f38715facca07d97b74c472e6e12272
416
py
Python
py_ws/sep_while.py
hjhan/python-for-kids
51d8cb3361fc7b7c4fb0a714670498450611d219
[ "MIT" ]
null
null
null
py_ws/sep_while.py
hjhan/python-for-kids
51d8cb3361fc7b7c4fb0a714670498450611d219
[ "MIT" ]
null
null
null
py_ws/sep_while.py
hjhan/python-for-kids
51d8cb3361fc7b7c4fb0a714670498450611d219
[ "MIT" ]
null
null
null
# print("请输入一个正整数:", end=' ') n = int(input("请输入一个正整数:")) i = 0 digits = [] # 列表 list while (n >= 10 ** i): # digit = int(n % 10 ** (i + 1) / 10 ** i) digit = n % 10 ** (i + 1) // 10 ** i # 取出每一位数字 #digits.insert(0, digit) digits.append(digit) i += 1 print("每位为%s" % digits) len = len(...
23.111111
52
0.478365
0
0
0
0
0
0
0
0
196
0.411765
9cbade0bc4a1a6746c6d1a8abe962b54698d0d4e
3,469
py
Python
src/generator/dependency_tracker.py
SirGFM/SirGFM.github.io
d2432be03bb0ced68b546bd25769e59dfade4982
[ "Zlib" ]
null
null
null
src/generator/dependency_tracker.py
SirGFM/SirGFM.github.io
d2432be03bb0ced68b546bd25769e59dfade4982
[ "Zlib" ]
null
null
null
src/generator/dependency_tracker.py
SirGFM/SirGFM.github.io
d2432be03bb0ced68b546bd25769e59dfade4982
[ "Zlib" ]
null
null
null
import json import sys import re class BufferedWriter(): def __init__(self, txt='', max_len=80, out=sys.stdout): self._txt = txt self._len = len(txt) self._max_len = max_len self._out = out def write(self, txt, force=False): """Write some text. If the line were to go b...
33.355769
113
0.502162
844
0.243298
0
0
0
0
0
0
939
0.270683
9cbc11953dd73fb6f511c74d730fad379ee2138f
91
py
Python
config.py
agithug/fan-controller
046ecd9120c3a3fa0c581cbcd3dc89bd50a7373c
[ "MIT" ]
null
null
null
config.py
agithug/fan-controller
046ecd9120c3a3fa0c581cbcd3dc89bd50a7373c
[ "MIT" ]
null
null
null
config.py
agithug/fan-controller
046ecd9120c3a3fa0c581cbcd3dc89bd50a7373c
[ "MIT" ]
null
null
null
#used as a configuration file def fan: pin = 4 dependencies = [“python3”,”gpiozero”]
13
37
0.67033
0
0
0
0
0
0
0
0
29
0.292929
9cbc945a0d3063f43ad61663e0acc93e00ed41c0
6,742
py
Python
src/HAnDS/helper.py
abhipec/hands
ff9658d4226c78b96c02ccf3b91b7d2699f0e4cf
[ "MIT" ]
13
2019-05-02T01:44:04.000Z
2022-02-21T13:39:47.000Z
src/HAnDS/helper.py
abhipec/hands
ff9658d4226c78b96c02ccf3b91b7d2699f0e4cf
[ "MIT" ]
1
2021-06-01T13:04:51.000Z
2021-06-08T16:07:35.000Z
src/HAnDS/helper.py
abhipec/hands
ff9658d4226c78b96c02ccf3b91b7d2699f0e4cf
[ "MIT" ]
1
2019-12-26T07:24:03.000Z
2019-12-26T07:24:03.000Z
""" Contains various helper function related to CADS framework. """ import os import errno import pickle from nameparser import HumanName #pylint:disable=raising-bad-type def ensure_directory(directory): """ Create the directories along the provided directory path that do not exist. """ directory = os....
29.831858
96
0.641946
0
0
0
0
0
0
0
0
1,694
0.251261
9cbd3addb82fc2785f1af32671b0ecfb8f84bd9d
1,974
py
Python
zmon_worker_monitor/adapters/ifunctionfactory_plugin.py
heroldus/zmon-worker
458f8bacb5a00f7fd93d59db406a2c80870519d1
[ "Apache-2.0" ]
17
2016-06-03T14:59:21.000Z
2020-11-06T13:12:18.000Z
zmon_worker_monitor/adapters/ifunctionfactory_plugin.py
heroldus/zmon-worker
458f8bacb5a00f7fd93d59db406a2c80870519d1
[ "Apache-2.0" ]
394
2016-06-03T14:47:37.000Z
2020-04-21T09:31:23.000Z
zmon_worker_monitor/adapters/ifunctionfactory_plugin.py
heroldus/zmon-worker
458f8bacb5a00f7fd93d59db406a2c80870519d1
[ "Apache-2.0" ]
55
2016-08-15T12:42:28.000Z
2021-04-06T10:49:35.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- from ibase_plugin import IBasePlugin from abc import ABCMeta, abstractmethod class IFunctionFactoryPlugin(IBasePlugin): """ Base class for all plugins of type Function. We call it Function adapter. """ __metaclass__ = ABCMeta def __init__(self): ...
32.9
118
0.678825
1,558
0.78926
0
0
280
0.141844
0
0
995
0.504053
9cbd9e49ae6c4d9c717ce04a992db53d48888f0a
17,459
py
Python
design.py
tvanzyl/adaptive_bandwidth_kde
8aef713b78705ac3192bf5eb6b42b93b3611d8dc
[ "MIT" ]
null
null
null
design.py
tvanzyl/adaptive_bandwidth_kde
8aef713b78705ac3192bf5eb6b42b93b3611d8dc
[ "MIT" ]
null
null
null
design.py
tvanzyl/adaptive_bandwidth_kde
8aef713b78705ac3192bf5eb6b42b93b3611d8dc
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Mon Jun 6 16:59:19 2016 @author: tvzyl """ import data from sklearn.datasets import make_spd_matrix from pandas import DataFrame from numpy import mean, diag, eye, rot90, dot, array, abs from numpy import zeros, ones, arange from numpy.random import uniform from scipy.stats ...
48.768156
281
0.627986
17,009
0.974114
0
0
0
0
0
0
7,135
0.408625
9cc4a956152fdbca76b3675be69befe26d5b5929
41
py
Python
0x02-python-import_modules/101-easy_print.py
Nahi-Terefe/alx-higher_level_programming
c67a78a6f79e853918963971f8352979e7691541
[ "MIT" ]
null
null
null
0x02-python-import_modules/101-easy_print.py
Nahi-Terefe/alx-higher_level_programming
c67a78a6f79e853918963971f8352979e7691541
[ "MIT" ]
null
null
null
0x02-python-import_modules/101-easy_print.py
Nahi-Terefe/alx-higher_level_programming
c67a78a6f79e853918963971f8352979e7691541
[ "MIT" ]
null
null
null
#!/usr/bin/python3 import easy_print_101
13.666667
21
0.804878
0
0
0
0
0
0
0
0
18
0.439024
9cc5c9273609531bbca19e97c35f0e5eef3aa812
675
py
Python
offline_tools/processing/create_samples.py
kauevestena/snav
73b93bc4e5c9d9fc51cbd3559a1d74209d2a7fc9
[ "MIT" ]
2
2019-05-13T20:46:01.000Z
2021-02-10T14:06:37.000Z
offline_tools/processing/create_samples.py
kauevestena/snav
73b93bc4e5c9d9fc51cbd3559a1d74209d2a7fc9
[ "MIT" ]
null
null
null
offline_tools/processing/create_samples.py
kauevestena/snav
73b93bc4e5c9d9fc51cbd3559a1d74209d2a7fc9
[ "MIT" ]
null
null
null
import os import glob import random from processing_functions import misc as msc from shutil import copyfile # define the number of samples you want n_samples = 50 imgsPath = os.environ['HOME']+'/data/extracted_images/2019-07-11-16-21-46/ngr' out_path = os.environ['HOME']+'/data/extracted_images/samples/'+msc.find...
19.285714
98
0.742222
0
0
0
0
0
0
0
0
171
0.253333
9cc5d0cf3bc75d730a617fb4405aa3d01d0ee2a9
16,626
py
Python
AppcestryCore/compare.py
jason-chao/appcestry
c3858e51ac27466cb008722453a3cc9882b2e6a1
[ "MIT" ]
3
2019-04-04T02:49:40.000Z
2021-08-31T03:19:47.000Z
AppcestryCore/compare.py
jason-chao/appcestry
c3858e51ac27466cb008722453a3cc9882b2e6a1
[ "MIT" ]
null
null
null
AppcestryCore/compare.py
jason-chao/appcestry
c3858e51ac27466cb008722453a3cc9882b2e6a1
[ "MIT" ]
2
2019-04-05T15:06:54.000Z
2019-08-04T12:21:55.000Z
#!/usr/bin/env python3 # This script compares AppGene files for similiarty # Run this script in terminal / command line to see the usage of arguments. import os import argparse from sklearn.feature_extraction.text import HashingVectorizer import json import re from sklearn.metrics.pairwise import cosine_similarity im...
41.669173
206
0.630218
0
0
0
0
0
0
0
0
7,809
0.469686
9cc696533b798f11c9e94346fe3734171f19a56d
328
py
Python
api/common/JQSDK_Connect.py
abcdcamey/stock-data
bfdc67e60b7d4de59c66dbb52159574b4e0a5e51
[ "MIT" ]
1
2019-04-10T09:07:59.000Z
2019-04-10T09:07:59.000Z
api/common/JQSDK_Connect.py
abcdcamey/stock-data
bfdc67e60b7d4de59c66dbb52159574b4e0a5e51
[ "MIT" ]
2
2021-06-01T23:39:34.000Z
2021-12-13T19:58:31.000Z
api/common/JQSDK_Connect.py
abcdcamey/stock-data
bfdc67e60b7d4de59c66dbb52159574b4e0a5e51
[ "MIT" ]
null
null
null
#coding=utf-8 from jqdatasdk import * class JQSDK_Connect: def __init__(self): #auth('18818273592','Chenmin585858') #账号是申请时所填写的手机号;密码为聚宽官网登录密码,新申请用户默认为手机号后6位 auth('15821295829', 'Niuniuniu2020') #auth('13816896174', '896174') def get_query_count(self): return get_query_count(...
16.4
86
0.670732
360
0.8867
0
0
0
0
0
0
227
0.559113
9cc7ac4c9568f74a7e2bfcb29110a9c6f879e2fd
4,561
py
Python
python/coloralgorithm/coloralgorithm.py
jonolt/dmx-colormatch
170ac4748f7d4d03e14104a2096cdd11b63d7a0e
[ "Xnet", "X11" ]
null
null
null
python/coloralgorithm/coloralgorithm.py
jonolt/dmx-colormatch
170ac4748f7d4d03e14104a2096cdd11b63d7a0e
[ "Xnet", "X11" ]
1
2021-03-05T19:37:02.000Z
2021-03-05T19:37:02.000Z
python/coloralgorithm/coloralgorithm.py
jonolt/dmx-colormatch
170ac4748f7d4d03e14104a2096cdd11b63d7a0e
[ "Xnet", "X11" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- from fixture import FixtureRGB import math import time import numpy as np def rel_diff(cur, ref) -> float: if ref == 0: return cur return (ref - cur) / ref def get_max_index(array): max_index = 0 for i in range(len(array)): if array[i] ...
24.923497
147
0.521377
0
0
0
0
0
0
0
0
727
0.159395
9cc7f5b2b9f4e310e35dc3ebd0e3ad778fc7d355
3,880
py
Python
oasislmf/utils/defaults.py
strategist922/OasisLMF
7f30ab061307d27943b3fc1b0262c6200e2cdcf3
[ "BSD-3-Clause" ]
1
2019-10-25T03:15:14.000Z
2019-10-25T03:15:14.000Z
oasislmf/utils/defaults.py
strategist922/OasisLMF
7f30ab061307d27943b3fc1b0262c6200e2cdcf3
[ "BSD-3-Clause" ]
null
null
null
oasislmf/utils/defaults.py
strategist922/OasisLMF
7f30ab061307d27943b3fc1b0262c6200e2cdcf3
[ "BSD-3-Clause" ]
null
null
null
__all__ = [ 'get_config_profile', 'get_default_accounts_profile', 'get_default_deterministic_analysis_settings', 'get_default_exposure_profile', 'get_default_fm_aggregation_profile', 'get_default_unified_profile', 'get_loc_dtypes', 'get_acc_dtypes', 'get_scope_dtypes', 'get_info_...
26.758621
107
0.70799
0
0
0
0
0
0
0
0
1,695
0.436856
9cc9655c102180c64f11f7ecabab9a8083456ce9
318
py
Python
PythonModulo1/ex006.py
BossNX/ExerciciosDePython
27c79d284794f65f94d3a07de11429d665ec92da
[ "MIT" ]
null
null
null
PythonModulo1/ex006.py
BossNX/ExerciciosDePython
27c79d284794f65f94d3a07de11429d665ec92da
[ "MIT" ]
null
null
null
PythonModulo1/ex006.py
BossNX/ExerciciosDePython
27c79d284794f65f94d3a07de11429d665ec92da
[ "MIT" ]
null
null
null
n = int(input('Digite um número: ')) d = n * 2 t = n * 3 r = n ** (1/2) print('O dobro de \033[4;31m{}\033[m vale \033[34m{}\033[m. '.format(n, d)) print('O triplo de \033[4;33m{}\033[m vale \033[36m{}\033[m. '.format(n, t)) print('A raíz quadrada de \033[4;35m{}\033[m é igual a \033[32m{:.2f}\033[m. '.format(n, r))
39.75
92
0.578616
0
0
0
0
0
0
0
0
206
0.641745
9cca040e273e226a19dc1e216e57277c3625c810
1,107
py
Python
api/views.py
aleattene/ASD-Management
3824ad1697eecf8c052e56bed9bbe53eddd71d00
[ "MIT" ]
null
null
null
api/views.py
aleattene/ASD-Management
3824ad1697eecf8c052e56bed9bbe53eddd71d00
[ "MIT" ]
21
2021-07-22T08:32:24.000Z
2022-02-16T10:38:24.000Z
api/views.py
aleattene/asd-management-webapp-responsive
3824ad1697eecf8c052e56bed9bbe53eddd71d00
[ "MIT" ]
null
null
null
import requests import json from environs import Env from django.http import HttpResponse, HttpResponseBadRequest, HttpRequest from django.views.decorators.csrf import csrf_exempt, csrf_protect env = Env() @csrf_exempt # @api_view(['POST']) def request_access_token(request): client_secret = env.str("GOOGLE_CLIENT...
29.131579
82
0.707317
0
0
0
0
843
0.761518
0
0
254
0.229449
9ccc6cbd9c91a838175af4e8950b1d1c84a28033
555
py
Python
Lab04.py
gksmfzz1/JavaProject
6b22badf8052a66928ab3ef2f60e83bfa54466c1
[ "Apache-2.0" ]
null
null
null
Lab04.py
gksmfzz1/JavaProject
6b22badf8052a66928ab3ef2f60e83bfa54466c1
[ "Apache-2.0" ]
null
null
null
Lab04.py
gksmfzz1/JavaProject
6b22badf8052a66928ab3ef2f60e83bfa54466c1
[ "Apache-2.0" ]
null
null
null
# 30 while문을 이용 100이상10000미만 5의배수 합구하기 number = 100 isloot = True sumnum = 0 while isloot: if number >= 10000: isloot = False sumnum += number number += 5 print(sumnum) # 34 화씨(F)를 섭씨(c)로 변환하는 프로그램 작성 # 섭씨 = (100/180) x (화씨 - 32) F = 0 C = 0 isloot = True while isloot: F = int(input('섭씨로...
14.605263
49
0.533333
0
0
0
0
0
0
0
0
351
0.481481
9cccec976465dabe3cfc2d20364490a9faddcc8e
157
py
Python
codewof/programming/content/en/price-in-budget/initial.py
taskmaker1/codewof
92d52cd3ee91f0f311ff01a92cf6ec07e5593b8d
[ "MIT" ]
3
2019-08-29T04:11:22.000Z
2021-06-22T16:05:51.000Z
codewof/programming/content/en/price-in-budget/initial.py
taskmaker1/codewof
92d52cd3ee91f0f311ff01a92cf6ec07e5593b8d
[ "MIT" ]
265
2019-05-30T03:51:46.000Z
2022-03-31T01:05:12.000Z
codewof/programming/content/en/price-in-budget/initial.py
samuelsandri/codewof
c9b8b378c06b15a0c42ae863b8f46581de04fdfc
[ "MIT" ]
7
2019-06-29T12:13:37.000Z
2021-09-06T06:49:14.000Z
def is_price_in_budget(price): if price > 100 or price < 500: is_in_budget = True else: is_in_budget = False return is_in_budget
22.428571
34
0.643312
0
0
0
0
0
0
0
0
0
0
9cd017d4ef005fd4cb543de0bc5fedaa0f8e0574
747
py
Python
Aurix code/jsonDijkstra/map2json/Line_t.py
SamiEzz/embeddedTwirtee
118e7709c9bb173701e25c4b1375ee1d384a61a4
[ "MIT" ]
null
null
null
Aurix code/jsonDijkstra/map2json/Line_t.py
SamiEzz/embeddedTwirtee
118e7709c9bb173701e25c4b1375ee1d384a61a4
[ "MIT" ]
1
2020-02-26T16:14:32.000Z
2020-02-26T16:14:32.000Z
python_tools/map2json/Line_t.py
SamiEzz/embeddedTwirtee
118e7709c9bb173701e25c4b1375ee1d384a61a4
[ "MIT" ]
null
null
null
from Point_t import Point_t from Leg import * import math class Line_t(Leg): """Classe représentant une ligne""" def __init__(self, coo_tulpe_start, coo_tulpe_end, id): Leg.__init__(self, id) #classe mere leg self._point_start = Point_t(coo_tulpe_start) #point start du leg se...
43.941176
244
0.686747
683
0.913102
0
0
0
0
0
0
108
0.144385
9cd0e0ae6fade5e80f9f3332ac23be40551b8667
6,344
py
Python
multiMNIST/display_result.py
kelvin95/EPOSearch
020f0a8890437449dd7bb37534697aa9f71e8305
[ "MIT" ]
null
null
null
multiMNIST/display_result.py
kelvin95/EPOSearch
020f0a8890437449dd7bb37534697aa9f71e8305
[ "MIT" ]
null
null
null
multiMNIST/display_result.py
kelvin95/EPOSearch
020f0a8890437449dd7bb37534697aa9f71e8305
[ "MIT" ]
null
null
null
import numpy as np import pickle as pkl import os import matplotlib.pyplot as plt from brokenaxes import brokenaxes from latex_utils import latexify baseline = "indiv" methods = [ # "epo", # "pmtl", "linscalar", # "gradnorm", "gradortho", "grad...
35.049724
83
0.51466
0
0
0
0
0
0
0
0
1,366
0.215322
9cd122ce12f565785b62e9d4b58b2d66d5dbc30f
1,849
py
Python
api/organisations/tests/factories.py
django-doctor/lite-api
1ba278ba22ebcbb977dd7c31dd3701151cd036bf
[ "MIT" ]
3
2019-05-15T09:30:39.000Z
2020-04-22T16:14:23.000Z
api/organisations/tests/factories.py
django-doctor/lite-api
1ba278ba22ebcbb977dd7c31dd3701151cd036bf
[ "MIT" ]
85
2019-04-24T10:39:35.000Z
2022-03-21T14:52:12.000Z
api/organisations/tests/factories.py
django-doctor/lite-api
1ba278ba22ebcbb977dd7c31dd3701151cd036bf
[ "MIT" ]
1
2021-01-17T11:12:19.000Z
2021-01-17T11:12:19.000Z
import random import factory from django.utils import timezone from api.addresses.tests.factories import AddressFactory from api.organisations import models from api.organisations.enums import OrganisationType, OrganisationStatus from api.organisations.tests.providers import OrganisationProvider factory.Faker.add_pr...
33.017857
105
0.746349
1,350
0.730124
0
0
419
0.226609
0
0
134
0.072472
9cd259722e42f71cb19331be9d7293420eff0873
2,187
py
Python
rental/pagination.py
sunscrapers/restonomicon.pl
56a167cd4a07520a66377e7d899d8f1759f00e3d
[ "MIT" ]
null
null
null
rental/pagination.py
sunscrapers/restonomicon.pl
56a167cd4a07520a66377e7d899d8f1759f00e3d
[ "MIT" ]
null
null
null
rental/pagination.py
sunscrapers/restonomicon.pl
56a167cd4a07520a66377e7d899d8f1759f00e3d
[ "MIT" ]
null
null
null
from collections import OrderedDict from rest_framework.pagination import LimitOffsetPagination from rest_framework.response import Response from rest_framework.utils.urls import remove_query_param, replace_query_param class HeaderLimitOffsetPagination(LimitOffsetPagination): def paginate_queryset(self, queryset...
35.274194
77
0.566529
1,964
0.898034
0
0
0
0
0
0
119
0.054412
9cd61c204b329ca886ff80f063d2527cb83d49ab
462
py
Python
sanskrit_parser/generator/test/test_ajanta_stri.py
avinashvarna/sanskrit_parser
79338213128b29927fe2f06031379bb1e3864a83
[ "MIT" ]
54
2017-06-30T09:11:53.000Z
2022-03-22T15:35:41.000Z
sanskrit_parser/generator/test/test_ajanta_stri.py
avinashvarna/sanskrit_parser
79338213128b29927fe2f06031379bb1e3864a83
[ "MIT" ]
159
2017-06-30T07:04:36.000Z
2021-06-17T17:03:43.000Z
sanskrit_parser/generator/test/test_ajanta_stri.py
avinashvarna/sanskrit_parser
79338213128b29927fe2f06031379bb1e3864a83
[ "MIT" ]
18
2017-08-17T13:22:00.000Z
2022-01-20T01:08:58.000Z
from sanskrit_parser.generator.pratyaya import * # noqa: F403, F401 from sanskrit_parser.generator.dhatu import * # noqa: F403, F401 from sanskrit_parser.generator.pratipadika import * # noqa: F403, F401 from sanskrit_parser.base.sanskrit_base import DEVANAGARI from sanskrit_parser.generator.sutras_yaml import sutra...
38.5
71
0.824675
0
0
0
0
0
0
0
0
54
0.116883
9cd6a9907dbb3c98dd8a89732b5e0a3f3014b425
444
py
Python
setup.py
CD3/txt2svg
d53110b320f8442f57a694ae24b557f1d410e0ba
[ "MIT" ]
null
null
null
setup.py
CD3/txt2svg
d53110b320f8442f57a694ae24b557f1d410e0ba
[ "MIT" ]
null
null
null
setup.py
CD3/txt2svg
d53110b320f8442f57a694ae24b557f1d410e0ba
[ "MIT" ]
null
null
null
#! /usr/bin/env python from setuptools import setup, find_packages setup( name='txt2svg', license="MIT", version="0.1", description='A tool for generating svg images from plain text files.', url='https://github.com/CD3/txt2svg', author='C.D. Clark III', packages=find_packages(), instal...
23.368421
74
0.657658
0
0
0
0
0
0
0
0
233
0.524775
9cd70cc3359c08bf7a6d62844d5b552cec8efabc
157
py
Python
blog/admin.py
Debanjan2001/MyBlog-WebApp
6a98ea512431490d0fcb9f10de0def9933e49c25
[ "MIT" ]
1
2021-04-21T17:58:10.000Z
2021-04-21T17:58:10.000Z
blog/admin.py
Debanjan2001/MyBlog-WebApp
6a98ea512431490d0fcb9f10de0def9933e49c25
[ "MIT" ]
null
null
null
blog/admin.py
Debanjan2001/MyBlog-WebApp
6a98ea512431490d0fcb9f10de0def9933e49c25
[ "MIT" ]
null
null
null
from blog.models import Comment, Post from django.contrib import admin # Register your models here. admin.site.register(Post) admin.site.register(Comment)
19.625
37
0.802548
0
0
0
0
0
0
0
0
28
0.178344
9cd790991b2e8bb7fe6665f9e39b218f772a44ee
12,076
py
Python
elbow/models/time_series.py
davmre/elbow
5ca2733068dc367404ad48d4e2c7f61f9901216a
[ "BSD-3-Clause" ]
93
2016-10-04T23:15:54.000Z
2021-01-10T20:31:36.000Z
elbow/models/time_series.py
davmre/bayesflow
5ca2733068dc367404ad48d4e2c7f61f9901216a
[ "BSD-3-Clause" ]
1
2017-02-22T11:29:15.000Z
2017-02-22T21:13:36.000Z
elbow/models/time_series.py
davmre/elbow
5ca2733068dc367404ad48d4e2c7f61f9901216a
[ "BSD-3-Clause" ]
19
2016-10-26T08:19:39.000Z
2019-12-19T02:26:43.000Z
import numpy as np import tensorflow as tf import elbow.util as util from elbow import ConditionalDistribution import scipy.stats from elbow.gaussian_messages import MVGaussianMeanCov, reverse_message, forward_message from elbow.parameterization import unconstrained, psd_matrix, psd_diagonal class LinearGaussian(C...
42.223776
242
0.602103
11,774
0.974992
0
0
0
0
0
0
1,227
0.101606
9cd7f195a00e7374763e0bd2f25ffaede27cf631
300
py
Python
src/docs/net/ip/tcp_server.py
fujiawei-dev/protocols-notes
4f5b2dd6f7b5a7f2d1260312972898be0f123ff5
[ "MIT" ]
null
null
null
src/docs/net/ip/tcp_server.py
fujiawei-dev/protocols-notes
4f5b2dd6f7b5a7f2d1260312972898be0f123ff5
[ "MIT" ]
null
null
null
src/docs/net/ip/tcp_server.py
fujiawei-dev/protocols-notes
4f5b2dd6f7b5a7f2d1260312972898be0f123ff5
[ "MIT" ]
null
null
null
""" Date: 2022.04.03 16:48:45 LastEditors: Rustle Karl LastEditTime: 2022.04.03 20:21:38 """ import socket server = socket.socket(socket.AF_INET, socket.SOCK_STREAM) server.bind(("0.0.0.0", 9090)) server.listen(50000) while True: client, client_address = server.accept() client.send("OK")
18.75
58
0.71
0
0
0
0
0
0
0
0
105
0.35
9cd90bd91ff172e86f44aefdf72ca6e011490a20
458
py
Python
scrapy/python3/mysite/nutrition/urls.py
litteletips/crawling_scraping-scrapy_tool
6d70b4d2a91f2d2bebcc5266ed43ad9be4723bc0
[ "MIT" ]
null
null
null
scrapy/python3/mysite/nutrition/urls.py
litteletips/crawling_scraping-scrapy_tool
6d70b4d2a91f2d2bebcc5266ed43ad9be4723bc0
[ "MIT" ]
16
2021-03-19T09:44:52.000Z
2022-03-12T00:22:14.000Z
scrapy/python3/mysite/nutrition/urls.py
litteletips/crawling_scraping
6d70b4d2a91f2d2bebcc5266ed43ad9be4723bc0
[ "MIT" ]
null
null
null
from django.conf.urls import patterns, url from nutrition import views from django.views.generic import ListView urlpatterns = [ url(r'^nutrition/ITEM/$', views.AddCommentList.as_view()), url(r'^nutrition/ITEM/(?P<pk>[0-9]+)/$', views.AddCommentDetail.as_view()), url(r'^nutrition/item/$', views.ItemList.as_...
35.230769
79
0.707424
0
0
0
0
0
0
0
0
110
0.240175
9cd986f63f2998e03a6a691279dbbb3f5191e30f
413
py
Python
Mundo2/des55.1.py
julimoraislima/Python-CursoEmVideo
d21b0485d2f5767039d819cf743255dfd0f27b18
[ "MIT" ]
2
2021-01-05T12:31:00.000Z
2021-03-20T00:31:18.000Z
Mundo2/des55.1.py
julimoraislima/Python-CursoEmVideo
d21b0485d2f5767039d819cf743255dfd0f27b18
[ "MIT" ]
null
null
null
Mundo2/des55.1.py
julimoraislima/Python-CursoEmVideo
d21b0485d2f5767039d819cf743255dfd0f27b18
[ "MIT" ]
1
2020-12-28T22:56:10.000Z
2020-12-28T22:56:10.000Z
#desafio 55: maior e menor da sequência usando lista [] pessoas = [] #lista vazia for c in range(1, 6): peso = float(input(f'Peso da {c}ª pessoa: ')) pessoas = pessoas + [peso] #lista += [peso] #add os valores de peso na lista print('><'*15) print(f'\33[33m O Maior peso lido foi: {max(pessoas)}') #máximo va...
41.3
82
0.658596
0
0
0
0
0
0
0
0
288
0.690647
9cdbe360a8f667d204259709a219c4ef5ae20b25
627
py
Python
Basics_with_Pytorch/Exam/exam2.py
SoyOscarRH/LearningNeuralNetworks
dd5be94b38b3a0efb3428f76d3416227a92c8265
[ "MIT" ]
3
2020-01-20T19:56:35.000Z
2021-09-24T14:47:33.000Z
Basics_with_Pytorch/Exam/exam2.py
SoyOscarRH/LearningNeuralNetworks
dd5be94b38b3a0efb3428f76d3416227a92c8265
[ "MIT" ]
null
null
null
Basics_with_Pytorch/Exam/exam2.py
SoyOscarRH/LearningNeuralNetworks
dd5be94b38b3a0efb3428f76d3416227a92c8265
[ "MIT" ]
null
null
null
import numpy as np x1 = 1 x2 = 1 def sigm(x): return 1 / (1 + np.exp(-x)) # input a0 = 1 a1 = x1 a2 = x2 # w input - layer 1 w01 = 1 w02 = 0.5 w11 = 1 w12 = 0 w21 = -1 w22 = 0.5 # layer 1 zh1 = (w01 * a0) + (w11 * a1) + (w21 * a2) zh2 = (w02 * a0) + (w12 * a1) + (w22 * a2) print(f"zh1 = {round(zh1, 2)}") print...
13.0625
42
0.511962
0
0
0
0
0
0
0
0
203
0.323764
9cdcd417120489c50be7c4fe5fc7166efe788f6e
1,659
py
Python
temp.py
zimmed/project200
07ed6952bcec890c4cbc3b00d09ca3be6c1cfbf8
[ "MIT" ]
null
null
null
temp.py
zimmed/project200
07ed6952bcec890c4cbc3b00d09ca3be6c1cfbf8
[ "MIT" ]
null
null
null
temp.py
zimmed/project200
07ed6952bcec890c4cbc3b00d09ca3be6c1cfbf8
[ "MIT" ]
1
2021-06-01T10:44:21.000Z
2021-06-01T10:44:21.000Z
from store.user import User from store import ModelStore as DataStore from game import Game from core.dotdict import DotDict from server import EventServer import sys def prnt(obj, k): def f(model, key, func): print obj + ':' + k + ' -> ' + model[k] return f def server_main(): print ...
29.105263
83
0.579867
0
0
0
0
0
0
0
0
248
0.149488
9cdd480827a1fd289872f3766e3983a441501350
5,164
py
Python
tools/polyfilt.py
ernestyalumni/18-327-wavelets-filter-banks
eeb3fd65b42808cf907aa716110417515dbbfd82
[ "MIT" ]
13
2015-07-18T16:13:19.000Z
2021-11-09T12:04:01.000Z
tools/polyfilt.py
ernestyalumni/18-327-wavelets-filter-banks
eeb3fd65b42808cf907aa716110417515dbbfd82
[ "MIT" ]
null
null
null
tools/polyfilt.py
ernestyalumni/18-327-wavelets-filter-banks
eeb3fd65b42808cf907aa716110417515dbbfd82
[ "MIT" ]
7
2015-07-30T20:05:22.000Z
2021-06-29T01:11:08.000Z
## polyfilt.py ## This is my implementation of polyfilt.m ## Polyphase implementation of a filter ## using Python libraries numpy, scipy ## ## The main reference that I'll use is ## Gilbert Strang, and Kevin Amaratunga. 18.327 Wavelets, Filter Banks and Applications, Spring 2003. (Massachusetts Institute of Technology...
46.107143
241
0.445972
0
0
0
0
0
0
0
0
4,833
0.935902
9cdf1578fa4f2e1b103a8b115bdfeb2d7e8e8584
2,716
py
Python
main/config/config.py
m-adamski/python-send-db-result
797aa2faec33e21c15c8fb703a6790815b070b28
[ "MIT" ]
1
2020-10-02T21:32:37.000Z
2020-10-02T21:32:37.000Z
main/config/config.py
m-adamski/python-send-db-result
797aa2faec33e21c15c8fb703a6790815b070b28
[ "MIT" ]
null
null
null
main/config/config.py
m-adamski/python-send-db-result
797aa2faec33e21c15c8fb703a6790815b070b28
[ "MIT" ]
null
null
null
import os import json def load_config_file(config_path): if config_path is not None and os.path.isfile(config_path): with open(config_path, "r") as config_file: return json.load(config_file) else: return {} class Config: # Database configuration db_host = "127.0.0.1" ...
31.218391
104
0.576215
2,468
0.908689
0
0
0
0
0
0
643
0.236745
9cdfdb149027f845e15333f523f0c024a1f4b256
6,913
py
Python
lib_client/src/d1_client/d1client.py
DataONEorg/d1_python
dfab267c3adea913ab0e0073ed9dc1ee50b5b8eb
[ "Apache-2.0" ]
15
2016-10-28T13:56:52.000Z
2022-01-31T19:07:49.000Z
lib_client/src/d1_client/d1client.py
DataONEorg/d1_python
dfab267c3adea913ab0e0073ed9dc1ee50b5b8eb
[ "Apache-2.0" ]
56
2017-03-16T03:52:32.000Z
2022-03-12T01:05:28.000Z
lib_client/src/d1_client/d1client.py
DataONEorg/d1_python
dfab267c3adea913ab0e0073ed9dc1ee50b5b8eb
[ "Apache-2.0" ]
11
2016-05-31T16:22:02.000Z
2020-10-05T14:37:10.000Z
#!/usr/bin/env python # This work was created by participants in the DataONE project, and is # jointly copyrighted by participating institutions in DataONE. For # more information on DataONE, see our web site at http://dataone.org. # # Copyright 2009-2019 DataONE # # Licensed under the Apache License, Version 2.0 (t...
33.076555
88
0.672356
3,385
0.489657
0
0
0
0
0
0
3,074
0.444669
9ce28045195119b03b6a70cb5dc288a624a6fad1
2,139
py
Python
tests/unit/model/test_catalogo.py
douglasdcm/easy_db
25a3b2fa51dda484cde7a6aa27f26e8ad6d0c827
[ "MIT" ]
null
null
null
tests/unit/model/test_catalogo.py
douglasdcm/easy_db
25a3b2fa51dda484cde7a6aa27f26e8ad6d0c827
[ "MIT" ]
null
null
null
tests/unit/model/test_catalogo.py
douglasdcm/easy_db
25a3b2fa51dda484cde7a6aa27f26e8ad6d0c827
[ "MIT" ]
null
null
null
from src.model.catalogo_curso import CatalogoCurso from src.model.curso import Curso from src.model.materia import Materia class TestCatalogo: curso = "marcenaria" materia_1 = "prego" materia_2 = "parafuso" materia_3 = "martelo" def setup_method(self, method): self.catalogo = CatalogoCur...
31.925373
54
0.649836
2,014
0.941561
0
0
0
0
0
0
68
0.031791
9ce3032a51e788ff5c21581798ceabf05763db56
1,664
py
Python
tinymongo/errors.py
sumants-dev/tinymongo
e904f274524fa3f86c5aeb04a7e8199414567de7
[ "MIT" ]
177
2016-04-04T14:23:35.000Z
2022-02-21T15:40:17.000Z
tinymongo/errors.py
sumants-dev/tinymongo
e904f274524fa3f86c5aeb04a7e8199414567de7
[ "MIT" ]
35
2016-07-14T10:15:11.000Z
2022-02-13T15:19:27.000Z
tinymongo/errors.py
sumants-dev/tinymongo
e904f274524fa3f86c5aeb04a7e8199414567de7
[ "MIT" ]
33
2016-07-17T14:15:02.000Z
2022-02-21T16:28:55.000Z
"""Exceptions raised by TinyMongo.""" class TinyMongoError(Exception): """Base class for all TinyMongo exceptions.""" class ConnectionFailure(TinyMongoError): """Raised when a connection to the database file cannot be made or is lost. """ class ConfigurationError(TinyMongoError): """Raised when so...
26.83871
79
0.689904
1,602
0.96274
0
0
545
0.327524
0
0
988
0.59375
9ce35431b33811cb36dbd79aae7d5f814ea244b0
2,149
py
Python
compare_Tensorflow_Sckit_Learn/benchmark_classification.py
sinkingtitanic/mljar-examples
1ea4e99f4751f20b90e22cb75e6a7424005722e5
[ "Apache-2.0" ]
43
2017-02-01T21:44:39.000Z
2022-03-29T13:59:48.000Z
compare_Tensorflow_Sckit_Learn/benchmark_classification.py
sinkingtitanic/mljar-examples
1ea4e99f4751f20b90e22cb75e6a7424005722e5
[ "Apache-2.0" ]
7
2017-02-22T09:11:05.000Z
2021-09-02T09:10:48.000Z
compare_Tensorflow_Sckit_Learn/benchmark_classification.py
sinkingtitanic/mljar-examples
1ea4e99f4751f20b90e22cb75e6a7424005722e5
[ "Apache-2.0" ]
23
2017-02-22T09:08:45.000Z
2022-02-11T01:01:38.000Z
import os import time import json import numpy as np import pandas as pd from supervised.automl import AutoML from sklearn.model_selection import train_test_split from sklearn.metrics import log_loss from sklearn.model_selection import train_test_split from pmlb import fetch_data, classification_dataset_names results...
28.653333
71
0.64309
0
0
0
0
0
0
0
0
207
0.096324