hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
b0680313f08baec10f4a8b5ea84ee4ba0c56d7a7
382
py
Python
workpy/base.py
cofear/workpy
74df24f1b9de519cf33897a648e6ae563cdd0368
[ "MIT" ]
null
null
null
workpy/base.py
cofear/workpy
74df24f1b9de519cf33897a648e6ae563cdd0368
[ "MIT" ]
null
null
null
workpy/base.py
cofear/workpy
74df24f1b9de519cf33897a648e6ae563cdd0368
[ "MIT" ]
null
null
null
def llist(s): return [i.split() for i in s.split('\n') if len(i) > 0] def hump(s): a = [i for i in uline(s).split('_') if len(i) > 0] return a[0].lower()+''.join(i.capitalize() for i in a[1:]) def uline(s): b = '' a = str(s) for i, v in enumerate(a): b += '_'+v if v.isupper() and a[i-1].islower() else v ret...
25.466667
65
0.554974
1dad4a43dbfcf604df04f16ee888f8058f63b543
2,005
py
Python
Array/Merge_Intervals.py
shua2018ti/Google
3a9847e0c60d887d15eb4b0d4d8ebf51e464df1b
[ "MIT" ]
87
2015-07-15T20:41:09.000Z
2022-03-08T13:55:38.000Z
Array/Merge_Intervals.py
shua2018ti/Google
3a9847e0c60d887d15eb4b0d4d8ebf51e464df1b
[ "MIT" ]
59
2015-03-19T22:26:41.000Z
2015-07-25T17:58:08.000Z
Array/Merge_Intervals.py
shua2018ti/Google
3a9847e0c60d887d15eb4b0d4d8ebf51e464df1b
[ "MIT" ]
45
2015-07-15T20:41:12.000Z
2022-02-01T20:18:07.000Z
''' Given a collection of intervals, merge all overlapping intervals. For example, Given [1,3],[2,6],[8,10],[15,18], return [1,6],[8,10],[15,18]. ''' class Solution: # @param intervals, a list of Interval # @return a list of Interval def merge(self, intervals): length = len(intervals) if ...
30.378788
90
0.494763
f19177c2ae6044f5fb814eec4f2f1ce180dabd83
6,313
py
Python
test/dialect/mysql/test_query.py
EvaSDK/sqlalchemy
0a60865d527331a4df9db0fc8a15038108075bca
[ "MIT" ]
1
2016-07-26T14:47:04.000Z
2016-07-26T14:47:04.000Z
test/dialect/mysql/test_query.py
EvaSDK/sqlalchemy
0a60865d527331a4df9db0fc8a15038108075bca
[ "MIT" ]
null
null
null
test/dialect/mysql/test_query.py
EvaSDK/sqlalchemy
0a60865d527331a4df9db0fc8a15038108075bca
[ "MIT" ]
null
null
null
# coding: utf-8 from sqlalchemy.testing import eq_, is_ from sqlalchemy import * from sqlalchemy.testing import fixtures, AssertsCompiledSQL from sqlalchemy import testing class IdiosyncrasyTest(fixtures.TestBase, AssertsCompiledSQL): __only_on__ = 'mysql' __backend__ = True @testing.emits_warning() ...
35.072222
81
0.518929
a329ed6b5b857302bfa1532e16aefa50a0d0e4a2
363
py
Python
examples/djangoproject/djangoproject/urls.py
seanbrant/pykss
c01b0f97c3ebfff32b4bdb3e6e2e1616c5c4ea3e
[ "BSD-3-Clause" ]
12
2015-01-31T19:24:56.000Z
2018-09-11T10:02:28.000Z
examples/djangoproject/djangoproject/urls.py
seanbrant/pykss
c01b0f97c3ebfff32b4bdb3e6e2e1616c5c4ea3e
[ "BSD-3-Clause" ]
7
2016-08-02T15:13:15.000Z
2021-06-10T18:51:13.000Z
examples/djangoproject/djangoproject/urls.py
kundo/pykss
5ea14041b7cb0bb3f8596213126b119df918b5ea
[ "BSD-3-Clause" ]
6
2015-01-23T17:19:27.000Z
2019-03-20T09:04:46.000Z
from django.conf.urls import patterns, url from django.views.generic.base import TemplateView from pykss.contrib.django.views import StyleguideView urlpatterns = patterns('', url(r'^$', TemplateView.as_view(template_name='index.html'), name='index'), url(r'^styleguide/$', StyleguideView.as_view(template_name...
33
102
0.757576
94be0b90c1659da749ccf150b99d348dd535560b
1,992
py
Python
orodja.py
nomad2001/dvojke-ali-trojke
9c7a0460d2012a285dcda122418995796d213cab
[ "MIT" ]
null
null
null
orodja.py
nomad2001/dvojke-ali-trojke
9c7a0460d2012a285dcda122418995796d213cab
[ "MIT" ]
null
null
null
orodja.py
nomad2001/dvojke-ali-trojke
9c7a0460d2012a285dcda122418995796d213cab
[ "MIT" ]
null
null
null
import csv import json import os import requests import sys global count count = 0 def pripravi_imenik(ime_datoteke): '''Če še ne obstaja, pripravi prazen imenik za dano datoteko.''' imenik = os.path.dirname(ime_datoteke) if imenik: os.makedirs(imenik, exist_ok=True) def shrani_spletno_stran(url...
31.619048
75
0.64508
176a5af9bed2ffe4a27e09b8c2972ea7fe5b4059
14,676
py
Python
Paired Recordings/Preprint Code/5_Figure 6 and supplement - Spike Reliability.py
kampff-lab/sc.io
0d110856ebbb2d20bf13c49c3b5d77bf622c9df4
[ "MIT" ]
17
2018-05-10T09:37:15.000Z
2021-07-11T17:51:43.000Z
Paired Recordings/Preprint Code/5_Figure 6 and supplement - Spike Reliability.py
kampff-lab/sc.io
0d110856ebbb2d20bf13c49c3b5d77bf622c9df4
[ "MIT" ]
1
2019-09-10T09:00:26.000Z
2020-05-23T13:47:42.000Z
Paired Recordings/Preprint Code/5_Figure 6 and supplement - Spike Reliability.py
kampff-lab/sc.io
0d110856ebbb2d20bf13c49c3b5d77bf622c9df4
[ "MIT" ]
16
2018-04-06T18:27:34.000Z
2020-05-30T18:44:59.000Z
#%%Imports import pandas import numpy as np import matplotlib.pyplot as plt import os from collections import defaultdict import random import math import scipy.stats as stats from sklearn.model_selection import train_test_split from sklearn.linear_model import LinearRegression from sklearn import metrics ...
51.135889
217
0.65631
9e1c26cc130b635bef7b127f1b8c5adb440121c3
871
py
Python
448.Find-All-Numbers-Disappeared-in-an-Array.py
mickey0524/leetcode
6bedeb6ff29b02a97178cca464c5fd639951801f
[ "MIT" ]
18
2018-07-14T12:45:37.000Z
2022-03-26T14:51:04.000Z
448.Find-All-Numbers-Disappeared-in-an-Array.py
mickey0524/leetcode
6bedeb6ff29b02a97178cca464c5fd639951801f
[ "MIT" ]
null
null
null
448.Find-All-Numbers-Disappeared-in-an-Array.py
mickey0524/leetcode
6bedeb6ff29b02a97178cca464c5fd639951801f
[ "MIT" ]
3
2019-05-29T04:09:22.000Z
2021-06-07T23:37:46.000Z
# https://leetcode.com/problems/find-all-numbers-disappeared-in-an-array/ # # algorithms # Easy (53.99%) # Total Accepted: 170,160 # Total Submissions: 315,198 class Solution(object): def findDisappearedNumbers(self, nums): """ :type nums: List[int] :rtype: List[int] """ ...
24.194444
73
0.405281
c6ac0fc8513192375c44cf7e9c47490c32b955c8
7,642
py
Python
configs/_base_/models/htc_without_semantic_swin_fpn.py
ace19-dev/CBNetV2
b08cfa8bbe438cd72651da3049ec4829f168ba81
[ "Apache-2.0" ]
null
null
null
configs/_base_/models/htc_without_semantic_swin_fpn.py
ace19-dev/CBNetV2
b08cfa8bbe438cd72651da3049ec4829f168ba81
[ "Apache-2.0" ]
null
null
null
configs/_base_/models/htc_without_semantic_swin_fpn.py
ace19-dev/CBNetV2
b08cfa8bbe438cd72651da3049ec4829f168ba81
[ "Apache-2.0" ]
null
null
null
# model settings model = dict( type='HybridTaskCascade', pretrained=None, backbone=dict( type='SwinTransformer', embed_dim=96, depths=[2, 2, 6, 2], num_heads=[3, 6, 12, 24], window_size=7, mlp_ratio=4., qkv_bias=True, qk_scale=None, dro...
34.423423
79
0.448966
775721980050bcea76134cb90c3f2e0b9d2acb44
20,641
py
Python
tests/python/unittest/test_image.py
sandutsar/incubator-mxnet
3ae7ddfd9c99f40a33c4cb716b3810e5463b810a
[ "Apache-2.0", "MIT" ]
1
2021-05-11T18:04:50.000Z
2021-05-11T18:04:50.000Z
tests/python/unittest/test_image.py
sandutsar/incubator-mxnet
3ae7ddfd9c99f40a33c4cb716b3810e5463b810a
[ "Apache-2.0", "MIT" ]
2
2022-01-13T03:57:21.000Z
2022-03-12T01:01:35.000Z
tests/python/unittest/test_image.py
sandutsar/incubator-mxnet
3ae7ddfd9c99f40a33c4cb716b3810e5463b810a
[ "Apache-2.0", "MIT" ]
1
2019-12-11T19:22:13.000Z
2019-12-11T19:22:13.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
46.073661
127
0.59939
eae54590b0a874499e3cc264c7a64e4b3546945a
3,417
py
Python
ooobuild/lo/awt/uno_control_group_box_model.py
Amourspirit/ooo_uno_tmpl
64e0c86fd68f24794acc22d63d8d32ae05dd12b8
[ "Apache-2.0" ]
null
null
null
ooobuild/lo/awt/uno_control_group_box_model.py
Amourspirit/ooo_uno_tmpl
64e0c86fd68f24794acc22d63d8d32ae05dd12b8
[ "Apache-2.0" ]
null
null
null
ooobuild/lo/awt/uno_control_group_box_model.py
Amourspirit/ooo_uno_tmpl
64e0c86fd68f24794acc22d63d8d32ae05dd12b8
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 # # Copyright 2022 :Barry-Thomas-Paul: Moss # # 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 applicab...
28.239669
146
0.657302
fd425e02c260465ad9788485f3e5014d8c9ca4d1
2,725
py
Python
data/cirq_new/cirq_program/startCirq_pragma493.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
data/cirq_new/cirq_program/startCirq_pragma493.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
data/cirq_new/cirq_program/startCirq_pragma493.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Time : 5/15/20 4:49 PM # @File : grover.py # qubit number=4 # total number=17 import cirq import cirq.google as cg from typing import Optional import sys from math import log2 import numpy as np class Opty(cirq.PointOptimizer): def optimization_at( ...
32.831325
92
0.645505
b34fdf0a49caff104394b8985a7504d096b7396b
61,106
py
Python
osm_ro/vimconn_openvim.py
igordcard/RO
d9f2b88a86bb04c44f40008c719f6ff6cd7aea2f
[ "Apache-2.0" ]
null
null
null
osm_ro/vimconn_openvim.py
igordcard/RO
d9f2b88a86bb04c44f40008c719f6ff6cd7aea2f
[ "Apache-2.0" ]
null
null
null
osm_ro/vimconn_openvim.py
igordcard/RO
d9f2b88a86bb04c44f40008c719f6ff6cd7aea2f
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- ## # Copyright 2015 Telefónica Investigación y Desarrollo, S.A.U. # This file is part of openmano # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License ...
45.330861
174
0.579256
4463314721311911ab2467053820a7ea25747474
1,704
py
Python
example.py
ruandocini/pyScopus
cec3477301056524c8c83ab124042899692a5263
[ "MIT" ]
null
null
null
example.py
ruandocini/pyScopus
cec3477301056524c8c83ab124042899692a5263
[ "MIT" ]
null
null
null
example.py
ruandocini/pyScopus
cec3477301056524c8c83ab124042899692a5263
[ "MIT" ]
null
null
null
import requests import pandas as pd import time import extractor as ext query = 'TITLE-ABS-KEY ( temperature OR rain* OR precipitat* OR warm* OR summer OR winter OR spring OR autumn OR meteorolog* OR weather OR forecast* OR humidit* OR wave OR wind OR tide* OR "ocean current" OR "mariti...
106.5
1,390
0.640258
411f387b9ed9356ea2f50cdb6a217105b330bc07
5,232
py
Python
proj2_test_code.py
Nucliam/comp10001-2021s1
61441aa9b3c89a3938046e4301a8f75cae70a8f8
[ "MIT" ]
2
2021-05-01T01:55:36.000Z
2021-05-01T04:48:35.000Z
proj2_test_code.py
Nucliam/comp10001-2021s1
61441aa9b3c89a3938046e4301a8f75cae70a8f8
[ "MIT" ]
null
null
null
proj2_test_code.py
Nucliam/comp10001-2021s1
61441aa9b3c89a3938046e4301a8f75cae70a8f8
[ "MIT" ]
7
2021-05-19T03:08:42.000Z
2021-05-26T05:44:57.000Z
# # Test harness for COMP10001 Project 2, 2021s1 # # Author: Tim Baldwin # # Date: 26/4/2021 # # Version 1.0 # import sys try: import program as submission # import the file `program.py' import tests # import the file `tests.py' try: import tests_extra except ImportError: print("W...
31.902439
120
0.582951
41303daeef292f5f1b91542d518a67bfb86a1d0e
467
py
Python
Python3/0312-Burst-Balloons/soln-1.py
wyaadarsh/LeetCode-Solutions
3719f5cb059eefd66b83eb8ae990652f4b7fd124
[ "MIT" ]
5
2020-07-24T17:48:59.000Z
2020-12-21T05:56:00.000Z
Python3/0312-Burst-Balloons/soln-1.py
zhangyaqi1989/LeetCode-Solutions
2655a1ffc8678ad1de6c24295071308a18c5dc6e
[ "MIT" ]
null
null
null
Python3/0312-Burst-Balloons/soln-1.py
zhangyaqi1989/LeetCode-Solutions
2655a1ffc8678ad1de6c24295071308a18c5dc6e
[ "MIT" ]
2
2020-07-24T17:49:01.000Z
2020-08-31T19:57:35.000Z
class Solution: def maxCoins(self, nums: List[int]) -> int: nums = [1] + [num for num in nums if num] + [1] n = len(nums) dp = [[0] * n for _ in range(n)] for length in range(1, n - 1): for l in range(0, n - 1 - length): r = l + length + 1 ...
38.916667
95
0.423983
bec59677770b50bb173450dacdec0a9674051307
1,480
py
Python
Lab2/main.py
EricCharnesky/CIS2001-Winter2021
a633e32026726f985eea1fe7dd0da3497fff45aa
[ "MIT" ]
3
2021-02-04T22:56:48.000Z
2021-07-17T05:47:24.000Z
Lab2/main.py
EricCharnesky/CIS2001-Winter2021
a633e32026726f985eea1fe7dd0da3497fff45aa
[ "MIT" ]
null
null
null
Lab2/main.py
EricCharnesky/CIS2001-Winter2021
a633e32026726f985eea1fe7dd0da3497fff45aa
[ "MIT" ]
1
2021-02-07T01:40:24.000Z
2021-02-07T01:40:24.000Z
from matplotlib import pyplot as plt import sys import time def compute_time_to_add(list_to_add_to, item): start = time.perf_counter() list_to_add_to.append(item) end = time.perf_counter() return end-start def compute_time_to_remove_from_index(list_to_remove_from, index_to_remove_from): start =...
25.964912
127
0.745946
b734d6db8a968728167096f78620ebfb23e18795
1,524
py
Python
examples/12_building_subqueries/models/kfai_pets_model.py
kungfuai/sql-chemistry
98f75bb66eff87cec51eb77ecc2ebba1a1ae0870
[ "MIT" ]
1
2021-07-29T15:50:02.000Z
2021-07-29T15:50:02.000Z
examples/10_group_by_clause_queries/models/kfai_pets_model.py
kungfuai/sql-chemistry
98f75bb66eff87cec51eb77ecc2ebba1a1ae0870
[ "MIT" ]
3
2021-05-20T14:35:53.000Z
2021-06-25T12:24:26.000Z
examples/11_having_clause_queries/models/kfai_pets_model.py
kungfuai/sql-chemistry
98f75bb66eff87cec51eb77ecc2ebba1a1ae0870
[ "MIT" ]
2
2021-05-04T18:42:44.000Z
2021-09-18T16:27:35.000Z
from sqlalchemy import Column, ForeignKey, Boolean, String, Integer from sqlalchemy.dialects.postgresql import UUID from sqlalchemy.ext.declarative import declarative_base from sqlalchemy.orm import relationship from uuid import uuid4 BaseDbModel = declarative_base() class EmployeeModel(BaseDbModel): __tablename...
33.130435
90
0.749344
f852e3b7898c876ebcf745ce2111fa2e5aff8306
1,419
py
Python
aliyun-python-sdk-gpdb/aliyunsdkgpdb/request/v20160503/DescribeRegionsRequest.py
jia-jerry/aliyun-openapi-python-sdk
e90f3683a250cfec5b681b5f1d73a68f0dc9970d
[ "Apache-2.0" ]
1,001
2015-07-24T01:32:41.000Z
2022-03-25T01:28:18.000Z
aliyun-python-sdk-gpdb/aliyunsdkgpdb/request/v20160503/DescribeRegionsRequest.py
jia-jerry/aliyun-openapi-python-sdk
e90f3683a250cfec5b681b5f1d73a68f0dc9970d
[ "Apache-2.0" ]
363
2015-10-20T03:15:00.000Z
2022-03-08T12:26:19.000Z
aliyun-python-sdk-gpdb/aliyunsdkgpdb/request/v20160503/DescribeRegionsRequest.py
jia-jerry/aliyun-openapi-python-sdk
e90f3683a250cfec5b681b5f1d73a68f0dc9970d
[ "Apache-2.0" ]
682
2015-09-22T07:19:02.000Z
2022-03-22T09:51:46.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
37.342105
76
0.764623
d30209d410becc46c64ac09b42cd21a10407238e
5,115
py
Python
Interface/Dialogs/GainCoinsDialog.py
Snackhole/PyFifth
2a644b81c08d3abc35889fa45eae280dbbcc037d
[ "MIT" ]
null
null
null
Interface/Dialogs/GainCoinsDialog.py
Snackhole/PyFifth
2a644b81c08d3abc35889fa45eae280dbbcc037d
[ "MIT" ]
null
null
null
Interface/Dialogs/GainCoinsDialog.py
Snackhole/PyFifth
2a644b81c08d3abc35889fa45eae280dbbcc037d
[ "MIT" ]
null
null
null
from PyQt5 import QtCore from PyQt5.QtWidgets import QDialog, QGridLayout, QSizePolicy, QPushButton, QSpinBox, QLabel class GainCoinsDialog(QDialog): def __init__(self, ParentWindow): super().__init__(parent=ParentWindow) # Store Parameters self.ParentWindow = ParentWindow # Vari...
40.595238
92
0.668622
8dd8572bb41c67d9b0d65e0b726eea1e143bdd6c
9,620
py
Python
ngeo_browse_server/control/management/commands/ngeo_check_overlapping_time.py
EOX-A/ngeo-b
b55315c7955b4c2b68cbd7f8276ac890ee19106e
[ "MIT" ]
4
2016-08-05T17:33:41.000Z
2020-07-10T21:30:13.000Z
ngeo_browse_server/control/management/commands/ngeo_check_overlapping_time.py
EOX-A/ngeo-b
b55315c7955b4c2b68cbd7f8276ac890ee19106e
[ "MIT" ]
23
2015-10-29T17:52:06.000Z
2021-07-20T09:52:18.000Z
ngeo_browse_server/control/management/commands/ngeo_check_overlapping_time.py
EOX-A/ngeo-b
b55315c7955b4c2b68cbd7f8276ac890ee19106e
[ "MIT" ]
5
2015-07-21T09:33:57.000Z
2019-11-28T22:55:03.000Z
#------------------------------------------------------------------------------ # # Project: ngEO Browse Server <https://github.com/EOX-A/ngeo-b> # Authors: Lubomir Bucek <lubomir.bucek@eox.at> # #------------------------------------------------------------------------------ # Copyright (C) 2019 EOX IT Services GmbH # ...
53.149171
216
0.568607
e9f33f9270f289b500363cac4b62c542d6e1e22d
1,712
py
Python
schemas/tests/unit/schema_data.py
bcgov/FWBEN
d155b11b16b9f3d454d5887cddf13d276d8aebdd
[ "Apache-2.0" ]
1
2019-08-17T03:11:12.000Z
2019-08-17T03:11:12.000Z
schemas/tests/unit/schema_data.py
bcgov/FWBEN
d155b11b16b9f3d454d5887cddf13d276d8aebdd
[ "Apache-2.0" ]
206
2019-08-09T18:30:53.000Z
2022-02-27T21:28:50.000Z
schemas/tests/unit/schema_data.py
bcgov/FWBEN
d155b11b16b9f3d454d5887cddf13d276d8aebdd
[ "Apache-2.0" ]
null
null
null
# Copyright © 2019 Province of British Columbia # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agr...
32.301887
83
0.617407
1012b866f1f788be775e2fc0f091c3572d0725c7
2,972
py
Python
FClip/lr_schedulers.py
Delay-Xili/F-Clip
ea5a7b2ddba8f4baf57e62962b479d8f0447bd65
[ "MIT" ]
93
2021-04-22T03:20:27.000Z
2022-03-27T02:21:49.000Z
FClip/lr_schedulers.py
Delay-Xili/F-Clip
ea5a7b2ddba8f4baf57e62962b479d8f0447bd65
[ "MIT" ]
10
2021-04-23T09:30:37.000Z
2022-02-28T10:24:41.000Z
FClip/lr_schedulers.py
Delay-Xili/F-Clip
ea5a7b2ddba8f4baf57e62962b479d8f0447bd65
[ "MIT" ]
9
2021-04-22T05:21:26.000Z
2022-03-17T07:57:45.000Z
from __future__ import absolute_import from __future__ import print_function import torch import math from torch.optim.lr_scheduler import _LRScheduler def init_lr_scheduler(optimizer, lr_scheduler='multi_step', # learning rate scheduler stepsize=[20, 40], # step size to d...
42.457143
125
0.651413
df190a3420896fcfcd67b9ef9d4ca6e10fc25e06
40
py
Python
Replacethesubstring.py
Arnabsaha6/Snakify
df0c1112ae8a56a275044f786bfd89f746e3ca85
[ "MIT" ]
null
null
null
Replacethesubstring.py
Arnabsaha6/Snakify
df0c1112ae8a56a275044f786bfd89f746e3ca85
[ "MIT" ]
null
null
null
Replacethesubstring.py
Arnabsaha6/Snakify
df0c1112ae8a56a275044f786bfd89f746e3ca85
[ "MIT" ]
null
null
null
Code: print(input().replace('1', 'one'))
20
34
0.625
86d9c764207d85fda619a26f01cdcd8db6e3ad75
5,693
py
Python
tests/providers/samba/hooks/test_samba.py
ahdbilal/airflow
37afe55775676e2cb4cf6ed0cfc6c892855d6805
[ "Apache-2.0" ]
4
2020-02-16T18:13:54.000Z
2021-01-01T03:22:19.000Z
tests/providers/samba/hooks/test_samba.py
ahdbilal/airflow
37afe55775676e2cb4cf6ed0cfc6c892855d6805
[ "Apache-2.0" ]
14
2019-11-22T09:24:20.000Z
2021-07-09T06:06:59.000Z
tests/providers/samba/hooks/test_samba.py
ahdbilal/airflow
37afe55775676e2cb4cf6ed0cfc6c892855d6805
[ "Apache-2.0" ]
1
2020-04-12T00:38:02.000Z
2020-04-12T00:38:02.000Z
# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not...
46.663934
105
0.764623
7b29ad3fecf23aed4ff790cba32bea031a083628
1,700
py
Python
python/Lists.py
yandong2023/The-sword-pointing-to-offer-code
bb7b43222c8f0dac72a31dae8484eb333aca72c1
[ "Apache-2.0" ]
2
2021-07-05T23:00:12.000Z
2021-07-07T02:37:23.000Z
python/Lists.py
yandong2023/leetcode-Top
0df7974e073a39a88898431ac6fd873c6d04804f
[ "Apache-2.0" ]
null
null
null
python/Lists.py
yandong2023/leetcode-Top
0df7974e073a39a88898431ac6fd873c6d04804f
[ "Apache-2.0" ]
null
null
null
class Node: def __init__(self, initdata): self.data = initdata self.next = None def getData(self): return self.data def getNext(self): return self.next def setData(self, newdata): self.next = newdata def setNext(self, nextNode): self.next = nextNod...
21.518987
47
0.548824
bd6f2a93a7ec6954f8fa1055fbe570c4bee89fed
15,726
py
Python
simulation/dqn-simulation/r9/dqn-delta.py
pgabriela/dqn-jitsi-autoscaler
b39eb335e584095ef66a9941dbe0b2ea21a02d4a
[ "Apache-2.0" ]
null
null
null
simulation/dqn-simulation/r9/dqn-delta.py
pgabriela/dqn-jitsi-autoscaler
b39eb335e584095ef66a9941dbe0b2ea21a02d4a
[ "Apache-2.0" ]
null
null
null
simulation/dqn-simulation/r9/dqn-delta.py
pgabriela/dqn-jitsi-autoscaler
b39eb335e584095ef66a9941dbe0b2ea21a02d4a
[ "Apache-2.0" ]
null
null
null
import math import json import random import time import calendar import pickle import os import requests import numpy as np import pandas as pd import matplotlib.pyplot as plt from collections import namedtuple import torch import torch.nn as nn import torch.optim as optim import torch.nn.functional as F SEED = 270...
35.740909
200
0.579168
2ea045f7225403c1645c2f200037640c34bcb128
1,715
py
Python
django_iris/cursor.py
nickmitchko/django-iris
2eb59553e554ad022b96bd37921f7f35bbb64e38
[ "MIT" ]
2
2022-02-23T12:46:23.000Z
2022-02-27T22:14:36.000Z
django_iris/cursor.py
nickmitchko/django-iris
2eb59553e554ad022b96bd37921f7f35bbb64e38
[ "MIT" ]
3
2022-03-19T02:04:51.000Z
2022-03-19T19:15:55.000Z
django_iris/cursor.py
nickmitchko/django-iris
2eb59553e554ad022b96bd37921f7f35bbb64e38
[ "MIT" ]
3
2022-02-15T14:08:45.000Z
2022-03-19T17:05:37.000Z
class CursorWrapper: def __init__(self, cursor): self.cursor = cursor def _fix_for_params(self, query, params): if query.endswith(';'): query = query[:-1] if params is None: params = [] elif hasattr(params, 'keys'): # Handle params as dict ...
28.114754
59
0.552187
32cbafe0abcf11e10c12a5c38cf1c23a848c8966
8,717
py
Python
MoveInfoEnums.py
GGelatin/TekkenBot
33e9a319a085aa17f355dc6f470dfb15e15020cd
[ "MIT" ]
null
null
null
MoveInfoEnums.py
GGelatin/TekkenBot
33e9a319a085aa17f355dc6f470dfb15e15020cd
[ "MIT" ]
null
null
null
MoveInfoEnums.py
GGelatin/TekkenBot
33e9a319a085aa17f355dc6f470dfb15e15020cd
[ "MIT" ]
null
null
null
from enum import Enum class AttackType(Enum): """ """ # Doesn't hit characters on the ground? # Very rare, appears on Alisa's chainsaw stance f+2 ANTIAIR_ONLY = 11 THROW = 10 # This is only the attack type *during* the throw animation LOW_UNBLOCKABLE = 9 # Yoshimitsu's 10 hit co...
24.905714
81
0.609843
b9bce3cf092096922371d3ad4710243687daa666
1,453
py
Python
kws_streaming/models/models.py
bryantower/google-research
2d5dc20e96152566d0876977e4fb974724f406a6
[ "Apache-2.0" ]
2
2020-05-14T06:29:29.000Z
2020-08-10T17:30:15.000Z
kws_streaming/models/models.py
JustinDurham/google-research
9049acf9246c1b75170f0c6757e62a8f619a9db6
[ "Apache-2.0" ]
15
2020-09-25T22:39:40.000Z
2022-02-10T02:11:48.000Z
kws_streaming/models/models.py
JustinDurham/google-research
9049acf9246c1b75170f0c6757e62a8f619a9db6
[ "Apache-2.0" ]
2
2020-08-29T08:58:30.000Z
2021-08-29T09:59:34.000Z
# coding=utf-8 # Copyright 2020 The Google Research 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 applicab...
34.595238
74
0.756366
b7a56df23b04d1231b47581ab16430cfc290fa67
4,675
py
Python
modulos/modulo_03/codigoFuente/src/analizadorSintactico.py
CodeRevenge/proyecto-seminario-traductores-ii
02ecc462450d7814b7045085229d94127bb7749c
[ "MIT" ]
1
2020-11-09T05:36:25.000Z
2020-11-09T05:36:25.000Z
modulos/modulo_03/codigoFuente/src/analizadorSintactico.py
CodeRevenge/proyecto-seminario-traductores-ii
02ecc462450d7814b7045085229d94127bb7749c
[ "MIT" ]
null
null
null
modulos/modulo_03/codigoFuente/src/analizadorSintactico.py
CodeRevenge/proyecto-seminario-traductores-ii
02ecc462450d7814b7045085229d94127bb7749c
[ "MIT" ]
null
null
null
from src.analizadorLexico import AnalizadorLexico from src.arbol import Arbol class ReglasSintacticas: def __init__(self): self.tabla_lr = [] self.extra = [] self.id_reglas = [] self.long_reglas = [] self.id_regla_int = [] self.leer_reglas() def leer_reglas(self...
39.618644
127
0.542888
c649f6b2c709f2245d3a564df48d315c9b5cab56
281
py
Python
ch9-schemas-and-documentation/posts/urls.py
NazarMiroshnichenko/djangoforapis_30
7ae64f2f7869ffd21453914de8a008d405875bcc
[ "MIT" ]
6
2020-09-04T18:06:26.000Z
2021-02-27T03:37:57.000Z
ch9-schemas-and-documentation/posts/urls.py
RicardoVeronica/restapiswithdjango
bec24822cd8bc839395dc978b42914d3b85db99f
[ "MIT" ]
null
null
null
ch9-schemas-and-documentation/posts/urls.py
RicardoVeronica/restapiswithdjango
bec24822cd8bc839395dc978b42914d3b85db99f
[ "MIT" ]
3
2020-12-06T15:37:31.000Z
2021-09-09T11:07:51.000Z
from django.urls import path from rest_framework.routers import SimpleRouter from .views import UserViewSet, PostViewSet router = SimpleRouter() router.register('users', UserViewSet, basename='users') router.register('', PostViewSet, basename='posts') urlpatterns = router.urls
25.545455
55
0.797153
021592573df2ea25edcdb2cb7d66476885a1ae1d
1,921
py
Python
main.py
theoldmoon0602/YARU
9b7cfc65d8890e72a0719f2aedb589f05d11221a
[ "MIT" ]
null
null
null
main.py
theoldmoon0602/YARU
9b7cfc65d8890e72a0719f2aedb589f05d11221a
[ "MIT" ]
null
null
null
main.py
theoldmoon0602/YARU
9b7cfc65d8890e72a0719f2aedb589f05d11221a
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 from dateutil.parser import parse import os import sys import json class Farenda(object): def __init__(self, teksto, limdato=None): self.teksto = teksto try: self.limdato = parse(limdato).strftime('%Y/%m/%d') except: self.limdato = None def da...
24.316456
71
0.60177
e7095af1686f4ebe41f5e5453541b22ee2b7ae55
2,130
py
Python
tests/test_UTILS_expand_prefixes.py
kcoyle/dctap-python
e688ed244327bc2b92d68b98a66b81d9b03cd60a
[ "MIT" ]
6
2021-06-01T18:53:35.000Z
2021-12-08T14:38:01.000Z
tests/test_UTILS_expand_prefixes.py
kcoyle/dctap-python
e688ed244327bc2b92d68b98a66b81d9b03cd60a
[ "MIT" ]
9
2021-06-02T08:14:38.000Z
2021-07-13T07:39:56.000Z
tests/test_UTILS_expand_prefixes.py
kcoyle/dctap-python
e688ed244327bc2b92d68b98a66b81d9b03cd60a
[ "MIT" ]
3
2021-06-13T20:03:11.000Z
2021-11-21T16:25:29.000Z
"""Verify that string is valid as URL.""" import os import pytest from dctap.utils import expand_uri_prefixes def test_utils_expand_uri_prefixes(tmp_path): """Expands prefixes in shapes dictionary according as per config settings.""" config_dict = { "default_shape_identifier": "default", "prefixes": ...
30.869565
81
0.399531
47ad7cc06511ed20e3c5ca8573f1639c46e75208
1,730
py
Python
setup.py
7starsea/shark
5030f576da6f5998728d80170480e68a3debfe79
[ "MIT" ]
null
null
null
setup.py
7starsea/shark
5030f576da6f5998728d80170480e68a3debfe79
[ "MIT" ]
null
null
null
setup.py
7starsea/shark
5030f576da6f5998728d80170480e68a3debfe79
[ "MIT" ]
null
null
null
from skbuild import setup from setuptools import find_packages # # python setup.py install --generator "Sublime Text 2 - Unix Makefiles" -- -- -j8 # # python setup.py install -- -- -j8 package_folder = 'shark' setup( name='shark', version='0.0.1', description='reinforcement learning project...
34.6
90
0.586705
e7eec646e08dfc37a5cb67cbf799afca137c3531
685
py
Python
tests/test_meaning.py
rhyspowell/pybites-tools
27b2808ba125735ec76108c3b321a8f463439866
[ "MIT" ]
null
null
null
tests/test_meaning.py
rhyspowell/pybites-tools
27b2808ba125735ec76108c3b321a8f463439866
[ "MIT" ]
null
null
null
tests/test_meaning.py
rhyspowell/pybites-tools
27b2808ba125735ec76108c3b321a8f463439866
[ "MIT" ]
null
null
null
import argparse import pytest from pybites_tools.meaning import get_meaning, main from unittest import mock @pytest.mark.parametrize( "args, expected", [ ( argparse.Namespace(origin=False, word="word"), "The smallest unit of language that has a particular meaning and can be ex...
27.4
179
0.654015
9f3010fa10768268d3b98c3e1047e4721f408430
874
py
Python
ebiznes/apps/service/migrations/0004_auto_20191101_0941.py
khaki560/EBiznes
a053e329978f6ba4a7565e259d8a843a4d6530a7
[ "MIT" ]
null
null
null
ebiznes/apps/service/migrations/0004_auto_20191101_0941.py
khaki560/EBiznes
a053e329978f6ba4a7565e259d8a843a4d6530a7
[ "MIT" ]
1
2019-10-30T06:26:36.000Z
2019-11-20T17:07:25.000Z
ebiznes/apps/service/migrations/0004_auto_20191101_0941.py
khaki560/EBiznes
a053e329978f6ba4a7565e259d8a843a4d6530a7
[ "MIT" ]
1
2019-11-12T19:09:05.000Z
2019-11-12T19:09:05.000Z
# Generated by Django 2.2.5 on 2019-11-01 09:41 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('service', '0003_auto_20191028_1805'), ] operations = [ migrations.AddField( model_name='service', name='phone_number...
30.137931
124
0.604119
377deb739f2c678b9c827669cd5f5a92ce15944c
6,204
py
Python
lib/head/non_local_embedded_gaussian.py
Wanger-SJTU/SegToolbox.Pytorch
d2ad07caa4c8ab5370b36a000472d5e019d36364
[ "MIT" ]
2
2019-11-10T14:13:43.000Z
2020-02-12T18:06:48.000Z
lib/head/non_local_embedded_gaussian.py
Wanger-SJTU/SegToolbox.Pytorch
d2ad07caa4c8ab5370b36a000472d5e019d36364
[ "MIT" ]
6
2019-11-06T08:20:18.000Z
2022-03-12T00:03:44.000Z
lib/head/non_local_embedded_gaussian.py
Wanger-SJTU/SegToolbox.Pytorch
d2ad07caa4c8ab5370b36a000472d5e019d36364
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Wang, X., Girshick, R., Gupta, A., & He, K. (2018). # Non-local neural networks. CVPR # Code from https://github.com/AlexHex7/Non-local_pytorch.git import torch from torch import nn from torch.nn import functional as F class _NonLocalBlockND(nn.Module): def __init__(self, in_channels, ...
37.829268
109
0.555448
19d5df97189e576d911461abf2fc3cb1d40767a9
225
py
Python
teste-py3.8/src/Mundo1/aula3/desafios/desafio3.py
NicolasMCP/py
37c073de01db100afe325fe08b2b56bc9c8a6020
[ "MIT" ]
null
null
null
teste-py3.8/src/Mundo1/aula3/desafios/desafio3.py
NicolasMCP/py
37c073de01db100afe325fe08b2b56bc9c8a6020
[ "MIT" ]
null
null
null
teste-py3.8/src/Mundo1/aula3/desafios/desafio3.py
NicolasMCP/py
37c073de01db100afe325fe08b2b56bc9c8a6020
[ "MIT" ]
null
null
null
# Nícolas Ramos # desenvolvido para ser igual ao pedido no desafio print('====== DESAFIO 1 ======') primeiro = int(input('Primeiro número ')) segundo = int(input('Segundo número ')) print(f'A soma é {primeiro + segundo}')
22.5
50
0.671111
7e00177fcf7aaa0b3e0bb54ce9178ef56a6196f6
691
py
Python
shares/facebook.py
cuteredcat/gator
7e9183b4fb33f203f38aa512228305a7a4e089d6
[ "MIT" ]
null
null
null
shares/facebook.py
cuteredcat/gator
7e9183b4fb33f203f38aa512228305a7a4e089d6
[ "MIT" ]
null
null
null
shares/facebook.py
cuteredcat/gator
7e9183b4fb33f203f38aa512228305a7a4e089d6
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- from gator import app from shares import SocialNetwork class Facebook(SocialNetwork): def __init__(self): self.name = "facebook" self.check_interval = app.config["FACEBOOK_CHECK_INTERVAL"] def get(self, link): separator = "?" if "...
27.64
149
0.602026
11a66a6bae297dae084e783ec637e8fbd9bfe7a8
5,962
py
Python
examples/CSCI-4968-MBE/challenges/crackme0x04/solve.py
FantasqueX/angr-doc
0db1ed8d34930197411774147b80da1948955897
[ "BSD-2-Clause" ]
null
null
null
examples/CSCI-4968-MBE/challenges/crackme0x04/solve.py
FantasqueX/angr-doc
0db1ed8d34930197411774147b80da1948955897
[ "BSD-2-Clause" ]
null
null
null
examples/CSCI-4968-MBE/challenges/crackme0x04/solve.py
FantasqueX/angr-doc
0db1ed8d34930197411774147b80da1948955897
[ "BSD-2-Clause" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Author: David Manouchehri <manouchehri@protonmail.com> # Modern Binary Exploitation # http://security.cs.rpi.edu/courses/binexp-spring2015/ import angr import subprocess # from IPython import embed # pop iPython at the end def main(): proj = angr.Project('crackme0x0...
51.396552
188
0.553673
3b0b6b0cd4f28796406bd1ab7ac4d1f1088363c5
276
py
Python
kivy_ios/recipes/pyobjus/__init__.py
Terunami/kivy-ios-test
d128db448b6b5a9ca320a4d06f8d4cd094a08897
[ "MIT" ]
548
2015-01-02T23:04:29.000Z
2022-03-21T11:24:59.000Z
kivy_ios/recipes/pyobjus/__init__.py
Terunami/kivy-ios-test
d128db448b6b5a9ca320a4d06f8d4cd094a08897
[ "MIT" ]
511
2015-01-07T08:07:42.000Z
2022-03-31T18:22:07.000Z
kivy_ios/recipes/pyobjus/__init__.py
Terunami/kivy-ios-test
d128db448b6b5a9ca320a4d06f8d4cd094a08897
[ "MIT" ]
258
2015-02-01T21:42:40.000Z
2022-03-09T21:14:00.000Z
from kivy_ios.toolchain import CythonRecipe class PyobjusRecipe(CythonRecipe): version = "master" url = "https://github.com/kivy/pyobjus/archive/{version}.zip" library = "libpyobjus.a" depends = ["python"] pre_build_ext = True recipe = PyobjusRecipe()
21.230769
65
0.702899
87efccafeb6d4785b6946780462e004b0b999eb7
271
py
Python
EjemplosClase/while.py
fwchj/cursoABMPythonPublic
b19215c2de8c414f68ab99d1aaaccc9db454870b
[ "MIT" ]
2
2019-12-17T01:54:10.000Z
2020-02-13T18:25:29.000Z
EjemplosClase/while.py
fwchj/cursoABMPythonPublic
b19215c2de8c414f68ab99d1aaaccc9db454870b
[ "MIT" ]
null
null
null
EjemplosClase/while.py
fwchj/cursoABMPythonPublic
b19215c2de8c414f68ab99d1aaaccc9db454870b
[ "MIT" ]
4
2019-08-30T00:08:55.000Z
2021-03-19T18:25:05.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Tue Aug 27 19:09:43 2019 @author: florian """ i = 1 while (i<15): print(i) i+=1 print("--------") suma = 0 for x in (2**p for p in range(1,7)): print(x) suma +=x print("--------") print(suma)
14.263158
36
0.516605
bfb49e732275c3ace4fa395b0a774637372963af
428
py
Python
src/read_file.py
xryuseix/proofreader
b4c523d05324cf771acee688d51cfea8d6d6d114
[ "MIT" ]
null
null
null
src/read_file.py
xryuseix/proofreader
b4c523d05324cf771acee688d51cfea8d6d6d114
[ "MIT" ]
5
2020-04-28T18:13:26.000Z
2020-05-17T19:09:42.000Z
src/read_file.py
xryuseix/Proofreader
b4c523d05324cf771acee688d51cfea8d6d6d114
[ "MIT" ]
null
null
null
import csv def readFile(path, is_csv=False): text = "" word_list = [] with open(path) as f: if is_csv: reader = csv.reader(f) for row in reader: for i, r in enumerate(row): if i: word_list.append([r, row[0]]) ...
21.4
53
0.450935
831ba16b05c75f367f61f23e6eb2a237d1710661
4,930
py
Python
opensanctions/crawlers/everypolitician.py
opensanctions/opennames
39675797b0e70e71f54edff2b8e623e23aef9c15
[ "MIT" ]
3
2017-04-14T21:27:07.000Z
2017-04-25T14:57:22.000Z
opensanctions/crawlers/everypolitician.py
opensanctions/opennames
39675797b0e70e71f54edff2b8e623e23aef9c15
[ "MIT" ]
null
null
null
opensanctions/crawlers/everypolitician.py
opensanctions/opennames
39675797b0e70e71f54edff2b8e623e23aef9c15
[ "MIT" ]
null
null
null
from datetime import datetime from typing import Dict, Optional, Set from opensanctions.core import Context from opensanctions import helpers as h def crawl(context: Context): data = context.fetch_json(context.dataset.data.url) for country in data: for legislature in country.get("legislatures", []):...
38.515625
77
0.628195
4b161f7290894aa68ba291885c434e6daac19228
3,734
bzl
Python
tests/unit/proxy_test.bzl
SeleniumHQ/rules_jvm_external
906875b0d5eaaf61a8ca2c9c3835bde6f435d011
[ "Apache-2.0" ]
3
2017-12-01T19:46:36.000Z
2018-03-27T16:55:21.000Z
tests/unit/proxy_test.bzl
SeleniumHQ/rules_jvm_external
906875b0d5eaaf61a8ca2c9c3835bde6f435d011
[ "Apache-2.0" ]
3
2018-01-23T22:52:54.000Z
2018-04-12T12:57:46.000Z
tests/unit/proxy_test.bzl
SeleniumHQ/rules_jvm_external
906875b0d5eaaf61a8ca2c9c3835bde6f435d011
[ "Apache-2.0" ]
5
2017-12-04T15:57:04.000Z
2018-04-05T09:49:32.000Z
load("@bazel_skylib//lib:unittest.bzl", "asserts", "unittest") load("//private:proxy.bzl", "get_java_proxy_args") def _java_proxy_parsing_empty_test_impl(ctx): env = unittest.begin(ctx) asserts.equals(env, [], get_java_proxy_args("", "", "")) asserts.equals(env, [], get_java_proxy_args(None, None, None)) ...
34.256881
134
0.654526
895da9d71112ee309dc00c26dd4c1d87577f5c73
5,716
py
Python
T2GEORES/lloyd_relaxation.py
jejimenezm/T2GEORES
9cb7392ff5d720d06d3b82426a6074b179e073ac
[ "MIT" ]
null
null
null
T2GEORES/lloyd_relaxation.py
jejimenezm/T2GEORES
9cb7392ff5d720d06d3b82426a6074b179e073ac
[ "MIT" ]
null
null
null
T2GEORES/lloyd_relaxation.py
jejimenezm/T2GEORES
9cb7392ff5d720d06d3b82426a6074b179e073ac
[ "MIT" ]
null
null
null
from scipy.spatial import Voronoi import numpy as np class Field(): ''' Create a Voronoi map that can be used to run Lloyd relaxation on an array of 2D points. For background, see: https://en.wikipedia.org/wiki/Lloyd%27s_algorithm ''' def __init__(self, *args, **kwargs): ''' Store the points and b...
36.407643
85
0.618964
d4b44deee3d473b7d8fedd3e1c5d54dfc2050ff2
230
py
Python
references/api/serializers.py
varianks/django_patronus3
3369d02b75b017af3f14f5ee45b292b39b5782c2
[ "MIT" ]
null
null
null
references/api/serializers.py
varianks/django_patronus3
3369d02b75b017af3f14f5ee45b292b39b5782c2
[ "MIT" ]
9
2021-03-30T13:37:06.000Z
2022-03-12T00:35:25.000Z
references/api/serializers.py
varianks/django_patronus3
3369d02b75b017af3f14f5ee45b292b39b5782c2
[ "MIT" ]
null
null
null
from rest_framework import serializers from ..models import Reference class ReferenceSerializer(serializers.ModelSerializer): class Meta: model = Reference fields = ['id','title','description','author','link']
32.857143
61
0.726087
a0ce24c186c9c40273aac124ad3c4f586d17aff0
5,256
py
Python
src/res2net.py
weijun88/SANet
68da18e4a682cfe8f4e9f679bd52fee07f3f562b
[ "MIT" ]
19
2021-08-03T01:36:26.000Z
2022-03-22T08:08:16.000Z
src/res2net.py
weijun88/SANet
68da18e4a682cfe8f4e9f679bd52fee07f3f562b
[ "MIT" ]
3
2021-09-04T03:17:06.000Z
2022-02-26T03:41:34.000Z
src/res2net.py
weijun88/SANet
68da18e4a682cfe8f4e9f679bd52fee07f3f562b
[ "MIT" ]
4
2021-08-25T11:11:41.000Z
2022-03-23T08:17:07.000Z
import torch.nn as nn import math import torch import torch.nn.functional as F class Bottle2neck(nn.Module): expansion = 4 def __init__(self, inplanes, planes, stride=1, downsample=None, baseWidth=26, scale=4, stype='normal'): super(Bottle2neck, self).__init__() width = int(math.floor(pla...
40.122137
137
0.583714
e1efec3d776857c8a09493ac1a2ee6e151e71434
610
py
Python
Paddle_Industry_Practice_Sample_Library/Football_Action/PaddleVideo/paddlevideo/modeling/framework/multimodal/__init__.py
linuxonly801/awesome-DeepLearning
b063757fa130c4d56aea5cce2e592610f1e169f9
[ "Apache-2.0" ]
5
2022-01-30T07:35:58.000Z
2022-02-08T05:45:20.000Z
Paddle_Industry_Practice_Sample_Library/Football_Action/PaddleVideo/paddlevideo/modeling/framework/multimodal/__init__.py
linuxonly801/awesome-DeepLearning
b063757fa130c4d56aea5cce2e592610f1e169f9
[ "Apache-2.0" ]
1
2022-01-14T02:33:28.000Z
2022-01-14T02:33:28.000Z
Paddle_Industry_Practice_Sample_Library/Football_Action/PaddleVideo/paddlevideo/modeling/framework/multimodal/__init__.py
linuxonly801/awesome-DeepLearning
b063757fa130c4d56aea5cce2e592610f1e169f9
[ "Apache-2.0" ]
1
2022-03-03T08:03:53.000Z
2022-03-03T08:03:53.000Z
# Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License" # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applic...
35.882353
74
0.757377
4455786f3194daf0dac275e41d216f6279e9d181
18,780
py
Python
sdk/python/pulumi_azure_native/documentdb/v20200301/sql_resource_sql_user_defined_function.py
sebtelko/pulumi-azure-native
711ec021b5c73da05611c56c8a35adb0ce3244e4
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/documentdb/v20200301/sql_resource_sql_user_defined_function.py
sebtelko/pulumi-azure-native
711ec021b5c73da05611c56c8a35adb0ce3244e4
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/documentdb/v20200301/sql_resource_sql_user_defined_function.py
sebtelko/pulumi-azure-native
711ec021b5c73da05611c56c8a35adb0ce3244e4
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from ... import _utilities fro...
57.431193
2,180
0.695847
3aac6e9bca947c6c51002b90d72877ff5d975d93
1,650
py
Python
main.py
justinmckeown/hashmeashlee
83e7e9dc94c207a255c4ac55b784cd9cc6c12f22
[ "MIT" ]
null
null
null
main.py
justinmckeown/hashmeashlee
83e7e9dc94c207a255c4ac55b784cd9cc6c12f22
[ "MIT" ]
null
null
null
main.py
justinmckeown/hashmeashlee
83e7e9dc94c207a255c4ac55b784cd9cc6c12f22
[ "MIT" ]
null
null
null
import kivy from kivy.app import App from kivy.uix.widget import Widget from kivy.uix.label import Label from kivy.uix.gridlayout import GridLayout from kivy.uix.boxlayout import BoxLayout from kivy.uix.textinput import TextInput from kivy.uix.button import Button from kivy.uix.filechooser import FileChooser #from ply...
26.190476
79
0.651515
1c7a493ea81a6d9c392f07ac0fa18e4f02975bc3
1,978
py
Python
examples/rabbitmq_extensions/length_limit.py
deslum/pika
d8af8a573b3535e02540c2e5a14c7b34e276adc0
[ "BSD-3-Clause" ]
1
2020-11-25T07:31:56.000Z
2020-11-25T07:31:56.000Z
examples/rabbitmq_extensions/length_limit.py
deslum/pika
d8af8a573b3535e02540c2e5a14c7b34e276adc0
[ "BSD-3-Clause" ]
null
null
null
examples/rabbitmq_extensions/length_limit.py
deslum/pika
d8af8a573b3535e02540c2e5a14c7b34e276adc0
[ "BSD-3-Clause" ]
null
null
null
import pika from threading import Thread HOST = 'localhost' USER = 'guest' PASSWORD = 'guest' VHOST = '/' MSG = "Test message for RabbitMQ" QUEUE = 'length_limit_queue' class RabbitMQ(): def __init__(self, exchange='messages', host='localhost', user='guest', ...
28.666667
79
0.596562
982242572e1595afd14568c275f78053a239f6f5
941
py
Python
estate_app/estate_app/doctype/surveysites2/survey_api.py
khaledasem/estate_app-ver4
6c4097e7627f8bbe87916cd5cdcae8f9c692954c
[ "MIT" ]
null
null
null
estate_app/estate_app/doctype/surveysites2/survey_api.py
khaledasem/estate_app-ver4
6c4097e7627f8bbe87916cd5cdcae8f9c692954c
[ "MIT" ]
null
null
null
estate_app/estate_app/doctype/surveysites2/survey_api.py
khaledasem/estate_app-ver4
6c4097e7627f8bbe87916cd5cdcae8f9c692954c
[ "MIT" ]
null
null
null
import frappe @frappe.whitelist() def get_contracted_site(name): return frappe.db.sql(f"""SELECT * FROM tabNewSites WHERE name='{name}';""", as_dict = True) @frappe.whitelist() def get_government_info(city): return frappe.db.sql(f"""SELECT * FROM tabgovern1 WHERE name1='{city}';""", as_dict = True) @frappe.white...
29.40625
122
0.721573
20dd63ec77ea7b88d2db5c311861aab62e6b93b5
10,299
py
Python
sushichef.py
learningequality/sushi-chef-stanford-digital-medic
2c20e5f272add7893723ecd9cae00f0e04c68624
[ "MIT" ]
null
null
null
sushichef.py
learningequality/sushi-chef-stanford-digital-medic
2c20e5f272add7893723ecd9cae00f0e04c68624
[ "MIT" ]
5
2020-05-26T19:13:40.000Z
2022-03-12T00:31:43.000Z
sushichef.py
learningequality/sushi-chef-stanford-digital-medic
2c20e5f272add7893723ecd9cae00f0e04c68624
[ "MIT" ]
1
2021-07-23T06:11:11.000Z
2021-07-23T06:11:11.000Z
#!/usr/bin/env python import hashlib import json import os import re import sys from io import BytesIO from ricecooker.utils import downloader, html_writer from ricecooker.chefs import SushiChef from ricecooker.classes import nodes, files, questions, licenses from ricecooker.config import LOGGER # Use LOG...
40.547244
171
0.635693
dc3ad0813f20302bcb3e3bb7b3797a5b66c5a4b4
7,102
py
Python
Part-03-Understanding-Software-Crafting-Your-Own-Tools/models/edx-platform/common/lib/xmodule/xmodule/tests/test_course_metadata_utils.py
osoco/better-ways-of-thinking-about-software
83e70d23c873509e22362a09a10d3510e10f6992
[ "MIT" ]
3
2021-12-15T04:58:18.000Z
2022-02-06T12:15:37.000Z
Part-03-Understanding-Software-Crafting-Your-Own-Tools/models/edx-platform/common/lib/xmodule/xmodule/tests/test_course_metadata_utils.py
osoco/better-ways-of-thinking-about-software
83e70d23c873509e22362a09a10d3510e10f6992
[ "MIT" ]
null
null
null
Part-03-Understanding-Software-Crafting-Your-Own-Tools/models/edx-platform/common/lib/xmodule/xmodule/tests/test_course_metadata_utils.py
osoco/better-ways-of-thinking-about-software
83e70d23c873509e22362a09a10d3510e10f6992
[ "MIT" ]
1
2019-01-02T14:38:50.000Z
2019-01-02T14:38:50.000Z
""" Tests for course_metadata_utils. """ from collections import namedtuple from datetime import datetime, timedelta from unittest import TestCase from pytz import utc import pytest from xmodule.block_metadata_utils import ( display_name_with_default, display_name_with_default_escaped, url_name_for_block...
40.352273
101
0.588989
ed6459a627a7082a87293e537bafd2fb96b25e4b
19,703
py
Python
mmdet/models/relation_heads/relation_head.py
yizhe-ang/MMSceneGraph
d4daec3d7930d6fe1efe75b9c0a265c8be0b70ba
[ "MIT" ]
null
null
null
mmdet/models/relation_heads/relation_head.py
yizhe-ang/MMSceneGraph
d4daec3d7930d6fe1efe75b9c0a265c8be0b70ba
[ "MIT" ]
null
null
null
mmdet/models/relation_heads/relation_head.py
yizhe-ang/MMSceneGraph
d4daec3d7930d6fe1efe75b9c0a265c8be0b70ba
[ "MIT" ]
null
null
null
# --------------------------------------------------------------- # relation_head.py # Set-up time: 2020/5/22 下午4:09 # Copyright (c) 2020 ICT # Licensed under The MIT License [see LICENSE for details] # Written by Kenneth-Wong (Wenbin-Wang) @ VIPL.ICT # Contact: wenbin.wang@vipl.ict.ac.cn [OR] nkwangwenbin@gmail....
46.36
144
0.584175
6a1a573c3e518a6f5976fba80dd6ae14844a19d9
4,140
py
Python
quadpy/sphere/_lebedev/__init__.py
whzup/quadpy
ca8bd2f9c5a4ae30dc85d8fb79217602bd42525e
[ "MIT" ]
null
null
null
quadpy/sphere/_lebedev/__init__.py
whzup/quadpy
ca8bd2f9c5a4ae30dc85d8fb79217602bd42525e
[ "MIT" ]
null
null
null
quadpy/sphere/_lebedev/__init__.py
whzup/quadpy
ca8bd2f9c5a4ae30dc85d8fb79217602bd42525e
[ "MIT" ]
null
null
null
import json import os import re from ...helpers import article from .._helpers import SphereScheme, cartesian_to_spherical, untangle2 # Sphere integration schemes from a series of publications, in chronological order # <https://en.wikipedia.org/wiki/Lebedev_quadrature> # <https://people.sc.fsu.edu/~jburkardt/datasets...
19.078341
163
0.618116
2711750260f2afd0bfdff3b3873aafefffa90611
4,339
py
Python
catkin_ws/devel/lib/python2.7/dist-packages/duckietown_msgs/msg/_Rects.py
bendychua/final
35fd0477ec5950479f0e082a65db2aa05a92db82
[ "CC-BY-2.0" ]
1
2019-05-13T00:40:11.000Z
2019-05-13T00:40:11.000Z
catkin_ws/devel/lib/python2.7/dist-packages/duckietown_msgs/msg/_Rects.py
bendychua/final
35fd0477ec5950479f0e082a65db2aa05a92db82
[ "CC-BY-2.0" ]
null
null
null
catkin_ws/devel/lib/python2.7/dist-packages/duckietown_msgs/msg/_Rects.py
bendychua/final
35fd0477ec5950479f0e082a65db2aa05a92db82
[ "CC-BY-2.0" ]
null
null
null
# This Python file uses the following encoding: utf-8 """autogenerated by genpy from duckietown_msgs/Rects.msg. Do not edit.""" import sys python3 = True if sys.hexversion > 0x03000000 else False import genpy import struct import duckietown_msgs.msg class Rects(genpy.Message): _md5sum = "f5b74b2b15b5d4d2f299389f9f4...
31.671533
123
0.626412
c6ee9aafcd8fbba69eab3e1516031801425bafe3
2,355
py
Python
src/psdtools.py
Constuelo/email_generator
d8dff15a77ccf8ef6db7393edb44139e07ab3d20
[ "MIT" ]
1
2019-01-17T19:40:02.000Z
2019-01-17T19:40:02.000Z
src/psdtools.py
Constuelo/email_generator
d8dff15a77ccf8ef6db7393edb44139e07ab3d20
[ "MIT" ]
5
2019-01-17T14:16:06.000Z
2019-07-04T20:19:39.000Z
src/psdtools.py
Constuelo/photoshop_email_generator
d8dff15a77ccf8ef6db7393edb44139e07ab3d20
[ "MIT" ]
null
null
null
import sys from src.helpers import colour_to_hex from src.encode import encode def list_of_psd_layers(artboard): lst = [] for layer in reversed(list(artboard)): if ( layer.is_visible() and layer.kind == "group" and "header".lower() not in layer.name.lower() ...
30.192308
103
0.523142
cb9a0b23d3845f2a5ca68809a4238823bafe54d8
5,164
py
Python
examples/python/reconstruction_system/initialize_config.py
amoran-symbio/Open3D
ae7e44e0dcef11a5df763819d47dec8c5bd5294b
[ "MIT" ]
1,455
2021-07-27T19:44:50.000Z
2022-03-31T19:39:21.000Z
examples/python/reconstruction_system/initialize_config.py
amoran-symbio/Open3D
ae7e44e0dcef11a5df763819d47dec8c5bd5294b
[ "MIT" ]
1,439
2021-07-27T16:02:52.000Z
2022-03-31T22:29:05.000Z
examples/python/reconstruction_system/initialize_config.py
amoran-symbio/Open3D
ae7e44e0dcef11a5df763819d47dec8c5bd5294b
[ "MIT" ]
339
2021-07-28T03:07:28.000Z
2022-03-31T13:38:00.000Z
# ---------------------------------------------------------------------------- # - Open3D: www.open3d.org - # ---------------------------------------------------------------------------- # The MIT License (MIT) # # Copyright (c) 2018-2021 www.open3d.org # # Permission i...
49.180952
79
0.688613
5684bf064343281075737322748fce688191ad58
1,830
py
Python
Python/smallest-range-ii.py
RideGreg/LeetCode
b70818b1e6947bf29519a24f78816e022ebab59e
[ "MIT" ]
1
2022-01-30T06:55:28.000Z
2022-01-30T06:55:28.000Z
Python/smallest-range-ii.py
RideGreg/LeetCode
b70818b1e6947bf29519a24f78816e022ebab59e
[ "MIT" ]
null
null
null
Python/smallest-range-ii.py
RideGreg/LeetCode
b70818b1e6947bf29519a24f78816e022ebab59e
[ "MIT" ]
1
2021-12-31T03:56:39.000Z
2021-12-31T03:56:39.000Z
# Time: O(nlogn) # Space: O(1) # 910 # Given an array A of integers, for each integer A[i] # we need to choose either x = -K or x = K, and add x to A[i] (only once). # # After this process, we have some array B. # # Return the smallest possible difference # between the maximum value of B and the minimum value of B. #...
31.016949
97
0.574317
14524a40578c18021c0d3bf903aa6108a1f39231
6,831
py
Python
python_bindings/setup.py
NancyLi1013/nmslib
9db508b0d9965e93f37edf609bb63dd55fd6448a
[ "Apache-2.0" ]
1
2020-09-18T04:35:45.000Z
2020-09-18T04:35:45.000Z
python_bindings/setup.py
NancyLi1013/nmslib
9db508b0d9965e93f37edf609bb63dd55fd6448a
[ "Apache-2.0" ]
null
null
null
python_bindings/setup.py
NancyLi1013/nmslib
9db508b0d9965e93f37edf609bb63dd55fd6448a
[ "Apache-2.0" ]
null
null
null
import os from setuptools import setup, Extension from setuptools.command.build_ext import build_ext import sys import setuptools import struct __version__ = '2.0.5' if sys.platform.startswith("win") and struct.calcsize("P") * 8 == 32: raise RuntimeError("Windows 32-bit is not supported.") dep_list = ['pybind11>...
35.578125
106
0.633875
85d0fe63fda15a3fcab26cfb0ad61313a1441c9c
153
py
Python
bin/hexes/hexahexes-triangle-1.py
tiwo/puzzler
7ad3d9a792f0635f7ec59ffa85fb46b54fd77a7e
[ "Intel" ]
null
null
null
bin/hexes/hexahexes-triangle-1.py
tiwo/puzzler
7ad3d9a792f0635f7ec59ffa85fb46b54fd77a7e
[ "Intel" ]
null
null
null
bin/hexes/hexahexes-triangle-1.py
tiwo/puzzler
7ad3d9a792f0635f7ec59ffa85fb46b54fd77a7e
[ "Intel" ]
1
2022-01-02T16:54:14.000Z
2022-01-02T16:54:14.000Z
#!/usr/bin/env python # $Id$ """ solutions""" import puzzler from puzzler.puzzles.hexahexes import HexahexesTriangle1 puzzler.run(HexahexesTriangle1)
15.3
56
0.771242
93c5e3880176af9ae3596dfac17dc3f56151e36d
3,441
py
Python
demo/dogeyenose_detector.py
jireh-father/mmdetection_210507
857c78d2caef8842909cb46d870570b4dd176792
[ "Apache-2.0" ]
null
null
null
demo/dogeyenose_detector.py
jireh-father/mmdetection_210507
857c78d2caef8842909cb46d870570b4dd176792
[ "Apache-2.0" ]
null
null
null
demo/dogeyenose_detector.py
jireh-father/mmdetection_210507
857c78d2caef8842909cb46d870570b4dd176792
[ "Apache-2.0" ]
null
null
null
from argparse import ArgumentParser from mmdet.apis import inference_detector, init_detector, save_result_pyplot import glob import os import time import shutil from PIL import Image import numpy as np class DogEyeNoseDetector: def __init__(self): pass def is_intersect(a, b): # returns None if rectangle...
38.233333
120
0.609997
4caf0f80303d255537e0f1abf06d60aa27273241
534
py
Python
test_fixtures/integrations/torch/__init__.py
allenai/tango
80c90caefae4ad1c3f8472718ddada912cd8fcf9
[ "Apache-2.0" ]
52
2021-09-24T17:52:34.000Z
2022-03-29T22:55:02.000Z
test_fixtures/integrations/torch/__init__.py
allenai/tango
80c90caefae4ad1c3f8472718ddada912cd8fcf9
[ "Apache-2.0" ]
90
2021-09-29T04:23:29.000Z
2022-03-31T21:23:02.000Z
test_fixtures/integrations/torch/__init__.py
allenai/tango
80c90caefae4ad1c3f8472718ddada912cd8fcf9
[ "Apache-2.0" ]
8
2021-11-13T01:56:22.000Z
2022-02-27T03:29:42.000Z
import torch.nn as nn from tango.integrations.torch import Model @Model.register("basic_regression") class BasicRegression(Model): def __init__(self): super().__init__() self.linear = nn.Linear(10, 1) self.sigmoid = nn.Sigmoid() self.mse = nn.MSELoss() def forward(self, x, y=...
23.217391
43
0.586142
59b9a026963b3bcc0a9587f2f076546628ede8de
7,326
py
Python
sdk/python/pulumi_azure_native/databoxedge/v20190701/get_storage_account_credential.py
pulumi-bot/pulumi-azure-native
f7b9490b5211544318e455e5cceafe47b628e12c
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/databoxedge/v20190701/get_storage_account_credential.py
pulumi-bot/pulumi-azure-native
f7b9490b5211544318e455e5cceafe47b628e12c
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/databoxedge/v20190701/get_storage_account_credential.py
pulumi-bot/pulumi-azure-native
f7b9490b5211544318e455e5cceafe47b628e12c
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from ... import _utilities, _tables from...
36.63
212
0.649331
5ebed3f65121be78defed6fd231067b9b353bc8c
7,898
bzl
Python
tools/maven_info.bzl
ansman/dagger
732323b6c0e9dc9dfd92029db64fe91f0786da51
[ "Apache-2.0" ]
17,481
2015-01-01T03:47:42.000Z
2022-03-31T22:30:34.000Z
tools/maven_info.bzl
ansman/dagger
732323b6c0e9dc9dfd92029db64fe91f0786da51
[ "Apache-2.0" ]
1,982
2015-01-01T18:16:55.000Z
2022-03-31T18:35:19.000Z
tools/maven_info.bzl
ansman/dagger
732323b6c0e9dc9dfd92029db64fe91f0786da51
[ "Apache-2.0" ]
2,552
2015-01-03T15:58:02.000Z
2022-03-30T11:10:08.000Z
# Copyright (C) 2019 The Dagger Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in w...
32.368852
97
0.622816
d4655ce9b53572d682ed903f7f1d1552dc29f15a
1,587
py
Python
sa/profiles/Eltex/MA4000/ping.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
84
2017-10-22T11:01:39.000Z
2022-02-27T03:43:48.000Z
sa/profiles/Eltex/MA4000/ping.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
22
2017-12-11T07:21:56.000Z
2021-09-23T02:53:50.000Z
sa/profiles/Eltex/MA4000/ping.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
23
2017-12-06T06:59:52.000Z
2022-02-24T00:02:25.000Z
# --------------------------------------------------------------------- # Eltex.MA4000.ping # --------------------------------------------------------------------- # Copyright (C) 2007-2014 The NOC Project # See LICENSE for details # --------------------------------------------------------------------- # Python module...
32.387755
100
0.487083
a8b2d1cebaa0fc2a41c9eb0caca9c093a08be3c1
3,007
py
Python
scripts/fine_tune_hyperparams.py
WEgeophysics/watex
21616ce35372a095c3dd624f82a5282b15cb2c91
[ "MIT" ]
3
2021-06-19T02:16:46.000Z
2021-07-16T15:56:49.000Z
scripts/fine_tune_hyperparams.py
WEgeophysics/watex
21616ce35372a095c3dd624f82a5282b15cb2c91
[ "MIT" ]
null
null
null
scripts/fine_tune_hyperparams.py
WEgeophysics/watex
21616ce35372a095c3dd624f82a5282b15cb2c91
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ .. synopsis: Create your model and fine tune its hyperparameters. with your dataset. Created on Fri Sep 24 21:28:48 2021 @author: @Daniel03 """ from sklearn.linear_model import LogisticRegression , SGDClassifier from sklearn.svm import SVC, LinearSVC from watex.viewer.mlplot im...
35.376471
101
0.535085
1587837a0bfc4581c6734989b4c8c51a8258ce10
36,979
py
Python
src/python/WMCore/Services/DBS/DBS3Reader.py
hufnagel/WMCore
b150cc725b68fc1cf8e6e0fa07c826226a4421fa
[ "Apache-2.0" ]
null
null
null
src/python/WMCore/Services/DBS/DBS3Reader.py
hufnagel/WMCore
b150cc725b68fc1cf8e6e0fa07c826226a4421fa
[ "Apache-2.0" ]
null
null
null
src/python/WMCore/Services/DBS/DBS3Reader.py
hufnagel/WMCore
b150cc725b68fc1cf8e6e0fa07c826226a4421fa
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python """ _DBSReader_ Readonly DBS Interface """ from __future__ import print_function, division import logging from collections import defaultdict from RestClient.ErrorHandling.RestClientExceptions import HTTPError from dbs.apis.dbsClient import DbsApi from dbs.exceptions.dbsClientException import ...
38.044239
163
0.601774
0088d6191608a263f4d4efecc18fe6c0d095a0f4
2,773
py
Python
nxbender/__init__.py
jeanlego/nxBender
48b066d93d615b8171aa0b6967deca4f53c51f3c
[ "BSD-3-Clause" ]
null
null
null
nxbender/__init__.py
jeanlego/nxBender
48b066d93d615b8171aa0b6967deca4f53c51f3c
[ "BSD-3-Clause" ]
null
null
null
nxbender/__init__.py
jeanlego/nxBender
48b066d93d615b8171aa0b6967deca4f53c51f3c
[ "BSD-3-Clause" ]
null
null
null
import configargparse import requests import logging import getpass from colorlog import ColoredFormatter parser = configargparse.ArgumentParser( description='Connect to a netExtender VPN', default_config_files=['/etc/nxbender', '~/.nxbender'], ) parser.add_argument('-c', '--conf', is_config_file=...
36.012987
154
0.65669
c1ea1bd5e02efa510aa87bd25bb052a9bf42da4c
741
py
Python
problem_solving/python/algorithms/implementation/sequence_equation.py
kcc3/hackerrank-solutions
f862b44b840bd447d99dc148f6bb5e2f5bfb8a86
[ "MIT" ]
null
null
null
problem_solving/python/algorithms/implementation/sequence_equation.py
kcc3/hackerrank-solutions
f862b44b840bd447d99dc148f6bb5e2f5bfb8a86
[ "MIT" ]
null
null
null
problem_solving/python/algorithms/implementation/sequence_equation.py
kcc3/hackerrank-solutions
f862b44b840bd447d99dc148f6bb5e2f5bfb8a86
[ "MIT" ]
1
2020-06-04T09:23:19.000Z
2020-06-04T09:23:19.000Z
def permutation_equation(p): """Hackerrank Problem: https://www.hackerrank.com/challenges/permutation-equation/problem Given a sequence of n integers, p(1), p(2), ..., p(n) where each element is distinct and satisfies 1 <= p(x) <= n. For each x where 1 <= x <= n, find any integer y such that p(p(y)) ~ x an...
35.285714
118
0.620783
9b6b84a59b855235f201a1fbf216c22f4fad8792
1,193
py
Python
datasets/wdbc/wdbc_extract.py
fadel/msc-experiments
427e92982169f7e55f836fea2fd9865f0f809bd4
[ "MIT" ]
null
null
null
datasets/wdbc/wdbc_extract.py
fadel/msc-experiments
427e92982169f7e55f836fea2fd9865f0f809bd4
[ "MIT" ]
null
null
null
datasets/wdbc/wdbc_extract.py
fadel/msc-experiments
427e92982169f7e55f836fea2fd9865f0f809bd4
[ "MIT" ]
null
null
null
import hashlib import logging import pandas as pd import os import os.path import wget DATA_URL = "http://archive.ics.uci.edu/ml/machine-learning-databases/breast-cancer-wisconsin/wdbc.data" DATA_SHA256 = "d606af411f3e5be8a317a5a8b652b425aaf0ff38ca683d5327ffff94c3695f4a" DATA_FILE = "wdbc.data" if __name__ == "__ma...
34.085714
103
0.652976
eadcf29bfc7fb68a7c7d2a8034909be70519d37d
274
py
Python
one_fm/operations/doctype/checkpoints_form_child_table/checkpoints_form_child_table.py
askmetoo/One-FM
c93ed63695a3e62ee8129bd9adf563116b749030
[ "MIT" ]
16
2021-06-14T23:56:47.000Z
2022-03-22T12:05:06.000Z
one_fm/operations/doctype/checkpoints_form_child_table/checkpoints_form_child_table.py
askmetoo/One-FM
c93ed63695a3e62ee8129bd9adf563116b749030
[ "MIT" ]
119
2020-08-17T16:27:45.000Z
2022-03-28T12:42:56.000Z
one_fm/operations/doctype/checkpoints_form_child_table/checkpoints_form_child_table.py
askmetoo/One-FM
c93ed63695a3e62ee8129bd9adf563116b749030
[ "MIT" ]
12
2021-05-16T13:35:40.000Z
2022-02-21T12:41:04.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2020, omar jaber and contributors # For license information, please see license.txt from __future__ import unicode_literals # import frappe from frappe.model.document import Document class CheckpointsFormChildTable(Document): pass
24.909091
49
0.784672
9117728b98731a3eae74d5d9b7c7d0d1cd3d3213
525
py
Python
var/spack/repos/builtin/packages/py-xlrd/package.py
HaochengLIU/spack
26e51ff1705a4d6234e2a0cf734f93f7f95df5cb
[ "ECL-2.0", "Apache-2.0", "MIT" ]
2
2018-11-27T03:39:44.000Z
2021-09-06T15:50:35.000Z
var/spack/repos/builtin/packages/py-xlrd/package.py
HaochengLIU/spack
26e51ff1705a4d6234e2a0cf734f93f7f95df5cb
[ "ECL-2.0", "Apache-2.0", "MIT" ]
1
2019-01-11T20:11:52.000Z
2019-01-11T20:11:52.000Z
var/spack/repos/builtin/packages/py-xlrd/package.py
HaochengLIU/spack
26e51ff1705a4d6234e2a0cf734f93f7f95df5cb
[ "ECL-2.0", "Apache-2.0", "MIT" ]
1
2020-10-14T14:20:17.000Z
2020-10-14T14:20:17.000Z
# Copyright 2013-2018 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * class PyXlrd(PythonPackage): """Library for developers to extract data from Microsoft Excel (tm)...
30.882353
73
0.72
f09d6118de643641e53d35d92594ad024a8559c8
192
py
Python
app/__init__.py
rohansatapathy/rohansatapathy.com
7187fe44bc8f6aac1dc6a621d4d67d91ff5f7f01
[ "MIT" ]
null
null
null
app/__init__.py
rohansatapathy/rohansatapathy.com
7187fe44bc8f6aac1dc6a621d4d67d91ff5f7f01
[ "MIT" ]
null
null
null
app/__init__.py
rohansatapathy/rohansatapathy.com
7187fe44bc8f6aac1dc6a621d4d67d91ff5f7f01
[ "MIT" ]
null
null
null
from flask import Flask from flask_flatpages import FlatPages from config import Config app = Flask(__name__) app.config.from_object(Config) pages = FlatPages(app) from app import routes
14.769231
37
0.802083
82eb51aec0417f7d036e1937ed4824dfe749dead
1,606
py
Python
plenum/test/node_request/test_commit/test_num_of_commit_with_f_plus_one_faults.py
steptan/indy-plenum
488bf63c82753a74a92ac6952da784825ffd4a3d
[ "Apache-2.0" ]
null
null
null
plenum/test/node_request/test_commit/test_num_of_commit_with_f_plus_one_faults.py
steptan/indy-plenum
488bf63c82753a74a92ac6952da784825ffd4a3d
[ "Apache-2.0" ]
null
null
null
plenum/test/node_request/test_commit/test_num_of_commit_with_f_plus_one_faults.py
steptan/indy-plenum
488bf63c82753a74a92ac6952da784825ffd4a3d
[ "Apache-2.0" ]
2
2017-12-13T21:14:54.000Z
2021-06-06T15:48:03.000Z
from functools import partial import pytest from plenum.common.util import getNoInstances from stp_core.common.util import adict from plenum.test.node_request.node_request_helper import checkCommitted from plenum.test.malicious_behaviors_node import makeNodeFaulty, \ delaysPrePrepareProcessing, \ changesReque...
31.490196
81
0.663138
84c77c4679deebbedf6f1a054a33a5d1383193d1
458
py
Python
src/plotfunc.py
r4tn3sh/MIMO_detection
3bfe80c4c3d7e6cfef4510b6e81683d987dc14ac
[ "MIT" ]
6
2020-06-15T21:45:51.000Z
2022-01-19T09:37:37.000Z
src/plotfunc.py
r4tn3sh/MIMO_detection
3bfe80c4c3d7e6cfef4510b6e81683d987dc14ac
[ "MIT" ]
null
null
null
src/plotfunc.py
r4tn3sh/MIMO_detection
3bfe80c4c3d7e6cfef4510b6e81683d987dc14ac
[ "MIT" ]
4
2020-07-24T09:32:13.000Z
2022-02-25T18:37:07.000Z
import matplotlib.pyplot as plt from numpy import array # ---------- PLOTS ------------ def plotConstell(y): """ Plots the constellation of given samples. """ yr = y.real#[a.real for a in y] yi = y.imag#[a.imag for a in y] nrow, ncol = y.shape #p = plt.figure() p, ax = plt.subplots() ...
25.444444
82
0.565502
a96d380327131be0309bbbc2fadcfb0651a776bd
4,781
py
Python
pdfreader/codecs/standard.py
tmcclintock/pdfreader
2933e7b92b5ab7fd60e1a4a27c251de387ad098a
[ "MIT" ]
77
2020-01-07T11:32:53.000Z
2022-03-31T08:16:17.000Z
pdfreader/codecs/standard.py
tmcclintock/pdfreader
2933e7b92b5ab7fd60e1a4a27c251de387ad098a
[ "MIT" ]
49
2019-12-23T19:33:53.000Z
2022-03-06T15:44:41.000Z
pdfreader/codecs/standard.py
tmcclintock/pdfreader
2933e7b92b5ab7fd60e1a4a27c251de387ad098a
[ "MIT" ]
18
2020-05-27T19:26:19.000Z
2022-02-25T06:42:59.000Z
from .codec import Codec class StandardCodec(Codec): use_ZapfDingbats = True name = "StandardEncoding" encode_table = {'A': b'A', 'Æ': b'\xe1', 'B': b'B', 'C': b'C', 'D': b'D', 'E': b'E', 'F': b'F', 'G': b'G', 'H': b'H', 'I': b'I', 'J': b'J', 'K': b'K', 'L': b'L', 'Ł': b'\xe8', 'M': b...
93.745098
124
0.356829
e0d7a8890a2ea6806a6475df423d3fdb169e2ab6
523
py
Python
invsystem/object_adder/migrations/0005_auto_20181227_1206.py
Clemens-Dautermann/Inventarium
da22fb630a876b0e3c7e7bfe8a84c71c9d2ab0f9
[ "MIT" ]
null
null
null
invsystem/object_adder/migrations/0005_auto_20181227_1206.py
Clemens-Dautermann/Inventarium
da22fb630a876b0e3c7e7bfe8a84c71c9d2ab0f9
[ "MIT" ]
4
2018-12-27T23:45:37.000Z
2018-12-30T19:11:23.000Z
invsystem/object_adder/migrations/0005_auto_20181227_1206.py
Clemens-Dautermann/Inventarium
da22fb630a876b0e3c7e7bfe8a84c71c9d2ab0f9
[ "MIT" ]
null
null
null
# Generated by Django 2.1.4 on 2018-12-27 11:06 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('object_adder', '0004_auto_20181223_1300'), ] operations = [ migrations.AlterField( model_name='...
26.15
147
0.657744
b7e6a7076a78e0189045c7d6a92814fe59c84664
1,865
py
Python
doozerlib/assertion.py
Ximinhan/doozer
eeb33625f88cb264f2681347457dff209da261a4
[ "Apache-2.0" ]
16
2018-11-06T16:49:03.000Z
2021-11-07T19:48:49.000Z
doozerlib/assertion.py
Ximinhan/doozer
eeb33625f88cb264f2681347457dff209da261a4
[ "Apache-2.0" ]
479
2018-11-15T15:37:49.000Z
2022-03-31T08:39:44.000Z
doozerlib/assertion.py
Ximinhan/doozer
eeb33625f88cb264f2681347457dff209da261a4
[ "Apache-2.0" ]
38
2018-11-07T14:33:15.000Z
2021-12-13T13:59:12.000Z
""" The assertion module provides functions that will raise an exception if the asserted condition is not met. The use of the FileNotFound exception makes this Python3 ready. Making them functions keeps the exception definition localized. """ import os import errno # Create FileNotFound for Python2 try: import Fi...
28.257576
86
0.695442
aa0340579bf91599ab6a0b6c64ab138b36666de1
4,391
py
Python
scrapel/http/response/__init__.py
NJoyX/nameko-scrapel
7ad43e6b9b14ffe39e50d6c2c9539a9ef5cff2af
[ "Apache-2.0" ]
1
2017-12-03T12:47:19.000Z
2017-12-03T12:47:19.000Z
scrapel/http/response/__init__.py
NJoyX/nameko-scrapel
7ad43e6b9b14ffe39e50d6c2c9539a9ef5cff2af
[ "Apache-2.0" ]
null
null
null
scrapel/http/response/__init__.py
NJoyX/nameko-scrapel
7ad43e6b9b14ffe39e50d6c2c9539a9ef5cff2af
[ "Apache-2.0" ]
null
null
null
from __future__ import unicode_literals, print_function, absolute_import from scrapel.exceptions import NotSupported from scrapel.http import Request from scrapel.http.headers import Headers from six.moves.urllib.parse import urljoin __author__ = 'Fill Q and Scrapy developers' __all__ = ['Response'] # @TODO JsonRes...
33.265152
102
0.577773
5159821abc30141903dd01228c0234705a8c9589
278
py
Python
PythonStudy/learnxinyminutes_Class.py
CenterLineM/PythonPon
ca6a29ec10b095684e90cfcfbf6e0ac1cb5eabe3
[ "Apache-2.0" ]
null
null
null
PythonStudy/learnxinyminutes_Class.py
CenterLineM/PythonPon
ca6a29ec10b095684e90cfcfbf6e0ac1cb5eabe3
[ "Apache-2.0" ]
null
null
null
PythonStudy/learnxinyminutes_Class.py
CenterLineM/PythonPon
ca6a29ec10b095684e90cfcfbf6e0ac1cb5eabe3
[ "Apache-2.0" ]
null
null
null
class Human(object): # 類屬性 此類共用 species = "H. sapiens" def __init__(self,name): # Assign theargument to the instance's name attribute' self.name = name def say(self, msg): return "{name}: {message}".format(name=self.name, message=msg) # 類方法
25.272727
70
0.625899
3e43af14aaf50a1f6002b47528bdb2227adada9b
206
py
Python
Pacote-download/aulas_python_cev/ex_29_multa_km.py
HLAvieira/Curso-em-Video-Python3
04b9fa08acd1f70e39c6671e48330a445e2a77f8
[ "MIT" ]
null
null
null
Pacote-download/aulas_python_cev/ex_29_multa_km.py
HLAvieira/Curso-em-Video-Python3
04b9fa08acd1f70e39c6671e48330a445e2a77f8
[ "MIT" ]
null
null
null
Pacote-download/aulas_python_cev/ex_29_multa_km.py
HLAvieira/Curso-em-Video-Python3
04b9fa08acd1f70e39c6671e48330a445e2a77f8
[ "MIT" ]
null
null
null
velocidade = float(input('Digite a velocidade do carro em Km/h ::::: ')) if velocidade > 80.0: print('você foi multado em R${:.2f} '. format((velocidade-80.0)*7)) else: print('Velocidade permitida')
41.2
72
0.660194
f1df13964525f4c1c4b34cf26c29b60fa1eaa9bc
9,937
py
Python
grr/server/grr_response_server/gui/selenium_tests/hosttable_test.py
certxlm/grr
c2a442a27f656fb18dfa3bce098847e5c5b849d7
[ "Apache-2.0" ]
1
2019-08-28T23:48:20.000Z
2019-08-28T23:48:20.000Z
grr/server/grr_response_server/gui/selenium_tests/hosttable_test.py
AjitNair2/grr
2a2ea891b3927775872904cdd402a18e7bb3d143
[ "Apache-2.0" ]
2
2022-01-15T03:18:12.000Z
2022-02-13T22:02:43.000Z
grr/server/grr_response_server/gui/selenium_tests/hosttable_test.py
acidburn0zzz/grr
44e1a5b1630e8101610faaaebe15b19b5ad30cb1
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python """Tests for host table in search view.""" from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from absl import app from grr_response_server.gui import gui_test_lib from grr.test_lib import test_lib class TestHostTable(gui_test_lib.Sea...
40.394309
80
0.687531
28148ca9d928831a1ae4418d99c1b308e5044b2a
12,557
py
Python
Deprecated/move_paper_feed.py
pkgw/hera_mc
d2769a716a0e68fe709d3834362b94f547136836
[ "BSD-2-Clause" ]
null
null
null
Deprecated/move_paper_feed.py
pkgw/hera_mc
d2769a716a0e68fe709d3834362b94f547136836
[ "BSD-2-Clause" ]
null
null
null
Deprecated/move_paper_feed.py
pkgw/hera_mc
d2769a716a0e68fe709d3834362b94f547136836
[ "BSD-2-Clause" ]
null
null
null
#! /usr/bin/env python # -*- mode: python; coding: utf-8 -*- # Copyright 2016 the HERA Collaboration # Licensed under the 2-clause BSD license. """ Script to handle moving a PAPER feed into HERA hex. """ from __future__ import absolute_import, division, print_function from hera_mc import mc, cm_utils, part_connect, ...
44.059649
98
0.639484
77b25be5f0b55f9785d67b872ccf012c035a3615
1,086
py
Python
docs/examples/basic_tracer/tests/test_tracer.py
nirsky/opentelemetry-python
8d09319c43a24b05d14128361de2c9afe8c856b6
[ "Apache-2.0" ]
null
null
null
docs/examples/basic_tracer/tests/test_tracer.py
nirsky/opentelemetry-python
8d09319c43a24b05d14128361de2c9afe8c856b6
[ "Apache-2.0" ]
null
null
null
docs/examples/basic_tracer/tests/test_tracer.py
nirsky/opentelemetry-python
8d09319c43a24b05d14128361de2c9afe8c856b6
[ "Apache-2.0" ]
null
null
null
# Copyright The OpenTelemetry Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
35.032258
74
0.708103
d95217c77f930c4bdf883c1aaf422357cfdc2733
99
py
Python
BOJ/week02/string/ex11720.py
FridayAlgorithm/taesong_study
50c07ee6ead0fb5bb80e0decb03b801cbbbabf9c
[ "MIT" ]
null
null
null
BOJ/week02/string/ex11720.py
FridayAlgorithm/taesong_study
50c07ee6ead0fb5bb80e0decb03b801cbbbabf9c
[ "MIT" ]
null
null
null
BOJ/week02/string/ex11720.py
FridayAlgorithm/taesong_study
50c07ee6ead0fb5bb80e0decb03b801cbbbabf9c
[ "MIT" ]
2
2020-12-27T15:03:46.000Z
2021-03-06T14:13:34.000Z
T = int(input()) N = input() count = 0 for i in range(len(N)): count += int(N[i]) print(count)
14.142857
23
0.565657
58addef4464253009e8ffbb87c8d97fddbdda2be
44,719
py
Python
pytorch_transformers/modeling_utils.py
ksboy/pytorch-transformers
a0867e3b4d2092acfdda02e53902ffa3495bc9a8
[ "Apache-2.0" ]
null
null
null
pytorch_transformers/modeling_utils.py
ksboy/pytorch-transformers
a0867e3b4d2092acfdda02e53902ffa3495bc9a8
[ "Apache-2.0" ]
null
null
null
pytorch_transformers/modeling_utils.py
ksboy/pytorch-transformers
a0867e3b4d2092acfdda02e53902ffa3495bc9a8
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # Copyright 2018 The Google AI Language Team Authors and The HuggingFace Inc. team. # Copyright (c) 2018, NVIDIA CORPORATION. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a cop...
49.46792
157
0.643843
18d832114f024bc66d52c7382062f8dc2afba1f4
1,325
py
Python
egs/librispeech_adv/asr1/local/create_erep_feats_json.py
brijmohan/espnet
971e43ab429b287517406fa1be3cafd55b992793
[ "Apache-2.0" ]
null
null
null
egs/librispeech_adv/asr1/local/create_erep_feats_json.py
brijmohan/espnet
971e43ab429b287517406fa1be3cafd55b992793
[ "Apache-2.0" ]
null
null
null
egs/librispeech_adv/asr1/local/create_erep_feats_json.py
brijmohan/espnet
971e43ab429b287517406fa1be3cafd55b992793
[ "Apache-2.0" ]
null
null
null
''' Copies filterbank json and replaces feats and shape with new erep feats ''' import os from os.path import exists, join import json # for kaldi io import kaldi_io_py old_json_dir = 'dump/train_100/deltafalse/split_utt_spk' new_feats_scp = 'data/erep_train_100/feats.scp' new_json_dir = 'data/erep_train_100/json'...
27.604167
79
0.592453
e4d706eb78658407c729e0374a3d30a79642646d
5,472
py
Python
src/sage/categories/examples/posets.py
bopopescu/sage
2d495be78e0bdc7a0a635454290b27bb4f5f70f0
[ "BSL-1.0" ]
4
2020-07-17T04:49:44.000Z
2020-07-29T06:33:51.000Z
src/sage/categories/examples/posets.py
Ivo-Maffei/sage
467fbc70a08b552b3de33d9065204ee9cbfb02c7
[ "BSL-1.0" ]
2
2018-10-30T13:40:20.000Z
2020-07-23T12:13:30.000Z
src/sage/categories/examples/posets.py
dimpase/sage
468f23815ade42a2192b0a9cd378de8fdc594dcd
[ "BSL-1.0" ]
7
2021-11-08T10:01:59.000Z
2022-03-03T11:25:52.000Z
""" Examples of posets """ #***************************************************************************** # Copyright (C) 2011 Nicolas M. Thiery <nthiery at users.sf.net> # # Distributed under the terms of the GNU General Public License (GPL) # http://www.gnu.org/licenses/ #**************************...
31.268571
144
0.561038
39dcc313d4291404f441cc2b1be3e85a7d0687a4
2,494
py
Python
align_faces.py
contail/Face-Alignment-with-OpenCV-and-Python
5d0439aa854b559fa396ce7f3e97748be42c15c9
[ "MIT" ]
13
2018-10-05T17:05:20.000Z
2022-01-27T00:54:57.000Z
align_faces.py
contail/Face-Alignment-with-OpenCV-and-Python
5d0439aa854b559fa396ce7f3e97748be42c15c9
[ "MIT" ]
null
null
null
align_faces.py
contail/Face-Alignment-with-OpenCV-and-Python
5d0439aa854b559fa396ce7f3e97748be42c15c9
[ "MIT" ]
6
2019-03-18T06:03:41.000Z
2022-03-02T18:15:01.000Z
from imutils.face_utils import FaceAligner from imutils.face_utils import rect_to_bb import argparse import imutils import dlib import cv2 import os ap = argparse.ArgumentParser() ap.add_argument("-r", "--root_dir", required=True, help="path to root directories of input images") ap.add_argument("-d", "...
37.223881
110
0.595028
0716c555ebe53d1dc694a5dc9cafb8f9679ce67a
10,424
py
Python
audio/augmentation.py
girishdhegde/augmentation
02d5859e365d959da368dbf8e8a9e0800faea032
[ "MIT" ]
1
2021-08-24T17:57:26.000Z
2021-08-24T17:57:26.000Z
audio/augmentation.py
girishdhegde/augmentation
02d5859e365d959da368dbf8e8a9e0800faea032
[ "MIT" ]
null
null
null
audio/augmentation.py
girishdhegde/augmentation
02d5859e365d959da368dbf8e8a9e0800faea032
[ "MIT" ]
1
2021-08-25T08:16:16.000Z
2021-08-25T08:16:16.000Z
import random import glob import torch import torch.nn as nn import torchaudio from einops import rearrange, repeat from einops.layers.torch import Rearrange import numpy as np import sounddevice as sd # Author: Girish Hegde def rms(samples): """Root Mean Square (RMS).""" return torch.sqrt((samples**2).m...
33.197452
125
0.565138
444f1a6e8549a27e356acc04a3029ee841eb1d50
1,023
py
Python
pylurch/contract/client/context/training.py
tingiskhan/pylurch
f94581f7e31fb32fd41d74e55d731147bf64e4ac
[ "MIT" ]
null
null
null
pylurch/contract/client/context/training.py
tingiskhan/pylurch
f94581f7e31fb32fd41d74e55d731147bf64e4ac
[ "MIT" ]
null
null
null
pylurch/contract/client/context/training.py
tingiskhan/pylurch
f94581f7e31fb32fd41d74e55d731147bf64e4ac
[ "MIT" ]
null
null
null
from typing import List, Dict, Any from ...database import Label, Score, Package from .update import UpdateContext class TrainingContext(UpdateContext): def __init__(self, client, training_session): super().__init__(client, training_session, None) def add_label(self, label: str): self._to_com...
34.1
96
0.673509
a708d1728ce200ccd6edb80f2dadf9e8c9cc90f3
38,350
py
Python
salt/states/smartos.py
ev0rtex/salt
769cfe1a7de85a35083423af6abb12220f48a07e
[ "Apache-2.0" ]
null
null
null
salt/states/smartos.py
ev0rtex/salt
769cfe1a7de85a35083423af6abb12220f48a07e
[ "Apache-2.0" ]
null
null
null
salt/states/smartos.py
ev0rtex/salt
769cfe1a7de85a35083423af6abb12220f48a07e
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- ''' Management of SmartOS Standalone Compute Nodes :maintainer: Jorge Schrauwen <sjorge@blackdot.be> :maturity: new :depends: vmadm, imgadm :platform: smartos .. versionadded:: 2016.3.0 .. code-block:: yaml vmtest.example.org: smartos.vm_present: - config...
34.863636
130
0.515854
cbd378e2d53fa2aa75ba5f05bd1dea49259b57b4
32,540
py
Python
ledger/accounts/models.py
mohdbakhrayba/ledger
0180d6b35bce4d028e9f6081c86feffd7a5dfae3
[ "Apache-2.0" ]
null
null
null
ledger/accounts/models.py
mohdbakhrayba/ledger
0180d6b35bce4d028e9f6081c86feffd7a5dfae3
[ "Apache-2.0" ]
11
2019-03-19T02:03:11.000Z
2019-05-31T07:20:59.000Z
ledger/accounts/models.py
dbca-dragon/ledger
6f71699e21c8e502ee805cadc82ee0ec4c004e79
[ "Apache-2.0" ]
null
null
null
from __future__ import unicode_literals import os import zlib from django.contrib.auth.models import BaseUserManager, AbstractBaseUser, PermissionsMixin from django.contrib.postgres.fields import JSONField from django.db import models, IntegrityError, transaction from django.utils.encoding import python_2_unicode_com...
40.828105
258
0.642778
1b93c0d83a276f5976ea230ba69f64461914fb3d
1,320
py
Python
2019/12 December/dp12062019.py
vishrutkmr7/DailyPracticeProblemsDIP
d1bfbc75f2024736c22c05385f753a90ddcfa0f5
[ "MIT" ]
5
2019-08-06T02:34:41.000Z
2022-01-08T03:03:16.000Z
2019/12 December/dp12062019.py
ourangzeb/DailyPracticeProblemsDIP
66c07af88754e5d59b243e3ee9f02db69f7c0a77
[ "MIT" ]
15
2021-06-01T14:04:16.000Z
2022-03-08T21:17:22.000Z
2019/12 December/dp12062019.py
ourangzeb/DailyPracticeProblemsDIP
66c07af88754e5d59b243e3ee9f02db69f7c0a77
[ "MIT" ]
4
2019-09-19T20:00:05.000Z
2021-08-16T11:31:51.000Z
# This problem was recently asked by Microsoft: # A maze is a matrix where each cell can either be a 0 or 1. A 0 represents that the cell is empty, and a 1 represents a wall # that cannot be walked through. You can also only travel either right or down. # Given a nxm matrix, find the number of ways someone can go fro...
25.882353
125
0.522727
aa559ca9f62d2bdb97e45733b0e4107d144a0ef1
2,061
py
Python
var/spack/repos/builtin/packages/tar/package.py
varioustoxins/spack
cab0e4cb240f34891a6d753f3393e512f9a99e9a
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
null
null
null
var/spack/repos/builtin/packages/tar/package.py
varioustoxins/spack
cab0e4cb240f34891a6d753f3393e512f9a99e9a
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
6
2022-01-08T08:41:11.000Z
2022-03-14T19:28:07.000Z
var/spack/repos/builtin/packages/tar/package.py
foeroyingur/spack
5300cbbb2e569190015c72d0970d25425ea38647
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
null
null
null
# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) import re from spack import * class Tar(AutotoolsPackage, GNUMirrorPackage): """GNU Tar provides the ability to cre...
40.411765
94
0.704998
857f3dca205c3d6550b0f9a26a161ebdb01b88a4
377
py
Python
openpype/hosts/standalonepublisher/plugins/publish/collect_app_name.py
Tilix4/OpenPype
8909bd890170880aa7ec8b673abaa25a9bdf40f2
[ "MIT" ]
1
2022-02-08T15:40:41.000Z
2022-02-08T15:40:41.000Z
openpype/hosts/standalonepublisher/plugins/publish/collect_app_name.py
zafrs/OpenPype
4b8e7e1ed002fc55b31307efdea70b0feaed474f
[ "MIT" ]
2
2022-03-18T01:46:03.000Z
2022-03-18T01:46:16.000Z
openpype/hosts/standalonepublisher/plugins/publish/collect_app_name.py
zafrs/OpenPype
4b8e7e1ed002fc55b31307efdea70b0feaed474f
[ "MIT" ]
null
null
null
import pyblish.api class CollectSAAppName(pyblish.api.ContextPlugin): """Collect app name and label.""" label = "Collect App Name/Label" order = pyblish.api.CollectorOrder - 0.5 hosts = ["standalonepublisher"] def process(self, context): context.data["appName"] = "standalone publisher" ...
26.928571
57
0.681698
39ebc559707b4d8eaed23c8f4d780d504e8fed8d
11,231
py
Python
qiskit/optimization/algorithms/minimum_eigen_optimizer.py
MetcalfeTom/qiskit-aqua
1718e1612dba38a3f15309c860fe7875914fe8cc
[ "Apache-2.0" ]
null
null
null
qiskit/optimization/algorithms/minimum_eigen_optimizer.py
MetcalfeTom/qiskit-aqua
1718e1612dba38a3f15309c860fe7875914fe8cc
[ "Apache-2.0" ]
null
null
null
qiskit/optimization/algorithms/minimum_eigen_optimizer.py
MetcalfeTom/qiskit-aqua
1718e1612dba38a3f15309c860fe7875914fe8cc
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # This code is part of Qiskit. # # (C) Copyright IBM 2020. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any modi...
41.139194
100
0.670733