hexsha
stringlengths
40
40
size
int64
6
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
247
max_issues_repo_name
stringlengths
4
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
247
max_forks_repo_name
stringlengths
4
130
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.53
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
6
1.04M
filtered:remove_non_ascii
int64
0
538k
filtered:remove_decorators
int64
0
917k
filtered:remove_async
int64
0
722k
filtered:remove_classes
int64
-45
1M
filtered:remove_generators
int64
0
814k
filtered:remove_function_no_docstring
int64
-102
850k
filtered:remove_class_no_docstring
int64
-3
5.46k
filtered:remove_unused_imports
int64
-1,350
52.4k
filtered:remove_delete_markers
int64
0
59.6k
366737a828415b6bfb9f1a6b95aefbecdab7cc3d
2,259
py
Python
Examples/scripts/vector_scalar.py
jenkayco/hacknostics
4f980b17a2648cb6547cd2d8b442ae23253ab5e6
[ "MIT" ]
2
2019-06-04T20:10:46.000Z
2021-06-07T21:10:39.000Z
Examples/scripts/vector_scalar.py
jenkayco/hacknostics
4f980b17a2648cb6547cd2d8b442ae23253ab5e6
[ "MIT" ]
2
2019-06-05T03:08:06.000Z
2019-06-05T15:38:01.000Z
Examples/scripts/vector_scalar.py
jenkayco/hacknostics
4f980b17a2648cb6547cd2d8b442ae23253ab5e6
[ "MIT" ]
2
2019-06-05T03:11:35.000Z
2019-06-05T05:33:45.000Z
#================================================# # vector_scalar.py # based on: gsn_vec_scal_1.ncl, # gsn_vec_scal_2.ncl, # gsn_vec_scal_3.ncl #================================================# from pathlib import Path import numpy as np import xarray as xr import matplotlib.pyplot as plt impo...
37.65
88
0.536963
#================================================# # vector_scalar.py # based on: gsn_vec_scal_1.ncl, # gsn_vec_scal_2.ncl, # gsn_vec_scal_3.ncl #================================================# from pathlib import Path import numpy as np import xarray as xr import matplotlib.pyplot as plt impo...
0
0
0
0
0
0
0
0
0
fa4414908dbefc98c70ceea38be4dd04bef4dd48
2,691
py
Python
command_cop.py
jperras/command_cop
4b2c4f3020b6bdac1ed2973c5c8b2c1ba1b69b21
[ "MIT" ]
1
2019-09-15T14:04:09.000Z
2019-09-15T14:04:09.000Z
command_cop.py
jperras/command_cop
4b2c4f3020b6bdac1ed2973c5c8b2c1ba1b69b21
[ "MIT" ]
null
null
null
command_cop.py
jperras/command_cop
4b2c4f3020b6bdac1ed2973c5c8b2c1ba1b69b21
[ "MIT" ]
null
null
null
# -*- encoding: utf-8 -*- ### # Copyright 2019 Jol Perras <joel@nerderati.com> # 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 #...
38.442857
105
0.719064
# -*- encoding: utf-8 -*- ### # Copyright 2019 Joël Perras <joel@nerderati.com> # 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 ...
4
0
0
0
0
0
0
0
0
898fd9f2849e86df31a1eb44887c52a2fa952bac
1,143
py
Python
config.py
amour-lee/NewsProject
85fcd3798e84657d13583b0d0344c993aeb87790
[ "MIT" ]
null
null
null
config.py
amour-lee/NewsProject
85fcd3798e84657d13583b0d0344c993aeb87790
[ "MIT" ]
null
null
null
config.py
amour-lee/NewsProject
85fcd3798e84657d13583b0d0344c993aeb87790
[ "MIT" ]
null
null
null
# # configs = { 'dev':DevelopmentConfig, 'prod':ProductionConfig }
21.566038
87
0.688539
from redis import StrictRedis import logging # 准备配置类 class Config(object): """app配置类""" # DEBUG = True # 配置MySQL:指定数据库位置 SQLALCHEMY_DATABASE_URI = 'mysql://root:mysql@mysql@127.0.0.1:3306/information_new' # 禁用追踪mysql:因为mysql的性能差,如果再去追踪mysql的所有的修改,会再次浪费性能 SQLALCHEMY_TRACK_MODIFICATIONS = False ...
585
0
0
756
0
0
0
1
112
7194658629832659b219bf86a0f106db81b3b79b
2,074
py
Python
src/controllers/joint_space_feedforward_controller.py
MatthiasDR96/industrial_robotics_simulator
9039e7a581ce97c583c73294e9937664de90530b
[ "MIT" ]
1
2020-10-21T15:32:41.000Z
2020-10-21T15:32:41.000Z
src/controllers/joint_space_feedforward_controller.py
MatthiasDR96/industrial_robotics_simulator
9039e7a581ce97c583c73294e9937664de90530b
[ "MIT" ]
null
null
null
src/controllers/joint_space_feedforward_controller.py
MatthiasDR96/industrial_robotics_simulator
9039e7a581ce97c583c73294e9937664de90530b
[ "MIT" ]
null
null
null
""" A controller class which implements a joint feedforward controller by compensating for the desired acceleration torque and the desired gravity torque."""
31.424242
111
0.62729
import math import numpy as np """ A controller class which implements a joint feedforward controller by compensating for the desired acceleration torque and the desired gravity torque.""" class Control: def __init__(self, arm): # Bind arm self.arm = arm # Control type self.con...
0
0
0
1,859
0
0
0
-13
68
203ff959bd2a258325fc3617c59e0ffe1dab56f5
27,305
py
Python
research/a2n/train.py
srihari-humbarwadi/neural-structured-learning
345b8d644dd7745179263bf6dc9aeb8a921528f4
[ "Apache-2.0" ]
939
2019-08-28T06:50:30.000Z
2022-03-30T02:37:07.000Z
research/a2n/train.py
srihari-humbarwadi/neural-structured-learning
345b8d644dd7745179263bf6dc9aeb8a921528f4
[ "Apache-2.0" ]
80
2019-09-01T19:47:30.000Z
2022-02-02T20:38:38.000Z
research/a2n/train.py
srihari-humbarwadi/neural-structured-learning
345b8d644dd7745179263bf6dc9aeb8a921528f4
[ "Apache-2.0" ]
196
2019-09-01T19:38:53.000Z
2022-02-08T01:25:57.000Z
# Copyright 2019 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
40.814649
105
0.680718
# Copyright 2019 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
0
0
0
145
0
298
0
0
71
8276054130b6223eb6e4eaa348d70760cd57a8e8
1,419
py
Python
scrapfishin/queries.py
SupahNoob/scrapfishin
8163ee40a348ff45d2dd0384acf948c4fff87fa3
[ "MIT" ]
null
null
null
scrapfishin/queries.py
SupahNoob/scrapfishin
8163ee40a348ff45d2dd0384acf948c4fff87fa3
[ "MIT" ]
null
null
null
scrapfishin/queries.py
SupahNoob/scrapfishin
8163ee40a348ff45d2dd0384acf948c4fff87fa3
[ "MIT" ]
null
null
null
from typing import Iterable import sqlalchemy as sa from scrapfishin.models import Recipe def grocery_list( s: sa.orm.Session, recipes: Iterable[Recipe] ) -> str: """ Format an iterable of Recipes into a Grocery List. Parameters ---------- s : sqlalchemy.orm.Session database ses...
21.830769
70
0.549683
from typing import Iterable import sqlalchemy as sa from scrapfishin.models import Recipe def grocery_list( s: sa.orm.Session, recipes: Iterable[Recipe] ) -> str: """ Format an iterable of Recipes into a Grocery List. Parameters ---------- s : sqlalchemy.orm.Session database ses...
0
0
0
0
0
0
0
0
0
9ab7a8ab803317414b2c748a2679e0808435230a
2,345
py
Python
ndg/security/server/test/config/attributeauthority/sitea/attributeauthorityapp.py
cedadev/ndg_security_server
6873cc0de1a01ad05ddcbeb3f074a33923dc1ca1
[ "BSD-3-Clause" ]
null
null
null
ndg/security/server/test/config/attributeauthority/sitea/attributeauthorityapp.py
cedadev/ndg_security_server
6873cc0de1a01ad05ddcbeb3f074a33923dc1ca1
[ "BSD-3-Clause" ]
null
null
null
ndg/security/server/test/config/attributeauthority/sitea/attributeauthorityapp.py
cedadev/ndg_security_server
6873cc0de1a01ad05ddcbeb3f074a33923dc1ca1
[ "BSD-3-Clause" ]
1
2017-12-05T17:31:08.000Z
2017-12-05T17:31:08.000Z
#!/usr/bin/env python """NDG Security Attribute Authority test harness for unit test site 'A' NERC Data Grid Project """ __author__ = "P J Kershaw" __date__ = "24/09/08" __copyright__ = "(C) 2009 Science and Technology Facilities Council" __contact__ = "Philip.Kershaw@stfc.ac.uk" __revision__ = "$Id$" from os import ...
33.028169
76
0.557356
#!/usr/bin/env python """NDG Security Attribute Authority test harness for unit test site 'A' NERC Data Grid Project """ __author__ = "P J Kershaw" __date__ = "24/09/08" __copyright__ = "(C) 2009 Science and Technology Facilities Council" __contact__ = "Philip.Kershaw@stfc.ac.uk" __revision__ = "$Id$" from os import ...
0
0
0
0
0
0
0
0
0
688e52d3ed32eaeadd847a7afafdb32a45017795
2,836
py
Python
clients/python/tyckiting_client/ai/stettin.py
CarstenWalther/space-tyckiting
8398f080332c78c7f246289947fdda49558e0f12
[ "MIT" ]
1
2017-02-04T14:13:44.000Z
2017-02-04T14:13:44.000Z
clients/python/tyckiting_client/ai/stettin.py
CarstenWalther/space-tyckiting
8398f080332c78c7f246289947fdda49558e0f12
[ "MIT" ]
null
null
null
clients/python/tyckiting_client/ai/stettin.py
CarstenWalther/space-tyckiting
8398f080332c78c7f246289947fdda49558e0f12
[ "MIT" ]
null
null
null
''' Rules: like robin but in certain situations endangered bots stay and do an other action ''' STAY_PROB = 0.25
34.585366
94
0.627997
import random from tyckiting_client.ai import base from tyckiting_client import actions from tyckiting_client.ai.strategies import pipelineEscaping from tyckiting_client.ai.strategies import scanning from tyckiting_client.ai.strategies import uncertainTracking ''' Rules: like robin but in certain situations endangere...
0
0
0
2,435
0
0
0
129
156
8a8b53191890167d24f5bf11c407382590852801
2,581
py
Python
faces.py
Sxela/PythonSnippets
6a91e2c6080330195aedc04c7b9c36636cb488ff
[ "MIT" ]
null
null
null
faces.py
Sxela/PythonSnippets
6a91e2c6080330195aedc04c7b9c36636cb488ff
[ "MIT" ]
null
null
null
faces.py
Sxela/PythonSnippets
6a91e2c6080330195aedc04c7b9c36636cb488ff
[ "MIT" ]
1
2021-11-20T06:26:19.000Z
2021-11-20T06:26:19.000Z
""" Code related to face detection and manipulation """ #pip install facenet_pytorch from facenet_pytorch import MTCNN mtcnn = MTCNN(image_size=256, margin=80) # simplest ye olde trustworthy MTCNN for face detection with landmarks # my version of isOdd, should make a separate repo for it :D # the actual scaler...
31.096386
118
0.678032
""" Code related to face detection and manipulation """ #pip install facenet_pytorch from facenet_pytorch import MTCNN mtcnn = MTCNN(image_size=256, margin=80) # simplest ye olde trustworthy MTCNN for face detection with landmarks def detect(img): # Detect faces batch_boxes, batch_probs, batch_...
0
0
0
0
0
1,574
0
0
89
719922355fdc1bd4f77e6d2055a74f97ffa8ac71
621
py
Python
src/ansys/templates/python/pyace_flask/{{cookiecutter.__project_name_slug}}/src/blueprints/health.py
pyansys/pyansys-templates
dbbcc7e89c1014bb68e065bf70af30c10ecfadb6
[ "MIT" ]
null
null
null
src/ansys/templates/python/pyace_flask/{{cookiecutter.__project_name_slug}}/src/blueprints/health.py
pyansys/pyansys-templates
dbbcc7e89c1014bb68e065bf70af30c10ecfadb6
[ "MIT" ]
16
2022-03-18T09:17:10.000Z
2022-03-28T06:52:05.000Z
src/ansys/templates/python/pyace_flask/{{cookiecutter.__project_name_slug}}/src/blueprints/health.py
pyansys/ansys-templates
f7def562e23c5c8db51c17d56a7c34f62f77077d
[ "MIT" ]
1
2022-03-16T18:23:12.000Z
2022-03-16T18:23:12.000Z
{%- if cookiecutter.copyright != "None" -%} # Copyright (c) {% now "utc", '%Y' %}, {{ cookiecutter.copyright }}. Unauthorised use, distribution or duplication is prohibited {% endif %} """ {{ cookiecutter.project_name }}. {{ cookiecutter.library_name }} """ from flask import Blueprint, jsonify from observability.log...
25.875
128
0.689211
{%- if cookiecutter.copyright != "None" -%} # Copyright (c) {% now "utc", '%Y' %}, {{ cookiecutter.copyright }}. Unauthorised use, distribution or duplication is prohibited {% endif %} """ {{ cookiecutter.project_name }}. {{ cookiecutter.library_name }} """ from flask import Blueprint, jsonify from observability.log...
0
120
0
0
0
0
0
0
23
6fc60e43f1a5c92d6bfc4dc8ba0dc775c230b8ca
9,953
py
Python
tests/test_news.py
Paule3569/feuersoftware
fe2bc9f71a45d4b9232df8d3fe8d50239c775296
[ "MIT" ]
1
2021-04-29T10:57:48.000Z
2021-04-29T10:57:48.000Z
tests/test_news.py
Paule3569/feuersoftware
fe2bc9f71a45d4b9232df8d3fe8d50239c775296
[ "MIT" ]
null
null
null
tests/test_news.py
Paule3569/feuersoftware
fe2bc9f71a45d4b9232df8d3fe8d50239c775296
[ "MIT" ]
1
2018-08-28T14:30:02.000Z
2018-08-28T14:30:02.000Z
#!/usr/bin/env python #-*- coding: utf-8 -*- import sys import os sys.path.insert(0, os.path.abspath('./')) TOKEN = '2xgRoQfoMGb4IveCDJIZqOO1l8hZZ5jT5mAw7SSk1otrFSq50IA2HIYB3luEpv7Vw8BWwG'\ 'Y2zV96VUkOF3FCZs2OP03qaTWF3CDrUHOKndvLIFTTgx0FCMBTFBRF1DfG4g3rs8BSMHB4'\ '6qph1AlxOZ6parmJlp90V3GQB4EoI6DFdKE4...
40.958848
128
0.683412
#!/usr/bin/env python #-*- coding: utf-8 -*- import sys import os import pytest from mock import patch sys.path.insert(0, os.path.abspath('./')) from feuersoftware import PublicAPI TOKEN = '2xgRoQfoMGb4IveCDJIZqOO1l8hZZ5jT5mAw7SSk1otrFSq50IA2HIYB3luEpv7Vw8BWwG'\ 'Y2zV96VUkOF3FCZs2OP03qaTWF3CDrUHOKndvLIFTTgx...
4
8,823
0
0
0
0
0
7
343
abcd1e3a4b4fa40687d4d76ca3859663c28333f4
1,266
py
Python
strangeflix/provider/migrations/0013_auto_20201027_1642.py
samsoldeinstein/webster2020
9795635e806caa261bb33d629f3d1f2bd603638c
[ "MIT" ]
6
2020-11-02T16:40:56.000Z
2020-11-07T06:59:00.000Z
strangeflix/provider/migrations/0013_auto_20201027_1642.py
samsoldeinstein/webster2020
9795635e806caa261bb33d629f3d1f2bd603638c
[ "MIT" ]
null
null
null
strangeflix/provider/migrations/0013_auto_20201027_1642.py
samsoldeinstein/webster2020
9795635e806caa261bb33d629f3d1f2bd603638c
[ "MIT" ]
2
2020-11-03T05:20:25.000Z
2020-11-03T05:38:47.000Z
# Generated by Django 3.1.2 on 2020-10-27 11:12
38.363636
242
0.629542
# Generated by Django 3.1.2 on 2020-10-27 11:12 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ('provider', '0012_reportc...
0
0
0
1,086
0
0
0
41
90
b831d0118bd1cb0ebd9c4bf798fd205bc356bfe5
4,952
py
Python
result_service_gui/services/dashboard_adapter.py
abdulfahad66/result-service-gui
214342dd6d00f1173bfe90f8429c7d6c9947783b
[ "Apache-2.0" ]
null
null
null
result_service_gui/services/dashboard_adapter.py
abdulfahad66/result-service-gui
214342dd6d00f1173bfe90f8429c7d6c9947783b
[ "Apache-2.0" ]
null
null
null
result_service_gui/services/dashboard_adapter.py
abdulfahad66/result-service-gui
214342dd6d00f1173bfe90f8429c7d6c9947783b
[ "Apache-2.0" ]
null
null
null
"""Module for events adapter.""" import os EVENTS_HOST_SERVER = os.getenv("EVENTS_HOST_SERVER", "localhost") EVENTS_HOST_PORT = os.getenv("EVENTS_HOST_PORT", "8082") EVENT_SERVICE_URL = f"http://{EVENTS_HOST_SERVER}:{EVENTS_HOST_PORT}"
37.515152
86
0.539782
"""Module for events adapter.""" import copy import logging import os from typing import List from aiohttp import ClientSession from aiohttp import hdrs from aiohttp import web from multidict import MultiDict EVENTS_HOST_SERVER = os.getenv("EVENTS_HOST_SERVER", "localhost") EVENTS_HOST_PORT = os.getenv("EVENTS_HOST_P...
0
0
4,350
174
0
0
0
12
178
5dd8c1a13aa126acef031096fe6c5f2daa3b4777
1,726
py
Python
scripts/feots_compare.py
schoonovernumerics/FEOTs
d8bf24d0e0c23a9ee65e2be6a75f5dbc83d3e5ad
[ "BSD-3-Clause" ]
null
null
null
scripts/feots_compare.py
schoonovernumerics/FEOTs
d8bf24d0e0c23a9ee65e2be6a75f5dbc83d3e5ad
[ "BSD-3-Clause" ]
13
2017-08-03T22:30:25.000Z
2019-01-23T16:32:28.000Z
scripts/feots_compare.py
schoonovernumerics/FEOTS
d8bf24d0e0c23a9ee65e2be6a75f5dbc83d3e5ad
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/python3 DOC="""feots_compare feots_compare is use to compare two FEOTS NetCDF output files and report simple statistics. Currently feots_compare will generate a histogram of log_{10}( |f_1 - f_2| ) where f_1 and f_2 are tracer fields from two FEOTS output files. Usage: feots_compare absdiff <file1> <fi...
27.83871
103
0.648899
#!/usr/bin/python3 DOC="""feots_compare feots_compare is use to compare two FEOTS NetCDF output files and report simple statistics. Currently feots_compare will generate a histogram of log_{10}( |f_1 - f_2| ) where f_1 and f_2 are tracer fields from two FEOTS output files. Usage: feots_compare absdiff <file1> <fi...
0
0
0
0
0
870
0
15
157
aee06431ad2ec6bcfc0d5ab724b78f72227eea3a
49,614
py
Python
Scripts/simulation/statistics/ranked_statistic.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
Scripts/simulation/statistics/ranked_statistic.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
Scripts/simulation/statistics/ranked_statistic.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\statistics\ranked_statistic.py # Compiled at: 2020-08-11 17:51:45 # Size of source mod 2**32: 58267 ...
57.892649
781
0.617023
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\statistics\ranked_statistic.py # Compiled at: 2020-08-11 17:51:45 # Size of source mod 2**32: 58267 ...
0
6,753
0
24,053
0
8,626
0
0
995
739d41393a77764cb1e6c4ffc79168adc816618e
280
py
Python
main.py
umutykaya/yelp_business_search_api
aee604733f69b88c94121db652745a8243cd1e6a
[ "MIT" ]
null
null
null
main.py
umutykaya/yelp_business_search_api
aee604733f69b88c94121db652745a8243cd1e6a
[ "MIT" ]
null
null
null
main.py
umutykaya/yelp_business_search_api
aee604733f69b88c94121db652745a8243cd1e6a
[ "MIT" ]
null
null
null
# Import utils submodule import api.api # Decide to start seeing other people api.api.we_need_to_talk(break_up=False) import api # Create instance of MyClass my_instance = api.AppClass(value='class attribute value') # Print out class attribute value print(my_instance.attribute)
25.454545
57
0.807143
# Import utils submodule import api.api # Decide to start seeing other people api.api.we_need_to_talk(break_up=False) import api # Create instance of MyClass my_instance = api.AppClass(value='class attribute value') # Print out class attribute value print(my_instance.attribute)
0
0
0
0
0
0
0
0
0
88257a5631f85a303cf369ae7a877f11db6c90b8
2,642
py
Python
pysptools/examples/ex_hematite_v2.py
ctherien/pysptools
fbcd3ecaa7ab27f0158b28b4327537c3e75db160
[ "Apache-2.0" ]
35
2016-03-20T15:25:07.000Z
2022-03-29T04:05:56.000Z
pysptools/examples/ex_hematite_v2.py
ctherien/pysptools
fbcd3ecaa7ab27f0158b28b4327537c3e75db160
[ "Apache-2.0" ]
12
2016-03-24T13:38:52.000Z
2021-04-06T07:11:19.000Z
pysptools/examples/ex_hematite_v2.py
ctherien/pysptools
fbcd3ecaa7ab27f0158b28b4327537c3e75db160
[ "Apache-2.0" ]
14
2016-03-21T17:26:46.000Z
2022-01-18T08:39:27.000Z
""" Plot a quartz class map for a drill core HSI cube. """ from __future__ import print_function import os import os.path as osp import numpy as np import pysptools.util as util import pysptools.eea as eea if __name__ == '__main__': # Load the cube data_path = os.environ['PYSPTOOLS_...
28.408602
106
0.641938
""" Plot a quartz class map for a drill core HSI cube. """ from __future__ import print_function import os import os.path as osp import matplotlib.pyplot as plt import numpy as np import pysptools.util as util import pysptools.eea as eea import pysptools.abundance_maps as amp def parse_ENVI_header(...
0
0
0
0
0
797
0
27
146
54026340f4cf4ce095dffe423dda6e49920ea4bc
546
py
Python
task/task1.py
SofyaGrobova/lab14
7d0e8b8d56acc9c6b86e9e0303b53762f470be3b
[ "MIT" ]
null
null
null
task/task1.py
SofyaGrobova/lab14
7d0e8b8d56acc9c6b86e9e0303b53762f470be3b
[ "MIT" ]
null
null
null
task/task1.py
SofyaGrobova/lab14
7d0e8b8d56acc9c6b86e9e0303b53762f470be3b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- if __name__ == '__main__': print(func(5, 3)()) print(func(8, 10, 1)()) print(func(3, 5, 0)()) print(func(2, 2, 1)())
21
73
0.47619
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import math def func(a, b, type=0): def func2(): if type == 0: res = a * b / 2 res = f'Для значений {a}, {b} площадь треугольника = {res}' return res elif type == 1: res = a * b res = f'Для ...
124
0
0
0
0
264
0
-10
46
d8d1c0f3e83aa3b5a43247e7f58ad9de5aa9b287
2,477
py
Python
get_premium/tests.py
BarunBlog/Link_People
1ffd07bc5b31a715133c99efbbb478efe18d632b
[ "MIT" ]
null
null
null
get_premium/tests.py
BarunBlog/Link_People
1ffd07bc5b31a715133c99efbbb478efe18d632b
[ "MIT" ]
null
null
null
get_premium/tests.py
BarunBlog/Link_People
1ffd07bc5b31a715133c99efbbb478efe18d632b
[ "MIT" ]
null
null
null
'''from django.contrib.auth import get_user_model from django.test import TestCase #an extension of Pythons TestCase from django.urls import reverse, resolve from django.test import Client from .models import PremiumBlog from .views import ( BlogListView, BlogDetailView, ) class CustomUserTests(TestCas...
30.207317
72
0.644732
'''from django.contrib.auth import get_user_model from django.test import TestCase #an extension of Python’s TestCase from django.urls import reverse, resolve from django.test import Client from .models import PremiumBlog from .views import ( BlogListView, BlogDetailView, ) class CustomUserTests(TestCa...
3
0
0
0
0
0
0
0
0
406e78c5faea77fb778787c685d5a2bd4b6c7a1d
4,208
py
Python
acme/utils/observers/action_metrics_test.py
wookayin/acme
71b2ab8577a118c103718f034fa62c5ad2c0fd97
[ "Apache-2.0" ]
null
null
null
acme/utils/observers/action_metrics_test.py
wookayin/acme
71b2ab8577a118c103718f034fa62c5ad2c0fd97
[ "Apache-2.0" ]
null
null
null
acme/utils/observers/action_metrics_test.py
wookayin/acme
71b2ab8577a118c103718f034fa62c5ad2c0fd97
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 DeepMind Technologies Limited. 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 ...
32.875
77
0.643774
# Copyright 2018 DeepMind Technologies Limited. 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 ...
0
0
0
2,781
0
441
0
25
157
03e5c1084cdb72e0eb5d8f98d04c7100f12e582e
31,595
py
Python
SMPyBandits/Policies/DoublingTrickWrapper.py
balbok0/SMPyBandits
c8ff765687989e0c20ab42c2e2e1d8440923225b
[ "MIT" ]
309
2018-03-03T22:07:59.000Z
2022-03-26T08:15:58.000Z
Policies/DoublingTrickWrapper.py
98k-bot/SMPyBandits
35e675bde29dafbec68288fcfcd14ef3b0f058b2
[ "MIT" ]
125
2018-02-27T22:54:03.000Z
2021-11-05T10:50:15.000Z
Policies/DoublingTrickWrapper.py
98k-bot/SMPyBandits
35e675bde29dafbec68288fcfcd14ef3b0f058b2
[ "MIT" ]
60
2018-04-30T20:54:24.000Z
2022-02-21T22:41:46.000Z
# -*- coding: utf-8 -*- r""" A policy that acts as a wrapper on another policy `P`, assumed to be *horizon dependent* (has to known :math:`T`), by implementing a "doubling trick": - starts to assume that :math:`T=T_0=1000`, and run the policy :math:`P(T_0)`, from :math:`t=1` to :math:`t=T_0`, - if :math:`t > T_0`, the...
47.297904
346
0.65963
# -*- coding: utf-8 -*- r""" A policy that acts as a wrapper on another policy `P`, assumed to be *horizon dependent* (has to known :math:`T`), by implementing a "doubling trick": - starts to assume that :math:`T=T_0=1000`, and run the policy :math:`P(T_0)`, from :math:`t=1` to :math:`t=T_0`, - if :math:`t > T_0`, the...
0
1,191
0
5,877
0
1,441
0
29
397
2fa4bbb8ea840af3c1d5538c76d509d8cce1d549
738
py
Python
LM-1221 intro-python-xml/py-primer-1/concat_sol.py
russellpope/devnet-express-dc
4bdb2194abdee2fc950c2ff20e607aa4af9b68b5
[ "Apache-2.0" ]
null
null
null
LM-1221 intro-python-xml/py-primer-1/concat_sol.py
russellpope/devnet-express-dc
4bdb2194abdee2fc950c2ff20e607aa4af9b68b5
[ "Apache-2.0" ]
null
null
null
LM-1221 intro-python-xml/py-primer-1/concat_sol.py
russellpope/devnet-express-dc
4bdb2194abdee2fc950c2ff20e607aa4af9b68b5
[ "Apache-2.0" ]
null
null
null
myVarRed= "Red" myVarBlue= "Blue" print("Roses are Red. " + "Violets are Blue.") print("Roses are " + myVarRed + ". Violets are " + myVarBlue) myStr = "Roses are Red. " + "Violets are Blue." varStr = "Roses are " + myVarRed + ". Violets are " + myVarBlue print(myStr) print(varStr) name = "Joe" feet= 6 inches= 2 p...
25.448276
94
0.601626
myVarRed= "Red" myVarBlue= "Blue" print("Roses are Red. " + "Violets are Blue.") print("Roses are " + myVarRed + ". Violets are " + myVarBlue) myStr = "Roses are Red. " + "Violets are Blue." varStr = "Roses are " + myVarRed + ". Violets are " + myVarBlue print(myStr) print(varStr) name = "Joe" feet= 6 inches= 2 p...
0
0
0
0
0
0
0
0
0
842007e2d61d97d0fa4ac492f9400db322530dc3
35
py
Python
haul3/haul/platforms/android/__init__.py
hotkeymuc/haul
22533491e3a22ce9fabd81f281282a09880b400c
[ "MIT" ]
2
2021-07-04T13:00:50.000Z
2022-03-19T21:39:06.000Z
haul3/haul/platforms/android/__init__.py
hotkeymuc/haul
22533491e3a22ce9fabd81f281282a09880b400c
[ "MIT" ]
null
null
null
haul3/haul/platforms/android/__init__.py
hotkeymuc/haul
22533491e3a22ce9fabd81f281282a09880b400c
[ "MIT" ]
null
null
null
__all__ = [ 'builder_android', ]
11.666667
20
0.628571
__all__ = [ 'builder_android', ]
0
0
0
0
0
0
0
0
0
353c5aebfd3ddcbd66eae6f02131a97bfbbcb204
168
py
Python
notmuchtask/cli/globals.py
neuhalje/notmuch-task
096231e841b5996c85dd3f50bee02d26989a0505
[ "0BSD", "MIT" ]
7
2019-06-11T10:39:09.000Z
2022-01-18T17:53:33.000Z
notmuchtask/cli/globals.py
neuhalje/notmuch-task
096231e841b5996c85dd3f50bee02d26989a0505
[ "0BSD", "MIT" ]
1
2021-11-03T14:43:27.000Z
2021-11-03T14:43:27.000Z
notmuchtask/cli/globals.py
neuhalje/notmuch-task
096231e841b5996c85dd3f50bee02d26989a0505
[ "0BSD", "MIT" ]
null
null
null
CONTEXT = Context()
16.8
50
0.732143
from configparser import RawConfigParser class Context(object): def set_config(self, config: RawConfigParser): self.config = config CONTEXT = Context()
0
0
0
81
0
0
0
19
45
f7bbd0a87756108eeffd6e1b15b2b36e5c8c7aed
434
py
Python
setup.py
jab/hip
a42c11e6a77190809e37c2337c50b86baca2c9d9
[ "MIT" ]
null
null
null
setup.py
jab/hip
a42c11e6a77190809e37c2337c50b86baca2c9d9
[ "MIT" ]
null
null
null
setup.py
jab/hip
a42c11e6a77190809e37c2337c50b86baca2c9d9
[ "MIT" ]
null
null
null
#!/usr/bin/env python import os import re import unasync # requires pip>=10.0 for PEP 518 support from setuptools import setup # Get the version (borrowed from SQLAlchemy) base_path = os.path.dirname(__file__) with open(os.path.join(base_path, "src", "urllib3", "__init__.py")) as fp: version = re.match(r".*__v...
27.125
78
0.705069
#!/usr/bin/env python import os import re import unasync # requires pip>=10.0 for PEP 518 support from setuptools import setup # Get the version (borrowed from SQLAlchemy) base_path = os.path.dirname(__file__) with open(os.path.join(base_path, "src", "urllib3", "__init__.py")) as fp: version = re.match(r".*__v...
0
0
0
0
0
0
0
0
0
6cbfe283c09e5b6fcb128a6b0257ddfdd443c402
967
py
Python
tests/test_config.py
evanyerburgh/pybo
d26bb298992276949227b8c4c596f2c209cbb507
[ "Apache-2.0" ]
null
null
null
tests/test_config.py
evanyerburgh/pybo
d26bb298992276949227b8c4c596f2c209cbb507
[ "Apache-2.0" ]
null
null
null
tests/test_config.py
evanyerburgh/pybo
d26bb298992276949227b8c4c596f2c209cbb507
[ "Apache-2.0" ]
null
null
null
# coding: utf8
35.814815
112
0.672182
# coding: utf8 from pybo import Config from pathlib import Path def test_config(): config = Config() # default config filename assert config.filename.name == 'pybo.yaml' # config.filename is a Path object # paths for trie content main, custom = config.get_tok_data_paths('POS') # each profil...
0
0
0
0
0
879
0
5
67
c65c404008e35e66385951320b626f514aff10e0
6,971
py
Python
detection_3d/tools/pylatex_tools.py
coolzhangfeng/lidar_dynamic_objects_detection
8d64cc75202208549adef6c854bbb03c2b3c465a
[ "MIT" ]
1
2020-11-07T01:42:12.000Z
2020-11-07T01:42:12.000Z
detection_3d/tools/pylatex_tools.py
coolzhangfeng/lidar_dynamic_objects_detection
8d64cc75202208549adef6c854bbb03c2b3c465a
[ "MIT" ]
null
null
null
detection_3d/tools/pylatex_tools.py
coolzhangfeng/lidar_dynamic_objects_detection
8d64cc75202208549adef6c854bbb03c2b3c465a
[ "MIT" ]
null
null
null
#!/usr/bin/env python __copyright__ = """ Copyright (c) 2020 Tananaev Denis 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, cop...
37.278075
107
0.677091
#!/usr/bin/env python __copyright__ = """ Copyright (c) 2020 Tananaev Denis 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, cop...
0
0
0
0
0
0
0
35
0
37b1f19266734c9c1a9e6de7cf06f8e23a8796a7
3,414
py
Python
yardstick/tests/unit/common/messaging/test_payloads.py
upfront710/yardstick
2c3898f2ca061962cedbfc7435f78b59aa39b097
[ "Apache-2.0" ]
28
2017-02-07T07:46:42.000Z
2021-06-30T08:11:06.000Z
yardstick/tests/unit/common/messaging/test_payloads.py
upfront710/yardstick
2c3898f2ca061962cedbfc7435f78b59aa39b097
[ "Apache-2.0" ]
6
2018-01-18T08:00:54.000Z
2019-04-11T04:51:41.000Z
yardstick/tests/unit/common/messaging/test_payloads.py
upfront710/yardstick
2c3898f2ca061962cedbfc7435f78b59aa39b097
[ "Apache-2.0" ]
46
2016-12-13T10:05:47.000Z
2021-02-18T07:33:06.000Z
# Copyright (c) 2018 Intel Corporation # # 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 i...
41.13253
76
0.702402
# Copyright (c) 2018 Intel Corporation # # 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 i...
0
0
0
2,594
0
0
0
71
159
73f61a2414248de653696a251d78ce78694bfc78
5,258
py
Python
fileprocess/mergefile/filebuf.py
edonyzpc/toolkitem
3a09ebf45eee8ecd9ff0e441392d5fc746b996e5
[ "MIT" ]
3
2015-04-20T08:17:09.000Z
2020-07-07T15:22:06.000Z
fileprocess/mergefile/filebuf.py
edonyzpc/toolkitem
3a09ebf45eee8ecd9ff0e441392d5fc746b996e5
[ "MIT" ]
24
2015-11-14T14:54:59.000Z
2017-10-23T15:14:45.000Z
fileprocess/mergefile/filebuf.py
edonyzpc/toolkitem
3a09ebf45eee8ecd9ff0e441392d5fc746b996e5
[ "MIT" ]
1
2017-02-28T06:35:44.000Z
2017-02-28T06:35:44.000Z
# -*- coding: utf-8 -*- r""" # .---. .----------- # / \ __ / ------ # / / \( )/ ----- (`-') _ _(`-') <-. (`-')_ # ////// '\/ ` --- ( OO).-/( (OO ).-> .-> \( OO) ) .-> # //// / // : : --- (,------. \ .'_ (`-')----. ,...
35.288591
90
0.386649
# -*- coding: utf-8 -*- r""" # .---. .----------- # / \ __ / ------ # / / \( )/ ----- (`-') _ _(`-') <-. (`-')_ # ////// '\/ ` --- ( OO).-/( (OO ).-> .-> \( OO) ) .-> # //// / // : : --- (,------. \ .'_ (`-')----. ,...
0
197
0
3,847
0
0
0
0
45
e82d465500d9c28a0dec8c45feff5a27425e0085
6,085
py
Python
solr-admin-app/solr_admin/views/synonym_view.py
sumesh-aot/namex
53e11aed5ea550b71b7b983f1b57b65db5a06766
[ "Apache-2.0" ]
4
2018-10-05T23:41:05.000Z
2019-06-19T16:17:50.000Z
solr-admin-app/solr_admin/views/synonym_view.py
sumesh-aot/namex
53e11aed5ea550b71b7b983f1b57b65db5a06766
[ "Apache-2.0" ]
635
2018-05-31T04:12:46.000Z
2022-03-31T18:45:42.000Z
solr-admin-app/solr_admin/views/synonym_view.py
rarmitag/namex
1b308bf96130619d4a61d44e075cc7ab177dc6cd
[ "Apache-2.0" ]
71
2018-05-14T20:47:55.000Z
2022-03-31T23:08:30.000Z
# The customized ModelView that is used for working with the synonyms. # Validate the Synonyms Text and ensure it meets our standards. # Check for multi-word synonyms # Only a-z, 0-9, and space are allowed in the synonyms. # Multiple spaces are not allowed. # Duplicate values are not allowed. # Ensure tha...
34.185393
117
0.708463
import re from wtforms import validators from solr_admin import keycloak from solr_admin import models from solr_admin import solr from solr_admin.models import synonym_audit # The customized ModelView that is used for working with the synonyms. from solr_admin.services.get_stems import get_stems from solr_admin.s...
0
0
0
2,300
0
2,694
0
163
400
1af7590f916bd3c3dd5e8addcc07a4b7e95fd3b0
1,963
py
Python
src/sgd.py
jmarrietar/suncet
43868f7863e329e2db94f07e983f547add1bc495
[ "MIT" ]
413
2020-12-01T19:10:19.000Z
2022-03-30T21:03:34.000Z
src/sgd.py
amalbinessa/suncet
731547d727b8c94d06c08a7848b4955de3a70cea
[ "MIT" ]
25
2021-05-03T01:26:39.000Z
2022-03-24T01:13:08.000Z
src/sgd.py
amalbinessa/suncet
731547d727b8c94d06c08a7848b4955de3a70cea
[ "MIT" ]
57
2021-04-30T20:05:42.000Z
2022-02-25T19:01:17.000Z
# Copyright (c) Facebook, Inc. and its affiliates. # All rights reserved. # # This source code is licensed under the license found in the # LICENSE file in the root directory of this source tree. #
32.716667
83
0.532348
# Copyright (c) Facebook, Inc. and its affiliates. # All rights reserved. # # This source code is licensed under the license found in the # LICENSE file in the root directory of this source tree. # import torch from torch.optim import Optimizer class SGD(Optimizer): def __init__(self, params, lr, momentum=0, we...
0
1,024
0
669
0
0
0
3
68
f673acd60723c0325469403a0d884d2a910fe005
1,512
py
Python
ks8-2/server/controllers/todo.py
nabbott2008/ks
888b7dfc4541199f31eef74edaca477f3ce48e6e
[ "MIT" ]
225
2017-11-20T21:21:37.000Z
2022-03-10T14:15:17.000Z
ks8-2/server/controllers/todo.py
cglacet/ks
7e5331218cff0bed4342c0f0318ff91cf2ecbd67
[ "MIT" ]
12
2017-11-23T10:56:11.000Z
2019-09-04T08:19:13.000Z
ks8-2/server/controllers/todo.py
cglacet/ks
7e5331218cff0bed4342c0f0318ff91cf2ecbd67
[ "MIT" ]
93
2017-11-02T09:33:24.000Z
2022-02-28T11:29:01.000Z
'todo list controller' import json from flask import request from flask import jsonify from flask import current_app import data.database as database def list_items(): 'GET todo list' current_app.logger.info('todo controller called, func: list') db = database.Database(current_app.config['CONN_STRING']) ...
24
72
0.666667
'todo list controller' import json from flask import request from flask import jsonify from flask import current_app import data.database as database def list_items(): 'GET todo list' current_app.logger.info('todo controller called, func: list') db = database.Database(current_app.config['CONN_STRING']) ...
0
0
0
0
0
0
0
0
0
c515e211deadee410b0cb9289bd5dd7e0a11e5ad
311
py
Python
models/__init__.py
Louis-udm/Word-Grounded-Graph-Convolutional-Network
4c90bff0ec8bcdd8994154eead0efb5a3caefca7
[ "MIT" ]
null
null
null
models/__init__.py
Louis-udm/Word-Grounded-Graph-Convolutional-Network
4c90bff0ec8bcdd8994154eead0efb5a3caefca7
[ "MIT" ]
null
null
null
models/__init__.py
Louis-udm/Word-Grounded-Graph-Convolutional-Network
4c90bff0ec8bcdd8994154eead0efb5a3caefca7
[ "MIT" ]
null
null
null
""" The model package """ from models.gcn import GCN_2Layers from models.mlp import MLP_1h, MLP_2h from models.wgcn import WGCN, WGCN_embedding_classifier, WGCN_VocabEmbedding __all__ = [ "MLP_1h", "MLP_2h", "GCN_2Layers", "WGCN", "WGCN_embedding_classifier", "WGCN_VocabEmbedding", ]
18.294118
76
0.713826
""" The model package """ from models.gcn import GCN_2Layers from models.mlp import MLP_1h, MLP_2h from models.wgcn import WGCN, WGCN_embedding_classifier, WGCN_VocabEmbedding __all__ = [ "MLP_1h", "MLP_2h", "GCN_2Layers", "WGCN", "WGCN_embedding_classifier", "WGCN_VocabEmbedding", ]
0
0
0
0
0
0
0
0
0
0d9377f8193646dade6cba7c117254caa1149f09
2,746
py
Python
day14/day14.py
andreaskaempf/adventofcode2021
6a72c64e8258cf4e69b5d4602ae194cd27492017
[ "MIT" ]
null
null
null
day14/day14.py
andreaskaempf/adventofcode2021
6a72c64e8258cf4e69b5d4602ae194cd27492017
[ "MIT" ]
null
null
null
day14/day14.py
andreaskaempf/adventofcode2021
6a72c64e8258cf4e69b5d4602ae194cd27492017
[ "MIT" ]
null
null
null
# Advent of Code 2021, Day 14 # # Apply character insertion rules to a sequence of characters, # runs out of memory if you try to build up character strings, # so had to build dictionary of pairs of characters. # # AK, 14/12/2021 import time t0 = time.time() # Input file name f = 'sample.txt' f = 'input.txt' # Read ...
26.403846
76
0.593955
# Advent of Code 2021, Day 14 # # Apply character insertion rules to a sequence of characters, # runs out of memory if you try to build up character strings, # so had to build dictionary of pairs of characters. # # AK, 14/12/2021 import time t0 = time.time() # Input file name f = 'sample.txt' f = 'input.txt' # Read ...
0
0
0
0
0
1,450
0
0
22
45bef6004eaadfa841b8189d4d5bb21998043cc2
9,636
py
Python
train/inflammation-classifier.py
JorisRoels/mri-inflammation-prediction
37e9d0e6f3b0a20a6b35667b1e2741b60280c2a4
[ "MIT" ]
null
null
null
train/inflammation-classifier.py
JorisRoels/mri-inflammation-prediction
37e9d0e6f3b0a20a6b35667b1e2741b60280c2a4
[ "MIT" ]
null
null
null
train/inflammation-classifier.py
JorisRoels/mri-inflammation-prediction
37e9d0e6f3b0a20a6b35667b1e2741b60280c2a4
[ "MIT" ]
null
null
null
''' This script illustrates training of an inflammation classifier for patches along SI joints ''' import argparse import os import shutil from neuralnets.util.io import print_frm from neuralnets.util.tools import set_seed from data.datasets import SPARCCDataset from models.sparcc_cnn import Inflammation_CNN factor ...
50.450262
121
0.642798
''' This script illustrates training of an inflammation classifier for patches along SI joints ''' import argparse import os import shutil import pytorch_lightning as pl from torch.utils.data import DataLoader from neuralnets.util.io import print_frm from neuralnets.util.tools import set_seed from neuralnets.util.augm...
0
0
0
0
0
1,450
0
89
157
fa3a4d39bf525419dd2000248d3378e487b7e58d
51
py
Python
examples/one/rule_1.py
ayushpallav/anthill
740b8fce4281dfc4ca587c21a2d37741c649d870
[ "MIT" ]
14
2020-05-22T20:57:29.000Z
2021-08-19T14:56:32.000Z
examples/one/rule_1.py
ayushpallav/apple-pie
740b8fce4281dfc4ca587c21a2d37741c649d870
[ "MIT" ]
2
2021-01-04T05:05:08.000Z
2021-01-04T05:11:08.000Z
examples/one/rule_1.py
ayushpallav/apple-pie
740b8fce4281dfc4ca587c21a2d37741c649d870
[ "MIT" ]
null
null
null
print("-----------------rule_1------------------")
25.5
50
0.215686
print("-----------------rule_1------------------")
0
0
0
0
0
0
0
0
0
0cd13ee9792d2b275510c09e2c2a14904a1130ee
456
py
Python
web/flask_test/flask_test.py
nciefeiniu/python-test
d81fcfff8cdec724c3010d6b7a77aabad7f90595
[ "Apache-2.0" ]
null
null
null
web/flask_test/flask_test.py
nciefeiniu/python-test
d81fcfff8cdec724c3010d6b7a77aabad7f90595
[ "Apache-2.0" ]
null
null
null
web/flask_test/flask_test.py
nciefeiniu/python-test
d81fcfff8cdec724c3010d6b7a77aabad7f90595
[ "Apache-2.0" ]
null
null
null
from flask import Flask app = Flask(__name__) if __name__ == '__main__': app.run()
20.727273
54
0.690789
from flask import Flask from flask import render_template app = Flask(__name__) @app.route('/hello/<name>') def hello_world(name): return render_template('hello.html', name=name) @app.route('/user/<username>', methods=['POST','GET']) def show_user_profile(username): # show the user profile for that user ...
0
263
0
0
0
0
0
12
91
d96b97a3673f37466a8c9eb623e60075bc2cd115
3,727
py
Python
tests/propagators/test_binary_propagator.py
rlopes-ki/python-sensor
07e827f9982b2a0c482e8eab82d1a420923efd5e
[ "MIT" ]
61
2017-09-27T02:50:17.000Z
2022-03-22T12:13:37.000Z
tests/propagators/test_binary_propagator.py
rlopes-ki/python-sensor
07e827f9982b2a0c482e8eab82d1a420923efd5e
[ "MIT" ]
82
2017-07-11T13:47:33.000Z
2022-03-22T10:10:38.000Z
tests/propagators/test_binary_propagator.py
rlopes-ki/python-sensor
07e827f9982b2a0c482e8eab82d1a420923efd5e
[ "MIT" ]
27
2017-09-11T16:22:32.000Z
2022-03-11T17:21:49.000Z
# (c) Copyright IBM Corp. 2021 # (c) Copyright Instana Inc. 2021
51.054795
114
0.622485
# (c) Copyright IBM Corp. 2021 # (c) Copyright Instana Inc. 2021 from instana.propagators.binary_propagator import BinaryPropagator from instana.span_context import SpanContext import unittest class TestBinaryPropagator(unittest.TestCase): def setUp(self): self.bp = BinaryPropagator() def test_injec...
0
0
0
3,510
0
0
0
62
90
0e2ca74fbdb064638c6b006fa12bbc8faacd1af7
618
py
Python
pyBoard v1.1(STM32F405)/3.拓展实验/2.RGB灯带/main.py
01studio-lab/MicroPython_Examples
f06a1bee398674ceafebed2aac88d8413cc8abad
[ "MIT" ]
73
2020-05-02T13:48:27.000Z
2022-03-26T13:15:10.000Z
pyBoard v1.1(STM32F405)/3.拓展实验/2.RGB灯带/main.py
01studio-lab/MicroPython_Examples
f06a1bee398674ceafebed2aac88d8413cc8abad
[ "MIT" ]
null
null
null
pyBoard v1.1(STM32F405)/3.拓展实验/2.RGB灯带/main.py
01studio-lab/MicroPython_Examples
f06a1bee398674ceafebed2aac88d8413cc8abad
[ "MIT" ]
50
2020-05-15T13:57:28.000Z
2022-03-30T14:03:33.000Z
''' RGB v1.0 2019.7 01Studio RGB ''' from ws2812 import WS2812 from machine import Pin import pyb #Y11 LED = Pin('Y11',Pin.OUT,value=0) #RGB, strip = WS2812(spi_bus=LED, led_count=30) #,led_count #RGB strip.show(fill_color(EMPTY)) while True: strip.show(fill_color(RED)) pyb.delay(1000) strip.show(fi...
15.073171
41
0.699029
''' 实验名称:RGB灯带 版本:v1.0 日期:2019.7 作者:01Studio 说明:RGB灯带控制。 ''' from ws2812 import WS2812 from colors import * from machine import Pin import pyb #定义灯带连接引脚,Y11接口 LED = Pin('Y11',Pin.OUT,value=0) #构建RGB灯带对象,定义控制引脚和灯珠数量 strip = WS2812(spi_bus=LED, led_count=30) #灯带填色函数,灯珠数量为led_count def fill_color(color): data=[] ...
207
0
0
0
0
94
0
-1
44
fcccc0b2a1e1b7db9084f5867072305324db2292
5,307
py
Python
test/test_prettyprinter.py
plotnick/prettyprinter
edde630011ad5eada6476366a2b2da422f4a9d74
[ "MIT" ]
null
null
null
test/test_prettyprinter.py
plotnick/prettyprinter
edde630011ad5eada6476366a2b2da422f4a9d74
[ "MIT" ]
null
null
null
test/test_prettyprinter.py
plotnick/prettyprinter
edde630011ad5eada6476366a2b2da422f4a9d74
[ "MIT" ]
null
null
null
from __future__ import with_statement import unittest if __name__ == "__main__": unittest.main()
34.914474
80
0.44658
from __future__ import with_statement import unittest from cStringIO import StringIO from format import format from prettyprinter import * from bindings import bindings import printervars class PrettyPrinterTest(unittest.TestCase): roads = ["Elm", "Cottonwood"] town = ["Boston"] def ppEquals(self, result,...
0
0
0
5,048
0
0
0
24
133
d520b024353774f21173e09b7db4a18cc61c1f22
11,522
py
Python
updates.py
stephenangelico/shed
9df18b1681366c1add9de0ec1abb4b85e1c99300
[ "MIT" ]
12
2015-01-12T15:44:46.000Z
2020-07-10T06:35:36.000Z
updates.py
stephenangelico/shed
9df18b1681366c1add9de0ec1abb4b85e1c99300
[ "MIT" ]
2
2021-11-06T02:09:30.000Z
2022-01-23T07:22:09.000Z
updates.py
stephenangelico/shed
9df18b1681366c1add9de0ec1abb4b85e1c99300
[ "MIT" ]
8
2016-10-12T20:17:10.000Z
2022-03-26T08:18:34.000Z
#!/usr/bin/python3 # requires system Python and the python3-apt package import textwrap from collections import OrderedDict # Starting with Python 3.7, we could just use vanilla dicts import apt # ImportError? apt install python3-apt HELP_INFO = """Top-level package manager This tool lists all packages that aren't ma...
41.297491
126
0.67523
#!/usr/bin/python3 # requires system Python and the python3-apt package import textwrap from collections import OrderedDict # Starting with Python 3.7, we could just use vanilla dicts import apt # ImportError? apt install python3-apt def describe(pkg): # Python 3.7 equivalent: # return {"Name": pkg.name, "Installed"...
0
0
0
0
0
1,846
0
0
115
e2c8923a8f3465ac1f6e6f808251f566f4c248ff
4,987
py
Python
model.py
govinsprabhu/Behavioral_Cloning
6b4bf27e6669707824aaa73b83b8da9e5a1d18b8
[ "MIT" ]
null
null
null
model.py
govinsprabhu/Behavioral_Cloning
6b4bf27e6669707824aaa73b83b8da9e5a1d18b8
[ "MIT" ]
null
null
null
model.py
govinsprabhu/Behavioral_Cloning
6b4bf27e6669707824aaa73b83b8da9e5a1d18b8
[ "MIT" ]
null
null
null
from sklearn.model_selection import train_test_split lines = [] path = 'C:/Users/609600403/Documents/ML/project/CarND-Behavioral-Cloning-P3-master/data/' # loading the image paths from csv lines = get_data(path) print(len(lines)) # Splitting train and validation ,used 20% of data for validation train_samples, va...
35.119718
173
0.648286
import csv import cv2 import numpy as np from keras.models import Sequential, load_model from keras.layers import Flatten, Dense, Lambda, Cropping2D, Dropout from keras.layers.convolutional import Conv2D from sklearn.model_selection import train_test_split from sklearn.utils import shuffle lines = [] def get_data(p...
0
0
0
0
2,025
1,700
0
84
223
f7907661b240e64761abf5f915f0c3ced1efa2dc
8,462
py
Python
sharper/flaskapp/helper.py
sluggard6/bgirl
3c9fa895189ef16442694830d0c05cf60ee5187b
[ "Apache-2.0" ]
null
null
null
sharper/flaskapp/helper.py
sluggard6/bgirl
3c9fa895189ef16442694830d0c05cf60ee5187b
[ "Apache-2.0" ]
null
null
null
sharper/flaskapp/helper.py
sluggard6/bgirl
3c9fa895189ef16442694830d0c05cf60ee5187b
[ "Apache-2.0" ]
null
null
null
# -*- coding:utf-8 -*- """ flskapp/helper.py ~~~~~~~~~~~~~~ Flask """ from sharper.util.string import random_number from flask import get_flashed_messages, request, current_app __authors__ = ['"linnchord gao" <linnchord@gmail.com>'] def get_flash_msg(_type=None, joiner=' '): """ flash @_typ...
24.527536
107
0.60494
# -*- coding:utf-8 -*- """ flskapp/helper.py ~~~~~~~~~~~~~~ Flask框架帮助方法 """ import os from random import randint import traceback import urllib2 from sharper.util.string import random_number from flask import get_flashed_messages, request, jsonify, current_app, logging, session import sys from ..lib.error ...
1,071
0
0
0
0
3,805
0
40
750
95ceeda69677ea47c26fa6c65cda51757e65fe34
10,410
py
Python
src/modify_log.py
mattiafrak/Processes-Predictions-with-MP-A-Priori-Knowledge
7e1bb94bb2fc535972a351f543be4f0ad8475275
[ "MIT" ]
null
null
null
src/modify_log.py
mattiafrak/Processes-Predictions-with-MP-A-Priori-Knowledge
7e1bb94bb2fc535972a351f543be4f0ad8475275
[ "MIT" ]
null
null
null
src/modify_log.py
mattiafrak/Processes-Predictions-with-MP-A-Priori-Knowledge
7e1bb94bb2fc535972a351f543be4f0ad8475275
[ "MIT" ]
null
null
null
""" Here timestamps are updated in order to have elapsed times following a particular pattern/rule Author: Mattia Fraccaro """
47.534247
173
0.397214
""" Here timestamps are updated in order to have elapsed times following a particular pattern/rule Author: Mattia Fraccaro """ import csv import time from datetime import datetime, timedelta from random import * class ModifyLog: log_name = '50x5_3W' difflist = [] timestamps_list = [] csvfile = open...
0
0
0
10,173
0
0
0
-3
112
555ed55160246b66953bd0e607e4ba2a8294241c
4,630
py
Python
bq_data_access/v1/pairwise.py
isb-cgc/ISB-CGC-Webapp
52ed5366ee295e938108a4687bad551a8dee6b34
[ "Apache-2.0" ]
13
2016-01-14T02:43:10.000Z
2020-11-25T20:43:05.000Z
bq_data_access/v1/pairwise.py
isb-cgc/ISB-CGC-Webapp
52ed5366ee295e938108a4687bad551a8dee6b34
[ "Apache-2.0" ]
84
2015-11-20T02:03:33.000Z
2021-10-14T19:24:24.000Z
bq_data_access/v1/pairwise.py
isb-cgc/ISB-CGC-Webapp
52ed5366ee295e938108a4687bad551a8dee6b34
[ "Apache-2.0" ]
5
2015-11-25T19:29:53.000Z
2019-09-04T17:37:52.000Z
# # Copyright 2015-2019, Institute for Systems Biology # # 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 ...
31.712329
88
0.649892
# # Copyright 2015-2019, Institute for Systems Biology # # 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 ...
0
3,217
0
286
0
0
0
112
246
100c4a9136eb4bb23e2157a31502b9018a9a3418
17,040
py
Python
tickettemplate/ttadmin.py
t-kenji/trac-ticket-template-plugin
71f58052eb555393922da0d8295454cad6a3bce0
[ "BSD-3-Clause" ]
null
null
null
tickettemplate/ttadmin.py
t-kenji/trac-ticket-template-plugin
71f58052eb555393922da0d8295454cad6a3bce0
[ "BSD-3-Clause" ]
null
null
null
tickettemplate/ttadmin.py
t-kenji/trac-ticket-template-plugin
71f58052eb555393922da0d8295454cad6a3bce0
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (C) 2008-2013 Richard Liao <richard.liao.i@gmail.com> # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # from __future__ import with_statement from trac.util.translation import dom...
33.742574
83
0.564906
# -*- coding: utf-8 -*- # # Copyright (C) 2008-2013 Richard Liao <richard.liao.i@gmail.com> # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # from __future__ import with_statement import inspect import textwrap impor...
0
0
0
15,691
0
0
0
404
426
79f1e8f31fc56c489b60eecbe30ff8b8e3035435
1,383
py
Python
test-sum.py
eliteraspberries/python-libnu
869945fc3f0d4c7ebbc9a4e66f3aa6700472b0f3
[ "0BSD" ]
null
null
null
test-sum.py
eliteraspberries/python-libnu
869945fc3f0d4c7ebbc9a4e66f3aa6700472b0f3
[ "0BSD" ]
null
null
null
test-sum.py
eliteraspberries/python-libnu
869945fc3f0d4c7ebbc9a4e66f3aa6700472b0f3
[ "0BSD" ]
null
null
null
#!/usr/bin/env python import functools import numpy import hypothesis import hypothesis.extra.numpy import hypothesis.strategies arrays = functools.partial( hypothesis.extra.numpy.arrays, dtype=numpy.float32, unique=True, ) floats = hypothesis.strategies.floats(-1.0, 1.0) numpy.zeros = functools.partial(...
23.844828
65
0.677513
#!/usr/bin/env python import functools import numpy import hypothesis import hypothesis.extra.numpy import hypothesis.strategies import libnu.sum from test import eq arrays = functools.partial( hypothesis.extra.numpy.arrays, dtype=numpy.float32, unique=True, ) floats = hypothesis.strategies.floats(-1.0...
0
799
0
0
0
0
0
-7
138
4909075b90f779efa0cc283e1cf15a85409c64e5
1,003
py
Python
pycodegen/frontend/frontend_cpp/__init__.py
blejdfist/pycodegen
b7a7fad2c9e0a537893e53df0e07544d047e443d
[ "MIT" ]
5
2019-02-15T16:13:43.000Z
2021-07-22T02:54:57.000Z
pycodegen/frontend/frontend_cpp/__init__.py
blejdfist/pycodegen
b7a7fad2c9e0a537893e53df0e07544d047e443d
[ "MIT" ]
1
2019-12-06T20:24:36.000Z
2020-05-04T18:43:12.000Z
pycodegen/frontend/frontend_cpp/__init__.py
blejdfist/pycodegen
b7a7fad2c9e0a537893e53df0e07544d047e443d
[ "MIT" ]
null
null
null
"""C/C++ parser frontend based on libclang""" import logging _LOGGER = logging.getLogger(__name__)
27.861111
86
0.65005
"""C/C++ parser frontend based on libclang""" import argparse import logging import sys _LOGGER = logging.getLogger(__name__) def register_arguments(argument_parser): argument_parser.add_argument("--args", nargs=argparse.REMAINDER, help="Arguments to pass to clang") argument...
0
0
0
0
0
828
0
-17
90
4ef3ac76c9db1a0b2024af4c2263d9bea69f7d99
1,773
py
Python
pgscout/ScoutGuard.py
SuspectJohnny/PGScout
35e3209b681942977be82544616d8dd4a5262574
[ "Apache-2.0" ]
null
null
null
pgscout/ScoutGuard.py
SuspectJohnny/PGScout
35e3209b681942977be82544616d8dd4a5262574
[ "Apache-2.0" ]
null
null
null
pgscout/ScoutGuard.py
SuspectJohnny/PGScout
35e3209b681942977be82544616d8dd4a5262574
[ "Apache-2.0" ]
null
null
null
import logging log = logging.getLogger(__name__)
31.660714
118
0.599549
import logging import sys import time from pgscout.Scout import Scout from pgscout.config import use_pgpool from pgscout.utils import load_pgpool_accounts log = logging.getLogger(__name__) class ScoutGuard(object): def __init__(self, auth, username, password, job_queue): self.job_queue = job_queue ...
0
0
0
1,558
0
0
0
30
134
3fadd272a1dd660ba3aac05b14b52bd48175a9ea
4,027
py
Python
am/legislative/schema.py
access-missouri/am-django-project
2457b8089900c61c73000c1d7479b7a72f6d1855
[ "BSD-2-Clause" ]
4
2018-05-01T20:31:49.000Z
2021-12-20T19:30:40.000Z
am/legislative/schema.py
access-missouri/am-django-project
2457b8089900c61c73000c1d7479b7a72f6d1855
[ "BSD-2-Clause" ]
22
2017-04-13T15:02:09.000Z
2021-02-02T21:48:41.000Z
am/legislative/schema.py
access-missouri/am-django-project
2457b8089900c61c73000c1d7479b7a72f6d1855
[ "BSD-2-Clause" ]
1
2018-07-02T20:08:43.000Z
2018-07-02T20:08:43.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*-
35.955357
82
0.627514
#!/usr/bin/env python # -*- coding: utf-8 -*- from graphene import relay, ObjectType, String from graphene_django.types import DjangoObjectType from graphene_django.filter import DjangoFilterConnectionField from legislative import models as LM class BillNode(DjangoObjectType): absolute_url = String() admin_url...
0
0
0
3,641
0
0
0
110
226
d1cc6225724878d5dd3d8e4214d652acbfc7f11c
1,123
py
Python
techminer2/most_local_cited_authors.py
jdvelasq/techminer2
ad64a49402749755798a18417c38a7ad10e83bad
[ "MIT" ]
null
null
null
techminer2/most_local_cited_authors.py
jdvelasq/techminer2
ad64a49402749755798a18417c38a7ad10e83bad
[ "MIT" ]
null
null
null
techminer2/most_local_cited_authors.py
jdvelasq/techminer2
ad64a49402749755798a18417c38a7ad10e83bad
[ "MIT" ]
null
null
null
""" Most local cited authors in references =============================================================================== See :doc:`column indicators <column_indicators>` to obtain a `pandas.Dataframe` with the data. Use the following code: .. code:: python column_indicators( column="authors", ...
22.019608
109
0.606411
""" Most local cited authors in references =============================================================================== See :doc:`column indicators <column_indicators>` to obtain a `pandas.Dataframe` with the data. Use the following code: .. code:: python column_indicators( column="authors", ...
0
0
0
0
0
312
0
23
45
d4d4167b896d5de17790ec88ba387137143b6306
1,890
py
Python
scripts/networks_theoretical_bounds_analysis.py
PuchatekwSzortach/voc_ssd
4bf1013c5243b5a76e4c1a392c8d1c3076c72a90
[ "MIT" ]
1
2020-01-22T07:13:12.000Z
2020-01-22T07:13:12.000Z
scripts/networks_theoretical_bounds_analysis.py
PuchatekwSzortach/voc_ssd
4bf1013c5243b5a76e4c1a392c8d1c3076c72a90
[ "MIT" ]
null
null
null
scripts/networks_theoretical_bounds_analysis.py
PuchatekwSzortach/voc_ssd
4bf1013c5243b5a76e4c1a392c8d1c3076c72a90
[ "MIT" ]
1
2021-11-10T22:02:36.000Z
2021-11-10T22:02:36.000Z
""" Script for analyzing theoretical bounds on model's recall """ import argparse import sys import yaml import tqdm import net.data import net.ssd import net.utilities def analyse_theoretical_performance(config, ssd_model_configuration): """ Analyse theoretical performance of SSD model on VOC dataset ...
26.25
112
0.732804
""" Script for analyzing theoretical bounds on model's recall """ import argparse import sys import yaml import tqdm import net.data import net.ssd import net.utilities def analyse_theoretical_performance(config, ssd_model_configuration): """ Analyse theoretical performance of SSD model on VOC dataset ...
0
0
0
0
0
0
0
0
0
f4ca648ec083b50f3ce5b91759643c2cf7dca9fa
16,182
py
Python
examples/lidar_tour_traffic_data_analysis.py
MissMeriel/BeamNGpy
a8467c57537441802bc5b56f0012dfee2b5f5af0
[ "MIT" ]
1
2021-08-10T19:29:52.000Z
2021-08-10T19:29:52.000Z
examples/lidar_tour_traffic_data_analysis.py
MissMeriel/BeamNGpy
a8467c57537441802bc5b56f0012dfee2b5f5af0
[ "MIT" ]
null
null
null
examples/lidar_tour_traffic_data_analysis.py
MissMeriel/BeamNGpy
a8467c57537441802bc5b56f0012dfee2b5f5af0
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt # format data for dataframe if __name__ == '__main__': main()
38.165094
131
0.559016
import sys from time import sleep import numpy as np from beamngpy.beamngcommon import * import time import random, copy import math import matplotlib.pyplot as plt from matplotlib.pyplot import figure from matplotlib.pyplot import imshow import pandas as pd import seaborn as sn import matplotlib.pyplot as plt from sci...
0
0
0
0
0
15,364
0
21
695
ab2dbea6e1fc2af0c93dae92cb5a85ec8dcd206c
974
py
Python
flask/app.py
apple800/python_study
29864a6b4389d47c5d59f6459bee7c7fd09cceb5
[ "MIT" ]
null
null
null
flask/app.py
apple800/python_study
29864a6b4389d47c5d59f6459bee7c7fd09cceb5
[ "MIT" ]
null
null
null
flask/app.py
apple800/python_study
29864a6b4389d47c5d59f6459bee7c7fd09cceb5
[ "MIT" ]
null
null
null
from flask import Flask # Init app app = Flask(__name__) db = [] # URI, endpoint # Update list # @app.route('/update/<task>', methods=['GET']) # def update(task): # num = db.index(task) # text = '' # db[num] = text # return redirect(url_for('main')) if __name__ == '__main__': # Only in dev...
21.644444
68
0.603696
from flask import Flask, render_template, request, redirect, url_for # Init app app = Flask(__name__) db = [] # URI, endpoint @app.route('/', methods=['GET', 'POST']) def main(): if request.method == 'POST': new_task = request.form['new_task'] modify_task = request.form['mo'] num = reque...
6
529
0
0
0
0
0
45
45
fbea0d257d3da6c82d0b9bbeaff1d1aaf62a8831
795
py
Python
neodroid/messaging/__init__.py
sintefneodroid/neo
0999f1dff95c4a8c5880a9b3add532d74f38586a
[ "Apache-2.0" ]
7
2017-09-13T08:28:37.000Z
2022-01-21T15:59:14.000Z
neodroid/messaging/__init__.py
sintefneodroid/neo
0999f1dff95c4a8c5880a9b3add532d74f38586a
[ "Apache-2.0" ]
25
2019-03-25T13:49:43.000Z
2019-05-02T13:58:13.000Z
neodroid/messaging/__init__.py
sintefneodroid/neo
0999f1dff95c4a8c5880a9b3add532d74f38586a
[ "Apache-2.0" ]
2
2017-09-21T10:14:39.000Z
2017-10-21T09:57:04.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = "Christian Heider Nielsen"
25.645161
56
0.631447
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = "Christian Heider Nielsen" import logging from enum import Enum, auto from functools import wraps class ClientEvents(Enum): CONNECTED = auto() DISCONNECTED = auto() TIMEOUT = auto() def message_client_event(event): def receive_func(func): ...
0
394
0
74
0
120
0
5
113
ce27e0fd1a63289b96eec99e747558875b354786
88
py
Python
P3_9.py
JosefinaMedina/EjerciciosComputacion-Python
98f04171ce954e4eb9b20adfc98b0351e6016deb
[ "Apache-2.0" ]
null
null
null
P3_9.py
JosefinaMedina/EjerciciosComputacion-Python
98f04171ce954e4eb9b20adfc98b0351e6016deb
[ "Apache-2.0" ]
null
null
null
P3_9.py
JosefinaMedina/EjerciciosComputacion-Python
98f04171ce954e4eb9b20adfc98b0351e6016deb
[ "Apache-2.0" ]
null
null
null
import numpy as np n=int(input("Dimension de la matriz: ")) print(np.identity(n))
17.6
41
0.670455
import numpy as np n=int(input("Dimension de la matriz: ")) print(np.identity(n))
0
0
0
0
0
0
0
0
0
02e08aa2c67dd5c15617f863e1ff3ce9467f1dfd
2,557
py
Python
src/horner.py
dhermes/k-compensated-de-casteljau
8511f0c2c525ac24215f6307e80032329f97301d
[ "Apache-2.0" ]
2
2020-02-22T15:45:20.000Z
2020-12-03T07:56:01.000Z
src/horner.py
dhermes/k-compensated-de-casteljau
8511f0c2c525ac24215f6307e80032329f97301d
[ "Apache-2.0" ]
null
null
null
src/horner.py
dhermes/k-compensated-de-casteljau
8511f0c2c525ac24215f6307e80032329f97301d
[ "Apache-2.0" ]
null
null
null
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under t...
22.628319
74
0.594056
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under t...
0
0
0
0
0
1,471
0
-11
138
4b5221cd58c1dfa6507ede60d4aff71e4b131d0f
248
py
Python
datalad/plugin/wtf.py
mikapfl/datalad
7b407ecbbfbbea0789304a640bac721d1718e72d
[ "MIT" ]
298
2015-01-25T17:36:29.000Z
2022-03-20T03:38:47.000Z
datalad/plugin/wtf.py
mikapfl/datalad
7b407ecbbfbbea0789304a640bac721d1718e72d
[ "MIT" ]
6,387
2015-01-02T18:15:01.000Z
2022-03-31T20:58:58.000Z
datalad/plugin/wtf.py
mikapfl/datalad
7b407ecbbfbbea0789304a640bac721d1718e72d
[ "MIT" ]
109
2015-01-25T17:49:40.000Z
2022-03-06T06:54:54.000Z
import warnings warnings.warn( "datalad.plugin.wtf is deprecated and will be removed in a future " "release. " "Use the module from its new location datalad.local.wtf instead.", DeprecationWarning)
24.8
71
0.729839
import warnings warnings.warn( "datalad.plugin.wtf is deprecated and will be removed in a future " "release. " "Use the module from its new location datalad.local.wtf instead.", DeprecationWarning) from datalad.local.wtf import *
0
0
0
0
0
0
0
10
23
f658e8ccbd73923fbc6b2c597d99bc868e8e814c
22,841
py
Python
flopy/modflow/mfoc.py
langevin/flopy
2398a0b9a9294b4e2fb5c7e0228f0f42af45b80a
[ "BSD-3-Clause" ]
null
null
null
flopy/modflow/mfoc.py
langevin/flopy
2398a0b9a9294b4e2fb5c7e0228f0f42af45b80a
[ "BSD-3-Clause" ]
null
null
null
flopy/modflow/mfoc.py
langevin/flopy
2398a0b9a9294b4e2fb5c7e0228f0f42af45b80a
[ "BSD-3-Clause" ]
null
null
null
""" mfoc module. Contains the ModflowOc class. Note that the user can access the ModflowOc class as `flopy.modflow.ModflowOc`. Additional information for this MODFLOW package can be found at the `Online MODFLOW Guide <http://water.usgs.gov/ogw/modflow/MODFLOW-2005-Guide/index.html?oc.htm>`_. """
39.585789
114
0.467668
""" mfoc module. Contains the ModflowOc class. Note that the user can access the ModflowOc class as `flopy.modflow.ModflowOc`. Additional information for this MODFLOW package can be found at the `Online MODFLOW Guide <http://water.usgs.gov/ogw/modflow/MODFLOW-2005-Guide/index.html?oc.htm>`_. """ import sy...
0
12,388
0
10,074
0
0
0
-1
72
8349256563b8b4c78b3b7cdafe91df9d453f14f3
119
py
Python
inz/schemas.py
matbur/inz
f6be1a685761f99f8c808d8b23f58debf7e19da2
[ "MIT" ]
null
null
null
inz/schemas.py
matbur/inz
f6be1a685761f99f8c808d8b23f58debf7e19da2
[ "MIT" ]
2
2020-03-24T16:35:39.000Z
2020-03-31T00:33:08.000Z
inz/schemas.py
matbur/inz
f6be1a685761f99f8c808d8b23f58debf7e19da2
[ "MIT" ]
null
null
null
from typing import List NeuronSchema = List[float] LayerSchema = List[NeuronSchema] NetworkSchema = List[LayerSchema]
19.833333
33
0.806723
from typing import List NeuronSchema = List[float] LayerSchema = List[NeuronSchema] NetworkSchema = List[LayerSchema]
0
0
0
0
0
0
0
0
0
b181d0030ad8cc4abf4c2b847f5e8fba3ba43456
3,497
py
Python
Programs/MP2/MP2_NUMPY/mp2.py
dgasmith/SICM2-Software-Summer-School-2014
af97770cbade3bf4a246f21e607e8be66c9df7da
[ "MIT" ]
2
2015-07-16T14:00:27.000Z
2016-01-10T20:21:48.000Z
Programs/MP2/MP2_NUMPY/mp2.py
dgasmith/SICM2-Software-Summer-School-2014
af97770cbade3bf4a246f21e607e8be66c9df7da
[ "MIT" ]
null
null
null
Programs/MP2/MP2_NUMPY/mp2.py
dgasmith/SICM2-Software-Summer-School-2014
af97770cbade3bf4a246f21e607e8be66c9df7da
[ "MIT" ]
null
null
null
# # Author: Daniel G. A. Smith # Created: 6/15/14 # Original content from: # http://sirius.chem.vt.edu/wiki/doku.php?id=crawdad:programming # import numpy as np from scipy import linalg as SLA #Setup a few constats for the HF computation nuclear = 8.002367061810450 ndocc = 5 print 'Reading in integrals...' # Read i...
22.707792
94
0.592222
# # Author: Daniel G. A. Smith # Created: 6/15/14 # Original content from: # http://sirius.chem.vt.edu/wiki/doku.php?id=crawdad:programming # import numpy as np from scipy import linalg as SLA #Setup a few constats for the HF computation nuclear = 8.002367061810450 ndocc = 5 print 'Reading in integrals...' # Read i...
0
0
0
0
0
269
0
0
23
3863ce9f8d10cfb3ae982a92420729f09cb0102c
4,727
py
Python
pyrobolearn/models/dmp/rhythmic_dmp.py
Pandinosaurus/pyrobolearn
9cd7c060723fda7d2779fa255ac998c2c82b8436
[ "Apache-2.0" ]
2
2021-01-21T21:08:30.000Z
2022-03-29T16:45:49.000Z
pyrobolearn/models/dmp/rhythmic_dmp.py
Pandinosaurus/pyrobolearn
9cd7c060723fda7d2779fa255ac998c2c82b8436
[ "Apache-2.0" ]
null
null
null
pyrobolearn/models/dmp/rhythmic_dmp.py
Pandinosaurus/pyrobolearn
9cd7c060723fda7d2779fa255ac998c2c82b8436
[ "Apache-2.0" ]
1
2020-09-29T21:25:39.000Z
2020-09-29T21:25:39.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """Define the rhythmic dynamic movement primitive. """ __author__ = "Brian Delhaisse" __copyright__ = "Copyright 2018, PyRoboLearn" __credits__ = ["Brian Delhaisse"] __license__ = "GNU GPLv3" __version__ = "1.0.0" __maintainer__ = "Brian Delhaisse" __email__ = "briandelhai...
41.104348
118
0.649672
#!/usr/bin/env python # -*- coding: utf-8 -*- """Define the rhythmic dynamic movement primitive. """ import numpy as np from pyrobolearn.models.dmp.canonical_systems import RhythmicCS from pyrobolearn.models.dmp.forcing_terms import RhythmicForcingTerm from pyrobolearn.models.dmp.dmp import DMP __author__ = "Brian D...
0
0
0
4,144
0
0
0
107
113
f435c309888d9e68dc96f1aa6e903d696c5cca03
656
py
Python
xblock/test/test_fragment.py
cclauss/XBlock
3e5341015e8f8b4a203ac4a41471bac5549182b0
[ "Apache-2.0" ]
null
null
null
xblock/test/test_fragment.py
cclauss/XBlock
3e5341015e8f8b4a203ac4a41471bac5549182b0
[ "Apache-2.0" ]
null
null
null
xblock/test/test_fragment.py
cclauss/XBlock
3e5341015e8f8b4a203ac4a41471bac5549182b0
[ "Apache-2.0" ]
null
null
null
""" Unit tests for the Fragment class. Note: this class has been deprecated in favor of web_fragments.fragment.Fragment """ from __future__ import absolute_import, division, print_function, unicode_literals
25.230769
82
0.690549
""" Unit tests for the Fragment class. Note: this class has been deprecated in favor of web_fragments.fragment.Fragment """ from __future__ import absolute_import, division, print_function, unicode_literals from unittest import TestCase from xblock.fragment import Fragment class TestFragment(TestCase): """ ...
0
0
0
354
0
0
0
23
69
c6bcb780f95fe8ae4a95bc9a59ae2ad9f8b29924
8,244
py
Python
eval/cls_eval.py
EthanZhangYC/invariance-equivariance
6e369fd6f43c6b217740f7acd9533c298c43d360
[ "MIT" ]
24
2021-04-21T09:35:23.000Z
2022-02-28T12:44:39.000Z
eval/cls_eval.py
wct5217488/invariance-equivariance
6dfadb39a485d0e55c1cd0c8ce0e0f6dfc602dd3
[ "MIT" ]
3
2021-05-12T19:09:13.000Z
2021-08-23T17:17:10.000Z
eval/cls_eval.py
wct5217488/invariance-equivariance
6dfadb39a485d0e55c1cd0c8ce0e0f6dfc602dd3
[ "MIT" ]
8
2021-06-09T02:41:37.000Z
2022-02-27T02:14:17.000Z
from __future__ import print_function import torch import time from tqdm import tqdm from .util import AverageMeter, accuracy import numpy as np def validate(val_loader, model, criterion, opt): """One epoch validation""" batch_time = AverageMeter() losses = AverageMeter() top1 = AverageMeter() top...
40.610837
88
0.434983
from __future__ import print_function import torch import time from tqdm import tqdm from .util import AverageMeter, accuracy import numpy as np def validate(val_loader, model, criterion, opt): """One epoch validation""" batch_time = AverageMeter() losses = AverageMeter() top1 = AverageMeter() top...
0
0
0
0
0
0
0
0
0
4a0fdc481c5a936d2863ba60f31ce7a87ac8d13b
2,576
py
Python
exampdftomindmap.py
synsandacks/CiscoExamPDFtoMindmap
fff0a10bcf18a2a2075e770b2305b038b1375de4
[ "MIT" ]
1
2022-02-10T09:31:50.000Z
2022-02-10T09:31:50.000Z
exampdftomindmap.py
synsandacks/CiscoExamPDFtoMindmap
fff0a10bcf18a2a2075e770b2305b038b1375de4
[ "MIT" ]
null
null
null
exampdftomindmap.py
synsandacks/CiscoExamPDFtoMindmap
fff0a10bcf18a2a2075e770b2305b038b1375de4
[ "MIT" ]
1
2022-02-09T21:19:38.000Z
2022-02-09T21:19:38.000Z
# Function that extracts the text from the supplied PDF and return the contents as a massive string. # Function that takes a list of text ex. ['this', 'is', 'how', 'the', 'data', 'would', 'look'] # and iterate over that list to return a new list that groups exam objectives properly. # Function to generate the md fil...
35.287671
113
0.590062
import PyPDF2 import re # Function that extracts the text from the supplied PDF and return the contents as a massive string. def pdftotext(pdffile): pdfFile = open(pdffile, 'rb') pdfReader = PyPDF2.PdfFileReader(pdfFile) numPages = pdfReader.numPages pdfText = '' for page in range(numPages): ...
0
0
0
0
0
1,879
0
-20
133
5f41b87dcf6b0dbdc532c835f9547fb846c9d202
317
py
Python
MoCalculator/main.py
daveh07/AS4100-1998-Mo_Moment_Calculator
5b83044d73bc78b12943e7b2175df6baf40a634b
[ "MIT" ]
null
null
null
MoCalculator/main.py
daveh07/AS4100-1998-Mo_Moment_Calculator
5b83044d73bc78b12943e7b2175df6baf40a634b
[ "MIT" ]
null
null
null
MoCalculator/main.py
daveh07/AS4100-1998-Mo_Moment_Calculator
5b83044d73bc78b12943e7b2175df6baf40a634b
[ "MIT" ]
null
null
null
# MEMBER CAPACITY OF SEGMENTS WITHOUT FULL LATERAL RESTRAINT # IN ACCORDANCE WITH AS4100-1998 - SECTION 5.6 # # V1.0 - 04/12/2020 by D.HILL # Calculate Alpha M print("Alpha_m = " + str((alpha_m_moment()))) # Calculate Alpha S buckling_moment()
19.8125
60
0.731861
# MEMBER CAPACITY OF SEGMENTS WITHOUT FULL LATERAL RESTRAINT # IN ACCORDANCE WITH AS4100-1998 - SECTION 5.6 # # V1.0 - 04/12/2020 by D.HILL from userInputs import * from alpha_m import * from alpha_s import * # Calculate Alpha M print("Alpha_m = " + str((alpha_m_moment()))) # Calculate Alpha S buckling_moment()
0
0
0
0
0
0
0
3
66
9a5198bc7713ce99f07d59ad097f76cd84eb5861
7,732
py
Python
webProject/sport/models.py
mohammadrezasalehi95/webproject-backend
e7b697d6e1197d3781446f44904eabd3d5137c5a
[ "MIT" ]
null
null
null
webProject/sport/models.py
mohammadrezasalehi95/webproject-backend
e7b697d6e1197d3781446f44904eabd3d5137c5a
[ "MIT" ]
7
2020-02-11T23:40:45.000Z
2022-03-11T23:39:40.000Z
webProject/sport/models.py
mohammadrezasalehi95/webproject-backend
e7b697d6e1197d3781446f44904eabd3d5137c5a
[ "MIT" ]
null
null
null
from pygments.lexers import get_all_lexers from pygments.styles import get_all_styles LEXERS = [item for item in get_all_lexers() if item[1]] LANGUAGE_CHOICES = sorted([(item[1][0], item[0]) for item in LEXERS]) STYLE_CHOICES = sorted((item, item) for item in get_all_styles()) # # class TeamGame(models.Model): # ...
42.718232
105
0.725297
from django.contrib.auth.models import User from django.utils import timezone from model_utils import Choices from pygments.lexers import get_all_lexers from pygments.styles import get_all_styles from django.contrib.auth.models import AbstractUser from django.db import models LEXERS = [item for item in get_all_lexers(...
0
0
0
6,452
0
0
0
81
501
4215a859c4f0ee1fa3f5c5043ebaff2722426e5a
277
py
Python
src/button.py
3dani33/ePaper_polaroid
54d98ac3492ecf5974254ac6651295affb23cb88
[ "MIT" ]
null
null
null
src/button.py
3dani33/ePaper_polaroid
54d98ac3492ecf5974254ac6651295affb23cb88
[ "MIT" ]
null
null
null
src/button.py
3dani33/ePaper_polaroid
54d98ac3492ecf5974254ac6651295affb23cb88
[ "MIT" ]
null
null
null
import RPi.GPIO as GPIO BUTTON_PIN = 4 if __name__ == '__main__': setup() while True: GPIO.wait_for_edge(BUTTON_PIN, GPIO.RISING) print('button!')
21.307692
63
0.66787
import RPi.GPIO as GPIO BUTTON_PIN = 4 def setup(): GPIO.setmode(GPIO.BCM) GPIO.setup(BUTTON_PIN, GPIO.IN, pull_up_down=GPIO.PUD_DOWN) if __name__ == '__main__': setup() while True: GPIO.wait_for_edge(BUTTON_PIN, GPIO.RISING) print('button!')
0
0
0
0
0
82
0
0
23
6da0e91d33eed83fe5c7b0ac6a350c323b69f234
1,848
py
Python
lustre/precomputation.py
half-cambodian-hacker-man/lustre
93e2196a962cafcfd7fa0be93a6b0d563c46ba75
[ "MIT" ]
3
2020-09-06T02:21:09.000Z
2020-09-30T00:05:54.000Z
lustre/precomputation.py
videogame-hacker/lustre
93e2196a962cafcfd7fa0be93a6b0d563c46ba75
[ "MIT" ]
null
null
null
lustre/precomputation.py
videogame-hacker/lustre
93e2196a962cafcfd7fa0be93a6b0d563c46ba75
[ "MIT" ]
null
null
null
import importlib
28.875
83
0.621753
import typing import importlib, importlib.resources from markupsafe import Markup from .templating import set_template_global class Precomputation: # TODO: Can we think of a better name for this? def __init__(self, precomputation_package: str): self.precomputation_package = precomputation_package ...
0
0
0
1,672
0
0
0
43
114
2adffddfdd68ffd15f238992beb73b2d8929d348
2,847
py
Python
tests/junk/recall/train_keras.py
imandr/gradnet
72b9b140cb3f43224a11310b115480fb42820546
[ "BSD-3-Clause" ]
null
null
null
tests/junk/recall/train_keras.py
imandr/gradnet
72b9b140cb3f43224a11310b115480fb42820546
[ "BSD-3-Clause" ]
null
null
null
tests/junk/recall/train_keras.py
imandr/gradnet
72b9b140cb3f43224a11310b115480fb42820546
[ "BSD-3-Clause" ]
null
null
null
from generator import Generator import numpy as np np.set_printoptions(precision=4, suppress=True, linewidth=132) if __name__ == '__main__': nwords = 10 length = 50 distance = 5 r = 2 batch_size = 5 g = Generator(nwords, distance, r) model = create_net(nwords, batch_size) train(mo...
33.494118
118
0.60274
from generator import Generator import numpy as np, random np.set_printoptions(precision=4, suppress=True, linewidth=132) from tensorflow import keras from tensorflow.keras.layers import LSTM, Dense, Input from tensorflow.keras import Model from tensorflow.keras.optimizers import Adagrad def create_net(nwords, batch...
0
0
0
0
0
2,227
0
87
185
6500f03260a475dd256be21b2448a300479360eb
29,087
py
Python
resolwe_bio/processes/alignment/star.py
plojyon/resolwe-bio
45d001a78fcc387b5e3239a34c9da7f40d789022
[ "Apache-2.0" ]
12
2015-12-07T18:29:27.000Z
2022-03-16T08:00:18.000Z
resolwe_bio/processes/alignment/star.py
plojyon/resolwe-bio
45d001a78fcc387b5e3239a34c9da7f40d789022
[ "Apache-2.0" ]
480
2015-11-20T21:46:43.000Z
2022-03-28T12:40:57.000Z
resolwe_bio/processes/alignment/star.py
plojyon/resolwe-bio
45d001a78fcc387b5e3239a34c9da7f40d789022
[ "Apache-2.0" ]
45
2015-11-19T14:54:07.000Z
2022-02-13T21:36:50.000Z
"""Align reads with STAR aligner.""" import gzip import shutil from pathlib import Path SPECIES = [ "Caenorhabditis elegans", "Cricetulus griseus", "Dictyostelium discoideum", "Dictyostelium purpureum", "Drosophila melanogaster", "Homo sapiens", "Macaca mulatta", "Mus musculus", "Od...
42.033237
103
0.587685
"""Align reads with STAR aligner.""" import gzip import shutil from pathlib import Path from plumbum import TEE from resolwe.process import ( BooleanField, Cmd, DataField, FileField, FloatField, GroupField, IntegerField, Process, SchedulingClass, StringField, ) SPECIES = [ ...
18
0
0
27,736
0
0
0
170
69
3568b320c9b54a136b9f6bb0bf61aa5462c0e752
5,759
py
Python
lywsd02/client.py
andras-tim/lywsd02
a5d7fb41094a7bf66b0e3bd943f922b3c529d1ca
[ "MIT" ]
null
null
null
lywsd02/client.py
andras-tim/lywsd02
a5d7fb41094a7bf66b0e3bd943f922b3c529d1ca
[ "MIT" ]
null
null
null
lywsd02/client.py
andras-tim/lywsd02
a5d7fb41094a7bf66b0e3bd943f922b3c529d1ca
[ "MIT" ]
null
null
null
import logging _LOGGER = logging.getLogger(__name__) UUID_UNITS = 'EBE0CCBE-7A0A-4B0C-8A1A-6FF2997DA3A6' # 0x00 - F, 0x01 - C READ WRITE UUID_HISTORY = 'EBE0CCBC-7A0A-4B0C-8A1A-6FF2997DA3A6' # Last idx 152 READ NOTIFY UUID_TIME = 'EBE0CCB7-7A0A-4B0C-8A1A-6FF2997DA3A6' # 5 or 4 bytes RE...
31.12973
91
0.610523
import collections import contextlib import logging import struct import time from datetime import datetime from bluepy import btle _LOGGER = logging.getLogger(__name__) UUID_UNITS = 'EBE0CCBE-7A0A-4B0C-8A1A-6FF2997DA3A6' # 0x00 - F, 0x01 - C READ WRITE UUID_HISTORY = 'EBE0CCBC-7A0A-4B0C-8A1A-6FF2997DA3A6' ...
0
2,402
0
2,716
0
0
0
-15
179
a779c56183368760dd85753f55634afaf79389d6
697
py
Python
problems/euler/45/pentagonal.py
vidyadeepa/the-coding-interview
90171b77b6884176a6c28bdccb5d45bd6929b489
[ "MIT" ]
1,571
2015-12-09T14:08:47.000Z
2022-03-30T21:34:36.000Z
problems/euler/45/pentagonal.py
vidyadeepa/the-coding-interview
90171b77b6884176a6c28bdccb5d45bd6929b489
[ "MIT" ]
117
2015-10-22T05:59:19.000Z
2021-09-17T00:14:38.000Z
problems/euler/45/pentagonal.py
vidyadeepa/the-coding-interview
90171b77b6884176a6c28bdccb5d45bd6929b489
[ "MIT" ]
452
2015-10-21T23:00:58.000Z
2022-03-18T21:16:50.000Z
from itertools import takewhile, combinations start = 40756 tg = triangle_generator(start) pg = pentagonal_generator(start) hg = hexagonal_generator(start) p = pg.next() t = tg.next() for h in hg: while p < h: p = pg.next() if p != h: continue while t < h: t = tg.next() if t == h: print h
15.840909
45
0.572453
from itertools import takewhile, combinations def triangle_generator(start): n = 1 while True: num = n*(n+1)/2 if num >= start: yield num n = n + 1 def pentagonal_generator(start): n = 1 while True: num = n*(3*n-1)/2 if num >= start: yield num n = n + 1 def hexagonal_gener...
0
0
0
0
311
0
0
0
69
b8b810d6136b1aa2892efe14a75d85f0d51b1527
301
py
Python
classifications/getSubjectDump.py
tingard/Galaxy-builder-aggregation
78fec76eeb2ab4b38e241b66fa5643e0002ba3a7
[ "MIT" ]
1
2018-05-16T14:48:43.000Z
2018-05-16T14:48:43.000Z
classifications/getSubjectDump.py
tingard/Galaxy-builder-aggregation
78fec76eeb2ab4b38e241b66fa5643e0002ba3a7
[ "MIT" ]
null
null
null
classifications/getSubjectDump.py
tingard/Galaxy-builder-aggregation
78fec76eeb2ab4b38e241b66fa5643e0002ba3a7
[ "MIT" ]
null
null
null
import sys if len(sys.argv) > 1: fpath = sys.argv[1] else: fpath = 'galaxy-builder-subjects.csv' try: with open(fpath) as f: classificationCsv = f.read().split('\n')[1:] except FileNotFoundError: print('No subjects file found, exiting') sys.exit(0)
18.8125
52
0.651163
import re import json import sys if len(sys.argv) > 1: fpath = sys.argv[1] else: fpath = 'galaxy-builder-subjects.csv' try: with open(fpath) as f: classificationCsv = f.read().split('\n')[1:] except FileNotFoundError: print('No subjects file found, exiting') sys.exit(0)
0
0
0
0
0
0
0
-22
44
487508962cb47f6dd9ce8ee856085cd1bb2f3541
998
py
Python
raspberry_pi/lightning/config.py
asmyczek/lightning
f0b27ae07ade148a8ef938bb2356a83650eb3197
[ "MIT" ]
null
null
null
raspberry_pi/lightning/config.py
asmyczek/lightning
f0b27ae07ade148a8ef938bb2356a83650eb3197
[ "MIT" ]
null
null
null
raspberry_pi/lightning/config.py
asmyczek/lightning
f0b27ae07ade148a8ef938bb2356a83650eb3197
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*-
23.209302
57
0.538076
# -*- coding: utf-8 -*- from typing import Dict, Any from json import loads from pathlib import Path import logging def load_config(config_file) -> Dict: try: config_file = Path(config_file).resolve() with config_file.open() as file: return loads(file.read()) except FileNotFoundEr...
0
0
0
596
0
237
0
4
135
be70ea7a964506442e645e8316bd0bab9a81f566
13,643
py
Python
src/rez/build_system.py
ColinKennedy/rez
1ecc85f638d11d70ed78d4bd9c5cdc6f32ac58c4
[ "Apache-2.0" ]
null
null
null
src/rez/build_system.py
ColinKennedy/rez
1ecc85f638d11d70ed78d4bd9c5cdc6f32ac58c4
[ "Apache-2.0" ]
null
null
null
src/rez/build_system.py
ColinKennedy/rez
1ecc85f638d11d70ed78d4bd9c5cdc6f32ac58c4
[ "Apache-2.0" ]
null
null
null
# SPDX-License-Identifier: Apache-2.0 # Copyright Contributors to the Rez Project import os.path from rez.exceptions import BuildSystemError from rez.packages import get_developer_package def get_buildsys_types(): """Returns the available build system implementations - cmake, make etc.""" from rez.plugin_ma...
40.008798
86
0.607931
# SPDX-License-Identifier: Apache-2.0 # Copyright Contributors to the Rez Project import os.path from rez.build_process import BuildType from rez.exceptions import BuildSystemError from rez.packages import get_developer_package from rez.rex_bindings import VariantBinding def get_buildsys_types(): """Returns th...
0
5,097
0
3,328
0
0
0
40
68
5dcb7579adca2910e170cde3ffb6e6b2c855b1b4
642
py
Python
languages/python/src/concepts/P093_OOP_Exceptions_TryExceptBlock.py
vikash-india/DeveloperNotes2Myself
fe277a3c52f73884863f2f72b237365b27a8c882
[ "MIT" ]
2
2019-05-25T10:09:00.000Z
2022-03-11T09:06:23.000Z
languages/python/src/concepts/P093_OOP_Exceptions_TryExceptBlock.py
vikash-india/DeveloperNotes2Myself
fe277a3c52f73884863f2f72b237365b27a8c882
[ "MIT" ]
2
2020-03-31T04:30:17.000Z
2020-10-30T07:54:28.000Z
languages/python/src/concepts/P093_OOP_Exceptions_TryExceptBlock.py
vikash-india/DeveloperNotes2Myself
fe277a3c52f73884863f2f72b237365b27a8c882
[ "MIT" ]
4
2019-07-12T13:18:56.000Z
2021-11-17T08:04:55.000Z
# Description: Exception Handling Using Try-Except Block import sys random_list = ["a", 0, 2, "#", 33] for item in random_list: try: reciprocal = 1 / int(item) print("The reciprocal {} is {}".format(item, reciprocal)) except ValueError: # Handle one exception type ValueError p...
32.1
75
0.64486
# Description: Exception Handling Using Try-Except Block import sys random_list = ["a", 0, 2, "#", 33] for item in random_list: try: reciprocal = 1 / int(item) print("The reciprocal {} is {}".format(item, reciprocal)) except ValueError: # Handle one exception type ValueError p...
0
0
0
0
0
0
0
0
0
2a950afe711201b092e94ec25cac483c37306dd2
89
py
Python
__init__.py
redtreeai/img2txt
e58ccc8fea802d07403b67474d5d47eacbd66044
[ "Apache-2.0" ]
2
2019-05-31T01:23:26.000Z
2019-11-14T09:45:31.000Z
__init__.py
redtreeai/img2txt
e58ccc8fea802d07403b67474d5d47eacbd66044
[ "Apache-2.0" ]
null
null
null
__init__.py
redtreeai/img2txt
e58ccc8fea802d07403b67474d5d47eacbd66044
[ "Apache-2.0" ]
null
null
null
''' @author: redtree @contact: redtreec@gmail.com @time: 17-12-28 11:17 @desc: '''
8.090909
28
0.629213
''' @author: redtree @contact: redtreec@gmail.com @time: 17-12-28 上午11:17 @desc: '''
6
0
0
0
0
0
0
0
0
d08c76cd24dbc93762735c0379a49d9da7f40305
2,983
py
Python
mogan/api/validation/parameter_types.py
GURUIFENG9139/rocky-mogan
6008c1d12b00e70d2cc651f7bd5d47968fc3aec7
[ "Apache-2.0" ]
null
null
null
mogan/api/validation/parameter_types.py
GURUIFENG9139/rocky-mogan
6008c1d12b00e70d2cc651f7bd5d47968fc3aec7
[ "Apache-2.0" ]
null
null
null
mogan/api/validation/parameter_types.py
GURUIFENG9139/rocky-mogan
6008c1d12b00e70d2cc651f7bd5d47968fc3aec7
[ "Apache-2.0" ]
null
null
null
# Copyright 2017 Huawei Technologies Co.,LTD. # 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 # # Unl...
21.307143
78
0.552799
# Copyright 2017 Huawei Technologies Co.,LTD. # 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 # # Unl...
0
0
0
0
0
0
0
0
0
75e838a4394ded0ea2e9eb939c11fb31a274332e
1,226
py
Python
appbasico/migrations/0008_auto_20210409_1835.py
brunovirgilio/django-basico
156a49cf70cd5c261c3662b62d69e9696c76598f
[ "MIT" ]
1
2021-07-09T06:19:53.000Z
2021-07-09T06:19:53.000Z
appbasico/migrations/0008_auto_20210409_1835.py
brunovirgilio/django-basico
156a49cf70cd5c261c3662b62d69e9696c76598f
[ "MIT" ]
null
null
null
appbasico/migrations/0008_auto_20210409_1835.py
brunovirgilio/django-basico
156a49cf70cd5c261c3662b62d69e9696c76598f
[ "MIT" ]
null
null
null
# Generated by Django 3.1.7 on 2021-04-09 21:35
29.902439
121
0.584829
# Generated by Django 3.1.7 on 2021-04-09 21:35 from django.db import migrations, models import django.utils.timezone class Migration(migrations.Migration): dependencies = [ ('appbasico', '0007_auto_20210407_1431'), ] operations = [ migrations.AddField( model_name='postagem'...
8
0
0
1,079
0
0
0
26
68
4508d181044add4dc60d5b3b6da615c480a288a2
858
py
Python
setup.py
AlyaGomaa/bitsbehumble
2e7ee1f8beb727974957f5a3bf111df3f8239594
[ "MIT" ]
13
2020-06-22T15:00:38.000Z
2021-08-30T05:28:04.000Z
setup.py
AlyaGomaa/bitsbehumble
2e7ee1f8beb727974957f5a3bf111df3f8239594
[ "MIT" ]
null
null
null
setup.py
AlyaGomaa/bitsbehumble
2e7ee1f8beb727974957f5a3bf111df3f8239594
[ "MIT" ]
1
2020-06-22T16:35:25.000Z
2020-06-22T16:35:25.000Z
with open("README.md", "r") as fh: long_description = fh.read() my_packages=find_packages() setup( name = 'bitsbehumble', packages = my_packages, version = '0.5', long_description=long_description, long_description_content_type="text/markdown", author = 'Alya Gomaa', url = 'https...
26
84
0.635198
from setuptools import * with open("README.md", "r") as fh: long_description = fh.read() my_packages=find_packages() setup( name = 'bitsbehumble', packages = my_packages, version = '0.5', long_description=long_description, long_description_content_type="text/markdown", author = 'Aly...
0
0
0
0
0
0
0
3
23
a58f3a0841bc4642e7bb06398e78041517c53a26
4,142
py
Python
scripts/migrate_experiment_designs.py
SD2E/python-datacatalog
51ab366639505fb6e8a14cd6b446de37080cd20d
[ "CNRI-Python" ]
null
null
null
scripts/migrate_experiment_designs.py
SD2E/python-datacatalog
51ab366639505fb6e8a14cd6b446de37080cd20d
[ "CNRI-Python" ]
2
2019-07-25T15:39:04.000Z
2019-10-21T15:31:46.000Z
scripts/migrate_experiment_designs.py
SD2E/python-datacatalog
51ab366639505fb6e8a14cd6b446de37080cd20d
[ "CNRI-Python" ]
1
2019-10-15T14:33:44.000Z
2019-10-15T14:33:44.000Z
# Note: Read and understand https://gitlab.sd2e.org/sd2program/python-datacatalog/merge_requests/190 # Before running! import pymongo from datacatalog.identifiers.typeduuid import catalog_uuid # Update this to target production # This should only need to be done once dbURI = "mongodb://catalog:catalog@localhost:2701...
44.537634
160
0.619507
# Note: Read and understand https://gitlab.sd2e.org/sd2program/python-datacatalog/merge_requests/190 # Before running! import pymongo from datacatalog.identifiers.typeduuid import catalog_uuid # Update this to target production # This should only need to be done once dbURI = "mongodb://catalog:catalog@localhost:2701...
0
0
0
0
0
0
0
0
0
74eb31bf50e4f0475673bcfefa2b48567fa9e685
13,404
py
Python
paging/paging.py
jounikor/3gpp
1f0aa0ffa8c83a62740e28fa0d5769b1564edc09
[ "Unlicense" ]
null
null
null
paging/paging.py
jounikor/3gpp
1f0aa0ffa8c83a62740e28fa0d5769b1564edc09
[ "Unlicense" ]
null
null
null
paging/paging.py
jounikor/3gpp
1f0aa0ffa8c83a62740e28fa0d5769b1564edc09
[ "Unlicense" ]
1
2022-03-10T16:03:29.000Z
2022-03-10T16:03:29.000Z
# # Version 0.1 (c) 2018 Jouni Korhonen # # #import exceptions # See 36.304 subclause 7.2 # i_s=0 i_s=1 i_s=2 i_s=3 sf_pattern_npdcch_or_mpdcch_gt_3MHz_fdd = ( (9, None, None, None), # Ns = 1 (4, 9, None, None), # Ns = 2 (0, 4, 5, 9) # Ns = 4 ) # See 36.304...
33.014778
114
0.559609
# # Version 0.1 (c) 2018 Jouni Korhonen # # #import exceptions import rrcconfig as rrc import nasconfig as nas import math as m # See 36.304 subclause 7.2 # i_s=0 i_s=1 i_s=2 i_s=3 sf_pattern_npdcch_or_mpdcch_gt_3MHz_fdd = ( (9, None, None, None), # Ns = 1 (4, 9, None, None), # Ns...
0
0
0
12,486
0
0
0
-1
134
bc4c0d17d5a50732f9ab3b4888be555842ab0bdb
3,537
py
Python
app/controllers/main.py
akotlerman/flask-website
1e1e659a2fcab522c4179089d370b5783aff1eb1
[ "BSD-2-Clause" ]
null
null
null
app/controllers/main.py
akotlerman/flask-website
1e1e659a2fcab522c4179089d370b5783aff1eb1
[ "BSD-2-Clause" ]
null
null
null
app/controllers/main.py
akotlerman/flask-website
1e1e659a2fcab522c4179089d370b5783aff1eb1
[ "BSD-2-Clause" ]
null
null
null
from flask import Blueprint main = Blueprint('main', __name__)
29.722689
108
0.648007
from flask import Blueprint, render_template, flash, request, redirect, url_for, jsonify, abort from app.extensions import cache, pages from app.tasks import long_task import flam3, io, base64, struct from PIL import Image main = Blueprint('main', __name__) @main.route('/') @cache.cached(timeout=1000) def home(): ...
0
2,955
0
0
0
59
0
107
341
bbe52c431dfd2064958b7c864f8d7ea5f4c87352
6,099
py
Python
src/viektup.py
fyodr/kektuple
5602134d9b784fbbbf1efd6afe7a0c523dded06a
[ "MIT" ]
null
null
null
src/viektup.py
fyodr/kektuple
5602134d9b784fbbbf1efd6afe7a0c523dded06a
[ "MIT" ]
3
2020-05-26T22:28:22.000Z
2020-05-27T02:32:10.000Z
src/viektup.py
fyodr/kektuple
5602134d9b784fbbbf1efd6afe7a0c523dded06a
[ "MIT" ]
null
null
null
""" viektup.py by Ted Morin viektup <= visual interactive kektup a class for visualizing Barnette graphs via interactive visualization """ from iektup import Iektup if __name__ == '__main__': v = Viektup(g = Iektup.random_graph(30, 0)) v.show_tutte_embedding(f=9) input("exit on enter")
35.666667
76
0.571733
""" viektup.py by Ted Morin viektup <= visual interactive kektup a class for visualizing Barnette graphs via interactive visualization """ import numpy as np from vektup import Vektup from iektup import Iektup class Viektup(Vektup): def __init__(self, g=None, showing_points=True, showing...
0
0
0
5,727
0
0
0
1
67
1995081178b8e9fad8c0b013bb69eea59dd02469
374
py
Python
examples/annotations/upload_annotation_to_dataset.py
dataloop-ai/sdk_examples
422d5629df5af343d2dc275e9570bb83c4e2f49d
[ "MIT" ]
3
2022-01-07T20:33:49.000Z
2022-03-22T12:41:30.000Z
examples/annotations/upload_annotation_to_dataset.py
dataloop-ai/sdk_examples
422d5629df5af343d2dc275e9570bb83c4e2f49d
[ "MIT" ]
null
null
null
examples/annotations/upload_annotation_to_dataset.py
dataloop-ai/sdk_examples
422d5629df5af343d2dc275e9570bb83c4e2f49d
[ "MIT" ]
3
2021-12-29T13:11:30.000Z
2022-03-22T12:25:50.000Z
import dtlpy as dl dataset_id = '' annotations_path = r'' # make sure they have the same hierarchy dataset = dl.datasets.get(dataset_id=dataset_id) # clean: bool - if True it remove the old annotations # remote_root_path: str - the remote root path to match remote and local items dataset.upload_annotations(local_path...
34
90
0.783422
import dtlpy as dl dataset_id = '' annotations_path = r'' # make sure they have the same hierarchy dataset = dl.datasets.get(dataset_id=dataset_id) # clean: bool - if True it remove the old annotations # remote_root_path: str - the remote root path to match remote and local items dataset.upload_annotations(local_path...
0
0
0
0
0
0
0
0
0
1c6e4a81a173fa18b5f8b7f938e0d2aac2fb1994
436
py
Python
examples/volumetric/tet_threshold.py
evanphilip/vedo
e8504fb1a7d2cb667a776180d69bb17cad634e1e
[ "CC0-1.0" ]
836
2020-06-14T02:38:12.000Z
2022-03-31T15:39:50.000Z
examples/volumetric/tet_threshold.py
evanphilip/vedo
e8504fb1a7d2cb667a776180d69bb17cad634e1e
[ "CC0-1.0" ]
418
2020-06-14T10:51:32.000Z
2022-03-31T23:23:14.000Z
examples/volumetric/tet_threshold.py
evanphilip/vedo
e8504fb1a7d2cb667a776180d69bb17cad634e1e
[ "CC0-1.0" ]
136
2020-06-14T02:26:41.000Z
2022-03-31T12:47:18.000Z
"""Threshold the original TetMesh with a scalar array""" settings.useDepthPeeling = True tetm = TetMesh(dataurl+'limb_ugrid.vtk') tetm.color('prism').alpha([0,1]) # Threshold the tetrahedral mesh for values in the range: tetm.threshold(above=0.9, below=1) tetm.addScalarBar3D(title='chem_0 expression levels', c='k',...
24.222222
71
0.704128
"""Threshold the original TetMesh with a scalar array""" from vedo import * settings.useDepthPeeling = True tetm = TetMesh(dataurl+'limb_ugrid.vtk') tetm.color('prism').alpha([0,1]) # Threshold the tetrahedral mesh for values in the range: tetm.threshold(above=0.9, below=1) tetm.addScalarBar3D(title='chem_0 express...
0
0
0
0
0
0
0
-3
22
8232a837d37bf5ce21f07e2fbce3a35ef2d5d563
373
py
Python
test/client/post_client.py
lidall/risk-authentication-service
17e59dc264618a691767b5e271ac170b4178eb6f
[ "MIT" ]
null
null
null
test/client/post_client.py
lidall/risk-authentication-service
17e59dc264618a691767b5e271ac170b4178eb6f
[ "MIT" ]
null
null
null
test/client/post_client.py
lidall/risk-authentication-service
17e59dc264618a691767b5e271ac170b4178eb6f
[ "MIT" ]
null
null
null
import asyncio text = asyncio.run(main()) # Assuming you're using python 3.7+ print(text)
24.866667
70
0.619303
import asyncio import aiohttp async def main(): url = 'http://0.0.0.0:8080/log' with open('data.txt', 'rb') as f: async with aiohttp.ClientSession() as session: async with session.post(url, data={'key': f}) as response: return await response.text() text = asyncio.run(main...
0
0
241
0
0
0
0
-7
45
0f1ba0f472d43145fe9d19222d09e17981af0786
1,934
py
Python
lldb/scripts/copy-static-bindings.py
LaudateCorpus1/llvm-project-staging
cc926dc3a87af7023aa9b6c392347a0a8ed6949b
[ "Apache-2.0" ]
null
null
null
lldb/scripts/copy-static-bindings.py
LaudateCorpus1/llvm-project-staging
cc926dc3a87af7023aa9b6c392347a0a8ed6949b
[ "Apache-2.0" ]
null
null
null
lldb/scripts/copy-static-bindings.py
LaudateCorpus1/llvm-project-staging
cc926dc3a87af7023aa9b6c392347a0a8ed6949b
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python """SWIG Static Binding Copier This script copies over the Python bindings generated by SWIG from the build directory to the source directory. Before using the script, make sure you have LLDB_USE_STATIC_BINDINGS set to OFF by looking at CMakeCache.txt in the LLDB build directory. The scripts kno...
32.233333
78
0.668046
#!/usr/bin/env python """SWIG Static Binding Copier This script copies over the Python bindings generated by SWIG from the build directory to the source directory. Before using the script, make sure you have LLDB_USE_STATIC_BINDINGS set to OFF by looking at CMakeCache.txt in the LLDB build directory. The scripts kno...
0
0
0
0
0
1,185
0
-37
112
2854f114e96f2c3f14e1c5c147096d7b6d434e74
193
py
Python
tests/requests/req-head.py
Team-Fenris/tfcctrl
d7af8750fddb7d09f6ee3830d9703c5356b9ef13
[ "Apache-2.0" ]
1
2021-12-28T17:07:21.000Z
2021-12-28T17:07:21.000Z
tests/requests/req-head.py
Team-Fenris/tfcctrl
d7af8750fddb7d09f6ee3830d9703c5356b9ef13
[ "Apache-2.0" ]
null
null
null
tests/requests/req-head.py
Team-Fenris/tfcctrl
d7af8750fddb7d09f6ee3830d9703c5356b9ef13
[ "Apache-2.0" ]
null
null
null
import requests # Request URL from the user input url = input("Insert URL: ") # Set up and make the test ready for print x = requests.head(url) # Print the callback print(x.headers)
19.3
43
0.694301
import requests # Request URL from the user input url = input("Insert URL: ") # Set up and make the test ready for print x = requests.head(url) # Print the callback print(x.headers)
0
0
0
0
0
0
0
0
0
a0eaa0066688a682511c63cb1875814600dd18a3
205
py
Python
fec_raw/tests.py
datadesk/django-fec-raw-data
9d1f49e5ecc1552c55b635c63c1bf021871e4c0b
[ "MIT" ]
3
2016-06-01T18:16:36.000Z
2021-07-20T14:51:40.000Z
fec_raw/tests.py
datadesk/django-fec-raw-data
9d1f49e5ecc1552c55b635c63c1bf021871e4c0b
[ "MIT" ]
9
2015-11-24T06:22:56.000Z
2021-06-10T17:45:57.000Z
fec_raw/tests.py
datadesk/django-fec-raw-data
9d1f49e5ecc1552c55b635c63c1bf021871e4c0b
[ "MIT" ]
1
2020-12-01T21:22:53.000Z
2020-12-01T21:22:53.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import unicode_literals
18.636364
39
0.697561
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import unicode_literals from django.test import TestCase class FecTest(TestCase): def test_fake(self): self.assertEqual(2+2, 4)
0
0
0
62
0
0
0
11
45
345988313f381b37b27d23851276e597d1cfa427
1,432
py
Python
tests/test_fix_print.py
graingert/python-modernize
028d13416d7abe4b8b39bc21e6425df65c7836c0
[ "BSD-3-Clause" ]
220
2015-03-25T11:06:13.000Z
2020-08-19T13:33:57.000Z
tests/test_fix_print.py
graingert/python-modernize
028d13416d7abe4b8b39bc21e6425df65c7836c0
[ "BSD-3-Clause" ]
113
2015-01-03T18:05:27.000Z
2020-08-18T21:42:23.000Z
tests/test_fix_print.py
graingert/python-modernize
028d13416d7abe4b8b39bc21e6425df65c7836c0
[ "BSD-3-Clause" ]
39
2015-01-18T10:08:52.000Z
2020-07-12T18:44:40.000Z
from __future__ import generator_stop PRINT_BARE = ( """\ print """, """\ from __future__ import print_function print() """, ) PRINT_SIMPLE = ( """\ print 'Hello' """, """\ from __future__ import print_function print('Hello') """, ) PRINT_MULTIPLE = ( """\ print 'Hello', 'world' """, """\ fro...
14.039216
47
0.65852
from __future__ import generator_stop from utils import check_on_input PRINT_BARE = ( """\ print """, """\ from __future__ import print_function print() """, ) PRINT_SIMPLE = ( """\ print 'Hello' """, """\ from __future__ import print_function print('Hello') """, ) PRINT_MULTIPLE = ( """\ print ...
0
0
0
0
0
311
0
11
184
d736de07b87063cbed39e7376c3caac6450912bb
490
py
Python
app/server/auth/__init__.py
tderleth/2-item-catalog
168e8f5ad10a26a03f6c50b1b2173de0b5dde113
[ "MIT" ]
null
null
null
app/server/auth/__init__.py
tderleth/2-item-catalog
168e8f5ad10a26a03f6c50b1b2173de0b5dde113
[ "MIT" ]
null
null
null
app/server/auth/__init__.py
tderleth/2-item-catalog
168e8f5ad10a26a03f6c50b1b2173de0b5dde113
[ "MIT" ]
null
null
null
#!/usr/bin/env python2.7 # -*- coding: utf-8 -*- """Initialize package.""" def login_required(f): """Check if user is authenticated.""" return wrap
23.333333
50
0.632653
#!/usr/bin/env python2.7 # -*- coding: utf-8 -*- """Initialize package.""" from flask import redirect, url_for from flask import session as login_session from functools import wraps def login_required(f): """Check if user is authenticated.""" @wraps(f) def wrap(*args, **kwargs): if login_session...
0
196
0
0
0
0
0
41
93
ca1e6d19ff949ebaf3c6b29a5cb5dea9ff1c5275
240
py
Python
cli_tests/nb_config.py
jbn/dissertate
a3e258b8686408b28fec13ba300e77d466465e5b
[ "MIT" ]
2
2019-03-08T14:24:11.000Z
2019-07-11T15:13:07.000Z
cli_tests/nb_config.py
jbn/dissertate
a3e258b8686408b28fec13ba300e77d466465e5b
[ "MIT" ]
1
2017-04-30T18:04:19.000Z
2017-06-15T22:28:53.000Z
cli_tests/nb_config.py
jbn/dissertate
a3e258b8686408b28fec13ba300e77d466465e5b
[ "MIT" ]
null
null
null
import dissertate c = get_config() c.Exporter.preprocessors = ['dissertate.preprocessors.CellElider', 'dissertate.preprocessors.EmptyCellElider'] c.Exporter.template_file = dissertate.markdown_template_path()
26.666667
71
0.725
import dissertate c = get_config() c.Exporter.preprocessors = ['dissertate.preprocessors.CellElider', 'dissertate.preprocessors.EmptyCellElider'] c.Exporter.template_file = dissertate.markdown_template_path()
0
0
0
0
0
0
0
0
0
ba57317d47dd39595ebadff7a609644ff3f9eb12
19,205
py
Python
responder/aws/function/responder.py
gracious-tech/stello
1b7b1b28c76c38eede4abef308cb981e26f068b8
[ "MIT" ]
1
2021-11-04T11:36:12.000Z
2021-11-04T11:36:12.000Z
responder/aws/function/responder.py
gracious-tech/stello
1b7b1b28c76c38eede4abef308cb981e26f068b8
[ "MIT" ]
7
2021-07-29T06:26:06.000Z
2021-11-19T01:42:25.000Z
responder/aws/function/responder.py
gracious-tech/stello
1b7b1b28c76c38eede4abef308cb981e26f068b8
[ "MIT" ]
null
null
null
import os import json import base64 import string from time import time from uuid import uuid4 from pathlib import Path from traceback import format_exc from contextlib import suppress import rollbar import boto3 from botocore.config import Config from cryptography.hazmat.primitives.hashes import SHA256 from cryptogr...
35.964419
398
0.664358
import os import json import base64 import string from time import time from uuid import uuid4 from pathlib import Path from traceback import format_exc from contextlib import suppress import rollbar import boto3 from botocore.config import Config from cryptography.hazmat.primitives.hashes import SHA256 from cryptogr...
0
0
0
71
0
140
0
0
45
3d41d405150ed0e79bbadee5ab542a4512d98c48
2,718
py
Python
controllers.py
afewyards/starcitizen_gremlin
a173711f96e4ad491901a0afd3b899fa08f76d2b
[ "MIT" ]
null
null
null
controllers.py
afewyards/starcitizen_gremlin
a173711f96e4ad491901a0afd3b899fa08f76d2b
[ "MIT" ]
null
null
null
controllers.py
afewyards/starcitizen_gremlin
a173711f96e4ad491901a0afd3b899fa08f76d2b
[ "MIT" ]
null
null
null
# Copyright (c) 2017 Thierry Kleist # # MIT License # # 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, merg...
33.555556
75
0.702723
# Copyright (c) 2017 Thierry Kleist # # MIT License # # 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, merg...
0
525
0
829
0
0
0
87
135
94c8cc94a2af46e25ce52873ef6ff30ccc268642
4,875
py
Python
adv_setup.py
Derek318/Adversarial-Squad-CS224N
9b4a5da2a262f4de9b9b05d7b67dc48b2b857e46
[ "MIT" ]
1
2020-11-12T02:49:32.000Z
2020-11-12T02:49:32.000Z
adv_setup.py
Derek318/Adversarial-Squad-CS224N
9b4a5da2a262f4de9b9b05d7b67dc48b2b857e46
[ "MIT" ]
null
null
null
adv_setup.py
Derek318/Adversarial-Squad-CS224N
9b4a5da2a262f4de9b9b05d7b67dc48b2b857e46
[ "MIT" ]
null
null
null
import torch.utils.data as data import ujson as json # 60 20 20 split if __name__ == '__main__': pre_process() test_baseline()
39.314516
159
0.694359
import logging import os import queue import random import re from args import get_setup_args import shutil import string import setup import torch import torch.nn.functional as F import torch.utils.data as data from collections import Counter import tqdm import numpy as np import ujson as json import spacy import json...
0
0
0
0
0
4,322
0
-53
433
62db68da161d1ea9d14e592b1e3cf0ae819a76bf
1,612
py
Python
udacity/self-driving-intro/2-bayesian-thinking/12/test.py
adriancarriger/experiments
7e4248592dc8fbb08522c9b5f0393c80dc7e2699
[ "MIT" ]
1
2021-06-22T13:38:36.000Z
2021-06-22T13:38:36.000Z
udacity/self-driving-intro/2-bayesian-thinking/12/test.py
adriancarriger/experiments
7e4248592dc8fbb08522c9b5f0393c80dc7e2699
[ "MIT" ]
108
2019-05-23T16:12:32.000Z
2020-09-04T15:47:33.000Z
udacity/self-driving-intro/2-bayesian-thinking/12/test.py
adriancarriger/experiments
7e4248592dc8fbb08522c9b5f0393c80dc7e2699
[ "MIT" ]
null
null
null
# from './localizer' import localizer test_sense()
23.362319
75
0.604218
# from './localizer' import localizer import localizer import helpers def test_sense(): R = 'r' _ = 'g' simple_grid = [ [_, _, _], [_, R, _], [_, _, _] ] p = 1.0 / 9 initial_beliefs = [ [p, p, p], [p, p, p], [p, p, p] ] observation = R...
0
0
0
0
0
1,503
0
-12
67
deecfb2ff8809fa583a186388e95973a391ea0c6
3,577
py
Python
volDB/migrations/0001_initial.py
leg2015/CSCapstone19Volunteers
ae0fcf1e8ce4fafe8578edd0a3943574703046fa
[ "MIT" ]
4
2020-01-13T23:30:34.000Z
2021-03-17T21:23:57.000Z
volDB/migrations/0001_initial.py
leg2015/CSCapstone19Volunteers
ae0fcf1e8ce4fafe8578edd0a3943574703046fa
[ "MIT" ]
5
2020-02-12T03:25:17.000Z
2021-06-10T22:29:16.000Z
volDB/migrations/0001_initial.py
leg2015/CSCapstone19Volunteers
ae0fcf1e8ce4fafe8578edd0a3943574703046fa
[ "MIT" ]
null
null
null
# Generated by Django 2.1.7 on 2019-02-23 18:47
41.593023
137
0.574224
# Generated by Django 2.1.7 on 2019-02-23 18:47 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Address', fields=[ ...
0
0
0
3,430
0
0
0
30
68
5bf95b53dad15597c23e37c17856b5c97c6c0117
627
py
Python
Python Fundamentals/Dictionaries/Exercise/Task10.py
IvanTodorovBG/SoftUni
7b667f6905d9f695ab1484efbb02b6715f6d569e
[ "MIT" ]
1
2022-03-16T10:23:04.000Z
2022-03-16T10:23:04.000Z
Python Fundamentals/Dictionaries/Exercise/Task10.py
IvanTodorovBG/SoftUni
7b667f6905d9f695ab1484efbb02b6715f6d569e
[ "MIT" ]
null
null
null
Python Fundamentals/Dictionaries/Exercise/Task10.py
IvanTodorovBG/SoftUni
7b667f6905d9f695ab1484efbb02b6715f6d569e
[ "MIT" ]
null
null
null
command = input() company_users = {} # add all company users in dictionary while command != "End": command = command.split(" -> ") company = command[0] users = command[1] company_users.setdefault(company, []).append(users) command = input() # remove duplicating users for k, v in company_users.i...
23.222222
78
0.669856
command = input() company_users = {} # add all company users in dictionary while command != "End": command = command.split(" -> ") company = command[0] users = command[1] company_users.setdefault(company, []).append(users) command = input() # remove duplicating users for k, v in company_users.i...
0
0
0
0
0
0
0
0
0