hexsha
stringlengths
40
40
size
int64
1
1.03M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
239
max_stars_repo_name
stringlengths
5
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
239
max_issues_repo_name
stringlengths
5
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
239
max_forks_repo_name
stringlengths
5
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.03M
avg_line_length
float64
1
958k
max_line_length
int64
1
1.03M
alphanum_fraction
float64
0
1
796a1cb885816f619e4d6c7561b290fe324e3663
4,939
py
Python
reporting/resources/report.py
AndrewRot/wpt
8959b13684b68186781340c044d9c1b62a388358
[ "BSD-3-Clause" ]
null
null
null
reporting/resources/report.py
AndrewRot/wpt
8959b13684b68186781340c044d9c1b62a388358
[ "BSD-3-Clause" ]
null
null
null
reporting/resources/report.py
AndrewRot/wpt
8959b13684b68186781340c044d9c1b62a388358
[ "BSD-3-Clause" ]
null
null
null
import time import json import re import uuid from wptserve.utils import isomorphic_decode def retrieve_from_stash(request, key, timeout, default_value, min_count=None): """Retrieve the set of reports for a given report ID. This will extract either the set of reports, credentials, or request count from the sta...
38.585938
157
0.691436
796a1d3d9ddf0ec498667c3d31902b837f38c1a2
3,292
py
Python
Game- Word Jump Game/Game/run.py
MrArthor/Python-Projects
f272ef1557d958500a23abd49667ba525e94b4bb
[ "MIT" ]
null
null
null
Game- Word Jump Game/Game/run.py
MrArthor/Python-Projects
f272ef1557d958500a23abd49667ba525e94b4bb
[ "MIT" ]
null
null
null
Game- Word Jump Game/Game/run.py
MrArthor/Python-Projects
f272ef1557d958500a23abd49667ba525e94b4bb
[ "MIT" ]
null
null
null
#importing modules import pygame import random import time #initializing window pygame.init() WIDTH = 800 HEIGHT = 600 black=(0,0,0) Display = pygame.display.set_mode((WIDTH, HEIGHT))#setting game display size pygame.display.set_caption('DuckShoot Modified Word Games') background = pygame.image.load('keyback.jpg') bac...
29.927273
85
0.637606
796a1d5d05efccfbea7a92ef25d3c7e28cb14783
3,782
py
Python
pychron/experiment/utilities/frequency_edit_view.py
ael-noblegas/pychron
6ebbbb1f66a614972b62b7a9be4c784ae61b5d62
[ "Apache-2.0" ]
1
2019-02-27T21:57:44.000Z
2019-02-27T21:57:44.000Z
pychron/experiment/utilities/frequency_edit_view.py
ael-noblegas/pychron
6ebbbb1f66a614972b62b7a9be4c784ae61b5d62
[ "Apache-2.0" ]
80
2018-07-17T20:10:20.000Z
2021-08-17T15:38:24.000Z
pychron/experiment/utilities/frequency_edit_view.py
AGESLDEO/pychron
1a81e05d9fba43b797f335ceff6837c016633bcf
[ "Apache-2.0" ]
null
null
null
# =============================================================================== # Copyright 2014 Jake Ross # # 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...
33.175439
88
0.585669
796a1d73bfed68048cb097d7929545f00cab41ff
2,965
py
Python
spearmint-win/spearmint/chooser/CMAChooser.py
TudorParas/Practical-Bayesian-Optimization
db13b509e07e1283c9f37a31cae11d9c9940ebfc
[ "MIT" ]
null
null
null
spearmint-win/spearmint/chooser/CMAChooser.py
TudorParas/Practical-Bayesian-Optimization
db13b509e07e1283c9f37a31cae11d9c9940ebfc
[ "MIT" ]
null
null
null
spearmint-win/spearmint/chooser/CMAChooser.py
TudorParas/Practical-Bayesian-Optimization
db13b509e07e1283c9f37a31cae11d9c9940ebfc
[ "MIT" ]
null
null
null
from cma import CMAEvolutionStrategy from spearmint import util import Locker def init(expt_dir, arg_string): args = util.unpack_args(arg_string) return CMAChooser(expt_dir, **args) """ Chooser module for the CMA-ES evolutionary optimizer. """ class CMAChooser: def __init__(self, expt_dir): rais...
34.08046
90
0.601686
796a1d90ac1e3c96b667a1a720a168419e737ddb
1,925
py
Python
utils.py
piterskikhsa/db-hack
2c25fc6ae545cef1689b21d03e217de88de85808
[ "MIT" ]
null
null
null
utils.py
piterskikhsa/db-hack
2c25fc6ae545cef1689b21d03e217de88de85808
[ "MIT" ]
null
null
null
utils.py
piterskikhsa/db-hack
2c25fc6ae545cef1689b21d03e217de88de85808
[ "MIT" ]
null
null
null
import random from datacenter.models import Mark, Chastisement, Commendation, Lesson, Schoolkid def fix_mark(schoolkid): Mark.objects.filter(schoolkid=schoolkid, points__in=(2, 3)).update(points=5) def remove_chastisements(schoolkid): Chastisement.objects.filter(schoolkid=schoolkid).delete() def create_c...
40.957447
116
0.643636
796a1ddab2492b789bc0b407fe1e9ba34a0356d5
2,098
py
Python
cdn/endpoints/api/me/me.py
Axelancerr/cdn
9fe1dba9b61ca011beb207b8f21b43aa6e64de1b
[ "MIT" ]
4
2021-11-05T04:57:44.000Z
2022-03-28T11:28:52.000Z
cdn/endpoints/api/me/me.py
Axelancerr/cdn
9fe1dba9b61ca011beb207b8f21b43aa6e64de1b
[ "MIT" ]
null
null
null
cdn/endpoints/api/me/me.py
Axelancerr/cdn
9fe1dba9b61ca011beb207b8f21b43aa6e64de1b
[ "MIT" ]
null
null
null
# Future from __future__ import annotations # Packages import aiohttp.web # My stuff from core.app import CDN from utilities import exceptions async def get(request: aiohttp.web.Request) -> aiohttp.web.Response: app: CDN = request.app # type: ignore if not (token := request.headers.get("Authorization")):...
34.966667
113
0.702097
796a1e1fdf18ceb1632c2b670fd9e40ebecb0c18
152
py
Python
src/waldur_hpc/extension.py
geant-multicloud/MCMS-mastermind
81333180f5e56a0bc88d7dad448505448e01f24e
[ "MIT" ]
26
2017-10-18T13:49:58.000Z
2021-09-19T04:44:09.000Z
src/waldur_hpc/extension.py
geant-multicloud/MCMS-mastermind
81333180f5e56a0bc88d7dad448505448e01f24e
[ "MIT" ]
14
2018-12-10T14:14:51.000Z
2021-06-07T10:33:39.000Z
src/waldur_hpc/extension.py
geant-multicloud/MCMS-mastermind
81333180f5e56a0bc88d7dad448505448e01f24e
[ "MIT" ]
32
2017-09-24T03:10:45.000Z
2021-10-16T16:41:09.000Z
from waldur_core.core import WaldurExtension class HPCExtension(WaldurExtension): @staticmethod def django_app(): return 'waldur_hpc'
19
44
0.743421
796a1ed379da22636e31b008ca1784b2e1e03751
4,110
py
Python
web_console_v2/api/fedlearner_webconsole/auth/apis.py
nolanliou/fedlearner
54127c465b3b5d77ae41b823e42efbc1b707e826
[ "Apache-2.0" ]
null
null
null
web_console_v2/api/fedlearner_webconsole/auth/apis.py
nolanliou/fedlearner
54127c465b3b5d77ae41b823e42efbc1b707e826
[ "Apache-2.0" ]
null
null
null
web_console_v2/api/fedlearner_webconsole/auth/apis.py
nolanliou/fedlearner
54127c465b3b5d77ae41b823e42efbc1b707e826
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 The FedLearner 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...
34.830508
80
0.673479
796a1f1f3c03806001f11cb8d30dbdf69fcb54cc
10,700
py
Python
rasterio/merge.py
fwfichtner/rasterio
6857bb00a63c53d0b32103fbf6cc0da859199163
[ "BSD-3-Clause" ]
1
2021-09-16T00:44:50.000Z
2021-09-16T00:44:50.000Z
rasterio/merge.py
fwfichtner/rasterio
6857bb00a63c53d0b32103fbf6cc0da859199163
[ "BSD-3-Clause" ]
null
null
null
rasterio/merge.py
fwfichtner/rasterio
6857bb00a63c53d0b32103fbf6cc0da859199163
[ "BSD-3-Clause" ]
null
null
null
"""Copy valid pixels from input files to an output file.""" from contextlib import contextmanager from pathlib import Path import logging import math import warnings import numpy as np import rasterio from rasterio import windows from rasterio.enums import Resampling from rasterio.compat import string_types from ras...
35.666667
99
0.610093
796a1f6a84dbeed2d4bae255050685e7704bc20e
9,704
py
Python
jason/xp_figure2_msc.py
ajclaros/rl_legged_walker
26d0e124ef38045943449c2772b966571117683b
[ "MIT" ]
null
null
null
jason/xp_figure2_msc.py
ajclaros/rl_legged_walker
26d0e124ef38045943449c2772b966571117683b
[ "MIT" ]
null
null
null
jason/xp_figure2_msc.py
ajclaros/rl_legged_walker
26d0e124ef38045943449c2772b966571117683b
[ "MIT" ]
null
null
null
import numpy as np import numpy as np import random from jason.ctrnn import CTRNN from jason.rl_ctrnn import RL_CTRNN from jason.xp_perturb_solutions import run_perturb_experiment from jason.mga import MicrobialGA import matplotlib.pyplot as plt import sys import json import os from jason.simple_oscillator_task import ...
36.208955
184
0.674361
796a202ee5cdd16d9595c1d5e8deef03c15f0217
6,384
py
Python
tests/model/Megatron_GPT2/run_checkpoint_test.py
sheikheddy/DeepSpeed
8575200079041cf42685b1cae11e0885a5b53507
[ "MIT" ]
null
null
null
tests/model/Megatron_GPT2/run_checkpoint_test.py
sheikheddy/DeepSpeed
8575200079041cf42685b1cae11e0885a5b53507
[ "MIT" ]
null
null
null
tests/model/Megatron_GPT2/run_checkpoint_test.py
sheikheddy/DeepSpeed
8575200079041cf42685b1cae11e0885a5b53507
[ "MIT" ]
null
null
null
# coding=utf-8 # Copyright (c) 2019, The Microsoft DeepSpeed Team. All rights reserved. # # Note: please copy webtext data to "Megatron-LM" folder, before running this script. import unittest import subprocess import os import time import re from .test_common import BaseTestCase def grep_loss_from_file(file_name): ...
31.761194
101
0.564693
796a20ae6986e2d69e98bfe4e6c35187977e2901
309
py
Python
imagefactory/tests/test_cli.py
jaantollander/imagefactory
fe163a5f1ad9c0419341d27a297d33936bb359a1
[ "MIT" ]
null
null
null
imagefactory/tests/test_cli.py
jaantollander/imagefactory
fe163a5f1ad9c0419341d27a297d33936bb359a1
[ "MIT" ]
null
null
null
imagefactory/tests/test_cli.py
jaantollander/imagefactory
fe163a5f1ad9c0419341d27a297d33936bb359a1
[ "MIT" ]
null
null
null
from click.testing import CliRunner import tempfile from imagefactory.cli import main def test_commands(): runner = CliRunner() with tempfile.TemporaryDirectory() as tmpdir: result = runner.invoke(main, ['--savedir', tmpdir]) assert result.exit_code == 0 assert result.output == ''
23.769231
59
0.705502
796a20cd6b861ea8e88e60ea1d0de994ceadfa70
386
py
Python
kagi/lower/west/three.py
jedhsu/kagi
1301f7fc437bb445118b25ca92324dbd58d6ad2d
[ "MIT" ]
null
null
null
kagi/lower/west/three.py
jedhsu/kagi
1301f7fc437bb445118b25ca92324dbd58d6ad2d
[ "MIT" ]
null
null
null
kagi/lower/west/three.py
jedhsu/kagi
1301f7fc437bb445118b25ca92324dbd58d6ad2d
[ "MIT" ]
null
null
null
""" *Lower-West 3* |⠦| The lower-west three gi. """ from dataclasses import dataclass from ...._gi import Gi from ..._gi import StrismicGi from ...west import WesternGi from ..._number import ThreeGi from .._gi import LowerGi __all__ = ["LowerWest3"] @dataclass class LowerWest3( Gi, StrismicGi, ...
13.310345
33
0.650259
796a21a60eab8803b590051bc303c1c2ceda575e
1,363
py
Python
Classmate_API_Review/website.py
antpas/EC500C1
398550baeef7aa5a3fddd5d6e4c67e948e3b5dc6
[ "MIT" ]
null
null
null
Classmate_API_Review/website.py
antpas/EC500C1
398550baeef7aa5a3fddd5d6e4c67e948e3b5dc6
[ "MIT" ]
null
null
null
Classmate_API_Review/website.py
antpas/EC500C1
398550baeef7aa5a3fddd5d6e4c67e948e3b5dc6
[ "MIT" ]
1
2018-04-17T20:01:29.000Z
2018-04-17T20:01:29.000Z
from flask import Flask, request, render_template, url_for, redirect import twitterAPIexercise app = Flask(__name__) @app.route('/') def my_form(): return render_template('my-form.html') @app.route('/', methods=['POST']) def my_form_post(): text = request.form['text'] processed_text = text.lo...
30.977273
121
0.655906
796a21b5012cf6cf2e3df20f801f2c4304a5202d
5,208
py
Python
slmpy.py
OnurBahadir/slm_simulation
b0cdc5b120f1f9a428e39071953be76fb4d30ef9
[ "MIT" ]
null
null
null
slmpy.py
OnurBahadir/slm_simulation
b0cdc5b120f1f9a428e39071953be76fb4d30ef9
[ "MIT" ]
null
null
null
slmpy.py
OnurBahadir/slm_simulation
b0cdc5b120f1f9a428e39071953be76fb4d30ef9
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Sun Dec 06 20:14:02 2015 @author: Sebastien Popoff """ import wx import threading import numpy as np EVT_NEW_IMAGE = wx.PyEventBinder(wx.NewEventType(), 0) class ImageEvent(wx.PyCommandEvent): def __init__(self, eventType=EVT_NEW_IMAGE.evtType[0], i...
34.95302
115
0.594662
796a21d783c411a7146b8f2d7d3954b38d25a192
16,210
py
Python
pgdrive/policy/idm_policy.py
decisionforce/pgdrive
19af5d09a40a68a2a5f8b3ac8b40f109e71c26ee
[ "Apache-2.0" ]
97
2020-12-25T06:02:17.000Z
2022-01-16T06:58:39.000Z
pgdrive/policy/idm_policy.py
decisionforce/pgdrive
19af5d09a40a68a2a5f8b3ac8b40f109e71c26ee
[ "Apache-2.0" ]
192
2020-12-25T07:58:17.000Z
2021-08-28T10:13:59.000Z
pgdrive/policy/idm_policy.py
decisionforce/pgdrive
19af5d09a40a68a2a5f8b3ac8b40f109e71c26ee
[ "Apache-2.0" ]
11
2020-12-29T11:23:44.000Z
2021-12-06T23:25:49.000Z
import logging import numpy as np from pgdrive.component.vehicle_module.PID_controller import PIDController from pgdrive.policy.base_policy import BasePolicy from pgdrive.utils.math_utils import not_zero, wrap_to_pi, point_distance from pgdrive.utils.scene_utils import is_same_lane_index, is_following_lane_index cl...
45.79096
234
0.646144
796a236d3f1d4afa8b7a42d132a4a3cbf289b061
870
py
Python
advances/lambda.py
tienduy-nguyen/python-learning
3f91482638e11bb19f877a8044c11bce7e91aefc
[ "MIT" ]
null
null
null
advances/lambda.py
tienduy-nguyen/python-learning
3f91482638e11bb19f877a8044c11bce7e91aefc
[ "MIT" ]
null
null
null
advances/lambda.py
tienduy-nguyen/python-learning
3f91482638e11bb19f877a8044c11bce7e91aefc
[ "MIT" ]
null
null
null
# lambda Parameter: Operation(parameter) lambda x: x+1 # Equivalence def plus(x): return x +1 lambda x, y: x*y # Equivalence def mul(x, y): return x*y # Example nums = [[10, 20, 11], [3, 9, 6], [8, 14, 3]] # Sort from the second value in sub array sorted(nums, key=lambda x: x[1], reverse = True) # Ex2: sort...
22.307692
94
0.627586
796a239f0171a8f5f82f75c9a555e2b4a533f24d
6,648
py
Python
optable_submission/optable_package/optable/learning/optuna_hyper_params_searcher.py
pfnet-research/KDD-Cup-AutoML-5
54202eb6aa414316a70faa8e07a68e1c8ca7bd1b
[ "MIT" ]
18
2019-07-22T06:35:37.000Z
2021-03-20T08:37:56.000Z
optable_submission/optable_package/optable/learning/optuna_hyper_params_searcher.py
pfnet-research/KDD-Cup-AutoML-5
54202eb6aa414316a70faa8e07a68e1c8ca7bd1b
[ "MIT" ]
1
2020-03-22T21:06:57.000Z
2020-03-22T21:06:57.000Z
optable_submission/optable_package/optable/learning/optuna_hyper_params_searcher.py
pfnet-research/KDD-Cup-AutoML-5
54202eb6aa414316a70faa8e07a68e1c8ca7bd1b
[ "MIT" ]
11
2019-07-23T04:06:08.000Z
2020-05-12T08:44:01.000Z
import gc import lightgbm as lgb import optuna import numpy as np from optable.learning import learner class OptunaHyperParamsSearcher(learner.Learner): def __init__(self, mode, timer): self.__params = None self.__mode = mode self.__timer = timer self.__seed = 1360457 @prope...
36.933333
110
0.512184
796a23a3c8adb071134bd5d2f19635b44accac3d
1,260
py
Python
strava_analysis/analyze_data/analyze_data.py
annakoretchko/strava_analysis
5eafda68f3ee80a8628e131a04ad6526f7a61d28
[ "MIT" ]
null
null
null
strava_analysis/analyze_data/analyze_data.py
annakoretchko/strava_analysis
5eafda68f3ee80a8628e131a04ad6526f7a61d28
[ "MIT" ]
null
null
null
strava_analysis/analyze_data/analyze_data.py
annakoretchko/strava_analysis
5eafda68f3ee80a8628e131a04ad6526f7a61d28
[ "MIT" ]
null
null
null
import pandas as pd import numpy as np import seaborn as sns import matplotlib.pyplot as plt from datetime import datetime as date import os import sys import utils.analyze_data_utils as analyze_data_utils import utils.general_utils as general_utils # import strava_analysis.utils.analyze_data_utils as analyze_data_u...
28.636364
77
0.679365
796a2454e585bdc365e4b6fde9d419a988ffc0bd
12,416
py
Python
code/model_mir.py
acids-ircam/lottery_mir
1440d717d7fd688ac43c1a406602aaf2d5a3842d
[ "MIT" ]
10
2020-07-29T23:12:15.000Z
2022-03-23T16:27:43.000Z
code/model_mir.py
acids-ircam/lottery_mir
1440d717d7fd688ac43c1a406602aaf2d5a3842d
[ "MIT" ]
null
null
null
code/model_mir.py
acids-ircam/lottery_mir
1440d717d7fd688ac43c1a406602aaf2d5a3842d
[ "MIT" ]
1
2022-02-06T11:42:28.000Z
2022-02-06T11:42:28.000Z
# -*- coding: utf-8 -*- import sys import torch import torch.nn as nn from model import LotteryClassification """ ################### Trainer for regression models ################### """ class LotteryRegression(LotteryClassification): def __init__(self, args): super(LotteryRegression, self).__ini...
38.439628
79
0.617107
796a2528e12832ba41340df90ae6fa6af4fe4344
1,284
py
Python
nipype/interfaces/afni/tests/test_auto_Maskave.py
nicholsn/nipype
6601b00aac39d17bb9fb3a6801f5a740a6ebb1e3
[ "BSD-3-Clause" ]
1
2018-04-18T12:13:37.000Z
2018-04-18T12:13:37.000Z
nipype/interfaces/afni/tests/test_auto_Maskave.py
ito-takuya/nipype
9099a5809487b55868cdec82a719030419cbd6ba
[ "BSD-3-Clause" ]
null
null
null
nipype/interfaces/afni/tests/test_auto_Maskave.py
ito-takuya/nipype
9099a5809487b55868cdec82a719030419cbd6ba
[ "BSD-3-Clause" ]
1
2021-09-08T14:31:47.000Z
2021-09-08T14:31:47.000Z
# AUTO-GENERATED by tools/checkspecs.py - DO NOT EDIT from nipype.testing import assert_equal from nipype.interfaces.afni.preprocess import Maskave def test_Maskave_inputs(): input_map = dict(args=dict(argstr='%s', ), environ=dict(nohash=True, usedefault=True, ), ignore_exception=dict(nohash=Tr...
25.176471
78
0.644081
796a264f23170a6cd473f611152250227c1f8ce9
4,705
py
Python
ssh_keyword/ssh_keyword_connection.py
befabri/ssh-keyword
27715ea025a8baa83657bc36514d853efb8accff
[ "MIT" ]
1
2020-02-05T00:29:54.000Z
2020-02-05T00:29:54.000Z
ssh_keyword/ssh_keyword_connection.py
befabri/ssh-keyword
27715ea025a8baa83657bc36514d853efb8accff
[ "MIT" ]
null
null
null
ssh_keyword/ssh_keyword_connection.py
befabri/ssh-keyword
27715ea025a8baa83657bc36514d853efb8accff
[ "MIT" ]
null
null
null
import json from ssh_keyword_tools import checkQuit from ssh_keyword_json import ManageJson from ssh_keyword_newconnection import CreateConnection class Connection(object): 'Manage connections' def __init__(self, ip='0'): self.ip = ip self.fJson = ManageJson() def setConnection(self): ...
39.537815
106
0.53135
796a266969a72b61f16cbce9359f961b26669521
7,194
py
Python
kubernetes_asyncio/client/models/admissionregistration_v1_service_reference.py
tomplus/kubernetes-asyncio
11c3eb4d50ae822545572aa7b8c15f7153f65a1c
[ "Apache-2.0" ]
null
null
null
kubernetes_asyncio/client/models/admissionregistration_v1_service_reference.py
tomplus/kubernetes-asyncio
11c3eb4d50ae822545572aa7b8c15f7153f65a1c
[ "Apache-2.0" ]
null
null
null
kubernetes_asyncio/client/models/admissionregistration_v1_service_reference.py
tomplus/kubernetes-asyncio
11c3eb4d50ae822545572aa7b8c15f7153f65a1c
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ Kubernetes No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 The version of the OpenAPI document: v1.23.6 Generated by: https://openapi-generator.tech """ try: from inspect import getfullargspec except Im...
32.7
183
0.617876
796a275eb6f11d2893488ba1d0ebcafbf0cb6b67
52
py
Python
deploy/lights_on.py
alttch/eva-demo-smarthome
3c61b7538c676deaa427148079ead901e58b121d
[ "Apache-2.0" ]
2
2019-06-08T01:19:48.000Z
2021-01-23T13:05:14.000Z
cfg/lights_on.py
dyachenko93/eva-demo-smarthome
5c71ec587174a60f2832efd6df12101520edaa13
[ "Apache-2.0" ]
null
null
null
cfg/lights_on.py
dyachenko93/eva-demo-smarthome
5c71ec587174a60f2832efd6df12101520edaa13
[ "Apache-2.0" ]
2
2019-06-14T15:54:21.000Z
2021-01-24T03:41:30.000Z
start('unit:light/room1') start('unit:light/room2')
17.333333
25
0.730769
796a27886014df5ca961610cd4db643edfb4ecf0
23,514
py
Python
saleor/order/actions.py
vililahtevanoja/saleor
4127d917a81b99e8011035fd5d7f71ba3b7a447f
[ "CC-BY-4.0" ]
null
null
null
saleor/order/actions.py
vililahtevanoja/saleor
4127d917a81b99e8011035fd5d7f71ba3b7a447f
[ "CC-BY-4.0" ]
null
null
null
saleor/order/actions.py
vililahtevanoja/saleor
4127d917a81b99e8011035fd5d7f71ba3b7a447f
[ "CC-BY-4.0" ]
null
null
null
import logging from decimal import Decimal from typing import TYPE_CHECKING, Dict, List, Optional, Tuple from django.contrib.sites.models import Site from django.db import transaction from ..core import analytics from ..core.exceptions import InsufficientStock from ..order.emails import send_order_confirmed from ..pa...
36.287037
88
0.698265
796a2806767ed712b7a39ef2a11e1f22d536737d
487
py
Python
tests/test_parse_struct.py
ousttrue/cpptypeinfo
38b219ec5683dbba380e6f5ca2074c1ea0ccfaa9
[ "MIT" ]
1
2021-03-22T10:19:52.000Z
2021-03-22T10:19:52.000Z
tests/test_parse_struct.py
ousttrue/cpptypeinfo
38b219ec5683dbba380e6f5ca2074c1ea0ccfaa9
[ "MIT" ]
null
null
null
tests/test_parse_struct.py
ousttrue/cpptypeinfo
38b219ec5683dbba380e6f5ca2074c1ea0ccfaa9
[ "MIT" ]
null
null
null
import unittest import cpptypeinfo SOURCE = ''' struct B; struct B; struct B { int value; }; struct { int a; }; struct { int a; } end; typedef struct tag { int a; } A; void func (); void func () { } ''' class StructTests(unittest.TestCase): def test_struct(self) -...
12.815789
61
0.577002
796a28ca4c2f2a58d572adccdc1de5865293df1f
5,055
py
Python
gennav/planners/prm/prmstar.py
harsh336/gennav
36ab23b39b2c6411872b09806fd562256b33677e
[ "MIT" ]
null
null
null
gennav/planners/prm/prmstar.py
harsh336/gennav
36ab23b39b2c6411872b09806fd562256b33677e
[ "MIT" ]
null
null
null
gennav/planners/prm/prmstar.py
harsh336/gennav
36ab23b39b2c6411872b09806fd562256b33677e
[ "MIT" ]
null
null
null
import math from gennav.planners.base import Planner from gennav.utils import Trajectory from gennav.utils.custom_exceptions import ( InvalidGoalState, InvalidStartState, PathNotFound, ) from gennav.utils.geometry import compute_distance from gennav.utils.graph import Graph from gennav.utils.graph_search.a...
38.007519
107
0.561227
796a29b657eb72c4582664e831785eeb7dfbad45
838
py
Python
src/ralph/ui/forms/util.py
deejay1/ralph
26b7c66912590093e0087ba801e9108290ad0d63
[ "Apache-2.0" ]
1
2018-09-01T14:14:08.000Z
2018-09-01T14:14:08.000Z
src/ralph/ui/forms/util.py
srikanth4372/sample
127b5742ae464d42909a14d71e3c10c241ec3a23
[ "Apache-2.0" ]
1
2019-08-14T10:03:45.000Z
2019-08-14T10:03:45.000Z
src/ralph/ui/forms/util.py
srikanth4372/sample
127b5742ae464d42909a14d71e3c10c241ec3a23
[ "Apache-2.0" ]
1
2019-08-14T09:59:42.000Z
2019-08-14T09:59:42.000Z
# -*- coding: utf-8 -*- from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals from ralph.business.models import Venture, VentureRole def all_ventures(): yield '', '---------' for v in Venture.objects.filter(show_in...
27.933333
78
0.573986
796a29eacd6edbd5e3a1fc17ab98f89a0b278b1a
895
py
Python
src/multiple_trees/compare_trees.py
npakudin/embrionic_tree
fe4c6379cf9b63ec116678549bd284abff638655
[ "MIT" ]
null
null
null
src/multiple_trees/compare_trees.py
npakudin/embrionic_tree
fe4c6379cf9b63ec116678549bd284abff638655
[ "MIT" ]
5
2020-08-01T03:01:38.000Z
2022-03-12T00:45:17.000Z
src/multiple_trees/compare_trees.py
npakudin/embrionic_tree
fe4c6379cf9b63ec116678549bd284abff638655
[ "MIT" ]
null
null
null
import copy from src.multiple_trees.trees_matrix import full_distance from src.single_tree.development_tree_reader import read_all_trees def get_distances_by_files(pattern, global_params, is_reducing, use_flipping=False, use_min_common_depth=False, is_test_nodes=False): # read trees from *.xtg files in xtg folde...
37.291667
133
0.765363
796a2a2f65bf41362baa7adaca7b2c4104751574
13,672
py
Python
openregistry/lots/loki/tests/blanks/item_blanks.py
oleksiyVeretiuk/openregistry.lots.loki
0039c101fca4732e96904b93ac2efcbdd338900f
[ "Apache-2.0" ]
null
null
null
openregistry/lots/loki/tests/blanks/item_blanks.py
oleksiyVeretiuk/openregistry.lots.loki
0039c101fca4732e96904b93ac2efcbdd338900f
[ "Apache-2.0" ]
null
null
null
openregistry/lots/loki/tests/blanks/item_blanks.py
oleksiyVeretiuk/openregistry.lots.loki
0039c101fca4732e96904b93ac2efcbdd338900f
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from datetime import timedelta from copy import deepcopy from uuid import uuid4 from openregistry.lots.core.utils import ( get_now, calculate_business_date ) from openregistry.lots.core.models import Period from openregistry.lots.loki.models import Lot from openregistry.lots.loki.tests....
46.345763
117
0.64014
796a2aa20065cb2ae7110dba88c82dfb5a2bf33a
1,305
py
Python
demo.py
MKegler/pyNSL
43ba95b3fa072b8af35de3999bce586d055acde2
[ "MIT" ]
2
2022-01-26T19:48:43.000Z
2022-03-08T12:01:06.000Z
demo.py
MKegler/pyNSL
43ba95b3fa072b8af35de3999bce586d055acde2
[ "MIT" ]
1
2021-07-05T15:19:46.000Z
2021-07-07T09:46:17.000Z
demo.py
MKegler/pyNSL
43ba95b3fa072b8af35de3999bce586d055acde2
[ "MIT" ]
null
null
null
""" Demo usage of the pyNSL package. Mikolaj Kegler, January 2021 """ import matplotlib.pyplot as plt import soundfile as sf import pyNSL # Load sample audio (for plotting) audio, fs = sf.read('./SampleData/SX95.WAV') # Set up parameters paras = [8, 8, -2, -1] # Window size: 8 ms # Integration window: 8 ms # Compres...
27.765957
80
0.697318
796a2b098c8d3de83c029d0761a005cff2ad2cfb
522
py
Python
Unification Algorithm An Assignment/solution.py
mahajanakshat07/mobilecomputing855
ec869f42845362a8062c3be124692ce1db1928be
[ "Unlicense" ]
null
null
null
Unification Algorithm An Assignment/solution.py
mahajanakshat07/mobilecomputing855
ec869f42845362a8062c3be124692ce1db1928be
[ "Unlicense" ]
null
null
null
Unification Algorithm An Assignment/solution.py
mahajanakshat07/mobilecomputing855
ec869f42845362a8062c3be124692ce1db1928be
[ "Unlicense" ]
null
null
null
#This file is used to take input from User. # from unification import unification #take input from user term1 = raw_input(" Enter First Term : ex : f(f(X,Y),X) ") term2 = raw_input("Enter Second Term : ex : f(f(X,Y),X)") term1=term1.replace(" ", "") term2=term2.replace(" ","") print("First Term= "+te...
19.333333
59
0.622605
796a2c97c0b62dc587d27470f2128eef68bedda9
1,147
py
Python
Unit11/downloadXkcd.py
yanfeng12/AutoMakePython
ef3d00aa0947f52b8336fd17b815e612728d7bde
[ "MIT" ]
null
null
null
Unit11/downloadXkcd.py
yanfeng12/AutoMakePython
ef3d00aa0947f52b8336fd17b815e612728d7bde
[ "MIT" ]
null
null
null
Unit11/downloadXkcd.py
yanfeng12/AutoMakePython
ef3d00aa0947f52b8336fd17b815e612728d7bde
[ "MIT" ]
null
null
null
#! python3 # downloadXkcd.py - Downloads every single XKCD comic. import requests, os, bs4 url = 'http://xkcd.com' # starting url os.makedirs('xkcd',exist_ok=True) # store comics in ./xkcd while not url.endswith('#'): # Download the page print('Downloading page %s...' %url) res = requests....
27.97561
80
0.6068
796a2d1a527e45b27dfa5d96b3d20f2849edcf51
271
py
Python
static/code/backpropagation/ce.py
navivokaj/deepcourse
c5385e7a7b8417fe1017f1057e8e5d32b4a24bb5
[ "Apache-2.0" ]
91
2021-08-28T05:03:36.000Z
2022-01-27T09:46:36.000Z
static/code/backpropagation/ce.py
faisalbi/deepcourse
fe26314e43896013d195955d16fc4f215e39a53a
[ "Apache-2.0" ]
8
2021-09-14T13:21:56.000Z
2021-12-28T19:45:51.000Z
static/code/backpropagation/ce.py
faisalbi/deepcourse
fe26314e43896013d195955d16fc4f215e39a53a
[ "Apache-2.0" ]
10
2021-08-28T22:32:19.000Z
2022-03-16T11:13:02.000Z
def cross_entropy(probs, targets): return -torch.sum(targets * torch.log(probs + 1e-8), dim=1) probs = torch.tensor([ [0.9, 0.1], [0.7, 0.3], [0.2, 0.8], [0.6, 0.4] ]) targets = torch.eye(2)[torch.tensor([0, 0, 0, 1])] cross_entropy(probs, targets)
20.846154
63
0.579336
796a2d3b12756e446a2231da7522d9aa49455863
15,098
py
Python
src/oci/cloud_guard/models/create_target_details.py
LaudateCorpus1/oci-python-sdk
b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015
[ "Apache-2.0", "BSD-3-Clause" ]
null
null
null
src/oci/cloud_guard/models/create_target_details.py
LaudateCorpus1/oci-python-sdk
b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015
[ "Apache-2.0", "BSD-3-Clause" ]
null
null
null
src/oci/cloud_guard/models/create_target_details.py
LaudateCorpus1/oci-python-sdk
b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015
[ "Apache-2.0", "BSD-3-Clause" ]
null
null
null
# coding: utf-8 # Copyright (c) 2016, 2022, Oracle and/or its affiliates. All rights reserved. # This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may c...
36.645631
245
0.677772
796a2d739695bf1e297cdc51edf5c2446afcfafc
379
py
Python
model.py
VilkaMini/tc-235-files
63ef7625082eb56d5c18544f34c0ede460479f32
[ "MIT" ]
null
null
null
model.py
VilkaMini/tc-235-files
63ef7625082eb56d5c18544f34c0ede460479f32
[ "MIT" ]
null
null
null
model.py
VilkaMini/tc-235-files
63ef7625082eb56d5c18544f34c0ede460479f32
[ "MIT" ]
null
null
null
from sklearn.datasets import load_boston from sklearn.model_selection import train_test_split from sklearn.linear_model import LinearRegression import pickle data = load_boston() X_train, X_test, y_train, y_test = train_test_split(data.data, data.target) clf = LinearRegression() clf.fit(X_train, y_train) with open(...
27.071429
75
0.794195
796a2e7bc657f9f5a4eb150e08a56aab16df07f4
1,731
py
Python
userbot/plugins/something.py
SamRamdhan/FridayUserbot
b19a98815bdd787820ee5ab344fb4b0c9e3405eb
[ "MIT" ]
null
null
null
userbot/plugins/something.py
SamRamdhan/FridayUserbot
b19a98815bdd787820ee5ab344fb4b0c9e3405eb
[ "MIT" ]
null
null
null
userbot/plugins/something.py
SamRamdhan/FridayUserbot
b19a98815bdd787820ee5ab344fb4b0c9e3405eb
[ "MIT" ]
2
2020-09-11T08:29:23.000Z
2020-12-25T19:52:35.000Z
''' Whatever Plugin by Noobs of Telegram i.e. @pureindialover ''' from telethon import events import asyncio import os import sys from uniborg.util import admin_cmd @borg.on(admin_cmd(pattern=r"lmoon")) async def test(event): if event.fwd_from: return await event.edit("🌕🌕🌕🌕🌕🌕🌕🌕\n🌕🌕🌖🌔🌖🌔�...
32.660377
184
0.400924
796a2ea5e109507ec61d82e54ed688953a6f891d
20,096
py
Python
quotes.py
pynshaixcx/JarvisAutomation
de06adbf396941f5038b53775a9d36697bc41080
[ "MIT" ]
1
2021-07-16T17:22:21.000Z
2021-07-16T17:22:21.000Z
quotes.py
pynshaixcx/JarvisAutomation
de06adbf396941f5038b53775a9d36697bc41080
[ "MIT" ]
null
null
null
quotes.py
pynshaixcx/JarvisAutomation
de06adbf396941f5038b53775a9d36697bc41080
[ "MIT" ]
null
null
null
import random import pyttsx3 engine = pyttsx3.init() engine.setProperty('rate',115) def engine_speak(text): text = str(text) engine.say(text) voices = engine.getProperty('voices') engine.setProperty('voice',voices[0].id) engine.setProperty('rate',115) engine.runAndWait() def Quo...
78.807843
168
0.752339
796a2edbefbf5f515482c757f74df793a78c427a
5,058
py
Python
test/functional/rpc_preciousblock.py
lihuanghai/bitcoin
624da15f8c55219f4ca3e0877a17799990299504
[ "MIT" ]
20
2019-04-03T06:30:39.000Z
2019-11-07T08:57:50.000Z
test/functional/rpc_preciousblock.py
ksystemsio/bitcoin
a589f536b5e15daf3ac6ffcc137a146514c81967
[ "MIT" ]
28
2018-03-20T03:49:17.000Z
2018-03-21T18:13:08.000Z
test/functional/rpc_preciousblock.py
ksystemsio/bitcoin
a589f536b5e15daf3ac6ffcc137a146514c81967
[ "MIT" ]
19
2017-08-29T02:08:40.000Z
2021-05-22T09:14:09.000Z
#!/usr/bin/env python3 # Copyright (c) 2015-2017 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test the preciousblock RPC.""" from test_framework.test_framework import BitcoinTestFramework from tes...
44.368421
127
0.669039
796a2f23a4669b174153344e7ef56abf037dcaf3
1,657
py
Python
awards_app/migrations/0001_initial.py
jakesIII/awwwards
869f3524a379bc862179a06c4336d34401351299
[ "Unlicense" ]
null
null
null
awards_app/migrations/0001_initial.py
jakesIII/awwwards
869f3524a379bc862179a06c4336d34401351299
[ "Unlicense" ]
3
2020-06-06T00:35:27.000Z
2021-06-10T22:29:20.000Z
awards_app/migrations/0001_initial.py
jakesIII/awwwards
869f3524a379bc862179a06c4336d34401351299
[ "Unlicense" ]
1
2020-02-19T23:46:14.000Z
2020-02-19T23:46:14.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.11 on 2020-01-11 09:31 from __future__ import unicode_literals from django.conf import settings from django.db import migrations, models import django.db.models.deletion import pyuploadcare.dj.models class Migration(migrations.Migration): initial = True depen...
38.534884
121
0.614363
796a2f4ae986fb6418e5024b32e6208411d57278
1,708
py
Python
app/core/migrations/0001_initial.py
agarciapnp/recipe-api-travis-fix
4ce5743c56b52d9f5ac7487025474dde731b4cc1
[ "MIT" ]
205
2018-12-23T01:16:25.000Z
2022-03-23T19:02:27.000Z
app/core/migrations/0001_initial.py
agarciapnp/recipe-api-travis-fix
4ce5743c56b52d9f5ac7487025474dde731b4cc1
[ "MIT" ]
5
2020-09-28T23:20:51.000Z
2021-07-01T23:19:03.000Z
app/core/migrations/0001_initial.py
agarciapnp/recipe-api-travis-fix
4ce5743c56b52d9f5ac7487025474dde731b4cc1
[ "MIT" ]
201
2018-11-18T05:42:04.000Z
2022-03-28T20:09:44.000Z
# Generated by Django 2.1.3 on 2018-11-08 21:09 from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operations = [ migrations.CreateModel( name='User', ...
50.235294
266
0.638759
796a2fbed7245dd7dd2347ab81f2f923e9b5a26b
5,672
py
Python
configure_pretraining.py
shadow2496/electra
94f29444f8d08b631315a4cd4e117b52e400a2cd
[ "Apache-2.0" ]
1
2020-06-18T08:16:59.000Z
2020-06-18T08:16:59.000Z
configure_pretraining.py
shadow2496/electra
94f29444f8d08b631315a4cd4e117b52e400a2cd
[ "Apache-2.0" ]
null
null
null
configure_pretraining.py
shadow2496/electra
94f29444f8d08b631315a4cd4e117b52e400a2cd
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # Copyright 2020 The Google Research Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicab...
39.117241
86
0.687764
796a30021bad8a8a454caa1d8b180212ecdc53e5
3,530
py
Python
src/rogerthat/cron/birthday.py
goubertbrent/oca-backend
b9f59cc02568aecb55d4b54aec05245790ea25fd
[ "Apache-2.0" ]
null
null
null
src/rogerthat/cron/birthday.py
goubertbrent/oca-backend
b9f59cc02568aecb55d4b54aec05245790ea25fd
[ "Apache-2.0" ]
null
null
null
src/rogerthat/cron/birthday.py
goubertbrent/oca-backend
b9f59cc02568aecb55d4b54aec05245790ea25fd
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2020 Green Valley Belgium NV # # 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 appl...
45.25641
117
0.740227
796a302fe92a37257ba88707545d88b9ebe45886
2,657
py
Python
tools/Polygraphy/polygraphy/backend/onnxrt/runner.py
KaliberAI/TensorRT
34a167558058bb801176430d37d38a46328ab0d2
[ "Apache-2.0" ]
5,249
2019-06-17T17:20:34.000Z
2022-03-31T17:56:05.000Z
tools/Polygraphy/polygraphy/backend/onnxrt/runner.py
KaliberAI/TensorRT
34a167558058bb801176430d37d38a46328ab0d2
[ "Apache-2.0" ]
1,721
2019-06-17T18:13:29.000Z
2022-03-31T16:09:53.000Z
tools/Polygraphy/polygraphy/backend/onnxrt/runner.py
KaliberAI/TensorRT
34a167558058bb801176430d37d38a46328ab0d2
[ "Apache-2.0" ]
1,414
2019-06-18T04:01:17.000Z
2022-03-31T09:16:53.000Z
# # Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appl...
33.2125
99
0.639067
796a31013e0adbd45db6a7d7daa4fe79c9924582
2,675
py
Python
sherpa_client/models/role_desc.py
kairntech/sherpa-client
cd259c87b7291eeec3f3ea025e368f2f069a06cd
[ "Apache-2.0" ]
null
null
null
sherpa_client/models/role_desc.py
kairntech/sherpa-client
cd259c87b7291eeec3f3ea025e368f2f069a06cd
[ "Apache-2.0" ]
null
null
null
sherpa_client/models/role_desc.py
kairntech/sherpa-client
cd259c87b7291eeec3f3ea025e368f2f069a06cd
[ "Apache-2.0" ]
null
null
null
from typing import Any, Dict, List, Type, TypeVar, Union, cast import attr from ..types import UNSET, Unset T = TypeVar("T", bound="RoleDesc") @attr.s(auto_attribs=True) class RoleDesc: """ """ label: str permissions: List[str] rolename: str type: str created_at: Union[Unset, str] = UNSET ...
27.020202
63
0.577196
796a317f3b70326f9daa5a81758873dfbb1c0987
464
py
Python
alipay/aop/api/response/AlipayEcoCplifeResidentinfoDeleteResponse.py
snowxmas/alipay-sdk-python-all
96870ced60facd96c5bce18d19371720cbda3317
[ "Apache-2.0" ]
213
2018-08-27T16:49:32.000Z
2021-12-29T04:34:12.000Z
alipay/aop/api/response/AlipayEcoCplifeResidentinfoDeleteResponse.py
snowxmas/alipay-sdk-python-all
96870ced60facd96c5bce18d19371720cbda3317
[ "Apache-2.0" ]
29
2018-09-29T06:43:00.000Z
2021-09-02T03:27:32.000Z
alipay/aop/api/response/AlipayEcoCplifeResidentinfoDeleteResponse.py
snowxmas/alipay-sdk-python-all
96870ced60facd96c5bce18d19371720cbda3317
[ "Apache-2.0" ]
59
2018-08-27T16:59:26.000Z
2022-03-25T10:08:15.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- import json from alipay.aop.api.response.AlipayResponse import AlipayResponse class AlipayEcoCplifeResidentinfoDeleteResponse(AlipayResponse): def __init__(self): super(AlipayEcoCplifeResidentinfoDeleteResponse, self).__init__() def parse_response_cont...
29
114
0.790948
796a31eab7b4cba23dcbefa8c6b71a98495dc676
13,815
py
Python
google/ads/google_ads/v4/proto/errors/url_field_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
1
2021-04-09T04:28:47.000Z
2021-04-09T04:28:47.000Z
google/ads/google_ads/v4/proto/errors/url_field_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
null
null
null
google/ads/google_ads/v4/proto/errors/url_field_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/ads/googleads_v4/proto/errors/url_field_error.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import...
45.745033
3,037
0.76055
796a31ee1d36de67a2ce48b093c1eef29cc451fe
3,174
py
Python
docs/conf.py
sharad16j/flask
d887d32f4d0effedb6bf40f3d2ad790036934387
[ "BSD-3-Clause" ]
2
2020-11-29T13:02:43.000Z
2020-11-29T13:02:46.000Z
docs/conf.py
sharad16j/flask
d887d32f4d0effedb6bf40f3d2ad790036934387
[ "BSD-3-Clause" ]
1
2021-04-20T21:35:38.000Z
2021-04-20T21:35:38.000Z
docs/conf.py
sharad16j/flask
d887d32f4d0effedb6bf40f3d2ad790036934387
[ "BSD-3-Clause" ]
1
2020-10-25T20:19:55.000Z
2020-10-25T20:19:55.000Z
import packaging.version from pallets_sphinx_themes import get_version from pallets_sphinx_themes import ProjectLink # Project -------------------------------------------------------------- project = "Flask" copyright = "2010 Pallets" author = "Pallets" release, version = get_version("Flask") # General -------------...
33.0625
86
0.604915
796a321d94e6221da2957b55b95ddf43fb7d4fa8
4,281
py
Python
osgar/tools/log2video.py
robotika/osgar
6f4f584d5553ab62c08a1c7bb493fefdc9033173
[ "MIT" ]
12
2017-02-16T10:22:59.000Z
2022-03-20T05:48:06.000Z
osgar/tools/log2video.py
robotika/osgar
6f4f584d5553ab62c08a1c7bb493fefdc9033173
[ "MIT" ]
618
2016-08-30T04:46:12.000Z
2022-03-25T16:03:10.000Z
osgar/tools/log2video.py
robotika/osgar
6f4f584d5553ab62c08a1c7bb493fefdc9033173
[ "MIT" ]
11
2016-08-27T20:02:55.000Z
2022-03-07T08:53:53.000Z
#!/usr/bin/python """ Convert logfile to AVI video """ import pathlib from datetime import timedelta try: import cv2 except ImportError: print('\nERROR: Please install OpenCV\n pip install opencv-python\n') try: import numpy as np except ImportError: print('\nERROR: Please install numpy\n pip ...
39.275229
98
0.570895
796a3348f3368d8209f846089de2dcde3476ca35
10,228
py
Python
py/moma/subtask_env.py
wx-b/dm_robotics
5d407622360ccf7f0b4b50bcee84589e2cfd0783
[ "Apache-2.0" ]
128
2021-09-08T18:39:39.000Z
2022-03-27T11:29:05.000Z
py/moma/subtask_env.py
wx-b/dm_robotics
5d407622360ccf7f0b4b50bcee84589e2cfd0783
[ "Apache-2.0" ]
7
2021-10-11T14:26:17.000Z
2022-03-15T17:26:45.000Z
py/moma/subtask_env.py
wx-b/dm_robotics
5d407622360ccf7f0b4b50bcee84589e2cfd0783
[ "Apache-2.0" ]
8
2021-09-08T18:25:49.000Z
2022-02-21T23:45:16.000Z
# Copyright 2020 DeepMind Technologies Limited. # # 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 ag...
34.093333
80
0.716367
796a3368a6adb969e99c80ce296ff5832d2dcbfe
538
py
Python
example/speech_recognition/stt_bucketing_module.py
zt706/-mxnet_for_ssd
cd1c21ffa30d8be6c7cb7909de8bec8a0fb7b71d
[ "Apache-2.0" ]
1
2018-09-08T05:58:17.000Z
2018-09-08T05:58:17.000Z
example/speech_recognition/stt_bucketing_module.py
zt706/-mxnet_for_ssd
cd1c21ffa30d8be6c7cb7909de8bec8a0fb7b71d
[ "Apache-2.0" ]
null
null
null
example/speech_recognition/stt_bucketing_module.py
zt706/-mxnet_for_ssd
cd1c21ffa30d8be6c7cb7909de8bec8a0fb7b71d
[ "Apache-2.0" ]
1
2018-09-04T10:46:25.000Z
2018-09-04T10:46:25.000Z
import mxnet as mx class STTBucketingModule(mx.mod.BucketingModule): def save_checkpoint(self, prefix, epoch, save_optimizer_states=False): symbol, data_names, label_names = self._sym_gen(self._default_bucket_key) symbol.save('%s-symbol.json' % prefix) param_name = '%s-%04d.params...
41.384615
82
0.674721
796a336b7145c3acd708019c6ae69753b319246f
323
py
Python
index.py
yubang/shortUrl
f449d061e1882058775cd7663f6e3a81e51eeb81
[ "Apache-2.0" ]
null
null
null
index.py
yubang/shortUrl
f449d061e1882058775cd7663f6e3a81e51eeb81
[ "Apache-2.0" ]
null
null
null
index.py
yubang/shortUrl
f449d061e1882058775cd7663f6e3a81e51eeb81
[ "Apache-2.0" ]
2
2015-10-01T00:43:53.000Z
2019-09-13T13:10:25.000Z
#coding:UTF-8 """ 短网址生成小应用 """ from flask import Flask,redirect from shortUrl.app import sApp app=Flask(__name__) app.register_blueprint(sApp,url_prefix="/shortUrl") @app.route("/") def index(): "主页面" return redirect("/shortUrl") if __name__ == "__main__": app.run(debug=True,host="0.0.0.0",port=800...
13.458333
51
0.681115
796a336e76b885d5e89f439b4a92bf7a87d75184
79,162
py
Python
Python27/ORCSim/PHEX_ASME2015.py
labothap/ORCmKit
10b930c00f47983a3d6eae62363afa872c4dafb6
[ "MIT" ]
16
2016-10-05T10:44:46.000Z
2022-02-04T04:43:04.000Z
Python27/ORCSim/PHEX_ASME2015.py
labothap/ORCmKit
10b930c00f47983a3d6eae62363afa872c4dafb6
[ "MIT" ]
12
2016-06-27T21:41:14.000Z
2020-05-26T01:52:28.000Z
Python27/ORCSim/PHEX_ASME2015.py
labothap/ORCmKit
10b930c00f47983a3d6eae62363afa872c4dafb6
[ "MIT" ]
17
2017-01-29T16:23:52.000Z
2022-02-07T03:44:21.000Z
""" ASME ORC 2015 3rd International Seminar on ORC Systems 12-14 October 2015, Brussels, Belgium Moving-boundary PHEX model derived from ACHP (https://github.com/TSTK) and modified to include incompressible fluids such as thermal oils and lubricants. At the moment only INCOMP::T66 is included. Reference Paper: D....
47.80314
277
0.575706
796a33f4536e505b6b10eab4b05be451a51c9694
761
py
Python
scripts/model_notifications.py
kkaris/emmaa
e381bac492579007efaa248bde4fa8d2005ff2f7
[ "BSD-2-Clause" ]
6
2018-11-29T09:33:07.000Z
2021-02-10T04:21:47.000Z
scripts/model_notifications.py
kkaris/emmaa
e381bac492579007efaa248bde4fa8d2005ff2f7
[ "BSD-2-Clause" ]
53
2019-02-01T14:44:57.000Z
2021-09-17T16:13:28.000Z
scripts/model_notifications.py
kkaris/emmaa
e381bac492579007efaa248bde4fa8d2005ff2f7
[ "BSD-2-Clause" ]
8
2018-11-22T02:41:56.000Z
2021-03-26T19:54:41.000Z
import argparse from emmaa.subscription.notifications import model_update_notify from emmaa.db import get_db if __name__ == '__main__': parser = argparse.ArgumentParser( description='Script to tweet and email about model and test deltas.') parser.add_argument('-m', '--model', help='Model name', requir...
40.052632
78
0.653088
796a349c4edcb75b32515bc9df1b618066beda60
337
py
Python
profiles/migrations/0008_remove_groupdata_description.py
sohamdigheoss/vesit-pomas
5d6c7e32b44c8f830baddc995df4d2d9faddf2cd
[ "Apache-2.0" ]
null
null
null
profiles/migrations/0008_remove_groupdata_description.py
sohamdigheoss/vesit-pomas
5d6c7e32b44c8f830baddc995df4d2d9faddf2cd
[ "Apache-2.0" ]
null
null
null
profiles/migrations/0008_remove_groupdata_description.py
sohamdigheoss/vesit-pomas
5d6c7e32b44c8f830baddc995df4d2d9faddf2cd
[ "Apache-2.0" ]
1
2019-04-20T05:26:27.000Z
2019-04-20T05:26:27.000Z
# Generated by Django 2.1.7 on 2019-03-11 19:40 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('profiles', '0007_auto_20190311_1854'), ] operations = [ migrations.RemoveField( model_name='groupdata', name='description', ...
18.722222
48
0.602374
796a358a315d2cb966246b87b22d65c3a0284a69
22,503
py
Python
tests/data_generation_scripts/indexing.py
Shamazo/NickDB
a8189ab672e1e2af64c3c22028a94a7994b7fe8e
[ "CECILL-B" ]
null
null
null
tests/data_generation_scripts/indexing.py
Shamazo/NickDB
a8189ab672e1e2af64c3c22028a94a7994b7fe8e
[ "CECILL-B" ]
null
null
null
tests/data_generation_scripts/indexing.py
Shamazo/NickDB
a8189ab672e1e2af64c3c22028a94a7994b7fe8e
[ "CECILL-B" ]
null
null
null
#!/usr/bin/python import sys, string from random import choice import random from string import ascii_lowercase from scipy.stats import beta, uniform import numpy as np import struct import pandas as pd import math import data_gen_utils # # Example usage: # python milestone3.py 10000 42 /db/tests/gen_tests /db/tes...
54.355072
167
0.686575
796a36db0950eb66697a67fe6d8e54601c9a9828
2,405
py
Python
tests/configs/realview64-minor.py
mandaltj/gem5_chips
b9c0c602241ffda7851c1afb32fa01f295bb98fd
[ "BSD-3-Clause" ]
30
2019-07-12T02:35:33.000Z
2022-02-22T03:34:35.000Z
tests/configs/realview64-minor.py
mandaltj/gem5_chips
b9c0c602241ffda7851c1afb32fa01f295bb98fd
[ "BSD-3-Clause" ]
8
2020-02-05T17:47:10.000Z
2021-09-06T03:58:56.000Z
tests/configs/realview64-minor.py
mandaltj/gem5_chips
b9c0c602241ffda7851c1afb32fa01f295bb98fd
[ "BSD-3-Clause" ]
25
2017-12-02T00:46:04.000Z
2022-02-18T19:28:53.000Z
# Copyright (c) 2014 ARM Limited # All rights reserved. # # The license below extends only to copyright in the software and shall # not be construed as granting a license to any other intellectual # property including but not limited to intellectual property relating # to a hardware implementation of the functionality ...
53.444444
72
0.76341
796a37c3d1383bef0adde757eeb8f6b3850acf92
647
py
Python
121. Best Time to Buy and Sell Stock.py
TilokSaha/LeetCode-Solution
891910fb6b4c92de74ae361313bd65570bf85fc7
[ "MIT" ]
null
null
null
121. Best Time to Buy and Sell Stock.py
TilokSaha/LeetCode-Solution
891910fb6b4c92de74ae361313bd65570bf85fc7
[ "MIT" ]
null
null
null
121. Best Time to Buy and Sell Stock.py
TilokSaha/LeetCode-Solution
891910fb6b4c92de74ae361313bd65570bf85fc7
[ "MIT" ]
null
null
null
class Solution: def maxProfit(self, prices: List[int]) -> int: n = len(prices) ans = 0 Sum = 0 for i in range(n-1): # <--------- Another application of Kadane's algorithm Sum += prices[i+1] - prices[i] # <------ Finding the consecutive difference if ...
58.818182
108
0.506955
796a3838e3ccabb143baa6bdd176da8a76c6de97
866
py
Python
sheets_and_friends/column_update.py
turbomam/sheets_and_friends
2f7c6f512847a7ad833f7ef8c1796fa1a448ac47
[ "MIT" ]
null
null
null
sheets_and_friends/column_update.py
turbomam/sheets_and_friends
2f7c6f512847a7ad833f7ef8c1796fa1a448ac47
[ "MIT" ]
85
2022-02-11T18:35:14.000Z
2022-03-31T17:11:28.000Z
sheets_and_friends/column_update.py
microbiomedata/sheets_and_friends
5a0e41f86cc9188bc9ff86cdf6f4e54ad72bdb55
[ "MIT" ]
null
null
null
import os.path import pandas as pd from pathlib import Path old_file = "data/nmdc_test_data_valid.tsv" extension_val = ".tsv" suffix_val = "_lowercased" path_prefix = "artifacts" basename = Path(old_file).stem with_extension = basename + suffix_val + extension_val with_path = os.path.join(path_prefix, with_extensi...
25.470588
111
0.788684
796a3844bb6ba3dbdf362ad8a38367d264e25b35
3,025
py
Python
vessel_tracking/mcts.py
gmaher/vessel_tracking
3fd31f0b999bcd570199efd0dc7478924a90704e
[ "MIT" ]
1
2019-12-16T23:07:51.000Z
2019-12-16T23:07:51.000Z
vessel_tracking/mcts.py
gmaher/vessel_tracking
3fd31f0b999bcd570199efd0dc7478924a90704e
[ "MIT" ]
null
null
null
vessel_tracking/mcts.py
gmaher/vessel_tracking
3fd31f0b999bcd570199efd0dc7478924a90704e
[ "MIT" ]
null
null
null
class Node(object): def __init__(self, state, terminal=False): self.state = state self.value = 0 self.children = [] self.visits = 0 self.terminal = terminal def terminal(node): index = node.state for i in range(2): if index[i] == 0 or index[i] == N: return Tr...
28.537736
77
0.513388
796a3ad3e044808738579d2557a38e62588ed0ae
643
py
Python
a/Avishay/main.py
yuribernstein2/intservice
cd1dbab0c971f0e05180f84f9888eb973935d28b
[ "Apache-2.0" ]
1
2021-01-03T22:00:11.000Z
2021-01-03T22:00:11.000Z
a/Avishay/main.py
yuribernstein2/intservice
cd1dbab0c971f0e05180f84f9888eb973935d28b
[ "Apache-2.0" ]
null
null
null
a/Avishay/main.py
yuribernstein2/intservice
cd1dbab0c971f0e05180f84f9888eb973935d28b
[ "Apache-2.0" ]
5
2020-12-15T16:39:43.000Z
2021-04-18T13:17:58.000Z
import json import send import argparse from logs import logger def load_config(): with open('./configuration.json') as json_file: configs = json.load(json_file) key = configs['configuration']['key'] host = configs['configuration']['host'] return key, host # spiderman def main():...
24.730769
98
0.659409
796a3c8e51bef12f8ba8e25ce585baabc92c2ac2
85
py
Python
integration/tests/conftest.py
alan-turing-institute/gateway
443d30a558cc14757ad928670a2481a94b7be27b
[ "MIT" ]
3
2019-07-29T11:32:06.000Z
2020-07-13T17:27:52.000Z
integration/tests/conftest.py
alan-turing-institute/science-gateway
443d30a558cc14757ad928670a2481a94b7be27b
[ "MIT" ]
42
2017-07-31T10:49:58.000Z
2018-02-25T17:13:22.000Z
integration/tests/conftest.py
alan-turing-institute/gateway
443d30a558cc14757ad928670a2481a94b7be27b
[ "MIT" ]
1
2018-07-17T06:52:55.000Z
2018-07-17T06:52:55.000Z
import pytest def pytest_namespace(): return {"token": None, "headers": None}
12.142857
43
0.670588
796a3d2ca0526f50a710640327fc88d1a1177414
1,059
py
Python
dataprep/tests/eda/test_create_report.py
kla55/dataprep
75542cda64570f1fe3c4ac61e670cc0ce2febaa3
[ "MIT" ]
null
null
null
dataprep/tests/eda/test_create_report.py
kla55/dataprep
75542cda64570f1fe3c4ac61e670cc0ce2febaa3
[ "MIT" ]
null
null
null
dataprep/tests/eda/test_create_report.py
kla55/dataprep
75542cda64570f1fe3c4ac61e670cc0ce2febaa3
[ "MIT" ]
null
null
null
""" module for testing create_report(df) function. """ import logging import numpy as np import pandas as pd import pytest from ...eda import create_report LOGGER = logging.getLogger(__name__) @pytest.fixture(scope="module") # type: ignore def simpledf() -> pd.DataFrame: df = pd.DataFrame(np.random.rand(100...
24.068182
86
0.544854
796a3e4397ca400e5aa486ea3c23f40c331b8fef
1,972
py
Python
custom_components/dpc/const.py
caiosweet/METEO-HYDRO-ALERT
556a711ef71d71cf7e38487a6ab7b80a994af3bf
[ "MIT" ]
null
null
null
custom_components/dpc/const.py
caiosweet/METEO-HYDRO-ALERT
556a711ef71d71cf7e38487a6ab7b80a994af3bf
[ "MIT" ]
null
null
null
custom_components/dpc/const.py
caiosweet/METEO-HYDRO-ALERT
556a711ef71d71cf7e38487a6ab7b80a994af3bf
[ "MIT" ]
null
null
null
"""Constants for Dpc.""" import logging from homeassistant.components.binary_sensor import DOMAIN as BINARY_SENSOR_DOMAIN from homeassistant.components.sensor import DOMAIN as SENSOR_DOMAIN LOGGER = logging.getLogger(__package__) PLATFORMS = [BINARY_SENSOR_DOMAIN, SENSOR_DOMAIN] # Base component constants ATTRIBUTIO...
25.947368
92
0.710446
796a3e53d98672e77597f0e841c3cb2dab8f64b2
2,113
py
Python
userbot/plugins/_helper.py
IAmNoobAF/NoobAFUserBot
e1d50c6c3b8178cd075a009ac94936f3c8539b55
[ "MIT" ]
null
null
null
userbot/plugins/_helper.py
IAmNoobAF/NoobAFUserBot
e1d50c6c3b8178cd075a009ac94936f3c8539b55
[ "MIT" ]
null
null
null
userbot/plugins/_helper.py
IAmNoobAF/NoobAFUserBot
e1d50c6c3b8178cd075a009ac94936f3c8539b55
[ "MIT" ]
null
null
null
from userbot import CMD_LIST from userbot.utils import admin_cmd @command(pattern="^.help ?(.*)") #@borg.on(admin_cmd(pattern=r"help ?(.*)")) async def cmd_list(event): if not event.text[0].isalpha() and event.text[0] not in ("/", "#", "@", "!"): tgbotusername = Var.TG_BOT_USER_NAME_BF_HER input_st...
39.867925
138
0.469948
796a3f07c21e032cbe360485980639329d58218e
1,984
py
Python
tests/test_tokenization_fast.py
MichalPitr/transformers
8b26688e2e4b68a64f4710b3627439089947cb08
[ "Apache-2.0" ]
101
2021-12-22T00:03:51.000Z
2022-03-30T07:39:09.000Z
tests/test_tokenization_fast.py
MichalPitr/transformers
8b26688e2e4b68a64f4710b3627439089947cb08
[ "Apache-2.0" ]
5
2021-12-30T07:01:11.000Z
2022-03-28T01:56:04.000Z
tests/test_tokenization_fast.py
MichalPitr/transformers
8b26688e2e4b68a64f4710b3627439089947cb08
[ "Apache-2.0" ]
11
2021-12-30T06:18:04.000Z
2022-03-28T13:50:00.000Z
# coding=utf-8 # Copyright 2019 HuggingFace 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 ag...
36.740741
117
0.756048
796a3fc2922f99df2426810ef6c80939cfd1175d
18,836
py
Python
yolov5/yolov5_trt_api.py
karmarv/tensorrtx
bcce74246c71d381192c577d346cb2aa67af05b7
[ "MIT" ]
null
null
null
yolov5/yolov5_trt_api.py
karmarv/tensorrtx
bcce74246c71d381192c577d346cb2aa67af05b7
[ "MIT" ]
null
null
null
yolov5/yolov5_trt_api.py
karmarv/tensorrtx
bcce74246c71d381192c577d346cb2aa67af05b7
[ "MIT" ]
null
null
null
""" An example that uses TensorRT's Python api to make inferences. """ import ctypes import os import shutil import random import sys import threading import time import cv2 import numpy as np import pycuda.autoinit import pycuda.driver as cuda import tensorrt as trt import torch import torchvision CONF_THRESH = 0.5 I...
39.82241
194
0.583086
796a3fc92fa5ad372aa465956d40cec79ef05d55
4,940
py
Python
Staging/GTK 3 Interface - Creating a Program Launcher (Pt 2).py
mccolm-robotics/Claver-AI-Assistant
12b31633b4a45709403ed9599c626e63743318c7
[ "MIT" ]
1
2020-05-22T18:45:07.000Z
2020-05-22T18:45:07.000Z
Staging/GTK 3 Interface - Creating a Program Launcher (Pt 2).py
mccolm-robotics/Claver-AI-Assistant
12b31633b4a45709403ed9599c626e63743318c7
[ "MIT" ]
null
null
null
Staging/GTK 3 Interface - Creating a Program Launcher (Pt 2).py
mccolm-robotics/Claver-AI-Assistant
12b31633b4a45709403ed9599c626e63743318c7
[ "MIT" ]
null
null
null
import gi import sys gi.require_version('Gtk', '3.0') from gi.repository import Gtk, Gdk class MyApplication(Gtk.Application): def __init__(self): Gtk.Application.__init__(self) self.is_fullscreen = False self.monitor_num_for_display = 0 def do_activate(self): window = Gtk.Win...
36.058394
105
0.640688
796a3fdfaa0ea2141b1c4178c8d97f9be1a61282
158
py
Python
tests/skl_datasets_reg/freidman1/skl_dataset_freidman1_DecisionTreeRegressor_0_code_gen.py
antoinecarme/sklearn_model_explanation
feeeb75576931f4a05a786d936babc0a664eef46
[ "BSD-3-Clause" ]
13
2017-12-22T09:12:51.000Z
2021-07-26T06:31:54.000Z
tests/skl_datasets_reg/freidman1/skl_dataset_freidman1_DecisionTreeRegressor_0_code_gen.py
antoinecarme/sklearn_model_explanation
feeeb75576931f4a05a786d936babc0a664eef46
[ "BSD-3-Clause" ]
11
2017-09-19T20:00:35.000Z
2018-02-05T07:59:06.000Z
tests/skl_datasets_reg/freidman1/skl_dataset_freidman1_DecisionTreeRegressor_0_code_gen.py
antoinecarme/sklearn_model_explanation
feeeb75576931f4a05a786d936babc0a664eef46
[ "BSD-3-Clause" ]
4
2017-12-11T12:33:32.000Z
2020-02-09T15:08:56.000Z
from sklearn_explain.tests.skl_datasets_reg import skl_datasets_test as skltest skltest.test_reg_dataset_and_model("freidman1" , "DecisionTreeRegressor_0")
31.6
79
0.867089
796a3fe0468bb3e4bac2617701e4b7ff0d6addd8
7,524
py
Python
sdk/python/pulumi_aws/neptune/subnet_group.py
sibuthomasmathew/pulumi-aws
6351f2182eb6f693d4e09e4136c385adfa0ab674
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
sdk/python/pulumi_aws/neptune/subnet_group.py
sibuthomasmathew/pulumi-aws
6351f2182eb6f693d4e09e4136c385adfa0ab674
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
sdk/python/pulumi_aws/neptune/subnet_group.py
sibuthomasmathew/pulumi-aws
6351f2182eb6f693d4e09e4136c385adfa0ab674
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** 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 _utilitie...
40.891304
137
0.623339
796a40cfcf39b1983091f7d6e52bcde513e64948
221
py
Python
fairtally/__init__.py
cffbots/fairtally
ef2991ca647856d39e8c65e39f8d8229e46013e0
[ "Apache-2.0" ]
5
2021-03-09T09:10:51.000Z
2021-11-16T11:49:22.000Z
fairtally/__init__.py
cffbots/fairtally
ef2991ca647856d39e8c65e39f8d8229e46013e0
[ "Apache-2.0" ]
69
2021-02-24T13:03:30.000Z
2022-02-02T16:14:43.000Z
fairtally/__init__.py
cffbots/fairtally
ef2991ca647856d39e8c65e39f8d8229e46013e0
[ "Apache-2.0" ]
2
2022-02-02T13:17:49.000Z
2022-02-02T14:09:29.000Z
import logging from .__version__ import __version__ logging.getLogger(__name__).addHandler(logging.NullHandler()) __author__ = "FAIR Software" __email__ = "j.spaaks@esciencecenter.nl" __all__ = [ "__version__" ]
15.785714
61
0.764706
796a416c94b813d311ef7911a5f8d0411cc02f8a
8,464
py
Python
qcfractal/services/torsiondrive_service.py
cgbriggs99/QCFractal
1cf2631056f74321f758307de83bd2eb48689046
[ "BSD-3-Clause" ]
2
2020-03-12T14:29:58.000Z
2020-03-12T14:30:05.000Z
qcfractal/services/torsiondrive_service.py
doaa-altarawy/QCFractal
5f00dd06bb34ca912c4055f0cbac60863ea89c7f
[ "BSD-3-Clause" ]
null
null
null
qcfractal/services/torsiondrive_service.py
doaa-altarawy/QCFractal
5f00dd06bb34ca912c4055f0cbac60863ea89c7f
[ "BSD-3-Clause" ]
null
null
null
""" Wraps geometric procedures """ import io import copy import json import contextlib from typing import Any, Dict, List import numpy as np from ..extras import find_module from ..interface.models import TorsionDriveRecord from .service_util import BaseService, TaskManager __all__ = ["TorsionDriveService"] __td_a...
33.322835
113
0.609523
796a4179d4e30c6716be3918ed4e508dc932cfdb
7,536
py
Python
f5/bigip/tm/gtm/test/functional/test_rule.py
nghia-tran/f5-common-python
acb23a6e5830a119b460c19a578654113419f5c3
[ "Apache-2.0" ]
272
2016-02-23T06:05:44.000Z
2022-02-20T02:09:32.000Z
f5/bigip/tm/gtm/test/functional/test_rule.py
nghia-tran/f5-common-python
acb23a6e5830a119b460c19a578654113419f5c3
[ "Apache-2.0" ]
1,103
2016-02-11T17:48:03.000Z
2022-02-15T17:13:37.000Z
f5/bigip/tm/gtm/test/functional/test_rule.py
nghia-tran/f5-common-python
acb23a6e5830a119b460c19a578654113419f5c3
[ "Apache-2.0" ]
167
2016-02-11T17:48:21.000Z
2022-01-17T20:13:05.000Z
# Copyright 2014-2017 F5 Networks 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 ...
36.230769
78
0.662553
796a41e8b0e78bd4015f1f62a030fbdee30436a0
1,297
py
Python
django/javanlp/models.py
arunchaganty/presidential-debates
be56ddcb78ad94c1ea25120572acc1f79e0c32f3
[ "MIT" ]
null
null
null
django/javanlp/models.py
arunchaganty/presidential-debates
be56ddcb78ad94c1ea25120572acc1f79e0c32f3
[ "MIT" ]
3
2015-12-03T00:30:26.000Z
2016-01-05T22:07:20.000Z
django/javanlp/models.py
arunchaganty/presidential-debates
be56ddcb78ad94c1ea25120572acc1f79e0c32f3
[ "MIT" ]
null
null
null
from django.db import models from django.contrib.postgres.fields import ArrayField class Sentence(models.Model): """ Represents the consitutents of each sentence, with the basic annotations. """ doc_id = models.BigIntegerField() # More general than a foreign key? sentence_index = models.Integer...
39.30303
98
0.713955
796a430c7fc534ad339636e09f8d4b7eb074bbac
641
py
Python
demo/LogSig_demo.py
f1amingo/logparser
65f077a78a974a50e0fff792257fb6fea0a86821
[ "MIT" ]
null
null
null
demo/LogSig_demo.py
f1amingo/logparser
65f077a78a974a50e0fff792257fb6fea0a86821
[ "MIT" ]
null
null
null
demo/LogSig_demo.py
f1amingo/logparser
65f077a78a974a50e0fff792257fb6fea0a86821
[ "MIT" ]
null
null
null
#!/usr/bin/env python import sys sys.path.append('../') from logparser import LogSig input_dir = '../logs/HDFS/' # The input directory of log file output_dir = 'LogSig_result/' # The output directory of parsing results log_file = 'HDFS_2k.log' # The input log file name log_format = '<Date> <Time>...
40.0625
86
0.700468
796a431691fc3eac1984a6888a39362827b5be6c
2,221
py
Python
benchmark/startPyquil1158.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
benchmark/startPyquil1158.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
benchmark/startPyquil1158.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
# qubit number=5 # total number=52 import pyquil from pyquil.api import local_forest_runtime, QVMConnection from pyquil import Program, get_qc from pyquil.gates import * import numpy as np conn = QVMConnection() def make_circuit()-> Program: prog = Program() # circuit begin prog += H(0) # number=3 pr...
24.955056
64
0.541648
796a43a0dd2fd444e0f30f99572155da39dd43f6
6,183
py
Python
zencad/libs/kinematic.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
5
2018-04-11T14:11:40.000Z
2018-09-12T19:03:36.000Z
zencad/libs/kinematic.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
zencad/libs/kinematic.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
import zencad.assemble import zencad.libs.screw import numpy import time from abc import ABC, abstractmethod from zencad.assemble import kinematic_unit class kinematic_chain: """Объект-алгоритм управления участком кинематической чепи от точки выхода, до точки входа. Порядок следования обратный, потому ...
29.303318
87
0.535824
796a44e888be7f5d00e0326def2a32a1d9323ea5
2,033
py
Python
qnarre/doc/ipython.py
quantapix/qnarre.com
f51d5945c20ef8182c4aa11f1b407d064c190c70
[ "MIT" ]
null
null
null
qnarre/doc/ipython.py
quantapix/qnarre.com
f51d5945c20ef8182c4aa11f1b407d064c190c70
[ "MIT" ]
null
null
null
qnarre/doc/ipython.py
quantapix/qnarre.com
f51d5945c20ef8182c4aa11f1b407d064c190c70
[ "MIT" ]
null
null
null
# Copyright 2019 Quantapix 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 applicable l...
32.790323
79
0.662568
796a46b70fc50808ed17a667b326fbfa9da534cf
208
py
Python
states/wisconsin/main.py
kynelee/elections-officials
06e9bbf7b87693b49d2b90812adf745b99dddb9d
[ "Apache-2.0" ]
null
null
null
states/wisconsin/main.py
kynelee/elections-officials
06e9bbf7b87693b49d2b90812adf745b99dddb9d
[ "Apache-2.0" ]
null
null
null
states/wisconsin/main.py
kynelee/elections-officials
06e9bbf7b87693b49d2b90812adf745b99dddb9d
[ "Apache-2.0" ]
null
null
null
import parse_pdf import augment import aggregate from common import arg_parser if __name__ == "__main__": args = arg_parser() if args.crawl: parse_pdf.main() augment.main() aggregate.main()
13.866667
29
0.716346
796a474fdef5d996b3a712c8f8a0d700fe96e1a2
9,032
py
Python
src/foremast/autoscaling_policy/create_policy.py
JessicaAlan/foremast
86c2141b88707b5826d6225d64fb31a7bf3867fc
[ "Apache-2.0" ]
null
null
null
src/foremast/autoscaling_policy/create_policy.py
JessicaAlan/foremast
86c2141b88707b5826d6225d64fb31a7bf3867fc
[ "Apache-2.0" ]
null
null
null
src/foremast/autoscaling_policy/create_policy.py
JessicaAlan/foremast
86c2141b88707b5826d6225d64fb31a7bf3867fc
[ "Apache-2.0" ]
null
null
null
# Foremast - Pipeline Tooling # # Copyright 2018 Gogo, 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 # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required...
47.287958
120
0.650022
796a4928f3d004c69e006bdc1b697c41bb74d1cf
118,117
py
Python
lib/tests/test_wallet_vertical.py
blondfrogs/electrum
1ffee267c7f103526f2e0ebeb992bd8b3226365d
[ "MIT" ]
null
null
null
lib/tests/test_wallet_vertical.py
blondfrogs/electrum
1ffee267c7f103526f2e0ebeb992bd8b3226365d
[ "MIT" ]
null
null
null
lib/tests/test_wallet_vertical.py
blondfrogs/electrum
1ffee267c7f103526f2e0ebeb992bd8b3226365d
[ "MIT" ]
3
2018-06-22T20:24:10.000Z
2018-07-27T15:36:07.000Z
import unittest from unittest import mock import shutil import tempfile from typing import Sequence import lib from lib import storage, bitcoin, keystore, constants from lib.transaction import Transaction from lib.simple_config import SimpleConfig from lib.wallet import TX_HEIGHT_UNCONFIRMED, TX_HEIGHT_UNCONF_PARENT f...
94.72093
6,844
0.846144
796a4a26345341b6c1ecc33d4498984c180e80cc
1,484
py
Python
gpvdm_gui/gui/json_spectra_db_item.py
roderickmackenzie/gpvdm
914fd2ee93e7202339853acaec1d61d59b789987
[ "BSD-3-Clause" ]
12
2016-09-13T08:58:13.000Z
2022-01-17T07:04:52.000Z
gpvdm_gui/gui/json_spectra_db_item.py
roderickmackenzie/gpvdm
914fd2ee93e7202339853acaec1d61d59b789987
[ "BSD-3-Clause" ]
3
2017-11-11T12:33:02.000Z
2019-03-08T00:48:08.000Z
gpvdm_gui/gui/json_spectra_db_item.py
roderickmackenzie/gpvdm
914fd2ee93e7202339853acaec1d61d59b789987
[ "BSD-3-Clause" ]
6
2019-01-03T06:17:12.000Z
2022-01-01T15:59:00.000Z
# # General-purpose Photovoltaic Device Model - a drift diffusion base/Shockley-Read-Hall # model for 1st, 2nd and 3rd generation solar cells. # Copyright (C) 2008-2022 Roderick C. I. MacKenzie r.c.i.mackenzie at googlemail.com # # https://www.gpvdm.com # # This program is free software; you can redist...
35.333333
89
0.743261
796a4a443c4f5aec9217df1289ad9a86a86a2507
236,133
py
Python
cpplint.py
vladimirgamalian/banknote
3a5e7a6430b8e2c1c819c1b198b5efb6009827ea
[ "MIT" ]
78
2016-09-24T16:56:00.000Z
2022-03-05T01:05:40.000Z
cpplint.py
vladimirgamalian/banknote
3a5e7a6430b8e2c1c819c1b198b5efb6009827ea
[ "MIT" ]
null
null
null
cpplint.py
vladimirgamalian/banknote
3a5e7a6430b8e2c1c819c1b198b5efb6009827ea
[ "MIT" ]
9
2016-09-30T07:45:35.000Z
2022-03-18T02:43:53.000Z
#!/usr/bin/env python # # Copyright (c) 2009 Google Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list...
38.571219
97
0.652509
796a4b0e86d6cf2eea3baa066ce999a26983349b
856
py
Python
base_site/urls.py
KVooys/djangoblog
663df166cc66d519a040a4400a5e32c7a1d58fa7
[ "MIT" ]
null
null
null
base_site/urls.py
KVooys/djangoblog
663df166cc66d519a040a4400a5e32c7a1d58fa7
[ "MIT" ]
1
2021-06-04T21:51:53.000Z
2021-06-04T21:51:53.000Z
base_site/urls.py
KVooys/djangoblog
663df166cc66d519a040a4400a5e32c7a1d58fa7
[ "MIT" ]
null
null
null
"""base_site URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.2/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-bas...
35.666667
77
0.699766
796a4b8949c709c833e41fafe4447df2f4f650c2
3,998
py
Python
apps/processing/o2/migrations/0009_delete_agg_create_unique_index.py
gis4dis/poster_new
cee983bfcfc90f581b18712d558bc9d8a83a400a
[ "BSD-3-Clause" ]
4
2017-10-17T10:52:27.000Z
2020-08-30T10:13:46.000Z
apps/processing/o2/migrations/0009_delete_agg_create_unique_index.py
gis4dis/poster_new
cee983bfcfc90f581b18712d558bc9d8a83a400a
[ "BSD-3-Clause" ]
138
2017-10-13T09:09:02.000Z
2020-06-05T18:55:33.000Z
apps/processing/o2/migrations/0009_delete_agg_create_unique_index.py
gis4dis/poster_new
cee983bfcfc90f581b18712d558bc9d8a83a400a
[ "BSD-3-Clause" ]
2
2018-01-21T19:44:51.000Z
2018-02-15T11:27:39.000Z
# Generated by Django 2.1.5 on 2019-03-25 14:08 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('o2', '0008_add_timeslots_delete_unique'), ] operations = [ migrations.RunSQL(""" DELETE FROM o2_mob...
33.316667
84
0.566783
796a4d82549442d5b2b7b39804aedf8b763e9d87
4,781
py
Python
script/release/release/images.py
jpic/compose
79557e3d3ab67c3697641d9af91866d7e400cfeb
[ "Apache-2.0" ]
null
null
null
script/release/release/images.py
jpic/compose
79557e3d3ab67c3697641d9af91866d7e400cfeb
[ "Apache-2.0" ]
null
null
null
script/release/release/images.py
jpic/compose
79557e3d3ab67c3697641d9af91866d7e400cfeb
[ "Apache-2.0" ]
null
null
null
from __future__ import absolute_import from __future__ import print_function from __future__ import unicode_literals import base64 import json import os import docker from enum import Enum from .const import NAME from .const import REPO_ROOT from .utils import ScriptError class Platform(Enum): ALPINE = 'alpine...
36.219697
93
0.609496
796a4d93e001bd4c9250781a71885ec86c70f7da
2,013
py
Python
qiskit/quantum_info/__init__.py
tareqdandachi/qiskit-terra
5221fe330adba5529bfa22dc25262ac8e6291aaf
[ "Apache-2.0" ]
3
2019-05-19T17:39:38.000Z
2020-01-28T19:59:18.000Z
qiskit/quantum_info/__init__.py
tareqdandachi/qiskit-terra
5221fe330adba5529bfa22dc25262ac8e6291aaf
[ "Apache-2.0" ]
4
2019-05-13T15:28:46.000Z
2019-12-19T20:47:02.000Z
qiskit/quantum_info/__init__.py
tareqdandachi/qiskit-terra
5221fe330adba5529bfa22dc25262ac8e6291aaf
[ "Apache-2.0" ]
1
2021-07-07T16:55:41.000Z
2021-07-07T16:55:41.000Z
# -*- coding: utf-8 -*- # This code is part of Qiskit. # # (C) Copyright IBM 2017. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any modif...
19.543689
77
0.676602
796a4fc0d50506373dceeba1e6921d5d3df5d531
856
py
Python
send_message.py
mga-odoo/intern-contacts
16f52b6e89196b79beb94e1dd0e515302416665a
[ "MIT" ]
2
2019-05-04T15:01:04.000Z
2019-05-04T15:01:07.000Z
send_message.py
mga-odoo/intern-contacts
16f52b6e89196b79beb94e1dd0e515302416665a
[ "MIT" ]
null
null
null
send_message.py
mga-odoo/intern-contacts
16f52b6e89196b79beb94e1dd0e515302416665a
[ "MIT" ]
1
2019-05-04T15:01:18.000Z
2019-05-04T15:01:18.000Z
import firebase_admin from firebase_admin import auth from firebase_admin import messaging from firebase_admin import credentials # This registration token comes from the client FCM SDKs. registration_token = 'ccf1-MwxPDA:APA91bFCmxFzOVz4C5BcoJS_WObG4OuUwUwAlBkSSfmGRtC7PBFf4PAbF5tabqe0kQzy8KSc201vJcFCZQpgQu_Am6-cl1Fvd...
32.923077
175
0.797897
796a4ffaceb7b7d163d4dec2b75c049d955e2275
894
py
Python
python/raft/raft/test/test_raft.py
kaatish/raft
f487da7f2585e60f0a11aef43ce17c990cc6145a
[ "Apache-2.0" ]
null
null
null
python/raft/raft/test/test_raft.py
kaatish/raft
f487da7f2585e60f0a11aef43ce17c990cc6145a
[ "Apache-2.0" ]
null
null
null
python/raft/raft/test/test_raft.py
kaatish/raft
f487da7f2585e60f0a11aef43ce17c990cc6145a
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2020-2022, NVIDIA 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 agre...
27.9375
74
0.743848
796a5195b31b6c01e3a500d30f31211899b17ea0
4,501
py
Python
code.py
johanloones/regularization-code-along
d8db7d2c084a242b3e62935181d5f4b44935ea36
[ "MIT" ]
null
null
null
code.py
johanloones/regularization-code-along
d8db7d2c084a242b3e62935181d5f4b44935ea36
[ "MIT" ]
null
null
null
code.py
johanloones/regularization-code-along
d8db7d2c084a242b3e62935181d5f4b44935ea36
[ "MIT" ]
null
null
null
# -------------- ## Load the data import pandas as pd sales_data=pd.read_csv(path) sales_data.head() ## Split the data and preprocess #Split it into train and test sets using the source column. train=sales_data[sales_data.source=='train'].copy() test=sales_data[sales_data.source=='test'].copy() train.drop(columns='sou...
31.921986
128
0.8016
796a51d8ef8174dd172936601e9a7f414352b30b
6,230
py
Python
apps/dgiot_evidence/priv/python/drawxnqx.py
dgiot/dgiot
c9f2f78af71692ba532e4806621b611db2afe0c9
[ "Apache-2.0" ]
2,783
2021-05-19T04:33:46.000Z
2022-03-30T11:18:28.000Z
apps/dgiot_evidence/priv/python/drawxnqx.py
dgiot/dgiot
c9f2f78af71692ba532e4806621b611db2afe0c9
[ "Apache-2.0" ]
353
2021-07-02T06:07:05.000Z
2022-03-31T07:25:54.000Z
apps/dgiot_evidence/priv/python/drawxnqx.py
dgiot/dgiot
c9f2f78af71692ba532e4806621b611db2afe0c9
[ "Apache-2.0" ]
704
2021-05-19T04:33:49.000Z
2022-03-31T21:29:43.000Z
import matplotlib.pyplot as plt from pylab import mpl import math import numpy as np from mpl_toolkits.axisartist.parasite_axes import HostAxes, ParasiteAxes import time import sys import base64 import json """完成拟合曲线参数计算前相应变量的计算""" def polynomial_fitting(data_x, data_y): size = len(data_x) i = 0 sum_x = ...
28.577982
105
0.600803
796a5268234c93eb2ccd97092cad465ecc517306
1,917
py
Python
dciclient/v1/shell_commands/product.py
redhat-cip/python-dciclient
0169e3872a64e614c2655626b04361b165f8513b
[ "Apache-2.0" ]
6
2015-12-18T14:03:02.000Z
2017-08-03T14:09:05.000Z
dciclient/v1/shell_commands/product.py
redhat-cip/python-dciclient
0169e3872a64e614c2655626b04361b165f8513b
[ "Apache-2.0" ]
13
2015-12-23T22:27:23.000Z
2018-05-14T20:51:42.000Z
dciclient/v1/shell_commands/product.py
redhat-cip/python-dciclient
0169e3872a64e614c2655626b04361b165f8513b
[ "Apache-2.0" ]
2
2016-01-26T23:30:24.000Z
2020-06-18T16:33:19.000Z
# -*- encoding: utf-8 -*- # # Copyright 2017 Red Hat, 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 ...
31.42623
86
0.679708
796a5342f44ffc1188ec5da97920b232a9fcbbd0
6,133
py
Python
artifact/cadp/scripts/ProcessLabels.py
tyler-utah/AlloyForwardProgress
d9c779129f5ff9f678b31d9b7ccb29c184ddb097
[ "BSD-2-Clause" ]
null
null
null
artifact/cadp/scripts/ProcessLabels.py
tyler-utah/AlloyForwardProgress
d9c779129f5ff9f678b31d9b7ccb29c184ddb097
[ "BSD-2-Clause" ]
null
null
null
artifact/cadp/scripts/ProcessLabels.py
tyler-utah/AlloyForwardProgress
d9c779129f5ff9f678b31d9b7ccb29c184ddb097
[ "BSD-2-Clause" ]
null
null
null
import sys import os.path import time from enum import Enum class Sched(Enum): SANITY_LOOP = 0 SANITY_TERMINATION = 1 OBE = 2 S_OBE = 3 HSA = 4 S_HSA = 5 HSA_OBE = 6 S_HSA_OBE = 7 # HSA PRIORITY CURRENTLY NOT PRINTED HSA_P = 8 S_HSA_P = 9 LOBE = 10 S_LOBE = 11 W_...
37.625767
128
0.586825
796a53a85892c9d07e1041810c9cb9c21dcc72db
6,753
py
Python
jina/clients/base.py
DimitrisPr/jina
8d5e0c9bda20e3561e842600e09d14ca73dbdf4f
[ "Apache-2.0" ]
2
2021-01-22T07:34:35.000Z
2021-01-23T04:36:41.000Z
jina/clients/base.py
DimitrisPr/jina
8d5e0c9bda20e3561e842600e09d14ca73dbdf4f
[ "Apache-2.0" ]
null
null
null
jina/clients/base.py
DimitrisPr/jina
8d5e0c9bda20e3561e842600e09d14ca73dbdf4f
[ "Apache-2.0" ]
null
null
null
__copyright__ = "Copyright (c) 2020 Jina AI Limited. All rights reserved." __license__ = "Apache-2.0" import argparse import os from typing import Callable, Union, Optional, Iterator, List import grpc from . import request from .helper import callback_exec from .request import GeneratorSourceType from ..enums import...
39.723529
113
0.579446
796a543b07b811af54751b8fc8bfdf0f8e917e00
15,207
py
Python
privacy/tensorflow_privacy/privacy/analysis/tree_aggregation_accountant.py
tkgsn/P3GM
443550b7781b7ab3c920893923056a8faef44994
[ "MIT" ]
1,605
2018-12-21T18:47:34.000Z
2022-03-31T07:16:12.000Z
privacy/tensorflow_privacy/privacy/analysis/tree_aggregation_accountant.py
tkgsn/P3GM
443550b7781b7ab3c920893923056a8faef44994
[ "MIT" ]
190
2018-12-26T06:13:27.000Z
2022-03-27T17:14:00.000Z
privacy/tensorflow_privacy/privacy/analysis/tree_aggregation_accountant.py
tkgsn/P3GM
443550b7781b7ab3c920893923056a8faef44994
[ "MIT" ]
396
2018-12-21T19:19:49.000Z
2022-03-27T08:26:14.000Z
# Copyright 2018 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...
41.435967
80
0.71763
796a56321e6499e3f1db38297aeb29c1c5226c16
840
py
Python
test_add_digits.py
brigitteunger/katas
3f9af88fe5d98753360457084741f573c863dc25
[ "MIT" ]
null
null
null
test_add_digits.py
brigitteunger/katas
3f9af88fe5d98753360457084741f573c863dc25
[ "MIT" ]
null
null
null
test_add_digits.py
brigitteunger/katas
3f9af88fe5d98753360457084741f573c863dc25
[ "MIT" ]
null
null
null
import unittest class Solution: def addDigits(self, num: int) -> int: str_num = str(num) nums = list(str_num) result = 0 for num in nums: result += int(num) if result >= 10: result -= 9 return result class TestAddDigitst(unittest.Te...
19.090909
43
0.572619
796a5731cb74b27fb7f1b66f497d4835571490d8
198
py
Python
vizdoomgym/envs/vizdoomdefendcenter.py
astronautas/vizdoom_gym
142e7e61e8069e06153492a76c5881bdd04e36ed
[ "MIT" ]
null
null
null
vizdoomgym/envs/vizdoomdefendcenter.py
astronautas/vizdoom_gym
142e7e61e8069e06153492a76c5881bdd04e36ed
[ "MIT" ]
null
null
null
vizdoomgym/envs/vizdoomdefendcenter.py
astronautas/vizdoom_gym
142e7e61e8069e06153492a76c5881bdd04e36ed
[ "MIT" ]
null
null
null
from vizdoomgym.envs.vizdoomenv import VizdoomEnv class VizdoomDefendCenter(VizdoomEnv): def __init__(self, agent_id): super(VizdoomDefendCenter, self).__init__(2, agent_id=agent_id)
24.75
71
0.777778
796a584175162410dc3cbde3c277b6a14c92104b
5,378
py
Python
1D_Model/src/dataset.py
yamsam/G2Net-GoGoGo
629199ba044adf8a0ffec3e6fd33146bcad4299e
[ "MIT" ]
2
2021-09-30T08:23:24.000Z
2021-10-01T06:45:55.000Z
1D_Model/src/dataset.py
VincentWang25/G2Net_GoGoGo
064037982d80656cb35442ffe1cd59390aeb5dc2
[ "MIT" ]
null
null
null
1D_Model/src/dataset.py
VincentWang25/G2Net_GoGoGo
064037982d80656cb35442ffe1cd59390aeb5dc2
[ "MIT" ]
2
2021-09-30T08:20:35.000Z
2021-10-02T05:48:28.000Z
import pickle5 as pickle from torch.utils.data import Dataset import torch import random import numpy as np import pandas as pd from sklearn.model_selection import StratifiedKFold from .util import id_2_path_wave class DataRetriever(Dataset): def __init__(self, paths, targets, synthetic=None, Config=None): ...
39.837037
108
0.650614
796a592fb2c6f19f73d2d72e07f13c29058caa7d
13,850
py
Python
metaspace/engine/sm/engine/annotation/metrics.py
METASPACE2020/METASPACE
e1acd9a409f84a78eed7ca9713258c09b0e137ca
[ "Apache-2.0" ]
null
null
null
metaspace/engine/sm/engine/annotation/metrics.py
METASPACE2020/METASPACE
e1acd9a409f84a78eed7ca9713258c09b0e137ca
[ "Apache-2.0" ]
null
null
null
metaspace/engine/sm/engine/annotation/metrics.py
METASPACE2020/METASPACE
e1acd9a409f84a78eed7ca9713258c09b0e137ca
[ "Apache-2.0" ]
null
null
null
import numpy as np from cpyImagingMSpec import measure_of_chaos from pyImagingMSpec.image_measures import isotope_pattern_match, isotope_image_correlation from scipy.ndimage import maximum_filter, minimum_filter, grey_closing def spectral_metric(iso_imgs_flat, formula_ints): # Ignore div-by-zero / NaN errors - th...
46.32107
118
0.695162
796a5a8705deea077c83cc441430c46bbcf8a3ec
1,892
py
Python
brus/oauth.py
webkom/brus
a1ffe0c03f78d6a8b301e4ae7554e625ed2e46a9
[ "MIT" ]
null
null
null
brus/oauth.py
webkom/brus
a1ffe0c03f78d6a8b301e4ae7554e625ed2e46a9
[ "MIT" ]
38
2016-04-30T16:07:09.000Z
2022-03-18T16:56:59.000Z
brus/oauth.py
webkom/brus
a1ffe0c03f78d6a8b301e4ae7554e625ed2e46a9
[ "MIT" ]
null
null
null
from six.moves.urllib.parse import urljoin from social_core.backends.oauth import BaseOAuth2 from social_core.exceptions import AuthFailed class LegoOAuth2(BaseOAuth2): name = "lego" ACCESS_TOKEN_METHOD = "POST" SCOPE_SEPARATOR = "," EXTRA_DATA = [("id", "id"), ("expires_in", "expires_in")] def ...
33.192982
88
0.629493