hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
75d4367999961c5433556d37188b1324f556216d
9,665
py
Python
contrib/bitrpc/bitrpc.py
stintcoin/Stintcoin
75b9fc740ed1929bde1f142502f9adbbb630d812
[ "MIT" ]
2
2018-12-04T17:42:46.000Z
2020-02-13T17:49:29.000Z
contrib/bitrpc/bitrpc.py
stintcoin/Stintcoin
75b9fc740ed1929bde1f142502f9adbbb630d812
[ "MIT" ]
null
null
null
contrib/bitrpc/bitrpc.py
stintcoin/Stintcoin
75b9fc740ed1929bde1f142502f9adbbb630d812
[ "MIT" ]
null
null
null
from jsonrpc import ServiceProxy import sys import string import getpass # ===== BEGIN USER SETTINGS ===== # if you do not set these you will be prompted for a password for every command rpcuser = "" rpcpass = "" # ====== END USER SETTINGS ====== if rpcpass == "": access = ServiceProxy("http://127.0.0.1:27502") ...
28.594675
101
0.573513
ded5f9a23f4c03aedce76e7701d5db3aeaaa8b95
2,607
py
Python
src/app/main/sms_tools.py
chenweixu/bunnyc_mgr
1243fa951c45c665442212247d682ce3d39aec08
[ "Apache-2.0" ]
null
null
null
src/app/main/sms_tools.py
chenweixu/bunnyc_mgr
1243fa951c45c665442212247d682ce3d39aec08
[ "Apache-2.0" ]
null
null
null
src/app/main/sms_tools.py
chenweixu/bunnyc_mgr
1243fa951c45c665442212247d682ce3d39aec08
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Email: chenwx716@163.com # DateTime: 2017-12-01 15:32:37 __author__ = "chenwx" import hashlib from suds.client import Client from app.main.conf import conf_data from app import work_log class Sms_tools(object): """docstring for Sms_tools""" def __init__(self): super(Sms_too...
34.302632
86
0.472957
64fd4c08cba646e567331e5ad0c53e36b8dc7d75
28,700
py
Python
diofant/tests/simplify/test_simplify.py
BuildJet/diofant
1895ccbf7da0c3a6a7fb45b7d8529f69a8dcf96b
[ "BSD-3-Clause" ]
null
null
null
diofant/tests/simplify/test_simplify.py
BuildJet/diofant
1895ccbf7da0c3a6a7fb45b7d8529f69a8dcf96b
[ "BSD-3-Clause" ]
null
null
null
diofant/tests/simplify/test_simplify.py
BuildJet/diofant
1895ccbf7da0c3a6a7fb45b7d8529f69a8dcf96b
[ "BSD-3-Clause" ]
null
null
null
import pytest from diofant import (Add, Basic, E, Eq, Float, Function, GoldenRatio, I, Integer, Integral, Lt, Matrix, MatrixSymbol, Mul, Number, Piecewise, Rational, Sum, Symbol, acos, asin, atan, besseli, besselj, besselsimp, binomial, cancel, cbrt, ...
40.365682
117
0.523868
9828404d36d9f36d8a21be2c1f751db6754e8e30
2,065
py
Python
mp_template/app/routes.py
ang-jason/fip_powerx_mini_projects-foxtrot
37e3671969b516369e2d1c7cab5890b75c489f56
[ "MIT" ]
12
2021-09-03T08:00:47.000Z
2021-11-21T03:45:21.000Z
mp_template/app/routes.py
ang-jason/fip_powerx_mini_projects-foxtrot
37e3671969b516369e2d1c7cab5890b75c489f56
[ "MIT" ]
8
2021-06-17T03:16:09.000Z
2021-10-06T03:41:57.000Z
mp_template/app/routes.py
ang-jason/fip_powerx_mini_projects-foxtrot
37e3671969b516369e2d1c7cab5890b75c489f56
[ "MIT" ]
36
2021-07-02T06:06:42.000Z
2022-01-25T08:31:34.000Z
from app import application from flask import render_template, flash, redirect, url_for from app.forms import LoginForm, RegistrationForm from flask_login import current_user, login_user, logout_user, login_required from app.models import User from werkzeug.urls import url_parse from app import db from flask import r...
30.820896
77
0.748668
dcb19f470c8c4bcc205f8983e32566d117e52c6e
7,218
py
Python
allennlp/allennlp/training/learning_rate_schedulers/slanted_triangular.py
rahular/joint-coref-srl
cd85fb4e11af1a1ea400ed657d0a4511c1d6c6be
[ "MIT" ]
null
null
null
allennlp/allennlp/training/learning_rate_schedulers/slanted_triangular.py
rahular/joint-coref-srl
cd85fb4e11af1a1ea400ed657d0a4511c1d6c6be
[ "MIT" ]
null
null
null
allennlp/allennlp/training/learning_rate_schedulers/slanted_triangular.py
rahular/joint-coref-srl
cd85fb4e11af1a1ea400ed657d0a4511c1d6c6be
[ "MIT" ]
null
null
null
import logging from typing import List from overrides import overrides import torch from allennlp.training.learning_rate_schedulers.learning_rate_scheduler import ( LearningRateScheduler, ) logger = logging.getLogger(__name__) @LearningRateScheduler.register("slanted_triangular") class SlantedTriangular(Learn...
43.221557
97
0.631477
2616e1acb4d6c9923e78026ec8d3168d6109b685
2,495
py
Python
ttslab/tokenizers.py
jkleczar/ttslab
33fe0c3f88c1533816b2602b52e4162760d9c5f0
[ "BSD-3-Clause" ]
null
null
null
ttslab/tokenizers.py
jkleczar/ttslab
33fe0c3f88c1533816b2602b52e4162760d9c5f0
[ "BSD-3-Clause" ]
null
null
null
ttslab/tokenizers.py
jkleczar/ttslab
33fe0c3f88c1533816b2602b52e4162760d9c5f0
[ "BSD-3-Clause" ]
1
2019-02-25T10:27:41.000Z
2019-02-25T10:27:41.000Z
# -*- coding: utf-8 -*- """ Contains tokenizer UttProcessor implementations... Think about ways of documenting requirements properly... """ from __future__ import unicode_literals, division, print_function #Py2 __author__ = "Daniel van Niekerk" __email__ = "dvn.demitasse@gmail.com" import re import unicodedata f...
30.426829
80
0.569138
f9c8157cb6411003eb15133f866d7f7604c1463a
2,118
py
Python
azure-mgmt-recoveryservicesbackup/azure/mgmt/recoveryservicesbackup/models/workload_protectable_item_resource.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
1
2021-09-07T18:36:04.000Z
2021-09-07T18:36:04.000Z
azure-mgmt-recoveryservicesbackup/azure/mgmt/recoveryservicesbackup/models/workload_protectable_item_resource.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
2
2019-10-02T23:37:38.000Z
2020-10-02T01:17:31.000Z
azure-mgmt-recoveryservicesbackup/azure/mgmt/recoveryservicesbackup/models/workload_protectable_item_resource.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
1
2019-06-17T22:18:23.000Z
2019-06-17T22:18:23.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
35.898305
82
0.603399
55a0e111d5f7e519d1889fe413cb26ead5c334e4
7,559
py
Python
openmdao/utils/array_utils.py
fzahle/OpenMDAO
ce53b0a0862ac1162d5daad7b0ca34ae085ee47c
[ "Apache-2.0" ]
null
null
null
openmdao/utils/array_utils.py
fzahle/OpenMDAO
ce53b0a0862ac1162d5daad7b0ca34ae085ee47c
[ "Apache-2.0" ]
null
null
null
openmdao/utils/array_utils.py
fzahle/OpenMDAO
ce53b0a0862ac1162d5daad7b0ca34ae085ee47c
[ "Apache-2.0" ]
null
null
null
""" Utils for dealing with arrays. """ from __future__ import print_function, division import sys import six from six.moves import range import numpy as np def evenly_distrib_idxs(num_divisions, arr_size): """ Return evenly distributed entries for the given array size. Given a number of divisions and t...
27.487273
88
0.584998
a106957cabf3a33dfbcd0e0bbd60b2409c02be2c
2,644
py
Python
imdb_sentiment/vocab.py
shazi4399/machine-learning-example
0e332bc53ff85a11887012f7d5b09be9597bb4ef
[ "Apache-2.0" ]
16
2021-07-09T08:40:50.000Z
2022-03-29T03:21:18.000Z
imdb_sentiment/vocab.py
shazi4399/machine-learning-example
0e332bc53ff85a11887012f7d5b09be9597bb4ef
[ "Apache-2.0" ]
null
null
null
imdb_sentiment/vocab.py
shazi4399/machine-learning-example
0e332bc53ff85a11887012f7d5b09be9597bb4ef
[ "Apache-2.0" ]
15
2021-06-07T11:20:38.000Z
2022-03-08T15:48:50.000Z
""" 文本序列化 """ class Vocab: UNK_TAG = "<UNK>" # 表示未知字符 PAD_TAG = "<PAD>" # 填充符 PAD = 0 UNK = 1 def __init__(self): self.dict = { # 保存词语和对应的数字 self.UNK_TAG: self.UNK, self.PAD_TAG: self.PAD } self.count = {} # 统计词频的 def fit(...
28.73913
104
0.513994
8ee7edb84411d1ee38eeea117c0f0529592c0840
3,677
py
Python
source/svm_vowelsound_classification.py
Hanumanth004/classification_using_svm
be244e82c2d34063f9ef3bdcdc0dd162ab6ce6ca
[ "MIT" ]
null
null
null
source/svm_vowelsound_classification.py
Hanumanth004/classification_using_svm
be244e82c2d34063f9ef3bdcdc0dd162ab6ce6ca
[ "MIT" ]
null
null
null
source/svm_vowelsound_classification.py
Hanumanth004/classification_using_svm
be244e82c2d34063f9ef3bdcdc0dd162ab6ce6ca
[ "MIT" ]
null
null
null
import numpy as np from random import randint import sys import csv from sklearn.svm import SVC from sklearn.model_selection import train_test_split from sklearn.model_selection import GridSearchCV from sklearn.metrics import classification_report from sklearn import preprocessing def str_column_to_float(X_data, col...
26.453237
188
0.645907
cea2bc44a132dfd9908c7addc147c0ea82a82f71
6,768
py
Python
pysilico_server/camera_controller/camera_controller.py
ArcetriAdaptiveOptics/pysilico_server
ebdfa06dbfa889e5f2dde21e44859c8a2868e11a
[ "MIT" ]
null
null
null
pysilico_server/camera_controller/camera_controller.py
ArcetriAdaptiveOptics/pysilico_server
ebdfa06dbfa889e5f2dde21e44859c8a2868e11a
[ "MIT" ]
1
2022-01-25T14:40:46.000Z
2022-01-25T14:40:46.000Z
pysilico_server/camera_controller/camera_controller.py
ArcetriAdaptiveOptics/pysilico_server
ebdfa06dbfa889e5f2dde21e44859c8a2868e11a
[ "MIT" ]
null
null
null
import threading import time import numpy as np from plico.utils.hackerable import Hackerable from plico.utils.snapshotable import Snapshotable from plico.utils.stepable import Stepable from plico.utils.serverinfoable import ServerInfoable from plico.utils.logger import Logger from plico.utils.decorator import override...
36
79
0.617169
eac60f6fda9b54023cf006b5935312f0b584cfc9
4,109
py
Python
packages/watchmen-model/src/watchmen_model/indicator/navigation.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-model/src/watchmen_model/indicator/navigation.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-model/src/watchmen_model/indicator/navigation.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from enum import Enum from typing import List, Optional, Union from pydantic import BaseModel from watchmen_model.common import Auditable, BucketId, DataModel, FactorId, IndicatorId, NavigationId, UserBasedTuple from watchmen_utilities import ArrayHelper, is_not_blank from .indicator import IndicatorAggregateArithmet...
31.128788
117
0.794597
ca9c86b2029cfe365f3b64bc16bf7b5ae7e51745
85,186
py
Python
cripts/core/cripts_mongoengine.py
lakiw/cripts
43f62891a3724e1ec60629887d97c421fb302163
[ "MIT" ]
2
2017-04-06T12:26:11.000Z
2018-11-05T19:17:15.000Z
cripts/core/cripts_mongoengine.py
lakiw/cripts
43f62891a3724e1ec60629887d97c421fb302163
[ "MIT" ]
9
2016-09-28T10:19:10.000Z
2017-02-24T17:58:43.000Z
cripts/core/cripts_mongoengine.py
lakiw/cripts
43f62891a3724e1ec60629887d97c421fb302163
[ "MIT" ]
null
null
null
import datetime import json, yaml import io import csv from bson import json_util, ObjectId from dateutil.parser import parse from django.conf import settings from django.core.urlresolvers import reverse from django.template.loader import render_to_string from mongoengine import Document, EmbeddedDocument, DynamicEmb...
37.444396
107
0.578064
57fd108dad45c5413c131685e8c7865ef9f49411
1,673
py
Python
cogs/reaction.py
MySekwel/discord.py-MySQL
89b343f3619150ff1cf7560ddc31efa3d1e58312
[ "Apache-2.0" ]
2
2021-02-06T15:26:23.000Z
2022-01-29T02:18:01.000Z
cogs/reaction.py
MySekwel/Sakila
89b343f3619150ff1cf7560ddc31efa3d1e58312
[ "Apache-2.0" ]
null
null
null
cogs/reaction.py
MySekwel/Sakila
89b343f3619150ff1cf7560ddc31efa3d1e58312
[ "Apache-2.0" ]
1
2021-01-22T04:47:48.000Z
2021-01-22T04:47:48.000Z
from discord.ext import commands from cogs import user from main import Connection from utils import emoji_dictionary as emojii class React(commands.Cog): def __init__(self, bot): self.bot = bot @commands.Cog.listener() async def on_raw_reaction_add(self, payload): emoji = payload.emoji ...
32.173077
93
0.541542
27168dd0871f6c29ef4e5788a918e9c251850b54
739
py
Python
layerindex/migrations/0026_incfile.py
ebrent8/clear-linux-dissector-web
45f1f9b5a5753ab8b14ed3c99f1c9e68bb97a47c
[ "MIT" ]
3
2019-05-12T21:11:53.000Z
2019-09-15T18:11:21.000Z
layerindex/migrations/0026_incfile.py
ebrent8/clear-linux-dissector-web
45f1f9b5a5753ab8b14ed3c99f1c9e68bb97a47c
[ "MIT" ]
21
2019-06-26T05:01:01.000Z
2022-03-11T23:47:21.000Z
layerindex/migrations/0026_incfile.py
ebrent8/clear-linux-dissector-web
45f1f9b5a5753ab8b14ed3c99f1c9e68bb97a47c
[ "MIT" ]
8
2019-06-13T08:51:12.000Z
2021-02-17T11:14:46.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.11.12 on 2018-11-05 19:50 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('layerindex', '0025_update_retcode'), ] operations...
29.56
125
0.625169
5b454a90ce2a73c430d3450f36f2f5392359d4e8
786
py
Python
pythondata_cpu_blackparrot/system_verilog/black-parrot/external/basejump_stl/testing/bsg_cache/regression_v2/test_store_load2.py
litex-hub/pythondata-cpu-blackparrot
ba50883f12d33e1d834640640c84ddc9329bb68a
[ "BSD-3-Clause" ]
3
2021-05-12T21:57:55.000Z
2021-07-29T19:56:04.000Z
pythondata_cpu_blackparrot/system_verilog/black-parrot/external/basejump_stl/testing/bsg_cache/regression_v2/test_store_load2.py
litex-hub/litex-data-cpu-blackparrot
ba50883f12d33e1d834640640c84ddc9329bb68a
[ "BSD-3-Clause" ]
1
2020-05-02T02:41:24.000Z
2020-05-02T02:44:25.000Z
pythondata_cpu_blackparrot/system_verilog/black-parrot/external/basejump_stl/testing/bsg_cache/regression_v2/test_store_load2.py
litex-hub/litex-data-cpu-blackparrot
ba50883f12d33e1d834640640c84ddc9329bb68a
[ "BSD-3-Clause" ]
2
2020-05-01T08:33:19.000Z
2021-07-29T19:56:12.000Z
import sys import random from test_base import * class TestStoreLoad2(TestBase): def get_random_addr(self): tag = random.randint(0,15) index = random.randint(0,1) block_offset = random.randint(0,3) taddr = self.get_addr(tag,index,block_offset) return taddr def generate(self): self.clear_t...
20.684211
53
0.643766
cf3d0ee4a711e6e470320d304be9cccf5265130f
18,921
py
Python
lib/coginvasion/hood/DistributedDoor.py
theclashingfritz/Cog-Invasion-Online-Dump
2561abbacb3e2e288e06f3f04b935b5ed589c8f8
[ "Apache-2.0" ]
1
2020-03-12T16:44:10.000Z
2020-03-12T16:44:10.000Z
lib/coginvasion/hood/DistributedDoor.py
theclashingfritz/Cog-Invasion-Online-Dump
2561abbacb3e2e288e06f3f04b935b5ed589c8f8
[ "Apache-2.0" ]
null
null
null
lib/coginvasion/hood/DistributedDoor.py
theclashingfritz/Cog-Invasion-Online-Dump
2561abbacb3e2e288e06f3f04b935b5ed589c8f8
[ "Apache-2.0" ]
null
null
null
# uncompyle6 version 3.2.4 # Python bytecode 2.7 (62211) # Decompiled from: Python 2.7.15 (v2.7.15:ca079a3ea3, Apr 30 2018, 16:30:26) [MSC v.1500 64 bit (AMD64)] # Embedded file name: lib.coginvasion.hood.DistributedDoor from direct.directnotify.DirectNotifyGlobal import directNotify from direct.distributed import Dist...
41.132609
261
0.635537
98170e6c9ed6645d6a491d68a78b820c2c6e9e05
764
py
Python
unitpy/units/time.py
jenders97/unitpy
a39fefe1c109b57c174eeba53b877f32f044de0f
[ "MIT" ]
null
null
null
unitpy/units/time.py
jenders97/unitpy
a39fefe1c109b57c174eeba53b877f32f044de0f
[ "MIT" ]
null
null
null
unitpy/units/time.py
jenders97/unitpy
a39fefe1c109b57c174eeba53b877f32f044de0f
[ "MIT" ]
null
null
null
from measurement.base import MeasureBase __all__ = [ 'Time', ] class Time(MeasureBase): """ Time measurements (generally for multidimensional measures). Please do not use this for handling durations of time unrelated to measure classes -- python's built-in datetime module has much better funct...
21.222222
74
0.541885
3b194ef87a1e59efa1782c14ca9a86e69b5e6366
102,213
py
Python
tensorflow/python/keras/engine/base_layer.py
dan-zheng/tensorflow
b4245c36bc9bcb752c0a2118728098b359fd97e2
[ "Apache-2.0" ]
2
2019-08-04T20:28:14.000Z
2019-10-27T23:26:42.000Z
tensorflow/python/keras/engine/base_layer.py
dan-zheng/tensorflow
b4245c36bc9bcb752c0a2118728098b359fd97e2
[ "Apache-2.0" ]
1
2019-08-19T08:03:52.000Z
2019-08-19T08:03:52.000Z
tensorflow/python/keras/engine/base_layer.py
dan-zheng/tensorflow
b4245c36bc9bcb752c0a2118728098b359fd97e2
[ "Apache-2.0" ]
1
2019-08-19T06:53:43.000Z
2019-08-19T06:53:43.000Z
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
40.083529
111
0.679356
58224f09156547002a94ed10da4c14b307ab6c92
1,035
py
Python
codebase_dump/download_notes.py
Hipo/codebase-ultra
6dbb8424809350cced5926f491da0ee9fe0b32f4
[ "MIT" ]
null
null
null
codebase_dump/download_notes.py
Hipo/codebase-ultra
6dbb8424809350cced5926f491da0ee9fe0b32f4
[ "MIT" ]
2
2019-09-27T15:29:33.000Z
2020-06-05T23:10:16.000Z
codebase_dump/download_notes.py
Hipo/codebase-ultra
6dbb8424809350cced5926f491da0ee9fe0b32f4
[ "MIT" ]
null
null
null
import sys import os import time import requests from pathlib import Path USER = os.environ['CODEBASE_USER'] PASSWORD = os.environ['CODEBASE_PASSWORD'] session = requests.sessions.Session() session.auth = (USER, PASSWORD) session.headers['Accept'] = 'application/xml' project = sys.argv[1] project_path = Path(__fil...
27.236842
88
0.724638
1c11c78c290ed54c3326cd3a1508c9417f3a7d43
10,061
py
Python
manimlib/mobject/svg/text_mobject.py
Ermaotie/manim
b25e446042571bf80b47198adfe230e0cb1b9637
[ "MIT" ]
1
2021-07-11T21:38:13.000Z
2021-07-11T21:38:13.000Z
manimlib/mobject/svg/text_mobject.py
Ermaotie/manim
b25e446042571bf80b47198adfe230e0cb1b9637
[ "MIT" ]
null
null
null
manimlib/mobject/svg/text_mobject.py
Ermaotie/manim
b25e446042571bf80b47198adfe230e0cb1b9637
[ "MIT" ]
null
null
null
import copy import hashlib import os import re import typing import warnings from contextlib import contextmanager from pathlib import Path import manimpango from manimlib.constants import * from manimlib.mobject.geometry import Dot from manimlib.mobject.svg.svg_mobject import SVGMobject from manimlib.mobject.types.ve...
33.875421
96
0.567439
27ec7afefaa4a9d4bc9a17f25af223fb37eb65c2
252
py
Python
homeassistant/components/ambient_station/const.py
shanbs/home-assistant
818776d2b4f11e4f51992dc88bc0a6f9055833b2
[ "Apache-2.0" ]
4
2019-07-03T22:36:57.000Z
2019-08-10T15:33:25.000Z
homeassistant/components/ambient_station/const.py
shanbs/home-assistant
818776d2b4f11e4f51992dc88bc0a6f9055833b2
[ "Apache-2.0" ]
7
2019-08-23T05:26:02.000Z
2022-03-11T23:57:18.000Z
homeassistant/components/ambient_station/const.py
shanbs/home-assistant
818776d2b4f11e4f51992dc88bc0a6f9055833b2
[ "Apache-2.0" ]
3
2019-04-28T16:35:45.000Z
2020-05-28T15:21:59.000Z
"""Define constants for the Ambient PWS component.""" DOMAIN = 'ambient_station' ATTR_LAST_DATA = 'last_data' CONF_APP_KEY = 'app_key' DATA_CLIENT = 'data_client' TOPIC_UPDATE = 'update' TYPE_BINARY_SENSOR = 'binary_sensor' TYPE_SENSOR = 'sensor'
18
53
0.757937
c7fb75387aa31cab0cda67d020739f0ed48db823
610,380
py
Python
python/paddle/fluid/layers/nn.py
WeiLi233/Paddle
3d2ec707185c351943446f35a45db425e3be1b53
[ "Apache-2.0" ]
2
2022-01-04T10:51:58.000Z
2022-01-10T12:29:08.000Z
python/paddle/fluid/layers/nn.py
WeiLi233/Paddle
3d2ec707185c351943446f35a45db425e3be1b53
[ "Apache-2.0" ]
1
2020-09-08T01:45:28.000Z
2020-09-08T01:45:28.000Z
python/paddle/fluid/layers/nn.py
WeiLi233/Paddle
3d2ec707185c351943446f35a45db425e3be1b53
[ "Apache-2.0" ]
5
2021-12-10T11:20:06.000Z
2022-02-18T05:18:12.000Z
# Copyright (c) 2018 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
39.681446
946
0.577419
bc4dcd5793fe1750cd4e4b4c8d15b513771e8ffd
7,473
py
Python
mod/parts.py
wtfsystems/ppms
b8c900496cfa263a5c2b7cdfe256174b484f109b
[ "MIT" ]
5
2020-07-29T01:22:30.000Z
2021-08-25T13:41:18.000Z
mod/parts.py
wtfsystems/ppms
b8c900496cfa263a5c2b7cdfe256174b484f109b
[ "MIT" ]
null
null
null
mod/parts.py
wtfsystems/ppms
b8c900496cfa263a5c2b7cdfe256174b484f109b
[ "MIT" ]
null
null
null
################################################################## # # Python Polyphonic MIDI Synthesizer # ################################################################## # # ~~~~~~~[]=¤ԅ(ˊᗜˋ* )੭ # # Filename: parts.py # By: Matthew Evans # https://www.wtfsystems.net/ # # See L...
36.632353
97
0.633882
e6273b510f5f189e8460d82599751fafd4347163
6,814
py
Python
models/wrf_hydro/hydro_dart_py/hydrodartpy/tests/conftest.py
fairaque1999/DART
7490f75cf9800cc841b66d87840ad96c5751b809
[ "Apache-2.0" ]
65
2019-10-16T13:31:06.000Z
2022-03-14T11:52:58.000Z
models/wrf_hydro/hydro_dart_py/hydrodartpy/tests/conftest.py
fairaque1999/DART
7490f75cf9800cc841b66d87840ad96c5751b809
[ "Apache-2.0" ]
283
2019-09-23T15:48:34.000Z
2022-03-31T21:44:41.000Z
models/wrf_hydro/hydro_dart_py/hydrodartpy/tests/conftest.py
fairaque1999/DART
7490f75cf9800cc841b66d87840ad96c5751b809
[ "Apache-2.0" ]
67
2019-09-19T22:13:24.000Z
2022-03-20T15:58:26.000Z
from boltons.iterutils import remap import hydrodartpy import os import pathlib import pytest import shlex import shutil import subprocess import yaml import hydrodartpy.core.setup_experiment_tools as hdp_tools repo_dir = hdp_tools.repo_dir def if_e_rm(path: pathlib.Path): if path.is_file(): _ = path.u...
33.566502
84
0.636924
a36ef29e203b07efb73d96dec77659759d7c7b2f
2,100
py
Python
jdcloud_sdk/services/cdn/apis/QueryPurgeTaskRequest.py
Tanc009/jdcloud-sdk-python
8b045c99bc5b73ca7348e950b6f01e03a27982f5
[ "Apache-2.0" ]
14
2018-04-19T09:53:56.000Z
2022-01-27T06:05:48.000Z
jdcloud_sdk/services/cdn/apis/QueryPurgeTaskRequest.py
Tanc009/jdcloud-sdk-python
8b045c99bc5b73ca7348e950b6f01e03a27982f5
[ "Apache-2.0" ]
15
2018-09-11T05:39:54.000Z
2021-07-02T12:38:02.000Z
jdcloud_sdk/services/cdn/apis/QueryPurgeTaskRequest.py
Tanc009/jdcloud-sdk-python
8b045c99bc5b73ca7348e950b6f01e03a27982f5
[ "Apache-2.0" ]
33
2018-04-20T05:29:16.000Z
2022-02-17T09:10:05.000Z
# coding=utf8 # Copyright 2018 JDCLOUD.COM # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
25.609756
75
0.62381
5df4c0ba005460d8167247ff37c458aca45d8ff7
1,278
py
Python
project_backend/views.py
MichaelDoctor/Portfolio
41d9104ef6d34f8eb146230b19038b445351c713
[ "MIT" ]
null
null
null
project_backend/views.py
MichaelDoctor/Portfolio
41d9104ef6d34f8eb146230b19038b445351c713
[ "MIT" ]
4
2021-06-09T18:02:18.000Z
2022-01-13T03:06:24.000Z
project_backend/views.py
MichaelDoctor/Portfolio
41d9104ef6d34f8eb146230b19038b445351c713
[ "MIT" ]
null
null
null
from rest_framework.views import APIView from rest_framework import permissions from rest_framework.response import Response from rest_framework.authentication import SessionAuthentication, \ BasicAuthentication from django.contrib.auth.models import User class CurrentUser(APIView): permission_classes = (perm...
31.95
74
0.607199
371f9dd5617b720d67b3f6eb236249fbdffd89a0
2,234
py
Python
19_wod/wod.py
bilbatez/tiny_python_projects
4ab831dbaf1b15aa427e70ae8abfa924cd7ecc38
[ "MIT" ]
null
null
null
19_wod/wod.py
bilbatez/tiny_python_projects
4ab831dbaf1b15aa427e70ae8abfa924cd7ecc38
[ "MIT" ]
null
null
null
19_wod/wod.py
bilbatez/tiny_python_projects
4ab831dbaf1b15aa427e70ae8abfa924cd7ecc38
[ "MIT" ]
null
null
null
#! /usr/bin/env python3 """ Author: Albert Julian Tannady Purpose: Chapter 19 - Workout of the Day """ import re import csv import sys import random import argparse from tabulate import tabulate SPLITTER = re.compile(r"(\d+)-(\d+)") def get_args(): """Get command-line arguments""" parser = argparse.Argumen...
25.101124
82
0.582811
dc26a8f886c5010318fa6ee8b946e1531b6ec75b
1,115
py
Python
oeGPIO.py
octopusengine/simple3dscanner
4c62e0ba1bd4b1217106d81ce9ac0a2c6851244a
[ "MIT" ]
33
2016-04-26T07:26:53.000Z
2022-03-14T15:14:20.000Z
oeGPIO.py
octopusengine/simple3dscanner
4c62e0ba1bd4b1217106d81ce9ac0a2c6851244a
[ "MIT" ]
2
2016-09-02T09:48:35.000Z
2016-10-19T08:01:47.000Z
oeGPIO.py
octopusengine/simple3dscanner
4c62e0ba1bd4b1217106d81ce9ac0a2c6851244a
[ "MIT" ]
16
2016-04-25T18:21:20.000Z
2020-03-23T08:16:37.000Z
#!/usr/bin/python # Filename : oeGPIO.py #----------------------------------- ## simple 3d scanner ##---------------------------------- import time from time import sleep import RPi.GPIO as GPIO # for step motor EN2 = 22 DIR2 = 27 STEP2 = 17 dStep=0.00001 #--------------------------------- def oeS...
22.755102
59
0.536323
bd12e83e2e413501e9619d823b6ac2364a4a9411
17,038
py
Python
Savethemblobs/PythonistaKit.framework/pylib/textwrap.py
iApeiron/Savethemblobs_app
38184facf78b55ba89a727be7b1fc08d6085f20c
[ "MIT" ]
19
2017-05-17T16:48:02.000Z
2020-08-18T18:21:45.000Z
Savethemblobs/PythonistaKit.framework/pylib/textwrap.py
iApeiron/Savethemblobs_app
38184facf78b55ba89a727be7b1fc08d6085f20c
[ "MIT" ]
2
2017-05-17T06:41:47.000Z
2017-05-17T17:27:13.000Z
Savethemblobs/PythonistaKit.framework/pylib/textwrap.py
iApeiron/Savethemblobs_app
38184facf78b55ba89a727be7b1fc08d6085f20c
[ "MIT" ]
4
2017-05-17T03:56:25.000Z
2018-11-09T00:00:20.000Z
"""Text wrapping and filling. """ # Copyright (C) 1999-2001 Gregory P. Ward. # Copyright (C) 2002, 2003 Python Software Foundation. # Written by Greg Ward <gward@python.net> __revision__ = "$Id$" import string, re try: _unicode = unicode except NameError: # If Python is built without Unicode support, the u...
39.901639
80
0.605881
6c94c793278ad48da061aa3d0b54d874790512bc
5,128
py
Python
pytorch_projects/common_pytorch/blocks/resnet_direct_regression.py
NiteshBharadwaj/structured_aleatoric_uncertainty_for_human_pose
c74fb7384be562f0a0f1966b3fadf19e13a235f2
[ "MIT" ]
null
null
null
pytorch_projects/common_pytorch/blocks/resnet_direct_regression.py
NiteshBharadwaj/structured_aleatoric_uncertainty_for_human_pose
c74fb7384be562f0a0f1966b3fadf19e13a235f2
[ "MIT" ]
null
null
null
pytorch_projects/common_pytorch/blocks/resnet_direct_regression.py
NiteshBharadwaj/structured_aleatoric_uncertainty_for_human_pose
c74fb7384be562f0a0f1966b3fadf19e13a235f2
[ "MIT" ]
null
null
null
import os from easydict import EasyDict as edict import torch import torch.nn as nn from torchvision.models.resnet import model_zoo, model_urls from common_pytorch.base_modules.resnet import resnet_spec, ResNetBackbone from common_pytorch.base_modules.avg_pool_head import AvgPoolHead, AvgPoolHead2 def get_default_n...
39.751938
120
0.607839
da2f2b613fce29ecdb4107b77005b88cf7f1b4c7
1,503
py
Python
Algorithms_easy/1170. Compare Strings by Frequency of the Smallest Character.py
VinceW0/Leetcode_Python_solutions
09e9720afce21632372431606ebec4129eb79734
[ "Xnet", "X11" ]
4
2020-08-11T20:45:15.000Z
2021-03-12T00:33:34.000Z
Algorithms_easy/1170. Compare Strings by Frequency of the Smallest Character.py
VinceW0/Leetcode_Python_solutions
09e9720afce21632372431606ebec4129eb79734
[ "Xnet", "X11" ]
null
null
null
Algorithms_easy/1170. Compare Strings by Frequency of the Smallest Character.py
VinceW0/Leetcode_Python_solutions
09e9720afce21632372431606ebec4129eb79734
[ "Xnet", "X11" ]
null
null
null
""" 1170. Compare Strings by Frequency of the Smallest Character Easy Let's define a function f(s) over a non-empty string s, which calculates the frequency of the smallest character in s. For example, if s = "dcce" then f(s) = 2 because the smallest character is "c" and its frequency is 2. Now, given string arrays q...
35.785714
221
0.600798
841277ffb7b889e7631853e62b1e76a5ccd0bcfc
18,325
py
Python
test/functional/feature_bip68_sequence.py
durgeshkmr/Libra-Coin
c40293ac5c8f289e4c06b46d0c7f3ca76ff591a6
[ "MIT" ]
null
null
null
test/functional/feature_bip68_sequence.py
durgeshkmr/Libra-Coin
c40293ac5c8f289e4c06b46d0c7f3ca76ff591a6
[ "MIT" ]
null
null
null
test/functional/feature_bip68_sequence.py
durgeshkmr/Libra-Coin
c40293ac5c8f289e4c06b46d0c7f3ca76ff591a6
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) 2014-2018 The Libra Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test BIP68 implementation.""" import time from test_framework.blocktools import create_block, create_co...
45.471464
153
0.639291
ef8a8e2f16bb3a627216a078f7b0c96859b5f665
2,657
py
Python
ciscoisesdk/models/validators/v3_0_0/jsd_b14d63c641e95ac0a8c2da2fb65909c7.py
oianson/ciscoisesdk
c8fe9d80416048dd0ff2241209c4f78ab78c1a4a
[ "MIT" ]
null
null
null
ciscoisesdk/models/validators/v3_0_0/jsd_b14d63c641e95ac0a8c2da2fb65909c7.py
oianson/ciscoisesdk
c8fe9d80416048dd0ff2241209c4f78ab78c1a4a
[ "MIT" ]
null
null
null
ciscoisesdk/models/validators/v3_0_0/jsd_b14d63c641e95ac0a8c2da2fb65909c7.py
oianson/ciscoisesdk
c8fe9d80416048dd0ff2241209c4f78ab78c1a4a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Identity Services Engine createEndpointGroup data model. Copyright (c) 2021 Cisco and/or its affiliates. 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 restric...
34.064103
83
0.619872
a95b5a21c242fa06d26a0dd668881ddb4d056abf
551
py
Python
manage.py
veshitala/DatadiscussForum
8ebe56db680b084093bf9b5bf1d5cff737aa3e3a
[ "MIT" ]
null
null
null
manage.py
veshitala/DatadiscussForum
8ebe56db680b084093bf9b5bf1d5cff737aa3e3a
[ "MIT" ]
38
2019-04-15T13:08:33.000Z
2021-08-23T01:10:19.000Z
manage.py
veshitala/DatadiscussForum
8ebe56db680b084093bf9b5bf1d5cff737aa3e3a
[ "MIT" ]
null
null
null
#!/usr/bin/env python import os import sys if __name__ == '__main__': os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'django_simple_forum.settings') try: from django.core.management import execute_from_command_line except ImportError as exc: raise ImportError( "Couldn't import ...
34.4375
83
0.693285
824145efa851c0bd6bce92a60bcaedd88ebbd042
4,885
py
Python
app/main.py
VadymHutei/claims
0b5522e844b1e3862b71044d3e63acf649e5ceeb
[ "MIT" ]
null
null
null
app/main.py
VadymHutei/claims
0b5522e844b1e3862b71044d3e63acf649e5ceeb
[ "MIT" ]
null
null
null
app/main.py
VadymHutei/claims
0b5522e844b1e3862b71044d3e63acf649e5ceeb
[ "MIT" ]
null
null
null
import datetime from random import choice from flask import Flask, render_template, request, redirect, url_for, make_response from claims_model import Model import conf # Variables tokens = [] app = Flask(__name__) model = Model() # Functions def createRandomString(n=8): abc = 'abcdefghijklmnopqrstuvwxyz01234...
29.077381
116
0.719754
7b719f9de38fc7f9d5f12198e40e3da3ba8da0e4
5,687
py
Python
lib3to2/fixes/fix_unpacking.py
hajs/lib3to2_fork
4a2c734398493c5ff72857f3b849895aecdfc3f7
[ "Apache-2.0" ]
3
2021-03-29T19:21:08.000Z
2021-12-31T09:30:11.000Z
VisionAPI/lib/python3.8/site-packages/lib3to2/fixes/fix_unpacking.py
aniruddhakj/AnswerScriptEvaluation
7b039b84355ecda1d55dc037ccfc4a4d661ad5e3
[ "BSD-3-Clause" ]
1
2019-05-07T11:15:34.000Z
2019-05-07T11:15:34.000Z
env/lib/python2.7/site-packages/lib3to2/fixes/fix_unpacking.py
Eric-Muthemba/qontroverse
1f12d0e3bbdee628a88bac77dc53426ded220755
[ "MIT" ]
2
2019-01-22T01:05:22.000Z
2019-09-27T12:32:22.000Z
""" Fixer for: (a,)* *b (,c)* [,] = s for (a,)* *b (,c)* [,] in d: ... """ from lib2to3 import fixer_base from itertools import count from ..fixer_util import Assign, Comma, Call, Newline, Name, Number, indentation, suitify, commatize, token, syms, Node, Leaf def assignment_source(num_pre, num_post, LISTNAME, ITERNAM...
48.194915
361
0.596976
2a4deec7a8bf5b8445793105ce1500d86ea17af4
79,898
py
Python
stubs/micropython-v1_18-docstubs/pyb.py
mattytrentini/micropython-stubs
4d596273823b69e9e5bcf5fa67f249c374ee0bbc
[ "MIT" ]
null
null
null
stubs/micropython-v1_18-docstubs/pyb.py
mattytrentini/micropython-stubs
4d596273823b69e9e5bcf5fa67f249c374ee0bbc
[ "MIT" ]
null
null
null
stubs/micropython-v1_18-docstubs/pyb.py
mattytrentini/micropython-stubs
4d596273823b69e9e5bcf5fa67f249c374ee0bbc
[ "MIT" ]
null
null
null
""" functions related to the board. See: https://docs.micropython.org/en/v1.18/library/pyb.html The ``pyb`` module contains specific functions related to the board. """ # source version: v1_18 # origin module:: micropython/docs/library/pyb.rst # + module: pyb.Accel.rst # + module: pyb.ADC.rst # + module: pyb.CAN.rst ...
35.700626
137
0.585008
2dcf4ee2b9809e61bebe3b40244d45afa2af9982
264
py
Python
Aula-07/ex012.py
matheussantanads/exercicios-python
3b25db164342e9613f97d2f81ff218a99ab3febe
[ "MIT" ]
1
2020-07-15T02:59:58.000Z
2020-07-15T02:59:58.000Z
Aula-07/ex012.py
matheussantanads/exercicios-python
3b25db164342e9613f97d2f81ff218a99ab3febe
[ "MIT" ]
null
null
null
Aula-07/ex012.py
matheussantanads/exercicios-python
3b25db164342e9613f97d2f81ff218a99ab3febe
[ "MIT" ]
null
null
null
# Curso Python 07 # ---Desafio 12--- # Faça um algoritmo que leia o preço de um produto # e mostre seu novo preço, com 5& de desconto. val = float(input('Digite o preço do produto: ')) print(f'O novo preço do produto com 5% de desconto é de R$ {val*0.95:.2f}')
29.333333
75
0.67803
c02ab334a6323e03902333c923cceead75c45741
1,922
py
Python
scripts/addb-py/chronometry/s3server_integration/s3_overrides.py
swatid-seagate/cortx-motr
ab17cd5f401be08bb4f72790b4d2316ecc99449d
[ "Apache-2.0" ]
null
null
null
scripts/addb-py/chronometry/s3server_integration/s3_overrides.py
swatid-seagate/cortx-motr
ab17cd5f401be08bb4f72790b4d2316ecc99449d
[ "Apache-2.0" ]
1
2022-02-03T09:51:48.000Z
2022-02-03T09:51:48.000Z
scripts/addb-py/chronometry/s3server_integration/s3_overrides.py
swatid-seagate/cortx-motr
ab17cd5f401be08bb4f72790b4d2316ecc99449d
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # # Copyright (c) 2020 Seagate Technology LLC and/or its Affiliates # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # ...
32.576271
116
0.632674
4db58384e3ca9e88e5284baae7bf371e99a79093
3,443
py
Python
sky_anisotropy/reductions.py
viniwiedemann/sky-anisotropy
f183ac11f87755203ede357749d75364af3b958d
[ "MIT" ]
null
null
null
sky_anisotropy/reductions.py
viniwiedemann/sky-anisotropy
f183ac11f87755203ede357749d75364af3b958d
[ "MIT" ]
null
null
null
sky_anisotropy/reductions.py
viniwiedemann/sky-anisotropy
f183ac11f87755203ede357749d75364af3b958d
[ "MIT" ]
null
null
null
import itertools from collections import OrderedDict import sky_anisotropy as sa import numpy as np import xarray as xr import healpy as hp from dask.diagnostics import ProgressBar import dask.array as da import dask.dataframe as dd from dask import compute def digitize_columns(partition, col_to_bins): for col ...
32.481132
85
0.636073
cf7df2474da6895903c23431ea6365a161487a53
6,558
py
Python
sdk/python/pulumi_azure_nextgen/apimanagement/v20180601preview/certificate.py
pulumi/pulumi-azure-nextgen
452736b0a1cf584c2d4c04666e017af6e9b2c15c
[ "Apache-2.0" ]
31
2020-09-21T09:41:01.000Z
2021-02-26T13:21:59.000Z
sdk/python/pulumi_azure_nextgen/apimanagement/v20180601preview/certificate.py
pulumi/pulumi-azure-nextgen
452736b0a1cf584c2d4c04666e017af6e9b2c15c
[ "Apache-2.0" ]
231
2020-09-21T09:38:45.000Z
2021-03-01T11:16:03.000Z
sdk/python/pulumi_azure_nextgen/apimanagement/v20180601preview/certificate.py
pulumi/pulumi-azure-nextgen
452736b0a1cf584c2d4c04666e017af6e9b2c15c
[ "Apache-2.0" ]
4
2020-09-29T14:14:59.000Z
2021-02-10T20:38:16.000Z
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from ... import _utilities, _tables __a...
45.541667
784
0.65584
6fab1da81fe43a3041403cb96261ed2eed29054f
2,481
py
Python
dags/kv_uploader_dag.py
nsutton00/starthinker
e597d679a95ca85a21af9cf4df3ff935ca34abf8
[ "Apache-2.0" ]
null
null
null
dags/kv_uploader_dag.py
nsutton00/starthinker
e597d679a95ca85a21af9cf4df3ff935ca34abf8
[ "Apache-2.0" ]
null
null
null
dags/kv_uploader_dag.py
nsutton00/starthinker
e597d679a95ca85a21af9cf4df3ff935ca34abf8
[ "Apache-2.0" ]
null
null
null
########################################################################### # # Copyright 2019 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org...
29.188235
105
0.600564
9b53d64bc81fe3135c7f596d68bf88330dd5d7f2
2,637
py
Python
CoppeliaSim_Edu_V4_1_0_Ubuntu18_04/programming/libPlugin/simStubsGen/lua_to_xml.py
YueErro/ModernRobotics
82345c04157c1322b24553bf00abd1f2b03281a5
[ "MIT" ]
39
2018-08-28T21:28:07.000Z
2022-03-12T10:30:40.000Z
external/v_repStubsGen/lua_to_xml.py
kasperg3/vrep_ros_interface
8e68a1b37591e7fe8576ca8b8cce9d6859a6bf5e
[ "BSD-3-Clause" ]
175
2017-06-29T09:37:43.000Z
2021-07-09T12:55:28.000Z
external/v_repStubsGen/lua_to_xml.py
kasperg3/vrep_ros_interface
8e68a1b37591e7fe8576ca8b8cce9d6859a6bf5e
[ "BSD-3-Clause" ]
14
2018-07-12T06:59:48.000Z
2021-03-31T08:27:39.000Z
from sys import argv, exit import re if len(argv) != 3: print('usage: {} <input-lua-file> <output-xml-file>'.format(argv[0])) exit(1) luafile = argv[1] outfile = argv[2] fun = None args, rets = [], [] with open(outfile, 'w') as fout: fout.write('<?xml version="1.0" encoding="UTF-8" standalone="no" ?>\n'...
36.625
87
0.406523
f84e04cc7107778c9b9a61eea2bfc836f40bdc5d
325
py
Python
pyjobs/core/migrations/0012_remove_profile_phone.py
Mdslino/PyJobs
d2496d58067503c3304a6c59052238b1f097472b
[ "BSD-3-Clause" ]
132
2017-10-27T23:54:47.000Z
2022-03-15T12:10:10.000Z
pyjobs/core/migrations/0012_remove_profile_phone.py
Mdslino/PyJobs
d2496d58067503c3304a6c59052238b1f097472b
[ "BSD-3-Clause" ]
129
2017-09-05T04:22:50.000Z
2022-03-12T01:06:49.000Z
pyjobs/core/migrations/0012_remove_profile_phone.py
Mdslino/PyJobs
d2496d58067503c3304a6c59052238b1f097472b
[ "BSD-3-Clause" ]
82
2017-10-28T00:14:04.000Z
2021-07-27T20:00:40.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.11.5 on 2018-04-13 23:30 from __future__ import unicode_literals from django.db import migrations class Migration(migrations.Migration): dependencies = [("core", "0011_auto_20180413_2320")] operations = [migrations.RemoveField(model_name="profile", name="phon...
25
77
0.732308
cfd33b9dc4d628986d2742047594e934ea9f7792
2,274
py
Python
tests/test_worker_serialize.py
mozaiques/zombase
fc8dbfdad7cdb1975fac63030fc6f6c20b6df260
[ "MIT" ]
3
2015-01-22T21:54:49.000Z
2022-02-13T14:22:00.000Z
tests/test_worker_serialize.py
mozaiques/zombase
fc8dbfdad7cdb1975fac63030fc6f6c20b6df260
[ "MIT" ]
null
null
null
tests/test_worker_serialize.py
mozaiques/zombase
fc8dbfdad7cdb1975fac63030fc6f6c20b6df260
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from zombase import worker import test_worker class InvalidWorker(worker.MappingManagingWorker): pass class Worker(worker.MappingManagingWorker): def _serialize_one(self, item): return {'a_prop': item.a_prop} class TestInvalidWorker(test_worker.BaseTestWorker): def t...
29.153846
76
0.669745
4fb12f36b5ef1e79fa440554ef86c56934a3e114
11,385
py
Python
test/test_cell.py
azagajewski/ColiCoords
fa26e46971e24ff582c4d33331c5b8181f605c9f
[ "MIT" ]
null
null
null
test/test_cell.py
azagajewski/ColiCoords
fa26e46971e24ff582c4d33331c5b8181f605c9f
[ "MIT" ]
null
null
null
test/test_cell.py
azagajewski/ColiCoords
fa26e46971e24ff582c4d33331c5b8181f605c9f
[ "MIT" ]
null
null
null
from test.testcase import ArrayTestCase from test.test_functions import load_testdata from colicoords.preprocess import data_to_cells from colicoords.data_models import Data from colicoords.support import pad_cell from colicoords.cell import CellList, Cell from colicoords.fileIO import load import os import sys...
43.454198
123
0.618621
c7efb9ed7449394c573acbaa1492998a9b1bbb18
1,756
py
Python
apps/songs/patches.py
Torniojaws/vortech-backend
f775a97eeae089fa720088d86fe92d40bc5d65bc
[ "MIT" ]
null
null
null
apps/songs/patches.py
Torniojaws/vortech-backend
f775a97eeae089fa720088d86fe92d40bc5d65bc
[ "MIT" ]
93
2017-09-01T22:24:10.000Z
2021-12-22T14:07:06.000Z
apps/songs/patches.py
Torniojaws/vortech-backend
f775a97eeae089fa720088d86fe92d40bc5d65bc
[ "MIT" ]
null
null
null
"""To implement the RFC 6902 logic for patches, there are some various complex methods needed. For clarity, they are in this separate file as helper methods.""" from copy import deepcopy from jsonpatch import JsonPatch def patch_item(song, patchdata, **kwargs): """This is used to run patches on the datab...
37.361702
95
0.643508
256938d9027345a88523d27064d66f9053052ad1
759
py
Python
functional_spec/src/cars.py
sahasrara62/parking_lot
ada8f14ce2bf0d9ccd9472ab1c5d4376f1e2a85e
[ "Apache-2.0" ]
3
2020-01-30T11:58:11.000Z
2021-03-24T06:43:49.000Z
functional_spec/src/cars.py
sahasrara62/parking_lot
ada8f14ce2bf0d9ccd9472ab1c5d4376f1e2a85e
[ "Apache-2.0" ]
null
null
null
functional_spec/src/cars.py
sahasrara62/parking_lot
ada8f14ce2bf0d9ccd9472ab1c5d4376f1e2a85e
[ "Apache-2.0" ]
5
2019-10-20T18:29:34.000Z
2022-01-22T04:12:55.000Z
__all__ = ['Car'] class Car(object): """ defining the property of the car property include : car "registration number" and "colour" of the car """ def __init__(self, registration_number, color): """ initialising the car object :param registration_number: registation numb...
21.083333
72
0.578393
8c72269eb6344355df7d62a8b5e36378f967ad06
129
py
Python
routes/web.py
josephmancuso/ambient
193152d72ca2302f2167ac5e4afcc50fa48d0bc2
[ "MIT" ]
5
2020-06-07T14:20:50.000Z
2020-07-24T15:20:42.000Z
routes/web.py
josephmancuso/ambient
193152d72ca2302f2167ac5e4afcc50fa48d0bc2
[ "MIT" ]
null
null
null
routes/web.py
josephmancuso/ambient
193152d72ca2302f2167ac5e4afcc50fa48d0bc2
[ "MIT" ]
null
null
null
"""Web Routes.""" from masonite.routes import Route ROUTES = [ Route.get('/', 'WelcomeController@show').name('welcome'), ]
16.125
61
0.651163
805a3334542dd9d9f7ce49999346e1053eaf9e02
5,149
py
Python
code_for_hw5/code_for_hw5/modules_disp.py
codr-oneci/Machine-Learning-Algorithms
9d90fc4abe8646e86c38c69a2969b23e501a792e
[ "MIT" ]
null
null
null
code_for_hw5/code_for_hw5/modules_disp.py
codr-oneci/Machine-Learning-Algorithms
9d90fc4abe8646e86c38c69a2969b23e501a792e
[ "MIT" ]
null
null
null
code_for_hw5/code_for_hw5/modules_disp.py
codr-oneci/Machine-Learning-Algorithms
9d90fc4abe8646e86c38c69a2969b23e501a792e
[ "MIT" ]
null
null
null
import pdb import numpy as np import random import matplotlib import matplotlib.pyplot as plt def classify(X, Y, nn, it=10000, lr=0.005): D = X.shape[0] N = X.shape[1] O = Y.shape[0] # Modifies the weights and biases nn.sgd(X, Y, it, lr) # Draw it... def predict(x): return nn.module...
34.326667
76
0.540882
35ba03d36d6034ab09960f756ec38d5915a47aea
69,265
py
Python
samples/contrib/e2e-outlier-drift-explainer/seldon/seldon_e2e_cifar10.kale.nfs.py
evan-hataishi/kfp-tekton
6e1f367841c7add4ca13e5472220939846da81b0
[ "Apache-2.0" ]
null
null
null
samples/contrib/e2e-outlier-drift-explainer/seldon/seldon_e2e_cifar10.kale.nfs.py
evan-hataishi/kfp-tekton
6e1f367841c7add4ca13e5472220939846da81b0
[ "Apache-2.0" ]
1,720
2021-01-25T09:32:00.000Z
2022-03-31T08:09:51.000Z
samples/contrib/e2e-outlier-drift-explainer/seldon/seldon_e2e_cifar10.kale.nfs.py
evan-hataishi/kfp-tekton
6e1f367841c7add4ca13e5472220939846da81b0
[ "Apache-2.0" ]
null
null
null
import kfp.dsl as dsl import json import kfp.components as comp from collections import OrderedDict from kubernetes import client as k8s_client def setup(MINIO_ACCESS_KEY: str, MINIO_HOST: str, MINIO_MODEL_BUCKET: str, MINIO_SECRET_KEY: str): pipeline_parameters_block = ''' MINIO_ACCESS_KEY = "{}" MINIO_H...
37.259279
432
0.675464
65e83c298bc19d970f2f3315e8442311264e80b0
2,825
py
Python
catalyst/contrib/models/encoder/resnet.py
andrey-avdeev/catalyst
fd17aaba7775c99b7e2b1ce86e60aa8f2379acc3
[ "Apache-2.0" ]
1
2019-12-15T18:29:15.000Z
2019-12-15T18:29:15.000Z
catalyst/contrib/models/encoder/resnet.py
andrey-avdeev/catalyst
fd17aaba7775c99b7e2b1ce86e60aa8f2379acc3
[ "Apache-2.0" ]
null
null
null
catalyst/contrib/models/encoder/resnet.py
andrey-avdeev/catalyst
fd17aaba7775c99b7e2b1ce86e60aa8f2379acc3
[ "Apache-2.0" ]
1
2020-04-16T10:20:00.000Z
2020-04-16T10:20:00.000Z
from typing import Union # isort:skip from pathlib import Path import torch import torch.nn as nn import torchvision from catalyst import utils from catalyst.contrib.modules import Flatten from catalyst.contrib.registry import MODULES class ResnetEncoder(nn.Module): def __init__( self, arch: st...
34.036145
79
0.587965
428aff44eb71fc3533446e292de15f75c9a74eb2
3,823
py
Python
src/dct/cli.py
jochem725/deepracer-camera-telemetry
e0ceb227cb937d5e502a6231c9b4ebde6927dc64
[ "MIT" ]
null
null
null
src/dct/cli.py
jochem725/deepracer-camera-telemetry
e0ceb227cb937d5e502a6231c9b4ebde6927dc64
[ "MIT" ]
null
null
null
src/dct/cli.py
jochem725/deepracer-camera-telemetry
e0ceb227cb937d5e502a6231c9b4ebde6927dc64
[ "MIT" ]
1
2021-10-02T17:27:33.000Z
2021-10-02T17:27:33.000Z
import click import requests import json import logging import sys import socket import os from dct.util.silverstone import DeepRacerCar from dct.camera.stream import DeepRacerMJPEGStream, StreamConsumer from dct.visualizations.base import BaseFrameVisualizer from dct.visualizations.hud import HudOverlay from dct.vis...
27.702899
87
0.644782
9629e4932c742a08741a3a472320c42f1f57c348
1,356
py
Python
__init__.py
devs-mycroft/skill-speak
587eb47c4e60ac62a225b2cafed38e634696032b
[ "Apache-2.0" ]
5
2018-11-14T19:31:11.000Z
2021-02-17T23:28:54.000Z
__init__.py
devs-mycroft/skill-speak
587eb47c4e60ac62a225b2cafed38e634696032b
[ "Apache-2.0" ]
9
2017-12-21T00:10:48.000Z
2022-02-22T05:52:40.000Z
__init__.py
devs-mycroft/skill-speak
587eb47c4e60ac62a225b2cafed38e634696032b
[ "Apache-2.0" ]
22
2017-05-02T22:53:50.000Z
2021-11-24T21:49:12.000Z
# Copyright 2016 Mycroft AI Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writin...
30.818182
74
0.693215
e716fa3f2eab14574e864c9101f4e6eece00c86a
2,853
py
Python
taurex/binning/simplebinner.py
rychallener/TauREx3_public
eb0eeeeca8f47e5e7d64d8d70b43a3af370b7677
[ "BSD-3-Clause" ]
10
2019-12-18T09:19:16.000Z
2021-06-21T11:02:06.000Z
taurex/binning/simplebinner.py
rychallener/TauREx3_public
eb0eeeeca8f47e5e7d64d8d70b43a3af370b7677
[ "BSD-3-Clause" ]
10
2020-03-24T18:02:15.000Z
2021-08-23T20:32:09.000Z
taurex/binning/simplebinner.py
rychallener/TauREx3_public
eb0eeeeca8f47e5e7d64d8d70b43a3af370b7677
[ "BSD-3-Clause" ]
8
2020-03-26T14:16:42.000Z
2021-12-18T22:11:25.000Z
from .binner import Binner from taurex.util import bindown from taurex.util.util import compute_bin_edges, wnwidth_to_wlwidth from taurex import OutputSize class SimpleBinner(Binner): """ Bins to a wavenumber grid given by ``wngrid``. The method places flux into the correct bins using histogramming me...
31.351648
75
0.599019
61f2193d6c3963bcc4002919d59de6a4525e4e7b
3,104
py
Python
setup.py
gerrymanoim/distributed
ac35e0f8104baaccfb44f98b67a48ee359069316
[ "BSD-3-Clause" ]
3
2021-05-27T07:40:11.000Z
2021-05-27T07:40:16.000Z
setup.py
happyLeecz/DaskServerless
c1ddfe678fedc7f7ecb6eabb784b967f71a2054a
[ "BSD-3-Clause" ]
1
2019-04-25T14:13:48.000Z
2019-04-25T16:54:54.000Z
setup.py
happyLeecz/DaskServerless
c1ddfe678fedc7f7ecb6eabb784b967f71a2054a
[ "BSD-3-Clause" ]
2
2019-04-24T17:06:29.000Z
2020-09-02T10:48:07.000Z
#!/usr/bin/env python import os import sys from setuptools import find_packages, setup from setuptools.extension import Extension import versioneer requires = open("requirements.txt").read().strip().split("\n") setup_requires = [] install_requires = [] extras_require = {} for r in requires: if ";" in r: ...
28.740741
85
0.616624
f022374a59090c7e70d1af21df023976e80004e5
1,360
py
Python
reviser/commands/sheller.py
rocketboosters/reviser
03ee5eadd35db78cf122e48fac4d48981518af11
[ "MIT" ]
null
null
null
reviser/commands/sheller.py
rocketboosters/reviser
03ee5eadd35db78cf122e48fac4d48981518af11
[ "MIT" ]
null
null
null
reviser/commands/sheller.py
rocketboosters/reviser
03ee5eadd35db78cf122e48fac4d48981518af11
[ "MIT" ]
null
null
null
""" Macro command to convert to interactive shell operation. This is a special command to use in run command groups/macros to start interactive command mode for the terminal. Useful when in scenarios where you wish to prefix an interactive session with commonly executed commands. For example, if you want to select cer...
34.871795
87
0.754412
eecb24ca46a630491f547e61d79f7c2899b5a66d
379
py
Python
taxonomy/templatetags/pagination.py
vdejager/pipetaxon
2dcf2f4cf3fd9ca8677ba313c0191df45ccc3f77
[ "MIT" ]
18
2018-11-26T03:04:18.000Z
2021-05-12T16:25:27.000Z
taxonomy/templatetags/pagination.py
vdejager/pipetaxon
2dcf2f4cf3fd9ca8677ba313c0191df45ccc3f77
[ "MIT" ]
13
2018-11-26T17:41:41.000Z
2022-02-19T19:49:51.000Z
taxonomy/templatetags/pagination.py
vdejager/pipetaxon
2dcf2f4cf3fd9ca8677ba313c0191df45ccc3f77
[ "MIT" ]
3
2018-11-26T15:20:15.000Z
2020-11-27T07:26:17.000Z
from django import template register = template.Library() def pagination(value, offset): current_page_number = value.number lower = current_page_number - offset higher = current_page_number + offset if lower < 0: lower = 0 higher = offset + offset return "{0}:{1}".format(lower, ...
19.947368
48
0.686016
9c194ae02cf369e888b212ddde338633a8277830
2,696
py
Python
test/test_LEB128.py
TrueBitFoundation/python-offchain
ecc1a68b50cddbc539110311916f1200a669eecd
[ "MIT" ]
2
2017-09-27T10:19:44.000Z
2018-01-02T06:10:23.000Z
test/test_LEB128.py
TrueBitFoundation/python-offchain
ecc1a68b50cddbc539110311916f1200a669eecd
[ "MIT" ]
1
2018-01-30T13:44:55.000Z
2018-01-30T13:44:55.000Z
test/test_LEB128.py
TrueBitFoundation/python-offchain
ecc1a68b50cddbc539110311916f1200a669eecd
[ "MIT" ]
1
2017-12-01T18:14:07.000Z
2017-12-01T18:14:07.000Z
import sys sys.path.append('../') from utils import * from binascii import hexlify vals = [-624485, -1, 0, 1, 624485] uResults = [None, None, bytes([0x00]), bytes([0x01]), bytes([0xE5, 0x8E, 0x26])] sResults = [bytes([0x9B, 0xF1, 0x59]), bytes([0x7F]), ...
32.481928
79
0.517804
d4411fd37edf231ce67fb11f67770e8a78dbb302
223
py
Python
aio_statsd/utlis.py
AdamLeyshon/aiostatsd
4193e1e2674692ae76555a3fdc85d280d54a2102
[ "Apache-2.0" ]
null
null
null
aio_statsd/utlis.py
AdamLeyshon/aiostatsd
4193e1e2674692ae76555a3fdc85d280d54a2102
[ "Apache-2.0" ]
null
null
null
aio_statsd/utlis.py
AdamLeyshon/aiostatsd
4193e1e2674692ae76555a3fdc85d280d54a2102
[ "Apache-2.0" ]
null
null
null
import asyncio import sys __all__ = ["get_event_loop"] def get_event_loop() -> asyncio.AbstractEventLoop: if sys.version_info >= (3, 7): return asyncio.get_running_loop() return asyncio.get_event_loop()
18.583333
50
0.713004
defc699b1e9d62cdc8b04714a00cf1edf7dc65c6
596
py
Python
casemgmt/management/commands/oso_shell.py
saolsen/oso-casemgmt-django
05e7e1d54c0ca274341df3fa53c82b9735c377c6
[ "MIT" ]
3
2020-12-18T13:52:16.000Z
2021-02-17T17:05:28.000Z
casemgmt/management/commands/oso_shell.py
saolsen/oso-casemgmt-django
05e7e1d54c0ca274341df3fa53c82b9735c377c6
[ "MIT" ]
1
2021-04-13T18:58:17.000Z
2021-04-13T18:58:17.000Z
casemgmt/management/commands/oso_shell.py
saolsen/oso-casemgmt-django
05e7e1d54c0ca274341df3fa53c82b9735c377c6
[ "MIT" ]
2
2020-12-21T15:10:29.000Z
2021-02-17T19:22:05.000Z
import traceback from django.core.management.base import BaseCommand # Example: # python manage.py oso_shell class Command(BaseCommand): help = 'Start OSO Authorization Policy REPL Shell' def handle(self, *args, **options): from django_oso.oso import Oso while True: # Run OSO (...
28.380952
119
0.61745
662398fafbcd096657a8e0a87bcee81cd9e099df
1,408
py
Python
flowLossPlot.py
arfc/uiuc-arfc-2017-01
99e79735bc9ce977df4c4135e7b59bbb2a6b759c
[ "CC-BY-4.0" ]
null
null
null
flowLossPlot.py
arfc/uiuc-arfc-2017-01
99e79735bc9ce977df4c4135e7b59bbb2a6b759c
[ "CC-BY-4.0" ]
null
null
null
flowLossPlot.py
arfc/uiuc-arfc-2017-01
99e79735bc9ce977df4c4135e7b59bbb2a6b759c
[ "CC-BY-4.0" ]
null
null
null
#!/usr/bin/env python3 # makes a plot for the flow loss case # note: you need to comment out the header on the csv file import matplotlib.pyplot as pl from matplotlib import rc import numpy as np # directory with output data: outdir = ('/home/gav/projects/moltres/problems/' 'LOFA/') data = np.loadtxt(outdir...
31.288889
79
0.673295
35ecf8435c079fa59fa726fb6706894219e729f0
2,495
py
Python
grpcHandle/servicefunction/pieces_defects_process_service_function.py
dodoyuan/docker-airflow-datax
3fb37a34dd61b6694bf1845219f9392089424645
[ "Apache-2.0" ]
10
2018-12-01T20:15:00.000Z
2022-02-28T05:11:50.000Z
grpcHandle/servicefunction/pieces_defects_process_service_function.py
dodoyuan/docker-airflow-datax
3fb37a34dd61b6694bf1845219f9392089424645
[ "Apache-2.0" ]
null
null
null
grpcHandle/servicefunction/pieces_defects_process_service_function.py
dodoyuan/docker-airflow-datax
3fb37a34dd61b6694bf1845219f9392089424645
[ "Apache-2.0" ]
2
2020-10-12T09:37:54.000Z
2021-02-04T03:23:35.000Z
import settings import os from servicefunction.utils import get_format_time, write_file import subprocess log_file_dir = settings.AOI_LOG_DIR def exec_ftpdownloader_command(): pva_home = settings.PVA_HOME_PATH psa_home = settings.PSA_HOME_PATH oneday = settings.FTP_ONE_DAY days = settings.FTP_DAYS ...
35.642857
119
0.652505
4b93c7e6e153b8710df931b4d25c1cf600450f38
3,143
py
Python
gonzo/connectors/twitter/tests.py
paulcwatts/1hph
407337955121c3f59b4621acb392e6c23b57ae8e
[ "BSD-3-Clause" ]
1
2016-10-03T05:29:12.000Z
2016-10-03T05:29:12.000Z
gonzo/connectors/twitter/tests.py
paulcwatts/1hph
407337955121c3f59b4621acb392e6c23b57ae8e
[ "BSD-3-Clause" ]
null
null
null
gonzo/connectors/twitter/tests.py
paulcwatts/1hph
407337955121c3f59b4621acb392e6c23b57ae8e
[ "BSD-3-Clause" ]
null
null
null
from urlparse import urlparse from django.contrib.auth.models import User from django.test import TestCase from django.test.client import Client from gonzo.connectors import twitter from gonzo.connectors.twitter.models import TwitterProfile class TwitterTest(TestCase): def setUp(self): self.is_enabled = ...
40.294872
79
0.617881
c1c09f4e739f0a3ddd7390cc4e21dd606601cadb
4,455
py
Python
tests/experimental/test_implementations.py
rlbellaire/hydra-zen
e6832542162e6eb252112d1f4990b255423eef7f
[ "MIT" ]
null
null
null
tests/experimental/test_implementations.py
rlbellaire/hydra-zen
e6832542162e6eb252112d1f4990b255423eef7f
[ "MIT" ]
null
null
null
tests/experimental/test_implementations.py
rlbellaire/hydra-zen
e6832542162e6eb252112d1f4990b255423eef7f
[ "MIT" ]
null
null
null
# Copyright (c) 2021 Massachusetts Institute of Technology # SPDX-License-Identifier: MIT from pathlib import Path import pytest from hydra import compose, initialize from hydra.core.config_store import ConfigStore from omegaconf.omegaconf import OmegaConf from hydra_zen import builds, instantiate from hydra_zen.exp...
28.557692
83
0.670258
9016d2f9eca64e4fad44ac1c09e6b7676671e4e4
4,046
py
Python
src/python/pants/engine/selectors.py
sammy-1234/pants
889016952a248cf229c78c014d9f6c95422d98b8
[ "Apache-2.0" ]
1
2020-08-26T03:30:31.000Z
2020-08-26T03:30:31.000Z
src/python/pants/engine/selectors.py
sammy-1234/pants
889016952a248cf229c78c014d9f6c95422d98b8
[ "Apache-2.0" ]
1
2021-09-02T14:16:37.000Z
2021-09-02T14:16:37.000Z
src/python/pants/engine/selectors.py
sammy-1234/pants
889016952a248cf229c78c014d9f6c95422d98b8
[ "Apache-2.0" ]
null
null
null
# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). import ast from pants.util.objects import SubclassesOf, TypeConstraint, datatype _type_field = SubclassesOf(type) class Get(datatype([ ('product', _type_field), ('subject_decl...
39.666667
99
0.681167
886b821e869b0ede85173417b484ddeb8d42934b
1,475
py
Python
server/config/settings/components/paths.py
NikitaGrishchenko/csp-tender-hack-server
56055f51bf472f0f1e56b419a48d993cc91e0f3a
[ "MIT" ]
null
null
null
server/config/settings/components/paths.py
NikitaGrishchenko/csp-tender-hack-server
56055f51bf472f0f1e56b419a48d993cc91e0f3a
[ "MIT" ]
null
null
null
server/config/settings/components/paths.py
NikitaGrishchenko/csp-tender-hack-server
56055f51bf472f0f1e56b419a48d993cc91e0f3a
[ "MIT" ]
null
null
null
"""Paths settings""" import os # Base CONFIG_DIR = os.path.dirname( os.path.dirname(os.path.dirname(os.path.abspath(__file__))) ) BACKEND_DIR = os.path.dirname(CONFIG_DIR) PROJECT_DIR = os.path.dirname(BACKEND_DIR) ENV_FILE = os.path.join(PROJECT_DIR, ".env") ENV_FILE_EXAMPLE = os.path.join(PROJECT_DIR, ".env.exa...
32.777778
72
0.753898
17a294fca2a2f7688f941043a30db342d62dd39e
3,179
py
Python
examples/android/tflite_convertor/tfltransfer/optimizers/adam.py
g-pichler/flower
e455cdc3678921ece960287a0e1ae5123500c948
[ "Apache-2.0" ]
null
null
null
examples/android/tflite_convertor/tfltransfer/optimizers/adam.py
g-pichler/flower
e455cdc3678921ece960287a0e1ae5123500c948
[ "Apache-2.0" ]
null
null
null
examples/android/tflite_convertor/tfltransfer/optimizers/adam.py
g-pichler/flower
e455cdc3678921ece960287a0e1ae5123500c948
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
39.246914
84
0.622837
7277cd3e772077b247bbacdecd6e9c2fc12d740c
3,082
py
Python
electroncash/version.py
damascene/Electron-Cash-SLP
3819046ecbd585aa8f5fac1c58550046dd027266
[ "MIT" ]
53
2019-01-14T17:49:47.000Z
2022-03-29T13:51:43.000Z
electroncash/version.py
damascene/Electron-Cash-SLP
3819046ecbd585aa8f5fac1c58550046dd027266
[ "MIT" ]
186
2019-01-10T17:33:15.000Z
2022-02-01T02:14:41.000Z
electroncash/version.py
damascene/Electron-Cash-SLP
3819046ecbd585aa8f5fac1c58550046dd027266
[ "MIT" ]
54
2019-01-23T21:47:10.000Z
2022-01-31T20:44:53.000Z
PACKAGE_VERSION = '3.6.6' # version of the client package, this is used by update_checker.py PRE_RELEASE_TAG = '3.6.7-dev6' # title bar tag used for pre-releases, doesn't affect update_checker.py PROTOCOL_VERSION = '1.4' # protocol version requested EXTENSIONS = { 'SLP': "1" } # The hash of the Electrum mnemonic se...
39.012658
103
0.580143
99219709e7d369c4a5f2446fc74d84a7b5bd4026
1,412
py
Python
things2/MusicXML/app.py
mvasilkov/scrapheap
53e30b88879ab8e4d80867b0ec7fa631ce46e55e
[ "MIT" ]
null
null
null
things2/MusicXML/app.py
mvasilkov/scrapheap
53e30b88879ab8e4d80867b0ec7fa631ce46e55e
[ "MIT" ]
null
null
null
things2/MusicXML/app.py
mvasilkov/scrapheap
53e30b88879ab8e4d80867b0ec7fa631ce46e55e
[ "MIT" ]
null
null
null
from functools import cmp_to_key from math import floor from magenta.music import constants from magenta.music.musicxml_parser import Tempo from magenta.music.musicxml_reader import musicxml_file_to_sequence_proto def _parse(self): self.qpm = constants.DEFAULT_QUARTERS_PER_MINUTE self.time_position = self.st...
24.344828
88
0.624646
9879c2c06585ca3949d518269fa79e91f022c684
544
py
Python
backend/innovations/models.py
Yandjatg/ragproject
36acdd5a8d2f9593ca5b7da272346bddba8fa9bd
[ "MIT" ]
null
null
null
backend/innovations/models.py
Yandjatg/ragproject
36acdd5a8d2f9593ca5b7da272346bddba8fa9bd
[ "MIT" ]
null
null
null
backend/innovations/models.py
Yandjatg/ragproject
36acdd5a8d2f9593ca5b7da272346bddba8fa9bd
[ "MIT" ]
null
null
null
from django.db import models # Create your models here. class Innovation(models.Model): image = models.ImageField(max_length=1000) title = models.CharField(max_length=100) description = models.TextField() def get_image(self): return self.image def __str__(self): return self.imag...
19.428571
46
0.665441
5afff0d51d55ea5a77e9fa866cfbd85b6718a5aa
2,553
py
Python
workflow/utils_link_pred.py
skojaku/residual2vec
ea10caae3c2671953fbc295358040baa36ee1547
[ "MIT" ]
2
2022-01-20T18:03:11.000Z
2022-03-04T08:21:42.000Z
workflow/utils_link_pred.py
skojaku/residual2vec
ea10caae3c2671953fbc295358040baa36ee1547
[ "MIT" ]
null
null
null
workflow/utils_link_pred.py
skojaku/residual2vec
ea10caae3c2671953fbc295358040baa36ee1547
[ "MIT" ]
null
null
null
import numpy as np from scipy import sparse def fit_glove_bias(A, emb): N = A.shape[0] row_sum = np.array(A.sum(axis=1)).reshape(-1).astype(float) col_sum = np.array(A.sum(axis=0)).reshape(-1).astype(float) emb_sum = np.array(emb @ np.array(np.sum(emb, axis=0)).reshape((-1, 1))).reshape(-1) row_s...
27.159574
88
0.50803
8cf5739399037582786f7c3654f9b970d97da878
1,107
py
Python
models/problem_3c_unscaled.py
taoyilee/ml_final_project
0ac5ee3938d70e9ffcae8e186e0ef1a621391980
[ "Unlicense" ]
null
null
null
models/problem_3c_unscaled.py
taoyilee/ml_final_project
0ac5ee3938d70e9ffcae8e186e0ef1a621391980
[ "Unlicense" ]
null
null
null
models/problem_3c_unscaled.py
taoyilee/ml_final_project
0ac5ee3938d70e9ffcae8e186e0ef1a621391980
[ "Unlicense" ]
null
null
null
import numpy as np import pickle from homework4.problem_3 import sample_train_knn if __name__ == "__main__": X = np.genfromtxt('data/X_train.txt', delimiter=None) Y = np.genfromtxt('data/Y_train.txt', delimiter=None)[:, np.newaxis] raw_data = np.concatenate((X, Y), axis=1) trn_p = 20 dev_p = 5 ...
36.9
113
0.620596
6f962ae4dfec841c5e2e19e5dc5acc216ce3e30b
2,264
py
Python
internal/notes/builtin-SAVE/packages/py-pyflakes/package.py
HPCToolkit/hpctest
5ff4455582bf39e75530a31badcf6142081b386b
[ "BSD-3-Clause" ]
1
2019-01-17T20:07:19.000Z
2019-01-17T20:07:19.000Z
internal/notes/builtin-SAVE/packages/py-pyflakes/package.py
HPCToolkit/hpctest
5ff4455582bf39e75530a31badcf6142081b386b
[ "BSD-3-Clause" ]
null
null
null
internal/notes/builtin-SAVE/packages/py-pyflakes/package.py
HPCToolkit/hpctest
5ff4455582bf39e75530a31badcf6142081b386b
[ "BSD-3-Clause" ]
2
2019-08-06T18:13:57.000Z
2021-11-05T18:19:49.000Z
############################################################################## # Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC. # Produced at the Lawrence Livermore National Laboratory. # # This file is part of Spack. # Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. # LLNL-CODE-64...
47.166667
78
0.694788
020f74c2ff9908146b7a1e81636c9efdc20b0af9
37,387
py
Python
mysql-dst/mysql-cluster/ndb/mcc/request_handler.py
SJTU-IPADS/dst
897b929a692642cbf295c105d9d6e64090abb673
[ "Apache-2.0" ]
9
2020-12-17T01:59:13.000Z
2022-03-30T16:25:08.000Z
mysql-dst/mysql-cluster/ndb/mcc/request_handler.py
SJTU-IPADS/dst
897b929a692642cbf295c105d9d6e64090abb673
[ "Apache-2.0" ]
1
2021-07-30T12:06:33.000Z
2021-07-31T10:16:09.000Z
mysql-dst/mysql-cluster/ndb/mcc/request_handler.py
SJTU-IPADS/dst
897b929a692642cbf295c105d9d6e64090abb673
[ "Apache-2.0" ]
1
2021-08-01T13:47:07.000Z
2021-08-01T13:47:07.000Z
# Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; version 2 of the License. # # This program is distributed in the ...
42.582005
233
0.612272
7215ab298bc393b5930ec6bfd82c79f1b96918f2
1,033
py
Python
tests/scheduling/conftest.py
JeshuaT/PsyNeuLink
912f691028e848659055430f37b6c15273c762f1
[ "Apache-2.0" ]
67
2018-01-05T22:18:44.000Z
2022-03-27T11:27:31.000Z
tests/scheduling/conftest.py
JeshuaT/PsyNeuLink
912f691028e848659055430f37b6c15273c762f1
[ "Apache-2.0" ]
1,064
2017-12-01T18:58:27.000Z
2022-03-31T22:22:24.000Z
tests/scheduling/conftest.py
JeshuaT/PsyNeuLink
912f691028e848659055430f37b6c15273c762f1
[ "Apache-2.0" ]
25
2017-12-01T20:27:07.000Z
2022-03-08T21:49:39.000Z
import psyneulink as pnl import pytest def pytest_assertrepr_compare(op, left, right): if isinstance(left, list) and isinstance(right, list) and op == '==': return [ 'Time Step output matching:', 'Actual output:', str(left), 'Expected output:', str(right) ] @p...
27.918919
73
0.632139
f5996a9c6eb5884f59766af3217d924ec3eab701
7,600
py
Python
databuilder/publisher/elasticsearch_publisher.py
pemmasanikrishna/amundsendatabuilder
f29bb3baeb61f383750b4492538a79415daa149b
[ "Apache-2.0" ]
null
null
null
databuilder/publisher/elasticsearch_publisher.py
pemmasanikrishna/amundsendatabuilder
f29bb3baeb61f383750b4492538a79415daa149b
[ "Apache-2.0" ]
null
null
null
databuilder/publisher/elasticsearch_publisher.py
pemmasanikrishna/amundsendatabuilder
f29bb3baeb61f383750b4492538a79415daa149b
[ "Apache-2.0" ]
null
null
null
import json import logging import textwrap from typing import List # noqa: F401 from pyhocon import ConfigTree # noqa: F401 from elasticsearch.exceptions import NotFoundError from databuilder.publisher.base_publisher import Publisher LOGGER = logging.getLogger(__name__) class ElasticsearchPublisher(Publisher): ...
37.073171
117
0.557632
6bc62d51d418de6b1a5198f4a44843bf94a80638
5,884
py
Python
linequ.py
wangzqzero/calculator
94bf0c454672b88262ed87d090908a5ed1518fd3
[ "MIT" ]
null
null
null
linequ.py
wangzqzero/calculator
94bf0c454672b88262ed87d090908a5ed1518fd3
[ "MIT" ]
null
null
null
linequ.py
wangzqzero/calculator
94bf0c454672b88262ed87d090908a5ed1518fd3
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'linequ.ui' # # Created by: PyQt5 UI code generator 5.15.4 # # WARNING: Any manual changes made to this file will be lost when pyuic5 is # run again. Do not edit this file unless you know what you are doing. from PyQt5 import QtCore, QtGui...
45.612403
131
0.664684
0e56bfa5abf98af84585e76c8b35ae98684b280d
49,914
py
Python
tests/test_invariants_and_dependencies.py
IMTMarburg/pypipegraph2
182f04481f0b0b6b1c05cfbe23549714af5cfbcc
[ "MIT" ]
null
null
null
tests/test_invariants_and_dependencies.py
IMTMarburg/pypipegraph2
182f04481f0b0b6b1c05cfbe23549714af5cfbcc
[ "MIT" ]
null
null
null
tests/test_invariants_and_dependencies.py
IMTMarburg/pypipegraph2
182f04481f0b0b6b1c05cfbe23549714af5cfbcc
[ "MIT" ]
null
null
null
import os import gzip from pathlib import Path from loguru import logger import stat import time import hashlib import shutil import pytest import pypipegraph2 as ppg from .shared import write, read, append, Dummy, counter, force_load class Undepickable(object): def __getstate__(self): return {"shu": 123}...
33.033752
120
0.564892
7e4582246ed0faad1c3ef763653d69a41ec247f7
2,076
py
Python
src/python/chaste/core/__init__.py
jmsgrogan/PyChaste
48a9863d2c941c71e47ecb72e917b477ba5c1413
[ "FTL" ]
6
2017-02-04T16:10:53.000Z
2021-07-01T08:03:16.000Z
src/python/chaste/core/__init__.py
jmsgrogan/PyChaste
48a9863d2c941c71e47ecb72e917b477ba5c1413
[ "FTL" ]
6
2017-06-22T08:50:41.000Z
2019-12-15T20:17:29.000Z
src/python/chaste/core/__init__.py
jmsgrogan/PyChaste
48a9863d2c941c71e47ecb72e917b477ba5c1413
[ "FTL" ]
3
2017-05-15T21:33:58.000Z
2019-10-27T21:43:07.000Z
#!/usr/bin/env python """Core Module """ __copyright__ = """Copyright (c) 2005-2019, University of Oxford. All rights reserved. University of Oxford means the Chancellor, Masters and Scholars of the University of Oxford, having an administrative office at Wellington Square, Oxford OX1 2JD, UK. This file is part of C...
48.27907
119
0.80395
781076b1e4a912f380372b14564f4840db435ada
316
py
Python
paradise/config/docs.py
pfrydlewicz/paradise
bdd2597d259ab7313a140d82de4afce5961b0cb6
[ "MIT" ]
null
null
null
paradise/config/docs.py
pfrydlewicz/paradise
bdd2597d259ab7313a140d82de4afce5961b0cb6
[ "MIT" ]
null
null
null
paradise/config/docs.py
pfrydlewicz/paradise
bdd2597d259ab7313a140d82de4afce5961b0cb6
[ "MIT" ]
null
null
null
""" Configuration for docs """ # source_link = "https://github.com/[org_name]/paradise" # docs_base_url = "https://[org_name].github.io/paradise" # headline = "App that does everything" # sub_heading = "Yes, you got that right the first time, everything" def get_context(context): context.brand_html = "Paradise"
26.333333
68
0.724684
6bd4c8c3fe44ecff059c89fc525dae97a0f4465f
1,305
py
Python
element_feature.py
jingshenSN2/HOIP_bandgap_prediction
fc989c47e20d98490d7d9679cb6f9a6b2b0b9ebc
[ "MIT" ]
4
2020-01-05T09:41:07.000Z
2020-11-04T17:42:19.000Z
element_feature.py
NurcanOrmanli/HOIP_bandgap_prediction
fc989c47e20d98490d7d9679cb6f9a6b2b0b9ebc
[ "MIT" ]
null
null
null
element_feature.py
NurcanOrmanli/HOIP_bandgap_prediction
fc989c47e20d98490d7d9679cb6f9a6b2b0b9ebc
[ "MIT" ]
5
2020-02-19T07:26:41.000Z
2021-09-12T21:18:52.000Z
import pandas as pd def __add_formula(df): formula_list = [] for i in range(len(df)): row = df.iloc[i] abx = str(row['A-site']) + str(row['B-site']) + str(row['X-site']) formula_list.append(abx) df['formula'] = formula_list return df def raw_drop_duplicates(): df = __add_f...
39.545455
115
0.607663
a0b91356b9038b976a391c25d3cbe13662ff460e
12,109
py
Python
setup.py
ContextLogic/sqlalchemy
b7adfe5e4d9baa61169ba79aa5ba8f64f0ff7645
[ "MIT" ]
null
null
null
setup.py
ContextLogic/sqlalchemy
b7adfe5e4d9baa61169ba79aa5ba8f64f0ff7645
[ "MIT" ]
null
null
null
setup.py
ContextLogic/sqlalchemy
b7adfe5e4d9baa61169ba79aa5ba8f64f0ff7645
[ "MIT" ]
1
2021-06-23T09:02:32.000Z
2021-06-23T09:02:32.000Z
"""setup.py Please see README for basic installation instructions. """ import os import re import sys from distutils.command.build_ext import build_ext from distutils.errors import (CCompilerError, DistutilsExecError, DistutilsPlatformError) try: from setuptools import setup, Extens...
40.363333
76
0.641506
2ff2f0dd8a537dcfedbc9f68a6755b0407f5eb62
2,136
py
Python
tests/test_mapper.py
CuervoEC/ioet_employee_payment
be52d2f50b26ef3f9550d06194901ed73bc383e7
[ "MIT" ]
null
null
null
tests/test_mapper.py
CuervoEC/ioet_employee_payment
be52d2f50b26ef3f9550d06194901ed73bc383e7
[ "MIT" ]
null
null
null
tests/test_mapper.py
CuervoEC/ioet_employee_payment
be52d2f50b26ef3f9550d06194901ed73bc383e7
[ "MIT" ]
null
null
null
import unittest from calculator.mapper import unwrap_info class MapperTestClass(unittest.TestCase): def setUp(self): self.text = 'RENE=MO10:00-12:00,MO18:00-22:00,TU10:00-12:00' def test_should_return_name_and_schedule_when_valid_text_is_provided(self): name, schedule = unwrap_info(self.text)...
39.555556
113
0.703184
f476b41d6b6b7bf143a47ef6b91bb7b0e292e304
1,988
py
Python
01-byoc/code/dataloader.py
timchiu9781/Tomofun
3f7abcb7fc1cc8200ec3fdff62bd51fbaada4126
[ "MIT-0" ]
27
2021-06-20T01:40:31.000Z
2022-02-17T12:23:41.000Z
01-byoc/code/dataloader.py
timchiu9781/Tomofun
3f7abcb7fc1cc8200ec3fdff62bd51fbaada4126
[ "MIT-0" ]
2
2021-07-14T06:26:37.000Z
2022-03-12T00:58:44.000Z
01-byoc/code/dataloader.py
timchiu9781/Tomofun
3f7abcb7fc1cc8200ec3fdff62bd51fbaada4126
[ "MIT-0" ]
7
2021-07-03T13:14:28.000Z
2021-07-29T15:23:59.000Z
import numpy as np from torch.utils.data import DataLoader from torch.utils.data.dataloader import default_collate from torch.utils.data.sampler import SubsetRandomSampler class SoundDataLoader(DataLoader): def __init__(self, dataset, batch_size, shuffle=False, validation_split=0.0, num_workers=0, collate_fn=defau...
34.275862
141
0.650905
1d416b1c042f227d678f74298537e80499ca21a3
2,810
py
Python
slack_blockkit/utils/blocks.py
dylanmoring/slack-blockkit
90c8efd6f4d7e0ffe5850955e1b816e647b3c9f9
[ "MIT" ]
10
2020-07-20T03:29:19.000Z
2022-01-09T02:11:53.000Z
slack_blockkit/utils/blocks.py
dylanmoring/slack-blockkit
90c8efd6f4d7e0ffe5850955e1b816e647b3c9f9
[ "MIT" ]
6
2020-07-25T06:08:11.000Z
2022-01-05T17:39:13.000Z
slack_blockkit/utils/blocks.py
dylanmoring/slack-blockkit
90c8efd6f4d7e0ffe5850955e1b816e647b3c9f9
[ "MIT" ]
5
2021-02-14T17:10:35.000Z
2021-06-17T16:09:08.000Z
from slack_blockkit.block_element import BlockElement, ImageElement from slack_blockkit.composition_object import MarkdownTextObject, TextObject from slack_blockkit.layout_block import SectionBlock def get_checkmark(task_completed: bool) -> str: """ Returns a check mark emoji indicating the completed task sta...
35.56962
114
0.695018
d17a19c116b5e182be5f474805e8480817ebe703
4,510
py
Python
experiments/heli/baselines.py
sisl/CEEM
6154587fe3cdb92e8b7f70eedb1262caa1553cc8
[ "MIT" ]
5
2020-06-21T16:50:42.000Z
2021-03-14T04:02:01.000Z
experiments/heli/baselines.py
sisl/CEEM
6154587fe3cdb92e8b7f70eedb1262caa1553cc8
[ "MIT" ]
1
2021-03-13T07:46:36.000Z
2021-03-16T05:14:47.000Z
experiments/heli/baselines.py
sisl/CEEM
6154587fe3cdb92e8b7f70eedb1262caa1553cc8
[ "MIT" ]
1
2021-03-30T12:08:20.000Z
2021-03-30T12:08:20.000Z
import os import time import click import numpy as np import torch from ceem import logger, utils from ceem.baseline_utils import LagModel from ceem.data_utils import load_helidata, load_statistics from ceem.exp_utils import * from ceem.nn import LNMLP torch.set_default_dtype(torch.float64) opj = os.path.join devi...
30.472973
99
0.574501
8fb8daaa16e1701a65110b68a9eadaf96495fab1
1,238
py
Python
jdcloud_sdk/services/kubernetes/models/NodeConfigSpec.py
jdcloud-demo/jdcloud-sdk-python
fddc2af24031c597948b8b8091978ac7e01a2695
[ "Apache-2.0" ]
null
null
null
jdcloud_sdk/services/kubernetes/models/NodeConfigSpec.py
jdcloud-demo/jdcloud-sdk-python
fddc2af24031c597948b8b8091978ac7e01a2695
[ "Apache-2.0" ]
null
null
null
jdcloud_sdk/services/kubernetes/models/NodeConfigSpec.py
jdcloud-demo/jdcloud-sdk-python
fddc2af24031c597948b8b8091978ac7e01a2695
[ "Apache-2.0" ]
null
null
null
# coding=utf8 # Copyright 2018 JDCLOUD.COM # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
34.388889
96
0.709208
e7ddf0a82ae82e9eb38e385aa0ea0647965aa8af
443
py
Python
examples/pytorch/jtnn/jtnn/line_profiler_integration.py
ketyi/dgl
a1b859c29b63a673c148d13231a49504740e0e01
[ "Apache-2.0" ]
9,516
2018-12-08T22:11:31.000Z
2022-03-31T13:04:33.000Z
examples/pytorch/jtnn/jtnn/line_profiler_integration.py
ketyi/dgl
a1b859c29b63a673c148d13231a49504740e0e01
[ "Apache-2.0" ]
2,494
2018-12-08T22:43:00.000Z
2022-03-31T21:16:27.000Z
examples/pytorch/jtnn/jtnn/line_profiler_integration.py
ketyi/dgl
a1b859c29b63a673c148d13231a49504740e0e01
[ "Apache-2.0" ]
2,529
2018-12-08T22:56:14.000Z
2022-03-31T13:07:41.000Z
''' line_profiler integration ''' import os if os.getenv('PROFILE', 0): import line_profiler import atexit profile = line_profiler.LineProfiler() profile_output = os.getenv('PROFILE_OUTPUT', None) if profile_output: from functools import partial atexit.register(partial(profile.dump...
22.15
68
0.688488
c99ec695e5955c864749177f1be92b424299ac74
238
py
Python
Aula 13/Desafios/060.py
mateuschaves/curso-python
53b2f3b4bf083ae2ce7ea19dd358f49a36becd9d
[ "MIT" ]
1
2018-07-23T04:03:35.000Z
2018-07-23T04:03:35.000Z
Aula 13/Desafios/060.py
mateuschaves/curso-python
53b2f3b4bf083ae2ce7ea19dd358f49a36becd9d
[ "MIT" ]
null
null
null
Aula 13/Desafios/060.py
mateuschaves/curso-python
53b2f3b4bf083ae2ce7ea19dd358f49a36becd9d
[ "MIT" ]
null
null
null
""" Faça um programa que leia um número qualquer e mostre o seu fatorial """ n = int(input('Informe um número: ')) s = n fatorial = 1 while n > 1: fatorial *= n n -= 1 print('O fatorial de {} é {} !'.format(s, fatorial))
18.307692
52
0.592437
99b729946379628696d46a029150e5d787aedd70
13,135
py
Python
test.py
jernej19/fantasynhl
1b2ee42e82d714f3e3b9b01e1fc0e799e3f77f77
[ "Apache-2.0" ]
null
null
null
test.py
jernej19/fantasynhl
1b2ee42e82d714f3e3b9b01e1fc0e799e3f77f77
[ "Apache-2.0" ]
null
null
null
test.py
jernej19/fantasynhl
1b2ee42e82d714f3e3b9b01e1fc0e799e3f77f77
[ "Apache-2.0" ]
null
null
null
import pandas as pd import numpy as np # Import data to dataframe players = pd.read_csv('players.csv') goalies = pd.read_csv('goalies.csv') # Remove unnecessary columns: players = players.drop(columns=['adjusted_assists', 'adjusted_goals', 'adjusted_goals_against_average', 'adjusted_goals_created', 'adjusted_points'...
36.085165
121
0.620708
1efd119ab3a348443e237ec63e09114df858b223
7,698
py
Python
repos/system_upgrade/el7toel8/actors/checkxfs/tests/unit_test.py
adka1408/leapp-repository
be5a9603b57f86c65d395ba6a02b860cacae0fb6
[ "Apache-2.0" ]
null
null
null
repos/system_upgrade/el7toel8/actors/checkxfs/tests/unit_test.py
adka1408/leapp-repository
be5a9603b57f86c65d395ba6a02b860cacae0fb6
[ "Apache-2.0" ]
null
null
null
repos/system_upgrade/el7toel8/actors/checkxfs/tests/unit_test.py
adka1408/leapp-repository
be5a9603b57f86c65d395ba6a02b860cacae0fb6
[ "Apache-2.0" ]
null
null
null
import pytest from leapp.exceptions import StopActorExecutionError from leapp.libraries.actor import library from leapp.libraries.common.testutils import produce_mocked from leapp.libraries.stdlib import api from leapp.models import StorageInfo, FstabEntry, MountEntry, SystemdMountEntry, XFSPresence class run_mocked...
37.735294
97
0.599896
c26a4cf6a1b57ac559442976bf026cb0223dc928
3,167
py
Python
rpi-opencv-video-stream.py
wesmith/streaming-video-rpi
a92ed556d995efc7433e6adbc8a08bbd1b252867
[ "MIT" ]
null
null
null
rpi-opencv-video-stream.py
wesmith/streaming-video-rpi
a92ed556d995efc7433e6adbc8a08bbd1b252867
[ "MIT" ]
null
null
null
rpi-opencv-video-stream.py
wesmith/streaming-video-rpi
a92ed556d995efc7433e6adbc8a08bbd1b252867
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # WS TODO # - (done) run webcam via opencv # - add command-line inputs: camera type, url, port, frame size # - fix the stylesheet # - add change-detection, other algos from importlib import import_module import os from flask import Flask, render_template, Response from flask import jsonify, re...
31.356436
70
0.569624
a1617b2dd3d795639251e20b4c18bf90445ad956
3,139
py
Python
color_image.py
hassanmohsin/stl-to-voxel
52b81a8b28e35511deb7c7ff6b300b069a91a64d
[ "MIT" ]
null
null
null
color_image.py
hassanmohsin/stl-to-voxel
52b81a8b28e35511deb7c7ff6b300b069a91a64d
[ "MIT" ]
null
null
null
color_image.py
hassanmohsin/stl-to-voxel
52b81a8b28e35511deb7c7ff6b300b069a91a64d
[ "MIT" ]
null
null
null
import argparse import json import math import matplotlib.pyplot as plt import numpy as np from stltovoxel import get_voxels, file_choices, read_stl class ColorImage(object): def __init__(self, stl_file, voxel_resolution=100): self.stl_file = stl_file self.voxel_resolution = voxel_resol...
45.492754
113
0.635871
120d5144f92162f54bfe4c0066715dbedeaa26a2
5,890
py
Python
normalizing_flows_typed/flow.py
kiwi0fruit/jats-semi-supervised-pytorch
67e9bb85f09f8ef02e17e495784d1d9a71c3adec
[ "MIT" ]
null
null
null
normalizing_flows_typed/flow.py
kiwi0fruit/jats-semi-supervised-pytorch
67e9bb85f09f8ef02e17e495784d1d9a71c3adec
[ "MIT" ]
null
null
null
normalizing_flows_typed/flow.py
kiwi0fruit/jats-semi-supervised-pytorch
67e9bb85f09f8ef02e17e495784d1d9a71c3adec
[ "MIT" ]
null
null
null
""" Code by Jesper Wohlert was forked from https://github.com/wohlert/semi-supervised-pytorch Code by Nicola De Cao was forked from https://github.com/nicola-decao/BNAF MIT License Copyright (c) 2017 Jesper Wohlert, 2019 Nicola De Cao, 2019 Peter Zagubisalo Permission is hereby granted, free of charge, to any person...
36.358025
89
0.665705
01c8371284c699cb3ee0ef0b56df4ed553330743
142
py
Python
main/factorial/factorial_lambda.py
akshit777/Hello-world
ea38f8fb146f9855bde3614c9683e8b151b1a838
[ "MIT" ]
null
null
null
main/factorial/factorial_lambda.py
akshit777/Hello-world
ea38f8fb146f9855bde3614c9683e8b151b1a838
[ "MIT" ]
null
null
null
main/factorial/factorial_lambda.py
akshit777/Hello-world
ea38f8fb146f9855bde3614c9683e8b151b1a838
[ "MIT" ]
null
null
null
import sys factorial = lambda w: reduce(lambda x,y: x*y, range(1,w+1)) if w > 0 else 1 if w == 0 else None print(factorial(int(sys.argv[1])))
35.5
95
0.669014
4f90a526f956909115d9073dbec8f3a6fe4fe7fc
22,634
py
Python
commpy/modulation.py
Devansh0210/CommPy
c924b38e21d0600bf8072164cb0d9060d2ac2660
[ "BSD-3-Clause" ]
2
2018-11-18T22:10:49.000Z
2019-07-12T08:35:24.000Z
commpy/modulation.py
Devansh0210/CommPy
c924b38e21d0600bf8072164cb0d9060d2ac2660
[ "BSD-3-Clause" ]
null
null
null
commpy/modulation.py
Devansh0210/CommPy
c924b38e21d0600bf8072164cb0d9060d2ac2660
[ "BSD-3-Clause" ]
null
null
null
# Authors: CommPy contributors # License: BSD 3-Clause """ ================================================== Modulation Demodulation (:mod:`commpy.modulation`) ================================================== .. autosummary:: :toctree: generated/ PSKModem -- Phase Shift Keying (PSK) Modem. QA...
34.982998
120
0.595785
d99d5c60ef0e9b45215619a43f4f22cbc870cbc9
809
py
Python
a10sdk/core/link/link.py
deepfield/a10sdk-python
bfaa58099f51f085d5e91652d1d1a3fd5c529d5d
[ "Apache-2.0" ]
16
2015-05-20T07:26:30.000Z
2021-01-23T11:56:57.000Z
a10sdk/core/link/link.py
deepfield/a10sdk-python
bfaa58099f51f085d5e91652d1d1a3fd5c529d5d
[ "Apache-2.0" ]
6
2015-03-24T22:07:11.000Z
2017-03-28T21:31:18.000Z
a10sdk/core/link/link.py
deepfield/a10sdk-python
bfaa58099f51f085d5e91652d1d1a3fd5c529d5d
[ "Apache-2.0" ]
23
2015-03-29T15:43:01.000Z
2021-06-02T17:12:01.000Z
from a10sdk.common.A10BaseClass import A10BaseClass class Link(A10BaseClass): """ :param DeviceProxy: The device proxy for REST operations and session handling. Refer to `common/device_proxy.py` Class Description:: Link to Configuration Profile. Class link supports CRUD Operations and inherits f...
23.114286
123
0.631644
ba74b25a88f0d28959cd1e8c3b92b4677df40b43
145
py
Python
intro/numpy/solutions/1_1_array_creation.py
junghun73/Learning
8b5a295c42f142a3b2f5fa13fc75434a2ea9235a
[ "CC-BY-4.0" ]
419
2016-03-05T08:50:48.000Z
2022-03-24T15:16:46.000Z
intro/numpy/solutions/1_1_array_creation.py
techeye220/scipy-lecture-notes-zh-CN
cc87204fcc4bd2f4702f7c29c83cb8ed5c94b7d6
[ "CC-BY-4.0" ]
5
2016-05-21T14:21:12.000Z
2017-10-06T11:09:48.000Z
intro/numpy/solutions/1_1_array_creation.py
techeye220/scipy-lecture-notes-zh-CN
cc87204fcc4bd2f4702f7c29c83cb8ed5c94b7d6
[ "CC-BY-4.0" ]
233
2016-02-13T09:22:57.000Z
2021-11-11T17:58:44.000Z
import numpy as np a = np.ones((4, 4), dtype=int) a[3,1] = 6 a[2,3] = 2 b = np.zeros((6, 5)) b[1:] = np.diag(np.arange(2, 7)) print a print b
12.083333
32
0.551724