hexsha
stringlengths
40
40
size
int64
7
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
125
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
125
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
125
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.77
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
7
1.04M
filtered:remove_function_no_docstring
int64
-102
942k
filtered:remove_class_no_docstring
int64
-354
977k
filtered:remove_delete_markers
int64
0
60.1k
cb495600a41947b1d94bf9580b821c4073762c83
1,431
py
Python
builder/wheel.py
allenporter/home-assistant-wheels
c7ae5629b7045691d495cf40e9ae123946ba9c76
[ "Apache-2.0" ]
14
2021-01-17T23:31:10.000Z
2022-02-25T18:23:53.000Z
builder/wheel.py
allenporter/home-assistant-wheels
c7ae5629b7045691d495cf40e9ae123946ba9c76
[ "Apache-2.0" ]
140
2020-02-03T11:12:29.000Z
2022-03-29T07:24:34.000Z
builder/wheel.py
allenporter/home-assistant-wheels
c7ae5629b7045691d495cf40e9ae123946ba9c76
[ "Apache-2.0" ]
14
2020-07-05T07:40:57.000Z
2022-03-10T23:26:14.000Z
"""Utils for wheel.""" from contextlib import suppress from pathlib import Path import re import shutil from .utils import run_command, build_arch RE_WHEEL_PLATFORM = re.compile(r"^(?P<name>.*-)cp\d{2}m?-linux_\w+\.whl$") ARCH_PLAT = { "amd64": "linux_x86_64", "i386": "linux_i686", "aarch6...
30.446809
100
0.639413
"""Utils for wheel.""" from contextlib import suppress from pathlib import Path import re import shutil from .utils import run_command, build_arch RE_WHEEL_PLATFORM = re.compile(r"^(?P<name>.*-)cp\d{2}m?-linux_\w+\.whl$") ARCH_PLAT = { "amd64": "linux_x86_64", "i386": "linux_i686", "aarch6...
0
0
0
1cb684d2bf98f35c08eef045efcf405bf30ab2ea
1,135
py
Python
packnet/interface.py
c0mplh4cks/packnet
8a4fa4f398e59a9c0e35d35ad8194d3ed8b56cb7
[ "MIT" ]
2
2021-01-08T12:26:51.000Z
2021-09-17T05:16:33.000Z
packnet/interface.py
c0mplh4cks/packnet
8a4fa4f398e59a9c0e35d35ad8194d3ed8b56cb7
[ "MIT" ]
null
null
null
packnet/interface.py
c0mplh4cks/packnet
8a4fa4f398e59a9c0e35d35ad8194d3ed8b56cb7
[ "MIT" ]
2
2020-12-14T21:18:48.000Z
2021-09-17T11:04:36.000Z
""" PACKNET - c0mplh4cks INTERFACE """ # === Importing Dependencies === # import socket from time import time from .standards import encode, decode from . import ADDR, MAC # === Interface === #
19.568966
92
0.574449
""" PACKNET - c0mplh4cks INTERFACE """ # === Importing Dependencies === # import socket from time import time from .standards import encode, decode from . import ADDR, MAC # === Interface === # class Interface(): def __init__(self, card=None, port=0, passive=False, timeout=64): self.pass...
819
-3
102
95d66a14992e28b3c373cbfacf4f6d039c4b0e91
359
py
Python
smp_manifold_learning/scripts/create_dir_if_not_exist.py
gsutanto/smp_manifold_learning
60ef8278942c784c8d3bcd0a09031475f80d96fb
[ "MIT" ]
11
2020-09-26T12:13:01.000Z
2022-03-23T07:34:14.000Z
smp_manifold_learning/scripts/create_dir_if_not_exist.py
gsutanto/smp_manifold_learning
60ef8278942c784c8d3bcd0a09031475f80d96fb
[ "MIT" ]
1
2021-04-10T10:42:28.000Z
2021-04-16T07:04:26.000Z
smp_manifold_learning/scripts/create_dir_if_not_exist.py
gsutanto/smp_manifold_learning
60ef8278942c784c8d3bcd0a09031475f80d96fb
[ "MIT" ]
5
2020-09-24T18:52:46.000Z
2022-03-23T07:26:15.000Z
import argparse from smp_manifold_learning.differentiable_models.utils import create_dir_if_not_exist parser = argparse.ArgumentParser(allow_abbrev=False) parser.add_argument("-d", "--dir_path", default='../plot/ecmnn/', type=str) if __name__ == '__main__': args = parser.parse_args() dir_path = args.dir_pat...
29.916667
85
0.774373
import argparse from smp_manifold_learning.differentiable_models.utils import create_dir_if_not_exist parser = argparse.ArgumentParser(allow_abbrev=False) parser.add_argument("-d", "--dir_path", default='../plot/ecmnn/', type=str) if __name__ == '__main__': args = parser.parse_args() dir_path = args.dir_pat...
0
0
0
9f4fe7c4c5b6a35be415fce1b8b7462a20ce88df
432
py
Python
dashboard/migrations/0010_antenna_ant_name.py
HERA-Team/heranow
1bc827459a7a92f600cefbd0c8a08f629a211cda
[ "BSD-3-Clause" ]
null
null
null
dashboard/migrations/0010_antenna_ant_name.py
HERA-Team/heranow
1bc827459a7a92f600cefbd0c8a08f629a211cda
[ "BSD-3-Clause" ]
6
2020-09-10T05:33:17.000Z
2021-03-16T20:36:47.000Z
dashboard/migrations/0010_antenna_ant_name.py
HERA-Team/heranow
1bc827459a7a92f600cefbd0c8a08f629a211cda
[ "BSD-3-Clause" ]
null
null
null
# Generated by Django 3.0.3 on 2020-08-13 18:04 from django.db import migrations, models
21.6
64
0.592593
# Generated by Django 3.0.3 on 2020-08-13 18:04 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ("dashboard", "0009_hookupnotes"), ] operations = [ migrations.AddField( model_name="antenna", name="ant_name", ...
0
318
23
55f3a6b88a946898726d384c6d0d5e2eb62cc48f
828
py
Python
website-backend/ava/common/uuid_utils.py
kbladin/ava-capture
2fc24f4a3712f721c3a229b499631e00697209a5
[ "BSD-3-Clause" ]
null
null
null
website-backend/ava/common/uuid_utils.py
kbladin/ava-capture
2fc24f4a3712f721c3a229b499631e00697209a5
[ "BSD-3-Clause" ]
null
null
null
website-backend/ava/common/uuid_utils.py
kbladin/ava-capture
2fc24f4a3712f721c3a229b499631e00697209a5
[ "BSD-3-Clause" ]
null
null
null
# # Copyright (c) 2017 Electronic Arts Inc. All Rights Reserved # import uuid # https://stackoverflow.com/questions/1181919/python-base-36-encoding/1181924 def base36encode(number, alphabet='0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ'): """Converts an integer to a base36 string.""" if not isinstance(number, (int,...
25.090909
77
0.655797
# # Copyright (c) 2017 Electronic Arts Inc. All Rights Reserved # import uuid # https://stackoverflow.com/questions/1181919/python-base-36-encoding/1181924 def base36encode(number, alphabet='0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ'): """Converts an integer to a base36 string.""" if not isinstance(number, (int,...
114
0
23
2c90a03c1e24538f9c99a9df8168f749aec70377
4,801
py
Python
med_log.py
Zierman/medlog
ad0d932187d67b34895c7a74dc7deea8df1921c3
[ "MIT" ]
null
null
null
med_log.py
Zierman/medlog
ad0d932187d67b34895c7a74dc7deea8df1921c3
[ "MIT" ]
2
2021-12-05T06:29:41.000Z
2021-12-05T07:50:14.000Z
med_log.py
Zierman/medlog
ad0d932187d67b34895c7a74dc7deea8df1921c3
[ "MIT" ]
null
null
null
from __future__ import annotations from dataclasses import dataclass, Field from datetime import datetime, timedelta from typing import Union, Optional, Tuple, List from parse import parse from med import Med, MedRegistry, DOSAGE_PARSE_FORMAT DEFAULT_LOG_FILE = 'logs/med.log' DEFAULT_DATE_TIME_FORMAT = r'%m/%d/%Y %H...
35.043796
113
0.656738
from __future__ import annotations from dataclasses import dataclass, Field from datetime import datetime, timedelta from typing import Union, Optional, Tuple, List from parse import parse from med import Med, MedRegistry, DOSAGE_PARSE_FORMAT DEFAULT_LOG_FILE = 'logs/med.log' DEFAULT_DATE_TIME_FORMAT = r'%m/%d/%Y %H...
3,982
364
114
a9ab98b718aa838357f77aed9bea96e0588c0a11
10,896
py
Python
ffta/analysis/filtering.py
lindat18/ffta
f510a2068b7626e2984e54afc1a577450e560e97
[ "MIT" ]
null
null
null
ffta/analysis/filtering.py
lindat18/ffta
f510a2068b7626e2984e54afc1a577450e560e97
[ "MIT" ]
null
null
null
ffta/analysis/filtering.py
lindat18/ffta
f510a2068b7626e2984e54afc1a577450e560e97
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Mon Feb 26 17:15:36 2018 @author: Raj """ import pycroscopy as px from pycroscopy.processing.fft import FrequencyFilter import pyUSID as usid import numpy as np from scipy import signal as sps from ffta.load import get_utils from ffta import pixel from matplotlib import pyplot...
28.978723
117
0.73192
# -*- coding: utf-8 -*- """ Created on Mon Feb 26 17:15:36 2018 @author: Raj """ import pycroscopy as px from pycroscopy.processing.fft import FrequencyFilter import pyUSID as usid import numpy as np from scipy import signal as sps from ffta.load import get_utils from ffta import pixel from matplotlib import pyplot...
767
1,692
45
52823e59cd073588f3ba138cace3b20df0d5b5b5
3,395
py
Python
calvin/runtime/north/plugins/port/queue/test/test_collect_tagged.py
gabrielcercel/calvin-base
c0315f100643230d65aed1745e1c22df3e7a7c2c
[ "Apache-2.0" ]
334
2015-06-04T15:14:28.000Z
2022-02-09T11:14:17.000Z
calvin/runtime/north/plugins/port/queue/test/test_collect_tagged.py
gabrielcercel/calvin-base
c0315f100643230d65aed1745e1c22df3e7a7c2c
[ "Apache-2.0" ]
89
2015-06-13T19:15:35.000Z
2019-12-03T19:23:20.000Z
calvin/runtime/north/plugins/port/queue/test/test_collect_tagged.py
gabrielcercel/calvin-base
c0315f100643230d65aed1745e1c22df3e7a7c2c
[ "Apache-2.0" ]
112
2015-06-06T19:16:54.000Z
2020-10-19T01:27:55.000Z
import pytest from calvin.runtime.north.plugins.port import queue from calvin.runtime.north.calvin_token import Token from calvin.runtime.north.plugins.port.queue.common import QueueEmpty from calvin.runtime.north.plugins.port.queue.test.test_collect_unordered import TestCollectUnorderedFIFO pytest_unittest = pytest.m...
34.642857
104
0.554345
import pytest from calvin.runtime.north.plugins.port import queue from calvin.runtime.north.calvin_token import Token from calvin.runtime.north.plugins.port.queue.common import QueueEmpty from calvin.runtime.north.plugins.port.queue.test.test_collect_unordered import TestCollectUnorderedFIFO pytest_unittest = pytest.m...
2,704
54
273
92c65123a6c522968afa5a515527ab9b438ba792
1,706
py
Python
python/odml/nix_demo.py
mpsonntag/snippets
fc3cc42ea49b885c1f29c0aef1379055a931a978
[ "BSD-3-Clause" ]
null
null
null
python/odml/nix_demo.py
mpsonntag/snippets
fc3cc42ea49b885c1f29c0aef1379055a931a978
[ "BSD-3-Clause" ]
null
null
null
python/odml/nix_demo.py
mpsonntag/snippets
fc3cc42ea49b885c1f29c0aef1379055a931a978
[ "BSD-3-Clause" ]
null
null
null
import matplotlib.pyplot as plt import pandas as pd from pathlib import Path import nixio as nix fnbase = Path.joinpath(Path.home(), 'Chaos', 'work') fnraw = str(Path.joinpath(fnbase, '_Lab_Zimmer/calcium_imaging/results/N2/urx/shift210421/20120705Pflp178GCaMP5kshift210421W7URXx2.log')) ...
28.915254
129
0.743259
import matplotlib.pyplot as plt import pandas as pd from pathlib import Path import nixio as nix fnbase = Path.joinpath(Path.home(), 'Chaos', 'work') fnraw = str(Path.joinpath(fnbase, '_Lab_Zimmer/calcium_imaging/results/N2/urx/shift210421/20120705Pflp178GCaMP5kshift210421W7URXx2.log')) ...
0
0
0
1e91a5afa6e064ba7a41a2c596e40f3890588e36
12,082
py
Python
jupyros/ros_widgets.py
ihuicatl/jupyter-ros
ea9c9e89f0ebf82108ac4d96897b2c64e6f74563
[ "BSD-3-Clause" ]
null
null
null
jupyros/ros_widgets.py
ihuicatl/jupyter-ros
ea9c9e89f0ebf82108ac4d96897b2c64e6f74563
[ "BSD-3-Clause" ]
null
null
null
jupyros/ros_widgets.py
ihuicatl/jupyter-ros
ea9c9e89f0ebf82108ac4d96897b2c64e6f74563
[ "BSD-3-Clause" ]
null
null
null
############################################################################# # Copyright (c) Wolf Vollprecht, QuantStack # # # # Distributed under the terms of the BSD 3-Clause License. # # ...
35.02029
131
0.595514
############################################################################# # Copyright (c) Wolf Vollprecht, QuantStack # # # # Distributed under the terms of the BSD 3-Clause License. # # ...
5,035
0
282
a292b4b0b721e7945377bc0b2da0181e22768ebd
4,369
bzl
Python
nixpkgs/repositories.bzl
seewpx/rules_nixpkgs
1c02fe914763448398739bb295b858362bb2810b
[ "Apache-2.0" ]
null
null
null
nixpkgs/repositories.bzl
seewpx/rules_nixpkgs
1c02fe914763448398739bb295b858362bb2810b
[ "Apache-2.0" ]
null
null
null
nixpkgs/repositories.bzl
seewpx/rules_nixpkgs
1c02fe914763448398739bb295b858362bb2810b
[ "Apache-2.0" ]
null
null
null
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") load("@bazel_tools//tools/build_defs/repo:utils.bzl", "maybe") load("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository") def rules_nixpkgs_dependencies(rules_nixpkgs_name = "io_tweag_rules_nixpkgs"): """Load repositories required by r...
45.041237
126
0.613642
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") load("@bazel_tools//tools/build_defs/repo:utils.bzl", "maybe") load("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository") def rules_nixpkgs_dependencies(rules_nixpkgs_name = "io_tweag_rules_nixpkgs"): """Load repositories required by r...
0
0
0
8d09485db8efd21615a8b003ba88ca0a4332df60
2,041
py
Python
src/_dependencies/injectable.py
dry-python/dependencies
1a8bba41ab42d0b5249b36471f5300d9faba81e7
[ "BSD-2-Clause" ]
175
2018-07-21T13:04:44.000Z
2020-05-27T15:31:06.000Z
src/_dependencies/injectable.py
proofit404/dependencies
204e0cfadca801d64857f24aa4c74e7939ed9af0
[ "BSD-2-Clause" ]
325
2016-05-16T11:16:11.000Z
2022-03-04T00:45:57.000Z
src/_dependencies/injectable.py
dry-python/dependencies
1a8bba41ab42d0b5249b36471f5300d9faba81e7
[ "BSD-2-Clause" ]
18
2018-06-17T09:33:16.000Z
2020-05-20T18:12:30.000Z
from inspect import isclass from inspect import signature from _dependencies.exceptions import DependencyError # Messages. default_class_value_template = """ {owner} has a default value of {argument!r} argument set to {value!r} class. You should either change the name of the argument into '{argument}_class' ...
30.014706
76
0.680059
from inspect import isclass from inspect import signature from _dependencies.exceptions import DependencyError def _function_args(func, funcname, owner): arguments = _args(func, funcname, owner) return _separate(arguments) def _method_args(func, funcname, owner): arguments = _args(func, funcname, owner...
1,539
0
115
a027763e2428f3baf3eb8729ecd4250edf35d58d
347
py
Python
4_Applied ML with Python/Review/plot1.py
syedmeesamali/CourseraPlus
0e729d10938ecb55fde69433c6b02cb02b8e6d10
[ "MIT" ]
null
null
null
4_Applied ML with Python/Review/plot1.py
syedmeesamali/CourseraPlus
0e729d10938ecb55fde69433c6b02cb02b8e6d10
[ "MIT" ]
null
null
null
4_Applied ML with Python/Review/plot1.py
syedmeesamali/CourseraPlus
0e729d10938ecb55fde69433c6b02cb02b8e6d10
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt import numpy as np from sklearn.metrics import accuracy_score from sklearn.linear_model import LogisticRegression from sklearn.svm import SVC from sklearn.gaussian_process import GaussianProcessClassifier from sklearn.gaussian_process.kernels import RBF from sklearn import datasets i...
24.785714
62
0.855908
import matplotlib.pyplot as plt import numpy as np from sklearn.metrics import accuracy_score from sklearn.linear_model import LogisticRegression from sklearn.svm import SVC from sklearn.gaussian_process import GaussianProcessClassifier from sklearn.gaussian_process.kernels import RBF from sklearn import datasets i...
0
0
0
925fda38891dd3f10a9708584698f2913670ab94
3,267
py
Python
sstubs_miner/analysers/DataAnalyser.py
louislefevre/sstubs-research
95755b7adcc49149f9b13ee6a8d05a95b356570b
[ "Apache-2.0" ]
1
2020-12-06T18:49:10.000Z
2020-12-06T18:49:10.000Z
sstubs_miner/analysers/DataAnalyser.py
louislefevre/sstubs-miner
95755b7adcc49149f9b13ee6a8d05a95b356570b
[ "Apache-2.0" ]
null
null
null
sstubs_miner/analysers/DataAnalyser.py
louislefevre/sstubs-miner
95755b7adcc49149f9b13ee6a8d05a95b356570b
[ "Apache-2.0" ]
null
null
null
from datetime import datetime, timedelta from math import inf as infinity from statistics import mean
32.029412
96
0.607591
from datetime import datetime, timedelta from math import inf as infinity from statistics import mean class DataAnalyser: def __init__(self, sstubs): self._sstubs = sstubs self._builds = self._initialise_builds(sstubs) def sstub_count(self): return len(self._sstubs) def project_c...
2,667
474
23
b70fdc8bf52039d2c2d5c4f1ddb9c314fa9b21cc
7,140
py
Python
src/datasource.py
Muhazerin/auto-star-planner
4a4a2054dacdfd614b82c300eb8760fddc0a7260
[ "MIT" ]
1
2021-06-05T17:13:47.000Z
2021-06-05T17:13:47.000Z
src/datasource.py
Muhazerin/auto-star-planner
4a4a2054dacdfd614b82c300eb8760fddc0a7260
[ "MIT" ]
null
null
null
src/datasource.py
Muhazerin/auto-star-planner
4a4a2054dacdfd614b82c300eb8760fddc0a7260
[ "MIT" ]
1
2020-12-03T02:32:13.000Z
2020-12-03T02:32:13.000Z
import requests import re from bs4 import BeautifulSoup import indexParser source = DataSource()
46.666667
117
0.594818
import requests import re from bs4 import BeautifulSoup import indexParser class DataSource: def __init__(self): self.__acad_sem_dict = None # Dict self.__chosen_acad_sem = None # String self.__course_year_value = None # List self.__course_year_key = None # ...
6,281
736
23
5424c7e93680618774daa851b9a17447ac5087bb
421
py
Python
Library/app/migrations/0003_user_slug.py
kumarnishu/BOOKS-LIBRARY
28690850248acbe90bb47a37700f6152e047829c
[ "Apache-2.0" ]
1
2020-03-30T16:39:42.000Z
2020-03-30T16:39:42.000Z
Library/app/migrations/0003_user_slug.py
kumarnishu/BOOKS-LIBRARY
28690850248acbe90bb47a37700f6152e047829c
[ "Apache-2.0" ]
8
2021-03-19T01:21:01.000Z
2022-03-12T00:21:57.000Z
Library/app/migrations/0003_user_slug.py
kumarnishu/BOOKS-LIBRARY
28690850248acbe90bb47a37700f6152e047829c
[ "Apache-2.0" ]
null
null
null
# Generated by Django 3.0.2 on 2020-02-02 05:09 from django.db import migrations, models
21.05
59
0.589074
# Generated by Django 3.0.2 on 2020-02-02 05:09 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('app', '0002_auto_20200201_1054'), ] operations = [ migrations.AddField( model_name='user', name='slug', ...
0
307
23
e6b9b1217c4b0f3170afd80044dc33127aaf422c
4,210
py
Python
eval_shapes.py
VLL-HD/HINT
b26c5026bd486bb392a9416430cb1dfebe5aa06f
[ "MIT" ]
14
2020-03-23T20:31:27.000Z
2022-03-02T21:12:23.000Z
eval_shapes.py
VLL-HD/HINT
b26c5026bd486bb392a9416430cb1dfebe5aa06f
[ "MIT" ]
1
2020-04-02T17:44:26.000Z
2020-05-04T21:50:35.000Z
eval_shapes.py
VLL-HD/HINT
b26c5026bd486bb392a9416430cb1dfebe5aa06f
[ "MIT" ]
4
2020-04-02T17:45:40.000Z
2021-06-24T19:12:49.000Z
import numpy as np import traceback import multiprocessing as mp from tqdm import tqdm from best_shape_fit import * from data import PlusShapeModel configs = [ # 'plus_shape.conditional_cinn_4', # 'plus_shape.conditional_cinn_8', # 'plus_shape.conditional_hint_4_full', ...
31.41791
94
0.609026
import numpy as np import traceback import multiprocessing as mp from tqdm import tqdm from best_shape_fit import * from data import PlusShapeModel configs = [ # 'plus_shape.conditional_cinn_4', # 'plus_shape.conditional_cinn_8', # 'plus_shape.conditional_hint_4_full', ...
1,997
0
74
f7fca72e52232376356f35434e420a846dc84c45
850
py
Python
backend/utils.py
DenX/pixyship
b8c75d18bfcaf86e1d1c4d7de5b58a51175b9110
[ "MIT" ]
null
null
null
backend/utils.py
DenX/pixyship
b8c75d18bfcaf86e1d1c4d7de5b58a51175b9110
[ "MIT" ]
null
null
null
backend/utils.py
DenX/pixyship
b8c75d18bfcaf86e1d1c4d7de5b58a51175b9110
[ "MIT" ]
null
null
null
import time from config import CONFIG
20.238095
81
0.635294
import time from config import CONFIG def float_range(values, start_key, end_key): start = 0 if values[start_key]: start = float(values[start_key]) end = 0 if values[end_key]: end = float(values[end_key]) return start, end def int_range(values, start_key, end_key): start =...
667
48
92
9d9175a033fb44ad4b48daf8451547ae55922b48
6,298
py
Python
botto/core/models/jmdict.py
MusicOnline/Tango-Legacy
6c7b65924392a182fc01686cdd3a83638a64aaa4
[ "MIT" ]
2
2019-05-27T06:41:02.000Z
2020-03-18T19:08:45.000Z
botto/core/models/jmdict.py
MusicOnline/Tango
6c7b65924392a182fc01686cdd3a83638a64aaa4
[ "MIT" ]
null
null
null
botto/core/models/jmdict.py
MusicOnline/Tango
6c7b65924392a182fc01686cdd3a83638a64aaa4
[ "MIT" ]
null
null
null
from botto.core.bot import Botto db = Botto.db # pylint: disable=no-member
34.415301
88
0.636075
from botto.core.bot import Botto db = Botto.db # pylint: disable=no-member class Entry(db.Model): # type: ignore # <entry> __tablename__ = "JMdict_Entry" id = db.Column(db.Integer, primary_key=True) # <ent_seq> def __repr__(self) -> str: return "<Entry id={0.id}>".format(self) class Writi...
1,314
4,691
207
06248ee30f4354aece78fbe7fb4ab9742f2eb407
1,161
py
Python
utils/parse_arguments.py
xujinzh/csk
136002da069d300fc2da9ae8530861818087ff40
[ "BSD-2-Clause" ]
4
2021-09-21T14:24:11.000Z
2022-02-27T06:46:11.000Z
utils/parse_arguments.py
xujinzh/CSK
136002da069d300fc2da9ae8530861818087ff40
[ "BSD-2-Clause" ]
null
null
null
utils/parse_arguments.py
xujinzh/CSK
136002da069d300fc2da9ae8530861818087ff40
[ "BSD-2-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Author : Jinzhong Xu # @Contact : jinzhongxu@csu.ac.cn # @Time : 10/12/2020 3:56 PM # @File : parse_arguments.py # @Software: PyCharm import os from optparse import OptionParser
32.25
88
0.587425
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Author : Jinzhong Xu # @Contact : jinzhongxu@csu.ac.cn # @Time : 10/12/2020 3:56 PM # @File : parse_arguments.py # @Software: PyCharm import os from optparse import OptionParser def parse_arguments(): parser = OptionParser() parser.descrip...
889
0
25
fda6cb12c17fb53e321e374fd86da7176480a1f1
1,005
py
Python
Python OOP/OOP/Static and Class Methods/Lab/Task03.py
IvanTodorovBG/SoftUni
7b667f6905d9f695ab1484efbb02b6715f6d569e
[ "MIT" ]
1
2022-03-16T10:23:04.000Z
2022-03-16T10:23:04.000Z
Python OOP/OOP/Static and Class Methods/Lab/Task03.py
IvanTodorovBG/SoftUni
7b667f6905d9f695ab1484efbb02b6715f6d569e
[ "MIT" ]
null
null
null
Python OOP/OOP/Static and Class Methods/Lab/Task03.py
IvanTodorovBG/SoftUni
7b667f6905d9f695ab1484efbb02b6715f6d569e
[ "MIT" ]
null
null
null
import math first_num = Integer(10) print(first_num.value) second_num = Integer.from_roman("IV") print(second_num.value) print(Integer.from_float("2.6")) print(Integer.from_string(2.6))
25.125
72
0.579104
import math class Integer: def __init__(self, value: int): self.value = value @classmethod def from_float(cls, float_value): if type(float_value) != float: return "value is not a float" return cls(math.floor(float_value)) @classmethod def from_roman(cls, value...
640
151
23
0bb36db59fbc86162f8a7314f21f36a272c8c5ba
2,067
py
Python
InvenTree/InvenTree/test_api.py
linucks/InvenTree
fa789036e0ae7d56ced3c9e1f2d2ff596983a365
[ "MIT" ]
null
null
null
InvenTree/InvenTree/test_api.py
linucks/InvenTree
fa789036e0ae7d56ced3c9e1f2d2ff596983a365
[ "MIT" ]
8
2020-06-06T01:14:46.000Z
2022-03-12T00:14:35.000Z
InvenTree/InvenTree/test_api.py
linucks/InvenTree
fa789036e0ae7d56ced3c9e1f2d2ff596983a365
[ "MIT" ]
null
null
null
""" Low level tests for the InvenTree API """ from rest_framework.test import APITestCase from rest_framework import status from django.urls import reverse from django.contrib.auth import get_user_model class APITests(APITestCase): """ Tests for the InvenTree API """ fixtures = [ 'location', ...
30.397059
122
0.652637
""" Low level tests for the InvenTree API """ from rest_framework.test import APITestCase from rest_framework import status from django.urls import reverse from django.contrib.auth import get_user_model class APITests(APITestCase): """ Tests for the InvenTree API """ fixtures = [ 'location', ...
154
0
27
d88bfd8d597623db85bd482852228fa9b0e0d6c4
580
py
Python
test/test_formatter.py
ta08/girepo
73ce6dd108428590a69fbe19fe1ad8b337d4462f
[ "Apache-2.0" ]
null
null
null
test/test_formatter.py
ta08/girepo
73ce6dd108428590a69fbe19fe1ad8b337d4462f
[ "Apache-2.0" ]
27
2019-09-05T15:36:10.000Z
2021-07-13T20:23:14.000Z
test/test_formatter.py
ta08/girepo
73ce6dd108428590a69fbe19fe1ad8b337d4462f
[ "Apache-2.0" ]
null
null
null
from unittest import TestCase from girepo.formatter import beautify_text
29
57
0.55
from unittest import TestCase from girepo.formatter import beautify_text class TestFormatter(TestCase): def test_beautify_text(self): test_data = [ ("Hello World", "|", "Hello World"), ("Hello | World", "|", "Hello \| World"), ("Hello $ World", "$", "Hello \$ World"),...
446
9
50
8fbe9592818a42e980cd5c36fa7ec5bfffa7c074
146
py
Python
ex014.py
ChrysWillians/exercicios-python3
354c8684cbc9de0c734e6a40e76e2f613845de96
[ "MIT" ]
1
2021-09-26T01:08:36.000Z
2021-09-26T01:08:36.000Z
ex014.py
ChrysWillians/exercicios-python3
354c8684cbc9de0c734e6a40e76e2f613845de96
[ "MIT" ]
null
null
null
ex014.py
ChrysWillians/exercicios-python3
354c8684cbc9de0c734e6a40e76e2f613845de96
[ "MIT" ]
null
null
null
c = float(input('Digite a temperatura para ser convertida: ')) f = ((9*c)/5)+32 print('A temperatura de {}ºC, é igual a {}ºF!'.format(c, f))
29.2
63
0.616438
c = float(input('Digite a temperatura para ser convertida: ')) f = ((9*c)/5)+32 print('A temperatura de {}ºC, é igual a {}ºF!'.format(c, f))
0
0
0
9f25517180c05a14e99b59867617e829be8fc282
19,378
py
Python
capsnet-arch/train.py
eaaskt/nlu
77382be572ce59f15d8ea9c5cd653615c39891d1
[ "MIT" ]
3
2019-03-11T09:15:36.000Z
2020-04-06T15:06:33.000Z
capsnet-arch/train.py
eaaskt/nlu
77382be572ce59f15d8ea9c5cd653615c39891d1
[ "MIT" ]
24
2020-03-31T11:22:54.000Z
2022-03-12T00:23:49.000Z
capsnet-arch/train.py
eaaskt/nlu
77382be572ce59f15d8ea9c5cd653615c39891d1
[ "MIT" ]
5
2020-03-29T10:04:31.000Z
2020-05-28T06:50:18.000Z
import math import os from random import * import data_loader import model_s2i import util import flags import errno import json import numpy as np import tensorflow as tf from seqeval.metrics import accuracy_score from seqeval.metrics import f1_score from seqeval.metrics import precision_score from seqeval.metrics im...
45.275701
136
0.655537
import math import os from random import * import data_loader import model_s2i import util import flags import errno import json import numpy as np import tensorflow as tf from seqeval.metrics import accuracy_score from seqeval.metrics import f1_score from seqeval.metrics import precision_score from seqeval.metrics im...
3,650
0
46
fa35b3feb2f0012a2c86cb320ec2b287c6644569
2,132
py
Python
dataset.py
youngsend/behavioral-cloning
8d4e3aeb964005c0594b8b7468e3b5352b54fb90
[ "MIT" ]
null
null
null
dataset.py
youngsend/behavioral-cloning
8d4e3aeb964005c0594b8b7468e3b5352b54fb90
[ "MIT" ]
null
null
null
dataset.py
youngsend/behavioral-cloning
8d4e3aeb964005c0594b8b7468e3b5352b54fb90
[ "MIT" ]
null
null
null
import os import random import torch import pandas as pd import torchvision.transforms.functional as T_F from torch.utils.data import Dataset from PIL import Image class BehaviorCloneDataset(Dataset): """ Behavioral cloning dataset. I referred to https://pytorch.org/tutorials/beginner/data_loading_tutoria...
34.95082
117
0.640713
import os import random import torch import pandas as pd import torchvision.transforms.functional as T_F from torch.utils.data import Dataset from PIL import Image class BehaviorCloneDataset(Dataset): """ Behavioral cloning dataset. I referred to https://pytorch.org/tutorials/beginner/data_loading_tutoria...
1,070
0
54
5055c590ee27d86e094c6eb93148926211ad9ca4
415
py
Python
zerver/migrations/0188_userprofile_enable_login_emails.py
TylerPham2000/zulip
2e7aaba0dde5517b4a55cb0bd782f009be45e3ba
[ "Apache-2.0" ]
17,004
2015-09-25T18:27:24.000Z
2022-03-31T22:02:32.000Z
zerver/migrations/0188_userprofile_enable_login_emails.py
TylerPham2000/zulip
2e7aaba0dde5517b4a55cb0bd782f009be45e3ba
[ "Apache-2.0" ]
20,344
2015-09-25T19:02:42.000Z
2022-03-31T23:54:40.000Z
zerver/migrations/0188_userprofile_enable_login_emails.py
TylerPham2000/zulip
2e7aaba0dde5517b4a55cb0bd782f009be45e3ba
[ "Apache-2.0" ]
7,271
2015-09-25T18:48:39.000Z
2022-03-31T21:06:11.000Z
# Generated by Django 1.11.14 on 2018-08-22 09:57 from django.db import migrations, models
21.842105
56
0.626506
# Generated by Django 1.11.14 on 2018-08-22 09:57 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ("zerver", "0187_userprofile_is_billing_admin"), ] operations = [ migrations.AddField( model_name="userprofile", nam...
0
299
23
dd0482f8708b53c479a409a1122ba3e19eb16cdc
1,061
py
Python
nettest/utils.py
public0821/nettest
0fed7949526640dd55dda51ba37a98e1ab7e9109
[ "Apache-2.0" ]
2
2016-06-29T08:01:58.000Z
2020-11-25T02:51:29.000Z
nettest/utils.py
public0821/nettest
0fed7949526640dd55dda51ba37a98e1ab7e9109
[ "Apache-2.0" ]
null
null
null
nettest/utils.py
public0821/nettest
0fed7949526640dd55dda51ba37a98e1ab7e9109
[ "Apache-2.0" ]
1
2020-11-24T07:05:24.000Z
2020-11-24T07:05:24.000Z
import struct import array def mac2str(mac): """Converts mac address to string . Args: mac: 6 bytes mac address Returns: readable string """ return '%02x:%02x:%02x:%02x:%02x:%02x'%tuple(int(x) for x in struct.unpack('BBBBBB', mac)) def str2mac...
23.065217
94
0.531574
import struct import array def mac2str(mac): """Converts mac address to string . Args: mac: 6 bytes mac address Returns: readable string """ return '%02x:%02x:%02x:%02x:%02x:%02x'%tuple(int(x) for x in struct.unpack('BBBBBB', mac)) def str2mac...
0
0
0
343669861f664697fc3420138a36fe9eb392d316
21,927
py
Python
script/panda_grasp.py
Hymwgk/gpg
07bb0c3a357ba2ac21bc179ba57584fee9eda6d3
[ "BSD-2-Clause" ]
null
null
null
script/panda_grasp.py
Hymwgk/gpg
07bb0c3a357ba2ac21bc179ba57584fee9eda6d3
[ "BSD-2-Clause" ]
null
null
null
script/panda_grasp.py
Hymwgk/gpg
07bb0c3a357ba2ac21bc179ba57584fee9eda6d3
[ "BSD-2-Clause" ]
null
null
null
#!/usr/bin/env python #coding=utf-8 """ moveit_ik_demo.py - Version 0.1 2014-01-14 Use inverse kinemtatics to move the end effector to a specified pose Created for the Pi Robot Project: http://www.pirobot.org Copyleft (c) 2014 Patrick Goebel. All lefts reserved. This program is free software;...
38.333916
136
0.634879
#!/usr/bin/env python #coding=utf-8 """ moveit_ik_demo.py - Version 0.1 2014-01-14 Use inverse kinemtatics to move the end effector to a specified pose Created for the Pi Robot Project: http://www.pirobot.org Copyleft (c) 2014 Patrick Goebel. All lefts reserved. This program is free software;...
12,325
9,540
23
3f86479e0b03f5d196f79e5392543c14b05df6c0
20,008
py
Python
opennem/db/models/opennem.py
tourdownunder/opennem
deec3e2079db9d9d84171010fd0c239170d1e7ce
[ "MIT" ]
null
null
null
opennem/db/models/opennem.py
tourdownunder/opennem
deec3e2079db9d9d84171010fd0c239170d1e7ce
[ "MIT" ]
1
2020-09-06T04:17:59.000Z
2020-09-06T04:17:59.000Z
opennem/db/models/opennem.py
tourdownunder/opennem
deec3e2079db9d9d84171010fd0c239170d1e7ce
[ "MIT" ]
null
null
null
""" OpenNEM primary schema adapted to support multiple energy sources Currently supported: - NEM - WEM """ from decimal import Decimal from typing import Optional from dictalchemy import DictableModel from geoalchemy2 import Geometry from shapely import wkb from sqlalchemy import ( JSON, Boo...
27.445816
141
0.636795
""" OpenNEM primary schema adapted to support multiple energy sources Currently supported: - NEM - WEM """ from decimal import Decimal from typing import Optional from dictalchemy import DictableModel from geoalchemy2 import Geometry from shapely import wkb from sqlalchemy import ( JSON, Boo...
2,471
14,606
330
1088673daa0097667a5fca816f207d5e564b7fe1
22
py
Python
factest/data_service/__init__.py
zzb610/factest
1e628f6fc885cd1975c2e68181caf40e2874dc08
[ "MIT" ]
4
2020-12-17T11:45:09.000Z
2020-12-20T05:42:55.000Z
factest/data_service/__init__.py
zzb610/factest
1e628f6fc885cd1975c2e68181caf40e2874dc08
[ "MIT" ]
null
null
null
factest/data_service/__init__.py
zzb610/factest
1e628f6fc885cd1975c2e68181caf40e2874dc08
[ "MIT" ]
null
null
null
name = 'data_service'
11
21
0.727273
name = 'data_service'
0
0
0
5d52583f6c7ba537e0737f4e7009f8e8792c8c36
6,037
py
Python
wifi_direct/wfd.py
sabzo/PiDroid
8f80f751424335cee89ff6455255e65c06f1ea10
[ "Apache-2.0" ]
16
2017-01-04T20:50:39.000Z
2021-09-15T17:23:34.000Z
wifi_direct/wfd.py
sabzo/PiDroid
8f80f751424335cee89ff6455255e65c06f1ea10
[ "Apache-2.0" ]
null
null
null
wifi_direct/wfd.py
sabzo/PiDroid
8f80f751424335cee89ff6455255e65c06f1ea10
[ "Apache-2.0" ]
8
2016-02-02T21:27:37.000Z
2021-04-21T11:17:04.000Z
# -*- coding: UTF-8 -*- # This file is forked from Piracast (July 2014): https://github.com/codemonkeyricky/piracast # import re import time from util import get_stdout cmd_killall_wpa_spplicant = 'killall wpa_supplicant' cmd_killall_hostapd = 'killall hostapd' cmd_iwlist_wlan0_scan = 'iwlist wl...
23.490272
96
0.598807
# -*- coding: UTF-8 -*- # This file is forked from Piracast (July 2014): https://github.com/codemonkeyricky/piracast # import re import time from util import get_stdout cmd_killall_wpa_spplicant = 'killall wpa_supplicant' cmd_killall_hostapd = 'killall hostapd' cmd_iwlist_wlan0_scan = 'iwlist wl...
5,038
0
365
dbd5a54d0bb2ef3bda2378f863fa670f59924a50
2,301
py
Python
stock_portfolio/stock_portfolio/views/auth.py
tyler-fishbone/pyramid-stocks
2d7c5a9aa74d5a9eec04005a99af25048a6666df
[ "MIT" ]
null
null
null
stock_portfolio/stock_portfolio/views/auth.py
tyler-fishbone/pyramid-stocks
2d7c5a9aa74d5a9eec04005a99af25048a6666df
[ "MIT" ]
3
2019-12-26T16:42:46.000Z
2021-06-01T22:22:44.000Z
stock_portfolio/views/auth.py
tyler-fishbone/new_stock_portfolio
05ec449b4a5798f197e1e147151a1c222cb26f9d
[ "MIT" ]
null
null
null
from pyramid.response import Response from pyramid.view import view_config # from ..sample_data import MOCK_DATA from sqlalchemy.exc import DBAPIError, IntegrityError from pyramid.httpexceptions import HTTPFound, HTTPNotFound, HTTPUnauthorized, HTTPBadRequest from pyramid.security import NO_PERMISSION_REQUIRED, remembe...
34.343284
103
0.646241
from pyramid.response import Response from pyramid.view import view_config # from ..sample_data import MOCK_DATA from sqlalchemy.exc import DBAPIError, IntegrityError from pyramid.httpexceptions import HTTPFound, HTTPNotFound, HTTPUnauthorized, HTTPBadRequest from pyramid.security import NO_PERMISSION_REQUIRED, remembe...
1,677
0
44
fa4c82bd5e9d1c1ab8d0a807e0ed131f0e310820
4,310
py
Python
src/datasets/samplers.py
achariso/gans-thesis
cde09fec4b617da47b74f5ecbf2ac2f9444c3634
[ "MIT" ]
2
2021-07-28T07:48:20.000Z
2021-07-29T13:14:42.000Z
src/datasets/samplers.py
achariso/gans-thesis
cde09fec4b617da47b74f5ecbf2ac2f9444c3634
[ "MIT" ]
1
2021-10-31T21:15:39.000Z
2021-10-31T21:15:39.000Z
src/datasets/samplers.py
achariso/gans-thesis
cde09fec4b617da47b74f5ecbf2ac2f9444c3634
[ "MIT" ]
null
null
null
from typing import Union, Sized import numpy as np import torch from torch.utils.data import Sampler from utils.command_line_logger import CommandLineLogger class InfiniteSampler(Sampler): """ InfiniteSampler Class: Sampler for torch.utils.data.DataLoader that loops over the dataset indefinitely, shuffl...
35.619835
118
0.617633
from typing import Union, Sized import numpy as np import torch from torch.utils.data import Sampler from utils.command_line_logger import CommandLineLogger class InfiniteSampler(Sampler): """ InfiniteSampler Class: Sampler for torch.utils.data.DataLoader that loops over the dataset indefinitely, shuffl...
2,299
0
216
cdf623d62d45366dbca8833e23fde4ea5943179d
14,782
py
Python
primehub/__init__.py
InfuseAI/primehub-python-sdk
edbdbcb3e41f0c99e4542245de1345a64f509fb4
[ "Apache-2.0" ]
10
2021-09-13T23:14:22.000Z
2022-02-06T06:07:40.000Z
primehub/__init__.py
KellenJohn/primehub-python-sdk
edbdbcb3e41f0c99e4542245de1345a64f509fb4
[ "Apache-2.0" ]
4
2021-08-10T03:10:27.000Z
2021-12-16T02:11:50.000Z
primehub/__init__.py
KellenJohn/primehub-python-sdk
edbdbcb3e41f0c99e4542245de1345a64f509fb4
[ "Apache-2.0" ]
1
2021-12-21T11:59:51.000Z
2021-12-21T11:59:51.000Z
import abc import importlib import json import os import sys from typing import Union, Callable, Any from primehub.utils import group_required, create_logger, PrimeHubException from primehub.utils.core import CommandContainer from primehub.utils.decorators import cmd # noqa: F401 from primehub.utils.display import Di...
32.559471
114
0.636991
import abc import importlib import json import os import sys from typing import Union, Callable, Any from primehub.utils import group_required, create_logger, PrimeHubException from primehub.utils.core import CommandContainer from primehub.utils.decorators import cmd # noqa: F401 from primehub.utils.display import Di...
9,755
1,900
512
ce9e0db3f30d2be75fb0fc0351d471e23abcab55
168
py
Python
Werewolf/WP/__init__.py
HuangFuSL/Werewolf
4791aa4b743acb810c86e1bad6b2442b38e2821c
[ "MIT" ]
3
2020-10-24T09:04:59.000Z
2020-11-23T03:49:27.000Z
Werewolf/WP/__init__.py
HuangFuSL/Werewolf
4791aa4b743acb810c86e1bad6b2442b38e2821c
[ "MIT" ]
8
2020-11-11T04:07:53.000Z
2020-11-23T04:37:53.000Z
Werewolf/WP/__init__.py
HuangFuSL/Werewolf
4791aa4b743acb810c86e1bad6b2442b38e2821c
[ "MIT" ]
3
2020-10-18T13:23:55.000Z
2020-11-08T16:27:48.000Z
""" The protocol for the werewolf game """ import os import socket import sys from .api import ChunckedData, ReceiveThread, _recv, TimeLock, KillableThread, ReadInput
18.666667
88
0.785714
""" The protocol for the werewolf game """ import os import socket import sys from .api import ChunckedData, ReceiveThread, _recv, TimeLock, KillableThread, ReadInput
0
0
0
7f0e7f9590442369c6f34ff92071d31f95b824ae
1,093
py
Python
gunicorn_logstash_formatter/gunicorn_logstash_formatter.py
alphagov/gunicorn-logstash-formatter
0787016e085b40856f2b1d07ce753523a05f8bdb
[ "MIT" ]
1
2020-05-03T09:27:12.000Z
2020-05-03T09:27:12.000Z
gunicorn_logstash_formatter/gunicorn_logstash_formatter.py
alphagov/gunicorn-logstash-formatter
0787016e085b40856f2b1d07ce753523a05f8bdb
[ "MIT" ]
2
2017-10-11T23:02:25.000Z
2019-06-04T17:26:28.000Z
gunicorn_logstash_formatter/gunicorn_logstash_formatter.py
alphagov/gunicorn-logstash-formatter
0787016e085b40856f2b1d07ce753523a05f8bdb
[ "MIT" ]
3
2017-10-11T23:16:28.000Z
2021-04-10T19:54:03.000Z
# -*- coding: utf-8 -*- """Main module.""" import json import logging # this only works with post-19.7.1 gunicorn to pull in commit 610596c9 # which logs separate format and args
33.121212
73
0.505032
# -*- coding: utf-8 -*- """Main module.""" import json import logging # this only works with post-19.7.1 gunicorn to pull in commit 610596c9 # which logs separate format and args class AccessFormatter(logging.Formatter): def __init__(self, *args, **kwargs): pass def format(self, record): msg...
816
20
75
c0f734da732f372e948a1ca81000809240a47e74
403
py
Python
ee/urls.py
jessethegame/posthog
f6f6e2e91ef211df1d980e5aedbc8145d54a3dff
[ "MIT" ]
null
null
null
ee/urls.py
jessethegame/posthog
f6f6e2e91ef211df1d980e5aedbc8145d54a3dff
[ "MIT" ]
null
null
null
ee/urls.py
jessethegame/posthog
f6f6e2e91ef211df1d980e5aedbc8145d54a3dff
[ "MIT" ]
null
null
null
from rest_framework_extensions.routers import NestedRegistryItem from posthog.api.routing import DefaultRouterPlusPlus from .api import hooks, license
36.636364
98
0.82134
from rest_framework_extensions.routers import NestedRegistryItem from posthog.api.routing import DefaultRouterPlusPlus from .api import hooks, license def extend_api_router(root_router: DefaultRouterPlusPlus, *, projects_router: NestedRegistryItem): root_router.register(r"license", license.LicenseViewSet) p...
226
0
23
40710d8467979f15b42d1c45bd0a92775dacde11
9,907
py
Python
src/rogerthat/bizz/news/influx/__init__.py
goubertbrent/oca-backend
b9f59cc02568aecb55d4b54aec05245790ea25fd
[ "Apache-2.0" ]
null
null
null
src/rogerthat/bizz/news/influx/__init__.py
goubertbrent/oca-backend
b9f59cc02568aecb55d4b54aec05245790ea25fd
[ "Apache-2.0" ]
null
null
null
src/rogerthat/bizz/news/influx/__init__.py
goubertbrent/oca-backend
b9f59cc02568aecb55d4b54aec05245790ea25fd
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2020 Green Valley Belgium NV # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appl...
47.401914
119
0.62683
# -*- coding: utf-8 -*- # Copyright 2020 Green Valley Belgium NV # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appl...
8,444
0
184
e8eef6e7da1adab3641ffa7a4ccbd1615df1d5c7
303
py
Python
mindhome_alpha/erpnext/patches/v7_2/update_website_for_variant.py
Mindhome/field_service
3aea428815147903eb9af1d0c1b4b9fc7faed057
[ "MIT" ]
1
2021-04-29T14:55:29.000Z
2021-04-29T14:55:29.000Z
mindhome_alpha/erpnext/patches/v7_2/update_website_for_variant.py
Mindhome/field_service
3aea428815147903eb9af1d0c1b4b9fc7faed057
[ "MIT" ]
null
null
null
mindhome_alpha/erpnext/patches/v7_2/update_website_for_variant.py
Mindhome/field_service
3aea428815147903eb9af1d0c1b4b9fc7faed057
[ "MIT" ]
1
2021-04-29T14:39:01.000Z
2021-04-29T14:39:01.000Z
from __future__ import unicode_literals import frappe
23.307692
40
0.726073
from __future__ import unicode_literals import frappe def execute(): # variant must have show_in_website = 0 frappe.reload_doctype('Item') frappe.db.sql(''' update tabItem set show_variant_in_website = 1, show_in_website = 0 where show_in_website=1 and ifnull(variant_of, "")!=""''')
227
0
23
3f80b87d12d499c59e0bbc921240b76b2fa3a219
3,381
py
Python
SyslogIP.py
sschaefervmw/vshieldSyslog
a2b42b37fdb79e7e94febec22e7bc76a6c0d6c43
[ "Unlicense" ]
2
2015-03-12T09:53:27.000Z
2015-03-13T21:25:02.000Z
SyslogIP.py
sschaefervmw/vshieldSyslog
a2b42b37fdb79e7e94febec22e7bc76a6c0d6c43
[ "Unlicense" ]
null
null
null
SyslogIP.py
sschaefervmw/vshieldSyslog
a2b42b37fdb79e7e94febec22e7bc76a6c0d6c43
[ "Unlicense" ]
null
null
null
# coding=utf-8 import requests import getpass from requests.auth import HTTPBasicAuth import xml.etree.ElementTree as ET API_URL = "Place vCD URL Here" #Cloud API URL ending in /api/ EDGE_NAME = 'Place Edge Name Here' #Edge Gateway Name SYSLOG_IP = 'Place Syslog IP Here' #IP of syslog server USERNAME = 'Place Usernam...
40.25
131
0.656906
# coding=utf-8 import requests import getpass from requests.auth import HTTPBasicAuth import xml.etree.ElementTree as ET API_URL = "Place vCD URL Here" #Cloud API URL ending in /api/ EDGE_NAME = 'Place Edge Name Here' #Edge Gateway Name SYSLOG_IP = 'Place Syslog IP Here' #IP of syslog server USERNAME = 'Place Usernam...
2,235
515
177
cd21e79a44fe5ee27387f892bb515f4bb277f8fa
5,318
py
Python
redditscript.py
Azl-Eyekay/channel-keepalive
a3aaf4fa5e716484c7ede35be37aeeab26e024fd
[ "MIT" ]
null
null
null
redditscript.py
Azl-Eyekay/channel-keepalive
a3aaf4fa5e716484c7ede35be37aeeab26e024fd
[ "MIT" ]
null
null
null
redditscript.py
Azl-Eyekay/channel-keepalive
a3aaf4fa5e716484c7ede35be37aeeab26e024fd
[ "MIT" ]
null
null
null
# Installed python3-praw, geany and ffmpeg from debian # and others from pip # Made a Reddit account, set up an application and added its client id and secret # made a white noise video named noise.mkv and downloaded 3 pieces of music as music{0-1}.mp3 import praw from PIL import Image, ImageDraw, ImageFont import url...
42.887097
246
0.657202
# Installed python3-praw, geany and ffmpeg from debian # and others from pip # Made a Reddit account, set up an application and added its client id and secret # made a white noise video named noise.mkv and downloaded 3 pieces of music as music{0-1}.mp3 import praw from PIL import Image, ImageDraw, ImageFont import url...
0
0
0
c4c26982ca660d6c3c28d85eb698c83bf6259908
210
py
Python
shot_detector/services/__init__.py
w495/shot_detector
617ff45c9c3c96bbd9a975aef15f1b2697282b9c
[ "BSD-3-Clause" ]
18
2015-09-27T21:34:18.000Z
2022-03-24T12:14:51.000Z
shot_detector/services/__init__.py
w495/shot_detector
617ff45c9c3c96bbd9a975aef15f1b2697282b9c
[ "BSD-3-Clause" ]
6
2021-03-18T21:21:35.000Z
2022-03-11T23:32:55.000Z
shot_detector/services/__init__.py
w495/shot_detector
617ff45c9c3c96bbd9a975aef15f1b2697282b9c
[ "BSD-3-Clause" ]
3
2017-09-14T20:53:26.000Z
2021-12-18T19:18:18.000Z
# -*- coding: utf8 -*- """ Services """ from __future__ import absolute_import, division, print_function from .base_service import BaseService from .shot_detector_service import ShotDetectorPlotService
19.090909
64
0.771429
# -*- coding: utf8 -*- """ Services """ from __future__ import absolute_import, division, print_function from .base_service import BaseService from .shot_detector_service import ShotDetectorPlotService
0
0
0
bca359f6502b4247bcc9867263ccbe22ad06b24c
174
py
Python
eplot/__init__.py
SophiaHanx/eplot
1cc104bba6c41fe3cce98a24e2c722a890cef2c2
[ "MIT" ]
76
2019-02-04T05:05:56.000Z
2021-12-26T05:56:07.000Z
eplot/__init__.py
SophiaHanx/eplot
1cc104bba6c41fe3cce98a24e2c722a890cef2c2
[ "MIT" ]
5
2019-05-13T02:45:39.000Z
2022-03-27T14:57:16.000Z
eplot/__init__.py
SophiaHanx/eplot
1cc104bba6c41fe3cce98a24e2c722a890cef2c2
[ "MIT" ]
18
2019-05-13T02:45:46.000Z
2021-08-10T00:32:57.000Z
#! /usr/bin/env python # -*- coding: utf-8 -*- """ @version: 0.1 @author: pjgao @city: Nanjing @file: __init__.py.py @time: 2018/12/10 16:22 """ __version__ = '0.1.1'
15.818182
26
0.586207
#! /usr/bin/env python # -*- coding: utf-8 -*- """ @version: 0.1 @author: pjgao @city: Nanjing @file: __init__.py.py @time: 2018/12/10 16:22 """ __version__ = '0.1.1'
0
0
0
ee1b696fd0dd9bef0ddf714611f2ae67f9df1f0d
1,067
py
Python
jussi/middlewares/__init__.py
bnchdrff/jussi
79d8decde323b84cdd8331e5cbb490021ea78cee
[ "MIT" ]
null
null
null
jussi/middlewares/__init__.py
bnchdrff/jussi
79d8decde323b84cdd8331e5cbb490021ea78cee
[ "MIT" ]
null
null
null
jussi/middlewares/__init__.py
bnchdrff/jussi
79d8decde323b84cdd8331e5cbb490021ea78cee
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from .jsonrpc import validate_jsonrpc_request from .jussi import finalize_jussi_response from .jussi import convert_to_jussi_request from .limits import check_limits from .caching import get_response from .caching import cache_response from .update_block_num import update_last_irreversible_bloc...
35.566667
77
0.811621
# -*- coding: utf-8 -*- from .jsonrpc import validate_jsonrpc_request from .jussi import finalize_jussi_response from .jussi import convert_to_jussi_request from .limits import check_limits from .caching import get_response from .caching import cache_response from .update_block_num import update_last_irreversible_bloc...
717
0
23
5752b7e60dffe0e263eaf7ca7c23f9cbf7ed6ee4
5,072
py
Python
Book/chap1/python/chap1_intro.py
lorenghoh/pyman
9b4ddd52c5577fc85e2601ae3128f398f0eb673c
[ "CC0-1.0" ]
3
2020-04-30T19:50:11.000Z
2020-10-17T02:07:00.000Z
Book/chap1/python/chap1_intro.py
lorenghoh/pyman
9b4ddd52c5577fc85e2601ae3128f398f0eb673c
[ "CC0-1.0" ]
35
2020-04-21T04:25:31.000Z
2021-11-06T22:49:44.000Z
Book/chap1/python/chap1_intro.py
lorenghoh/pyman
9b4ddd52c5577fc85e2601ae3128f398f0eb673c
[ "CC0-1.0" ]
11
2020-04-21T04:33:48.000Z
2020-10-23T21:12:12.000Z
# --- # jupyter: # jupytext: # cell_metadata_filter: all # notebook_metadata_filter: all,-language_info # text_representation: # extension: .py # format_name: percent # format_version: '1.2' # jupytext_version: 1.2.1 # kernelspec: # display_name: Python 3 # language: pyth...
48.769231
474
0.743494
# --- # jupyter: # jupytext: # cell_metadata_filter: all # notebook_metadata_filter: all,-language_info # text_representation: # extension: .py # format_name: percent # format_version: '1.2' # jupytext_version: 1.2.1 # kernelspec: # display_name: Python 3 # language: pyth...
0
0
0
9e12d44f5d5d039463c31ca6d9efbeeca62f298e
5,812
py
Python
src/python/janelia_emrp/zcorr/plot_z_coords.py
JaneliaSciComp/EM_recon_pipeline
0a1076aaa0de24623014902a4c7ee9741a0730fb
[ "BSD-3-Clause" ]
null
null
null
src/python/janelia_emrp/zcorr/plot_z_coords.py
JaneliaSciComp/EM_recon_pipeline
0a1076aaa0de24623014902a4c7ee9741a0730fb
[ "BSD-3-Clause" ]
null
null
null
src/python/janelia_emrp/zcorr/plot_z_coords.py
JaneliaSciComp/EM_recon_pipeline
0a1076aaa0de24623014902a4c7ee9741a0730fb
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python import glob import os import sys from bokeh.io import output_file from bokeh.models import SingleIntervalTicker from bokeh.plotting import figure, show if __name__ == '__main__': if len(sys.argv) < 4: print(f'USAGE: {sys.argv[0]} <owner> <project> <stack> <run> [label ...]') ...
34.188235
111
0.639195
#!/usr/bin/env python import glob import os import sys from bokeh.io import output_file from bokeh.models import SingleIntervalTicker from bokeh.plotting import figure, show def load_z_coords_file_data(z_coords_path): z_values = [] delta_values = [] layer_count = 0 first_z = None previous_corre...
5,141
0
115
18b61b5c3fb43146fb5267cd7120f9d26e8dde9f
148
py
Python
paralleldomain/constants.py
parallel-domain/pd-sdk
20e3d052a5cb612a2dd84bda7b1b5487a6a60edc
[ "Apache-2.0" ]
10
2021-11-17T17:23:49.000Z
2022-03-18T09:51:23.000Z
paralleldomain/constants.py
parallel-domain/pd-sdk
20e3d052a5cb612a2dd84bda7b1b5487a6a60edc
[ "Apache-2.0" ]
3
2021-12-02T17:16:20.000Z
2022-01-07T12:47:13.000Z
paralleldomain/constants.py
parallel-domain/pd-sdk
20e3d052a5cb612a2dd84bda7b1b5487a6a60edc
[ "Apache-2.0" ]
2
2022-03-09T07:03:54.000Z
2022-03-23T15:53:48.000Z
CAMERA_MODEL_OPENCV_PINHOLE: str = "opencv_pinhole" CAMERA_MODEL_OPENCV_FISHEYE: str = "opencv_fisheye" CAMERA_MODEL_PD_FISHEYE: str = "pd_fisheye"
37
51
0.837838
CAMERA_MODEL_OPENCV_PINHOLE: str = "opencv_pinhole" CAMERA_MODEL_OPENCV_FISHEYE: str = "opencv_fisheye" CAMERA_MODEL_PD_FISHEYE: str = "pd_fisheye"
0
0
0
c1639b26a8e3699cd950a8a4897360c1ca8da877
2,395
py
Python
panoptes_aggregation/tests/reducer_tests/test_question_reducer.py
CKrawczyk/python-reducers-for-caesar
9c5d9e072906d3fde2497fa61a66e4c8c0113ec2
[ "Apache-2.0" ]
1
2018-11-27T16:43:37.000Z
2018-11-27T16:43:37.000Z
panoptes_aggregation/tests/reducer_tests/test_question_reducer.py
CKrawczyk/python-reducers-for-caesar
9c5d9e072906d3fde2497fa61a66e4c8c0113ec2
[ "Apache-2.0" ]
2
2017-07-27T09:05:03.000Z
2019-04-03T20:28:31.000Z
panoptes_aggregation/tests/reducer_tests/test_question_reducer.py
CKrawczyk/python-reducers-for-caesar
9c5d9e072906d3fde2497fa61a66e4c8c0113ec2
[ "Apache-2.0" ]
2
2017-07-26T17:30:17.000Z
2017-07-27T09:14:51.000Z
import unittest from collections import Counter import flask import json from panoptes_aggregation.reducers.question_reducer import process_data, question_reducer from panoptes_aggregation.reducers.test_utils import extract_in_data extracted_data = [ {'a': 1, 'b': 1}, {'a': 1}, {'b': 1, 'c': 1}, {'b': ...
27.528736
89
0.66096
import unittest from collections import Counter import flask import json from panoptes_aggregation.reducers.question_reducer import process_data, question_reducer from panoptes_aggregation.reducers.test_utils import extract_in_data extracted_data = [ {'a': 1, 'b': 1}, {'a': 1}, {'b': 1, 'c': 1}, {'b': ...
1,342
23
265
7cf76b633da3ca24efc2b044a305e83bcc121a93
905
py
Python
chapter_08/03_date_printer.py
SergeHall/Tony-Gaddis-Python-4th
24e7c70fbd196ff531a5e4e7f6f5021c4b4177ba
[ "MIT" ]
2
2021-04-07T03:26:37.000Z
2021-07-26T07:38:49.000Z
chapter_08/03_date_printer.py
SergeHall/Tony-Gaddis-Python-4th
24e7c70fbd196ff531a5e4e7f6f5021c4b4177ba
[ "MIT" ]
null
null
null
chapter_08/03_date_printer.py
SergeHall/Tony-Gaddis-Python-4th
24e7c70fbd196ff531a5e4e7f6f5021c4b4177ba
[ "MIT" ]
null
null
null
# 3. Принтер дат. Напишите программу, которая считывает от пользователя # строковое значение, содержащее дату в формате дд/мм/гггг. Она должна # напечатать дату в формате 12 марта 2018 г. main()
25.138889
71
0.614365
# 3. Принтер дат. Напишите программу, которая считывает от пользователя # строковое значение, содержащее дату в формате дд/мм/гггг. Она должна # напечатать дату в формате 12 марта 2018 г. def main(): # get the date from the user. date = get_date() # convert date to like March 12, 2014 literal_date = c...
637
0
69
b763443b905c931d81818a74873ed7fa19410bcf
2,461
py
Python
Mailbot/cogs/utils/strManip/owo.py
tekofu/Mailbot
a0475d20ae01c9f09c1174a8ddaf3a92cf1707a2
[ "MIT" ]
null
null
null
Mailbot/cogs/utils/strManip/owo.py
tekofu/Mailbot
a0475d20ae01c9f09c1174a8ddaf3a92cf1707a2
[ "MIT" ]
null
null
null
Mailbot/cogs/utils/strManip/owo.py
tekofu/Mailbot
a0475d20ae01c9f09c1174a8ddaf3a92cf1707a2
[ "MIT" ]
null
null
null
# Port from https://github.com/zuzak/owo """MIT License Original substitutions: Copyright (c) 2018 Eva (Nepeta) JavaScript library: Copyright (c) 2019 Douglas Gardner <douglas@chippy.ch> Python library: Copyright (c) 2019 tekofu Permission is hereby granted, free of charge, to any person obtaining a copy...
23.893204
78
0.60382
# Port from https://github.com/zuzak/owo """MIT License Original substitutions: Copyright (c) 2018 Eva (Nepeta) JavaScript library: Copyright (c) 2019 Douglas Gardner <douglas@chippy.ch> Python library: Copyright (c) 2019 tekofu Permission is hereby granted, free of charge, to any person obtaining a copy...
517
0
23
ee07d386a54685fbce86e02e57f64443fe1564d9
2,185
py
Python
biliapi/search.py
elecmonkey/biliapi-py
560bf8e332c79daa83da6ff6f011a08172c651ab
[ "MIT" ]
1
2020-03-26T03:33:25.000Z
2020-03-26T03:33:25.000Z
biliapi/search.py
elecmonkey/biliapi-py
560bf8e332c79daa83da6ff6f011a08172c651ab
[ "MIT" ]
null
null
null
biliapi/search.py
elecmonkey/biliapi-py
560bf8e332c79daa83da6ff6f011a08172c651ab
[ "MIT" ]
null
null
null
import json import urllib.parse from .lib.gethttp import getHttpPage
43.7
269
0.523112
import json import urllib.parse from .lib.gethttp import getHttpPage class Search: __keyword = '' __caching = {} def __init__(self, keyword): self.__keyword = keyword def setUid(self, keyword): self.__keyword = keyword def getUid(self, keyword): return self.__keyword d...
1,986
136
23
01b5c4ad0af3c39ac513f99c62e7604958db38e2
1,510
py
Python
tests/test_dbgp_eval_property.py
Taluu/vdebug
2ebf27b1ffb6752f0ba6cf4ec6be0a7498897d48
[ "MIT" ]
null
null
null
tests/test_dbgp_eval_property.py
Taluu/vdebug
2ebf27b1ffb6752f0ba6cf4ec6be0a7498897d48
[ "MIT" ]
null
null
null
tests/test_dbgp_eval_property.py
Taluu/vdebug
2ebf27b1ffb6752f0ba6cf4ec6be0a7498897d48
[ "MIT" ]
null
null
null
import unittest import vdebug.dbgp import xml.etree.ElementTree as ET
37.75
123
0.659603
import unittest import vdebug.dbgp import xml.etree.ElementTree as ET class EvalPropertyTest(unittest.TestCase): def __get_eval_property(self,xml_string,code,lang): xml = ET.fromstring(xml_string) firstnode = xml[0] return vdebug.dbgp.EvalProperty(firstnode,code,lang) def test_numeric_...
1,343
21
76
16cc64d424b0814ed9440ed104da575c4aaeb25f
7,366
py
Python
darling_ansible/python_venv/lib/python3.7/site-packages/oci/cims/models/limit_item.py
revnav/sandbox
f9c8422233d093b76821686b6c249417502cf61d
[ "Apache-2.0" ]
null
null
null
darling_ansible/python_venv/lib/python3.7/site-packages/oci/cims/models/limit_item.py
revnav/sandbox
f9c8422233d093b76821686b6c249417502cf61d
[ "Apache-2.0" ]
null
null
null
darling_ansible/python_venv/lib/python3.7/site-packages/oci/cims/models/limit_item.py
revnav/sandbox
f9c8422233d093b76821686b6c249417502cf61d
[ "Apache-2.0" ]
1
2020-06-25T03:12:58.000Z
2020-06-25T03:12:58.000Z
# coding: utf-8 # Copyright (c) 2016, 2020, Oracle and/or its affiliates. All rights reserved. # This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may c...
32.307018
245
0.63508
# coding: utf-8 # Copyright (c) 2016, 2020, Oracle and/or its affiliates. All rights reserved. # This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may c...
177
0
81
522211a4f5a97c6fa2d49305fa8392bcbc68d35d
12,541
py
Python
pytests/sg/sginstalltests.py
sumedhpb/testrunner
9ff887231c75571624abc31a3fb5248110e01203
[ "Apache-2.0" ]
14
2015-02-06T02:47:57.000Z
2020-03-14T15:06:05.000Z
pytests/sg/sginstalltests.py
sumedhpb/testrunner
9ff887231c75571624abc31a3fb5248110e01203
[ "Apache-2.0" ]
3
2019-02-27T19:29:11.000Z
2021-06-02T02:14:27.000Z
pytests/sg/sginstalltests.py
sumedhpb/testrunner
9ff887231c75571624abc31a3fb5248110e01203
[ "Apache-2.0" ]
108
2015-03-26T08:58:49.000Z
2022-03-21T05:21:39.000Z
from sg.sg_base import GatewayBaseTest from remote.remote_util import RemoteMachineShellConnection import time help_string = ['This script creates an init service to run a sync_gateway instance.', 'If you want to install more than one service instance', 'create additional services with di...
55.49115
128
0.667889
from sg.sg_base import GatewayBaseTest from remote.remote_util import RemoteMachineShellConnection import time help_string = ['This script creates an init service to run a sync_gateway instance.', 'If you want to install more than one service instance', 'create additional services with di...
11,151
18
400
bc824221bd86159252cc6ddafd65edc617bbc567
3,713
py
Python
build-tools/garbage-files-generator.py
neuro-inc/neuro-cli
72bd2a825cc319bbc79c6df16f33380796fad4f5
[ "Apache-2.0" ]
5
2019-09-24T15:37:47.000Z
2020-08-04T09:25:29.000Z
build-tools/garbage-files-generator.py
neuromation/platform-client-python
72bd2a825cc319bbc79c6df16f33380796fad4f5
[ "Apache-2.0" ]
748
2019-08-05T14:57:11.000Z
2020-09-28T09:54:41.000Z
build-tools/garbage-files-generator.py
neuro-inc/neuro-cli
72bd2a825cc319bbc79c6df16f33380796fad4f5
[ "Apache-2.0" ]
3
2019-10-07T19:25:22.000Z
2020-06-29T01:41:26.000Z
#!/usr/bin/env python import argparse import math import os import pathlib import re from rich.console import Console from rich.progress import Progress if __name__ == "__main__": main()
31.466102
88
0.587934
#!/usr/bin/env python import argparse import math import os import pathlib import re from rich.console import Console from rich.progress import Progress def main(): args = _parse_args() generate_data( args.total_size, args.files_count, args.branching_factor, args.output_dir, ...
3,398
0
115
aa2432989d267f1697e3b7870f5529c883957cbd
416
py
Python
app.py
youqad/oxford-hack-2020
7c4bf02f0dc52ce99cee721a3b7b3344060018f2
[ "MIT" ]
null
null
null
app.py
youqad/oxford-hack-2020
7c4bf02f0dc52ce99cee721a3b7b3344060018f2
[ "MIT" ]
null
null
null
app.py
youqad/oxford-hack-2020
7c4bf02f0dc52ce99cee721a3b7b3344060018f2
[ "MIT" ]
null
null
null
from flask import Flask, render_template, request, url_for, flash, redirect from werkzeug.exceptions import abort app = Flask(__name__) app.config['SECRET_KEY'] = 'mA7OumwKVZQr9ousrge1OVQxQr51WEs7' @app.route('/') @app.route('/info') @app.route('/algo')
23.111111
75
0.730769
from flask import Flask, render_template, request, url_for, flash, redirect from werkzeug.exceptions import abort app = Flask(__name__) app.config['SECRET_KEY'] = 'mA7OumwKVZQr9ousrge1OVQxQr51WEs7' @app.route('/') def index(): return render_template('index.html') @app.route('/info') def info(): return rende...
92
0
66
ce7b3baf52f5102717543610e6978b690f6d6393
9,183
py
Python
src/anchorpy/clientgen/accounts.py
kevinheavey/anchorpy
d4cc28365c6adaeaec7f5001fa6b8a3e719b41ad
[ "MIT" ]
87
2021-09-26T18:14:07.000Z
2022-03-28T08:22:24.000Z
src/anchorpy/clientgen/accounts.py
kevinheavey/anchorpy
d4cc28365c6adaeaec7f5001fa6b8a3e719b41ad
[ "MIT" ]
15
2021-10-07T16:12:23.000Z
2022-03-20T21:04:40.000Z
src/anchorpy/clientgen/accounts.py
kevinheavey/anchorpy
d4cc28365c6adaeaec7f5001fa6b8a3e719b41ad
[ "MIT" ]
16
2021-10-16T04:40:28.000Z
2022-03-18T16:49:40.000Z
from pathlib import Path from black import format_str, FileMode from autoflake import fix_code from pyheck import snake from genpy import ( FromImport, Import, Assign, Suite, Collection, ImportAs, Return, For, If, Raise, Statement, ) from anchorpy.coder.accounts import _accou...
31.885417
86
0.541326
from pathlib import Path from black import format_str, FileMode from autoflake import fix_code from pyheck import snake from genpy import ( FromImport, Import, Assign, Suite, Collection, ImportAs, Return, For, If, Raise, Statement, ) from anchorpy.coder.accounts import _accou...
8,265
0
115
b1b31f991a09674904d9957324ed536384780435
2,369
py
Python
analysis/active/saccades/deconvolve-saccades.py
goldman-lab/oculomotor-response-timescales
fa9f73e6f6a256a5983248b30c6348a50f1fdfcf
[ "BSD-3-Clause" ]
null
null
null
analysis/active/saccades/deconvolve-saccades.py
goldman-lab/oculomotor-response-timescales
fa9f73e6f6a256a5983248b30c6348a50f1fdfcf
[ "BSD-3-Clause" ]
null
null
null
analysis/active/saccades/deconvolve-saccades.py
goldman-lab/oculomotor-response-timescales
fa9f73e6f6a256a5983248b30c6348a50f1fdfcf
[ "BSD-3-Clause" ]
1
2022-01-05T18:26:33.000Z
2022-01-05T18:26:33.000Z
import numpy as np import sys sys.path.append('../../../tools/') import fitting_functions import os import scipy.io as sio import scipy.optimize import tqdm if __name__ == "__main__": file_names = [ ('090711e_0006',), ('090811c_0002',), ('090811d_0002','090811d_0004',), ('091111a_0001', '091111a_0003')...
37.603175
104
0.633179
import numpy as np import sys sys.path.append('../../../tools/') import fitting_functions import os import scipy.io as sio import scipy.optimize import tqdm def deconvolveEyePos(trange, eye_pos, plant, ind=-1): plant_model = fitting_functions.exponentialModel(trange, plant) dt = trange[2]-trange[1] def...
566
0
23
7f099f5157ae9f8859ce21a33bfc1f8961efeb77
7,032
py
Python
models/backbone/shufflenet.py
Minerva-J/Pytorch-Segmentation-multi-models
0845b54d4fbc8d38c70f158054b7ab1be2b3ceb9
[ "Apache-2.0" ]
84
2020-06-10T11:50:10.000Z
2022-03-28T15:24:27.000Z
models/backbone/shufflenet.py
eeaesa/Pytorch-Segmentation-multi-models
0845b54d4fbc8d38c70f158054b7ab1be2b3ceb9
[ "Apache-2.0" ]
4
2020-08-10T07:22:08.000Z
2022-01-28T01:58:25.000Z
models/backbone/shufflenet.py
eeaesa/Pytorch-Segmentation-multi-models
0845b54d4fbc8d38c70f158054b7ab1be2b3ceb9
[ "Apache-2.0" ]
28
2020-07-02T11:04:56.000Z
2022-02-16T13:57:20.000Z
# -*- coding: utf-8 -*- # Thanks to https://github.com/ericsun99/Shufflenet-v2-Pytorch import torch import torch.nn as nn import torch.nn.functional as F from torch.autograd import Variable from collections import OrderedDict from torch.nn import init import math __all__ = ['shufflenet_v2', 'ShuffleNetV2'] if ...
34.135922
115
0.567975
# -*- coding: utf-8 -*- # Thanks to https://github.com/ericsun99/Shufflenet-v2-Pytorch import torch import torch.nn as nn import torch.nn.functional as F from torch.autograd import Variable from collections import OrderedDict from torch.nn import init import math __all__ = ['shufflenet_v2', 'ShuffleNetV2'] def conv_...
6,180
120
218
3305587d836a98367649a9f623ff4f20d1af90de
1,826
py
Python
backend/importer/import_tmks.py
warent/ACLU
94c617658284b93ac1edb6c01193fb344f8f60cc
[ "MIT" ]
23
2017-07-13T04:47:43.000Z
2021-12-12T09:33:08.000Z
backend/importer/import_tmks.py
warent/ACLU
94c617658284b93ac1edb6c01193fb344f8f60cc
[ "MIT" ]
188
2017-07-13T04:40:27.000Z
2021-07-20T05:42:30.000Z
backend/importer/import_tmks.py
warent/ACLU
94c617658284b93ac1edb6c01193fb344f8f60cc
[ "MIT" ]
16
2017-08-17T05:05:58.000Z
2019-03-18T21:54:31.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright © 2017 # # Distributed under terms of the MIT license. import click import datetime import logging import logging.config import multiprocessing import os import sys import uuid from utilities import get_features_from_geojson from utilities import get_organi...
26.463768
131
0.7092
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright © 2017 # # Distributed under terms of the MIT license. import click import datetime import logging import logging.config import multiprocessing import os import sys import uuid from utilities import get_features_from_geojson from utilities import get_organi...
848
0
45
b958639b31027285cbe8affba52c97466d35072c
702
py
Python
src/models/version_model_test.py
DEV3L/python-learning-journal
cb7f7b4ddaeffa8e207f9f4b42b775d442d975a4
[ "Beerware" ]
null
null
null
src/models/version_model_test.py
DEV3L/python-learning-journal
cb7f7b4ddaeffa8e207f9f4b42b775d442d975a4
[ "Beerware" ]
null
null
null
src/models/version_model_test.py
DEV3L/python-learning-journal
cb7f7b4ddaeffa8e207f9f4b42b775d442d975a4
[ "Beerware" ]
null
null
null
from src.models.version_model import VersionModel
21.9375
53
0.746439
from src.models.version_model import VersionModel def test_version_model_sets_attributes(): expected_version = 'v001_data_init' version_model = VersionModel(expected_version) assert expected_version == version_model.version def test_version_model_returns_json(): expected_json = { 'version'...
580
0
69
dc2fa87cd670ce4ae43ad47ddaa88ef5cbdd69cf
112
py
Python
Marauders_GUI/kirk.py
kmackenzieii/marauders-map
0027d2880cec8e5ef77b7e5c6454f43ef17b9867
[ "MIT" ]
null
null
null
Marauders_GUI/kirk.py
kmackenzieii/marauders-map
0027d2880cec8e5ef77b7e5c6454f43ef17b9867
[ "MIT" ]
null
null
null
Marauders_GUI/kirk.py
kmackenzieii/marauders-map
0027d2880cec8e5ef77b7e5c6454f43ef17b9867
[ "MIT" ]
null
null
null
width = 300 height = 450 box_size = 35 x = width / box_size y = height / box_size File = "/interface/kirk.gif"
14
28
0.678571
width = 300 height = 450 box_size = 35 x = width / box_size y = height / box_size File = "/interface/kirk.gif"
0
0
0
66441229a6c1d50bf2de571106f41bcdf21efda4
989
py
Python
discovery-provider/alembic/versions/f775fb87f5ff_add_skipped_transaction_level_column.py
lucylow/audius-protocol
5ef93462f9dc7df01a15877c02ca79b9a7d99236
[ "Apache-2.0" ]
1
2022-03-27T21:40:36.000Z
2022-03-27T21:40:36.000Z
discovery-provider/alembic/versions/f775fb87f5ff_add_skipped_transaction_level_column.py
abelxmendoza/audius-protocol
33757e1b722a4be97960086b98b26ae3a75ee56b
[ "Apache-2.0" ]
null
null
null
discovery-provider/alembic/versions/f775fb87f5ff_add_skipped_transaction_level_column.py
abelxmendoza/audius-protocol
33757e1b722a4be97960086b98b26ae3a75ee56b
[ "Apache-2.0" ]
null
null
null
"""add skipped_transaction level column Revision ID: f775fb87f5ff Revises: be27a2794f75 Create Date: 2022-01-12 22:32:24.949547 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = "f775fb87f5ff" down_revision = "be27a2794f75" branch_labels = None depends_on = None ...
26.026316
88
0.697674
"""add skipped_transaction level column Revision ID: f775fb87f5ff Revises: be27a2794f75 Create Date: 2022-01-12 22:32:24.949547 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = "f775fb87f5ff" down_revision = "be27a2794f75" branch_labels = None depends_on = None ...
621
0
46
cb86331692b61d5b15915b797e85955b1ce6bdaa
344
py
Python
Doc/includes/sqlite3/adapter_point_2.py
shawwn/cpython
0ff8a3b374286d2218fc18f47556a5ace202dad3
[ "0BSD" ]
52,316
2015-01-01T15:56:25.000Z
2022-03-31T23:19:01.000Z
Doc/includes/sqlite3/adapter_point_2.py
shawwn/cpython
0ff8a3b374286d2218fc18f47556a5ace202dad3
[ "0BSD" ]
25,286
2015-03-03T23:18:02.000Z
2022-03-31T23:17:27.000Z
Doc/includes/sqlite3/adapter_point_2.py
shawwn/cpython
0ff8a3b374286d2218fc18f47556a5ace202dad3
[ "0BSD" ]
31,623
2015-01-01T13:29:37.000Z
2022-03-31T19:55:06.000Z
import sqlite3 sqlite3.register_adapter(Point, adapt_point) con = sqlite3.connect(":memory:") cur = con.cursor() p = Point(4.0, -3.2) cur.execute("select ?", (p,)) print(cur.fetchone()[0]) con.close()
17.2
44
0.630814
import sqlite3 class Point: def __init__(self, x, y): self.x, self.y = x, y def adapt_point(point): return "%f;%f" % (point.x, point.y) sqlite3.register_adapter(Point, adapt_point) con = sqlite3.connect(":memory:") cur = con.cursor() p = Point(4.0, -3.2) cur.execute("select ?", (p,)) print(cur.fetc...
76
-9
72
64b3ce3a7dd6f9e321707f00bb7be83f35d3e438
177
py
Python
src/test/shedule test/schedule_0.5.0.py
dev-gmmahs/block-vote-service
cc1e296f4bfff657961a50e05150ad5b0f7479e5
[ "MIT" ]
4
2018-08-28T10:14:58.000Z
2020-02-14T07:49:20.000Z
src/test/shedule test/schedule_0.5.0.py
dev-gmmahs/block-vote-service
cc1e296f4bfff657961a50e05150ad5b0f7479e5
[ "MIT" ]
17
2018-08-29T01:57:04.000Z
2022-02-12T02:49:52.000Z
src/test/shedule test/schedule_0.5.0.py
dev-gmmahs/block-vote-service
cc1e296f4bfff657961a50e05150ad5b0f7479e5
[ "MIT" ]
5
2018-08-27T12:02:10.000Z
2018-12-07T20:54:52.000Z
# schedule 0.5.0 import schedule import time # 1분마다 호출 schedule.every().minutes.do(job) while True: schedule.run_pending() time.sleep(1)
12.642857
32
0.666667
# schedule 0.5.0 import schedule import time def job(): print("호출 됨") # 1분마다 호출 schedule.every().minutes.do(job) while True: schedule.run_pending() time.sleep(1)
13
0
23
47f5a4c8ff80d736fd6553d71572644d4ce13d3b
739
py
Python
back-end/credentials.py
tamasandacian/Flask-Angular-EmployeeSearch
dfe4fd825de36eabdf9b293f8e566e44a5a49ebf
[ "MIT" ]
3
2019-07-20T20:19:47.000Z
2022-01-06T16:44:05.000Z
back-end/credentials.py
tamasandacian/Flask-Angular-EmployeeSearch
dfe4fd825de36eabdf9b293f8e566e44a5a49ebf
[ "MIT" ]
9
2020-09-06T14:09:14.000Z
2022-03-02T04:55:41.000Z
back-end/credentials.py
tamasandacian/Flask-Angular-EmployeeSearch
dfe4fd825de36eabdf9b293f8e566e44a5a49ebf
[ "MIT" ]
null
null
null
import os from dotenv import load_dotenv from pathlib import Path env_path = Path('.') / '.env' load_dotenv(dotenv_path=env_path) ############################# CONNECTION TO ELASTICSEARCH LOCALHOST ############################# # username = os.environ.get('ELASTICSEARCH_USERNAME_LOCALHOST') # password = os.environ.g...
43.470588
97
0.554804
import os from dotenv import load_dotenv from pathlib import Path env_path = Path('.') / '.env' load_dotenv(dotenv_path=env_path) ############################# CONNECTION TO ELASTICSEARCH LOCALHOST ############################# # username = os.environ.get('ELASTICSEARCH_USERNAME_LOCALHOST') # password = os.environ.g...
0
0
0
d3d36bed3f73ffc3b77760185d28d8fe4c701b22
3,132
py
Python
benchmark/bench_objectify.py
skeptycal/lxml
32ac7a3bdc8faf2104a77787ed18f2096d0a7346
[ "BSD-3-Clause" ]
null
null
null
benchmark/bench_objectify.py
skeptycal/lxml
32ac7a3bdc8faf2104a77787ed18f2096d0a7346
[ "BSD-3-Clause" ]
1
2020-07-07T04:35:41.000Z
2020-07-07T04:35:41.000Z
benchmark/bench_objectify.py
skeptycal/lxml
32ac7a3bdc8faf2104a77787ed18f2096d0a7346
[ "BSD-3-Clause" ]
null
null
null
from itertools import * import benchbase from benchbase import with_text, children, nochange ############################################################ # Benchmarks ############################################################ if __name__ == "__main__": benchbase.main(BenchMark)
26.1
70
0.58014
from itertools import * import benchbase from benchbase import with_text, children, nochange ############################################################ # Benchmarks ############################################################ class BenchMark(benchbase.TreeBenchMark): repeat100 = range(100) repeat1000 = ra...
540
2,279
23
d20d5b327d487d24d93236afb3de25b6fe501f5e
12,392
py
Python
sdk/python/pulumi_proxmox/ct/outputs.py
meyskens/pulumi-proxmox
bf48570690350be68fa554e1cec376212eb449ab
[ "ECL-2.0", "Apache-2.0" ]
16
2021-01-11T11:26:19.000Z
2022-01-23T02:32:34.000Z
sdk/python/pulumi_proxmox/ct/outputs.py
meyskens/pulumi-proxmox
bf48570690350be68fa554e1cec376212eb449ab
[ "ECL-2.0", "Apache-2.0" ]
2
2021-01-29T08:15:46.000Z
2021-10-17T16:33:19.000Z
sdk/python/pulumi_proxmox/ct/outputs.py
meyskens/pulumi-proxmox
bf48570690350be68fa554e1cec376212eb449ab
[ "ECL-2.0", "Apache-2.0" ]
4
2021-04-06T00:36:05.000Z
2021-12-16T14:25:07.000Z
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from .. import _utilitie...
30.902743
98
0.633393
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from .. import _utilitie...
7,916
3,128
286
9ee5b034b8a1988afc54329a5bec46ecaa4b519c
4,585
py
Python
vizier/api/webservice/__init__.py
VizierDB/web-api-async
e99f43df3df80ad5647f57d805c339257336ac73
[ "ECL-2.0", "Apache-2.0" ]
2
2019-10-21T03:01:39.000Z
2020-06-05T01:43:00.000Z
vizier/api/webservice/__init__.py
VizierDB/web-api-async
e99f43df3df80ad5647f57d805c339257336ac73
[ "ECL-2.0", "Apache-2.0" ]
56
2019-07-12T21:16:03.000Z
2020-11-06T23:29:22.000Z
vizier/api/webservice/__init__.py
VizierDB/web-api-async
e99f43df3df80ad5647f57d805c339257336ac73
[ "ECL-2.0", "Apache-2.0" ]
2
2020-02-07T19:56:55.000Z
2020-08-07T11:17:51.000Z
# Copyright (C) 2017-2019 New York University, # University at Buffalo, # Illinois Institute of Technology. # # 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 th...
33.224638
113
0.627481
# Copyright (C) 2017-2019 New York University, # University at Buffalo, # Illinois Institute of Technology. # # 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 th...
0
0
0
316e27aa43683da3ab30191f818a1621683e1504
3,228
py
Python
http_helper.py
uk-gov-mirror/alphagov.github-actions-runner-orchestration
9803e0c96d3da3c800d8c809f06065a611a65a10
[ "MIT" ]
8
2021-03-19T17:40:51.000Z
2021-12-24T04:18:28.000Z
http_helper.py
uk-gov-mirror/alphagov.github-actions-runner-orchestration
9803e0c96d3da3c800d8c809f06065a611a65a10
[ "MIT" ]
3
2021-03-15T15:55:30.000Z
2021-06-07T10:42:40.000Z
http_helper.py
uk-gov-mirror/alphagov.github-actions-runner-orchestration
9803e0c96d3da3c800d8c809f06065a611a65a10
[ "MIT" ]
2
2021-04-10T17:16:39.000Z
2021-04-10T20:14:41.000Z
import hmac import hashlib import base64 import json import re import time def extractAndValidateBody( body: str, key: str = "", signature: str = "", isBase64: bool = False, with_validate: bool = True, ) -> dict: """ Basic parsing of the body, including optional validation ...
29.888889
125
0.550186
import hmac import hashlib import base64 import json import re import time def extractAndValidateBody( body: str, key: str = "", signature: str = "", isBase64: bool = False, with_validate: bool = True, ) -> dict: """ Basic parsing of the body, including optional validation ...
0
0
0
6726cbedef2c6f18fa62a6fb72c6c2851af790bb
50
py
Python
tests/tests/test.py
cbsi-dto/KubernetesJobOperator
32f23c20adaa7db63e35a103f466207908063b43
[ "MIT" ]
35
2020-02-10T16:55:41.000Z
2022-03-18T01:25:00.000Z
tests/tests/test.py
LamaAni/KubernetesJobOperator
32f23c20adaa7db63e35a103f466207908063b43
[ "MIT" ]
26
2020-02-10T05:36:44.000Z
2022-03-02T18:44:47.000Z
tests/tests/test.py
cbsi-dto/KubernetesJobOperator
32f23c20adaa7db63e35a103f466207908063b43
[ "MIT" ]
8
2020-02-28T23:24:07.000Z
2021-11-29T21:35:46.000Z
from airflow import version print(version.version)
25
27
0.86
from airflow import version print(version.version)
0
0
0
5a82275a3506fff40f44b058e01545b74a067eb9
106
py
Python
ntc_rosetta_conf/usr_state_data_handlers.py
networktocode/ntc-rosetta-conf
06c8028e0bbafdd97d15e14ca13faa2601345d8b
[ "Apache-2.0" ]
5
2019-07-31T03:06:48.000Z
2020-09-01T21:51:04.000Z
ntc_rosetta_conf/usr_state_data_handlers.py
networktocode/ntc-rosetta-conf
06c8028e0bbafdd97d15e14ca13faa2601345d8b
[ "Apache-2.0" ]
1
2020-12-14T15:02:05.000Z
2020-12-14T15:02:05.000Z
ntc_rosetta_conf/usr_state_data_handlers.py
networktocode/ntc-rosetta-conf
06c8028e0bbafdd97d15e14ca13faa2601345d8b
[ "Apache-2.0" ]
1
2021-04-05T09:53:53.000Z
2021-04-05T09:53:53.000Z
from jetconf.data import BaseDatastore
17.666667
55
0.783019
from jetconf.data import BaseDatastore def register_state_handlers(ds: BaseDatastore) -> None: pass
43
0
23
9e4a27f78a5c2ba5e353dcd5fc86de8de8171e03
1,723
py
Python
geonode/geonode/maps/__init__.py
ttungbmt/BecaGIS_GeoPortal
6c05f9fc020ec4ccf600ba2503a06c2231443920
[ "MIT" ]
null
null
null
geonode/geonode/maps/__init__.py
ttungbmt/BecaGIS_GeoPortal
6c05f9fc020ec4ccf600ba2503a06c2231443920
[ "MIT" ]
null
null
null
geonode/geonode/maps/__init__.py
ttungbmt/BecaGIS_GeoPortal
6c05f9fc020ec4ccf600ba2503a06c2231443920
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- ######################################################################### # # Copyright (C) 2016 OSGeo # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 ...
44.179487
96
0.598375
# -*- coding: utf-8 -*- ######################################################################### # # Copyright (C) 2016 OSGeo # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 ...
0
684
23
d343e3206562b2f8211d80e497a5ea3ebe66d36a
3,970
py
Python
draalcore/middleware/tests/test_login.py
jojanper/draalcore
3d3f5a53efe32c721c34d7e48267328a4e9e8402
[ "MIT" ]
1
2017-04-25T10:54:55.000Z
2017-04-25T10:54:55.000Z
draalcore/middleware/tests/test_login.py
jojanper/draalcore
3d3f5a53efe32c721c34d7e48267328a4e9e8402
[ "MIT" ]
1
2022-02-10T06:48:36.000Z
2022-02-10T06:48:36.000Z
draalcore/middleware/tests/test_login.py
jojanper/draalcore
3d3f5a53efe32c721c34d7e48267328a4e9e8402
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """Login middleware tests""" # System imports import logging from mock import MagicMock, patch from datetime import datetime, timedelta from django.http import HttpRequest from django.conf import settings from django.contrib import auth from django.urls import reverse # P...
31.015625
105
0.678086
#!/usr/bin/env python # -*- coding: utf-8 -*- """Login middleware tests""" # System imports import logging from mock import MagicMock, patch from datetime import datetime, timedelta from django.http import HttpRequest from django.conf import settings from django.contrib import auth from django.urls import reverse # P...
0
0
0
2c8adce33aac5b9e88d71156a20ce690711966f7
346
py
Python
data_science_layer/machine_learning/support_vector_regressor.py
nathangeology/cyclist_dataset
44ad4a3765e86cba934bfdbfb151a788eddfbead
[ "MIT" ]
null
null
null
data_science_layer/machine_learning/support_vector_regressor.py
nathangeology/cyclist_dataset
44ad4a3765e86cba934bfdbfb151a788eddfbead
[ "MIT" ]
null
null
null
data_science_layer/machine_learning/support_vector_regressor.py
nathangeology/cyclist_dataset
44ad4a3765e86cba934bfdbfb151a788eddfbead
[ "MIT" ]
null
null
null
from sklearn.svm import SVR from data_science_layer.machine_learning.base_regressor import BaseRegressor
24.714286
76
0.699422
from sklearn.svm import SVR from data_science_layer.machine_learning.base_regressor import BaseRegressor class SupportVectorRegressorModel(BaseRegressor): short_name = 'SVR' sklearn_model = SVR() hyper_param_dict = {'C': [0.001, 0.01, 0.1, 1, 10, 100]} def __init__(self): super().__init__() ...
51
165
23
f1c8a2ea1e6774516b221761cec538d39be7d6c1
254
py
Python
learn-python/sort_with_key.py
barissimsek/gopython
7e2c1bdb20b2a908c601794ea9dbf71ea035a869
[ "Apache-2.0" ]
null
null
null
learn-python/sort_with_key.py
barissimsek/gopython
7e2c1bdb20b2a908c601794ea9dbf71ea035a869
[ "Apache-2.0" ]
null
null
null
learn-python/sort_with_key.py
barissimsek/gopython
7e2c1bdb20b2a908c601794ea9dbf71ea035a869
[ "Apache-2.0" ]
null
null
null
ips = [ '10.0.0.5', '10.5.3.1', '192.168.11.10', '2.2.2.2', '100.0.0.1', '20.3.2.4' ] print(sort_ips(ips))
12.095238
52
0.566929
ips = [ '10.0.0.5', '10.5.3.1', '192.168.11.10', '2.2.2.2', '100.0.0.1', '20.3.2.4' ] def getKey(item): return tuple(int(part) for part in item.split('.')) def sort_ips(iplist): return sorted(ips, key=getKey) print(sort_ips(ips))
81
0
46
472bac29ae211663cfbeeaa2790296ad3609df06
4,913
py
Python
src/glusterfsweb/glusternodestate.py
aravindavk/glusterfs-web
5ffacd4ac614a524b4e118b7f4aa68f12453b82a
[ "BSD-3-Clause" ]
10
2015-08-28T10:18:05.000Z
2019-10-04T03:45:25.000Z
src/glusterfsweb/glusternodestate.py
iesool/glusterfs-web
5ffacd4ac614a524b4e118b7f4aa68f12453b82a
[ "BSD-3-Clause" ]
null
null
null
src/glusterfsweb/glusternodestate.py
iesool/glusterfs-web
5ffacd4ac614a524b4e118b7f4aa68f12453b82a
[ "BSD-3-Clause" ]
7
2015-11-21T00:59:49.000Z
2022-02-21T20:37:00.000Z
# -*- coding: utf-8 -*- """ glusternodestate.py :copyright: (c) 2013 by Aravinda VK :license: BSD, GPL v2, see LICENSE for more details. """ import argparse import errno import os from functools import wraps import sys import requests from glusterfstools import volumes import nodestatedb as _db from conf...
24.565
77
0.607165
# -*- coding: utf-8 -*- """ glusternodestate.py :copyright: (c) 2013 by Aravinda VK :license: BSD, GPL v2, see LICENSE for more details. """ import argparse import errno import os from functools import wraps import sys import requests from glusterfstools import volumes import nodestatedb as _db from conf...
3,826
27
335
c91d9e8b4b3fd15318d5312b088f30df2d69e23d
940
py
Python
array/defuse_the_bomb.py
elenaborisova/LeetCode-Solutions
98376aab7fd150a724e316357ae5ea46988d9eac
[ "MIT" ]
null
null
null
array/defuse_the_bomb.py
elenaborisova/LeetCode-Solutions
98376aab7fd150a724e316357ae5ea46988d9eac
[ "MIT" ]
null
null
null
array/defuse_the_bomb.py
elenaborisova/LeetCode-Solutions
98376aab7fd150a724e316357ae5ea46988d9eac
[ "MIT" ]
null
null
null
print(decrypt([5, 7, 1, 4], 3)) print(decrypt([1, 2, 3, 4], 0)) print(decrypt([2, 4, 9, 3], -2))
21.860465
44
0.370213
def decrypt(code, k): decoded = [] if k > 0: for i in range(len(code)): num = 0 idx = i count = 0 while count < k: if idx == len(code): idx = 0 num += code[idx] idx += 1 ...
819
0
22
865161f80d1b8ceda72b675814ede88a53fd25f6
1,321
py
Python
extrairdados/lpl springs 21/dragons.py
pedrograngeiro/Webcrasping-E-sports-Wiki
d5f6f1a0577b7ff2e2796bfd18b412f296256fe9
[ "MIT" ]
null
null
null
extrairdados/lpl springs 21/dragons.py
pedrograngeiro/Webcrasping-E-sports-Wiki
d5f6f1a0577b7ff2e2796bfd18b412f296256fe9
[ "MIT" ]
null
null
null
extrairdados/lpl springs 21/dragons.py
pedrograngeiro/Webcrasping-E-sports-Wiki
d5f6f1a0577b7ff2e2796bfd18b412f296256fe9
[ "MIT" ]
null
null
null
import requests from bs4 import BeautifulSoup import csv cont = 0 i = 0 j = 0 source = requests.get('https://lol.gamepedia.com/LPL/2021_Season/Spring_Season/Scoreboards/Week_10').text soup = BeautifulSoup(source, 'html.parser') times = soup.find_all('span', "teamname") kills = soup.find_all('div', "sb-footer-item s...
23.589286
105
0.643452
import requests from bs4 import BeautifulSoup import csv cont = 0 i = 0 j = 0 source = requests.get('https://lol.gamepedia.com/LPL/2021_Season/Spring_Season/Scoreboards/Week_10').text soup = BeautifulSoup(source, 'html.parser') times = soup.find_all('span', "teamname") kills = soup.find_all('div', "sb-footer-item s...
0
0
0
9090ec2dfef9312f57c4b22062703c36c0d45f2c
6,375
py
Python
tests/python_tests/ryw_benchmark.py
sfc-gh-bvr/foundationdb
7594f5c0f92d2582dae717ce0244c11642b27dd4
[ "Apache-2.0" ]
1
2022-02-23T07:17:32.000Z
2022-02-23T07:17:32.000Z
tests/python_tests/ryw_benchmark.py
sfc-gh-bvr/foundationdb
7594f5c0f92d2582dae717ce0244c11642b27dd4
[ "Apache-2.0" ]
null
null
null
tests/python_tests/ryw_benchmark.py
sfc-gh-bvr/foundationdb
7594f5c0f92d2582dae717ce0244c11642b27dd4
[ "Apache-2.0" ]
1
2022-03-01T12:28:03.000Z
2022-03-01T12:28:03.000Z
#!/usr/bin/env python # # ryw_benchmark.py # # This source file is part of the FoundationDB open source project # # Copyright 2013-2018 Apple Inc. and the FoundationDB project authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. #...
32.19697
93
0.586667
#!/usr/bin/env python # # ryw_benchmark.py # # This source file is part of the FoundationDB open source project # # Copyright 2013-2018 Apple Inc. and the FoundationDB project authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. #...
3,714
892
23
9cc587f7aa5a1c467dbabad1cd923174c7d37d14
2,836
py
Python
example/generateExampleIFP.py
whitesides1/spify
5e7ec10f96d486ec15167ebe09bc5d9c05e7f0a8
[ "BSD-3-Clause" ]
1
2021-10-20T21:32:32.000Z
2021-10-20T21:32:32.000Z
example/generateExampleIFP.py
LLNL/spify
6b8386837de7398a43d0440c3b229cb4cefebdf9
[ "BSD-3-Clause" ]
null
null
null
example/generateExampleIFP.py
LLNL/spify
6b8386837de7398a43d0440c3b229cb4cefebdf9
[ "BSD-3-Clause" ]
null
null
null
#!/bin/env python import os,sys #Root of spify src directory SPIFY_SRC_DIR = os.path.join(os.getcwd(),'..') #Name your parser spify_parser_name = "ExampleIFP" spify_parser_params = [] #Specify parameters spify_parser_params.append( { 'name':'boolOption', 'type':'bool', 'shortDesc':'My Boolean Option', ...
19.971831
82
0.680536
#!/bin/env python import os,sys #Root of spify src directory SPIFY_SRC_DIR = os.path.join(os.getcwd(),'..') #Name your parser spify_parser_name = "ExampleIFP" spify_parser_params = [] #Specify parameters spify_parser_params.append( { 'name':'boolOption', 'type':'bool', 'shortDesc':'My Boolean Option', ...
0
0
0
30b60c0864be34ec2d64b39f90a4d523c0554545
632
py
Python
apps/about.py
BlessedMut/Time-Series-Crypto
83817d4fe939802a7d2dc361a094d9982698a66b
[ "MIT" ]
null
null
null
apps/about.py
BlessedMut/Time-Series-Crypto
83817d4fe939802a7d2dc361a094d9982698a66b
[ "MIT" ]
null
null
null
apps/about.py
BlessedMut/Time-Series-Crypto
83817d4fe939802a7d2dc361a094d9982698a66b
[ "MIT" ]
1
2021-07-06T09:48:40.000Z
2021-07-06T09:48:40.000Z
import streamlit as st
26.333333
62
0.547468
import streamlit as st def app(): st.title('Time Series Predictions for Crypto-Currencies') c1, c2, c3 = st.beta_columns([4,2,4]) with c2: st.subheader('Done by:') b,m1,r, m2, l = st.beta_columns([2,1,2,1,2]) with b: st.write('Blessed Mutengwa - R182565F') ...
585
0
24
8eb50fbdaf93c046a32c9ce8f6cfefb2ba329d1a
1,749
py
Python
init.py
substancegrise/POKEMON_TP
641c5be5a641c39a52c6e382528218a36807badb
[ "Xnet", "X11" ]
null
null
null
init.py
substancegrise/POKEMON_TP
641c5be5a641c39a52c6e382528218a36807badb
[ "Xnet", "X11" ]
null
null
null
init.py
substancegrise/POKEMON_TP
641c5be5a641c39a52c6e382528218a36807badb
[ "Xnet", "X11" ]
null
null
null
import requests from bs4 import BeautifulSoup import mysql.connector conn = mysql.connector.connect(host="localhost", user="root", password="root", database="pokedex", port=8889) cursor = conn.cursor(buffered=True) # connexion et récupération des données / parse du site #response = requests.get("https://pokemondb.n...
26.104478
159
0.563751
import requests from bs4 import BeautifulSoup import mysql.connector conn = mysql.connector.connect(host="localhost", user="root", password="root", database="pokedex", port=8889) cursor = conn.cursor(buffered=True) # connexion et récupération des données / parse du site #response = requests.get("https://pokemondb.n...
0
0
0
6a97bb611be63764ae92d04e937cf473eb3bec37
191,812
pyt
Python
Create arcgis project tool.pyt
traderboy/collector-tools
2afa61a0f93095461c6b324ef9641786a969c0a7
[ "MIT" ]
null
null
null
Create arcgis project tool.pyt
traderboy/collector-tools
2afa61a0f93095461c6b324ef9641786a969c0a7
[ "MIT" ]
null
null
null
Create arcgis project tool.pyt
traderboy/collector-tools
2afa61a0f93095461c6b324ef9641786a969c0a7
[ "MIT" ]
null
null
null
import subprocess import arcpy from arcpy import env import sqlite3 import xml.etree.ElementTree import os import json import zipfile from arcpy import mapping import os from xml.dom.minidom import parse from datetime import datetime import time import copy import shutil import types import ConfigParser import copy imp...
49.270999
1,296
0.61883
import subprocess import arcpy from arcpy import env import sqlite3 import xml.etree.ElementTree import os import json import zipfile from arcpy import mapping import os from xml.dom.minidom import parse from datetime import datetime import time import copy import shutil import types import ConfigParser import copy imp...
186,501
11
1,485
55facd052781622c3e1a9c0e26c779edb3f62050
1,313
py
Python
test/cases/response/text.py
zefirka/bobot
76d4f9e8d1cf57341ae1c709b46d7f9ceea5064d
[ "MIT" ]
5
2016-08-07T06:05:05.000Z
2017-01-12T20:19:28.000Z
test/cases/response/text.py
zefirka/bobot
76d4f9e8d1cf57341ae1c709b46d7f9ceea5064d
[ "MIT" ]
1
2016-12-15T16:28:01.000Z
2016-12-16T09:26:27.000Z
test/cases/response/text.py
zefirka/bobot
76d4f9e8d1cf57341ae1c709b46d7f9ceea5064d
[ "MIT" ]
2
2016-08-07T09:38:59.000Z
2016-10-05T16:10:35.000Z
"Testcases for text messages" from .. import Case from bobot.Rule import Rule from bobot.Response import Text responseAsTextDict = Case.Case([ Rule({ 'match': 'text', 'response': { 'text': 'Waiting for text' } }) ], [ { 'expected': [Case.Expectation('Waiting fo...
21.177419
67
0.514851
"Testcases for text messages" from .. import Case from bobot.Rule import Rule from bobot.Response import Text responseAsTextDict = Case.Case([ Rule({ 'match': 'text', 'response': { 'text': 'Waiting for text' } }) ], [ { 'expected': [Case.Expectation('Waiting fo...
0
0
0
7fdd40e4ebe3b02e3d9613f13bc2c9e4556a6616
5,977
py
Python
axon/db/sql/repository.py
gitvipin/validation-app-engine
5581c506bd9d7f1810edc9ae25faec0761f2c840
[ "BSD-2-Clause" ]
null
null
null
axon/db/sql/repository.py
gitvipin/validation-app-engine
5581c506bd9d7f1810edc9ae25faec0761f2c840
[ "BSD-2-Clause" ]
null
null
null
axon/db/sql/repository.py
gitvipin/validation-app-engine
5581c506bd9d7f1810edc9ae25faec0761f2c840
[ "BSD-2-Clause" ]
null
null
null
#!/usr/bin/env python # Copyright (c) 2019 VMware, Inc. All Rights Reserved. # SPDX-License-Identifier: BSD-2 License # The full license information can be found in LICENSE.txt # in the root directory of this project. import uuid from sqlalchemy.orm import joinedload from sqlalchemy.sql import func from axon.db.sql....
35.158824
77
0.655011
#!/usr/bin/env python # Copyright (c) 2019 VMware, Inc. All Rights Reserved. # SPDX-License-Identifier: BSD-2 License # The full license information can be found in LICENSE.txt # in the root directory of this project. import uuid from sqlalchemy.orm import joinedload from sqlalchemy.sql import func from axon.db.sql....
4,417
829
319
b759390c7b719a8979700c907dcbf9dda1a7735f
856
py
Python
test3d.py
ivandumas/Algoritmos
6ba6e548f4d0150a052346a53e11cc40fa234fd5
[ "MIT" ]
null
null
null
test3d.py
ivandumas/Algoritmos
6ba6e548f4d0150a052346a53e11cc40fa234fd5
[ "MIT" ]
null
null
null
test3d.py
ivandumas/Algoritmos
6ba6e548f4d0150a052346a53e11cc40fa234fd5
[ "MIT" ]
null
null
null
from py3dbp import Packer, Bin, Item packer = Packer() packer.add_bin(Bin('small', 300,300,200,5)) packer.add_bin(Bin('big', 500,600,400,8)) packer.add_item(Item('Producto 1',45,60,70,0.5)) packer.add_item(Item('Producto 2',30,50,30,0.7)) packer.add_item(Item('Producto 3',20,70,70,1)) packer.add_item(Item('Producto ...
29.517241
64
0.560748
from py3dbp import Packer, Bin, Item packer = Packer() packer.add_bin(Bin('small', 300,300,200,5)) packer.add_bin(Bin('big', 500,600,400,8)) packer.add_item(Item('Producto 1',45,60,70,0.5)) packer.add_item(Item('Producto 2',30,50,30,0.7)) packer.add_item(Item('Producto 3',20,70,70,1)) packer.add_item(Item('Producto ...
0
0
0
31e4b8813206b272d5411d76736c75a9b6ad48fb
840
py
Python
Beginner/day-3-5-exercise.py
pathilink/TheAppBrewery
d8dc6c7c6908aca8ce039450dfb8f3c16891c8eb
[ "MIT" ]
1
2021-06-02T12:55:24.000Z
2021-06-02T12:55:24.000Z
Beginner/day-3-5-exercise.py
pathilink/TheAppBrewery
d8dc6c7c6908aca8ce039450dfb8f3c16891c8eb
[ "MIT" ]
null
null
null
Beginner/day-3-5-exercise.py
pathilink/TheAppBrewery
d8dc6c7c6908aca8ce039450dfb8f3c16891c8eb
[ "MIT" ]
null
null
null
# 🚨 Don't change the code below 👇 print("Welcome to the Love Calculator!") name1 = input("What is your name? \n") name2 = input("What is their name? \n") # 🚨 Don't change the code above 👆 #Write your code below this line 👇 names_concat = name1.lower() + name2.lower() names_true_total = names_concat.count('t') +...
36.521739
120
0.695238
# 🚨 Don't change the code below 👇 print("Welcome to the Love Calculator!") name1 = input("What is your name? \n") name2 = input("What is their name? \n") # 🚨 Don't change the code above 👆 #Write your code below this line 👇 names_concat = name1.lower() + name2.lower() names_true_total = names_concat.count('t') +...
0
0
0
eb3b96adabc5946dd2424b870a549c05eed80663
6,557
py
Python
input_adj_pipeline.py
Lednik7/SMART_Product
069f63ec944747352b8609d103e7ffb5023c798f
[ "Apache-2.0" ]
2
2021-03-21T18:07:04.000Z
2022-01-23T10:18:20.000Z
input_adj_pipeline.py
Lednik7/SMART_Product
069f63ec944747352b8609d103e7ffb5023c798f
[ "Apache-2.0" ]
null
null
null
input_adj_pipeline.py
Lednik7/SMART_Product
069f63ec944747352b8609d103e7ffb5023c798f
[ "Apache-2.0" ]
null
null
null
import pandas as pd import os import pymorphy2 from sklearn.preprocessing import MinMaxScaler from sklearn.feature_extraction.text import CountVectorizer, TfidfVectorizer import numpy as np import pickle PATH = 'models/' with open(os.path.join(PATH, 'tfidf.pkl'), 'rb') as f: tfidf = pickle.load(f) tim...
37.901734
116
0.617813
import pandas as pd import os import pymorphy2 from sklearn.preprocessing import MinMaxScaler from sklearn.feature_extraction.text import CountVectorizer, TfidfVectorizer import numpy as np import pickle PATH = 'models/' with open(os.path.join(PATH, 'tfidf.pkl'), 'rb') as f: tfidf = pickle.load(f) tim...
5,665
0
324
269b2b608f55030cd416d3cd10c67de0ffea7a94
2,175
py
Python
rebound/rebound/tests/test_shearingsheet.py
rodluger/ttv-devil
e534e4f3cd75db951cba54441f7a5458c87e0cf9
[ "MIT" ]
null
null
null
rebound/rebound/tests/test_shearingsheet.py
rodluger/ttv-devil
e534e4f3cd75db951cba54441f7a5458c87e0cf9
[ "MIT" ]
null
null
null
rebound/rebound/tests/test_shearingsheet.py
rodluger/ttv-devil
e534e4f3cd75db951cba54441f7a5458c87e0cf9
[ "MIT" ]
null
null
null
import rebound import unittest import math import numpy as np if __name__ == "__main__": unittest.main()
33.984375
70
0.512644
import rebound import unittest import math import numpy as np class TestShearingSheet(unittest.TestCase): def test_saturnsrings(self): sim = rebound.Simulation() OMEGA = 0.00013143527 # [1/s] sim.ri_sei.OMEGA = OMEGA surface_density = 400. # kg/m^2 particle_densi...
1,989
22
54
b2a466cb655eb0070b424a1359656da5287dd289
4,282
py
Python
examples/self_supervised/common.py
sandutsar/catalyst
55a3a557cb9276149cf2f70381878d87264e71c2
[ "Apache-2.0" ]
4
2019-12-14T07:27:09.000Z
2021-03-23T14:34:37.000Z
examples/self_supervised/common.py
sandutsar/catalyst
55a3a557cb9276149cf2f70381878d87264e71c2
[ "Apache-2.0" ]
null
null
null
examples/self_supervised/common.py
sandutsar/catalyst
55a3a557cb9276149cf2f70381878d87264e71c2
[ "Apache-2.0" ]
null
null
null
from typing import Dict, Optional from datasets import datasets import torch from torch.utils.data import DataLoader from catalyst.contrib import nn from catalyst.contrib.models.cv.encoders import ResnetEncoder from catalyst.data.dataset.self_supervised import SelfSupervisedDatasetWrapper def add_arguments(parser) ...
31.255474
96
0.671649
from typing import Dict, Optional from datasets import datasets import torch from torch.utils.data import DataLoader from catalyst.contrib import nn from catalyst.contrib.models.cv.encoders import ResnetEncoder from catalyst.data.dataset.self_supervised import SelfSupervisedDatasetWrapper def add_arguments(parser) ...
121
0
27
63a068b07249210cbb884b5404a8565cf36c1246
20,121
py
Python
versgedropt.py
Kunstenpunt/versgedropt
b1cc889d601f3ad4b1e86e6c7a054cf09ad281bb
[ "Apache-2.0" ]
null
null
null
versgedropt.py
Kunstenpunt/versgedropt
b1cc889d601f3ad4b1e86e6c7a054cf09ad281bb
[ "Apache-2.0" ]
1
2021-06-02T00:46:21.000Z
2021-06-02T00:46:21.000Z
versgedropt.py
Kunstenpunt/versgedropt
b1cc889d601f3ad4b1e86e6c7a054cf09ad281bb
[ "Apache-2.0" ]
null
null
null
import spotipy import sys import musicbrainzngs from spotipy.oauth2 import SpotifyClientCredentials from requests import get, exceptions from json import loads from dateparser import parse from pandas import DataFrame, read_excel from bs4 import BeautifulSoup from time import sleep from datetime import datetime, timede...
40.648485
196
0.551315
import spotipy import sys import musicbrainzngs from spotipy.oauth2 import SpotifyClientCredentials from requests import get, exceptions from json import loads from dateparser import parse from pandas import DataFrame, read_excel from bs4 import BeautifulSoup from time import sleep from datetime import datetime, timede...
18,225
27
959
c7f7911950c25ab495d084c77ad18ed923650d20
42
py
Python
tests/components/pushbullet/__init__.py
domwillcode/home-assistant
f170c80bea70c939c098b5c88320a1c789858958
[ "Apache-2.0" ]
30,023
2016-04-13T10:17:53.000Z
2020-03-02T12:56:31.000Z
tests/components/pushbullet/__init__.py
jagadeeshvenkatesh/core
1bd982668449815fee2105478569f8e4b5670add
[ "Apache-2.0" ]
31,101
2020-03-02T13:00:16.000Z
2022-03-31T23:57:36.000Z
tests/components/pushbullet/__init__.py
jagadeeshvenkatesh/core
1bd982668449815fee2105478569f8e4b5670add
[ "Apache-2.0" ]
11,956
2016-04-13T18:42:31.000Z
2020-03-02T09:32:12.000Z
"""Tests for the pushbullet component."""
21
41
0.714286
"""Tests for the pushbullet component."""
0
0
0
1638445b983d8d6ecbff1ab862d979b7aba9bc68
5,321
py
Python
sosia/processing/tests/test_querying.py
sosia-dev/sosia
d4d2d5edb0cd1d085b5a457eb6d19bf8e9fea7f5
[ "MIT" ]
14
2019-03-12T22:07:47.000Z
2022-03-08T14:05:05.000Z
sosia/processing/tests/test_querying.py
sosia-dev/sosia
d4d2d5edb0cd1d085b5a457eb6d19bf8e9fea7f5
[ "MIT" ]
31
2018-10-15T16:02:44.000Z
2021-04-09T08:13:44.000Z
sosia/processing/tests/test_querying.py
sosia-dev/sosia
d4d2d5edb0cd1d085b5a457eb6d19bf8e9fea7f5
[ "MIT" ]
2
2020-01-09T06:47:09.000Z
2020-12-05T13:21:03.000Z
# -*- coding: utf-8 -*- """Tests for processing.querying module.""" from os.path import expanduser from nose.tools import assert_equal, assert_true from string import Template from sosia.establishing import connect_database from sosia.processing import base_query, count_citations, create_queries,\ query_pubs_by_...
39.708955
83
0.66698
# -*- coding: utf-8 -*- """Tests for processing.querying module.""" from os.path import expanduser from nose.tools import assert_equal, assert_true from string import Template from sosia.establishing import connect_database from sosia.processing import base_query, count_citations, create_queries,\ query_pubs_by_...
4,646
0
184
87cb912625c5f0172dccede1f05b6398960d3c64
3,004
py
Python
data/scripts/weather/weather.py
obi-two/GameServer
7d37024e2291a97d49522610cd8f1dbe5666afc2
[ "MIT" ]
20
2015-02-23T15:11:56.000Z
2022-03-18T20:56:48.000Z
data/scripts/weather/weather.py
apathyboy/swganh
665128efe9154611dec4cb5efc61d246dd095984
[ "MIT" ]
null
null
null
data/scripts/weather/weather.py
apathyboy/swganh
665128efe9154611dec4cb5efc61d246dd095984
[ "MIT" ]
20
2015-04-04T16:35:59.000Z
2022-03-24T14:54:37.000Z
# swgpy from swgpy import app, utility, weather from swgpy.weather import WeatherEvent, WeatherSequence # modules import random service_mgr = kernel.serviceManager() weather_svc = service_mgr.weatherService() #This script is called every 30 minutes. #Weather duration is now set in minutes: weather_event(duration(mins...
61.306122
121
0.778296
# swgpy from swgpy import app, utility, weather from swgpy.weather import WeatherEvent, WeatherSequence # modules import random service_mgr = kernel.serviceManager() weather_svc = service_mgr.weatherService() #This script is called every 30 minutes. #Weather duration is now set in minutes: weather_event(duration(mins...
165
0
22
bad18646aa55721ad9b73e97436ebeaa678b78df
3,353
py
Python
run.py
tomplays/raspberry-car
1458b0ed698232bc03133248b5ff616f3b6f3290
[ "MIT" ]
6
2015-07-13T10:19:55.000Z
2018-11-08T13:16:55.000Z
run.py
tomplays/raspberry-car
1458b0ed698232bc03133248b5ff616f3b6f3290
[ "MIT" ]
null
null
null
run.py
tomplays/raspberry-car
1458b0ed698232bc03133248b5ff616f3b6f3290
[ "MIT" ]
1
2021-02-13T19:49:16.000Z
2021-02-13T19:49:16.000Z
#!/usr/bin/env python # blou # Raspberry Car v1.xx # MIT Licence - Tom Wersinger https://github.com/tomplays/raspberry-car/ import RPi.GPIO as io import time # pins attribution #motor A in3_pin = 4 in4_pin = 17 #motor B in1_pin = 27 in2_pin = 22 #Blinking orange leds o_pin = 24 or_pin = 23 # always stop motors a...
22.503356
72
0.554131
#!/usr/bin/env python # blou # Raspberry Car v1.xx # MIT Licence - Tom Wersinger https://github.com/tomplays/raspberry-car/ import RPi.GPIO as io import time # pins attribution #motor A in3_pin = 4 in4_pin = 17 #motor B in1_pin = 27 in2_pin = 22 #Blinking orange leds o_pin = 24 or_pin = 23 # always stop motors a...
1,795
0
110
d716fb576f2df8487d65e77afa4a5b2379a0f174
1,821
py
Python
api_recipes/serializers.py
szypkiwonsz/Recipes-Rest-Api
8fa5c826f26a8160314d81f5f0e8df7407ee4c13
[ "MIT" ]
null
null
null
api_recipes/serializers.py
szypkiwonsz/Recipes-Rest-Api
8fa5c826f26a8160314d81f5f0e8df7407ee4c13
[ "MIT" ]
null
null
null
api_recipes/serializers.py
szypkiwonsz/Recipes-Rest-Api
8fa5c826f26a8160314d81f5f0e8df7407ee4c13
[ "MIT" ]
null
null
null
from drf_writable_nested import WritableNestedModelSerializer, UniqueFieldsMixin from rest_framework import serializers from api_recipes.models import Recipe, Ingredient, Food, Step, User class FoodSerializer(UniqueFieldsMixin, serializers.ModelSerializer): """Food serializer.""" class StepSerializer(UniqueFie...
27.179104
80
0.674355
from drf_writable_nested import WritableNestedModelSerializer, UniqueFieldsMixin from rest_framework import serializers from api_recipes.models import Recipe, Ingredient, Food, Step, User class FoodSerializer(UniqueFieldsMixin, serializers.ModelSerializer): """Food serializer.""" def create(self, validated_...
482
304
216
0d575dfb068e866aa2a4d160851da5eda651fa00
1,971
py
Python
jdcloud_sdk/services/monitor/models/UpdateCmAlarmSpec.py
jdcloud-demo/jdcloud-sdk-python
fddc2af24031c597948b8b8091978ac7e01a2695
[ "Apache-2.0" ]
null
null
null
jdcloud_sdk/services/monitor/models/UpdateCmAlarmSpec.py
jdcloud-demo/jdcloud-sdk-python
fddc2af24031c597948b8b8091978ac7e01a2695
[ "Apache-2.0" ]
null
null
null
jdcloud_sdk/services/monitor/models/UpdateCmAlarmSpec.py
jdcloud-demo/jdcloud-sdk-python
fddc2af24031c597948b8b8091978ac7e01a2695
[ "Apache-2.0" ]
null
null
null
# coding=utf8 # Copyright 2018 JDCLOUD.COM # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
39.42
186
0.679351
# coding=utf8 # Copyright 2018 JDCLOUD.COM # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
0
1,599
23
e12340c19552627ebf352b0af090b6a4d4ab0aac
728
py
Python
ella/articles/admin.py
petrlosa/ella
120eac56b46b7b79cdeea0582d2711f5a4b0bf51
[ "BSD-3-Clause" ]
75
2015-01-17T08:30:08.000Z
2022-02-23T19:05:36.000Z
ella/articles/admin.py
petrlosa/ella
120eac56b46b7b79cdeea0582d2711f5a4b0bf51
[ "BSD-3-Clause" ]
3
2016-04-21T22:16:37.000Z
2021-07-08T12:47:37.000Z
ella/articles/admin.py
petrlosa/ella
120eac56b46b7b79cdeea0582d2711f5a4b0bf51
[ "BSD-3-Clause" ]
26
2015-02-12T04:13:41.000Z
2022-01-08T05:26:27.000Z
from django.contrib import admin from django.utils.translation import ugettext_lazy as _ from ella.core.admin import PublishableAdmin, ListingInlineAdmin, RelatedInlineAdmin from ella.articles.models import Article admin.site.register(Article, ArticleAdmin)
36.4
96
0.677198
from django.contrib import admin from django.utils.translation import ugettext_lazy as _ from ella.core.admin import PublishableAdmin, ListingInlineAdmin, RelatedInlineAdmin from ella.articles.models import Article class ArticleAdmin(PublishableAdmin): ordering = ('-publish_from',) fieldsets = ( (_("...
0
443
23