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
ed21c3ef14f32d774ae0d3c108989f13ef7f4f27
2,841
py
Python
tests/unit/protocol/test_line_receiver.py
majacQ/linehaul
7b4a656ce268344b2f98ca71d6f08e18a8b530eb
[ "Apache-2.0" ]
74
2016-07-13T14:53:42.000Z
2022-01-24T12:01:33.000Z
tests/unit/protocol/test_line_receiver.py
majacQ/linehaul
7b4a656ce268344b2f98ca71d6f08e18a8b530eb
[ "Apache-2.0" ]
29
2016-05-04T16:21:29.000Z
2021-11-28T20:22:19.000Z
tests/unit/protocol/test_line_receiver.py
majacQ/linehaul
7b4a656ce268344b2f98ca71d6f08e18a8b530eb
[ "Apache-2.0" ]
33
2016-02-26T20:34:37.000Z
2022-03-21T01:28:21.000Z
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the Li...
31.21978
86
0.724745
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the Li...
0
1,379
0
0
0
0
0
101
138
8f3122484d019cb4320ac4961a6186a8e21ffc50
60,380
py
Python
quicksip.py
ixkael/QuickSip
79c0ed44494b0369d5ca860418538740be471d8a
[ "MIT" ]
5
2018-01-04T21:48:23.000Z
2022-03-29T17:26:57.000Z
quicksip.py
ixkael/QuickSip
79c0ed44494b0369d5ca860418538740be471d8a
[ "MIT" ]
null
null
null
quicksip.py
ixkael/QuickSip
79c0ed44494b0369d5ca860418538740be471d8a
[ "MIT" ]
3
2016-05-20T15:54:06.000Z
2019-05-27T10:28:28.000Z
import numpy as np import pyfits import matplotlib.pyplot as plt import numpy.random import os import astropy.io.fits as pyfits # ---------------------------------------------------------------------------------------- # # Make directory # Some unit definitions arcsec_to_radians = 0.0000048481368111 degree_to_arcse...
45.986291
219
0.593806
import numpy as np import healpy as hp import pyfits from time import time import matplotlib.pyplot as plt from multiprocessing import Pool from multiprocessing.dummy import Pool as ThreadPool import numpy.random import os, errno import subprocess import astropy.wcs import astropy.io.fits as pyfits from astropy.coord...
0
313
0
18,974
0
31,465
0
63
800
45df3ace3bc21da44113d70f868713c25dc2a68a
1,640
py
Python
tests/factories.py
zgrzebnickij/demo-cookiecutter-flask
3031c447dbaa3e819c1638cae79e83ee5869e292
[ "MIT" ]
null
null
null
tests/factories.py
zgrzebnickij/demo-cookiecutter-flask
3031c447dbaa3e819c1638cae79e83ee5869e292
[ "MIT" ]
null
null
null
tests/factories.py
zgrzebnickij/demo-cookiecutter-flask
3031c447dbaa3e819c1638cae79e83ee5869e292
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Factories to help in tests."""
24.477612
66
0.517683
# -*- coding: utf-8 -*- """Factories to help in tests.""" from factory import PostGenerationMethodCall, Sequence from factory.alchemy import SQLAlchemyModelFactory from my_flask_app.database import db from my_flask_app.user.models import User from my_flask_app.quiz.models import Quiz import json class BaseFactory(S...
0
0
0
1,271
0
0
0
107
203
ee79a4c9017765fa43dedc938578b2ccb5c7c300
739
py
Python
fcontroller/FController.py
othercodes/fcontroller-py
de6fb6cdc43abf42a99e4c8c5f3f2b6752acdcf2
[ "MIT" ]
null
null
null
fcontroller/FController.py
othercodes/fcontroller-py
de6fb6cdc43abf42a99e4c8c5f3f2b6752acdcf2
[ "MIT" ]
null
null
null
fcontroller/FController.py
othercodes/fcontroller-py
de6fb6cdc43abf42a99e4c8c5f3f2b6752acdcf2
[ "MIT" ]
null
null
null
#!/usr/bin/env python
29.56
58
0.637348
#!/usr/bin/env python from .Core import Core class FController(Core): def __new__(cls, *parameters): it = cls.__dict__.get("__it__") if it is not None: return it cls.__it__ = it = object.__new__(cls, *parameters) return it def set_module(self, name, module, parame...
0
0
0
669
0
0
0
1
46
ae0df5138202aec6ba9d22ecf0eb7874c420b570
3,292
py
Python
holoai_api/srp.py
arthus-leroy/holoai-api
87656fa3aeda67eaf2bc827600947d60bbe64e8c
[ "MIT" ]
2
2022-01-23T18:43:15.000Z
2022-02-23T00:12:16.000Z
holoai_api/srp.py
arthus-leroy/holoai-api
87656fa3aeda67eaf2bc827600947d60bbe64e8c
[ "MIT" ]
null
null
null
holoai_api/srp.py
arthus-leroy/holoai-api
87656fa3aeda67eaf2bc827600947d60bbe64e8c
[ "MIT" ]
1
2022-02-23T00:12:21.000Z
2022-02-23T00:12:21.000Z
# Port of the tssrp6a library used for authentification # Kudos to Schmitty#5079 for doing a rough translation from Javascript to Python # of the important functions from typing import Tuple N = 217661744586174357731910088918027537819076683742555385111446432246898862353838409572109090130860564015713997172358072665816...
31.961165
621
0.715067
# Port of the tssrp6a library used for authentification # Kudos to Schmitty#5079 for doing a rough translation from Javascript to Python # of the important functions import hashlib import secrets from typing import Tuple N = 21766174458617435773191008891802753781907668374255538511144643224689886235383840957210909013...
0
0
0
0
0
985
0
-14
321
ba16b9b81d6f8104d733661a21c0e5b752273a5a
3,227
py
Python
deep_translator/mymemory.py
nidhaloff/deep_translator
4379cbabd029515ea1cf0a162808c25534822727
[ "MIT" ]
118
2020-06-09T18:41:47.000Z
2020-08-31T13:08:41.000Z
deep_translator/mymemory.py
vshantam/deep-translator
5df969b04ec489f779932ebc0be210db053fe61f
[ "MIT" ]
15
2020-07-26T15:46:02.000Z
2020-08-24T02:56:43.000Z
deep_translator/mymemory.py
vshantam/deep-translator
5df969b04ec489f779932ebc0be210db053fe61f
[ "MIT" ]
14
2020-06-23T10:25:33.000Z
2020-08-25T17:38:48.000Z
""" mymemory translator API """
31.028846
92
0.586303
""" mymemory translator API """ from typing import List, Optional, Union import requests from deep_translator.base import BaseTranslator from deep_translator.constants import BASE_URLS from deep_translator.exceptions import ( RequestError, TooManyRequests, TranslationNotFound, ) from deep_translator.valid...
0
0
0
2,847
0
0
0
190
157
402a84c65ee357bd47e487286cc9ced9143bc0eb
7,264
py
Python
cleartext/models/components.py
cschmidat/cleartext
c99c24792c06aba5b3d3848a4a74768b260188e5
[ "MIT" ]
1
2020-07-09T19:51:18.000Z
2020-07-09T19:51:18.000Z
cleartext/models/components.py
cschmidat/cleartext
c99c24792c06aba5b3d3848a4a74768b260188e5
[ "MIT" ]
null
null
null
cleartext/models/components.py
cschmidat/cleartext
c99c24792c06aba5b3d3848a4a74768b260188e5
[ "MIT" ]
2
2020-06-26T13:55:17.000Z
2020-07-09T19:16:23.000Z
from torch import nn as nn from .. import utils
33.62963
116
0.632847
from typing import Tuple import torch from torch import nn as nn, Tensor from torch.nn.functional import softmax from .. import utils class Encoder(nn.Module): """Encoder module. The encoder represents its inputs using fixed, pre-trained GloVe embeddings, which are passed through a bidirectional GRU. ...
0
0
0
7,056
0
0
0
20
136
b9ea8ac43e49c9dd688a744c46ad303d0fd4f7fe
3,329
py
Python
streamr/util/constant.py
streamr-dev/streamr-client-python
8160df6d58cc124369bc47cf56245c7d17bf662f
[ "Apache-2.0" ]
8
2019-06-13T04:02:55.000Z
2022-02-10T04:33:49.000Z
streamr/util/constant.py
streamr-dev/streamr-client-python
8160df6d58cc124369bc47cf56245c7d17bf662f
[ "Apache-2.0" ]
3
2019-01-17T22:59:01.000Z
2021-11-06T16:49:14.000Z
streamr/util/constant.py
streamr-dev/streamr-client-python
8160df6d58cc124369bc47cf56245c7d17bf662f
[ "Apache-2.0" ]
4
2019-01-27T14:02:07.000Z
2021-11-02T15:08:31.000Z
""" constant """
21.901316
76
0.638931
""" constant """ class Addrs: """ Server address """ WS_ADDR = 'wss://www.streamr.com/api/v1/ws' REST_ADDR = 'https://www.streamr.com/api/v1' class RestfullConstant: """ Restful constants """ GET_SESSION_ADDR = Addrs.REST_ADDR + '/login/apikey' GET_SESSION_PARAS = {"Content-...
0
0
0
3,071
0
0
0
0
230
76de25a81b07e2495e3cea34469601b1b0e6a69c
358
py
Python
myscripts/projects/thesis/bl/coefficients.py
LSaffin/scripts
100fc442229ea11f8766a6d78b4db8790c607326
[ "MIT" ]
1
2020-03-16T13:54:28.000Z
2020-03-16T13:54:28.000Z
myscripts/projects/thesis/bl/coefficients.py
LSaffin/scripts
100fc442229ea11f8766a6d78b4db8790c607326
[ "MIT" ]
null
null
null
myscripts/projects/thesis/bl/coefficients.py
LSaffin/scripts
100fc442229ea11f8766a6d78b4db8790c607326
[ "MIT" ]
1
2021-01-16T04:54:53.000Z
2021-01-16T04:54:53.000Z
import numpy as np import matplotlib.pyplot as plt Ri = np.linspace(0, 0.25, 26) f_long = 1 / (1 + 10 * Ri) f_sharp = (1 - 5 * Ri)**2 f_sharp[11:] = (1 / (20 * Ri[11:]))**2 print(Ri[11]) plt.plot(Ri, f_long, '-g', label='Land') plt.plot(Ri, f_sharp, '-b', label='Sea') plt.xlabel('Ri') plt.ylabel(r'$f(\mathrm{Ri})$...
17.9
40
0.594972
import numpy as np import matplotlib.pyplot as plt Ri = np.linspace(0, 0.25, 26) f_long = 1 / (1 + 10 * Ri) f_sharp = (1 - 5 * Ri)**2 f_sharp[11:] = (1 / (20 * Ri[11:]))**2 print(Ri[11]) plt.plot(Ri, f_long, '-g', label='Land') plt.plot(Ri, f_sharp, '-b', label='Sea') plt.xlabel('Ri') plt.ylabel(r'$f(\mathrm{Ri})$...
0
0
0
0
0
0
0
0
0
8427fd416cd771d612441d24fa475032b4cb61da
4,928
py
Python
tracker/site/views.py
XOyarz/potato-app
845e69da5bf82e2ebacd0d5488f8a3ce7041751d
[ "Apache-2.0" ]
null
null
null
tracker/site/views.py
XOyarz/potato-app
845e69da5bf82e2ebacd0d5488f8a3ce7041751d
[ "Apache-2.0" ]
null
null
null
tracker/site/views.py
XOyarz/potato-app
845e69da5bf82e2ebacd0d5488f8a3ce7041751d
[ "Apache-2.0" ]
null
null
null
from django.contrib.auth.decorators import login_required my_tickets_view = MyTicketsView.as_view() project_list_view = ProjectListView.as_view() create_project_view = login_required(CreateProjectView.as_view()) update_project_view = login_required(UpdateProjectView.as_view()) project_view = ProjectView.a...
29.159763
91
0.680195
from django.core.urlresolvers import reverse from django.contrib.auth.decorators import login_required from django.shortcuts import get_object_or_404 from django.views.generic import TemplateView, CreateView, UpdateView, ListView, DeleteView from .forms import ProjectForm, TicketForm from .models import Project, Ticke...
0
0
0
3,859
0
0
0
153
317
bc92d8c2fdfb8a1d5426d5fa0c0f7470454691f2
614
py
Python
python/string-manipulation/sherlock_and_valid_string.py
anishLearnsToCode/hackerrabk-interview-preparation-kit
9d31eefe336e6dbef104ae78f06dd46686c28f84
[ "MIT" ]
2
2020-06-04T09:48:30.000Z
2021-11-28T15:43:00.000Z
python/string-manipulation/sherlock_and_valid_string.py
anishLearnsToCode/hackerrabk-interview-preparation-kit
9d31eefe336e6dbef104ae78f06dd46686c28f84
[ "MIT" ]
null
null
null
python/string-manipulation/sherlock_and_valid_string.py
anishLearnsToCode/hackerrabk-interview-preparation-kit
9d31eefe336e6dbef104ae78f06dd46686c28f84
[ "MIT" ]
1
2020-11-01T01:03:08.000Z
2020-11-01T01:03:08.000Z
string = input() print('YES' if is_valid(string) else 'NO')
27.909091
106
0.654723
from typing import Dict def get_frequency(iter) -> Dict: frequency = {} for item in iter: frequency[item] = frequency.get(item, 0) + 1 return frequency def is_valid(string: str) -> bool: character_frequency = get_frequency(string) distribution = get_frequency(character_frequency.values()...
0
0
0
0
0
480
0
2
68
a2ecb4cf7e8c3cd52478f1d4f70224ce2ff4d2f0
1,330
py
Python
tools/telemetry/telemetry/core/platform/mac_platform_backend_unittest.py
shaochangbin/chromium-crosswalk
634d34e4cf82b4f7400357c53ec12efaffe94add
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
2
2019-01-16T03:57:28.000Z
2021-01-23T15:29:45.000Z
tools/telemetry/telemetry/core/platform/mac_platform_backend_unittest.py
shaochangbin/chromium-crosswalk
634d34e4cf82b4f7400357c53ec12efaffe94add
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
null
null
null
tools/telemetry/telemetry/core/platform/mac_platform_backend_unittest.py
shaochangbin/chromium-crosswalk
634d34e4cf82b4f7400357c53ec12efaffe94add
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
1
2017-03-15T13:21:38.000Z
2017-03-15T13:21:38.000Z
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file.
39.117647
74
0.745113
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import os import unittest from telemetry import test from telemetry.core.platform import factory from telemetry.core.platform import mac_platform_backend ...
0
377
0
611
0
0
0
44
135
7f731e5244262ef1e82c68a94df4dcd9b97c7cf6
454
py
Python
Pure Storage/s-ListMessagesPurityfbAPIVer.py
adrianojiu/Pub
acd52fa3d56b83d3b93b825edb70c6a13eefadc8
[ "MIT" ]
null
null
null
Pure Storage/s-ListMessagesPurityfbAPIVer.py
adrianojiu/Pub
acd52fa3d56b83d3b93b825edb70c6a13eefadc8
[ "MIT" ]
null
null
null
Pure Storage/s-ListMessagesPurityfbAPIVer.py
adrianojiu/Pub
acd52fa3d56b83d3b93b825edb70c6a13eefadc8
[ "MIT" ]
null
null
null
from purity_fb import PurityFb, VersionResponse, rest # Get Pure API version fb = PurityFb("10.70.100.10") # assume the array IP is 10.255.9.28 fb.disable_verify_ssl() try: # no need to login to get API versions res = fb.api_version.list_versions() assert isinstance(res, VersionResponse) print (res.ve...
32.428571
66
0.687225
from purity_fb import PurityFb, VersionResponse, rest # Get Pure API version fb = PurityFb("10.70.100.10") # assume the array IP is 10.255.9.28 fb.disable_verify_ssl() try: # no need to login to get API versions res = fb.api_version.list_versions() assert isinstance(res, VersionResponse) print (res.ve...
0
0
0
0
0
0
0
0
0
f861ffc4bdb67ede0cc959cdc6e3d355f2c94068
1,568
py
Python
helper_extor.py
gislite/maplet
eb2577eea96775861fd20b949cd4d88cbb6cd7d1
[ "MIT" ]
36
2017-04-04T15:20:33.000Z
2021-06-30T09:37:42.000Z
helper_extor.py
gislite/maplet
eb2577eea96775861fd20b949cd4d88cbb6cd7d1
[ "MIT" ]
null
null
null
helper_extor.py
gislite/maplet
eb2577eea96775861fd20b949cd4d88cbb6cd7d1
[ "MIT" ]
16
2017-02-26T01:01:43.000Z
2021-03-17T07:47:57.000Z
# -*- coding: utf-8 -*- import sys from torcms.model.post_model import MPost def run_update_lon(): ''' :return: ''' map_recs = MPost.query_all(limit_num=5000, kind='2') for map_rec in map_recs: lon = float(map_rec.extinfo['ext_lon']) if lon > -180 and lon < 180: pass ...
24.5
72
0.556122
# -*- coding: utf-8 -*- import getopt import sys from torcms.model.post_model import MPost from torcms.script.script_init_tabels import create_table from torcms_maplet.model.map_tab import MabGson, MabPost2Gson, MabLayout def run_init(): create_table(MabGson) create_table(MabLayout) create_table(MabPost2...
69
0
0
0
0
591
0
79
140
31d6463af385801e100dbb33f091e57af971d35f
6,762
py
Python
qiskit/tools/file_io.py
niefermar/CuanticaProgramacion
cf066149b4bd769673e83fd774792e9965e5dbc0
[ "Apache-2.0" ]
null
null
null
qiskit/tools/file_io.py
niefermar/CuanticaProgramacion
cf066149b4bd769673e83fd774792e9965e5dbc0
[ "Apache-2.0" ]
null
null
null
qiskit/tools/file_io.py
niefermar/CuanticaProgramacion
cf066149b4bd769673e83fd774792e9965e5dbc0
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2017, IBM. # # This source code is licensed under the Apache License, Version 2.0 found in # the LICENSE.txt file in the root directory of this source tree. """Utilities for File Input/Output.""" import copy import datetime import json import os import numpy import qiskit from q...
31.305556
79
0.629695
# -*- coding: utf-8 -*- # Copyright 2017, IBM. # # This source code is licensed under the Apache License, Version 2.0 found in # the LICENSE.txt file in the root directory of this source tree. """Utilities for File Input/Output.""" import copy import datetime import json import os import numpy from sympy import Bas...
0
0
0
610
0
0
0
20
67
7883dd6e2c41626aa8891626686c853a1064f8db
7,484
py
Python
Modules/Mods.py
Skk-nsmt/reina
1b658bfcf4ff35a641c7fe9398652aa36b254d3a
[ "WTFPL" ]
null
null
null
Modules/Mods.py
Skk-nsmt/reina
1b658bfcf4ff35a641c7fe9398652aa36b254d3a
[ "WTFPL" ]
13
2020-12-22T04:35:03.000Z
2021-07-07T07:05:53.000Z
Modules/Mods.py
Skk-nsmt/reina
1b658bfcf4ff35a641c7fe9398652aa36b254d3a
[ "WTFPL" ]
1
2022-02-28T21:40:51.000Z
2022-02-28T21:40:51.000Z
import pytz JP_TZ: pytz.UTC = pytz.timezone('Asia/Tokyo') UNIVERSAL_TZ: pytz.UTC = pytz.timezone('UTC') PACIFIC_TZ: pytz.UTC = pytz.timezone('America/Los_Angeles') CENTRAL_TZ: pytz.UTC = pytz.timezone('America/Chicago') EASTERN_TZ: pytz.UTC = pytz.timezone('America/New_York') TIMEZONES = [ ("Japan Time", JP_TZ), ...
46.484472
151
0.581908
import datetime import time import discord import pytz from discord.ext import commands from Modules import CONSTANT from Modules.CONSTANT import SHOWROOM_ALERT_ROLES from Modules.Checks import check_if_bot_spam JP_TZ: pytz.UTC = pytz.timezone('Asia/Tokyo') UNIVERSAL_TZ: pytz.UTC = pytz.timezone('UTC') PACIFIC_TZ: p...
0
6,295
292
165
0
0
0
46
179
642d357bac75cc1eb9c820004d0973372e3ba273
6,499
py
Python
deephistory/deephistory.py
iandees/deep-history-py
63557abb22e90f45876cce3bfd2fd467790a4e17
[ "Apache-2.0" ]
null
null
null
deephistory/deephistory.py
iandees/deep-history-py
63557abb22e90f45876cce3bfd2fd467790a4e17
[ "Apache-2.0" ]
2
2022-02-01T13:59:50.000Z
2022-02-16T22:32:53.000Z
deephistory/deephistory.py
iandees/deep-history-py
63557abb22e90f45876cce3bfd2fd467790a4e17
[ "Apache-2.0" ]
null
null
null
from flask import Blueprint, Flask hist = Blueprint('history', __name__, template_folder='templates', static_folder='static') app = Flask(__name__) API_URL = 'https://api.openstreetmap.org/api/0.6' app.register_blueprint(hist, url_prefix='/history')
26.100402
105
0.616095
import requests from flask import Blueprint, Flask, redirect, render_template, request, url_for from itertools import tee from markupsafe import Markup, escape hist = Blueprint('history', __name__, template_folder='templates', static_folder='static') app = Flask(__name__) API_URL = 'https://api.openstreetmap.org/api/0...
3
3,984
0
91
0
1,637
0
59
457
a67348778b9bd155ed5e1dfc496d5245a4f52aed
1,334
py
Python
load_test/locustfile.py
naveen-marthala/ml-monitoring
dd584e21376d297a298909f689a90a7f0fd6f639
[ "MIT" ]
129
2021-01-03T06:01:35.000Z
2022-03-27T16:26:48.000Z
load_test/locustfile.py
vcl990/ml-monitoring
a41deed41cfdd663aac50d5c6dd7fe0116b4ebce
[ "MIT" ]
5
2021-05-05T13:27:51.000Z
2021-12-06T03:00:54.000Z
load_test/locustfile.py
vcl990/ml-monitoring
a41deed41cfdd663aac50d5c6dd7fe0116b4ebce
[ "MIT" ]
29
2021-01-12T11:02:33.000Z
2022-02-09T15:29:15.000Z
""" Run load tests: locust -f load_test/locustfile.py --host http://127.0.0.1:3000 """ import pandas as pd feature_columns = { "fixed acidity": "fixed_acidity", "volatile acidity": "volatile_acidity", "citric acid": "citric_acid", "residual sugar": "residual_sugar", "chlorides": "chlorides", "...
26.156863
101
0.646177
""" Run load tests: locust -f load_test/locustfile.py --host http://127.0.0.1:3000 """ from locust import HttpUser, task import pandas as pd import random feature_columns = { "fixed acidity": "fixed_acidity", "volatile acidity": "volatile_acidity", "citric acid": "citric_acid", "residual sugar": "res...
0
383
0
14
0
0
0
4
148
e09a5652d18ca8c33bd3596b5553f4c0f5e8e725
8,378
pyde
Python
loesungen_in_python/10-vererbung/aufgabe_W_10_10_webseitengenerator/aufgabe_W_10_10_webseitengenerator.pyde
gtuthey/loesungen
31af695adc6b947cbb84749594bf5469dcb37d52
[ "MIT" ]
11
2019-04-24T07:19:00.000Z
2022-03-12T08:30:12.000Z
loesungen_in_python/10-vererbung/aufgabe_W_10_10_webseitengenerator/aufgabe_W_10_10_webseitengenerator.pyde
gtuthey/loesungen
31af695adc6b947cbb84749594bf5469dcb37d52
[ "MIT" ]
3
2018-04-30T07:12:46.000Z
2022-02-02T09:02:10.000Z
loesungen_in_python/10-vererbung/aufgabe_W_10_10_webseitengenerator/aufgabe_W_10_10_webseitengenerator.pyde
gtuthey/loesungen
31af695adc6b947cbb84749594bf5469dcb37d52
[ "MIT" ]
21
2018-04-04T11:27:11.000Z
2022-03-12T08:30:18.000Z
# Import spezieller Python-Funktionalitten, damit Abstrakte Methoden # definiert werden knnen # Konstanten, mit denen wir die Wetterlage beschreiben SONNE = 0, BEWOELKT = 1 REGEN = 2 # Abstrakte Klasse zur Reprsentation einer Stadt. # Von dieser Klasse kann keine Instanz (= Objekt) erzeugt werden. # ffentliche Kla...
30.915129
69
0.627238
# Import spezieller Python-Funktionalitäten, damit Abstrakte Methoden # definiert werden können from abc import ABCMeta, abstractmethod # Konstanten, mit denen wir die Wetterlage beschreiben SONNE = 0, BEWOELKT = 1 REGEN = 2 # Abstrakte Klasse zur Repräsentation einer Stadt. # Von dieser Klasse kann keine Instanz (= ...
156
90
0
6,731
0
693
0
18
133
3ba473579a2944f028097dc85be27da818363762
20
py
Python
tests/__init__.py
jordeu/itab
e0cf32f011d282678266b542a51665287adf3b56
[ "Apache-2.0" ]
null
null
null
tests/__init__.py
jordeu/itab
e0cf32f011d282678266b542a51665287adf3b56
[ "Apache-2.0" ]
1
2015-05-27T10:43:30.000Z
2015-05-27T10:43:30.000Z
tests/__init__.py
bbglab/itab
e0cf32f011d282678266b542a51665287adf3b56
[ "Apache-2.0" ]
null
null
null
__author__ = 'jdeu'
10
19
0.7
__author__ = 'jdeu'
0
0
0
0
0
0
0
0
0
10ae90393a2f526b224615aaf84977e91b989cc7
496
py
Python
content_sync/signals.py
mitodl/ocw-studio
949f96ec0647064f8d495ebdd22d66eea7d024a5
[ "BSD-3-Clause" ]
2
2020-08-07T15:55:41.000Z
2021-08-16T18:28:09.000Z
content_sync/signals.py
mitodl/ocw-studio
949f96ec0647064f8d495ebdd22d66eea7d024a5
[ "BSD-3-Clause" ]
924
2020-08-10T17:54:19.000Z
2022-03-31T21:15:17.000Z
content_sync/signals.py
mitodl/ocw-studio
949f96ec0647064f8d495ebdd22d66eea7d024a5
[ "BSD-3-Clause" ]
null
null
null
"""Signals for content syncing"""
26.105263
53
0.772177
"""Signals for content syncing""" from django.db.models.signals import post_save from django.dispatch import receiver from content_sync import api from websites.models import WebsiteContent @receiver( post_save, sender=WebsiteContent, dispatch_uid="sync_state_website_content_upsert", ) def upsert_content...
0
281
0
0
0
0
0
68
112
a366831ddbfd855c94eac7c78c5a444dceff462d
6,678
py
Python
ade25/base/imagetool.py
ade25/ade25.base
d30fbdc9e63b66d335b551e54f0261d9d7616f65
[ "MIT" ]
null
null
null
ade25/base/imagetool.py
ade25/ade25.base
d30fbdc9e63b66d335b551e54f0261d9d7616f65
[ "MIT" ]
1
2020-01-08T08:02:07.000Z
2020-01-08T08:02:07.000Z
ade25/base/imagetool.py
ade25/ade25.base
d30fbdc9e63b66d335b551e54f0261d9d7616f65
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Module providing an image scaling factory.""" IMG = 'data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAAAAAQABAAACAkQBADs='
35.521277
79
0.518568
# -*- coding: utf-8 -*- """Module providing an image scaling factory.""" import os import json import six from plone import api from plone.scale.interfaces import IScaledImageQuality from zope.component import getMultiAdapter, queryUtility from zope.globalrequest import getRequest from ade25.base.utils import get_fil...
0
997
0
5,240
0
0
0
86
201
3a5c7c8b417bb6dff2bb0a21ebf5f643b15cb7c8
1,045
py
Python
LeetCode/python/211-240/232-implement-queue-using-stacks/solution.py
shootsoft/practice
49f28c2e0240de61d00e4e0291b3c5edd930e345
[ "Apache-2.0" ]
null
null
null
LeetCode/python/211-240/232-implement-queue-using-stacks/solution.py
shootsoft/practice
49f28c2e0240de61d00e4e0291b3c5edd930e345
[ "Apache-2.0" ]
null
null
null
LeetCode/python/211-240/232-implement-queue-using-stacks/solution.py
shootsoft/practice
49f28c2e0240de61d00e4e0291b3c5edd930e345
[ "Apache-2.0" ]
null
null
null
__author__ = 'yinjun'
18.660714
42
0.478469
__author__ = 'yinjun' class Queue: # initialize your data structure here. def __init__(self): self.s1 = [] self.s2 = [] self.length = 0 # @param x, an integer # @return nothing def push(self, x): self.length +=1 self.s1.append(x) ...
0
0
0
1,000
0
0
0
0
24
b5f7db5a26676c78bcfcd99ed28f46a6fb85d543
200
py
Python
gym_splendor_code/envs/data/files_paths.py
StanczakDominik/gym-splendor
b7d6b0356d96ad1c528371f52412b81687a0ecc6
[ "MIT" ]
1
2020-03-09T18:56:01.000Z
2020-03-09T18:56:01.000Z
gym_splendor_code/envs/data/files_paths.py
StanczakDominik/gym-splendor
b7d6b0356d96ad1c528371f52412b81687a0ecc6
[ "MIT" ]
null
null
null
gym_splendor_code/envs/data/files_paths.py
StanczakDominik/gym-splendor
b7d6b0356d96ad1c528371f52412b81687a0ecc6
[ "MIT" ]
1
2019-10-25T13:09:40.000Z
2019-10-25T13:09:40.000Z
import os DATA_DIR = os.path.dirname(os.path.abspath(__file__)) CARDS_DATABASE_FILE = os.path.join(DATA_DIR, 'database_cards.csv') NOBLES_DATABASE_FILE = os.path.join(DATA_DIR, 'database_nobles.csv')
40
68
0.8
import os DATA_DIR = os.path.dirname(os.path.abspath(__file__)) CARDS_DATABASE_FILE = os.path.join(DATA_DIR, 'database_cards.csv') NOBLES_DATABASE_FILE = os.path.join(DATA_DIR, 'database_nobles.csv')
0
0
0
0
0
0
0
0
0
162d58d9a23046f26a83ea40ba3106d9d514e17e
4,926
py
Python
.github/scripts/github_release.py
ScriptBox99/spiceai
f8aa178fed5cc6d6d9397c123bdc869500c5135b
[ "Apache-2.0" ]
713
2021-09-07T19:57:25.000Z
2022-03-21T02:31:02.000Z
.github/scripts/github_release.py
ScriptBox99/spiceai
f8aa178fed5cc6d6d9397c123bdc869500c5135b
[ "Apache-2.0" ]
133
2021-09-07T17:34:16.000Z
2022-02-27T17:34:31.000Z
.github/scripts/github_release.py
ScriptBox99/spiceai
f8aa178fed5cc6d6d9397c123bdc869500c5135b
[ "Apache-2.0" ]
29
2021-09-07T23:46:20.000Z
2022-02-11T21:11:04.000Z
import os import argparse apiHost = "https://api.github.com" token = os.getenv("GITHUB_TOKEN") if token == None: print("ERROR: Specify GITHUB_TOKEN environment variable") exit(1) authHeader = { "Authorization": f"token {token}"} parser = argparse.ArgumentParser() parser.add_argument('--owner') parser.add_ar...
30.7875
158
0.653674
import os import argparse import requests apiHost = "https://api.github.com" token = os.getenv("GITHUB_TOKEN") if token == None: print("ERROR: Specify GITHUB_TOKEN environment variable") exit(1) authHeader = { "Authorization": f"token {token}"} parser = argparse.ArgumentParser() parser.add_argument('--owner...
0
0
0
0
0
4,098
0
-6
252
c926042a2b6de891b60edfe671027aa4bded1b7f
6,207
py
Python
tworaven_apps/configurations/views.py
TwoRavens/TwoRavens
e5f820557d6646df525ceed15e17d79f4159cf0a
[ "Apache-2.0" ]
20
2017-12-11T07:26:06.000Z
2021-11-22T16:16:20.000Z
tworaven_apps/configurations/views.py
TwoRavens/TwoRavens
e5f820557d6646df525ceed15e17d79f4159cf0a
[ "Apache-2.0" ]
849
2017-10-20T18:21:18.000Z
2022-02-18T02:45:44.000Z
tworaven_apps/configurations/views.py
TwoRavens/TwoRavens
e5f820557d6646df525ceed15e17d79f4159cf0a
[ "Apache-2.0" ]
1
2020-05-18T06:02:13.000Z
2020-05-18T06:02:13.000Z
"""Views for the D3M configuration module""" # Create your views here.
34.483333
78
0.687289
"""Views for the D3M configuration module""" import os import json import mimetypes from django.views.decorators.csrf import csrf_exempt from django.shortcuts import render from django.http import FileResponse from django.http import JsonResponse, HttpResponse, Http404 from tworaven_apps.configurations.models_d3m impor...
0
5,207
0
0
0
0
0
453
471
91e504578c3d63b648925a07e81f014e6b9c84d0
269
py
Python
packages/pyre/units/angle.py
BryanRiel/pyre
179359634a7091979cced427b6133dd0ec4726ea
[ "BSD-3-Clause" ]
null
null
null
packages/pyre/units/angle.py
BryanRiel/pyre
179359634a7091979cced427b6133dd0ec4726ea
[ "BSD-3-Clause" ]
null
null
null
packages/pyre/units/angle.py
BryanRiel/pyre
179359634a7091979cced427b6133dd0ec4726ea
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # # michael a.g. avzis # orthologue # (c) 1998-2018 all rights reserved # from math import pi as from import radian degree = /180 * radian arcminute = degree / 60 arcsecond = arcminute / 60 deg = degree rad = radian # end of file
12.809524
35
0.665428
# -*- coding: utf-8 -*- # # michael a.g. aïvázis # orthologue # (c) 1998-2018 all rights reserved # from math import pi as π from .SI import radian degree = π/180 * radian arcminute = degree / 60 arcsecond = arcminute / 60 deg = degree rad = radian # end of file
8
0
0
0
0
0
0
4
0
275f38da79e64c11bf85acf4e8479021c8c538ac
1,761
py
Python
Basic Programming/cost_of_balloons.py
Rounak259/HackerEarth
fb6f950f0b68f1c4ffab0a0c17b2e693700c4cb0
[ "MIT" ]
null
null
null
Basic Programming/cost_of_balloons.py
Rounak259/HackerEarth
fb6f950f0b68f1c4ffab0a0c17b2e693700c4cb0
[ "MIT" ]
null
null
null
Basic Programming/cost_of_balloons.py
Rounak259/HackerEarth
fb6f950f0b68f1c4ffab0a0c17b2e693700c4cb0
[ "MIT" ]
null
null
null
test_cases = int(input()) for test in range(1,test_cases+1): if test%2==1: green, purple = input().split() green = int(green) purple = int(purple) participants = int(input()) cost = 0 for participant in range(0,participants): m, n = map(int,inp...
30.894737
80
0.439523
test_cases = int(input()) for test in range(1,test_cases+1): if test%2==1: green, purple = input().split() green = int(green) purple = int(purple) participants = int(input()) cost = 0 for participant in range(0,participants): m, n = map(int,inp...
0
0
0
0
0
0
0
0
0
123c02d7662c7348e1d9e02d2bb74a8f32b1da99
2,290
py
Python
models/loss_function.py
lapras-inc/disk-embedding
09b2faaa81f7fc8080a3817961b740232cabe8e4
[ "Apache-2.0" ]
13
2019-06-15T11:49:00.000Z
2022-02-14T23:59:01.000Z
models/loss_function.py
lapras-inc/disk-embedding
09b2faaa81f7fc8080a3817961b740232cabe8e4
[ "Apache-2.0" ]
null
null
null
models/loss_function.py
lapras-inc/disk-embedding
09b2faaa81f7fc8080a3817961b740232cabe8e4
[ "Apache-2.0" ]
5
2019-08-11T22:30:05.000Z
2021-03-18T22:18:02.000Z
_loss_functions = {}
27.926829
91
0.571179
import numpy as np _loss_functions = {} def get_loss_function(name, **kwargs): return _loss_functions[name](**kwargs) def _register_name(name): def _registerer(cls): _loss_functions[name] = cls return cls return _registerer class LossFunctionBase(object): def __init__(self, margin=0):...
0
1,846
0
73
0
168
0
-3
182
ad04e0e1e21e628ae8ad1f1459120bf7aab0288a
2,351
py
Python
corehq/util/tests/test_itertools.py
kkrampa/commcare-hq
d64d7cad98b240325ad669ccc7effb07721b4d44
[ "BSD-3-Clause" ]
1
2020-05-05T13:10:01.000Z
2020-05-05T13:10:01.000Z
corehq/util/tests/test_itertools.py
kkrampa/commcare-hq
d64d7cad98b240325ad669ccc7effb07721b4d44
[ "BSD-3-Clause" ]
1
2019-12-09T14:00:14.000Z
2019-12-09T14:00:14.000Z
corehq/util/tests/test_itertools.py
MaciejChoromanski/commcare-hq
fd7f65362d56d73b75a2c20d2afeabbc70876867
[ "BSD-3-Clause" ]
5
2015-11-30T13:12:45.000Z
2019-07-01T19:27:07.000Z
from __future__ import absolute_import from __future__ import unicode_literals from collections import namedtuple from testil import eq from corehq.util.itertools import zip_with_gaps def test_zip_with_gaps_key_funcs(): """ Specifying a keyfunc should use it to match items """ WithFirstName = namedt...
28.325301
89
0.62484
from __future__ import absolute_import from __future__ import unicode_literals import doctest from collections import namedtuple from testil import eq from corehq.util import itertools from corehq.util.itertools import zip_with_gaps def test_doctests(): results = doctest.testmod(itertools) assert results.f...
0
0
0
0
0
100
0
5
96
1c6e77b189e8f858ca9ecb3bf03e4186fa68a13e
15,178
py
Python
codalab_competition_bundle/AutoDL_starting_kit/AutoDL_ingestion_program/ingestion.py
meta-meta-learning/autodl
11f6b1140cee2f0e5d5c67dfd8667a683bf72e84
[ "Apache-2.0" ]
null
null
null
codalab_competition_bundle/AutoDL_starting_kit/AutoDL_ingestion_program/ingestion.py
meta-meta-learning/autodl
11f6b1140cee2f0e5d5c67dfd8667a683bf72e84
[ "Apache-2.0" ]
null
null
null
codalab_competition_bundle/AutoDL_starting_kit/AutoDL_ingestion_program/ingestion.py
meta-meta-learning/autodl
11f6b1140cee2f0e5d5c67dfd8667a683bf72e84
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # Usage: python ingestion.py input_dir output_dir ingestion_program_dir submission_program_dir # data result ingestion code of participants # AS A PARTICIPANT, DO NOT MODIFY THIS CODE. # # This is the "ingestion program" written by the organ...
42.396648
123
0.647648
#!/usr/bin/env python # Usage: python ingestion.py input_dir output_dir ingestion_program_dir submission_program_dir # data result ingestion code of participants # AS A PARTICIPANT, DO NOT MODIFY THIS CODE. # # This is the "ingestion program" written by the organ...
68
0
0
0
0
84
0
9
98
f4cfddea8a047aab9ba9e0ae9eb73d49258d63cd
6,569
py
Python
system/shhistory.py
Aareon/stash
d2cc8fbe0488db025883fd8e729094fb92f824b9
[ "MIT" ]
null
null
null
system/shhistory.py
Aareon/stash
d2cc8fbe0488db025883fd8e729094fb92f824b9
[ "MIT" ]
1
2021-05-19T00:55:31.000Z
2021-05-19T00:55:31.000Z
system/shhistory.py
Aareon/stash
d2cc8fbe0488db025883fd8e729094fb92f824b9
[ "MIT" ]
null
null
null
#-*- coding: utf-8 -*- """ StaSh input history """ from stash.lib.libslog import slog _pyfile_ = __file__.split("/")[-1] slog(f'pyfile: {_pyfile_}')
30.133028
85
0.542701
#-*- coding: utf-8 -*- """ StaSh input history """ import json from stash.lib.libslog import slog _pyfile_ = __file__.split("/")[-1] slog(f'pyfile: {_pyfile_}') from stash.system.shcommon import ShEventNotFound class ShHistory(object): """ This class is responsible for input history. :param stash: the S...
0
960
0
5,372
0
0
0
18
68
ef3ac15b2c176a3497ff582a262eb531ee8317d7
2,890
py
Python
rubik/index_picker.py
Borsos/rubik
af220a142b81a8f5b5011e4e072be9e3d130e827
[ "Apache-2.0" ]
1
2019-11-13T00:44:09.000Z
2019-11-13T00:44:09.000Z
rubik/index_picker.py
Borsos/rubik
af220a142b81a8f5b5011e4e072be9e3d130e827
[ "Apache-2.0" ]
null
null
null
rubik/index_picker.py
Borsos/rubik
af220a142b81a8f5b5011e4e072be9e3d130e827
[ "Apache-2.0" ]
1
2019-11-13T00:47:16.000Z
2019-11-13T00:47:16.000Z
#!/usr/bin/env python3 # # Copyright 2014 Simone Campagna # # 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 ...
30.421053
78
0.554671
#!/usr/bin/env python3 # # Copyright 2014 Simone Campagna # # 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 ...
0
588
0
1,610
0
0
0
8
46
31e1c8420eb5a4921e67af2b0911a530e41a3f1a
5,165
py
Python
src/kem/newhopenist/upstream/scripts/PQsecurity.py
gabrielgauthier/liboqs-test
1ead2e2b6e89a8dddcdf89393cc00cbbf37a6d23
[ "MIT" ]
null
null
null
src/kem/newhopenist/upstream/scripts/PQsecurity.py
gabrielgauthier/liboqs-test
1ead2e2b6e89a8dddcdf89393cc00cbbf37a6d23
[ "MIT" ]
null
null
null
src/kem/newhopenist/upstream/scripts/PQsecurity.py
gabrielgauthier/liboqs-test
1ead2e2b6e89a8dddcdf89393cc00cbbf37a6d23
[ "MIT" ]
null
null
null
getcontext().prec = 30 log_infinity = 9999 global_log2_eps = 0 ## The root hermite factor delta of BKZ-b ## log_2 of best plausible Quantum Cost of SVP in dimension b ## log_2 of best plausible Quantum Cost of SVP in dimension b ## log_2 of best known Quantum Cost of SVP in dimension b ## Return the cost of t...
30.382353
184
0.658858
from math import * from decimal import * getcontext().prec = 30 log_infinity = 9999 global_log2_eps = 0 ## The root hermite factor delta of BKZ-b def delta_BKZ(b): return ( (pi*b)**(1./b) * b / (2*pi*exp(1)))**(1./(2.*b-2.)) ## log_2 of best plausible Quantum Cost of SVP in dimension b def svp_plausible(b): ret...
0
0
0
0
0
3,605
0
-3
244
cb5ae017ceb6c55016c18af4c146a8c2500de974
6,124
py
Python
participant_data.py
FrancoisNadeau/cimaqprep
df8b60997546cbe563628c27a24fd147ae2ad397
[ "MIT" ]
null
null
null
participant_data.py
FrancoisNadeau/cimaqprep
df8b60997546cbe563628c27a24fd147ae2ad397
[ "MIT" ]
null
null
null
participant_data.py
FrancoisNadeau/cimaqprep
df8b60997546cbe563628c27a24fd147ae2ad397
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 #from nilearn import masking #from nilearn.plotting import plot_stat_map, plot_anat, plot_img, plot_epi #from nilearn.image import concat_imgs, mean_img #from nilearn.input_data import NiftiMasker #from cimaqprep.get_epi_mask_fromdata import get_epi_mask_fromdata #from cimaqprep.resample_fmri_to...
48.220472
108
0.596506
#!/usr/bin/env python3 import nibabel as nib import nilearn #from nilearn import masking #from nilearn.plotting import plot_stat_map, plot_anat, plot_img, plot_epi #from nilearn.image import concat_imgs, mean_img #from nilearn.input_data import NiftiMasker import numpy as np import os from typing import Union import p...
0
0
0
3,664
0
627
0
197
400
99bb7a5d56cf6bb27fe5dc96fc18d5c763afea9b
2,278
py
Python
evaulate_tf.py
RsTaK/saarthi-task
c0653b251afba46b0572bd7a16f5933e07ee2541
[ "MIT" ]
null
null
null
evaulate_tf.py
RsTaK/saarthi-task
c0653b251afba46b0572bd7a16f5933e07ee2541
[ "MIT" ]
null
null
null
evaulate_tf.py
RsTaK/saarthi-task
c0653b251afba46b0572bd7a16f5933e07ee2541
[ "MIT" ]
null
null
null
import pandas as pd from src.tensorflow.model import TfModel from config.tensorflow.text_config import Config from src.pytorch.label_encoding import get_encoding from sklearn.metrics import classification_report from sklearn.metrics import f1_score if __name__=="__main__": target, path=argp() if target != "...
29.973684
109
0.71115
import pickle from numpy.lib.function_base import append import pandas as pd import argparse from torch.utils import data from torch.utils.data import dataset from src.tensorflow.model import TfModel from config.tensorflow.text_config import Config from src.pytorch.label_encoding import get_encoding from src.tensorf...
0
0
0
0
0
944
0
61
225
38a720048d670c13d4523a477856b7bad29e0145
54,711
py
Python
pgpy/packet/packets.py
J08nY/PGPy
934787ae73016ed7204acfe8827a50d1ac06c85a
[ "BSD-3-Clause" ]
null
null
null
pgpy/packet/packets.py
J08nY/PGPy
934787ae73016ed7204acfe8827a50d1ac06c85a
[ "BSD-3-Clause" ]
null
null
null
pgpy/packet/packets.py
J08nY/PGPy
934787ae73016ed7204acfe8827a50d1ac06c85a
[ "BSD-3-Clause" ]
1
2019-02-14T09:54:29.000Z
2019-02-14T09:54:29.000Z
""" packet.py """ __all__ = ['PKESessionKey', 'PKESessionKeyV3', 'Signature', 'SignatureV4', 'SKESessionKey', 'SKESessionKeyV4', 'OnePassSignature', 'OnePassSignatureV3', 'PrivKey', 'PubKey', 'PubKeyV4', ...
34.066625
115
0.662938
""" packet.py """ import abc import binascii import calendar import copy import hashlib import os import re from datetime import datetime import six from cryptography.hazmat.primitives import constant_time from cryptography.hazmat.primitives.asymmetric import padding from .fields import DSAPriv, DSAPub, DSASignatur...
0
7,742
0
44,319
0
0
0
450
1,466
26668799d3ba145f4ec2f782495c153ee9579a32
556
py
Python
chapter07/7.1.2_generate_text.py
Myeonghan-Jeong/Deep-learning-from-scratch2
9a6df82b4e0eef89926e59a175b7b8f83754ba2f
[ "MIT" ]
null
null
null
chapter07/7.1.2_generate_text.py
Myeonghan-Jeong/Deep-learning-from-scratch2
9a6df82b4e0eef89926e59a175b7b8f83754ba2f
[ "MIT" ]
1
2021-08-23T20:42:43.000Z
2021-08-23T20:42:43.000Z
chapter07/7.1.2_generate_text.py
Myeonghan-Jeong/Deep-learning-from-scratch2
9a6df82b4e0eef89926e59a175b7b8f83754ba2f
[ "MIT" ]
2
2019-12-29T08:47:08.000Z
2020-07-18T15:24:09.000Z
from datasets import ptb from rnnlm_gen import RNNLMGen corpus, word_to_id, id_to_word = ptb.load_data('train') vocab_size = len(word_to_id) corpus_size = len(corpus) model = RNNLMGen() # model.load_params('./chapter06/RNNLM.pkl') # set start and skip word start_word = 'you' start_id = word_to_id[start_word] skip_wo...
25.272727
55
0.717626
from datasets import ptb from rnnlm_gen import RNNLMGen corpus, word_to_id, id_to_word = ptb.load_data('train') vocab_size = len(word_to_id) corpus_size = len(corpus) model = RNNLMGen() # model.load_params('./chapter06/RNNLM.pkl') # set start and skip word start_word = 'you' start_id = word_to_id[start_word] skip_wo...
0
0
0
0
0
0
0
0
0
a3e94aaf2ba8b29f18246022b8839532755798d7
399
py
Python
Socket/Socket/udp/udp_unix_server.py
RolandBalabekyan1994/socket-socketserver
94ca247d1aa0e84b970d49b7e974e67932440b11
[ "MIT" ]
null
null
null
Socket/Socket/udp/udp_unix_server.py
RolandBalabekyan1994/socket-socketserver
94ca247d1aa0e84b970d49b7e974e67932440b11
[ "MIT" ]
null
null
null
Socket/Socket/udp/udp_unix_server.py
RolandBalabekyan1994/socket-socketserver
94ca247d1aa0e84b970d49b7e974e67932440b11
[ "MIT" ]
null
null
null
import os import socket unix_sock_name = 'unix.sock' sock = socket.socket(socket.AF_UNIX, socket.SOCK_DGRAM) if os.path.exists(unix_sock_name): os.remove(unix_sock_name) sock.bind(unix_sock_name) while True: try: result = sock.recv(1024) except KeyboardInterrupt: sock.clos...
21
56
0.646617
import os import socket unix_sock_name = 'unix.sock' sock = socket.socket(socket.AF_UNIX, socket.SOCK_DGRAM) if os.path.exists(unix_sock_name): os.remove(unix_sock_name) sock.bind(unix_sock_name) while True: try: result = sock.recv(1024) except KeyboardInterrupt: sock.clos...
0
0
0
0
0
0
0
0
0
404774bf77d62bdadccc27d36999abd6da5f3fcc
1,638
py
Python
src/nlp/classification/tf1/traditional_cls/model.py
wu-uw/OpenCompetition
9aa9d7a50ada1deb653d295dd8a7fe46321b9094
[ "Apache-2.0" ]
15
2019-12-22T14:26:47.000Z
2020-11-02T10:57:37.000Z
src/nlp/classification/tf1/traditional_cls/model.py
GT-JLU/OpenCompetition
5262fc5fa7efd7b483c1dc09cb7747dd75e37175
[ "Apache-2.0" ]
2
2020-02-03T07:10:11.000Z
2020-02-11T16:38:56.000Z
src/nlp/classification/tf1/traditional_cls/model.py
GT-JLU/OpenCompetition
5262fc5fa7efd7b483c1dc09cb7747dd75e37175
[ "Apache-2.0" ]
12
2020-01-06T14:16:52.000Z
2020-05-23T14:12:30.000Z
# -- coding: utf-8 -- # @Time : 2019/7/23 # @Author : lha # @File : main.py import torch.nn as nn
33.428571
117
0.642857
# -- coding: utf-8 -- # @Time : 2019/7/23 # @Author : lha # @File : main.py import os import sys import torch import torch.nn as nn import argparse from crf import CRF from file_utils import TaskModelBase class Bilstm_Crf(TaskModelBase): def __init__(self, args, vocab_size, embed_dim, vec_list, l...
0
0
0
1,392
0
0
0
-25
165
d0109285ff74203e1ac678ac988e931be887496e
5,150
py
Python
example_project/compile_with_cython.py
Yuriy-Leonov/cython_imports_limit_issue
2f9e7c02798fb52185dabfe6ce3811c439ca2839
[ "MIT" ]
null
null
null
example_project/compile_with_cython.py
Yuriy-Leonov/cython_imports_limit_issue
2f9e7c02798fb52185dabfe6ce3811c439ca2839
[ "MIT" ]
null
null
null
example_project/compile_with_cython.py
Yuriy-Leonov/cython_imports_limit_issue
2f9e7c02798fb52185dabfe6ce3811c439ca2839
[ "MIT" ]
null
null
null
"""python compile_with_cython.py build_ext --inplace""" # import setuptools # important import os import multiprocessing sep = os.path.sep DISTRIBUTE_DIR_NAME = "dist" DISTRIBUTE_DIR_PATH = f"..{sep}{DISTRIBUTE_DIR_NAME}" THREADS = multiprocessing.cpu_count() module_directories = [ "some_modules" ] ...
29.261364
78
0.641553
"""python compile_with_cython.py build_ext --inplace""" # import setuptools # important import os from distutils.core import setup from distutils.extension import Extension from Cython.Distutils import build_ext from Cython.Build import cythonize import shutil import multiprocessing sep = os.path.sep DISTRIBUTE_DIR_...
0
0
0
0
0
4,396
0
53
340
3c5db155e6603f36d24ecf906217e6e9f933fa26
1,251
py
Python
Face_detector.py
sm1216/python
ccb78875dcb95cc18bf8d2a66896dedbb0fe7b41
[ "MIT" ]
null
null
null
Face_detector.py
sm1216/python
ccb78875dcb95cc18bf8d2a66896dedbb0fe7b41
[ "MIT" ]
null
null
null
Face_detector.py
sm1216/python
ccb78875dcb95cc18bf8d2a66896dedbb0fe7b41
[ "MIT" ]
null
null
null
#pip install pip install opencv-python import cv2 from random import randrange #load some pretrained data on face frontals from open cv (haar cascade algotithm (git hub opencv the data )) trained_face_data = cv2.CascadeClassifier("haarcascade_frontalface_default.xml") #choose an image to detect faces #img = ...
29.093023
110
0.714628
#pip install pip install opencv-python import cv2 from random import randrange #load some pretrained data on face frontals from open cv (haar cascade algotithm (git hub opencv the data )) trained_face_data = cv2.CascadeClassifier("haarcascade_frontalface_default.xml") #choose an image to detect faces #img = ...
0
0
0
0
0
0
0
0
0
c7dc43aac8dd8cc24847ba1a0567de0c676e9a82
13,711
py
Python
src/OFS/userfolder.py
tseaver/Zope-RFA
08634f39b0f8b56403a2a9daaa6ee4479ef0c625
[ "ZPL-2.1" ]
2
2015-12-21T10:34:56.000Z
2017-09-24T11:07:58.000Z
src/OFS/userfolder.py
MatthewWilkes/Zope
740f934fc9409ae0062e8f0cd6dcfd8b2df00376
[ "ZPL-2.1" ]
null
null
null
src/OFS/userfolder.py
MatthewWilkes/Zope
740f934fc9409ae0062e8f0cd6dcfd8b2df00376
[ "ZPL-2.1" ]
null
null
null
############################################################################## # # Copyright (c) 2002 Zope Foundation and Contributors. # # This software is subject to the provisions of the Zope Public License, # Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. # THIS SOFTWARE IS PROVIDED "AS I...
38.84136
79
0.588651
############################################################################## # # Copyright (c) 2002 Zope Foundation and Contributors. # # This software is subject to the provisions of the Zope Public License, # Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. # THIS SOFTWARE IS PROVIDED "AS I...
0
6,237
0
5,441
0
0
0
338
402
c7db55fcc2e9454e9eb4b3411553c8fe577a71b6
5,969
py
Python
pde/grids/operators/tests/test_cylindrical_operators.py
deephog/py-pde
2b9cf5ecf90d33f484b6f2fb61437199ca66b25c
[ "MIT" ]
null
null
null
pde/grids/operators/tests/test_cylindrical_operators.py
deephog/py-pde
2b9cf5ecf90d33f484b6f2fb61437199ca66b25c
[ "MIT" ]
null
null
null
pde/grids/operators/tests/test_cylindrical_operators.py
deephog/py-pde
2b9cf5ecf90d33f484b6f2fb61437199ca66b25c
[ "MIT" ]
null
null
null
""" .. codeauthor:: David Zwicker <david.zwicker@ds.mpg.de> """ import numpy as np from pde import CartesianGrid, CylindricalGrid, ScalarField, VectorField from pde.grids.operators import cylindrical as ops def test_laplace_cyl(): """ test the implementation of the laplace operator """ for boundary_z in ["p...
40.060403
87
0.611325
""" .. codeauthor:: David Zwicker <david.zwicker@ds.mpg.de> """ import numpy as np from pde import CartesianGrid, CylindricalGrid, ScalarField, VectorField from pde.grids.operators import cylindrical as ops def test_laplace_cyl(): """ test the implementation of the laplace operator """ for boundary_z in ["p...
0
0
0
0
0
0
0
0
0
5fc4d1ed42ff01b57e29a35e30b3ae2d3a42bfc2
4,445
py
Python
myspider/myspider/downloaders/myrequests.py
yanyaming/yxf_myspider_py_scrapy
9c06b8b88b13ca31ecb7f6004b88f7fe5f78eeb4
[ "MIT" ]
2
2019-03-05T01:00:46.000Z
2020-11-18T09:53:47.000Z
myspider/myspider/downloaders/myrequests.py
yanyaming/yxf_myspider_py_scrapy
9c06b8b88b13ca31ecb7f6004b88f7fe5f78eeb4
[ "MIT" ]
null
null
null
myspider/myspider/downloaders/myrequests.py
yanyaming/yxf_myspider_py_scrapy
9c06b8b88b13ca31ecb7f6004b88f7fe5f78eeb4
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import requests ''' scrapycss/js ''' def my_requests_request(method, url, **kwargs): """ :param method: method for the new :class:`Request` object. :param url: URL for the new :class:`Request` object. :param params: (optional) Dictionary or bytes to be s...
44.45
133
0.688639
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import requests ''' 用于替代scrapy原生下载器(过于简陋),在尽量不渲染css/js,不访问附带文件的情况下,高度模拟真实访问,反反爬。 ''' def my_requests_request(method, url, **kwargs): """ :param method: method for the new :class:`Request` object. :param url: URL for the new :class:`Request` object. :para...
144
0
0
2,078
0
0
0
0
23
d9f420b753af169a63dae84b49acfa4284279119
50
py
Python
access/__init__.py
darkismus/kompassi
35dea2c7af2857a69cae5c5982b48f01ba56da1f
[ "CC-BY-3.0" ]
13
2015-11-29T12:19:12.000Z
2021-02-21T15:42:11.000Z
access/__init__.py
darkismus/kompassi
35dea2c7af2857a69cae5c5982b48f01ba56da1f
[ "CC-BY-3.0" ]
23
2015-04-29T19:43:34.000Z
2021-02-10T05:50:17.000Z
access/__init__.py
darkismus/kompassi
35dea2c7af2857a69cae5c5982b48f01ba56da1f
[ "CC-BY-3.0" ]
11
2015-09-20T18:59:00.000Z
2020-02-07T08:47:34.000Z
default_app_config = 'access.apps.AccessAppConfig'
50
50
0.86
default_app_config = 'access.apps.AccessAppConfig'
0
0
0
0
0
0
0
0
0
4a101969796f8f85101b2e165550375c8761f404
12,952
py
Python
src/data_loaders/attribute_annotation_data_loader.py
shigashiyama/seikanlp_sematt
b192c2568dc27cba497245a334baaa175b73270c
[ "MIT" ]
null
null
null
src/data_loaders/attribute_annotation_data_loader.py
shigashiyama/seikanlp_sematt
b192c2568dc27cba497245a334baaa175b73270c
[ "MIT" ]
null
null
null
src/data_loaders/attribute_annotation_data_loader.py
shigashiyama/seikanlp_sematt
b192c2568dc27cba497245a334baaa175b73270c
[ "MIT" ]
null
null
null
DELIM = ',' COLON = ':' COLON_ALT = '^'
37.760933
111
0.555435
import sys import constants, constants_sematt import dictionary from data_loaders import data_loader from data_loaders.data_loader import DataLoader, Data, RestorableData DELIM = ',' COLON = ':' COLON_ALT = '^' class AttributeAnnotationDataLoader(DataLoader): def __init__(self, token_index=1, ...
0
0
0
12,263
0
427
0
61
157
e336b0c302f586aa2073b6bcb9cdfe2b5c14c9ae
1,548
py
Python
entrada.py
thiagosouzalink/Jogo_Adivinhacao-Python
8cc1272f78ca90e2037c39d6ba286dcff83b3fcf
[ "MIT" ]
null
null
null
entrada.py
thiagosouzalink/Jogo_Adivinhacao-Python
8cc1272f78ca90e2037c39d6ba286dcff83b3fcf
[ "MIT" ]
null
null
null
entrada.py
thiagosouzalink/Jogo_Adivinhacao-Python
8cc1272f78ca90e2037c39d6ba286dcff83b3fcf
[ "MIT" ]
null
null
null
""" Pacote de funes Autor: Thiago Souza """ def ler_letra(txt): """ Funo que valida letra digitada pelo usurio. :param txt: Caracter digitado pelo usurio :return: Letra validada corretamente. """ while True: letra = input(txt).strip() if not letra: print("V...
22.434783
74
0.585271
""" Pacote de funções Autor: Thiago Souza """ def ler_letra(txt): """ Função que valida letra digitada pelo usuário. :param txt: Caracter digitado pelo usuário :return: Letra validada corretamente. """ while True: letra = input(txt).strip() if not letra: pr...
40
0
0
0
0
0
0
0
0
6f0aafbad793a54544e32d76badbd0d62477c6ed
514
py
Python
2021/13/day13.py
caryhooper/adventofcode
70d142780a7d8c742c97448fb2287abe735c2f9c
[ "MIT" ]
null
null
null
2021/13/day13.py
caryhooper/adventofcode
70d142780a7d8c742c97448fb2287abe735c2f9c
[ "MIT" ]
null
null
null
2021/13/day13.py
caryhooper/adventofcode
70d142780a7d8c742c97448fb2287abe735c2f9c
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 #Advent of Code Day 13 "Transparent Oragami" import sys sys.path.append("..") import submarine sub = submarine.Submarine() #Part 1 thermal = sub.navigator.thermal_camera file = open('input.txt','r') #Activate camera by feeding input from manual thermal.activate(file.readlines()) #Fold once the...
22.347826
75
0.7607
#!/usr/bin/env python3 #Advent of Code Day 13 "Transparent Oragami" import sys sys.path.append("..") import submarine sub = submarine.Submarine() #Part 1 thermal = sub.navigator.thermal_camera file = open('input.txt','r') #Activate camera by feeding input from manual thermal.activate(file.readlines()) #Fold once the...
0
0
0
0
0
0
0
0
0
aeb18942dff0e7646e277a08051e5b1f9a2eadd8
4,462
py
Python
detoxify/model.py
Borda/detoxify
bb96b78b98285e996392b633d3e682abc2cc7e39
[ "Apache-2.0" ]
7
2021-11-22T20:21:00.000Z
2022-01-03T06:20:25.000Z
detoxify/model.py
Borda/detoxify
bb96b78b98285e996392b633d3e682abc2cc7e39
[ "Apache-2.0" ]
null
null
null
detoxify/model.py
Borda/detoxify
bb96b78b98285e996392b633d3e682abc2cc7e39
[ "Apache-2.0" ]
null
null
null
DOWNLOAD_URL = "https://github.com/unitaryai/detoxify/releases/download/" MODEL_URLS = { "original": DOWNLOAD_URL + "v0.1-alpha/toxic_original-c1212f89.ckpt", "unbiased": DOWNLOAD_URL + "v0.3-alpha/toxic_debiased-c7548aa0.ckpt", "multilingual": DOWNLOAD_URL + "v0.4-alpha/multilingual_debiased-0b549669.ckpt...
37.183333
116
0.679964
import torch import transformers DOWNLOAD_URL = "https://github.com/unitaryai/detoxify/releases/download/" MODEL_URLS = { "original": DOWNLOAD_URL + "v0.1-alpha/toxic_original-c1212f89.ckpt", "unbiased": DOWNLOAD_URL + "v0.3-alpha/toxic_debiased-c7548aa0.ckpt", "multilingual": DOWNLOAD_URL + "v0.4-alpha/mu...
0
514
0
1,456
0
1,739
0
-11
251
97c9a923d0e13d1348154fc6b73527c9f73b1797
143
py
Python
onesignalapi/config/settings.py
alexromer0/onesignal-api
a5fb3acfd2fe81bc70fcf6c7b8a9216f207b409f
[ "MIT" ]
1
2018-08-14T16:32:29.000Z
2018-08-14T16:32:29.000Z
onesignalapi/config/settings.py
alexromer0/onesignal-api
a5fb3acfd2fe81bc70fcf6c7b8a9216f207b409f
[ "MIT" ]
2
2018-11-20T22:38:43.000Z
2018-11-20T22:42:35.000Z
onesignalapi/config/settings.py
alexromer0/onesignal-api
a5fb3acfd2fe81bc70fcf6c7b8a9216f207b409f
[ "MIT" ]
null
null
null
ONESIGNAL_APP_ID = False ONESIGNAL_API_KEY = False ONESIGNAL_BASE_URL = 'https://onesignal.com/api/' ONESIGNAL_VERSION = 'v1' TIMEZONE = 'UTC'
23.833333
49
0.776224
ONESIGNAL_APP_ID = False ONESIGNAL_API_KEY = False ONESIGNAL_BASE_URL = 'https://onesignal.com/api/' ONESIGNAL_VERSION = 'v1' TIMEZONE = 'UTC'
0
0
0
0
0
0
0
0
0
c268536a8b2591b5027d107caca87981be1bf5c2
733
py
Python
public/client/init.py
petrkruntorad/bachelors-thesis-kruntorad
d340e799f5a657fd7092fa4b76984a762681c3bc
[ "MIT" ]
1
2022-03-02T17:38:56.000Z
2022-03-02T17:38:56.000Z
public/client/init.py
petrkruntorad/bachelors-thesis-kruntorad
d340e799f5a657fd7092fa4b76984a762681c3bc
[ "MIT" ]
null
null
null
public/client/init.py
petrkruntorad/bachelors-thesis-kruntorad
d340e799f5a657fd7092fa4b76984a762681c3bc
[ "MIT" ]
null
null
null
import json import logging from functions import setCronJob logging.basicConfig(filename='log.txt', encoding='utf-8', level=logging.ERROR) try: # variable init configFile = open('config.json') sensors = [] writeInterval = None # loads config configData = json.load(configFile) # if write i...
27.148148
78
0.703956
import json import logging from functions import setCronJob logging.basicConfig(filename='log.txt', encoding='utf-8', level=logging.ERROR) try: # variable init configFile = open('config.json') sensors = [] writeInterval = None # loads config configData = json.load(configFile) # if write i...
0
0
0
0
0
0
0
0
0
0461261d17b93eb451030594fc2554e3e299e1f7
17,722
py
Python
src/engine_test.py
mapto/-
532ec719c44eaad405d1bd7b339e92ecbdbe9021
[ "MIT" ]
2
2020-04-02T19:44:12.000Z
2020-04-08T19:18:17.000Z
src/engine_test.py
mapto/-
532ec719c44eaad405d1bd7b339e92ecbdbe9021
[ "MIT" ]
5
2020-04-26T15:36:52.000Z
2020-05-14T19:21:29.000Z
src/engine_test.py
mapto/-
532ec719c44eaad405d1bd7b339e92ecbdbe9021
[ "MIT" ]
2
2020-04-07T18:03:25.000Z
2020-04-21T09:05:34.000Z
#!/usr/bin/env python3 # coding: utf-8
32.818519
89
0.632096
#!/usr/bin/env python3 # coding: utf-8 import pytest # type: ignore from state import Board, Piece, GameState, GameMove from engine import GameEngine, Dice def test_initial_gate_state(monkeypatch): # Given board = Board.create(players=[1, 3]) state = GameState.create(board) # When game = GameEn...
0
0
0
0
0
17,324
0
36
313
94274230307b116cd38973824accfc173644c49f
40,540
py
Python
unanalysed.py
CAST-Extend/com.castsoftware.uc.checkanalysiscompleteness
cdf64262422728e7fc64ac2e5012173d277e0d7a
[ "MIT" ]
1
2017-06-16T12:04:10.000Z
2017-06-16T12:04:10.000Z
unanalysed.py
CAST-Extend/com.castsoftware.uc.checkanalysiscompleteness
cdf64262422728e7fc64ac2e5012173d277e0d7a
[ "MIT" ]
14
2017-02-02T18:13:32.000Z
2021-07-29T10:38:35.000Z
unanalysed.py
CAST-Extend/com.castsoftware.uc.checkanalysiscompleteness
cdf64262422728e7fc64ac2e5012173d277e0d7a
[ "MIT" ]
1
2017-01-31T10:48:19.000Z
2017-01-31T10:48:19.000Z
''' Created on 23 dc. 2015 Take an application and add a worksheet to an excell for unanalyzed files @todo : add also existing analyzer for some languages (name and url) @todo : what to do with project files ? pom, .eclipse, .csproj etc... @author: MRO ''' def generate_report(application, workbook, version=None,...
35.190972
136
0.427134
''' Created on 23 déc. 2015 Take an application and add a worksheet to an excell for unanalyzed files @todo : add also existing analyzer for some languages (name and url) @todo : what to do with project files ? pom, .eclipse, .csproj etc... @author: MRO ''' import os, re, logging import math from sortedcontainers ...
2
0
0
39,634
0
0
0
93
245
7247dd7c684789a49b97c0b21c3bdbfc5281e3f3
176
py
Python
brain.py
codeinvolute/Capoeta
918b133b5014821125a6aad606b3cb377329d6ee
[ "MIT" ]
null
null
null
brain.py
codeinvolute/Capoeta
918b133b5014821125a6aad606b3cb377329d6ee
[ "MIT" ]
null
null
null
brain.py
codeinvolute/Capoeta
918b133b5014821125a6aad606b3cb377329d6ee
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Thu Oct 25 05:23:53 2018 @author: manoj """ heart = {"www.github.com" : {"nothing here":"never here"} }
16
35
0.573864
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Thu Oct 25 05:23:53 2018 @author: manoj """ heart = {"www.github.com" : {"nothing here":"never here"} }
0
0
0
0
0
0
0
0
0
c01c618e04466bd6963b15afbacc7dd8bb0981d2
2,538
py
Python
constants/bezirke.py
WhereIsTheExit/HeinzBot
1e35f1706d03b47dddfa8b8a04cede6a7c4be301
[ "Apache-2.0" ]
6
2019-05-12T13:30:48.000Z
2020-07-30T08:58:10.000Z
constants/bezirke.py
WhereIsTheExit/HeinzBot
1e35f1706d03b47dddfa8b8a04cede6a7c4be301
[ "Apache-2.0" ]
16
2019-05-11T14:07:06.000Z
2021-11-29T22:13:35.000Z
constants/bezirke.py
WhereIsTheExit/HeinzBot
1e35f1706d03b47dddfa8b8a04cede6a7c4be301
[ "Apache-2.0" ]
5
2019-05-11T13:29:47.000Z
2020-01-15T12:18:40.000Z
BEZIRKE = { "AT": "oesterreich", "W": "wien", "B": "burgenland", "SBG": "salzburg", "T": "tirol", "V": "vorarlberg", "KTN": "kaernten", "O": "oberoesterreich", "N": "niederoesterreich", "STMK": "steiermark", "AM": "amstetten", "BN": "baden", "BZ": "bludenz", "BR"...
23.943396
37
0.485422
BEZIRKE = { "AT": "oesterreich", "W": "wien", "B": "burgenland", "SBG": "salzburg", "T": "tirol", "V": "vorarlberg", "KTN": "kaernten", "OÖ": "oberoesterreich", "NÖ": "niederoesterreich", "STMK": "steiermark", "AM": "amstetten", "BN": "baden", "BZ": "bludenz", "B...
4
0
0
0
0
0
0
0
0
164073324857721be8db1d6d9dad7b4f8c194e56
664
py
Python
nngen/verify/__init__.py
m1kit/nngen
c96457aa0f1681a8ba7c12881ea3d455eccffde0
[ "Apache-2.0" ]
7
2020-06-08T13:36:13.000Z
2021-12-24T06:55:30.000Z
nngen/verify/__init__.py
m1kit/nngen
c96457aa0f1681a8ba7c12881ea3d455eccffde0
[ "Apache-2.0" ]
null
null
null
nngen/verify/__init__.py
m1kit/nngen
c96457aa0f1681a8ba7c12881ea3d455eccffde0
[ "Apache-2.0" ]
1
2021-03-12T03:51:56.000Z
2021-03-12T03:51:56.000Z
from __future__ import absolute_import from __future__ import print_function from __future__ import division
33.2
57
0.85241
from __future__ import absolute_import from __future__ import print_function from __future__ import division from .basic import * from .relu import relu, relu6 from .leaky_relu import leaky_relu, get_leaky_relu_op from .matmul import matmul from .conv2d import conv2d from .log_weight_conv2d import log_weight_conv2d fr...
0
0
0
0
0
0
0
224
331
bc6c7c07f9e074cff9fe14167620f50fa7a794bb
531
py
Python
src/ezcode/string/__init__.py
zheng-gao/ez_code
fbf48990291aa57d6436d4548b0a6c25dfb8f82d
[ "MIT" ]
null
null
null
src/ezcode/string/__init__.py
zheng-gao/ez_code
fbf48990291aa57d6436d4548b0a6c25dfb8f82d
[ "MIT" ]
null
null
null
src/ezcode/string/__init__.py
zheng-gao/ez_code
fbf48990291aa57d6436d4548b0a6c25dfb8f82d
[ "MIT" ]
null
null
null
def rotate_char(char: str, rotation_factor: int): """ special characters won't rotate """ if len(char) != 1: raise ValueError(f"Invalid char: \"{char}\"") start, end = "", "" if "0" <= char and char <= "9": start, end = "0", "9" elif "a" <= char and char <= "z": start, end =...
31.235294
101
0.508475
def rotate_char(char: str, rotation_factor: int): """ special characters won't rotate """ if len(char) != 1: raise ValueError(f"Invalid char: \"{char}\"") start, end = "", "" if "0" <= char and char <= "9": start, end = "0", "9" elif "a" <= char and char <= "z": start, end =...
0
0
0
0
0
0
0
0
0
06580a80c33054817fd284c92900b8255e56115c
1,724
py
Python
spider_smooc/spider/parser.py
MisterZhouZhou/pythonLearn
8933c7a6d444d3d86a173984e6cf4c08dbf84039
[ "Apache-2.0" ]
1
2019-07-09T09:59:39.000Z
2019-07-09T09:59:39.000Z
spider_smooc/spider/parser.py
MisterZhouZhou/pythonLearn
8933c7a6d444d3d86a173984e6cf4c08dbf84039
[ "Apache-2.0" ]
null
null
null
spider_smooc/spider/parser.py
MisterZhouZhou/pythonLearn
8933c7a6d444d3d86a173984e6cf4c08dbf84039
[ "Apache-2.0" ]
null
null
null
# coding:utf-8
37.478261
131
0.567285
# coding:utf-8 import re from bs4 import BeautifulSoup from config import DOWNLOAD_URL from entity.fileinfor import FileInfor from spider.downloader import Downloader class Parser(object): ''' html解析器:从中提取出视频信息 ''' def __init__(self): self.res_data = [] # 用来存放视频信息 def parser(self, html_c...
297
0
0
1,435
0
0
0
42
133
f67055f5da53d262c2cb9c3a024880cf87fa3864
2,318
py
Python
setup.py
dimensigon/dimensigon
079d7c91a66e10f13510d89844fbadb27e005b40
[ "Apache-2.0" ]
2
2020-11-20T10:27:14.000Z
2021-02-21T13:57:56.000Z
setup.py
dimensigon/dimensigon
079d7c91a66e10f13510d89844fbadb27e005b40
[ "Apache-2.0" ]
null
null
null
setup.py
dimensigon/dimensigon
079d7c91a66e10f13510d89844fbadb27e005b40
[ "Apache-2.0" ]
null
null
null
from setuptools import setup, find_packages INIT_FILE = 'dimensigon/__init__.py' with open("README.md", "r") as fh: long_description = fh.read() author, email = find_author_email() setup( name='dimensigon', version=find_version(), package_dir={"": "."}, packages=find_packages(where=".", exc...
32.194444
117
0.600518
import re from setuptools import setup, find_packages INIT_FILE = 'dimensigon/__init__.py' with open("README.md", "r") as fh: long_description = fh.read() def find_version(): with open(INIT_FILE) as fp: for line in fp: # __version__ = '0.1.0' match = re.search(r"__version__\...
0
0
0
0
0
1,062
0
-12
114
9f54e11f0ffdeec4083e0d6c2285301556dd85c0
1,716
py
Python
mtda/usb/rpi_gpio.py
LevyForchh/mtda
c5f2255216777287fb453be821e6fb6e1bfdbf8e
[ "MIT" ]
null
null
null
mtda/usb/rpi_gpio.py
LevyForchh/mtda
c5f2255216777287fb453be821e6fb6e1bfdbf8e
[ "MIT" ]
null
null
null
mtda/usb/rpi_gpio.py
LevyForchh/mtda
c5f2255216777287fb453be821e6fb6e1bfdbf8e
[ "MIT" ]
null
null
null
# System imports import RPi.GPIO as GPIO # Local imports
26.8125
72
0.549534
# System imports import abc import RPi.GPIO as GPIO # Local imports from mtda.usb.switch import UsbSwitch class RPiGpioUsbSwitch(UsbSwitch): def __init__(self): self.dev = None self.pin = 0 self.enable = GPIO.HIGH self.disable = GPIO.LOW GPIO.setwarnings(False) ...
0
0
0
1,537
0
26
0
5
90
292d542fb32071bae497c918254f743167f40823
486
py
Python
practice/classes/ex6.py
recursivelycurious/wordnik-repl
9d9e96a8ebc79b95f135d5bc871602b65d2d2b79
[ "MIT" ]
null
null
null
practice/classes/ex6.py
recursivelycurious/wordnik-repl
9d9e96a8ebc79b95f135d5bc871602b65d2d2b79
[ "MIT" ]
8
2017-12-29T21:19:00.000Z
2018-04-01T05:05:05.000Z
practice/classes/ex6.py
recursivelycurious/wordnik-repl
9d9e96a8ebc79b95f135d5bc871602b65d2d2b79
[ "MIT" ]
1
2017-12-27T23:45:58.000Z
2017-12-27T23:45:58.000Z
hippo = Animal("Sally", 22) hippo.description() sloth = Animal("Minnie", 47) ocelot = Animal("Mike", 32) print hippo.health print sloth.health print ocelot.health # member variables are variables that are available to all members of a class (like health)
21.130435
91
0.6893
class Animal(object): """Makes cute animals.""" is_alive = True health = "good" def __init__(self, name, age): self.name = name self.age = age def description(self): print self.name print self.age hippo = Animal("Sally", 22) hippo.description() sloth = Animal("Minnie", 47) ocelot = Anima...
0
0
0
202
0
0
0
0
22
348b5f40d6803019d333e4a0adc0d670258a3517
348
py
Python
src/brands/migrations/0008_auto_20200511_1102.py
Bakhtiyar-Habib/CSE327-Project
4126b40eb398e4cf13b49136e552775c5f3b0635
[ "bzip2-1.0.6" ]
null
null
null
src/brands/migrations/0008_auto_20200511_1102.py
Bakhtiyar-Habib/CSE327-Project
4126b40eb398e4cf13b49136e552775c5f3b0635
[ "bzip2-1.0.6" ]
null
null
null
src/brands/migrations/0008_auto_20200511_1102.py
Bakhtiyar-Habib/CSE327-Project
4126b40eb398e4cf13b49136e552775c5f3b0635
[ "bzip2-1.0.6" ]
null
null
null
# Generated by Django 2.0.7 on 2020-05-11 05:02
19.333333
47
0.614943
# Generated by Django 2.0.7 on 2020-05-11 05:02 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('brands', '0007_auto_20200511_1057'), ] operations = [ migrations.RenameModel( old_name='Levis_brand_detail', new_name='Brand...
0
0
0
242
0
0
0
11
46
3ecd982f4906b77d8ce5569bf9f3ad048233d31e
729
py
Python
skins/alphaflow/af_assign_process.py
gocept/alphaflow
4b797cb12fb52254b1884159fd9a8b899c739f7c
[ "ZPL-2.1", "ZPL-2.0" ]
null
null
null
skins/alphaflow/af_assign_process.py
gocept/alphaflow
4b797cb12fb52254b1884159fd9a8b899c739f7c
[ "ZPL-2.1", "ZPL-2.0" ]
null
null
null
skins/alphaflow/af_assign_process.py
gocept/alphaflow
4b797cb12fb52254b1884159fd9a8b899c739f7c
[ "ZPL-2.1", "ZPL-2.0" ]
1
2021-11-01T07:58:18.000Z
2021-11-01T07:58:18.000Z
##parameters=process_uid # Copyright (c) 2004-2006 gocept gmbh & co. kg # See also LICENSE.txt # af_assign_process.py,v 1.5.6.2 2005/05/02 10:08:52 zagy Exp from Products.CMFCore.utils import getToolByName from Products.Archetypes.config import UID_CATALOG from Products.AlphaFlow.interfaces import ILifeCycleController ...
40.5
75
0.748971
##parameters=process_uid # Copyright (c) 2004-2006 gocept gmbh & co. kg # See also LICENSE.txt # af_assign_process.py,v 1.5.6.2 2005/05/02 10:08:52 zagy Exp from Products.CMFCore.utils import getToolByName from Products.Archetypes.config import UID_CATALOG from Products.AlphaFlow.interfaces import ILifeCycleController ...
0
0
0
0
0
0
0
0
0
1feada181e174b393d109780804b6611169a772d
1,185
py
Python
AlbertUnruhUtils/utils/logger.py
AlbertUnruh/AlbertUnruhUtils.py
33f28752195f4b759d1c97fd49c62eda36adce72
[ "MIT" ]
1
2022-01-29T21:27:13.000Z
2022-01-29T21:27:13.000Z
AlbertUnruhUtils/utils/logger.py
AlbertUnruh/AlbertUnruhUtils.py
33f28752195f4b759d1c97fd49c62eda36adce72
[ "MIT" ]
1
2022-02-01T18:44:13.000Z
2022-02-01T18:44:13.000Z
AlbertUnruhUtils/utils/logger.py
AlbertUnruh/AlbertUnruhUtils.py
33f28752195f4b759d1c97fd49c62eda36adce72
[ "MIT" ]
null
null
null
__all__ = ("get_logger",) import sys import typing from logging import (getLogger, Formatter, StreamHandler) _LOG_LEVEL_STR = typing.Literal[ "CRITICAL", "FATAL", "ERROR", "WARN", "WARNING", "INFO", "DEBUG", "NOTSET", ] _F = "\033[33m{asctime} \t{name: <15} {levelname: <10}\t{message...
20.431034
73
0.612658
__all__ = ("get_logger",) import sys import typing from logging import ( getLogger, Formatter, StreamHandler, ) _LOG_LEVEL_STR = typing.Literal[ "CRITICAL", "FATAL", "ERROR", "WARN", "WARNING", "INFO", "DEBUG", "NOTSET", ] _F = "\033[33m{asctime} \t{name: <15} {levelname:...
0
0
0
0
0
0
0
15
0
4fe040fc7709ef85a097ca7c5e007401b4d116d1
55,436
py
Python
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/network/network_editor.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
4
2020-11-13T02:35:56.000Z
2021-03-29T20:15:54.000Z
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/network/network_editor.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
9
2020-12-09T02:12:39.000Z
2021-02-18T00:15:28.000Z
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/network/network_editor.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
1
2020-11-20T19:31:26.000Z
2020-11-20T19:31:26.000Z
# Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo # Copyright (C) 2016-2020 German Aerospace Center (DLR) and others. # SUMOPy module # Copyright (C) 2012-2017 University of Bologna - DICAM # This program and the accompanying materials are made available under the # terms of the Eclipse Public ...
39.540656
209
0.576196
# Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo # Copyright (C) 2016-2020 German Aerospace Center (DLR) and others. # SUMOPy module # Copyright (C) 2012-2017 University of Bologna - DICAM # This program and the accompanying materials are made available under the # terms of the Eclipse Public ...
0
0
0
52,780
0
148
0
26
412
c370eeeff94edaa16aded9cf5ad8193dddc65920
1,459
py
Python
scripts/convert_nametag.py
Jwink3101/notefile
3ed7b94597ea972f9193d3ef3e9c2dee656a81db
[ "MIT" ]
7
2020-01-05T18:24:32.000Z
2022-03-08T18:04:25.000Z
scripts/convert_nametag.py
Jwink3101/notefile
3ed7b94597ea972f9193d3ef3e9c2dee656a81db
[ "MIT" ]
null
null
null
scripts/convert_nametag.py
Jwink3101/notefile
3ed7b94597ea972f9193d3ef3e9c2dee656a81db
[ "MIT" ]
1
2020-01-05T18:25:23.000Z
2020-01-05T18:25:23.000Z
""" Convert from filename_[tag1,tag2].ext format to notefile """ import os import re import shutil #sys.path.append(os.path.abspath('..')) import notefile print(notefile.__version__) # 20200103 SOURCE = '/full/path/to/source' retags = re.compile('^(.*)[\_|-][\[|\(](.*?)[\]|\)]$') def get_tag(filename): """ ...
20.263889
66
0.516792
""" Convert from filename_[tag1,tag2].ext format to notefile """ import sys import os import re import shutil #sys.path.append(os.path.abspath('..')) import notefile print(notefile.__version__) # 20200103 SOURCE = '/full/path/to/source' retags = re.compile('^(.*)[\_|-][\[|\(](.*?)[\]|\)]$') def get_tag(filename):...
0
0
0
0
0
0
0
-11
23
ed097a275599aae6db09e636b36e79177610a40e
3,018
py
Python
modules/lib/mp_elevation.py
a-wing/mavelous
eef41c096cc282bb3acd33a747146a88d2bd1eee
[ "MIT" ]
80
2015-01-02T23:23:19.000Z
2021-11-02T16:03:07.000Z
modules/lib/mp_elevation.py
Y-H-T/mavelous
eef41c096cc282bb3acd33a747146a88d2bd1eee
[ "MIT" ]
1
2016-04-13T15:44:23.000Z
2016-04-13T15:44:23.000Z
modules/lib/mp_elevation.py
Y-H-T/mavelous
eef41c096cc282bb3acd33a747146a88d2bd1eee
[ "MIT" ]
63
2015-01-03T19:35:39.000Z
2022-02-08T17:15:44.000Z
#!/usr/bin/python ''' Wrapper for the SRTM module (srtm.py) It will grab the altitude of a long,lat pair from the SRTM database Created by Stephen Dade (stephen_dade@hotmail.com) ''' import time if __name__ == "__main__": from optparse import OptionParser parser = OptionParser("mp_elevation.py [options]") ...
36.361446
119
0.616302
#!/usr/bin/python ''' Wrapper for the SRTM module (srtm.py) It will grab the altitude of a long,lat pair from the SRTM database Created by Stephen Dade (stephen_dade@hotmail.com) ''' import numpy, os, time, sys, srtm, GAreader class ElevationModel(): '''Elevation Model. Only SRTM for now''' def __init__(self...
0
0
0
1,544
0
0
0
32
23
991454e6d673baa6abac87ff4870af30f6d9a3fb
1,499
py
Python
stepik_selenium_final/conftest.py
vshagur/stepik-selenium-final
86842dc5c23f87c846a02a3d6f18c89c94935f23
[ "MIT" ]
null
null
null
stepik_selenium_final/conftest.py
vshagur/stepik-selenium-final
86842dc5c23f87c846a02a3d6f18c89c94935f23
[ "MIT" ]
null
null
null
stepik_selenium_final/conftest.py
vshagur/stepik-selenium-final
86842dc5c23f87c846a02a3d6f18c89c94935f23
[ "MIT" ]
1
2020-07-12T11:57:17.000Z
2020-07-12T11:57:17.000Z
BROWSERS_LIST = ("chrome", "firefox") BASE_URL = 'http://selenium1py.pythonanywhere.com/'
27.254545
85
0.661775
import pytest from selenium import webdriver from selenium.webdriver.chrome.options import Options BROWSERS_LIST = ("chrome", "firefox") BASE_URL = 'http://selenium1py.pythonanywhere.com/' def pytest_addoption(parser): parser.addoption( '--browser_name', action='store', default="chrome", ...
0
816
0
0
0
421
0
33
135
cb2b0d243f0e1bb09a45dfd69d785d65afccf59a
2,172
py
Python
CNN_model/train_CNN.py
Tejasteju/Sudoku-Solver
d00e158d9ce7cb07c7059421bd471990352fdaf5
[ "MIT" ]
2
2020-10-06T20:07:17.000Z
2021-08-13T14:15:00.000Z
CNN_model/train_CNN.py
Tejasteju/Sudoku-Solver
d00e158d9ce7cb07c7059421bd471990352fdaf5
[ "MIT" ]
null
null
null
CNN_model/train_CNN.py
Tejasteju/Sudoku-Solver
d00e158d9ce7cb07c7059421bd471990352fdaf5
[ "MIT" ]
null
null
null
## importing the required libraries ## import tensorflow as tf from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Dense, Activation, Flatten, Conv2D, MaxPooling2D import h5py import numpy as np import keras.utils as kut ## get the data set from saved hdf file ## with h5py.File('data.h...
28.96
98
0.72744
## importing the required libraries ## import tensorflow as tf from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Dense, Dropout, Activation, Flatten, Conv2D, MaxPooling2D import h5py import numpy as np import keras.utils as kut import cv2 import matplotlib.pyplot as plt ## get the dat...
0
0
0
0
0
333
0
8
67
76a49ae592bdd7c23027228750cbf03cb5e01b2e
1,957
py
Python
sdk/eventgrid/azure-eventgrid/azure/eventgrid/models/media_live_event_connection_rejected_event_data.py
iscai-msft/azure-sdk-for-python
83715b95c41e519d5be7f1180195e2fba136fc0f
[ "MIT" ]
1
2021-09-07T18:36:04.000Z
2021-09-07T18:36:04.000Z
sdk/eventgrid/azure-eventgrid/azure/eventgrid/models/media_live_event_connection_rejected_event_data.py
iscai-msft/azure-sdk-for-python
83715b95c41e519d5be7f1180195e2fba136fc0f
[ "MIT" ]
226
2019-07-24T07:57:21.000Z
2019-10-15T01:07:24.000Z
sdk/eventgrid/azure-eventgrid/azure/eventgrid/models/media_live_event_connection_rejected_event_data.py
iscai-msft/azure-sdk-for-python
83715b95c41e519d5be7f1180195e2fba136fc0f
[ "MIT" ]
1
2020-07-31T16:33:51.000Z
2020-07-31T16:33:51.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
34.946429
81
0.600409
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
0
0
0
1,420
0
0
0
17
46
61c42051b0f9be215db7243b7aaf4699d6a4cfa4
3,480
py
Python
annotator/stopwords.py
LLCampos/radlex_annotator
dcc6338f7554987b7d2e810dce6dece6cd9b0565
[ "MIT" ]
null
null
null
annotator/stopwords.py
LLCampos/radlex_annotator
dcc6338f7554987b7d2e810dce6dece6cd9b0565
[ "MIT" ]
null
null
null
annotator/stopwords.py
LLCampos/radlex_annotator
dcc6338f7554987b7d2e810dce6dece6cd9b0565
[ "MIT" ]
null
null
null
STOPWORDS = ['I', 'A', 'ABOVE', 'AFTER', 'AGAINST', 'ALL', 'ALONE', 'ALWAYS', 'AM', 'AMOUNT', 'AN', 'AND', 'ANY', 'ARE', 'AROUND', ...
20.838323
28
0.191092
STOPWORDS = ['I', 'A', 'ABOVE', 'AFTER', 'AGAINST', 'ALL', 'ALONE', 'ALWAYS', 'AM', 'AMOUNT', 'AN', 'AND', 'ANY', 'ARE', 'AROUND', ...
0
0
0
0
0
0
0
0
0
43a1c9dd8eb272303c149f11f8f121bf3108e57a
16,623
py
Python
virt/ansible-2.3.0/lib/python2.7/site-packages/ansible/playbook/task.py
lakhlaifi/RedHat-Ansible
27c5077cced9d416081fcd5d69ea44bca0317fa4
[ "Apache-2.0" ]
null
null
null
virt/ansible-2.3.0/lib/python2.7/site-packages/ansible/playbook/task.py
lakhlaifi/RedHat-Ansible
27c5077cced9d416081fcd5d69ea44bca0317fa4
[ "Apache-2.0" ]
null
null
null
virt/ansible-2.3.0/lib/python2.7/site-packages/ansible/playbook/task.py
lakhlaifi/RedHat-Ansible
27c5077cced9d416081fcd5d69ea44bca0317fa4
[ "Apache-2.0" ]
1
2020-02-13T14:24:57.000Z
2020-02-13T14:24:57.000Z
# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.com> # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) an...
37.439189
141
0.60699
# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.com> # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) an...
0
241
0
14,638
0
0
0
405
355
e39bd32f67d3845311499fcd8a0e052f6424fc9f
1,175
py
Python
summarization/cover.py
telescopic/stampify
95f95ec98aa3f0b05d8ad39ce5dd3d89858b4488
[ "Apache-2.0" ]
2
2020-07-26T03:24:33.000Z
2020-12-19T15:40:31.000Z
summarization/cover.py
telescopic/stampify
95f95ec98aa3f0b05d8ad39ce5dd3d89858b4488
[ "Apache-2.0" ]
65
2020-06-09T09:31:53.000Z
2020-07-23T08:26:04.000Z
summarization/cover.py
telescopic/stampify
95f95ec98aa3f0b05d8ad39ce5dd3d89858b4488
[ "Apache-2.0" ]
9
2020-06-04T13:48:24.000Z
2022-01-03T02:42:09.000Z
''' Module to define the Cover object used in budgeted max cover solver '''
31.756757
61
0.627234
''' Module to define the Cover object used in budgeted max cover solver ''' class Cover: ''' Boiled down representation of a stamp page consists of only the cover of elements along with the cost and id. All elements are considered to have equal weight. Attributes: * cover : a list of size...
0
0
0
1,075
0
0
0
0
23
464d67ef641c33ea08164bf3e346050b87477926
1,765
py
Python
substream/tempbucket/__init__.py
mdegans/substream
60a329c1d12acbcf1d73586071b371ee8535ef8f
[ "MIT" ]
9
2020-09-14T09:58:34.000Z
2022-03-18T20:40:21.000Z
substream/tempbucket/__init__.py
aniket-amagi/substream
2b5e41c96a30541e8f7210de87551030a4bf45d9
[ "MIT" ]
2
2020-02-05T16:48:39.000Z
2020-12-12T21:31:41.000Z
substream/tempbucket/__init__.py
aniket-amagi/substream
2b5e41c96a30541e8f7210de87551030a4bf45d9
[ "MIT" ]
5
2019-08-19T20:57:03.000Z
2021-02-24T05:42:38.000Z
name = 'substream.tempbucket'
31.517857
80
0.64136
import contextlib import logging import uuid import six from google.cloud import storage, exceptions name = 'substream.tempbucket' class TemporaryBucket(contextlib.AbstractContextManager): """Functions much like tempfile.TemporaryDirectory() context manager, only it returns a google.storage.Bucket instead o...
0
0
0
1,608
0
0
0
-9
134
8a2c12b54779e102fabafd2fedf70f56d191c952
234
py
Python
it.py
xiaohh007/speech
48b2661bccbe9882bd8591866f60581f03cfa6ec
[ "Apache-2.0" ]
null
null
null
it.py
xiaohh007/speech
48b2661bccbe9882bd8591866f60581f03cfa6ec
[ "Apache-2.0" ]
null
null
null
it.py
xiaohh007/speech
48b2661bccbe9882bd8591866f60581f03cfa6ec
[ "Apache-2.0" ]
null
null
null
import librosa import sys y, sr = librosa.load(sys.argv[1], sr=16000) frame_size = 256 frmae_shift = 128 mfccs = librosa.feature.mfcc(y, sr, n_mfcc=12, hop_length=frmae_shift, n_fft=frame_size) print(mfccs)
21.272727
88
0.75641
import numpy as np import math,librosa import sys y, sr = librosa.load(sys.argv[1], sr=16000) frame_size = 256 frmae_shift = 128 mfccs = librosa.feature.mfcc(y, sr, n_mfcc=12, hop_length=frmae_shift, n_fft=frame_size) print(mfccs)
3
0
0
0
0
0
0
2
22
956204a97a220c27e3ae0b79db48714a03a27e28
5,046
py
Python
app/auth/forms.py
chinmaya-dev/ttbdonation
1ea4cb2c279db86465040b68f1fa48dbb5f7e17c
[ "MIT" ]
null
null
null
app/auth/forms.py
chinmaya-dev/ttbdonation
1ea4cb2c279db86465040b68f1fa48dbb5f7e17c
[ "MIT" ]
11
2019-12-26T17:21:03.000Z
2022-03-21T22:17:07.000Z
app/auth/forms.py
chinmaya-dev/ttbdonation
1ea4cb2c279db86465040b68f1fa48dbb5f7e17c
[ "MIT" ]
null
null
null
from .. import db, bcrypt
53.680851
390
0.674197
from flask_wtf import FlaskForm, RecaptchaField from flask_wtf.file import FileField, FileAllowed from wtforms import StringField, PasswordField, SubmitField, BooleanField, RadioField, IntegerField, SelectField from wtforms.fields.html5 import DateField from wtforms.validators import DataRequired, Length, Email, EqualT...
0
0
0
4,382
0
0
0
250
383
7828b076e8d358798ac9144fbfef852fc41dd4ec
4,460
py
Python
cogs/greeting.py
scriptgalih/re-direct-discord-message
5f720a205fd331814b68611d56088f1742be74c6
[ "MIT" ]
null
null
null
cogs/greeting.py
scriptgalih/re-direct-discord-message
5f720a205fd331814b68611d56088f1742be74c6
[ "MIT" ]
null
null
null
cogs/greeting.py
scriptgalih/re-direct-discord-message
5f720a205fd331814b68611d56088f1742be74c6
[ "MIT" ]
null
null
null
import pymongo import json with open('cogs/dbCred.json') as json_file: db_cred = json.load(json_file) myClient = pymongo.MongoClient(db_cred['client']) myDB = myClient[db_cred['db_name']] col_botinfo = myDB['botinfo'] col_serverinfo = myDB['serverinfo'] col_greeting_msg = myDB['greeting_msg']
38.448276
104
0.629148
from discord.ext import commands import discord import pymongo import json import asyncio with open('cogs/dbCred.json') as json_file: db_cred = json.load(json_file) myClient = pymongo.MongoClient(db_cred['client']) myDB = myClient[db_cred['db_name']] col_botinfo = myDB['botinfo'] col_serverinfo = myDB['serverinfo...
0
3,611
0
397
0
41
0
-3
112
2f8d942dc127f66ceeafebb5755d1196fbefdd3d
304
py
Python
infrabbitmq/exceptions.py
aleasoluciones/infrabbitmq3
5a5f5cf7e4fbcdae659855edcbf1b8c2d007f69f
[ "MIT" ]
null
null
null
infrabbitmq/exceptions.py
aleasoluciones/infrabbitmq3
5a5f5cf7e4fbcdae659855edcbf1b8c2d007f69f
[ "MIT" ]
null
null
null
infrabbitmq/exceptions.py
aleasoluciones/infrabbitmq3
5a5f5cf7e4fbcdae659855edcbf1b8c2d007f69f
[ "MIT" ]
1
2019-04-15T06:38:30.000Z
2019-04-15T06:38:30.000Z
# ------------------------------------- # RabbitMQClient Errors # ------------------------------------- # ------------------------------------- # PikaClientWrapper Errors # -------------------------------------
17.882353
39
0.361842
# ------------------------------------- # RabbitMQClient Errors # ------------------------------------- class RabbitMQError(Exception): pass # ------------------------------------- # PikaClientWrapper Errors # ------------------------------------- class ClientWrapperError(Exception): pass
0
0
0
43
0
0
0
0
46
87034caaa4f4c903a863843450bcfe5e99404b23
485
py
Python
CoolPlot/Util/__init__.py
CoolProp/CoolPlot
0967e243934c0970ef830b43befeabacc688cdfd
[ "MIT" ]
9
2019-05-23T08:13:43.000Z
2022-03-02T11:37:39.000Z
CoolPlot/Util/__init__.py
CoolProp/CoolPlot
0967e243934c0970ef830b43befeabacc688cdfd
[ "MIT" ]
1
2019-06-28T16:57:32.000Z
2019-07-17T20:49:23.000Z
CoolPlot/Util/__init__.py
CoolProp/CoolPlot
0967e243934c0970ef830b43befeabacc688cdfd
[ "MIT" ]
3
2020-10-29T01:49:59.000Z
2022-02-21T17:43:11.000Z
# -*- coding: utf-8 -*-
25.526316
100
0.645361
# -*- coding: utf-8 -*- import CoolProp def is_string(in_obj): try: return isinstance(in_obj, basestring) except NameError: return isinstance(in_obj, str) # except: # return False def _get_index(prop): if is_string(prop): return CoolProp.CoolProp.get_parameter_index(pro...
0
0
0
0
0
399
0
-6
69
5fbc73f58f4c967d8d6abe408aec9582be8906a2
2,085
py
Python
02-evolution/compare.py
MKuranowski/STUD-WSI
f0d39c73d918a20933f745378cddfdbb321b68a7
[ "MIT" ]
null
null
null
02-evolution/compare.py
MKuranowski/STUD-WSI
f0d39c73d918a20933f745378cddfdbb321b68a7
[ "MIT" ]
null
null
null
02-evolution/compare.py
MKuranowski/STUD-WSI
f0d39c73d918a20933f745378cddfdbb321b68a7
[ "MIT" ]
null
null
null
# cSpell:words stdev import os ROUNDS_OF_ALGO = 50 INITIAL_POINT_BOUND = 100 SEPARATOR = os.getenv("SEP", "\t") if __name__ == "__main__": main()
30.217391
91
0.629257
# cSpell:words stdev import multiprocessing.pool import os from statistics import mean, stdev from typing import Any, NamedTuple from cec2017.functions import f4 from evolution import Evolution ROUNDS_OF_ALGO = 50 INITIAL_POINT_BOUND = 100 SEPARATOR = os.getenv("SEP", "\t") class Result(NamedTuple): min: float...
0
210
0
244
0
1,241
0
53
181
0a686e67039c86e26fa0f5cafd4d711b37c9a831
1,593
py
Python
calvinextras/calvinsys/ui/PollingSensor.py
gabrielcercel/calvin-base
c0315f100643230d65aed1745e1c22df3e7a7c2c
[ "Apache-2.0" ]
334
2015-06-04T15:14:28.000Z
2022-02-09T11:14:17.000Z
calvinextras/calvinsys/ui/PollingSensor.py
gabrielcercel/calvin-base
c0315f100643230d65aed1745e1c22df3e7a7c2c
[ "Apache-2.0" ]
89
2015-06-13T19:15:35.000Z
2019-12-03T19:23:20.000Z
calvinextras/calvinsys/ui/PollingSensor.py
gabrielcercel/calvin-base
c0315f100643230d65aed1745e1c22df3e7a7c2c
[ "Apache-2.0" ]
112
2015-06-06T19:16:54.000Z
2020-10-19T01:27:55.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2017 Ericsson AB # # 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 ...
27
75
0.646579
# -*- coding: utf-8 -*- # Copyright (c) 2017 Ericsson AB # # 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 ...
0
0
0
839
0
0
0
80
68
54e892fbf15c2ace4b30f0f0d961e8bfe0a68ee9
762
py
Python
lectures/lecture06/code/contours_demo.py
mateusza/Introduction-to-Python-Numerical-Analysis-for-Engineers-and-Scientist
a27144cc8742e67af215e8de781bd208cc1f7436
[ "MIT" ]
101
2017-11-28T15:08:25.000Z
2022-03-26T13:59:49.000Z
lectures/lecture06/code/contours_demo.py
mateusza/Introduction-to-Python-Numerical-Analysis-for-Engineers-and-Scientist
a27144cc8742e67af215e8de781bd208cc1f7436
[ "MIT" ]
1
2017-12-16T19:41:39.000Z
2017-12-16T19:41:39.000Z
lectures/lecture06/code/contours_demo.py
mateusza/Introduction-to-Python-Numerical-Analysis-for-Engineers-and-Scientist
a27144cc8742e67af215e8de781bd208cc1f7436
[ "MIT" ]
54
2017-12-15T19:19:53.000Z
2022-03-01T23:36:55.000Z
import numpy as np import matplotlib.pyplot as plt x = np.linspace(-2,2,100) y = np.linspace(-1,3,100) #x,y = np.meshgrid(x,y) f = (1.0-x)**2 + (100.0*((y-(x**2))**2)) # plt.figure() # plt.plot(x,y,'ok') # plt.show() plt.figure() plt.contourf(x,y,f,100) plt.colorbar() x,y = np.meshgrid(x,y) f = (1.0-x)**...
21.771429
64
0.587927
import numpy as np import matplotlib.pyplot as plt from mpl_toolkits.mplot3d import Axes3D x = np.linspace(-2,2,100) y = np.linspace(-1,3,100) #x,y = np.meshgrid(x,y) f = (1.0-x)**2 + (100.0*((y-(x**2))**2)) # plt.figure() # plt.plot(x,y,'ok') # plt.show() plt.figure() plt.contourf(x,y,f,100) plt.colorbar()...
0
0
0
0
0
0
0
18
23
9eb15173c59da128b4256d5127c7999ec40929e8
57
py
Python
__init__.py
Xarrow/tan
b801eb814d767a62df899f9facc2d1bcd3b02d0f
[ "MIT" ]
null
null
null
__init__.py
Xarrow/tan
b801eb814d767a62df899f9facc2d1bcd3b02d0f
[ "MIT" ]
null
null
null
__init__.py
Xarrow/tan
b801eb814d767a62df899f9facc2d1bcd3b02d0f
[ "MIT" ]
null
null
null
# -*- coding:utf-8 -*-
19
33
0.684211
# -*- coding:utf-8 -*- from tan import tancp_cli,tan_cli
0
0
0
0
0
0
0
12
22
4a4f0d0d46e7908a0651a785d65a77ce951d30f7
3,469
py
Python
opensand-testbed/configurator.py
jhuwyler/qpep
3b06f02f749cbc14ff9988ad6d9411f0a666f5f9
[ "Unlicense" ]
68
2020-05-09T14:43:20.000Z
2022-01-19T05:26:47.000Z
opensand-testbed/configurator.py
jhuwyler/qpep
3b06f02f749cbc14ff9988ad6d9411f0a666f5f9
[ "Unlicense" ]
6
2020-06-01T11:54:07.000Z
2022-01-18T19:38:10.000Z
opensand-testbed/configurator.py
jhuwyler/qpep
3b06f02f749cbc14ff9988ad6d9411f0a666f5f9
[ "Unlicense" ]
11
2020-05-10T12:40:00.000Z
2022-02-01T23:08:58.000Z
from dotenv import load_dotenv load_dotenv() if __name__ == '__main__': configure_gateway_container() configure_proxy_st_container() configure_satellite_container() configure_terminal_container() configure_ws_ovpn_container() configure_ws_st_container() configure_ws_gw_container()
43.3625
144
0.683482
import fileinput import os from dotenv import load_dotenv load_dotenv() def configure_gateway_container(): base_path = 'gateway/config/' conf_file = base_path + 'gw.conf' change_line(conf_file, 22, 'emu_ipv4 = ' + str(os.getenv("EMU_NETWORK_HEAD")) + ".0.3/24") change_line(conf_file, 25, 'lan_ipv4 = ' ...
0
0
0
0
0
2,922
0
-17
251
b806de62599e63bdeb512a8d441a43706003e5e9
4,108
py
Python
asm/contrib/middleware.py
fbigun/asm_leancloud
9c52bd7c7eea1cd5f1c60b73ce668e87a60c7b33
[ "MIT" ]
null
null
null
asm/contrib/middleware.py
fbigun/asm_leancloud
9c52bd7c7eea1cd5f1c60b73ce668e87a60c7b33
[ "MIT" ]
null
null
null
asm/contrib/middleware.py
fbigun/asm_leancloud
9c52bd7c7eea1cd5f1c60b73ce668e87a60c7b33
[ "MIT" ]
null
null
null
# coding: utf-8
35.721739
113
0.62999
# coding: utf-8 import os from werkzeug.wrappers import Request, Response from werkzeug.utils import redirect from werkzeug.exceptions import HTTPException, NotFound from . import utils class HTTPMethodOverrideMiddleware(object): """ 使用中间件以接受标准 HTTP 方法 详见:https://gist.github.com/nervouna/47cf9b69484213...
123
0
0
3,782
0
0
0
60
205
ddacdab55fdd88b5b8bf51a381aa55b84c9b8415
30,691
py
Python
app/views/dash.py
davideguidobene/cinema-web-app
1a83576a1e37ea69bec2b2a80f584912cfc9b264
[ "MIT" ]
null
null
null
app/views/dash.py
davideguidobene/cinema-web-app
1a83576a1e37ea69bec2b2a80f584912cfc9b264
[ "MIT" ]
null
null
null
app/views/dash.py
davideguidobene/cinema-web-app
1a83576a1e37ea69bec2b2a80f584912cfc9b264
[ "MIT" ]
null
null
null
""" Modulo contenente le route della dashboard amministratori. Le route sono registrate nel Blueprint 'dash', con prefisso '/dashboard'. """ from datetime import datetime, timedelta from flask import Blueprint, current_app from sqlalchemy.sql.expression import func from sqlalchemy.exc import IntegrityError, Programmi...
47.362654
137
0.594865
""" Modulo contenente le route della dashboard amministratori. Le route sono registrate nel Blueprint 'dash', con prefisso '/dashboard'. """ from datetime import datetime, date, timedelta from flask import Blueprint, render_template, abort, request, current_app, flash, redirect, url_for from sqlalchemy.sql import sel...
46
23,620
0
0
0
0
0
229
228
cecdb9b16325aea86e592d272d691fde9449c2e5
5,528
py
Python
virtualscreening/vina/python/zinc_db.py
rodrigofaccioli/drugdesign
de15880af361a010729b1f4fbc8a75a2b36688a6
[ "Apache-2.0" ]
3
2015-01-19T20:12:59.000Z
2019-02-21T18:43:04.000Z
virtualscreening/vina/python/zinc_db.py
rodrigofaccioli/drugdesign
de15880af361a010729b1f4fbc8a75a2b36688a6
[ "Apache-2.0" ]
22
2015-01-05T16:48:54.000Z
2017-01-21T16:36:10.000Z
virtualscreening/vina/python/zinc_db.py
rodrigofaccioli/drugdesign
de15880af361a010729b1f4fbc8a75a2b36688a6
[ "Apache-2.0" ]
11
2015-03-03T13:32:24.000Z
2020-04-03T11:22:24.000Z
#! /usr/bin/env python """ Routines to extract compounds from ZINC Database: http://zinc.docking.org/ These routines were developed by: Rodrigo Antonio Faccioli - rodrigo.faccioli@usp.br / rodrigo.faccioli@gmail.com Leandro Oliveira Bortot - leandro.bortot@usp.br / leandro.obt@gmail.com """ import ...
34.335404
87
0.7339
#! /usr/bin/env python """ Routines to extract compounds from ZINC Database: http://zinc.docking.org/ These routines were developed by: Rodrigo Antonio Faccioli - rodrigo.faccioli@usp.br / rodrigo.faccioli@gmail.com Leandro Oliveira Bortot - leandro.bortot@usp.br / leandro.obt@gmail.com """ import...
0
0
0
0
0
1,071
0
4
139
d4ee3dba7be61d0dbb4a37ed1592777494c8d39b
453
py
Python
spherpro/bromodules/io.py
BodenmillerGroup/spherpro
0bcbc76942c7bae82deddcdc4fa5239e04442553
[ "BSD-3-Clause" ]
1
2020-07-28T13:53:15.000Z
2020-07-28T13:53:15.000Z
spherpro/bromodules/io.py
BodenmillerGroup/spherpro
0bcbc76942c7bae82deddcdc4fa5239e04442553
[ "BSD-3-Clause" ]
null
null
null
spherpro/bromodules/io.py
BodenmillerGroup/spherpro
0bcbc76942c7bae82deddcdc4fa5239e04442553
[ "BSD-3-Clause" ]
null
null
null
import spherpro.bromodules.io_masks as io_masks import spherpro.bromodules.io_stackimage as io_stackimage
34.846154
60
0.766004
import spherpro.bromodules.io_anndata as io_ann import spherpro.bromodules.io_imcfolder as io_imc import spherpro.bromodules.io_masks as io_masks import spherpro.bromodules.io_stackimage as io_stackimage class Io(object): def __init__(self, bro): self.masks = io_masks.IoMasks(bro) self.imcimg = io...
0
0
0
225
0
0
0
54
67
feed07ae1a04187a706f943e8684878a4ff2f736
1,563
py
Python
lab4/evaluate.py
PiotrGrzybowski/SocialMediaAnalysis
b341f7a9134220398cdb65b01ec50c837600d604
[ "Apache-2.0" ]
null
null
null
lab4/evaluate.py
PiotrGrzybowski/SocialMediaAnalysis
b341f7a9134220398cdb65b01ec50c837600d604
[ "Apache-2.0" ]
null
null
null
lab4/evaluate.py
PiotrGrzybowski/SocialMediaAnalysis
b341f7a9134220398cdb65b01ec50c837600d604
[ "Apache-2.0" ]
null
null
null
import numpy as np from keras.models import load_model from keras_preprocessing.sequence import pad_sequences from keras_preprocessing.text import Tokenizer from lab4.utils import clean_text model = load_model('my_model.h5') texts = ['It was my fault I let you control me', 'If I was gone tomorrow would you ...
42.243243
207
0.726807
import numpy as np from keras.models import load_model from keras_preprocessing.sequence import pad_sequences from keras_preprocessing.text import Tokenizer from lab4.utils import clean_text model = load_model('my_model.h5') texts = ['It was my fault I let you control me', 'If I was gone tomorrow would you ...
0
0
0
0
0
0
0
0
0
0a1e6258a9a01cfd78422e6aba910aa5fcd1bed3
6,481
py
Python
monai/networks/nets/regressor.py
function2-llx/MONAI
4cddaa830b61b88ec78e089bb5f21e05bb1a78f4
[ "Apache-2.0" ]
3
2020-06-22T20:59:14.000Z
2021-04-09T21:24:45.000Z
monai/networks/nets/regressor.py
Borda/MONAI
e0db5a564225a7cb62e7a23df97267019006302f
[ "Apache-2.0" ]
null
null
null
monai/networks/nets/regressor.py
Borda/MONAI
e0db5a564225a7cb62e7a23df97267019006302f
[ "Apache-2.0" ]
1
2020-06-22T19:22:59.000Z
2020-06-22T19:22:59.000Z
# Copyright (c) MONAI Consortium # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, so...
42.638158
118
0.666872
# Copyright (c) MONAI Consortium # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, so...
0
0
0
5,455
0
0
0
203
202
1d64b2a42ad57672defc16a4a878fa3ecad0782c
5,219
py
Python
perc_tester.py
gregtucker/percolator
9e699c8ab485369e762590d83583a5bc31ec23be
[ "MIT" ]
null
null
null
perc_tester.py
gregtucker/percolator
9e699c8ab485369e762590d83583a5bc31ec23be
[ "MIT" ]
null
null
null
perc_tester.py
gregtucker/percolator
9e699c8ab485369e762590d83583a5bc31ec23be
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 # -*- coding: utf-8 -*- """ Created on Thu Jun 21 20:22:37 2018 @author: gtucker """ import sys FULL = 1 # code for full cell in 'cell' array, used for plotting (only) if __name__ == '__main__': import doctest doctest.testmod() try: n = sys.argv[1] except: ...
29.320225
78
0.538609
#!/usr/bin/env python2 # -*- coding: utf-8 -*- """ Created on Thu Jun 21 20:22:37 2018 @author: gtucker """ import sys import numpy as np from percolation import Percolator FULL = 1 # code for full cell in 'cell' array, used for plotting (only) class PercTester(object): """A PercTester implements testing of ...
0
0
0
4,625
0
0
0
10
67
6593eb8058ea16808750452054b11e25b63d5aa0
23,643
py
Python
rplugin/python3/deoplete/resources/meld_mj_refman.py
poppyschmo/deoplete-latex
0118ade4e2e8ca7dd5b162a92dfb238b0817ca3e
[ "MIT" ]
18
2017-04-24T09:35:47.000Z
2020-03-23T02:55:22.000Z
rplugin/python3/deoplete/resources/meld_mj_refman.py
poppyschmo/deoplete-latex
0118ade4e2e8ca7dd5b162a92dfb238b0817ca3e
[ "MIT" ]
4
2017-02-03T08:57:02.000Z
2019-12-12T07:54:05.000Z
rplugin/python3/deoplete/resources/meld_mj_refman.py
poppyschmo/deoplete-latex
0118ade4e2e8ca7dd5b162a92dfb238b0817ca3e
[ "MIT" ]
null
null
null
#!/bin/python3 # The aim of this script is to reorganize everything from ``update_mathjax.js`` # and ``get_refman`` by package, roughly mimicking the layout exported by # ``get_cwl``. Anything not in a known package can follow two routes: If # tagged with a ``KaTeX`` or ``MathJax`` meta tag, it'll get dumped in the #...
44.110075
79
0.534069
#!/bin/python3 # The aim of this script is to reorganize everything from ``update_mathjax.js`` # and ``get_refman`` by package, roughly mimicking the layout exported by # ``get_cwl``. Anything not in a known package can follow two routes: If # tagged with a ``KaTeX`` or ``MathJax`` meta tag, it'll get dumped in the #...
0
0
0
0
0
16,800
0
53
249
c43a3c2450e4c6b2008b231c0677034e7c91ce2e
6,815
py
Python
others/planck.py
nineties/planckforth
4337cedd5f8fb9a900f823a3b5ef2263a854caaf
[ "MIT" ]
225
2021-01-13T15:27:28.000Z
2022-03-20T22:19:31.000Z
others/planck.py
eblanton/planckforth
725b09d3faf7e6292b35afe5d2286fd440ccfb7c
[ "MIT" ]
3
2021-01-20T22:40:31.000Z
2021-12-06T14:00:02.000Z
others/planck.py
eblanton/planckforth
725b09d3faf7e6292b35afe5d2286fd440ccfb7c
[ "MIT" ]
9
2021-01-20T15:37:09.000Z
2022-02-16T01:21:16.000Z
#!/usr/bin/env python3 # planck - # Copyright (C) 2021 nineties # import sys import operator import array import platform RUNTIME_NAME = "Python {}".format(platform.python_version()) COPYRIGHT = "Copyright (c) 2021 Koichi Nakamura <koichi@idein.jp>" VERSION = "{}:{}".format(RUNTIME_NAME, COPYRIGHT) MEMORY_SIZE = 0x...
22.792642
73
0.633309
#!/usr/bin/env python3 # planck - # Copyright (C) 2021 nineties # import os import sys import operator import array import ctypes import platform RUNTIME_NAME = "Python {}".format(platform.python_version()) COPYRIGHT = "Copyright (c) 2021 Koichi Nakamura <koichi@idein.jp>" VERSION = "{}:{}".format(RUNTIME_NAME, COP...
0
0
0
0
0
2,895
0
-20
859
1e436623a443d39d0f88b9cdb14e9c2756899a54
1,317
py
Python
vhs_stitcher/image_editing.py
babichjacob/vhs-stitcher
b09793c951949475dc6a6ff24b3178b13d355a9b
[ "MIT" ]
null
null
null
vhs_stitcher/image_editing.py
babichjacob/vhs-stitcher
b09793c951949475dc6a6ff24b3178b13d355a9b
[ "MIT" ]
3
2022-01-13T02:37:59.000Z
2022-03-16T23:39:51.000Z
vhs_stitcher/image_editing.py
babichjacob/vhs-stitcher
b09793c951949475dc6a6ff24b3178b13d355a9b
[ "MIT" ]
null
null
null
from numpy import array, hstack from PIL import Image from PIL.Image import Image as ImageType from PIL.ImageFilter import FIND_EDGES, GaussianBlur from . import IMAGE_SIZE_LARGE, IMAGE_SIZE_SMALL def prepare_image(image: ImageType): """ 1. Downscale the image a little bit to a square 2. Blur (1) 3....
28.021277
70
0.732726
from typing import Dict from uuid import uuid4 from imageio import imread, imwrite from numpy import array, hstack, ndarray, subtract from PIL import Image from PIL.Image import Image as ImageType from PIL.ImageFilter import FIND_EDGES, GaussianBlur from tqdm import tqdm from . import IMAGE_SIZE_LARGE, IMAGE_SIZE_SMA...
0
0
0
0
0
54
0
36
112
daf0edb1e825a66a3475a509fd7bca5a4ed45f98
1,115
py
Python
try_controls/try5_frame/try2_frame_layout.py
ashidagithub/HJDS201909LB
9e78b3cf4904f9f8af841db0032b66bc2f4f6fea
[ "Apache-2.0" ]
null
null
null
try_controls/try5_frame/try2_frame_layout.py
ashidagithub/HJDS201909LB
9e78b3cf4904f9f8af841db0032b66bc2f4f6fea
[ "Apache-2.0" ]
null
null
null
try_controls/try5_frame/try2_frame_layout.py
ashidagithub/HJDS201909LB
9e78b3cf4904f9f8af841db0032b66bc2f4f6fea
[ "Apache-2.0" ]
null
null
null
# -*- coding: UTF-8 -*- # ------------------------(max to 80 columns)----------------------------------- # author by : ID) # created: 2019.11 # Description: # WinForm ( Frame ) # ------------------------(max to 80 columns)----------------------------------- import tkinter as tk import tkinter.messagebox # crea...
23.723404
88
0.573991
# -*- coding: UTF-8 -*- # ------------------------(max to 80 columns)----------------------------------- # author by : (学员ID) # created: 2019.11 # Description: # 初步学习 WinForm 编程 ( Frame ) # ------------------------(max to 80 columns)----------------------------------- import tkinter as tk from tkinter import ttk ...
27
0
0
0
0
0
0
2
22
36726aae0d193cfa6543569ed4cf296c0756dec1
7,704
py
Python
py-worker/lib/worker.py
pwegrzyn/wegpat-gmail.com
3fce9d0bc32c1d6be94cd664eb13a69255975fd0
[ "MIT" ]
null
null
null
py-worker/lib/worker.py
pwegrzyn/wegpat-gmail.com
3fce9d0bc32c1d6be94cd664eb13a69255975fd0
[ "MIT" ]
5
2021-09-02T12:22:08.000Z
2022-03-02T09:15:20.000Z
py-worker/lib/worker.py
pwegrzyn/wegpat-gmail.com
3fce9d0bc32c1d6be94cd664eb13a69255975fd0
[ "MIT" ]
null
null
null
import logging logger = logging.getLogger(__name__) logger.setLevel(logging.INFO)
43.039106
129
0.596314
import json import pickle import logging import datetime import time from datetime import timedelta from geopy.distance import great_circle import requests logger = logging.getLogger(__name__) logger.setLevel(logging.INFO) class PyWorker: """ Represents a Python process acting as worker (listening for job...
0
0
0
7,455
0
0
0
-13
178
ade988b1282385a6b1e0d7ef57621bf4895b5d5f
5,022
py
Python
lib/topology_test.py
724686158/cisot_network_monitor
aeed862ce044aa65baa815f7c25ee4a650add432
[ "MIT" ]
1
2021-12-22T07:18:43.000Z
2021-12-22T07:18:43.000Z
lib/topology_test.py
724686158/cisot_network_monitor
aeed862ce044aa65baa815f7c25ee4a650add432
[ "MIT" ]
null
null
null
lib/topology_test.py
724686158/cisot_network_monitor
aeed862ce044aa65baa815f7c25ee4a650add432
[ "MIT" ]
null
null
null
# # Copyright (c) 2020 by Ilya Tsyganov, Ryazan State Radio Engineering University. # # 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...
33.704698
81
0.644962
# # Copyright (c) 2020 by Ilya Tsyganov, Ryazan State Radio Engineering University. # # 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
3,639
0
0
0
56
115
55a3c93070b621c0b7fb7c198286f5b653537268
1,704
py
Python
spdlog/conanfile.py
kapilsh/conan-scripts
31c55397a2d721c80da5dbd6a6c738accfdbb241
[ "MIT" ]
null
null
null
spdlog/conanfile.py
kapilsh/conan-scripts
31c55397a2d721c80da5dbd6a6c738accfdbb241
[ "MIT" ]
null
null
null
spdlog/conanfile.py
kapilsh/conan-scripts
31c55397a2d721c80da5dbd6a6c738accfdbb241
[ "MIT" ]
null
null
null
import sys import os sys.path.append( os.path.abspath(os.path.join(os.path.dirname(__file__), '..')))
29.37931
76
0.643192
import sys import os import shutil from conans import ConanFile, CMake from conans.tools import download, unzip sys.path.append( os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))) class SpdLogConan(ConanFile): with open(os.path.join(os.path.dirname(os.path.realpath( __file__)), "VER...
0
0
0
1,481
0
0
0
25
90
3bfcfcfcc87907df2ad5394bf1ceff7df5e07fe0
950
py
Python
basic/m_unittest/prac_unittest.py
plerin/playground_with_python
221362b47e456656749455d82bb3c611fa8f4440
[ "MIT" ]
null
null
null
basic/m_unittest/prac_unittest.py
plerin/playground_with_python
221362b47e456656749455d82bb3c611fa8f4440
[ "MIT" ]
null
null
null
basic/m_unittest/prac_unittest.py
plerin/playground_with_python
221362b47e456656749455d82bb3c611fa8f4440
[ "MIT" ]
null
null
null
import unittest if __name__ == '__main__': unittest.main()
21.111111
66
0.626316
import unittest import os import for_unittest class MyCalcTest(unittest.TestCase): def test_add(self): c = for_unittest.add(20, 10) self.assertEqual(c, 30) def test_substract(self): c = for_unittest.substract(20, 10) self.assertEqual(c, 10) class MyUtilTest(unittest.TestCas...
0
0
0
807
0
0
0
-14
90