hexsha
stringlengths
40
40
size
int64
5
2.06M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
248
max_stars_repo_name
stringlengths
5
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
248
max_issues_repo_name
stringlengths
5
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
248
max_forks_repo_name
stringlengths
5
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
5
2.06M
avg_line_length
float64
1
1.02M
max_line_length
int64
3
1.03M
alphanum_fraction
float64
0
1
count_classes
int64
0
1.6M
score_classes
float64
0
1
count_generators
int64
0
651k
score_generators
float64
0
1
count_decorators
int64
0
990k
score_decorators
float64
0
1
count_async_functions
int64
0
235k
score_async_functions
float64
0
1
count_documentation
int64
0
1.04M
score_documentation
float64
0
1
e2d5d4f0834f8da2bcbaa8cad00c966d5e044936
425
py
Python
stylo/testing/examples.py
mvinoba/stylo
84f3a74cf9cb29c6d24b990dc9a474562114392b
[ "MIT" ]
null
null
null
stylo/testing/examples.py
mvinoba/stylo
84f3a74cf9cb29c6d24b990dc9a474562114392b
[ "MIT" ]
null
null
null
stylo/testing/examples.py
mvinoba/stylo
84f3a74cf9cb29c6d24b990dc9a474562114392b
[ "MIT" ]
null
null
null
import pytest def define_benchmarked_example(name, example): import matplotlib matplotlib.use("Agg") image = example() @pytest.mark.parametrize("n", [512, 1024, 2048]) def benchmark_test(benchmark, n): filename = None if n == 512: filename = "docs/_static/examples...
18.478261
71
0.623529
0
0
0
0
256
0.602353
0
0
38
0.089412
e2d660e0b5ccf4c5de10c851eccbbeca7e9ba7b7
387
py
Python
src/sendmeanemail.py
CoolTechOrganisation/raspberry-api
704d4c5ccef21cf0ea7667b98d07547578e17f51
[ "MIT" ]
null
null
null
src/sendmeanemail.py
CoolTechOrganisation/raspberry-api
704d4c5ccef21cf0ea7667b98d07547578e17f51
[ "MIT" ]
null
null
null
src/sendmeanemail.py
CoolTechOrganisation/raspberry-api
704d4c5ccef21cf0ea7667b98d07547578e17f51
[ "MIT" ]
null
null
null
import smtplib smtpUser = '' smtpPass = '' toAdd = '' fromAdd = smtpUser subject = '' header = 'To: ' + '\n' + 'From: ' + fromAdd + '\n' + 'Subject :' + subject body = '' print header + '\n' + body smtp = smtplib.SMTP('smtp.gmail.com', 587) smtp.ehlo() smtp.starttls() smtp.ehlo() smtp.login(smtpUser, smtpPass)...
16.125
75
0.614987
0
0
0
0
0
0
0
0
69
0.178295
e2d6911a7095478d504ed809314715261924ff4a
1,376
py
Python
examples/original-paper/example-fancylabel.py
aengelke/z-plot
63e4e6656355b608487a3e4df5da13b7fad9b108
[ "BSD-3-Clause" ]
22
2016-10-19T15:02:22.000Z
2021-12-23T12:40:37.000Z
examples/original-paper/example-fancylabel.py
aengelke/z-plot
63e4e6656355b608487a3e4df5da13b7fad9b108
[ "BSD-3-Clause" ]
4
2017-04-16T03:15:48.000Z
2020-10-28T11:36:35.000Z
examples/original-paper/example-fancylabel.py
aengelke/z-plot
63e4e6656355b608487a3e4df5da13b7fad9b108
[ "BSD-3-Clause" ]
11
2017-01-18T02:41:57.000Z
2021-12-28T02:21:30.000Z
#! /usr/bin/env python from zplot import * import sys import random # a simple label/arrow combination function def label_with_arrow(canvas, x, y, text, size, anchor, dx, dy): ax, ay = x, y if anchor == 'top': ay = ay + size elif anchor == 'bottom': ay = ay - size else: print '...
27.52
78
0.619913
0
0
0
0
0
0
0
0
292
0.212209
e2d8e578b36c81838d94eacbe7d5ce89b3fd1df5
2,700
py
Python
pycraft/player.py
PapaMarky/pycraft
919fe000ae7f1d2dd715d0468957d67ca61725b4
[ "MIT" ]
null
null
null
pycraft/player.py
PapaMarky/pycraft
919fe000ae7f1d2dd715d0468957d67ca61725b4
[ "MIT" ]
null
null
null
pycraft/player.py
PapaMarky/pycraft
919fe000ae7f1d2dd715d0468957d67ca61725b4
[ "MIT" ]
null
null
null
import glob import os import python_nbt.nbt as nbt import requests from pycraft.error import PycraftException from pycraft.region import Region class Player: def __init__(self, world_path): if not os.path.exists(world_path): print(f'Saved world not found: "{world_path}"') raise P...
29.67033
94
0.583333
2,551
0.944815
0
0
1,176
0.435556
0
0
556
0.205926
e2da1b80294662dc1e56bd780492fbf92dc01da3
387
py
Python
day13/part2.py
BaderSZ/adventofcode2020
dae705fd093bbd176021118f0898947cb4b02f84
[ "MIT" ]
null
null
null
day13/part2.py
BaderSZ/adventofcode2020
dae705fd093bbd176021118f0898947cb4b02f84
[ "MIT" ]
null
null
null
day13/part2.py
BaderSZ/adventofcode2020
dae705fd093bbd176021118f0898947cb4b02f84
[ "MIT" ]
null
null
null
inp = [] with open("input", "r") as f: for line in f.readlines(): inp = inp + line.rsplit()[0].split(",") # In form (BUS_ID, index) busses = [(int(x), i) for i, x in enumerate(inp[1:]) if x != "x"] # Chinese remainder theorem time = 0 prod = 1 for id, i in busses: while (time + i)%id != 0: ...
17.590909
65
0.542636
0
0
0
0
0
0
0
0
79
0.204134
e2dc3c2e573af6b5ac4a24e0a8a5e7d24b83ef56
1,143
py
Python
setup.py
torstenfeld/django-warrant
ad19b9c9aefb9e44f6a01c07d11dc41809f88881
[ "BSD-3-Clause" ]
167
2017-04-21T17:54:14.000Z
2022-02-19T20:37:44.000Z
setup.py
torstenfeld/django-warrant
ad19b9c9aefb9e44f6a01c07d11dc41809f88881
[ "BSD-3-Clause" ]
15
2017-08-31T12:33:18.000Z
2021-07-03T06:36:36.000Z
setup.py
torstenfeld/django-warrant
ad19b9c9aefb9e44f6a01c07d11dc41809f88881
[ "BSD-3-Clause" ]
56
2017-06-15T17:26:43.000Z
2022-03-30T15:15:42.000Z
import os from setuptools import setup, find_packages def parse_requirements(filename): """ load requirements from a pip requirements file """ lineiter = (line.strip() for line in open(filename)) return [line for line in lineiter if line and not line.startswith("#")] version = '0.1.1' README="""Djang...
28.575
115
0.684164
0
0
0
0
0
0
0
0
518
0.453193
e2dd633808e9b6b31f7be658d3a59c23ec67ec01
1,599
py
Python
src/python/WMCore/WMBS/MySQL/Subscriptions/GetSubsWithoutJobGroup.py
khurtado/WMCore
f74e252412e49189a92962945a94f93bec81cd1e
[ "Apache-2.0" ]
21
2015-11-19T16:18:45.000Z
2021-12-02T18:20:39.000Z
src/python/WMCore/WMBS/MySQL/Subscriptions/GetSubsWithoutJobGroup.py
khurtado/WMCore
f74e252412e49189a92962945a94f93bec81cd1e
[ "Apache-2.0" ]
5,671
2015-01-06T14:38:52.000Z
2022-03-31T22:11:14.000Z
src/python/WMCore/WMBS/MySQL/Subscriptions/GetSubsWithoutJobGroup.py
khurtado/WMCore
f74e252412e49189a92962945a94f93bec81cd1e
[ "Apache-2.0" ]
67
2015-01-21T15:55:38.000Z
2022-02-03T19:53:13.000Z
#!/usr/bin/env python from __future__ import division, print_function from WMCore.Database.DBFormatter import DBFormatter class GetSubsWithoutJobGroup(DBFormatter): """ _GetSubsWithoutJobGroup_ Finds whether there are unfinished subscriptions for Production and Processing task types where JobCreato...
35.533333
89
0.65666
1,472
0.920575
0
0
0
0
0
0
1,017
0.636023
e2ddd4f9ac3b25764edd0fce1bfdd7ca076702ea
1,092
py
Python
experiments/summarize_svdf_linkpred_sweep.py
samihaija/tf-fsvd
677cad8cfa21668369ce39c515874dabfbc021d5
[ "MIT" ]
16
2021-02-18T15:53:24.000Z
2021-11-25T19:50:03.000Z
experiments/summarize_svdf_linkpred_sweep.py
samihaija/tf-fsvd
677cad8cfa21668369ce39c515874dabfbc021d5
[ "MIT" ]
1
2021-05-13T05:23:52.000Z
2021-05-13T05:23:52.000Z
experiments/summarize_svdf_linkpred_sweep.py
samihaija/tf-fsvd
677cad8cfa21668369ce39c515874dabfbc021d5
[ "MIT" ]
2
2021-02-24T16:03:30.000Z
2021-03-13T14:17:06.000Z
import os import glob import collections import json import numpy as np from absl import app, flags flags.DEFINE_string('results_dir', 'results/linkpred_d_sweep/fsvd', 'Directory where run files are written.') FLAGS = flags.FLAGS def main(_): files = glob.glob(os.path.join(FLAGS.results_dir, '*...
29.513514
82
0.623626
0
0
0
0
0
0
0
0
305
0.279304
e2deb7eb7ee2e7c59cb13a91610999e85e9556e5
3,737
py
Python
telegram_crypto_price_bot/message_dispatcher.py
RBBOTDEVELOPER/telegram_crypto_price_bot
88391e22c22bdfecb30bacba9b3bb103ef453d9e
[ "MIT" ]
null
null
null
telegram_crypto_price_bot/message_dispatcher.py
RBBOTDEVELOPER/telegram_crypto_price_bot
88391e22c22bdfecb30bacba9b3bb103ef453d9e
[ "MIT" ]
null
null
null
telegram_crypto_price_bot/message_dispatcher.py
RBBOTDEVELOPER/telegram_crypto_price_bot
88391e22c22bdfecb30bacba9b3bb103ef453d9e
[ "MIT" ]
null
null
null
# Copyright (c) 2021 Emanuele Bellocchia # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish,...
39.336842
79
0.652395
2,294
0.613861
0
0
0
0
0
0
1,571
0.420391
e2df7962b641dd4664ecec2ae0a2c8f36b185a2b
738
py
Python
smallactsmanifesto/signatures/forms.py
luzfcb/smallactsmanifesto
b1fc3ca6de413b8c03a01122014c5c599cb3da40
[ "MIT" ]
11
2015-10-17T02:44:58.000Z
2021-03-05T15:18:59.000Z
smallactsmanifesto/signatures/forms.py
luzfcb/smallactsmanifesto
b1fc3ca6de413b8c03a01122014c5c599cb3da40
[ "MIT" ]
2
2016-01-17T12:06:58.000Z
2018-05-05T19:48:48.000Z
smallactsmanifesto/signatures/forms.py
luzfcb/smallactsmanifesto
b1fc3ca6de413b8c03a01122014c5c599cb3da40
[ "MIT" ]
5
2016-01-16T11:19:31.000Z
2019-06-07T20:13:32.000Z
# coding: utf-8 from django import forms from django.utils.translation import ugettext_lazy as _ from captcha.fields import ReCaptchaField from .models import Signatory from .utils import mark_safe_lazy as safe HELP_CAPTCHA = safe(_('Just a small act to prevent spam. <em>Sorry about this!</em>')) class SignupForm(f...
28.384615
86
0.689702
435
0.589431
0
0
0
0
0
0
119
0.161247
e2dfe764fe9ea5057fc7e5b4b8e6089f8b160246
768
py
Python
packages/ekstep_data_pipelines/audio_analysis/speaker_analysis/file_cluster_mapping.py
jeevan-revaneppa-hirethanad/audio-to-speech-pipeline
a5bd7f0321834507e4157eb1aea8659cd205bf1c
[ "MIT" ]
23
2021-03-20T13:24:37.000Z
2022-03-26T19:02:33.000Z
packages/ekstep_data_pipelines/audio_analysis/speaker_analysis/file_cluster_mapping.py
jeevan-revaneppa-hirethanad/audio-to-speech-pipeline
a5bd7f0321834507e4157eb1aea8659cd205bf1c
[ "MIT" ]
10
2021-04-06T14:00:35.000Z
2022-03-16T12:27:13.000Z
packages/ekstep_data_pipelines/audio_analysis/speaker_analysis/file_cluster_mapping.py
jeevan-revaneppa-hirethanad/audio-to-speech-pipeline
a5bd7f0321834507e4157eb1aea8659cd205bf1c
[ "MIT" ]
16
2021-03-30T10:57:34.000Z
2022-03-23T01:07:19.000Z
import json def save_json(file_path, mappings): with open(file_path, "w+") as file: json.dump(mappings, file) def file_to_speaker_map(speaker_to_file_map): file_to_speaker = {} for speaker in speaker_to_file_map: files = speaker_to_file_map.get(speaker) for file in files: ...
28.444444
88
0.670573
0
0
0
0
0
0
0
0
10
0.013021
e2e061e6b977fbeb127ea4c725ec9eca5c51463c
2,232
py
Python
test_codes/overpass_api.py
WhoaNellie/ShadeWays
ce5629b821b34ef3265fe450177912cbc5918394
[ "MIT" ]
2
2020-01-18T17:30:56.000Z
2020-03-09T04:52:48.000Z
test_codes/overpass_api.py
WhoaNellie/ShadeWays
ce5629b821b34ef3265fe450177912cbc5918394
[ "MIT" ]
null
null
null
test_codes/overpass_api.py
WhoaNellie/ShadeWays
ce5629b821b34ef3265fe450177912cbc5918394
[ "MIT" ]
1
2020-03-09T04:52:55.000Z
2020-03-09T04:52:55.000Z
#!/usr/bin/env python3 import requests import json import sys #area(32.227754,-110.959464,32.236005,-110.944097); overpass_url = "http://overpass-api.de/api/interpreter" overpass_query = """ [out:json]; area[name="Tucson"]; (node["building"="yes"](area); way["building"="yes"](area); rel["building"="yes"](area); ); ...
24.26087
116
0.597222
0
0
0
0
0
0
0
0
1,280
0.573477
e2e20661e6fd1d16b0a0f47887066e3517db1d11
485
py
Python
solutions/tier_04/python/uri_1766_o_elfo_das_trevas.py
EstevaoNaval/URI_repository
373681078f237231a6ec2c5a2ab04be434f54968
[ "MIT" ]
null
null
null
solutions/tier_04/python/uri_1766_o_elfo_das_trevas.py
EstevaoNaval/URI_repository
373681078f237231a6ec2c5a2ab04be434f54968
[ "MIT" ]
null
null
null
solutions/tier_04/python/uri_1766_o_elfo_das_trevas.py
EstevaoNaval/URI_repository
373681078f237231a6ec2c5a2ab04be434f54968
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- qntCaso = int(input()) for caso in range(qntCaso): numTotalRena, numTotalRenaPuxaraoTreno = map(int, input().split()) listRena = [list(map(str, input().split())) for linha in range(numTotalRena)] listRena = sorted(listRena, key= lambda x: (-int(x[1]),int(x[2]),float(x[3]),x[0])...
44.090909
119
0.637113
0
0
0
0
0
0
0
0
46
0.094845
e2e20f39835f5c3307a75b90031b87737e56b9cf
2,754
py
Python
tests/test_signals.py
appsembler/course-cccess-groups
d9c59dc55a3d021196c50e1080d3a251b4751780
[ "MIT" ]
null
null
null
tests/test_signals.py
appsembler/course-cccess-groups
d9c59dc55a3d021196c50e1080d3a251b4751780
[ "MIT" ]
null
null
null
tests/test_signals.py
appsembler/course-cccess-groups
d9c59dc55a3d021196c50e1080d3a251b4751780
[ "MIT" ]
null
null
null
""" Tests for signal handlers. """ import logging import pytest from course_access_groups.models import Membership from course_access_groups.signals import ( on_learner_account_activated, on_learner_register, ) from test_utils.factories import ( MembershipRuleFactory, UserFactory, UserOrganizatio...
33.585366
116
0.755628
0
0
0
0
2,406
0.873638
0
0
905
0.328613
e2e2f5a7e716d47c2bc599311bb54fb09059029e
12,180
py
Python
koku/api/query_handler.py
Vasyka/koku
b5aa9ec41c3b0821e74afe9ff3a5ffaedb910614
[ "Apache-2.0" ]
2
2022-01-12T03:42:39.000Z
2022-01-12T03:42:40.000Z
koku/api/query_handler.py
Vasyka/koku
b5aa9ec41c3b0821e74afe9ff3a5ffaedb910614
[ "Apache-2.0" ]
null
null
null
koku/api/query_handler.py
Vasyka/koku
b5aa9ec41c3b0821e74afe9ff3a5ffaedb910614
[ "Apache-2.0" ]
1
2021-07-21T09:33:59.000Z
2021-07-21T09:33:59.000Z
# # Copyright 2021 Red Hat Inc. # SPDX-License-Identifier: Apache-2.0 # """Query Handling for all APIs.""" import datetime import logging from dateutil import parser from dateutil import relativedelta from django.core.exceptions import FieldDoesNotExist from django.db.models.functions import TruncDay from django.db.mo...
34.213483
116
0.611987
11,621
0.954105
0
0
1,851
0.15197
0
0
4,574
0.375534
e2e33962d911eef3a960dee21f3ec19a3c424ec3
649
py
Python
alertaclient/commands/cmd_group.py
gapitio/python-alerta-client
943a624c2136e952c92fbdfaa80e61b73d949275
[ "Apache-2.0" ]
null
null
null
alertaclient/commands/cmd_group.py
gapitio/python-alerta-client
943a624c2136e952c92fbdfaa80e61b73d949275
[ "Apache-2.0" ]
null
null
null
alertaclient/commands/cmd_group.py
gapitio/python-alerta-client
943a624c2136e952c92fbdfaa80e61b73d949275
[ "Apache-2.0" ]
null
null
null
import sys import click @click.command('group', short_help='Create user group') @click.option('--name', help='Group name') @click.option('--text', help='Description of user group') @click.option('--delete', '-D', metavar='ID', help='Delete user group using ID') @click.pass_obj def cli(obj, name, text, delete): "...
28.217391
80
0.614792
0
0
0
0
621
0.956857
0
0
182
0.280431
e2e34e65edcf19e2167bc7860688291ab0325a3e
1,677
py
Python
hw/hw05/tests/q4c.py
surajrampure/data-94-sp21
074543103579c28d796c681f78f3c38449825328
[ "BSD-3-Clause" ]
1
2020-11-21T09:42:52.000Z
2020-11-21T09:42:52.000Z
hw/hw05/tests/q4c.py
surajrampure/data-94-sp21
074543103579c28d796c681f78f3c38449825328
[ "BSD-3-Clause" ]
null
null
null
hw/hw05/tests/q4c.py
surajrampure/data-94-sp21
074543103579c28d796c681f78f3c38449825328
[ "BSD-3-Clause" ]
null
null
null
test = { 'name': 'q4c', 'points': 2, 'suites': [ { 'cases': [ {'code': ">>> top_lac_schools.labels == ('Name', 'City', 'Region', 'Applied', 'Admitted', 'Enrolled', 'Acceptance Rate')\nTrue", 'hidden': False, 'locked': False}, {'code': '>>> top_lac_schools.num_rows == 1...
83.85
199
0.419201
0
0
0
0
0
0
0
0
919
0.548002
e2e4d33ff1712d3173ec4251c6fe16e0f15be96e
492
py
Python
week2/scripts/hello_publisher.py
ajaykrishna1878/Robotics-Automation-QSTP-2021
f5b8626db20a60f9dd923bab5a0bec118d0abc67
[ "MIT" ]
null
null
null
week2/scripts/hello_publisher.py
ajaykrishna1878/Robotics-Automation-QSTP-2021
f5b8626db20a60f9dd923bab5a0bec118d0abc67
[ "MIT" ]
null
null
null
week2/scripts/hello_publisher.py
ajaykrishna1878/Robotics-Automation-QSTP-2021
f5b8626db20a60f9dd923bab5a0bec118d0abc67
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import rospy from std_msgs.msg import String class hello: def __init__(self): self.word = "Hello," self.pub = rospy.Publisher('/hello', String, queue_size=1) self.rate = rospy.Rate(1) def publish_word(self): while not rospy.is_shutdown(): ...
24.6
66
0.623984
308
0.626016
0
0
0
0
0
0
65
0.132114
e2e5addc85c1fc0d216c3f94ac5274fc2fc64fc0
766
py
Python
core/mask/Template.py
marcostolosa/bluffy
3f6ec810b9ea9bbc04e61c92ce08b48e2730d107
[ "MIT" ]
218
2021-12-03T13:44:46.000Z
2022-03-29T23:59:44.000Z
core/mask/Template.py
Phuong39/bluffy
3f6ec810b9ea9bbc04e61c92ce08b48e2730d107
[ "MIT" ]
1
2022-03-15T21:20:28.000Z
2022-03-15T21:25:26.000Z
core/mask/Template.py
Phuong39/bluffy
3f6ec810b9ea9bbc04e61c92ce08b48e2730d107
[ "MIT" ]
40
2021-12-03T16:58:48.000Z
2022-03-29T23:59:46.000Z
class SVGMgr: def __init__(self, blob: bytes): self.blob = blob self.payload_name = "unsigned char* payload[]" self.chunk_size = 10 def mask(self) -> dict[str:str]: """Mask the data as a X""" # format the blob! return self.format_blob() def format_blob(self...
27.357143
83
0.573107
765
0.998695
0
0
0
0
0
0
290
0.37859
e2e60fefd12f980302a3f8d0677aef2cf55d0964
1,348
py
Python
demos/path/demo_path.py
WisconsinAutonomous/wa_simulator
405a086b16f262fc82513ca9b23fd040e6375945
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
5
2021-02-14T03:56:07.000Z
2021-12-16T04:46:54.000Z
demos/path/demo_path.py
WisconsinAutonomous/wa_simulator
405a086b16f262fc82513ca9b23fd040e6375945
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
1
2021-02-05T19:30:55.000Z
2021-02-05T19:51:21.000Z
demos/path/demo_path.py
WisconsinAutonomous/wa_simulator
405a086b16f262fc82513ca9b23fd040e6375945
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
3
2021-09-20T21:21:12.000Z
2022-01-09T20:49:46.000Z
# Simple path demo # Meant to demonstrate the WA Simulator API # ----------------------------------------------------------------- # Import the simulator import wa_simulator as wa import matplotlib.pyplot as plt # Command line arguments parser = wa.WAArgumentParser(use_sim_defaults=False) parser.add_argument("-p", "-...
31.348837
94
0.626113
0
0
0
0
0
0
0
0
492
0.364985
e2e6e9f256351ec45645abb75d19744b0bc45894
4,684
py
Python
Practice2/Lab3-2_Genre_Classification.py
kiseyno92/SNU_ML
be48a5c570ef59dc2b5a782c828536e100d7f0eb
[ "MIT" ]
1
2017-08-10T10:16:32.000Z
2017-08-10T10:16:32.000Z
Practice2/Lab3-2_Genre_Classification.py
kiseyno92/SNU_ML
be48a5c570ef59dc2b5a782c828536e100d7f0eb
[ "MIT" ]
null
null
null
Practice2/Lab3-2_Genre_Classification.py
kiseyno92/SNU_ML
be48a5c570ef59dc2b5a782c828536e100d7f0eb
[ "MIT" ]
null
null
null
# coding: utf-8 # ### Machine Learning Application - Genre Classification # UDSL-SNU Big Data Academy # 20170725 # ##### Import libraries # In[1]: import h5py import numpy as np import matplotlib.pyplot as plt from sklearn import cross_validation from sklearn.preprocessing import StandardScaler from sklearn.me...
22.411483
86
0.6962
0
0
0
0
0
0
0
0
1,375
0.293553
e2e70943a13008111153a414f22c56d558bfae48
1,232
py
Python
flurry.util/flurry/util/json.py
mccolljr/fete
9342c814db997c8a7b5a1f3b23dd309d463c9718
[ "MIT" ]
1
2022-01-10T20:19:16.000Z
2022-01-10T20:19:16.000Z
flurry.util/flurry/util/json.py
mccolljr/fete
9342c814db997c8a7b5a1f3b23dd309d463c9718
[ "MIT" ]
null
null
null
flurry.util/flurry/util/json.py
mccolljr/fete
9342c814db997c8a7b5a1f3b23dd309d463c9718
[ "MIT" ]
null
null
null
from typing import Any import json import base64 import binascii import datetime as dt __all__ = ("JSON",) class JSON(json.JSONEncoder): """A JSON encoder that supports datetime values.""" def default(self, o): if isinstance(o, dt.datetime): return o.astimezone(dt.timezone.utc).isoform...
27.377778
68
0.582792
1,119
0.908279
0
0
658
0.534091
0
0
118
0.095779
e2e880113fa2ff93a3ecc07d1b229e383a3a5b72
6,023
py
Python
assignments/assignment_clo_worksheet.py
dgrobani/py3_canvaslmi_api
c02c56a33dd196bdf779039c13bb52aa1e88699d
[ "MIT" ]
18
2017-07-20T20:20:39.000Z
2021-09-26T20:16:58.000Z
assignments/assignment_clo_worksheet.py
dgrobani/py3_canvaslmi_api
c02c56a33dd196bdf779039c13bb52aa1e88699d
[ "MIT" ]
null
null
null
assignments/assignment_clo_worksheet.py
dgrobani/py3_canvaslmi_api
c02c56a33dd196bdf779039c13bb52aa1e88699d
[ "MIT" ]
3
2018-05-17T12:07:36.000Z
2021-12-22T23:17:18.000Z
# https://openpyxl.readthedocs.io/ # https://automatetheboringstuff.com/chapter12/ # https://www.ablebits.com/office-addins-blog/2014/09/24/excel-drop-down-list/ # http://stackoverflow.com/questions/18595686/how-does-operator-itemgetter-and-sort-work-in-python from canvas.core.courses import get_course_by_sis_id,...
48.96748
117
0.636062
0
0
0
0
0
0
0
0
1,267
0.21036
e2ead67c7bdbd412472810f4cfc5c65925b61e24
3,949
py
Python
curiefense/curielogserver/curielogserver/ratelimitrecommendation.py
fossabot/curiefense
6941f8aa08bcac1b0cf87c36ddb0037917a38c5a
[ "Apache-2.0" ]
1
2020-11-15T06:27:05.000Z
2020-11-15T06:27:05.000Z
curiefense/curielogserver/curielogserver/ratelimitrecommendation.py
fossabot/curiefense
6941f8aa08bcac1b0cf87c36ddb0037917a38c5a
[ "Apache-2.0" ]
3
2022-02-24T09:58:32.000Z
2022-03-01T20:05:07.000Z
curiefense/curielogserver/curielogserver/ratelimitrecommendation.py
xavier-rbz/curiefense
44200a90c515fe184e9c66ea662b2643adcbd34e
[ "Apache-2.0" ]
1
2021-01-07T20:51:48.000Z
2021-01-07T20:51:48.000Z
import yaml class FeatureAnalysis(object): def __init__(self, **kwargs): self.input_params = {} self.yaml_data = None self.input_params.update(kwargs) self.yaml_data = self._load_yaml() def _load_yaml(self): ''' Read yaml template from path @param file...
30.612403
109
0.627247
3,783
0.957964
0
0
0
0
0
0
746
0.188909
e2eca23998b33c6bcec131356180963aa665068c
7,359
py
Python
tests/test_pool.py
5uper5hoot/PikaExamples
9d3ae7918343ed612c253bf410882575033c80d6
[ "MIT" ]
null
null
null
tests/test_pool.py
5uper5hoot/PikaExamples
9d3ae7918343ed612c253bf410882575033c80d6
[ "MIT" ]
17
2019-01-13T00:18:25.000Z
2020-03-31T01:18:32.000Z
tests/test_pool.py
5uper5hoot/PikaExamples
9d3ae7918343ed612c253bf410882575033c80d6
[ "MIT" ]
null
null
null
""" *********************************************************************** This code has been sourced from https://github.com/bninja/pika-pool/blob/master/pika_pool.py Governed by the following BSD licence sourced from https://github.com/bninja/pika-pool/blob/master/LICENSE. No copyright notice is available. Redistr...
31.314894
79
0.649409
2,976
0.404403
0
0
1,832
0.248947
0
0
2,097
0.284957
e2ed43d6c5005bae2644f44607ee1e0503afb323
702
py
Python
lino_xl/lib/boards/__init__.py
khchine5/xl
b1634937a9ce87af1e948eb712b934b11f221d9d
[ "BSD-2-Clause" ]
1
2018-01-12T14:09:48.000Z
2018-01-12T14:09:48.000Z
lino_xl/lib/boards/__init__.py
khchine5/xl
b1634937a9ce87af1e948eb712b934b11f221d9d
[ "BSD-2-Clause" ]
1
2019-09-10T05:03:47.000Z
2019-09-10T05:03:47.000Z
lino_xl/lib/boards/__init__.py
khchine5/xl
b1634937a9ce87af1e948eb712b934b11f221d9d
[ "BSD-2-Clause" ]
null
null
null
# Copyright 2008-2015 Luc Saffre # # License: BSD (see file COPYING for details) """See :mod:`ml.boards`. .. autosummary:: :toctree: models mixins """ from lino.api import ad, _ class Plugin(ad.Plugin): "See :class:`lino.core.Plugin`." verbose_name = _("Boards") def setup_config_menu(con...
21.272727
67
0.665242
504
0.717949
0
0
0
0
0
0
232
0.330484
e2ed6bd63b9ba47737b8f3f36b327226fa4cd188
1,628
py
Python
setup.py
cfobel/go-posh
29e387d823fcd148cf7020afdbe5b26a56293729
[ "MIT" ]
null
null
null
setup.py
cfobel/go-posh
29e387d823fcd148cf7020afdbe5b26a56293729
[ "MIT" ]
null
null
null
setup.py
cfobel/go-posh
29e387d823fcd148cf7020afdbe5b26a56293729
[ "MIT" ]
null
null
null
#!/usr/bin/env python # Copyright (c) 2002-2008 ActiveState Software # Author: Trent Mick (trentm@gmail.com) """Quick directory changing (super-cd) 'go' is a simple command line script to simplify jumping between directories in the shell. You can create shortcut names for commonly used directories and invoke ...
28.068966
72
0.668919
0
0
0
0
0
0
0
0
920
0.565111
e2f0f6178903796c7342081af199f0f30fa8ed96
2,294
py
Python
refinery/bnpy/bnpy-dev/tests/end-to-end/TestProxFunc.py
csa0001/Refinery
0d5de8fc3d680a2c79bd0e9384b506229787c74f
[ "MIT" ]
103
2015-01-13T00:48:14.000Z
2021-11-08T10:53:22.000Z
refinery/bnpy/bnpy-dev/tests/end-to-end/TestProxFunc.py
csa0001/Refinery
0d5de8fc3d680a2c79bd0e9384b506229787c74f
[ "MIT" ]
7
2015-02-21T04:03:40.000Z
2021-08-23T20:24:54.000Z
refinery/bnpy/bnpy-dev/tests/end-to-end/TestProxFunc.py
csa0001/Refinery
0d5de8fc3d680a2c79bd0e9384b506229787c74f
[ "MIT" ]
27
2015-01-23T00:54:31.000Z
2020-12-30T14:30:50.000Z
''' Unit tests to verify that our proposed proximity functions work as expected. Proximity function (defined in Util) are used to determine if two estimated parameters are "close enough" within some numerical tolerance to be treated as equivalent. We eventually use these functions to assess whether learning algorithms...
32.309859
307
0.672188
1,829
0.797297
0
0
0
0
0
0
570
0.248474
e2f30d3a34d3afe633e7babc6d3703910a51d3d8
173
py
Python
ProgettiHWSW/const.py
ArdaSeremet/progettihwsw
565d1fb35d88d3e7c272c03b8a190231179cce74
[ "MIT" ]
1
2020-08-28T21:46:12.000Z
2020-08-28T21:46:12.000Z
ProgettiHWSW/const.py
ArdaSeremet/progettihwsw
565d1fb35d88d3e7c272c03b8a190231179cce74
[ "MIT" ]
null
null
null
ProgettiHWSW/const.py
ArdaSeremet/progettihwsw
565d1fb35d88d3e7c272c03b8a190231179cce74
[ "MIT" ]
null
null
null
# Copyright (c) 2020 Arda Seremet <ardaseremet@outlook.com> TURN_ON_BASE = 16 TURN_OFF_BASE = 116 TOGGLE_BASE = 0 TEMP_MONOSTABLE_BASE = 200 STATUS_XML_PATH = "status.xml"
21.625
59
0.780347
0
0
0
0
0
0
0
0
71
0.410405
e2f3bc60879bf6291053573473efb8979f222e3a
3,672
py
Python
UforFunction.py
DezhengLee/Labster
561c522d6d3d0b4b70c667d2f9a1d16e1734affc
[ "Apache-2.0" ]
1
2021-09-27T14:26:20.000Z
2021-09-27T14:26:20.000Z
UforFunction.py
DezhengLee/Labster
561c522d6d3d0b4b70c667d2f9a1d16e1734affc
[ "Apache-2.0" ]
null
null
null
UforFunction.py
DezhengLee/Labster
561c522d6d3d0b4b70c667d2f9a1d16e1734affc
[ "Apache-2.0" ]
null
null
null
from sympy import * from sympy.abc import * import functions as func from decimal import * def findAbsFuncU(function, U, variable, means, roundornot=True): """ This function is used to find the absolut compound U, as well as the values of U of temp variables :param function: (String) the formula ...
31.384615
103
0.572168
0
0
0
0
0
0
0
0
984
0.267974
e2f68d2c703206d782b3bf27baf1eb812e1e2a22
489
py
Python
swid_generator/meta.py
xgdfalcon/swidGenerator
367706d93d6f6ec2407d695b96446dd704d1ab87
[ "MIT" ]
13
2015-10-16T18:28:32.000Z
2021-08-29T09:36:08.000Z
swid_generator/meta.py
sthagen/swidGenerator
b70f9bef402de11bc2d226b4379d18dc490ec7fd
[ "MIT" ]
11
2018-07-03T13:34:08.000Z
2019-04-10T10:29:29.000Z
swid_generator/meta.py
sthagen/swidGenerator
b70f9bef402de11bc2d226b4379d18dc490ec7fd
[ "MIT" ]
12
2017-02-22T14:51:10.000Z
2022-03-23T16:55:20.000Z
# -*- coding: utf-8 -*- """ This module contains metadata about the project. """ from __future__ import unicode_literals title = 'swid_generator' version = '1.1.0' description = 'Application which generates SWID-Tags from Linux installed packages, package-files and ' \ 'directories using tools like DPGK ...
34.928571
105
0.711656
0
0
0
0
0
0
0
0
360
0.734694
e2f6de5e5cb0ff1bac4f2a109787e36e831a69bb
3,946
py
Python
tombot/registry.py
TijmenW/tom-bot
e9368a41562496761a111c28697384730f43db0e
[ "MIT" ]
1
2020-02-02T21:41:01.000Z
2020-02-02T21:41:01.000Z
tombot/registry.py
TijmenW/tom-bot
e9368a41562496761a111c28697384730f43db0e
[ "MIT" ]
1
2021-05-17T13:14:30.000Z
2021-05-17T13:14:30.000Z
tombot/registry.py
TijmenW/tom-bot
e9368a41562496761a111c28697384730f43db0e
[ "MIT" ]
2
2020-02-19T17:20:46.000Z
2020-07-29T18:51:10.000Z
''' Contains generalized events and the command handlers. ''' #pylint: disable=too-few-public-methods import logging import types from collections import defaultdict # Events # Event constants: # Format: NAME = 'identifier' # when, (args) BOT_START = 'tombot.bot.start' # bot's start, (bot) BOT_SHUTD...
32.081301
95
0.650025
2,029
0.514192
0
0
0
0
0
0
1,303
0.330208
e2f78778d85f1d18a46b7ce5d657b1b24b664e70
638
py
Python
whist/game_events.py
PeterSR/pywhist
b66e92974c374d92fb34d28ed20e5af6940175b0
[ "MIT" ]
null
null
null
whist/game_events.py
PeterSR/pywhist
b66e92974c374d92fb34d28ed20e5af6940175b0
[ "MIT" ]
null
null
null
whist/game_events.py
PeterSR/pywhist
b66e92974c374d92fb34d28ed20e5af6940175b0
[ "MIT" ]
null
null
null
from dataclasses import dataclass from .cards import Trick from .player import Player from .partners import TeamID from .game_actions import BaseAction class BaseEvent: pass @dataclass(frozen=True) class ActionTakenEvent(BaseEvent): player: Player action: BaseAction def __str__(self): retu...
20.580645
65
0.722571
428
0.670846
0
0
451
0.706897
0
0
92
0.144201
e2f92c07c25bcc67308a2cb5dcae80b8b541482b
35
py
Python
junn/common/__init__.py
modsim/junn
a40423b98c6a3739dd0b2ba02d546a5db91f9215
[ "BSD-2-Clause" ]
null
null
null
junn/common/__init__.py
modsim/junn
a40423b98c6a3739dd0b2ba02d546a5db91f9215
[ "BSD-2-Clause" ]
null
null
null
junn/common/__init__.py
modsim/junn
a40423b98c6a3739dd0b2ba02d546a5db91f9215
[ "BSD-2-Clause" ]
null
null
null
"""Common functionality module."""
17.5
34
0.714286
0
0
0
0
0
0
0
0
34
0.971429
e2f98c7ebc2068e8843a92cd18ee6c291058f255
425
py
Python
unsupervised/clustering/ICluster.py
erickfmm/ML-experiments
b1e81b8eea976efeda6e4dc70af747628a6eb43a
[ "MIT" ]
null
null
null
unsupervised/clustering/ICluster.py
erickfmm/ML-experiments
b1e81b8eea976efeda6e4dc70af747628a6eb43a
[ "MIT" ]
null
null
null
unsupervised/clustering/ICluster.py
erickfmm/ML-experiments
b1e81b8eea976efeda6e4dc70af747628a6eb43a
[ "MIT" ]
null
null
null
from abc import ABCMeta, abstractmethod import unsupervised.clustering.utils.initial_assignments as init_assign class ICluster: __metaclass__ = ABCMeta def __init__(self, data): self.X = data self.assign = [] self.centroids = [] self.initial_assignment = init_assign.random_assig...
32.692308
78
0.731765
312
0.734118
0
0
94
0.221176
0
0
0
0
e2fa0aa5791ecb78f7681d90c87d0dd344dafd21
990
py
Python
easy/108-convert-sorted-array-to-binary-search-tree.py
wanglongjiang/leetcode
c61d2e719e81575cfb5bde9d64e15cee7cf01ef3
[ "MIT" ]
2
2021-03-14T11:38:26.000Z
2021-03-14T11:38:30.000Z
easy/108-convert-sorted-array-to-binary-search-tree.py
wanglongjiang/leetcode
c61d2e719e81575cfb5bde9d64e15cee7cf01ef3
[ "MIT" ]
null
null
null
easy/108-convert-sorted-array-to-binary-search-tree.py
wanglongjiang/leetcode
c61d2e719e81575cfb5bde9d64e15cee7cf01ef3
[ "MIT" ]
1
2022-01-17T19:33:23.000Z
2022-01-17T19:33:23.000Z
''' 将有序数组转换为二叉搜索树 给你一个整数数组 nums ,其中元素已经按 升序 排列,请你将其转换为一棵 高度平衡 二叉搜索树。 高度平衡 二叉树是一棵满足「每个节点的左右两个子树的高度差的绝对值不超过 1 」的二叉树。 ''' from typing import List class TreeNode: def __init__(self, val=0, left=None, right=None): self.val = val self.left = left self.right = right ''' 思路:递归创建树。 时间复杂度:O(n) 空间...
25.384615
98
0.570707
787
0.636731
0
0
0
0
0
0
415
0.335761
e2faad4c3d7b7b278b5e577d4bcd74c44ae6ecb8
1,863
py
Python
Downloader.py
mozdren/IPCamMozRecord
f5ce1d3725af65137468e2ecb948dda3b9d584dd
[ "MIT" ]
null
null
null
Downloader.py
mozdren/IPCamMozRecord
f5ce1d3725af65137468e2ecb948dda3b9d584dd
[ "MIT" ]
null
null
null
Downloader.py
mozdren/IPCamMozRecord
f5ce1d3725af65137468e2ecb948dda3b9d584dd
[ "MIT" ]
null
null
null
import urllib2 import threading import Configuration import cv def download(url): try: response = urllib2.urlopen(url, timeout = 5) data = response.read() return data except Exception, e: print str(e) return None class DownloaderThread(threading.Thread): def __init_...
31.576271
85
0.602791
1,401
0.752013
0
0
0
0
0
0
55
0.029522
e2fb4f7486995eba5533445b1969c67b56305d0a
1,310
py
Python
src/SNA_compute_AI.py
soham1112/spider-networks
0607f54044f2b16de8f543df4755c5ce3875e153
[ "MIT" ]
null
null
null
src/SNA_compute_AI.py
soham1112/spider-networks
0607f54044f2b16de8f543df4755c5ce3875e153
[ "MIT" ]
null
null
null
src/SNA_compute_AI.py
soham1112/spider-networks
0607f54044f2b16de8f543df4755c5ce3875e153
[ "MIT" ]
null
null
null
#=============================================================================== # SM 2/2016 # Code exclusively for computing association_index_attacker using full # association index given the pair of attackers (M, N) and data D. #=============================================================================== import...
26.2
91
0.51145
0
0
0
0
0
0
0
0
451
0.344275
e2fbe936b6cb25bafa6c922903345c6baab44779
8,800
py
Python
pynet/datasets/cub.py
Duplums/pynet
5f91dc2e80c2eb4e44d57403dd65aa80e8a5875b
[ "CECILL-B" ]
null
null
null
pynet/datasets/cub.py
Duplums/pynet
5f91dc2e80c2eb4e44d57403dd65aa80e8a5875b
[ "CECILL-B" ]
null
null
null
pynet/datasets/cub.py
Duplums/pynet
5f91dc2e80c2eb4e44d57403dd65aa80e8a5875b
[ "CECILL-B" ]
null
null
null
import os import torch import logging from PIL import Image from itertools import compress from torch.utils.data import DataLoader, RandomSampler, SequentialSampler import torchvision.transforms as transforms from torchvision.datasets import ImageFolder from pynet.datasets.core import AbstractDataManager, DataItem, Set...
47.826087
123
0.617727
8,432
0.958182
0
0
987
0.112159
0
0
2,648
0.300909
e2fcbd9acf6f2cb524344b5614e1587fae9a574d
1,734
py
Python
scripts/test.py
xinchaosong/rdda_ur5_control
309f381b9a3fc975b9d6c70de35fc778d3a1064f
[ "BSD-3-Clause" ]
6
2020-10-05T03:11:49.000Z
2021-08-23T19:04:47.000Z
scripts/test.py
xinchaosong/rdda_ur5_control
309f381b9a3fc975b9d6c70de35fc778d3a1064f
[ "BSD-3-Clause" ]
null
null
null
scripts/test.py
xinchaosong/rdda_ur5_control
309f381b9a3fc975b9d6c70de35fc778d3a1064f
[ "BSD-3-Clause" ]
1
2020-10-05T03:11:54.000Z
2020-10-05T03:11:54.000Z
#!/usr/bin/env python from time import sleep import rospy from rdda_ur5_control.srv import SetRddaParam, RddaData, Move, MoveTraj, NoParam if __name__ == "__main__": rospy.wait_for_service('rdda_ur5_control/home_rdda') rospy.wait_for_service('rdda_ur5_control/set_rdda_stiffness') rospy.wait_for_service('r...
41.285714
100
0.707036
0
0
0
0
0
0
0
0
751
0.433103
e2fd80e0dd958c8f4932541c7c796d5fba2375bb
24,569
py
Python
smp_manifold_learning/scripts/vae_analysis.py
gsutanto/smp_manifold_learning
60ef8278942c784c8d3bcd0a09031475f80d96fb
[ "MIT" ]
11
2020-09-26T12:13:01.000Z
2022-03-23T07:34:14.000Z
smp_manifold_learning/scripts/vae_analysis.py
gsutanto/smp_manifold_learning
60ef8278942c784c8d3bcd0a09031475f80d96fb
[ "MIT" ]
1
2021-04-10T10:42:28.000Z
2021-04-16T07:04:26.000Z
smp_manifold_learning/scripts/vae_analysis.py
gsutanto/smp_manifold_learning
60ef8278942c784c8d3bcd0a09031475f80d96fb
[ "MIT" ]
5
2020-09-24T18:52:46.000Z
2022-03-23T07:26:15.000Z
#!/usr/bin/env python3 import numpy as np import os import dill import json import pandas as pd import torch import matplotlib.pyplot as plt import plotly.graph_objects as go from smp_manifold_learning.motion_planner.feature import SphereFeature, LoopFeature from smp_manifold_learning.differentiable_models.utils impor...
39.949593
148
0.53421
7,995
0.32541
0
0
0
0
0
0
5,500
0.223859
e2fd8380ddf10eda9c6d44420cfcef69f1e223b3
1,062
py
Python
app/request.py
lorderonnie/ronniesblog
11bb3ebf96e49a52c5fbc36f098e262e03334872
[ "MIT" ]
null
null
null
app/request.py
lorderonnie/ronniesblog
11bb3ebf96e49a52c5fbc36f098e262e03334872
[ "MIT" ]
null
null
null
app/request.py
lorderonnie/ronniesblog
11bb3ebf96e49a52c5fbc36f098e262e03334872
[ "MIT" ]
null
null
null
import urllib.request,json from .models import Quote get_quote_url='http://quotes.stormconsultancy.co.uk/random.json' def get_quote(): ''' This gets thejson respond and allows you to access the url information ''' with urllib.request.urlopen(get_quote_url) as url: get_quote_data = url.read(...
22.125
74
0.619586
0
0
0
0
0
0
0
0
236
0.222222
e2fdc91e625cb3fb22bf10795f9fa82f5dac02f9
222
py
Python
ioc_writer/__init__.py
mandiant/ioc_writer
712247f3a10bdc2584fa18ac909fc763f71df21a
[ "Apache-2.0" ]
167
2015-01-05T00:58:07.000Z
2022-03-22T18:20:22.000Z
ioc_writer/__init__.py
vitty84/ioc_writer
712247f3a10bdc2584fa18ac909fc763f71df21a
[ "Apache-2.0" ]
5
2016-05-26T15:24:07.000Z
2017-12-11T05:23:41.000Z
ioc_writer/__init__.py
mandiant/ioc_writer
712247f3a10bdc2584fa18ac909fc763f71df21a
[ "Apache-2.0" ]
60
2015-03-15T23:33:14.000Z
2022-01-12T23:19:53.000Z
from ioc_writer import ioc_api from ioc_writer import ioc_et from ioc_writer import ioc_common from ioc_writer import utils from ioc_writer import managers __all__ = ['ioc_api', 'ioc_common', 'ioc_et', 'utils', 'managers']
37
66
0.806306
0
0
0
0
0
0
0
0
46
0.207207
39018e67f03e1e9f61e5f82b904d4555c3dc4529
3,537
py
Python
github_sync.py
polifonia-project/polifonia_dashboard
7a2ad585eb5adc3726ff8c6585cc7d1061507e77
[ "0BSD" ]
null
null
null
github_sync.py
polifonia-project/polifonia_dashboard
7a2ad585eb5adc3726ff8c6585cc7d1061507e77
[ "0BSD" ]
2
2022-03-09T21:43:19.000Z
2022-03-15T18:13:51.000Z
github_sync.py
polifonia-project/polifonia_dashboard
7a2ad585eb5adc3726ff8c6585cc7d1061507e77
[ "0BSD" ]
null
null
null
import os , json import requests from github import Github, InputGitAuthor import conf dir_path = os.path.dirname(os.path.realpath(__file__)) # OAUTH APP clientId = conf.clientID clientSecret = conf.clientSecret def ask_user_permission(code): """ get user permission when authenticating via github""" res = None ...
33.685714
112
0.729714
0
0
0
0
0
0
0
0
1,013
0.286239
3901f5052217f31c1711d03d87f6b9db3214ccf0
1,928
py
Python
pubs_converter/converter.py
IntelAgir-Research-Group/intelagir-research-group.github.io
5ab3572c1ac08b4819b2a0df26516d6127ce0a35
[ "MIT" ]
null
null
null
pubs_converter/converter.py
IntelAgir-Research-Group/intelagir-research-group.github.io
5ab3572c1ac08b4819b2a0df26516d6127ce0a35
[ "MIT" ]
null
null
null
pubs_converter/converter.py
IntelAgir-Research-Group/intelagir-research-group.github.io
5ab3572c1ac08b4819b2a0df26516d6127ce0a35
[ "MIT" ]
2
2021-02-08T16:23:33.000Z
2022-01-05T20:19:44.000Z
# install package before running: # pip install bibtexparser import bibtexparser with open('publications.bib') as bibtex_file: # bib_database = bibtexparser.load(bibtex_file) bib_database = bibtexparser.bparser.BibTexParser(common_strings=True).parse_file(bibtex_file) md_string = "" for entry in bib_database...
31.606557
97
0.604772
0
0
0
0
0
0
0
0
827
0.428942
39029f6c2c31cf4b23816a7a341ec805e7421baa
698
py
Python
[OPMan]/Seasonals [TV]/2011-4 - Fall/[a8292] Ben-To/setup.py
LightArrowsEXE/Encoding-Projects
4ea96a5b25a7710f615ada5ff25949c496492b53
[ "MIT" ]
57
2019-01-31T17:32:46.000Z
2022-03-23T05:46:51.000Z
[OPMan]/Seasonals [TV]/2011-4 - Fall/[a8292] Ben-To/setup.py
LightArrowsEXE/Encoding-Projects
4ea96a5b25a7710f615ada5ff25949c496492b53
[ "MIT" ]
null
null
null
[OPMan]/Seasonals [TV]/2011-4 - Fall/[a8292] Ben-To/setup.py
LightArrowsEXE/Encoding-Projects
4ea96a5b25a7710f615ada5ff25949c496492b53
[ "MIT" ]
12
2019-04-30T06:16:13.000Z
2022-03-14T16:15:07.000Z
#!/usr/bin/env python3 import setuptools with open("requirements.txt") as fh: install_requires = fh.read() name = "bento_filters" version = "1.0.0" release = "1.0.0" setuptools.setup( name=name, version=release, author="LightArrowsEXE", author_email="Lightarrowsreboot@gmail.com", description...
23.266667
58
0.640401
0
0
0
0
0
0
0
0
316
0.451429
39030dc4ca3d919715e730ef09db812f228c6f4a
5,256
py
Python
nips17_proto/proto.py
hli2020/proto_net
e95ee26a2d68ecdb6ddd701b5ef4029202e33742
[ "MIT" ]
2
2019-07-06T08:04:51.000Z
2019-10-18T12:27:16.000Z
nips17_proto/proto.py
hli2020/proto_net
e95ee26a2d68ecdb6ddd701b5ef4029202e33742
[ "MIT" ]
null
null
null
nips17_proto/proto.py
hli2020/proto_net
e95ee26a2d68ecdb6ddd701b5ef4029202e33742
[ "MIT" ]
1
2021-01-26T02:56:46.000Z
2021-01-26T02:56:46.000Z
# coding=utf-8 from tqdm import tqdm import sys import argparse from torch import optim from basic_opt import * from prototypical_loss import prototypical_loss as loss_fn from protonet import ProtoNet sys.path.append(os.getcwd()) from dataset.data_loader import data_loader from torch.optim.lr_scheduler import MultiSte...
38.086957
116
0.660769
0
0
0
0
0
0
0
0
1,146
0.218037
39047cc2529d32fdf0736bc253ad9e235e31b909
2,141
py
Python
scene_cutter/scene_cutter.py
Zselter07/ffmpeg_scene_cutter
b78237acfe233a1897ef5d12a7745589d21ef0c4
[ "MIT" ]
null
null
null
scene_cutter/scene_cutter.py
Zselter07/ffmpeg_scene_cutter
b78237acfe233a1897ef5d12a7745589d21ef0c4
[ "MIT" ]
null
null
null
scene_cutter/scene_cutter.py
Zselter07/ffmpeg_scene_cutter
b78237acfe233a1897ef5d12a7745589d21ef0c4
[ "MIT" ]
null
null
null
import os from typing import Optional, List from kcu import sh, kpath def create_scenes( in_path: str, output_folder_path: str, threshold: float=0.5, min_scene_duration: float=1.5, max_scene_duration: float=30, debug: bool=False ) -> Optional[List[str]]: os.makedirs(output_folder_path,...
33.984127
124
0.643624
0
0
0
0
0
0
0
0
255
0.119103
3904fe36e254754cd9d0f734bd1f20cf48a463ed
1,294
py
Python
tutorials/source/1.parameterized_quantum_circuit.py
Takishima/mindquantum
e90dfe474b759023d7ae18281b9a87cb8d223d04
[ "Apache-2.0" ]
null
null
null
tutorials/source/1.parameterized_quantum_circuit.py
Takishima/mindquantum
e90dfe474b759023d7ae18281b9a87cb8d223d04
[ "Apache-2.0" ]
null
null
null
tutorials/source/1.parameterized_quantum_circuit.py
Takishima/mindquantum
e90dfe474b759023d7ae18281b9a87cb8d223d04
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2022 <Huawei Technologies Co., Ltd> # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unle...
22.701754
76
0.673107
0
0
0
0
0
0
0
0
812
0.627512
39057e3e32745631eb166e612031e1b4eb2801c6
5,097
py
Python
.executor/arch-package/t2ec-lib/arch-update.py
gh0zialfat1h/dotfiles
d9b3f93ea6301ec65ed8140b6c6180d7166f3623
[ "MIT" ]
3
2021-06-02T04:54:09.000Z
2021-06-06T04:29:01.000Z
.executor/arch-package/t2ec-lib/arch-update.py
0xft1h/dotfiles
d9b3f93ea6301ec65ed8140b6c6180d7166f3623
[ "MIT" ]
null
null
null
.executor/arch-package/t2ec-lib/arch-update.py
0xft1h/dotfiles
d9b3f93ea6301ec65ed8140b6c6180d7166f3623
[ "MIT" ]
null
null
null
#!/usr/bin/python # _*_ coding: utf-8 _*_ """ # Author: Piotr Miller # e-mail: nwg.piotr@gmail.com # Website: http://nwg.pl # Project: https://github.com/nwg-piotr/tint2-executors # License: GPL3 # Credits: RaphaelRochet/arch-update # https://github.com/RaphaelRochet/arch-update # Icon by @edskeye Arguments [-C<aur_...
33.313725
134
0.530116
0
0
0
0
0
0
0
0
1,865
0.365902
3905bcd7408ea63d921f3109b9efc0c9b7cc46b6
21,558
py
Python
tests/unit/test_doc.py
alexey-zhukovin/salt
87382072abf353f3da62ae4e2d9fe1ba14344efa
[ "Apache-2.0" ]
1
2021-09-06T00:14:04.000Z
2021-09-06T00:14:04.000Z
tests/unit/test_doc.py
alexey-zhukovin/salt
87382072abf353f3da62ae4e2d9fe1ba14344efa
[ "Apache-2.0" ]
2
2021-04-30T21:17:57.000Z
2021-12-13T20:40:23.000Z
tests/unit/test_doc.py
Kamatera/salt
ac960a3308617657d9d039dae9108e0045ab3929
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ tests.unit.doc_test ~~~~~~~~~~~~~~~~~~~~ """ # Import Python libs from __future__ import absolute_import import collections import logging import os import re # Import Salt libs import salt.modules.cmdmod import salt.utils.files import salt.utils.platform from tests.support.runtes...
35.810631
105
0.583728
21,101
0.978801
0
0
3,472
0.161054
0
0
8,985
0.416783
3905f2e565555cf20834bdf278a2d30e0b9efa4d
733
py
Python
segment_level/scripts/combine_gismo_clusters_generate_saf.py
gtonkinhill/falciparum_transcriptome_manuscript
e7a9d33715264c741abfee77253e2244f5a8d91a
[ "MIT" ]
null
null
null
segment_level/scripts/combine_gismo_clusters_generate_saf.py
gtonkinhill/falciparum_transcriptome_manuscript
e7a9d33715264c741abfee77253e2244f5a8d91a
[ "MIT" ]
null
null
null
segment_level/scripts/combine_gismo_clusters_generate_saf.py
gtonkinhill/falciparum_transcriptome_manuscript
e7a9d33715264c741abfee77253e2244f5a8d91a
[ "MIT" ]
1
2020-12-10T13:56:42.000Z
2020-12-10T13:56:42.000Z
import glob mult=1 with open("combined_blocks_clustered.csv", 'w') as outfile: for f in glob.glob("*hierarchical_clusters.csv"): print f with open(f, 'rU') as infile: if mult==1: outfile.write(infile.next()) else: infile.next() for line in infile: line = line.strip()...
25.275862
92
0.575716
0
0
0
0
0
0
0
0
117
0.159618
3906a98a261906d140cb30e83a28612005b970ab
1,913
py
Python
tailorpad/admin/doctype/product_options/product_options.py
LaganJ/Tailoring
2c527e229871c5292a9ed7c92967219b756ba99d
[ "MIT" ]
2
2022-03-21T18:09:21.000Z
2022-03-22T05:47:50.000Z
tailorpad/admin/doctype/product_options/product_options.py
LaganJ/Tailoring
2c527e229871c5292a9ed7c92967219b756ba99d
[ "MIT" ]
null
null
null
tailorpad/admin/doctype/product_options/product_options.py
LaganJ/Tailoring
2c527e229871c5292a9ed7c92967219b756ba99d
[ "MIT" ]
1
2022-03-28T14:28:13.000Z
2022-03-28T14:28:13.000Z
# Copyright (c) 2022, White Hat Global and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe import _ from frappe.utils import cint, cstr from frappe.model.document import Document class ProductOptions(Document): def validate(self): sel...
32.982759
98
0.738108
1,433
0.749085
0
0
0
0
0
0
439
0.229482
390bc903243dbca726f91a88351ec6f06ced30c7
151
py
Python
tcplotter/__init__.py
HUGG/gchron-plotters
6f8115c62431030f59bbe6203b243f88d96527e0
[ "MIT" ]
null
null
null
tcplotter/__init__.py
HUGG/gchron-plotters
6f8115c62431030f59bbe6203b243f88d96527e0
[ "MIT" ]
5
2022-02-04T07:13:32.000Z
2022-03-15T14:15:04.000Z
tcplotter/__init__.py
HUGG/gchron-plotters
6f8115c62431030f59bbe6203b243f88d96527e0
[ "MIT" ]
null
null
null
from .tcplotter import time_vs_temp from .tcplotter import eu_vs_radius from .tcplotter import rate_vs_radius_eu from .tcplotter import rate_vs_age_tc
30.2
40
0.86755
0
0
0
0
0
0
0
0
0
0
390da76a8bf622886139deafd78e028a0a5a866c
884
py
Python
display_sars_cov2_infection_study_results.py
vporubsky/COMBINE_2020_reproducibility
43ae5cda128845fbb1d63bc22dc97c0afff04c0c
[ "Apache-2.0" ]
null
null
null
display_sars_cov2_infection_study_results.py
vporubsky/COMBINE_2020_reproducibility
43ae5cda128845fbb1d63bc22dc97c0afff04c0c
[ "Apache-2.0" ]
null
null
null
display_sars_cov2_infection_study_results.py
vporubsky/COMBINE_2020_reproducibility
43ae5cda128845fbb1d63bc22dc97c0afff04c0c
[ "Apache-2.0" ]
null
null
null
'''display_sars_cov2_infection_study_results.py This script is executed using the CMD tag in the Dockerfile in order to display modeling study results to the console and to an html site allocated on the host machine. ''' from flask import Flask, render_template from shutil import move from os import getcwd app = Flas...
36.833333
98
0.757919
0
0
0
0
95
0.107466
0
0
452
0.511312
3912b626fb6eea72b992a53c272a97d250910d77
871
py
Python
instagram_scraper/proxy.py
smb-h/instagram-scraper
7c9a5ec99b825ed975b4acc71c970f0853e82eb4
[ "Unlicense" ]
null
null
null
instagram_scraper/proxy.py
smb-h/instagram-scraper
7c9a5ec99b825ed975b4acc71c970f0853e82eb4
[ "Unlicense" ]
3
2022-01-13T04:22:06.000Z
2022-03-12T01:04:48.000Z
instagram_scraper/proxy.py
smb-h/instagram-scraper
7c9a5ec99b825ed975b4acc71c970f0853e82eb4
[ "Unlicense" ]
1
2021-04-27T07:59:28.000Z
2021-04-27T07:59:28.000Z
import requests from stem import Signal from stem.control import Controller from fake_useragent import UserAgent import random, time headers = { 'User-Agent': UserAgent().random } print(requests.get('https://ident.me', headers=headers).text) proxies = { 'http': 'socks5://127.0.0.1:9050', 'https': 'socks5://...
26.393939
83
0.718714
0
0
0
0
0
0
0
0
274
0.314581
3916c639b5db2d10c51e8dc556530287daecff0c
2,781
py
Python
src/preprocess/remove_duplicate.py
yogendra-yatnalkar/AI_for_any_game_using_CNN
be398c86f61d211534b6b709c5501f2276735552
[ "MIT" ]
1
2020-05-31T13:02:48.000Z
2020-05-31T13:02:48.000Z
src/preprocess/remove_duplicate.py
yogendra-yatnalkar/AI_for_any_game_using_CNN
be398c86f61d211534b6b709c5501f2276735552
[ "MIT" ]
null
null
null
src/preprocess/remove_duplicate.py
yogendra-yatnalkar/AI_for_any_game_using_CNN
be398c86f61d211534b6b709c5501f2276735552
[ "MIT" ]
null
null
null
from PIL import Image import imagehash import os import pandas as pd class RemoveDuplicate: def __init__(self,img_ds_path, csv_file_path = None, csv_file_name = 'dataset.csv'): self.img_ds_path = img_ds_path self.hash_db = set() self.count_duplicate = 0 self.count_corrupt = 0 ...
44.142857
127
0.512046
2,710
0.97447
0
0
0
0
0
0
520
0.186983
3918401a1115c32350535dad538e1deab5215e1f
1,327
py
Python
boa/argparse.py
malice-labs/boa
49c1fd24e2050f8e08409a6871b7e30c6d1e27f7
[ "MIT" ]
3
2020-08-10T04:24:45.000Z
2022-03-16T07:22:11.000Z
boa/argparse.py
malice-labs/boa
49c1fd24e2050f8e08409a6871b7e30c6d1e27f7
[ "MIT" ]
15
2020-08-09T22:01:32.000Z
2022-03-18T04:15:53.000Z
boa/argparse.py
malice-labs/boa
49c1fd24e2050f8e08409a6871b7e30c6d1e27f7
[ "MIT" ]
2
2021-02-04T16:25:57.000Z
2021-12-20T20:07:58.000Z
""" argparse.py Argument parser helper for both the UWSGI runner and CLI Credits: https://mike.depalatis.net/blog/simplifying-argparse.html """ import sys import argparse HEADER = """ ___. \_ |__ _________ | __ \ / _ \__ \ | \_\ ( <_> ) __ \_ |___ /\____(____ / \/ ...
25.037736
75
0.654861
0
0
0
0
0
0
0
0
643
0.484552
39190f6f95541bce0a5214eb986ad0051aecedc4
2,420
py
Python
HierStack/hierarchy.py
manisa/ClassifyTE
e186a6a6d4fcc4f6a9fc3ccc234f66c58a3d1b93
[ "MIT" ]
11
2020-09-24T02:12:22.000Z
2022-03-11T09:55:08.000Z
HierStack/hierarchy.py
manisa/ClassifyTE
e186a6a6d4fcc4f6a9fc3ccc234f66c58a3d1b93
[ "MIT" ]
2
2020-09-24T02:17:53.000Z
2021-03-10T00:59:47.000Z
HierStack/hierarchy.py
manisa/ClassifyTE
e186a6a6d4fcc4f6a9fc3ccc234f66c58a3d1b93
[ "MIT" ]
3
2021-04-08T05:45:36.000Z
2021-12-30T19:18:15.000Z
import networkx as nx import pandas as pd import numpy as np class hierarchy: G=nx.DiGraph() def __init__(self,nodes): self.G.add_node('0', depth = 0) n = open(nodes,'r') for line in n.readlines(): self.get_nodes(line.strip()) def get_nodes(self,line): node_name="" edge_name="" nodes = ...
30.632911
83
0.642975
2,354
0.972727
0
0
0
0
0
0
134
0.055372
3919b6d798e6bab79283dcfc695bccf752daf541
12,058
py
Python
sushichef.py
learningequality/sushi-chef-openstax
dea899fec6b090a1f7b0e1597f8260ca4c0b0f6f
[ "MIT" ]
null
null
null
sushichef.py
learningequality/sushi-chef-openstax
dea899fec6b090a1f7b0e1597f8260ca4c0b0f6f
[ "MIT" ]
4
2017-09-25T19:39:26.000Z
2019-01-11T17:19:13.000Z
sushichef.py
learningequality/sushi-chef-openstax
dea899fec6b090a1f7b0e1597f8260ca4c0b0f6f
[ "MIT" ]
null
null
null
#!/usr/bin/env python import copy import os import sys; sys.path.append(os.getcwd()) # Handle relative imports from ricecooker.utils import downloader, html_writer from ricecooker.chefs import SushiChef from ricecooker.classes import nodes, files from ricecooker.config import LOGGER # Use logger ...
44.659259
147
0.619423
4,454
0.369381
0
0
0
0
0
0
4,194
0.347819
391a19afad9866d05133372637046deacf2e74ca
5,085
pyw
Python
sigaa8.pyw
luisrguerra/calculadorahorariossigaaunb
e99a271683812310fe6289dbe128232657253faf
[ "BSD-3-Clause" ]
1
2021-01-21T02:42:17.000Z
2021-01-21T02:42:17.000Z
sigaa8.pyw
luisrguerra/calculadorahorariossigaaunb
e99a271683812310fe6289dbe128232657253faf
[ "BSD-3-Clause" ]
null
null
null
sigaa8.pyw
luisrguerra/calculadorahorariossigaaunb
e99a271683812310fe6289dbe128232657253faf
[ "BSD-3-Clause" ]
null
null
null
from tkinter import * from tkinter import ttk import os.path #para checar se o arquivo existe import solicitar import imprimir import fechar icone = ".\data\icone.ico" icone_existe = os.path.exists(icone) while True: cor_fundo = 'white' fonte_texto = "Arial" tamanho_texto = 12 tamanho_titulo = 16 ...
30.449102
93
0.417306
0
0
0
0
0
0
0
0
836
0.164179
391af0070ec9aa055f9fe705531d28f9338b23ac
1,966
py
Python
__init__.py
carlosnavarro25/ListadeSuper
7ed3779ed21bd4ff6decff24050e196f4ffd4af3
[ "MIT" ]
null
null
null
__init__.py
carlosnavarro25/ListadeSuper
7ed3779ed21bd4ff6decff24050e196f4ffd4af3
[ "MIT" ]
null
null
null
__init__.py
carlosnavarro25/ListadeSuper
7ed3779ed21bd4ff6decff24050e196f4ffd4af3
[ "MIT" ]
null
null
null
from flask import Flask, request, flash from flask import render_template from flask import redirect from flask_sqlalchemy import SQLAlchemy app = Flask(__name__) app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///listasuper.sqlite3' app.config['SECRET_KEY'] = 'uippc3' db = SQLAlchemy(app) class Super(db.Model): ...
23.97561
70
0.660732
396
0.201424
0
0
1,153
0.58647
0
0
314
0.159715
391b3c5be435c99144a6db5bd572222cb6d2f3f1
29
py
Python
ngs_utils/jsontemplate/__init__.py
pdiakumis/NGS_Utils
9eae9f8d5f0e408118d429fde90e297dbac9ae15
[ "MIT" ]
3
2018-06-06T01:41:51.000Z
2020-08-20T11:36:06.000Z
ngs_utils/jsontemplate/__init__.py
pdiakumis/NGS_Utils
9eae9f8d5f0e408118d429fde90e297dbac9ae15
[ "MIT" ]
4
2019-11-28T03:34:54.000Z
2021-06-24T23:04:55.000Z
ngs_utils/jsontemplate/__init__.py
pdiakumis/NGS_Utils
9eae9f8d5f0e408118d429fde90e297dbac9ae15
[ "MIT" ]
5
2018-03-15T12:43:38.000Z
2021-06-24T23:12:48.000Z
from ._jsontemplate import *
14.5
28
0.793103
0
0
0
0
0
0
0
0
0
0
391b9c72800385ae9692b6e6dd7debb52f9635d1
4,309
py
Python
utils.py
jinhwanlazy/kalman-filter-isnt-hard
7db92bda639761b41be505596b1708b83aa8fa3f
[ "Unlicense" ]
null
null
null
utils.py
jinhwanlazy/kalman-filter-isnt-hard
7db92bda639761b41be505596b1708b83aa8fa3f
[ "Unlicense" ]
null
null
null
utils.py
jinhwanlazy/kalman-filter-isnt-hard
7db92bda639761b41be505596b1708b83aa8fa3f
[ "Unlicense" ]
null
null
null
import scipy.io from matplotlib import pyplot as plt import numpy as np def load_imu_data(): dt = 0.01 gyro_data = scipy.io.loadmat('./source/11.ARS/ArsGyro.mat') acce_data = scipy.io.loadmat('./source/11.ARS/ArsAccel.mat') ts = np.arange(len(gyro_data['wz'])) * dt gyro = np.concatenate([ ...
26.598765
103
0.571362
0
0
574
0.13321
0
0
0
0
245
0.056858
391c545fe97dbf90b53cd05bbc8214ed5d823aa1
1,119
py
Python
interval_search/binary_search.py
mmore500/interval-search
c03f14cbd51770ff4a6abf8f627028c4961368fd
[ "MIT" ]
null
null
null
interval_search/binary_search.py
mmore500/interval-search
c03f14cbd51770ff4a6abf8f627028c4961368fd
[ "MIT" ]
null
null
null
interval_search/binary_search.py
mmore500/interval-search
c03f14cbd51770ff4a6abf8f627028c4961368fd
[ "MIT" ]
null
null
null
import typing def binary_search( predicate: typing.Callable[[int], bool], lower_bound: int, upper_bound: int, ) -> typing.Optional[int]: """ Find the positive integer threshold below which a search criteria is never satisfied and above which it is always satisfied. Parameters --------...
27.292683
78
0.65773
0
0
0
0
0
0
0
0
605
0.540661
391c64ffe43e8158ce594a3b15df0fa54c77d26e
8,326
py
Python
data/external/repositories/208513/kaggle-liberty-hazard-prediction-master/tuning/mutual_info.py
Keesiu/meta-kaggle
87de739aba2399fd31072ee81b391f9b7a63f540
[ "MIT" ]
null
null
null
data/external/repositories/208513/kaggle-liberty-hazard-prediction-master/tuning/mutual_info.py
Keesiu/meta-kaggle
87de739aba2399fd31072ee81b391f9b7a63f540
[ "MIT" ]
null
null
null
data/external/repositories/208513/kaggle-liberty-hazard-prediction-master/tuning/mutual_info.py
Keesiu/meta-kaggle
87de739aba2399fd31072ee81b391f9b7a63f540
[ "MIT" ]
1
2019-12-04T08:23:33.000Z
2019-12-04T08:23:33.000Z
# Note: Kaggle only runs Python 3, not Python 2 # We'll use the pandas library to read CSV files into dataframes import pandas as pd import numpy as np from sklearn import preprocessing from sklearn.linear_model import SGDRegressor from sklearn import decomposition, pipeline, metrics, grid_search from sklearn.metrics ...
33.171315
103
0.675354
0
0
0
0
0
0
0
0
5,538
0.665145
39224edae2c8c9217adba82e613f3d788595f00d
2,482
py
Python
tools/eval2txt.py
youshyee/Greatape-Detection
333b63d8f76538659bcd2bc6022128830a7a435b
[ "Apache-2.0" ]
1
2019-09-22T16:47:16.000Z
2019-09-22T16:47:16.000Z
tools/eval2txt.py
youshyee/Greatape-Detection
333b63d8f76538659bcd2bc6022128830a7a435b
[ "Apache-2.0" ]
null
null
null
tools/eval2txt.py
youshyee/Greatape-Detection
333b63d8f76538659bcd2bc6022128830a7a435b
[ "Apache-2.0" ]
null
null
null
''' given a wordking dir calculate the result for each epoch saving and save it as txt file ''' import os import mmcv import argparse import os.path as osp import shutil import tempfile import torch import torch.distributed as dist from mmcv.runner import load_checkpoint, get_dist_info from mmcv.parallel import MMDat...
31.820513
148
0.695407
0
0
0
0
0
0
0
0
432
0.174053
3922f2d026215c4b598ddcee6bd6c8a6350ddcaf
573
py
Python
example_python/app_02_grpc/client/main.py
simplebuild/please.make
3d0fbea34e633f5b71694c53aca7352e829e2c46
[ "MIT" ]
24
2020-05-06T17:57:40.000Z
2022-02-22T13:30:36.000Z
example_python/app_02_grpc/client/main.py
simplebuild/please.make
3d0fbea34e633f5b71694c53aca7352e829e2c46
[ "MIT" ]
3
2022-02-13T12:58:28.000Z
2022-02-27T04:32:16.000Z
example_python/app_02_grpc/client/main.py
simplebuild/please.make
3d0fbea34e633f5b71694c53aca7352e829e2c46
[ "MIT" ]
3
2020-05-21T12:58:50.000Z
2021-02-03T07:36:01.000Z
import grpc import logging from absl import app, flags import example_python.app_02_grpc.proto.greeter_pb2 as greeter_pb2 import example_python.app_02_grpc.proto.greeter_pb2_grpc as greeter_pb2_grpc flags.DEFINE_integer('port', 50051, 'Port to serve book service on') def main(argv): client = greeter_pb2_grpc.Gr...
28.65
97
0.776614
0
0
0
0
0
0
0
0
115
0.200698
3923d604ff92a346c270b87926a44f2862185eb0
3,118
py
Python
community_erpnext_com/erpnext_community_portal/doctype/frappe_job_bid/frappe_job_bid.py
saurabh6790/community_erpnext_com
edf285de15285e376b223b8c85ea19b46e7d16d7
[ "MIT" ]
null
null
null
community_erpnext_com/erpnext_community_portal/doctype/frappe_job_bid/frappe_job_bid.py
saurabh6790/community_erpnext_com
edf285de15285e376b223b8c85ea19b46e7d16d7
[ "MIT" ]
null
null
null
community_erpnext_com/erpnext_community_portal/doctype/frappe_job_bid/frappe_job_bid.py
saurabh6790/community_erpnext_com
edf285de15285e376b223b8c85ea19b46e7d16d7
[ "MIT" ]
1
2020-02-27T11:18:08.000Z
2020-02-27T11:18:08.000Z
# Copyright (c) 2015, Frappe Technologies Pvt Ltd and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe import _ from frappe.website.website_generator import WebsiteGenerator from frappe.website.utils import get_comment_list class FrappeJo...
34.263736
89
0.739256
1,748
0.560616
0
0
809
0.259461
0
0
945
0.303079
39243003cba396e92b11cfacdc18745deb8b6050
2,314
py
Python
Passing/rotate.py
FootBrawlers/Passing_Algo
5341168dc12f7c4cb254a0a4901de7c3766cc823
[ "MIT" ]
1
2020-01-16T13:19:19.000Z
2020-01-16T13:19:19.000Z
Passing/rotate.py
FootBrawlers/Passing_Algo
5341168dc12f7c4cb254a0a4901de7c3766cc823
[ "MIT" ]
null
null
null
Passing/rotate.py
FootBrawlers/Passing_Algo
5341168dc12f7c4cb254a0a4901de7c3766cc823
[ "MIT" ]
1
2020-01-09T21:04:30.000Z
2020-01-09T21:04:30.000Z
import math if(__name__=="__main__"): pos1=[-5,-2] #positions of the bots pos2=[-9,2] ang1=123 #initial direction of bots ang2=21 def cosinv(num): #function to return cos inverse in degrees ang=math.acos(num) ang=180*ang/(math.pi) return(ang) def ro...
27.879518
87
0.553587
0
0
0
0
0
0
0
0
734
0.3172
3924b0c63a982cfc2185670003e734bf53265e66
1,346
py
Python
aggregate/quality_of_life/access_to_jobs.py
NYCPlanning/db-equitable-development-tool
b24d83dc4092489995cabcdcb611642c1c8ee3b2
[ "MIT" ]
1
2021-12-30T21:03:56.000Z
2021-12-30T21:03:56.000Z
aggregate/quality_of_life/access_to_jobs.py
NYCPlanning/db-equitable-development-tool
b24d83dc4092489995cabcdcb611642c1c8ee3b2
[ "MIT" ]
209
2021-10-20T19:03:04.000Z
2022-03-31T21:02:37.000Z
aggregate/quality_of_life/access_to_jobs.py
NYCPlanning/db-equitable-development-tool
b24d83dc4092489995cabcdcb611642c1c8ee3b2
[ "MIT" ]
null
null
null
import pandas as pd from internal_review.set_internal_review_file import set_internal_review_files from utils.PUMA_helpers import clean_PUMAs, puma_to_borough def access_to_jobs(geography, write_to_internal_review=False): indicator_col_name = "access_employment_count" clean_df = load_clean_source_data(indicat...
37.388889
119
0.719168
0
0
0
0
0
0
0
0
350
0.26003
3924f850ecca94736efdcc056138a74edf483435
279
py
Python
main.py
Shivams9/pythoncodecamp
e6cd27f4704a407ee360414a8c9236b254117a59
[ "MIT" ]
6
2021-08-04T08:15:22.000Z
2022-02-02T11:15:56.000Z
main.py
Maurya232Abhishek/pythoncodecamp
729d2a6167da35f1d6d4786ea43a74fa0c1e4a89
[ "MIT" ]
14
2021-08-02T06:28:00.000Z
2022-03-25T10:44:15.000Z
main.py
Maurya232Abhishek/pythoncodecamp
729d2a6167da35f1d6d4786ea43a74fa0c1e4a89
[ "MIT" ]
6
2021-07-16T04:56:41.000Z
2022-02-16T04:40:06.000Z
# A compilation of Python programs for learning purposes. def print_hi(name): print(f'Hi, {name}') # Press the green button in the gutter to run the script. if __name__ == '__main__': print_hi('Python') # See PyCharm help at https://www.jetbrains.com/help/pycharm/
19.928571
61
0.706093
0
0
0
0
0
0
0
0
206
0.738351
3925fe1fce8c87b4355c29e43b08be99a6eefa03
388
py
Python
job_scraper/__init__.py
DannyMcwaves/ATS
91327ce15b4c4ea2fffebf02562cb8095b7983ec
[ "BSD-3-Clause" ]
null
null
null
job_scraper/__init__.py
DannyMcwaves/ATS
91327ce15b4c4ea2fffebf02562cb8095b7983ec
[ "BSD-3-Clause" ]
4
2020-06-05T17:38:46.000Z
2022-03-02T14:54:30.000Z
job_scraper/__init__.py
DannyMcwaves/ATS
91327ce15b4c4ea2fffebf02562cb8095b7983ec
[ "BSD-3-Clause" ]
null
null
null
""" run the scrape bot from inside the project using an exported function from this module. """ __all__ = ['run'] from scrapy.crawler import CrawlerProcess from .spiders import JobScraperSpider def run(url): process = CrawlerProcess({ 'USER_AGENT': 'AppleWebKit/537.36 (KHTML, like Gecko)' }) pr...
20.421053
62
0.708763
0
0
0
0
0
0
0
0
152
0.391753
3926d81892df689f687efb02a6b67ba5dbe79654
8,272
py
Python
translate/translate_bpe2char.py
nyu-dl/dl4mt-c2c
7655c0edc2fbc113fa856e9916592f4662059099
[ "BSD-3-Clause" ]
171
2016-11-01T13:13:47.000Z
2022-03-21T14:10:19.000Z
translate/translate_bpe2char.py
trevordonnelly/dl4mt-c2c
7655c0edc2fbc113fa856e9916592f4662059099
[ "BSD-3-Clause" ]
23
2016-11-20T03:55:36.000Z
2019-05-13T15:18:32.000Z
translate/translate_bpe2char.py
trevordonnelly/dl4mt-c2c
7655c0edc2fbc113fa856e9916592f4662059099
[ "BSD-3-Clause" ]
63
2016-11-01T16:53:28.000Z
2020-06-13T13:12:40.000Z
import argparse import sys import os import time reload(sys) sys.setdefaultencoding('utf-8') sys.path.insert(0, "/misc/kcgscratch1/ChoGroup/jasonlee/dl4mt-c2c/bpe2char") # change appropriately import numpy import cPickle as pkl from mixer import * def translate_model(jobqueue, resultqueue, model, options, k, normal...
35.655172
254
0.615933
0
0
0
0
0
0
0
0
2,110
0.255077
3929a5f96eb3582a55288fd32d81ecdcdf883c97
607
py
Python
scripts/print_model_summary.py
qai222/CompAugCycleGAN
1a9d54237f4470a4fd5ab215993ed5b373a87e86
[ "CC-BY-4.0" ]
null
null
null
scripts/print_model_summary.py
qai222/CompAugCycleGAN
1a9d54237f4470a4fd5ab215993ed5b373a87e86
[ "CC-BY-4.0" ]
null
null
null
scripts/print_model_summary.py
qai222/CompAugCycleGAN
1a9d54237f4470a4fd5ab215993ed5b373a87e86
[ "CC-BY-4.0" ]
null
null
null
import os from cacgan.data import FormulaDataset, GroupAB from cacgan.gans import AugCycleGan from cacgan.gans import Trainer from cacgan.utils import SEED, seed_rng, load_pkl """ print a txt file describing the structure of augcyc """ seed_rng(SEED) dataset = load_pkl("../dataset/dataset_ab.pkl") dataset: FormulaD...
27.590909
94
0.792422
0
0
0
0
0
0
0
0
149
0.24547
3929bec32ef1c5ce780461ed9cf4da4c8626eee2
894
py
Python
reddit_dashboard/migrations/0002_auto_20201017_1650.py
tarikyayla/reddit_dashboard
e5ecf3349a5c9333793c3ae5375bc4a0e501a16c
[ "MIT" ]
null
null
null
reddit_dashboard/migrations/0002_auto_20201017_1650.py
tarikyayla/reddit_dashboard
e5ecf3349a5c9333793c3ae5375bc4a0e501a16c
[ "MIT" ]
null
null
null
reddit_dashboard/migrations/0002_auto_20201017_1650.py
tarikyayla/reddit_dashboard
e5ecf3349a5c9333793c3ae5375bc4a0e501a16c
[ "MIT" ]
1
2020-11-27T23:24:09.000Z
2020-11-27T23:24:09.000Z
# Generated by Django 3.1.2 on 2020-10-17 13:50 import django.contrib.auth.models from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('reddit_dashboard', '0001_initial'), ] operations = [ migrations.AlterModelManagers( name='dashboarduse...
24.833333
70
0.551454
775
0.86689
0
0
0
0
0
0
205
0.229306
392acdb2ba71ec521fa09fbe78d6aeda095a2027
20,473
py
Python
python_scripts/tools/test_accuracy.py
cristianwpuig/Object-detection-and-classification-using-LiDAR-and-edgeTPU
fa876ee8ccf40ecfacfd3a697c41a519a15a3ff1
[ "MIT" ]
null
null
null
python_scripts/tools/test_accuracy.py
cristianwpuig/Object-detection-and-classification-using-LiDAR-and-edgeTPU
fa876ee8ccf40ecfacfd3a697c41a519a15a3ff1
[ "MIT" ]
null
null
null
python_scripts/tools/test_accuracy.py
cristianwpuig/Object-detection-and-classification-using-LiDAR-and-edgeTPU
fa876ee8ccf40ecfacfd3a697c41a519a15a3ff1
[ "MIT" ]
null
null
null
import ctypes import csv import os import numpy as np import tflite_runtime.interpreter as tflite import time import platform import collections import operator ''' source /home/cristian/virtualenvs/coral/bin/activate python test_accuracy.py ''' # Configuration parametres print_results = True load_results = False writ...
44.506522
217
0.640014
0
0
0
0
0
0
0
0
3,841
0.187613
392c38c4087be8ff3e32c8fcba510fcdd3370bb8
10,037
py
Python
scripts/achived/classifcation5.py
nmningmei/metacognition
734082e247cc7fc9d277563e2676e10692617a3f
[ "MIT" ]
3
2019-07-09T15:37:46.000Z
2019-07-17T16:28:02.000Z
scripts/achived/classifcation5.py
nmningmei/metacognition
734082e247cc7fc9d277563e2676e10692617a3f
[ "MIT" ]
null
null
null
scripts/achived/classifcation5.py
nmningmei/metacognition
734082e247cc7fc9d277563e2676e10692617a3f
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Mon Aug 13 13:31:08 2018 @author: nmei Cross experiment validation """ import os working_dir = '../data/' import pandas as pd from tqdm import tqdm pd.options.mode.chained_assignment = None import numpy as np from sklearn.metrics import roc_auc_score fr...
34.850694
98
0.507721
0
0
0
0
0
0
0
0
2,708
0.269802
392d149ad0b50198610a97e8e0753d72575eb6b5
924
py
Python
Scoring_Tools/check_stacks_2.py
htpans/htpans
49b9c6cec007577bde5e8dfbce9acde45be78fbf
[ "MIT" ]
null
null
null
Scoring_Tools/check_stacks_2.py
htpans/htpans
49b9c6cec007577bde5e8dfbce9acde45be78fbf
[ "MIT" ]
null
null
null
Scoring_Tools/check_stacks_2.py
htpans/htpans
49b9c6cec007577bde5e8dfbce9acde45be78fbf
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Jul 26 17:43:03 2019 @author: Eric Danielson """ from skimage import io import os import argparse from tqdm import tqdm argparser = argparse.ArgumentParser( description='Train and validate YOLO_v2 model on any dataset') argparser.add_argument( '-i',...
24.315789
67
0.554113
0
0
0
0
0
0
0
0
286
0.309524
392d42b9edf6beeccc22b6acefd045b99b7ec43e
574
py
Python
hqtrace_start.py
halucinator/hq-tracer
67d155142910aec25ef2fc14159cb0ef80a34111
[ "BSD-3-Clause" ]
1
2021-08-03T01:54:12.000Z
2021-08-03T01:54:12.000Z
hqtrace_start.py
halucinator/hq-tracer
67d155142910aec25ef2fc14159cb0ef80a34111
[ "BSD-3-Clause" ]
null
null
null
hqtrace_start.py
halucinator/hq-tracer
67d155142910aec25ef2fc14159cb0ef80a34111
[ "BSD-3-Clause" ]
null
null
null
# Copyright 2021 National Technology & Engineering Solutions of Sandia, LLC (NTESS). # Under the terms of Contract DE-NA0003525 with NTESS, # the U.S. Government retains certain rights in this software. # #This script starts the HQTrace Plugin #@Christopher Wright #@category HQTracer #@keybinding alt shift t #@menupa...
35.875
85
0.773519
0
0
0
0
0
0
0
0
383
0.667247
392d9ed47279e20510efa86956a52f2d4392ee39
2,816
py
Python
gps_server/server.py
simonfong6/not-kiwi-bot
9542f328542126b32b2bb2961eea3f4243bdd29f
[ "MIT" ]
1
2018-05-16T00:52:53.000Z
2018-05-16T00:52:53.000Z
gps_server/server.py
simonfong6/not-kiwi-bot
9542f328542126b32b2bb2961eea3f4243bdd29f
[ "MIT" ]
null
null
null
gps_server/server.py
simonfong6/not-kiwi-bot
9542f328542126b32b2bb2961eea3f4243bdd29f
[ "MIT" ]
1
2020-09-24T17:58:34.000Z
2020-09-24T17:58:34.000Z
#!/env/usr/bin python """ server.py Tool to visualize GPS coordinates for donkeycar. """ from flask import Flask, request, send_from_directory, jsonify import json # File that stores the GPS markers DATA_FILE = 'data.json' # JSON status messages SUCCESS = {'status' : {'success': True}} FAIL = {'status': {'success':...
24.920354
77
0.580256
0
0
0
0
2,052
0.728693
0
0
1,056
0.375
392ece3eab4fceea4640046a996ab12e285120cf
6,635
py
Python
lunarlander/learn.py
brianquinlan/learn-machine-learning
275284eafdeb4e0140ab5d877e06d3258f7b590a
[ "MIT" ]
1
2018-05-10T02:55:15.000Z
2018-05-10T02:55:15.000Z
lunarlander/learn.py
brianquinlan/learn-machine-learning
275284eafdeb4e0140ab5d877e06d3258f7b590a
[ "MIT" ]
null
null
null
lunarlander/learn.py
brianquinlan/learn-machine-learning
275284eafdeb4e0140ab5d877e06d3258f7b590a
[ "MIT" ]
null
null
null
# Copyright 2019 Brian Quinlan # # 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 writin...
27.417355
78
0.609495
0
0
0
0
0
0
0
0
1,511
0.227732
392fd6cec05398851f6edab18f7e5a5a0402b4ac
316
py
Python
chapter05/error_view_demo/errors/urls.py
Tomtao626/django
fe945063593b4bfe82d74842f728b854b501a294
[ "Apache-2.0" ]
null
null
null
chapter05/error_view_demo/errors/urls.py
Tomtao626/django
fe945063593b4bfe82d74842f728b854b501a294
[ "Apache-2.0" ]
null
null
null
chapter05/error_view_demo/errors/urls.py
Tomtao626/django
fe945063593b4bfe82d74842f728b854b501a294
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # @Time : 02/01/2021 23:37 # @Author : tomtao # @Email : tp320670258@gmail.com # @File : urls.py # @Project : error_view_demo from django.urls import path from . import views urlpatterns = [ path('405.html', views.view_405, name='405'), path('403.html', views.view_403, name='403') ]
24.307692
49
0.651899
0
0
0
0
0
0
0
0
174
0.550633
393274511ff8ade3d568edf3ce281b780dd13969
3,376
py
Python
tests/test_dataset.py
ckauth/eurostat-api-client
70c859881d50b3eca275434e2590ff7d76b290e9
[ "Apache-2.0" ]
4
2019-01-04T12:57:07.000Z
2021-03-14T04:03:42.000Z
tests/test_dataset.py
ckauth/eurostat-api-client
70c859881d50b3eca275434e2590ff7d76b290e9
[ "Apache-2.0" ]
6
2019-06-16T21:20:09.000Z
2021-09-15T21:03:57.000Z
tests/test_dataset.py
ckauth/eurostat-api-client
70c859881d50b3eca275434e2590ff7d76b290e9
[ "Apache-2.0" ]
9
2019-07-29T16:13:25.000Z
2022-03-10T17:42:30.000Z
from eurostatapiclient.models.dataset import dimension_list_size from eurostatapiclient.models.dimension import ItemList, Dimension import unittest from eurostatapiclient.models.dataset import Dataset import datetime import json import os TEST_ASSET_DIR = os.path.join(os.path.dirname(__file__), 'assets') ADD_DATASET =...
36.301075
74
0.591825
3,000
0.888626
0
0
0
0
0
0
407
0.120557
3933365abb5430b754b10a4e77d9d9f75fd097cc
3,001
py
Python
MediaTracker/views/views_main.py
sarahbeharrygoss/MediaTracker
3df8ae27534ed5c9933cc4944b90372d5f569692
[ "MIT" ]
null
null
null
MediaTracker/views/views_main.py
sarahbeharrygoss/MediaTracker
3df8ae27534ed5c9933cc4944b90372d5f569692
[ "MIT" ]
null
null
null
MediaTracker/views/views_main.py
sarahbeharrygoss/MediaTracker
3df8ae27534ed5c9933cc4944b90372d5f569692
[ "MIT" ]
null
null
null
from __future__ import unicode_literals from MediaTracker.flask_app_and_db import flask_app as app from MediaTracker import models from flask import render_template, request from MediaTracker.forms import MediaForm from MediaTracker.controllers import media_controller, tag_controller from urllib.parse import urlencode...
34.895349
105
0.676774
0
0
0
0
1,198
0.3992
0
0
357
0.11896
3933b14868fb7835981174229acf0723b316d2f0
3,448
py
Python
marx.py
shrsv/marx
bf0f332c8505e4c17035f0aaddf501a9c3f160f5
[ "MIT" ]
null
null
null
marx.py
shrsv/marx
bf0f332c8505e4c17035f0aaddf501a9c3f160f5
[ "MIT" ]
null
null
null
marx.py
shrsv/marx
bf0f332c8505e4c17035f0aaddf501a9c3f160f5
[ "MIT" ]
null
null
null
#!/usr/bin/env python import ply.lex as lex # Commonmark specification by John MacFarlane # http://spec.commonmark.org/0.21/ # The spec uses BMP Unicode codepoints: # U+NNNN where 0000 <= NNNN <= FFFF # https://en.wikipedia.org/wiki/Plane_(Unicode)#Basic_Multilingual_Plane # The building blocks are: # character, li...
38.311111
80
0.75145
0
0
0
0
0
0
0
0
3,338
0.968097
3934036821b99f3a446c5842236bd774d012e9ea
283
py
Python
pirates.py
sanjeev8386/Debugging
dd4ad640cf22af1d06d3bdccb74acab29bab47fc
[ "Apache-2.0" ]
5
2019-03-03T06:18:45.000Z
2019-03-03T06:27:29.000Z
pirates.py
sanjeev8386/Debugging
dd4ad640cf22af1d06d3bdccb74acab29bab47fc
[ "Apache-2.0" ]
null
null
null
pirates.py
sanjeev8386/Debugging
dd4ad640cf22af1d06d3bdccb74acab29bab47fc
[ "Apache-2.0" ]
null
null
null
# greeting = input("Kya naam hai aapka?") # print(greeting) # greeting = input("Kya naam hai aapka?") # print(greeting) greeting = input("Hello, pirate ji! Andar aane ka password batao?") if "AbraKaDabra" == greeting: print("Andar aao ji!") else: print("Bhaag jaa pirate!")
28.3
67
0.674912
0
0
0
0
0
0
0
0
212
0.749117
39340c106072ca98c8d5dadf76bb06e25cb34669
4,409
py
Python
api/generated/python/azure-iiot-opc-registry/models/__init__.py
benjguin/Industrial-IoT
1bc68a62383f0849bbb18f373c9566d8d30c1d68
[ "MIT" ]
2
2021-08-06T19:40:53.000Z
2021-08-07T05:21:24.000Z
api/generated/python/azure-iiot-opc-registry/models/__init__.py
benjguin/Industrial-IoT
1bc68a62383f0849bbb18f373c9566d8d30c1d68
[ "MIT" ]
null
null
null
api/generated/python/azure-iiot-opc-registry/models/__init__.py
benjguin/Industrial-IoT
1bc68a62383f0849bbb18f373c9566d8d30c1d68
[ "MIT" ]
null
null
null
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator 2.3.33.0 # ...
44.535354
96
0.821048
0
0
0
0
0
0
0
0
1,570
0.35609
393450fc2d2715e9100e072a54294b73919a49e9
11,446
py
Python
src/qibo/tests/test_core_hamiltonians.py
renatomello/qibo
20c6f3f22effbeccd5d31ed456717f9bee449e0c
[ "Apache-2.0" ]
null
null
null
src/qibo/tests/test_core_hamiltonians.py
renatomello/qibo
20c6f3f22effbeccd5d31ed456717f9bee449e0c
[ "Apache-2.0" ]
null
null
null
src/qibo/tests/test_core_hamiltonians.py
renatomello/qibo
20c6f3f22effbeccd5d31ed456717f9bee449e0c
[ "Apache-2.0" ]
1
2022-03-28T17:52:46.000Z
2022-03-28T17:52:46.000Z
"""Test methods in `qibo/core/hamiltonians.py`.""" import pytest import numpy as np from scipy import sparse from qibo import hamiltonians, K from qibo.tests.utils import random_complex def random_sparse_matrix(n, sparse_type=None): if K.name in ("qibotf", "tensorflow"): nonzero = int(0.1 * n * n) ...
35.880878
90
0.62441
0
0
0
0
9,445
0.825179
0
0
965
0.084309
39368ab4391d5218fe27c32f6d8834334fe277a9
9,451
py
Python
modules/feature_weights.py
keyvantaj/Quantitative
77c7c414c47ed3fe22873b87ed15e92dc62226da
[ "MIT" ]
9
2020-10-11T21:09:41.000Z
2022-02-17T01:52:04.000Z
modules/feature_weights.py
ajmal017/Quantitative
7af681677031987c64f402d8cb06b358cedd184a
[ "MIT" ]
null
null
null
modules/feature_weights.py
ajmal017/Quantitative
7af681677031987c64f402d8cb06b358cedd184a
[ "MIT" ]
3
2020-07-18T02:19:08.000Z
2022-01-30T15:37:02.000Z
import matplotlib.pyplot as plt import datetime as datetime import numpy as np import pandas as pd import talib import seaborn as sns from time import time from sklearn import preprocessing from pandas.plotting import register_matplotlib_converters from .factorize import FactorManagement import scipy.stats as stats imp...
42.191964
114
0.632526
8,904
0.942123
0
0
1,243
0.13152
0
0
1,413
0.149508
39373fd62c1c95168677446d3aff06f09ea5b298
3,179
py
Python
tests/asv_bench/benchmarks/count_if.py
realead/cykhash
b1a45843c3be49cd232d3c78315d2291a830284f
[ "MIT" ]
18
2019-03-13T08:20:06.000Z
2021-06-22T08:03:01.000Z
tests/asv_bench/benchmarks/count_if.py
realead/cykhash
b1a45843c3be49cd232d3c78315d2291a830284f
[ "MIT" ]
6
2020-04-13T10:11:45.000Z
2021-11-14T15:59:55.000Z
tests/asv_bench/benchmarks/count_if.py
realead/cykhash
b1a45843c3be49cd232d3c78315d2291a830284f
[ "MIT" ]
7
2019-05-19T22:24:57.000Z
2020-08-26T23:01:23.000Z
import numpy as np from cykhash import count_if_int64, count_if_int64_from_iter, Int64Set_from, Int64Set_from_buffer from cykhash import count_if_int32, count_if_int32_from_iter, Int32Set_from, Int32Set_from_buffer from cykhash import count_if_float64, count_if_float64_from_iter, Float64Set_from, Float64Set_from_buffe...
30.864078
110
0.643599
2,212
0.695816
0
0
0
0
0
0
50
0.015728
3938add8f52f37344b2c5a7d5cbf597b4f740a18
1,188
py
Python
src/sim/06-allegheny-05-school-work-flu/sim-test-01.py
momacs/pram
d2de43ea447d13a65d814f781ec86889754f76fe
[ "BSD-3-Clause" ]
10
2019-01-18T19:11:54.000Z
2022-03-16T08:39:36.000Z
src/sim/06-allegheny-05-school-work-flu/sim-test-01.py
momacs/pram
d2de43ea447d13a65d814f781ec86889754f76fe
[ "BSD-3-Clause" ]
2
2019-02-19T15:10:44.000Z
2019-02-26T04:26:24.000Z
src/sim/06-allegheny-05-school-work-flu/sim-test-01.py
momacs/pram
d2de43ea447d13a65d814f781ec86889754f76fe
[ "BSD-3-Clause" ]
3
2019-02-19T15:11:08.000Z
2021-08-20T11:51:04.000Z
''' A test simulation involving the SEIR flu model in isolation. ''' from pram.data import GroupSizeProbe, ProbeMsgMode from pram.entity import Group, Site from pram.rule import SEIRFluRule from pram.sim import Simulation rand_seed = 1928 probe_grp_size_flu = GroupSizeProbe.by_attr('flu', SEIRFluRule.ATTR, SE...
24.75
159
0.590067
0
0
0
0
0
0
0
0
569
0.478956
39393793b2eafb2d08a2bee5095d95946bcad88f
31
py
Python
models/__init__.py
StephenTerror/TSSCapsNet
edc01b85987da641f4797c1bf60355bc78a6d51f
[ "Apache-2.0" ]
1
2021-03-21T12:37:38.000Z
2021-03-21T12:37:38.000Z
models/__init__.py
StephenTerror/TSSCapsNet
edc01b85987da641f4797c1bf60355bc78a6d51f
[ "Apache-2.0" ]
null
null
null
models/__init__.py
StephenTerror/TSSCapsNet
edc01b85987da641f4797c1bf60355bc78a6d51f
[ "Apache-2.0" ]
null
null
null
from models.model_zoo import *
15.5
30
0.806452
0
0
0
0
0
0
0
0
0
0
39393fd1663cd51cc893648130264d6a536c39eb
374
py
Python
ProjectEuler.Problem.024.py
jihunroh/ProjectEuler-Python
2fceaf5c3dd61038004b6128c5d9ee7a76142bca
[ "MIT" ]
null
null
null
ProjectEuler.Problem.024.py
jihunroh/ProjectEuler-Python
2fceaf5c3dd61038004b6128c5d9ee7a76142bca
[ "MIT" ]
null
null
null
ProjectEuler.Problem.024.py
jihunroh/ProjectEuler-Python
2fceaf5c3dd61038004b6128c5d9ee7a76142bca
[ "MIT" ]
null
null
null
from ProjectEulerCommons.Base import * Answer( int(''.join(map(str, first_true_value(permutations(list(range(10))), pred = lambda enum: enum[0] == 1000000 - 1)))) ) """ ------------------------------------------------ ProjectEuler.Problem.024.py The Answer is: 2783915460 Time Elasped: 1.132969617843628sec...
28.769231
119
0.516043
0
0
0
0
0
0
0
0
205
0.548128
393af2e7a56b8e1fb6dfc214efb3967a67da7892
866
py
Python
test_first/patch_module.py
haarcuba/test_first
804ccd40699345423a44c90c62ced7fcb82f735b
[ "MIT" ]
null
null
null
test_first/patch_module.py
haarcuba/test_first
804ccd40699345423a44c90c62ced7fcb82f735b
[ "MIT" ]
7
2021-10-30T19:09:10.000Z
2021-12-04T21:14:28.000Z
test_first/patch_module.py
haarcuba/test_first
804ccd40699345423a44c90c62ced7fcb82f735b
[ "MIT" ]
null
null
null
import pytest from test_first import fake _SENTINEL = 'test_first-sentinel-a72004be-7a66-42f5-bdcf-7d71eb7283e3' class Patcher: def __init__(self): self.__stack = [] def __call__(self, module, attribute, mock = None): if hasattr( module, attribute ): original = getattr( module, at...
27.0625
70
0.620092
652
0.752887
80
0.092379
96
0.110855
0
0
58
0.066975
393d856c5a143092e3bf4ec4635cb697b334ab02
12,721
py
Python
geo/geophys/examples/RM15/RM15.py
Tamlyn78/geo
dd63372acdd1fe8b744c05eca5ad23836e6a1604
[ "MIT" ]
null
null
null
geo/geophys/examples/RM15/RM15.py
Tamlyn78/geo
dd63372acdd1fe8b744c05eca5ad23836e6a1604
[ "MIT" ]
null
null
null
geo/geophys/examples/RM15/RM15.py
Tamlyn78/geo
dd63372acdd1fe8b744c05eca5ad23836e6a1604
[ "MIT" ]
null
null
null
from os import listdir, makedirs from os.path import abspath, basename, dirname, isdir, join import re import csv import numpy as np import pandas as pd from scipy import stats, ndimage, signal import matplotlib.pyplot as plt from matplotlib import cm, rc from mpl_toolkits.axes_grid1 import make_axes_locatable from ma...
33.564644
135
0.585803
0
0
0
0
0
0
0
0
1,623
0.127584
393d8a33f773b3b39e9d958ef90238b7ad2f9749
309
py
Python
Apps/phsplunkoncall/splunkoncall_consts.py
ryanbsaunders/phantom-apps
1befda793a08d366fbd443894f993efb1baf9635
[ "Apache-2.0" ]
74
2019-10-22T02:00:53.000Z
2022-03-15T12:56:13.000Z
Apps/phsplunkoncall/splunkoncall_consts.py
ryanbsaunders/phantom-apps
1befda793a08d366fbd443894f993efb1baf9635
[ "Apache-2.0" ]
375
2019-10-22T20:53:50.000Z
2021-11-09T21:28:43.000Z
Apps/phsplunkoncall/splunkoncall_consts.py
ryanbsaunders/phantom-apps
1befda793a08d366fbd443894f993efb1baf9635
[ "Apache-2.0" ]
175
2019-10-23T15:30:42.000Z
2021-11-05T21:33:31.000Z
# File: splunkoncall_consts.py # # Copyright (c) 2018-2021 Splunk Inc. # # Licensed under Apache 2.0 (https://www.apache.org/licenses/LICENSE-2.0.txt) # # Define your constants here INTEGRATION_URL_MISSING = "Integration URL required in asset configuration" UPDATE_INCIDENT_ERROR = "Error updating incident"
28.090909
77
0.776699
0
0
0
0
0
0
0
0
249
0.805825
393d8d7d5792eab89a415b922f64a52c86ec37a7
1,716
py
Python
specreduce/table_utils.py
simontorres/specreduce
bb41c2d1416cb2fa1137f58643ddd9400a3092b9
[ "BSD-3-Clause" ]
null
null
null
specreduce/table_utils.py
simontorres/specreduce
bb41c2d1416cb2fa1137f58643ddd9400a3092b9
[ "BSD-3-Clause" ]
null
null
null
specreduce/table_utils.py
simontorres/specreduce
bb41c2d1416cb2fa1137f58643ddd9400a3092b9
[ "BSD-3-Clause" ]
null
null
null
"""Utility functions to parse master NIST table. """ from astropy.table import Column, Table, vstack import glob import numpy as np def sort_table_by_element(table, elem_list): """Build table based on list of elements Parameters ---------- table: astropy table Table to sort elem_list: lis...
26
91
0.643939
0
0
0
0
0
0
0
0
839
0.488928
393e5bb1bc9612539e7d8b447c1f8d1b0ef109f0
1,223
py
Python
AioCentralBankRuApi.py
dark0ghost/AioCentralBankRuApi
fcd9d0c9bc660c8e03c67d022398b51f47571720
[ "MIT" ]
null
null
null
AioCentralBankRuApi.py
dark0ghost/AioCentralBankRuApi
fcd9d0c9bc660c8e03c67d022398b51f47571720
[ "MIT" ]
null
null
null
AioCentralBankRuApi.py
dark0ghost/AioCentralBankRuApi
fcd9d0c9bc660c8e03c67d022398b51f47571720
[ "MIT" ]
null
null
null
import aiohttp from typing import Dict class CenterBankApi: """ class implements api cbr """ def __init__(self, session: aiohttp.ClientSession) -> None: self.link = "https://www.cbr-xml-daily.ru/daily_json.js" self.obj = dict() self.date: str = "" self.session: aiohtt...
27.177778
75
0.540474
1,180
0.964841
0
0
0
0
730
0.596893
359
0.29354
393e655ee87ab592a9155b2f92d99ffe276dd68d
40,932
py
Python
IntOpt/NeurIPSIntopt-main/Interior/intopt_energy_mlp.py
Patyrn/Divide-and-Learn
ff03689c7ab6a7155ebd019babce8f79d0757a53
[ "MIT" ]
7
2020-11-06T01:29:48.000Z
2022-01-02T12:49:40.000Z
IntOpt/NeurIPSIntopt-main/Interior/intopt_energy_mlp.py
Patyrn/Divide-and-Learn
ff03689c7ab6a7155ebd019babce8f79d0757a53
[ "MIT" ]
2
2021-01-19T16:59:04.000Z
2021-01-25T10:17:46.000Z
IntOpt/NeurIPSIntopt-main/Interior/intopt_energy_mlp.py
Patyrn/Divide-and-Learn
ff03689c7ab6a7155ebd019babce8f79d0757a53
[ "MIT" ]
5
2021-07-13T04:47:13.000Z
2022-01-17T14:05:06.000Z
import sys sys.path.insert(0, '..') sys.path.insert(0, '../EnergyCost') from qpthlocal.qp import QPFunction from qpthlocal.qp import QPSolvers from qpthlocal.qp import make_gurobi_model from ICON import * from sgd_learner import * from sklearn.metrics import mean_squared_error as mse from collections import defaultdict...
41.981538
134
0.569066
30,556
0.746506
230
0.005619
246
0.00601
0
0
4,163
0.101705