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
0ef084880aa5a686fc78250f687244510146698b
1,235
py
Python
slothql/types/fields/shortcuts.py
IndioInc/slothql
64a574013e249968746044555bd8779ac353b13f
[ "MIT" ]
2
2018-02-09T19:12:00.000Z
2018-04-13T01:50:15.000Z
slothql/types/fields/shortcuts.py
IndioInc/slothql
64a574013e249968746044555bd8779ac353b13f
[ "MIT" ]
29
2018-02-02T01:07:07.000Z
2018-05-28T23:04:28.000Z
slothql/types/fields/shortcuts.py
IndioInc/slothql
64a574013e249968746044555bd8779ac353b13f
[ "MIT" ]
null
null
null
from slothql.types.scalars import IntegerType, FloatType, StringType, BooleanType, IDType from slothql.types.json import JsonStringType from slothql.types.datetime import DateTimeType, DateType, TimeType from .field import Field
24.7
89
0.687449
from slothql.types.scalars import IntegerType, FloatType, StringType, BooleanType, IDType from slothql.types.json import JsonStringType from slothql.types.datetime import DateTimeType, DateType, TimeType from .field import Field class Integer(Field): def __init__(self, **kwargs): super().__init__(of_type=...
566
-10
441
50578585f1b1c3714387270db94790d2634d62a0
2,573
py
Python
db/createDB.py
DigasNikas/PyRecommender
fb056929bba45431a5fc98691332b9bf91e730bb
[ "MIT" ]
2
2017-05-27T15:06:04.000Z
2018-11-23T06:43:25.000Z
db/createDB.py
DigasNikas/PyRecommender
fb056929bba45431a5fc98691332b9bf91e730bb
[ "MIT" ]
null
null
null
db/createDB.py
DigasNikas/PyRecommender
fb056929bba45431a5fc98691332b9bf91e730bb
[ "MIT" ]
null
null
null
import psycopg2 import json import os import sys def create_tables(): """ create tables in the PostgreSQL database""" commands = ( """DROP TABLE main; """, """ CREATE TABLE main ( package VARCHAR NOT NULL, category VARCHAR NOT NULL, downloads ...
32.1625
107
0.551108
import psycopg2 import json import os import sys def read_jason(path): conn = None part_files = os.listdir(path) try: # read the connection parameters params = "dbname='app_data' user='postgres' host='localhost' password='postgres'" # connect to the PostgreSQL server conn = ...
1,385
0
23
37b72cb9ac1bd75472e0e7f41ef60e09200233d3
1,821
py
Python
mlqm/models/GaussianBoundaryCondition.py
Nuclear-Physics-with-Machine-Learning/MLQM
69472921b130abb530b11840ab8c1b8c608b5089
[ "Apache-2.0" ]
8
2021-05-13T13:58:56.000Z
2022-02-28T22:11:06.000Z
mlqm/models/GaussianBoundaryCondition.py
coreyjadams/AI-for-QM
69472921b130abb530b11840ab8c1b8c608b5089
[ "Apache-2.0" ]
1
2021-09-23T01:44:26.000Z
2021-09-23T17:51:43.000Z
mlqm/models/GaussianBoundaryCondition.py
coreyjadams/AI-for-QM
69472921b130abb530b11840ab8c1b8c608b5089
[ "Apache-2.0" ]
1
2022-03-15T07:18:24.000Z
2022-03-15T07:18:24.000Z
import tensorflow as tf import numpy class GaussianBoundaryCondition(tf.keras.layers.Layer): """A simple module for applying an exponential boundary condition in N dimensions Note that the exponent is *inside* of the power of 2 in the exponent. This is to prevent divergence when it is trainable and goes n...
34.358491
123
0.643053
import tensorflow as tf import numpy class GaussianBoundaryCondition(tf.keras.layers.Layer): """A simple module for applying an exponential boundary condition in N dimensions Note that the exponent is *inside* of the power of 2 in the exponent. This is to prevent divergence when it is trainable and goes n...
472
0
26
a380d47347ebec46f0b4459ad3d764d33d8e18ac
70,890
py
Python
gridsim/grid_sim_linear_program.py
mfastudillo/energysimulation
09c40bc52fd41e00be0fcafca40e2f5cb9e8ef8f
[ "Apache-2.0" ]
null
null
null
gridsim/grid_sim_linear_program.py
mfastudillo/energysimulation
09c40bc52fd41e00be0fcafca40e2f5cb9e8ef8f
[ "Apache-2.0" ]
null
null
null
gridsim/grid_sim_linear_program.py
mfastudillo/energysimulation
09c40bc52fd41e00be0fcafca40e2f5cb9e8ef8f
[ "Apache-2.0" ]
null
null
null
# Copyright 2017 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
36.883455
88
0.645253
# Copyright 2017 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
3,654
184
408
d5ab3a7720db01daa3de43c7dfde773e221acba3
899
py
Python
tests/test_tfidf.py
eig-2017/dedupe
7f90bcbbf345534b8692df726e9ba2479856bba1
[ "MIT" ]
null
null
null
tests/test_tfidf.py
eig-2017/dedupe
7f90bcbbf345534b8692df726e9ba2479856bba1
[ "MIT" ]
null
null
null
tests/test_tfidf.py
eig-2017/dedupe
7f90bcbbf345534b8692df726e9ba2479856bba1
[ "MIT" ]
null
null
null
import dedupe import unittest if __name__ == "__main__": unittest.main()
29
69
0.575083
import dedupe import unittest class ParsingTest(unittest.TestCase) : def setUp(self) : self.index = dedupe.tfidf.TfIdfIndex() def test_keywords(self) : self.index.index(('AND', 'OR', 'EOF', 'NOT')) self.index._index.initSearch() assert self.index.search(('AND', 'OR', 'E...
638
17
165
c34d95a85f6568f6c9a18b0c92ccbd0ba5e083c9
2,788
py
Python
get_data.py
Jack07310/Project-2-Image-Classifier-Part-2
cafb78ca541faae45851281e87b99c2cdc493f04
[ "MIT" ]
null
null
null
get_data.py
Jack07310/Project-2-Image-Classifier-Part-2
cafb78ca541faae45851281e87b99c2cdc493f04
[ "MIT" ]
null
null
null
get_data.py
Jack07310/Project-2-Image-Classifier-Part-2
cafb78ca541faae45851281e87b99c2cdc493f04
[ "MIT" ]
null
null
null
#get_data.py #234567890123456789012345678901234567890123456789012345678901234567890123456789 # Imports here import torch from torchvision import datasets, transforms # The command line parser for train.py
40.405797
79
0.532999
#get_data.py #234567890123456789012345678901234567890123456789012345678901234567890123456789 # Imports here import torch from torchvision import datasets, transforms # The command line parser for train.py def get_dataloaders(data_dir): # Load the data train_dir = data_dir + '/train' valid_dir = data_dir + '/...
2,560
0
22
cceaa1dde18416d633f3357f1ad781584903faad
1,421
py
Python
Backend/migrations/alembic/versions/f8791d49d830_create_bed_capacity_table.py
dbvis-ukon/coronavis
f00374ac655c9d68541183d28ede6fe5536581dc
[ "Apache-2.0" ]
15
2020-04-24T20:18:11.000Z
2022-01-31T21:05:05.000Z
Backend/migrations/alembic/versions/f8791d49d830_create_bed_capacity_table.py
dbvis-ukon/coronavis
f00374ac655c9d68541183d28ede6fe5536581dc
[ "Apache-2.0" ]
2
2021-05-19T07:15:09.000Z
2022-03-07T08:29:34.000Z
Backend/migrations/alembic/versions/f8791d49d830_create_bed_capacity_table.py
dbvis-ukon/coronavis
f00374ac655c9d68541183d28ede6fe5536581dc
[ "Apache-2.0" ]
4
2020-04-27T16:20:13.000Z
2021-02-23T10:39:42.000Z
"""create bed_capacity table Revision ID: f8791d49d830 Revises: b84312f6532e Create Date: 2020-11-26 15:22:19.299937 """ from alembic import op # revision identifiers, used by Alembic. revision = 'f8791d49d830' down_revision = '4fcda072e8c6' branch_labels = None depends_on = None
28.42
82
0.635468
"""create bed_capacity table Revision ID: f8791d49d830 Revises: b84312f6532e Create Date: 2020-11-26 15:22:19.299937 """ from alembic import op # revision identifiers, used by Alembic. revision = 'f8791d49d830' down_revision = '4fcda072e8c6' branch_labels = None depends_on = None def upgrade(): op.get_bind().e...
1,089
0
46
cdb565b081ef8900b32c772239390e1a1c75c7d1
4,897
py
Python
openjij/sampler/response.py
Atsushi-Machida/OpenJij
e4bddebb13536eb26ff0b7b9fc6b1c75659fe934
[ "Apache-2.0" ]
null
null
null
openjij/sampler/response.py
Atsushi-Machida/OpenJij
e4bddebb13536eb26ff0b7b9fc6b1c75659fe934
[ "Apache-2.0" ]
null
null
null
openjij/sampler/response.py
Atsushi-Machida/OpenJij
e4bddebb13536eb26ff0b7b9fc6b1c75659fe934
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 Jij Inc. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, softwa...
32.430464
91
0.602001
# Copyright 2019 Jij Inc. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, softwa...
1,484
0
81
559b08125c8dd5044f6a3227a31f3322c215c5f1
231
py
Python
Round #534 (Div 2)/B.py
julianferres/Codeforces
ac80292a4d53b8078fc1a85e91db353c489555d9
[ "MIT" ]
4
2020-01-31T15:49:25.000Z
2020-07-07T11:44:03.000Z
Round #534 (Div 2)/B.py
julianferres/CodeForces
14e8369e82a2403094183d6f7824201f681c9f65
[ "MIT" ]
null
null
null
Round #534 (Div 2)/B.py
julianferres/CodeForces
14e8369e82a2403094183d6f7824201f681c9f65
[ "MIT" ]
null
null
null
B()
12.833333
44
0.554113
def B(): s = input() stack = [] counter = 0 for x in s: if(not len(stack)): stack.append(x) elif(stack[-1]==x): stack.pop() counter+=1 else: stack.append(x) print("Yes") if(counter%2) else print("No") B()
205
0
22
6b14c5d2b9d6119d7b2f3a785b2ddfa6e6e4344f
1,799
py
Python
py_se_day03/py_fucntions.py
letscodedjango/py-se-bootcamp
302e2acb69f4aaefbb2fe6361083c9135b000394
[ "MIT" ]
null
null
null
py_se_day03/py_fucntions.py
letscodedjango/py-se-bootcamp
302e2acb69f4aaefbb2fe6361083c9135b000394
[ "MIT" ]
null
null
null
py_se_day03/py_fucntions.py
letscodedjango/py-se-bootcamp
302e2acb69f4aaefbb2fe6361083c9135b000394
[ "MIT" ]
1
2020-05-20T14:48:48.000Z
2020-05-20T14:48:48.000Z
# # add_numbers() # x = add_numbers_version_01(20,30) # print(x) # ? # not returning anything to you # add_numbers_version_01(50, 10) # add_numbers_version_01(300, 29) # add_numbers_version_01(20.78, 56.89) # # Average of two numbers # Add 2 nos and then divide the sum with nos. of value # no_one = 50 # n...
19.344086
96
0.712062
# def add_numbers(): no_one = 20 no_two = 30 result = no_one + no_two print(result) # add_numbers() def add_numbers_version_01(x, y): no_one = x no_two = y result = no_one + no_two #print("The value of result variable is " + str(result) ) ### ? return result # print(result) # x = add_numbers_version_01...
538
0
114
f4e25421a136d0f49225bf4f0ffc79ec0d8aff41
264
py
Python
GTFS2OMNS/test.py
luyuliu/playground
0e0382be27abf6714bda8ea1bc34249286ef53c1
[ "MIT" ]
null
null
null
GTFS2OMNS/test.py
luyuliu/playground
0e0382be27abf6714bda8ea1bc34249286ef53c1
[ "MIT" ]
null
null
null
GTFS2OMNS/test.py
luyuliu/playground
0e0382be27abf6714bda8ea1bc34249286ef53c1
[ "MIT" ]
null
null
null
# Note: # 1. Need dependency autoinstall # 2. GDAL import os os.environ['PATH'] import gtfs2gmns as gg gtfs_path = "H:\\ChromeDownload\\gtfscota" gmns_path = "H:\\ChromeDownload\\gtfscota\\output" node_transit,link_transit = gg.Convert_GTFS(gtfs_path,gmns_path)
22
64
0.761364
# Note: # 1. Need dependency autoinstall # 2. GDAL import os os.environ['PATH'] import gtfs2gmns as gg gtfs_path = "H:\\ChromeDownload\\gtfscota" gmns_path = "H:\\ChromeDownload\\gtfscota\\output" node_transit,link_transit = gg.Convert_GTFS(gtfs_path,gmns_path)
0
0
0
6399edf0c794754950ba2f79efc7d0c101bed496
9,518
py
Python
scipy/sparse/linalg/eigen/_svds.py
jcharlong/scipy
153467a9174b0c6f4b90ffeed5871e5018658108
[ "BSD-3-Clause" ]
1
2021-08-16T09:32:42.000Z
2021-08-16T09:32:42.000Z
scipy/sparse/linalg/eigen/_svds.py
jcharlong/scipy
153467a9174b0c6f4b90ffeed5871e5018658108
[ "BSD-3-Clause" ]
44
2019-06-27T15:56:14.000Z
2022-03-15T22:21:10.000Z
scipy/sparse/linalg/eigen/_svds.py
jcharlong/scipy
153467a9174b0c6f4b90ffeed5871e5018658108
[ "BSD-3-Clause" ]
4
2020-06-13T10:32:25.000Z
2021-12-03T15:48:16.000Z
import numpy as np from .arpack import _arpack # type: ignore[attr-defined] from . import eigsh from scipy.sparse.linalg.interface import LinearOperator from scipy.sparse import isspmatrix from scipy.sparse.sputils import is_pydata_spmatrix from scipy.sparse.linalg.eigen.lobpcg import lobpcg # type: ignore[no-redef...
34.737226
79
0.604854
import numpy as np from .arpack import _arpack # type: ignore[attr-defined] from . import eigsh from scipy.sparse.linalg.interface import LinearOperator from scipy.sparse import isspmatrix from scipy.sparse.sputils import is_pydata_spmatrix from scipy.sparse.linalg.eigen.lobpcg import lobpcg # type: ignore[no-redef...
924
0
123
99b6bd941f90c609486b360ca9e450f760cfa0d4
691
py
Python
monty/os/__init__.py
yanikou19/monty
822ae841f7d29bd7464287fd99b51da6e5960088
[ "MIT" ]
null
null
null
monty/os/__init__.py
yanikou19/monty
822ae841f7d29bd7464287fd99b51da6e5960088
[ "MIT" ]
null
null
null
monty/os/__init__.py
yanikou19/monty
822ae841f7d29bd7464287fd99b51da6e5960088
[ "MIT" ]
null
null
null
from __future__ import absolute_import __author__ = 'Shyue Ping Ong' __copyright__ = 'Copyright 2013, The Materials Project' __version__ = '0.1' __maintainer__ = 'Shyue Ping Ong' __email__ = 'ongsp@ucsd.edu' __date__ = '1/24/14' import os from contextlib import contextmanager @contextmanager def cd(path): """ ...
20.939394
72
0.66136
from __future__ import absolute_import __author__ = 'Shyue Ping Ong' __copyright__ = 'Copyright 2013, The Materials Project' __version__ = '0.1' __maintainer__ = 'Shyue Ping Ong' __email__ = 'ongsp@ucsd.edu' __date__ = '1/24/14' import os from contextlib import contextmanager @contextmanager def cd(path): """ ...
0
0
0
0aa7b9480412288c537a477f9a614f1b0959bd31
5,683
py
Python
eval.py
khchow-gt/mnist_challenge
89e9e05b538e887de3e2e5ba45809b7b7505f5c1
[ "MIT" ]
null
null
null
eval.py
khchow-gt/mnist_challenge
89e9e05b538e887de3e2e5ba45809b7b7505f5c1
[ "MIT" ]
null
null
null
eval.py
khchow-gt/mnist_challenge
89e9e05b538e887de3e2e5ba45809b7b7505f5c1
[ "MIT" ]
null
null
null
""" Infinite evaluation loop going through the checkpoints in the model directory as they appear and evaluating them. Accuracy and average loss are printed and added as tensorboard summaries. """ from __future__ import absolute_import from __future__ import division from __future__ import print_function from ...
35.298137
79
0.600211
""" Infinite evaluation loop going through the checkpoints in the model directory as they appear and evaluating them. Accuracy and average loss are printed and added as tensorboard summaries. """ from __future__ import absolute_import from __future__ import division from __future__ import print_function from ...
2,393
0
23
04b1d605171844fcc802147261d398861e284991
5,204
py
Python
tests/test_xbse_calendar.py
GitDjTHU/exchange_calendars
5c544f74d14fe01aa43a18a73667033124495d0c
[ "Apache-2.0" ]
null
null
null
tests/test_xbse_calendar.py
GitDjTHU/exchange_calendars
5c544f74d14fe01aa43a18a73667033124495d0c
[ "Apache-2.0" ]
7
2021-11-03T01:20:29.000Z
2022-03-31T01:28:12.000Z
tests/test_xbse_calendar.py
GitDjTHU/exchange_calendars
5c544f74d14fe01aa43a18a73667033124495d0c
[ "Apache-2.0" ]
null
null
null
from unittest import TestCase import pandas as pd from pytz import UTC from exchange_calendars.exchange_calendar_xbse import XBSEExchangeCalendar from .test_exchange_calendar import ExchangeCalendarTestBase
43.008264
88
0.590123
from unittest import TestCase import pandas as pd from pytz import UTC from exchange_calendars.exchange_calendar_xbse import XBSEExchangeCalendar from .test_exchange_calendar import ExchangeCalendarTestBase class XBSECalendarTestCase(ExchangeCalendarTestBase, TestCase): answer_key_filename = "xbse" calend...
3,352
1,618
23
50f41c52255abfd0c6e8b9f4a85116ed07d020a3
887
py
Python
jp.atcoder/abc086/arc089_a/8309315.py
kagemeka/atcoder-submissions
91d8ad37411ea2ec582b10ba41b1e3cae01d4d6e
[ "MIT" ]
1
2022-02-09T03:06:25.000Z
2022-02-09T03:06:25.000Z
jp.atcoder/abc086/arc089_a/8309315.py
kagemeka/atcoder-submissions
91d8ad37411ea2ec582b10ba41b1e3cae01d4d6e
[ "MIT" ]
1
2022-02-05T22:53:18.000Z
2022-02-09T01:29:30.000Z
jp.atcoder/abc086/arc089_a/8309315.py
kagemeka/atcoder-submissions
91d8ad37411ea2ec582b10ba41b1e3cae01d4d6e
[ "MIT" ]
null
null
null
# author: kagemeka # created: 2019-11-06 12:47:30(JST) import sys # import collections # import math # import string # import bisect # import re # import itertools # import statistics if __name__ == "__main__": # execute only if run as a script ...
22.74359
74
0.445321
# author: kagemeka # created: 2019-11-06 12:47:30(JST) import sys # import collections # import math # import string # import bisect # import re # import itertools # import statistics def main(): n, *txy = (int(x) for x in sys.stdin.read().split()) ...
532
0
25
9d8e89264f07302c0cb52316292081e4a527f1bb
7,218
py
Python
src/sima/workflow/plotnode.py
SINTEF/simapy
650b8c2f15503dad98e2bfc0d0788509593822c7
[ "MIT" ]
null
null
null
src/sima/workflow/plotnode.py
SINTEF/simapy
650b8c2f15503dad98e2bfc0d0788509593822c7
[ "MIT" ]
null
null
null
src/sima/workflow/plotnode.py
SINTEF/simapy
650b8c2f15503dad98e2bfc0d0788509593822c7
[ "MIT" ]
null
null
null
# This an autogenerated file # # Generated with PlotNode from typing import Dict,Sequence,List from dmt.entity import Entity from dmt.blueprint import Blueprint from .blueprints.plotnode import PlotNodeBlueprint from typing import Dict from sima.post.controlsignalinputslot import ControlSignalInputSlot from sima.post....
25.595745
168
0.590053
# This an autogenerated file # # Generated with PlotNode from typing import Dict,Sequence,List from dmt.entity import Entity from dmt.blueprint import Blueprint from .blueprints.plotnode import PlotNodeBlueprint from typing import Dict from sima.post.controlsignalinputslot import ControlSignalInputSlot from sima.post....
867
0
27
6c83e241e2fd1082aae160c9ab4a297c935583b4
10,275
py
Python
src/photo/tests/test_utils.py
rjhelms/photo
fd9e3ff384554c5bc1e3b024d13ca40f50e049e5
[ "MIT" ]
null
null
null
src/photo/tests/test_utils.py
rjhelms/photo
fd9e3ff384554c5bc1e3b024d13ca40f50e049e5
[ "MIT" ]
null
null
null
src/photo/tests/test_utils.py
rjhelms/photo
fd9e3ff384554c5bc1e3b024d13ca40f50e049e5
[ "MIT" ]
null
null
null
# pylint: disable=invalid-name """ Tests for photo.utils """ import uuid from django.test import TestCase from photo import utils # pylint: disable=too-few-public-methods class DummyInstance: """ Dummy instance object for passing into UploadToPathAndRename """ pk = None class UploadToPathAndRenameT...
35.801394
78
0.631533
# pylint: disable=invalid-name """ Tests for photo.utils """ import uuid from django.test import TestCase from photo import utils # pylint: disable=too-few-public-methods class DummyInstance: """ Dummy instance object for passing into UploadToPathAndRename """ pk = None class UploadToPathAndRenameT...
112
0
26
e5b3c5630bb7e2c668fe7689326b01560779d8e5
2,970
py
Python
python_code/medium/430_Flatten_Multilevel_Doubly_Linked_List_medium/solution.py
timshenkao/interview_coding_exercises
c531fa5e0c09faef976539275589e957fcb88393
[ "Apache-2.0" ]
null
null
null
python_code/medium/430_Flatten_Multilevel_Doubly_Linked_List_medium/solution.py
timshenkao/interview_coding_exercises
c531fa5e0c09faef976539275589e957fcb88393
[ "Apache-2.0" ]
null
null
null
python_code/medium/430_Flatten_Multilevel_Doubly_Linked_List_medium/solution.py
timshenkao/interview_coding_exercises
c531fa5e0c09faef976539275589e957fcb88393
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2021 - present, Timur Shenkao # All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appl...
47.903226
120
0.678451
# Copyright (c) 2021 - present, Timur Shenkao # All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appl...
691
530
23
53fa4a3dfcdf40efa45d965ce57530c2fb2653cb
5,266
py
Python
file_forensics.py
nshadov/file_forensics
ff87d84876daf12614185acc8b31ace2aa21fe0a
[ "MIT" ]
8
2017-06-09T21:18:52.000Z
2022-02-18T00:55:28.000Z
file_forensics.py
nshadov/file_forensics
ff87d84876daf12614185acc8b31ace2aa21fe0a
[ "MIT" ]
null
null
null
file_forensics.py
nshadov/file_forensics
ff87d84876daf12614185acc8b31ace2aa21fe0a
[ "MIT" ]
null
null
null
#!/usr/bin/env python """Searches specified directory for miss named files.""" import os class bcolors: """Color text in terminal.""" HEADER = '\033[95m' OKBLUE = '\033[94m' OKGREEN = '\033[92m' WARNING = '\033[93m' FAIL = '\033[91m' ENDC = '\033[0m' BOLD = '\033[1m' UNDERLINE =...
32.9125
79
0.507026
#!/usr/bin/env python """Searches specified directory for miss named files.""" import os class bcolors: """Color text in terminal.""" HEADER = '\033[95m' OKBLUE = '\033[94m' OKGREEN = '\033[92m' WARNING = '\033[93m' FAIL = '\033[91m' ENDC = '\033[0m' BOLD = '\033[1m' UNDERLINE =...
0
0
0
605b26d6d3532dde3890281f964748b6b7ca2774
4,620
py
Python
test_equipment/openSMILE_dir_to_csv.py
ChildMindInstitute/test_recording_equipment
ce062be5c278f4c32c72eadd90b68e4898e9f1fe
[ "Apache-2.0" ]
1
2018-07-20T23:45:22.000Z
2018-07-20T23:45:22.000Z
test_equipment/openSMILE_dir_to_csv.py
ChildMindInstitute/test-recording-equipment
ce062be5c278f4c32c72eadd90b68e4898e9f1fe
[ "Apache-2.0" ]
null
null
null
test_equipment/openSMILE_dir_to_csv.py
ChildMindInstitute/test-recording-equipment
ce062be5c278f4c32c72eadd90b68e4898e9f1fe
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ openSMILE_dir_to_csv.py Script to format openSMILE emobase *.csv output for a given set of files into a single csv. Also returns the data as a pandas dataframe. Created on Mon Jan 23 10:43:34 2017 Author: – Jon Clucas, 2017 (jon.clucas@childmind.org) © 2017...
34.222222
79
0.585714
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ openSMILE_dir_to_csv.py Script to format openSMILE emobase *.csv output for a given set of files into a single csv. Also returns the data as a pandas dataframe. Created on Mon Jan 23 10:43:34 2017 Author: – Jon Clucas, 2017 (jon.clucas@childmind.org) © 2017...
444
0
23
8973e35176c8a1a48a4120591aa32770860149cc
2,186
py
Python
examples/frameworks/catboost/catboost_example.py
thepycoder/clearml
717edba8c2b39fb7486bd2aba9ca0294f309b4c3
[ "Apache-2.0" ]
2,097
2019-06-11T14:36:25.000Z
2020-12-21T03:52:59.000Z
examples/frameworks/catboost/catboost_example.py
thepycoder/clearml
717edba8c2b39fb7486bd2aba9ca0294f309b4c3
[ "Apache-2.0" ]
247
2019-06-11T15:10:26.000Z
2020-12-21T17:34:32.000Z
examples/frameworks/catboost/catboost_example.py
thepycoder/clearml
717edba8c2b39fb7486bd2aba9ca0294f309b4c3
[ "Apache-2.0" ]
256
2019-06-11T14:36:28.000Z
2020-12-18T08:32:47.000Z
# ClearML - Example of CatBoost training, saving model and loading model # import argparse from catboost import CatBoostRegressor, Pool from catboost.datasets import msrank from clearml import Task import numpy as np from sklearn.model_selection import train_test_split if __name__ == "__main__": Task.init(pr...
35.836066
100
0.741537
# ClearML - Example of CatBoost training, saving model and loading model # import argparse from catboost import CatBoostRegressor, Pool from catboost.datasets import msrank from clearml import Task import numpy as np from sklearn.model_selection import train_test_split def main(iterations): # Download train a...
1,634
0
23
1f3ee22025ccb85d0fe14837daa5f25f69472cd0
411
py
Python
src/product/signals.py
asanka94/OMS-backend
0b0637b40e71b9b71156d28fdc0ff1fb7a3d12ac
[ "MIT" ]
null
null
null
src/product/signals.py
asanka94/OMS-backend
0b0637b40e71b9b71156d28fdc0ff1fb7a3d12ac
[ "MIT" ]
9
2021-03-19T01:50:04.000Z
2022-03-12T00:23:18.000Z
src/product/signals.py
asanka94/OMS-backend
0b0637b40e71b9b71156d28fdc0ff1fb7a3d12ac
[ "MIT" ]
null
null
null
from django.template.defaultfilters import slugify def slug_generator(sender, instance, *args, **kwargs): ''' capitalize first letter of each word and generates slug ''' instance.name = instance.name.title() slug = slugify(instance.name) exists = sender.objects.filter(slug=slug).exists() if not exists...
27.4
66
0.688564
from django.template.defaultfilters import slugify def slug_generator(sender, instance, *args, **kwargs): ''' capitalize first letter of each word and generates slug ''' instance.name = instance.name.title() slug = slugify(instance.name) exists = sender.objects.filter(slug=slug).exists() if not exists...
0
0
0
5d777d6f520440d73be3b7e20022b539bde151fb
14,330
py
Python
tests/utils/html.py
boltnev/iktomi
bc92006c026f9b42e56f1af5ced2fe577673a486
[ "MIT" ]
14
2015-02-15T05:24:22.000Z
2020-03-19T10:07:28.000Z
tests/utils/html.py
boltnev/iktomi
bc92006c026f9b42e56f1af5ced2fe577673a486
[ "MIT" ]
10
2015-04-04T10:10:41.000Z
2016-06-01T13:17:58.000Z
tests/utils/html.py
boltnev/iktomi
bc92006c026f9b42e56f1af5ced2fe577673a486
[ "MIT" ]
5
2015-02-20T11:18:58.000Z
2016-10-18T15:30:13.000Z
# -*- coding: utf-8 -*- import unittest import os import re from iktomi.utils import html from lxml.html import Element from lxml import etree import lxml.html as h class TestSanitizer(unittest.TestCase): '''Tests for sanitizer based on lxml''' @unittest.skip('lxml does not provide css filtration') def te...
42.776119
105
0.52589
# -*- coding: utf-8 -*- import unittest import os import re from iktomi.utils import html from lxml.html import Element from lxml import etree import lxml.html as h class TestSanitizer(unittest.TestCase): '''Tests for sanitizer based on lxml''' def setUp(self): self.attrs = { 'allow_tags':...
11,055
0
776
38b2d2763ba8fad7eb60aaae1908527d08cc5568
1,216
py
Python
Algorithms/Strings/remove_vowels.py
Praggya17/HacktoberFestContribute
098cb1012f1f2ed6ca6b3544a7b962b6c49e2643
[ "MIT" ]
98
2018-10-09T15:42:41.000Z
2021-10-04T15:25:44.000Z
Algorithms/Strings/remove_vowels.py
Praggya17/HacktoberFestContribute
098cb1012f1f2ed6ca6b3544a7b962b6c49e2643
[ "MIT" ]
141
2018-10-06T16:55:20.000Z
2021-10-31T18:25:35.000Z
Algorithms/Strings/remove_vowels.py
Praggya17/HacktoberFestContribute
098cb1012f1f2ed6ca6b3544a7b962b6c49e2643
[ "MIT" ]
885
2018-10-06T17:14:44.000Z
2022-01-29T03:16:21.000Z
#!/usr/bin/env python # from any given string, remove all vowels # NON REGEX VERSION sample_string='Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Ne...
64
881
0.813322
#!/usr/bin/env python # from any given string, remove all vowels # NON REGEX VERSION sample_string='Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Ne...
0
0
0
16be4ccde99385c97c7b33aca56b05715bfed523
5,490
py
Python
src/sdgen/svg/cairosvg/parser.py
PP-TSD/sdgen
58a3a46f7f612c8d7774dd43a4ab55df4f33ab20
[ "MIT" ]
1
2015-02-18T17:59:05.000Z
2015-02-18T17:59:05.000Z
src/sdgen/svg/cairosvg/parser.py
PP-TSD/sdgen
58a3a46f7f612c8d7774dd43a4ab55df4f33ab20
[ "MIT" ]
null
null
null
src/sdgen/svg/cairosvg/parser.py
PP-TSD/sdgen
58a3a46f7f612c8d7774dd43a4ab55df4f33ab20
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # This file is part of CairoSVG # Copyright © 2010-2012 Kozea # # This library is free software: you can redistribute it and/or modify it under # the terms of the GNU Lesser General Public License as published by the Free # Software Foundation, either version 3 of the License, or (at your option...
32.485207
79
0.573953
# -*- coding: utf-8 -*- # This file is part of CairoSVG # Copyright © 2010-2012 Kozea # # This library is free software: you can redistribute it and/or modify it under # the terms of the GNU Lesser General Public License as published by the Free # Software Foundation, either version 3 of the License, or (at your option...
0
0
0
b349d1e936564787580505606709c070ef2e106f
1,567
py
Python
src/onegov/town6/views/form_definition.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/form_definition.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/form_definition.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.core.security import Private, Public from onegov.form import FormCollection, FormDefinition from onegov.org.forms.form_definition import FormDefinitionUrlForm from onegov.org.views.form_definition import get_form_class, \ handle_new_definition, handle_edit_definition, handle_defined_form, \ handle_c...
39.175
75
0.767709
from onegov.core.security import Private, Public from onegov.form import FormCollection, FormDefinition from onegov.org.forms.form_definition import FormDefinitionUrlForm from onegov.org.views.form_definition import get_form_class, \ handle_new_definition, handle_edit_definition, handle_defined_form, \ handle_c...
514
0
88
19adb3a4de59d8b8ef5b77d31fbc5e8cc66282df
7,498
py
Python
src/gameplay.py
Gravens/AirDimples
5531b0e43afb1349b121a54bb8ab1dd29bba0a84
[ "Apache-2.0" ]
null
null
null
src/gameplay.py
Gravens/AirDimples
5531b0e43afb1349b121a54bb8ab1dd29bba0a84
[ "Apache-2.0" ]
2
2021-07-14T09:32:01.000Z
2021-07-19T16:25:15.000Z
src/gameplay.py
Gravens/AirDimples
5531b0e43afb1349b121a54bb8ab1dd29bba0a84
[ "Apache-2.0" ]
1
2021-07-14T15:31:02.000Z
2021-07-14T15:31:02.000Z
import cv2 from time import time from random import randint from object_manager import DefaultCircleManager, PackmanManager, MoovingCircleManager from utils import log, Joint from drawing import draw_objects from config import config
36.935961
106
0.609629
import cv2 from time import time from random import randint from object_manager import DefaultCircleManager, PackmanManager, MoovingCircleManager from utils import log, Joint from drawing import draw_objects from config import config class Game: def __init__(self, w_size): self.w_size = w_size sel...
6,646
13
601
13406aa5f5d3a775426e7a74d7015441611738ac
8,888
py
Python
dev/Gems/CloudGemMetric/v1/AWS/common-code/Lib/numba/tests/npyufunc/test_caching.py
jeikabu/lumberyard
07228c605ce16cbf5aaa209a94a3cb9d6c1a4115
[ "AML" ]
8
2019-10-07T16:33:47.000Z
2020-12-07T03:59:58.000Z
dev/Gems/CloudGemMetric/v1/AWS/common-code/Lib/numba/tests/npyufunc/test_caching.py
jeikabu/lumberyard
07228c605ce16cbf5aaa209a94a3cb9d6c1a4115
[ "AML" ]
1
2018-04-03T22:37:40.000Z
2018-04-03T23:53:43.000Z
dev/Gems/CloudGemMetric/v1/AWS/common-code/Lib/numba/tests/npyufunc/test_caching.py
jeikabu/lumberyard
07228c605ce16cbf5aaa209a94a3cb9d6c1a4115
[ "AML" ]
5
2020-08-27T20:44:18.000Z
2021-08-21T22:54:11.000Z
from __future__ import print_function, absolute_import, division import sys import os.path import re from contextlib import contextmanager import subprocess import numpy as np from numba import unittest_support as unittest from numba import config from ..support import captured_stdout from ..test_dispatcher import ...
37.344538
84
0.670117
from __future__ import print_function, absolute_import, division import sys import os.path import re from contextlib import contextmanager import subprocess import numpy as np from numba import unittest_support as unittest from numba import config from ..support import captured_stdout from ..test_dispatcher import ...
5,613
86
600
395d8eca7d1e0f912a781947a6d97be3bde8a106
35,045
py
Python
generator.py
s-fifteen-instruments/Digital_Pattern_Generator_DPG1
e8113154ba150a5d19e26171c9204cf22d55760d
[ "MIT" ]
null
null
null
generator.py
s-fifteen-instruments/Digital_Pattern_Generator_DPG1
e8113154ba150a5d19e26171c9204cf22d55760d
[ "MIT" ]
null
null
null
generator.py
s-fifteen-instruments/Digital_Pattern_Generator_DPG1
e8113154ba150a5d19e26171c9204cf22d55760d
[ "MIT" ]
null
null
null
""" this is an attempt to convert a readable patt format (similar to the ones compatible with arbitrarypatterngenerator) into the 4-word format that can be cat into pattern generator v2 it reads pattfile written in the following format and generate the corresponding dpatt: #triggered input_line use_table threshold_...
44.081761
349
0.706549
""" this is an attempt to convert a readable patt format (similar to the ones compatible with arbitrarypatterngenerator) into the 4-word format that can be cat into pattern generator v2 it reads pattfile written in the following format and generate the corresponding dpatt: #triggered input_line use_table threshold_...
30,471
0
310
8d68291ec8146ddef556012f26a8ece3f9f8aed0
237
py
Python
api/tasks.py
mkeller3/django_celery_redis
193e550644ef79b5f12d51aa8866c20f1a7a2a3a
[ "Apache-2.0" ]
null
null
null
api/tasks.py
mkeller3/django_celery_redis
193e550644ef79b5f12d51aa8866c20f1a7a2a3a
[ "Apache-2.0" ]
null
null
null
api/tasks.py
mkeller3/django_celery_redis
193e550644ef79b5f12d51aa8866c20f1a7a2a3a
[ "Apache-2.0" ]
null
null
null
# Create your tasks here from __future__ import absolute_import, unicode_literals from celery import shared_task import time @shared_task @shared_task
15.8
56
0.725738
# Create your tasks here from __future__ import absolute_import, unicode_literals from celery import shared_task import time @shared_task def add(x, y): time.sleep(30) return x + y @shared_task def mul(x, y): return x * y
39
0
44
3b627431f1cb8b0cc63515012844c169b8b05a75
321
py
Python
djangoapi/courses/serializers.py
peter0083/djangoapi
fe4e9e28d9c8df6625b401592ed4f91c7791a902
[ "MIT" ]
null
null
null
djangoapi/courses/serializers.py
peter0083/djangoapi
fe4e9e28d9c8df6625b401592ed4f91c7791a902
[ "MIT" ]
null
null
null
djangoapi/courses/serializers.py
peter0083/djangoapi
fe4e9e28d9c8df6625b401592ed4f91c7791a902
[ "MIT" ]
null
null
null
from rest_framework import serializers from .models import Course
45.857143
122
0.750779
from rest_framework import serializers from .models import Course class CourseSerializer(serializers.HyperlinkedModelSerializer): # serializers.HyperLinkedModelSerializer is the superclass class Meta: # a class container for metadata model = Course fields = ('id', 'url', 'name', 'language', 'price'...
0
233
23
78d0c18558fc3459c334f45b248e8979c544b47b
6,927
py
Python
modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores.py
Aexyn/webrtc2
daea5bf2deb843567a792f22ea2047a037e09d78
[ "DOC", "BSD-3-Clause" ]
2
2018-01-16T13:29:45.000Z
2018-08-10T09:15:23.000Z
modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores.py
Aexyn/webrtc2
daea5bf2deb843567a792f22ea2047a037e09d78
[ "DOC", "BSD-3-Clause" ]
null
null
null
modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores.py
Aexyn/webrtc2
daea5bf2deb843567a792f22ea2047a037e09d78
[ "DOC", "BSD-3-Clause" ]
null
null
null
# Copyright (c) 2017 The WebRTC project authors. All Rights Reserved. # # Use of this source code is governed by a BSD-style license # that can be found in the LICENSE file in the root of the source # tree. An additional intellectual property rights grant can be found # in the file PATENTS. All contributing project au...
28.273469
80
0.711708
# Copyright (c) 2017 The WebRTC project authors. All Rights Reserved. # # Use of this source code is governed by a BSD-style license # that can be found in the LICENSE file in the root of the source # tree. An additional intellectual property rights grant can be found # in the file PATENTS. All contributing project au...
2,769
1,686
173
fde991a1ade12f993fa6cd31e8d7a1c98760897e
407
py
Python
airloft/utils/icao.py
Allaye/airloft
deb6274b9eb1de2de79d0b152d67411d1f747afe
[ "FTL" ]
2
2022-03-06T10:34:12.000Z
2022-03-27T15:41:52.000Z
airloft/utils/icao.py
Allaye/airloft
deb6274b9eb1de2de79d0b152d67411d1f747afe
[ "FTL" ]
null
null
null
airloft/utils/icao.py
Allaye/airloft
deb6274b9eb1de2de79d0b152d67411d1f747afe
[ "FTL" ]
null
null
null
ICAO = { "Anaa": "NTGA", "Apalachicola Regional": "KAAF", "Malamala": "FAMD", "Al Ain International": "OMAL", "Atlantic City": "KACY", "Albany International": "KBAL", "Baise Youjiang": "ZGBS", "Albuquerque International Sunport": "KABQ", "RAF Abisko": "EAAK", "RAF Leuchars": "EGQ...
25.4375
48
0.592138
ICAO = { "Anaa": "NTGA", "Apalachicola Regional": "KAAF", "Malamala": "FAMD", "Al Ain International": "OMAL", "Atlantic City": "KACY", "Albany International": "KBAL", "Baise Youjiang": "ZGBS", "Albuquerque International Sunport": "KABQ", "RAF Abisko": "EAAK", "RAF Leuchars": "EGQ...
0
0
0
ac0348ba5b1b7a69a6c3f778f9a0b37ea7be7200
2,145
py
Python
rightarrow/lexer.py
wuzzeb/python-rightarrow
bc26059d272e4a903fa2a18db9ebb484e7f74aed
[ "Apache-2.0" ]
1
2020-04-30T22:24:41.000Z
2020-04-30T22:24:41.000Z
rightarrow/lexer.py
wuzzeb/python-rightarrow
bc26059d272e4a903fa2a18db9ebb484e7f74aed
[ "Apache-2.0" ]
null
null
null
rightarrow/lexer.py
wuzzeb/python-rightarrow
bc26059d272e4a903fa2a18db9ebb484e7f74aed
[ "Apache-2.0" ]
null
null
null
import sys import logging import ply.lex logger = logging.getLogger(__name__) class Lexer(object): ''' A Lexical analyzer for Python Typelanguage. ''' def tokenize(self, string): ''' Maps a string to an iterator over tokens. In other words: [char] -> [token] ''' ...
28.223684
138
0.549184
import sys import logging import ply.lex logger = logging.getLogger(__name__) class Lexer(object): ''' A Lexical analyzer for Python Typelanguage. ''' def __init__(self, debug=False): self.debug = debug def tokenize(self, string): ''' Maps a string to an iterator ove...
177
0
58
f7ba2a9383bd30b230072da3c6b714a3283b8ada
287
py
Python
output/models/nist_data/list_pkg/normalized_string/schema_instance/nistschema_sv_iv_list_normalized_string_length_5_xsd/__init__.py
tefra/xsdata-w3c-tests
b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f
[ "MIT" ]
1
2021-08-14T17:59:21.000Z
2021-08-14T17:59:21.000Z
output/models/nist_data/list_pkg/normalized_string/schema_instance/nistschema_sv_iv_list_normalized_string_length_5_xsd/__init__.py
tefra/xsdata-w3c-tests
b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f
[ "MIT" ]
4
2020-02-12T21:30:44.000Z
2020-04-15T20:06:46.000Z
output/models/nist_data/list_pkg/normalized_string/schema_instance/nistschema_sv_iv_list_normalized_string_length_5_xsd/__init__.py
tefra/xsdata-w3c-tests
b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f
[ "MIT" ]
null
null
null
from output.models.nist_data.list_pkg.normalized_string.schema_instance.nistschema_sv_iv_list_normalized_string_length_5_xsd.nistschema_sv_iv_list_normalized_string_length_5 import NistschemaSvIvListNormalizedStringLength5 __all__ = [ "NistschemaSvIvListNormalizedStringLength5", ]
47.833333
222
0.905923
from output.models.nist_data.list_pkg.normalized_string.schema_instance.nistschema_sv_iv_list_normalized_string_length_5_xsd.nistschema_sv_iv_list_normalized_string_length_5 import NistschemaSvIvListNormalizedStringLength5 __all__ = [ "NistschemaSvIvListNormalizedStringLength5", ]
0
0
0
b4cb5cadefacca2ad51093281c7e045a146a2c6c
423
py
Python
paper/convert_matt.py
ACTCollaboration/tilec
11ed8d027ad6ffac09b3e291a047f33e97673f14
[ "BSD-3-Clause" ]
1
2021-01-04T14:51:44.000Z
2021-01-04T14:51:44.000Z
paper/convert_matt.py
ACTCollaboration/tilec
11ed8d027ad6ffac09b3e291a047f33e97673f14
[ "BSD-3-Clause" ]
4
2019-09-03T22:19:16.000Z
2020-07-13T12:38:08.000Z
paper/convert_matt.py
ACTCollaboration/tilec
11ed8d027ad6ffac09b3e291a047f33e97673f14
[ "BSD-3-Clause" ]
1
2020-08-10T14:51:11.000Z
2020-08-10T14:51:11.000Z
from __future__ import print_function from orphics import maps,io,cosmology,catalogs from pixell import enmap import numpy as np import os,sys ifile = "paper/E-D56Clusters.fits" #catalogs.convert_hilton_catalog_to_enplot_annotate_file('public_clusters.csv',ifile,radius=15,width=3,color='red') catalogs.convert_hilton_...
35.25
125
0.839243
from __future__ import print_function from orphics import maps,io,cosmology,catalogs from pixell import enmap import numpy as np import os,sys ifile = "paper/E-D56Clusters.fits" #catalogs.convert_hilton_catalog_to_enplot_annotate_file('public_clusters.csv',ifile,radius=15,width=3,color='red') catalogs.convert_hilton_...
0
0
0
3dbb54ea861a369163c812d4d62ac2373f9253b7
1,374
py
Python
oogli/utils.py
brianbruggeman/oogli
6a6f681468d609035924ede27d895afcc9d432b6
[ "Apache-2.0" ]
3
2016-01-18T22:10:51.000Z
2016-06-10T16:02:55.000Z
oogli/utils.py
brianbruggeman/oogli
6a6f681468d609035924ede27d895afcc9d432b6
[ "Apache-2.0" ]
null
null
null
oogli/utils.py
brianbruggeman/oogli
6a6f681468d609035924ede27d895afcc9d432b6
[ "Apache-2.0" ]
null
null
null
import glfw from glfw import gl import numpy as np def opengl_supported(major, minor): '''Determines if opengl is supported for the version provided''' assert glfw.core.init() != 0 version = (major, minor) glfw.core.window_hint(glfw.CONTEXT_VERSION_MAJOR, major) glfw.core.window_hint(glfw.CONTEXT...
35.230769
87
0.706696
import glfw from glfw import gl import numpy as np def screenshot(win, pixels=None): width, height = win.width, win.height if not isinstance(pixels, np.ndarray): shape = (width, height, 3) pixels = np.zeros(shape, dtype=np.uint8) return gl.read_pixels(0, 0, width, height, gl.RGB, gl.UNSIGN...
262
0
23
e6add1302c8c0b6938d09deef9aee73e224f4832
2,362
py
Python
tools/vim/ninja_output.py
Wzzzx/chromium-crosswalk
768dde8efa71169f1c1113ca6ef322f1e8c9e7de
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
2
2019-01-28T08:09:58.000Z
2021-11-15T15:32:10.000Z
tools/vim/ninja_output.py
maidiHaitai/haitaibrowser
a232a56bcfb177913a14210e7733e0ea83a6b18d
[ "BSD-3-Clause" ]
null
null
null
tools/vim/ninja_output.py
maidiHaitai/haitaibrowser
a232a56bcfb177913a14210e7733e0ea83a6b18d
[ "BSD-3-Clause" ]
6
2020-09-23T08:56:12.000Z
2021-11-18T03:40:49.000Z
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import sys import os import exceptions import itertools import re def GetNinjaOutputDirectory(chrome_root): """Returns <chrome_root>/<output_dir>/(Relea...
35.253731
80
0.701948
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import sys import os import exceptions import itertools import re def GetNinjaOutputDirectory(chrome_root): """Returns <chrome_root>/<output_dir>/(Relea...
451
0
50
1036b6605f5cc8baea52e6bdd3a4d604cd22c71e
4,604
py
Python
Kill Confirm Calculator.py
camando-73/Kill-Confirm-Calculator
d5c08f24092e99ceb3a66d8a5135c78c41879e7a
[ "MIT" ]
null
null
null
Kill Confirm Calculator.py
camando-73/Kill-Confirm-Calculator
d5c08f24092e99ceb3a66d8a5135c78c41879e7a
[ "MIT" ]
null
null
null
Kill Confirm Calculator.py
camando-73/Kill-Confirm-Calculator
d5c08f24092e99ceb3a66d8a5135c78c41879e7a
[ "MIT" ]
null
null
null
from tkinter import * import PySimpleGUI as sg window = Tk() window.title("Kill Confirm Calculator") global oppKilPer promptLabel = Label(window, text="Select your Opponents Rival").grid(row=1, column=4) promptLabel1 = Label(window, text="by clicking a Button").grid(row=2, column=4) #Functions containing e...
37.430894
91
0.68397
from tkinter import * import PySimpleGUI as sg window = Tk() window.title("Kill Confirm Calculator") global oppKilPer promptLabel = Label(window, text="Select your Opponents Rival").grid(row=1, column=4) promptLabel1 = Label(window, text="by clicking a Button").grid(row=2, column=4) #Functions containing e...
2,114
0
345
c81f3107437fcc895e116096a76e159155a09374
5,791
py
Python
FindAllRNA/Archieved/encoders.py
Koushul/FindAllRNA
a2c41831f67be2cd52629ebc2ef24cfca3e172f5
[ "MIT" ]
null
null
null
FindAllRNA/Archieved/encoders.py
Koushul/FindAllRNA
a2c41831f67be2cd52629ebc2ef24cfca3e172f5
[ "MIT" ]
null
null
null
FindAllRNA/Archieved/encoders.py
Koushul/FindAllRNA
a2c41831f67be2cd52629ebc2ef24cfca3e172f5
[ "MIT" ]
null
null
null
import warnings warnings.simplefilter(action='ignore', category=FutureWarning) from Bio import SeqIO from Bio.Seq import Seq import numpy as np import random import itertools from textwrap import wrap from collections import defaultdict if __name__ == '__main__': ...
29.697436
120
0.572267
import warnings warnings.simplefilter(action='ignore', category=FutureWarning) from Bio import SeqIO from Bio.Seq import Seq import numpy as np import random import itertools from textwrap import wrap from collections import defaultdict class AbstractSequenceEncoder: ALLOWED_CHARACTERS = 'ATGC' def enco...
1,646
2,700
359
77b6756cbbe27bf7e8e52e03f492721847e9e2cc
2,531
py
Python
utils/reviews_utils.py
woctezuma/steam-reviews-to-sales
51ca279d07a2a1cf26d099a5cfe51566760298cd
[ "MIT" ]
3
2021-08-08T21:06:19.000Z
2021-12-27T05:29:50.000Z
utils/reviews_utils.py
woctezuma/steam-reviews-to-sales
51ca279d07a2a1cf26d099a5cfe51566760298cd
[ "MIT" ]
null
null
null
utils/reviews_utils.py
woctezuma/steam-reviews-to-sales
51ca279d07a2a1cf26d099a5cfe51566760298cd
[ "MIT" ]
null
null
null
import requests from utils.time_utils import get_target_date_as_timestamp if __name__ == "__main__": main()
28.122222
118
0.66772
import requests from utils.time_utils import get_target_date_as_timestamp def get_steam_api_url(app_id): return f"https://store.steampowered.com/appreviews/{app_id}" def get_request_params(target_timestamp=None, verbose=True): # References: # - https://partner.steamgames.com/doc/store/getreviews # ...
2,272
0
138
76675b41d2da4ee91a92fb16e3bd655bdb21e69c
17,737
py
Python
adapters/pox/ext/debugger/component_launcher/component_launcher.py
ARCCN/elt
3bf4e6cc0c7abbe442d6513ed294e956143c3bea
[ "BSD-3-Clause" ]
1
2016-07-14T14:45:56.000Z
2016-07-14T14:45:56.000Z
adapters/pox/ext/debugger/component_launcher/component_launcher.py
ARCCN/elt
3bf4e6cc0c7abbe442d6513ed294e956143c3bea
[ "BSD-3-Clause" ]
null
null
null
adapters/pox/ext/debugger/component_launcher/component_launcher.py
ARCCN/elt
3bf4e6cc0c7abbe442d6513ed294e956143c3bea
[ "BSD-3-Clause" ]
null
null
null
from __future__ import print_function import sys import traceback import inspect import types from ConfigParser import ConfigParser import os from functools import partial from pox.boot import _do_imports from pox.core import core from pox.lib.revent.revent import EventHalt log = core.getLogger("ComponentLauncher")...
37.106695
79
0.537408
from __future__ import print_function import sys import traceback import inspect import types from ConfigParser import ConfigParser import os from functools import partial from pox.boot import _do_imports from pox.core import core from pox.lib.revent.revent import EventHalt log = core.getLogger("ComponentLauncher")...
6,225
10,757
94
b9917b0364f6a2e7a4445c0bc9b7221c3b487eb7
2,771
py
Python
wagtailnest/views.py
ionata/wagtailnest
da903db0967e6f3b87db7213c9d94c0ec98048f5
[ "BSD-3-Clause" ]
1
2018-04-11T23:47:33.000Z
2018-04-11T23:47:33.000Z
wagtailnest/views.py
ionata/wagtailnest
da903db0967e6f3b87db7213c9d94c0ec98048f5
[ "BSD-3-Clause" ]
12
2017-07-18T01:52:06.000Z
2021-09-08T00:15:37.000Z
wagtailnest/views.py
ionata/wagtailnest
da903db0967e6f3b87db7213c9d94c0ec98048f5
[ "BSD-3-Clause" ]
1
2017-05-05T06:18:44.000Z
2017-05-05T06:18:44.000Z
from django.views.generic.base import RedirectView from rest_framework.generics import RetrieveAPIView from rest_framework.settings import api_settings from wagtail.core.models import Page from wagtail.core.views import serve as serve_page from wagtail.documents.views.serve import serve as serve_doc from wagtail.images...
36.460526
76
0.693973
from django.views.generic.base import RedirectView from rest_framework.generics import RetrieveAPIView from rest_framework.settings import api_settings from wagtail.core.models import Page from wagtail.core.views import serve as serve_page from wagtail.documents.views.serve import serve as serve_doc from wagtail.images...
1,170
0
131
ed915cdbf0499255e73830ce7fa7cc05fd04e05b
6,126
py
Python
cs15211/CheapestFlightsWithinKStops.py
JulyKikuAkita/PythonPrac
0ba027d9b8bc7c80bc89ce2da3543ce7a49a403c
[ "Apache-2.0" ]
1
2021-07-05T01:53:30.000Z
2021-07-05T01:53:30.000Z
cs15211/CheapestFlightsWithinKStops.py
JulyKikuAkita/PythonPrac
0ba027d9b8bc7c80bc89ce2da3543ce7a49a403c
[ "Apache-2.0" ]
null
null
null
cs15211/CheapestFlightsWithinKStops.py
JulyKikuAkita/PythonPrac
0ba027d9b8bc7c80bc89ce2da3543ce7a49a403c
[ "Apache-2.0" ]
1
2018-01-08T07:14:08.000Z
2018-01-08T07:14:08.000Z
__source__ = 'https://leetcode.com/problems/cheapest-flights-within-k-stops/' # Time: O() # Space: O() # # Description: Leetcode # 787. Cheapest Flights Within K Stops # # There are n cities connected by m flights. # Each fight starts from city u and arrives at v with a price w. # # Now given all the cities and flight...
31.096447
104
0.550278
__source__ = 'https://leetcode.com/problems/cheapest-flights-within-k-stops/' # Time: O() # Space: O() # # Description: Leetcode # 787. Cheapest Flights Within K Stops # # There are n cities connected by m flights. # Each fight starts from city u and arrives at v with a price w. # # Now given all the cities and flight...
31
1,398
93
c8bd77d23986fec7b1ef68b2bccc25888a90ed92
1,093
py
Python
examples/examples-by-ml-library/libraries/raw_file_example.py
cdknorow/modelstore
f08839478432b89e828a8dcb41adf27b0e3aa66b
[ "Apache-2.0" ]
151
2020-09-20T14:53:06.000Z
2022-03-22T20:49:06.000Z
examples/examples-by-ml-library/libraries/raw_file_example.py
cdknorow/modelstore
f08839478432b89e828a8dcb41adf27b0e3aa66b
[ "Apache-2.0" ]
29
2020-12-07T16:27:39.000Z
2022-03-30T22:11:17.000Z
examples/examples-by-ml-library/libraries/raw_file_example.py
cdknorow/modelstore
f08839478432b89e828a8dcb41adf27b0e3aa66b
[ "Apache-2.0" ]
4
2022-01-10T17:42:02.000Z
2022-03-07T14:14:43.000Z
import json import os import tempfile from modelstore.model_store import ModelStore _DOMAIN_NAME = "example-model-file"
32.147059
79
0.709973
import json import os import tempfile from modelstore.model_store import ModelStore _DOMAIN_NAME = "example-model-file" def _train_and_save_example_model(tmp_dir: str) -> str: # Create a file with a "model" -- in this case it is a json file, # but modelstore can handle any file type model_path = os.path...
903
0
69
64a70685034132430735b61b79a01c637c745705
5,472
py
Python
client/read_data.py
aitmlouk/FEDn-client-FedQAS-tf
278a1c402b313d22a8a060a40e434a8c59dbe93b
[ "Apache-2.0" ]
1
2022-02-16T05:56:43.000Z
2022-02-16T05:56:43.000Z
client/read_data.py
aitmlouk/FEDn-client-FedQAS-tf
278a1c402b313d22a8a060a40e434a8c59dbe93b
[ "Apache-2.0" ]
null
null
null
client/read_data.py
aitmlouk/FEDn-client-FedQAS-tf
278a1c402b313d22a8a060a40e434a8c59dbe93b
[ "Apache-2.0" ]
null
null
null
import json import os import numpy as np from tokenizers import BertWordPieceTokenizer from transformers import BertTokenizer class SquadExample: """ Process SQUAD dataset """ def read_data(filename, settings): """ Helper function to read and preprocess SQUAD data for training and validation w...
36.724832
119
0.623904
import json import os import numpy as np from tokenizers import BertWordPieceTokenizer from transformers import BertTokenizer class SquadExample: """ Process SQUAD dataset """ def __init__(self, question, context, start_char_idx, answer_text, all_answers): self.question = question sel...
4,340
0
100
00a1b50f3dd846088071791349bcd247d295c762
9,000
py
Python
data/common.py
Khanhnn00/blind-image-sr
42bba4894ac9ee6595d2fff9b25a7678f323ad87
[ "Apache-2.0" ]
null
null
null
data/common.py
Khanhnn00/blind-image-sr
42bba4894ac9ee6595d2fff9b25a7678f323ad87
[ "Apache-2.0" ]
null
null
null
data/common.py
Khanhnn00/blind-image-sr
42bba4894ac9ee6595d2fff9b25a7678f323ad87
[ "Apache-2.0" ]
null
null
null
import os import random import numpy as np import scipy.misc as misc import imageio from tqdm import tqdm import cv2 from PIL import Image import torch import torch.nn.functional as F IMG_EXTENSIONS = ['.jpg', '.JPG', '.jpeg', '.JPEG', '.png', '.PNG', '.ppm', '.PPM', '.bmp', '.BMP'] BINARY_EXTENSIONS = ['.npy'] BENCH...
31.690141
113
0.585778
import os import random import numpy as np import scipy.misc as misc import imageio from tqdm import tqdm import cv2 from PIL import Image import torch import torch.nn.functional as F IMG_EXTENSIONS = ['.jpg', '.JPG', '.jpeg', '.JPEG', '.png', '.PNG', '.ppm', '.PPM', '.bmp', '.BMP'] BINARY_EXTENSIONS = ['.npy'] BENCH...
7,930
0
481
a0355f919cc4728a58640cd8403ab48bfc29e577
460
py
Python
Exe15_triangulo_isoseles_equilatero_escaleno.py
lucaslk122/Exercicios_Python_estutura_decisao
51a9699c5d85aa6cfb163d891c56e804a7255634
[ "MIT" ]
null
null
null
Exe15_triangulo_isoseles_equilatero_escaleno.py
lucaslk122/Exercicios_Python_estutura_decisao
51a9699c5d85aa6cfb163d891c56e804a7255634
[ "MIT" ]
null
null
null
Exe15_triangulo_isoseles_equilatero_escaleno.py
lucaslk122/Exercicios_Python_estutura_decisao
51a9699c5d85aa6cfb163d891c56e804a7255634
[ "MIT" ]
null
null
null
print("Entre com os dados de um trangulo") lado1 = int(input("Lado 1: ")) lado2 = int(input("Lado 2: ")) lado3 = int(input("Lado 3: ")) if lado1 < lado2 + lado3 and lado2 < lado1 + lado3 and lado3 < lado1 + lado2: if lado1 == lado2 == lado3: print("Triângulo equilatero") elif lado1 != lado2 != lado3 != ...
35.384615
77
0.626087
print("Entre com os dados de um trangulo") lado1 = int(input("Lado 1: ")) lado2 = int(input("Lado 2: ")) lado3 = int(input("Lado 3: ")) if lado1 < lado2 + lado3 and lado2 < lado1 + lado3 and lado3 < lado1 + lado2: if lado1 == lado2 == lado3: print("Triângulo equilatero") elif lado1 != lado2 != lado3 != ...
0
0
0
67698325e8a8db41808cc663d5073ddee6cdf27f
6,346
py
Python
game.py
matthewspangler/quillengine
80bce8f4d17a15766c6e43b768d3bf028c74ba73
[ "MIT-0" ]
1
2020-10-27T12:26:25.000Z
2020-10-27T12:26:25.000Z
game.py
matthewspangler/quillengine
80bce8f4d17a15766c6e43b768d3bf028c74ba73
[ "MIT-0" ]
null
null
null
game.py
matthewspangler/quillengine
80bce8f4d17a15766c6e43b768d3bf028c74ba73
[ "MIT-0" ]
null
null
null
# -------------------------------------------------------------------- # # game.py # contains main game loop, # including events, drawing, and update # -------------------------------------------------------------------- # # General imports: import sys # Game related imports: import pygame import pyscroll import py...
39.17284
109
0.608887
# -------------------------------------------------------------------- # # game.py # contains main game loop, # including events, drawing, and update # -------------------------------------------------------------------- # # General imports: import sys # Game related imports: import pygame import pyscroll import py...
5,179
2
180
d9f00e14ddde6217639bd67754bf5cb2607b36a4
7,592
py
Python
notebooks/SignDetectorAndClassifier/src/utils/autoanchor.py
lsd-maddrive/adas_system
0352d59a500aebbd68fbf45f416fb98d1b850e13
[ "MIT" ]
null
null
null
notebooks/SignDetectorAndClassifier/src/utils/autoanchor.py
lsd-maddrive/adas_system
0352d59a500aebbd68fbf45f416fb98d1b850e13
[ "MIT" ]
14
2021-10-02T10:10:45.000Z
2022-03-26T08:32:48.000Z
notebooks/SignDetectorAndClassifier/src/utils/autoanchor.py
lsd-maddrive/adas_system
0352d59a500aebbd68fbf45f416fb98d1b850e13
[ "MIT" ]
null
null
null
# YOLOv5 🚀 by Ultralytics, GPL-3.0 license """ Auto-anchor utils """ import random import numpy as np import torch import yaml from tqdm import tqdm from utils.general import LOGGER, colorstr, emojis PREFIX = colorstr("AutoAnchor: ") def kmean_anchors( dataset="./data/coco128.yaml", n=9, img_size=640, thr=...
36.854369
111
0.559405
# YOLOv5 🚀 by Ultralytics, GPL-3.0 license """ Auto-anchor utils """ import random import numpy as np import torch import yaml from tqdm import tqdm from utils.general import LOGGER, colorstr, emojis PREFIX = colorstr("AutoAnchor: ") def check_anchor_order(m): # Check anchor order against stride order for YO...
3,735
0
127
453c5d60dedd3235c1f46cd9497155d8b3a70989
12,610
py
Python
tests/test_sendmail.py
thijstriemstra/aiosmtplib
39bab303bf15cc8e14aa0b7cffe800f1e7f83e58
[ "MIT" ]
null
null
null
tests/test_sendmail.py
thijstriemstra/aiosmtplib
39bab303bf15cc8e14aa0b7cffe800f1e7f83e58
[ "MIT" ]
null
null
null
tests/test_sendmail.py
thijstriemstra/aiosmtplib
39bab303bf15cc8e14aa0b7cffe800f1e7f83e58
[ "MIT" ]
null
null
null
""" SMTP.sendmail and SMTP.send_message method testing. """ import copy import email.generator import email.header import pytest from aiosmtplib import ( SMTPNotSupported, SMTPRecipientsRefused, SMTPResponseException, SMTPStatus, ) pytestmark = pytest.mark.asyncio() async def test_rset_af...
29.670588
87
0.691356
""" SMTP.sendmail and SMTP.send_message method testing. """ import copy import email.generator import email.header import pytest from aiosmtplib import ( SMTPNotSupported, SMTPRecipientsRefused, SMTPResponseException, SMTPStatus, ) pytestmark = pytest.mark.asyncio() async def test_sendmail_simple_...
9,602
0
460
8763891fb88cc1cd0e9f6ac035c59a16230135e5
129
py
Python
route/main_error_404.py
susemeee/openNAMU
0f3d8acb5f0fe179cc8dbbfea1846da3ca0cd4e1
[ "BSD-3-Clause" ]
null
null
null
route/main_error_404.py
susemeee/openNAMU
0f3d8acb5f0fe179cc8dbbfea1846da3ca0cd4e1
[ "BSD-3-Clause" ]
null
null
null
route/main_error_404.py
susemeee/openNAMU
0f3d8acb5f0fe179cc8dbbfea1846da3ca0cd4e1
[ "BSD-3-Clause" ]
1
2020-01-04T09:43:35.000Z
2020-01-04T09:43:35.000Z
from .tool.func import *
21.5
49
0.666667
from .tool.func import * def main_error_404_2(conn): curs = conn.cursor() return redirect('/w/' + url_pas(wiki_set(2)))
82
0
23
b2ddef6aa2fb689d119c86fd4710810575904ef7
18,985
py
Python
Matrix_Portal_Moon_Clock/code.py
jposada202020/Adafruit_Learning_System_Guides
d9656b8ba59532926240ddee50b81160e2e3fd11
[ "MIT" ]
1
2021-01-05T02:08:27.000Z
2021-01-05T02:08:27.000Z
Matrix_Portal_Moon_Clock/code.py
jposada202020/Adafruit_Learning_System_Guides
d9656b8ba59532926240ddee50b81160e2e3fd11
[ "MIT" ]
null
null
null
Matrix_Portal_Moon_Clock/code.py
jposada202020/Adafruit_Learning_System_Guides
d9656b8ba59532926240ddee50b81160e2e3fd11
[ "MIT" ]
null
null
null
""" MOON PHASE CLOCK for Adafruit Matrix Portal: displays current time, lunar phase and time of next moonrise or moonset. Requires WiFi internet access. Written by Phil 'PaintYourDragon' Burgess for Adafruit Industries. MIT license, all text above must be included in any redistribution. BDF fonts from the X.Org proje...
43.946759
78
0.603318
""" MOON PHASE CLOCK for Adafruit Matrix Portal: displays current time, lunar phase and time of next moonrise or moonset. Requires WiFi internet access. Written by Phil 'PaintYourDragon' Burgess for Adafruit Industries. MIT license, all text above must be included in any redistribution. BDF fonts from the X.Org proje...
0
0
0
228275216d91b7a87408c952779feef91a8be9f0
2,466
py
Python
ignite/metrics/metrics_lambda.py
ndronen/ignite
5d7298017ceb0e5457551263d3f4090c34dbf636
[ "BSD-3-Clause" ]
null
null
null
ignite/metrics/metrics_lambda.py
ndronen/ignite
5d7298017ceb0e5457551263d3f4090c34dbf636
[ "BSD-3-Clause" ]
null
null
null
ignite/metrics/metrics_lambda.py
ndronen/ignite
5d7298017ceb0e5457551263d3f4090c34dbf636
[ "BSD-3-Clause" ]
null
null
null
from ignite.metrics.metric import Metric from ignite.engine import Events class MetricsLambda(Metric): """ Apply a function to other metrics to obtain a new metric. The result of the new metric is defined to be the result of applying the function to the result of argument metrics. When update, th...
37.938462
104
0.652068
from ignite.metrics.metric import Metric from ignite.engine import Events class MetricsLambda(Metric): """ Apply a function to other metrics to obtain a new metric. The result of the new metric is defined to be the result of applying the function to the result of argument metrics. When update, th...
1,130
0
134
074a4b4261490d73d5f971d4834dfbbf2f1de8c7
1,688
py
Python
loginBuptGw/loginBuptGw.py
JamesLinus/Scripts
28aa33b60154ad11dd60c5d74642343aa5059a7f
[ "MIT" ]
1
2019-04-22T09:10:46.000Z
2019-04-22T09:10:46.000Z
loginBuptGw/loginBuptGw.py
JamesLinus/Scripts
28aa33b60154ad11dd60c5d74642343aa5059a7f
[ "MIT" ]
null
null
null
loginBuptGw/loginBuptGw.py
JamesLinus/Scripts
28aa33b60154ad11dd60c5d74642343aa5059a7f
[ "MIT" ]
null
null
null
#!/usr/bin/python # -*- coding:utf-8 -*- """ 北邮人网关登录脚本: 使用方法: 登录:python loginBuptGw.py i 退出:python loginBuptGw.py o """ import urllib2 import urllib import cookielib import hashlib import os import re import sys reload(sys) sys.setdefaultencoding('utf8') uname = XXXXXX #请正确填写学号 upass = 'XXXXXX' #请正确填写密码 if __na...
21.1
174
0.683649
#!/usr/bin/python # -*- coding:utf-8 -*- """ 北邮人网关登录脚本: 使用方法: 登录:python loginBuptGw.py i 退出:python loginBuptGw.py o """ import urllib2 import urllib import cookielib import hashlib import os import re import sys reload(sys) sys.setdefaultencoding('utf8') uname = XXXXXX #请正确填写学号 upass = 'XXXXXX' #请正确填写密码 def saf...
1,024
0
115
8d9d97da1eeec5795d33bf640fc9d80248931137
1,639
py
Python
trendfilter/extrapolate.py
dave31415/trendfilter
793714359ec243857d0557ede9abcae61981f119
[ "MIT" ]
null
null
null
trendfilter/extrapolate.py
dave31415/trendfilter
793714359ec243857d0557ede9abcae61981f119
[ "MIT" ]
null
null
null
trendfilter/extrapolate.py
dave31415/trendfilter
793714359ec243857d0557ede9abcae61981f119
[ "MIT" ]
null
null
null
from scipy.interpolate import interp1d import numpy as np def vectorize(func_orig): """ A function that takes a function and returns another that can fun on lists and arrays :param func_orig: any functions :return: vectorized function """ return func def get_interp_extrapolate_functions(...
30.924528
84
0.681513
from scipy.interpolate import interp1d import numpy as np def vectorize(func_orig): """ A function that takes a function and returns another that can fun on lists and arrays :param func_orig: any functions :return: vectorized function """ def func(x_new): if isinstance(x_new, list)...
583
0
107
8a1e23316ee7f7cad0e7bf9eafe1c857d3b52749
328
py
Python
Scripts/simulation/objects/decorative/__init__.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
Scripts/simulation/objects/decorative/__init__.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
Scripts/simulation/objects/decorative/__init__.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\objects\decorative\__init__.py # Compiled at: 2009-11-20 02:49:20 # Size of source mod 2**32: 106 by...
46.857143
107
0.728659
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\objects\decorative\__init__.py # Compiled at: 2009-11-20 02:49:20 # Size of source mod 2**32: 106 by...
0
0
0
9d55fcd21fd668728d576d29f89f13e00a3cb35f
412
py
Python
tests/utils_tests.py
joyongjin/peb
078faf1a83cc4c161e9b4779bb9af6068b25c5b9
[ "MIT" ]
null
null
null
tests/utils_tests.py
joyongjin/peb
078faf1a83cc4c161e9b4779bb9af6068b25c5b9
[ "MIT" ]
null
null
null
tests/utils_tests.py
joyongjin/peb
078faf1a83cc4c161e9b4779bb9af6068b25c5b9
[ "MIT" ]
null
null
null
import random from unittest import TestCase import peb
22.888889
72
0.667476
import random from unittest import TestCase import peb class UtilTest(TestCase): def test_raise_or(self): error = ValueError('Test error') value = 'TEST_VALUE' self.assertEqual(peb.raise_or(error, value, throw=False), value) with self.assertRaises(ValueError) as res: ...
301
4
49
15dd6aac8e204d47fef9c8e7da2d4dd65a45dcc0
1,555
py
Python
patients/migrations/0012_auto_20201104_1553.py
joshgoshbgosh/ccs-final-project
566bf8bfaa82986010a2dfbdc3b32592c796d4a9
[ "MIT" ]
1
2020-11-05T14:21:45.000Z
2020-11-05T14:21:45.000Z
patients/migrations/0012_auto_20201104_1553.py
joshgoshbgosh/ccs-final-project
566bf8bfaa82986010a2dfbdc3b32592c796d4a9
[ "MIT" ]
null
null
null
patients/migrations/0012_auto_20201104_1553.py
joshgoshbgosh/ccs-final-project
566bf8bfaa82986010a2dfbdc3b32592c796d4a9
[ "MIT" ]
null
null
null
# Generated by Django 3.1.2 on 2020-11-04 15:53 from django.db import migrations, models
42.027027
170
0.583923
# Generated by Django 3.1.2 on 2020-11-04 15:53 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('patients', '0011_patient_image'), ] operations = [ migrations.CreateModel( name='Prescription', fields=[ ...
0
1,441
23
fe2ccb0b7614d1cc9f61af3c2a9134c91f178963
49,940
py
Python
bin/sofa_analyze.py
pingsutw/sofa
66b960859dde4be7143ed06ed98396c743a6478a
[ "Apache-2.0" ]
1
2020-04-21T09:05:29.000Z
2020-04-21T09:05:29.000Z
bin/sofa_analyze.py
y78078/sofa
2f8967df18abc03cedf7a97f8bbf77164ca69bf9
[ "Apache-2.0" ]
null
null
null
bin/sofa_analyze.py
y78078/sofa
2f8967df18abc03cedf7a97f8bbf77164ca69bf9
[ "Apache-2.0" ]
null
null
null
import argparse import matplotlib matplotlib.use('agg') import csv import json import multiprocessing as mp import os import random import re import sys from functools import partial from operator import attrgetter, itemgetter import networkx as nx import numpy as np import pandas as pd import time from sofa_aisi impor...
44.470169
259
0.569704
import argparse import matplotlib matplotlib.use('agg') import csv import json import multiprocessing as mp import os import random import re import sys from functools import partial from operator import attrgetter, itemgetter import networkx as nx import numpy as np import pandas as pd import time from sofa_aisi impor...
48,776
-9
515
75cc48f5e1deff324b747de89196a4848b8c3eec
1,439
py
Python
backend/database.py
metabsd/GLaDOS-Potato
40d42e3d1471cdf6f24ddd36a06c5efd5fb3726b
[ "Apache-2.0" ]
1
2016-09-22T00:05:38.000Z
2016-09-22T00:05:38.000Z
backend/database.py
metabsd/GLaDOS-Potato
40d42e3d1471cdf6f24ddd36a06c5efd5fb3726b
[ "Apache-2.0" ]
null
null
null
backend/database.py
metabsd/GLaDOS-Potato
40d42e3d1471cdf6f24ddd36a06c5efd5fb3726b
[ "Apache-2.0" ]
null
null
null
import MySQLdb db = MySQLdb.connect("db", "root", "my-secret-pw", "bd_notes") cursor = db.cursor() global resultsExportEtudiants resultsExportEtudiants = []
28.215686
146
0.512856
import MySQLdb db = MySQLdb.connect("db", "root", "my-secret-pw", "bd_notes") cursor = db.cursor() global resultsExportEtudiants resultsExportEtudiants = [] def getetudiants(): del resultsExportEtudiants[:] sql = "SELECT * FROM t_etudiant" try: cursor.execute(sql) results = cursor.fetchal...
1,233
0
46
409cef07b90435c6fa62817fde97b01e461264b5
3,210
py
Python
async_blp/base_request.py
rockscie/async_blp
acb8777ccf2499681bde87d76ca780b61219699c
[ "MIT" ]
12
2019-08-05T16:56:54.000Z
2021-02-02T11:09:37.000Z
async_blp/base_request.py
lightning-like/async_blp
acb8777ccf2499681bde87d76ca780b61219699c
[ "MIT" ]
null
null
null
async_blp/base_request.py
lightning-like/async_blp
acb8777ccf2499681bde87d76ca780b61219699c
[ "MIT" ]
5
2019-12-08T15:43:13.000Z
2021-11-14T08:38:07.000Z
import abc import asyncio from typing import Any from typing import Dict from typing import Optional from async_blp.enums import ErrorBehaviour from async_blp.utils import log # pylint: disable=ungrouped-imports try: import blpapi except ImportError: from async_blp.utils import env_test as blpapi LOGGER = lo...
31.165049
80
0.62648
import abc import asyncio from typing import Any from typing import Dict from typing import Optional from async_blp.enums import ErrorBehaviour from async_blp.utils import log # pylint: disable=ungrouped-imports try: import blpapi except ImportError: from async_blp.utils import env_test as blpapi LOGGER = lo...
991
1,860
23
6059b582a58a0a62cbb1d858d37bdc9bba85ab35
3,108
py
Python
qcengine/programs/madness/keywords.py
ahurta92/QCEngine
7e7482886eb320696904a5ee35c0d37f98341728
[ "BSD-3-Clause" ]
null
null
null
qcengine/programs/madness/keywords.py
ahurta92/QCEngine
7e7482886eb320696904a5ee35c0d37f98341728
[ "BSD-3-Clause" ]
null
null
null
qcengine/programs/madness/keywords.py
ahurta92/QCEngine
7e7482886eb320696904a5ee35c0d37f98341728
[ "BSD-3-Clause" ]
null
null
null
import collections from typing import Any, Dict, Tuple def format_keyword(keyword: str, val: Any, lop_off: bool = True) -> Tuple[str, str]: """Function to reformat value `val` for `keyword` from python into nwchem-speak.""" # Transform string booleans into " " if val is True: return keyword.lower...
35.318182
107
0.536358
import collections from typing import Any, Dict, Tuple def format_keyword(keyword: str, val: Any, lop_off: bool = True) -> Tuple[str, str]: """Function to reformat value `val` for `keyword` from python into nwchem-speak.""" # Transform string booleans into " " if val is True: return keyword.lower...
39
0
27
07a5e20ea4239cfeedbc6865859a61d72d396fa3
785
py
Python
common/DirCleaner.py
hep-cce/hpc-edge-service
57f2b9252d21d478eabe06cbdced5b623f08c75f
[ "BSD-3-Clause" ]
null
null
null
common/DirCleaner.py
hep-cce/hpc-edge-service
57f2b9252d21d478eabe06cbdced5b623f08c75f
[ "BSD-3-Clause" ]
null
null
null
common/DirCleaner.py
hep-cce/hpc-edge-service
57f2b9252d21d478eabe06cbdced5b623f08c75f
[ "BSD-3-Clause" ]
null
null
null
from common.file_tools import delete_old_files_directories import time
37.380952
106
0.634395
from common.file_tools import delete_old_files_directories import time class DirCleaner: def __init__(self,path,period_in_sec,cutoff_in_seconds,remove_files = True, remove_directories = True): self.start_time = time.time() self.path = path self.period = period_in_sec self.last_time = self.st...
644
-4
74
b2af71edc5b61342cca24d22cee1ab418ea58547
1,314
py
Python
Client/inputs.py
Cescollino/FederatedPi
e7261c04c40cc7721e77287348c557c932d58543
[ "MIT" ]
null
null
null
Client/inputs.py
Cescollino/FederatedPi
e7261c04c40cc7721e77287348c557c932d58543
[ "MIT" ]
null
null
null
Client/inputs.py
Cescollino/FederatedPi
e7261c04c40cc7721e77287348c557c932d58543
[ "MIT" ]
null
null
null
from smbus2 import SMBus import time # RPi Channel 1 channel = 1 bus = SMBus(channel) # ADS1115 address and registers address = 0x48 reg_config = 0x01 # Config value: # - Single conversion # - A0 input # - 4.096V reference config = [0xC2, 0xB3] while True: reg_conversion = 0x00 # Start conversion bus.write...
22.271186
62
0.671233
from smbus2 import SMBus import time # RPi Channel 1 channel = 1 bus = SMBus(channel) # ADS1115 address and registers address = 0x48 reg_config = 0x01 # Config value: # - Single conversion # - A0 input # - 4.096V reference config = [0xC2, 0xB3] while True: reg_conversion = 0x00 # Start conversion bus.write...
0
0
0
6e22ddda76a72a3664a045ce067b390f4547bec7
8,076
py
Python
utils/SamplingUtils.py
nanohedra/nanohedra
3921b7f5ce10e0e3393c3b675bb97ccbecb96663
[ "MIT" ]
2
2020-12-07T00:38:32.000Z
2021-05-13T19:36:17.000Z
utils/SamplingUtils.py
nanohedra/nanohedra
3921b7f5ce10e0e3393c3b675bb97ccbecb96663
[ "MIT" ]
null
null
null
utils/SamplingUtils.py
nanohedra/nanohedra
3921b7f5ce10e0e3393c3b675bb97ccbecb96663
[ "MIT" ]
1
2021-05-13T19:36:18.000Z
2021-05-13T19:36:18.000Z
import numpy as np import math # Copyright 2020 Joshua Laniado and Todd O. Yeates. __author__ = "Joshua Laniado and Todd O. Yeates" __copyright__ = "Copyright 2020, Nanohedra" __version__ = "1.0" # ROTATION RANGE DEG C2 = 180 C3 = 120 C4 = 90 C5 = 72 C6 = 60 RotRangeDict = {"C2": C2, "C3": C3, "C4": C4, "C5": C5, "...
40.38
138
0.59943
import numpy as np import math # Copyright 2020 Joshua Laniado and Todd O. Yeates. __author__ = "Joshua Laniado and Todd O. Yeates" __copyright__ = "Copyright 2020, Nanohedra" __version__ = "1.0" # ROTATION RANGE DEG C2 = 180 C3 = 120 C4 = 90 C5 = 72 C6 = 60 RotRangeDict = {"C2": C2, "C3": C3, "C4": C4, "C5": C5, "...
7,579
0
161
5b1d9807ad96abc37e81be4b9f133dcc9788a6ff
466
py
Python
tests/helpers/test_utils.py
biern/precious
4b533bfaa850641a410ef05a453422a09f2d9603
[ "MIT" ]
2
2016-11-06T13:24:53.000Z
2018-07-15T11:19:15.000Z
tests/helpers/test_utils.py
biern/precious
4b533bfaa850641a410ef05a453422a09f2d9603
[ "MIT" ]
null
null
null
tests/helpers/test_utils.py
biern/precious
4b533bfaa850641a410ef05a453422a09f2d9603
[ "MIT" ]
null
null
null
from precious import Value, assign_attributes, copy
20.26087
54
0.60515
from precious import Value, assign_attributes, copy class Point(Value): @assign_attributes def __init__(self, x, y): pass class TestCopyObject: def test_copy_object_with_same_attributes(self): p1 = Point(1, 2) p2 = copy(p1) assert p2.x == 1 assert p2.y == 2 def test...
266
47
99
7ac0bfbd29d462f9bf8bf305205720af17e182d2
550
py
Python
tests/handlers/test_maven_releases.py
sawood14012/fabric8-analytics-jobs
a7d850dfef5785144676b9a3b4e29942161e5347
[ "Apache-2.0" ]
5
2017-05-04T11:22:31.000Z
2018-08-24T16:12:30.000Z
tests/handlers/test_maven_releases.py
sawood14012/fabric8-analytics-jobs
a7d850dfef5785144676b9a3b4e29942161e5347
[ "Apache-2.0" ]
325
2017-05-03T08:44:03.000Z
2021-12-13T21:03:49.000Z
tests/handlers/test_maven_releases.py
sawood14012/fabric8-analytics-jobs
a7d850dfef5785144676b9a3b4e29942161e5347
[ "Apache-2.0" ]
28
2017-05-02T05:09:32.000Z
2021-03-11T09:42:34.000Z
"""Tests for maven_releases.py.""" # import pytest # TODO enable when new test(s) will be added # from f8a_jobs.handlers.maven_releases import MavenReleasesAnalyses class TestMavenReleasesAnalyses(object): """Tests for MavenReleasesAnalyses class.""" def setup_method(self, method): """Set up any st...
28.947368
84
0.710909
"""Tests for maven_releases.py.""" # import pytest # TODO enable when new test(s) will be added # from f8a_jobs.handlers.maven_releases import MavenReleasesAnalyses class TestMavenReleasesAnalyses(object): """Tests for MavenReleasesAnalyses class.""" def setup_method(self, method): """Set up any st...
0
0
0
a9553230e74a1b791dc28477f6cff5a0798d610e
901
py
Python
python/design_patterns/template_method.py
pgularski/snippets
0b34ac837dd768f3dfa72dbf3e3d271c51e71da9
[ "MIT" ]
null
null
null
python/design_patterns/template_method.py
pgularski/snippets
0b34ac837dd768f3dfa72dbf3e3d271c51e71da9
[ "MIT" ]
null
null
null
python/design_patterns/template_method.py
pgularski/snippets
0b34ac837dd768f3dfa72dbf3e3d271c51e71da9
[ "MIT" ]
null
null
null
#!/usr/bin/env python # −*− coding: UTF−8 −*− import abc if __name__ == '__main__': test()
18.02
44
0.588235
#!/usr/bin/env python # −*− coding: UTF−8 −*− import abc class HotBeverage(object): __metaclass__ = abc.ABCMeta def prepare(self): self.boil_water() self.brew() self.pour_in_cup() if self.customer_wants_condiments(): self.add_condiments() @abc.abstractmethod ...
287
391
122
45d6e9edd987d3f729c82e2725f851919559b12b
1,177
py
Python
pages/themes/ParallelProgramming-Lecture4/examples/download_images_demos/download_images_with_threas.py
WWWCourses/PythonCourseNetIT-Slides
78dbb5eb7695cc64042b71a1911d4ef3feddb074
[ "MIT" ]
null
null
null
pages/themes/ParallelProgramming-Lecture4/examples/download_images_demos/download_images_with_threas.py
WWWCourses/PythonCourseNetIT-Slides
78dbb5eb7695cc64042b71a1911d4ef3feddb074
[ "MIT" ]
null
null
null
pages/themes/ParallelProgramming-Lecture4/examples/download_images_demos/download_images_with_threas.py
WWWCourses/PythonCourseNetIT-Slides
78dbb5eb7695cc64042b71a1911d4ef3feddb074
[ "MIT" ]
null
null
null
import threading import requests import os import time urls = [ "https://unsplash.com/photos/CTflmHHVrBM/download?force=true", "https://unsplash.com/photos/pWV8HjvHzk8/download?force=true", # "https://unsplash.com/photos/1jn_3WBp60I/download?force=true", # "https://unsplash.com/photos/8E5HawfqCMM/download?force=t...
24.020408
65
0.723025
import threading import requests import os import time def download_file(url): file_name=url.split('/')[4]+'.jpg' full_file_name = os.path.join(download_path,file_name) # get image bytes print(f"Start downloading {url}") response = requests.get(url, allow_redirects=True) # write image to file with open(full...
338
0
23
7e6fb24c9fdf24078eca20ccd5e9b951ede5ba72
350
py
Python
lhotse/recipes/__init__.py
freewym/lhotse
66e9bbaf25b75011388ab00189baa162c3c1d435
[ "Apache-2.0" ]
null
null
null
lhotse/recipes/__init__.py
freewym/lhotse
66e9bbaf25b75011388ab00189baa162c3c1d435
[ "Apache-2.0" ]
null
null
null
lhotse/recipes/__init__.py
freewym/lhotse
66e9bbaf25b75011388ab00189baa162c3c1d435
[ "Apache-2.0" ]
null
null
null
from .ami import prepare_ami from .broadcast_news import prepare_broadcast_news from .librimix import prepare_librimix from .librispeech import prepare_librispeech from .switchboard import prepare_switchboard __all__ = [ 'prepare_ami', 'prepare_broadcast_news', 'prepare_librimix', 'prepare_librispeech'...
25
50
0.794286
from .ami import prepare_ami from .broadcast_news import prepare_broadcast_news from .librimix import prepare_librimix from .librispeech import prepare_librispeech from .switchboard import prepare_switchboard __all__ = [ 'prepare_ami', 'prepare_broadcast_news', 'prepare_librimix', 'prepare_librispeech'...
0
0
0
34c4a49b1a56810d1ba1396800b3826151f2cfe8
1,109
py
Python
linux/local_article.py
shienka07/no_corona_zone
3b015d3bf7bff38eadfad722da4222bf5ed92c8e
[ "Apache-2.0" ]
null
null
null
linux/local_article.py
shienka07/no_corona_zone
3b015d3bf7bff38eadfad722da4222bf5ed92c8e
[ "Apache-2.0" ]
null
null
null
linux/local_article.py
shienka07/no_corona_zone
3b015d3bf7bff38eadfad722da4222bf5ed92c8e
[ "Apache-2.0" ]
4
2021-07-23T07:35:44.000Z
2021-09-10T11:51:32.000Z
import re from selenium import webdriver from selenium.webdriver.chrome.options import Options import argparse import ncz import chromedriver_binary parser = argparse.ArgumentParser() parser.add_argument('keyword1', help="main_city_name") parser.add_argument('keyword2', help="sub_city_name") parser.add_argument('key...
27.04878
99
0.762849
import re from selenium import webdriver from selenium.webdriver.chrome.options import Options import argparse import ncz import chromedriver_binary parser = argparse.ArgumentParser() parser.add_argument('keyword1', help="main_city_name") parser.add_argument('keyword2', help="sub_city_name") parser.add_argument('key...
0
0
0
3be02ab6c72b00d31e2b2218e2fec095e4a55665
3,712
py
Python
CalibMuon/DTCalibration/python/Workflow/DTTTrigTimeBoxesWriter.py
pasmuss/cmssw
566f40c323beef46134485a45ea53349f59ae534
[ "Apache-2.0" ]
null
null
null
CalibMuon/DTCalibration/python/Workflow/DTTTrigTimeBoxesWriter.py
pasmuss/cmssw
566f40c323beef46134485a45ea53349f59ae534
[ "Apache-2.0" ]
null
null
null
CalibMuon/DTCalibration/python/Workflow/DTTTrigTimeBoxesWriter.py
pasmuss/cmssw
566f40c323beef46134485a45ea53349f59ae534
[ "Apache-2.0" ]
null
null
null
from tools import loadCmsProcess,writeCfg from addPoolDBESSource import addPoolDBESSource from CmsswTask import CmsswTask import os
52.28169
129
0.655172
from tools import loadCmsProcess,writeCfg from addPoolDBESSource import addPoolDBESSource from CmsswTask import CmsswTask import os class DTTTrigTimeBoxesWriter: def __init__(self, run, dir, result_dir, config): self.runnumber = int(run) self.config = config self.dir = dir self.resu...
3,429
8
143
4e0b4f1736db9347d30a2d18993a1c64f19dbfc6
504
py
Python
node2vec/src/testNetworkX.py
CEfanmin/DataMiningProjects
b6375f542c68c0001ae2971dd7e8046a0b4afc7a
[ "MIT" ]
3
2018-04-26T06:44:27.000Z
2018-09-01T13:58:21.000Z
node2vec/src/testNetworkX.py
CEfanmin/DataMiningProjects
b6375f542c68c0001ae2971dd7e8046a0b4afc7a
[ "MIT" ]
null
null
null
node2vec/src/testNetworkX.py
CEfanmin/DataMiningProjects
b6375f542c68c0001ae2971dd7e8046a0b4afc7a
[ "MIT" ]
1
2018-09-01T13:58:27.000Z
2018-09-01T13:58:27.000Z
import networkx as nx import matplotlib.pyplot as plt ## add a node G = nx.Graph() G.add_node(1) G.add_nodes_from([2, 3]) H = nx.path_graph(10) G.add_nodes_from(H) G.add_node(H) G.add_node('shopping') ## edges G.add_edge(1, 2, {'weight': 3.1415}) e = (2, 3) G.add_edge(*e) G.add_edges_from([(1,2), (1,3)]) # G.add_edg...
18
50
0.646825
import networkx as nx import matplotlib.pyplot as plt ## add a node G = nx.Graph() G.add_node(1) G.add_nodes_from([2, 3]) H = nx.path_graph(10) G.add_nodes_from(H) G.add_node(H) G.add_node('shopping') ## edges G.add_edge(1, 2, {'weight': 3.1415}) e = (2, 3) G.add_edge(*e) G.add_edges_from([(1,2), (1,3)]) # G.add_edg...
0
0
0
7a5a12a2b65d10df25cd9f836ac609b209cce23a
918
py
Python
adv/mona.py
dl-stuff/dl
185cc8a16339c47ed873768ff30804f8d06090a2
[ "Apache-2.0" ]
22
2020-04-04T17:34:16.000Z
2021-09-25T00:22:23.000Z
adv/mona.py
dl-stuff/dl
185cc8a16339c47ed873768ff30804f8d06090a2
[ "Apache-2.0" ]
92
2020-04-04T15:30:34.000Z
2022-03-24T01:43:11.000Z
adv/mona.py
dl-stuff/dl
185cc8a16339c47ed873768ff30804f8d06090a2
[ "Apache-2.0" ]
37
2020-04-16T02:47:07.000Z
2021-03-28T23:18:50.000Z
from core.advbase import * from module.template import Adv_INFUTP variants = {None: Mona, "RNG": Mona_RNG, "INFUTP": Mona_INFUTP}
26.228571
85
0.595861
from core.advbase import * from module.template import Adv_INFUTP class Mona(Adv): def prerun(self): self.beast_eye = Selfbuff("beast_eye", 0.2, 30, "utph", "buff").ex_bufftime() Event("dragon").listener(self.ddrive_buff_off) def fs_proc(self, e): if self.nihilism: return ...
589
19
175
8948fe9ebd947bd18a879bad266e94c8f09b14d4
89
py
Python
Code/facebook_credentials.py
PritomDas/Automated-Tinder-AI-Bot
085a41c586671767b976f18627d8f72ed3614dcd
[ "MIT" ]
1
2020-02-11T06:44:33.000Z
2020-02-11T06:44:33.000Z
Code/facebook_credentials.py
PritomDas/Automated-Tinder-AI-Bot
085a41c586671767b976f18627d8f72ed3614dcd
[ "MIT" ]
1
2020-02-11T06:56:48.000Z
2020-02-11T06:56:48.000Z
Code/facebook_credentials.py
PritomDas/Automated-Tinder-AI-Bot
085a41c586671767b976f18627d8f72ed3614dcd
[ "MIT" ]
null
null
null
username = '' #enter your facebook user name password = '' #enter your facebook password
29.666667
44
0.741573
username = '' #enter your facebook user name password = '' #enter your facebook password
0
0
0
de336d770cfcbea47a843316d1fc22134021b6c5
908
py
Python
main.py
arieroos/crypto-trader
c419f712fd7c501507c99a48a142e909f92a949c
[ "MIT" ]
2
2021-09-08T07:23:51.000Z
2021-11-08T14:59:32.000Z
main.py
arieroos/crypto-trader
c419f712fd7c501507c99a48a142e909f92a949c
[ "MIT" ]
null
null
null
main.py
arieroos/crypto-trader
c419f712fd7c501507c99a48a142e909f92a949c
[ "MIT" ]
null
null
null
import sys from datetime import datetime import error_handler import valr UNKNOWN_TREND = "unknown" DOWN_TREND = "down" UP_TREND = "up" if __name__ == "__main__": sys.excepthook = error_handler.excepthook orders = [x for x in valr.get_open_orders() if x["side"].upper() == "BUY"] if len(orders) > 0: ...
24.540541
78
0.65859
import sys from datetime import datetime import error_handler import valr UNKNOWN_TREND = "unknown" DOWN_TREND = "down" UP_TREND = "up" def log(msg: str): print(f"[{datetime.now()}] {msg}", flush=True) if __name__ == "__main__": sys.excepthook = error_handler.excepthook orders = [x for x in valr.get_...
48
0
23
b7bab76e2c1606435bce4d050c6f35fd5a5ee94d
2,106
py
Python
bucket_manifest/utils.py
uc-cdis/cdis-dataflow-templates
6a3d28d27094db34e2df6ef10d61a700bfc6c94d
[ "Apache-2.0" ]
null
null
null
bucket_manifest/utils.py
uc-cdis/cdis-dataflow-templates
6a3d28d27094db34e2df6ef10d61a700bfc6c94d
[ "Apache-2.0" ]
1
2020-06-17T21:54:37.000Z
2020-06-17T21:54:37.000Z
bucket_manifest/utils.py
uc-cdis/cdis-dataflow-templates
6a3d28d27094db34e2df6ef10d61a700bfc6c94d
[ "Apache-2.0" ]
null
null
null
import csv from google.cloud import storage import logging def write_tsv(filename, files, fieldnames=None): """ write to tsv file Args: filename(str): file name files(list(dict)): list of file info [ { "GUID": "guid_example", "filename":...
26.325
97
0.565052
import csv from google.cloud import storage import logging def write_tsv(filename, files, fieldnames=None): """ write to tsv file Args: filename(str): file name files(list(dict)): list of file info [ { "GUID": "guid_example", "filename":...
0
0
0
631cfccd8f55be80c2b322c2b729d8a58d117353
5,153
py
Python
main/commands/breakpoint_menus.py
sexybiggetje/sublime_db
0d1cac7b87b32f843e65d8bee6583cadd5f9ea6a
[ "MIT" ]
null
null
null
main/commands/breakpoint_menus.py
sexybiggetje/sublime_db
0d1cac7b87b32f843e65d8bee6583cadd5f9ea6a
[ "MIT" ]
null
null
null
main/commands/breakpoint_menus.py
sexybiggetje/sublime_db
0d1cac7b87b32f843e65d8bee6583cadd5f9ea6a
[ "MIT" ]
null
null
null
from sublime_db.core.typecheck import ( Any, Callable, Optional ) import sublime import sublime_plugin from sublime_db import core from sublime_db import ui from sublime_db.main.breakpoints import Breakpoints, Breakpoint, FunctionBreakpoint from .commands import AutoCompleteTextInputHandler @core.async @core.a...
37.613139
194
0.761692
from sublime_db.core.typecheck import ( Any, Callable, Optional ) import sublime import sublime_plugin from sublime_db import core from sublime_db import ui from sublime_db.main.breakpoints import Breakpoints, Breakpoint, FunctionBreakpoint from .commands import AutoCompleteTextInputHandler def edit_breakpoint(br...
4,633
25
181
72412d50c7dc555be4686d28e6d8ca8e63ec7561
539
py
Python
main/templatetags/custom_tags.py
CrazyOrr/gamemob
defdf748d8860ac9a1af317781c4b88421326762
[ "Apache-2.0" ]
null
null
null
main/templatetags/custom_tags.py
CrazyOrr/gamemob
defdf748d8860ac9a1af317781c4b88421326762
[ "Apache-2.0" ]
null
null
null
main/templatetags/custom_tags.py
CrazyOrr/gamemob
defdf748d8860ac9a1af317781c4b88421326762
[ "Apache-2.0" ]
null
null
null
__author__ = 'wanglei02' from django import template from django.utils.html import conditional_escape from django.utils.safestring import mark_safe register = template.Library() @register.filter(name='join_link', needs_autoescape=True)
23.434783
57
0.658627
__author__ = 'wanglei02' from django import template from django.utils.html import conditional_escape from django.utils.safestring import mark_safe register = template.Library() @register.filter(name='join_link', needs_autoescape=True) def join_link(value, arg, autoescape=True): arr = [] if autoescape: ...
277
0
22
94bc3a6ce98787e7cedbb192ad7f8bf17596c45c
32,960
py
Python
rayserve/inference.py
drunkcoding/model-inference
02d2240bc7052fa32223a80fa63625fe681db102
[ "MIT" ]
1
2021-11-15T19:07:13.000Z
2021-11-15T19:07:13.000Z
rayserve/inference.py
drunkcoding/model-inference
02d2240bc7052fa32223a80fa63625fe681db102
[ "MIT" ]
null
null
null
rayserve/inference.py
drunkcoding/model-inference
02d2240bc7052fa32223a80fa63625fe681db102
[ "MIT" ]
null
null
null
import copy from dataclasses import dataclass import dataclasses import functools import io import logging from multiprocessing.connection import wait import uuid from typing import Any, Dict, List, Optional, Tuple, Union from attr import field from concurrent.futures import ProcessPoolExecutor import pandas as pd impo...
35.251337
136
0.543811
import copy from dataclasses import dataclass import dataclasses import functools import io import logging from multiprocessing.connection import wait import uuid from typing import Any, Dict, List, Optional, Tuple, Union from attr import field from concurrent.futures import ProcessPoolExecutor import pandas as pd impo...
20,418
3,792
89
2946e941bb095163cf2a9d20b54c7195e621b50f
8,050
py
Python
test.py
byaka/CapybaraMail
c6bad864c56e8a7f4e93397b095d5013f6ba0c7f
[ "Apache-2.0" ]
null
null
null
test.py
byaka/CapybaraMail
c6bad864c56e8a7f4e93397b095d5013f6ba0c7f
[ "Apache-2.0" ]
5
2019-06-18T14:03:44.000Z
2019-09-01T12:44:40.000Z
test.py
byaka/CapybaraMail
c6bad864c56e8a7f4e93397b095d5013f6ba0c7f
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from functionsex import * from VombatiDB import VombatiDB, showDB, showStats, Workspace from VombatiDB import errors as dbError from importMail import ImportMail_MBox import errors as storeError import api from utils import RepairDialogLinking from libs.plainText import plaintext import textw...
37.268519
181
0.600124
# -*- coding: utf-8 -*- from functionsex import * from VombatiDB import VombatiDB, showDB, showStats, Workspace from VombatiDB import errors as dbError from importMail import ImportMail_MBox import errors as storeError import api from utils import RepairDialogLinking from libs.plainText import plaintext import textw...
5,147
1,346
23
b4bec296bcdb6c4b7fe42711cd71ddae86964068
15,585
py
Python
cytopy/tests/test_gating_strategy.py
JANHMS/CytoPy
8537d707fa25645b55b4ec1e25fff9f19847fb1b
[ "MIT" ]
41
2020-04-08T11:01:28.000Z
2022-03-11T17:17:18.000Z
cytopy/tests/test_gating_strategy.py
JANHMS/CytoPy
8537d707fa25645b55b4ec1e25fff9f19847fb1b
[ "MIT" ]
27
2020-04-07T14:59:24.000Z
2022-03-01T20:43:34.000Z
cytopy/tests/test_gating_strategy.py
JANHMS/CytoPy
8537d707fa25645b55b4ec1e25fff9f19847fb1b
[ "MIT" ]
8
2020-04-28T15:16:24.000Z
2022-03-02T19:02:14.000Z
from cytopy.data.gating_strategy import GatingStrategy, DuplicatePopulationError from cytopy.data.gate import ThresholdGate, PolygonGate, EllipseGate from cytopy.data.project import Project import matplotlib.pyplot as plt import pandas as pd import pytest @pytest.mark.parametrize("gate,child_n", ...
42.933884
112
0.637857
from cytopy.data.gating_strategy import GatingStrategy, DuplicatePopulationError from cytopy.data.gate import ThresholdGate, PolygonGate, EllipseGate from cytopy.data.project import Project import matplotlib.pyplot as plt import pandas as pd import pytest def create_gatingstrategy_and_load(example_populated_experimen...
14,140
0
595
5f9010516eb2e0571e28ec33c2d1d8fc9a1902b4
2,070
py
Python
scheduler_task/process_verification_every_minute.py
jepret/jepret-backend
2a892e1a7141da09d286b14f47769c3e6f4c0979
[ "MIT" ]
null
null
null
scheduler_task/process_verification_every_minute.py
jepret/jepret-backend
2a892e1a7141da09d286b14f47769c3e6f4c0979
[ "MIT" ]
6
2021-03-19T01:58:42.000Z
2022-03-11T23:52:43.000Z
scheduler_task/process_verification_every_minute.py
jepret/jepret-backend
2a892e1a7141da09d286b14f47769c3e6f4c0979
[ "MIT" ]
null
null
null
import dotenv dotenv.load_dotenv() from time import sleep import schedule import requests import json from service.image_recognition import check_image_similarity from model import UMKM, UMKMValidator, Verification, Campaign schedule.every().minute.do(process_verifications) while True: try: sched...
26.538462
120
0.666184
import dotenv dotenv.load_dotenv() from time import sleep import schedule import requests import json from service.image_recognition import check_image_similarity from model import UMKM, UMKMValidator, Verification, Campaign def get_base_images(umkm): validator = UMKMValidator.get_or_none(UMKMValidator.umkm == ...
1,562
0
115
9c1092d1f7b7cde8a89cbf00955b5db64557a26d
21,342
py
Python
modules/teacher_dashboard/teacher_dashboard.py
ehiller/mobilecsp-v18
a59801c44c616d30f5e916d6771e479c8a9e88f7
[ "Apache-2.0" ]
null
null
null
modules/teacher_dashboard/teacher_dashboard.py
ehiller/mobilecsp-v18
a59801c44c616d30f5e916d6771e479c8a9e88f7
[ "Apache-2.0" ]
null
null
null
modules/teacher_dashboard/teacher_dashboard.py
ehiller/mobilecsp-v18
a59801c44c616d30f5e916d6771e479c8a9e88f7
[ "Apache-2.0" ]
null
null
null
__author__ = 'ehiller@css.edu' # Module to support custom teacher views in CourseBuilder dashboard # Views include: # Section Roster - list of students in section # Sections - list of sections for current user # Student Dashboard - view of a single student's performance in the course # Teacher...
44.370062
141
0.685222
__author__ = 'ehiller@css.edu' # Module to support custom teacher views in CourseBuilder dashboard # Views include: # Section Roster - list of students in section # Sections - list of sections for current user # Student Dashboard - view of a single student's performance in the course # Teacher...
53
0
26
55c6ebbc315a030d0f8f7cc93fc5471567d72e3b
36,442
py
Python
python/bigipconfigdriver.py
ymaxgit/f5-bigip-ctrl
51af36727025b18e6b4d54b2fbaefa77d73125e6
[ "Apache-2.0" ]
null
null
null
python/bigipconfigdriver.py
ymaxgit/f5-bigip-ctrl
51af36727025b18e6b4d54b2fbaefa77d73125e6
[ "Apache-2.0" ]
null
null
null
python/bigipconfigdriver.py
ymaxgit/f5-bigip-ctrl
51af36727025b18e6b4d54b2fbaefa77d73125e6
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # Copyright 2016, 2017 F5 Networks, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
36.661972
79
0.562455
#!/usr/bin/env python # Copyright 2016, 2017 F5 Networks, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
21,195
1,155
924
bc89cfbc8e32ea0a9edc5ecb60c9f0aad0a8306a
7,098
py
Python
Scripts/SeaIce/NSIDCseaice_quartiles.py
dargueso/IceVarFigs
6c76cdde6f51cecf73beaaca83c7a5db51864bfd
[ "MIT" ]
1
2019-02-02T06:12:01.000Z
2019-02-02T06:12:01.000Z
Scripts/SeaIce/NSIDCseaice_quartiles.py
jq222/IceVarFigs
d9b1bb3ac09a9dfd097e72b0dba78276b7e251e4
[ "MIT" ]
null
null
null
Scripts/SeaIce/NSIDCseaice_quartiles.py
jq222/IceVarFigs
d9b1bb3ac09a9dfd097e72b0dba78276b7e251e4
[ "MIT" ]
null
null
null
""" Reads in current year's Arctic sea ice extent from Sea Ice Index 3 (NSIDC) Website : ftp://sidads.colorado.edu/DATASETS/NOAA/G02135/north/daily/data/ Author : Zachary M. Labe Date : 5 September 2016 """ ### Import modules import numpy as np import urllib as UL import datetime import matplotlib.pyplot as...
34.965517
85
0.606509
""" Reads in current year's Arctic sea ice extent from Sea Ice Index 3 (NSIDC) Website : ftp://sidads.colorado.edu/DATASETS/NOAA/G02135/north/daily/data/ Author : Zachary M. Labe Date : 5 September 2016 """ ### Import modules import numpy as np import urllib as UL import datetime import matplotlib.pyplot as...
400
0
23
7d899950b4d9b46ac5424339c27486ecac02f536
4,486
py
Python
Predict-next-word/train.py
PandoraLS/python_toys
d3f78815ada5c20863656c643342d48bcc3aef53
[ "MIT" ]
null
null
null
Predict-next-word/train.py
PandoraLS/python_toys
d3f78815ada5c20863656c643342d48bcc3aef53
[ "MIT" ]
null
null
null
Predict-next-word/train.py
PandoraLS/python_toys
d3f78815ada5c20863656c643342d48bcc3aef53
[ "MIT" ]
null
null
null
import collections import nltk import tensorflow as tf import numpy as np from tensorflow.contrib import rnn from utils import chunks import json import os import shutil def word_indexing(words): """ :param words: a string :return: a vocabulary dictionary {word1: 1, word2: 2, ...} and its reveres {...
32.507246
100
0.656933
import collections import nltk import tensorflow as tf import numpy as np from tensorflow.contrib import rnn from utils import chunks import json import os import shutil def word_indexing(words): """ :param words: a string :return: a vocabulary dictionary {word1: 1, word2: 2, ...} and its reveres {...
434
0
23
a68d277ee2f5e00f491c500efd8e74e9cf78e73f
2,719
py
Python
paper_analyses/compute_panel_d.py
benmaier/vaccontrib
1be75e049d3069ba465e7779e850c2e2504daae9
[ "MIT" ]
1
2021-12-14T15:51:19.000Z
2021-12-14T15:51:19.000Z
paper_analyses/compute_panel_d.py
benmaier/vaccontrib
1be75e049d3069ba465e7779e850c2e2504daae9
[ "MIT" ]
null
null
null
paper_analyses/compute_panel_d.py
benmaier/vaccontrib
1be75e049d3069ba465e7779e850c2e2504daae9
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as pl from vaccontrib.covid import ( get_covid_matrices ) from vaccontrib.main import ( get_reduced_vaccinated_susceptible_contribution_matrix, get_reduced_vaccinated_susceptible_eigenvector, get_eigenvector, get_next_generation_...
24.944954
81
0.614932
import numpy as np import matplotlib.pyplot as pl from vaccontrib.covid import ( get_covid_matrices ) from vaccontrib.main import ( get_reduced_vaccinated_susceptible_contribution_matrix, get_reduced_vaccinated_susceptible_eigenvector, get_eigenvector, get_next_generation_...
0
0
0
28b21e86c02b08e5ab2bdee34146d5d7f7ba3d30
1,358
py
Python
baekjoon/15483.py
GihwanKim/Baekjoon
52eb2bf80bb1243697858445e5b5e2d50d78be4e
[ "MIT" ]
null
null
null
baekjoon/15483.py
GihwanKim/Baekjoon
52eb2bf80bb1243697858445e5b5e2d50d78be4e
[ "MIT" ]
null
null
null
baekjoon/15483.py
GihwanKim/Baekjoon
52eb2bf80bb1243697858445e5b5e2d50d78be4e
[ "MIT" ]
null
null
null
""" 15483 : 최소 편집 URL : https://www.acmicpc.net/problem/15483 Input #1 : abc ab Output #1 : 1 Input #2 : ca abc Output #2 : 3 Input #3 : abc cba Output #3 : 2 Input #4 : abcd bcde Output #4 : ...
15.609195
65
0.431517
""" 15483 : 최소 편집 URL : https://www.acmicpc.net/problem/15483 Input #1 : abc ab Output #1 : 1 Input #2 : ca abc Output #2 : 3 Input #3 : abc cba Output #3 : 2 Input #4 : abcd bcde Output #4 : ...
390
0
23
2ef90b04f7e868f7f0bca13278b34e23837d7c75
2,247
py
Python
BioClients/jensenlab/Utils.py
jeremyjyang/BioClients
b78ab2b948c79616fed080112e31d383346bec58
[ "CC0-1.0" ]
10
2020-05-26T07:29:14.000Z
2021-12-06T21:33:40.000Z
BioClients/jensenlab/Utils.py
jeremyjyang/BioClients
b78ab2b948c79616fed080112e31d383346bec58
[ "CC0-1.0" ]
1
2021-10-05T12:25:30.000Z
2021-10-05T17:05:56.000Z
BioClients/jensenlab/Utils.py
jeremyjyang/BioClients
b78ab2b948c79616fed080112e31d383346bec58
[ "CC0-1.0" ]
2
2021-03-16T03:20:24.000Z
2021-08-08T20:17:10.000Z
#!/usr/bin/env python3 """ Utility functions for JensenLab REST APIs. https://api.jensenlab.org/Textmining?type1=-26&id1=DOID:10652&type2=9606&limit=10&format=json https://api.jensenlab.org/Textmining?query=jetlag[tiab]%20OR%20jet-lag[tiab]&type2=9606&limit=10&format=json https://api.jensenlab.org/Knowledge?type1=-26&i...
41.611111
129
0.611927
#!/usr/bin/env python3 """ Utility functions for JensenLab REST APIs. https://api.jensenlab.org/Textmining?type1=-26&id1=DOID:10652&type2=9606&limit=10&format=json https://api.jensenlab.org/Textmining?query=jetlag[tiab]%20OR%20jet-lag[tiab]&type2=9606&limit=10&format=json https://api.jensenlab.org/Knowledge?type1=-26&i...
650
0
22
88a3d975b40f4ab3e7c50b58fa6b52cf82ff0344
8,252
py
Python
sandbox/finetuning/runs/test_env_change.py
andrewli77/rllab-finetuning
2dae9141d0fdc284d04f18931907131d66b43023
[ "MIT" ]
23
2020-04-27T23:53:44.000Z
2022-03-10T03:13:16.000Z
sandbox/finetuning/runs/test_env_change.py
WeiChengTseng/rllab-finetuning
2dae9141d0fdc284d04f18931907131d66b43023
[ "MIT" ]
1
2021-11-14T13:30:22.000Z
2021-11-14T13:30:22.000Z
sandbox/finetuning/runs/test_env_change.py
WeiChengTseng/rllab-finetuning
2dae9141d0fdc284d04f18931907131d66b43023
[ "MIT" ]
8
2020-06-17T03:28:34.000Z
2022-03-09T03:13:03.000Z
import numpy as np import joblib from rllab.sampler.utils import rollout import os from rllab import config from rllab.misc import ext from tqdm import trange, tqdm import IPython import matplotlib matplotlib.use("Agg") import matplotlib.pyplot as plt import itertools from sandbox.finetuning.envs.mujoco.modified.modifi...
42.536082
272
0.628817
import numpy as np import joblib from rllab.sampler.utils import rollout import os from rllab import config from rllab.misc import ext from tqdm import trange, tqdm import IPython import matplotlib matplotlib.use("Agg") import matplotlib.pyplot as plt import itertools from sandbox.finetuning.envs.mujoco.modified.modifi...
7,548
0
91
e9dfe2e63bb667d6bffa21f11821945741f40f73
398
py
Python
pwlocker/views.py
boosh/pwlocker
60fce09e5d81fdf055e7448ca3e179d70f98c8a7
[ "MIT" ]
14
2015-03-15T23:58:29.000Z
2021-11-16T11:01:43.000Z
pwlocker/views.py
boosh/pwlocker
60fce09e5d81fdf055e7448ca3e179d70f98c8a7
[ "MIT" ]
null
null
null
pwlocker/views.py
boosh/pwlocker
60fce09e5d81fdf055e7448ca3e179d70f98c8a7
[ "MIT" ]
6
2015-01-31T18:40:00.000Z
2019-03-10T14:42:37.000Z
from django.shortcuts import render_to_response from django.http import HttpResponseRedirect from django.http import HttpResponse from django.core.urlresolvers import reverse from django.views.decorators.csrf import csrf_exempt from django.template import RequestContext ## The home page.
36.181818
52
0.829146
from django.shortcuts import render_to_response from django.http import HttpResponseRedirect from django.http import HttpResponse from django.core.urlresolvers import reverse from django.views.decorators.csrf import csrf_exempt from django.template import RequestContext ## The home page. def home(request): context...
87
0
22
b2e129ea7d56ff16cc1bce77021a476210227221
456
py
Python
api/checklist/migrations/0004_auto_20180507_0047.py
Samuel-L/checklistshare
3953f4c1175f2c0641a6683a7667e9809a6efc8d
[ "MIT" ]
null
null
null
api/checklist/migrations/0004_auto_20180507_0047.py
Samuel-L/checklistshare
3953f4c1175f2c0641a6683a7667e9809a6efc8d
[ "MIT" ]
7
2018-05-06T20:25:17.000Z
2018-05-07T01:33:37.000Z
api/checklist/migrations/0004_auto_20180507_0047.py
Samuel-L/checklistshare
3953f4c1175f2c0641a6683a7667e9809a6efc8d
[ "MIT" ]
null
null
null
# Generated by Django 2.0.5 on 2018-05-07 00:47 from django.db import migrations
19.826087
47
0.546053
# Generated by Django 2.0.5 on 2018-05-07 00:47 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('checklist', '0003_item'), ] operations = [ migrations.RenameModel( old_name='Checklist', new_name='List', ), ...
0
350
23
a1fe930fe84ff9aae4969cbbe95da039a19f3d78
1,291
py
Python
main.py
rhdimas/basik-calc
7c77869bdd80d8a01922eccd6836d02b69c6b980
[ "MIT" ]
null
null
null
main.py
rhdimas/basik-calc
7c77869bdd80d8a01922eccd6836d02b69c6b980
[ "MIT" ]
null
null
null
main.py
rhdimas/basik-calc
7c77869bdd80d8a01922eccd6836d02b69c6b980
[ "MIT" ]
null
null
null
################################## # Basik-Calc # Calculator for basic operations # Author: Ricardo Dimas ################################## import sys if __name__ == '__main__': try: main() except KeyboardInterrupt: print('\nExiting...') sys.exit()
21.516667
67
0.516654
################################## # Basik-Calc # Calculator for basic operations # Author: Ricardo Dimas ################################## def main(): print('Welcome to Basik-Calc\n') import sys def sum(a, b): print(int(a) + int(b)) def sub(a, b): print(int(a) - int(b)) def mult(a, b): print(int(...
868
0
138
6058bfd3df4d9c845cb5afb45d2ec2c5750cc310
7,248
py
Python
corehq/apps/export/management/commands/process_skipped_pages.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
471
2015-01-10T02:55:01.000Z
2022-03-29T18:07:18.000Z
corehq/apps/export/management/commands/process_skipped_pages.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
14,354
2015-01-01T07:38:23.000Z
2022-03-31T20:55:14.000Z
corehq/apps/export/management/commands/process_skipped_pages.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
175
2015-01-06T07:16:47.000Z
2022-03-29T13:27:01.000Z
import multiprocessing import os import re import shutil import tempfile import zipfile from datetime import datetime from django.core.management.base import BaseCommand, CommandError import sh from corehq.apps.export.dbaccessors import get_properly_wrapped_export_instance from corehq.apps.export.multiprocess import...
40.49162
115
0.650248
import multiprocessing import os import re import shutil import tempfile import zipfile from datetime import datetime from django.core.management.base import BaseCommand, CommandError import sh from corehq.apps.export.dbaccessors import get_properly_wrapped_export_instance from corehq.apps.export.multiprocess import...
6,507
221
46
d2ac279ca965701a840e4ddb8b46f6fec912175d
14,317
py
Python
openpifpaf/plugins/apollocar3d/apollo_kp.py
anhvth/openpifpaf
a88edd744b50f76dfdae9dbb180d4a403cbfd060
[ "CC-BY-2.0", "CC-BY-4.0" ]
null
null
null
openpifpaf/plugins/apollocar3d/apollo_kp.py
anhvth/openpifpaf
a88edd744b50f76dfdae9dbb180d4a403cbfd060
[ "CC-BY-2.0", "CC-BY-4.0" ]
null
null
null
openpifpaf/plugins/apollocar3d/apollo_kp.py
anhvth/openpifpaf
a88edd744b50f76dfdae9dbb180d4a403cbfd060
[ "CC-BY-2.0", "CC-BY-4.0" ]
null
null
null
""" Interface for custom data. This module handles datasets and is the class that you need to inherit from for your custom dataset. This class gives you all the handles so that you can train with a new –dataset=mydataset. The particular configuration of keypoints and skeleton is specified in the headmeta instances """...
42.993994
100
0.607809
""" Interface for custom data. This module handles datasets and is the class that you need to inherit from for your custom dataset. This class gives you all the handles so that you can train with a new –dataset=mydataset. The particular configuration of keypoints and skeleton is specified in the headmeta instances """...
12,269
0
266
d5e96b96dbd80b64de082352f330662845ad51bf
2,194
py
Python
win32comext/axscript/client/pydumper.py
zhanqxun/cv_fish
f78f4f5bdafb070c179efee8b9276719dfaef1d7
[ "Apache-2.0" ]
1
2017-08-07T14:52:02.000Z
2017-08-07T14:52:02.000Z
Lib/site-packages/win32comext/axscript/client/pydumper.py
adzhou/Python27
a7113b69d54a04cc780143241c2f1fe81939ad3a
[ "bzip2-1.0.6" ]
null
null
null
Lib/site-packages/win32comext/axscript/client/pydumper.py
adzhou/Python27
a7113b69d54a04cc780143241c2f1fe81939ad3a
[ "bzip2-1.0.6" ]
4
2021-02-11T03:51:39.000Z
2021-02-12T05:10:43.000Z
# pydumper.py # # This is being worked on - it does not yet work at all, in ay way # shape or form :-) # # A new script engine, derived from the standard scripting engine, # which dumps information. # This generally can be used to grab all sorts of useful details about # an engine - expose bugs in it or Pytho...
30.901408
97
0.709663
# pydumper.py # # This is being worked on - it does not yet work at all, in ay way # shape or form :-) # # A new script engine, derived from the standard scripting engine, # which dumps information. # This generally can be used to grab all sorts of useful details about # an engine - expose bugs in it or Pytho...
1,195
102
100
ee77d4c66934df1360d5087f5f5f89a2e5c47844
521
py
Python
kCoreBots/CoreBotEN/MachineLearning/NaiveBayes/PythonScripts/obtainList.py
sai6kiran/TwitterBotFarms
cf6bfddda9fac1e27477186fd4f4b086ac711781
[ "MIT" ]
null
null
null
kCoreBots/CoreBotEN/MachineLearning/NaiveBayes/PythonScripts/obtainList.py
sai6kiran/TwitterBotFarms
cf6bfddda9fac1e27477186fd4f4b086ac711781
[ "MIT" ]
null
null
null
kCoreBots/CoreBotEN/MachineLearning/NaiveBayes/PythonScripts/obtainList.py
sai6kiran/TwitterBotFarms
cf6bfddda9fac1e27477186fd4f4b086ac711781
[ "MIT" ]
null
null
null
import pandas as pd import numpy as np import csv #################Obtain the List of All bpts that sent Political Tweets [i.e. Political Bots]:####################### dfn = pd.read_csv("/root/.encrypted/.pythonSai/kCoreBots/CoreBotEN/MachineLearning/NaiveBayes/datasets/CoreBotTweetsCombinedEN.csv", sep=",", skiprows=...
52.1
199
0.710173
import pandas as pd import numpy as np import csv #################Obtain the List of All bpts that sent Political Tweets [i.e. Political Bots]:####################### dfn = pd.read_csv("/root/.encrypted/.pythonSai/kCoreBots/CoreBotEN/MachineLearning/NaiveBayes/datasets/CoreBotTweetsCombinedEN.csv", sep=",", skiprows=...
0
0
0