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
a5e4666915212b8f6b0b15dc2449a686ce496e42
5,633
py
Python
stackdriver/restapi.py
MarkMarine/stackdriver-client-python
7e5e5806d02fcf4b8633d19adbce6d64f3082083
[ "Apache-2.0" ]
null
null
null
stackdriver/restapi.py
MarkMarine/stackdriver-client-python
7e5e5806d02fcf4b8633d19adbce6d64f3082083
[ "Apache-2.0" ]
null
null
null
stackdriver/restapi.py
MarkMarine/stackdriver-client-python
7e5e5806d02fcf4b8633d19adbce6d64f3082083
[ "Apache-2.0" ]
null
null
null
""" restapi - base for calling rest resources Stackdriver Public API, Copyright Stackdriver 2014 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 license...
35.427673
164
0.680987
4,275
0.758921
0
0
1,516
0.269128
0
0
2,098
0.372448
a5e7acf2b322f72151a720e8d6b6a7577bf377de
13,896
py
Python
ventana_perceptron.py
musicbiker/ANNT
301f1090925c8937f0fd3b4955ec68ff772022ce
[ "MIT" ]
null
null
null
ventana_perceptron.py
musicbiker/ANNT
301f1090925c8937f0fd3b4955ec68ff772022ce
[ "MIT" ]
null
null
null
ventana_perceptron.py
musicbiker/ANNT
301f1090925c8937f0fd3b4955ec68ff772022ce
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Wed Dec 11 15:05:41 2019 @author: jrodriguez119 """ import tkinter as tk from tkinter import ttk import crearcapas import perceptron_multicapa from threading import Thread import sys from matplotlib.backends.backend_tkagg import FigureCanvasTkAgg, NavigationToolbar2...
40.750733
151
0.573258
441
0.031633
0
0
0
0
0
0
3,049
0.218707
a5e93ad8745db2b82f7503c050a79a9fd3c06143
419
py
Python
tests/search/test_search_onedrive.py
theodoriss/Office365-REST-Python-Client
3bd7a62dadcd3f0a0aceeaff7584fff3fd44886e
[ "MIT" ]
544
2016-08-04T17:10:16.000Z
2022-03-31T07:17:20.000Z
tests/search/test_search_onedrive.py
theodoriss/Office365-REST-Python-Client
3bd7a62dadcd3f0a0aceeaff7584fff3fd44886e
[ "MIT" ]
438
2016-10-11T12:24:22.000Z
2022-03-31T19:30:35.000Z
tests/search/test_search_onedrive.py
theodoriss/Office365-REST-Python-Client
3bd7a62dadcd3f0a0aceeaff7584fff3fd44886e
[ "MIT" ]
202
2016-08-22T19:29:40.000Z
2022-03-30T20:26:15.000Z
from tests.graph_case import GraphTestCase class TestSearchOneDrive(GraphTestCase): @classmethod def setUpClass(cls): super(TestSearchOneDrive, cls).setUpClass() @classmethod def tearDownClass(cls): pass def test1_search_files(self): result = self.client.search.query("Gu...
23.277778
99
0.706444
372
0.887828
0
0
142
0.338902
0
0
23
0.054893
a5ea06e0a07718613f62378639588110228f7035
728
py
Python
secu/tests/user_post_test.py
wancy86/tornado-seed
bea842f4ba6b23dda53ec9ae9f1349e1d2b54fd3
[ "MIT" ]
null
null
null
secu/tests/user_post_test.py
wancy86/tornado-seed
bea842f4ba6b23dda53ec9ae9f1349e1d2b54fd3
[ "MIT" ]
null
null
null
secu/tests/user_post_test.py
wancy86/tornado-seed
bea842f4ba6b23dda53ec9ae9f1349e1d2b54fd3
[ "MIT" ]
null
null
null
import requests from ..base.test import BaseTestCase, AuthorizedTestCase import uuid import common class T(AuthorizedTestCase): @property def path(self): return '/service/secu/user' def setUp(self): super().setUp() self.data = { 'username': 'myao', ...
26.962963
59
0.542582
641
0.859249
0
0
67
0.089812
0
0
159
0.213137
a5ea9efb676efad8c603777a80d368a57ffbe7ba
2,204
py
Python
arbeitsplan/management/commands/meldungConsistent.py
hkarl/svpb
29aab0065ff69c7c4d52812508167514d635cab9
[ "Apache-2.0" ]
3
2015-02-20T14:53:17.000Z
2020-12-01T19:29:14.000Z
arbeitsplan/management/commands/meldungConsistent.py
hkarl/svpb
29aab0065ff69c7c4d52812508167514d635cab9
[ "Apache-2.0" ]
67
2015-01-06T19:48:59.000Z
2022-03-20T16:56:22.000Z
arbeitsplan/management/commands/meldungConsistent.py
hkarl/svpb
29aab0065ff69c7c4d52812508167514d635cab9
[ "Apache-2.0" ]
2
2015-12-07T09:21:10.000Z
2015-12-30T18:36:53.000Z
""" Define a command that should be run from a crontab. This one should check consistency of Meldungen: at most one Meldung per Aufgabe, per User. """ from django.core.management.base import BaseCommand, CommandError from django.core.management import call_command from django.utils import translation from django.conf...
29.783784
72
0.587114
1,720
0.780399
0
0
0
0
0
0
828
0.375681
a5ece29e8598f0696a2017f159b9027891f278ea
1,215
py
Python
app/migrations/0013_auto_20200907_1056.py
mapoetto/group2_CTFLab
5b492ce46875ea37a57701686897bd9613e2dd13
[ "MIT" ]
1
2021-10-15T14:37:33.000Z
2021-10-15T14:37:33.000Z
app/migrations/0013_auto_20200907_1056.py
mapoetto/group2_CTFLab
5b492ce46875ea37a57701686897bd9613e2dd13
[ "MIT" ]
null
null
null
app/migrations/0013_auto_20200907_1056.py
mapoetto/group2_CTFLab
5b492ce46875ea37a57701686897bd9613e2dd13
[ "MIT" ]
null
null
null
# Generated by Django 2.1.15 on 2020-09-07 10:56 import app.models from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('app', '0012_user_id_ctfd'), ] operations = [ migrations.CreateModel( name='CTFd_configs', fields=...
31.153846
114
0.568724
1,103
0.907819
0
0
0
0
0
0
173
0.142387
a5ef7047358651b5620e1896751f01c69ce61941
6,404
py
Python
products_and_services_client/models/monthly_price.py
pitzer42/opbk-br-quickstart
b3f86b2e5f82a6090aaefb563614e174a452383c
[ "MIT" ]
2
2021-02-07T23:58:36.000Z
2021-02-08T01:03:25.000Z
products_and_services_client/models/monthly_price.py
pitzer42/opbk-br-quickstart
b3f86b2e5f82a6090aaefb563614e174a452383c
[ "MIT" ]
null
null
null
products_and_services_client/models/monthly_price.py
pitzer42/opbk-br-quickstart
b3f86b2e5f82a6090aaefb563614e174a452383c
[ "MIT" ]
null
null
null
# coding: utf-8 """ API's OpenData do Open Banking Brasil As API's descritas neste documento são referentes as API's da fase OpenData do Open Banking Brasil. # noqa: E501 OpenAPI spec version: 1.0.0-rc5.2 Contact: apiteam@swagger.io Generated by: https://github.com/swagger-api/swagger-codegen.gi...
32.841026
392
0.600562
6,037
0.940782
0
0
3,276
0.510519
0
0
3,542
0.551971
a5f29eaf88394cd5b49f0dfad22427d8e4654b7c
481
py
Python
sqlalchemy_i18n/expressions.py
EdwardBetts/sqlalchemy-i18n
9cf515be75be6e319416579b32528e1a096c03cf
[ "BSD-3-Clause" ]
31
2015-02-26T11:08:43.000Z
2022-03-18T11:53:30.000Z
sqlalchemy_i18n/expressions.py
EdwardBetts/sqlalchemy-i18n
9cf515be75be6e319416579b32528e1a096c03cf
[ "BSD-3-Clause" ]
13
2015-01-05T09:40:59.000Z
2022-01-18T23:57:28.000Z
sqlalchemy_i18n/expressions.py
EdwardBetts/sqlalchemy-i18n
9cf515be75be6e319416579b32528e1a096c03cf
[ "BSD-3-Clause" ]
13
2015-01-08T08:24:15.000Z
2022-02-05T01:59:41.000Z
import sqlalchemy as sa from sqlalchemy.ext.compiler import compiles from sqlalchemy.sql.functions import GenericFunction class current_locale(GenericFunction): type = sa.types.String() @compiles(current_locale) def compile_current_locale(element, compiler, **kw): # Lazy import get_locale so that it can be ...
26.722222
57
0.756757
67
0.139293
0
0
286
0.594595
0
0
73
0.151767
a5f2ce8d23f3ea07c4d73928966352c760c23c7e
47
py
Python
scripts/portal/OutElfKingRoom.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
54
2019-04-16T23:24:48.000Z
2021-12-18T11:41:50.000Z
scripts/portal/OutElfKingRoom.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
3
2019-05-19T15:19:41.000Z
2020-04-27T16:29:16.000Z
scripts/portal/OutElfKingRoom.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
49
2020-11-25T23:29:16.000Z
2022-03-26T16:20:24.000Z
# 101050010 sm.warp(101050000, 7) sm.dispose()
11.75
21
0.723404
0
0
0
0
0
0
0
0
11
0.234043
a5f31b512ae3b988c292e1211f6d15cfb61624fc
839
py
Python
suppy/simulator/atomics/divergence_atomic.py
bmaris98/suppy
8450c6d25ffa492cdedfbbb4c111d22e7f2788a7
[ "BSD-3-Clause" ]
null
null
null
suppy/simulator/atomics/divergence_atomic.py
bmaris98/suppy
8450c6d25ffa492cdedfbbb4c111d22e7f2788a7
[ "BSD-3-Clause" ]
null
null
null
suppy/simulator/atomics/divergence_atomic.py
bmaris98/suppy
8450c6d25ffa492cdedfbbb4c111d22e7f2788a7
[ "BSD-3-Clause" ]
null
null
null
from suppy.utils.stats_constants import DIVERGENCE, TYPE from typing import Any, Dict from suppy.simulator.atomics.atomic import Atomic class DivergenceAtomic(Atomic): def __init__(self, uid: str, seh, name: str): Atomic.__init__(self, uid, seh, name, 0, 0) def get_stats(self) -> Dict[str, Any]: ...
31.074074
56
0.647199
701
0.835518
0
0
0
0
0
0
0
0
a5f71728f2d90dfa8913ba58e0714da23be50b98
2,673
py
Python
train/compute/python/pytorch_benchmark.py
sazanovd/param
595b81ceb64d8d106d05ab67d2c73e8465d06921
[ "MIT" ]
null
null
null
train/compute/python/pytorch_benchmark.py
sazanovd/param
595b81ceb64d8d106d05ab67d2c73e8465d06921
[ "MIT" ]
null
null
null
train/compute/python/pytorch_benchmark.py
sazanovd/param
595b81ceb64d8d106d05ab67d2c73e8465d06921
[ "MIT" ]
null
null
null
import logging from .lib.init_helper import init_logging, load_modules # Initialize logging format before loading all other modules logger = init_logging(logging.INFO) import argparse from .lib import pytorch as lib_pytorch from .lib.config import BenchmarkConfig from .lib.pytorch.benchmark import ( make_defaul...
29.7
99
0.674523
0
0
0
0
0
0
0
0
811
0.303404
a5f7a4ecfa05bf78a585981771c76de8e093cf7a
5,180
py
Python
database/BuildDatabase.py
chanzuckerberg/scoreboard
7ebf783819d0f5b4dd54092201f709b8644c85a4
[ "MIT" ]
8
2017-11-28T22:36:37.000Z
2020-10-20T06:46:19.000Z
database/BuildDatabase.py
chanzuckerberg/scoreboard
7ebf783819d0f5b4dd54092201f709b8644c85a4
[ "MIT" ]
25
2017-12-27T19:05:41.000Z
2022-03-15T18:35:22.000Z
database/BuildDatabase.py
chanzuckerberg/scoreboard
7ebf783819d0f5b4dd54092201f709b8644c85a4
[ "MIT" ]
1
2018-04-23T11:16:41.000Z
2018-04-23T11:16:41.000Z
from sqlalchemy import create_engine from sqlalchemy import Column, Integer, Boolean, String, DateTime, ForeignKey from sqlalchemy.ext.declarative import declarative_base from sqlalchemy.dialects.postgresql import JSONB from sqlalchemy.orm import sessionmaker from sqlalchemy.sql import func import datetime import os im...
37
121
0.72471
3,287
0.634556
0
0
0
0
0
0
697
0.134556
a5f7a9890ad3c832bc0b2c81569f369cddac6df1
6,767
py
Python
docs/tutorials_source/generate_images_tutorial.py
XavierXinweiWang/UnrealCV_Ubuntu
4fdbb32f2096a4c95c0912d018ff4adb4801fb8b
[ "MIT" ]
null
null
null
docs/tutorials_source/generate_images_tutorial.py
XavierXinweiWang/UnrealCV_Ubuntu
4fdbb32f2096a4c95c0912d018ff4adb4801fb8b
[ "MIT" ]
null
null
null
docs/tutorials_source/generate_images_tutorial.py
XavierXinweiWang/UnrealCV_Ubuntu
4fdbb32f2096a4c95c0912d018ff4adb4801fb8b
[ "MIT" ]
null
null
null
# Need at least 20 # characters """ =============== Generate Images =============== This ipython notebook demonstrates how to generate an image dataset with rich ground truth from a virtual environment. """ #################### import time; print(time.strftime("The last update of this file: %Y-%m-%d %H:%M:%S", time.gm...
33.171569
189
0.632186
383
0.056598
0
0
0
0
0
0
3,574
0.528151
a5f94be0d65ac72db51e3348feb82e21a6da2f05
458
py
Python
blogs/migrations/0003_auto_20161006_1654.py
fenglb/mysite
a5b68ebdb23f4d5c55c5490ffebaa97780a5d6ab
[ "CC0-1.0" ]
null
null
null
blogs/migrations/0003_auto_20161006_1654.py
fenglb/mysite
a5b68ebdb23f4d5c55c5490ffebaa97780a5d6ab
[ "CC0-1.0" ]
null
null
null
blogs/migrations/0003_auto_20161006_1654.py
fenglb/mysite
a5b68ebdb23f4d5c55c5490ffebaa97780a5d6ab
[ "CC0-1.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.10 on 2016-10-06 08:54 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('blogs', '0002_auto_20161006_1652'), ] operations = [ migrations.AlterField( ...
21.809524
62
0.617904
302
0.659389
0
0
0
0
0
0
116
0.253275
a5fa4568c42ee2ffd61fc83bd38a5e610ae98af1
1,660
py
Python
examples/ieffileupdate.py
duncan-r/SHIP
2c4c22c77f9c18ea545d3bce70a36aebbd18256a
[ "MIT" ]
6
2016-04-10T17:32:44.000Z
2022-03-13T18:41:21.000Z
examples/ieffileupdate.py
duncan-r/SHIP
2c4c22c77f9c18ea545d3bce70a36aebbd18256a
[ "MIT" ]
19
2017-06-23T08:21:53.000Z
2017-07-26T08:23:03.000Z
examples/ieffileupdate.py
duncan-r/SHIP
2c4c22c77f9c18ea545d3bce70a36aebbd18256a
[ "MIT" ]
6
2016-10-26T16:04:38.000Z
2019-04-25T23:55:06.000Z
""" Summary: Example use of the fmp package to update file paths in an .ief file and save the ief file under a new name. Author: Duncan Runnacles Created: 01 Apr 2016 Copyright: Duncan Runnacles 2016 TODO: Updates: """ import os from ship....
26.349206
75
0.654217
0
0
0
0
0
0
0
0
870
0.524096
a5fbd11dbc9a0e80007cdb92a40b5c8dd7191ce7
8,387
py
Python
packages/w3af/w3af/core/data/url/HTTPRequest.py
ZooAtmosphereGroup/HelloPackages
0ccffd33bf927b13d28c8f715ed35004c33465d9
[ "Apache-2.0" ]
null
null
null
packages/w3af/w3af/core/data/url/HTTPRequest.py
ZooAtmosphereGroup/HelloPackages
0ccffd33bf927b13d28c8f715ed35004c33465d9
[ "Apache-2.0" ]
null
null
null
packages/w3af/w3af/core/data/url/HTTPRequest.py
ZooAtmosphereGroup/HelloPackages
0ccffd33bf927b13d28c8f715ed35004c33465d9
[ "Apache-2.0" ]
null
null
null
""" HTTPRequest.py Copyright 2010 Andres Riancho This file is part of w3af, http://w3af.org/ . w3af is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation version 2 of the License. w3af is distributed in the hope that...
34.514403
99
0.623465
7,368
0.878502
0
0
2,113
0.251938
0
0
2,253
0.26863
a5ff1935416c4a799dc3631e3b180db7559793bf
817
py
Python
moldesign/_notebooks/nbscripts/gen_toc.py
Autodesk/molecular-design-toolkit
5f45a47fea21d3603899a6366cb163024f0e2ec4
[ "Apache-2.0" ]
147
2016-07-15T18:53:55.000Z
2022-01-30T04:36:39.000Z
moldesign/_notebooks/nbscripts/gen_toc.py
cherishyli/molecular-design-toolkit
5f45a47fea21d3603899a6366cb163024f0e2ec4
[ "Apache-2.0" ]
151
2016-07-15T21:35:11.000Z
2019-10-10T08:57:29.000Z
moldesign/_notebooks/nbscripts/gen_toc.py
cherishyli/molecular-design-toolkit
5f45a47fea21d3603899a6366cb163024f0e2ec4
[ "Apache-2.0" ]
33
2016-08-02T00:04:51.000Z
2021-09-02T10:05:04.000Z
#!/usr/bin/env python from __future__ import print_function import sys, os from nbformat import v4 def parse_line(line): if not line.startswith('#'): return None ilevel = 0 for char in line: if char == '#': ilevel += 1 else: break name = line[ilevel:].strip() return ileve...
19.452381
85
0.532436
0
0
0
0
0
0
0
0
117
0.143207
570013af797984af8b152ded17b276b76de011a7
1,102
py
Python
server/gaiaApi/gaia/serializer.py
JawaBaliIBM/Gaia
12572330c637cec559f8f122ecc2bd3af3dcf64e
[ "Apache-2.0" ]
6
2021-07-31T10:52:36.000Z
2022-03-19T17:10:55.000Z
server/gaiaApi/gaia/serializer.py
JawaBaliIBM/Gaia
12572330c637cec559f8f122ecc2bd3af3dcf64e
[ "Apache-2.0" ]
3
2021-07-24T08:17:53.000Z
2021-08-10T14:41:46.000Z
server/gaiaApi/gaia/serializer.py
JawaBaliIBM/Gaia
12572330c637cec559f8f122ecc2bd3af3dcf64e
[ "Apache-2.0" ]
1
2021-07-31T10:15:45.000Z
2021-07-31T10:15:45.000Z
from rest_framework import serializers class ArticleSerializer(serializers.Serializer): date = serializers.CharField(allow_blank=False) sentiment = serializers.CharField(allow_blank=False) title = serializers.CharField(allow_blank=False) description = serializers.CharField(allow_blank=False) articl...
42.384615
62
0.784029
1,056
0.958258
0
0
0
0
0
0
0
0
5701301232a4492ca4d517aea40acc01301fe2f8
329
py
Python
aoc2020/d01_report_repair/methods.py
sflis/aoc2020
ef6ee81c18b6ec8332b150638b3d78772fe8327a
[ "Unlicense" ]
null
null
null
aoc2020/d01_report_repair/methods.py
sflis/aoc2020
ef6ee81c18b6ec8332b150638b3d78772fe8327a
[ "Unlicense" ]
null
null
null
aoc2020/d01_report_repair/methods.py
sflis/aoc2020
ef6ee81c18b6ec8332b150638b3d78772fe8327a
[ "Unlicense" ]
null
null
null
import numpy as np def sum_pair_equals(values, val_eq): values = np.array(values) return np.where(values + values[:, None] == val_eq)[0] def sum_triad_equals(values, val_eq): values = np.array(values) sum_ = values + values[:, None] + values[:, None, None] return np.array(np.where(sum_ == val_eq...
25.307692
59
0.653495
0
0
0
0
0
0
0
0
0
0
570168b655cd4c5fe01f67c0408794d1cfd928aa
2,306
py
Python
tests/test_persona.py
holnburger/persine
cb26d1e275f7ed7e1048bc1e6b66b71386c3e602
[ "MIT" ]
84
2020-12-20T20:39:19.000Z
2022-02-02T01:01:12.000Z
tests/test_persona.py
holnburger/persine
cb26d1e275f7ed7e1048bc1e6b66b71386c3e602
[ "MIT" ]
1
2020-12-25T01:07:09.000Z
2020-12-25T04:05:19.000Z
tests/test_persona.py
holnburger/persine
cb26d1e275f7ed7e1048bc1e6b66b71386c3e602
[ "MIT" ]
9
2020-12-23T03:10:35.000Z
2021-09-08T14:44:18.000Z
import pytest from persine import Persona from selenium import webdriver from selenium.webdriver.chrome.options import Options from unittest.mock import Mock @pytest.fixture def engine(): def launch_chrome(user_data_dir): options = Options() options.add_argument("--headless") return webdr...
26.204545
77
0.598439
0
0
0
0
388
0.168257
0
0
477
0.206852
57018df18d3cbc94d73679782950464b4f793c17
26,556
py
Python
inference.py
QuPengfei/learnable-triangulation-pytorch
861d9ccf8b06bd2f130697cd40b7ac57d7f7d9f2
[ "MIT" ]
null
null
null
inference.py
QuPengfei/learnable-triangulation-pytorch
861d9ccf8b06bd2f130697cd40b7ac57d7f7d9f2
[ "MIT" ]
null
null
null
inference.py
QuPengfei/learnable-triangulation-pytorch
861d9ccf8b06bd2f130697cd40b7ac57d7f7d9f2
[ "MIT" ]
null
null
null
import torch import numpy as np import cv2 import os import h5py from collections import defaultdict from mvn.models.triangulation import RANSACTriangulationNet, AlgebraicTriangulationNet, VolumetricTriangulationNet from mvn.models.loss import KeypointsMSELoss, KeypointsMSESmoothLoss, KeypointsMAELoss, KeypointsL2Loss...
42.018987
185
0.640496
4,653
0.175215
0
0
0
0
0
0
5,126
0.193026
57028ca06deb47d996805621dce315dc63a9dc8f
4,846
py
Python
survol/sources_types/Linux/tcp_sockets.py
AugustinMascarelli/survol
7a822900e82d1e6f016dba014af5741558b78f15
[ "BSD-3-Clause" ]
null
null
null
survol/sources_types/Linux/tcp_sockets.py
AugustinMascarelli/survol
7a822900e82d1e6f016dba014af5741558b78f15
[ "BSD-3-Clause" ]
null
null
null
survol/sources_types/Linux/tcp_sockets.py
AugustinMascarelli/survol
7a822900e82d1e6f016dba014af5741558b78f15
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python """ TCP Linux sockets with netstat """ import re import sys import socket import lib_util import lib_common from lib_properties import pc from sources_types import addr as survol_addr # Many advantages compared to psutil: # The Python module psutil is not needed # psutil gives only sockets ...
38.460317
98
0.577383
0
0
0
0
0
0
0
0
3,079
0.635369
57033e68edf1bc714421c03684cc8349a3a89d3f
5,832
py
Python
models.py
JiaMingLin/residual_adapters
a3d32b4fb6c3c252f5adc1ad178b026a111c1a08
[ "Apache-2.0" ]
137
2018-03-22T15:45:30.000Z
2022-03-17T09:39:07.000Z
models.py
JiaMingLin/residual_adapters
a3d32b4fb6c3c252f5adc1ad178b026a111c1a08
[ "Apache-2.0" ]
5
2018-09-25T19:44:34.000Z
2020-12-19T11:26:41.000Z
models.py
JiaMingLin/residual_adapters
a3d32b4fb6c3c252f5adc1ad178b026a111c1a08
[ "Apache-2.0" ]
40
2018-04-04T12:36:54.000Z
2022-02-19T05:46:36.000Z
# models.py # created by Sylvestre-Alvise Rebuffi [srebuffi@robots.ox.ac.uk] # Copyright © The University of Oxford, 2017-2020 # This code is made available under the Apache v2.0 licence, see LICENSE.txt for details import torch import torch.nn as nn import torch.nn.functional as F from torch.autograd import Variable...
39.945205
133
0.627743
4,844
0.830447
0
0
0
0
0
0
355
0.060861
5703b571d61c82b1ad4a982fd9b8632e8dd15fd8
1,028
py
Python
Parte 02/Projeto 01.py
andrewyamagata/Python
ac9baf16cd142156829ec6e977ecfcac8a4e3965
[ "MIT" ]
null
null
null
Parte 02/Projeto 01.py
andrewyamagata/Python
ac9baf16cd142156829ec6e977ecfcac8a4e3965
[ "MIT" ]
null
null
null
Parte 02/Projeto 01.py
andrewyamagata/Python
ac9baf16cd142156829ec6e977ecfcac8a4e3965
[ "MIT" ]
null
null
null
#Condições Aninhadas #if -> elif -> elif -> else # pode usar quantos elif quiser #Aprovando Empréstimo casa = float(input('Qual o valor da casa: R$ ')) salario = float(input('Qual o valor do salário: R$ ')) tempo = int(input('Quanto anos para pagar? ')) salario30 = salario * 0.30 prestacao = casa / (tempo * 12) if sal...
38.074074
168
0.657588
0
0
0
0
0
0
0
0
611
0.582459
57053e08159134b657dc6dde4b49efc028c6a0a2
2,196
py
Python
main.py
GauravP2001/courseSniperBot
c3e05d2890f10177ee847a961b957d5e63e7d0ec
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
main.py
GauravP2001/courseSniperBot
c3e05d2890f10177ee847a961b957d5e63e7d0ec
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
main.py
GauravP2001/courseSniperBot
c3e05d2890f10177ee847a961b957d5e63e7d0ec
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
import discord import os import requests import asyncio import psycopg2 import logging from apscheduler.schedulers.asyncio import AsyncIOScheduler from discord.ext import commands logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(name)s - %(levelname)s - %(message)s', datefmt=f"%m/%d...
28.519481
105
0.658015
0
0
0
0
294
0.13388
1,027
0.467668
806
0.367031
57071627a3f7ead2f2e5161d076288e623b02921
160
py
Python
src/utilities/grammar.py
sonishreyas/news_scraper
7cd1bd9eb14fb903fc7b190b04191237da0a1d23
[ "MIT" ]
null
null
null
src/utilities/grammar.py
sonishreyas/news_scraper
7cd1bd9eb14fb903fc7b190b04191237da0a1d23
[ "MIT" ]
null
null
null
src/utilities/grammar.py
sonishreyas/news_scraper
7cd1bd9eb14fb903fc7b190b04191237da0a1d23
[ "MIT" ]
null
null
null
from gingerit.gingerit import GingerIt def check_grammar(text): parser = GingerIt() correct_text = parser.parse(text) return correct_text['result']
26.666667
38
0.74375
0
0
0
0
0
0
0
0
8
0.05
57075fadbef4087df6eac236abcbc48b853a6d54
619
py
Python
Python_Exercicios/Mundo2/Condições em Python (if..elif)/python_038.py
jbauermanncode/Curso_Em_Video_Python
330c207d7bed4e663fe1b9ab433ab57a9828b7f1
[ "MIT" ]
null
null
null
Python_Exercicios/Mundo2/Condições em Python (if..elif)/python_038.py
jbauermanncode/Curso_Em_Video_Python
330c207d7bed4e663fe1b9ab433ab57a9828b7f1
[ "MIT" ]
null
null
null
Python_Exercicios/Mundo2/Condições em Python (if..elif)/python_038.py
jbauermanncode/Curso_Em_Video_Python
330c207d7bed4e663fe1b9ab433ab57a9828b7f1
[ "MIT" ]
null
null
null
''' Escreva um programa que leia dois números inteiros e compare- os, mostrando na tela uma mensagem: - O primeiro valor é maior - O segundo valor é maior - não existe valor maior, os dois são iguais ''' # Ler dois números inteiros n1 = int(input('Informe o primeiro número: ')) n2 = int(input('In...
22.925926
101
0.663974
0
0
0
0
0
0
0
0
456
0.719243
57088093d1d0b3cfd26c3d3201f0bca2db2decb3
324
py
Python
ABS/ABC085C.py
fumiyanll23/AtCoder
362ca9fcacb5415c1458bc8dee5326ba2cc70b65
[ "MIT" ]
null
null
null
ABS/ABC085C.py
fumiyanll23/AtCoder
362ca9fcacb5415c1458bc8dee5326ba2cc70b65
[ "MIT" ]
null
null
null
ABS/ABC085C.py
fumiyanll23/AtCoder
362ca9fcacb5415c1458bc8dee5326ba2cc70b65
[ "MIT" ]
null
null
null
def main(): # input N, Y = map(int, input().split()) # compute for i in range(N+1): for j in range(N+1): if 10000*i+5000*j+1000*(N-i-j)==Y and N-i-j>=0: print(i, j, N-i-j) exit() # output print(-1, -1, -1) if __name__ == '__main__': mai...
18
59
0.435185
0
0
0
0
0
0
0
0
34
0.104938
5708b5548cafd7c9ca9620325b1633201ca209f8
1,127
py
Python
mail_open_xchange/__openerp__.py
OdooCommunityWidgets/IDEAS-FOR-MODULES
74c588f6b6058119b8953650b6cb325fe5506cfd
[ "MIT" ]
1
2015-05-27T19:56:29.000Z
2015-05-27T19:56:29.000Z
mail_open_xchange/__openerp__.py
OdooCommunityWidgets/IDEAS-FOR-MODULES
74c588f6b6058119b8953650b6cb325fe5506cfd
[ "MIT" ]
null
null
null
mail_open_xchange/__openerp__.py
OdooCommunityWidgets/IDEAS-FOR-MODULES
74c588f6b6058119b8953650b6cb325fe5506cfd
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- { 'name': 'Open-Xchange Odoo', 'version': '1.0', 'category': 'Social Network', 'sequence': 2, 'summary': 'Discussions, Mailing Lists, News', 'description': """ Open-Xchange Integration ========================= This module is designed to be a standard open-xchange inbox i...
38.862069
233
0.674357
0
0
0
0
0
0
0
0
993
0.8811
5708df6ade016849aefe1a0044ec7ee2d375c82f
10,853
py
Python
testing/test_pulse_prop.py
ibegleris/w-fopo
e44b83b8ec54d01bb34b89805378a2b0659dfe6f
[ "BSD-3-Clause" ]
null
null
null
testing/test_pulse_prop.py
ibegleris/w-fopo
e44b83b8ec54d01bb34b89805378a2b0659dfe6f
[ "BSD-3-Clause" ]
null
null
null
testing/test_pulse_prop.py
ibegleris/w-fopo
e44b83b8ec54d01bb34b89805378a2b0659dfe6f
[ "BSD-3-Clause" ]
null
null
null
import sys sys.path.append('src') from functions import * import numpy as np from numpy.testing import assert_allclose "-----------------------Full soliton--------------------------------------------" def get_Qs(nm, gama,fv, a_vec, dnerr, index, master_index,lamda, n2): if nm == 1: D = loadmat('loading_dat...
36.056478
105
0.540404
5,177
0.477011
0
0
0
0
0
0
1,790
0.164931
570a3a32cbbdc85ab026871552208d720276a1d7
1,089
py
Python
download.py
wujushan/AndroidHeatMap
1d6ecff8d810ffd63ba84f56c1a44ee5e7770c59
[ "Apache-2.0" ]
1
2019-06-13T16:05:36.000Z
2019-06-13T16:05:36.000Z
download.py
wujushan/AndroidHeatMap
1d6ecff8d810ffd63ba84f56c1a44ee5e7770c59
[ "Apache-2.0" ]
null
null
null
download.py
wujushan/AndroidHeatMap
1d6ecff8d810ffd63ba84f56c1a44ee5e7770c59
[ "Apache-2.0" ]
null
null
null
import os import requests def download(url): download_path = '/root/AndroidHeatMap/download/' if not os.path.exists(download_path): os.mkdir(download_path) all_content = requests.get(url).text file_line = all_content.split("\n") if file_line[0] != "#EXTM3U": raise BaseExceptio...
34.03125
113
0.575758
0
0
0
0
0
0
0
0
232
0.213039
570a7fbde091be0d15c77144e4caa11f184860d3
4,945
py
Python
tests/watermarks_test.py
yujialuo/erdos
7a631b55895f1a473b0f4d38a0d6053851e65b5d
[ "Apache-2.0" ]
null
null
null
tests/watermarks_test.py
yujialuo/erdos
7a631b55895f1a473b0f4d38a0d6053851e65b5d
[ "Apache-2.0" ]
null
null
null
tests/watermarks_test.py
yujialuo/erdos
7a631b55895f1a473b0f4d38a0d6053851e65b5d
[ "Apache-2.0" ]
null
null
null
from collections import defaultdict from time import sleep from absl import app from absl import flags import erdos.graph from erdos.op import Op from erdos.utils import frequency from erdos.message import Message from erdos.data_stream import DataStream from erdos.timestamp import Timestamp from erdos.message import...
37.462121
90
0.658038
3,999
0.808696
0
0
1,545
0.312437
0
0
1,640
0.331648
570a9547e24dbd1a28701e76c97396c34016c792
1,436
py
Python
test/test_shop/views.py
blakelockley/django-base-shop
455a2f4465e90cde57719ac29dc090b14f0bd324
[ "MIT" ]
1
2020-01-12T04:05:42.000Z
2020-01-12T04:05:42.000Z
test/test_shop/views.py
blakelockley/django-base-shop
455a2f4465e90cde57719ac29dc090b14f0bd324
[ "MIT" ]
14
2020-03-24T18:11:07.000Z
2022-03-12T00:15:20.000Z
test/test_shop/views.py
blakelockley/django-base-shop
455a2f4465e90cde57719ac29dc090b14f0bd324
[ "MIT" ]
null
null
null
from django.http import HttpResponse from django_base_shop.models import ShippingTag from .models import ConcreteCart, ConcreteProduct def index(request): return HttpResponse(b"Hello world") def check_cart(request): cart = request.cart if not cart.is_persisted: return HttpResponse(b"None") ...
24.338983
85
0.660167
0
0
0
0
0
0
0
0
266
0.185237
570cfc314b92388cc92855fea7600f5e8b1e443e
11,600
py
Python
q3/q3/drivers/ui/pyqt5.py
virtimus/makaronLab
10b9be7d7d65d3da6219f929ea7070dd5fed3a81
[ "0BSD" ]
2
2021-03-16T05:48:36.000Z
2021-10-11T01:55:48.000Z
q3/q3/drivers/ui/pyqt5.py
virtimus/makaronLab
10b9be7d7d65d3da6219f929ea7070dd5fed3a81
[ "0BSD" ]
null
null
null
q3/q3/drivers/ui/pyqt5.py
virtimus/makaronLab
10b9be7d7d65d3da6219f929ea7070dd5fed3a81
[ "0BSD" ]
1
2021-03-16T05:48:39.000Z
2021-03-16T05:48:39.000Z
# PYQT import sys #from ...TabPanel import TabPanel import sip from q3.ui.engine import qtw,qtc,qtg from ... import consts, prop, direction from ...ui import orientation, colors from ...moduletype import ModuleType from ...nodeiotype import NodeIoType from ...q3vector import Q3Vector from ...EventSignal import E...
34.017595
141
0.617931
10,978
0.946379
0
0
0
0
0
0
3,326
0.286724
570eadcaa613e66d764e81bda74fc4c5ac38c715
2,538
py
Python
2. ExaminingBivariateandMultivariateRelationships/2. scatter_plots.py
michaelbwalker/Data-Cleaning-and-Exploration-with-Machine-Learning
9de44e5ad2e8d197b0a3c1b362b0377339278bd2
[ "MIT" ]
7
2021-10-02T03:19:59.000Z
2022-03-21T21:24:14.000Z
2. ExaminingBivariateandMultivariateRelationships/2. scatter_plots.py
michaelbwalker/Data-Cleaning-and-Exploration-with-Machine-Learning
9de44e5ad2e8d197b0a3c1b362b0377339278bd2
[ "MIT" ]
null
null
null
2. ExaminingBivariateandMultivariateRelationships/2. scatter_plots.py
michaelbwalker/Data-Cleaning-and-Exploration-with-Machine-Learning
9de44e5ad2e8d197b0a3c1b362b0377339278bd2
[ "MIT" ]
6
2021-08-30T02:58:02.000Z
2022-02-01T07:46:49.000Z
# import pandas, matplotlib, and seaborn import pandas as pd import numpy as np import matplotlib.pyplot as plt import seaborn as sns pd.set_option('display.width', 53) pd.set_option('display.max_columns', 5) pd.set_option('display.max_rows', 200) pd.options.display.float_format = '{:,.0f}'.format covidtotals = pd.read...
39.046154
130
0.754137
0
0
0
0
0
0
0
0
1,022
0.402679
570ee5f940cb42c1bdadbd336c5d3471836f1133
7,359
py
Python
tests/test/base/test_map_set.py
Eve-ning/reamber_base_py
6d19c84f2c110b60e633b82b73e0516396466f56
[ "MIT" ]
10
2020-06-28T11:16:36.000Z
2021-08-09T21:41:43.000Z
tests/test/base/test_map_set.py
Eve-ning/reamberPy
6d19c84f2c110b60e633b82b73e0516396466f56
[ "MIT" ]
35
2020-06-18T13:05:50.000Z
2022-02-18T10:13:35.000Z
tests/test/base/test_map_set.py
Eve-ning/reamber_base_py
6d19c84f2c110b60e633b82b73e0516396466f56
[ "MIT" ]
2
2021-05-26T17:05:06.000Z
2021-06-12T18:42:13.000Z
import unittest import numpy as np from reamber.base import Bpm, Hit, Hold, Map, MapSet from reamber.base.lists import BpmList from reamber.base.lists.notes import HitList, HoldList # noinspection PyTypeChecker,DuplicatedCode class TestMapSet(unittest.TestCase): """ Not much to test here since Bpm is basically ...
54.110294
116
0.621552
7,079
0.961951
0
0
0
0
0
0
686
0.093219
570f7be4fc6a73c331b26ffda6ddfc47a075df88
1,252
py
Python
minifyoperation.py
seece/cbpp
b6771c7933fa07444e660eafda6f06cf60edce01
[ "MIT" ]
null
null
null
minifyoperation.py
seece/cbpp
b6771c7933fa07444e660eafda6f06cf60edce01
[ "MIT" ]
null
null
null
minifyoperation.py
seece/cbpp
b6771c7933fa07444e660eafda6f06cf60edce01
[ "MIT" ]
null
null
null
import re from util import * from operation import Operation, OperationResult class Replacement: def __init__(self, regex, substitution): self.regex = regex self.substitution = substitution class MinifyOperation(Operation): def __init__(self): self.inMultilineComment = False pass def apply(self, line, sta...
24.076923
122
0.626997
1,169
0.933706
0
0
0
0
0
0
170
0.135783
570f8d367a6c727fc6ef795d72a90ef7bea75141
2,024
py
Python
graph.py
mrpatiwi/k-walk-py
a800f64079024716b26c0ebb9c3a2c5b6a935b78
[ "MIT" ]
null
null
null
graph.py
mrpatiwi/k-walk-py
a800f64079024716b26c0ebb9c3a2c5b6a935b78
[ "MIT" ]
null
null
null
graph.py
mrpatiwi/k-walk-py
a800f64079024716b26c0ebb9c3a2c5b6a935b78
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from index_matrix import Matrix __author__ = 'Patricio Lopez Juri' class Graph: def __init__(self, V, E, K): self.V = V self.E = E self.K = K self.A = Matrix.square(items=V) for a, b in self.E: self.A[a, b] = 1 @property def o...
23.264368
77
0.535079
1,928
0.952569
0
0
162
0.08004
0
0
44
0.021739
570fe23611397bcc46c1ab733771a0e34fdc4ba4
1,302
py
Python
ep004_helper.py
jpch89/effectivepython
97ba297bf987f346219bf8de5198c0817f5146e0
[ "MIT" ]
null
null
null
ep004_helper.py
jpch89/effectivepython
97ba297bf987f346219bf8de5198c0817f5146e0
[ "MIT" ]
null
null
null
ep004_helper.py
jpch89/effectivepython
97ba297bf987f346219bf8de5198c0817f5146e0
[ "MIT" ]
null
null
null
from urllib.parse import parse_qs # 解析查询字符串 query string my_values = parse_qs('red=5&blue=0&green=', keep_blank_values=True) # print(repr(my_values)) # 原书写法 print(my_values) # 返回的是字典,直接这样写就行了 # >>> # {'red': ['5'], 'blue': ['0'], 'green': ['']} # 查询字符串中的参数可能有:多个值和空白 blank 值。 # 有些参数则没有出现。 # 使用 g...
23.25
48
0.609831
0
0
0
0
0
0
0
0
935
0.55
570febe7fa7b5748adbff547439e5061a41d7ecb
2,643
py
Python
Piece_class_stuff.py
krystianpietryka/Chess
e65afbe3ac51441327a5057b3677334ceb54d916
[ "MIT" ]
null
null
null
Piece_class_stuff.py
krystianpietryka/Chess
e65afbe3ac51441327a5057b3677334ceb54d916
[ "MIT" ]
null
null
null
Piece_class_stuff.py
krystianpietryka/Chess
e65afbe3ac51441327a5057b3677334ceb54d916
[ "MIT" ]
null
null
null
from enum import Enum import pygame class Colour(Enum): WHITE = 0 BLACK = 1 class Piece: def __init__(self, column, row, model, colour): self.row = row self.column = column self.model = model self.colour = colour # Load sprites into pygame class Sprites: board_image...
37.757143
57
0.650397
2,546
0.963299
0
0
0
0
0
0
294
0.111237
5710d9d404ac2b132ecaaa64415a70da05239921
656
py
Python
pubsub.py
basecue/micropython-pubsub
fcb6189d648515f1a7106ed5f54e332ba069793d
[ "Apache-2.0" ]
null
null
null
pubsub.py
basecue/micropython-pubsub
fcb6189d648515f1a7106ed5f54e332ba069793d
[ "Apache-2.0" ]
null
null
null
pubsub.py
basecue/micropython-pubsub
fcb6189d648515f1a7106ed5f54e332ba069793d
[ "Apache-2.0" ]
null
null
null
from micropython import schedule _subscribers = {} def publisher(topic): def _publish(func): def _wrapper(*args, **kwargs): value = func(*args, **kwargs) publish(topic, value) return value return _wrapper return _publish def publish(topic, value) -> Non...
19.294118
47
0.609756
0
0
0
0
0
0
0
0
0
0
5712c5f2bba3745161134c95e4c1fe8d35033684
5,808
py
Python
sc_cost_meter/utils.py
zaro0508/lambda-sc-cost-meter
2e10fa102af983f61a352ae633651fc3eaf64b19
[ "Apache-2.0" ]
null
null
null
sc_cost_meter/utils.py
zaro0508/lambda-sc-cost-meter
2e10fa102af983f61a352ae633651fc3eaf64b19
[ "Apache-2.0" ]
null
null
null
sc_cost_meter/utils.py
zaro0508/lambda-sc-cost-meter
2e10fa102af983f61a352ae633651fc3eaf64b19
[ "Apache-2.0" ]
null
null
null
import boto3 import logging import os from datetime import datetime log = logging.getLogger(__name__) log.setLevel(logging.DEBUG) def get_ec2_client(): return boto3.client('ec2') def get_ssm_client(): return boto3.client('ssm') def get_ce_client(): return boto3.client('ce') def get_meteringmarketplace_clien...
31.394595
89
0.719697
0
0
0
0
0
0
0
0
2,595
0.446798
5714de071955ec101c9d0bd2f8b9cad2f55c7b5c
8,000
py
Python
source/metadata.py
sanmik/brain-network-viz
9c881e49c14c94e3f7ef4b7776d98c930716ee91
[ "MIT" ]
5
2017-09-01T14:05:03.000Z
2019-07-13T07:52:49.000Z
source/metadata.py
sanmik/brain-network-viz
9c881e49c14c94e3f7ef4b7776d98c930716ee91
[ "MIT" ]
null
null
null
source/metadata.py
sanmik/brain-network-viz
9c881e49c14c94e3f7ef4b7776d98c930716ee91
[ "MIT" ]
1
2017-09-01T14:05:03.000Z
2017-09-01T14:05:03.000Z
# Library Imports from itertools import islice import csv # Local Module Imports import config class Metadata(object): """ Base class for maintaining metadata (properties and their attributes) about Node and Edge objects. This base class handles parsing and storing the CSV data, and providing accessor method...
33.057851
79
0.58775
7,897
0.987125
0
0
0
0
0
0
5,212
0.6515
571574f8dd7e9bd961d512815c9fd6535e05f1d8
20,165
py
Python
src/src_python/antares_xpansion/driver.py
pelefebvre/antares-xpansion
c62ed1a982e970325dec6007eb57a9c6288ef0c7
[ "Apache-2.0" ]
null
null
null
src/src_python/antares_xpansion/driver.py
pelefebvre/antares-xpansion
c62ed1a982e970325dec6007eb57a9c6288ef0c7
[ "Apache-2.0" ]
null
null
null
src/src_python/antares_xpansion/driver.py
pelefebvre/antares-xpansion
c62ed1a982e970325dec6007eb57a9c6288ef0c7
[ "Apache-2.0" ]
1
2021-05-27T13:06:26.000Z
2021-05-27T13:06:26.000Z
""" Class to control the execution of the optimization session """ import shutil import configparser import glob import os import subprocess import sys from pathlib import Path from antares_xpansion.input_checker import check_candidates_file from antares_xpansion.input_checker import check_settings_file from ant...
41.069246
129
0.579965
19,788
0.981304
0
0
0
0
0
0
6,066
0.300818
571589111619e9fd5ae98d9e183ad96ef4ec5ca8
1,186
py
Python
CRASHLACMA/slistener.py
carlynorama/CRASHLACMA
d59890a5a0702940a0d678b600230f0f53384710
[ "CC0-1.0" ]
null
null
null
CRASHLACMA/slistener.py
carlynorama/CRASHLACMA
d59890a5a0702940a0d678b600230f0f53384710
[ "CC0-1.0" ]
null
null
null
CRASHLACMA/slistener.py
carlynorama/CRASHLACMA
d59890a5a0702940a0d678b600230f0f53384710
[ "CC0-1.0" ]
null
null
null
from tweepy import StreamListener import json, time, sys class SListener(StreamListener): def __init__(self, api = None, fprefix = 'streamer'): self.api = api or API() self.filecounter = 1 self.fprefix = fprefix def on_data(self, data): if 'in_reply_to_status' in dat...
29.65
108
0.555649
1,126
0.94941
0
0
0
0
0
0
170
0.143339
5715f8e7099f46fd56b68c4c665702f7dc7e68e3
379
py
Python
Curso-em-video-Python/PycharmProjects/pythonExercicios/Ex052.py
sartinicj/curso-em-video-python
8cb4ca05a88351c44aa4a7befc59c9596a50f268
[ "MIT" ]
null
null
null
Curso-em-video-Python/PycharmProjects/pythonExercicios/Ex052.py
sartinicj/curso-em-video-python
8cb4ca05a88351c44aa4a7befc59c9596a50f268
[ "MIT" ]
null
null
null
Curso-em-video-Python/PycharmProjects/pythonExercicios/Ex052.py
sartinicj/curso-em-video-python
8cb4ca05a88351c44aa4a7befc59c9596a50f268
[ "MIT" ]
null
null
null
''' N = int(input('Digite um NÚMERO: ')) tot = 0 for c in range(1, n+1): if n%c == 0: print('\033[33m', end=' ') tot+=1 else: print('\033[31m', end=' ') print('{}'.format(c), end=' ') print('\n\033[mO numero {} foi divisivel {} vezes'.format(n, tot)) if tot == 2: print('E POR ISS...
21.055556
66
0.506596
0
0
0
0
0
0
0
0
382
0.997389
57167335582e22b6c5a86bb8546c9e43ffff5640
158
py
Python
core/views.py
TonyLuque/marketing_website
2ebbbf7788c439afc8192926fa3dc3e231b1e69e
[ "MIT" ]
null
null
null
core/views.py
TonyLuque/marketing_website
2ebbbf7788c439afc8192926fa3dc3e231b1e69e
[ "MIT" ]
null
null
null
core/views.py
TonyLuque/marketing_website
2ebbbf7788c439afc8192926fa3dc3e231b1e69e
[ "MIT" ]
null
null
null
from django.shortcuts import render # Create your views here. def home(request): return render(request,'core/index.html') def detail(request): pass
17.555556
44
0.734177
0
0
0
0
0
0
0
0
42
0.265823
57172ba3fed738751a65af00ff67b7037fd96b96
206
py
Python
qclib/qclab.py
hagne/qclib
c90e06cb22708d610126710715a5d66bd4dc0898
[ "MIT" ]
null
null
null
qclib/qclab.py
hagne/qclib
c90e06cb22708d610126710715a5d66bd4dc0898
[ "MIT" ]
null
null
null
qclib/qclab.py
hagne/qclib
c90e06cb22708d610126710715a5d66bd4dc0898
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import qclib.tag_times def qc_by_tagging_times(path2data, path2database): out = qclib.tag_times.Controller(path2data=path2data, path2database=path2database) return out
25.75
86
0.747573
0
0
0
0
0
0
0
0
23
0.11165
57179805f172aec6d932cd77e1ce3e7e6d275877
317
py
Python
t_server.py
iloghyr/easy_python
b750f6817d54562b23630e2419bace19da0abf8b
[ "Apache-2.0" ]
1
2018-03-01T02:42:52.000Z
2018-03-01T02:42:52.000Z
t_server.py
iloghyr/easy_python
b750f6817d54562b23630e2419bace19da0abf8b
[ "Apache-2.0" ]
null
null
null
t_server.py
iloghyr/easy_python
b750f6817d54562b23630e2419bace19da0abf8b
[ "Apache-2.0" ]
null
null
null
import socket address = ('127.0.0.1', 31500) s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # s = socket.socket() s.bind(address) s.listen(5) ss, addr = s.accept() print 'got connected from',addr ss.send('hihi') ra = ss.recv(512) print ra ss.close() s.close()
19.8125
78
0.583596
0
0
0
0
0
0
0
0
61
0.192429
5717a38a4849d391d82607edadcfd400d7080783
1,906
py
Python
py_solutions_71-80/Euler_77.py
tijko/Project-Euler
d953a2bf6932c2c4e1235409fedf760add65a0ba
[ "MIT" ]
null
null
null
py_solutions_71-80/Euler_77.py
tijko/Project-Euler
d953a2bf6932c2c4e1235409fedf760add65a0ba
[ "MIT" ]
1
2022-03-15T02:49:09.000Z
2022-03-15T02:49:09.000Z
py_solutions_71-80/Euler_77.py
tijko/Project-Euler
d953a2bf6932c2c4e1235409fedf760add65a0ba
[ "MIT" ]
null
null
null
# what is the first number to have 5000 different ways to sum with prime numbers? import math import timeit start = timeit.default_timer() def is_prime(x): if x == 2: return True if x % 2 == 0 or x == 1: return False for i in range(3,int(math.sqrt(x))+1,2): if x % i == 0: ...
28.029412
82
0.407135
0
0
0
0
0
0
0
0
104
0.054565
57199578121fb89b3db3e976c4737dd3dcc14bf5
2,258
py
Python
lambdas/get_users.py
charvi-a/320-S20-Track1
ac97504fc1fdedb1c311773b015570eeea8a8663
[ "BSD-3-Clause" ]
9
2019-12-30T16:32:22.000Z
2020-03-03T20:14:47.000Z
lambdas/get_users.py
charvi-a/320-S20-Track1
ac97504fc1fdedb1c311773b015570eeea8a8663
[ "BSD-3-Clause" ]
283
2020-02-03T15:16:03.000Z
2020-05-05T03:18:59.000Z
lambdas/get_users.py
charvi-a/320-S20-Track1
ac97504fc1fdedb1c311773b015570eeea8a8663
[ "BSD-3-Clause" ]
3
2020-04-16T15:23:29.000Z
2020-05-12T00:38:41.000Z
from package.query_db import query from package.lambda_exception import LambdaException def handler(event, context): is_admin = event['is_admin'] is_supporter = event['is_supporter'] is_student = event['is_student'] if is_admin == "" and is_supporter == "" and is_student == "": get_users_sql ...
34.738462
171
0.574402
0
0
0
0
0
0
0
0
561
0.24845
571ab14954af261729cb1d3fc0d5e206657e96fa
705
py
Python
leetCode/swap_nodes_in_pairs.py
yskang/AlgorithmPracticeWithPython
f7129bd1924a7961489198f0ee052d2cd1e9cf40
[ "MIT" ]
null
null
null
leetCode/swap_nodes_in_pairs.py
yskang/AlgorithmPracticeWithPython
f7129bd1924a7961489198f0ee052d2cd1e9cf40
[ "MIT" ]
1
2019-11-04T06:44:04.000Z
2019-11-04T06:46:55.000Z
leetCode/swap_nodes_in_pairs.py
yskang/AlgorithmPractice
31b76e38b4c2f1e3e29fb029587662a745437912
[ "MIT" ]
null
null
null
# Title: Swap Nodes in Pairs # Link: https://leetcode.com/problems/swap-nodes-in-pairs class ListNode: def __init__(self, val=0, next=None): self.val = val self.next = next class Problem: def swap_pairs(self, head: ListNode) -> ListNode: pre, pre.next = self, head while pre.nex...
22.741935
61
0.58156
395
0.560284
0
0
0
0
0
0
95
0.134752
571ac253ee844d994243e9c2e1443c9c4aa20002
16,967
py
Python
detect_actions.py
CTewan/ACAM_Demo
b76cf4ce1289b8c311dbad1588f299ff67f7eaf3
[ "MIT" ]
null
null
null
detect_actions.py
CTewan/ACAM_Demo
b76cf4ce1289b8c311dbad1588f299ff67f7eaf3
[ "MIT" ]
null
null
null
detect_actions.py
CTewan/ACAM_Demo
b76cf4ce1289b8c311dbad1588f299ff67f7eaf3
[ "MIT" ]
null
null
null
import numpy as np import cv2 import imageio import tensorflow as tf import json import csv import os import sys sys.path.append("object_detection") sys.path.append("object_detection/deep_sort") sys.path.append("action_detection") import argparse import object_detection.object_detector as obj import action_detection...
38.386878
145
0.590263
0
0
0
0
0
0
0
0
3,712
0.218778
571af6febfc1dc4cb09b37f0fb44cc848ccf1059
5,556
py
Python
tests/test_parametric_shapes/test_SweepMixedShape.py
RemDelaporteMathurin/paramak
10552f1b89820dd0f7a08e4a126834877e3106b4
[ "MIT" ]
null
null
null
tests/test_parametric_shapes/test_SweepMixedShape.py
RemDelaporteMathurin/paramak
10552f1b89820dd0f7a08e4a126834877e3106b4
[ "MIT" ]
null
null
null
tests/test_parametric_shapes/test_SweepMixedShape.py
RemDelaporteMathurin/paramak
10552f1b89820dd0f7a08e4a126834877e3106b4
[ "MIT" ]
null
null
null
import os import unittest from pathlib import Path import pytest from paramak import SweepMixedShape class test_object_properties(unittest.TestCase): def test_solid_construction(self): """checks that a SweepMixedShape solid can be created""" test_shape = SweepMixedShape( points=[ ...
29.089005
89
0.430166
5,401
0.972102
0
0
0
0
0
0
962
0.173146
571d88262578b13c16efd4393da7b28acd2cd972
458
py
Python
upload.py
newkisoft/newki-sql-backup
82690b25cfa57dc770210e5a3398954949271c0e
[ "MIT" ]
null
null
null
upload.py
newkisoft/newki-sql-backup
82690b25cfa57dc770210e5a3398954949271c0e
[ "MIT" ]
null
null
null
upload.py
newkisoft/newki-sql-backup
82690b25cfa57dc770210e5a3398954949271c0e
[ "MIT" ]
null
null
null
from boto3.s3.transfer import S3Transfer import boto3 import glob import os def upload_to_aws(local_file, bucket, s3_file): client = boto3.client('s3', aws_access_key_id='###',aws_secret_access_key='###') transfer = S3Transfer(client) transfer.upload_file(local_file, bucket, local_file) fi...
28.625
84
0.69869
0
0
0
0
0
0
0
0
35
0.076419
571dbed119712d82f6343f841d5c39a1d78ee427
996
py
Python
run_rnn.py
iqbaalmuhmd/CNNnumpyTest
eaecf5bc53a7b5c932a82d38cc6ca2a40430af4b
[ "MIT" ]
332
2017-06-13T10:40:05.000Z
2022-03-11T15:10:02.000Z
run_rnn.py
iqbaalmuhmd/CNNnumpyTest
eaecf5bc53a7b5c932a82d38cc6ca2a40430af4b
[ "MIT" ]
9
2017-06-16T02:36:06.000Z
2021-05-09T06:01:34.000Z
run_rnn.py
iqbaalmuhmd/CNNnumpyTest
eaecf5bc53a7b5c932a82d38cc6ca2a40430af4b
[ "MIT" ]
105
2017-06-15T06:40:44.000Z
2022-03-09T06:38:59.000Z
import numpy as np from deepnet.nnet import RNN from deepnet.solver import sgd_rnn def text_to_inputs(path): """ Converts the given text into X and y vectors X : contains the index of all the characters in the text vocab y : y[i] contains the index of next character for X[i] in the text vocab """ ...
27.666667
79
0.625502
0
0
0
0
0
0
0
0
231
0.231928
571ddbe314e19b402b88195037ee31e371ecdddf
5,421
py
Python
lcclassifier/experiments/attnstats.py
oscarpimentel/astro-lightcurves-classifier
f697b43e22bd8c92c1b9df514be8565c736dd7cc
[ "MIT" ]
1
2021-12-31T18:00:08.000Z
2021-12-31T18:00:08.000Z
lcclassifier/experiments/attnstats.py
oscarpimentel/astro-lightcurves-classifier
f697b43e22bd8c92c1b9df514be8565c736dd7cc
[ "MIT" ]
null
null
null
lcclassifier/experiments/attnstats.py
oscarpimentel/astro-lightcurves-classifier
f697b43e22bd8c92c1b9df514be8565c736dd7cc
[ "MIT" ]
null
null
null
from __future__ import print_function from __future__ import division from . import _C import torch from fuzzytorch.utils import TDictHolder, tensor_to_numpy, minibatch_dict_collate import numpy as np from fuzzytools.progress_bars import ProgressBar, ProgressBarMulti import fuzzytools.files as files import fuzzytools....
35.431373
147
0.65855
0
0
0
0
0
0
0
0
1,568
0.289246
571ea096124b732422144c10209f4cc5cb3c06c7
1,473
py
Python
get_item_by_key.py
flyco2016/my_python_module_project
6e1ac7f074f7b57403d7b7c6adadab17a26fc27d
[ "Apache-2.0" ]
null
null
null
get_item_by_key.py
flyco2016/my_python_module_project
6e1ac7f074f7b57403d7b7c6adadab17a26fc27d
[ "Apache-2.0" ]
1
2019-01-04T06:37:06.000Z
2019-01-04T06:37:06.000Z
get_item_by_key.py
flyco2016/my_python_module_project
6e1ac7f074f7b57403d7b7c6adadab17a26fc27d
[ "Apache-2.0" ]
null
null
null
# 处理嵌套的根据键取值 def getItemByKey(obj, key, result=None): if isinstance(obj, dict): for k in obj: if key == k: if isinstance(result, list): if isinstance(obj[k], list): result.extend(obj[k]) else: ...
33.477273
81
0.491514
0
0
0
0
0
0
0
0
70
0.046885
571ee3c5442f3448677cce9af4cb7b0165e2aa98
148
py
Python
tests/test_tail_chunks.py
moskytw/tacit
58286a71140be150438d10acf93028ef5f78f6d1
[ "MIT" ]
null
null
null
tests/test_tail_chunks.py
moskytw/tacit
58286a71140be150438d10acf93028ef5f78f6d1
[ "MIT" ]
null
null
null
tests/test_tail_chunks.py
moskytw/tacit
58286a71140be150438d10acf93028ef5f78f6d1
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- from tacit import tac_slices for chunk in tac_slices('data/ordered.list', 2): print repr(chunk)
18.5
48
0.675676
0
0
0
0
0
0
0
0
63
0.425676
571f77622a48c2fb03cc44698429e534d7932593
7,166
py
Python
calories.py
davidsvaughn/har-pytorch
334733a1e870637c9077d16fc15e0b1954a6dfc5
[ "MIT" ]
5
2020-09-17T12:17:13.000Z
2022-02-28T08:07:49.000Z
calories.py
davidsvaughn/har-pytorch
334733a1e870637c9077d16fc15e0b1954a6dfc5
[ "MIT" ]
null
null
null
calories.py
davidsvaughn/har-pytorch
334733a1e870637c9077d16fc15e0b1954a6dfc5
[ "MIT" ]
null
null
null
import numpy as np import pandas as pd import json from datetime import datetime import psycopg2 import functools import requests ############################################################## ## https://www.exrx.net/Calculators/WalkRunMETs ## https://www.cdc.gov/growthcharts/clinical_charts.htm ## https://help.fitbit...
30.887931
110
0.558889
1,205
0.168155
0
0
813
0.113452
0
0
2,055
0.286771
5720538c6a907cf78b7908572f98d96063191e14
1,651
py
Python
pagelets/conf.py
rysdyk/django-pagelets
31669771b7ecf8ade3dae64465d3fa984d88d0f9
[ "BSD-3-Clause" ]
null
null
null
pagelets/conf.py
rysdyk/django-pagelets
31669771b7ecf8ade3dae64465d3fa984d88d0f9
[ "BSD-3-Clause" ]
null
null
null
pagelets/conf.py
rysdyk/django-pagelets
31669771b7ecf8ade3dae64465d3fa984d88d0f9
[ "BSD-3-Clause" ]
null
null
null
from django.conf import settings CONTENT_AREAS = getattr(settings, 'PAGELET_CONTENT_AREAS', ( ('main', 'Main'), )) CONTENT_AREA_DEFAULT = getattr(settings, 'PAGELET_CONTENT_AREA_DEFAULT', 'main') CONTENT_TYPES = getattr(settings, 'PAGELET_CONTENT_TYPES', ( ('html', 'HTML', (), {},), ('markdown'...
36.688889
85
0.723198
0
0
0
0
0
0
0
0
711
0.430648
5721e5bf810d647e593fd1d82e6a86cb2fa7e570
14,744
py
Python
alphad3m/alphad3m/metalearning/grammar_builder.py
VIDA-NYU/alphad3m
db40193a448300d87442c451f9da17fa5cb845fd
[ "Apache-2.0" ]
null
null
null
alphad3m/alphad3m/metalearning/grammar_builder.py
VIDA-NYU/alphad3m
db40193a448300d87442c451f9da17fa5cb845fd
[ "Apache-2.0" ]
null
null
null
alphad3m/alphad3m/metalearning/grammar_builder.py
VIDA-NYU/alphad3m
db40193a448300d87442c451f9da17fa5cb845fd
[ "Apache-2.0" ]
null
null
null
import logging import numpy as np from scipy import stats from collections import OrderedDict from alphad3m.metalearning.resource_builder import load_metalearningdb from alphad3m.metalearning.dataset_similarity import get_similar_datasets from alphad3m.primitive_loader import load_primitives_by_name, load_primitives_by...
48.983389
165
0.686788
0
0
0
0
0
0
0
0
3,566
0.241795
5723328e5cd271a82c8d25b908bc2b420246795d
4,512
py
Python
deap_learning.py
fzjcdt/Genetic-CNN
6bd53f3f429434557b7fbf1122020259d910f618
[ "Apache-2.0" ]
2
2019-10-08T08:27:41.000Z
2021-12-02T07:37:27.000Z
deap_learning.py
fzjcdt/Genetic-CNN
6bd53f3f429434557b7fbf1122020259d910f618
[ "Apache-2.0" ]
null
null
null
deap_learning.py
fzjcdt/Genetic-CNN
6bd53f3f429434557b7fbf1122020259d910f618
[ "Apache-2.0" ]
null
null
null
from deap import base, creator, tools import random """ 每个individual是一个list,包含10个元素,需要演化到元素和最小 """ # ****************************Types******************************** # def create(name, base, **kargs): # Creates a new class named *name* inheriting from *base* # A negative weight element corresponds to the minimization...
33.176471
89
0.629876
0
0
0
0
0
0
0
0
3,179
0.639381
57262781980201cf7735ba35e8965dd0cb76ade8
1,674
py
Python
pacman/utils/replay_buffer.py
i-rme/openai-pacman
4a80ed023ed2bdf031990147acbbeea904b9fc8e
[ "MIT" ]
2
2020-01-26T23:06:57.000Z
2021-04-12T08:36:55.000Z
pacman/utils/replay_buffer.py
i-rme/openai-pacman
4a80ed023ed2bdf031990147acbbeea904b9fc8e
[ "MIT" ]
null
null
null
pacman/utils/replay_buffer.py
i-rme/openai-pacman
4a80ed023ed2bdf031990147acbbeea904b9fc8e
[ "MIT" ]
null
null
null
from collections import deque import random import numpy as np class ReplayBuffer: ''' construct a buffer object that stores the past moves and samples a set of subsamples ''' def __init__(self, buffer_size): self.buffer_size = buffer_size self.count = 0 self.buffer = deque...
27.442623
93
0.548387
1,610
0.961768
0
0
0
0
0
0
641
0.382915
5726ab8f943f02dfa0eee1936447786383a1ce72
9,126
py
Python
tests/entities/test_creature.py
Flame753/ARPG
f931d3437a83995b43bdddc68cb5ba89922dc259
[ "MIT" ]
null
null
null
tests/entities/test_creature.py
Flame753/ARPG
f931d3437a83995b43bdddc68cb5ba89922dc259
[ "MIT" ]
null
null
null
tests/entities/test_creature.py
Flame753/ARPG
f931d3437a83995b43bdddc68cb5ba89922dc259
[ "MIT" ]
null
null
null
# Standard library imports from pprint import pprint import unittest # Local application imports from context import entities from entities import creatures from entities import items from entities import currency from entities import slots class TestCreature(unittest.TestCase): def setUp(self): self.d...
36.504
107
0.655928
8,651
0.947951
0
0
0
0
0
0
833
0.091278
5727029dde1ffe2dc5b477e3ae9e9d629cfe867a
729
py
Python
tile/io.py
ViliamV/tile
a2b105143341f250690b8034076ba9214e9ed787
[ "MIT" ]
null
null
null
tile/io.py
ViliamV/tile
a2b105143341f250690b8034076ba9214e9ed787
[ "MIT" ]
null
null
null
tile/io.py
ViliamV/tile
a2b105143341f250690b8034076ba9214e9ed787
[ "MIT" ]
null
null
null
import collections import re from typing import Iterator, TextIO from .constants import TILE_END, TILE_START, TILE_WARNING def from_file(file: TextIO) -> Iterator[str]: with file as f: yield from f def to_file(file: TextIO, lines: Iterator[str]): with file as f: f.write("\n".join(lines)) ...
24.3
100
0.650206
0
0
86
0.11797
0
0
0
0
45
0.061728
572995aff10ad23755f80a0359fa3ca259ee111e
199
py
Python
testfiles/benchmarks/send_multiple.py
marcolamartina/PASTEL
8e1e0fd086a26b7c50f15fe87ffe5dbd007cf925
[ "MIT" ]
null
null
null
testfiles/benchmarks/send_multiple.py
marcolamartina/PASTEL
8e1e0fd086a26b7c50f15fe87ffe5dbd007cf925
[ "MIT" ]
null
null
null
testfiles/benchmarks/send_multiple.py
marcolamartina/PASTEL
8e1e0fd086a26b7c50f15fe87ffe5dbd007cf925
[ "MIT" ]
1
2020-07-08T11:23:22.000Z
2020-07-08T11:23:22.000Z
import binascii from pwn import * def send(r,num): r.sendline(str(num)) port = 1234 server = '127.0.0.1' sleep(1) for i in range(10000): r = remote(server, port) send(r,i) r.close()
15.307692
28
0.623116
0
0
0
0
0
0
0
0
11
0.055276
572a6ba98328eb8f0c8ea9e03989e22fca55780e
271
py
Python
backend/users/serializers.py
rmisiarek/django_vue_base
440459fdd73209e47567fb3572c056a05dc1c45a
[ "MIT" ]
2
2019-04-28T20:26:13.000Z
2020-05-04T03:18:23.000Z
backend/users/serializers.py
rmisiarek/django_vue_base
440459fdd73209e47567fb3572c056a05dc1c45a
[ "MIT" ]
22
2019-12-04T22:34:42.000Z
2022-02-12T07:12:29.000Z
backend/users/serializers.py
shrekdev/Django_Vue_Base
4f200358724bce137f9c5e723036b280e4fd81e2
[ "MIT" ]
null
null
null
from djoser.serializers import UserCreateSerializer from .models import CustomUser class CustomUserRegistrationSerializer(UserCreateSerializer): class Meta(UserCreateSerializer.Meta): model = CustomUser fields = ('first_name', 'email', 'password')
27.1
61
0.763838
185
0.682657
0
0
0
0
0
0
29
0.107011
572d902af0ded1f19ce7ceba83a724a3db7dd67b
30
py
Python
flaskslack/__init__.py
Jamiewu2/flask-slack-template
8a2168aaab03ed080a3eab186c20a488cdf2055e
[ "MIT" ]
null
null
null
flaskslack/__init__.py
Jamiewu2/flask-slack-template
8a2168aaab03ed080a3eab186c20a488cdf2055e
[ "MIT" ]
null
null
null
flaskslack/__init__.py
Jamiewu2/flask-slack-template
8a2168aaab03ed080a3eab186c20a488cdf2055e
[ "MIT" ]
null
null
null
name = "flask_slack_template"
15
29
0.8
0
0
0
0
0
0
0
0
22
0.733333
572e21eca46eed4b2a282d7364cf1c249e13c730
6,704
py
Python
cpu.py
fernandozanutto/PyNES
cb8d589ceb55cd7df0e114e726c6b6bbbc556172
[ "Apache-2.0" ]
null
null
null
cpu.py
fernandozanutto/PyNES
cb8d589ceb55cd7df0e114e726c6b6bbbc556172
[ "Apache-2.0" ]
null
null
null
cpu.py
fernandozanutto/PyNES
cb8d589ceb55cd7df0e114e726c6b6bbbc556172
[ "Apache-2.0" ]
null
null
null
from typing import Dict from time import time_ns from bus import Bus from instructions.generic_instructions import Instruction from rom import ROM from status import Status import instructions.instructions as i_file import instructions.jump_instructions as j_file import instructions.load_instructions as l_file import ...
33.688442
110
0.604117
6,082
0.90722
0
0
0
0
0
0
1,173
0.17497
572f76ae3e95b7728b1969e8e8e8f04344ee7dae
227
py
Python
solution.py
t-pastore/gamesolver
39b0ba45350f0b558c53c40e7cc659577059d369
[ "Apache-2.0" ]
1
2021-01-27T03:14:07.000Z
2021-01-27T03:14:07.000Z
solution.py
t-pastore/gamesolver
39b0ba45350f0b558c53c40e7cc659577059d369
[ "Apache-2.0" ]
null
null
null
solution.py
t-pastore/gamesolver
39b0ba45350f0b558c53c40e7cc659577059d369
[ "Apache-2.0" ]
null
null
null
class Solution(): def __init__(self): self.pureNE = [] self.mixedNE = [] def appendPureNE(self, tup): self.pureNE.append(tup) def appendMixedNE(self, tup): self.mixedNE.append(tup)
20.636364
33
0.585903
227
1
0
0
0
0
0
0
0
0
57301fb1a81fd60d2a17effeed4478182c84a5a9
2,622
py
Python
timeouts/aa.py
kapsitis/ddgatve-stat
684fac54b9d0b8e7891f58bf1fb32605a2d87a3c
[ "Apache-2.0" ]
null
null
null
timeouts/aa.py
kapsitis/ddgatve-stat
684fac54b9d0b8e7891f58bf1fb32605a2d87a3c
[ "Apache-2.0" ]
null
null
null
timeouts/aa.py
kapsitis/ddgatve-stat
684fac54b9d0b8e7891f58bf1fb32605a2d87a3c
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import datetime import os import subprocess import re import urllib2 import math #################################################################### ## TODO: Replace this function by another one, which simply reads all lines from a file #########################################################...
27.030928
88
0.558734
0
0
0
0
0
0
0
0
873
0.332952
5731a1d1075f24d7e3e476ce3662c03caca1f970
1,786
py
Python
files_to_html_md5.py
jasonivey/scripts
09f9702e5ce62abbb7699aae16b45b33711fe856
[ "MIT" ]
null
null
null
files_to_html_md5.py
jasonivey/scripts
09f9702e5ce62abbb7699aae16b45b33711fe856
[ "MIT" ]
null
null
null
files_to_html_md5.py
jasonivey/scripts
09f9702e5ce62abbb7699aae16b45b33711fe856
[ "MIT" ]
null
null
null
import os import sys import hash_utils def StartIndexPhp(outfile): outfile.write( '<?php $rootdirectory = \'../../\' ?>\n\n' ) outfile.write( '<html>\n' ) outfile.write( '<head>\n' ) outfile.write( '\t<meta http-equiv="Content-Type" content="text/html; charset=utf-8">\n' ) outfile.write( '...
43.560976
133
0.526316
0
0
0
0
0
0
0
0
732
0.409854
573671e14e06512a6056d7ef96ce655d220e4a19
2,857
py
Python
Run_exphydro_distributed_type1_pso.py
sopanpatil/exp-hydro
7295dddc4df1028f669a223e1b631a4a91669515
[ "MIT" ]
11
2016-11-25T13:05:26.000Z
2022-03-25T03:24:16.000Z
Run_exphydro_distributed_type1_pso.py
sopanpatil/exp-hydro
7295dddc4df1028f669a223e1b631a4a91669515
[ "MIT" ]
null
null
null
Run_exphydro_distributed_type1_pso.py
sopanpatil/exp-hydro
7295dddc4df1028f669a223e1b631a4a91669515
[ "MIT" ]
6
2017-03-28T12:06:00.000Z
2021-09-16T17:50:34.000Z
#!/usr/bin/env python # Programmer(s): Sopan Patil. """ MAIN PROGRAM FILE Run this file to optimise the model parameters of the spatially distributed version of EXP-HYDRO model using Particle Swarm Optimisation (PSO) algorithm. Type 1 Model: - This type of distributed model is pixel based (i.e., all sub-components h...
35.7125
119
0.716136
0
0
0
0
0
0
0
0
1,797
0.628981
5738d01ad1ed866e8e47c9a1f5dadbf2cfce3611
11,104
py
Python
multi_input_multi_output/train.py
alt113/CS591-Multimodal-Spring2021
f28bade729818aa51fd131e86f1ba2271cca8947
[ "MIT" ]
null
null
null
multi_input_multi_output/train.py
alt113/CS591-Multimodal-Spring2021
f28bade729818aa51fd131e86f1ba2271cca8947
[ "MIT" ]
1
2021-05-03T18:59:43.000Z
2021-05-03T19:04:19.000Z
multi_input_multi_output/train.py
alt113/CS591-Multimodal-Spring2021
f28bade729818aa51fd131e86f1ba2271cca8947
[ "MIT" ]
null
null
null
import os from multi_input_multi_output.models import MultiNet from shared_weights.helpers import config, utils from shared_weights.helpers.siamese_network import create_encoder from data.data_tf import fat_dataset import tensorflow as tf from tensorflow import keras # ---------------------- def flatten_model(mode...
40.525547
132
0.665616
3,696
0.332853
0
0
67
0.006034
0
0
2,625
0.236401
573a1fa313f96c01ab6df0ada017abeca301701e
856
py
Python
tools/rebuild_caches.py
newbdoc/lookyloo
53a8952fccaf9ae42fa582d3475283babd55d08a
[ "BSD-3-Clause" ]
148
2020-06-14T06:55:42.000Z
2022-03-19T05:37:02.000Z
tools/rebuild_caches.py
newbdoc/lookyloo
53a8952fccaf9ae42fa582d3475283babd55d08a
[ "BSD-3-Clause" ]
261
2020-06-16T22:29:27.000Z
2022-03-31T10:40:52.000Z
tools/rebuild_caches.py
newbdoc/lookyloo
53a8952fccaf9ae42fa582d3475283babd55d08a
[ "BSD-3-Clause" ]
27
2020-06-08T12:28:33.000Z
2022-02-15T18:50:50.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import argparse import logging from lookyloo.lookyloo import Indexing, Lookyloo logging.basicConfig(format='%(asctime)s %(name)s %(levelname)s:%(message)s', level=logging.INFO) def main(): parser = argparse.ArgumentParser(description='Rebuild t...
25.939394
168
0.684579
0
0
0
0
0
0
0
0
291
0.339953
573ad54818708562c075e93c746dc4448d743b12
740
py
Python
save_restore_model/tf1/restore1_1.py
zlpmichelle/crackingtensorflow
66c3517b60c3793ef06f904e5d58e4d044628182
[ "Apache-2.0" ]
3
2017-10-19T23:41:26.000Z
2019-10-22T08:59:35.000Z
save_restore_model/tf1/restore1_1.py
zlpmichelle/crackingtensorflow
66c3517b60c3793ef06f904e5d58e4d044628182
[ "Apache-2.0" ]
null
null
null
save_restore_model/tf1/restore1_1.py
zlpmichelle/crackingtensorflow
66c3517b60c3793ef06f904e5d58e4d044628182
[ "Apache-2.0" ]
null
null
null
import tensorflow as tf sess=tf.Session() #First let's load meta graph and restore weights saver = tf.train.import_meta_graph('/Users/lipingzhang/Downloads/model/my_tf_model-1000.meta') saver.restore(sess,tf.train.latest_checkpoint('/Users/lipingzhang/Downloads/model/')) # Now, let's access and create placeholders v...
30.833333
94
0.777027
0
0
0
0
0
0
0
0
356
0.481081
573b50d93fdcd613c5e4eb9cd5d3608413327c07
633
py
Python
src/game.py
LuisMarques99/Number-Guesser-Terminal
6abfac23268022f7ce3776a20d1d6f550955d6c8
[ "MIT" ]
null
null
null
src/game.py
LuisMarques99/Number-Guesser-Terminal
6abfac23268022f7ce3776a20d1d6f550955d6c8
[ "MIT" ]
null
null
null
src/game.py
LuisMarques99/Number-Guesser-Terminal
6abfac23268022f7ce3776a20d1d6f550955d6c8
[ "MIT" ]
null
null
null
from random import randrange def main(): MIN = 1 MAX = 100 NUMBER = randrange(MIN, MAX + 1) guesses = 9 print(f"Guess a number from {MIN} to {MAX}.\nYou have {guesses} chances. Start now!\n") while guesses > 0: guess = input(f"Guess ({guesses}): ") guesses -= 1 try: guess = int(guess) if guess == ...
21.827586
90
0.624013
0
0
0
0
0
0
0
0
248
0.391785
573b7032640a85abec559a72d8a9edcb24834621
378
py
Python
Data Structures and Algorithms/HackerRank Algo Solutions/EASY PROBLEMS/Arrays.py
akkik04/Python-DataStructures-and-Algorithms
8db63173218e5a9205dbb325935c71fec93b695c
[ "MIT" ]
1
2022-01-22T18:19:07.000Z
2022-01-22T18:19:07.000Z
Data Structures and Algorithms/HackerRank Algo Solutions/EASY PROBLEMS/Arrays.py
akkik04/Python-DataStructures-and-Algorithms
8db63173218e5a9205dbb325935c71fec93b695c
[ "MIT" ]
null
null
null
Data Structures and Algorithms/HackerRank Algo Solutions/EASY PROBLEMS/Arrays.py
akkik04/Python-DataStructures-and-Algorithms
8db63173218e5a9205dbb325935c71fec93b695c
[ "MIT" ]
null
null
null
# ARRAYS-DS HACKERANK SOLUTION: # creating a function to reverse the array. def reverseArray(arr): # reversing the array. reversed = arr[::-1] # returning the reversed array. return reversed # receiving input. arr_count = int(input().strip()) arr = list(map(int, input().rstrip().spl...
22.235294
47
0.653439
0
0
0
0
0
0
0
0
173
0.457672
573eb0d44cfa9120f4cdede91149047e20c421a4
1,456
py
Python
bmds_server/analysis/admin.py
shapiromatron/bmds-server
0b2b79b521728582fa66100621e9ea03e251f9f1
[ "MIT" ]
1
2019-07-09T16:42:15.000Z
2019-07-09T16:42:15.000Z
bmds_server/analysis/admin.py
shapiromatron/bmds-server
0b2b79b521728582fa66100621e9ea03e251f9f1
[ "MIT" ]
103
2016-11-14T15:58:53.000Z
2022-03-07T21:01:03.000Z
bmds_server/analysis/admin.py
shapiromatron/bmds-server
0b2b79b521728582fa66100621e9ea03e251f9f1
[ "MIT" ]
2
2017-03-17T20:43:22.000Z
2018-01-04T19:15:18.000Z
from django.contrib import admin from django.contrib.admin import SimpleListFilter from django.db.models import TextChoices from django.utils.html import format_html from . import models class CustomQuerysetsFilter(SimpleListFilter): title = "custom" parameter_name = "custom" class CustomQuerysetChoices...
28.54902
97
0.691621
1,194
0.820055
0
0
791
0.543269
0
0
296
0.203297
573ec927838cc2f17f74c48d89acf3a9486bfe1d
96
py
Python
venv/lib/python3.8/site-packages/numpy/distutils/fcompiler/pg.py
Retraces/UkraineBot
3d5d7f8aaa58fa0cb8b98733b8808e5dfbdb8b71
[ "MIT" ]
2
2022-03-13T01:58:52.000Z
2022-03-31T06:07:54.000Z
venv/lib/python3.8/site-packages/numpy/distutils/fcompiler/pg.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
19
2021-11-20T04:09:18.000Z
2022-03-23T15:05:55.000Z
venv/lib/python3.8/site-packages/numpy/distutils/fcompiler/pg.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
null
null
null
/home/runner/.cache/pip/pool/34/e0/75/b2dceb8ef40c652edb20f4e059370015eddc8cdbde039f92ced519a83d
96
96
0.895833
0
0
0
0
0
0
0
0
0
0
5742d249cea7cefa19d4a4ea9010a2450f58aa8b
552
py
Python
03/00/0.py
pylangstudy/201801
eee9cfd2b370153359183d3c8f7fe117f4392142
[ "CC0-1.0" ]
null
null
null
03/00/0.py
pylangstudy/201801
eee9cfd2b370153359183d3c8f7fe117f4392142
[ "CC0-1.0" ]
null
null
null
03/00/0.py
pylangstudy/201801
eee9cfd2b370153359183d3c8f7fe117f4392142
[ "CC0-1.0" ]
null
null
null
#https://qiita.com/stkdev/items/a44976fb81ae90a66381 #import imaplib, re, email, six, dateutil.parser import imaplib, re, email email_default_encoding = 'iso-2022-jp' def main(): gmail = imaplib.IMAP4_SSL("imap.gmail.com") username = 'user' password = 'pass' gmail.login(username, password)#imaplib.erro...
32.470588
161
0.71558
0
0
0
0
0
0
0
0
353
0.598305
57452ea96aff7c8f3e31ad97f424bdd254f5bb63
5,468
py
Python
sql/filewalk.py
kylef-lab41/Redwood
c4e1c8284444b91246e52c165ea150eea23b26b9
[ "Apache-2.0" ]
null
null
null
sql/filewalk.py
kylef-lab41/Redwood
c4e1c8284444b91246e52c165ea150eea23b26b9
[ "Apache-2.0" ]
null
null
null
sql/filewalk.py
kylef-lab41/Redwood
c4e1c8284444b91246e52c165ea150eea23b26b9
[ "Apache-2.0" ]
null
null
null
import binascii import datetime import hashlib import mimetypes import os import re import struct import subprocess import sys import time import urllib import csv from Queue import Queue # 8 byte unique ID generator give a path. # - first five bytes are first five from sha1 of path name # - last 3 are the first t...
32.939759
211
0.602597
0
0
0
0
0
0
0
0
1,726
0.315655
574587d505f7c19dabd0452d40b6544e75b9a682
10,136
py
Python
processing_scripts/database_update/pokedex_entry.py
CorentG/Pokecube-Issues-and-Wiki
690af5d8499561f65f761fd49fbf5fc2bc85c4c3
[ "MIT" ]
24
2019-02-02T20:37:53.000Z
2022-02-09T13:51:41.000Z
processing_scripts/database_update/pokedex_entry.py
CorentG/Pokecube-Issues-and-Wiki
690af5d8499561f65f761fd49fbf5fc2bc85c4c3
[ "MIT" ]
671
2018-08-20T08:46:35.000Z
2022-03-26T00:11:43.000Z
processing_scripts/database_update/pokedex_entry.py
CorentG/Pokecube-Issues-and-Wiki
690af5d8499561f65f761fd49fbf5fc2bc85c4c3
[ "MIT" ]
68
2018-09-25T21:03:40.000Z
2022-02-25T19:59:51.000Z
import csv_loader import moves_names def getSingle(name, data, file, value): return data.get_info(name,value, expected_file=file, use_names_map=True)[file][0] def getExpYield(name, data): return int(getSingle(name, data,"pokemon" ,"base_experience")) def getHeight(name, data): return int(getSingle(name, d...
37.128205
120
0.530979
4,976
0.490923
0
0
0
0
0
0
1,959
0.193272
5746c4fc2776ee414b40d5372100f22e8a3258f4
25,539
py
Python
tests/test_add.py
open-contracting/kingfisher-views
7887610a144493f2ccd0d9a22cf43157dc180479
[ "BSD-3-Clause" ]
2
2019-02-19T16:15:19.000Z
2020-07-25T04:05:45.000Z
tests/test_add.py
open-contracting/kingfisher-views
7887610a144493f2ccd0d9a22cf43157dc180479
[ "BSD-3-Clause" ]
142
2019-03-11T15:14:22.000Z
2020-11-11T19:26:09.000Z
tests/test_add.py
open-contracting/kingfisher-views
7887610a144493f2ccd0d9a22cf43157dc180479
[ "BSD-3-Clause" ]
5
2019-04-11T14:11:10.000Z
2020-07-30T22:45:59.000Z
import datetime import decimal from unittest.mock import patch import pytest from click.testing import CliRunner from psycopg2 import sql from manage import SUMMARIES, cli, construct_where_fragment from tests import assert_bad_argument, assert_log_records, assert_log_running, fixture, noop command = 'add' TABLES = ...
40.092622
118
0.539958
0
0
0
0
23,799
0.931869
0
0
13,163
0.515408
57476587984e17ece720d64d289aa21890dba64a
3,520
py
Python
ReportGenerator.py
taarruunnnn/VAPT-Report-Generator-Vulnerability
8d618c7ddac4f6fe0cedd9fa39ff61805e06fa38
[ "MIT" ]
1
2020-11-30T18:09:40.000Z
2020-11-30T18:09:40.000Z
ReportGenerator.py
taarruunnnn/VAPT-Report-Generator-Vulnerability
8d618c7ddac4f6fe0cedd9fa39ff61805e06fa38
[ "MIT" ]
null
null
null
ReportGenerator.py
taarruunnnn/VAPT-Report-Generator-Vulnerability
8d618c7ddac4f6fe0cedd9fa39ff61805e06fa38
[ "MIT" ]
1
2020-09-16T20:51:18.000Z
2020-09-16T20:51:18.000Z
import os from docx import Document from docx.shared import Inches from docx import section from docx.enum.text import WD_ALIGN_PARAGRAPH from docx.shared import Pt from docx.shared import Cm from docx.shared import RGBColor import docx class Print_document(): def start_doc(self): self.docume...
31.711712
92
0.609091
3,272
0.929545
0
0
0
0
0
0
374
0.10625
5750825ae1de9236544f8dff0657979e541dfed6
764
py
Python
Season 06 - Files in Python/Episode 02 - Copying Files.py/Episode 02 - Copying Files.py
Pythobit/Python-tutorial
b0743eaa9c237c3578131ead1b3f2c295f11b7ee
[ "MIT" ]
3
2021-02-19T18:33:00.000Z
2021-08-03T14:56:50.000Z
Season 06 - Files in Python/Episode 02 - Copying Files.py/Episode 02 - Copying Files.py
barawalojas/Python-tutorial
3f4b2b073e421888b3d62ff634658317d9abcb9b
[ "MIT" ]
1
2021-07-10T14:37:57.000Z
2021-07-20T09:51:39.000Z
Season 06 - Files in Python/Episode 02 - Copying Files.py/Episode 02 - Copying Files.py
barawalojas/Python-tutorial
3f4b2b073e421888b3d62ff634658317d9abcb9b
[ "MIT" ]
1
2021-08-02T05:39:38.000Z
2021-08-02T05:39:38.000Z
# Copying files # Ask user for a list of 3 friends. # for each friend, we'll tell user whether they're nearby. # for each nearby friend, we'll save their name to `nearby_friends.txt`. friends = input('Enter three friends name(separated by commas): ').split(',') people = open('people.txt', 'r') people_nearby = [line.s...
27.285714
77
0.743455
0
0
0
0
0
0
0
0
360
0.471204
5750d5afb4b68c06b08670b53610fc887297a148
722
py
Python
beginner_contest/167/C.py
FGtatsuro/myatcoder
25a3123be6a6311e7d1c25394987de3e35575ff4
[ "MIT" ]
null
null
null
beginner_contest/167/C.py
FGtatsuro/myatcoder
25a3123be6a6311e7d1c25394987de3e35575ff4
[ "MIT" ]
null
null
null
beginner_contest/167/C.py
FGtatsuro/myatcoder
25a3123be6a6311e7d1c25394987de3e35575ff4
[ "MIT" ]
null
null
null
import sys input = sys.stdin.readline sys.setrecursionlimit(10 ** 7) n, m, x = map(int, input().split()) ca = [0] * n ca_sum = [0] * (m+1) for i in range(n): ca[i] = list(map(int, input().split())) for j in range(m+1): ca_sum[j] += ca[i][j] ans = 10 ** 10 for i in range(2 ** n): tmp = 0 tmp_ca...
21.235294
56
0.49723
0
0
0
0
0
0
0
0
10
0.01385
5752dc5277d06864407fc67287bd73391b57e2b0
923
py
Python
src/ProjectHeart/forms.py
LokotamaTheMastermind/secret-password-saver
e97f139b2cad9e1b0e9283079252d9a76764e3c1
[ "Unlicense" ]
null
null
null
src/ProjectHeart/forms.py
LokotamaTheMastermind/secret-password-saver
e97f139b2cad9e1b0e9283079252d9a76764e3c1
[ "Unlicense" ]
null
null
null
src/ProjectHeart/forms.py
LokotamaTheMastermind/secret-password-saver
e97f139b2cad9e1b0e9283079252d9a76764e3c1
[ "Unlicense" ]
null
null
null
from django import forms from .models import Passwords class PasswordsForm(forms.ModelForm): username = forms.CharField(widget=forms.TextInput( attrs={'class': 'uk-form-width-large uk-input uk-width-expand'}), required=False) email = forms.EmailField(widget=forms.TextInput( attrs={'class': 'uk...
43.952381
89
0.67714
865
0.937161
0
0
0
0
0
0
319
0.345612
57550dfdc85fef1e9e1bc0066478d7d691371d64
184
py
Python
data_relay/src/plugins/AzureBlob.py
phil-d-wilson/connectorV2
7077aa1c74276e8e334a8046793e942eec8d9975
[ "Apache-2.0" ]
null
null
null
data_relay/src/plugins/AzureBlob.py
phil-d-wilson/connectorV2
7077aa1c74276e8e334a8046793e942eec8d9975
[ "Apache-2.0" ]
49
2021-04-09T14:41:50.000Z
2021-07-28T10:54:48.000Z
data_relay/src/plugins/AzureBlob.py
phil-d-wilson/connectorV2
7077aa1c74276e8e334a8046793e942eec8d9975
[ "Apache-2.0" ]
2
2021-04-24T10:47:57.000Z
2021-07-17T07:13:00.000Z
NAME = "Azure BLOB storage" TYPE = "remote" FILE = "AzureBlob.yaml" VARS = [ "AZURE_BLOB_STORAGE_ACCOUNT", "AZURE_BLOB_STORAGE_ACCOUNT_KEY", "AZURE_BLOB_CONTAINER_NAME", ]
20.444444
37
0.717391
0
0
0
0
0
0
0
0
131
0.711957
5755b24aeb6ff531368ac2aba89c8fd019b3b452
8,965
py
Python
tests/application/test_helpers.py
alphagov-mirror/performanceplatform-admin
b63ae42b1276699623ef208b7d6edd3e0ce4ca59
[ "MIT" ]
1
2017-05-14T21:31:33.000Z
2017-05-14T21:31:33.000Z
tests/application/test_helpers.py
alphagov-mirror/performanceplatform-admin
b63ae42b1276699623ef208b7d6edd3e0ce4ca59
[ "MIT" ]
33
2015-01-05T12:23:45.000Z
2021-03-24T10:59:47.000Z
tests/application/test_helpers.py
alphagov-mirror/performanceplatform-admin
b63ae42b1276699623ef208b7d6edd3e0ce4ca59
[ "MIT" ]
4
2017-03-16T15:52:33.000Z
2021-04-10T20:14:53.000Z
import unittest from application import app from application.helpers import( requires_authentication, requires_feature, signed_in, group_by_group, signed_in_no_access, no_access, has_user_with_token, view_helpers, user_has_feature, ) from hamcrest import assert_that, equal_to, is_ fr...
37.19917
78
0.636587
8,621
0.961629
0
0
4,603
0.513441
0
0
1,696
0.18918
575730cc1be427336b55d40ef3a3e2821b465a72
1,210
py
Python
Unit 7/Ai bot/test bots/SlightlySmartSue.py
KevinBoxuGao/ICS3UI
2091a7c0276b888dd88f2063e6acd6e7ff7fb6fa
[ "MIT" ]
null
null
null
Unit 7/Ai bot/test bots/SlightlySmartSue.py
KevinBoxuGao/ICS3UI
2091a7c0276b888dd88f2063e6acd6e7ff7fb6fa
[ "MIT" ]
null
null
null
Unit 7/Ai bot/test bots/SlightlySmartSue.py
KevinBoxuGao/ICS3UI
2091a7c0276b888dd88f2063e6acd6e7ff7fb6fa
[ "MIT" ]
1
2020-03-09T16:22:33.000Z
2020-03-09T16:22:33.000Z
from random import * #STRATEGY SUMMARY: DON'T DUCK IF THE OPPONENT HAS NO SNOWBALLS. OTHERWISE, PICK RANDOMLY. def getMove( myScore, mySnowballs, myDucksUsed, myMovesSoFar, oppScore, oppSnowballs, oppDucksUsed, oppMovesSoFar ): if mySnowballs == 10: #I have 10 snowballs, so I must throw re...
31.842105
99
0.565289
0
0
0
0
0
0
0
0
528
0.436364
5757a45f92b96ddd746ba5a5bd686085a734073c
298
py
Python
customers/views/customers.py
chorna/taxi24
09e174a0cb3b9543ca4987e60cd0d37ecda6ac3c
[ "MIT" ]
null
null
null
customers/views/customers.py
chorna/taxi24
09e174a0cb3b9543ca4987e60cd0d37ecda6ac3c
[ "MIT" ]
null
null
null
customers/views/customers.py
chorna/taxi24
09e174a0cb3b9543ca4987e60cd0d37ecda6ac3c
[ "MIT" ]
null
null
null
from rest_framework import viewsets from customers.models import Customer from customers.serializers.customers import CustomerSerializer # Create your views here. class CustomerList(viewsets.ReadOnlyModelViewSet): queryset = Customer.objects.all() serializer_class = CustomerSerializer
24.833333
62
0.825503
130
0.436242
0
0
0
0
0
0
25
0.083893
57580cabba2c7dce9e5d8666af96b5e694af9738
5,370
py
Python
pysoa/test/plan/grammar/directives/expects_values.py
zetahernandez/pysoa
006e55ba877196a42c64f2ff453583d366082d55
[ "Apache-2.0" ]
91
2017-05-08T22:41:33.000Z
2022-02-09T11:37:07.000Z
pysoa/test/plan/grammar/directives/expects_values.py
zetahernandez/pysoa
006e55ba877196a42c64f2ff453583d366082d55
[ "Apache-2.0" ]
63
2017-06-14T20:08:49.000Z
2021-06-16T23:08:25.000Z
pysoa/test/plan/grammar/directives/expects_values.py
zetahernandez/pysoa
006e55ba877196a42c64f2ff453583d366082d55
[ "Apache-2.0" ]
26
2017-10-13T23:23:13.000Z
2022-01-11T16:58:17.000Z
""" Expect action directives """ from __future__ import ( absolute_import, unicode_literals, ) from pyparsing import ( CaselessLiteral, LineEnd, Literal, Optional, Suppress, ) from pysoa.test.plan.grammar.assertions import ( assert_not_expected, assert_not_present, assert_subse...
26.716418
115
0.60298
4,531
0.843762
0
0
1,815
0.337989
0
0
994
0.185102
575871e8030b4782c2b2ff33f329031a54131855
454
py
Python
src/manual/add_uuid_col.py
lshtm-gis/WHO_PHSM_Cleaning
5892673922fc555fb86d6e0be548b48c7dc66814
[ "MIT" ]
null
null
null
src/manual/add_uuid_col.py
lshtm-gis/WHO_PHSM_Cleaning
5892673922fc555fb86d6e0be548b48c7dc66814
[ "MIT" ]
123
2020-10-12T11:06:27.000Z
2021-04-28T15:32:29.000Z
src/manual/add_uuid_col.py
lshtm-gis/WHO_PHSM_Cleaning
5892673922fc555fb86d6e0be548b48c7dc66814
[ "MIT" ]
null
null
null
''' Script to add uuid to existing records Also shifts who_code values to original_who_code ''' import uuid import pandas as pd manually_cleaned = pd.read_csv('data/cleansed/mistress_latest_old.csv', low_memory=False) manually_cleaned['uuid'] = [str(uuid.uuid4()) for x in manually_cleaned.iloc[:, 1]] manually_cle...
25.222222
89
0.779736
0
0
0
0
0
0
0
0
207
0.455947
575a4a3127b8298acd5fe22aa043d391fe755667
1,821
py
Python
tests/test_qml.py
phil65/PrettyQt
26327670c46caa039c9bd15cb17a35ef5ad72e6c
[ "MIT" ]
7
2019-05-01T01:34:36.000Z
2022-03-08T02:24:14.000Z
tests/test_qml.py
phil65/PrettyQt
26327670c46caa039c9bd15cb17a35ef5ad72e6c
[ "MIT" ]
141
2019-04-16T11:22:01.000Z
2021-04-14T15:12:36.000Z
tests/test_qml.py
phil65/PrettyQt
26327670c46caa039c9bd15cb17a35ef5ad72e6c
[ "MIT" ]
5
2019-04-17T11:48:19.000Z
2021-11-21T10:30:19.000Z
"""Tests for `prettyqt` package.""" import pathlib import pytest from prettyqt import core, qml from prettyqt.utils import InvalidParamError # def test_jsvalue(): # val = qml.JSValue(2) # val["test"] = 1 # assert val["test"].toInt() == 1 # assert "test" in val # assert val.get_value() == 2 de...
24.945205
59
0.641406
0
0
0
0
0
0
0
0
358
0.196595
9386838c937de37405273fac5771d31ccf1a0479
2,550
py
Python
demo.py
HsienYu/tree_demo
aa2fa6c016b3ea5c1e768baa8ce4ea319c727bfc
[ "Artistic-2.0" ]
null
null
null
demo.py
HsienYu/tree_demo
aa2fa6c016b3ea5c1e768baa8ce4ea319c727bfc
[ "Artistic-2.0" ]
null
null
null
demo.py
HsienYu/tree_demo
aa2fa6c016b3ea5c1e768baa8ce4ea319c727bfc
[ "Artistic-2.0" ]
null
null
null
# Simple test for NeoPixels on Raspberry Pi import time import board import neopixel # Choose an open pin connected to the Data In of the NeoPixel strip, i.e. board.D18 # NeoPixels must be connected to D10, D12, D18 or D21 to work. pixel_pin = board.D18 # The number of NeoPixels num_pixels = 30 # The order of the p...
25.757576
92
0.533333
0
0
0
0
0
0
0
0
847
0.332157
93880a88a41dae3cf1a05e55925780f80609dbdb
1,774
py
Python
fsm.py
yusun1997/Chatbot
ee49d4a64857889ce1d1a8659a1de15cf062bd77
[ "MIT" ]
null
null
null
fsm.py
yusun1997/Chatbot
ee49d4a64857889ce1d1a8659a1de15cf062bd77
[ "MIT" ]
null
null
null
fsm.py
yusun1997/Chatbot
ee49d4a64857889ce1d1a8659a1de15cf062bd77
[ "MIT" ]
null
null
null
from transitions.extensions import GraphMachine class TocMachine(GraphMachine): def __init__(self, **machine_configs): self.machine = GraphMachine( model = self, **machine_configs ) def is_going_to_state1(self, update): text = update.message.text return...
27.71875
89
0.638106
1,723
0.971251
0
0
0
0
0
0
225
0.126832
93881978c162edde4ca5dd970ae7fc5d1d4dfecc
1,861
py
Python
rptk/query/__init__.py
wolcomm/rptk
fe6c1b597741ff14e4c89519458bb0950f0aa955
[ "Apache-2.0" ]
15
2017-11-30T01:28:11.000Z
2021-08-12T09:17:36.000Z
rptk/query/__init__.py
wolcomm/rptk
fe6c1b597741ff14e4c89519458bb0950f0aa955
[ "Apache-2.0" ]
71
2018-06-22T09:54:50.000Z
2020-10-21T07:10:54.000Z
rptk/query/__init__.py
wolcomm/rptk
fe6c1b597741ff14e4c89519458bb0950f0aa955
[ "Apache-2.0" ]
2
2019-08-31T20:45:19.000Z
2019-10-02T18:26:58.000Z
# Copyright (c) 2018 Workonline Communications (Pty) Ltd. All rights reserved. # # The contents of this file are licensed under the Apache License version 2.0 # (the "License"); you may not use this file except in compliance with the # License. # # Unless required by applicable law or agreed to in writing, software # d...
27.776119
79
0.667383
1,034
0.555615
318
0.170876
381
0.204729
0
0
868
0.466416
93888830e4d4bc95cb50e37baa9660d706afdc8a
1,697
py
Python
test/__main__.py
harisekhon/pylib
1d8fcfc0a26251a832536a5ff6bf0ef618b8508e
[ "MIT" ]
1
2015-12-17T21:08:22.000Z
2015-12-17T21:08:22.000Z
test/__main__.py
harisekhon/pylib
1d8fcfc0a26251a832536a5ff6bf0ef618b8508e
[ "MIT" ]
null
null
null
test/__main__.py
harisekhon/pylib
1d8fcfc0a26251a832536a5ff6bf0ef618b8508e
[ "MIT" ]
null
null
null
#!/usr/bin/env python # vim:ts=4:sts=4:sw=4:et # # Author: Hari Sekhon # Date: 2015-11-14 12:21:54 +0000 (Sat, 14 Nov 2015) # # https://github.com/HariSekhon/pylib # # License: see accompanying Hari Sekhon LICENSE file # # If you're using my code you're welcome to connect with me on LinkedIn # and optionally sen...
28.283333
88
0.700648
0
0
0
0
0
0
0
0
1,130
0.665881