hexsha
stringlengths
40
40
size
int64
6
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
247
max_issues_repo_name
stringlengths
4
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
247
max_forks_repo_name
stringlengths
4
130
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.53
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
6
1.04M
filtered:remove_non_ascii
int64
0
538k
filtered:remove_decorators
int64
0
917k
filtered:remove_async
int64
0
722k
filtered:remove_classes
int64
-45
1M
filtered:remove_generators
int64
0
814k
filtered:remove_function_no_docstring
int64
-102
850k
filtered:remove_class_no_docstring
int64
-3
5.46k
filtered:remove_unused_imports
int64
-1,350
52.4k
filtered:remove_delete_markers
int64
0
59.6k
b28910cf47ea8e3a98d8eb43d5925251f87a8b1c
692
py
Python
onlinecourse/migrations/0007_auto_20210420_1459.py
enricosiagri/final-cloud-app-with-database
d4dc4646c1e238bcba71fa240cf808b360e959c0
[ "Apache-2.0" ]
null
null
null
onlinecourse/migrations/0007_auto_20210420_1459.py
enricosiagri/final-cloud-app-with-database
d4dc4646c1e238bcba71fa240cf808b360e959c0
[ "Apache-2.0" ]
null
null
null
onlinecourse/migrations/0007_auto_20210420_1459.py
enricosiagri/final-cloud-app-with-database
d4dc4646c1e238bcba71fa240cf808b360e959c0
[ "Apache-2.0" ]
null
null
null
# Generated by Django 3.1.3 on 2021-04-20 14:59
23.862069
52
0.562139
# Generated by Django 3.1.3 on 2021-04-20 14:59 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('onlinecourse', '0006_auto_20210416_1459'), ] operations = [ migrations.RenameField( model_name='submission', old_nam...
0
0
0
578
0
0
0
19
46
a65f39ef854ba9a4bb94c8cf08a568806963b135
7,416
py
Python
finitediff/unit_tests.py
jolyonb/finitediff
fb6d05490fcf8a7a7603e68aec165b9fb931ba3a
[ "MIT" ]
null
null
null
finitediff/unit_tests.py
jolyonb/finitediff
fb6d05490fcf8a7a7603e68aec165b9fb931ba3a
[ "MIT" ]
null
null
null
finitediff/unit_tests.py
jolyonb/finitediff
fb6d05490fcf8a7a7603e68aec165b9fb931ba3a
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Unit tests for finite_diff library """ import unittest if __name__ == '__main__': unittest.main()
37.836735
91
0.618797
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Unit tests for finite_diff library """ import unittest import random from math import pi import numpy as np import finitediff class TestFiniteDiff(unittest.TestCase): """Unit test class for the finitediff library""" order = 4 # Order of the derivatives ...
0
0
0
7,167
0
0
0
-17
111
cd31afc24dd0c8fd36f1b2e599cb704db2845b1c
199
py
Python
problem0143.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
problem0143.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
problem0143.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
########################### # # #143 Investigating the Torricelli point of a triangle - Project Euler # https://projecteuler.net/problem=143 # # Code by Kevin Marciniak # ###########################
22.111111
71
0.537688
########################### # # #143 Investigating the Torricelli point of a triangle - Project Euler # https://projecteuler.net/problem=143 # # Code by Kevin Marciniak # ###########################
0
0
0
0
0
0
0
0
0
d0299594988dabb3885370f57f0c63136d56db5c
94
py
Python
connected_accounts/__init__.py
surajsonee/socialapp
e741d2467e2bbde5b7bdbe90702e4123ce31bddb
[ "BSD-3-Clause" ]
null
null
null
connected_accounts/__init__.py
surajsonee/socialapp
e741d2467e2bbde5b7bdbe90702e4123ce31bddb
[ "BSD-3-Clause" ]
null
null
null
connected_accounts/__init__.py
surajsonee/socialapp
e741d2467e2bbde5b7bdbe90702e4123ce31bddb
[ "BSD-3-Clause" ]
null
null
null
__version__ = '0.1.4' default_app_config = 'connected_accounts.apps.ConnectedAccountsConfig'
23.5
70
0.819149
__version__ = '0.1.4' default_app_config = 'connected_accounts.apps.ConnectedAccountsConfig'
0
0
0
0
0
0
0
0
0
80397360440b25ef17a5effd5d326a5b6eb37ed9
4,603
py
Python
optable/OptModel.py
dgroner/optable
4ee2947901c179925cdb6a6ceb172c54bf9b1844
[ "MIT" ]
null
null
null
optable/OptModel.py
dgroner/optable
4ee2947901c179925cdb6a6ceb172c54bf9b1844
[ "MIT" ]
null
null
null
optable/OptModel.py
dgroner/optable
4ee2947901c179925cdb6a6ceb172c54bf9b1844
[ "MIT" ]
null
null
null
# Specify and solve an LP using a Pandas DataFrame if __name__ != "__main__": from . import LpModel from . import Result else: if __name__ == "__main__": df = OptModel.read_csv("lpmodel.txt") #print(df.fillna("")) lpmodel = OptModel(df) print(lpmodel) result = lpmodel.solve() #print(result.stat...
27.562874
93
0.575277
# Specify and solve an LP using a Pandas DataFrame import pandas as pd if __name__ != "__main__": from . import LpModel from . import Result else: from LpModel import LpModel from Result import Result class OptModel: def __init__(self, df): #print("in OptModel()") self.df = df self.is...
0
332
0
3,452
0
0
0
8
96
2ad242ae4823f4b754e9228620d08ce52c874c74
2,320
py
Python
back-end/www/util/export_answers.py
Disfactory/SpotDiff
18a4bf88d9bd82cc58ac96658ad1f7d067f10a5c
[ "MIT" ]
2
2021-11-10T13:30:01.000Z
2021-11-17T13:15:19.000Z
back-end/www/util/export_answers.py
Disfactory/SpotDiff
18a4bf88d9bd82cc58ac96658ad1f7d067f10a5c
[ "MIT" ]
26
2021-10-06T12:01:33.000Z
2022-03-16T11:26:17.000Z
back-end/www/util/export_answers.py
Disfactory/SpotDiff
18a4bf88d9bd82cc58ac96658ad1f7d067f10a5c
[ "MIT" ]
1
2022-01-16T10:53:42.000Z
2022-01-16T10:53:42.000Z
""" The script exports the answer table to a CSV file. Config ------ CFG_NAME : The config name can be Develpment, Staging, Testing Output ------ The total answer numbers after export, and the CSV file. (aswer_YYYY_MM_DD_HH_mm_ss.csv) """ CFG_NAME = "config.config.DevelopmentConfig" import sys import os sys.path.a...
38.032787
153
0.747845
""" The script exports the answer table to a CSV file. Config ------ CFG_NAME : The config name can be Develpment, Staging, Testing Output ------ The total answer numbers after export, and the CSV file. (aswer_YYYY_MM_DD_HH_mm_ss.csv) """ CFG_NAME = "config.config.DevelopmentConfig" import sys import os sys.path.a...
0
0
0
0
0
0
0
43
44
b04105b29ed75ba096bb6529389fda511f9ef726
986
py
Python
data/anthropocentric/Geyer2017_plastic_production/viz/generate.py
ilopezgp/human_impacts
b2758245edac0946080a647f1dbfd1098c0f0b27
[ "MIT" ]
4
2020-08-25T00:52:01.000Z
2020-11-16T16:57:46.000Z
data/anthropocentric/Geyer2017_plastic_production/viz/generate.py
ilopezgp/human_impacts
b2758245edac0946080a647f1dbfd1098c0f0b27
[ "MIT" ]
5
2020-10-30T21:22:55.000Z
2021-12-30T02:07:02.000Z
data/anthropocentric/Geyer2017_plastic_production/viz/generate.py
ilopezgp/human_impacts
b2758245edac0946080a647f1dbfd1098c0f0b27
[ "MIT" ]
2
2020-08-28T10:11:28.000Z
2020-11-11T07:58:46.000Z
#%% import pandas as pd import altair as alt # Load the produciton data. data = pd.read_csv('../processed/Geyer2017_plastic_production.csv') data['year'] = pd.to_datetime(data['year'], format='%Y') chart = alt.Chart(data).encode( x=alt.X(field='year', type='temporal', timeUnit='year', title='year'), ...
31.806452
95
0.600406
#%% import numpy as np import pandas as pd import altair as alt import anthro.io # Load the produciton data. data = pd.read_csv('../processed/Geyer2017_plastic_production.csv') data['year'] = pd.to_datetime(data['year'], format='%Y') chart = alt.Chart(data).encode( x=alt.X(field='year', type='temporal...
0
0
0
0
0
0
0
-8
45
576e4546e2ca69d03d664c617ab23bbd9d8bb19c
6,967
py
Python
scripts/trio_ircproxy/ial.py
ashburry-chat-irc/trio_ircproxy
10d651d916505e3b3aeb9019e18466fffeaec667
[ "BSD-3-Clause" ]
null
null
null
scripts/trio_ircproxy/ial.py
ashburry-chat-irc/trio_ircproxy
10d651d916505e3b3aeb9019e18466fffeaec667
[ "BSD-3-Clause" ]
44
2021-08-28T00:48:31.000Z
2022-01-14T11:36:26.000Z
scripts/trio_ircproxy/ial.py
ashburry-chat-irc/trio_ircproxy
10d651d916505e3b3aeb9019e18466fffeaec667
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*-
36.098446
105
0.592077
#!/usr/bin/python # -*- coding: utf-8 -*- from fnmatch import fnmatch from typing import Union, List, Dict, Set from threading import Timer import circular class IALData: from circular import XsSocket myial: Dict[XsSocket, Dict[str, str]] = dict() myial_chan: Dict[XsSocket, Dict[str, Set[str]]] = dict() ...
0
6,215
0
573
0
0
0
26
111
a92523bd30212da5bb8ef2fd59130659e4470e80
10,353
py
Python
eduid_proofing_amp/__init__.py
SUNET/eduid-proofing-amp
aaf4e93070089ba51c6a985e0c6fce0c9c687b93
[ "BSD-3-Clause" ]
null
null
null
eduid_proofing_amp/__init__.py
SUNET/eduid-proofing-amp
aaf4e93070089ba51c6a985e0c6fce0c9c687b93
[ "BSD-3-Clause" ]
1
2017-06-07T08:55:39.000Z
2017-06-07T08:55:39.000Z
eduid_proofing_amp/__init__.py
SUNET/eduid-proofing-amp
aaf4e93070089ba51c6a985e0c6fce0c9c687b93
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import from celery.utils.log import get_task_logger logger = get_task_logger(__name__) def filter_nin(value): """ :param value: dict :return: list This function will compile a users verified NINs to a list of strings. """ result = [] for item in value: ...
26.546154
120
0.640587
from __future__ import absolute_import from eduid_userdb.proofing import OidcProofingUserDB, LetterProofingUserDB, LookupMobileProofingUserDB from eduid_userdb.proofing import EmailProofingUserDB, PhoneProofingUserDB, OrcidProofingUserDB from eduid_userdb.proofing import EidasProofingUserDB from eduid_userdb.personal_...
0
0
0
4,219
0
193
0
250
341
0a35a64bc8e129fa895b6268a0bf03dcfbeb2e19
3,974
py
Python
razzbee/webviewengine.py
razzbee/kivy-android-webview-
9f8910e710ed271ff32d20b6e1fd2bbab71522bf
[ "MIT" ]
14
2017-04-01T09:05:53.000Z
2021-02-05T19:31:28.000Z
razzbee/webviewengine.py
razzbee/kivy-android-webview-
9f8910e710ed271ff32d20b6e1fd2bbab71522bf
[ "MIT" ]
3
2018-03-16T00:35:16.000Z
2020-04-29T15:48:05.000Z
razzbee/webviewengine.py
razzbee/kivy-android-webview-
9f8910e710ed271ff32d20b6e1fd2bbab71522bf
[ "MIT" ]
8
2017-08-15T16:07:12.000Z
2022-03-27T03:41:34.000Z
from jnius import autoclass #Load Native Modules WebView = autoclass('android.webkit.WebView') WebViewClient = autoclass('android.webkit.WebViewClient') activity = autoclass('org.kivy.android.PythonActivity').mActivity Layo...
28.589928
130
0.668596
from kivy.uix.widget import Widget from kivy.clock import Clock from runnable import run_on_ui_thread from kivy.event import EventDispatcher from jnius import autoclass from webviewclient ...
0
1,296
0
1,921
0
0
0
72
264
200332a5b27e708f82148bbda4a77c474dc9ccba
1,861
py
Python
app/views/arduino.py
yakinaround/myadventure-api
aae56a93748457c2f060434b9faf81830de5bc99
[ "Apache-2.0" ]
null
null
null
app/views/arduino.py
yakinaround/myadventure-api
aae56a93748457c2f060434b9faf81830de5bc99
[ "Apache-2.0" ]
2
2021-03-31T18:30:32.000Z
2021-12-13T19:44:07.000Z
app/views/arduino.py
myadventure/myadventure-api
aae56a93748457c2f060434b9faf81830de5bc99
[ "Apache-2.0" ]
null
null
null
""" android.py Android views. """ from flask import Blueprint from app.decorators import ignore_exception SFLOAT = ignore_exception(TypeError)(float) SINT = ignore_exception(TypeError)(int) SBOOL = ignore_exception(TypeError)(bool) MOD_ARDUINO = Blueprint('arduino', __name__, url_prefix='/api/v1/adventure/<slug>/a...
30.508197
99
0.612574
""" android.py Android views. """ import logging from datetime import datetime from flask import Blueprint, abort, request, jsonify from werkzeug.exceptions import BadRequest from app.decorators import crossdomain, ignore_exception from app.models.adventure import Adventure from app.models.point import Point SFLOAT...
0
1,304
0
0
0
0
0
94
134
625140e4b32448c38225b930dd958630e387c909
1,231
py
Python
models/embedding.py
woo1/Anim-NeRF
03977700420691b18b6aa0bc809f3a05a9f07b12
[ "MIT" ]
130
2021-09-07T15:37:42.000Z
2022-03-30T16:22:50.000Z
models/embedding.py
woo1/Anim-NeRF
03977700420691b18b6aa0bc809f3a05a9f07b12
[ "MIT" ]
18
2021-11-24T05:01:50.000Z
2022-03-18T07:11:13.000Z
models/embedding.py
woo1/Anim-NeRF
03977700420691b18b6aa0bc809f3a05a9f07b12
[ "MIT" ]
15
2022-01-21T10:26:41.000Z
2022-03-30T08:32:12.000Z
import torch.nn as nn
31.564103
76
0.566206
import torch import torch.nn as nn import torch.nn.functional as F class Embedding(nn.Module): def __init__(self, in_channels, N_freqs, logscale=True): """ Defines a function that embeds x to (x, sin(2^k x), cos(2^k x), ...) in_channels: number of input channels (3 for both xyz and directio...
0
0
0
1,142
0
0
0
1
67
8281f6c429c581dacbd8c9cc2bf5636484bbc7fa
989
py
Python
flyer/fix.py
FIXFlyer/pyflyer
e40fdedff4db642a804ed6c29de742444ab0ffe5
[ "MIT" ]
2
2019-06-07T16:03:26.000Z
2020-12-20T22:12:19.000Z
flyer/fix.py
mdvx/pyflyer
e40fdedff4db642a804ed6c29de742444ab0ffe5
[ "MIT" ]
null
null
null
flyer/fix.py
mdvx/pyflyer
e40fdedff4db642a804ed6c29de742444ab0ffe5
[ "MIT" ]
4
2017-07-18T15:06:33.000Z
2022-03-30T05:26:46.000Z
#! /usr/bin/env python #----------------------------------------------------------------------- # COPYRIGHT_BEGIN # Copyright (C) 2016, FixFlyer, LLC. # All rights reserved. # COPYRIGHT_END #-----------------------------------------------------------------------
21.5
88
0.517695
#! /usr/bin/env python #----------------------------------------------------------------------- # COPYRIGHT_BEGIN # Copyright (C) 2016, FixFlyer, LLC. # All rights reserved. # COPYRIGHT_END #----------------------------------------------------------------------- class Message(object): def clear(self): pas...
0
0
0
703
0
0
0
0
23
167af61bf6438845997063a10538e46eff0df427
4,815
py
Python
AI701/bbo_osi/example_submissions/turbo/optimizer.py
sungnyun/AI-assignments
6451fd6db33fd8671ca362b4ad4c190979a98c22
[ "MIT" ]
103
2020-06-26T04:10:11.000Z
2022-03-17T02:09:29.000Z
example_submissions/turbo/optimizer.py
ntienvu/bbo_challenge_starter_kit
bba852b380388c1f1087b232dae62117ddb065bf
[ "Apache-2.0" ]
5
2020-07-12T16:49:42.000Z
2021-07-21T23:26:22.000Z
example_submissions/turbo/optimizer.py
ntienvu/bbo_challenge_starter_kit
bba852b380388c1f1087b232dae62117ddb065bf
[ "Apache-2.0" ]
35
2020-07-02T07:55:19.000Z
2021-03-31T19:00:27.000Z
from bayesmark.experiment import experiment_main if __name__ == "__main__": experiment_main(TurboOptimizer)
36.755725
101
0.61703
from copy import deepcopy import numpy as np import scipy.stats as ss from turbo import Turbo1 from turbo.utils import from_unit_cube, latin_hypercube, to_unit_cube from bayesmark.abstract_optimizer import AbstractOptimizer from bayesmark.experiment import experiment_main from bayesmark.space import JointSpace def ...
0
0
0
3,934
0
430
0
109
225
794bd7ed69e1e978e635f64a2d7412ba530be4c8
4,375
py
Python
setup.py
PRITI1999/klever
ac80edf4301c15f6b63e35837f4ffbf7e3e68809
[ "Apache-2.0" ]
1
2021-01-09T08:44:37.000Z
2021-01-09T08:44:37.000Z
setup.py
Abhik1998/klever
827bbd31b29e213bf74cb1d1b158153e62a2933e
[ "Apache-2.0" ]
3
2021-03-19T09:15:16.000Z
2021-09-22T19:24:40.000Z
setup.py
Abhik1998/klever
827bbd31b29e213bf74cb1d1b158153e62a2933e
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2020 ISP RAS (http://www.ispras.ru) # Ivannikov Institute for System Programming of the Russian Academy of Sciences # # 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 # # htt...
35.282258
91
0.636343
# Copyright (c) 2020 ISP RAS (http://www.ispras.ru) # Ivannikov Institute for System Programming of the Russian Academy of Sciences # # 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 # # htt...
0
0
0
0
0
422
0
-12
69
28334f96479ecb761075604e60d6c1e5c3a15823
1,891
py
Python
Lib/vanilla/test/list2/selection.py
roboDocs/vanilla
d8bb60b24edcc550c3d8cc60cf73143eee87d547
[ "MIT" ]
31
2015-02-09T09:09:26.000Z
2019-01-01T19:04:52.000Z
Lib/vanilla/test/list2/selection.py
roboDocs/vanilla
d8bb60b24edcc550c3d8cc60cf73143eee87d547
[ "MIT" ]
63
2015-04-14T00:40:50.000Z
2019-01-12T15:04:54.000Z
Lib/vanilla/test/list2/selection.py
roboDocs/vanilla
d8bb60b24edcc550c3d8cc60cf73143eee87d547
[ "MIT" ]
16
2015-03-28T21:00:22.000Z
2018-08-17T20:28:53.000Z
if __name__ == "__main__": from vanilla.test.testTools import executeVanillaTest executeVanillaTest(Test)
27.405797
61
0.524061
import vanilla def makeItems(): items = [] letters = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" for i, letter in enumerate(letters): number = i + 1 item = dict( letter=letter, number=number ) items.append(item) return items class Test: def __init__(self)...
0
0
0
1,468
0
245
0
-7
68
76f55ae94b6824f6292bc5b3ea75cb7ecfa43f4f
398
py
Python
api/sonetworks/migrations/0016_remove_staticpage_page.py
gvaldez81/semitki
6c7cbb2bb2260db79478de48a9b2e71b8ed633ff
[ "MIT" ]
null
null
null
api/sonetworks/migrations/0016_remove_staticpage_page.py
gvaldez81/semitki
6c7cbb2bb2260db79478de48a9b2e71b8ed633ff
[ "MIT" ]
51
2017-02-07T22:30:49.000Z
2022-03-11T23:15:55.000Z
api/sonetworks/migrations/0016_remove_staticpage_page.py
gvaldez81/semitki
6c7cbb2bb2260db79478de48a9b2e71b8ed633ff
[ "MIT" ]
1
2017-10-09T14:21:35.000Z
2017-10-09T14:21:35.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.10.5 on 2017-03-30 20:21 from __future__ import unicode_literals
19.9
50
0.61809
# -*- coding: utf-8 -*- # Generated by Django 1.10.5 on 2017-03-30 20:21 from __future__ import unicode_literals from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('sonetworks', '0015_auto_20170330_2001'), ] operations = [ migrations.RemoveField( ...
0
0
0
227
0
0
0
11
46
f7b6ea0ae206265a155eeb220d8b4777db821527
13,540
py
Python
bitsharesbase/operations.py
gdfbacchus/python-bitshares
95f9cefab2f6b72073221bb647df8ab40bcf8e4b
[ "MIT" ]
null
null
null
bitsharesbase/operations.py
gdfbacchus/python-bitshares
95f9cefab2f6b72073221bb647df8ab40bcf8e4b
[ "MIT" ]
null
null
null
bitsharesbase/operations.py
gdfbacchus/python-bitshares
95f9cefab2f6b72073221bb647df8ab40bcf8e4b
[ "MIT" ]
1
2018-11-20T03:50:25.000Z
2018-11-20T03:50:25.000Z
from .operationids import operations default_prefix = "BTS" def getOperationNameForId(i): """ Convert an operation id into the corresponding string """ for key in operations: if int(operations[key]) is int(i): return key return "Unknown Operation ID %d" % i
37.821229
99
0.511226
from collections import OrderedDict import json from graphenebase.types import ( Uint8, Int16, Uint16, Uint32, Uint64, Varint32, Int64, String, Bytes, Void, Array, PointInTime, Signature, Bool, Set, Fixed_array, Optional, Static_variant, Map, Id, VoteId ) from .objects import GrapheneObject, isArgsT...
0
0
0
12,345
0
0
0
382
500
fd14235a97115d0da605df7efd9315bb578a44f1
101
py
Python
run_kbstopwatch.py
mwiens91/kb-stopwatch
0eec6bd942ca1e9786f36d8e577ce304b58d77a3
[ "MIT" ]
null
null
null
run_kbstopwatch.py
mwiens91/kb-stopwatch
0eec6bd942ca1e9786f36d8e577ce304b58d77a3
[ "MIT" ]
null
null
null
run_kbstopwatch.py
mwiens91/kb-stopwatch
0eec6bd942ca1e9786f36d8e577ce304b58d77a3
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """Runs kb-stopwatch.""" from kbstopwatch.main import main # Run it main()
11.222222
33
0.683168
#!/usr/bin/env python3 """Runs kb-stopwatch.""" from kbstopwatch.main import main # Run it main()
0
0
0
0
0
0
0
0
0
a20c02cbb720f1bb48ec57842efc94d26eab867b
4,527
py
Python
transduction_based/laplacian_tags.py
vohoaiviet/tag-image-retrieval
0a257560581f702cd394f3f28c9e0f6202827ce8
[ "MIT" ]
50
2015-11-04T15:53:09.000Z
2022-01-03T14:46:17.000Z
transduction_based/laplacian_tags.py
vohoaiviet/tag-image-retrieval
0a257560581f702cd394f3f28c9e0f6202827ce8
[ "MIT" ]
2
2018-03-07T09:51:50.000Z
2018-10-13T11:05:13.000Z
transduction_based/laplacian_tags.py
vohoaiviet/tag-image-retrieval
0a257560581f702cd394f3f28c9e0f6202827ce8
[ "MIT" ]
17
2015-10-26T03:41:49.000Z
2021-08-23T08:11:05.000Z
#!/usr/bin/env python # encoding: utf-8 import sys import bisect INFO = 'transduction_based.laplacian_tags' DEFAULT_RATIOCS = 0.9 if __name__ == "__main__": sys.exit(main())
34.295455
181
0.662249
#!/usr/bin/env python # encoding: utf-8 import sys, os import numpy as np import bisect import scipy.io import bisect import math import h5py from nltk.corpus import wordnet as wn from nltk.corpus import wordnet_ic from basic.constant import ROOT_PATH from basic.common import makedirsforfile, checkToSkip, printStatus...
0
0
0
0
0
3,858
0
131
356
f7b24a3ed38cb3ed9682bfcbcf9843f1d5c4f3d8
11,103
py
Python
layers/qlib.py
astonzhang/Parameterization-of-Hypercomplex-Multiplications
0e3f1ceebccce9f14ce629356733c07602eb351c
[ "Apache-2.0" ]
10
2021-12-24T17:13:59.000Z
2022-03-22T10:15:00.000Z
layers/qlib.py
astonzhang/Parameterization-of-Hypercomplex-Multiplications
0e3f1ceebccce9f14ce629356733c07602eb351c
[ "Apache-2.0" ]
null
null
null
layers/qlib.py
astonzhang/Parameterization-of-Hypercomplex-Multiplications
0e3f1ceebccce9f14ce629356733c07602eb351c
[ "Apache-2.0" ]
null
null
null
from __future__ import absolute_import from __future__ import division from __future__ import print_function import tensorflow as tf """ Quarternion layers References: https://arxiv.org/pdf/1806.04418.pdf https://arxiv.org/pdf/1806.07789.pdf https://github.com/Orkis-Research/light-Recurrent-Neural-Networks https:/...
30.841667
154
0.665766
from __future__ import absolute_import from __future__ import division from __future__ import print_function import tensorflow as tf import numpy as np from numpy.random import RandomState from tensorflow.python.framework import dtypes from tensorflow.python.ops import random_ops import random """ Quarternion layers ...
0
59
0
1,253
0
1,524
0
52
363
71ef1c0962702fc6f2da6abacd53906df9d377f8
42,856
py
Python
hfc/protos/token/prover_pb2.py
hyperledger-gerrit-archive/fabric-sdk-py
0432d0ebce06a053d55febf7ed793dd163fcb68c
[ "Apache-2.0" ]
null
null
null
hfc/protos/token/prover_pb2.py
hyperledger-gerrit-archive/fabric-sdk-py
0432d0ebce06a053d55febf7ed793dd163fcb68c
[ "Apache-2.0" ]
1
2019-12-09T05:05:41.000Z
2019-12-09T05:05:41.000Z
hfc/protos/token/prover_pb2.py
hyperledger-gerrit-archive/fabric-sdk-py
0432d0ebce06a053d55febf7ed793dd163fcb68c
[ "Apache-2.0" ]
null
null
null
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: hfc/protos/token/prover.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 message as _message from google.protobuf import refl...
40.430189
3,733
0.757584
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: hfc/protos/token/prover.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 message as _message from google.protobuf import refl...
0
0
0
0
0
0
0
0
0
98227190b48433b30a13ee88906b852b86929253
2,899
py
Python
instagram_scraper/auth/authentication.py
davidargylethacker/instagram-scraper
b58760d90aa492f8d7795da572e822d7047a52a5
[ "Unlicense" ]
null
null
null
instagram_scraper/auth/authentication.py
davidargylethacker/instagram-scraper
b58760d90aa492f8d7795da572e822d7047a52a5
[ "Unlicense" ]
null
null
null
instagram_scraper/auth/authentication.py
davidargylethacker/instagram-scraper
b58760d90aa492f8d7795da572e822d7047a52a5
[ "Unlicense" ]
null
null
null
CHROME_WIN_UA = 'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36'
38.653333
127
0.617799
import json import requests from instagram_scraper.constants import BASE_URL, STORIES_UA, LOGIN_URL, LOGOUT_URL CHROME_WIN_UA = 'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36' class Authentication(object): def __init__(self): self.logged_...
0
0
0
2,632
0
0
0
46
91
76e2b89bed1f1e5e61c69927513e3fe46864ced5
2,051
py
Python
assessor_mark2.py
piyushsingariya/assessor-series
263b5852b83689f25e03fb2efb174b1aa13c7cf2
[ "MIT" ]
1
2019-06-16T17:15:41.000Z
2019-06-16T17:15:41.000Z
assessor_mark2.py
piyushsingariya/assessor-series
263b5852b83689f25e03fb2efb174b1aa13c7cf2
[ "MIT" ]
null
null
null
assessor_mark2.py
piyushsingariya/assessor-series
263b5852b83689f25e03fb2efb174b1aa13c7cf2
[ "MIT" ]
null
null
null
# Determining interface details with netfaces library # This script uses a number of functions to accomplish specific tasks # including get_networks, get_addresses, get_gateways and get_interfaces import netifaces import sys try: except: sys.exit("[!] Install the netifaces library: pip install netifaces") gateway...
33.080645
121
0.714286
# Determining interface details with netfaces library # This script uses a number of functions to accomplish specific tasks # including get_networks, get_addresses, get_gateways and get_interfaces import netifaces import sys try: import netifaces except: sys.exit("[!] Install the netifaces library: pip install...
0
0
0
0
0
1,216
0
-5
119
1e458847a7ea5ac7e0e6b7cd0b13973ccc014c9c
1,180
py
Python
controllers/user.py
brianpesy/DevCamp
48576ef93a1a33d2ea0f2d3901bee77c158d8767
[ "BSD-3-Clause" ]
null
null
null
controllers/user.py
brianpesy/DevCamp
48576ef93a1a33d2ea0f2d3901bee77c158d8767
[ "BSD-3-Clause" ]
null
null
null
controllers/user.py
brianpesy/DevCamp
48576ef93a1a33d2ea0f2d3901bee77c158d8767
[ "BSD-3-Clause" ]
null
null
null
from helpers import functions from flask import request, session, redirect, render_template, g, flash from werkzeug import check_password_hash def login(): """Logs the user in.""" if g.user: return redirect(functions.url_for('/')) error = None if request.method == 'POST': user = functio...
32.777778
66
0.611864
from helpers import functions from flask import Flask, request, session, url_for, redirect, \ render_template, abort, g, flash, _app_ctx_stack from werkzeug import check_password_hash, generate_password_hash def login(): """Logs the user in.""" if g.user: return redirect(functions.url_for('/')) ...
0
0
0
0
0
0
0
70
0
e706ff590d0748c75f079ded5d16403c7851b34f
42,001
py
Python
src/nanoSessionKontrol/ChannelStripController.py
lmarie23/nanoSessionKontrol
4a307464556734f03d4d073c377cebe1587d9316
[ "Apache-2.0" ]
1
2021-06-06T07:20:18.000Z
2021-06-06T07:20:18.000Z
src/nanoSessionKontrol/ChannelStripController.py
lmarie23/nanoSessionKontrol
4a307464556734f03d4d073c377cebe1587d9316
[ "Apache-2.0" ]
null
null
null
src/nanoSessionKontrol/ChannelStripController.py
lmarie23/nanoSessionKontrol
4a307464556734f03d4d073c377cebe1587d9316
[ "Apache-2.0" ]
null
null
null
#Embedded file name: /Users/versonator/Hudson/live/Projects/AppLive/Resources/MIDI Remote Scripts/MackieControl/ChannelStripController.py
48.725058
188
0.649794
#Embedded file name: /Users/versonator/Hudson/live/Projects/AppLive/Resources/MIDI Remote Scripts/MackieControl/ChannelStripController.py from itertools import chain from .MHControlComponent import * from _Generic.Devices import * class ChannelStripController(MHControlComponent): """ Controls all channel-...
0
0
0
41,746
0
0
0
27
90
ab774b27049c59a7c1608f2fef3901d45566ef6f
81
py
Python
Aula09/ex14.py
danicon/Curso_Python
18fb4aad975bdc3b96cb5320331dbc7d3c3a459d
[ "MIT" ]
null
null
null
Aula09/ex14.py
danicon/Curso_Python
18fb4aad975bdc3b96cb5320331dbc7d3c3a459d
[ "MIT" ]
null
null
null
Aula09/ex14.py
danicon/Curso_Python
18fb4aad975bdc3b96cb5320331dbc7d3c3a459d
[ "MIT" ]
null
null
null
nome = str(input('Digite o seu nome: ')) nom = nome.title() print('Silva' in nom)
27
40
0.654321
nome = str(input('Digite o seu nome: ')) nom = nome.title() print('Silva' in nom)
0
0
0
0
0
0
0
0
0
4c05ba9565f2cbca21d16be983c81c5b28beccd3
402
py
Python
09 Sorting/3 insertionSort.py
harshrajm/Python-Algo-DS
02437fa923b2b6264b29bd7ba84ccbb7feb9c8f0
[ "MIT" ]
null
null
null
09 Sorting/3 insertionSort.py
harshrajm/Python-Algo-DS
02437fa923b2b6264b29bd7ba84ccbb7feb9c8f0
[ "MIT" ]
null
null
null
09 Sorting/3 insertionSort.py
harshrajm/Python-Algo-DS
02437fa923b2b6264b29bd7ba84ccbb7feb9c8f0
[ "MIT" ]
null
null
null
print(insertionSort([55,3,2,5,6,75,4]))
21.157895
61
0.487562
def insertionSort(arr): for i in range(1,len(arr)): currentVal = arr[i] position = i while position > 0 and arr[position-1] > currentVal: arr[position] = arr[position-1] position = position - 1 arr[p...
0
0
0
0
0
332
0
0
25
e1877cfa1bdf9f6a3b42eb79a4b5b0362841a6c8
350
py
Python
PyMOTW/source/argparse/argparse_mutually_exclusive.py
axetang/AxePython
3b517fa3123ce2e939680ad1ae14f7e602d446a6
[ "Apache-2.0" ]
1
2019-01-04T05:47:50.000Z
2019-01-04T05:47:50.000Z
PyMOTW/source/argparse/argparse_mutually_exclusive.py
axetang/AxePython
3b517fa3123ce2e939680ad1ae14f7e602d446a6
[ "Apache-2.0" ]
1
2020-07-18T03:52:03.000Z
2020-07-18T04:18:01.000Z
PyMOTW/source/argparse/argparse_mutually_exclusive.py
axetang/AxePython
3b517fa3123ce2e939680ad1ae14f7e602d446a6
[ "Apache-2.0" ]
2
2021-03-06T04:28:32.000Z
2021-03-06T04:59:17.000Z
#!/usr/bin/env python3 # encoding: utf-8 # # Copyright (c) 2010 Doug Hellmann. All rights reserved. # """ """ #end_pymotw_header import argparse parser = argparse.ArgumentParser() group = parser.add_mutually_exclusive_group() group.add_argument('-a', action='store_true') group.add_argument('-b', action='store_true'...
18.421053
57
0.737143
#!/usr/bin/env python3 # encoding: utf-8 # # Copyright (c) 2010 Doug Hellmann. All rights reserved. # """ """ #end_pymotw_header import argparse parser = argparse.ArgumentParser() group = parser.add_mutually_exclusive_group() group.add_argument('-a', action='store_true') group.add_argument('-b', action='store_true'...
0
0
0
0
0
0
0
0
0
3fbb83487a465a1a51cc8203d043aefa5f77fea9
2,306
py
Python
example/server.py
inovonics/cloud-oauth
951124100dd45204c3325b975084fa9690d16147
[ "MIT" ]
1
2017-10-19T19:23:38.000Z
2017-10-19T19:23:38.000Z
example/server.py
inovonics/cloud-oauth
951124100dd45204c3325b975084fa9690d16147
[ "MIT" ]
3
2017-12-04T18:11:31.000Z
2018-04-10T23:58:59.000Z
example/server.py
inovonics/cloud-oauth
951124100dd45204c3325b975084fa9690d16147
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # === IMPORTS === import os from flask import Flask from inovonics.cloud.datastore import InoRedis from inovonics.cloud.oauth import InoOAuth2Provider, oauth_register_handlers # === GLOBALS === REDIS_HOST = os.getenv('REDIS_HOST', 'localhost') REDIS_PORT = os.getenv('REDIS_PORT', 6379) REDIS_...
27.452381
114
0.669124
#!/usr/bin/env python3 # === IMPORTS === import logging import os from flask import Flask from inovonics.cloud.datastore import InoRedis from inovonics.cloud.oauth import InoOAuth2Provider, oauth_register_handlers from inovonics.cloud.oauth import OAuthClients, OAuthClient, OAuthUsers, OAuthUser # === GLOBALS === ...
0
1,161
0
0
0
290
0
54
135
bdf6fc45c72e4cc335707fd6de0a5dd2d2ecb997
1,256
py
Python
sandbox/server.py
tacosync/quote-socket
e65b79968663d9d5a0d991166e791e0ee1029a91
[ "MIT" ]
null
null
null
sandbox/server.py
tacosync/quote-socket
e65b79968663d9d5a0d991166e791e0ee1029a91
[ "MIT" ]
1
2020-06-17T08:55:54.000Z
2020-06-17T08:55:54.000Z
sandbox/server.py
tacosync/quote-socket
e65b79968663d9d5a0d991166e791e0ee1029a91
[ "MIT" ]
null
null
null
''' Socket.IO server for testing CLI: python -m watchgod server.main [aiohttp|sanic|tornado|asgi] Test results: | connect | disconnect | event | background_task | Ctrl+C ---------+---------+------------+-------+-----------------|-------- aiohttp | O | O | O | X ...
27.911111
70
0.494427
''' Socket.IO server for testing CLI: python -m watchgod server.main [aiohttp|sanic|tornado|asgi] Test results: | connect | disconnect | event | background_task | Ctrl+C ---------+---------+------------+-------+-----------------|-------- aiohttp | O | O | O | X ...
0
0
0
0
0
416
0
115
144
5d135caa4532bcc7d1789591afc459bd38d60010
323
py
Python
1/video2frames.py
AnushK-Fro/ASCII-Video-Discord-Bot
c18e2278075e254f91492abb844713b7e5367542
[ "MIT" ]
null
null
null
1/video2frames.py
AnushK-Fro/ASCII-Video-Discord-Bot
c18e2278075e254f91492abb844713b7e5367542
[ "MIT" ]
null
null
null
1/video2frames.py
AnushK-Fro/ASCII-Video-Discord-Bot
c18e2278075e254f91492abb844713b7e5367542
[ "MIT" ]
null
null
null
video_file_name = "" if __name__ == '__main__': FrameCapture(video_file_name)
20.1875
49
0.606811
import cv2 video_file_name = "" def FrameCapture(path): vidObj = cv2.VideoCapture(path) count = 0 success = 1 while success: success, image = vidObj.read() cv2.imwrite("frame%d.jpg" % count, image) count += 1 if __name__ == '__main__': FrameCapture(video_file_nam...
0
0
0
0
0
199
0
-11
48
8a1fa51fea4d1f0796cf567794820f1f43be633e
14,907
py
Python
vpv/model/model.py
mpi2/vpv
3d0445fa36a8916dfbeed07f50e702b1ffe0973a
[ "Apache-2.0" ]
2
2016-08-15T22:06:28.000Z
2016-11-15T14:23:37.000Z
vpv/model/model.py
mpi2/vpv
3d0445fa36a8916dfbeed07f50e702b1ffe0973a
[ "Apache-2.0" ]
1
2018-07-30T22:47:37.000Z
2018-07-30T22:47:37.000Z
vpv/model/model.py
mpi2/vpv
3d0445fa36a8916dfbeed07f50e702b1ffe0973a
[ "Apache-2.0" ]
1
2020-08-05T03:54:02.000Z
2020-08-05T03:54:02.000Z
# Copyright 2016 Medical Research Council Harwell. # # 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...
37.08209
146
0.581673
# Copyright 2016 Medical Research Council Harwell. # # 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...
0
0
0
13,554
0
0
0
276
355
7f31bb9213a5312eb7c272816e3ae00023c5e887
16,836
py
Python
python2.7/site-packages/twisted/trial/test/test_reporter.py
84KaliPleXon3/sslstrip-hsts-openwrt
f875ded48078a3ed84bffef1e69dcbeaf2e77ae3
[ "MIT" ]
4
2020-10-31T19:52:05.000Z
2021-09-22T11:39:27.000Z
python2.7/site-packages/twisted/trial/test/test_reporter.py
84KaliPleXon3/sslstrip-hsts-openwrt
f875ded48078a3ed84bffef1e69dcbeaf2e77ae3
[ "MIT" ]
null
null
null
python2.7/site-packages/twisted/trial/test/test_reporter.py
84KaliPleXon3/sslstrip-hsts-openwrt
f875ded48078a3ed84bffef1e69dcbeaf2e77ae3
[ "MIT" ]
2
2020-02-27T08:28:35.000Z
2020-09-13T12:39:26.000Z
# Copyright (c) 2001-2004 Twisted Matrix Laboratories. # See LICENSE for details. # # Maintainer: Jonathan Lange <jml@twistedmatrix.com>
35.897655
79
0.622238
# Copyright (c) 2001-2004 Twisted Matrix Laboratories. # See LICENSE for details. # # Maintainer: Jonathan Lange <jml@twistedmatrix.com> import errno, sys, os, re, StringIO from twisted.internet.utils import suppressWarnings from twisted.python import failure from twisted.trial import unittest, runner, reporter, util...
0
0
0
16,113
0
0
0
113
456
beb3e066fe6e8c920e49769ce5fec01b8e52d337
218
py
Python
run.py
lowell-dev-club/live-flask-workshop
a57a3db79fd772a6676ad3bce1ff45e1a5c1c06d
[ "MIT" ]
null
null
null
run.py
lowell-dev-club/live-flask-workshop
a57a3db79fd772a6676ad3bce1ff45e1a5c1c06d
[ "MIT" ]
null
null
null
run.py
lowell-dev-club/live-flask-workshop
a57a3db79fd772a6676ad3bce1ff45e1a5c1c06d
[ "MIT" ]
null
null
null
# Import Flask app object from project folder (For python this means from the __init__.py file) from project import app # Run flask app with debug on and listening on port 8000 app.run( debug=True, port=8000 )
27.25
95
0.747706
# Import Flask app object from project folder (For python this means from the __init__.py file) from project import app # Run flask app with debug on and listening on port 8000 app.run( debug=True, port=8000 )
0
0
0
0
0
0
0
0
0
acb8f38d1fce7e807bb197cfdc155940d8636b58
704
py
Python
Section 4 - Lists/prediction exercise.py
gitjot/python-for-lccs
a8a4ae8847abbc33361f80183c06d57b20523382
[ "CC0-1.0" ]
10
2020-02-14T14:28:15.000Z
2022-02-02T18:44:11.000Z
Section 4 - Lists/prediction exercise.py
gitjot/python-for-lccs
a8a4ae8847abbc33361f80183c06d57b20523382
[ "CC0-1.0" ]
null
null
null
Section 4 - Lists/prediction exercise.py
gitjot/python-for-lccs
a8a4ae8847abbc33361f80183c06d57b20523382
[ "CC0-1.0" ]
8
2020-03-25T09:27:42.000Z
2021-11-03T15:24:38.000Z
# Event: LCCS Python Fundamental Skills Workshop # Date: May 2018 # Author: Joe English, PDST # eMail: computerscience@pdst.ie # Purpose: Prediction exercise fruits = ['Strawberry', 'Lemon', 'Orange', 'Raspberry', 'Cherry'] print(fruits[0]) print(fruits[3]) print(fruits[2]) print(fruits[len(fruits)-1]) pr...
23.466667
66
0.693182
# Event: LCCS Python Fundamental Skills Workshop # Date: May 2018 # Author: Joe English, PDST # eMail: computerscience@pdst.ie # Purpose: Prediction exercise fruits = ['Strawberry', 'Lemon', 'Orange', 'Raspberry', 'Cherry'] print(fruits[0]) print(fruits[3]) print(fruits[2]) print(fruits[len(fruits)-1]) pr...
0
0
0
0
0
0
0
0
0
b5797a6e0b5ac972df8e6cf74d6538070b12831e
762
py
Python
src/Overload.py
LukeMcCulloch/PyCFD
6720e6575e25f8c274ef591d6c215de90a740935
[ "MIT" ]
1
2020-07-04T15:42:15.000Z
2020-07-04T15:42:15.000Z
src/Overload.py
LukeMcCulloch/PyCFD
6720e6575e25f8c274ef591d6c215de90a740935
[ "MIT" ]
null
null
null
src/Overload.py
LukeMcCulloch/PyCFD
6720e6575e25f8c274ef591d6c215de90a740935
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 # -*- coding: utf-8 -*- """ Created on Sat Jan 4 07:43:40 2020 @author: lukemcculloch """
21.771429
45
0.566929
#!/usr/bin/env python2 # -*- coding: utf-8 -*- """ Created on Sat Jan 4 07:43:40 2020 @author: lukemcculloch """ import numpy as np class Overload(object): def __init__(self, vector): self.vector = vector self.parentcell = [] def __add__(self, other): if isinstance(...
0
0
0
596
0
0
0
-3
45
8f049df44809d1fe48e8f05eb98329ff0b64f235
126
py
Python
clu/__init__.py
basameera/CLI-Utils
7f52ffa3fee29ee7a7d864a497e4f947f94c40e0
[ "MIT" ]
null
null
null
clu/__init__.py
basameera/CLI-Utils
7f52ffa3fee29ee7a7d864a497e4f947f94c40e0
[ "MIT" ]
1
2020-05-06T20:37:48.000Z
2020-05-06T20:37:48.000Z
clu/__init__.py
basameera/CLI-Utils
7f52ffa3fee29ee7a7d864a497e4f947f94c40e0
[ "MIT" ]
null
null
null
from .vsr import VERSION __version__ = VERSION __author__ = 'Sameera Sandaruwan' __author_email__ = 'basameera@protonmail.com'
31.5
45
0.81746
from .vsr import VERSION __version__ = VERSION __author__ = 'Sameera Sandaruwan' __author_email__ = 'basameera@protonmail.com'
0
0
0
0
0
0
0
0
0
44af19045c58f933bd90128459e09cb4e7656830
3,295
py
Python
simpleblog/tests/test_functional_tests.py
blacktower2016/simpleblog
e0a7e79de7daf3774518a21f6e3c808e2fc79ec5
[ "MIT" ]
null
null
null
simpleblog/tests/test_functional_tests.py
blacktower2016/simpleblog
e0a7e79de7daf3774518a21f6e3c808e2fc79ec5
[ "MIT" ]
null
null
null
simpleblog/tests/test_functional_tests.py
blacktower2016/simpleblog
e0a7e79de7daf3774518a21f6e3c808e2fc79ec5
[ "MIT" ]
null
null
null
if __name__ == '__main__': unittest.main()
37.022472
84
0.692261
from django.test import LiveServerTestCase from selenium import webdriver from django.urls import reverse from django.utils.translation import activate, gettext_lazy as _ from .creation_utils import create_user, create_post from simpleblog.models import Post class TestPostCreate(LiveServerTestCase): def setUp(sel...
106
0
0
2,889
0
0
0
127
178
877a288b95e328f85cddeb7a00bdc71a41bafbba
498
py
Python
arrays/first_duplicate_value.py
maanavshah/coding-interview
4c842cdbc6870da79684635f379966d1caec2162
[ "MIT" ]
null
null
null
arrays/first_duplicate_value.py
maanavshah/coding-interview
4c842cdbc6870da79684635f379966d1caec2162
[ "MIT" ]
null
null
null
arrays/first_duplicate_value.py
maanavshah/coding-interview
4c842cdbc6870da79684635f379966d1caec2162
[ "MIT" ]
null
null
null
# O(n) time | O(n) space # O(n) time | O(1) space
24.9
41
0.566265
# O(n) time | O(n) space def firstDuplicateValue(array): seenElements = {} for idx, element in enumerate(array): if element in seenElements: return element else: seenElements[element] = idx return -1 # O(n) time | O(1) space def firstDuplicateValue(array): for el...
0
0
0
0
0
403
0
0
44
0aaae7be3b0ace41a6421efe879e353e865df314
4,063
py
Python
Sources/Workflows/Shanbay_Alfred2_Workflow/shanbay.py
yagosys/AlfredWorkflow.com
9e5087e61fb89640a7a6ca89ba554303aec0b037
[ "MIT" ]
2,177
2015-01-02T09:56:51.000Z
2022-03-27T01:48:37.000Z
Sources/Workflows/Shanbay_Alfred2_Workflow/shanbay.py
yagosys/AlfredWorkflow.com
9e5087e61fb89640a7a6ca89ba554303aec0b037
[ "MIT" ]
24
2015-01-02T19:11:51.000Z
2021-01-27T07:20:33.000Z
Sources/Workflows/Shanbay_Alfred2_Workflow/shanbay.py
yagosys/AlfredWorkflow.com
9e5087e61fb89640a7a6ca89ba554303aec0b037
[ "MIT" ]
516
2015-01-02T18:48:29.000Z
2022-01-26T07:12:35.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- #! utf-8 import sys reload(sys) sys.setdefaultencoding('utf8') # if __name__ == '__main__': d = ShanbayDict() d.query(sys.argv[1]) d.output()
31.992126
123
0.535811
#!/usr/bin/env python # -*- coding: utf-8 -*- #! 强制默认编码为utf-8 import sys reload(sys) sys.setdefaultencoding('utf8') import urllib, urllib2, json, time from pprint import pprint from pdb import set_trace import requests from lxml import html from alfred.feedback import Feedback from config import service, addword, ...
87
0
0
3,580
0
0
0
69
180
8dcef86aa8287856e10a453698de6d0f45be68cd
78
py
Python
odl_details.py
vaibhgupta157/PathCompute
44109176dc3770f7742e4e70225083ffe8eccad7
[ "MIT" ]
5
2019-08-05T20:00:03.000Z
2021-11-24T07:39:06.000Z
odl_details.py
vaibhgupta157/PathCompute
44109176dc3770f7742e4e70225083ffe8eccad7
[ "MIT" ]
1
2019-07-15T13:04:45.000Z
2019-10-10T02:21:51.000Z
odl_details.py
vaibhgupta157/PathCompute
44109176dc3770f7742e4e70225083ffe8eccad7
[ "MIT" ]
2
2019-08-01T21:17:15.000Z
2020-09-30T20:19:49.000Z
ODL_IP = "127.0.0.1" ODL_PORT = "8181" ODL_USER = "admin" ODL_PASS = "admin"
13
20
0.641026
ODL_IP = "127.0.0.1" ODL_PORT = "8181" ODL_USER = "admin" ODL_PASS = "admin"
0
0
0
0
0
0
0
0
0
174da0292817370750a98ca1b863b2c249ba736f
574
py
Python
nova_dveri_ru/html_work/html_code.py
Aleksey-Voko/nova_dveri_ru
7657c81e12f4486100385b9f181895f7688a8106
[ "MIT" ]
null
null
null
nova_dveri_ru/html_work/html_code.py
Aleksey-Voko/nova_dveri_ru
7657c81e12f4486100385b9f181895f7688a8106
[ "MIT" ]
null
null
null
nova_dveri_ru/html_work/html_code.py
Aleksey-Voko/nova_dveri_ru
7657c81e12f4486100385b9f181895f7688a8106
[ "MIT" ]
null
null
null
if __name__ == '__main__': url = 'https://nova-dveri.ru/mezhkomnatnye-dveri/ehkoshpon/il%20doors/dver-galleya-07-chern-yasen-svetlyj' out_html_file = 'galleya-07-chern-yasen-svetlyj.html' save_html_code(url, out_html_file)
27.333333
110
0.705575
import requests from nova_dveri_ru.data import USER_AGENT def save_html_code(input_url: str, out_file: str): headers = { 'User-Agent': USER_AGENT, } response = requests.get(input_url, headers=headers) html_code = response.text with open(out_file, 'w', encoding='utf-8') as fl: fl....
0
0
0
0
0
254
0
14
68
3fd50a97d477c6606a8e1d7b5ef666f3120603de
6,976
py
Python
src/mutiny/_internal/models/user.py
jack1142/Mutiny
586dc7131c0d9eba98a271601a446e00792e8cde
[ "ECL-2.0", "Apache-2.0" ]
20
2021-08-18T20:46:16.000Z
2022-01-06T22:53:25.000Z
src/mutiny/_internal/models/user.py
jack1142/Mutiny
586dc7131c0d9eba98a271601a446e00792e8cde
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
src/mutiny/_internal/models/user.py
jack1142/Mutiny
586dc7131c0d9eba98a271601a446e00792e8cde
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# Copyright 2021 Jakub Kuczys (https://github.com/jack1142) # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicab...
32.446512
88
0.673595
# Copyright 2021 Jakub Kuczys (https://github.com/jack1142) # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicab...
0
5,747
0
0
0
0
0
158
256
0addda13f42195fa3b166c4628f48102cc4fb485
33,961
py
Python
Lib/site-packages/win32/lib/winnt.py
raychorn/svn_Python-2.5.1
425005b1b489ba44ec0bb989e077297e8953d9be
[ "PSF-2.0" ]
null
null
null
Lib/site-packages/win32/lib/winnt.py
raychorn/svn_Python-2.5.1
425005b1b489ba44ec0bb989e077297e8953d9be
[ "PSF-2.0" ]
null
null
null
Lib/site-packages/win32/lib/winnt.py
raychorn/svn_Python-2.5.1
425005b1b489ba44ec0bb989e077297e8953d9be
[ "PSF-2.0" ]
null
null
null
# Generated by h2py from \mssdk\include\winnt.h APPLICATION_ERROR_MASK = 536870912 ERROR_SEVERITY_SUCCESS = 0 ERROR_SEVERITY_INFORMATIONAL = 1073741824 ERROR_SEVERITY_WARNING = -2147483648 ERROR_SEVERITY_ERROR = -1073741824 MINCHAR = 128 MAXCHAR = 127 MINSHORT = 32768 MAXSHORT = 32767 MINLONG = -2147483648 ...
30.901729
103
0.76317
# Generated by h2py from \mssdk\include\winnt.h APPLICATION_ERROR_MASK = 536870912 ERROR_SEVERITY_SUCCESS = 0 ERROR_SEVERITY_INFORMATIONAL = 1073741824 ERROR_SEVERITY_WARNING = -2147483648 ERROR_SEVERITY_ERROR = -1073741824 MINCHAR = 128 MAXCHAR = 127 MINSHORT = 32768 MAXSHORT = 32767 MINLONG = -2147483648 ...
0
0
0
0
0
699
0
0
448
e22e54a9a99a8dec899f21dc34205db0365bd080
775
py
Python
esipy/exceptions.py
klinger/EsiPy
f51863034f933c15ec4c506a466576b1b966d5ef
[ "BSD-3-Clause" ]
null
null
null
esipy/exceptions.py
klinger/EsiPy
f51863034f933c15ec4c506a466576b1b966d5ef
[ "BSD-3-Clause" ]
null
null
null
esipy/exceptions.py
klinger/EsiPy
f51863034f933c15ec4c506a466576b1b966d5ef
[ "BSD-3-Clause" ]
null
null
null
# -*- encoding: utf-8 -*- """ Exceptions for EsiPy related errors """
35.227273
68
0.532903
# -*- encoding: utf-8 -*- """ Exceptions for EsiPy related errors """ class APIException(Exception): """ Exception for SSO related errors """ def __init__(self, url, code, json_response): self.url = url self.status_code = code self.response = json_response super(API...
0
0
0
676
0
0
0
0
25
9ea5d5434ac2b3e087de3f3f4a234d09730d9a32
594
py
Python
problems/599.Minimum_Index_Sum_of_Two_Lists/li_counter.py
subramp-prep/leetcode
d125201d9021ab9b1eea5e5393c2db4edd84e740
[ "Unlicense" ]
null
null
null
problems/599.Minimum_Index_Sum_of_Two_Lists/li_counter.py
subramp-prep/leetcode
d125201d9021ab9b1eea5e5393c2db4edd84e740
[ "Unlicense" ]
null
null
null
problems/599.Minimum_Index_Sum_of_Two_Lists/li_counter.py
subramp-prep/leetcode
d125201d9021ab9b1eea5e5393c2db4edd84e740
[ "Unlicense" ]
null
null
null
# coding=utf-8 # Author: Jianghan LI # Question: 599.Minimum_Index_Sum_of_Two_Lists # Date: 2017-05-30, 0 wrong try from collections import Counter s = Solution() print s.findRestaurant(["Shogun", "Tapioca Express", "Burger King", "KFC"], ["KFC", "Shogun", "Burger King"])
28.285714
109
0.606061
# coding=utf-8 # Author: Jianghan LI # Question: 599.Minimum_Index_Sum_of_Two_Lists # Date: 2017-05-30, 0 wrong try from collections import Counter class Solution(object): def findRestaurant(self, l1, l2): d = set(l1) & set(l2) c = Counter({v: i + 1 for i, v in enumerate(l1) if v in d}) + \ ...
0
0
0
294
0
0
0
0
23
1eb5869afdf8053c80b5e34a7e2f20873044f9ab
3,666
py
Python
tests/test_awesomeversion.py
agners/awesomeversion
4d03a0a3fb35e35e4eab984423c903cf50137510
[ "MIT" ]
null
null
null
tests/test_awesomeversion.py
agners/awesomeversion
4d03a0a3fb35e35e4eab984423c903cf50137510
[ "MIT" ]
null
null
null
tests/test_awesomeversion.py
agners/awesomeversion
4d03a0a3fb35e35e4eab984423c903cf50137510
[ "MIT" ]
null
null
null
"""Test awesomeversion.""" import json import pytest from awesomeversion import (AwesomeVersion, AwesomeVersionStrategy, AwesomeVersionStrategyException) def test_awesomeversion(): """Test awesomeversion.""" version = AwesomeVersion("2020.12.1") assert not version.beta version = AwesomeVersion("202...
27.358209
85
0.665576
"""Test awesomeversion.""" import json import pytest from awesomeversion import ( AwesomeVersion, AwesomeVersionStrategy, AwesomeVersionStrategyException, ) def test_awesomeversion(): """Test awesomeversion.""" version = AwesomeVersion("2020.12.1") assert not version.beta version = Awes...
0
1,022
0
0
0
0
0
15
23
543dafa81620a4ef6fd62bec3b7da69e65bb0a52
2,934
py
Python
user/migrations/0001_initial.py
Hrsn2861/pysat-server
72224bb0e6af8ef825eaf3259587698b5639b8a5
[ "MIT" ]
null
null
null
user/migrations/0001_initial.py
Hrsn2861/pysat-server
72224bb0e6af8ef825eaf3259587698b5639b8a5
[ "MIT" ]
7
2020-06-06T01:55:39.000Z
2022-02-10T11:46:31.000Z
user/migrations/0001_initial.py
Hrsnnnn/pysat-server
72224bb0e6af8ef825eaf3259587698b5639b8a5
[ "MIT" ]
null
null
null
# Generated by Django 2.2.5 on 2019-11-02 11:35
37.615385
114
0.504431
# Generated by Django 2.2.5 on 2019-11-02 11:35 from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='EntryLog', fields=[ ('id', models.AutoField...
0
0
0
2,820
0
0
0
19
46
857923f165523a228611c35189dcf54fa43aa704
5,837
py
Python
examples/extension/fruitproperty/pyproperty.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
31
2015-04-01T15:59:36.000Z
2022-03-18T20:21:47.000Z
examples/extension/fruitproperty/pyproperty.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
3
2015-02-06T19:30:24.000Z
2017-05-25T14:14:31.000Z
examples/extension/fruitproperty/pyproperty.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
7
2015-01-23T15:19:22.000Z
2021-06-09T09:03:59.000Z
# -*- python -*- # This software was produced by NIST, an agency of the U.S. government, # and by statute is not subject to copyright in the United States. # Recipients of this software assume all responsibilities associated # with its operation, modification and maintenance. However, to # facilitate maintenance we as...
47.455285
79
0.587802
# -*- python -*- # This software was produced by NIST, an agency of the U.S. government, # and by statute is not subject to copyright in the United States. # Recipients of this software assume all responsibilities associated # with its operation, modification and maintenance. However, to # facilitate maintenance we as...
0
0
0
3,779
0
0
0
150
179
64b5a2cb8929ad161a1ee1dc4b0d356c36e7cf8d
2,930
py
Python
distributed_dp/dme_utils.py
AbdulmoneamAli/federated
c54a9f5053d6316f81aa6f6d1eba61068927a33d
[ "Apache-2.0" ]
1
2021-07-29T16:35:21.000Z
2021-07-29T16:35:21.000Z
distributed_dp/dme_utils.py
AbdulmoneamAli/federated
c54a9f5053d6316f81aa6f6d1eba61068927a33d
[ "Apache-2.0" ]
null
null
null
distributed_dp/dme_utils.py
AbdulmoneamAli/federated
c54a9f5053d6316f81aa6f6d1eba61068927a33d
[ "Apache-2.0" ]
null
null
null
# Copyright 2021, Google LLC. 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or...
37.088608
74
0.743686
# Copyright 2021, Google LLC. 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or...
0
0
0
0
0
0
0
0
0
d4c2ee1d2c14dcb31de7addfc1b457de42691515
3,199
py
Python
p2ner/components/plugin/overlayviz2/overlayviz/xmlinterface.py
schristakidis/p2ner
46694a41e8c1ebdc28f520b58c126da8785f3eed
[ "Apache-2.0" ]
2
2015-06-01T22:04:34.000Z
2017-07-06T09:35:00.000Z
p2ner/components/plugin/overlayviz2/overlayviz/xmlinterface.py
schristakidis/p2ner
46694a41e8c1ebdc28f520b58c126da8785f3eed
[ "Apache-2.0" ]
null
null
null
p2ner/components/plugin/overlayviz2/overlayviz/xmlinterface.py
schristakidis/p2ner
46694a41e8c1ebdc28f520b58c126da8785f3eed
[ "Apache-2.0" ]
1
2019-11-26T10:22:35.000Z
2019-11-26T10:22:35.000Z
# -*- coding: utf-8 -*- # Copyright 2012 Loris Corazza, Sakis Christakidis # # 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 # # U...
33.673684
91
0.524539
# -*- coding: utf-8 -*- # Copyright 2012 Loris Corazza, Sakis Christakidis # # 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 # # U...
0
0
0
2,461
0
0
0
29
68
c4847d72a088620fab5a7b96015b61f8285613d4
1,858
py
Python
migrations/versions/8580b5c0888c_initial_migrate.py
alchermd/client_payroll
fefb434cb3a4af768a1d01d0e88a4f22f88a2e6c
[ "MIT" ]
2
2018-12-02T01:36:57.000Z
2019-11-23T01:01:49.000Z
migrations/versions/8580b5c0888c_initial_migrate.py
alchermd/client_payroll
fefb434cb3a4af768a1d01d0e88a4f22f88a2e6c
[ "MIT" ]
4
2017-11-03T11:47:05.000Z
2017-11-05T15:20:00.000Z
migrations/versions/8580b5c0888c_initial_migrate.py
alchermd/client_payroll
fefb434cb3a4af768a1d01d0e88a4f22f88a2e6c
[ "MIT" ]
5
2018-04-02T13:52:43.000Z
2022-01-25T06:38:44.000Z
"""Initial migrate Revision ID: 8580b5c0888c Revises: Create Date: 2017-11-02 23:42:58.243681 """ # revision identifiers, used by Alembic. revision = '8580b5c0888c' down_revision = None branch_labels = None depends_on = None
30.966667
65
0.669537
"""Initial migrate Revision ID: 8580b5c0888c Revises: Create Date: 2017-11-02 23:42:58.243681 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = '8580b5c0888c' down_revision = None branch_labels = None depends_on = None def upgrade(): # ### commands auto ge...
0
0
0
0
0
1,533
0
3
90
d219082334961cda51c1bcbec9e557f2b3ee25de
884
py
Python
examples/uni_arviz_rhat.py
kushagragpt99/kanga
1f2343d15965148ae7c1dea95168c31a87b27c4f
[ "MIT" ]
1
2022-02-03T08:50:35.000Z
2022-02-03T08:50:35.000Z
examples/uni_arviz_rhat.py
kushagragpt99/kanga
1f2343d15965148ae7c1dea95168c31a87b27c4f
[ "MIT" ]
null
null
null
examples/uni_arviz_rhat.py
kushagragpt99/kanga
1f2343d15965148ae7c1dea95168c31a87b27c4f
[ "MIT" ]
null
null
null
# Compute potential scale reduction factor (Rhat) using rhat function of kanga, which is rhat of arviz # %% Load packages import numpy as np # %% Define function for computing univariate Rhat based on arviz # x is a numpy array of 3 dimensions, (chain, MC iteration, parameter) # %% Read chains chains = np.array([n...
34
121
0.726244
# Compute potential scale reduction factor (Rhat) using rhat function of kanga, which is rhat of arviz # %% Load packages import arviz as az import numpy as np # %% Define function for computing univariate Rhat based on arviz # x is a numpy array of 3 dimensions, (chain, MC iteration, parameter) def uni_arviz_rhat(...
0
0
0
0
0
167
0
-3
45
c4d06705bc583b21e2502fb5ef2e395b64121841
971
py
Python
tests/helpers/information/test_read_hacs_manifest.py
bdraco/integration
b30e799bb27fdd978bd68f21909c82005d0dd3ea
[ "MIT" ]
2
2019-06-18T11:30:53.000Z
2019-10-03T21:34:11.000Z
tests/helpers/information/test_read_hacs_manifest.py
bdraco/integration
b30e799bb27fdd978bd68f21909c82005d0dd3ea
[ "MIT" ]
341
2019-06-18T11:30:55.000Z
2021-07-15T05:38:46.000Z
tests/helpers/information/test_read_hacs_manifest.py
bdraco/integration
b30e799bb27fdd978bd68f21909c82005d0dd3ea
[ "MIT" ]
null
null
null
"""Helpers: Information: read_hacs_manifest.""" # pylint: disable=missing-docstring
27.742857
83
0.727085
"""Helpers: Information: read_hacs_manifest.""" import json # pylint: disable=missing-docstring import os from custom_components.hacs.helpers.functions.information import read_hacs_manifest from custom_components.hacs.share import get_hacs def temp_cleanup(tmpdir): hacsdir = f"{tmpdir.dirname}/custom_components...
0
0
0
0
0
681
0
68
135
a28a414297ec2f20a9b5a310b17760682c11db49
1,573
py
Python
ctf/pieces.py
documentedai/capture-the-flag
4dbfba094f2a56a6b581098b603fe49a4515efb6
[ "BSD-3-Clause" ]
null
null
null
ctf/pieces.py
documentedai/capture-the-flag
4dbfba094f2a56a6b581098b603fe49a4515efb6
[ "BSD-3-Clause" ]
3
2020-04-22T01:12:06.000Z
2020-04-26T17:59:11.000Z
ctf/pieces.py
documentedai/capture-the-flag
4dbfba094f2a56a6b581098b603fe49a4515efb6
[ "BSD-3-Clause" ]
null
null
null
"""Pieces used in Capture The Flag (Ctf) game."""
32.770833
77
0.583598
"""Pieces used in Capture The Flag (Ctf) game.""" class Piece(object): def __init__(self, idx, team, position): """This class initializes the storage of standard attributes, shared amongst the other pieces. Args: idx (:obj:`int`): Index of Piece. team (:obj:`int`): ...
0
0
0
1,452
0
0
0
0
69
2c368ee1137bb051389f24bf90f066aacb7f7eb3
6,202
py
Python
black_box/cem.py
domluna/deep-rl-gym-tutorials
7e6f53fac0cd4eb22f73916f477d43e3b6ef8715
[ "MIT" ]
17
2016-05-29T21:47:22.000Z
2021-02-05T07:51:24.000Z
black_box/cem.py
domluna/deep-rl-gym-tutorials
7e6f53fac0cd4eb22f73916f477d43e3b6ef8715
[ "MIT" ]
null
null
null
black_box/cem.py
domluna/deep-rl-gym-tutorials
7e6f53fac0cd4eb22f73916f477d43e3b6ef8715
[ "MIT" ]
5
2016-05-29T21:46:58.000Z
2019-05-15T07:00:01.000Z
"""The main idea of CE (Cross Entropy) is to maintain a distribution of possible solution, and update this distribution accordingly. Preliminary investigation showed that applicability of CE to RL problems is restricted severly by the phenomenon that the distribution concentrates to a single point too fast. To preven...
37.587879
150
0.666075
"""The main idea of CE (Cross Entropy) is to maintain a distribution of possible solution, and update this distribution accordingly. Preliminary investigation showed that applicability of CE to RL problems is restricted severly by the phenomenon that the distribution concentrates to a single point too fast. To preven...
0
0
0
203
1,727
168
0
0
90
6a1dc6b0666aee9e976d0587cbda3b6fe02edfd5
851
py
Python
avwx_api/views.py
flyinactor91/AVWX-API
2c56cb4c82b0fc6d1644fbd68693476254928d68
[ "MIT" ]
30
2016-12-16T07:26:13.000Z
2019-03-01T07:57:07.000Z
avwx_api/views.py
flyinactor91/AVWX-API
2c56cb4c82b0fc6d1644fbd68693476254928d68
[ "MIT" ]
12
2018-02-18T20:41:39.000Z
2019-04-13T06:10:54.000Z
avwx_api/views.py
flyinactor91/AVWX-API
2c56cb4c82b0fc6d1644fbd68693476254928d68
[ "MIT" ]
12
2018-02-14T08:53:06.000Z
2019-03-31T19:27:58.000Z
""" Michael duPont - michael@mdupont.com avwx_api.views - Routes and views for the Quart application """ # pylint: disable=W0702 # library # module # Static Web Pages # API Routing Errors
19.340909
59
0.66745
""" Michael duPont - michael@mdupont.com avwx_api.views - Routes and views for the Quart application """ # pylint: disable=W0702 # library from quart import Response, jsonify # module from avwx_api import app # Static Web Pages @app.route("/") @app.route("/home") async def home() -> Response: """Returns stati...
0
500
0
0
0
0
0
17
136
d7ef2a582472d8a5f158d57e9f43f8fbb6fa2f14
27,036
py
Python
third_party/ite/cost/base_i.py
gdikov/adversarial-variational-bayes
ebd692c70349f34bcb3a2086269bd814cafce96f
[ "MIT" ]
11
2017-09-25T07:46:43.000Z
2019-12-04T12:02:49.000Z
Foundations_of_Private_Computation/Split_Learning/concepts-definitions-code/ite-repo/ite/cost/base_i.py
gonzalo-munillag/Private_AI_OpenMined
c23da9cc1c914d10646a0c0bc1a2497fe2cbaaca
[ "MIT" ]
null
null
null
Foundations_of_Private_Computation/Split_Learning/concepts-definitions-code/ite-repo/ite/cost/base_i.py
gonzalo-munillag/Private_AI_OpenMined
c23da9cc1c914d10646a0c0bc1a2497fe2cbaaca
[ "MIT" ]
4
2018-04-26T15:08:37.000Z
2019-07-02T14:15:08.000Z
""" Base mutual information estimators. """
33.543424
79
0.544755
""" Base mutual information estimators. """ from numpy import sum, sqrt, isnan, exp, mean, eye, ones, dot, cumsum, \ hstack, newaxis, maximum, prod, abs, arange, log from numpy.linalg import norm from scipy.spatial.distance import pdist, squareform from scipy.special import factorial from scipy.linal...
0
0
0
26,060
0
0
0
518
406
289665ab30341dbcc3ad6785d5d631ee488b154e
2,268
py
Python
Chapter 17/17.3.py
adrian88szymanski/Python_Crash_Course_Eric_Matthes
74e9a627e3e044ea30e4a8579843d95fe8e4fc14
[ "MIT" ]
8
2021-07-21T02:52:49.000Z
2022-02-08T20:47:09.000Z
Chapter 17/17.3.py
barbarian47/Python_Crash_Course_Eric_Matthes
74e9a627e3e044ea30e4a8579843d95fe8e4fc14
[ "MIT" ]
null
null
null
Chapter 17/17.3.py
barbarian47/Python_Crash_Course_Eric_Matthes
74e9a627e3e044ea30e4a8579843d95fe8e4fc14
[ "MIT" ]
7
2021-06-10T12:27:56.000Z
2022-01-29T13:53:15.000Z
#! python3 print("Task 17.3") import requests from plotly import offline def get_response(): """Make an api call, and return the response.""" url = 'https://api.github.com/search/repositories?q=language:python&sort=stars' headers = {'Accept': 'application/vnd.github.v3+json'} r = requests.get(url, he...
29.076923
83
0.588183
#! python3 print("Task 17.3") import requests from plotly.graph_objs import Bar from plotly import offline def get_response(): """Make an api call, and return the response.""" url = 'https://api.github.com/search/repositories?q=language:python&sort=stars' headers = {'Accept': 'application/vnd.github.v3+...
0
0
0
0
0
0
0
12
23
89ed7f78af8281098bbc29e8127e532af7a1d748
124
py
Python
nj/exceptions.py
trstringer/jersey
08daaf84b7367c56a4c86893878cd16ed690ab08
[ "MIT" ]
7
2018-04-15T18:46:30.000Z
2020-10-03T10:50:31.000Z
nj/exceptions.py
trstringer/jersey
08daaf84b7367c56a4c86893878cd16ed690ab08
[ "MIT" ]
3
2018-01-23T13:44:45.000Z
2020-01-03T20:43:22.000Z
nj/exceptions.py
trstringer/jersey
08daaf84b7367c56a4c86893878cd16ed690ab08
[ "MIT" ]
5
2018-04-15T18:57:49.000Z
2021-06-27T11:44:13.000Z
"""Custom exceptions for this package"""
20.666667
42
0.701613
"""Custom exceptions for this package""" class JerseyError(Exception): """Basic exception for this package""" pass
0
0
0
60
0
0
0
0
23
def9b3d01bc3f769f677336481708ac65bc8dffd
1,579
py
Python
Day1-9/6.py
bcongdon/advent_of_code_2018
8f35d93401055d82b305f2887b3a85a67f70c468
[ "MIT" ]
null
null
null
Day1-9/6.py
bcongdon/advent_of_code_2018
8f35d93401055d82b305f2887b3a85a67f70c468
[ "MIT" ]
null
null
null
Day1-9/6.py
bcongdon/advent_of_code_2018
8f35d93401055d82b305f2887b3a85a67f70c468
[ "MIT" ]
null
null
null
# influenced by https://www.reddit.com/r/adventofcode/comments/a3kr4r/2018_day_6_solutions/eb7385m/ if __name__ == "__main__": with open("6.txt") as f: points = f.readlines() points = [tuple(int(i) for i in l.split(",")) for l in points] print("Part 1: {}".format(part1(points))) print("Part...
30.960784
99
0.580747
# influenced by https://www.reddit.com/r/adventofcode/comments/a3kr4r/2018_day_6_solutions/eb7385m/ import itertools from collections import defaultdict, Counter def part1(points): max_x, max_y = max(x[0] for x in points), max(x[1] for x in points) grid = defaultdict(lambda: -1) for x, y in itertools.pr...
0
0
0
0
0
1,119
0
18
91
fe26a724953a0c5baec9d22e630995498eeb16db
16,332
py
Python
pybnf/parse.py
arakkkkk/PyBNF
2f4cee1dd0b7467f82ca2fd859a10de2ed61df92
[ "BSD-3-Clause" ]
null
null
null
pybnf/parse.py
arakkkkk/PyBNF
2f4cee1dd0b7467f82ca2fd859a10de2ed61df92
[ "BSD-3-Clause" ]
null
null
null
pybnf/parse.py
arakkkkk/PyBNF
2f4cee1dd0b7467f82ca2fd859a10de2ed61df92
[ "BSD-3-Clause" ]
null
null
null
"""Grammar and methods for parsing the configuration file""" from .printing import PybnfError from string import punctuation import logging import re logger = logging.getLogger(__name__) numkeys_int = ['verbosity', 'parallel_count', 'delete_old_files', 'population_size', 'smoothing', 'max_iterati...
47.476744
125
0.541207
"""Grammar and methods for parsing the configuration file""" from .printing import PybnfError, print1 from .config import Configuration from string import punctuation import logging import pyparsing as pp import re logger = logging.getLogger(__name__) numkeys_int = ['verbosity', 'parallel_count', 'delete_old_fi...
0
0
0
0
0
11,893
0
21
136
771da24f5050ff10192faea4365fa098041b5d2b
8,358
py
Python
baseball.py
jason-sa/baseball_lin_regression
936535693f00b28d17b2b901144dcba8bce45ab9
[ "MIT" ]
null
null
null
baseball.py
jason-sa/baseball_lin_regression
936535693f00b28d17b2b901144dcba8bce45ab9
[ "MIT" ]
null
null
null
baseball.py
jason-sa/baseball_lin_regression
936535693f00b28d17b2b901144dcba8bce45ab9
[ "MIT" ]
null
null
null
import numpy as np import pandas as pd from bs4 import BeautifulSoup import time import re from sklearn.linear_model import LinearRegression from sklearn.linear_model import LassoCV from sklearn.pipeline import make_pipeline from sklearn.preprocessing import PolynomialFeatures from sklearn.preprocessing import Standard...
37.3125
157
0.686169
import numpy as np import pandas as pd from bs4 import BeautifulSoup from selenium import webdriver from selenium.webdriver.common.keys import Keys import requests import time import os from selenium.webdriver.common.by import By import re import time from sklearn.linear_model import LinearRegression from sklearn.model...
0
0
0
0
0
0
0
158
264
9fd68fa00d2ede88bbdff5ff4167ef2f9ac066c1
4,387
py
Python
utils/feature_desc.py
Hzfinfdu/DataLab
0da0226866f59ed2e535c346833f0797499b5174
[ "Apache-2.0" ]
null
null
null
utils/feature_desc.py
Hzfinfdu/DataLab
0da0226866f59ed2e535c346833f0797499b5174
[ "Apache-2.0" ]
null
null
null
utils/feature_desc.py
Hzfinfdu/DataLab
0da0226866f59ed2e535c346833f0797499b5174
[ "Apache-2.0" ]
null
null
null
feature_map_basic = { "avg_length":"the average length", "avg_basic_words":"the ratio of basic words (pre-defied by a dictionary)", "avg_lexical_richness":"the lexical diversity", "avg_gender_bias_word_male":"the average ratio of male words", "avg_gender_bias_word_female":"the average ratio of fe...
49.292135
175
0.714611
import sys feature_map_basic = { "avg_length":"the average length", "avg_basic_words":"the ratio of basic words (pre-defied by a dictionary)", "avg_lexical_richness":"the lexical diversity", "avg_gender_bias_word_male":"the average ratio of male words", "avg_gender_bias_word_female":"the average ...
0
0
0
0
0
1,717
0
-11
45
f533df67d3a04bbd440edb67989f011161b292e5
584
py
Python
filedemo.py
evertmulder/Aan-de-slag-met-Python
414bc12e5bca56d99ffedc46ada81bd44bc75ac5
[ "MIT" ]
null
null
null
filedemo.py
evertmulder/Aan-de-slag-met-Python
414bc12e5bca56d99ffedc46ada81bd44bc75ac5
[ "MIT" ]
null
null
null
filedemo.py
evertmulder/Aan-de-slag-met-Python
414bc12e5bca56d99ffedc46ada81bd44bc75ac5
[ "MIT" ]
null
null
null
fileName = 'test.txt' linebreak = '\n' items = [['a,99,22'], ['b,34,dd'], ['c,5,21']] writeItemsToFile(items) items = getItemsFromFile() print(items)
18.83871
57
0.642123
fileName = 'test.txt' linebreak = '\n' def getItemsFromFile(): try: file = open(fileName,"r") except: return [] listOfItems = [] for item in file: listOfItems.append(item.strip(linebreak).split(', ')) file.close() return listOfItems def writeItemsToFile(listOfItems): try: file = open(fi...
0
0
0
0
0
387
0
0
46
20fa375c6b7669cc69f05dbc68d39a9201f664f4
2,045
py
Python
Python3/450.py
rakhi2001/ecom7
73790d44605fbd51e8f7e804b9808e364fcfc680
[ "MIT" ]
854
2018-11-09T08:06:16.000Z
2022-03-31T06:05:53.000Z
Python3/450.py
rakhi2001/ecom7
73790d44605fbd51e8f7e804b9808e364fcfc680
[ "MIT" ]
29
2019-06-02T05:02:25.000Z
2021-11-15T04:09:37.000Z
Python3/450.py
rakhi2001/ecom7
73790d44605fbd51e8f7e804b9808e364fcfc680
[ "MIT" ]
347
2018-12-23T01:57:37.000Z
2022-03-12T14:51:21.000Z
__________________________________________________________________________________________________ sample 56 ms submission # Definition for a binary tree node. # class TreeNode: # def __init__(self, x): # self.val = x # self.left = None # self.right = None ___________________________________...
32.460317
98
0.577995
__________________________________________________________________________________________________ sample 56 ms submission # Definition for a binary tree node. # class TreeNode: # def __init__(self, x): # self.val = x # self.left = None # self.right = None class Solution: def deleteNode...
0
0
0
1,327
0
0
0
0
46
e1782d29f219364bea2d656d4bc1f58100d7018c
5,689
py
Python
IEX_29id/devices/slits.py
ravescovi/macros_29id
c569d4af29644f622a882162b2aa1ca03fb5454c
[ "MIT" ]
null
null
null
IEX_29id/devices/slits.py
ravescovi/macros_29id
c569d4af29644f622a882162b2aa1ca03fb5454c
[ "MIT" ]
null
null
null
IEX_29id/devices/slits.py
ravescovi/macros_29id
c569d4af29644f622a882162b2aa1ca03fb5454c
[ "MIT" ]
1
2021-09-20T21:26:26.000Z
2021-09-20T21:26:26.000Z
# busy_record = Component(EpicsSignalRO, "29idKappa:Kappa_busy", done_value=0,kind='omitted') ## Instantiate pseudo motors slits = _My4Slits("29idb:Slit",name="motors") #--------------------------- Old Functions ----------------------------# # def slit(val): # """ # Sets the exit slits: # ...
29.942105
120
0.587449
from epics import caput, caget from math import inf, nan from IEX_29id.utils.exp import CheckBranch from IEX_29id.utils.misc import read_dict from bluesky import plan_stubs as bps import logging from ophyd import EpicsMotor, EpicsSignal, PVPositionerPC, EpicsSignalRO, Signal from ophyd import Component, Device f...
0
0
0
817
0
0
0
165
272
3a37727f98514ee7c9bc433d59a81158bc9871f0
2,292
py
Python
tests/getnet/services/customers/test_integration.py
rafagonc/getnet-py
d2a5278b497408b5245d5d0fecd2e424f4ddb0d5
[ "MIT" ]
null
null
null
tests/getnet/services/customers/test_integration.py
rafagonc/getnet-py
d2a5278b497408b5245d5d0fecd2e424f4ddb0d5
[ "MIT" ]
null
null
null
tests/getnet/services/customers/test_integration.py
rafagonc/getnet-py
d2a5278b497408b5245d5d0fecd2e424f4ddb0d5
[ "MIT" ]
null
null
null
import unittest if __name__ == "__main__": unittest.main()
32.742857
76
0.687609
import os import unittest from vcr_unittest import VCRTestCase import getnet from getnet import NotFound from getnet.services.base import ResponseList from getnet.services.customers import Service, Customer from tests.getnet.services.customers.test_customer import sample class CustomersIntegrationTest(VCRTestCase):...
0
0
0
1,945
0
0
0
102
179
c197af5016a465d3ef80877ff635bb66841b6040
116
py
Python
src/Metrics/tobetested/memory_total.py
coolmay/hpcpack-acm
8c367148e8e9655a497b9589e9d1050faba02382
[ "MIT" ]
null
null
null
src/Metrics/tobetested/memory_total.py
coolmay/hpcpack-acm
8c367148e8e9655a497b9589e9d1050faba02382
[ "MIT" ]
null
null
null
src/Metrics/tobetested/memory_total.py
coolmay/hpcpack-acm
8c367148e8e9655a497b9589e9d1050faba02382
[ "MIT" ]
null
null
null
import psutil import json mem = psutil.virtual_memory() result = { "_Total": mem.total } print(json.dumps(result))
16.571429
32
0.732759
import psutil import json mem = psutil.virtual_memory() result = { "_Total": mem.total } print(json.dumps(result))
0
0
0
0
0
0
0
0
0
5d843f8c623b2cc6623f676f601598f6e245f5fa
3,962
py
Python
pixelsort/interval.py
HexCodeFFF/pixelsort
2b90d8e1cc937a332cea5b0a59c690e986d58e82
[ "MIT" ]
null
null
null
pixelsort/interval.py
HexCodeFFF/pixelsort
2b90d8e1cc937a332cea5b0a59c690e986d58e82
[ "MIT" ]
null
null
null
pixelsort/interval.py
HexCodeFFF/pixelsort
2b90d8e1cc937a332cea5b0a59c690e986d58e82
[ "MIT" ]
null
null
null
import typing from random import randint, random as random_range from PIL import ImageFilter, Image from pixelsort.sorting import lightness def edge(image: Image.Image, lower_threshold: float, **_) -> typing.List[typing.List[int]]: """Performs an edge detection, which is used to define intervals. Tweak threshol...
31.19685
120
0.595154
import typing from random import randint, random as random_range from PIL import ImageFilter, Image from pixelsort.sorting import lightness def edge(image: Image.Image, lower_threshold: float, **_) -> typing.List[typing.List[int]]: """Performs an edge detection, which is used to define intervals. Tweak threshol...
0
0
0
0
0
0
0
0
0
39675b4eae9bd0f8017c2c07deb058b60fae1c72
8,960
py
Python
popup_field/views.py
spcrxj/django-popup-field
0b9284c039a7c6453a3e0bb877010d67cc3d83dd
[ "BSD-3-Clause" ]
10
2018-09-14T09:49:41.000Z
2021-03-12T19:12:10.000Z
popup_field/views.py
spcrxj/django-popup-field
0b9284c039a7c6453a3e0bb877010d67cc3d83dd
[ "BSD-3-Clause" ]
1
2019-03-11T00:53:24.000Z
2019-03-11T00:53:24.000Z
popup_field/views.py
yinkh/django-popup-field
0b9284c039a7c6453a3e0bb877010d67cc3d83dd
[ "BSD-3-Clause" ]
7
2019-05-02T19:44:51.000Z
2021-06-28T23:31:32.000Z
import django if django.VERSION >= (2, 0): from django.urls import include else:
37.805907
119
0.642076
import django from django.conf import settings from django.utils.decorators import classonlymethod from django.views.generic import CreateView, UpdateView, DeleteView from django.contrib.auth.mixins import PermissionRequiredMixin from django.http.response import JsonResponse from django.template.response import Templat...
9
5,518
0
2,778
0
0
0
277
294
7297dac8ad7e2a204b1900de986dabdeacbb7cbb
458
py
Python
chapter10/10-7.py
alberthao/Python-Crash-Course-Homework
105ffb3075db075425d6cf0d08d9837ef0548866
[ "MIT" ]
138
2019-07-26T13:42:31.000Z
2021-04-13T23:51:49.000Z
chapter10/10-7.py
alberthao/Python-Crash-Course-Homework
105ffb3075db075425d6cf0d08d9837ef0548866
[ "MIT" ]
6
2019-07-20T13:47:47.000Z
2019-08-04T06:49:06.000Z
chapter10/10-7.py
alberthao/Python-Crash-Course-Homework
105ffb3075db075425d6cf0d08d9837ef0548866
[ "MIT" ]
51
2019-07-26T09:46:28.000Z
2021-03-29T07:58:16.000Z
print("Enter 'q' at any time to quit.\n") while True: try: x = input("\nGive me a number: ") if x == 'q': break x = int(x) y = input("Give me another number: ") if y == 'q': break y = int(y) except ValueError: print("Sorry, I r...
20.818182
82
0.434498
print("Enter 'q' at any time to quit.\n") while True: try: x = input("\nGive me a number: ") if x == 'q': break x = int(x) y = input("Give me another number: ") if y == 'q': break y = int(y) except ValueError: print("Sorry, I r...
0
0
0
0
0
0
0
0
0
199819f81209ebbe29e58acb795f12caf099835a
1,402
py
Python
bin/cds-efas.py
fmidev/harvesterseasons-smartmet
2a0538f1d7f95f8085273d4ff93d39066780c2a7
[ "MIT" ]
1
2021-04-09T16:48:26.000Z
2021-04-09T16:48:26.000Z
bin/cds-efas.py
fmidev/harvesterseasons-smartmet
2a0538f1d7f95f8085273d4ff93d39066780c2a7
[ "MIT" ]
null
null
null
bin/cds-efas.py
fmidev/harvesterseasons-smartmet
2a0538f1d7f95f8085273d4ff93d39066780c2a7
[ "MIT" ]
1
2021-07-21T11:27:02.000Z
2021-07-21T11:27:02.000Z
#!/usr/bin/env python3 import sys import cdsapi year= sys.argv[1] month= sys.argv[2] c = cdsapi.Client() c.retrieve( 'efas-historical', { 'format': 'grib', 'origin': 'ecmwf', 'simulation_version': 'version_3_5', 'variable'...
35.948718
77
0.245364
#!/usr/bin/env python3 import sys import cdsapi year= sys.argv[1] month= sys.argv[2] c = cdsapi.Client() c.retrieve( 'efas-historical', { 'format': 'grib', 'origin': 'ecmwf', 'simulation_version': 'version_3_5', 'variable'...
0
0
0
0
0
0
0
0
0
9aeb8240c4110e464b0d04ac28750b16f3b40727
8,197
py
Python
mcpipy/mcpi/block.py
sprintingkiwi/pycraft_mod
a1ce8817ccff3e701aa787a2e531df5a6cc8f887
[ "MIT" ]
15
2017-08-27T15:33:19.000Z
2021-05-05T07:30:57.000Z
pycraft_minetest-0.7/pycraft_minetest/blocklist.py
Lopastudio/complete-builder-for-minetest
23f1bca1f2aa87146c759ad3e8e5b8d62aec57a4
[ "MIT" ]
2
2018-11-30T19:56:02.000Z
2021-09-24T05:20:39.000Z
pycraft_minetest-0.7/pycraft_minetest/blocklist.py
Lopastudio/complete-builder-for-minetest
23f1bca1f2aa87146c759ad3e8e5b8d62aec57a4
[ "MIT" ]
4
2018-05-10T19:37:06.000Z
2019-09-02T19:28:14.000Z
from . import settings AIR = Block(0) STONE = Block(1) GRASS = Block(2) DIRT = Block(3) COBBLESTONE = Block(4) WOOD_PLANKS = Block(5) SAPLING = Block(6) BEDROCK = Block(7) WATER_FLOWING = Block(8) WATER ...
34.012448
86
0.665487
from . import settings class Block: """Minecraft PI block description. Can be sent to Minecraft.setBlock/s""" def __init__(self, id, data=0, nbt=None): self.id = id self.data = data if nbt is not None and len(nbt)==0: self.nbt = None else: self.nbt = nbt ...
0
0
0
1,197
0
0
0
0
23
52878d327589645b14ad5e2436d611def2a25388
2,280
py
Python
docs/code/wk8b.py
bond-lab/Language-and-the-Computer
58d808cdbe6873256f1d0fa091ebc5d909f211bb
[ "CC-BY-4.0" ]
null
null
null
docs/code/wk8b.py
bond-lab/Language-and-the-Computer
58d808cdbe6873256f1d0fa091ebc5d909f211bb
[ "CC-BY-4.0" ]
null
null
null
docs/code/wk8b.py
bond-lab/Language-and-the-Computer
58d808cdbe6873256f1d0fa091ebc5d909f211bb
[ "CC-BY-4.0" ]
null
null
null
#Write a function shorten(text, n) to process a text, # omitting the n most frequently occurring words of the text. # How readable is it? import nltk def shorten(text, n): """Delete the most frequent n words from a text (list of words)""" assert isinstance(text, list), "The text should be a list of words" ...
35.076923
80
0.713596
#Write a function shorten(text, n) to process a text, # omitting the n most frequently occurring words of the text. # How readable is it? import nltk def shorten(text, n): """Delete the most frequent n words from a text (list of words)""" assert isinstance(text, list), "The text should be a list of words" ...
0
0
0
0
0
0
0
0
0
9d85cfeb79dfeff38bfba2d9825cce4992fdc056
8,208
py
Python
database/backends/elastic_database.py
zhouhongf/loader_database
85e3d606d0bd2316eb5ae2c645766b3e5f4a7832
[ "MIT" ]
1
2021-11-27T06:40:43.000Z
2021-11-27T06:40:43.000Z
database/backends/elastic_database.py
zhouhongf/loader_database
85e3d606d0bd2316eb5ae2c645766b3e5f4a7832
[ "MIT" ]
null
null
null
database/backends/elastic_database.py
zhouhongf/loader_database
85e3d606d0bd2316eb5ae2c645766b3e5f4a7832
[ "MIT" ]
null
null
null
from config import Logger log = Logger().logger
37.309091
119
0.510599
import time from config import singleton, Logger from elasticsearch import Elasticsearch from elasticsearch.helpers import bulk from datetime import datetime from numpy import long log = Logger().logger @singleton class ElasticDatabase: def __init__(self): # 无用户名密码状态 # self.es = E...
138
3,778
0
0
0
4,091
0
45
190
82dd314634453ecfc01231902539794f306a6122
1,742
py
Python
arctic/project_template/app/views.py
sanoma/django-arctic
18edd63e46b31ce0492b5991d036df896bd14bc6
[ "MIT" ]
73
2016-08-15T11:37:08.000Z
2020-04-11T14:12:19.000Z
arctic/project_template/app/views.py
sanoma/django-arctic
18edd63e46b31ce0492b5991d036df896bd14bc6
[ "MIT" ]
331
2016-08-16T12:05:04.000Z
2020-04-16T18:39:46.000Z
arctic/project_template/app/views.py
sanoma/django-arctic
18edd63e46b31ce0492b5991d036df896bd14bc6
[ "MIT" ]
26
2016-08-17T12:58:30.000Z
2019-10-16T08:07:41.000Z
from django.urls import reverse, reverse_lazy from django.utils.translation import gettext_lazy as _ from arctic.generics import (CreateView, DeleteView, ListView, UpdateView) from .forms import {{ camel_case_app_name }}Form from .models import {{ camel_case_app_name }} class {{ camel_case_app_name }}ListView(ListV...
28.096774
73
0.639495
from django.urls import reverse, reverse_lazy from django.utils.translation import gettext_lazy as _ from arctic.generics import ( CreateView, DeleteView, ListView, UpdateView, ) from .forms import {{ camel_case_app_name }}Form from .models import {{ camel_case_app_name }} class {{ camel_case_app_na...
0
0
0
0
0
75
0
19
27
9d3749347780f434f22f67fb2805945ba774561c
1,707
py
Python
src/dep/cndict/gen_simp_trad.py
abrookins/RediSearch
773a04106e4f0cfbad3a75a84ce69f3a36fd16e1
[ "Apache-2.0", "Ruby", "BSD-3-Clause", "MIT" ]
2,098
2019-05-13T09:11:54.000Z
2022-03-31T06:24:50.000Z
src/dep/cndict/gen_simp_trad.py
abrookins/RediSearch
773a04106e4f0cfbad3a75a84ce69f3a36fd16e1
[ "Apache-2.0", "Ruby", "BSD-3-Clause", "MIT" ]
1,659
2019-05-13T07:55:29.000Z
2022-03-31T02:42:57.000Z
src/dep/cndict/gen_simp_trad.py
abrookins/RediSearch
773a04106e4f0cfbad3a75a84ce69f3a36fd16e1
[ "Apache-2.0", "Ruby", "BSD-3-Clause", "MIT" ]
227
2019-05-17T07:54:49.000Z
2022-03-28T03:50:19.000Z
#!/usr/bin/env python """ This script takes a JSON dictionary containing traditional chinese characters as keys, and the simplified equivalents as values. It then outputs a header file appropriate for inclusion. The header output file contains an array, `Cn_T2S` which can be used as ``` simpChr = Cn_T2S[tradChr];...
21.3375
80
0.657879
#!/usr/bin/env python """ This script takes a JSON dictionary containing traditional chinese characters as keys, and the simplified equivalents as values. It then outputs a header file appropriate for inclusion. The header output file contains an array, `Cn_T2S` which can be used as ``` simpChr = Cn_T2S[tradChr];...
0
0
0
0
0
0
0
0
0
0a9aafed602e4e30f7389bd6554aa255f58a62e3
5,001
py
Python
src/cm/models/public_ip.py
cc1-cloud/cc1
8113673fa13b6fe195cea99dedab9616aeca3ae8
[ "Apache-2.0" ]
11
2015-05-06T14:16:54.000Z
2022-02-08T23:21:31.000Z
src/cm/models/public_ip.py
fortress-shell/cc1
8113673fa13b6fe195cea99dedab9616aeca3ae8
[ "Apache-2.0" ]
1
2015-10-30T21:08:11.000Z
2015-10-30T21:08:11.000Z
src/cm/models/public_ip.py
fortress-shell/cc1
8113673fa13b6fe195cea99dedab9616aeca3ae8
[ "Apache-2.0" ]
5
2016-02-12T22:01:38.000Z
2021-12-06T16:56:54.000Z
# -*- coding: utf-8 -*- # @COPYRIGHT_begin # # Copyright [2010-2014] Institute of Nuclear Physics PAN, Krakow, Poland # # 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.apac...
38.175573
170
0.530494
# -*- coding: utf-8 -*- # @COPYRIGHT_begin # # Copyright [2010-2014] Institute of Nuclear Physics PAN, Krakow, Poland # # 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.apac...
2
939
0
2,932
0
0
0
27
114
1dccb3f4def3185980f12c8a2b142b665864fb7f
555
py
Python
external_libs/cryptopy/crypto/cipher/aes_cbc.py
rgrr/smartmeshsdk
a95f3e4d9e2254d59d326428fef8c77319cd4373
[ "BSD-3-Clause" ]
29
2015-02-17T14:22:14.000Z
2021-02-19T06:01:10.000Z
external_libs/cryptopy/crypto/cipher/aes_cbc.py
rgrr/smartmeshsdk
a95f3e4d9e2254d59d326428fef8c77319cd4373
[ "BSD-3-Clause" ]
104
2016-04-10T19:22:20.000Z
2018-11-20T15:47:14.000Z
external_libs/cryptopy/crypto/cipher/aes_cbc.py
rgrr/smartmeshsdk
a95f3e4d9e2254d59d326428fef8c77319cd4373
[ "BSD-3-Clause" ]
35
2015-07-10T18:58:15.000Z
2022-03-20T08:56:25.000Z
""" crypto.cipher.aes_cbc AES_CBC Encryption Algorithm Copyright (c) 2002 by Paul A. Lambert Read LICENSE.txt for license information. 2002-06-14 """
26.428571
70
0.695495
""" crypto.cipher.aes_cbc AES_CBC Encryption Algorithm Copyright (c) 2002 by Paul A. Lambert Read LICENSE.txt for license information. 2002-06-14 """ from crypto.cipher.aes import AES from crypto.cipher.cbc import CBC from crypto.cipher.base import BlockCipher, padWithPadLen, noPadding class AES_...
0
0
0
222
0
0
0
73
90
e6e8efd159bb1ab67df8cb926bb72fb6a4a0b0e5
2,484
py
Python
2021/18.py
pubkraal/Advent
286517fe7911490a817adceefc8a84a1032e7bcc
[ "MIT" ]
null
null
null
2021/18.py
pubkraal/Advent
286517fe7911490a817adceefc8a84a1032e7bcc
[ "MIT" ]
null
null
null
2021/18.py
pubkraal/Advent
286517fe7911490a817adceefc8a84a1032e7bcc
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import sys if __name__ == "__main__": test = len(sys.argv) > 1 and sys.argv[1] == "test" main(test)
22.178571
79
0.457327
#!/usr/bin/env python3 import sys import json from util.aoc import file_to_day from util.input import load_data def main(test=False): numbers = [ json.loads(line) for line in load_data(file_to_day(__file__), test) ] p1_res = numbers[0] for num in numbers[1:]: p1_res = add(p1_res, nu...
0
0
0
0
0
2,127
0
12
205
903af003069ad52f30b885bf744257637efbd592
227
py
Python
liveedit/urls.py
jonny5532/wagtail-liveedit
c44d46070891a1c9a4959bc120bf1b74e8f153b6
[ "MIT" ]
null
null
null
liveedit/urls.py
jonny5532/wagtail-liveedit
c44d46070891a1c9a4959bc120bf1b74e8f153b6
[ "MIT" ]
null
null
null
liveedit/urls.py
jonny5532/wagtail-liveedit
c44d46070891a1c9a4959bc120bf1b74e8f153b6
[ "MIT" ]
null
null
null
from django.urls import re_path from . import views urlpatterns = [ re_path(r'^action/', views.action_view), re_path(r'^append-block/', views.append_block_view), re_path(r'^edit-block/', views.edit_block_view), ]
22.7
56
0.709251
from django.urls import re_path from . import views urlpatterns = [ re_path(r'^action/', views.action_view), re_path(r'^append-block/', views.append_block_view), re_path(r'^edit-block/', views.edit_block_view), ]
0
0
0
0
0
0
0
0
0
bc4ad2574746fcb990fe2f5613171952429a286e
9,063
py
Python
src/libtakiyasha/ncm.py
nukemiko/takiyasha
d0e2ebab2a476646313a1fd412f55b9d1300ea87
[ "MIT" ]
15
2022-01-16T16:13:20.000Z
2022-03-27T15:30:51.000Z
src/libtakiyasha/ncm.py
nukemiko/takiyasha
d0e2ebab2a476646313a1fd412f55b9d1300ea87
[ "MIT" ]
null
null
null
src/libtakiyasha/ncm.py
nukemiko/takiyasha
d0e2ebab2a476646313a1fd412f55b9d1300ea87
[ "MIT" ]
2
2022-01-20T18:59:07.000Z
2022-01-26T08:09:15.000Z
from __future__ import annotations __all__ = ['NCM', 'NCMRC4Cipher']
32.956364
138
0.589871
from __future__ import annotations import json from base64 import b64decode, b64encode from copy import deepcopy as dp from io import BytesIO from random import randrange from string import digits as strdigits from typing import Generator, IO from . import utils from .common import Cipher, Crypter from .exceptions im...
1,377
384
0
7,738
0
0
0
120
290
ead8825c7772e8fc261d2f1de80ea3eefc760d6d
759
py
Python
application/configs.py
Jasbeauty/mine_blog
22899be4db20a92ad40cf35f84a3123dd0ebeee6
[ "Apache-2.0" ]
null
null
null
application/configs.py
Jasbeauty/mine_blog
22899be4db20a92ad40cf35f84a3123dd0ebeee6
[ "Apache-2.0" ]
null
null
null
application/configs.py
Jasbeauty/mine_blog
22899be4db20a92ad40cf35f84a3123dd0ebeee6
[ "Apache-2.0" ]
null
null
null
from datetime import timedelta SQLALCHEMY_DATABASE_URI = "mysql+pymysql://root:root@127.0.0.1:3306/mine_blog" SQLALCHEMY_TRACK_MODIFICATIONS = True JWT_SECRET_KEY = 'jwt_secret' JWT_AUTH_URL_RULE = '/api/v1/auth' JWT_EXPIRATION_DELTA = timedelta(seconds=12000) SYS_UPLOAD_PATH = '/home/laowang/gitwarehouse/mine_blog/ap...
36.142857
80
0.73386
from datetime import timedelta SQLALCHEMY_DATABASE_URI = "mysql+pymysql://root:root@127.0.0.1:3306/mine_blog" SQLALCHEMY_TRACK_MODIFICATIONS = True JWT_SECRET_KEY = 'jwt_secret' JWT_AUTH_URL_RULE = '/api/v1/auth' JWT_EXPIRATION_DELTA = timedelta(seconds=12000) SYS_UPLOAD_PATH = '/home/laowang/gitwarehouse/mine_blog/ap...
0
0
0
0
0
0
0
0
0
4f293f13da8b2b212878611a5435d18eee9f1452
387
py
Python
user/migrations/0002_customuser_address.py
Zomba4okk/MailApp
2d5cb4f26e3abe2b8e70f15ead888c502741c90b
[ "MIT" ]
null
null
null
user/migrations/0002_customuser_address.py
Zomba4okk/MailApp
2d5cb4f26e3abe2b8e70f15ead888c502741c90b
[ "MIT" ]
null
null
null
user/migrations/0002_customuser_address.py
Zomba4okk/MailApp
2d5cb4f26e3abe2b8e70f15ead888c502741c90b
[ "MIT" ]
null
null
null
# Generated by Django 3.1.4 on 2020-12-17 12:05
20.368421
62
0.591731
# Generated by Django 3.1.4 on 2020-12-17 12:05 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('user', '0001_initial'), ] operations = [ migrations.AddField( model_name='customuser', name='address', f...
0
0
0
273
0
0
0
19
46
ff0709071d96c95956e90d661b9d512c8f75af12
712
py
Python
Intro CS/Py4e/sum_comments.py
willian-pessoa/My-codes-in-CS-learning-journey
21970780b42435c6be5d5c240b033ff469eaddc5
[ "MIT" ]
null
null
null
Intro CS/Py4e/sum_comments.py
willian-pessoa/My-codes-in-CS-learning-journey
21970780b42435c6be5d5c240b033ff469eaddc5
[ "MIT" ]
null
null
null
Intro CS/Py4e/sum_comments.py
willian-pessoa/My-codes-in-CS-learning-journey
21970780b42435c6be5d5c240b033ff469eaddc5
[ "MIT" ]
null
null
null
# To run this, download the BeautifulSoup zip file # http://www.py4e.com/code3/bs4.zip # and unzip it in the same directory as this file from urllib.request import urlopen from bs4 import BeautifulSoup import ssl # Ignore SSL certificate errors ctx = ssl.create_default_context() ctx.check_hostname = False ...
24.551724
51
0.685393
# To run this, download the BeautifulSoup zip file # http://www.py4e.com/code3/bs4.zip # and unzip it in the same directory as this file from urllib.request import urlopen from bs4 import BeautifulSoup import ssl # Ignore SSL certificate errors ctx = ssl.create_default_context() ctx.check_hostname = False ...
0
0
0
0
0
0
0
0
0
af2dccf910778c1f8687b312a34eabc6f703bd55
328
py
Python
app/config.py
Mehranalam/Emoji
2f6fbc554589f05e599239b48a4ee0ab445071da
[ "MIT" ]
3
2022-01-16T05:08:25.000Z
2022-02-17T07:39:12.000Z
app/config.py
Mehranalam/Emoji
2f6fbc554589f05e599239b48a4ee0ab445071da
[ "MIT" ]
null
null
null
app/config.py
Mehranalam/Emoji
2f6fbc554589f05e599239b48a4ee0ab445071da
[ "MIT" ]
1
2022-01-22T13:17:33.000Z
2022-01-22T13:17:33.000Z
""" Donate to Createor : { just follow me on github and star to this project } """ # complement this fields
16.4
48
0.704268
""" Donate to Createor : { just follow me on github and star to this project } """ class configBot(): GROUP_NAME = "YOUR_GROUP_NAME" SESSION_NAME = "YOUR_SESSION_NAME" API_ID = "YOUR_API_ID" API_HASH = "YOUR_API_HASH" BOT_TOKEN = "BOT_TOKEN" WELCOMING_PASSED = "PASSED_MASSEAGE" # complement this fiel...
0
0
0
180
0
0
0
0
23
b22343d97b25c2391d780a533d3c31468e2929e7
1,973
py
Python
PizzaHat/bot.py
alexyy802/PizzaHat
ab544c9928bebcb3d6fe418c2753edd1d4f4dfc6
[ "Apache-2.0" ]
1
2021-12-06T23:38:26.000Z
2021-12-06T23:38:26.000Z
PizzaHat/bot.py
alexyy802/PizzaHat
ab544c9928bebcb3d6fe418c2753edd1d4f4dfc6
[ "Apache-2.0" ]
null
null
null
PizzaHat/bot.py
alexyy802/PizzaHat
ab544c9928bebcb3d6fe418c2753edd1d4f4dfc6
[ "Apache-2.0" ]
null
null
null
from dotenv import load_dotenv load_dotenv('.env') INITIAL_EXTENSIONS = [ 'cogs.dev', 'cogs.events', 'cogs.fun', 'cogs.games', 'cogs.help', 'cogs.image', 'cogs.mod', 'cogs.utility' ] bot = PizzaHat() if __name__ == '__main__': bot.run()
31.31746
124
0.603649
import discord from discord.ext import commands import asyncpg import datetime from dotenv import load_dotenv import os load_dotenv('.env') INITIAL_EXTENSIONS = [ 'cogs.dev', 'cogs.events', 'cogs.fun', 'cogs.games', 'cogs.help', 'cogs.image', 'cogs.mod', 'cogs.utility'...
0
0
284
1,276
0
0
0
-21
140
b8fa7a10579f9d489fdc7c485b64a1be798e2fae
6,671
py
Python
WaveBlocksND/HagedornBasisEvaluationPhi.py
raoulbq/WaveBlocksND
225b5dd9b1af1998bd40b5f6467ee959292b6a83
[ "BSD-3-Clause" ]
3
2016-09-01T21:13:54.000Z
2020-03-23T15:45:32.000Z
WaveBlocksND/HagedornBasisEvaluationPhi.py
raoulbq/WaveBlocksND
225b5dd9b1af1998bd40b5f6467ee959292b6a83
[ "BSD-3-Clause" ]
null
null
null
WaveBlocksND/HagedornBasisEvaluationPhi.py
raoulbq/WaveBlocksND
225b5dd9b1af1998bd40b5f6467ee959292b6a83
[ "BSD-3-Clause" ]
6
2016-03-16T15:22:01.000Z
2021-03-13T14:06:54.000Z
"""The WaveBlocks Project The basic common algorithms for evaluation Hagedorn basis functions of the old kind. @author: R. Bourquin @copyright: Copyright (C) 2016 R. Bourquin @license: Modified BSD License """ __all__ = ["HagedornBasisEvaluationPhi"]
35.296296
106
0.546695
"""The WaveBlocks Project The basic common algorithms for evaluation Hagedorn basis functions of the old kind. @author: R. Bourquin @copyright: Copyright (C) 2016 R. Bourquin @license: Modified BSD License """ from numpy import complexfloating, dot, vstack, zeros, conjugate from scipy import sqrt from scipy.linalg i...
0
0
0
6,184
0
0
0
119
113
5dfbc25fa139beaf44702988ff3b331c046b4a4f
2,913
py
Python
Pong/pong.py
Grantlee11/PyPong
af5c2cf41b361a9f91b5f3b43fbb5eec9e6a771b
[ "MIT" ]
null
null
null
Pong/pong.py
Grantlee11/PyPong
af5c2cf41b361a9f91b5f3b43fbb5eec9e6a771b
[ "MIT" ]
null
null
null
Pong/pong.py
Grantlee11/PyPong
af5c2cf41b361a9f91b5f3b43fbb5eec9e6a771b
[ "MIT" ]
null
null
null
# Simple PyPong in Python 3 import turtle window = turtle.Screen() window.title("PyPong by Grantlee11") window.bgcolor("black") window.setup(width = 800, height = 600) window.tracer(0) # Score scoreA = 0 scoreB = 0 # Paddle A paddleA = turtle.Turtle() paddleA.speed(0) paddleA.shape("square") paddleA.color("white"...
20.370629
141
0.599725
# Simple PyPong in Python 3 import turtle window = turtle.Screen() window.title("PyPong by Grantlee11") window.bgcolor("black") window.setup(width = 800, height = 600) window.tracer(0) # Score scoreA = 0 scoreB = 0 # Paddle A paddleA = turtle.Turtle() paddleA.speed(0) paddleA.shape("square") paddleA.color("white"...
0
0
0
0
0
338
0
0
91
929bb8c6c049704512bd15ad70f453b83423c37d
2,075
py
Python
examples/moderate/moderate.py
dneural/python-nullnude
1035d1a23d9d6a7a93b9efac4bdc99c13a8b92f4
[ "X11" ]
1
2016-05-31T09:05:38.000Z
2016-05-31T09:05:38.000Z
examples/moderate/moderate.py
dneural/python-nullnude
1035d1a23d9d6a7a93b9efac4bdc99c13a8b92f4
[ "X11" ]
null
null
null
examples/moderate/moderate.py
dneural/python-nullnude
1035d1a23d9d6a7a93b9efac4bdc99c13a8b92f4
[ "X11" ]
null
null
null
#!/usr/bin/env python # -*- encoding: utf-8 -*- # # Copyright (c) 2015, dNeural.com # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rig...
42.346939
98
0.758554
#!/usr/bin/env python # -*- encoding: utf-8 -*- # # Copyright (c) 2015, dNeural.com # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rig...
0
0
0
0
0
0
0
0
0
8c012d95d514c2b11377fbe82f7ae8f1e7c9c04c
15,265
py
Python
DQMOffline/Trigger/python/SusyMonitoring_cff.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
852
2015-01-11T21:03:51.000Z
2022-03-25T21:14:00.000Z
DQMOffline/Trigger/python/SusyMonitoring_cff.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
30,371
2015-01-02T00:14:40.000Z
2022-03-31T23:26:05.000Z
DQMOffline/Trigger/python/SusyMonitoring_cff.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
3,240
2015-01-02T05:53:18.000Z
2022-03-31T17:24:21.000Z
import FWCore.ParameterSet.Config as cms from DQMOffline.Trigger.TopMonitor_cfi import hltTOPmonitoring # muon double_soft_muon_muonpt = hltTOPmonitoring.clone() double_soft_muon_muonpt.FolderName = cms.string('HLT/SUSY/SOS/Muon/') # Selections double_soft_muon_muonpt.nmuons = cms.uint32(2) double_soft_muo...
57.387218
468
0.797707
import FWCore.ParameterSet.Config as cms from DQMOffline.Trigger.RazorMonitor_cff import * from DQMOffline.Trigger.VBFSUSYMonitor_cff import * from DQMOffline.Trigger.LepHTMonitor_cff import * from DQMOffline.Trigger.susyHLTEleCaloJets_cff import * from DQMOffline.Trigger.SoftMuHardJetMETSUSYMonitor_cff import * from ...
0
0
0
0
0
0
0
163
111
71bd3b77d216fb6bd6e19a6e951bade7f6e13e2c
7,401
py
Python
prototype/src/frontend/app.py
nmilovanovic/rep
70a7853f54250d26eb14be86643c3b3d5ed233c4
[ "MIT" ]
null
null
null
prototype/src/frontend/app.py
nmilovanovic/rep
70a7853f54250d26eb14be86643c3b3d5ed233c4
[ "MIT" ]
null
null
null
prototype/src/frontend/app.py
nmilovanovic/rep
70a7853f54250d26eb14be86643c3b3d5ed233c4
[ "MIT" ]
null
null
null
from flask import Flask from prometheus_client import Counter, start_http_server import os app = Flask(__name__) app.config["DEBUG"] = False REQUESTS = Counter('http_requests_total', 'Total number of requests to this API.') PICTURES_CONN_STRING = os.environ['PICTURES'] SPECS_CONN_STRING = os.environ['SPECS'] CART_CO...
38.149485
124
0.706391
from flask import Flask, redirect, url_for, request, render_template, make_response, session, send_from_directory, send_file import uuid import datetime import io import grpc import prototype_pb2_grpc import prototype_pb2 import base64 import json from prometheus_client import Counter, start_http_server import os app ...
0
6,318
0
0
0
0
0
48
430
dc56af512a538f9b748aec086cc85450f71fbc47
794
py
Python
modules/help.py
cernymichal/go2
82869e12a4fed4f9a61b55b81b3453a14fa42d5d
[ "Unlicense" ]
null
null
null
modules/help.py
cernymichal/go2
82869e12a4fed4f9a61b55b81b3453a14fa42d5d
[ "Unlicense" ]
null
null
null
modules/help.py
cernymichal/go2
82869e12a4fed4f9a61b55b81b3453a14fa42d5d
[ "Unlicense" ]
null
null
null
name = "Help" description = """ Module for displaying help modules: prints all modules help *module*: prints help for a Module """ metadata = {} functions = { "modules": Modules, "help": Help }
20.358974
87
0.671285
import asyncio import json import os from threading import Timer name = "Help" description = """ Module for displaying help modules: prints all modules help *module*: prints help for a Module """ metadata = {} async def OnReady(client, modules): global metadata for module in modules: key = module.n...
0
0
450
0
0
0
0
-23
157
31ff2f7c4e2d996eca1f2ec08a6bd9a3b13e6416
152
py
Python
fiaas_deploy_daemon/fake_consumer/fake_consumer.py
j-boivie/fiaas-deploy-daemon
3bba04b3b329f4c9c1418d80a9a007e8ed22f804
[ "Apache-2.0" ]
null
null
null
fiaas_deploy_daemon/fake_consumer/fake_consumer.py
j-boivie/fiaas-deploy-daemon
3bba04b3b329f4c9c1418d80a9a007e8ed22f804
[ "Apache-2.0" ]
null
null
null
fiaas_deploy_daemon/fake_consumer/fake_consumer.py
j-boivie/fiaas-deploy-daemon
3bba04b3b329f4c9c1418d80a9a007e8ed22f804
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8
12.666667
27
0.585526
#!/usr/bin/env python # -*- coding: utf-8 class FakeConsumer(object): def start(self): pass def is_alive(self): return True
0
0
0
86
0
0
0
0
23
eec6bebfa984569eb78f8114c1b0fb5d42b088c0
485
py
Python
MahaPolApp/models.py
safir72347/AngularJs-Django-Form-Validation
b86caa4b27e20e3ded90481a9bf256fcdce82a9b
[ "MIT" ]
null
null
null
MahaPolApp/models.py
safir72347/AngularJs-Django-Form-Validation
b86caa4b27e20e3ded90481a9bf256fcdce82a9b
[ "MIT" ]
null
null
null
MahaPolApp/models.py
safir72347/AngularJs-Django-Form-Validation
b86caa4b27e20e3ded90481a9bf256fcdce82a9b
[ "MIT" ]
1
2021-07-29T17:03:35.000Z
2021-07-29T17:03:35.000Z
# Create your models here.
34.642857
45
0.793814
from django.db import models # Create your models here. class register_data(models.Model): first_name = models.CharField(max_length=30) last_name = models.CharField(max_length=30) dob = models.CharField(max_length=30) mobile = models.CharField(max_length=20) address = models.CharField(max_length=150) user_name ...
0
0
0
406
0
0
0
7
45
6e013e327003dbb74a3af18c948acf50a8373ca5
7,215
py
Python
src/api/datahub/access/tests/modules/access/conftest.py
Chromico/bk-base
be822d9bbee544a958bed4831348185a75604791
[ "MIT" ]
84
2021-06-30T06:20:23.000Z
2022-03-22T03:05:49.000Z
src/api/datahub/access/tests/modules/access/conftest.py
Chromico/bk-base
be822d9bbee544a958bed4831348185a75604791
[ "MIT" ]
7
2021-06-30T06:21:16.000Z
2022-03-29T07:36:13.000Z
src/api/datahub/access/tests/modules/access/conftest.py
Chromico/bk-base
be822d9bbee544a958bed4831348185a75604791
[ "MIT" ]
40
2021-06-30T06:21:26.000Z
2022-03-29T12:42:26.000Z
# -*- coding: utf-8 -*- """ Tencent is pleased to support the open source community by making BK-BASE available. Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved. BK-BASE is licensed under the MIT License. License for BK-BASE : ------------------------------------------------------------...
29.44898
111
0.585031
# -*- coding: utf-8 -*- """ Tencent is pleased to support the open source community by making BK-BASE 蓝鲸基础平台 available. Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved. BK-BASE 蓝鲸基础平台 is licensed under the MIT License. License for BK-BASE 蓝鲸基础平台: ------------------------------------------...
63
5,295
0
0
0
230
0
13
252
184cf49ab5aa52ae09e6f247d56792442b3ec425
1,423
py
Python
GUI Application/main.py
vladBaciu/PPG-EduKit
2959ca884a2df84ea0d9993658c89d7fdc3452e7
[ "BSD-2-Clause" ]
1
2022-03-21T12:53:51.000Z
2022-03-21T12:53:51.000Z
GUI Application/main.py
vladBaciu/PPG-EduKit
2959ca884a2df84ea0d9993658c89d7fdc3452e7
[ "BSD-2-Clause" ]
null
null
null
GUI Application/main.py
vladBaciu/PPG-EduKit
2959ca884a2df84ea0d9993658c89d7fdc3452e7
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Thu Nov 11 17:47:46 2021 @author: vlad-eusebiu.baciu@vub.be """ if __name__ == '__main__': main()
25.410714
106
0.64863
# -*- coding: utf-8 -*- """ Created on Thu Nov 11 17:47:46 2021 @author: vlad-eusebiu.baciu@vub.be """ import pyqtgraph as pg import sys import logo_qrc import ctypes from PyQt5 import QtWidgets, uic from pyqtgraph import PlotWidget from application1 import App1_Gui from application2 import App2_Gui class MainWind...
0
0
0
927
0
99
0
22
232
c0e909dbb046be66edd190e071e7dd8efbfcda7a
858
py
Python
solutions/problem23.py
wy/ProjectEuler
842d45994fe76ef0ea70dbe6b6f2a559078f45f3
[ "Apache-1.1" ]
null
null
null
solutions/problem23.py
wy/ProjectEuler
842d45994fe76ef0ea70dbe6b6f2a559078f45f3
[ "Apache-1.1" ]
null
null
null
solutions/problem23.py
wy/ProjectEuler
842d45994fe76ef0ea70dbe6b6f2a559078f45f3
[ "Apache-1.1" ]
null
null
null
# coding: utf8 # Author: Wing Yung Chan (~wy) # Date: 2017 #non-abundant sums # N is non-abundant if the sum of its proper divisors is <= N # prop(N) = Set{1 <= i < N | N % i == 0} print(problem23())
16.823529
61
0.536131
# coding: utf8 # Author: Wing Yung Chan (~wy) # Date: 2017 #non-abundant sums # N is non-abundant if the sum of its proper divisors is <= N # prop(N) = Set{1 <= i < N | N % i == 0} def properdivisors(N): acc = 0 for i in range(1,N): if N % i == 0: acc = acc + i return acc def abun...
0
0
0
0
0
537
0
0
115