hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
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
4
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
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
4
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
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
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
31b1491cb1218b11a46facdc384274b8e0baf48c
860
py
Python
test/unit/rules/resources/dynamodb/test_billing_mode.py
tomislacker/cfn-python-lint
f209ddfef9bcc1a005adfebcfcc16220b18deddb
[ "MIT-0" ]
1
2020-05-08T20:12:31.000Z
2020-05-08T20:12:31.000Z
test/unit/rules/resources/dynamodb/test_billing_mode.py
tomislacker/cfn-python-lint
f209ddfef9bcc1a005adfebcfcc16220b18deddb
[ "MIT-0" ]
null
null
null
test/unit/rules/resources/dynamodb/test_billing_mode.py
tomislacker/cfn-python-lint
f209ddfef9bcc1a005adfebcfcc16220b18deddb
[ "MIT-0" ]
1
2020-12-01T14:54:28.000Z
2020-12-01T14:54:28.000Z
""" Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. SPDX-License-Identifier: MIT-0 """ from test.unit.rules import BaseRuleTestCase from cfnlint.rules.resources.dynamodb.BillingMode import BillingMode # pylint: disable=E0401 class TestBillingMode(BaseRuleTestCase): """Test BillingMode""" ...
30.714286
93
0.686047
8bd46bb3dd76883746a69195c7e016be18a7828a
36,235
py
Python
src/urllib3/connectionpool.py
perfectykills/urllib3-pyqt5
5d01683120051e78ed46467c1f24649970e82c0a
[ "MIT" ]
null
null
null
src/urllib3/connectionpool.py
perfectykills/urllib3-pyqt5
5d01683120051e78ed46467c1f24649970e82c0a
[ "MIT" ]
null
null
null
src/urllib3/connectionpool.py
perfectykills/urllib3-pyqt5
5d01683120051e78ed46467c1f24649970e82c0a
[ "MIT" ]
null
null
null
from __future__ import absolute_import import errno import logging import sys import warnings from socket import error as SocketError, timeout as SocketTimeout import socket from .exceptions import ( ClosedPoolError, ProtocolError, EmptyPoolError, HeaderParsingError, HostChangedError, Locatio...
34.841346
99
0.59368
a84fd3572717a7c1126090679403169e719ec280
2,673
py
Python
research/object_detection/tpu_exporters/export_saved_model_tpu_lib_tf1_test.py
hjkim-haga/TF-OD-API
22ac477ff4dfb93fe7a32c94b5f0b1e74330902b
[ "Apache-2.0" ]
1
2021-05-22T12:50:50.000Z
2021-05-22T12:50:50.000Z
object_detection/tpu_exporters/export_saved_model_tpu_lib_tf1_test.py
DemonDamon/mask-detection-based-on-tf2odapi
192ae544169c1230c21141c033800aa1bd94e9b6
[ "MIT" ]
null
null
null
object_detection/tpu_exporters/export_saved_model_tpu_lib_tf1_test.py
DemonDamon/mask-detection-based-on-tf2odapi
192ae544169c1230c21141c033800aa1bd94e9b6
[ "MIT" ]
null
null
null
# Copyright 2019 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...
37.125
81
0.668911
8540a505322d5f71a92064fee9061673c674b5d3
106
py
Python
sparv/modules/saldo/__init__.py
heatherleaf/sparv-pipeline
0fe5f27d0d82548ecc6cb21a69289668aac54cf1
[ "MIT" ]
17
2018-09-21T07:01:45.000Z
2022-02-24T23:26:49.000Z
sparv/modules/saldo/__init__.py
heatherleaf/sparv-pipeline
0fe5f27d0d82548ecc6cb21a69289668aac54cf1
[ "MIT" ]
146
2018-11-13T19:13:25.000Z
2022-03-31T09:57:56.000Z
sparv/modules/saldo/__init__.py
heatherleaf/sparv-pipeline
0fe5f27d0d82548ecc6cb21a69289668aac54cf1
[ "MIT" ]
5
2019-02-14T00:50:38.000Z
2021-03-29T15:37:41.000Z
"""SALDO-related annotations.""" from . import compound, nst_comp_model, saldo, saldo_model, stats_model
26.5
71
0.773585
784fee27ec83c80903d6becec35fc6273d1f861c
5,514
py
Python
tests/gold_tests/logging/log-filter.test.py
zhaorun/trafficserver
757256129811441f29eea288b1d7e19bc54fab9c
[ "Apache-2.0" ]
null
null
null
tests/gold_tests/logging/log-filter.test.py
zhaorun/trafficserver
757256129811441f29eea288b1d7e19bc54fab9c
[ "Apache-2.0" ]
null
null
null
tests/gold_tests/logging/log-filter.test.py
zhaorun/trafficserver
757256129811441f29eea288b1d7e19bc54fab9c
[ "Apache-2.0" ]
null
null
null
''' ''' # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License");...
44.112
228
0.673558
4c752c722ef9f3bd15c73d4917e51758c0eb8e2c
2,157
py
Python
source/conf.py
junisky/doc
a5a8b65edfb6466677ea36d88f864c93fa8a5df9
[ "MIT" ]
null
null
null
source/conf.py
junisky/doc
a5a8b65edfb6466677ea36d88f864c93fa8a5df9
[ "MIT" ]
null
null
null
source/conf.py
junisky/doc
a5a8b65edfb6466677ea36d88f864c93fa8a5df9
[ "MIT" ]
null
null
null
# Configuration file for the Sphinx documentation builder. # # This file only contains a selection of the most common options. For a full # list see the documentation: # https://www.sphinx-doc.org/en/master/usage/configuration.html # -- Path setup -------------------------------------------------------------- # If ex...
34.238095
79
0.676866
1e18c69a09a301223512c5ea1a53991e7dcb044a
1,039
py
Python
Python/queue-reconstruction-by-height.py
se77enn/LeetCode-Solution
d29ef5358cae592b63952c3d293897a176fb75e1
[ "MIT" ]
1
2020-10-27T03:22:31.000Z
2020-10-27T03:22:31.000Z
Python/queue-reconstruction-by-height.py
se77enn/LeetCode-Solution
d29ef5358cae592b63952c3d293897a176fb75e1
[ "MIT" ]
null
null
null
Python/queue-reconstruction-by-height.py
se77enn/LeetCode-Solution
d29ef5358cae592b63952c3d293897a176fb75e1
[ "MIT" ]
1
2021-03-22T18:58:23.000Z
2021-03-22T18:58:23.000Z
# Time: O(n * sqrt(n)) # Space: O(n) class Solution(object): def reconstructQueue(self, people): """ :type people: List[List[int]] :rtype: List[List[int]] """ people.sort(key=lambda h_k: (-h_k[0], h_k[1])) blocks = [[]] for p in people: index = ...
25.975
57
0.485082
f8d454c48db24502fc7410180cd849711f08c44b
171
py
Python
chat/routing.py
hamraa/channels-demo
9bcc3395bdc8062f55ef15052be1d2a5b8af2631
[ "MIT" ]
1
2022-01-06T16:57:48.000Z
2022-01-06T16:57:48.000Z
chat/routing.py
hamraa/channels-demo
9bcc3395bdc8062f55ef15052be1d2a5b8af2631
[ "MIT" ]
null
null
null
chat/routing.py
hamraa/channels-demo
9bcc3395bdc8062f55ef15052be1d2a5b8af2631
[ "MIT" ]
null
null
null
from django.urls import re_path from . import consumers websocket_urlpatterns = [ re_path(r'ws/chat/(?P<room_name>\w+)/$', consumers.AsyncChatConsumer.as_asgi()), ]
21.375
84
0.730994
b57a883822ff08ece5dc8d8a11d0eb4d087db883
13,496
py
Python
students/models.py
tnemisteam/cdf-steps
78896eebd08ba9975a2dece97f73dca9aa781238
[ "MIT" ]
null
null
null
students/models.py
tnemisteam/cdf-steps
78896eebd08ba9975a2dece97f73dca9aa781238
[ "MIT" ]
null
null
null
students/models.py
tnemisteam/cdf-steps
78896eebd08ba9975a2dece97f73dca9aa781238
[ "MIT" ]
null
null
null
from django.db import models from django.db.models.fields import * from baseapp.models import * import caching.base from imagekit.models import ProcessedImageField from imagekit.processors import ResizeToFill from django.db.models.signals import post_save, post_delete from imagekit import ImageSpec, register from imag...
43.118211
176
0.679238
d0c12fcc98685367ba3a03554e853f2875656c14
5,814
py
Python
server-py/room.py
pwmarcz/minefield
f4055da45251b79185d26fff7de7ccb153b5c171
[ "MIT" ]
22
2015-03-22T21:36:57.000Z
2021-11-08T12:37:33.000Z
server-py/room.py
pwmarcz/minefield
f4055da45251b79185d26fff7de7ccb153b5c171
[ "MIT" ]
10
2015-03-22T20:21:07.000Z
2021-05-09T09:59:02.000Z
server-py/room.py
pwmarcz/minefield
f4055da45251b79185d26fff7de7ccb153b5c171
[ "MIT" ]
6
2015-03-26T04:23:13.000Z
2021-04-06T05:55:12.000Z
import unittest import logging from game import Game from utils import make_key logger = logging.getLogger('room') class Room(object): def __init__(self, nicks=['P1', 'P2'], game_class=Game): self.game = game_class(callback=self.send_to_player) self.nicks = nicks self.players = [None, N...
31.427027
92
0.586171
50194a34ec8b1f5aefa20e42f423939adafc4627
365
py
Python
Pics/migrations/0007_auto_20191013_1408.py
IreneMercy/Instapic
98e3f48bffbc7c182cecb5460972872865f6e336
[ "MIT" ]
null
null
null
Pics/migrations/0007_auto_20191013_1408.py
IreneMercy/Instapic
98e3f48bffbc7c182cecb5460972872865f6e336
[ "MIT" ]
8
2019-12-05T00:36:46.000Z
2022-02-10T10:32:41.000Z
Pics/migrations/0007_auto_20191013_1408.py
IreneMercy/Instapic
98e3f48bffbc7c182cecb5460972872865f6e336
[ "MIT" ]
1
2020-07-05T19:24:28.000Z
2020-07-05T19:24:28.000Z
# Generated by Django 2.2 on 2019-10-13 11:08 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('Pics', '0006_auto_20191013_1405'), ] operations = [ migrations.RenameField( model_name='profile', old_name='image', ...
19.210526
45
0.589041
a07b2632346dbd2688db31cea1a1ec4f24dec322
613
py
Python
Python/tests.py
ayan59dutta/Small-Scripts
b560d7800445ee1f35d23eaf92900b87a902b238
[ "Unlicense" ]
2
2018-04-13T18:41:47.000Z
2021-11-19T13:20:06.000Z
Python/tests.py
ayan59dutta/Small-Scripts
b560d7800445ee1f35d23eaf92900b87a902b238
[ "Unlicense" ]
4
2018-03-29T17:12:35.000Z
2018-04-13T18:57:16.000Z
Python/tests.py
ayan59dutta/Small-Scripts
b560d7800445ee1f35d23eaf92900b87a902b238
[ "Unlicense" ]
2
2018-03-30T13:22:50.000Z
2019-10-24T18:57:18.000Z
#!/usr/bin/env python3 import unittest # Imports for caesar.py tests from caesar import decrypt from caesar import encrypt # Unit Tests for caesar.py class CaesarTest(unittest.TestCase): def test_decrypt_key(self): self.assertEqual('I am a good boy', encrypt('L dp d jrrg erb',-3)) def test_encrypt...
24.52
127
0.696574
98da3f35ef2deccde2028103bca8757b28a3af36
222
py
Python
watchdog_kj_kultura/organizations/apps.py
watchdogpolska/watchdog-kj-kultura
ea1a5c52ef2a174c012cc08eff5fdd7aa3b911b0
[ "MIT" ]
null
null
null
watchdog_kj_kultura/organizations/apps.py
watchdogpolska/watchdog-kj-kultura
ea1a5c52ef2a174c012cc08eff5fdd7aa3b911b0
[ "MIT" ]
138
2016-12-10T19:18:18.000Z
2019-06-10T19:32:40.000Z
watchdog_kj_kultura/organizations/apps.py
watchdogpolska/watchdog-kj-kultura
ea1a5c52ef2a174c012cc08eff5fdd7aa3b911b0
[ "MIT" ]
null
null
null
from django.apps import AppConfig from django.utils.translation import ugettext_lazy as _ class OrganizationsConfig(AppConfig): name = 'watchdog_kj_kultura.organizations' verbose_name = _("Organizations module")
27.75
55
0.801802
3d35e5e000a6bb40f519026206eee82216e1b4e0
4,694
py
Python
sdk/logic/azure-mgmt-logic/azure/mgmt/logic/models/edifact_delimiter_override_py3.py
iscai-msft/azure-sdk-for-python
83715b95c41e519d5be7f1180195e2fba136fc0f
[ "MIT" ]
8
2021-01-13T23:44:08.000Z
2021-03-17T10:13:36.000Z
sdk/logic/azure-mgmt-logic/azure/mgmt/logic/models/edifact_delimiter_override_py3.py
iscai-msft/azure-sdk-for-python
83715b95c41e519d5be7f1180195e2fba136fc0f
[ "MIT" ]
226
2019-07-24T07:57:21.000Z
2019-10-15T01:07:24.000Z
sdk/logic/azure-mgmt-logic/azure/mgmt/logic/models/edifact_delimiter_override_py3.py
iscai-msft/azure-sdk-for-python
83715b95c41e519d5be7f1180195e2fba136fc0f
[ "MIT" ]
2
2020-05-21T22:51:22.000Z
2020-05-26T20:53:01.000Z
# 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 ...
51.582418
376
0.697912
46e8ae2bdca053ee87cb93f3897ba819e617d26f
7,440
py
Python
ludolph/message.py
erigones/Ludolph
f46d2c0484db2b54b491be40b6324be8c64243db
[ "BSD-3-Clause" ]
33
2015-01-12T16:48:22.000Z
2022-01-24T09:45:56.000Z
ludolph/message.py
erigones/Ludolph
f46d2c0484db2b54b491be40b6324be8c64243db
[ "BSD-3-Clause" ]
36
2015-01-24T19:23:27.000Z
2020-10-03T20:04:47.000Z
ludolph/message.py
erigones/Ludolph
f46d2c0484db2b54b491be40b6324be8c64243db
[ "BSD-3-Clause" ]
10
2015-01-24T19:27:20.000Z
2022-02-24T16:47:54.000Z
""" Ludolph: Monitoring Jabber bot Copyright (C) 2012-2015 Erigones, s. r. o. This file is part of Ludolph. See the file LICENSE for copying permission. """ import logging import re from datetime import datetime, timedelta from sleekxmpp.xmlstream import ET from sleekxmpp.stanza import Message try: from xml.etree....
29.0625
115
0.557258
61016253d65208ae4a9dd7de8bc18e95b89738ac
984
py
Python
standard_library/threads/demo_consumer_producer.py
2581676612/python
b309564a05838b23044bb8112fd4ef71307266b6
[ "MIT" ]
112
2017-09-19T17:38:38.000Z
2020-05-27T18:00:27.000Z
standard_library/threads/demo_consumer_producer.py
tomoncle/Python-notes
ce675486290c3d1c7c2e4890b57e3d0c8a1228cc
[ "MIT" ]
null
null
null
standard_library/threads/demo_consumer_producer.py
tomoncle/Python-notes
ce675486290c3d1c7c2e4890b57e3d0c8a1228cc
[ "MIT" ]
56
2017-09-20T01:24:12.000Z
2020-04-16T06:19:31.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Time : 2017/4/29 14:44 # @Author : tom.lee # @Site : # @File : consumer_producer.py # @Software: PyCharm import time import threading import Queue class Consumer(threading.Thread): def __init__(self, queue): threading.Thread.__init__(self) ...
21.391304
59
0.569106
f20734a7d1a08c44b84b414beed794b22624cacc
477
py
Python
training/size_convertion.py
ndl-lab/ssd_keras
94c951cbe7b3d8c59a3ef5b2db26af5aa2099cc4
[ "CC-BY-4.0", "MIT" ]
4
2019-08-23T13:12:44.000Z
2019-12-24T05:40:17.000Z
training/size_convertion.py
ndl-lab/ssd_keras
94c951cbe7b3d8c59a3ef5b2db26af5aa2099cc4
[ "CC-BY-4.0", "MIT" ]
null
null
null
training/size_convertion.py
ndl-lab/ssd_keras
94c951cbe7b3d8c59a3ef5b2db26af5aa2099cc4
[ "CC-BY-4.0", "MIT" ]
null
null
null
import numpy as np import os import glob import pandas as pd import cv2 from xml.etree import ElementTree import random import shutil import glob from PIL import Image for dirname in os.listdir("tmp"): print(dirname) for fpath in glob.glob(os.path.join("fullsizeimg",dirname,"original","*")): img=Image....
28.058824
87
0.721174
16470838ce12928e0b9945d343c1bc7d3952caee
235
py
Python
20211125_PwnIntro/3_java/solution.py
alessandro-massarenti/Cybersec2021
3d6dcc4b255dd425b1be66d440df1d94d5ea5ac0
[ "BSD-3-Clause" ]
15
2021-10-01T16:10:48.000Z
2022-02-19T20:45:35.000Z
20211125_PwnIntro/3_java/solution.py
alessandro-massarenti/Cybersec2021
3d6dcc4b255dd425b1be66d440df1d94d5ea5ac0
[ "BSD-3-Clause" ]
null
null
null
20211125_PwnIntro/3_java/solution.py
alessandro-massarenti/Cybersec2021
3d6dcc4b255dd425b1be66d440df1d94d5ea5ac0
[ "BSD-3-Clause" ]
2
2021-11-06T08:32:41.000Z
2021-12-11T16:18:54.000Z
from pwn import * context.binary = "./java" p = process() p.sendline(b"java" + b"A" * 28 + p64(context.binary.functions["bash"].address + 0x32)) p.sendline(b"cat flag.txt") log.success(p.recvline_regex(rb".*{.*}.*").decode("ascii"))
26.111111
86
0.655319
eca90e337e79d729395c28aaf83ac96fbce7ebd4
1,952
py
Python
tests/cli/helpers/language.py
cugu-stars/plaso
a205f8e52dfe4c239aeae5558d572806b7b00e81
[ "Apache-2.0" ]
2
2019-10-23T03:37:59.000Z
2020-08-14T17:09:26.000Z
tests/cli/helpers/language.py
cugu-stars/plaso
a205f8e52dfe4c239aeae5558d572806b7b00e81
[ "Apache-2.0" ]
null
null
null
tests/cli/helpers/language.py
cugu-stars/plaso
a205f8e52dfe4c239aeae5558d572806b7b00e81
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Tests for the language CLI arguments helper.""" import argparse import unittest from plaso.cli import tools from plaso.cli.helpers import language from plaso.lib import errors from tests.cli import test_lib as cli_test_lib class LanguagergumentsHelperTest(cli_test_...
31.483871
79
0.720287
6445b6a74b119c1876423ab6d483861eb080e4bc
16,508
py
Python
NetBuilder.py
xxxyyyqqq12345/NetBuilder
7ff2c441c397aa44b0e4435639609c4cb155f969
[ "MIT" ]
null
null
null
NetBuilder.py
xxxyyyqqq12345/NetBuilder
7ff2c441c397aa44b0e4435639609c4cb155f969
[ "MIT" ]
null
null
null
NetBuilder.py
xxxyyyqqq12345/NetBuilder
7ff2c441c397aa44b0e4435639609c4cb155f969
[ "MIT" ]
null
null
null
import numpy as np import tensorflow as tf from Graph import * class NNetLayers(object): tfConvs=[tf.layers.conv1d,tf.layers.conv2d,tf.layers.conv3d] tfConvsT=[tf.layers.conv1d,tf.layers.conv2d_transpose,tf.layers.conv3d_transpose] tfMPools=[tf.layers.max_pooling1d,tf.layers.max_pooling2d,tf.layers.max_poo...
42.437018
125
0.606797
e0c16832154470689bcfa03e85670610fa9db21b
5,022
py
Python
deploy.py
shusain93/dehydrated-dreamhost-hook
3b49bbf4395a092499b73017b0c853a6433d24d9
[ "MIT" ]
null
null
null
deploy.py
shusain93/dehydrated-dreamhost-hook
3b49bbf4395a092499b73017b0c853a6433d24d9
[ "MIT" ]
1
2020-11-15T16:45:42.000Z
2020-11-15T16:45:42.000Z
deploy.py
shusain93/dehydrated-dreamhost-hook
3b49bbf4395a092499b73017b0c853a6433d24d9
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ Deploys new Let's Encrypt certificate. Copyright (c) 2016 Erin Morelli 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 ...
27.9
78
0.607129
ce288d8f965086e32006ac63d641074c31d7cea4
2,528
py
Python
app/management/commands/train_item_cf.py
skeptycal/albedo
50f76f080c7a834cb75ac42daa56a1895af2e595
[ "MIT" ]
1
2021-12-30T17:09:14.000Z
2021-12-30T17:09:14.000Z
app/management/commands/train_item_cf.py
00mjk/albedo
be94cad3e806616850af985e5befffa2f0898a21
[ "MIT" ]
1
2021-06-10T23:12:19.000Z
2021-06-10T23:12:19.000Z
app/management/commands/train_item_cf.py
00mjk/albedo
be94cad3e806616850af985e5befffa2f0898a21
[ "MIT" ]
null
null
null
# coding: utf-8 from django.core.management.base import BaseCommand from sklearn.metrics.pairwise import pairwise_distances import numpy as np import pandas as pd from app.utils_repo import prepare_user_item_df class Command(BaseCommand): def add_arguments(self, parser): parser.add_argument('-u', '--u...
41.442623
108
0.69462
71984fb5c8d0c7fcc50afc77418691f478616baa
1,023
py
Python
stars_etc/multipleSnowflakesrandomColours.py
cmulliss/turtles-doing-things
70c8241bcf6d3b37104a59e92b5cf5a002fcb0bf
[ "CC0-1.0" ]
null
null
null
stars_etc/multipleSnowflakesrandomColours.py
cmulliss/turtles-doing-things
70c8241bcf6d3b37104a59e92b5cf5a002fcb0bf
[ "CC0-1.0" ]
null
null
null
stars_etc/multipleSnowflakesrandomColours.py
cmulliss/turtles-doing-things
70c8241bcf6d3b37104a59e92b5cf5a002fcb0bf
[ "CC0-1.0" ]
null
null
null
# Multiple snowflakes from turtle import * import random mode('logo') shape('turtle') color('white') bgcolor('blue') pensize(2) shapesize(1) speed(600) colours = ['cyan', 'white', 'green', "red", 'yellow', 'red', 'orange', 'pink','purple', 'magenta','grey', 'turquoise' ] #beginning of snowflake function def snowflake...
20.058824
119
0.57087
940a97c96fce4d5f9a8030c86500227dd4e0fe04
3,039
py
Python
test/pyaz/group/lock/__init__.py
bigdatamoore/py-az-cli
54383a4ee7cc77556f6183e74e992eec95b28e01
[ "MIT" ]
null
null
null
test/pyaz/group/lock/__init__.py
bigdatamoore/py-az-cli
54383a4ee7cc77556f6183e74e992eec95b28e01
[ "MIT" ]
9
2021-09-24T16:37:24.000Z
2021-12-24T00:39:19.000Z
test/pyaz/group/lock/__init__.py
bigdatamoore/py-az-cli
54383a4ee7cc77556f6183e74e992eec95b28e01
[ "MIT" ]
null
null
null
import json, subprocess from ... pyaz_utils import get_cli_name, get_params def create(name, lock_type, resource_group, __RESOURCE_PROVIDER_NAMESPACE=None, notes=None, __PARENT_RESOURCE_PATH=None, __RESOURCE_TYPE=None, __RESOURCE_NAME=None): params = get_params(locals()) command = "az group lock create " +...
41.067568
190
0.699572
bfb0edb73bb137813640133aefffa7dedbf66fa5
839
py
Python
utils.py
FanLgchen/JWT-Certification
3f840696a5a296f0ea9e5400625bbcc502779323
[ "MIT" ]
null
null
null
utils.py
FanLgchen/JWT-Certification
3f840696a5a296f0ea9e5400625bbcc502779323
[ "MIT" ]
null
null
null
utils.py
FanLgchen/JWT-Certification
3f840696a5a296f0ea9e5400625bbcc502779323
[ "MIT" ]
null
null
null
import jwt as jwt from flask import current_app def generate_jwt(payload, expiry, secret=None): """ 生成jwt :param payload: dict 载荷 :param expiry: datetime 有效期 :param secret: 密钥 :return: jwt """ _payload = {'exp': expiry} _payload.update(payload) if not secret: secret = ...
17.479167
64
0.61025
99fabbea20b8537db72f4eb26799884a13f22ad3
24,350
py
Python
arc/mainTest.py
mefuller/ARC
69b877bd2e6063bc51410de6c65129a476a97bae
[ "MIT" ]
30
2019-02-02T01:45:40.000Z
2022-03-20T13:03:27.000Z
arc/mainTest.py
mefuller/ARC
69b877bd2e6063bc51410de6c65129a476a97bae
[ "MIT" ]
434
2018-12-24T18:00:07.000Z
2022-03-13T15:55:26.000Z
arc/mainTest.py
mefuller/ARC
69b877bd2e6063bc51410de6c65129a476a97bae
[ "MIT" ]
19
2019-01-04T19:05:45.000Z
2022-03-20T13:03:28.000Z
#!/usr/bin/env python3 # encoding: utf-8 """ This module contains unit tests for the arc.main module """ import os import shutil import unittest from arc.common import ARC_PATH from arc.exceptions import InputError from arc.imports import settings from arc.main import ARC, StatmechEnum, process_adaptive_levels from ...
54.842342
120
0.522587
8882edc18e59bc6723d5b4e7475655a6c0848a60
387
py
Python
processData.py
ganesh-cc/ticket_update
b01689e99422704080cd9a54d50be9ccc695fde0
[ "Unlicense" ]
null
null
null
processData.py
ganesh-cc/ticket_update
b01689e99422704080cd9a54d50be9ccc695fde0
[ "Unlicense" ]
null
null
null
processData.py
ganesh-cc/ticket_update
b01689e99422704080cd9a54d50be9ccc695fde0
[ "Unlicense" ]
null
null
null
import freshdeskService from collections import defaultdict name_mapping = { 480XXXX7506:"agent1", 480XXXX2697:"agent2", 480XXXX4635:"agent3", 480XXXX0364:"agent4" } fin = {} fd = defaultdict(list) def dataMapper(fd): for k in fd: for ke, va in name_mapping.items(): if(k == ke): key = name_mapping.get(...
13.344828
37
0.669251
c6299197bc4d1378357665bae7afc2dc03af904a
726
py
Python
World 1/If...Else/ex034 - Multiple Increase.py
MiguelChichorro/PythonExercises
3b2726e7d9ef92c1eb6b977088692c42a2a7b86e
[ "MIT" ]
2
2021-04-23T19:18:06.000Z
2021-05-15T17:45:21.000Z
World 1/If...Else/ex034 - Multiple Increase.py
MiguelChichorro/PythonExercises
3b2726e7d9ef92c1eb6b977088692c42a2a7b86e
[ "MIT" ]
1
2021-05-14T00:29:23.000Z
2021-05-14T00:29:23.000Z
World 1/If...Else/ex034 - Multiple Increase.py
MiguelChichorro/PythonExercises
3b2726e7d9ef92c1eb6b977088692c42a2a7b86e
[ "MIT" ]
1
2021-05-14T00:19:33.000Z
2021-05-14T00:19:33.000Z
from time import sleep colors = {"clean": "\033[m", "red": "\033[31m", "green": "\033[32m", "yellow": "\033[33m", "blue": "\033[34m", "purple": "\033[35m", "cian": "\033[36m"} sal = int(input("Enter your salary:")) print("{}Loading...{}".format(colors["green"]...
38.210526
108
0.553719
cb58aab54a57076131aef487d1d60c71a4c53dca
10,964
py
Python
src/m3_nested_loops_in_printing.py
khoslarr/18-LoopsWithinLoops
d18a4fd071779f9958b442e08503c4a8e1183454
[ "MIT" ]
null
null
null
src/m3_nested_loops_in_printing.py
khoslarr/18-LoopsWithinLoops
d18a4fd071779f9958b442e08503c4a8e1183454
[ "MIT" ]
null
null
null
src/m3_nested_loops_in_printing.py
khoslarr/18-LoopsWithinLoops
d18a4fd071779f9958b442e08503c4a8e1183454
[ "MIT" ]
null
null
null
""" This project demonstrates NESTED LOOPS (i.e., loops within loops) in the context of PRINTING on the CONSOLE. Authors: David Mutchler, Valerie Galluzzi, Mark Hays, Amanda Stouder, their colleagues and Rishav Khosla. """ # DONE: 1. PUT YOUR NAME IN THE ABOVE LINE. def main(): """ Calls the other func...
34.049689
74
0.530828
0ee22d74b57c3bc124ab3e4f95bb482e9d22fde5
9,249
py
Python
docs/source/conf.py
guidj/jsonuri-py
0e266be86a52dc93d792b05e458e07f0b279e490
[ "Apache-2.0" ]
null
null
null
docs/source/conf.py
guidj/jsonuri-py
0e266be86a52dc93d792b05e458e07f0b279e490
[ "Apache-2.0" ]
5
2015-06-17T05:34:55.000Z
2018-01-29T19:01:11.000Z
docs/source/conf.py
guidj/jsonuri-py
0e266be86a52dc93d792b05e458e07f0b279e490
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # JsonUri documentation build configuration file, created by # sphinx-quickstart on Thu Mar 19 01:41:24 2015. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this # au...
32.00346
79
0.716618
fc255974b5b6637d2a3dbaa153aa8c94b3c781d9
656
py
Python
leetcode/1133-last-substring-in-lexicographical-order.py
Magic07/online-judge-solutions
02a289dd7eb52d7eafabc97bd1a043213b65f70a
[ "MIT" ]
null
null
null
leetcode/1133-last-substring-in-lexicographical-order.py
Magic07/online-judge-solutions
02a289dd7eb52d7eafabc97bd1a043213b65f70a
[ "MIT" ]
null
null
null
leetcode/1133-last-substring-in-lexicographical-order.py
Magic07/online-judge-solutions
02a289dd7eb52d7eafabc97bd1a043213b65f70a
[ "MIT" ]
null
null
null
class Solution: def lastSubstring(self, s: str) -> str: currentMax=0 start=1 length=0 while start+length<len(s): if s[currentMax+length]==s[start+length]: length+=1 continue if s[currentMax+length]>s[start+length]: ...
36.444444
163
0.545732
125f37a1d1eb1f4462372874a95427fd3d6be79b
3,406
py
Python
.dev_scripts/convert_train_benchmark_script.py
mrzhuzhe/mmdetection
c04ca2c2a65500bc248a5d2ab6ace5b15f00064d
[ "Apache-2.0" ]
null
null
null
.dev_scripts/convert_train_benchmark_script.py
mrzhuzhe/mmdetection
c04ca2c2a65500bc248a5d2ab6ace5b15f00064d
[ "Apache-2.0" ]
null
null
null
.dev_scripts/convert_train_benchmark_script.py
mrzhuzhe/mmdetection
c04ca2c2a65500bc248a5d2ab6ace5b15f00064d
[ "Apache-2.0" ]
null
null
null
# Copyright (c) OpenMMLab. All rights reserved. import argparse import os import os.path as osp def parse_args(): parser = argparse.ArgumentParser( description='Convert benchmark model json to script') parser.add_argument( 'txt_path', type=str, help='txt path output by benchmark_filt...
34.06
75
0.525837
39c4f0f926dab2b8a69d373d2799595996223947
1,510
py
Python
tests/test_intersection.py
abdessamad14/zellij
ac49d4abc3779eb4bd11e425f502fd1de96cc0b8
[ "Apache-2.0" ]
12
2017-07-10T16:44:49.000Z
2021-11-09T21:24:57.000Z
tests/test_intersection.py
abdessamad14/zellije
ac49d4abc3779eb4bd11e425f502fd1de96cc0b8
[ "Apache-2.0" ]
2
2017-09-05T16:13:21.000Z
2018-05-05T19:46:46.000Z
tests/test_intersection.py
abdessamad14/zellije
ac49d4abc3779eb4bd11e425f502fd1de96cc0b8
[ "Apache-2.0" ]
3
2017-08-16T00:13:29.000Z
2021-11-09T21:29:58.000Z
from hypothesis import assume, given from hypothesis.strategies import builds, lists, integers, tuples from zellij.defuzz import Defuzzer from zellij.euclid import collinear, Segment, BadGeometry from zellij.intersection import segment_intersections from zellij.postulates import all_pairs nums = integers(min_value=-...
34.318182
92
0.669536
013efe4985b14efa1224cd76e8e3be655ae6f076
3,945
py
Python
airflow/providers/elasticsearch/backport_provider_setup.py
gtossou/airflow
0314a3a218f864f78ec260cc66134e7acae34bc5
[ "Apache-2.0" ]
2
2020-12-03T01:29:54.000Z
2020-12-03T01:30:06.000Z
airflow/providers/elasticsearch/backport_provider_setup.py
gtossou/airflow
0314a3a218f864f78ec260cc66134e7acae34bc5
[ "Apache-2.0" ]
null
null
null
airflow/providers/elasticsearch/backport_provider_setup.py
gtossou/airflow
0314a3a218f864f78ec260cc66134e7acae34bc5
[ "Apache-2.0" ]
null
null
null
# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not...
37.571429
109
0.677567
701a4065c3659ab1b245837fcaa77fbdc5b775c4
730
py
Python
jichu/api.py
theoturner/Fetch-Jichu
a6f34a0c6519b0a5d5a006acd13fc677ab7fbdbe
[ "Apache-2.0" ]
null
null
null
jichu/api.py
theoturner/Fetch-Jichu
a6f34a0c6519b0a5d5a006acd13fc677ab7fbdbe
[ "Apache-2.0" ]
null
null
null
jichu/api.py
theoturner/Fetch-Jichu
a6f34a0c6519b0a5d5a006acd13fc677ab7fbdbe
[ "Apache-2.0" ]
1
2019-10-22T15:29:32.000Z
2019-10-22T15:29:32.000Z
from flask import Flask, render_template, request, redirect, url_for from contract import ContractDeployer app = Flask(__name__) # Load secret key using local config / env var in production app.config["SECRET_KEY"] = "session-cookie-signing-key" txhash = '' @app.route("/") def index(): return render_template("ind...
30.416667
76
0.706849
59a400d46130b8c8c86037cc3ec3c807b4828675
5,314
py
Python
coherence_timeseries.py
olliestephenson/dpm-rnn-public
bc4247fd7126eac66dd07c50149a62be72a316ec
[ "MIT" ]
13
2021-07-03T09:58:55.000Z
2022-03-30T13:36:30.000Z
coherence_timeseries.py
olliestephenson/dpm-rnn-public
bc4247fd7126eac66dd07c50149a62be72a316ec
[ "MIT" ]
null
null
null
coherence_timeseries.py
olliestephenson/dpm-rnn-public
bc4247fd7126eac66dd07c50149a62be72a316ec
[ "MIT" ]
5
2021-02-18T16:54:25.000Z
2022-03-31T08:02:54.000Z
import os import numpy as np import torch from torch.utils.data import Dataset from enum import Enum class Mode(Enum): DEPLOY = 0 TRAIN = 1 TEST = 2 class Coherence_Timeseries(Dataset): data_dim = 1 # coherence values are scalar (dimension = 1) mode = Mode.DEPLOY # default mode def __init...
37.160839
122
0.629093
d3825a517263d7c77e0670ea7e6260ca8ae1d204
7,178
bzl
Python
apple/internal/binary_support.bzl
acecilia/rules_apple
3a295d2a2702800d77e2c583f3a77262e764823e
[ "Apache-2.0" ]
1
2022-02-16T12:42:23.000Z
2022-02-16T12:42:23.000Z
apple/internal/binary_support.bzl
acecilia/rules_apple
3a295d2a2702800d77e2c583f3a77262e764823e
[ "Apache-2.0" ]
11
2019-10-15T23:03:57.000Z
2020-06-14T16:10:12.000Z
apple/internal/binary_support.bzl
acecilia/rules_apple
3a295d2a2702800d77e2c583f3a77262e764823e
[ "Apache-2.0" ]
7
2019-07-04T14:23:54.000Z
2020-04-27T08:52:51.000Z
# Copyright 2017 The Bazel 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 applicable la...
38.180851
100
0.690582
b126aeab73d672fb64e7e9f736b3cc2c4ee0a256
5,270
py
Python
salt/_compat.py
moniker-dns/salt
0e1cd880dc7831b9f937a213dd90cc32e2a09884
[ "Apache-2.0" ]
1
2016-03-13T09:05:15.000Z
2016-03-13T09:05:15.000Z
salt/_compat.py
moniker-dns/salt
0e1cd880dc7831b9f937a213dd90cc32e2a09884
[ "Apache-2.0" ]
null
null
null
salt/_compat.py
moniker-dns/salt
0e1cd880dc7831b9f937a213dd90cc32e2a09884
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- ''' Salt compatibility code ''' # pylint: disable=W0611 # Import python libs import sys import types try: import cPickle as pickle except ImportError: import pickle try: # Python >2.5 import xml.etree.cElementTree as ElementTree except ImportError: try: # Python >2.5...
28.333333
80
0.663378
b28a39c4dde1a8fc70edad7bc8121516ad6030e5
6,669
py
Python
Room.py
AldoAbdn/Polar-Simulator-2017
1824cc1faa76fbaed8e4fa143679f1aed8685590
[ "MIT" ]
null
null
null
Room.py
AldoAbdn/Polar-Simulator-2017
1824cc1faa76fbaed8e4fa143679f1aed8685590
[ "MIT" ]
null
null
null
Room.py
AldoAbdn/Polar-Simulator-2017
1824cc1faa76fbaed8e4fa143679f1aed8685590
[ "MIT" ]
null
null
null
import pygame from pygame.locals import * from EventManager import EventManager from EventHandlers import RoomEventHandlers from SoundManager import SoundManager from Crate import Crate from Wall import Wall from WarehouseKeeper import WarehouseKeeper from Tile import Diamond from Tile import Tile from Grid i...
40.664634
192
0.606838
35cfe3e9fb76f502a6b60ce3f92e37e261cfc81a
6,096
py
Python
qa/rpc-tests/proxy_test.py
MichaelHDesigns/Bitcoin-Token-Core
61f7837fe83994cb9b76d28a55e75dc9fa86f1fd
[ "MIT" ]
null
null
null
qa/rpc-tests/proxy_test.py
MichaelHDesigns/Bitcoin-Token-Core
61f7837fe83994cb9b76d28a55e75dc9fa86f1fd
[ "MIT" ]
null
null
null
qa/rpc-tests/proxy_test.py
MichaelHDesigns/Bitcoin-Token-Core
61f7837fe83994cb9b76d28a55e75dc9fa86f1fd
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 # Copyright (c) 2015 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. import socket import traceback, sys from binascii import hexlify import time, os from socks5 import Socks5Conf...
41.753425
145
0.652887
519e7cc48cab3c9573d007ce00af528a04335789
1,322
py
Python
commit_data.py
iwangjian/ByteCup2018
c59c6a495f81c493eaaf7fda710c8acd7ef148b9
[ "MIT" ]
80
2018-09-08T01:11:36.000Z
2022-01-18T13:41:30.000Z
commit_data.py
BoostMom/ByteCup2018
c59c6a495f81c493eaaf7fda710c8acd7ef148b9
[ "MIT" ]
3
2018-12-02T15:08:05.000Z
2020-02-10T04:11:28.000Z
commit_data.py
BoostMom/ByteCup2018
c59c6a495f81c493eaaf7fda710c8acd7ef148b9
[ "MIT" ]
21
2018-10-27T07:40:25.000Z
2022-03-28T12:30:01.000Z
import os import argparse def process_decoded(args): if not os.path.exists(args.result_dir): os.mkdir(args.result_dir) punct = ["/", "`", "+", "-", ";", "-lrb-", "-rrb-", "``", "|", "~", "&quot"] for file in os.listdir(args.decode_dir): file_path = os.path.join(args.decode_dir, file) ...
33.897436
89
0.553707
886c36e0f2c94072803f50ab03678d988783fba7
349
py
Python
JustPy/04.Handling/mail.py
sarincr/Python-Web-Frameworks-and-Template-Engines
a830cafb0075539527688ea3c12e3e2d97d3519f
[ "MIT" ]
null
null
null
JustPy/04.Handling/mail.py
sarincr/Python-Web-Frameworks-and-Template-Engines
a830cafb0075539527688ea3c12e3e2d97d3519f
[ "MIT" ]
null
null
null
JustPy/04.Handling/mail.py
sarincr/Python-Web-Frameworks-and-Template-Engines
a830cafb0075539527688ea3c12e3e2d97d3519f
[ "MIT" ]
null
null
null
import justpy as jp def my_click(self, msg): self.text = 'I was clicked' print(msg.event_type) print(msg['event_type']) print(msg) def event_demo(): wp = jp.WebPage() d = jp.P(text='Not clicked yet', a=wp, classes='text-xl m-2 p-2 bg-blue-500 text-white') d.on('click', my_click) return...
20.529412
92
0.636103
e14ddb6cae4737692f361260b3fece66704c6fc7
836
py
Python
visualize.py
nime6/voxeldc-gan
e11e8248dc8ce0e3930de0f2867ef0fb395d5934
[ "MIT" ]
146
2016-09-30T01:41:23.000Z
2022-03-10T15:16:45.000Z
visualize.py
nime6/voxeldc-gan
e11e8248dc8ce0e3930de0f2867ef0fb395d5934
[ "MIT" ]
7
2017-03-02T14:13:32.000Z
2020-01-07T07:22:00.000Z
visualize.py
nime6/voxeldc-gan
e11e8248dc8ce0e3930de0f2867ef0fb395d5934
[ "MIT" ]
40
2017-01-20T13:36:33.000Z
2020-04-07T04:25:28.000Z
import tensorflow as tf import numpy as np import util import config from model import * netG = Generator() z = tf.placeholder(tf.float32, [config.batch_size, config.nz]) train = tf.placeholder(tf.bool) x = netG(z, train, config.nsf, config.nvx) t_vars = tf.trainable_variables() varsG = [var for var in t_vars if va...
29.857143
89
0.715311
d9dadb00c503d68ce7fa353d6d1f317a72e28769
929
py
Python
azure-mgmt-containerregistry/azure/mgmt/containerregistry/v2018_09_01/operations/__init__.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
1
2021-09-07T18:36:04.000Z
2021-09-07T18:36:04.000Z
azure-mgmt-containerregistry/azure/mgmt/containerregistry/v2018_09_01/operations/__init__.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
2
2019-10-02T23:37:38.000Z
2020-10-02T01:17:31.000Z
azure-mgmt-containerregistry/azure/mgmt/containerregistry/v2018_09_01/operations/__init__.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
1
2018-08-28T14:36:47.000Z
2018-08-28T14:36:47.000Z
# 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 ...
34.407407
76
0.662002
f717953473fd5d44045b712a4f139e641a8c661b
27,730
py
Python
InstallOpenface/fix_sklearn/label.py
s123600g/openfaceInstallscript
962b4b89c5626318b5701d7297d49df3423b0fe4
[ "MIT" ]
null
null
null
InstallOpenface/fix_sklearn/label.py
s123600g/openfaceInstallscript
962b4b89c5626318b5701d7297d49df3423b0fe4
[ "MIT" ]
null
null
null
InstallOpenface/fix_sklearn/label.py
s123600g/openfaceInstallscript
962b4b89c5626318b5701d7297d49df3423b0fe4
[ "MIT" ]
null
null
null
# Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Mathieu Blondel <mathieu@mblondel.org> # Olivier Grisel <olivier.grisel@ensta.org> # Andreas Mueller <amueller@ais.uni-bonn.de> # Joel Nothman <joel.nothman@gmail.com> # Hamzeh Alsalhi <ha258@cornell.edu> # Licens...
33.329327
87
0.588136
d8d281e08b8a9f30580b7ba5501ec6efe951376e
17,695
py
Python
experiments/net_rec.py
small-yellow-duck/titanic-ede
0a3e1b352ccff83a8308e190955bf839be9d2ef5
[ "BSD-3-Clause" ]
1
2019-07-24T14:15:38.000Z
2019-07-24T14:15:38.000Z
experiments/net_rec.py
small-yellow-duck/titanic-ede
0a3e1b352ccff83a8308e190955bf839be9d2ef5
[ "BSD-3-Clause" ]
null
null
null
experiments/net_rec.py
small-yellow-duck/titanic-ede
0a3e1b352ccff83a8308e190955bf839be9d2ef5
[ "BSD-3-Clause" ]
null
null
null
# -*- encoding: utf-8 -*- import torch import torch.nn as nn import torch.nn.functional as F from torch.autograd import Variable import numpy as np from torch.nn.parameter import Parameter from torch.nn import functional as F def get_embedding_weight(num_embeddings, embedding_dim, use_cuda): t = torch.rand(num_e...
36.559917
147
0.586324
6bcc38c2c21b6f3a3b0caf51bcc0b9113e5424f4
2,811
py
Python
src/emcr/skeleton.py
shashankvadrevu/EMCR
6ec548e3b9e1f97606b24e91807d655e2a180674
[ "MIT" ]
null
null
null
src/emcr/skeleton.py
shashankvadrevu/EMCR
6ec548e3b9e1f97606b24e91807d655e2a180674
[ "MIT" ]
null
null
null
src/emcr/skeleton.py
shashankvadrevu/EMCR
6ec548e3b9e1f97606b24e91807d655e2a180674
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This is a skeleton file that can serve as a starting point for a Python console script. To run this script uncomment the following lines in the [options.entry_points] section in setup.cfg: console_scripts = fibonacci = emcr.skeleton:run Then run `python s...
24.025641
77
0.635005
cb8bef2677dd3a83ffd137ece313c87f279d6f31
4,737
py
Python
demo_site/settings.py
williwacker/django-qr-code
17aba885a82a7fde1ac784e9c183f4c7e40cd7eb
[ "BSD-3-Clause" ]
null
null
null
demo_site/settings.py
williwacker/django-qr-code
17aba885a82a7fde1ac784e9c183f4c7e40cd7eb
[ "BSD-3-Clause" ]
null
null
null
demo_site/settings.py
williwacker/django-qr-code
17aba885a82a7fde1ac784e9c183f4c7e40cd7eb
[ "BSD-3-Clause" ]
null
null
null
""" Django settings for qr_code_demo project. Generated by 'django-admin startproject' using Django 1.11. For more information on this file, see https://docs.djangoproject.com/en/1.11/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.11/ref/settings/ """ import...
31.370861
335
0.709943
5551d6fa219aee9b3ced7d5f7daceb7fb28b837a
3,239
py
Python
plugins/holland.backup.mysql_lvm/holland/backup/mysql_lvm/plugin/raw/util.py
Alibloke/holland
e630b511a95ed8e36205e8300e632018918223ff
[ "BSD-3-Clause" ]
null
null
null
plugins/holland.backup.mysql_lvm/holland/backup/mysql_lvm/plugin/raw/util.py
Alibloke/holland
e630b511a95ed8e36205e8300e632018918223ff
[ "BSD-3-Clause" ]
null
null
null
plugins/holland.backup.mysql_lvm/holland/backup/mysql_lvm/plugin/raw/util.py
Alibloke/holland
e630b511a95ed8e36205e8300e632018918223ff
[ "BSD-3-Clause" ]
null
null
null
"""Utility functions to help out the mysql-lvm plugin""" import os import tempfile import logging from holland.core.backup import BackupError from holland.lib.compression import open_stream from holland.backup.mysql_lvm.actions import ( FlushAndLockMySQLAction, RecordMySQLReplicationAction, InnodbRecoveryAc...
39.987654
100
0.658845
6a15b6798016b88098740182d6aaba11969bb524
11,660
py
Python
notify_sdk/model/easy_flow/target_info_pb2.py
easyopsapis/easyops-api-python
adf6e3bad33fa6266b5fa0a449dd4ac42f8447d0
[ "Apache-2.0" ]
5
2019-07-31T04:11:05.000Z
2021-01-07T03:23:20.000Z
notify_sdk/model/easy_flow/target_info_pb2.py
easyopsapis/easyops-api-python
adf6e3bad33fa6266b5fa0a449dd4ac42f8447d0
[ "Apache-2.0" ]
null
null
null
notify_sdk/model/easy_flow/target_info_pb2.py
easyopsapis/easyops-api-python
adf6e3bad33fa6266b5fa0a449dd4ac42f8447d0
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: target_info.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf...
46.64
1,148
0.761407
a560a32700f691dc73b420e6e6856a4d4560d976
19,233
py
Python
edexOsgi/com.raytheon.uf.common.aviation/utility/common_static/base/aviation/python/GridData.py
srcarter3/awips2
37f31f5e88516b9fd576eaa49d43bfb762e1d174
[ "Apache-2.0" ]
null
null
null
edexOsgi/com.raytheon.uf.common.aviation/utility/common_static/base/aviation/python/GridData.py
srcarter3/awips2
37f31f5e88516b9fd576eaa49d43bfb762e1d174
[ "Apache-2.0" ]
null
null
null
edexOsgi/com.raytheon.uf.common.aviation/utility/common_static/base/aviation/python/GridData.py
srcarter3/awips2
37f31f5e88516b9fd576eaa49d43bfb762e1d174
[ "Apache-2.0" ]
1
2021-10-30T00:03:05.000Z
2021-10-30T00:03:05.000Z
## # This software was developed and / or modified by Raytheon Company, # pursuant to Contract DG133W-05-CQ-1067 with the US Government. # # U.S. EXPORT CONTROLLED TECHNICAL DATA # This software product contains export-restricted data whose # export/transfer/disclosure is restricted by U.S. law. Dissemination # to non...
34.283422
122
0.542089
83318e398572b3738fc257571cdb6bc759a514c1
7,490
py
Python
addon-fEVR/rootfs/var/www/html/cgi-bin/events.py
BeardedTek/BeardedTek-hassio-addons
1f3468417d98c0939a405770a4efedf7e52a43df
[ "MIT" ]
2
2021-12-26T03:03:48.000Z
2022-03-07T03:11:45.000Z
addon-fEVR/rootfs/var/www/html/cgi-bin/events.py
BeardedTek/BeardedTek-hassio-addons
1f3468417d98c0939a405770a4efedf7e52a43df
[ "MIT" ]
1
2021-12-18T21:48:20.000Z
2022-03-07T17:51:35.000Z
addon-fEVR/rootfs/var/www/html/cgi-bin/events.py
BeardedTek/BeardedTek-hassio-addons
1f3468417d98c0939a405770a4efedf7e52a43df
[ "MIT" ]
null
null
null
#!/usr/bin/python # fEVR (Frigate Event Video Recorder) Events Menu # # Copyright (C) 2021-2022 The Bearded Tek (http://www.beardedtek.com) William Kenny # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the ...
41.381215
102
0.557677
274400daaf7a8f1786e00c9d36a6514fcfbb666b
1,276
py
Python
predict.py
KelvinKim1/promotion_lab
7e2847146383dc8948f9004a1217c1263de4ab56
[ "MIT" ]
null
null
null
predict.py
KelvinKim1/promotion_lab
7e2847146383dc8948f9004a1217c1263de4ab56
[ "MIT" ]
null
null
null
predict.py
KelvinKim1/promotion_lab
7e2847146383dc8948f9004a1217c1263de4ab56
[ "MIT" ]
null
null
null
import regression_tree import Bayes_classifier import sys import csv data = [] with open("training_set.csv") as csvfile, open("test_set.csv") as csvfile2, open("predicted.csv","w") as t: readCSV = csv.reader(csvfile, delimiter=',') readCSV2 = csv.reader(csvfile2, delimiter=',') temp = csv.writer(t,delimit...
25.019608
107
0.626176
2c2ad689e2c1ae754f37ee6ed5ba2c30ff57db1d
2,459
py
Python
recipe_scrapers/hellofresh.py
chrisbubernak/recipe-scrapers
1617a542f6e728552886aebd29f14e97feeb8f5c
[ "MIT" ]
1
2021-02-07T17:48:09.000Z
2021-02-07T17:48:09.000Z
recipe_scrapers/hellofresh.py
chrisbubernak/recipe-scrapers
1617a542f6e728552886aebd29f14e97feeb8f5c
[ "MIT" ]
null
null
null
recipe_scrapers/hellofresh.py
chrisbubernak/recipe-scrapers
1617a542f6e728552886aebd29f14e97feeb8f5c
[ "MIT" ]
null
null
null
import re from ._abstract import AbstractScraper from ._utils import get_minutes, normalize_string, get_yields class HelloFresh(AbstractScraper): @classmethod def host(self, domain="com"): return f"hellofresh.{domain}" def title(self): return self.soup.find("h1").get_text() def tot...
29.626506
87
0.53233
72571bf4fad4e7b4e8346f4b64a7455ee6ce740c
30,036
py
Python
zerver/tests/test_docs.py
yuroitaki/zulip
95303a9929424b55a1f7c7cce9313c4619a9533b
[ "Apache-2.0" ]
1
2022-01-26T14:45:16.000Z
2022-01-26T14:45:16.000Z
zerver/tests/test_docs.py
jai2201/zulip
95303a9929424b55a1f7c7cce9313c4619a9533b
[ "Apache-2.0" ]
null
null
null
zerver/tests/test_docs.py
jai2201/zulip
95303a9929424b55a1f7c7cce9313c4619a9533b
[ "Apache-2.0" ]
null
null
null
import os import re from typing import TYPE_CHECKING, Any, Dict, Sequence from unittest import mock, skipUnless from urllib.parse import urlsplit import orjson from django.conf import settings from django.test import override_settings from django.utils.timezone import now as timezone_now from corporate.models import ...
47.07837
100
0.659475
a7df4eec6c025af7efb1f55e70c01bdf539d5584
983
py
Python
budgetportal/migrations/0005_department-unique-together-constraints.py
fluenty/datamanager
97ba9d58d4527b7d61b730ea4896f09a56e6ae60
[ "MIT" ]
null
null
null
budgetportal/migrations/0005_department-unique-together-constraints.py
fluenty/datamanager
97ba9d58d4527b7d61b730ea4896f09a56e6ae60
[ "MIT" ]
null
null
null
budgetportal/migrations/0005_department-unique-together-constraints.py
fluenty/datamanager
97ba9d58d4527b7d61b730ea4896f09a56e6ae60
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11.8 on 2017-12-14 10:27 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('budgetportal', '0004_government-unique-together-constraints'), ] operations = [ ...
28.085714
113
0.581892
13ed68b0a627c01009fc291acf7e79224dc3d799
25,549
py
Python
pajbot/modules/playsound.py
sadlyfell/bullbot
b6ef96f61678fab4a245d8ccddf9d1ae7aae9fee
[ "MIT" ]
null
null
null
pajbot/modules/playsound.py
sadlyfell/bullbot
b6ef96f61678fab4a245d8ccddf9d1ae7aae9fee
[ "MIT" ]
null
null
null
pajbot/modules/playsound.py
sadlyfell/bullbot
b6ef96f61678fab4a245d8ccddf9d1ae7aae9fee
[ "MIT" ]
null
null
null
import json import logging import re from argparse import ArgumentParser from pajbot.managers.db import DBManager from pajbot.models.playsound import Playsound from pajbot.modules import BaseModule from pajbot.modules import ModuleSetting log = logging.getLogger(__name__) class PlaysoundModule(BaseModule): ID =...
38.887367
120
0.526205
6df7d2565de18251cbc1741f5efc0493428dacfd
182
py
Python
hTools2.roboFontExt/lib/Scripts/selected glyphs/transform/gridfit.py
frankrolf/hTools2_extension
9d73b8640c85209853a72f8d4b167768de5e0d60
[ "BSD-3-Clause" ]
2
2019-12-18T16:12:07.000Z
2019-12-21T01:19:23.000Z
hTools2.roboFontExt/lib/Scripts/selected glyphs/transform/gridfit.py
frankrolf/hTools2_extension
9d73b8640c85209853a72f8d4b167768de5e0d60
[ "BSD-3-Clause" ]
null
null
null
hTools2.roboFontExt/lib/Scripts/selected glyphs/transform/gridfit.py
frankrolf/hTools2_extension
9d73b8640c85209853a72f8d4b167768de5e0d60
[ "BSD-3-Clause" ]
null
null
null
# [h] fit to grid dialog import hTools2.dialogs.glyphs.gridfit import importlib importlib.reload(hTools2.dialogs.glyphs.gridfit) hTools2.dialogs.glyphs.gridfit.roundToGridDialog()
22.75
50
0.824176
c961e7968ad6a762f86b400d59107435a0f7337a
926
py
Python
cosypose/simulator/textures.py
ompugao/cosypose
4e471c16f19d5ee632668cd52eaa57b562f287d6
[ "MIT" ]
202
2020-08-19T19:28:03.000Z
2022-03-29T07:10:47.000Z
cosypose/simulator/textures.py
ompugao/cosypose
4e471c16f19d5ee632668cd52eaa57b562f287d6
[ "MIT" ]
66
2020-08-24T09:28:05.000Z
2022-03-31T07:11:06.000Z
cosypose/simulator/textures.py
ompugao/cosypose
4e471c16f19d5ee632668cd52eaa57b562f287d6
[ "MIT" ]
66
2020-08-19T19:28:05.000Z
2022-03-18T20:47:55.000Z
import numpy as np from collections import defaultdict import pybullet as pb def apply_random_textures(body, texture_ids, per_link=False, np_random=np.random): data = body.visual_shape_data visual_shapes_ids = [t[1] for t in data] n_shapes = defaultdict(lambda: 0) for i in visual_shapes_ids: n...
38.583333
84
0.62635
fa50320b27220309d4d11b8fd1707c8fc39e59d1
2,202
py
Python
src/features.py
sebastiani/versa
019503c568b9e62aec05dc29eb75db9ff7c1ab9c
[ "MIT" ]
null
null
null
src/features.py
sebastiani/versa
019503c568b9e62aec05dc29eb75db9ff7c1ab9c
[ "MIT" ]
null
null
null
src/features.py
sebastiani/versa
019503c568b9e62aec05dc29eb75db9ff7c1ab9c
[ "MIT" ]
null
null
null
import tensorflow as tf from utilities import conv2d_pool_block, dense_block, conv2d_transpose_layer, dense_layer def extract_features(images, output_size, use_batch_norm, dropout_keep_prob): """ Based on the architecture described in 'Matching Networks for One-Shot Learning' http://arxiv.org/abs/1606.040...
40.777778
111
0.737057
24add0adfd598625649d003ed0767b0d6acadca4
804
py
Python
04_jump_the_five/jump.py
claracoo/tiny_python_projects
120a414e3b6125b537ce94f1fdec7faa9cf59b1f
[ "MIT" ]
null
null
null
04_jump_the_five/jump.py
claracoo/tiny_python_projects
120a414e3b6125b537ce94f1fdec7faa9cf59b1f
[ "MIT" ]
null
null
null
04_jump_the_five/jump.py
claracoo/tiny_python_projects
120a414e3b6125b537ce94f1fdec7faa9cf59b1f
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """Jump the Five""" import argparse # -------------------------------------------------- def get_args(): """Get command-line arguments""" parser = argparse.ArgumentParser( description='Jump the Five', formatter_class=argparse.ArgumentDefaultsHelpFormatter) parser....
25.125
65
0.458955
bc8fc1b51b55e07f3f5c533ec2e8a318aea38cb1
18,819
py
Python
log_complete/model_698.py
LoLab-VU/Bayesian_Inference_of_Network_Dynamics
54a5ef7e868be34289836bbbb024a2963c0c9c86
[ "MIT" ]
null
null
null
log_complete/model_698.py
LoLab-VU/Bayesian_Inference_of_Network_Dynamics
54a5ef7e868be34289836bbbb024a2963c0c9c86
[ "MIT" ]
null
null
null
log_complete/model_698.py
LoLab-VU/Bayesian_Inference_of_Network_Dynamics
54a5ef7e868be34289836bbbb024a2963c0c9c86
[ "MIT" ]
null
null
null
# exported from PySB model 'model' from pysb import Model, Monomer, Parameter, Expression, Compartment, Rule, Observable, Initial, MatchOnce, Annotation, ANY, WILD Model() Monomer('Ligand', ['Receptor']) Monomer('ParpU', ['C3A']) Monomer('C8A', ['BidU', 'C3pro']) Monomer('SmacM', ['BaxA']) Monomer('BaxM', ['BidM', '...
91.354369
710
0.806525
75d746fd45140bb01d6d31ebc50bbb45880e0865
103,634
py
Python
flakylib.py
R-Mussabayev/flakylib
dc79ec1b1210ca91aac64fec28ba94fa087cc90e
[ "MIT" ]
3
2020-07-08T18:31:31.000Z
2022-03-03T10:26:53.000Z
flakylib.py
R-Mussabayev/flakylib
dc79ec1b1210ca91aac64fec28ba94fa087cc90e
[ "MIT" ]
null
null
null
flakylib.py
R-Mussabayev/flakylib
dc79ec1b1210ca91aac64fec28ba94fa087cc90e
[ "MIT" ]
null
null
null
# Flaky Clustering Library v0.1 # Big MSSC (Minimum Sum-Of-Squares Clustering) # Nenad Mladenovic, Rustam Mussabayev, Alexander Krassovitskiy # rmusab@gmail.com # v0.11 - 06/09/2021 - Revision of VNS logic in Membership_Shaking_VNS and Center_Shaking_VNS # v0.1 - 30/06/2021 - Bug fixing in multi_portion_mssc # v0.0...
41.974079
355
0.607947
d258d57a19f8c4d94fa0aab9a02b2d728f8ab239
3,132
py
Python
zunis_lib/zunis/utils/function_wrapper.py
NGoetz/zunis
a2d3ba2392ef802349723465c6559e8eb407db54
[ "MIT" ]
18
2020-08-20T15:29:12.000Z
2022-03-21T09:41:44.000Z
zunis_lib/zunis/utils/function_wrapper.py
NGoetz/zunis
a2d3ba2392ef802349723465c6559e8eb407db54
[ "MIT" ]
13
2020-08-25T10:53:58.000Z
2022-03-25T15:25:10.000Z
zunis_lib/zunis/utils/function_wrapper.py
NGoetz/zunis
a2d3ba2392ef802349723465c6559e8eb407db54
[ "MIT" ]
2
2020-09-07T17:17:36.000Z
2020-12-30T01:22:23.000Z
"""Function wrappers to provide API-compatible functions""" import torch def wrap_numpy_hypercube_batch_function(f): """Take a function that evaluates on numpy batches with values in the unit hypercube and return a function that evaluates on pytorch batches in the unit hypercube """ def torchf(x): ...
39.64557
120
0.6606
1737012686d95b66a64c0594f35e9dc641baecc5
47,655
py
Python
calico/felix/plugins/fiptgenerator.py
ozdanborne/felix
5eff313e6498b3a7d775aa16cb09fd4578331701
[ "Apache-2.0" ]
6
2016-10-18T04:04:25.000Z
2016-10-18T04:06:49.000Z
calico/felix/plugins/fiptgenerator.py
ozdanborne/felix
5eff313e6498b3a7d775aa16cb09fd4578331701
[ "Apache-2.0" ]
1
2021-06-01T21:45:37.000Z
2021-06-01T21:45:37.000Z
calico/felix/plugins/fiptgenerator.py
ozdanborne/felix
5eff313e6498b3a7d775aa16cb09fd4578331701
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2015-2016 Tigera, Inc. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unle...
43.009928
79
0.562333
409f4fe3277097ce43757facb093414115570ce0
182
py
Python
app/ssp_module/errors.py
khushalt/ssp_india
02d760ae25917e86ea03ac5f5845068d7d987bdb
[ "MIT" ]
1
2020-07-04T14:42:49.000Z
2020-07-04T14:42:49.000Z
app/ssp_module/errors.py
khushalt/ssp_india
02d760ae25917e86ea03ac5f5845068d7d987bdb
[ "MIT" ]
null
null
null
app/ssp_module/errors.py
khushalt/ssp_india
02d760ae25917e86ea03ac5f5845068d7d987bdb
[ "MIT" ]
null
null
null
from flask import render_template from app.ssp_module import create_app @create_app().errorhandler(404) def not_found_error(error): return render_template('error/404.html'), 404
30.333333
49
0.807692
e969021a6cfb1ee2142d5bf0508049c43785e67f
5,913
py
Python
sct_custom/spinalcordtoolbox/scripts/sct_crop_image.py
nidebroux/lumbosacral_segmentation
3217960c6f0f5c3886dfdf46e1286ad2f737f4aa
[ "Unlicense", "MIT" ]
1
2021-09-07T08:52:21.000Z
2021-09-07T08:52:21.000Z
sct_custom/spinalcordtoolbox/scripts/sct_crop_image.py
nidebroux/lumbosacral_segmentation
3217960c6f0f5c3886dfdf46e1286ad2f737f4aa
[ "Unlicense", "MIT" ]
null
null
null
sct_custom/spinalcordtoolbox/scripts/sct_crop_image.py
nidebroux/lumbosacral_segmentation
3217960c6f0f5c3886dfdf46e1286ad2f737f4aa
[ "Unlicense", "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 # # CLI script to crop an image. # # Copyright (c) 2019 Polytechnique Montreal <www.neuro.polymtl.ca> # Authors: Julien Cohen-Adad # # About the license: see the file LICENSE.TXT import sys import os from spinalcordtoolbox.cropping import ImageCropper, BoundingBox from spinal...
32.489011
118
0.611703
1b21b3ce9aa871f15ec056aca3271ed0019d0b68
1,589
gyp
Python
third_party/fontconfig/fontconfig.gyp
iplo/Chain
8bc8943d66285d5258fffc41bed7c840516c4422
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
231
2015-01-08T09:04:44.000Z
2021-12-30T03:03:10.000Z
third_party/fontconfig/fontconfig.gyp
JasonEric/chromium
c7361d39be8abd1574e6ce8957c8dbddd4c6ccf7
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
1
2017-02-14T21:55:58.000Z
2017-02-14T21:55:58.000Z
third_party/fontconfig/fontconfig.gyp
JasonEric/chromium
c7361d39be8abd1574e6ce8957c8dbddd4c6ccf7
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
268
2015-01-21T05:53:28.000Z
2022-03-25T22:09:01.000Z
# Copyright 2014 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. { 'targets': [ { 'target_name': 'fontconfig', 'type': '<(component)', 'dependencies' : [ '../zlib/zlib.gyp:zlib', '.....
25.222222
72
0.488357
bcfbfe486a266b015cb48714e8753a1d0909ad34
1,126
py
Python
UltronRoBo/utils/filter_groups.py
UltronRoBo/UltronRoBoAssistant
874dcf725d453ffabd85543533d2a07676af4d65
[ "MIT" ]
null
null
null
UltronRoBo/utils/filter_groups.py
UltronRoBo/UltronRoBoAssistant
874dcf725d453ffabd85543533d2a07676af4d65
[ "MIT" ]
null
null
null
UltronRoBo/utils/filter_groups.py
UltronRoBo/UltronRoBoAssistant
874dcf725d453ffabd85543533d2a07676af4d65
[ "MIT" ]
null
null
null
""" MIT License Copyright (c) 2021 UltronRoBo 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, publish, di...
41.703704
78
0.801066
f63217b8619e680626a8582b22c6519590b2800c
227
py
Python
Programmers/[cutz]hate same num.py
cutz-j/AlgorithmStudy
de0f81220e29bd5e109d174800f507b12a3bee36
[ "MIT" ]
3
2019-11-26T14:31:01.000Z
2020-01-10T18:19:46.000Z
Programmers/[cutz]hate same num.py
cutz-j/AlgorithmStudy
de0f81220e29bd5e109d174800f507b12a3bee36
[ "MIT" ]
null
null
null
Programmers/[cutz]hate same num.py
cutz-j/AlgorithmStudy
de0f81220e29bd5e109d174800f507b12a3bee36
[ "MIT" ]
null
null
null
import sys def solution(arr): # 중복 수 제거 / 순서 유지 # 10**6 --> O(n) answer = [arr[0]] for a in arr[1:]: if a == answer[-1]: continue else: answer.append(a) return answer
18.916667
28
0.45815
9b14420a0061ef096b38daa64cd2955d62ae77e1
21,427
py
Python
lms/resources/_js_config/__init__.py
hypothesis/lms
722dac444dc1e73298eea5193f871f3ddefe46fd
[ "BSD-2-Clause" ]
38
2017-12-30T23:49:53.000Z
2022-02-15T21:07:49.000Z
lms/resources/_js_config/__init__.py
hypothesis/lms
722dac444dc1e73298eea5193f871f3ddefe46fd
[ "BSD-2-Clause" ]
1,733
2017-11-09T18:46:05.000Z
2022-03-31T11:05:50.000Z
lms/resources/_js_config/__init__.py
hypothesis/lms
722dac444dc1e73298eea5193f871f3ddefe46fd
[ "BSD-2-Clause" ]
10
2018-07-11T17:12:46.000Z
2022-01-07T20:00:23.000Z
import functools from enum import Enum from typing import List, Optional from lms.models import ApplicationInstance, GroupInfo, HUser from lms.resources._js_config.file_picker_config import FilePickerConfig from lms.services import HAPIError from lms.validation.authentication import BearerTokenSchema from lms.views.he...
38.817029
117
0.601344
cb7c5b7df70ada1b943c479aede913bb7f43898a
1,328
py
Python
setup.py
CIGIHub/newsletter_generator
2af3e183ffedce55ad26bf998c488282f94d477e
[ "MIT" ]
null
null
null
setup.py
CIGIHub/newsletter_generator
2af3e183ffedce55ad26bf998c488282f94d477e
[ "MIT" ]
null
null
null
setup.py
CIGIHub/newsletter_generator
2af3e183ffedce55ad26bf998c488282f94d477e
[ "MIT" ]
null
null
null
import os from setuptools import setup from setuptools import find_packages with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme: README = readme.read() # allow setup.py to be run from any path os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) setup( name='n...
32.390244
78
0.636295
f3bb25ac43535b771a6d2ab70dc603b83d78d59a
4,519
py
Python
test/generic_distributed_util_test.py
jerryzh168/ClassyVision-1
6acfb00a77487a9015803fbaad805330081293a9
[ "MIT" ]
1
2020-04-13T03:50:26.000Z
2020-04-13T03:50:26.000Z
test/generic_distributed_util_test.py
pkassotis/ClassyVision
e8704ecaa59a15dbb2f4b0724e85d6e5cb2f704e
[ "MIT" ]
null
null
null
test/generic_distributed_util_test.py
pkassotis/ClassyVision
e8704ecaa59a15dbb2f4b0724e85d6e5cb2f704e
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import tempfile import unittest from itertools import product from typing import Any, Dict, List import torch from cla...
32.985401
116
0.55322
f609b5fb8bc157283e76ef0f5e2a04ed34fef994
13,556
py
Python
doc/source/conf.py
walterst/bipy
49a3a9c33fd0c8c12bbb8f5cbb7e171f78fc4a96
[ "BSD-3-Clause" ]
null
null
null
doc/source/conf.py
walterst/bipy
49a3a9c33fd0c8c12bbb8f5cbb7e171f78fc4a96
[ "BSD-3-Clause" ]
null
null
null
doc/source/conf.py
walterst/bipy
49a3a9c33fd0c8c12bbb8f5cbb7e171f78fc4a96
[ "BSD-3-Clause" ]
1
2018-09-21T01:58:43.000Z
2018-09-21T01:58:43.000Z
import shutil import glob import sys import os import sphinx_bootstrap_theme import skbio # NOTE: parts of this file were taken from scipy's doc/source/conf.py. See # scikit-bio/licenses/scipy.txt for scipy's license. # If readthedocs.org is building the project, delete the generated/ directory, # which is created ...
31.163218
80
0.673134
681419994324038e4930e366c07abd5f6ae43dc1
1,555
py
Python
stubs.min/Autodesk/Revit/DB/__init___parts/CurtainCell.py
hdm-dt-fb/ironpython-stubs
4d2b405eda3ceed186e8adca55dd97c332c6f49d
[ "MIT" ]
1
2017-07-25T14:30:18.000Z
2017-07-25T14:30:18.000Z
stubs.min/Autodesk/Revit/DB/__init___parts/CurtainCell.py
hdm-dt-fb/ironpython-stubs
4d2b405eda3ceed186e8adca55dd97c332c6f49d
[ "MIT" ]
null
null
null
stubs.min/Autodesk/Revit/DB/__init___parts/CurtainCell.py
hdm-dt-fb/ironpython-stubs
4d2b405eda3ceed186e8adca55dd97c332c6f49d
[ "MIT" ]
null
null
null
class CurtainCell(APIObject,IDisposable): """ Represents a CurtainCell within Autodesk Revit. """ def Dispose(self): """ Dispose(self: APIObject,A_0: bool) """ pass def ReleaseManagedResources(self,*args): """ ReleaseManagedResources(self: APIObject) """ pass def ReleaseUnmanagedResources(self,*args...
43.194444
215
0.725402
620a33e4fc35345e615b41847b46ef5b53c016b9
214
py
Python
dosing_rl_gym/__init__.py
strongio/dosing-rl-gym
e9f0553080830dc621e97e0652c68b86788b7296
[ "MIT" ]
6
2020-01-30T11:31:53.000Z
2021-12-02T10:35:27.000Z
dosing_rl_gym/__init__.py
strongio/dosing-rl-gym
e9f0553080830dc621e97e0652c68b86788b7296
[ "MIT" ]
null
null
null
dosing_rl_gym/__init__.py
strongio/dosing-rl-gym
e9f0553080830dc621e97e0652c68b86788b7296
[ "MIT" ]
3
2019-11-13T15:56:14.000Z
2021-04-12T07:20:23.000Z
from gym.envs.registration import register register( id='Diabetic-v0', entry_point='dosing_rl_gym.envs:Diabetic0Env' ) register( id='Diabetic-v1', entry_point='dosing_rl_gym.envs:Diabetic1Env' )
16.461538
49
0.733645
79e36026c8411796fc4a9913d922d28f169892ba
89,274
py
Python
lib/sqlalchemy/orm/strategies.py
rgargente/sqlalchemy
2734439fff953a7bb8aecdedb5f851441b5122e9
[ "MIT" ]
null
null
null
lib/sqlalchemy/orm/strategies.py
rgargente/sqlalchemy
2734439fff953a7bb8aecdedb5f851441b5122e9
[ "MIT" ]
null
null
null
lib/sqlalchemy/orm/strategies.py
rgargente/sqlalchemy
2734439fff953a7bb8aecdedb5f851441b5122e9
[ "MIT" ]
null
null
null
# orm/strategies.py # Copyright (C) 2005-2020 the SQLAlchemy authors and contributors # <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php """sqlalchemy.orm.interfaces.LoaderStrategy implementations, and related Mapper...
34.736965
79
0.578153
17ce1ce266694cb465d80ed7bccf45dac81bc227
11,220
py
Python
hummingbot/market/bittrex/bittrex_order_book_tracker.py
fakecoinbase/Grandthraxslashhumming_extended
54e959520f515697b5a88d3fc3636e702ea381e5
[ "Apache-2.0" ]
2
2020-08-02T17:56:53.000Z
2021-02-12T18:47:04.000Z
hummingbot/market/bittrex/bittrex_order_book_tracker.py
Grandthrax/humming_extended
54e959520f515697b5a88d3fc3636e702ea381e5
[ "Apache-2.0" ]
1
2019-06-05T23:13:35.000Z
2019-06-05T23:13:35.000Z
hummingbot/market/bittrex/bittrex_order_book_tracker.py
Grandthrax/humming_extended
54e959520f515697b5a88d3fc3636e702ea381e5
[ "Apache-2.0" ]
2
2020-08-02T17:59:03.000Z
2021-09-05T22:19:28.000Z
#!/usr/bin/env python import asyncio import bisect import logging import time from collections import ( defaultdict, deque, ) from typing import ( Optional, Dict, List, Set, Deque, ) from hummingbot.core.data_type.order_book_message import ( OrderBookMessageType, OrderBookMessage, )...
48.571429
119
0.638948
9c6abf8233686ef9c771045703fdf4b5eaa98a4e
2,686
py
Python
cloudmesh/common/systeminfo.py
aporlowski/cloudmesh-common
ff991c07eb17b899742a1535665118a33d679f2d
[ "Apache-2.0" ]
null
null
null
cloudmesh/common/systeminfo.py
aporlowski/cloudmesh-common
ff991c07eb17b899742a1535665118a33d679f2d
[ "Apache-2.0" ]
null
null
null
cloudmesh/common/systeminfo.py
aporlowski/cloudmesh-common
ff991c07eb17b899742a1535665118a33d679f2d
[ "Apache-2.0" ]
null
null
null
import platform import sys import os from pathlib import Path from cloudmesh.common.util import readfile from collections import OrderedDict import pip import psutil import humanize def sys_user(): if "COLAB_GPU" in os.environ: return "collab" elif sys.platform == "win32": return os.environ["U...
27.690722
74
0.538347
ca25a67cc33477e6815dd3de8155b2d2d72696c6
4,504
py
Python
cgc/ThreeColors.py
Jfeatherstone/ColorGlass
f242541df614a8eea97c43d3480c779e92660ebb
[ "MIT" ]
null
null
null
cgc/ThreeColors.py
Jfeatherstone/ColorGlass
f242541df614a8eea97c43d3480c779e92660ebb
[ "MIT" ]
null
null
null
cgc/ThreeColors.py
Jfeatherstone/ColorGlass
f242541df614a8eea97c43d3480c779e92660ebb
[ "MIT" ]
null
null
null
from .Wavefunction import Wavefunction import numpy as np from scipy.fft import ifft2, fft2 from scipy.linalg import expm class Nucleus(Wavefunction): _wilsonLine = None _adjointWilsonLine = None # Some variables to keep track of what has been calculated/generated so far # allowing us to avoid r...
37.22314
195
0.574822
e43767ef2b648d0d5d57c00f38ccbd38390e38da
19,134
py
Python
tb_check.py
N1kYan/vssil
214363f1a924414415cfef940404d8057f6912e7
[ "MIT" ]
6,139
2017-06-13T02:43:20.000Z
2022-03-30T23:56:28.000Z
tb_check.py
N1kYan/vssil
214363f1a924414415cfef940404d8057f6912e7
[ "MIT" ]
3,239
2017-06-14T15:49:50.000Z
2022-03-31T23:43:15.000Z
tb_check.py
N1kYan/vssil
214363f1a924414415cfef940404d8057f6912e7
[ "MIT" ]
1,882
2017-06-15T01:33:54.000Z
2022-03-30T15:27:25.000Z
# Copyright 2019 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...
33.865487
82
0.610902
20e7f581435e325d89fb845110fc48bbbdf3cb72
2,465
py
Python
opentelemetry-api/setup.py
ThePumpingLemma/opentelemetry-python
9ed98eb9320b9064e43c3b43ee7c4990eec3657a
[ "Apache-2.0" ]
null
null
null
opentelemetry-api/setup.py
ThePumpingLemma/opentelemetry-python
9ed98eb9320b9064e43c3b43ee7c4990eec3657a
[ "Apache-2.0" ]
null
null
null
opentelemetry-api/setup.py
ThePumpingLemma/opentelemetry-python
9ed98eb9320b9064e43c3b43ee7c4990eec3657a
[ "Apache-2.0" ]
null
null
null
# Copyright 2019, OpenTelemetry 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 License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to i...
33.767123
74
0.664909
33d63c5c5b02e606550a6c37cb50f553f4f798a5
282
py
Python
solutions/Luck_check.py
AlexGameAndWebDev/CodeWars-Python
222b8244e9f248dbb4e5fabd390dd4cce446dc84
[ "MIT" ]
44
2015-05-24T13:46:22.000Z
2022-03-22T10:40:10.000Z
solutions/Luck_check.py
badruu/CodeWars-Python
222b8244e9f248dbb4e5fabd390dd4cce446dc84
[ "MIT" ]
3
2016-09-10T07:14:02.000Z
2021-09-14T12:16:25.000Z
solutions/Luck_check.py
badruu/CodeWars-Python
222b8244e9f248dbb4e5fabd390dd4cce446dc84
[ "MIT" ]
48
2016-04-03T04:48:33.000Z
2022-03-14T23:32:17.000Z
""" Luck check http://www.codewars.com/kata/5314b3c6bb244a48ab00076c/train/python """ def luck_check(string): i, j, total = 0, len(string) - 1, 0 while i != j and i < j: total += (int(string[i]) - int(string[j])) i += 1 j -= 1 return total == 0
21.692308
66
0.556738
aa75c2452fa34b449c1595bc69b1e225d220c8d1
541
py
Python
glashammer/utils/log.py
passy/glashammer-rdrei
9e56952d70b961d8945707469aad9cfe97c4e7b7
[ "MIT" ]
1
2016-07-04T15:23:59.000Z
2016-07-04T15:23:59.000Z
glashammer/utils/log.py
passy/glashammer-rdrei
9e56952d70b961d8945707469aad9cfe97c4e7b7
[ "MIT" ]
null
null
null
glashammer/utils/log.py
passy/glashammer-rdrei
9e56952d70b961d8945707469aad9cfe97c4e7b7
[ "MIT" ]
null
null
null
def add_log_handler(handler): root_logger = getLogger('') root_logger.addHandler(handler) def debug(msg): # Racy from glashammer.utils import emit_event emit_event('log', 'debug', msg) def info(msg): # Racy from glashammer.utils import emit_event emit_event('log', 'debug', msg) d...
16.90625
43
0.665434
0b14731419a7f2ec299cdbe928ffacc7ee1f1165
1,278
py
Python
dataset.py
NB-prog/multiclass-classificationDistilBert
ed64da14ac59e1c2992a8eb80e45befee6f02879
[ "MIT" ]
null
null
null
dataset.py
NB-prog/multiclass-classificationDistilBert
ed64da14ac59e1c2992a8eb80e45befee6f02879
[ "MIT" ]
null
null
null
dataset.py
NB-prog/multiclass-classificationDistilBert
ed64da14ac59e1c2992a8eb80e45befee6f02879
[ "MIT" ]
null
null
null
import config import torch from torch.utils.data import Dataset, DataLoader import transformers from transformers import DistilBertModel, DistilBertTokenizer class Triage(Dataset): def __init__(self, dataframe): self.len = len(dataframe) self.data = dataframe self.tokenizer = co...
31.170732
83
0.576682
ddf20b6a36293ec87eda1b7bbedccaf358e26505
1,242
py
Python
load_testing/ial2_sign_up.locustfile.py
18F/identity-loadtes
b437643f21bb47a1b2c7eff82e9bd6569e9f081b
[ "CC0-1.0" ]
null
null
null
load_testing/ial2_sign_up.locustfile.py
18F/identity-loadtes
b437643f21bb47a1b2c7eff82e9bd6569e9f081b
[ "CC0-1.0" ]
18
2020-03-25T21:44:21.000Z
2021-12-16T00:47:59.000Z
load_testing/ial2_sign_up.locustfile.py
18F/identity-loadtes
b437643f21bb47a1b2c7eff82e9bd6569e9f081b
[ "CC0-1.0" ]
2
2021-01-12T10:08:38.000Z
2021-08-24T17:35:40.000Z
from locust import HttpUser, TaskSet, task, between from common_flows import flow_ial2_proofing, flow_sign_up, flow_helper import logging class IAL2SignUpLoad(TaskSet): # Preload drivers license data license_front = flow_helper.load_fixture("mock-front.jpeg") license_back = flow_helper.load_fixture("mock-...
29.571429
74
0.652979
015b1a814579cf43b5516d3c75b393af0664560e
1,016
py
Python
esp32-pulsetimer/test-pt.py
tve/mpy-lib
9f102459c61a5be424291a277e421bd1fc16843a
[ "MIT" ]
6
2020-02-27T11:17:54.000Z
2020-12-04T10:14:26.000Z
esp32-pulsetimer/test-pt.py
tve/mpy-lib
9f102459c61a5be424291a277e421bd1fc16843a
[ "MIT" ]
4
2020-07-29T14:07:04.000Z
2021-05-19T05:10:33.000Z
esp32-pulsetimer/test-pt.py
tve/mpy-lib
9f102459c61a5be424291a277e421bd1fc16843a
[ "MIT" ]
3
2020-05-16T08:15:16.000Z
2021-09-30T10:39:37.000Z
import time, machine out_pin = 21 in_pin = 22 print("Testing pulsetimer, outputting on pin %d and reading pulsetimer on pin %d", out_pin, in_pin) print("Loading pulsetimer module") time.sleep_ms(100) import pulsetimer print("Instantiating output pin") out = machine.Pin(out_pin, machine.Pin.OUT, value=0) print("Sett...
17.824561
99
0.647638
f0aaeb810c20debffc4af960dcd2634ce2c58be8
4,476
py
Python
lite/examples/speech_commands/ml/train.py
samirma/examples
eab959e9033aff9b08ac8e8f90715f71ce7861ec
[ "Apache-2.0" ]
null
null
null
lite/examples/speech_commands/ml/train.py
samirma/examples
eab959e9033aff9b08ac8e8f90715f71ce7861ec
[ "Apache-2.0" ]
null
null
null
lite/examples/speech_commands/ml/train.py
samirma/examples
eab959e9033aff9b08ac8e8f90715f71ce7861ec
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 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...
31.521127
80
0.691466
51f5f52d487bac13720b21b2e472aabcc4ea0532
261
py
Python
pgmpy/utils/decorators.py
predictive-analytics-lab/pgmpy
6c2a31641adc72793acd130d007190fdb1632271
[ "MIT" ]
null
null
null
pgmpy/utils/decorators.py
predictive-analytics-lab/pgmpy
6c2a31641adc72793acd130d007190fdb1632271
[ "MIT" ]
null
null
null
pgmpy/utils/decorators.py
predictive-analytics-lab/pgmpy
6c2a31641adc72793acd130d007190fdb1632271
[ "MIT" ]
null
null
null
def convert_args_tuple(func): def _convert_param_to_tuples(obj, variable, parents=tuple(), complete_samples_only=None): parents = tuple(parents) return func(obj, variable, parents, complete_samples_only) return _convert_param_to_tuples
37.285714
93
0.758621
1264a8bb915513b19aa6ec501f841ec3f3944db5
7,481
py
Python
pybind/nos/v7_1_0/rbridge_id/route_map/content/set_/ip/global_/__init__.py
shivharis/pybind
4e1c6d54b9fd722ccec25546ba2413d79ce337e6
[ "Apache-2.0" ]
null
null
null
pybind/nos/v7_1_0/rbridge_id/route_map/content/set_/ip/global_/__init__.py
shivharis/pybind
4e1c6d54b9fd722ccec25546ba2413d79ce337e6
[ "Apache-2.0" ]
null
null
null
pybind/nos/v7_1_0/rbridge_id/route_map/content/set_/ip/global_/__init__.py
shivharis/pybind
4e1c6d54b9fd722ccec25546ba2413d79ce337e6
[ "Apache-2.0" ]
1
2021-11-05T22:15:42.000Z
2021-11-05T22:15:42.000Z
from operator import attrgetter import pyangbind.lib.xpathhelper as xpathhelper from pyangbind.lib.yangtypes import RestrictedPrecisionDecimalType, RestrictedClassType, TypedListType from pyangbind.lib.yangtypes import YANGBool, YANGListType, YANGDynClass, ReferenceType from pyangbind.lib.base import PybindBase from d...
59.373016
825
0.725972
cd63b278f1d4c6a14a58216501e618ab745f04bd
1,619
py
Python
atst/forms/forms.py
philip-dds/atst
a227044ccf464dd0e3144dd74cecfafe8d6841b9
[ "MIT" ]
1
2020-01-16T16:15:52.000Z
2020-01-16T16:15:52.000Z
atst/forms/forms.py
philip-dds/atst
a227044ccf464dd0e3144dd74cecfafe8d6841b9
[ "MIT" ]
null
null
null
atst/forms/forms.py
philip-dds/atst
a227044ccf464dd0e3144dd74cecfafe8d6841b9
[ "MIT" ]
null
null
null
from flask_wtf import FlaskForm from flask import current_app, request as http_request import re from atst.utils.flash import formatted_flash as flash EMPTY_LIST_FIELD = ["", None] def remove_empty_string(value): # only return strings that contain non whitespace characters if value and re.search(r"\S", valu...
34.446809
90
0.639284
20b514c63c39a8e277d8f178ee401ad7385f98c1
17,111
py
Python
src/genie/libs/parser/iosxe/tests/ShowInterfaces/cli/equal/golden_output_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
204
2018-06-27T00:55:27.000Z
2022-03-06T21:12:18.000Z
src/genie/libs/parser/iosxe/tests/ShowInterfaces/cli/equal/golden_output_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
468
2018-06-19T00:33:18.000Z
2022-03-31T23:23:35.000Z
src/genie/libs/parser/iosxe/tests/ShowInterfaces/cli/equal/golden_output_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
309
2019-01-16T20:21:07.000Z
2022-03-30T12:56:41.000Z
expected_output = { "Port-channel12": { "flow_control": {"send": False, "receive": False}, "err_disabled": False, "suspended": False, "type": "EtherChannel", "counters": { "out_buffer_failure": 0, "out_underruns": 0, "in_giants": 0, ...
31.804833
85
0.453919
5445646be3f26f6a69b259975e86cdb28353313a
1,254
py
Python
tests/unit/notifier/test_slack_notifer.py
steveYeah/amqpeek
0bcbedb2c96a4d77306e6143fac450ad620aad0d
[ "MIT" ]
3
2016-10-30T23:30:25.000Z
2019-03-13T13:44:05.000Z
tests/unit/notifier/test_slack_notifer.py
steveYeah/amqpeek
0bcbedb2c96a4d77306e6143fac450ad620aad0d
[ "MIT" ]
7
2016-10-13T11:53:05.000Z
2020-10-02T15:34:54.000Z
tests/unit/notifier/test_slack_notifer.py
steveYeah/amqpeek
0bcbedb2c96a4d77306e6143fac450ad620aad0d
[ "MIT" ]
2
2017-05-03T10:18:20.000Z
2017-05-18T05:29:01.000Z
"""Tests the slack notifier module.""" from unittest.mock import patch import pytest from amqpeek.notifier import SlackNotifier class TestSlackNotifier(object): """Tests for the SlackNotifier class.""" @pytest.fixture def slack_notifier_args(self) -> dict: """Some default args to use for these...
31.35
83
0.649123
8e7b321484c32cb61222cb2fd645aefc315d8112
1,589
py
Python
tests/wycheproof/test_x448.py
wdscxsj/cryptography
94590a9aecc9e5ef6fc8eda52bae43643a4c44bd
[ "PSF-2.0", "Apache-2.0", "BSD-3-Clause" ]
4,492
2015-01-02T23:02:52.000Z
2022-03-31T12:59:57.000Z
tests/wycheproof/test_x448.py
wdscxsj/cryptography
94590a9aecc9e5ef6fc8eda52bae43643a4c44bd
[ "PSF-2.0", "Apache-2.0", "BSD-3-Clause" ]
3,692
2015-01-01T03:16:56.000Z
2022-03-31T19:20:25.000Z
tests/wycheproof/test_x448.py
wdscxsj/cryptography
94590a9aecc9e5ef6fc8eda52bae43643a4c44bd
[ "PSF-2.0", "Apache-2.0", "BSD-3-Clause" ]
1,155
2015-01-09T00:48:05.000Z
2022-03-31T23:46:43.000Z
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. import binascii import pytest from cryptography.hazmat.primitives.asymmetric.x448 import ( X448PrivateKey, X448PublicKey, ) fro...
30.557692
79
0.713656
e029b55e773f1ab54a0fe9ede69f7a4a3d1ae9e2
375
py
Python
base/tasks.py
0xelectron/mhtportal-web
bd05069d6245e86d4ae887cacf33b04ef9476816
[ "MIT" ]
null
null
null
base/tasks.py
0xelectron/mhtportal-web
bd05069d6245e86d4ae887cacf33b04ef9476816
[ "MIT" ]
5
2019-10-20T06:17:36.000Z
2021-06-10T18:13:29.000Z
base/tasks.py
0xelectron/mhtportal-web
bd05069d6245e86d4ae887cacf33b04ef9476816
[ "MIT" ]
2
2019-05-11T17:25:25.000Z
2019-10-12T17:59:47.000Z
import logging import requests from celery import shared_task logger = logging.getLogger(__name__) @shared_task def send_sms_async(url, params=None): try: if params: requests.post(url, data=params) else: requests.get(url) except requests.RequestException as e: ...
19.736842
60
0.68
ffd3816d8cc9a364e7823e48f7eb3be36c2eef11
8,807
py
Python
tests/test_model.py
toni-moreno/loudml
0252b6792393fc46f2dc9c1da25dd89fc27a5fa4
[ "Apache-2.0" ]
245
2018-01-30T08:11:53.000Z
2022-03-26T07:17:42.000Z
tests/test_model.py
robcowart/loudml
0008baef02259a8ae81dd210d3f91a51ffc9ed9f
[ "Apache-2.0" ]
620
2018-01-28T22:58:24.000Z
2022-03-13T13:40:42.000Z
tests/test_model.py
robcowart/loudml
0008baef02259a8ae81dd210d3f91a51ffc9ed9f
[ "Apache-2.0" ]
97
2018-03-06T14:44:26.000Z
2022-03-24T01:57:31.000Z
import unittest from loudml import ( errors, ) from loudml.model import ( Feature, flatten_features, Model, ) class TestModel(unittest.TestCase): def invalid_feature(self, **kwargs): with self.assertRaises(errors.Invalid): Feature(**kwargs) def test_validate_feature(self)...
26.368263
69
0.269899
b4dc32f904e7ddc460920e869406ae35587ad393
3,553
py
Python
bigbench/api/model.py
colinzhaoust/BIG-bench
34cf4e737879f2fed7642c8df7648fef47cc463b
[ "Apache-2.0" ]
null
null
null
bigbench/api/model.py
colinzhaoust/BIG-bench
34cf4e737879f2fed7642c8df7648fef47cc463b
[ "Apache-2.0" ]
null
null
null
bigbench/api/model.py
colinzhaoust/BIG-bench
34cf4e737879f2fed7642c8df7648fef47cc463b
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, so...
42.807229
89
0.649029
9bc6914528c2ea8cbf07bea7aa7ac6ea43ac798d
6,233
py
Python
test/test_simple_macd.py
alexanu/TradingBot
9fabb6a0be51fbc1dba5a30605a7c29127f29fa2
[ "MIT" ]
null
null
null
test/test_simple_macd.py
alexanu/TradingBot
9fabb6a0be51fbc1dba5a30605a7c29127f29fa2
[ "MIT" ]
null
null
null
test/test_simple_macd.py
alexanu/TradingBot
9fabb6a0be51fbc1dba5a30605a7c29127f29fa2
[ "MIT" ]
null
null
null
import os import sys import inspect import pytest import json from datetime import datetime as dt import pandas as pd currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))) parentdir = os.path.dirname(currentdir) sys.path.insert(0, "{}/src".format(parentdir)) from Strategies.SimpleMACD...
29.966346
86
0.703995
eac14dc3b5c17390abd3dfa617466ff9c11b15c1
790
py
Python
tgpush.py
Verrickt/zju-dailyhealth-autocheck
43854717852727c640c3360e289aa54a36be7694
[ "MIT" ]
5
2021-12-22T04:27:03.000Z
2021-12-23T03:42:50.000Z
tgpush.py
Verrickt/zju-dailyhealth-autocheck
43854717852727c640c3360e289aa54a36be7694
[ "MIT" ]
null
null
null
tgpush.py
Verrickt/zju-dailyhealth-autocheck
43854717852727c640c3360e289aa54a36be7694
[ "MIT" ]
null
null
null
from requests import post import os """ TG 消息推送模块 """ def post_tg(config,message): TG_TOKEN = config['bot_token'] CHAT_ID = config['chat_id'] PROXY = config['proxy'] telegram_message = f"{message}" params = ( ('chat_id', CHAT_ID), ('text', telegram_message), ('parse_mode...
23.235294
77
0.61519
ab88d9cbaf815ac2d205a77dd23961825d2ec06a
1,916
py
Python
3.Understanding Convolutions/3_image.py
OwenGranot/Deep-Learning
436cc00783c7aeef527f1f06b6550e6d0ab944e0
[ "MIT" ]
null
null
null
3.Understanding Convolutions/3_image.py
OwenGranot/Deep-Learning
436cc00783c7aeef527f1f06b6550e6d0ab944e0
[ "MIT" ]
null
null
null
3.Understanding Convolutions/3_image.py
OwenGranot/Deep-Learning
436cc00783c7aeef527f1f06b6550e6d0ab944e0
[ "MIT" ]
null
null
null
# Disable debbuging logs (to get rid of cuda warnings) import os os.environ['TF_CPP_MIN_LOG_LEVEL'] = '3' import numpy as np from scipy import signal from scipy import misc import matplotlib.pyplot as plt from PIL import Image image = Image.open('bird.jpg') # convert("L") translates color images into b/w image_gr = ...
29.476923
126
0.709812