hexsha
stringlengths
40
40
size
int64
7
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
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
247
max_issues_repo_name
stringlengths
4
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
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
247
max_forks_repo_name
stringlengths
4
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
1
1.04M
avg_line_length
float64
1.77
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
7
1.04M
filtered:remove_function_no_docstring
int64
-102
942k
filtered:remove_class_no_docstring
int64
-354
977k
filtered:remove_delete_markers
int64
0
60.1k
e5bd9846792ca0380e9358b95728eb11553310f8
1,887
py
Python
bot.py
liamkirsh/FBChatBot
59eafee2c78f2d6a93c38a74fecf1a4d311a00e9
[ "MIT" ]
3
2017-07-23T20:10:19.000Z
2020-09-23T21:21:47.000Z
bot.py
liamkirsh/FBChatBot
59eafee2c78f2d6a93c38a74fecf1a4d311a00e9
[ "MIT" ]
1
2018-03-06T05:34:07.000Z
2018-03-07T19:51:18.000Z
bot.py
liamkirsh/FBChatBot
59eafee2c78f2d6a93c38a74fecf1a4d311a00e9
[ "MIT" ]
null
null
null
from collections import namedtuple from fbchat import Client from fbchat.models import ThreadType
38.510204
88
0.598304
from collections import namedtuple from fbchat import Client from fbchat.models import ThreadType class Bot(Client): Command = namedtuple('Command', ['func', 'admin', 'directed']) def __init__(self, email, password, name, admins=[], protected=[], *args, **kwargs): super(Bot, self).__init__(email=ema...
1,181
583
23
02aff8181b0dbece1ea2d0164648a1afb779ca20
170
py
Python
lesson3/practice/ex3.py
karina-marques/programming-exercises
ecce7ed3fee02b717bff8e4b8405ea65a574d93b
[ "MIT" ]
null
null
null
lesson3/practice/ex3.py
karina-marques/programming-exercises
ecce7ed3fee02b717bff8e4b8405ea65a574d93b
[ "MIT" ]
null
null
null
lesson3/practice/ex3.py
karina-marques/programming-exercises
ecce7ed3fee02b717bff8e4b8405ea65a574d93b
[ "MIT" ]
null
null
null
# Write here the test case for 'celsius_to_kelvin' function import lesson3_module x = float(input('Temperature in ºC:')) print(lesson3_module.celsius_to_kelvin(x), 'K')
28.333333
59
0.776471
# Write here the test case for 'celsius_to_kelvin' function import lesson3_module x = float(input('Temperature in ºC:')) print(lesson3_module.celsius_to_kelvin(x), 'K')
0
0
0
cec2d410c5f912bc216b0b0c406a6e81843c237f
1,344
py
Python
bot/platforms/vk/commands/menu/menu.py
AiratK/kaishnik-bot
c42351611a40a04d78c8ae481b97339adbd321e5
[ "MIT" ]
15
2019-04-30T14:37:15.000Z
2022-02-09T06:43:00.000Z
bot/platforms/vk/commands/menu/menu.py
AiratK/kaishnik-bot
c42351611a40a04d78c8ae481b97339adbd321e5
[ "MIT" ]
4
2019-03-18T06:09:38.000Z
2021-12-10T06:12:26.000Z
bot/platforms/vk/commands/menu/menu.py
AiratK/kaishnik-bot
c42351611a40a04d78c8ae481b97339adbd321e5
[ "MIT" ]
2
2020-04-12T10:31:52.000Z
2021-06-07T20:18:08.000Z
from vkwave.bots import SimpleBotEvent from vkwave.bots import PayloadFilter from bot.platforms.vk import vk_bot from bot.platforms.vk import states from bot.platforms.vk import guards from bot.platforms.vk.utilities.keyboards import menu from bot.platforms.vk.utilities.keyboards import additional_menu from bot.platf...
33.6
82
0.774554
from vkwave.bots import SimpleBotEvent from vkwave.bots import PayloadFilter from bot.platforms.vk import vk_bot from bot.platforms.vk import states from bot.platforms.vk import guards from bot.platforms.vk.utilities.keyboards import menu from bot.platforms.vk.utilities.keyboards import additional_menu from bot.platf...
388
0
44
3cf86ebe0b484806063d2c27915307b660d5121a
834
py
Python
pyfrcsim/types/relay.py
ariovistus/pyfrcsim
a95a3723abdadceaf4fc2ce9ac65e88de54c40ee
[ "BSD-3-Clause" ]
null
null
null
pyfrcsim/types/relay.py
ariovistus/pyfrcsim
a95a3723abdadceaf4fc2ce9ac65e88de54c40ee
[ "BSD-3-Clause" ]
1
2016-11-26T17:58:25.000Z
2016-11-27T20:04:59.000Z
pyfrcsim/types/relay.py
ariovistus/pyfrcsim
a95a3723abdadceaf4fc2ce9ac65e88de54c40ee
[ "BSD-3-Clause" ]
null
null
null
import logging from ..main_node import advertise from ..gazebo.gz_msgs.float64_pb2 import Float64 logger = logging.getLogger(__name__)
26.0625
75
0.619904
import logging from ..main_node import advertise from ..gazebo.gz_msgs.float64_pb2 import Float64 logger = logging.getLogger(__name__) class SimRelay: def __init__(self, channel, relay_dict): self.relay_dict = relay_dict self.publisher = advertise('simulator/relay/%s' % channel, Float64...
624
-6
77
11ce799861d7e0cdc3ceff7db0d0f1a5a0e6d214
4,035
py
Python
vrft/utils.py
alexberndt/PythonVRFT
b70b6fe48eb58a1f2d64b07f655ad478461dde37
[ "MIT" ]
3
2020-01-11T09:31:43.000Z
2021-01-08T07:33:25.000Z
vrft/utils.py
alexberndt/PythonVRFT
b70b6fe48eb58a1f2d64b07f655ad478461dde37
[ "MIT" ]
27
2017-03-27T07:26:28.000Z
2021-01-10T15:40:36.000Z
vrft/utils.py
alexberndt/PythonVRFT
b70b6fe48eb58a1f2d64b07f655ad478461dde37
[ "MIT" ]
1
2021-01-08T17:09:30.000Z
2021-01-08T17:09:30.000Z
# utils.py - VRFT utility functions # # Code author: [Alessio Russo - alessior@kth.se] # Last update: 10th January 2021, by alessior@kth.se # # Copyright (c) [2017-2021] Alessio Russo [alessior@kth.se]. All rights reserved. # This file is part of PythonVRFT. # PythonVRFT is free software: you can redistribute it and/or...
27.827586
88
0.624287
# utils.py - VRFT utility functions # # Code author: [Alessio Russo - alessior@kth.se] # Last update: 10th January 2021, by alessior@kth.se # # Copyright (c) [2017-2021] Alessio Russo [alessior@kth.se]. All rights reserved. # This file is part of PythonVRFT. # PythonVRFT is free software: you can redistribute it and/or...
0
0
0
4f10e9885b97434f0d74a6f55b52baad89d96495
1,835
py
Python
tf1x/data/tinyImages.py
dpaiton/DeepSparseCoding
5ea01fa8770794df5e13743aa3f2d85297c27eb1
[ "MIT" ]
12
2017-04-27T17:19:31.000Z
2021-11-07T03:37:59.000Z
tf1x/data/tinyImages.py
dpaiton/DeepSparseCoding
5ea01fa8770794df5e13743aa3f2d85297c27eb1
[ "MIT" ]
12
2018-03-21T01:16:25.000Z
2022-02-10T00:21:58.000Z
tf1x/data/tinyImages.py
dpaiton/DeepSparseCoding
5ea01fa8770794df5e13743aa3f2d85297c27eb1
[ "MIT" ]
12
2017-02-01T19:49:57.000Z
2021-12-08T03:16:58.000Z
import numpy as np from DeepSparseCoding.tf1x.data.dataset import Dataset import DeepSparseCoding.tf1x.utils.plot_functions as pf
45.875
99
0.745504
import numpy as np from DeepSparseCoding.tf1x.data.dataset import Dataset import DeepSparseCoding.tf1x.utils.plot_functions as pf class tinyImages(object): def __init__(self, image_dir, num_epochs=1, epoch_size=1000, rand_state=np.random.RandomState()): self.total_num_images = num_epochs * epoch_size self.i...
1,605
4
95
249739bfc9ec89f7c5665de18e1f4059fe63663f
2,434
py
Python
preproc/EOG_fix.py
athiede13/free_speech
bde32c2d48724c98f089376876cf9888f67a9f20
[ "MIT" ]
null
null
null
preproc/EOG_fix.py
athiede13/free_speech
bde32c2d48724c98f089376876cf9888f67a9f20
[ "MIT" ]
null
null
null
preproc/EOG_fix.py
athiede13/free_speech
bde32c2d48724c98f089376876cf9888f67a9f20
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ EOG channel assignment/fix. - read all preprocessed files - check whether EOG channels are correctly assigned - fix EOG assignment if not - save with '_EOG' extension Created on Mon Jan 8 15:55:09 2018 @author: Anja Thiede <anja.thiede@helsinki.fi> """ import os from os import walk import ...
36.328358
89
0.599425
# -*- coding: utf-8 -*- """ EOG channel assignment/fix. - read all preprocessed files - check whether EOG channels are correctly assigned - fix EOG assignment if not - save with '_EOG' extension Created on Mon Jan 8 15:55:09 2018 @author: Anja Thiede <anja.thiede@helsinki.fi> """ import os from os import walk import ...
0
0
0
623914a0a59077dc1ca930778af269a6be214c5d
388
py
Python
src/aerochat/test/__init__.py
mpillar/aerofs-chat
d4bc18b9275a3148f631ae349a0eae9cff853993
[ "MIT" ]
null
null
null
src/aerochat/test/__init__.py
mpillar/aerofs-chat
d4bc18b9275a3148f631ae349a0eae9cff853993
[ "MIT" ]
null
null
null
src/aerochat/test/__init__.py
mpillar/aerofs-chat
d4bc18b9275a3148f631ae349a0eae9cff853993
[ "MIT" ]
null
null
null
import glob import unittest
35.272727
97
0.706186
import glob import unittest def create_test_suite(): test_file_strings = glob.glob('aerochat/test/test_*.py') module_strings = ['aerochat.test.'+s.split('/')[-1].split('.')[0] for s in test_file_strings] suites = [unittest.defaultTestLoader.loadTestsFromName(name) \ for name in module_strings...
337
0
23
128f59be0bf02ba1f5105f575b731eb827ba460f
3,496
py
Python
app/core/config.py
BrunoComitre/todo-fastapi-mongodb
f6033612cfebd4d2f19f9eab4e28eaa88a4ccfa1
[ "CNRI-Python", "RSA-MD" ]
null
null
null
app/core/config.py
BrunoComitre/todo-fastapi-mongodb
f6033612cfebd4d2f19f9eab4e28eaa88a4ccfa1
[ "CNRI-Python", "RSA-MD" ]
null
null
null
app/core/config.py
BrunoComitre/todo-fastapi-mongodb
f6033612cfebd4d2f19f9eab4e28eaa88a4ccfa1
[ "CNRI-Python", "RSA-MD" ]
null
null
null
import secrets import os import urllib.parse from dotenv import load_dotenv from starlette.datastructures import CommaSeparatedStrings from databases import DatabaseURL from urllib.parse import quote_plus from pydantic import BaseSettings API_V1_STR = "/api" load_dotenv(".env") MAX_CONNECTIONS_COUNT = int(os.gete...
43.7
110
0.794622
import secrets import os import urllib.parse from dotenv import load_dotenv from starlette.datastructures import CommaSeparatedStrings from databases import DatabaseURL from urllib.parse import quote_plus from pydantic import BaseSettings API_V1_STR = "/api" load_dotenv(".env") MAX_CONNECTIONS_COUNT = int(os.gete...
0
0
0
ba3297569bcbc853538116b1b98556f588500820
18
py
Python
test/__init__.py
MrBitBucket/preppy-mirror
9b2356a24069e531710f13313c2131ffcd37d469
[ "BSD-3-Clause" ]
null
null
null
test/__init__.py
MrBitBucket/preppy-mirror
9b2356a24069e531710f13313c2131ffcd37d469
[ "BSD-3-Clause" ]
null
null
null
test/__init__.py
MrBitBucket/preppy-mirror
9b2356a24069e531710f13313c2131ffcd37d469
[ "BSD-3-Clause" ]
null
null
null
#enables imports
9
17
0.777778
#enables imports
0
0
0
091168b2803391834ce3e7cd71d54bda15623b0a
94
py
Python
booking/apps.py
eedf/becours
95ac62b3d102ddbb16b01fe27fc32c98d1c40410
[ "MIT" ]
null
null
null
booking/apps.py
eedf/becours
95ac62b3d102ddbb16b01fe27fc32c98d1c40410
[ "MIT" ]
null
null
null
booking/apps.py
eedf/becours
95ac62b3d102ddbb16b01fe27fc32c98d1c40410
[ "MIT" ]
null
null
null
from django.apps import AppConfig
15.666667
33
0.765957
from django.apps import AppConfig class BookingConfig(AppConfig): name = 'Réservations'
0
37
23
569d38994265895d566b44cc2ef2672f4f5e8428
3,447
py
Python
config/m600/monitor/landing_zone.py
leozz37/makani
c94d5c2b600b98002f932e80a313a06b9285cc1b
[ "Apache-2.0" ]
1,178
2020-09-10T17:15:42.000Z
2022-03-31T14:59:35.000Z
config/m600/monitor/landing_zone.py
leozz37/makani
c94d5c2b600b98002f932e80a313a06b9285cc1b
[ "Apache-2.0" ]
1
2020-05-22T05:22:35.000Z
2020-05-22T05:22:35.000Z
config/m600/monitor/landing_zone.py
leozz37/makani
c94d5c2b600b98002f932e80a313a06b9285cc1b
[ "Apache-2.0" ]
107
2020-09-10T17:29:30.000Z
2022-03-18T09:00:14.000Z
# Copyright 2020 Makani Technologies LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
38.730337
80
0.644909
# Copyright 2020 Makani Technologies LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
2,733
0
22
3c896fd68ffa65179c436a507ddcb557ccb2edc4
361
py
Python
aether-odk-module/aether/odk/api/migrations/0101_xform_unique_index.py
eHealthAfrica/aether
6845d7eeebd4ae57332f73d74db3617e00032204
[ "Apache-2.0" ]
14
2018-08-09T20:57:16.000Z
2020-10-11T12:22:18.000Z
aether-odk-module/aether/odk/api/migrations/0101_xform_unique_index.py
eHealthAfrica/aether
6845d7eeebd4ae57332f73d74db3617e00032204
[ "Apache-2.0" ]
148
2018-07-24T10:52:29.000Z
2022-02-10T09:06:44.000Z
aether-odk-module/aether/odk/api/migrations/0101_xform_unique_index.py
eHealthAfrica/aether
6845d7eeebd4ae57332f73d74db3617e00032204
[ "Apache-2.0" ]
6
2018-07-25T13:33:10.000Z
2019-09-23T03:02:09.000Z
# Generated by Django 2.2.3 on 2019-07-24 15:08 from django.db import migrations
20.055556
64
0.595568
# Generated by Django 2.2.3 on 2019-07-24 15:08 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('odk', '0100_initial_squashed'), ] operations = [ migrations.AlterUniqueTogether( name='xform', unique_together={('project', ...
0
255
23
d77d8eda6dabe7639080931dced891bebc2e6fe5
714
py
Python
tests/test_table_enforcer.py
xguse/table_enforcer
f3137839574bf8ea933a14ea16a8acba45e3e0c3
[ "MIT" ]
13
2017-11-16T23:24:17.000Z
2021-05-28T01:05:31.000Z
tests/test_table_enforcer.py
xguse/table_enforcer
f3137839574bf8ea933a14ea16a8acba45e3e0c3
[ "MIT" ]
1
2019-09-26T18:34:21.000Z
2021-10-12T17:18:24.000Z
tests/test_table_enforcer.py
xguse/table_enforcer
f3137839574bf8ea933a14ea16a8acba45e3e0c3
[ "MIT" ]
1
2017-11-17T17:18:31.000Z
2017-11-17T17:18:31.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """Tests for `table_enforcer` package.""" import pytest from .conftest import TABLE_PATH_1, TABLE_PATH_2 from . import Usage_Demo as ud from table_enforcer.errors import ValidationError, RecodingError from table_enforcer import Column, Enforcer
25.5
64
0.759104
#!/usr/bin/env python # -*- coding: utf-8 -*- """Tests for `table_enforcer` package.""" import pytest from .conftest import TABLE_PATH_1, TABLE_PATH_2 from . import Usage_Demo as ud from table_enforcer.errors import ValidationError, RecodingError from table_enforcer import Column, Enforcer def test_basic(): ud....
326
0
92
4af9fdad2a669fe44b6281c40a0452f218deb856
1,552
py
Python
selfdrive/test/tests/process_replay/compare_logs.py
iambluefred/Test_2
87de20745dfc918a639aca42d7ef167a1b4e2a63
[ "MIT" ]
null
null
null
selfdrive/test/tests/process_replay/compare_logs.py
iambluefred/Test_2
87de20745dfc918a639aca42d7ef167a1b4e2a63
[ "MIT" ]
null
null
null
selfdrive/test/tests/process_replay/compare_logs.py
iambluefred/Test_2
87de20745dfc918a639aca42d7ef167a1b4e2a63
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 import bz2 import os import sys import dictdiffer if "CI" in os.environ: tqdm = lambda x: x else: from tqdm import tqdm from tools.lib.logreader import LogReader if __name__ == "__main__": log1 = list(LogReader(sys.argv[1])) log2 = list(LogReader(sys.argv[2])) compare_logs(log1, log2...
25.032258
83
0.653351
#!/usr/bin/env python2 import bz2 import os import sys import dictdiffer if "CI" in os.environ: tqdm = lambda x: x else: from tqdm import tqdm from tools.lib.logreader import LogReader def save_log(dest, log_msgs): dat = "" for msg in log_msgs: dat += msg.as_builder().to_bytes() dat = bz2.compress(dat)...
1,147
0
69
9417b7e1f6a97193c09d7f3d61f0efaf43168bca
584
py
Python
newsme/NewsReader.py
lunfman/NewsMe
c429b7c143c69dfb5b8c3f17e91cfd8ef1be96f4
[ "MIT" ]
null
null
null
newsme/NewsReader.py
lunfman/NewsMe
c429b7c143c69dfb5b8c3f17e91cfd8ef1be96f4
[ "MIT" ]
null
null
null
newsme/NewsReader.py
lunfman/NewsMe
c429b7c143c69dfb5b8c3f17e91cfd8ef1be96f4
[ "MIT" ]
null
null
null
from html_creator import CreateHtml from get_news import GetNews from mail import ShareNews topics = ['github'] key = 'api_key' news = GetNews(key) news.articles_num = 1 create_html = CreateHtml() sender = ShareNews( mail='mail', password='pass', destination='to', smtp_server='smtp') for topic in topic...
18.83871
48
0.695205
from html_creator import CreateHtml from get_news import GetNews from mail import ShareNews topics = ['github'] key = 'api_key' news = GetNews(key) news.articles_num = 1 create_html = CreateHtml() sender = ShareNews( mail='mail', password='pass', destination='to', smtp_server='smtp') for topic in topic...
0
0
0
a96faaa762938e3365ab95589e023e3e7b6e16e0
1,404
py
Python
setup.py
Haikson/virtenviro-news
0ce85bace7308cbc009923e035cc95ede1641787
[ "Apache-2.0" ]
null
null
null
setup.py
Haikson/virtenviro-news
0ce85bace7308cbc009923e035cc95ede1641787
[ "Apache-2.0" ]
null
null
null
setup.py
Haikson/virtenviro-news
0ce85bace7308cbc009923e035cc95ede1641787
[ "Apache-2.0" ]
null
null
null
from distutils.core import setup from setuptools import find_packages, setup EXCLUDE_FROM_PACKAGES = [] setup( name='virtenviro-news', version="0.1.0" packages=find_packages(exclude=EXCLUDE_FROM_PACKAGES), include_package_data=True, url='http://www.virtenviro.org/', license='GPL3', author...
31.909091
71
0.60755
from distutils.core import setup from setuptools import find_packages, setup EXCLUDE_FROM_PACKAGES = [] setup( name='virtenviro-news', version="0.1.0" packages=find_packages(exclude=EXCLUDE_FROM_PACKAGES), include_package_data=True, url='http://www.virtenviro.org/', license='GPL3', author...
0
0
0
8ab55b8dba729af539f49920abaf3d8baa14945f
748
py
Python
blueprints/home_blueprint.py
headwinds/flask-now-postgres-offline
83420250c26dd3b2bcdfaed95fb310deccbd9db2
[ "MIT" ]
null
null
null
blueprints/home_blueprint.py
headwinds/flask-now-postgres-offline
83420250c26dd3b2bcdfaed95fb310deccbd9db2
[ "MIT" ]
5
2019-12-21T00:23:05.000Z
2022-03-21T22:17:43.000Z
blueprints/home_blueprint.py
headwinds/forge
83420250c26dd3b2bcdfaed95fb310deccbd9db2
[ "MIT" ]
null
null
null
from flask import Blueprint, redirect, url_for, render_template, request, session, json from helpers.helpers_user import get_user, credentials_valid from forms.login_form import LoginForm home_blueprint = Blueprint("home", __name__) # -------- Home --------- # @home_blueprint.route('/home', methods=['GET']) @home_...
32.521739
87
0.688503
from flask import Blueprint, redirect, url_for, render_template, request, session, json from helpers.helpers_user import get_user, credentials_valid from forms.login_form import LoginForm home_blueprint = Blueprint("home", __name__) # -------- Home --------- # @home_blueprint.route('/home', methods=['GET']) def home...
340
0
44
196a0ef0fec551c61133dd8a06456a06a5cceae3
1,281
py
Python
bookstore/views.py
msabiloo/django-rest-framework-sample
f80420dc42725ea2ccd52c52280fb572a3a4c4c1
[ "MIT" ]
null
null
null
bookstore/views.py
msabiloo/django-rest-framework-sample
f80420dc42725ea2ccd52c52280fb572a3a4c4c1
[ "MIT" ]
4
2021-03-18T22:39:56.000Z
2021-09-22T18:22:28.000Z
bookstore/views.py
msabiloo/django-rest-framework-sample
f80420dc42725ea2ccd52c52280fb572a3a4c4c1
[ "MIT" ]
null
null
null
from .models import Book, Rating, Stock from .serializers import BookSerializer, RatingSerializer, StockSerializer from django.http import Http404 from rest_framework.views import APIView from rest_framework.response import Response from rest_framework import status from rest_framework import generics from rest_frame...
30.5
74
0.803279
from .models import Book, Rating, Stock from .serializers import BookSerializer, RatingSerializer, StockSerializer from django.http import Http404 from rest_framework.views import APIView from rest_framework.response import Response from rest_framework import status from rest_framework import generics from rest_frame...
0
822
115
3badb128bfd2e9778188437945375abc926b0df6
829
py
Python
adminApp/views.py
winsphinx/webApp
222c0877ed6f48d9c7939293c8ce83f274eb71b9
[ "MIT" ]
null
null
null
adminApp/views.py
winsphinx/webApp
222c0877ed6f48d9c7939293c8ce83f274eb71b9
[ "MIT" ]
null
null
null
adminApp/views.py
winsphinx/webApp
222c0877ed6f48d9c7939293c8ce83f274eb71b9
[ "MIT" ]
null
null
null
from django.contrib.auth import authenticate, login, logout from django.contrib.auth.forms import UserCreationForm from django.shortcuts import redirect, render # Create your views here.
33.16
73
0.636912
from django.contrib.auth import authenticate, login, logout from django.contrib.auth.forms import UserCreationForm from django.shortcuts import redirect, render # Create your views here. def logout_view(request): logout(request) return redirect('adminApp:login') def register_view(request): i...
584
0
48
a469b73d55c54797b226d12396d4906820bbf794
3,802
py
Python
dag_car_abandon.py
kspaler/teste-b2w
a6531d79a61fe638338b2904ba423baf2eb43e73
[ "MIT" ]
null
null
null
dag_car_abandon.py
kspaler/teste-b2w
a6531d79a61fe638338b2904ba423baf2eb43e73
[ "MIT" ]
null
null
null
dag_car_abandon.py
kspaler/teste-b2w
a6531d79a61fe638338b2904ba423baf2eb43e73
[ "MIT" ]
null
null
null
# Bibliotecas from datetime import datetime, timedelta from airflow import DAG from airflow.operators.python import PythonOperator from airflow.operators.bash_operator import BashOperator from airflow.utils.dates import days_ago import json import pandas as pd from pandas.io.json import json_normalize #package for ...
33.350877
164
0.670963
# Bibliotecas from datetime import datetime, timedelta from airflow import DAG from airflow.operators.python import PythonOperator from airflow.operators.bash_operator import BashOperator from airflow.utils.dates import days_ago import json import pandas as pd from pandas.io.json import json_normalize #package for ...
1,763
0
23
7b44456fe60b11c5fd7a657b04545e306469d581
644
py
Python
listusers.py
codingforhelp/fbserv
b09cc2ce20eaa3714e80d23e0f5741f144d2eed2
[ "MIT" ]
5
2019-01-31T08:09:53.000Z
2020-04-13T22:48:25.000Z
listusers.py
codingforhelp/fbserv
b09cc2ce20eaa3714e80d23e0f5741f144d2eed2
[ "MIT" ]
2
2021-04-30T21:04:37.000Z
2021-06-01T23:42:18.000Z
listusers.py
codingforhelp/fbserv
b09cc2ce20eaa3714e80d23e0f5741f144d2eed2
[ "MIT" ]
3
2019-08-04T07:51:58.000Z
2022-02-25T13:39:30.000Z
import firebase_admin from firebase_admin import credentials, auth from time import sleep from utils.ansi import pretty, brightwhite cred = credentials.Certificate('firebase/fbsacckey.json') firebase_admin.initialize_app(cred) page = auth.list_users() while page: for user in page.users: uid = user.uid ...
28
57
0.630435
import firebase_admin from firebase_admin import credentials, auth from time import sleep from utils.ansi import pretty, brightwhite cred = credentials.Certificate('firebase/fbsacckey.json') firebase_admin.initialize_app(cred) page = auth.list_users() while page: for user in page.users: uid = user.uid ...
0
0
0
72a88074275fbcdd24c13a6b972d526580f090ff
1,979
py
Python
_site/tomat/apps/uploads/views.py
Lisaveta-K/lisaveta-k.github.io
96306c4d2634d62e6d0ac504aee8ca91f8b3de11
[ "MIT" ]
null
null
null
_site/tomat/apps/uploads/views.py
Lisaveta-K/lisaveta-k.github.io
96306c4d2634d62e6d0ac504aee8ca91f8b3de11
[ "MIT" ]
null
null
null
_site/tomat/apps/uploads/views.py
Lisaveta-K/lisaveta-k.github.io
96306c4d2634d62e6d0ac504aee8ca91f8b3de11
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import datetime import uuid import os.path from django.http import HttpResponseForbidden, HttpResponse from django.core.files.storage import default_storage from django.views.decorators.csrf import csrf_exempt from pytils.translit import slugify from uploads.forms import ImageForm, FileForm f...
28.681159
70
0.641233
# -*- coding: utf-8 -*- import datetime import uuid import os.path from django.http import HttpResponseForbidden, HttpResponse from django.core.files.storage import default_storage from django.views.decorators.csrf import csrf_exempt from pytils.translit import slugify from uploads.forms import ImageForm, FileForm f...
1,410
0
44
8312cb7f707052fbf9521d5c81de8b48994e1506
3,064
py
Python
fivetran_provider/example_dags/example_fivetran_bigquery.py
PubChimps/airflow-provider-fivetran-1
f84f3fd72356ea453361af4ce8c40eabe5d1c733
[ "Apache-2.0" ]
21
2021-02-19T20:30:01.000Z
2022-01-26T21:53:25.000Z
fivetran_provider/example_dags/example_fivetran_bigquery.py
PubChimps/airflow-provider-fivetran-1
f84f3fd72356ea453361af4ce8c40eabe5d1c733
[ "Apache-2.0" ]
34
2021-02-23T02:13:47.000Z
2022-03-03T14:41:31.000Z
fivetran_provider/example_dags/example_fivetran_bigquery.py
PubChimps/airflow-provider-fivetran-1
f84f3fd72356ea453361af4ce8c40eabe5d1c733
[ "Apache-2.0" ]
13
2021-02-23T01:54:41.000Z
2022-01-04T12:05:25.000Z
from airflow import DAG, AirflowException from airflow.operators.dummy_operator import DummyOperator from airflow.providers.google.cloud.sensors.bigquery import BigQueryTableExistenceSensor from airflow.providers.google.cloud.operators.bigquery import BigQueryValueCheckOperator from fivetran_provider.operators.fivetran...
35.218391
88
0.70953
from airflow import DAG, AirflowException from airflow.operators.dummy_operator import DummyOperator from airflow.providers.google.cloud.sensors.bigquery import BigQueryTableExistenceSensor from airflow.providers.google.cloud.operators.bigquery import BigQueryValueCheckOperator from fivetran_provider.operators.fivetran...
0
0
0
96824fcd273669bdfbf6d1c9fecdd4182a791fcb
3,538
py
Python
src/core/tests/widgets/test_scrollcontainer.py
luizoti/toga
3c49e685f325f1aba2ce048b253402d7e4519f97
[ "BSD-3-Clause" ]
1,261
2019-03-31T16:28:47.000Z
2022-03-31T09:01:23.000Z
src/core/tests/widgets/test_scrollcontainer.py
luizoti/toga
3c49e685f325f1aba2ce048b253402d7e4519f97
[ "BSD-3-Clause" ]
597
2019-04-02T20:02:42.000Z
2022-03-30T10:28:47.000Z
src/core/tests/widgets/test_scrollcontainer.py
luizoti/toga
3c49e685f325f1aba2ce048b253402d7e4519f97
[ "BSD-3-Clause" ]
318
2019-03-31T18:32:00.000Z
2022-03-30T18:07:13.000Z
from unittest import mock import toga import toga_dummy from toga_dummy.utils import TestCase, TestStyle
39.311111
94
0.702092
from unittest import mock import toga import toga_dummy from toga_dummy.utils import TestCase, TestStyle class ScrollContainerTests(TestCase): def setUp(self): super().setUp() self.on_scroll = mock.Mock() self.sc = toga.ScrollContainer( style=TestStyle(), factory=toga_dummy.fa...
3,070
16
346
73467ba0fe258371769d468a9a73899ba655c859
1,128
py
Python
BaseFile/GetProxyIp.py
solider245/Requests_Html_Spider
3ea30f8f16f88e8f2934b411fa720c76ad054482
[ "Apache-2.0" ]
10
2018-11-21T09:38:03.000Z
2021-02-01T07:13:37.000Z
BaseFile/GetProxyIp.py
solider245/Requests_Html_Spider
3ea30f8f16f88e8f2934b411fa720c76ad054482
[ "Apache-2.0" ]
null
null
null
BaseFile/GetProxyIp.py
solider245/Requests_Html_Spider
3ea30f8f16f88e8f2934b411fa720c76ad054482
[ "Apache-2.0" ]
8
2019-03-21T13:33:08.000Z
2021-02-01T07:20:49.000Z
#!/usr/bin/env python # encoding: utf-8 """ @version: v1.0 @author: W_H_J @license: Apache Licence @contact: 415900617@qq.com @software: PyCharm @file: GetProxyIp.py @time: 2018/9/25 17:45 @describe: 返回代理IP """ import sys import os import random import time sys.path.append(os.path.abspath(os.path.dirname(...
20.142857
72
0.559397
#!/usr/bin/env python # encoding: utf-8 """ @version: v1.0 @author: W_H_J @license: Apache Licence @contact: 415900617@qq.com @software: PyCharm @file: GetProxyIp.py @time: 2018/9/25 17:45 @describe: 返回代理IP """ import sys import os import random import time sys.path.append(os.path.abspath(os.path.dirname(...
510
0
80
91290d5d9e402ac07467d46bfe83bfbc81306ced
452
py
Python
setup.py
chrsbats/kvstore
6d478ac47f52eddd7fc84c334e4a1d5c040a8a5d
[ "MIT" ]
2
2018-09-08T04:36:13.000Z
2019-04-13T15:35:07.000Z
setup.py
chrsbats/kvstore
6d478ac47f52eddd7fc84c334e4a1d5c040a8a5d
[ "MIT" ]
3
2015-03-10T10:28:16.000Z
2015-03-10T10:29:38.000Z
setup.py
chrsbats/kvstore
6d478ac47f52eddd7fc84c334e4a1d5c040a8a5d
[ "MIT" ]
null
null
null
from distutils.core import setup setup( name='kvstore', version='0.4', author='C Bates', author_email='chrsbats@gmail.com', packages=['kvstore'], scripts=[], url='https://github.com/chrsbats/kvstore', license='LICENSE.TXT', description='Key value store with Filesystem and S3 backend...
25.111111
71
0.652655
from distutils.core import setup setup( name='kvstore', version='0.4', author='C Bates', author_email='chrsbats@gmail.com', packages=['kvstore'], scripts=[], url='https://github.com/chrsbats/kvstore', license='LICENSE.TXT', description='Key value store with Filesystem and S3 backend...
0
0
0
e185984ccebc6bf7d797754a5471e7ff26614010
606
py
Python
tests/conftest.py
schobster/dataclass-csv
9aa91940006d41731c76be8babf97bea848d5598
[ "BSD-3-Clause" ]
null
null
null
tests/conftest.py
schobster/dataclass-csv
9aa91940006d41731c76be8babf97bea848d5598
[ "BSD-3-Clause" ]
null
null
null
tests/conftest.py
schobster/dataclass-csv
9aa91940006d41731c76be8babf97bea848d5598
[ "BSD-3-Clause" ]
null
null
null
from csv import DictWriter import pytest @pytest.fixture()
22.444444
79
0.60066
from csv import DictWriter import pytest @pytest.fixture() def create_csv(tmpdir_factory): def func(data, filename='user.csv', factory=tmpdir_factory): assert data file = tmpdir_factory.mktemp('data').join(filename) row = data[0] if isinstance(data, list) else data with file.o...
522
0
22
f4921af7a3c83ba3c1199e6e5f19c6df3b94bdc6
547
py
Python
tests/test_methods/test_utils.py
NationalJournal/py-votesmart
9194f28564d8d005386f498b1fc915cc7772f38b
[ "BSD-3-Clause" ]
7
2018-03-08T16:33:02.000Z
2020-12-22T08:12:31.000Z
tests/test_methods/test_utils.py
NationalJournal/py-votesmart
9194f28564d8d005386f498b1fc915cc7772f38b
[ "BSD-3-Clause" ]
7
2018-02-13T02:40:29.000Z
2018-03-08T17:04:53.000Z
tests/test_methods/test_utils.py
NationalJournal/py-votesmart
9194f28564d8d005386f498b1fc915cc7772f38b
[ "BSD-3-Clause" ]
4
2018-02-13T13:41:28.000Z
2021-12-21T22:14:54.000Z
import pytest from votesmart.methods import utils as uts from votesmart.methods.containers import VotesmartApiObject # import _parse_api_response, VotesmartApiError
28.789474
59
0.738574
import pytest from votesmart.methods import utils as uts from votesmart.methods.containers import VotesmartApiObject # import _parse_api_response, VotesmartApiError def test_sanity(): assert 1 + 1 == 2 def test_parse_api_response(): response = {"noerror": "here"} value = uts.parse_api_response(response) ...
312
0
69
68cb9e91964699d07d0df58268025c9484c1878f
1,043
py
Python
run.py
fabric8-analytics/fabric8-analytics-github-events-monitor
bda33c3521d36677a7c70056621e18ff24e525c3
[ "Apache-2.0" ]
null
null
null
run.py
fabric8-analytics/fabric8-analytics-github-events-monitor
bda33c3521d36677a7c70056621e18ff24e525c3
[ "Apache-2.0" ]
43
2018-12-10T10:53:05.000Z
2021-12-13T19:53:58.000Z
run.py
fabric8-analytics/fabric8-analytics-github-events-monitor
bda33c3521d36677a7c70056621e18ff24e525c3
[ "Apache-2.0" ]
5
2018-12-07T11:20:55.000Z
2022-01-28T23:31:25.000Z
"""Entry point for the service.""" import logging import os from time import sleep from ghmonitor.monitor import get_auth_header from ghmonitor.backend import get_backend_by_name from ghmonitor.utils import create_monitors, process_new_events logger = logging.getLogger('Monitor') if __name__ == "__main__": #...
25.439024
83
0.707574
"""Entry point for the service.""" import logging import os from time import sleep from ghmonitor.monitor import get_auth_header from ghmonitor.backend import get_backend_by_name from ghmonitor.utils import create_monitors, process_new_events logger = logging.getLogger('Monitor') if __name__ == "__main__": #...
0
0
0
5b51baf3aa9bd02258bb72ec44f30237c71119e9
3,456
py
Python
parallel_merge_sort.py
ursulaabreu/ppd-trabalho1
800e1a83ae831fdb53ccce7ade736570934071d5
[ "MIT" ]
null
null
null
parallel_merge_sort.py
ursulaabreu/ppd-trabalho1
800e1a83ae831fdb53ccce7ade736570934071d5
[ "MIT" ]
null
null
null
parallel_merge_sort.py
ursulaabreu/ppd-trabalho1
800e1a83ae831fdb53ccce7ade736570934071d5
[ "MIT" ]
1
2021-07-28T01:13:35.000Z
2021-07-28T01:13:35.000Z
from contextlib import contextmanager from multiprocessing import Manager, Pool import time ############################################################################### ############################################################################### ##############################################################...
30.052174
86
0.546007
from contextlib import contextmanager from multiprocessing import Manager, Pool import time class Timer(object): def __init__(self, *steps): self._time_per_step = dict.fromkeys(steps) def __getitem__(self, item): return self.time_per_step[item] @property def time_per_step(self): ...
2,555
147
155
b85ea8ac7b673002f3d623de61fcc6dc2114e493
831
py
Python
stack.py
efrainc/data_struc_v2
ffbb5cb3a7d17c7c7720279dcb45d2215dbd6f3f
[ "MIT" ]
null
null
null
stack.py
efrainc/data_struc_v2
ffbb5cb3a7d17c7c7720279dcb45d2215dbd6f3f
[ "MIT" ]
null
null
null
stack.py
efrainc/data_struc_v2
ffbb5cb3a7d17c7c7720279dcb45d2215dbd6f3f
[ "MIT" ]
null
null
null
#! /usr/bin/env python class node(object): """Node container for linked list""" class stack(object): """Simple Stack Data Structure""" if __name__ == '__main__': a = node('first') b = node('second') c = node('third') sta = stack() sta.insert(a) sta.insert(b) sta.insert(c) p...
18.466667
52
0.572804
#! /usr/bin/env python class node(object): """Node container for linked list""" def __init__(self, data): # Single linked so only one pointer required self.pointer = None self.data = data class stack(object): """Simple Stack Data Structure""" def __init__(self): sel...
303
0
135
01e6b54530e14c5f9c927e4fce615fafafb65fa3
527
py
Python
examples/schelling/model.py
vishalbelsare/neworder
38635fca64f239a9e8eb1a671872c174e1814678
[ "MIT" ]
17
2017-12-08T10:21:18.000Z
2022-01-13T09:29:43.000Z
examples/schelling/model.py
vishalbelsare/neworder
38635fca64f239a9e8eb1a671872c174e1814678
[ "MIT" ]
61
2018-07-21T21:37:12.000Z
2021-07-10T12:49:15.000Z
examples/schelling/model.py
vishalbelsare/neworder
38635fca64f239a9e8eb1a671872c174e1814678
[ "MIT" ]
6
2019-06-06T18:29:31.000Z
2021-08-20T13:32:17.000Z
import numpy as np import neworder from schelling import Schelling #neworder.verbose() # category 0 is empty gridsize = [480,360] categories = np.array([0.36, 0.12, 0.12, 0.4]) # normalise if necessary # categories = categories / sum(categories) similarity = 0.6 # open-ended timeline with arbitrary timestep # the mo...
25.095238
79
0.764706
import numpy as np import neworder from schelling import Schelling #neworder.verbose() # category 0 is empty gridsize = [480,360] categories = np.array([0.36, 0.12, 0.12, 0.4]) # normalise if necessary # categories = categories / sum(categories) similarity = 0.6 # open-ended timeline with arbitrary timestep # the mo...
0
0
0
e5d8a43cfeefd1ec7c9a4dc4d4685ed87b588150
1,545
py
Python
catalog/bindings/gmd/dynamic_feature_type.py
NIVANorge/s-enda-playground
56ae0a8978f0ba8a5546330786c882c31e17757a
[ "Apache-2.0" ]
null
null
null
catalog/bindings/gmd/dynamic_feature_type.py
NIVANorge/s-enda-playground
56ae0a8978f0ba8a5546330786c882c31e17757a
[ "Apache-2.0" ]
null
null
null
catalog/bindings/gmd/dynamic_feature_type.py
NIVANorge/s-enda-playground
56ae0a8978f0ba8a5546330786c882c31e17757a
[ "Apache-2.0" ]
null
null
null
from dataclasses import dataclass, field from typing import Optional from bindings.gmd.abstract_feature_type import AbstractFeatureType from bindings.gmd.data_source import DataSource from bindings.gmd.data_source_reference import DataSourceReference from bindings.gmd.history import History from bindings.gmd.track impo...
29.150943
66
0.6
from dataclasses import dataclass, field from typing import Optional from bindings.gmd.abstract_feature_type import AbstractFeatureType from bindings.gmd.data_source import DataSource from bindings.gmd.data_source_reference import DataSourceReference from bindings.gmd.history import History from bindings.gmd.track impo...
0
1,089
22
5c4f3e824bbd5df8f8cb44127ea47edfcc679639
8,608
py
Python
echolect/filtering/filters.py
ryanvolz/echolect
ec2594925f34fdaea69b64e725fccb0c99665a55
[ "BSD-3-Clause" ]
1
2022-03-24T22:48:12.000Z
2022-03-24T22:48:12.000Z
echolect/filtering/filters.py
scivision/echolect
ec2594925f34fdaea69b64e725fccb0c99665a55
[ "BSD-3-Clause" ]
1
2015-03-25T20:41:24.000Z
2015-03-25T20:41:24.000Z
echolect/filtering/filters.py
scivision/echolect
ec2594925f34fdaea69b64e725fccb0c99665a55
[ "BSD-3-Clause" ]
null
null
null
#----------------------------------------------------------------------------- # Copyright (c) 2014, Ryan Volz # All rights reserved. # # Distributed under the terms of the BSD 3-Clause ("BSD New") license. # # The full license is in the LICENSE file, distributed with this software. #-----------------------------------...
29.278912
108
0.55309
#----------------------------------------------------------------------------- # Copyright (c) 2014, Ryan Volz # All rights reserved. # # Distributed under the terms of the BSD 3-Clause ("BSD New") license. # # The full license is in the LICENSE file, distributed with this software. #-----------------------------------...
6,978
0
237
f42b9e2e909af7496ad8c30d51f5b7b7782d8249
1,012
py
Python
doc/api_example.py
bmwiedemann/httpolice
4da2bde3d14a24b0623ee45ae10afd192d6fa771
[ "MIT" ]
1,027
2016-04-25T11:17:13.000Z
2022-02-06T23:47:45.000Z
doc/api_example.py
99/httpolice
8175020af13708801fbefc8d4f3787b11093c962
[ "MIT" ]
9
2016-07-25T11:30:34.000Z
2021-03-23T20:42:29.000Z
doc/api_example.py
99/httpolice
8175020af13708801fbefc8d4f3787b11093c962
[ "MIT" ]
27
2016-05-19T22:17:39.000Z
2020-09-18T05:53:39.000Z
import io import httpolice exchanges = [ httpolice.Exchange( httpolice.Request(u'https', u'GET', u'/index.html', u'HTTP/1.1', [(u'Host', b'example.com')], b''), [ httpolice.Response(u'HTTP/1.1', 401, u'Unautho...
30.666667
74
0.537549
import io import httpolice exchanges = [ httpolice.Exchange( httpolice.Request(u'https', u'GET', u'/index.html', u'HTTP/1.1', [(u'Host', b'example.com')], b''), [ httpolice.Response(u'HTTP/1.1', 401, u'Unautho...
0
0
0
0aabec811943a63ec6b0b1dd4789b782d3da5874
2,600
py
Python
config/urls.py
hqpr/findyour3d
8ad3d2cb7bd0adfd080bb2314df1c78b94d3973a
[ "MIT" ]
null
null
null
config/urls.py
hqpr/findyour3d
8ad3d2cb7bd0adfd080bb2314df1c78b94d3973a
[ "MIT" ]
null
null
null
config/urls.py
hqpr/findyour3d
8ad3d2cb7bd0adfd080bb2314df1c78b94d3973a
[ "MIT" ]
1
2020-11-26T10:52:20.000Z
2020-11-26T10:52:20.000Z
from django.conf import settings from django.conf.urls import include, url from django.conf.urls.static import static from django.contrib import admin from django.views.generic import TemplateView from django.views import defaults as default_views from findyour3d.contact.views import contact urlpatterns = [ ...
53.061224
114
0.62
from django.conf import settings from django.conf.urls import include, url from django.conf.urls.static import static from django.contrib import admin from django.views.generic import TemplateView from django.views import defaults as default_views from findyour3d.contact.views import contact urlpatterns = [ ...
0
0
0
0186a448b041439390be813bf3fe5a4b69b31958
779
py
Python
pueue/daemon/signals.py
leiz-me/pueue
1ab3b2d0c6bd0bd1208af97e7ac5a35eac57722b
[ "MIT" ]
null
null
null
pueue/daemon/signals.py
leiz-me/pueue
1ab3b2d0c6bd0bd1208af97e7ac5a35eac57722b
[ "MIT" ]
null
null
null
pueue/daemon/signals.py
leiz-me/pueue
1ab3b2d0c6bd0bd1208af97e7ac5a35eac57722b
[ "MIT" ]
null
null
null
"""Possible singals, which can be send to a process via `kill`.""" import signal signals = { # SigHup '1': signal.SIGHUP, 'sighup': signal.SIGHUP, 'hup': signal.SIGHUP, # SigInt '2': signal.SIGINT, 'sigint': signal.SIGINT, 'int': signal.SIGINT, # SigQuit '3': signal.SIGQUIT, ...
19.475
66
0.593068
"""Possible singals, which can be send to a process via `kill`.""" import signal signals = { # SigHup '1': signal.SIGHUP, 'sighup': signal.SIGHUP, 'hup': signal.SIGHUP, # SigInt '2': signal.SIGINT, 'sigint': signal.SIGINT, 'int': signal.SIGINT, # SigQuit '3': signal.SIGQUIT, ...
0
0
0
de64612e41d556d131cbd8b78a8c4f726a45aa82
882
py
Python
multiplespawner/config/template.py
ucphhpc/multiplespawner
912704135b04b843a360a8f87ec50196ebdb8825
[ "MIT" ]
null
null
null
multiplespawner/config/template.py
ucphhpc/multiplespawner
912704135b04b843a360a8f87ec50196ebdb8825
[ "MIT" ]
1
2021-02-02T13:49:30.000Z
2021-02-02T13:49:30.000Z
multiplespawner/config/template.py
ucphhpc/multiplespawner
912704135b04b843a360a8f87ec50196ebdb8825
[ "MIT" ]
null
null
null
import os import json from multiplespawner.defaults import default_base_path from multiplespawner.util import load
28.451613
76
0.683673
import os import json from multiplespawner.defaults import default_base_path from multiplespawner.util import load def get_spawner_template_path(path=None): if "MULTIPLE_SPAWNER_TEMPLATE_FILE" in os.environ: path = os.environ["MULTIPLE_SPAWNER_TEMPLATE_FILE"] else: # If no path is set programm...
719
0
46
5440d6c5f8e0be288839a349b271e8dd38fb733f
808
py
Python
bigquery-to-pandas.py
phoenix-w/Useful-Scripts
b9335350273184011d471d0ddfe6604c944537cd
[ "MIT" ]
null
null
null
bigquery-to-pandas.py
phoenix-w/Useful-Scripts
b9335350273184011d471d0ddfe6604c944537cd
[ "MIT" ]
null
null
null
bigquery-to-pandas.py
phoenix-w/Useful-Scripts
b9335350273184011d471d0ddfe6604c944537cd
[ "MIT" ]
null
null
null
# code for accessing BigQuery locally import os if __name__ == "__main__": client = main() # run a query and save the output as a data frame import pandas as pd df = client.query( """ YOUR-BigQuery-QUERY-GOES-HERE """ ).to_dataframe()
29.925926
86
0.726485
# code for accessing BigQuery locally import os def main(): from google.cloud import bigquery from google.oauth2 import service_account # follow the steps here to download a JSON file that contains your key # https://cloud.google.com/docs/authentication/production#create_service_account path = "LO...
528
0
22
6c7f326f59c1194de9697eb8dcff63abf880a94d
139
py
Python
generated-libraries/python/netapp/perf/counter.py
radekg/netapp-ontap-lib-get
6445ebb071ec147ea82a486fbe9f094c56c5c40d
[ "MIT" ]
2
2017-03-28T15:31:26.000Z
2018-08-16T22:15:18.000Z
generated-libraries/python/netapp/perf/counter.py
radekg/netapp-ontap-lib-get
6445ebb071ec147ea82a486fbe9f094c56c5c40d
[ "MIT" ]
null
null
null
generated-libraries/python/netapp/perf/counter.py
radekg/netapp-ontap-lib-get
6445ebb071ec147ea82a486fbe9f094c56c5c40d
[ "MIT" ]
null
null
null
class Counter(basestring): """ Counter Name """ @staticmethod
13.9
26
0.52518
class Counter(basestring): """ Counter Name """ @staticmethod def get_api_name(): return "counter"
25
0
26
8a8b6576ed46ffe7da30d0c60151ce34b09c49dc
3,549
py
Python
setup.py
maresb/lattice
2d68635da7455dc9e36161aebba58a7062682d98
[ "Apache-2.0" ]
null
null
null
setup.py
maresb/lattice
2d68635da7455dc9e36161aebba58a7062682d98
[ "Apache-2.0" ]
null
null
null
setup.py
maresb/lattice
2d68635da7455dc9e36161aebba58a7062682d98
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 The TensorFlow Lattice 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 ag...
33.481132
80
0.714004
# Copyright 2018 The TensorFlow Lattice 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 ag...
0
0
0
24f4d56b8bc678cd4f32e31df6a18f5a5df1403e
601
py
Python
djangoProject/api/migrations/0005_auto_20201209_1906.py
skygxsky/invitation_system
b6b345e4fc7116b64c509c75753fafa4b2d1f02c
[ "MIT" ]
null
null
null
djangoProject/api/migrations/0005_auto_20201209_1906.py
skygxsky/invitation_system
b6b345e4fc7116b64c509c75753fafa4b2d1f02c
[ "MIT" ]
null
null
null
djangoProject/api/migrations/0005_auto_20201209_1906.py
skygxsky/invitation_system
b6b345e4fc7116b64c509c75753fafa4b2d1f02c
[ "MIT" ]
null
null
null
# Generated by Django 3.1.4 on 2020-12-09 11:06 from django.db import migrations, models
25.041667
81
0.590682
# Generated by Django 3.1.4 on 2020-12-09 11:06 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('api', '0004_auto_20201209_1905'), ] operations = [ migrations.AlterField( model_name='userinfo', name='phone', ...
0
499
23
b58d5085506d6c967f0ecf03489928a9c483d62e
2,886
py
Python
speech/packages/chatbot/text_to_idea.py
sprtkd/OpenHmnD
361a5751824292e507b03c4b90e5f64564e8eb0e
[ "MIT" ]
2
2017-08-01T19:56:52.000Z
2018-06-15T01:57:36.000Z
speech/packages/chatbot/text_to_idea.py
sprtkd/OpenHmnD
361a5751824292e507b03c4b90e5f64564e8eb0e
[ "MIT" ]
2
2017-07-30T06:42:34.000Z
2017-07-30T06:50:19.000Z
speech/packages/chatbot/text_to_idea.py
sprtkd/OpenHmnD
361a5751824292e507b03c4b90e5f64564e8eb0e
[ "MIT" ]
4
2017-07-28T18:38:48.000Z
2017-08-06T20:07:24.000Z
# -*- coding: utf-8 -*- """ Created on Tue Jul 25 18:17:38 2017 @author: Punyajoy Saha """ #from rasa_nlu.converters import load_data #from rasa_nlu.config import RasaNLUConfig #from rasa_nlu.model import Trainer # #training_data = load_data('data/examples/rasa/demo-rasa.json') #trainer = Trainer(RasaNLUC...
28.019417
97
0.691268
# -*- coding: utf-8 -*- """ Created on Tue Jul 25 18:17:38 2017 @author: Punyajoy Saha """ #from rasa_nlu.converters import load_data #from rasa_nlu.config import RasaNLUConfig #from rasa_nlu.model import Trainer # #training_data = load_data('data/examples/rasa/demo-rasa.json') #trainer = Trainer(RasaNLUC...
108
0
29
6cc520b0bb3a3e330dfa7e9fcb6749a47b331ca0
40
py
Python
app/gui/symmetric/caesar/__init__.py
vasilypht/Cryptographic-methods
7a44a46f01d5973d338170cb05272582d34bc1be
[ "MIT" ]
null
null
null
app/gui/symmetric/caesar/__init__.py
vasilypht/Cryptographic-methods
7a44a46f01d5973d338170cb05272582d34bc1be
[ "MIT" ]
null
null
null
app/gui/symmetric/caesar/__init__.py
vasilypht/Cryptographic-methods
7a44a46f01d5973d338170cb05272582d34bc1be
[ "MIT" ]
null
null
null
from .caesar_widget import CaesarWidget
20
39
0.875
from .caesar_widget import CaesarWidget
0
0
0
023c5bcef128b6dc2e63ff88bad5e1fd9552349e
6,208
py
Python
amiq_sv_python_non_blocking_socket_communication_in_systemverilog_using_dpi_c/server.py
cristianbob/amiq_blog
184ddc8759c57268d8d4ffa552b3e57d22478247
[ "Apache-2.0" ]
23
2018-05-01T06:45:00.000Z
2022-03-23T09:49:09.000Z
amiq_sv_python_non_blocking_socket_communication_in_systemverilog_using_dpi_c/server.py
cristianbob/amiq_blog
184ddc8759c57268d8d4ffa552b3e57d22478247
[ "Apache-2.0" ]
3
2019-05-06T15:41:12.000Z
2021-12-14T14:04:51.000Z
amiq_sv_python_non_blocking_socket_communication_in_systemverilog_using_dpi_c/server.py
cristianbob/amiq_blog
184ddc8759c57268d8d4ffa552b3e57d22478247
[ "Apache-2.0" ]
30
2017-10-18T12:36:07.000Z
2022-03-28T15:09:01.000Z
# /****************************************************************************** # * (C) Copyright 2020 AMIQ Consulting # * # * 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:/...
40.575163
121
0.487597
# /****************************************************************************** # * (C) Copyright 2020 AMIQ Consulting # * # * 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:/...
0
0
0
bff4c69566b1181f069146caee9bbbfea9324660
5,490
py
Python
7-assets/past-student-repos/LambdaSchool-master/m6/63a1/src/iterative_sorting/iterative_sorting.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/LambdaSchool-master/m6/63a1/src/iterative_sorting/iterative_sorting.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/LambdaSchool-master/m6/63a1/src/iterative_sorting/iterative_sorting.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
# TODO: Complete the selection_sort() function below # os.chdir("E:\\projects\\LambdaSchool\\m6\\63a1\\src\\iterative_sorting\") # exec(open("iterative_sorting.py").read()) def selection_sort(arr): ''' procedure selection sort arr : array of items arraylength : size of ar...
28.59375
88
0.5
# TODO: Complete the selection_sort() function below # os.chdir("E:\\projects\\LambdaSchool\\m6\\63a1\\src\\iterative_sorting\") # exec(open("iterative_sorting.py").read()) def selection_sort(arr): ''' procedure selection sort arr : array of items arraylength : size of ar...
1,981
0
22
1d279cd97b22f47f53a00829342b4a64e9835eac
547
py
Python
tf_encrypted/keras/engine/input_layer_test.py
wqruan/tf-encrypted
50ee4ae3ba76b7c1f70a90e18f875191adea0a07
[ "Apache-2.0" ]
825
2019-04-18T09:21:32.000Z
2022-03-30T05:55:26.000Z
tf_encrypted/keras/engine/input_layer_test.py
wqruan/tf-encrypted
50ee4ae3ba76b7c1f70a90e18f875191adea0a07
[ "Apache-2.0" ]
354
2019-04-18T08:42:40.000Z
2022-03-31T18:06:31.000Z
tf_encrypted/keras/engine/input_layer_test.py
wqruan/tf-encrypted
50ee4ae3ba76b7c1f70a90e18f875191adea0a07
[ "Apache-2.0" ]
161
2019-05-02T16:43:31.000Z
2022-03-31T01:35:03.000Z
# pylint: disable=missing-docstring import unittest import numpy as np import tensorflow as tf import tf_encrypted as tfe from tf_encrypted.keras.engine.input_layer import Input np.random.seed(42) if __name__ == "__main__": unittest.main()
20.259259
55
0.674589
# pylint: disable=missing-docstring import unittest import numpy as np import tensorflow as tf import tf_encrypted as tfe from tf_encrypted.keras.engine.input_layer import Input np.random.seed(42) class TestInput(unittest.TestCase): def setUp(self): tf.reset_default_graph() def test_input(self): ...
207
14
76
7f843d30b13a3647cc3d81aae520204805a2fafc
3,424
py
Python
Update.py
errordimension/errordimension
24668bd2bfa199909410b441256dfbe0f39087ea
[ "MIT" ]
4
2021-08-20T06:56:43.000Z
2021-08-22T05:20:21.000Z
Update.py
ErrorDimension/ErrorDimension
3baab3d6e1c1acd586d55b96117b207a001a1e61
[ "MIT" ]
null
null
null
Update.py
ErrorDimension/ErrorDimension
3baab3d6e1c1acd586d55b96117b207a001a1e61
[ "MIT" ]
1
2021-08-28T08:40:05.000Z
2021-08-28T08:40:05.000Z
from datetime import datetime import pytz import requests import json from time import perf_counter, time import lib import colorama from colorama import Fore from lib import ehook from lib.log import log colorama.init() log("OKAY", "Imported: colorama") log("OKAY", "Imported: datetime.datetime") log("OKAY", "Importe...
26.542636
230
0.629381
from datetime import datetime import pytz import requests import json from time import perf_counter, time import lib import colorama from colorama import Fore from lib import ehook from lib.log import log colorama.init() log("OKAY", "Imported: colorama") log("OKAY", "Imported: datetime.datetime") log("OKAY", "Importe...
1,316
0
161
832a4e4151ab0ea68d9e0028d4ebe5b08667da01
3,699
py
Python
nwbwidgets/spectrum.py
NeurodataWithoutBorders/nwb-jupyter-widgets
0d11e5d7b193c53d744b13c6404186ac84f4a5c1
[ "BSD-3-Clause-LBNL" ]
35
2019-03-10T23:39:17.000Z
2021-11-16T11:50:33.000Z
nwbwidgets/spectrum.py
catalystneuro/nwb-jupyter-widgets
0d11e5d7b193c53d744b13c6404186ac84f4a5c1
[ "BSD-3-Clause-LBNL" ]
158
2019-03-12T21:40:24.000Z
2022-03-16T14:35:55.000Z
nwbwidgets/spectrum.py
catalystneuro/nwb-jupyter-widgets
0d11e5d7b193c53d744b13c6404186ac84f4a5c1
[ "BSD-3-Clause-LBNL" ]
20
2019-03-08T14:30:27.000Z
2021-11-08T16:31:26.000Z
import matplotlib.pyplot as plt import numpy as np from ipywidgets import widgets from ndx_spectrum import Spectrum def plot_spectrum_figure(spectrum, channel_nos, frequency_nos): """ Plot power vs frequencies and/or phase vs frequencies. Parameters ---------- spectrum: Spectrum channel_nos: ...
35.228571
88
0.638821
import matplotlib.pyplot as plt import numpy as np from ipywidgets import widgets from ndx_spectrum import Spectrum def show_spectrum(node: Spectrum, **kwargs) -> widgets.Widget: check_spectrum(node) data = node.power if "power" in node.fields else node.phase if len(data.shape) == 2: no_channels =...
1,618
0
46
111f8861f8a268462a9c22cdca35e2db764c3102
16,873
py
Python
crypto_futures_py/binance_futures.py
bear2u/CryptoFuturesPy
9cfbf5f3a32b35a8a7cd53c2a3ded55d7b3c78d0
[ "MIT" ]
7
2020-08-23T19:02:33.000Z
2022-03-24T15:48:18.000Z
crypto_futures_py/binance_futures.py
bear2u/CryptoFuturesPy
9cfbf5f3a32b35a8a7cd53c2a3ded55d7b3c78d0
[ "MIT" ]
null
null
null
crypto_futures_py/binance_futures.py
bear2u/CryptoFuturesPy
9cfbf5f3a32b35a8a7cd53c2a3ded55d7b3c78d0
[ "MIT" ]
1
2021-09-15T04:17:04.000Z
2021-09-15T04:17:04.000Z
""" This module contains an implementation for Binance Futures (BinanceFuturesExchangeHandler) """ from __future__ import annotations import pandas as pd import typing import json import logging import pandas as pd from datetime import datetime from dataclasses import dataclass from . import futurespy as fp from...
37.412417
122
0.551295
""" This module contains an implementation for Binance Futures (BinanceFuturesExchangeHandler) """ from __future__ import annotations import pandas as pd import typing import json import logging import pandas as pd from datetime import datetime from dataclasses import dataclass from . import futurespy as fp from...
7,052
9,443
23
161d98b443c391dbbea03d9c2f7f5e9a17fd23db
1,195
py
Python
release/stubs.min/System/Runtime/InteropServices/__init___parts/DllImportSearchPath.py
htlcnn/ironpython-stubs
780d829e2104b2789d5f4d6f32b0ec9f2930ca03
[ "MIT" ]
182
2017-06-27T02:26:15.000Z
2022-03-30T18:53:43.000Z
release/stubs.min/System/Runtime/InteropServices/__init___parts/DllImportSearchPath.py
htlcnn/ironpython-stubs
780d829e2104b2789d5f4d6f32b0ec9f2930ca03
[ "MIT" ]
28
2017-06-27T13:38:23.000Z
2022-03-15T11:19:44.000Z
release/stubs.min/System/Runtime/InteropServices/__init___parts/DllImportSearchPath.py
htlcnn/ironpython-stubs
780d829e2104b2789d5f4d6f32b0ec9f2930ca03
[ "MIT" ]
67
2017-06-28T09:43:59.000Z
2022-03-20T21:17:10.000Z
class DllImportSearchPath(Enum,IComparable,IFormattable,IConvertible): """ enum (flags) DllImportSearchPath,values: ApplicationDirectory (512),AssemblyDirectory (2),LegacyBehavior (0),SafeDirectories (4096),System32 (2048),UseDllDirectoryForDependencies (256),UserDirectories (1024) """ def __eq__(self,*args): ""...
34.142857
217
0.712971
class DllImportSearchPath(Enum,IComparable,IFormattable,IConvertible): """ enum (flags) DllImportSearchPath,values: ApplicationDirectory (512),AssemblyDirectory (2),LegacyBehavior (0),SafeDirectories (4096),System32 (2048),UseDllDirectoryForDependencies (256),UserDirectories (1024) """ def __eq__(self,*args): ""...
78
0
168
ac884fac4b4ad300f4213bf7b99c0cbbf3293a3a
1,441
py
Python
CIS41B/Assignments/assignment3_t4.py
jackh423/python
4187c16a1d6c1269d188a4a039e0a16020de51d0
[ "Apache-2.0" ]
1
2021-09-08T18:34:56.000Z
2021-09-08T18:34:56.000Z
CIS41B/Assignments/assignment3_t4.py
jackh423/python
4187c16a1d6c1269d188a4a039e0a16020de51d0
[ "Apache-2.0" ]
null
null
null
CIS41B/Assignments/assignment3_t4.py
jackh423/python
4187c16a1d6c1269d188a4a039e0a16020de51d0
[ "Apache-2.0" ]
null
null
null
import queue import threading import time from urllib.request import urlopen from bs4 import BeautifulSoup SITE_NAME = "https://www.esrl.noaa.gov/gmd/aggi/aggi.html" threadList = ["CO2", "CH4", "N2O", "CFC12", "CFC11", "15-minor"] exitFlag = False # threadList = ["Thread-1", "Thread-2", "Thread-3"] threadList = ["C...
24.844828
64
0.636364
import queue import threading import time from urllib.request import urlopen from bs4 import BeautifulSoup SITE_NAME = "https://www.esrl.noaa.gov/gmd/aggi/aggi.html" threadList = ["CO2", "CH4", "N2O", "CFC12", "CFC11", "15-minor"] exitFlag = False def processData(threadName, q): while not exitFlag: if no...
376
15
98
bf5aed444e548b8e2da7c54fa887c642fd51dfea
1,475
py
Python
Classification/NaiveBayes.py
govindansriram/CobraML
d231d2e446df7e7860071f5d7cfa1e31afa99c6b
[ "BSD-3-Clause" ]
15
2021-07-21T20:54:39.000Z
2021-09-03T02:54:46.000Z
Classification/NaiveBayes.py
govindansriram/CobraML
d231d2e446df7e7860071f5d7cfa1e31afa99c6b
[ "BSD-3-Clause" ]
3
2021-08-30T03:10:06.000Z
2021-10-05T19:40:34.000Z
Classification/NaiveBayes.py
govindansriram/CobraML
d231d2e446df7e7860071f5d7cfa1e31afa99c6b
[ "BSD-3-Clause" ]
1
2022-02-20T13:51:31.000Z
2022-02-20T13:51:31.000Z
import torch
34.302326
111
0.588475
import torch class NaiveBayes: def __init__(self, class_count, feature_count): self.__device = torch.device("cuda" if torch.cuda.is_available() else "cpu") self.__class_count = class_count self.__class_sum_tensor = torch.zeros(size=(1, self.__class_count...
1,280
-4
185
a6457c650d50808138f7d03d79ab801bdbc416d3
560
py
Python
activity_stream/forms.py
colbypalmer/cp-activity-stream
15df17ede14b4f82cfb534ef9445d26e52484a84
[ "MIT" ]
1
2015-12-12T18:41:56.000Z
2015-12-12T18:41:56.000Z
activity_stream/forms.py
colbypalmer/cp-activity-stream
15df17ede14b4f82cfb534ef9445d26e52484a84
[ "MIT" ]
null
null
null
activity_stream/forms.py
colbypalmer/cp-activity-stream
15df17ede14b4f82cfb534ef9445d26e52484a84
[ "MIT" ]
null
null
null
from django import forms from django.forms.widgets import CheckboxSelectMultiple from models import Stream, StreamConnection
43.076923
95
0.555357
from django import forms from django.forms.widgets import CheckboxSelectMultiple from models import Stream, StreamConnection class StreamForm(forms.ModelForm): streamconnections = forms.ModelMultipleChoiceField(widget=CheckboxSelectMultiple, queryset=StreamCon...
0
413
23
7089cc4f0b349788f98e48f4bc5ad70da741659c
484
py
Python
Chapter02/function-working.py
JeffreyAsuncion/PythonEssentialTraining
adf9164ac01db35f2f657e58ec60d9bcc197dcda
[ "MIT" ]
null
null
null
Chapter02/function-working.py
JeffreyAsuncion/PythonEssentialTraining
adf9164ac01db35f2f657e58ec60d9bcc197dcda
[ "MIT" ]
null
null
null
Chapter02/function-working.py
JeffreyAsuncion/PythonEssentialTraining
adf9164ac01db35f2f657e58ec60d9bcc197dcda
[ "MIT" ]
null
null
null
#!/home/jepoy/anaconda3/bin/python ## at terminal which python function(47) list_primes() n = 5 if isprime(n): print(f'{n} is prime') else: print(f'{n} not prime')
16.133333
41
0.541322
#!/home/jepoy/anaconda3/bin/python ## at terminal which python def function(n): print(n) function(47) def isprime(n): if n <= 1: return False for x in range(2, n): if n % x == 0: return False else: return True def list_primes(): for n in range(100): if...
241
0
69
c54428d22cf2cc86b1658d5448a25fcdaa354ccf
843
py
Python
text_office/apps.py
pkaczynski/django-text_office
07c52ad6f8955c11cf79e4a99e45d46c1b440345
[ "MIT" ]
null
null
null
text_office/apps.py
pkaczynski/django-text_office
07c52ad6f8955c11cf79e4a99e45d46c1b440345
[ "MIT" ]
null
null
null
text_office/apps.py
pkaczynski/django-text_office
07c52ad6f8955c11cf79e4a99e45d46c1b440345
[ "MIT" ]
1
2021-08-09T22:54:22.000Z
2021-08-09T22:54:22.000Z
from __future__ import unicode_literals from django.utils.translation import ugettext_lazy as _ from django.apps import AppConfig, apps as django_apps from django.conf import settings from django.core.checks import Error, register @register()
29.068966
70
0.650059
from __future__ import unicode_literals from django.utils.translation import ugettext_lazy as _ from django.apps import AppConfig, apps as django_apps from django.conf import settings from django.core.checks import Error, register class TextOfficeConfig(AppConfig): name = 'text_office' verbose_name = 'Text ...
479
71
45
21184f01ce738d95c71570af3f43f6ac70b35d6d
11,712
py
Python
frgpascal/experimentaldesign/test_batching.py
fenning-research-group/PASCAL
c175e60ec2015ac8dce1ed3ae037619072d48cea
[ "MIT" ]
1
2022-02-11T22:31:32.000Z
2022-02-11T22:31:32.000Z
frgpascal/experimentaldesign/test_batching.py
fenning-research-group/PASCAL
c175e60ec2015ac8dce1ed3ae037619072d48cea
[ "MIT" ]
7
2021-05-06T16:07:51.000Z
2021-08-07T15:18:06.000Z
frgpascal/experimentaldesign/test_batching.py
fenning-research-group/PASCAL
c175e60ec2015ac8dce1ed3ae037619072d48cea
[ "MIT" ]
1
2021-12-11T00:42:33.000Z
2021-12-11T00:42:33.000Z
import json import asyncio from abc import ABC, abstractmethod from threading import Lock, Thread import time from functools import partial import numpy as np from concurrent.futures import ThreadPoolExecutor speedup_factor = 50 # def anneal(self, task): # sample = self.maestro.samples[task["sample"]]...
35.92638
92
0.592469
import json import asyncio from abc import ABC, abstractmethod from threading import Lock, Thread import time from functools import partial import numpy as np from concurrent.futures import ThreadPoolExecutor speedup_factor = 50 def load_netlist(filename): with open(filename) as f: netlist = json.load(f)...
5,282
5,317
580
627ecf2f8b0e83fc8c01bca7b2bbaec3a02e4e43
1,298
py
Python
00_create_data.py
PauSempere-SQ/AzureMLServices
34006e0f261e497a9e32a6d71b480e8e2e0206b2
[ "MIT" ]
null
null
null
00_create_data.py
PauSempere-SQ/AzureMLServices
34006e0f261e497a9e32a6d71b480e8e2e0206b2
[ "MIT" ]
null
null
null
00_create_data.py
PauSempere-SQ/AzureMLServices
34006e0f261e497a9e32a6d71b480e8e2e0206b2
[ "MIT" ]
null
null
null
from sklearn import datasets import pandas as pd import numpy as np X, y = datasets.load_wine(return_X_y=True) df_to_save = pd.DataFrame(X) df_to_save['Class'] = y columns = ['Alcohol', 'Malic Acid', 'Ash', 'Alcalinity of Ash', 'Magnesium', 'Total Phenols', 'Flavonoids', 'Nonflavonoid phenols', 'Proanthocyanin...
28.844444
84
0.75963
from sklearn import datasets import pandas as pd import numpy as np X, y = datasets.load_wine(return_X_y=True) df_to_save = pd.DataFrame(X) df_to_save['Class'] = y columns = ['Alcohol', 'Malic Acid', 'Ash', 'Alcalinity of Ash', 'Magnesium', 'Total Phenols', 'Flavonoids', 'Nonflavonoid phenols', 'Proanthocyanin...
0
0
0
278fd34af1a7e817012c27f38647f9ce76f0c803
889
py
Python
legacy/ssd/visual.py
FrancisLiang/models-1
e14d5bc1ab36d0dd11977f27cff54605bf99c945
[ "Apache-2.0" ]
4
2020-01-04T13:15:02.000Z
2021-07-21T07:50:02.000Z
legacy/ssd/visual.py
FrancisLiang/models-1
e14d5bc1ab36d0dd11977f27cff54605bf99c945
[ "Apache-2.0" ]
2
2019-06-26T03:21:49.000Z
2019-09-19T09:43:42.000Z
legacy/ssd/visual.py
FrancisLiang/models-1
e14d5bc1ab36d0dd11977f27cff54605bf99c945
[ "Apache-2.0" ]
3
2019-10-31T07:18:49.000Z
2020-01-13T03:18:39.000Z
import cv2 import os data_dir = './data' infer_file = './infer.res' out_dir = './visual_res' path_to_im = dict() for line in open(infer_file): img_path, _, _, _ = line.strip().split('\t') if img_path not in path_to_im: im = cv2.imread(os.path.join(data_dir, img_path)) path_to_im[img_path] = i...
26.147059
64
0.622047
import cv2 import os data_dir = './data' infer_file = './infer.res' out_dir = './visual_res' path_to_im = dict() for line in open(infer_file): img_path, _, _, _ = line.strip().split('\t') if img_path not in path_to_im: im = cv2.imread(os.path.join(data_dir, img_path)) path_to_im[img_path] = i...
0
0
0
8e3459e461657ac976b8f92eec83934c2a841215
417
py
Python
CursoEmVideo/ex026.py
EduardoArgenti/Python
18b4578033d6eb6fb0ae2d6a8511a4a813856203
[ "MIT" ]
null
null
null
CursoEmVideo/ex026.py
EduardoArgenti/Python
18b4578033d6eb6fb0ae2d6a8511a4a813856203
[ "MIT" ]
null
null
null
CursoEmVideo/ex026.py
EduardoArgenti/Python
18b4578033d6eb6fb0ae2d6a8511a4a813856203
[ "MIT" ]
null
null
null
# Faça um programa que leia uma frase pelo teclado e mostre: # - Quantas vezes aparece a letra "a" # - Em que posição ela aparece a primeira vez # - Em que posição ela aparece a última vez frase = input('Digite uma frase: ') print('\nAnalisando...') print(f'"A" aparece {frase.lower().count("a")} vez(es)') print(f'Pri...
37.909091
60
0.678657
# Faça um programa que leia uma frase pelo teclado e mostre: # - Quantas vezes aparece a letra "a" # - Em que posição ela aparece a primeira vez # - Em que posição ela aparece a última vez frase = input('Digite uma frase: ') print('\nAnalisando...') print(f'"A" aparece {frase.lower().count("a")} vez(es)') print(f'Pri...
0
0
0
8bca2c72ac55977d81e8681d769f8dde8e7aa479
12,157
py
Python
tests/test_base.py
trytonus/trytond-magento
f27e8d136e5e222fdf86b679d10d468de38262eb
[ "BSD-3-Clause" ]
3
2015-10-07T15:51:40.000Z
2016-04-06T09:00:57.000Z
tests/test_base.py
trytonus/trytond-magento
f27e8d136e5e222fdf86b679d10d468de38262eb
[ "BSD-3-Clause" ]
19
2015-07-28T14:24:24.000Z
2016-07-13T06:02:35.000Z
tests/test_base.py
trytonus/trytond-magento
f27e8d136e5e222fdf86b679d10d468de38262eb
[ "BSD-3-Clause" ]
15
2015-07-28T05:54:17.000Z
2016-05-27T12:23:29.000Z
# -*- coding: utf-8 -*- import os from decimal import Decimal import json import unittest from datetime import datetime from dateutil.relativedelta import relativedelta import trytond.tests.test_tryton from trytond.tests.test_tryton import POOL, USER from trytond.transaction import Transaction from trytond.pyson impor...
35.546784
78
0.513449
# -*- coding: utf-8 -*- import os from decimal import Decimal import json import unittest from datetime import datetime from dateutil.relativedelta import relativedelta import trytond.tests.test_tryton from trytond.tests.test_tryton import POOL, USER from trytond.transaction import Transaction from trytond.pyson impor...
0
0
0
dde5c4d550e8f8004cc551619e131716af7b357c
1,307
py
Python
archive/macs21csv_to_HOMERbed.py
dkdeconti/sRNAPeaks
8f83afe60f98a70d8bc0cc733e8dac7017ab6bb4
[ "MIT" ]
1
2021-02-04T12:47:26.000Z
2021-02-04T12:47:26.000Z
archive/macs21csv_to_HOMERbed.py
dkdeconti/sRNAPeaks
8f83afe60f98a70d8bc0cc733e8dac7017ab6bb4
[ "MIT" ]
null
null
null
archive/macs21csv_to_HOMERbed.py
dkdeconti/sRNAPeaks
8f83afe60f98a70d8bc0cc733e8dac7017ab6bb4
[ "MIT" ]
null
null
null
#! /usr/bin/python import sys if __name__ == "__main__": main(sys.argv[1:])
23.763636
65
0.488906
#! /usr/bin/python import sys def parse_header(handle): header = handle.readline().strip('\n').strip(',') if header[0] == "#": while len(header) == 0 or header[0] == "#": header = handle.readline().strip('\n').strip(',') sys.stdout.write('#' + header + '\n') def parse_line(line): ...
1,104
0
115
b4954ebbe38426ef14f0c48d0939e47dc8ef64d4
1,450
py
Python
src/hcb/artifacts/make_qubit_count_plot.py
Strilanc/honeycomb-boundaries
cc33baac44c7831bd643db81d0053f8ec6eae9d8
[ "Apache-2.0" ]
null
null
null
src/hcb/artifacts/make_qubit_count_plot.py
Strilanc/honeycomb-boundaries
cc33baac44c7831bd643db81d0053f8ec6eae9d8
[ "Apache-2.0" ]
2
2022-02-25T22:28:24.000Z
2022-03-23T21:09:04.000Z
src/hcb/artifacts/make_qubit_count_plot.py
Strilanc/honeycomb-boundaries
cc33baac44c7831bd643db81d0053f8ec6eae9d8
[ "Apache-2.0" ]
null
null
null
import pathlib import matplotlib.colors as mcolors import matplotlib.pyplot as plt from hcb.codes.honeycomb.layout import HoneycombLayout OUT_DIR = pathlib.Path(__file__).parent.parent.parent.parent / "out" MARKERS = "ov*sp^<>8PhH+xXDd|" * 100 COLORS = list(mcolors.TABLEAU_COLORS) * 3 if __name__ == '__main__': ...
26.363636
93
0.583448
import pathlib import matplotlib.colors as mcolors import matplotlib.pyplot as plt from hcb.codes.honeycomb.layout import HoneycombLayout OUT_DIR = pathlib.Path(__file__).parent.parent.parent.parent / "out" MARKERS = "ov*sp^<>8PhH+xXDd|" * 100 COLORS = list(mcolors.TABLEAU_COLORS) * 3 def main(): gate_sets = ...
1,096
0
23
e7df75299fce5240f01c4d780034e2543c3f49a9
1,041
py
Python
fragmenter/tests/test_adjacency.py
kristianeschenburg/parcellation_fragmenter
9928db6697c80ce2f334305cca62031414a6181a
[ "BSD-3-Clause" ]
19
2018-07-19T16:11:51.000Z
2022-03-14T01:59:04.000Z
fragmenter/tests/test_adjacency.py
kristianeschenburg/parcellation_fragmenter
9928db6697c80ce2f334305cca62031414a6181a
[ "BSD-3-Clause" ]
32
2018-07-19T19:38:53.000Z
2020-09-27T21:14:36.000Z
fragmenter/tests/test_adjacency.py
kristianeschenburg/parcellation_fragmenter
9928db6697c80ce2f334305cca62031414a6181a
[ "BSD-3-Clause" ]
13
2018-07-19T22:04:33.000Z
2020-04-06T06:35:03.000Z
from fragmenter import adjacency import numpy as np FACES = np.asarray([ [0, 1, 2], [0, 1, 3], [1, 0, 2], [1, 3, 0], [1, 2, 4], [1, 2, 5], [2, 0, 1], [2, 1, 4], [2, 1, 5], [3, 0, 1], [4, 1, 2], [5, 1, 2]]) VERTICES = np.zeros((6, 3)) ADJ_LIST = { 0: [1, 2, 3], 1: [0, 2, 3, 4, 5], 2: [0, 1, 4,...
20.019231
76
0.522574
from fragmenter import adjacency import numpy as np FACES = np.asarray([ [0, 1, 2], [0, 1, 3], [1, 0, 2], [1, 3, 0], [1, 2, 4], [1, 2, 5], [2, 0, 1], [2, 1, 4], [2, 1, 5], [3, 0, 1], [4, 1, 2], [5, 1, 2]]) VERTICES = np.zeros((6, 3)) ADJ_LIST = { 0: [1, 2, 3], 1: [0, 2, 3, 4, 5], 2: [0, 1, 4,...
0
0
0
c2ca17e6b0e9168ef3b21b7ac5bafb611764d687
3,359
py
Python
project/gtm_scanner.py
yuyatinnefeld/gtm_controller
846845216a834a65a9e65842d42b6ad258547514
[ "MIT" ]
null
null
null
project/gtm_scanner.py
yuyatinnefeld/gtm_controller
846845216a834a65a9e65842d42b6ad258547514
[ "MIT" ]
null
null
null
project/gtm_scanner.py
yuyatinnefeld/gtm_controller
846845216a834a65a9e65842d42b6ad258547514
[ "MIT" ]
null
null
null
from pprint import pprint from gtm_base import GTMBase
37.322222
78
0.621316
from pprint import pprint from gtm_base import GTMBase class GTMScanner(GTMBase): def __init__(self, service): super().__init__(service) def print_account_list(self, account_list): for num, account in enumerate(account_list["account"]): print(num, "🤖 ACCOUNT") print("�...
2,927
5
454
ef17a1b001d220abaac815362070063ee2e26eba
2,138
py
Python
randbeacon/input_processing/merkle.py
randomchain/randbeacon
449b1ad387a526fafc3076c35c672c97006ee5d5
[ "MIT" ]
1
2018-04-08T16:24:57.000Z
2018-04-08T16:24:57.000Z
randbeacon/input_processing/merkle.py
randomchain/randbeacon
449b1ad387a526fafc3076c35c672c97006ee5d5
[ "MIT" ]
9
2018-04-08T16:11:43.000Z
2018-06-01T13:32:16.000Z
randbeacon/input_processing/merkle.py
randomchain/randbeacon
449b1ad387a526fafc3076c35c672c97006ee5d5
[ "MIT" ]
null
null
null
import sys import click import msgpack from logbook import Logger, StreamHandler from merkletools import MerkleTools from .base import BaseInputProcessor log = Logger('Merkle') @click.command() @click.option('--hash-algo', default="sha512") @click.option('--gather-time', default=5.0) @click.option('--pull-addr', de...
32.892308
118
0.683349
import sys import click import msgpack from logbook import Logger, StreamHandler from merkletools import MerkleTools from .base import BaseInputProcessor log = Logger('Merkle') class MerkleInputProcessor(BaseInputProcessor): def __init__(self, *, hash_algo, **kwargs): super().__init__(hash_algo=hash_algo...
1,135
242
45
4a8bc165aff8dd4c3b3bbedf82720de3555b4627
2,498
py
Python
src/cmd_lampe.py
guillaume-havard/com_elements_gui
3d21d248b495dc3698f609d7564943163eeb81d7
[ "MIT" ]
null
null
null
src/cmd_lampe.py
guillaume-havard/com_elements_gui
3d21d248b495dc3698f609d7564943163eeb81d7
[ "MIT" ]
14
2015-01-06T10:13:21.000Z
2015-01-23T14:49:06.000Z
src/cmd_lampe.py
guillaume-havard/com_elements_gui
3d21d248b495dc3698f609d7564943163eeb81d7
[ "MIT" ]
null
null
null
#!/usr/bin/python3 """ Copyright (c) 2014 Guillaume Havard - BVS """ import sys import os import time import serial import signal port = serial.Serial("/dev/ttyAMA0", baudrate=115200, timeout=0, parity=serial.PARITY_NONE, ...
23.345794
76
0.461569
#!/usr/bin/python3 """ Copyright (c) 2014 Guillaume Havard - BVS """ import sys import os import time import serial import signal port = serial.Serial("/dev/ttyAMA0", baudrate=115200, timeout=0, parity=serial.PARITY_NONE, ...
275
0
47
4e2fa6599180a9de69c94115c7f1b1adf84853dc
770
py
Python
api/storaging/migrations/0001_initial.py
selelab/admin
d858209da3b7efc4501d503968402268d3f689f8
[ "BSD-3-Clause" ]
null
null
null
api/storaging/migrations/0001_initial.py
selelab/admin
d858209da3b7efc4501d503968402268d3f689f8
[ "BSD-3-Clause" ]
17
2020-03-27T14:18:46.000Z
2022-02-27T01:24:58.000Z
api/storaging/migrations/0001_initial.py
selelab/admin
d858209da3b7efc4501d503968402268d3f689f8
[ "BSD-3-Clause" ]
1
2020-02-26T09:09:07.000Z
2020-02-26T09:09:07.000Z
# Generated by Django 3.0.5 on 2020-04-17 08:11 from django.db import migrations, models import django.utils.timezone import uuid
27.5
112
0.581818
# Generated by Django 3.0.5 on 2020-04-17 08:11 from django.db import migrations, models import django.utils.timezone import uuid class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Medium', fields=[ ...
0
615
23
5e2dfcf38c1df29decc962b43d31dc02ceb015c5
6,955
py
Python
pytorch_pretrained_bert/create_pretraining_data.py
harmdevries89/pytorch-pretrained-BERT
acd04eacc87ffdc666d4104958e2700785003380
[ "Apache-2.0" ]
null
null
null
pytorch_pretrained_bert/create_pretraining_data.py
harmdevries89/pytorch-pretrained-BERT
acd04eacc87ffdc666d4104958e2700785003380
[ "Apache-2.0" ]
null
null
null
pytorch_pretrained_bert/create_pretraining_data.py
harmdevries89/pytorch-pretrained-BERT
acd04eacc87ffdc666d4104958e2700785003380
[ "Apache-2.0" ]
null
null
null
import json import random import os import time import tqdm import copy import sys import multiprocessing as mp from multiprocessing import Pool from tokenization import BertTokenizer tokenizer = BertTokenizer.from_pretrained('bert-large-uncased', cache_dir='./data') rng = random.Random() def create_instances_from_...
39.742857
136
0.608914
import json import random import os import time import tqdm import copy import sys import multiprocessing as mp from multiprocessing import Pool from tokenization import BertTokenizer tokenizer = BertTokenizer.from_pretrained('bert-large-uncased', cache_dir='./data') rng = random.Random() def get_wiki_docs(wiki_pat...
683
0
69
c81fe6ca6808e60dfe4b8dd32ea47ae380ccbcee
5,400
py
Python
tests/test_exception_handling.py
DiamondLightSource/python-bluesky-taskgraph
7d843b84b2b9618399e63c2e5c7ab2ad3f010dc2
[ "Apache-2.0" ]
null
null
null
tests/test_exception_handling.py
DiamondLightSource/python-bluesky-taskgraph
7d843b84b2b9618399e63c2e5c7ab2ad3f010dc2
[ "Apache-2.0" ]
null
null
null
tests/test_exception_handling.py
DiamondLightSource/python-bluesky-taskgraph
7d843b84b2b9618399e63c2e5c7ab2ad3f010dc2
[ "Apache-2.0" ]
1
2022-02-22T08:30:10.000Z
2022-02-22T08:30:10.000Z
from typing import Any, Dict from unittest.mock import call from bluesky import RunEngine from bluesky.suspenders import SuspendCeil from mocks import mock_device from ophyd import DeviceStatus, Signal from ophyd.sim import SynAxis from ophyd.utils import DestroyedError from python_bluesky_taskgraph.core.decision_eng...
38.571429
87
0.606296
from typing import Any, Dict from unittest.mock import call from bluesky import RunEngine from bluesky.suspenders import SuspendCeil from mocks import mock_device from ophyd import DeviceStatus, Signal from ophyd.sim import SynAxis from ophyd.utils import DestroyedError from python_bluesky_taskgraph.core.decision_eng...
2,259
57
229
963ee08e1e4759634f5a2655aba9fb0915fb9647
2,333
py
Python
core/polyaxon/tracking/contrib/keras.py
jjasonkal/polyaxon
8454b29b2b971b965de8a7bf63afdd48f07d6d53
[ "Apache-2.0" ]
null
null
null
core/polyaxon/tracking/contrib/keras.py
jjasonkal/polyaxon
8454b29b2b971b965de8a7bf63afdd48f07d6d53
[ "Apache-2.0" ]
null
null
null
core/polyaxon/tracking/contrib/keras.py
jjasonkal/polyaxon
8454b29b2b971b965de8a7bf63afdd48f07d6d53
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # # Copyright 2018-2020 Polyaxon, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable ...
32.859155
89
0.68024
#!/usr/bin/python # # Copyright 2018-2020 Polyaxon, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable ...
945
17
130
830e2623c74c6ddd09d1cb655a40a56881491249
4,968
py
Python
gcn/Preprocess/load_unprocessed_graph.py
Patrickgsheng/GCN_detection_benchmark
ded59653accc61aeeb8e437c2ea9203e4fe9e500
[ "MIT" ]
null
null
null
gcn/Preprocess/load_unprocessed_graph.py
Patrickgsheng/GCN_detection_benchmark
ded59653accc61aeeb8e437c2ea9203e4fe9e500
[ "MIT" ]
4
2020-01-28T23:06:19.000Z
2022-02-10T00:45:00.000Z
gcn/Preprocess/load_unprocessed_graph.py
Patrickgsheng/GCN_detection_benchmark
ded59653accc61aeeb8e437c2ea9203e4fe9e500
[ "MIT" ]
1
2019-11-16T14:55:22.000Z
2019-11-16T14:55:22.000Z
import numpy as np import random import json import sys import os import networkx as nx from networkx.readwrite import json_graph version_info = list(map(int, nx.__version__.split('.'))) major = version_info[0] minor = version_info[1] assert (major <= 1) and (minor <= 11), "networkx major version > 1.11"
40.064516
160
0.634461
import numpy as np import random import json import sys import os import networkx as nx from networkx.readwrite import json_graph version_info = list(map(int, nx.__version__.split('.'))) major = version_info[0] minor = version_info[1] assert (major <= 1) and (minor <= 11), "networkx major version > 1.11" def load_unp...
4,639
0
23
a835c080783b9745efa7ccf09b32743b7fe555dc
1,827
py
Python
make_sitemap.py
nikicoon/www_shared
e9508c24b31a60f52578646ec3a47805c787f978
[ "0BSD" ]
null
null
null
make_sitemap.py
nikicoon/www_shared
e9508c24b31a60f52578646ec3a47805c787f978
[ "0BSD" ]
null
null
null
make_sitemap.py
nikicoon/www_shared
e9508c24b31a60f52578646ec3a47805c787f978
[ "0BSD" ]
null
null
null
# Copyright (C) 2019 GNUnet e.V. # # This code is derived from code contributed to GNUnet e.V. # by Nikita Ronja <nikita@NetBSD.org> # # Permission to use, copy, modify, and/or distribute this software for any # purpose with or without fee is hereby granted. # # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS...
35.134615
143
0.660646
# Copyright (C) 2019 GNUnet e.V. # # This code is derived from code contributed to GNUnet e.V. # by Nikita Ronja <nikita@NetBSD.org> # # Permission to use, copy, modify, and/or distribute this software for any # purpose with or without fee is hereby granted. # # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS...
875
0
23
d787b14f9736012c868dbb0f65da3eee4fd67c18
1,793
py
Python
test/test_object_ezsigntemplate_api.py
ezmaxinc/eZmax-SDK-python
6794b8001abfb7d9ae18a3b87aba164839b925a0
[ "MIT" ]
null
null
null
test/test_object_ezsigntemplate_api.py
ezmaxinc/eZmax-SDK-python
6794b8001abfb7d9ae18a3b87aba164839b925a0
[ "MIT" ]
null
null
null
test/test_object_ezsigntemplate_api.py
ezmaxinc/eZmax-SDK-python
6794b8001abfb7d9ae18a3b87aba164839b925a0
[ "MIT" ]
null
null
null
""" eZmax API Definition (Full) This API expose all the functionnalities for the eZmax and eZsign applications. # noqa: E501 The version of the OpenAPI document: 1.1.7 Contact: support-api@ezmax.ca Generated by: https://openapi-generator.tech """ import unittest import eZmaxApi from eZmaxApi.a...
24.902778
97
0.677078
""" eZmax API Definition (Full) This API expose all the functionnalities for the eZmax and eZsign applications. # noqa: E501 The version of the OpenAPI document: 1.1.7 Contact: support-api@ezmax.ca Generated by: https://openapi-generator.tech """ import unittest import eZmaxApi from eZmaxApi.a...
65
0
54
6c8d63295e38677fda751c87c4b9bf6690a83b24
5,933
py
Python
examples/pubcrawl/pubcrawl.py
vishalbelsare/soil
e860bdb922a22da2987fba07dffb81351c0272e5
[ "Apache-2.0" ]
null
null
null
examples/pubcrawl/pubcrawl.py
vishalbelsare/soil
e860bdb922a22da2987fba07dffb81351c0272e5
[ "Apache-2.0" ]
null
null
null
examples/pubcrawl/pubcrawl.py
vishalbelsare/soil
e860bdb922a22da2987fba07dffb81351c0272e5
[ "Apache-2.0" ]
null
null
null
from soil.agents import FSM, state, default_state from soil import Environment from random import random, shuffle from itertools import islice import logging class CityPubs(Environment): '''Environment with Pubs''' level = logging.INFO def enter(self, pub_id, *nodes): '''Agents will try to enter....
33.710227
89
0.549132
from soil.agents import FSM, state, default_state from soil import Environment from random import random, shuffle from itertools import islice import logging class CityPubs(Environment): '''Environment with Pubs''' level = logging.INFO def __init__(self, *args, number_of_pubs=3, pub_capacity=10, **kwargs...
1,001
0
142
22bd22625e9f3124aab03e87e4d2b826649e6a71
17,216
py
Python
rdp.py
Tripwire-VERT/Protocol-Independent-Fuzzer
0389e41940c8e5615f4ab6097f14d2527fdb01b7
[ "BSD-2-Clause" ]
8
2015-10-13T08:47:39.000Z
2022-02-09T04:50:55.000Z
rdp.py
Tripwire-VERT/Protocol-Independent-Fuzzer
0389e41940c8e5615f4ab6097f14d2527fdb01b7
[ "BSD-2-Clause" ]
null
null
null
rdp.py
Tripwire-VERT/Protocol-Independent-Fuzzer
0389e41940c8e5615f4ab6097f14d2527fdb01b7
[ "BSD-2-Clause" ]
8
2015-02-23T21:09:13.000Z
2021-04-22T12:23:55.000Z
import struct from Crypto.PublicKey import RSA import binascii import rdp_session_key import rdp_error #encryption types FOURTY_BIT = 1 ONE_TWENTY_EIGHT_BIT = 2 FIFTY_SIX_BIT = 8 FIPS = 16 #protocols DEFAULT = 0 TLS = 1 CredSSP = 2 #other COTP_DATA = '\x02\xf0\x80' class RDP( o...
45.424802
232
0.600139
import struct from Crypto.PublicKey import RSA import binascii import rdp_session_key import rdp_error #encryption types FOURTY_BIT = 1 ONE_TWENTY_EIGHT_BIT = 2 FIFTY_SIX_BIT = 8 FIPS = 16 #protocols DEFAULT = 0 TLS = 1 CredSSP = 2 #other COTP_DATA = '\x02\xf0\x80' class RDP( o...
15,397
0
757
a0d50efa89388ef617d552588363a66db3d35cad
1,325
py
Python
my_intrusion_convertor.py
QianruZhou333/ArtificialImmuneSystem
e4c12b784ce76bd01f98eee9ad0949482cbce80a
[ "Apache-2.0" ]
null
null
null
my_intrusion_convertor.py
QianruZhou333/ArtificialImmuneSystem
e4c12b784ce76bd01f98eee9ad0949482cbce80a
[ "Apache-2.0" ]
null
null
null
my_intrusion_convertor.py
QianruZhou333/ArtificialImmuneSystem
e4c12b784ce76bd01f98eee9ad0949482cbce80a
[ "Apache-2.0" ]
null
null
null
# Author: Qianru Zhou # Email: zhouqr333@126.com # Magic, do not touch!! import csv def intrusionCSV_to_binary(csvDir, binaryDir): """ Convert the intrusion data in 'intrusion.csv' to binary strings Args: csvDir: the absolute directory of the csv file binaryDir: the absolute directory of the binary file """ t...
25
86
0.66566
# Author: Qianru Zhou # Email: zhouqr333@126.com # Magic, do not touch!! import csv def intrusionCSV_to_binary(csvDir, binaryDir): """ Convert the intrusion data in 'intrusion.csv' to binary strings Args: csvDir: the absolute directory of the csv file binaryDir: the absolute directory of the binary file """ t...
0
0
0
489cd512e5e6d407b6980688e7fcefbf70c58397
7,883
py
Python
bigbench/benchmark_tasks/sudoku/test.py
mswedrowski/BIG-bench
0927d64905b26f08f851d408f7bb2d7bf1a0e4fa
[ "Apache-2.0" ]
null
null
null
bigbench/benchmark_tasks/sudoku/test.py
mswedrowski/BIG-bench
0927d64905b26f08f851d408f7bb2d7bf1a0e4fa
[ "Apache-2.0" ]
null
null
null
bigbench/benchmark_tasks/sudoku/test.py
mswedrowski/BIG-bench
0927d64905b26f08f851d408f7bb2d7bf1a0e4fa
[ "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...
33.544681
104
0.669796
# 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...
5,654
64
522
e524bd1d4fc69985d839a2a43b050e3316cdf066
2,863
py
Python
scripts/install.py
JajMandu96/TheDuckpvpProject
dadd21dd9fe0dd06d07f1acd46702da25905bb5b
[ "Apache-2.0" ]
null
null
null
scripts/install.py
JajMandu96/TheDuckpvpProject
dadd21dd9fe0dd06d07f1acd46702da25905bb5b
[ "Apache-2.0" ]
null
null
null
scripts/install.py
JajMandu96/TheDuckpvpProject
dadd21dd9fe0dd06d07f1acd46702da25905bb5b
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- import os import sys if not os.geteuid() == 0: sys.exit("""\033[1;91m\n[!] Xerosploit installer must be run as root.\n\033[1;m""") print(""" \033[1;36m ██████╗░██╗░░░██╗░█████╗░██╗░░██╗██████╗░██╗░░░██╗██████╗░ ██╔══██╗██║░░░██║██╔══██╗██║░██╔╝██╔══██╗██║░░░██║██╔══██╗ █...
53.018519
462
0.494586
#!/usr/bin/python # -*- coding: utf-8 -*- import os import sys if not os.geteuid() == 0: sys.exit("""\033[1;91m\n[!] Xerosploit installer must be run as root.\n\033[1;m""") print(""" \033[1;36m ██████╗░██╗░░░██╗░█████╗░██╗░░██╗██████╗░██╗░░░██╗██████╗░ ██╔══██╗██║░░░██║██╔══██╗██║░██╔╝██╔══██╗██║░░░██║██╔══██╗ █...
1,840
0
23
f9c503779b42667f8b1780088a96205e2ab21c18
1,405
py
Python
ntwrk/bayesopt/utils.py
g-benton/PCC-RL
56c9d7cbe4cca0a24bb136dcadb46dface1c0ad0
[ "Apache-2.0" ]
null
null
null
ntwrk/bayesopt/utils.py
g-benton/PCC-RL
56c9d7cbe4cca0a24bb136dcadb46dface1c0ad0
[ "Apache-2.0" ]
null
null
null
ntwrk/bayesopt/utils.py
g-benton/PCC-RL
56c9d7cbe4cca0a24bb136dcadb46dface1c0ad0
[ "Apache-2.0" ]
null
null
null
import math import torch def compute_reward(monitor_interval): """ Get an Estimate of the throughput of the network using on the last few packets (the lag) """ loss = len(monitor_interval.ack)/len(monitor_interval.sent) latency = sum(monitor_interval.rtts)/len(monitor_interval.rtts) ######...
28.1
67
0.594306
import math import torch def compute_reward(monitor_interval): """ Get an Estimate of the throughput of the network using on the last few packets (the lag) """ loss = len(monitor_interval.ack)/len(monitor_interval.sent) latency = sum(monitor_interval.rtts)/len(monitor_interval.rtts) ######...
741
0
81
367eaeabc2bdeca79e6f3ede74eb2ec1e1fa34c9
9,932
py
Python
app/blobsentiment.py
mcpeixoto/Sentrade
55f65508d6b565b99840c9ce5d757185f5027164
[ "MIT" ]
4
2020-09-28T18:40:47.000Z
2021-12-01T08:29:29.000Z
app/blobsentiment.py
ZiyouZhang/Sentrade
c88d20a858de6d05649f99230ca2b44f4c76cd3c
[ "MIT" ]
null
null
null
app/blobsentiment.py
ZiyouZhang/Sentrade
c88d20a858de6d05649f99230ca2b44f4c76cd3c
[ "MIT" ]
2
2021-08-10T22:32:52.000Z
2022-02-03T21:28:47.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = "Davide Locatelli, Ziyou Zhang" __status__ = "Production" import json import sys import spacy import os from datetime import datetime, timedelta from dateutil.parser import parse from textblob import TextBlob from pymongo import MongoClient from pymongo impo...
41.556485
127
0.657571
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = "Davide Locatelli, Ziyou Zhang" __status__ = "Production" import json import sys import spacy import os from datetime import datetime, timedelta from dateutil.parser import parse from textblob import TextBlob from pymongo import MongoClient from pymongo impo...
0
0
0
aa58e4dc56908c61558deac2af846a500cab22a8
9,172
py
Python
src/clusto/drivers/devices/common/portmixin.py
thekad/clusto
c141ea3ef4931c6a21fdf42845c6e9de5ee08caa
[ "BSD-3-Clause" ]
216
2015-01-10T17:03:25.000Z
2022-03-24T07:23:41.000Z
src/clusto/drivers/devices/common/portmixin.py
thekad/clusto
c141ea3ef4931c6a21fdf42845c6e9de5ee08caa
[ "BSD-3-Clause" ]
23
2015-01-08T16:51:22.000Z
2021-03-13T12:56:04.000Z
src/clusto/drivers/devices/common/portmixin.py
thekad/clusto
c141ea3ef4931c6a21fdf42845c6e9de5ee08caa
[ "BSD-3-Clause" ]
49
2015-01-08T00:13:17.000Z
2021-09-22T02:01:20.000Z
""" PortMixin is a basic mixin to be used with devices that have ports """ import clusto from clusto.exceptions import ConnectionException class PortMixin: """Provide port capabilities to devices The ports are defined in the Driver's _portmeta dictionary: _portmeta = { '<porttype>' : {'numports':...
32.992806
102
0.561055
""" PortMixin is a basic mixin to be used with devices that have ports """ import clusto from clusto.exceptions import ConnectionException class PortMixin: """Provide port capabilities to devices The ports are defined in the Driver's _portmeta dictionary: _portmeta = { '<porttype>' : {'numports':...
677
0
110
989caf958e039af9c96b04408dd71b0df1e3f2a9
18,361
py
Python
raspi/ledStripController.py
jimenezl/web-controlled-led-strips
d920d2ce5d92c4b79d2580b1877ff129407ba783
[ "MIT" ]
null
null
null
raspi/ledStripController.py
jimenezl/web-controlled-led-strips
d920d2ce5d92c4b79d2580b1877ff129407ba783
[ "MIT" ]
null
null
null
raspi/ledStripController.py
jimenezl/web-controlled-led-strips
d920d2ce5d92c4b79d2580b1877ff129407ba783
[ "MIT" ]
null
null
null
#!/usr/bin/python import time ##import RPi.GPIO as GPIO #import requests import os import random import pigpio controller = ledStripController() controller.runMainLoop()
35.652427
220
0.559991
#!/usr/bin/python import time ##import RPi.GPIO as GPIO #import requests import os import random import pigpio class ledStripController(object): def __init__(self): """ Object for controlling LED Strips """ self.RED_PIN = 9 #Change me to the pin hooked up to red self.GREEN_...
5,262
12,901
23
f6b44857d69b1e871cf3b6c1f0dd6f76bcf874d0
2,349
py
Python
filmrolls2exif.py
Apreche/filmrolls2exif
78f8b24d96067dbc0b7256182d236638be5d79c5
[ "MIT" ]
null
null
null
filmrolls2exif.py
Apreche/filmrolls2exif
78f8b24d96067dbc0b7256182d236638be5d79c5
[ "MIT" ]
null
null
null
filmrolls2exif.py
Apreche/filmrolls2exif
78f8b24d96067dbc0b7256182d236638be5d79c5
[ "MIT" ]
null
null
null
#!/usr/bin/env python import exif import os import re from xml.etree import ElementTree ROLL_FIELDS = [ 'title', 'speed', 'camera', 'load', 'unload', 'note', ] FRAME_FIELDS = [ 'lens', 'aperture', 'shutterSpeed', 'compensation', 'accessory', 'number', 'date', ...
25.258065
83
0.614304
#!/usr/bin/env python import exif import os import re from xml.etree import ElementTree ROLL_FIELDS = [ 'title', 'speed', 'camera', 'load', 'unload', 'note', ] FRAME_FIELDS = [ 'lens', 'aperture', 'shutterSpeed', 'compensation', 'accessory', 'number', 'date', ...
1,808
0
138
cd133d1ded6c055658833bb30ef3b487879dffd0
776
py
Python
runehistory_api/framework/api/v1/controllers/stats.py
RuneHistory/runehistory-api
4e857c7fdbdf585d57cf4c7fe6214b565ac37a22
[ "MIT" ]
null
null
null
runehistory_api/framework/api/v1/controllers/stats.py
RuneHistory/runehistory-api
4e857c7fdbdf585d57cf4c7fe6214b565ac37a22
[ "MIT" ]
6
2018-06-14T13:58:43.000Z
2018-07-16T14:02:24.000Z
runehistory_api/framework/api/v1/controllers/stats.py
RuneHistory/runehistory-api
4e857c7fdbdf585d57cf4c7fe6214b565ac37a22
[ "MIT" ]
null
null
null
from flask import Blueprint, jsonify, Response from cmdbus import cmdbus from runehistory_api.app.commands.stats import GetAccountCountCommand, \ GetHighScoreCountCommand from runehistory_api.framework.auth import requires_jwt, requires_permission stats_bp = Blueprint('stats', __name__) @stats_bp.route('/accoun...
26.758621
76
0.748711
from flask import Blueprint, jsonify, Response from cmdbus import cmdbus from runehistory_api.app.commands.stats import GetAccountCountCommand, \ GetHighScoreCountCommand from runehistory_api.framework.auth import requires_jwt, requires_permission stats_bp = Blueprint('stats', __name__) @stats_bp.route('/accoun...
222
0
44
70135212e5a504fe182af186aeb24f41b5b15f98
425
py
Python
rubberband/utils/file.py
ambros-gleixner/rubberband
72dd935dbc4bed93860fdcaa0cbe752bcbd6e395
[ "MIT" ]
4
2018-03-25T15:01:20.000Z
2020-06-22T14:34:01.000Z
rubberband/utils/file.py
ambros-gleixner/rubberband
72dd935dbc4bed93860fdcaa0cbe752bcbd6e395
[ "MIT" ]
41
2016-12-19T21:17:41.000Z
2021-12-13T19:50:34.000Z
rubberband/utils/file.py
ambros-gleixner/rubberband
72dd935dbc4bed93860fdcaa0cbe752bcbd6e395
[ "MIT" ]
1
2017-10-06T13:52:57.000Z
2017-10-06T13:52:57.000Z
"""Methods to help with file io.""" from rubberband.constants import FILES_DIR def write_file(filename, contents): """ Save a file on the filesystem. Parameters ---------- filename : string Filename of file to write to. contents : string Contents to write into file. """ ...
20.238095
42
0.611765
"""Methods to help with file io.""" from rubberband.constants import FILES_DIR def write_file(filename, contents): """ Save a file on the filesystem. Parameters ---------- filename : string Filename of file to write to. contents : string Contents to write into file. """ ...
0
0
0
95297ac0803182de62e995e2c17970b4a3eab2fc
349
py
Python
info.py
Tomtomgo/bingpy3
e7ac6d873df70e5a0da01832d29d2564e753f671
[ "MIT" ]
null
null
null
info.py
Tomtomgo/bingpy3
e7ac6d873df70e5a0da01832d29d2564e753f671
[ "MIT" ]
null
null
null
info.py
Tomtomgo/bingpy3
e7ac6d873df70e5a0da01832d29d2564e753f671
[ "MIT" ]
null
null
null
# package information. INFO = dict( name = "bingpy3", description = "Python 3 Bing Search API (2015)", author = "Makoto P. Kato", author_email = "kato@dl.kuis.kyoto-u.ac.jp", license = "MIT License", url = "https://github.com/tomtomgo/bingpy3", classifiers = [ "Programming Lang...
26.846154
54
0.595989
# package information. INFO = dict( name = "bingpy3", description = "Python 3 Bing Search API (2015)", author = "Makoto P. Kato", author_email = "kato@dl.kuis.kyoto-u.ac.jp", license = "MIT License", url = "https://github.com/tomtomgo/bingpy3", classifiers = [ "Programming Lang...
0
0
0
e17df3ceeee399b2576844edfafc1165afe2cbc0
692
py
Python
setup.py
tarekziade/utproxy
bc77a9d81c25e4b292ba71ef995f89f667ba68f5
[ "Apache-2.0" ]
8
2019-06-29T00:30:48.000Z
2022-03-25T15:46:39.000Z
setup.py
tarekziade/utproxy
bc77a9d81c25e4b292ba71ef995f89f667ba68f5
[ "Apache-2.0" ]
15
2019-07-01T08:21:46.000Z
2019-12-02T15:18:37.000Z
setup.py
tarekziade/utproxy
bc77a9d81c25e4b292ba71ef995f89f667ba68f5
[ "Apache-2.0" ]
null
null
null
# encoding: utf8 import os import sys from setuptools import setup, find_packages with open("README.rst") as f: README = f.read() if sys.platform == "win32": install_requires = ["pywin32"] else: install_requires = [] setup(name="tinap", version="0.3", author="Tarek Ziadé", author_emai...
22.322581
57
0.654624
# encoding: utf8 import os import sys from setuptools import setup, find_packages with open("README.rst") as f: README = f.read() if sys.platform == "win32": install_requires = ["pywin32"] else: install_requires = [] setup(name="tinap", version="0.3", author="Tarek Ziadé", author_emai...
0
0
0
3d463dbebb7fd4d70ed818d30349a58fe682c95e
2,302
py
Python
orderable/tests/run.py
codingjoe/django-orderable
4e4102aafdfb246f12443cb1d36aecbccca9f2fe
[ "BSD-2-Clause" ]
null
null
null
orderable/tests/run.py
codingjoe/django-orderable
4e4102aafdfb246f12443cb1d36aecbccca9f2fe
[ "BSD-2-Clause" ]
null
null
null
orderable/tests/run.py
codingjoe/django-orderable
4e4102aafdfb246f12443cb1d36aecbccca9f2fe
[ "BSD-2-Clause" ]
null
null
null
import sys from argparse import ArgumentParser import django from django.conf import settings settings.configure( DATABASES={'default': { 'ENGINE': 'django.db.backends.postgresql_psycopg2', 'NAME': 'orderable', 'HOST': 'localhost' }}, INSTALLED_APPS=( 'orderable.tests', ...
32.885714
80
0.651173
import sys from argparse import ArgumentParser import django from django.conf import settings settings.configure( DATABASES={'default': { 'ENGINE': 'django.db.backends.postgresql_psycopg2', 'NAME': 'orderable', 'HOST': 'localhost' }}, INSTALLED_APPS=( 'orderable.tests', ...
0
0
0
e6ce57cd0fc03cdfa5fd18b861fe0f8f5536e5fc
177
py
Python
mil_nets/__init__.py
dipanshawucr/DeepLPI
b6bfe44fd49102090f4b255d53912c804548da69
[ "MIT" ]
1
2021-06-05T17:39:30.000Z
2021-06-05T17:39:30.000Z
mil_nets/__init__.py
dipanshawucr/DeepLPI
b6bfe44fd49102090f4b255d53912c804548da69
[ "MIT" ]
null
null
null
mil_nets/__init__.py
dipanshawucr/DeepLPI
b6bfe44fd49102090f4b255d53912c804548da69
[ "MIT" ]
2
2020-04-11T20:02:44.000Z
2021-11-23T04:51:37.000Z
from __future__ import absolute_import from . import metrics from . import objectives from . import dataset from . import utils from . import layer from . import pooling_method
22.125
38
0.80791
from __future__ import absolute_import from . import metrics from . import objectives from . import dataset from . import utils from . import layer from . import pooling_method
0
0
0
09906744a1789b9bd42ff68225cd26c2d855e0fb
9,311
py
Python
header.py
sradiouy/DARK
7c78c362803175c8257dd567518c2b6eb917cd39
[ "MIT" ]
null
null
null
header.py
sradiouy/DARK
7c78c362803175c8257dd567518c2b6eb917cd39
[ "MIT" ]
4
2021-03-19T02:58:22.000Z
2022-03-11T23:58:11.000Z
header.py
sradiouy/DARK
7c78c362803175c8257dd567518c2b6eb917cd39
[ "MIT" ]
null
null
null
# coding=utf-8 import dash import dash_table import dash_bootstrap_components as dbc import dash_core_components as dcc import dash_html_components as html from dash.dependencies import Input, Output, State import pandas as pd logo = "https://raw.githubusercontent.com/sradiouy/DARK/master/Images/Capa%200.pn...
49.791444
144
0.511975
# coding=utf-8 import dash import dash_table import dash_bootstrap_components as dbc import dash_core_components as dcc import dash_html_components as html from dash.dependencies import Input, Output, State import pandas as pd logo = "https://raw.githubusercontent.com/sradiouy/DARK/master/Images/Capa%200.pn...
0
0
0
81305e071ad90fb8ca67b64d8de51a6e68234a4c
9,698
py
Python
doc/source/ext/snapshotqt_directive.py
tacaswell/silx
67f0ac8d3fcb5764c23b2210becfe2052f98061d
[ "CC0-1.0", "MIT" ]
null
null
null
doc/source/ext/snapshotqt_directive.py
tacaswell/silx
67f0ac8d3fcb5764c23b2210becfe2052f98061d
[ "CC0-1.0", "MIT" ]
null
null
null
doc/source/ext/snapshotqt_directive.py
tacaswell/silx
67f0ac8d3fcb5764c23b2210becfe2052f98061d
[ "CC0-1.0", "MIT" ]
1
2017-04-02T18:00:14.000Z
2017-04-02T18:00:14.000Z
# coding: utf-8 # /*########################################################################## # # Copyright (c) 2004-2019 European Synchrotron Radiation Facility # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to d...
39.909465
100
0.579295
# coding: utf-8 # /*########################################################################## # # Copyright (c) 2004-2019 European Synchrotron Radiation Facility # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to d...
5,577
170
165
7420ed782cf8e19fa74f0f760b4798848f31896a
1,432
py
Python
active-speaker-detection/wearer/energy_based/match_wearer_audio.py
EGO4D/audio-visual
bed9d837f4212e89540fe73f54399f69739b73f5
[ "MIT" ]
15
2021-12-06T14:13:23.000Z
2022-03-14T02:02:53.000Z
active-speaker-detection/wearer/energy_based/match_wearer_audio.py
EGO4D/audio-visual
bed9d837f4212e89540fe73f54399f69739b73f5
[ "MIT" ]
null
null
null
active-speaker-detection/wearer/energy_based/match_wearer_audio.py
EGO4D/audio-visual
bed9d837f4212e89540fe73f54399f69739b73f5
[ "MIT" ]
3
2021-11-25T19:10:21.000Z
2022-03-11T12:10:41.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Usage: python3 match_wearer_audio.py data_set import pickle import sys import os import numpy as np from scipy.spatial.distance import cdist data_set = sys.argv[1] # 'test' or 'val' if not os.path.isfile(data_set + '.txt'): sys.exit(data_set + ' list does not exist...
29.833333
112
0.598464
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Usage: python3 match_wearer_audio.py data_set import pickle import sys import os import numpy as np from scipy.spatial.distance import cdist data_set = sys.argv[1] # 'test' or 'val' if not os.path.isfile(data_set + '.txt'): sys.exit(data_set + ' list does not exist...
0
0
0
4df144d75dd397c47811fb8f1e7a666984506e79
123
py
Python
tests/test-cases/typeinfer_basecase/case2.py
SMAT-Lab/Scalpel
1022200043f2d9e8c24256821b863997ab34dd49
[ "Apache-2.0" ]
102
2021-12-15T09:08:48.000Z
2022-03-24T15:15:25.000Z
tests/test-cases/typeinfer_basecase/case2.py
StarWatch27/Scalpel
8853e6e84f318f3cfeda0e03d274748b2fbe30fa
[ "Apache-2.0" ]
11
2021-12-04T11:48:31.000Z
2022-03-21T09:21:45.000Z
tests/test-cases/typeinfer_basecase/case2.py
StarWatch27/Scalpel
8853e6e84f318f3cfeda0e03d274748b2fbe30fa
[ "Apache-2.0" ]
11
2021-12-04T11:47:41.000Z
2022-02-06T09:04:39.000Z
# Constant return type # EXPECTED OUTPUT: # case2.py: my_function() -> str
13.666667
32
0.674797
# Constant return type # EXPECTED OUTPUT: # case2.py: my_function() -> str def my_function(): return "Hello world!"
23
0
23
13f01c8d88f375315f15aa6f7654f9b960c7cc2d
13,619
py
Python
ansible/my_env/lib/python2.7/site-packages/ansible/modules/cloud/google/gcp_compute_disk_facts.py
otus-devops-2019-02/yyashkin_infra
0cd0c003884155ac922e3e301305ac202de7028c
[ "MIT" ]
1
2019-04-16T21:23:15.000Z
2019-04-16T21:23:15.000Z
ansible/my_env/lib/python2.7/site-packages/ansible/modules/cloud/google/gcp_compute_disk_facts.py
otus-devops-2019-02/yyashkin_infra
0cd0c003884155ac922e3e301305ac202de7028c
[ "MIT" ]
5
2020-02-26T20:10:50.000Z
2021-09-23T23:23:18.000Z
ansible/my_env/lib/python2.7/site-packages/ansible/modules/cloud/google/gcp_compute_disk_facts.py
otus-devops-2019-02/yyashkin_infra
0cd0c003884155ac922e3e301305ac202de7028c
[ "MIT" ]
1
2020-02-13T14:24:57.000Z
2020-02-13T14:24:57.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- # # Copyright (C) 2017 Google # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) # ---------------------------------------------------------------------------- # # *** AUTO GENERATED CODE *** AUTO GENERATED CODE *** # ...
40.532738
139
0.551215
#!/usr/bin/python # -*- coding: utf-8 -*- # # Copyright (C) 2017 Google # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) # ---------------------------------------------------------------------------- # # *** AUTO GENERATED CODE *** AUTO GENERATED CODE *** # ...
1,805
0
115
757a960db966a572538098b07bb37f9cd69fc62d
770
py
Python
link_product_alias/link_product_alias.py
dhightnm/pyScripts
7855e204ab365398a4f2363494fd09174ba75228
[ "MIT" ]
null
null
null
link_product_alias/link_product_alias.py
dhightnm/pyScripts
7855e204ab365398a4f2363494fd09174ba75228
[ "MIT" ]
null
null
null
link_product_alias/link_product_alias.py
dhightnm/pyScripts
7855e204ab365398a4f2363494fd09174ba75228
[ "MIT" ]
null
null
null
import requests import json, csv url = "{{productUrl}}/v1/product/replace_me" f = open('./output_file_name.json') json_data_packet = json.load(f) print(link_alias(json_data_packet))
25.666667
75
0.683117
import requests import json, csv url = "{{productUrl}}/v1/product/replace_me" f = open('./output_file_name.json') json_data_packet = json.load(f) def link_alias(json_data): for object in json_data: url = "https://product.deliverr.com/v1/product-alias/link" payload = json.dumps({ "channelId": "Sell...
561
0
23
14c7ea82e8f601691d9d642ee6de23e471f461ab
6,521
py
Python
nimbus/config.py
usdhs/nimbus
8d53510081c42cb585ebf6b6a3bcff72a33a8bf9
[ "CC0-1.0" ]
null
null
null
nimbus/config.py
usdhs/nimbus
8d53510081c42cb585ebf6b6a3bcff72a33a8bf9
[ "CC0-1.0" ]
1
2017-12-21T19:34:59.000Z
2017-12-21T19:34:59.000Z
nimbus/config.py
usdhs/nimbus
8d53510081c42cb585ebf6b6a3bcff72a33a8bf9
[ "CC0-1.0" ]
1
2022-03-29T15:32:27.000Z
2022-03-29T15:32:27.000Z
""" Configuration functions """ import os import subprocess from collections import namedtuple from functools import wraps import atomicwrites import requests import yaml from .errors import NotFound, ManyFound from .logs import log from .utils import merged_dicts, mkdir_p # TODO: is this correct for Windows? DEFAU...
31.350962
79
0.597148
""" Configuration functions """ import os import subprocess from collections import namedtuple from functools import wraps import atomicwrites import requests import yaml from .errors import NotFound, ManyFound from .logs import log from .utils import merged_dicts, mkdir_p # TODO: is this correct for Windows? DEFAU...
3,372
2,733
23
63e1979752ad523a45f0ef39d5ad4cf18d316115
11,186
py
Python
doc/build/patched_autosummary.py
drewrisinger/pyGSTi
dd4ad669931c7f75e026456470cf33ac5b682d0d
[ "Apache-2.0" ]
1
2021-12-19T15:11:09.000Z
2021-12-19T15:11:09.000Z
doc/build/patched_autosummary.py
drewrisinger/pyGSTi
dd4ad669931c7f75e026456470cf33ac5b682d0d
[ "Apache-2.0" ]
null
null
null
doc/build/patched_autosummary.py
drewrisinger/pyGSTi
dd4ad669931c7f75e026456470cf33ac5b682d0d
[ "Apache-2.0" ]
null
null
null
""" This file contains a *slightly* (see single "OLD" changed line) version of the `generate_autosummary_docs` function found in .../site_packages/sphinx/ext/autosummary/generate.py, which determines how to process the .. autosummary:: directives in pyGSTi's documentation- generating .rst files. In pyGSTi, s...
44.03937
140
0.582424
""" This file contains a *slightly* (see single "OLD" changed line) version of the `generate_autosummary_docs` function found in .../site_packages/sphinx/ext/autosummary/generate.py, which determines how to process the .. autosummary:: directives in pyGSTi's documentation- generating .rst files. In pyGSTi, s...
8,876
0
77
2d30e22f6cefe02f33eb72de6b99e9259850883b
27,387
py
Python
main.py
rdbende/WhirlEdit
248c36bfe01c7bb38f95973f4a761d1d184cc720
[ "MIT" ]
null
null
null
main.py
rdbende/WhirlEdit
248c36bfe01c7bb38f95973f4a761d1d184cc720
[ "MIT" ]
null
null
null
main.py
rdbende/WhirlEdit
248c36bfe01c7bb38f95973f4a761d1d184cc720
[ "MIT" ]
null
null
null
import os import yaml import tkinter as tk from tkinter import ttk from tkinter import * import tkinter.font as tkfont from tkinter.filedialog import askopenfilename, asksaveasfilename import subprocess import shutil import tkinter import zipfile import tempfile from wday import * from tkcode import CodeEd...
37.671252
1,588
0.61259
import os import yaml import tkinter as tk from tkinter import ttk from tkinter import * import tkinter.font as tkfont from tkinter.filedialog import askopenfilename, asksaveasfilename import subprocess import shutil import tkinter import zipfile import tempfile from wday import * from tkcode import CodeEd...
14,092
1,212
858