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
a12a09f22c4f5e88f0c6271dc4b2b3de7f615fa8
932
py
Python
server/migrations/versions/4a916694f1ba_add_initial_image_table.py
brodigan-e/capstone-POV
8ba8bf49e168a1c27a9a252d0f7af375a4e0bb5b
[ "MIT" ]
2
2020-10-02T20:49:48.000Z
2020-10-06T01:19:13.000Z
server/migrations/versions/4a916694f1ba_add_initial_image_table.py
brodigan-e/capstone-POV
8ba8bf49e168a1c27a9a252d0f7af375a4e0bb5b
[ "MIT" ]
15
2020-10-01T05:42:06.000Z
2020-12-07T22:48:22.000Z
server/migrations/versions/4a916694f1ba_add_initial_image_table.py
brodigan-e/capstone-POV
8ba8bf49e168a1c27a9a252d0f7af375a4e0bb5b
[ "MIT" ]
1
2020-11-12T20:47:57.000Z
2020-11-12T20:47:57.000Z
"""Add Initial Image Table Revision ID: 4a916694f1ba Revises: Create Date: 2020-10-16 02:24:18.479608 """ import sqlalchemy as sa from alembic import op # revision identifiers, used by Alembic. revision = '4a916694f1ba' down_revision = None branch_labels = None depends_on = None def upgrade(): # ### commands ...
26.628571
65
0.683476
0
0
0
0
0
0
0
0
423
0.453863
a12aedcd932c89aac78464696ed1d71cb2034b31
9,969
py
Python
skyoffset/multisimplex.py
jonathansick/skyoffset
369f54d8a237f48cd56f550e80bf1d39b355bfcd
[ "BSD-3-Clause" ]
null
null
null
skyoffset/multisimplex.py
jonathansick/skyoffset
369f54d8a237f48cd56f550e80bf1d39b355bfcd
[ "BSD-3-Clause" ]
null
null
null
skyoffset/multisimplex.py
jonathansick/skyoffset
369f54d8a237f48cd56f550e80bf1d39b355bfcd
[ "BSD-3-Clause" ]
null
null
null
import os import logging import platform import time import multiprocessing import numpy import pymongo # Pure python/numpy import simplex from scalarobj import ScalarObjective # Cython/numpy import cyscalarobj import cysimplex class MultiStartSimplex(object): """Baseclass for multi-start recongerging simplex s...
39.403162
131
0.634467
5,667
0.568462
0
0
0
0
0
0
3,659
0.367038
a12b99b03f4c428fc4fbd3c7f3bfcb53005d0cea
695
py
Python
netsuitesdk/api/custom_records.py
cart-com/netsuite-sdk-py
9c759b631f7a194efb86c06e1935cdc2856200d3
[ "MIT" ]
null
null
null
netsuitesdk/api/custom_records.py
cart-com/netsuite-sdk-py
9c759b631f7a194efb86c06e1935cdc2856200d3
[ "MIT" ]
null
null
null
netsuitesdk/api/custom_records.py
cart-com/netsuite-sdk-py
9c759b631f7a194efb86c06e1935cdc2856200d3
[ "MIT" ]
null
null
null
from netsuitesdk.internal.utils import PaginatedSearch from .base import ApiBase import logging logger = logging.getLogger(__name__) class CustomRecords(ApiBase): def __init__(self, ns_client): ApiBase.__init__(self, ns_client=ns_client, type_name='CustomRecordType') def get_all_by_id(self, interna...
33.095238
117
0.728058
557
0.801439
0
0
0
0
0
0
36
0.051799
a12be00ef3b06e0094c89aa20c5aafe79c822021
343
py
Python
Support/renameCNVNatorOutput.py
zhongmicai/SV_population
81987865c9b67be5e358cb1b966bb69cc303abee
[ "MIT" ]
18
2019-03-18T00:08:18.000Z
2021-10-19T06:21:56.000Z
Support/renameCNVNatorOutput.py
zhongmicai/SV_population
81987865c9b67be5e358cb1b966bb69cc303abee
[ "MIT" ]
5
2018-11-06T15:18:17.000Z
2020-07-24T09:31:08.000Z
Support/renameCNVNatorOutput.py
zhongmicai/SV_population
81987865c9b67be5e358cb1b966bb69cc303abee
[ "MIT" ]
2
2019-11-13T10:28:58.000Z
2021-09-07T08:25:12.000Z
#!/usr/bin/env python3 import os vcfdir='/home/matt/Plasmodium/Pf_SV/Data' for ID in os.listdir(vcfdir): nameID = '_'.join(ID.split('.')[0].split('_')[:-1]) coreID = nameID.split('_')[-1] if coreID[:3] == 'ERR': os.system('cp {0}.cnvs {1}_DEL.cnvs'.format(coreID, nameID)) os.system('cp {0}.cnvs {1}_DUP.cnvs'.f...
28.583333
62
0.641399
0
0
0
0
0
0
0
0
125
0.364431
a12cb244767dfa01e9b581f3a545006ea34d4ac7
1,568
py
Python
string_1/hello_name.py
nhutnamhcmus/coding-bat-solutions
5f780a4027a6c3523a72961db1bad547c997fdc6
[ "MIT" ]
1
2020-09-19T18:02:13.000Z
2020-09-19T18:02:13.000Z
string_1/hello_name.py
nhutnamhcmus/coding-bat-solutions
5f780a4027a6c3523a72961db1bad547c997fdc6
[ "MIT" ]
null
null
null
string_1/hello_name.py
nhutnamhcmus/coding-bat-solutions
5f780a4027a6c3523a72961db1bad547c997fdc6
[ "MIT" ]
null
null
null
# ======================================================================================================================================= # VNU-HCM, University of Science # Department Computer Science, Faculty of Information Technology # Authors: Nhut-Nam Le (Tich Phan Suy Rong) # © 2020 """ Given a string name, e.g. ...
27.508772
137
0.598852
944
0.599365
0
0
0
0
0
0
725
0.460317
a12f2dc13e43b20caf3450c97b9fa9395b547d8a
335
py
Python
materials/ch_04/escape_str.py
epsilonxe/RMUTT_09090016
863dd8a6471b560831b742da4aec27209c294df5
[ "MIT" ]
null
null
null
materials/ch_04/escape_str.py
epsilonxe/RMUTT_09090016
863dd8a6471b560831b742da4aec27209c294df5
[ "MIT" ]
null
null
null
materials/ch_04/escape_str.py
epsilonxe/RMUTT_09090016
863dd8a6471b560831b742da4aec27209c294df5
[ "MIT" ]
null
null
null
text1 = '''ABCDEF GHIJKL MNOPQRS TUVWXYZ ''' text2 = 'ABCDEF\ GHIJKL\ MNOPQRS\ TUVWXYZ' text3 = 'ABCD\'EF\'GHIJKL' text4 = 'ABCDEF\nGHIJKL\nMNOPQRS\nTUVWXYZ' text5 = 'ABCDEF\fGHIJKL\fMNOPQRS\fTUVWXYZ' print(text1) print('-' * 25) print(text2) print('-' * 25) print(text3) print('-' * 25) print(text4) print('-' * 2...
12.884615
42
0.671642
0
0
0
0
0
0
0
0
168
0.501493
a1300bc0639e795122958402aa1f3b4e0ab96874
823
py
Python
pygears/cookbook/reduce2.py
Risto97/pygears
19393e85101a16762cb3bbbf3010946ef69217f2
[ "MIT" ]
null
null
null
pygears/cookbook/reduce2.py
Risto97/pygears
19393e85101a16762cb3bbbf3010946ef69217f2
[ "MIT" ]
null
null
null
pygears/cookbook/reduce2.py
Risto97/pygears
19393e85101a16762cb3bbbf3010946ef69217f2
[ "MIT" ]
null
null
null
from pygears import gear, Intf from pygears.common import czip from pygears.typing import Tuple, Uint, Union, Queue from pygears.common import fmap, demux, decoupler, fifo, union_collapse from pygears.cookbook import priority_mux, replicate TCfg = Tuple[{'reduce_size': Uint['w_reduce_size'], 'init': 't_acc'}] @gear ...
29.392857
74
0.684083
0
0
0
0
508
0.617254
0
0
47
0.057108
a1309a770978d986e457fb2177d6163ed7ae8ec0
313
py
Python
atcoder/abc166D_i_hate_factorization.py
da-edra/kyopro
ad531d15bcccf6aafdaaef3cc69db850b0f7c471
[ "BSD-3-Clause" ]
2
2020-08-31T17:19:07.000Z
2021-01-08T21:35:48.000Z
atcoder/abc166D_i_hate_factorization.py
edglaz/kyopro
b8ac4f6873418ad20ad417e46d731c35a8062c0d
[ "BSD-3-Clause" ]
null
null
null
atcoder/abc166D_i_hate_factorization.py
edglaz/kyopro
b8ac4f6873418ad20ad417e46d731c35a8062c0d
[ "BSD-3-Clause" ]
null
null
null
# unihernandez22 # https://atcoder.jp/contests/abc166/tasks/abc166_d # math, brute force n = int(input()) for a in range(n): breaked = True for b in range(-1000, 1000): if a**5 - b**5 == n: print(a, b) break; else: breaked = False if breaked: break
20.866667
51
0.539936
0
0
0
0
0
0
0
0
86
0.27476
a130aee35a17b1d7653613de1de880f9a3444608
305
py
Python
packages/grid/apps/worker/src/main/core/database/groups/groups.py
exityan/PySyft
35166c487a5be57f9ad28929ed88a8ba6bdd5aeb
[ "Apache-2.0" ]
425
2019-09-22T06:14:53.000Z
2022-03-30T02:17:34.000Z
packages/grid/apps/worker/src/main/core/database/groups/groups.py
Metrix1010/PySyft
6477f64b63dc285059c3766deab3993653cead2e
[ "Apache-2.0" ]
352
2019-09-17T15:32:51.000Z
2022-03-12T01:07:35.000Z
packages/grid/apps/worker/src/main/core/database/groups/groups.py
Metrix1010/PySyft
6477f64b63dc285059c3766deab3993653cead2e
[ "Apache-2.0" ]
208
2019-09-18T18:32:10.000Z
2022-03-24T01:10:11.000Z
# grid relative from .. import BaseModel from .. import db class Group(BaseModel): __tablename__ = "group" id = db.Column(db.Integer(), primary_key=True, autoincrement=True) name = db.Column(db.String(255)) def __str__(self): return f"<Group id: {self.id}, name: {self.name}>"
21.785714
70
0.655738
243
0.796721
0
0
0
0
0
0
65
0.213115
a130d81a095f620365d47a00f587d3671ea0c357
2,416
py
Python
libraries/urx_python/urx_scripts/demo_apple_tree.py
giacomotomasi/tennisball_demo
f71cd552e64fe21533abe47b986db6999947c3a9
[ "Apache-2.0" ]
null
null
null
libraries/urx_python/urx_scripts/demo_apple_tree.py
giacomotomasi/tennisball_demo
f71cd552e64fe21533abe47b986db6999947c3a9
[ "Apache-2.0" ]
null
null
null
libraries/urx_python/urx_scripts/demo_apple_tree.py
giacomotomasi/tennisball_demo
f71cd552e64fe21533abe47b986db6999947c3a9
[ "Apache-2.0" ]
null
null
null
import urx import logging import time if __name__ == "__main__": logging.basicConfig(level=logging.WARN) #gripper_remove_pos = [0.0755, -0.2824, 0.3477, -0.0387, -3.0754, 0.4400] # rest position (good to place/remove gripper) rob = urx.Robot("192.168.56.1") #rob.set_tcp((0,0,0,0,0,0)) #rob.set_...
32.213333
124
0.577815
0
0
0
0
0
0
0
0
655
0.271109
a1311c3c3114e32c6b986776dfaae1a0d9bb6825
403
py
Python
solution/data_structure2/1302/main.py
jungyoonoh/baekjoon-1
2b4437a4b5e06244fa47fae6c7b7be0157d0f94f
[ "MIT" ]
2,236
2019-08-05T00:36:59.000Z
2022-03-31T16:03:53.000Z
solution/data_structure2/1302/main.py
juy4556/baekjoon
bc0b0a0ebaa45a5bbd32751f84c458a9cfdd9f92
[ "MIT" ]
225
2020-12-17T10:20:45.000Z
2022-01-05T17:44:16.000Z
solution/data_structure2/1302/main.py
juy4556/baekjoon
bc0b0a0ebaa45a5bbd32751f84c458a9cfdd9f92
[ "MIT" ]
602
2019-08-05T00:46:25.000Z
2022-03-31T13:38:23.000Z
# Authored by : gusdn3477 # Co-authored by : - # Link : http://boj.kr/8adc986ae26b461eadd65abdff3cfba9 import sys def input(): return sys.stdin.readline().rstrip() N = int(input()) book = {} for i in range(N): name = input() if name not in book: book[name] = 1 else: book[name] += 1 bo...
19.190476
55
0.600496
0
0
0
0
0
0
0
0
100
0.248139
a13162f4cb62e368c73037f36a88c321b285f2d8
1,152
py
Python
testflows/_core/utils/sort.py
testflows/TestFlows-Core
0aa17247dffd2f7199465031ab16cc4f12c9cfb0
[ "Apache-2.0" ]
3
2020-06-25T19:23:19.000Z
2021-10-20T19:29:56.000Z
testflows/_core/utils/sort.py
testflows/TestFlows-Core
0aa17247dffd2f7199465031ab16cc4f12c9cfb0
[ "Apache-2.0" ]
null
null
null
testflows/_core/utils/sort.py
testflows/TestFlows-Core
0aa17247dffd2f7199465031ab16cc4f12c9cfb0
[ "Apache-2.0" ]
1
2020-02-24T12:31:45.000Z
2020-02-24T12:31:45.000Z
# Copyright 2020 Katteli Inc. # TestFlows.com Open-Source Software Testing Framework (http://testflows.com) # # 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/lice...
38.4
89
0.717882
0
0
0
0
0
0
0
0
839
0.728299
a13291eccf29b835c30e820b06c59c45c1cf58bf
3,220
py
Python
tests/build/test_flash.py
cyliangtw/mbed-tools
69c600c0a5ac1eb0d52b481b5ba020da8bb73d33
[ "Apache-2.0" ]
39
2020-04-03T13:52:34.000Z
2022-03-23T13:08:22.000Z
tests/build/test_flash.py
cyliangtw/mbed-tools
69c600c0a5ac1eb0d52b481b5ba020da8bb73d33
[ "Apache-2.0" ]
306
2020-02-06T18:08:43.000Z
2022-03-25T14:50:18.000Z
tests/build/test_flash.py
cyliangtw/mbed-tools
69c600c0a5ac1eb0d52b481b5ba020da8bb73d33
[ "Apache-2.0" ]
23
2020-03-17T11:42:23.000Z
2022-01-30T02:56:18.000Z
# # Copyright (c) 2020-2021 Arm Limited and Contributors. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import pathlib import tempfile from unittest import TestCase, mock from mbed_tools.build.flash import flash_binary, _build_binary_file_path, _flash_dev from mbed_tools.build.exceptions import Binary...
36.590909
112
0.675776
2,663
0.827019
0
0
1,581
0.490994
0
0
329
0.102174
a133567cd81f4bb8edf05a69d95e9fb2d7bf451d
2,795
py
Python
packettotal_sdk/search_tools.py
RogerDeng/HoneyBot
3843ec6d684786091ced053857d1718ef1fa495c
[ "MIT" ]
67
2019-08-16T05:03:19.000Z
2021-11-25T01:48:23.000Z
packettotal_sdk/search_tools.py
RogerDeng/HoneyBot
3843ec6d684786091ced053857d1718ef1fa495c
[ "MIT" ]
1
2020-09-01T02:40:31.000Z
2020-09-01T02:40:31.000Z
packettotal_sdk/search_tools.py
RogerDeng/HoneyBot
3843ec6d684786091ced053857d1718ef1fa495c
[ "MIT" ]
16
2020-02-20T12:38:40.000Z
2022-03-22T17:45:25.000Z
import time import typing import requests from sys import stderr from datetime import datetime from packettotal_sdk import packettotal_api class SearchTools(packettotal_api.PacketTotalApi): def __init__(self, api_key: str): """ :param api_key: An API authentication token """ sup...
39.366197
120
0.594633
2,651
0.948479
0
0
0
0
0
0
966
0.345617
a133fa0afcdcf42b74dd45b66f95e50ddbf7734f
41
py
Python
actfw_core/v4l2/__init__.py
Idein/actfw-core
44c979bbe5d32d068eed20b7d565a6de2fb9acd3
[ "MIT" ]
2
2021-03-15T11:44:37.000Z
2021-05-12T09:58:35.000Z
actfw_core/v4l2/__init__.py
Idein/actfw-core
44c979bbe5d32d068eed20b7d565a6de2fb9acd3
[ "MIT" ]
28
2020-12-24T02:53:37.000Z
2022-03-14T09:02:28.000Z
actfw_core/v4l2/__init__.py
Idein/actfw-core
44c979bbe5d32d068eed20b7d565a6de2fb9acd3
[ "MIT" ]
null
null
null
from . import types, video # noqa: F401
20.5
40
0.682927
0
0
0
0
0
0
0
0
12
0.292683
a13428de836fe2ca966877503cf126c867ad3cd6
531
py
Python
xos/synchronizers/openstack/model_policies/model_policy_Sliver.py
xmaruto/mcord
3678a3d10c3703c2b73f396c293faebf0c82a4f4
[ "Apache-2.0" ]
null
null
null
xos/synchronizers/openstack/model_policies/model_policy_Sliver.py
xmaruto/mcord
3678a3d10c3703c2b73f396c293faebf0c82a4f4
[ "Apache-2.0" ]
null
null
null
xos/synchronizers/openstack/model_policies/model_policy_Sliver.py
xmaruto/mcord
3678a3d10c3703c2b73f396c293faebf0c82a4f4
[ "Apache-2.0" ]
null
null
null
def handle(instance): from core.models import Controller, ControllerSlice, ControllerNetwork, NetworkSlice networks = [ns.network for ns in NetworkSlice.objects.filter(slice=instance.slice)] controller_networks = ControllerNetwork.objects.filter(network__in=networks, ...
37.928571
116
0.6742
0
0
0
0
0
0
0
0
4
0.007533
a1357146c1bfe43fcbbabe34684a165daba3ef28
4,987
py
Python
tests/unit/test_s3.py
tejuafonja/SDGym
7c20c588a4c9f5940885467406e73274a5b01a8e
[ "MIT" ]
19
2019-05-23T14:27:02.000Z
2019-12-08T16:04:20.000Z
tests/unit/test_s3.py
tejuafonja/SDGym
7c20c588a4c9f5940885467406e73274a5b01a8e
[ "MIT" ]
11
2019-05-30T21:29:27.000Z
2019-12-10T16:49:28.000Z
tests/unit/test_s3.py
tejuafonja/SDGym
7c20c588a4c9f5940885467406e73274a5b01a8e
[ "MIT" ]
11
2019-05-23T14:27:06.000Z
2020-01-02T14:29:00.000Z
from unittest.mock import Mock, patch import pandas as pd from sdgym.s3 import is_s3_path, parse_s3_path, write_csv, write_file def test_is_s3_path_with_local_dir(): """Test the ``sdgym.s3.is_s3_path`` function with a local directory. If the path is not an s3 path, it should return ``False``. Input: ...
23.195349
72
0.645278
0
0
0
0
2,157
0.432525
0
0
2,861
0.573692
a1360dd0640d6fe332d03889c6a40e96f3ddedfb
3,227
py
Python
vet_care/scripts/generate_from_history.py
neerajvkn/vet_care
14914b22e7a83265d736f9f9dc5186271ae62d66
[ "MIT" ]
2
2020-11-23T11:14:32.000Z
2021-02-03T06:40:33.000Z
vet_care/scripts/generate_from_history.py
neerajvkn/vet_care
14914b22e7a83265d736f9f9dc5186271ae62d66
[ "MIT" ]
null
null
null
vet_care/scripts/generate_from_history.py
neerajvkn/vet_care
14914b22e7a83265d736f9f9dc5186271ae62d66
[ "MIT" ]
7
2019-11-16T14:36:33.000Z
2021-08-25T07:54:51.000Z
import csv import datetime import frappe # bench execute vet_care.scripts.generate_from_history.execute --args "['./data/important_data.csv']" def execute(filename): patient_activities = [] not_created = [] with open(filename, 'r') as csvfile: reader = csv.DictReader(csvfile) for row in re...
37.964706
119
0.634645
0
0
0
0
0
0
0
0
543
0.168268
a1362909e583305f43ba83685760d08284ce8f25
594
py
Python
aws_interface/cloud/auth/delete_sessions.py
hubaimaster/aws-interface
162dd056546d58b6eb29afcae1c3c2d78e4309b2
[ "Apache-2.0" ]
53
2018-10-02T05:58:54.000Z
2020-09-15T08:58:26.000Z
aws_interface/cloud/auth/delete_sessions.py
hubaimaster/aws-interface
162dd056546d58b6eb29afcae1c3c2d78e4309b2
[ "Apache-2.0" ]
52
2018-09-26T05:16:09.000Z
2022-03-11T23:51:14.000Z
aws_interface/cloud/auth/delete_sessions.py
hubaimaster/aws-interface
162dd056546d58b6eb29afcae1c3c2d78e4309b2
[ "Apache-2.0" ]
10
2019-03-11T16:35:14.000Z
2019-10-23T08:03:54.000Z
from cloud.permission import Permission, NeedPermission # Define the input output format of the function. # This information is used when creating the *SDK*. info = { 'input_format': { 'session_ids': ['str'], }, 'output_format': { 'success': 'bool' }, 'description': 'Delete session...
22.846154
56
0.6633
0
0
0
0
266
0.447811
0
0
222
0.373737
a137958aa6262c5d4af45fea5f852cfe4e0fb7c7
5,509
py
Python
plugin/autoWHUT.py
PPeanutButter/MediaServer
a6a0b3f424ca3fc4ea73d78db380ec3cc882bfd2
[ "MIT" ]
2
2021-09-23T15:09:25.000Z
2022-01-16T01:04:07.000Z
plugin/autoWHUT.py
PPeanutButter/MediaServer
a6a0b3f424ca3fc4ea73d78db380ec3cc882bfd2
[ "MIT" ]
1
2022-02-23T04:00:16.000Z
2022-02-23T04:10:06.000Z
plugin/autoWHUT.py
PPeanutButter/MediaServer
a6a0b3f424ca3fc4ea73d78db380ec3cc882bfd2
[ "MIT" ]
1
2021-09-23T15:09:26.000Z
2021-09-23T15:09:26.000Z
# coding=<utf-8> import requests import re import socket import base64 import psutil import pywifi from pywifi import const import subprocess import os import time def get_host_ip(): try: s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) s.connect(('8.8.8.8', 80)) ip = s.getsockname()[0...
34.43125
117
0.554547
4,252
0.771828
0
0
0
0
0
0
1,703
0.309131
a137f706cc16a7ddd946b13b277853a20e68de35
3,096
py
Python
active_subspaces/gradients.py
ftalbrecht/active_subspaces
64817a19db250e4b01bcd51055ad0f7d2a5665b8
[ "MIT" ]
51
2015-04-24T13:52:00.000Z
2022-02-16T13:30:39.000Z
active_subspaces/gradients.py
JIMMY-KSU/active_subspaces
64817a19db250e4b01bcd51055ad0f7d2a5665b8
[ "MIT" ]
10
2015-02-03T01:00:09.000Z
2022-03-06T07:48:46.000Z
active_subspaces/gradients.py
JIMMY-KSU/active_subspaces
64817a19db250e4b01bcd51055ad0f7d2a5665b8
[ "MIT" ]
44
2015-01-12T06:05:59.000Z
2022-02-02T18:53:34.000Z
"""Utilities for approximating gradients.""" import numpy as np from utils.misc import process_inputs from utils.simrunners import SimulationRunner def local_linear_gradients(X, f, p=None, weights=None): """Estimate a collection of gradients from input/output pairs. Given a set of input/output pairs, choo...
31.591837
80
0.609173
0
0
0
0
0
0
0
0
1,737
0.561047
a1385e4aefd67a6e8363bc3fce53670aa1ea871f
6,861
py
Python
covidaid/tools/read_data.py
sabuj7177/CovidProject
b4b7bcfa5ace165520507f489dc74da7b695e2f0
[ "Apache-2.0" ]
null
null
null
covidaid/tools/read_data.py
sabuj7177/CovidProject
b4b7bcfa5ace165520507f489dc74da7b695e2f0
[ "Apache-2.0" ]
null
null
null
covidaid/tools/read_data.py
sabuj7177/CovidProject
b4b7bcfa5ace165520507f489dc74da7b695e2f0
[ "Apache-2.0" ]
null
null
null
# encoding: utf-8 """ Read images and corresponding labels. """ import torch from torch.utils.data import Dataset from PIL import Image import os import random class ChestXrayDataSetTest(Dataset): def __init__(self, image_list_file, transform=None, combine_pneumonia=False): """ Create the Data Lo...
36.887097
153
0.594957
6,694
0.97566
0
0
0
0
0
0
1,737
0.25317
a13861d4cfee522305c9e242f88c3b1859a889ba
7,996
py
Python
helper/evaluator.py
manipopopo/TC-ResNet
7dff6f4f865f1e63ff705d8e0267cf3b9a0d70a3
[ "Apache-2.0" ]
185
2019-04-06T12:54:25.000Z
2022-03-24T12:06:59.000Z
helper/evaluator.py
manipopopo/TC-ResNet
7dff6f4f865f1e63ff705d8e0267cf3b9a0d70a3
[ "Apache-2.0" ]
23
2019-05-15T09:19:01.000Z
2022-02-10T00:07:03.000Z
helper/evaluator.py
manipopopo/TC-ResNet
7dff6f4f865f1e63ff705d8e0267cf3b9a0d70a3
[ "Apache-2.0" ]
61
2019-04-06T12:33:46.000Z
2022-03-01T06:41:53.000Z
import csv import sys from pathlib import Path from abc import abstractmethod import numpy as np import tensorflow as tf from tqdm import tqdm import common.tf_utils as tf_utils import metrics.manager as metric_manager from common.model_loader import Ckpt from common.utils import format_text from common.utils import ...
37.539906
119
0.674212
7,541
0.943097
0
0
1,368
0.171086
0
0
786
0.098299
a139c61e93bd3d976aaa5d706da3d269f7d52385
7,483
py
Python
src/sync.py
neybar/icloud-drive-docker
c7e59400c01b304c0f8ed7fd0b3ea2a623623b2e
[ "BSD-3-Clause" ]
null
null
null
src/sync.py
neybar/icloud-drive-docker
c7e59400c01b304c0f8ed7fd0b3ea2a623623b2e
[ "BSD-3-Clause" ]
null
null
null
src/sync.py
neybar/icloud-drive-docker
c7e59400c01b304c0f8ed7fd0b3ea2a623623b2e
[ "BSD-3-Clause" ]
null
null
null
__author__ = 'Mandar Patil ([email protected])' import datetime import os import re import time from pathlib import Path from shutil import copyfileobj, rmtree from pyicloud import PyiCloudService, utils, exceptions from src import config_parser from src import notify def wanted_file(filters, file_path, verbose=Fals...
42.276836
117
0.647735
0
0
0
0
0
0
0
0
621
0.082988
a13a98235b9b2f72025d1bf03dbd61547e3c8d9f
2,163
py
Python
sphinx-sources/Examples/Interference/MultiSlit.py
jccmak/lightpipes
1a296fe08bdd97fc9a0e11f92bab25c85f68e57d
[ "BSD-3-Clause" ]
null
null
null
sphinx-sources/Examples/Interference/MultiSlit.py
jccmak/lightpipes
1a296fe08bdd97fc9a0e11f92bab25c85f68e57d
[ "BSD-3-Clause" ]
null
null
null
sphinx-sources/Examples/Interference/MultiSlit.py
jccmak/lightpipes
1a296fe08bdd97fc9a0e11f92bab25c85f68e57d
[ "BSD-3-Clause" ]
null
null
null
#! python3 import numpy as np import matplotlib.pyplot as plt from LightPipes import * """ MultiSlit.py Demonstrates the RowOfFields command. Two wavelengths are used to show the principles of a grating. cc Fred van Goor, June 2020. """ wavelength=1000*nm Dlambda=150*nm size=11*mm N=2000 N2=int(N/...
31.808824
155
0.680536
0
0
0
0
0
0
0
0
793
0.36662
a13baec342fa639fe6142ecd977281a346771177
389
py
Python
genshimacro/__init__.py
trac-hacks/trac-GenshiMacro
d9da1a50f6d73904fdda2e9e7cbc4c056b929267
[ "BSD-3-Clause" ]
1
2015-02-19T21:08:53.000Z
2015-02-19T21:08:53.000Z
genshimacro/__init__.py
ejucovy/trac-GenshiMacro
d9da1a50f6d73904fdda2e9e7cbc4c056b929267
[ "BSD-3-Clause" ]
null
null
null
genshimacro/__init__.py
ejucovy/trac-GenshiMacro
d9da1a50f6d73904fdda2e9e7cbc4c056b929267
[ "BSD-3-Clause" ]
null
null
null
from genshi.template import MarkupTemplate from trac.core import * from trac.web.chrome import Chrome from trac.wiki.macros import WikiMacroBase class GenshiMacro(WikiMacroBase): def expand_macro(self, formatter, name, text, args): template = MarkupTemplate(text) chrome = Chrome(self.env) ...
29.923077
75
0.742931
241
0.619537
0
0
0
0
0
0
0
0
a13d6b6264ad2abf3168edf6c36418b077a9e067
2,110
py
Python
scripts/WIPS2015/WIPS_anydiag_time.py
eclee25/flu-SDI-exploratory-age
2f5a4d97b84d2116e179e85fe334edf4556aa946
[ "MIT" ]
3
2018-03-29T23:02:43.000Z
2020-08-10T12:01:50.000Z
scripts/WIPS2015/WIPS_anydiag_time.py
eclee25/flu-SDI-exploratory-age
2f5a4d97b84d2116e179e85fe334edf4556aa946
[ "MIT" ]
null
null
null
scripts/WIPS2015/WIPS_anydiag_time.py
eclee25/flu-SDI-exploratory-age
2f5a4d97b84d2116e179e85fe334edf4556aa946
[ "MIT" ]
null
null
null
#!/usr/bin/python ############################################## ###Python template ###Author: Elizabeth Lee ###Date: 10/11/14 ###Function: Any diagnosis per 100,000 population vs. week number for flu weeks (wks 40-20). Population size is from the calendar year of the week of calculation. ###Import data: SQL_export/a...
32.461538
186
0.691469
0
0
0
0
0
0
0
0
1,223
0.579621
a13d78de55aa35e5195b6d00dd9af4b319aa1688
5,290
py
Python
misc/src/scheduler_plugin.py
hivesolutions/colony_plugins
cfd8fb2ac58037e01002966704b8a642feb37895
[ "Apache-1.1" ]
1
2016-10-30T09:51:06.000Z
2016-10-30T09:51:06.000Z
misc/src/scheduler_plugin.py
hivesolutions/colony_plugins
cfd8fb2ac58037e01002966704b8a642feb37895
[ "Apache-1.1" ]
1
2015-12-29T18:51:07.000Z
2015-12-29T18:51:07.000Z
misc/src/scheduler_plugin.py
hivesolutions/colony_plugins
cfd8fb2ac58037e01002966704b8a642feb37895
[ "Apache-1.1" ]
1
2018-01-26T12:54:13.000Z
2018-01-26T12:54:13.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- # Hive Colony Framework # Copyright (c) 2008-2020 Hive Solutions Lda. # # This file is part of Hive Colony Framework. # # Hive Colony Framework is free software: you can redistribute it and/or modify # it under the terms of the Apache License as published by the Apach...
35.986395
112
0.709074
3,969
0.75
0
0
784
0.148148
0
0
1,713
0.323696
a13e0be2220cebb57badaee86dd77ccad221768a
3,458
py
Python
source/vistas/ui/controls/gl_camera.py
VISTAS-IVES/pyvistas
2de1541c0fb40ccbac4014af758ff329ba0677b1
[ "BSD-3-Clause" ]
1
2017-08-26T20:18:38.000Z
2017-08-26T20:18:38.000Z
source/vistas/ui/controls/gl_camera.py
VISTAS-IVES/pyvistas
2de1541c0fb40ccbac4014af758ff329ba0677b1
[ "BSD-3-Clause" ]
89
2017-06-10T21:03:16.000Z
2022-03-11T23:19:56.000Z
source/vistas/ui/controls/gl_camera.py
VISTAS-IVES/pyvistas
2de1541c0fb40ccbac4014af758ff329ba0677b1
[ "BSD-3-Clause" ]
1
2019-03-05T21:44:29.000Z
2019-03-05T21:44:29.000Z
import os import wx from vistas.core.graphics.camera_interactor import * from vistas.core.graphics.overlay import BasicOverlayButton from vistas.core.paths import get_resources_directory from vistas.ui.events import CameraChangedEvent from vistas.ui.utils import get_main_window class GLCameraControls(wx.EvtHandler)...
34.237624
114
0.669751
3,174
0.917872
0
0
0
0
0
0
260
0.075188
a13f0a11b4555fcfbf9c924b7e7de9f674331ec4
8,678
py
Python
src/_sever_qt4.py
Joy917/fast-transfer
dfbcf5c4239da3d550b721500dff05fb6d40b756
[ "MIT" ]
null
null
null
src/_sever_qt4.py
Joy917/fast-transfer
dfbcf5c4239da3d550b721500dff05fb6d40b756
[ "MIT" ]
null
null
null
src/_sever_qt4.py
Joy917/fast-transfer
dfbcf5c4239da3d550b721500dff05fb6d40b756
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'D:\SVNzhangy\fast-transfer\src\_sever.ui' # # Created by: PyQt4 UI code generator 4.11.4 # # WARNING! All changes made in this file will be lost! from PySide import QtCore, QtGui try: _fromUtf8 = QtCore.QString.fromUtf8 except Attribut...
58.635135
110
0.735999
7,999
0.921119
0
0
0
0
0
0
857
0.098687
a1423e6a2572b095e511d07a5f47171e04381471
4,579
py
Python
aleph/tests/test_documents_api.py
gazeti/aleph
f6714c4be038471cfdc6408bfe88dc9e2ed28452
[ "MIT" ]
1
2017-07-28T12:54:09.000Z
2017-07-28T12:54:09.000Z
aleph/tests/test_documents_api.py
gazeti/aleph
f6714c4be038471cfdc6408bfe88dc9e2ed28452
[ "MIT" ]
7
2017-08-16T12:49:23.000Z
2018-02-16T10:22:11.000Z
aleph/tests/test_documents_api.py
gazeti/aleph
f6714c4be038471cfdc6408bfe88dc9e2ed28452
[ "MIT" ]
6
2017-07-26T12:29:53.000Z
2017-08-18T09:35:50.000Z
import json from aleph.tests.util import TestCase class DocumentsApiTestCase(TestCase): def setUp(self): super(DocumentsApiTestCase, self).setUp() self.load_fixtures('docs.yaml') def test_index(self): res = self.client.get('/api/1/documents') assert res.status_code == 200, r...
37.227642
74
0.592487
4,525
0.988207
0
0
0
0
0
0
932
0.203538
a143abc8dbbd62332b147ee1258deecef9896d32
649
py
Python
acropolis.py
andreasa13/Flask_WebApp_TripAdvisor
ea77291280676128b224da02c4938a42bbbb5200
[ "MIT" ]
null
null
null
acropolis.py
andreasa13/Flask_WebApp_TripAdvisor
ea77291280676128b224da02c4938a42bbbb5200
[ "MIT" ]
1
2021-12-13T20:52:54.000Z
2021-12-13T20:52:54.000Z
acropolis.py
andreasagap/Flask_WebApp_TripAdvisor
06fd682248ea12ee440834719c113ec974635dd0
[ "MIT" ]
1
2021-06-09T18:29:33.000Z
2021-06-09T18:29:33.000Z
import json import pandas as pd from geopy.geocoders import Nominatim def getAcropolisStatistics(): data = pd.read_csv("Analytics/demographics_old.csv") ratings_acropolis = len(data) gender = data.gender.str.lower().value_counts() ages = data.age_group.value_counts() return ratings_acropolis, ge...
28.217391
82
0.70416
0
0
0
0
0
0
0
0
150
0.231125
a146f1a5836a0723e015b88316d930723a68dc51
1,464
py
Python
share/pegasus/init/split/daxgen.py
fengggli/pegasus
b68f588d90eb2b832086ed627d61414691f8ba95
[ "Apache-2.0" ]
null
null
null
share/pegasus/init/split/daxgen.py
fengggli/pegasus
b68f588d90eb2b832086ed627d61414691f8ba95
[ "Apache-2.0" ]
null
null
null
share/pegasus/init/split/daxgen.py
fengggli/pegasus
b68f588d90eb2b832086ed627d61414691f8ba95
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import os import pwd import sys import time from Pegasus.DAX3 import * # The name of the DAX file is the first argument if len(sys.argv) != 2: sys.stderr.write("Usage: %s DAXFILE\n" % (sys.argv[0])) sys.exit(1) daxfile = sys.argv[1] USER = pwd.getpwuid(os.getuid())[0] # Create ...
25.684211
70
0.672814
0
0
0
0
0
0
0
0
556
0.379781
a147e22d5aeaabe35ccc4c56ea5539f536e24407
3,685
py
Python
lbrynet/wallet/ledger.py
ttkopec/lbry
03415415ed397730e6f691f527f51b429a834ed5
[ "MIT" ]
null
null
null
lbrynet/wallet/ledger.py
ttkopec/lbry
03415415ed397730e6f691f527f51b429a834ed5
[ "MIT" ]
110
2018-11-26T05:41:35.000Z
2021-08-03T15:37:20.000Z
lbrynet/wallet/ledger.py
ttkopec/lbry
03415415ed397730e6f691f527f51b429a834ed5
[ "MIT" ]
1
2018-09-20T22:15:59.000Z
2018-09-20T22:15:59.000Z
import logging from six import int2byte from binascii import unhexlify from twisted.internet import defer from .resolve import Resolver from lbryschema.error import URIParseError from lbryschema.uri import parse_lbry_uri from torba.baseledger import BaseLedger from .account import Account from .network import Netwo...
34.12037
101
0.735414
3,195
0.867028
1,074
0.291452
1,404
0.381004
0
0
287
0.077883
a14898fc9eb718d11bd7d8fbc8f0101300add0a6
297
py
Python
MATA37-ILP 2021.2/JUDE/Lista 3 e Prova 3 - Loop/lista3_D.py
jeffersonraimon/Programming-UFBA
6a6803bfd0e6aa72f8c2b9ffa120792d73c727ca
[ "MIT" ]
1
2021-12-09T12:55:56.000Z
2021-12-09T12:55:56.000Z
MATA37-ILP 2021.2/JUDE/Lista 3 e Prova 3 - Loop/lista3_D.py
jeffersonraimon/Programming-UFBA
6a6803bfd0e6aa72f8c2b9ffa120792d73c727ca
[ "MIT" ]
null
null
null
MATA37-ILP 2021.2/JUDE/Lista 3 e Prova 3 - Loop/lista3_D.py
jeffersonraimon/Programming-UFBA
6a6803bfd0e6aa72f8c2b9ffa120792d73c727ca
[ "MIT" ]
1
2022-02-21T12:01:53.000Z
2022-02-21T12:01:53.000Z
T = int(input()) P = int(input()) controle = 0 #Uso para guardar o valor maior que o limite while P != 0: P = int(input()) if P >= T: controle = 1 #coloquei 1 so pra ser diferente de 0 if controle == 1: print("ALARME") else: print("O Havai pode dormir tranquilo")
14.142857
58
0.592593
0
0
0
0
0
0
0
0
120
0.40404
a1489d0338a6be1fe32c5e1421435901d7f812f7
1,387
py
Python
dopamine/fetch_cam_train/fetch_cam/test/fetch_dis_error.py
kbehouse/dopamine
1922481d9c23d6c3cf3ee3ec06e613c6eb87cbc1
[ "Apache-2.0" ]
null
null
null
dopamine/fetch_cam_train/fetch_cam/test/fetch_dis_error.py
kbehouse/dopamine
1922481d9c23d6c3cf3ee3ec06e613c6eb87cbc1
[ "Apache-2.0" ]
null
null
null
dopamine/fetch_cam_train/fetch_cam/test/fetch_dis_error.py
kbehouse/dopamine
1922481d9c23d6c3cf3ee3ec06e613c6eb87cbc1
[ "Apache-2.0" ]
null
null
null
import numpy as np import gym import time from matplotlib import pyplot as plt from fetch_cam import FetchCameraEnv from fsm import FSM dis_tolerance = 0.0001 # 1mm env = FetchCameraEnv() obs = env.reset() done = False want_pos = (obs['eeinfo'][0]).copy() ori_pos = (obs['eeinfo'][0]).copy() print('---ori_pos ...
24.333333
85
0.539293
0
0
0
0
0
0
0
0
314
0.226388
a1490edf966fa802ac0a01963e5d3d0e3138778b
5,091
py
Python
pyHarvest_build_151223/pyHarvest_Analyse_Data_v1.py
bl305/pyHarvest
d4c62d443ca657f9d31245c3c3f24c741cf2ae0b
[ "CC0-1.0" ]
null
null
null
pyHarvest_build_151223/pyHarvest_Analyse_Data_v1.py
bl305/pyHarvest
d4c62d443ca657f9d31245c3c3f24c741cf2ae0b
[ "CC0-1.0" ]
null
null
null
pyHarvest_build_151223/pyHarvest_Analyse_Data_v1.py
bl305/pyHarvest
d4c62d443ca657f9d31245c3c3f24c741cf2ae0b
[ "CC0-1.0" ]
null
null
null
# coding=utf-8 from packages import * import os #SET PARAMETERS myverbosity=-1 mymaxencode=5 TXT_filetypes=( #simple text files 'txt','lst', #config files 'ini','cfg', #programming languages 'c','cpp', #scripts 'vbs','py','pl') XLS_filetypes=('xls','xlsx') DOC_filetypes=('doc',) DOCX_filetypes=('docx',) PDF_filetype...
36.891304
144
0.792772
0
0
0
0
0
0
0
0
2,651
0.520723
a1499e6c4207a38f095d2e507e2c6116418ae733
2,732
py
Python
functions/update_modeling_results.py
zheng-da/covid19-severity-prediction
205ab5aa13a5e91a4c23ccd73e65939e4003626b
[ "MIT" ]
2
2020-05-15T14:42:02.000Z
2020-05-22T08:51:47.000Z
functions/update_modeling_results.py
rahul263-stack/covid19-severity-prediction
f581adb2fccb12d5ab3f3c59ee120f484703edf5
[ "MIT" ]
null
null
null
functions/update_modeling_results.py
rahul263-stack/covid19-severity-prediction
f581adb2fccb12d5ab3f3c59ee120f484703edf5
[ "MIT" ]
null
null
null
import numpy as np import pandas as pd from os.path import join as oj import os import pygsheets import pandas as pd import sys import inspect from datetime import datetime, timedelta currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))) parentdir = os.path.dirname(currentdir) sys.path...
35.947368
100
0.625915
0
0
0
0
0
0
0
0
439
0.160688
a14c5c58cf2881b62cfe95e034f42cf5c934399c
4,582
py
Python
zun/tests/unit/common/test_rpc.py
wanghuiict/zun
2f4a3a2ba06d7ca83002418d4003ee5dece70952
[ "Apache-2.0" ]
83
2016-09-14T22:06:26.000Z
2022-01-27T03:49:52.000Z
zun/tests/unit/common/test_rpc.py
wanghuiict/zun
2f4a3a2ba06d7ca83002418d4003ee5dece70952
[ "Apache-2.0" ]
2
2017-06-22T21:58:47.000Z
2019-04-10T03:17:44.000Z
zun/tests/unit/common/test_rpc.py
wanghuiict/zun
2f4a3a2ba06d7ca83002418d4003ee5dece70952
[ "Apache-2.0" ]
54
2016-09-29T10:16:02.000Z
2022-01-28T19:12:49.000Z
# Copyright 2017 OpenStack Foundation # 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 requ...
34.19403
78
0.654518
3,775
0.823876
0
0
1,402
0.30598
0
0
1,172
0.255784
a14da1829b09a4bac353d3762281e3ef271e99d4
26,935
py
Python
skidl/Pin.py
arjenroodselaar/skidl
0bf801bd3b74e6ef94bd9aa1b68eef756b568276
[ "MIT" ]
null
null
null
skidl/Pin.py
arjenroodselaar/skidl
0bf801bd3b74e6ef94bd9aa1b68eef756b568276
[ "MIT" ]
null
null
null
skidl/Pin.py
arjenroodselaar/skidl
0bf801bd3b74e6ef94bd9aa1b68eef756b568276
[ "MIT" ]
1
2020-09-21T23:31:41.000Z
2020-09-21T23:31:41.000Z
# -*- coding: utf-8 -*- # MIT license # # Copyright (C) 2018 by XESS Corp. # # 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...
34.57638
87
0.569742
21,292
0.790496
0
0
1,338
0.049675
0
0
11,516
0.427548
a14dc76d87023f8e5ab3f4a7babd9708c41bf004
34,030
py
Python
Project1/cl1_p1_wsd.py
Sanghyun-Hong/NLPProjects
9f81fa680946648f64ac25e5ca8197e9f3386deb
[ "MIT" ]
null
null
null
Project1/cl1_p1_wsd.py
Sanghyun-Hong/NLPProjects
9f81fa680946648f64ac25e5ca8197e9f3386deb
[ "MIT" ]
null
null
null
Project1/cl1_p1_wsd.py
Sanghyun-Hong/NLPProjects
9f81fa680946648f64ac25e5ca8197e9f3386deb
[ "MIT" ]
null
null
null
import numpy as np import operator # SHHONG: custom modules imported import json import random import itertools from math import pow, log from collections import Counter import os import sys sys.stdout = open(os.devnull, 'w') """ CMSC723 / INST725 / LING723 -- Fall 2016 Project 1: Implementing Word Sense Disambiguati...
43.075949
211
0.614634
0
0
0
0
0
0
0
0
10,731
0.315339
a14fb8c57a2911a94e991dd47b577ec949e53771
640
py
Python
Week 7 Web pages/Task05.py
retverd/python_hse
cb9bfb092c1cf68ae0c53b9919ca24a71a8cbf88
[ "MIT" ]
null
null
null
Week 7 Web pages/Task05.py
retverd/python_hse
cb9bfb092c1cf68ae0c53b9919ca24a71a8cbf88
[ "MIT" ]
null
null
null
Week 7 Web pages/Task05.py
retverd/python_hse
cb9bfb092c1cf68ae0c53b9919ca24a71a8cbf88
[ "MIT" ]
null
null
null
# Мы сохранили страницу с википедии про языки программирования и сохранили по адресу # https://stepik.org/media/attachments/lesson/209717/1.html # # Скачайте её с помощью скрипта на Питоне и посчитайте, какой язык упоминается чаще Python или C++ (ответ должен быть # одной из этих двух строк). Необходимо просто подсчита...
30.47619
117
0.739063
0
0
0
0
0
0
0
0
709
0.803855
a150c0cbc599ebc411b4f81c6fa3b0405cf1395b
31,794
py
Python
tests/test_bio/test_cell.py
jfaccioni/clovars
64e24286a2dc185490384aeb08027d88eb9462c4
[ "MIT" ]
null
null
null
tests/test_bio/test_cell.py
jfaccioni/clovars
64e24286a2dc185490384aeb08027d88eb9462c4
[ "MIT" ]
null
null
null
tests/test_bio/test_cell.py
jfaccioni/clovars
64e24286a2dc185490384aeb08027d88eb9462c4
[ "MIT" ]
null
null
null
import unittest from unittest import mock from unittest.mock import MagicMock from clovars.abstract import Circle from clovars.bio import Cell, Treatment from clovars.scientific import ConstantCellSignal, CellSignal, GaussianCellSignal, Gaussian from clovars.utils import SimulationError from tests import NotEmptyTestC...
53.345638
120
0.686482
31,418
0.988174
0
0
2,151
0.067654
0
0
10,440
0.328364
a151ad0affbfcc7813c745ba76d87908fc3a227a
2,959
py
Python
nutsml/examples/pytorch_/mnist/mlp_train.py
maet3608/nuts-ml
2551612a47bc6e9efa534eda0db5d8c5def51887
[ "Apache-2.0" ]
39
2017-02-07T03:22:41.000Z
2021-11-24T20:27:57.000Z
nutsml/examples/pytorch_/mnist/mlp_train.py
maet3608/nuts-ml
2551612a47bc6e9efa534eda0db5d8c5def51887
[ "Apache-2.0" ]
19
2017-02-13T22:22:30.000Z
2019-01-31T04:13:39.000Z
nutsml/examples/pytorch_/mnist/mlp_train.py
maet3608/nuts-ml
2551612a47bc6e9efa534eda0db5d8c5def51887
[ "Apache-2.0" ]
13
2017-06-01T13:44:54.000Z
2020-09-08T04:51:36.000Z
""" .. module:: cnn_train :synopsis: Example nuts-ml pipeline for training a MLP on MNIST """ import torch import torch.nn.functional as F import torch.nn as nn import torch.optim as optim import nutsflow as nf import nutsml as nm import numpy as np from nutsml.network import PytorchNetwork from utils import downl...
31.147368
76
0.613045
859
0.290301
0
0
0
0
0
0
739
0.249747
a152a29b6edc8d593cb4451e6903d733b234650c
2,317
py
Python
get_image.py
DanielJamesEvans/spectrophotometer_code
10957590a4b49fe91ec6a0111ef83da63cc4ee67
[ "MIT" ]
3
2019-08-31T16:43:10.000Z
2019-10-07T20:35:13.000Z
get_image.py
DanielJamesEvans/spectrophotometer_code
10957590a4b49fe91ec6a0111ef83da63cc4ee67
[ "MIT" ]
null
null
null
get_image.py
DanielJamesEvans/spectrophotometer_code
10957590a4b49fe91ec6a0111ef83da63cc4ee67
[ "MIT" ]
1
2019-08-31T19:10:40.000Z
2019-08-31T19:10:40.000Z
"""This code contains functions called by gui.py. This software is licensed under the MIT license. """ import time from picamera.array import PiRGBArray from picamera import PiCamera from gpiozero import LED import numpy as np from PIL import Image __author__ = "Daniel James Evans" __copyright__ = "Copyright 2019...
25.461538
79
0.662063
0
0
0
0
0
0
0
0
857
0.369875
a1536df44cebf44b8ca6b21340ed07ba5ea74a42
15,346
py
Python
rave_ec/Lib/ec_mcgill.py
DanielMichelson/drqc_article
cd7df2f7290adedb557bbc6ba484d30039a23ce2
[ "CC-BY-4.0" ]
null
null
null
rave_ec/Lib/ec_mcgill.py
DanielMichelson/drqc_article
cd7df2f7290adedb557bbc6ba484d30039a23ce2
[ "CC-BY-4.0" ]
null
null
null
rave_ec/Lib/ec_mcgill.py
DanielMichelson/drqc_article
cd7df2f7290adedb557bbc6ba484d30039a23ce2
[ "CC-BY-4.0" ]
null
null
null
''' Copyright (C) 2016 The Crown (i.e. Her Majesty the Queen in Right of Canada) This file is an add-on to RAVE. RAVE is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (a...
37.891358
84
0.6373
58
0.003779
0
0
0
0
0
0
4,821
0.314154
a1537d70484481dc31d44d35ec4975bba8b264f5
1,038
py
Python
product/migrations/0001_initial.py
dnetochaves/e-commerce
97c2266934b6db883d520381520130b0472e9db4
[ "MIT" ]
null
null
null
product/migrations/0001_initial.py
dnetochaves/e-commerce
97c2266934b6db883d520381520130b0472e9db4
[ "MIT" ]
null
null
null
product/migrations/0001_initial.py
dnetochaves/e-commerce
97c2266934b6db883d520381520130b0472e9db4
[ "MIT" ]
null
null
null
# Generated by Django 3.1.4 on 2020-12-27 15:03 from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Product', fields=[ ('id', models.AutoField(...
35.793103
122
0.575145
947
0.910577
0
0
0
0
0
0
229
0.220192
a155e11f0e425a96e53ea2166d51415855a2b463
921
py
Python
src/python/setup.py
Basasuya/tsne-cuda
dc518acd9fdf9109952ffe57d6cf12363e3ffd2c
[ "BSD-3-Clause" ]
2
2021-04-30T16:48:47.000Z
2021-05-21T08:49:13.000Z
src/python/setup.py
Basasuya/tsne-cuda
dc518acd9fdf9109952ffe57d6cf12363e3ffd2c
[ "BSD-3-Clause" ]
null
null
null
src/python/setup.py
Basasuya/tsne-cuda
dc518acd9fdf9109952ffe57d6cf12363e3ffd2c
[ "BSD-3-Clause" ]
1
2021-04-25T23:11:05.000Z
2021-04-25T23:11:05.000Z
from setuptools import setup setup( name='tsnecuda', version='2.1.0', author='Chan, David M., Huang, Forrest., Rao, Roshan.', author_email='[email protected]', packages=['tsnecuda', 'tsnecuda.test'], package_data={'tsnecuda': ['libtsnecuda.so']}, scripts=[], url='https://github.com...
27.909091
68
0.598263
0
0
0
0
0
0
0
0
512
0.555917
a15747184e94e78f55f7ab475ca0b1abe33741e3
107,889
py
Python
programs/parallels.py
ETCBC/parallells
f45f6cc3c4f933dba6e649f49cdb14a40dcf333f
[ "MIT" ]
4
2017-10-01T05:14:59.000Z
2020-09-09T09:41:26.000Z
programs/parallels.py
ETCBC/parallells
f45f6cc3c4f933dba6e649f49cdb14a40dcf333f
[ "MIT" ]
null
null
null
programs/parallels.py
ETCBC/parallells
f45f6cc3c4f933dba6e649f49cdb14a40dcf333f
[ "MIT" ]
1
2020-10-16T13:21:51.000Z
2020-10-16T13:21:51.000Z
#!/usr/bin/env python # coding: utf-8 # <h1>Table of Contents<span class="tocSkip"></span></h1> # <div class="toc" style="margin-top: 1em;"><ul class="toc-item"><li><span><a href="#0.1-Motivation" data-toc-modified-id="0.1-Motivation-1"><span class="toc-item-num">1&nbsp;&nbsp;</span>0.1 Motivation</a></span></li><li><...
30.896048
6,888
0.579503
0
0
0
0
0
0
0
0
51,128
0.473894
a157d32f7b13b416fb6bf59f5d4cfdbbe25ce080
4,870
py
Python
src/python/pants/goal/initialize_reporting.py
WamBamBoozle/pants
98cadfa1a5d337146903eb66548cfe955f2627b3
[ "Apache-2.0" ]
null
null
null
src/python/pants/goal/initialize_reporting.py
WamBamBoozle/pants
98cadfa1a5d337146903eb66548cfe955f2627b3
[ "Apache-2.0" ]
null
null
null
src/python/pants/goal/initialize_reporting.py
WamBamBoozle/pants
98cadfa1a5d337146903eb66548cfe955f2627b3
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # Copyright 2014 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import (absolute_import, division, generators, nested_scopes, print_function, unicode_literals, with_statement) import errno import ...
42.719298
98
0.716222
0
0
0
0
0
0
0
0
1,145
0.235113
a1586b7c08a86b032589e3a797f710af94eef3ed
4,947
py
Python
ResolvePageSwitcher.py
IgorRidanovic/DaVinciResolve-PageSwitcher
5a771d8fa319454dbcf986b8921e5fa0c665baa9
[ "MIT" ]
17
2018-06-01T07:30:33.000Z
2021-12-22T21:05:29.000Z
ResolvePageSwitcher.py
IgorRidanovic/DaVinciResolve-PageSwitcher
5a771d8fa319454dbcf986b8921e5fa0c665baa9
[ "MIT" ]
2
2018-10-23T17:32:45.000Z
2020-12-09T07:48:06.000Z
ResolvePageSwitcher.py
IgorRidanovic/DaVinciResolve-PageSwitcher
5a771d8fa319454dbcf986b8921e5fa0c665baa9
[ "MIT" ]
5
2018-09-06T02:11:56.000Z
2020-10-25T11:25:22.000Z
#! /usr/bin/env python # -*- coding: utf-8 -*- # DaVinci Resolve scripting proof of concept. Resolve page external switcher. # Local or TCP/IP control mode. # Refer to Resolve V15 public beta 2 scripting API documentation for host setup. # Copyright 2018 Igor Riđanović, www.hdhead.com from PyQt4 import QtCore, QtGui ...
36.91791
80
0.761472
3,703
0.748232
0
0
0
0
0
0
1,291
0.260861
a15a0aec2c8adfc46228db42100cded4658cf98f
14,022
py
Python
Make Data Files.py
micitz/Dune_Aspect_Ratio_XB_Paper
25395219886facb3a7e68835e8aae406dbff0b4d
[ "MIT" ]
null
null
null
Make Data Files.py
micitz/Dune_Aspect_Ratio_XB_Paper
25395219886facb3a7e68835e8aae406dbff0b4d
[ "MIT" ]
null
null
null
Make Data Files.py
micitz/Dune_Aspect_Ratio_XB_Paper
25395219886facb3a7e68835e8aae406dbff0b4d
[ "MIT" ]
null
null
null
""" All the data sources are scattered around the D drive, this script organizes it and consolidates it into the "Data" subfolder in the "Chapter 2 Dune Aspect Ratio" folder. Michael Itzkin, 5/6/2020 """ import shutil as sh import pandas as pd import numpy as np import os # Set the data directory to sav...
36.80315
118
0.597276
0
0
0
0
0
0
0
0
6,984
0.498074
a15ae079911483a5e3b82012f76254443eb7a059
339
py
Python
counter-test-applications/lr100000/linear-regr-100k.py
EsperLiu/vPython
f1005f011d6d9fd079cf72e8f78bab6d95a9f993
[ "0BSD" ]
1
2021-11-21T03:31:32.000Z
2021-11-21T03:31:32.000Z
counter-test-applications/lr100000/linear-regr-100k.py
EsperLiu/vPython
f1005f011d6d9fd079cf72e8f78bab6d95a9f993
[ "0BSD" ]
null
null
null
counter-test-applications/lr100000/linear-regr-100k.py
EsperLiu/vPython
f1005f011d6d9fd079cf72e8f78bab6d95a9f993
[ "0BSD" ]
1
2021-11-28T05:57:55.000Z
2021-11-28T05:57:55.000Z
def end_of_import(): return 0 def end_of_init(): return 0 def end_of_computing(): return 0 import numpy as np from sklearn.linear_model import LinearRegression end_of_import() X = np.array(range(0,100000)).reshape(-1, 1) # y = 2x + 3 y = np.dot(X, 2) + 3 end_of_init() reg = LinearRegression().fit(X, y)...
16.95
49
0.696165
0
0
0
0
0
0
0
0
12
0.035398
a15b3e54d6303597b66c9ac9aa7e5fefcc34013d
262
py
Python
python/bitcoin/ch04/04_08.py
gangserver/py_test
869bdfa5c94c3b6a15b87e0c3de6b2cdaca821f4
[ "Apache-2.0" ]
null
null
null
python/bitcoin/ch04/04_08.py
gangserver/py_test
869bdfa5c94c3b6a15b87e0c3de6b2cdaca821f4
[ "Apache-2.0" ]
null
null
null
python/bitcoin/ch04/04_08.py
gangserver/py_test
869bdfa5c94c3b6a15b87e0c3de6b2cdaca821f4
[ "Apache-2.0" ]
null
null
null
import requests url = "https://api.korbit.co.kr/v1/ticker/detailed?currency_pair=btc_krw" r = requests.get(url) bitcoin = r.json() print(bitcoin) print(type(bitcoin)) print(bitcoin['last']) print(bitcoin['bid']) print(bitcoin['ask']) print(bitcoin['volume'])
18.714286
73
0.725191
0
0
0
0
0
0
0
0
91
0.347328
a15b9e2b4f9954059a9f62e3b0c43fda6866814f
3,938
py
Python
jackselect/indicator.py
SpotlightKid/jack-select
acb6cfa5a48846fa7640373d4976d4df1ab0bbd7
[ "MIT" ]
12
2016-03-30T18:32:35.000Z
2022-01-18T21:12:51.000Z
jackselect/indicator.py
SpotlightKid/jack-select
acb6cfa5a48846fa7640373d4976d4df1ab0bbd7
[ "MIT" ]
8
2018-09-03T15:26:51.000Z
2020-04-20T14:44:00.000Z
jackselect/indicator.py
SpotlightKid/jack-select
acb6cfa5a48846fa7640373d4976d4df1ab0bbd7
[ "MIT" ]
null
null
null
"""A convenience class for a GTK 3 system tray indicator.""" from pkg_resources import resource_filename import gi gi.require_version('Gtk', '3.0') # noqa from gi.repository import Gtk from gi.repository.GdkPixbuf import Pixbuf class Indicator: """This class defines a standard GTK3 system tray indicator. ...
32.278689
94
0.61935
3,704
0.940579
0
0
0
0
0
0
1,446
0.367191
a15c583b91868493579d97f1c0cb3471ef7cba0e
442
py
Python
myaxf/migrations/0011_minebtns_is_used.py
Pyrans/test1806
1afc62e09bbebf74521b4b6fdafde8eeaa260ed9
[ "Apache-2.0" ]
null
null
null
myaxf/migrations/0011_minebtns_is_used.py
Pyrans/test1806
1afc62e09bbebf74521b4b6fdafde8eeaa260ed9
[ "Apache-2.0" ]
null
null
null
myaxf/migrations/0011_minebtns_is_used.py
Pyrans/test1806
1afc62e09bbebf74521b4b6fdafde8eeaa260ed9
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11.7 on 2018-11-06 01:54 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('myaxf', '0010_minebtns'), ] operations = [ migrations.AddField( ...
21.047619
52
0.608597
284
0.642534
0
0
0
0
0
0
112
0.253394
a15d304cf1b066b2781b604c9736d8b3d3f4ed26
3,342
py
Python
components/PyTorch/pytorch-kfp-components/setup.py
nostro-im/pipelines
39f5b6b74040abbf4b764cbd5b422d7548723d9e
[ "Apache-2.0" ]
2,860
2018-05-24T04:55:01.000Z
2022-03-31T13:49:56.000Z
components/PyTorch/pytorch-kfp-components/setup.py
nostro-im/pipelines
39f5b6b74040abbf4b764cbd5b422d7548723d9e
[ "Apache-2.0" ]
7,331
2018-05-16T09:03:26.000Z
2022-03-31T23:22:04.000Z
components/PyTorch/pytorch-kfp-components/setup.py
nostro-im/pipelines
39f5b6b74040abbf4b764cbd5b422d7548723d9e
[ "Apache-2.0" ]
1,359
2018-05-15T11:05:41.000Z
2022-03-31T09:42:09.000Z
#!/usr/bin/env/python3 # # Copyright (c) Facebook, Inc. and its affiliates. # 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...
31.528302
107
0.635548
0
0
0
0
0
0
0
0
1,684
0.50389
a15d6cd6a92c370d9583f2a5012f9737df67a02a
10,453
py
Python
generate_pipelines.py
phorne-uncharted/d3m-primitives
77d900b9dd6ab4b2b330f4e969dabcdc419c73e1
[ "MIT" ]
null
null
null
generate_pipelines.py
phorne-uncharted/d3m-primitives
77d900b9dd6ab4b2b330f4e969dabcdc419c73e1
[ "MIT" ]
null
null
null
generate_pipelines.py
phorne-uncharted/d3m-primitives
77d900b9dd6ab4b2b330f4e969dabcdc419c73e1
[ "MIT" ]
null
null
null
""" Utility to get generate all submission pipelines for all primitives. This script assumes that `generate_annotations.py` has already been run. """ import os import subprocess import shutil import fire from kf_d3m_primitives.data_preprocessing.data_cleaning.data_cleaning_pipeline import DataCleaningPipeline from...
50.990244
118
0.672534
0
0
0
0
0
0
0
0
4,322
0.41347
a16015f7fdd109191a18e2ce3c5cc5cd31b338c6
210
py
Python
gorynych/ontologies/gch/edges/basic/__init__.py
vurmux/gorynych
d721e8cdb61f7c7ee6bc4bd31026605df15f2d9d
[ "Apache-2.0" ]
null
null
null
gorynych/ontologies/gch/edges/basic/__init__.py
vurmux/gorynych
d721e8cdb61f7c7ee6bc4bd31026605df15f2d9d
[ "Apache-2.0" ]
null
null
null
gorynych/ontologies/gch/edges/basic/__init__.py
vurmux/gorynych
d721e8cdb61f7c7ee6bc4bd31026605df15f2d9d
[ "Apache-2.0" ]
null
null
null
__all__ = [ "aggregation", "association", "composition", "connection", "containment", "dependency", "includes", "membership", "ownership", "responsibility", "usage" ]
16.153846
21
0.557143
0
0
0
0
0
0
0
0
132
0.628571
a162116929e58d2ceb5db3d4712dce3ef830f40a
3,851
py
Python
square.py
chriswilson1982/black-and-white
e275e6f534aa51f12f4545730b627ce280aae8c3
[ "MIT" ]
null
null
null
square.py
chriswilson1982/black-and-white
e275e6f534aa51f12f4545730b627ce280aae8c3
[ "MIT" ]
null
null
null
square.py
chriswilson1982/black-and-white
e275e6f534aa51f12f4545730b627ce280aae8c3
[ "MIT" ]
2
2020-06-05T04:37:08.000Z
2020-09-30T06:15:22.000Z
# coding: utf-8 """Square module. Represents the squares on the game grid. """ from scene import * from common import * import sound class Square (SpriteNode): """Represents the squares on the game grid. Main properties are their row and column (used for path calculation) and state (corresponds to color in ...
33.780702
243
0.578811
3,714
0.964425
0
0
0
0
0
0
717
0.186185
a1635f7424a1cd00dce9eb1d4e2acface083e3bd
1,128
py
Python
coocurrence_loader.py
miselico/KGlove
2bcbce3d14ed5173a319d80bfff95be6486b41e2
[ "MIT" ]
2
2021-11-05T09:27:57.000Z
2022-02-25T12:33:14.000Z
coocurrence_loader.py
miselico/KGlove
2bcbce3d14ed5173a319d80bfff95be6486b41e2
[ "MIT" ]
null
null
null
coocurrence_loader.py
miselico/KGlove
2bcbce3d14ed5173a319d80bfff95be6486b41e2
[ "MIT" ]
1
2022-02-25T12:37:47.000Z
2022-02-25T12:37:47.000Z
import pathlib from struct import unpack from typing import BinaryIO, List, Optional, Tuple, cast import numpy as np import scipy.sparse def _read_little_endian_crec(file: BinaryIO ) -> Optional[Tuple[int, int, float]]: le_int = file.read(16) # https://docs.python.org/3/library/s...
28.2
77
0.639184
0
0
0
0
0
0
0
0
112
0.099291
a163e601ea9b0587f0a7996da2ea54d7b047cc87
597
py
Python
api_app/migrations/0001_initial.py
DurkinDevelopment/coinbase_api
0cea72234d481d09ff906f7bc064cfe16111c785
[ "MIT" ]
null
null
null
api_app/migrations/0001_initial.py
DurkinDevelopment/coinbase_api
0cea72234d481d09ff906f7bc064cfe16111c785
[ "MIT" ]
null
null
null
api_app/migrations/0001_initial.py
DurkinDevelopment/coinbase_api
0cea72234d481d09ff906f7bc064cfe16111c785
[ "MIT" ]
null
null
null
# Generated by Django 3.2.12 on 2022-02-15 02:57 from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='SpotPrice', fields=[ ('id', models.BigAuto...
24.875
117
0.562814
503
0.842546
0
0
0
0
0
0
96
0.160804
a163f9dace925925161f417c4fc2f6f13d99f9d2
924
py
Python
Kalender/views.py
RamonvdW/nhb-apps
5a9f840bfe066cd964174515c06b806a7b170c69
[ "BSD-3-Clause-Clear" ]
1
2021-12-22T13:11:12.000Z
2021-12-22T13:11:12.000Z
Kalender/views.py
RamonvdW/nhb-apps
5a9f840bfe066cd964174515c06b806a7b170c69
[ "BSD-3-Clause-Clear" ]
9
2020-10-28T07:07:05.000Z
2021-06-28T20:05:37.000Z
Kalender/views.py
RamonvdW/nhb-apps
5a9f840bfe066cd964174515c06b806a7b170c69
[ "BSD-3-Clause-Clear" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2021 Ramon van der Winkel. # All rights reserved. # Licensed under BSD-3-Clause-Clear. See LICENSE file for details. from django.views.generic import View from django.urls import reverse from django.http import HttpResponseRedirect from Functie.rol import Rollen, rol_get_hui...
26.4
79
0.683983
534
0.577922
0
0
365
0.395022
0
0
331
0.358225
a166142b9f7a87deb268c549d8183c79b3298038
9,511
py
Python
profile.py
giswqs/Depression-filling-1D
3c0ed86bbbe6f0b8573212a3efd59375dc7be45e
[ "MIT" ]
1
2022-02-27T14:40:00.000Z
2022-02-27T14:40:00.000Z
profile.py
giswqs/Depression-filling-1D
3c0ed86bbbe6f0b8573212a3efd59375dc7be45e
[ "MIT" ]
null
null
null
profile.py
giswqs/Depression-filling-1D
3c0ed86bbbe6f0b8573212a3efd59375dc7be45e
[ "MIT" ]
null
null
null
import os import numpy as np # class for depression class Depression: def __init__(self, id, width, depth, area, pour_elev, min_elev, points, internal_pts): self.id = id self.width = width self.depth = depth self.area = area self.pour_elev = pour_elev self.min_elev ...
33.255245
133
0.588161
346
0.036379
0
0
0
0
0
0
1,535
0.161392
a166258a27d4639c261790d1e5d9c74ab19c0e5f
4,544
py
Python
data/make_joint_comp_inc_data.py
gcunhase/StackedDeBERT
82777114fd99cafc6e2a3d760e774f007c563245
[ "MIT" ]
32
2020-01-03T09:53:03.000Z
2021-09-07T07:23:26.000Z
data/make_joint_comp_inc_data.py
gcunhase/StackedDeBERT
82777114fd99cafc6e2a3d760e774f007c563245
[ "MIT" ]
null
null
null
data/make_joint_comp_inc_data.py
gcunhase/StackedDeBERT
82777114fd99cafc6e2a3d760e774f007c563245
[ "MIT" ]
6
2020-01-21T06:50:21.000Z
2021-01-22T08:04:00.000Z
import argparse import os import csv import random from utils import ensure_dir, get_project_path from collections import defaultdict # POS-tag for irrelevant tag selection import nltk nltk.download('punkt') nltk.download('averaged_perceptron_tagger') __author__ = "Gwena Cunha" def write_tsv(intention_dir_path, fi...
42.867925
125
0.645026
0
0
0
0
0
0
0
0
1,279
0.28147
a16669ec079300a0633ffd694b38772760885089
4,989
py
Python
recipes/models.py
JakubKoralewski/django-recipes
3794c6a96fb0765e2e3cebfc3968dae88e4f084c
[ "MIT" ]
null
null
null
recipes/models.py
JakubKoralewski/django-recipes
3794c6a96fb0765e2e3cebfc3968dae88e4f084c
[ "MIT" ]
5
2021-03-19T03:49:52.000Z
2021-06-10T19:16:05.000Z
recipes/models.py
JakubKoralewski/django-recipes
3794c6a96fb0765e2e3cebfc3968dae88e4f084c
[ "MIT" ]
null
null
null
from typing import List, Dict, Union from django.db import models # Create your models here. # https://en.wikipedia.org/wiki/Cooking_weights_and_measures class AmountType(models.TextChoices): GRAMS = ('g', 'grams') KILOGRAMS = ('kg', 'kilograms') MILLILITERS = ('ml', 'milliliters') TABLE_SPOONS = ('tbsp', 'tabl...
28.83815
100
0.71798
4,806
0.963319
0
0
351
0.070355
0
0
907
0.1818
a166f12db4d713441e75c22cdaa77f074c8a2431
835
py
Python
zoneh/conf.py
RaminAT/zoneh
73c8e66d76cbd0aa51551e21740d88ff439158a9
[ "MIT" ]
8
2019-05-27T07:21:51.000Z
2021-09-14T21:26:53.000Z
zoneh/conf.py
RaminAT/zoneh
73c8e66d76cbd0aa51551e21740d88ff439158a9
[ "MIT" ]
5
2020-04-08T12:10:44.000Z
2021-02-11T01:51:41.000Z
zoneh/conf.py
RaminAT/zoneh
73c8e66d76cbd0aa51551e21740d88ff439158a9
[ "MIT" ]
5
2020-03-29T17:04:05.000Z
2021-09-14T21:26:58.000Z
"""Config module.""" import json import logging import os from zoneh.exceptions import ConfigError _log = logging.getLogger(__name__) _CONFIG_FILE = 'config.json' def _load_config(): """Load telegram and filters configuration from config file.""" if not os.path.isfile(_CONFIG_FILE): err_msg = f'Can...
22.567568
72
0.68024
0
0
0
0
0
0
0
0
234
0.28024
a1676b1833d7b48b6064b056da63a6fba24af86a
3,629
py
Python
mlogger.py
morris178/mqtt-data-logger
75e0fbbe0311ecaba8c905df356d6f7d8a0e3615
[ "MIT" ]
null
null
null
mlogger.py
morris178/mqtt-data-logger
75e0fbbe0311ecaba8c905df356d6f7d8a0e3615
[ "MIT" ]
null
null
null
mlogger.py
morris178/mqtt-data-logger
75e0fbbe0311ecaba8c905df356d6f7d8a0e3615
[ "MIT" ]
null
null
null
###demo code provided by Steve Cope at www.steves-internet-guide.com ##email [email protected] ###Free to use for any purpose """ implements data logging class """ import time, os, json, logging ############### class m_logger(object): """Class for logging data to a file. You can set the m...
36.656566
76
0.572058
3,390
0.934142
0
0
0
0
0
0
1,041
0.286856
a16793db9e30c478f5f315f915ced2b2053b7849
6,299
py
Python
ptools/lipytools/little_methods.py
piteren/ptools_module
5117d06d7dea4716b573b93d5feb10137966c373
[ "MIT" ]
null
null
null
ptools/lipytools/little_methods.py
piteren/ptools_module
5117d06d7dea4716b573b93d5feb10137966c373
[ "MIT" ]
null
null
null
ptools/lipytools/little_methods.py
piteren/ptools_module
5117d06d7dea4716b573b93d5feb10137966c373
[ "MIT" ]
null
null
null
""" 2018 (c) piteren some little methods (but frequently used) for Python """ from collections import OrderedDict import csv import inspect import json import os import pickle import random import shutil import string import time from typing import List, Callable, Any, Optional # prepares function parameters...
30.877451
120
0.582156
0
0
0
0
0
0
0
0
1,508
0.239327
a16884524638226d0ba06be614706d7a5f91b5dc
2,135
py
Python
tests/test.py
zephenryus/botw-grass
31adaebd69b56c4177bcdaf8e933fee5e8bc8433
[ "MIT" ]
1
2020-10-11T07:07:31.000Z
2020-10-11T07:07:31.000Z
tests/test.py
zephenryus/botw-grass
31adaebd69b56c4177bcdaf8e933fee5e8bc8433
[ "MIT" ]
null
null
null
tests/test.py
zephenryus/botw-grass
31adaebd69b56c4177bcdaf8e933fee5e8bc8433
[ "MIT" ]
1
2020-10-11T07:07:33.000Z
2020-10-11T07:07:33.000Z
import filecmp import hashlib import json import grass def grass_to_json(): """ Tests reading of grass file and exports data as a json file """ data = grass.read_grass("assets/5000000000.grass.extm") print("Saving file output/5000000000.grass.extm.json...") with open("output/5000000000.grass...
28.092105
90
0.6726
0
0
0
0
0
0
0
0
861
0.403279
a16900fa8a0412a37028d1da77ef8f912a14e56f
259
py
Python
Control/control_common.py
TomE8/drones
c92865556dd3df2d5f5b73589cd48e413bff3a3a
[ "MIT" ]
14
2018-10-29T00:52:18.000Z
2022-03-23T20:07:11.000Z
Control/control_common.py
TomE8/drones
c92865556dd3df2d5f5b73589cd48e413bff3a3a
[ "MIT" ]
4
2020-07-12T05:19:05.000Z
2020-09-20T12:40:47.000Z
Control/control_common.py
TomE8/drones
c92865556dd3df2d5f5b73589cd48e413bff3a3a
[ "MIT" ]
2
2019-03-08T01:36:47.000Z
2019-09-12T04:07:19.000Z
class AxisIndex(): #TODO: read this value from config file LEFT_RIGHT=0 FORWARD_BACKWARDS=1 ROTATE=2 UP_DOWN=3 class ButtonIndex(): TRIGGER = 0 SIDE_BUTTON = 1 HOVERING = 2 EXIT = 10 class ThresHold(): SENDING_TIME = 0.5
17.266667
58
0.648649
254
0.980695
0
0
0
0
0
0
39
0.150579
a16aa7de0e511402c80303f34d1d2b678e7b0256
446
py
Python
tests/LayoutTest.py
lakhman/restructuredWeb
a8aff9f96c63415fdefe6832f923a6d395d4ebdd
[ "MIT" ]
2
2021-05-19T15:43:26.000Z
2021-05-19T16:07:00.000Z
tests/LayoutTest.py
lakhman/restructuredWeb
a8aff9f96c63415fdefe6832f923a6d395d4ebdd
[ "MIT" ]
null
null
null
tests/LayoutTest.py
lakhman/restructuredWeb
a8aff9f96c63415fdefe6832f923a6d395d4ebdd
[ "MIT" ]
1
2021-05-19T15:43:44.000Z
2021-05-19T15:43:44.000Z
# -*- coding: utf-8 -*- from .BaseTest import BaseTest class LayoutTest(BaseTest): def test_layout_switch(self): """ Test layout switch """ self.do_component_fixture_test_with_real_sphinx('layout', 'layout') def test_layout_multiple(self): """ Test multiple lay...
26.235294
83
0.650224
388
0.869955
0
0
0
0
0
0
175
0.392377
a16aadbd9d67147c97cce0ae81ac212da4c01e1c
2,472
py
Python
.leetcode/16.3-sum-closest.2.py
KuiyuanFu/PythonLeetCode
8962df2fa838eb7ae48fa59de272ba55a89756d8
[ "MIT" ]
null
null
null
.leetcode/16.3-sum-closest.2.py
KuiyuanFu/PythonLeetCode
8962df2fa838eb7ae48fa59de272ba55a89756d8
[ "MIT" ]
null
null
null
.leetcode/16.3-sum-closest.2.py
KuiyuanFu/PythonLeetCode
8962df2fa838eb7ae48fa59de272ba55a89756d8
[ "MIT" ]
null
null
null
# @lc app=leetcode id=16 lang=python3 # # [16] 3Sum Closest # # https://leetcode.com/problems/3sum-closest/description/ # # algorithms # Medium (46.33%) # Likes: 3080 # Dislikes: 169 # Total Accepted: 570.4K # Total Submissions: 1.2M # Testcase Example: '[-1,2,1,-4]\n1' # # Given an array nums of n integers and ...
22.071429
95
0.506068
1,088
0.398535
0
0
0
0
0
0
1,599
0.585714
a16be12b3f57a68c02b41dfe786a31910f86a92e
2,142
py
Python
test/test_functions/test_michalewicz.py
carefree0910/botorch
c0b252baba8f16a4ea2eb3f99c266fba47418b1f
[ "MIT" ]
null
null
null
test/test_functions/test_michalewicz.py
carefree0910/botorch
c0b252baba8f16a4ea2eb3f99c266fba47418b1f
[ "MIT" ]
null
null
null
test/test_functions/test_michalewicz.py
carefree0910/botorch
c0b252baba8f16a4ea2eb3f99c266fba47418b1f
[ "MIT" ]
1
2019-05-07T23:53:08.000Z
2019-05-07T23:53:08.000Z
#! /usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved import unittest import torch from botorch.test_functions.michalewicz import ( GLOBAL_MAXIMIZER, GLOBAL_MAXIMUM, neg_michalewicz, ) class TestNegMichalewicz(unittest.TestCase): def test_single_eval_neg_mic...
38.25
80
0.661531
1,898
0.886088
0
0
0
0
0
0
126
0.058824
a16cdf1f2057c870dd857dd5ffd7ccfb349decff
1,122
py
Python
example_scripts/write_mztab_result.py
gavswe/pyqms
299cd4d96b78611ebbe43e0ac625909c6a8d8fd9
[ "MIT" ]
23
2017-06-28T07:53:42.000Z
2022-02-20T02:46:37.000Z
example_scripts/write_mztab_result.py
gavswe/pyqms
299cd4d96b78611ebbe43e0ac625909c6a8d8fd9
[ "MIT" ]
23
2019-05-15T18:05:18.000Z
2022-01-21T13:27:11.000Z
example_scripts/write_mztab_result.py
gavswe/pyqms
299cd4d96b78611ebbe43e0ac625909c6a8d8fd9
[ "MIT" ]
11
2017-06-26T13:22:57.000Z
2022-03-31T23:35:14.000Z
#!/usr/bin/env python3 # encoding: utf-8 """ pyQms ----- Python module for fast and accurate mass spectrometry data quantification :license: MIT, see LICENSE.txt for more details Authors: * Leufken, J. * Niehues, A. * Sarin, L.P. * Hippler, M. * Leidel, S....
21.169811
78
0.622995
0
0
0
0
0
0
0
0
798
0.71123
a16d009cfff8e6fc878e82ac94cf0ba2221a05c0
5,516
py
Python
dbservice/dbprovider/MessageDAO.py
artyomche9/digest_bot
480e9038ac1f42a10a9a333a72b9e38fa9fe8385
[ "MIT" ]
11
2019-10-25T12:42:03.000Z
2020-04-03T09:43:49.000Z
dbservice/dbprovider/MessageDAO.py
maybe-hello-world/digestbot
480e9038ac1f42a10a9a333a72b9e38fa9fe8385
[ "MIT" ]
13
2020-12-12T12:33:55.000Z
2021-09-09T15:00:57.000Z
dbservice/dbprovider/MessageDAO.py
artyomche9/digest_bot
480e9038ac1f42a10a9a333a72b9e38fa9fe8385
[ "MIT" ]
5
2019-10-06T09:55:24.000Z
2019-10-21T16:36:56.000Z
from decimal import Decimal from typing import List, Any from common.Enums import SortingType from models import Message from .engine import db_engine, DBEngine class MessageDAO: def __init__(self, engine: DBEngine): self.engine = engine @staticmethod def __make_insert_values_from_messages_array...
36.773333
99
0.603336
5,313
0.963198
0
0
857
0.155366
4,308
0.781001
2,084
0.37781
a16f85e6fac2fb3f5423a543ab4b85436a1f1301
196
py
Python
Chapter09/fuzzing.py
firebitsbr/Penetration-Testing-with-Shellcode
2d756bccace6b727e050b2010ebf23e08d221fdc
[ "MIT" ]
30
2018-05-15T21:45:09.000Z
2022-03-23T20:04:25.000Z
Chapter09/fuzzing.py
naveenselvan/Penetration-Testing-with-Shellcode
2d756bccace6b727e050b2010ebf23e08d221fdc
[ "MIT" ]
1
2020-10-19T13:03:32.000Z
2020-11-24T05:50:17.000Z
Chapter09/fuzzing.py
naveenselvan/Penetration-Testing-with-Shellcode
2d756bccace6b727e050b2010ebf23e08d221fdc
[ "MIT" ]
18
2018-02-20T21:21:23.000Z
2022-01-26T04:19:28.000Z
#!/usr/bin/python import socket import sys junk = 'A'*500 s=socket.socket(socket.AF_INET,socket.SOCK_STREAM) connect = s.connect(('192.168.129.128',21)) s.recv(1024) s.send('USER '+junk+'\r\n')
17.818182
50
0.69898
0
0
0
0
0
0
0
0
50
0.255102
a17081dce9dfbf674f07300258797fe7e68a0847
1,746
py
Python
017. Letter Combinations of a Phone Number.py
youhusky/Facebook_Prepare
4045bcb652537711b3680b2aa17204ae73c6bde8
[ "MIT" ]
6
2017-10-30T05:35:46.000Z
2020-12-15T06:51:52.000Z
017. Letter Combinations of a Phone Number.py
youhusky/Facebook_Prepare
4045bcb652537711b3680b2aa17204ae73c6bde8
[ "MIT" ]
1
2017-10-30T04:11:31.000Z
2017-10-30T05:46:24.000Z
017. Letter Combinations of a Phone Number.py
youhusky/Facebook_Prepare
4045bcb652537711b3680b2aa17204ae73c6bde8
[ "MIT" ]
2
2020-09-03T07:14:02.000Z
2021-05-21T19:19:57.000Z
# Given a digit string, return all possible letter combinations that the number could represent. # A mapping of digit to letters (just like on the telephone buttons) is given below. # Input:Digit string "23" # Output: ["ad", "ae", "af", "bd", "be", "bf", "cd", "ce", "cf"]. # DFS backtracking class Solution(object)...
27.28125
96
0.4874
1,374
0.786942
0
0
0
0
0
0
507
0.290378
a172ea5b14e8133a222d02986a593e89323cad7c
847
py
Python
FreeBSD/bsd_netstats_poller.py
failedrequest/telegraf-plugins
9cda0612a912f219fa84724f12af1f428483a37a
[ "BSD-2-Clause" ]
null
null
null
FreeBSD/bsd_netstats_poller.py
failedrequest/telegraf-plugins
9cda0612a912f219fa84724f12af1f428483a37a
[ "BSD-2-Clause" ]
null
null
null
FreeBSD/bsd_netstats_poller.py
failedrequest/telegraf-plugins
9cda0612a912f219fa84724f12af1f428483a37a
[ "BSD-2-Clause" ]
null
null
null
#!/usr/bin/env python3 # 3/21/2021 # Updated for python3 # A Simple sysctl to telegraf plugin for freebsd's netstats ip info from freebsd_sysctl import Sysctl as sysctl import subprocess as sp import re import json import sys import pprint as pp hostname = sysctl("kern.hostname").value netstat_data = {} points_netst...
22.289474
119
0.709563
0
0
0
0
0
0
0
0
248
0.292798
a1730ed2d00a6babe52f239de2d480281d939967
13,395
py
Python
ixnetwork_restpy/testplatform/sessions/ixnetwork/topology/packetinlist_10d8adb40e4e05f4b37904f2c6428ca9.py
OpenIxia/ixnetwork_restpy
f628db450573a104f327cf3c737ca25586e067ae
[ "MIT" ]
20
2019-05-07T01:59:14.000Z
2022-02-11T05:24:47.000Z
ixnetwork_restpy/testplatform/sessions/ixnetwork/topology/packetinlist_10d8adb40e4e05f4b37904f2c6428ca9.py
OpenIxia/ixnetwork_restpy
f628db450573a104f327cf3c737ca25586e067ae
[ "MIT" ]
60
2019-04-03T18:59:35.000Z
2022-02-22T12:05:05.000Z
ixnetwork_restpy/testplatform/sessions/ixnetwork/topology/packetinlist_10d8adb40e4e05f4b37904f2c6428ca9.py
OpenIxia/ixnetwork_restpy
f628db450573a104f327cf3c737ca25586e067ae
[ "MIT" ]
13
2019-05-20T10:48:31.000Z
2021-10-06T07:45:44.000Z
# MIT LICENSE # # Copyright 1997 - 2020 by IXIA Keysight # # 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,...
40.468278
193
0.642255
12,161
0.907876
0
0
3,618
0.270101
0
0
9,597
0.716461
a173546fb4be8c1b52e29b792d62de5b919bbc8f
97
py
Python
Python/Phani.py
baroood/Hacktoberfest-2k17
87383df4bf705358866a5a4120dd678a3f2acd3e
[ "MIT" ]
28
2017-10-04T19:42:26.000Z
2021-03-26T04:00:48.000Z
Python/Phani.py
baroood/Hacktoberfest-2k17
87383df4bf705358866a5a4120dd678a3f2acd3e
[ "MIT" ]
375
2017-09-28T02:58:37.000Z
2019-10-31T09:10:38.000Z
Python/Phani.py
baroood/Hacktoberfest-2k17
87383df4bf705358866a5a4120dd678a3f2acd3e
[ "MIT" ]
519
2017-09-28T02:40:29.000Z
2021-02-15T08:29:17.000Z
a = input("Enter the first number") b = input("Enter the second number") print('the sum is',a+b)
24.25
36
0.680412
0
0
0
0
0
0
0
0
61
0.628866
a1735e027f0563b68478c5ef69b57c79d02303e9
1,108
py
Python
servicecatalog_factory/constants_test.py
micwha/aws-service-catalog-factory
c50a922d64e3d47fd56dbe261d841d81f872f0fb
[ "Apache-2.0" ]
null
null
null
servicecatalog_factory/constants_test.py
micwha/aws-service-catalog-factory
c50a922d64e3d47fd56dbe261d841d81f872f0fb
[ "Apache-2.0" ]
null
null
null
servicecatalog_factory/constants_test.py
micwha/aws-service-catalog-factory
c50a922d64e3d47fd56dbe261d841d81f872f0fb
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. # SPDX-License-Identifier: Apache-2.0 from pytest import fixture @fixture def sut(): from servicecatalog_factory import constants return constants def test_bootstrap_stack_name(sut): # setup expected_result = "servicecatalog...
22.612245
73
0.712094
0
0
0
0
90
0.081227
0
0
462
0.416968
a173f091bd6a84a9640f8e5bfa3ab824665803fb
1,038
py
Python
django/contrib/contenttypes/tests/models.py
benjaoming/django
6dbe979b4d9396e1b307c7d27388c97c13beb21c
[ "BSD-3-Clause" ]
2
2015-01-21T15:45:07.000Z
2015-02-21T02:38:13.000Z
env/lib/python2.7/site-packages/django/contrib/contenttypes/tests/models.py
luiscarlosgph/nas
e5acee61e8bbf12c34785fe971ce7df8dee775d4
[ "MIT" ]
10
2019-12-26T17:31:31.000Z
2022-03-21T22:17:33.000Z
env/lib/python2.7/site-packages/django/contrib/contenttypes/tests/models.py
luiscarlosgph/nas
e5acee61e8bbf12c34785fe971ce7df8dee775d4
[ "MIT" ]
1
2020-05-25T08:55:19.000Z
2020-05-25T08:55:19.000Z
from django.db import models from django.utils.encoding import python_2_unicode_compatible from django.utils.http import urlquote class ConcreteModel(models.Model): name = models.CharField(max_length=10) class ProxyModel(ConcreteModel): class Meta: proxy = True @python_2_unicode_compatible class F...
23.590909
73
0.716763
864
0.83237
0
0
305
0.293834
0
0
345
0.33237
a174909b1f9a6d386413fccc83ffd4e52629d864
75,049
py
Python
tests/unit/utils/test_docker.py
springborland/salt
bee85e477d57e9a171884e54fefb9a59d0835ed0
[ "Apache-2.0" ]
1
2020-04-09T03:25:10.000Z
2020-04-09T03:25:10.000Z
tests/unit/utils/test_docker.py
springborland/salt
bee85e477d57e9a171884e54fefb9a59d0835ed0
[ "Apache-2.0" ]
null
null
null
tests/unit/utils/test_docker.py
springborland/salt
bee85e477d57e9a171884e54fefb9a59d0835ed0
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ tests.unit.utils.test_docker ============================ Test the funcs in salt.utils.docker and salt.utils.docker.translate """ # Import Python Libs from __future__ import absolute_import, print_function, unicode_literals import copy import functools import logging import os # Import sa...
37.134587
88
0.514371
74,245
0.989287
0
0
15,746
0.20981
0
0
23,282
0.310224
a174c86a4c793d497c49fdd9127b5aea515b4346
400
py
Python
utils/middleware.py
DavidRoldan523/elenas_test
8b520fae68a275654a42ad761713c9c932d17a76
[ "MIT" ]
null
null
null
utils/middleware.py
DavidRoldan523/elenas_test
8b520fae68a275654a42ad761713c9c932d17a76
[ "MIT" ]
null
null
null
utils/middleware.py
DavidRoldan523/elenas_test
8b520fae68a275654a42ad761713c9c932d17a76
[ "MIT" ]
null
null
null
from django.http import HttpResponse from django.utils.deprecation import MiddlewareMixin class HealthCheckMiddleware: def __init__(self, get_response): self.get_response = get_response def __call__(self, request): if request.META["PATH_INFO"] == "/health-check/": return HttpRespo...
28.571429
57
0.7
308
0.77
0
0
0
0
0
0
31
0.0775
a175602faa0357ee58584137efdc7c85d289bf89
3,317
py
Python
bot/exts/evergreen/catify.py
chincholikarsalil/sir-lancebot
05ba3de5c99b30a8eba393da1460fae255373457
[ "MIT" ]
null
null
null
bot/exts/evergreen/catify.py
chincholikarsalil/sir-lancebot
05ba3de5c99b30a8eba393da1460fae255373457
[ "MIT" ]
null
null
null
bot/exts/evergreen/catify.py
chincholikarsalil/sir-lancebot
05ba3de5c99b30a8eba393da1460fae255373457
[ "MIT" ]
null
null
null
import random from contextlib import suppress from typing import Optional from discord import AllowedMentions, Embed, Forbidden from discord.ext import commands from bot.constants import Cats, Colours, NEGATIVE_REPLIES from bot.utils import helpers class Catify(commands.Cog): """Cog for the catify command.""" ...
37.269663
119
0.545674
2,974
0.893361
0
0
2,836
0.851907
2,720
0.817062
643
0.193151
a1773cd4561ed64fe6472e04a837e283a5378aa9
1,763
py
Python
data/ebmnlp/stream.py
bepnye/tf_ner
c68b9f489e56e0ec8cfb02b7115d2b07d721ac6f
[ "Apache-2.0" ]
null
null
null
data/ebmnlp/stream.py
bepnye/tf_ner
c68b9f489e56e0ec8cfb02b7115d2b07d721ac6f
[ "Apache-2.0" ]
null
null
null
data/ebmnlp/stream.py
bepnye/tf_ner
c68b9f489e56e0ec8cfb02b7115d2b07d721ac6f
[ "Apache-2.0" ]
null
null
null
import os import data_utils from pathlib import Path top_path = Path(os.path.dirname(os.path.abspath(__file__))) EBM_NLP = Path('/Users/ben/Desktop/ebm_nlp/repo/ebm_nlp_2_00/') NO_LABEL = '0' def overwrite_tags(new_tags, tags): for i, t in enumerate(new_tags): if t != NO_LABEL: tags[i] = t def get_tags(d...
28.435484
109
0.683494
0
0
0
0
0
0
0
0
222
0.125922
a178917c391e8c7d6cc84a889a8b3efdf43b8cd9
16,753
py
Python
Kernels/Research/FFT/config/fft.py
WoodData/EndpointAI
8e4d145ff45cf5559ab009eba4f423e944dc6975
[ "Apache-2.0" ]
190
2020-09-22T02:14:29.000Z
2022-03-28T02:35:57.000Z
Kernels/Research/FFT/config/fft.py
chuancqc/EndpointAI
ab67cefeae3c06f1c93f66812bcf988c14e72ff1
[ "Apache-2.0" ]
2
2021-08-30T10:06:22.000Z
2021-11-05T20:37:58.000Z
Kernels/Research/FFT/config/fft.py
chuancqc/EndpointAI
ab67cefeae3c06f1c93f66812bcf988c14e72ff1
[ "Apache-2.0" ]
80
2020-09-13T17:48:56.000Z
2022-03-19T10:45:05.000Z
# # # Copyright (C) 2010-2021 ARM Limited or its affiliates. All rights reserved. # # SPDX-License-Identifier: Apache-2.0 # # 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 # # www.apache.org/lice...
27.463934
98
0.595595
6,312
0.376768
0
0
1,333
0.079568
0
0
4,460
0.266221
a179d95ca52452ffb3320f8150fc8f1ca9d9de24
1,275
py
Python
classification/resnetOnnx_inference_dynamicInput.py
SahilChachra/Onnx-Deposit
6cdf03903639166a43e0c809b67621a1aa2449dd
[ "BSD-3-Clause" ]
null
null
null
classification/resnetOnnx_inference_dynamicInput.py
SahilChachra/Onnx-Deposit
6cdf03903639166a43e0c809b67621a1aa2449dd
[ "BSD-3-Clause" ]
null
null
null
classification/resnetOnnx_inference_dynamicInput.py
SahilChachra/Onnx-Deposit
6cdf03903639166a43e0c809b67621a1aa2449dd
[ "BSD-3-Clause" ]
null
null
null
''' This inference script takes in images of dynamic size Runs inference in batch ** In this images have been resized but not need for this script ''' import onnx import onnxruntime as ort import numpy as np import cv2 from imagenet_classlist import get_class import os model_path = 'resnet18.onnx' model = onnx.load(...
28.977273
89
0.680784
0
0
0
0
0
0
0
0
358
0.280784
a17a4e7f440bd9450eae4bfedcba472184cfe212
3,857
py
Python
demo/Master/TaskMaker.py
build2last/JOCC
8eedaa923c6444a32e53e03fdd2a85a8031c46f5
[ "MIT" ]
null
null
null
demo/Master/TaskMaker.py
build2last/JOCC
8eedaa923c6444a32e53e03fdd2a85a8031c46f5
[ "MIT" ]
null
null
null
demo/Master/TaskMaker.py
build2last/JOCC
8eedaa923c6444a32e53e03fdd2a85a8031c46f5
[ "MIT" ]
null
null
null
# coding:utf-8 import time import MySQLdb import conf import Server # Another way to load data to MySQL: # load data infile "C://ProgramData/MySQL/MySQL Server 5.7/Uploads/track_info_url_0_part0.txt" ignore into table develop.task(mid, url); # doing: load data infile "C://ProgramData/MySQL/MySQL Server 5.7/Uploads/tr...
38.959596
221
0.577392
2,942
0.75494
326
0.083654
0
0
0
0
1,392
0.357198
a17ebf74350b134333915aa09bd51888d3742c03
770
py
Python
Inclass/python/sort_order_testing/sort_order.py
chenchuw/EC602-Design-by-Software
c233c9d08a67abc47235282fedd866d67ccaf4ce
[ "MIT" ]
null
null
null
Inclass/python/sort_order_testing/sort_order.py
chenchuw/EC602-Design-by-Software
c233c9d08a67abc47235282fedd866d67ccaf4ce
[ "MIT" ]
null
null
null
Inclass/python/sort_order_testing/sort_order.py
chenchuw/EC602-Design-by-Software
c233c9d08a67abc47235282fedd866d67ccaf4ce
[ "MIT" ]
1
2022-01-11T20:23:47.000Z
2022-01-11T20:23:47.000Z
#!/Users/francischen/opt/anaconda3/bin/python #pythons sorts are STABLE: order is the same as original in tie. # sort: key, reverse q = ['two','twelve','One','3'] #sort q, result being a modified list. nothing is returned q.sort() print(q) q = ['two','twelve','One','3',"this has lots of t's"] q.sort(reverse=True) pr...
18.333333
64
0.62987
0
0
0
0
0
0
0
0
457
0.593506
a17ec4639df7fdbb530566bb66941b664210b137
96
py
Python
bhinneka/utils.py
kangfend/scrapy-bhinneka
a4a6e4ae5295e8bf83b213c1dace9c7de70f128c
[ "MIT" ]
1
2016-10-04T10:10:05.000Z
2016-10-04T10:10:05.000Z
bhinneka/utils.py
kangfend/scrapy-bhinneka
a4a6e4ae5295e8bf83b213c1dace9c7de70f128c
[ "MIT" ]
null
null
null
bhinneka/utils.py
kangfend/scrapy-bhinneka
a4a6e4ae5295e8bf83b213c1dace9c7de70f128c
[ "MIT" ]
null
null
null
from bhinneka.settings import BASE_URL def get_absolute_url(path): return BASE_URL + path
16
38
0.78125
0
0
0
0
0
0
0
0
0
0
a17ef045f77adc98f9fc666a8b89d72884c7ebf6
287
py
Python
tests/test_vsan/vars.py
wardy3/mdssdk
393102fab146917a3893b6aa2bd6a0449ad491c5
[ "Apache-2.0" ]
4
2020-12-13T20:02:43.000Z
2022-02-27T23:36:58.000Z
tests/test_vsan/vars.py
wardy3/mdssdk
393102fab146917a3893b6aa2bd6a0449ad491c5
[ "Apache-2.0" ]
13
2020-09-23T07:30:15.000Z
2022-03-30T01:12:25.000Z
tests/test_vsan/vars.py
wardy3/mdssdk
393102fab146917a3893b6aa2bd6a0449ad491c5
[ "Apache-2.0" ]
12
2020-05-11T09:33:21.000Z
2022-03-18T11:11:28.000Z
import logging import random log = logging.getLogger(__name__) reserved_id = [4079, 4094] boundary_id = [0, 4095] # No need to have end=4094 as there are some inbetween vsans reserved for fport-channel-trunk def get_random_id(start=2, end=400): return random.randint(start, end)
22.076923
93
0.756098
0
0
0
0
0
0
0
0
93
0.324042
a17f452cabac62c273c6e040b99703605a01fbfa
1,403
py
Python
testing_ideas/try_pymed_package/try_pymed_and_ss_api.py
hschilling/data-collection-and-prep
b70ab54fd887592bad05d5748f492fc2f9ef0f6f
[ "Unlicense" ]
null
null
null
testing_ideas/try_pymed_package/try_pymed_and_ss_api.py
hschilling/data-collection-and-prep
b70ab54fd887592bad05d5748f492fc2f9ef0f6f
[ "Unlicense" ]
41
2021-01-01T14:01:30.000Z
2021-01-27T20:17:21.000Z
testing_ideas/try_pymed_package/try_pymed_and_ss_api.py
hschilling/data-collection-and-prep
b70ab54fd887592bad05d5748f492fc2f9ef0f6f
[ "Unlicense" ]
5
2021-02-08T14:19:35.000Z
2021-10-19T12:10:55.000Z
# Use the pymed package to call the PubMed API to get lots of papers from, in this case, JEB from pymed import PubMed import pandas as pd import requests _REQUESTS_TIMEOUT = 3.0 df_jeb = pd.DataFrame(columns=['title', 'abstract']) df_jeb = df_jeb.convert_dtypes() pubmed = PubMed(tool="MyTool", email="[email protected]...
40.085714
134
0.68211
0
0
0
0
0
0
0
0
708
0.504633
a17f65f1db1e9d6fc0255b219c8e7f7acd085081
287
py
Python
simple_functions/__init__.py
JihaoXin/ci_acse1
6ba30368cc2000bb13aab0dc213837d530753612
[ "MIT" ]
null
null
null
simple_functions/__init__.py
JihaoXin/ci_acse1
6ba30368cc2000bb13aab0dc213837d530753612
[ "MIT" ]
null
null
null
simple_functions/__init__.py
JihaoXin/ci_acse1
6ba30368cc2000bb13aab0dc213837d530753612
[ "MIT" ]
null
null
null
from .functions1 import my_sum, factorial from .constants import pi from .print import myprint from pkg_resources import get_distribution, DistributionNotFound try: __version__ = get_distribution(__name__).version except DistributionNotFound: # package is not installed pass
28.7
64
0.811847
0
0
0
0
0
0
0
0
26
0.090592
a17f75ddc89a6583319e9dcd13c17dded131aa22
1,259
bzl
Python
tools/build_defs/native_tools/tool_access.bzl
slsyy/rules_foreign_cc
34ab7f86a3ab1b2381cb4820d08a1c892f55bf54
[ "Apache-2.0" ]
null
null
null
tools/build_defs/native_tools/tool_access.bzl
slsyy/rules_foreign_cc
34ab7f86a3ab1b2381cb4820d08a1c892f55bf54
[ "Apache-2.0" ]
null
null
null
tools/build_defs/native_tools/tool_access.bzl
slsyy/rules_foreign_cc
34ab7f86a3ab1b2381cb4820d08a1c892f55bf54
[ "Apache-2.0" ]
null
null
null
# buildifier: disable=module-docstring load(":native_tools_toolchain.bzl", "access_tool") def get_cmake_data(ctx): return _access_and_expect_label_copied("@rules_foreign_cc//tools/build_defs:cmake_toolchain", ctx, "cmake") def get_ninja_data(ctx): return _access_and_expect_label_copied("@rules_foreign_cc//too...
38.151515
111
0.669579
0
0
0
0
0
0
0
0
430
0.341541
a1813bf8f98dea1f19c9411401522d50224116bd
5,805
py
Python
tests/test_model.py
jakehadar/py-snake
3c19d572afb275768c504c66d331b5727515fd71
[ "MIT" ]
null
null
null
tests/test_model.py
jakehadar/py-snake
3c19d572afb275768c504c66d331b5727515fd71
[ "MIT" ]
null
null
null
tests/test_model.py
jakehadar/py-snake
3c19d572afb275768c504c66d331b5727515fd71
[ "MIT" ]
1
2021-11-30T10:14:32.000Z
2021-11-30T10:14:32.000Z
# -*- coding: utf-8 -*- import sys import pytest from snake.common import Frame, Point, BoundaryCollision, SelfCollision from snake.config import GameConfig from snake.model import SnakeModel @pytest.fixture def config(): config = GameConfig() config.solid_walls = True config.initial_food_count = 0 ...
28.880597
102
0.64186
4,880
0.840655
0
0
2,887
0.49733
0
0
515
0.088717
a1823c37136cd59bed9a94266ef25fc93fb40d71
255
py
Python
gallery/photo/urls.py
andyjohn23/django-photo
e65ee3ab6fdad3a9d836d32b7f1026efcc728a41
[ "MIT" ]
null
null
null
gallery/photo/urls.py
andyjohn23/django-photo
e65ee3ab6fdad3a9d836d32b7f1026efcc728a41
[ "MIT" ]
null
null
null
gallery/photo/urls.py
andyjohn23/django-photo
e65ee3ab6fdad3a9d836d32b7f1026efcc728a41
[ "MIT" ]
null
null
null
from django.urls import path from . import views urlpatterns = [ path('', views.index, name="index"), path('category/<category>/', views.CategoryListView.as_view(), name="category"), path('search/', views.image_search, name='image-search'), ]
31.875
84
0.686275
0
0
0
0
0
0
0
0
64
0.25098
a182a47e0e9e4e6e3cf93dede6480b43b9da9679
381
py
Python
book2/s4_ex2.py
Felipe-Tommaselli/Python4everbody_Michigan
f4f940c15a4b165b144d14ead79d583bf31b805b
[ "MIT" ]
null
null
null
book2/s4_ex2.py
Felipe-Tommaselli/Python4everbody_Michigan
f4f940c15a4b165b144d14ead79d583bf31b805b
[ "MIT" ]
null
null
null
book2/s4_ex2.py
Felipe-Tommaselli/Python4everbody_Michigan
f4f940c15a4b165b144d14ead79d583bf31b805b
[ "MIT" ]
null
null
null
fname = input("Enter file name: ") if len(fname) < 1 : fname = "mbox-short.txt" list = list() f = open(fname) count = 0 for line in f: line = line.rstrip() list = line.split() if list == []: continue elif list[0].lower() == 'from': count += 1 print(list[1]) print("There w...
25.4
75
0.564304
0
0
0
0
0
0
0
0
100
0.262467
a183121368090836638181c5ae887b713f923588
6,358
py
Python
fedsimul/models/mnist/mclr.py
cshjin/fedsimul
1e2b9a9d9034fbc679dfaff059c42dea5642971d
[ "MIT" ]
11
2021-05-07T01:28:26.000Z
2022-03-10T08:23:16.000Z
fedsimul/models/mnist/mclr.py
cshjin/fedsimul
1e2b9a9d9034fbc679dfaff059c42dea5642971d
[ "MIT" ]
2
2021-08-13T10:12:13.000Z
2021-08-31T02:03:20.000Z
fedsimul/models/mnist/mclr.py
cshjin/fedsimul
1e2b9a9d9034fbc679dfaff059c42dea5642971d
[ "MIT" ]
1
2021-06-08T07:23:22.000Z
2021-06-08T07:23:22.000Z
import numpy as np import tensorflow as tf from tqdm import trange from fedsimul.utils.model_utils import batch_data from fedsimul.utils.tf_utils import graph_size from fedsimul.utils.tf_utils import process_grad class Model(object): ''' This is the tf model for the MNIST dataset with multiple class learner ...
35.920904
118
0.574394
6,141
0.96587
0
0
0
0
0
0
1,936
0.304498