hexsha
stringlengths
40
40
size
int64
6
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
247
max_issues_repo_name
stringlengths
4
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
247
max_forks_repo_name
stringlengths
4
130
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.53
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
6
1.04M
filtered:remove_non_ascii
int64
0
538k
filtered:remove_decorators
int64
0
917k
filtered:remove_async
int64
0
722k
filtered:remove_classes
int64
-45
1M
filtered:remove_generators
int64
0
814k
filtered:remove_function_no_docstring
int64
-102
850k
filtered:remove_class_no_docstring
int64
-3
5.46k
filtered:remove_unused_imports
int64
-1,350
52.4k
filtered:remove_delete_markers
int64
0
59.6k
415d145766ab4dedf431022b54fe379823c64f40
182
py
Python
version_check.py
git-ning/byte-of-python
6b231667c6df30b009ac525276106cc0d9c839ce
[ "Apache-2.0" ]
1
2017-08-23T02:18:29.000Z
2017-08-23T02:18:29.000Z
version_check.py
git-ning/byte-of-python
6b231667c6df30b009ac525276106cc0d9c839ce
[ "Apache-2.0" ]
null
null
null
version_check.py
git-ning/byte-of-python
6b231667c6df30b009ac525276106cc0d9c839ce
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python import sys, warnings if sys.version_info[0] < 3: warnings.warn('Need Python 3.0 for this program to run', RuntimeWarning) else: print('Procees as normal')
22.75
76
0.708791
#!/usr/bin/python import sys, warnings if sys.version_info[0] < 3: warnings.warn('Need Python 3.0 for this program to run', RuntimeWarning) else: print('Procees as normal')
0
0
0
0
0
0
0
0
0
b37d1c410788dc1e471824b9a7c765c37bbadd34
69
py
Python
Exercicios/test.py
jotmar/PythonEx
bf026518ae5479d5c99ff7a4e95fc383dec22d36
[ "MIT" ]
null
null
null
Exercicios/test.py
jotmar/PythonEx
bf026518ae5479d5c99ff7a4e95fc383dec22d36
[ "MIT" ]
null
null
null
Exercicios/test.py
jotmar/PythonEx
bf026518ae5479d5c99ff7a4e95fc383dec22d36
[ "MIT" ]
null
null
null
from datetime import datetime print(str(datetime.today())[:4])
23
35
0.753623
from datetime import date, datetime print(str(datetime.today())[:4])
0
0
0
0
0
0
0
6
0
f0447c0cdbf4bc25eb65c3b05213081608f80569
4,084
py
Python
cenv_tool/schemata.py
oozut/cenv_tool
a02977dc80a54c0045785ad97284fde0b9248aff
[ "MIT" ]
null
null
null
cenv_tool/schemata.py
oozut/cenv_tool
a02977dc80a54c0045785ad97284fde0b9248aff
[ "MIT" ]
null
null
null
cenv_tool/schemata.py
oozut/cenv_tool
a02977dc80a54c0045785ad97284fde0b9248aff
[ "MIT" ]
1
2020-10-01T22:08:17.000Z
2020-10-01T22:08:17.000Z
# -*- coding: utf-8 -*- """Contain schemata required by cenv-tool."""
29.171429
78
0.62904
# -*- coding: utf-8 -*- """Contain schemata required by cenv-tool.""" from marshmallow import fields from marshmallow import Schema from marshmallow import validate class SNPackage(Schema): """Contain the ``package``-section inside a ``meta.yaml``.""" name = fields.String(strict=True, required=True) vers...
0
0
0
3,727
0
0
0
29
250
3475a3835d34b20910fc7c5cc3289b8e260584d4
3,954
py
Python
vocabquiz-autogen/main.py
jkcw/vocabquiz-autogen
2242534d8142308dc8d5f318eb06b983df46e546
[ "MIT" ]
1
2021-08-21T05:00:34.000Z
2021-08-21T05:00:34.000Z
vocabquiz-autogen/main.py
jkcw/vocabquiz-autogen
2242534d8142308dc8d5f318eb06b983df46e546
[ "MIT" ]
null
null
null
vocabquiz-autogen/main.py
jkcw/vocabquiz-autogen
2242534d8142308dc8d5f318eb06b983df46e546
[ "MIT" ]
null
null
null
import json print(secret_key) # TODO: get some of questions only, not all. # TODO: present tense, verbs with "s" # TODO: full stop of each sentence # TODO: will print the error msg out "error:rm_answer_to_blank" # TODO: quality of the dictionary is too low # Load vocabulary list text_file = open("temp/ietls-vocab-li...
27.84507
116
0.620637
import requests import json import random from . import secretKey print(secret_key) # TODO: get some of questions only, not all. # TODO: present tense, verbs with "s" # TODO: full stop of each sentence # TODO: will print the error msg out "error:rm_answer_to_blank" # TODO: quality of the dictionary is too low # Loa...
0
0
0
2,637
0
0
0
-12
134
a10094fe76dba801777a5fd274be9cca1ac53ad5
13,716
py
Python
Evaluation/frame_prediction_BG.py
arpane4c5/ActivityNet
31a0972bb7461107e24d2be4fb76bf168382016f
[ "MIT" ]
13
2017-07-31T22:00:34.000Z
2020-03-19T01:40:57.000Z
Evaluation/frame_prediction_BG.py
zhangxgu/ActivityNet-1
31a0972bb7461107e24d2be4fb76bf168382016f
[ "MIT" ]
1
2018-05-25T02:31:04.000Z
2018-05-28T07:20:32.000Z
Evaluation/frame_prediction_BG.py
zhangxgu/ActivityNet-1
31a0972bb7461107e24d2be4fb76bf168382016f
[ "MIT" ]
6
2017-08-19T01:45:47.000Z
2020-11-23T12:05:26.000Z
#!/usr/bin/env python2 # -*- coding: utf-8 -*- """ Created on Mon Jul 3 14:49:28 2017 @author: Arpan Description: Use c3d trained model for prediction. To be executed after training_model_m4.py """ import json import os import utils import numpy as np import h5py import pandas as pd import collections import cv2 im...
41.563636
146
0.651502
#!/usr/bin/env python2 # -*- coding: utf-8 -*- """ Created on Mon Jul 3 14:49:28 2017 @author: Arpan Description: Use c3d trained model for prediction. To be executed after training_model_m4.py """ import json import os import utils import numpy as np import h5py import pandas as pd import collections import cv2 im...
0
0
0
0
0
2,748
0
0
69
c363fa928990a80be5a5204729d760da5a3c9cb3
2,335
py
Python
arc_tool/arc_tool.py
joe--cool/woodworking
1fd54702c8e752b1e111554fe419065c7c5e0225
[ "MIT" ]
null
null
null
arc_tool/arc_tool.py
joe--cool/woodworking
1fd54702c8e752b1e111554fe419065c7c5e0225
[ "MIT" ]
null
null
null
arc_tool/arc_tool.py
joe--cool/woodworking
1fd54702c8e752b1e111554fe419065c7c5e0225
[ "MIT" ]
null
null
null
import argparse from fractions import Fraction import math import numpy as np import pandas as pd from tabulate import tabulate # Formatting function #def format_fraction(val): # f = Fraction(val) # return '{:>5} {:>3} /{:>3}'.format(, f.numerator, f.denominator) # Parse command line parser = argparse.Argument...
46.7
161
0.652677
import argparse from fractions import Fraction import math import numpy as np import pandas as pd from tabulate import tabulate # Formatting function #def format_fraction(val): # f = Fraction(val) # return '{:>5} {:>3} /{:>3}'.format(, f.numerator, f.denominator) # Parse command line parser = argparse.Argument...
0
0
0
0
0
0
0
0
0
ee6d798cc2dcd7d17001dee8af0cee52840957a7
2,654
py
Python
introduction/02_QueryParameters.py
IBM/api-samples
d69f7a7b74244012e835f023bceec2b0370be586
[ "Apache-2.0" ]
172
2015-02-18T21:18:31.000Z
2022-03-13T17:51:11.000Z
introduction/02_QueryParameters.py
IBM/api-samples
d69f7a7b74244012e835f023bceec2b0370be586
[ "Apache-2.0" ]
15
2015-03-06T15:30:33.000Z
2021-03-05T09:20:34.000Z
introduction/02_QueryParameters.py
IBM/api-samples
d69f7a7b74244012e835f023bceec2b0370be586
[ "Apache-2.0" ]
77
2015-03-06T13:14:06.000Z
2022-02-14T15:35:58.000Z
#!/usr/bin/env python3 # This sample demonstrates how to use query parameters with a REST API # endpoint. # For a list of the endpoints that you can use along with the parameters that # they accept you can view the REST API interactive help page on your # deployment at https://<hostname>/api_doc # You can also retriev...
39.61194
79
0.720422
#!/usr/bin/env python3 # This sample demonstrates how to use query parameters with a REST API # endpoint. # For a list of the endpoints that you can use along with the parameters that # they accept you can view the REST API interactive help page on your # deployment at https://<hostname>/api_doc # You can also retriev...
0
0
0
0
0
1,955
0
-7
45
e405eb400288c9f8521071196f3827f3622495fc
47
py
Python
passwordConfig.py
jarivankaam/spambot-Python
b1bd47c7481e52a900a89c8ad92b969272cfe2c3
[ "MIT" ]
2
2022-02-27T07:15:30.000Z
2022-03-15T18:27:12.000Z
passwordConfig.py
jarivankaam/spambot-Python
b1bd47c7481e52a900a89c8ad92b969272cfe2c3
[ "MIT" ]
null
null
null
passwordConfig.py
jarivankaam/spambot-Python
b1bd47c7481e52a900a89c8ad92b969272cfe2c3
[ "MIT" ]
null
null
null
password = { "password": ""#password here }
15.666667
32
0.595745
password = { "password": ""#password here }
0
0
0
0
0
0
0
0
0
fd06c7333d4e62e3dfd574a686746e934124a2eb
3,090
py
Python
fifth_semester/Wbudowane/lab5.py
MajronMan/agh_stuff
d045e3bd47ac17880526203d9993d9b2389a9ffe
[ "Unlicense" ]
2
2019-03-02T19:31:57.000Z
2019-04-03T19:54:39.000Z
fifth_semester/Wbudowane/lab5.py
MajronMan/agh_stuff
d045e3bd47ac17880526203d9993d9b2389a9ffe
[ "Unlicense" ]
null
null
null
fifth_semester/Wbudowane/lab5.py
MajronMan/agh_stuff
d045e3bd47ac17880526203d9993d9b2389a9ffe
[ "Unlicense" ]
1
2019-04-03T18:26:50.000Z
2019-04-03T18:26:50.000Z
g = Graph([ [0, 1, 1, 0, 1], [0, 0, 0, 0, 0], [0, 0, 0, 1, 0], [0, 0, 0, 0, 0], [0, 0, 0, 0, 0] ]) print(g.BFS())
22.888889
73
0.486408
from typing import List, Tuple, Optional import numpy as np def rmse(x: List[float], y: List[float]) -> float: r = 0 for (a, b) in zip(x, y): r += (a - b) ** 2 return r def lin_reg(data: List[Tuple[float, float]]) -> Tuple[float, float]: d = np.array(data) m = d.shape[0] p = np.sum(d...
0
169
0
2,189
0
416
0
16
159
08acdf3c412cefa6cf27ac195df4e06a7d9e30d4
256
py
Python
tapis_cli/commands/taccapis/v2/apps/init/templates.py
bpachev/tapis-cli
c3128fb5b63ef74e06b737bbd95ef28fb24f0d32
[ "BSD-3-Clause" ]
8
2020-10-18T22:48:23.000Z
2022-01-10T09:16:14.000Z
tapis_cli/commands/taccapis/v2/apps/init/templates.py
bpachev/tapis-cli
c3128fb5b63ef74e06b737bbd95ef28fb24f0d32
[ "BSD-3-Clause" ]
238
2019-09-04T14:37:54.000Z
2020-04-15T16:24:24.000Z
tapis_cli/commands/taccapis/v2/apps/init/templates.py
bpachev/tapis-cli
c3128fb5b63ef74e06b737bbd95ef28fb24f0d32
[ "BSD-3-Clause" ]
5
2019-09-20T04:23:49.000Z
2020-01-16T17:45:14.000Z
"""Provides key, name, description, and location for cookiecutter apps templates """ __all__ = ['COOKIECUTTER_URI', 'DIRECTORY', 'CHECKOUT'] COOKIECUTTER_URI = 'https://github.com/TACC-Cloud/cc-tapis-v2-app.git' DIRECTORY = 'default' CHECKOUT = 'master'
25.6
70
0.738281
"""Provides key, name, description, and location for cookiecutter apps templates """ __all__ = ['COOKIECUTTER_URI', 'DIRECTORY', 'CHECKOUT'] COOKIECUTTER_URI = 'https://github.com/TACC-Cloud/cc-tapis-v2-app.git' DIRECTORY = 'default' CHECKOUT = 'master'
0
0
0
0
0
0
0
0
0
ab0d9c97270d7743ca9f1adeb401249fd9546ca6
3,610
py
Python
gaussian_processes/GPy_1_0_5/inference/latent_function_inference/__init__.py
highlandenergy/no-covid-19-climate-silver-lining-in-the-us-power-sector
1568db61f4cfd5d1aa3ffc65ce594ad8fe5e3893
[ "MIT" ]
null
null
null
gaussian_processes/GPy_1_0_5/inference/latent_function_inference/__init__.py
highlandenergy/no-covid-19-climate-silver-lining-in-the-us-power-sector
1568db61f4cfd5d1aa3ffc65ce594ad8fe5e3893
[ "MIT" ]
null
null
null
gaussian_processes/GPy_1_0_5/inference/latent_function_inference/__init__.py
highlandenergy/no-covid-19-climate-silver-lining-in-the-us-power-sector
1568db61f4cfd5d1aa3ffc65ce594ad8fe5e3893
[ "MIT" ]
null
null
null
# Copyright (c) 2012-2014, Max Zwiessele, James Hensman # Licensed under the BSD 3-clause license (see LICENSE.txt) __doc__ = """ Inference over Gaussian process latent functions In all our GP models, the consistency propery means that we have a Gaussian prior over a finite set of points f. This prior is math:: N(...
34.711538
93
0.710249
# Copyright (c) 2012-2014, Max Zwiessele, James Hensman # Licensed under the BSD 3-clause license (see LICENSE.txt) __doc__ = """ Inference over Gaussian process latent functions In all our GP models, the consistency propery means that we have a Gaussian prior over a finite set of points f. This prior is math:: N(...
0
0
0
771
0
0
0
170
223
2980400d27dab31f8bad6ff0f84d71599b28e696
974
py
Python
examples/src/dbnd_examples/dbnd_spark/pyspark_scripts/cut_salad.py
ipattarapong/dbnd
7bd65621c46c73e078eb628f994127ad4c7dbd1a
[ "Apache-2.0" ]
224
2020-01-02T10:46:37.000Z
2022-03-02T13:54:08.000Z
examples/src/dbnd_examples/dbnd_spark/pyspark_scripts/cut_salad.py
ipattarapong/dbnd
7bd65621c46c73e078eb628f994127ad4c7dbd1a
[ "Apache-2.0" ]
16
2020-03-11T09:37:58.000Z
2022-01-26T10:22:08.000Z
examples/src/dbnd_examples/dbnd_spark/pyspark_scripts/cut_salad.py
ipattarapong/dbnd
7bd65621c46c73e078eb628f994127ad4c7dbd1a
[ "Apache-2.0" ]
24
2020-03-24T13:53:50.000Z
2022-03-22T11:55:18.000Z
import logging import sys logger = logging.getLogger(__name__) if __name__ == "__main__": run_spark(sys.argv)
22.651163
83
0.666324
import datetime import logging import sys from random import shuffle logger = logging.getLogger(__name__) def run_spark(args): from pyspark.sql import SparkSession from pyspark.sql.types import StringType, StructField, StructType timestamp = str(datetime.datetime.now()).replace(" ", "_") spark = ...
0
0
0
0
0
788
0
-1
68
ce74564e71956b24721fb93832bb798ca28d1093
1,719
py
Python
ghostwriter/rolodex/migrations/0008_projectscope.py
bbhunter/Ghostwriter
1b684ddd119feed9891e83b39c9b314b41d086ca
[ "BSD-3-Clause" ]
601
2019-07-30T17:06:37.000Z
2022-03-31T00:55:31.000Z
ghostwriter/rolodex/migrations/0008_projectscope.py
chrismaddalena/Ghostwriter
5a938358450cd0e69a42883b1b18e067644744a8
[ "BSD-3-Clause" ]
150
2019-08-01T07:20:22.000Z
2022-03-29T19:18:02.000Z
ghostwriter/rolodex/migrations/0008_projectscope.py
chrismaddalena/Ghostwriter
5a938358450cd0e69a42883b1b18e067644744a8
[ "BSD-3-Clause" ]
126
2019-07-30T17:42:49.000Z
2022-03-21T20:43:35.000Z
# Generated by Django 3.0.10 on 2021-01-22 22:02
53.71875
213
0.643979
# Generated by Django 3.0.10 on 2021-01-22 22:02 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('rolodex', '0007_auto_20201027_1914'), ] operations = [ migrations.CreateModel( name='ProjectSc...
0
0
0
1,571
0
0
0
30
68
21c58e28067f9673c8b4ddaba9798e3d5af0df10
1,184
py
Python
tbonlineproject/archive/urls.py
nathangeffen/tbonline3
1b8a3af8d2dc1ee8083ca6638d025e94bd98f253
[ "MIT" ]
null
null
null
tbonlineproject/archive/urls.py
nathangeffen/tbonline3
1b8a3af8d2dc1ee8083ca6638d025e94bd98f253
[ "MIT" ]
3
2021-06-08T23:57:13.000Z
2022-01-13T03:42:01.000Z
tbonlineproject/archive/urls.py
nathangeffen/tbonline-2
0d5869197e66a0057fa07cb99f21dde7f5b47c30
[ "MIT" ]
null
null
null
from django.views.generic import DetailView, ListView from archive.models import Catalogue, Document urlpatterns = patterns('archive.views', url(r'^$', ListView.as_view( context_object_name="catalogues", queryset=Catalogue.objects.all(), tem...
34.823529
86
0.569257
from django.conf.urls.defaults import * from django.views.generic import DetailView, ListView from archive.models import Catalogue, Document urlpatterns = patterns('archive.views', url(r'^$', ListView.as_view( context_object_name="catalogues", queryset=Catalogu...
0
0
0
0
0
0
0
18
22
a53ea13c9e8f16859fa4193aab2acfef32eda2ed
506
py
Python
main.py
MustafaTheCoder/Spam-Detector
5e3545adbfe6ac1a6729c5cf769d463f01b77e17
[ "MIT" ]
null
null
null
main.py
MustafaTheCoder/Spam-Detector
5e3545adbfe6ac1a6729c5cf769d463f01b77e17
[ "MIT" ]
null
null
null
main.py
MustafaTheCoder/Spam-Detector
5e3545adbfe6ac1a6729c5cf769d463f01b77e17
[ "MIT" ]
null
null
null
text = input("Text: ") spam = False if("make money fast"): spam = True print("Spam Detected!") elif("subscribe this"): spam = True print("Spam Detected!") elif("buy now"): spam = True print("Spam Detected!") elif("purchase now"): spam = True print("Spam Detected!") elif(...
20.24
33
0.559289
text = input("Text: ") spam = False if("make money fast"): spam = True print("Spam Detected!") elif("subscribe this"): spam = True print("Spam Detected!") elif("buy now"): spam = True print("Spam Detected!") elif("purchase now"): spam = True print("Spam Detected!") elif(...
0
0
0
0
0
0
0
0
0
41c261c39d724212ea8e551fc7ba36bebd70a398
367
py
Python
ex032.py
dsjocimar/python
5716f46a9fa7f64aa78a39df9c262c5392571340
[ "MIT" ]
null
null
null
ex032.py
dsjocimar/python
5716f46a9fa7f64aa78a39df9c262c5392571340
[ "MIT" ]
null
null
null
ex032.py
dsjocimar/python
5716f46a9fa7f64aa78a39df9c262c5392571340
[ "MIT" ]
null
null
null
# Exerccio 032 from datetime import date ano = int(input('Digite um ano qualquer. Digite 0 para analisar o ano ATUAL ')) if ano == 0: ano = date.today().year if ano % 4 == 0 and ano % 100 != 0 or ano % 400 == 0: print(f'O ano de \033[1m{ano}\033[m \033[1;32m BISSEXTO!\033[m') else: print(f'O Ano de \033[1...
30.583333
79
0.637602
# Exercício 032 from datetime import date ano = int(input('Digite um ano qualquer. Digite 0 para analisar o ano ATUAL ')) if ano == 0: ano = date.today().year if ano % 4 == 0 and ano % 100 != 0 or ano % 400 == 0: print(f'O ano de \033[1m{ano}\033[m \033[1;32mé BISSEXTO!\033[m') else: print(f'O Ano de \033...
6
0
0
0
0
0
0
0
0
7311c514b082b3e5c5c1cc9dfc27db9760ee5f0b
3,539
py
Python
sahara/service/api/v2/job_executions.py
ksshanam/sahara
0d259f7a71447cd0cefe4f11184cc2ee335f4e33
[ "Apache-2.0" ]
null
null
null
sahara/service/api/v2/job_executions.py
ksshanam/sahara
0d259f7a71447cd0cefe4f11184cc2ee335f4e33
[ "Apache-2.0" ]
null
null
null
sahara/service/api/v2/job_executions.py
ksshanam/sahara
0d259f7a71447cd0cefe4f11184cc2ee335f4e33
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2016 Red Hat, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
32.172727
78
0.69935
# Copyright (c) 2016 Red Hat, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
0
0
0
0
0
2,398
0
87
338
1459204f92935929520298d47434577d9d6efb3f
1,260
py
Python
testing/data_loader.py
CRAI-OUS/crainets
252b2ff8e5a2fa59a92fa988ce459ba8d7985491
[ "BSD-4-Clause" ]
1
2021-09-17T09:13:34.000Z
2021-09-17T09:13:34.000Z
testing/data_loader.py
CRAI-OUS/crainets
252b2ff8e5a2fa59a92fa988ce459ba8d7985491
[ "BSD-4-Clause" ]
4
2022-03-18T08:52:38.000Z
2022-03-18T13:01:40.000Z
testing/data_loader.py
CRAI-OUS/crainets
252b2ff8e5a2fa59a92fa988ce459ba8d7985491
[ "BSD-4-Clause" ]
null
null
null
import torch import torchvision import testing.config as config import torch.utils.data as data_utils transform = torchvision.transforms.Compose( [torchvision.transforms.ToTensor(), torchvision.transforms.RandomHorizontalFlip(), torchvision.transforms.Normalize((0.5, 0.5, 0.5), (0.5, 0.5, 0.5))]) transf...
32.307692
73
0.605556
import torch import torchvision import testing.config as config import torch.utils.data as data_utils transform = torchvision.transforms.Compose( [torchvision.transforms.ToTensor(), torchvision.transforms.RandomHorizontalFlip(), torchvision.transforms.Normalize((0.5, 0.5, 0.5), (0.5, 0.5, 0.5))]) transf...
0
0
0
0
0
0
0
0
0
b8d8d5b21d1bea0a4925d10529b48e1565a65cbf
21,038
py
Python
trec2014/python/cuttsum/sentsim.py
kedz/cuttsum
992c21192af03fd2ef863f5ab7d10752f75580fa
[ "Apache-2.0" ]
6
2015-09-10T02:22:21.000Z
2021-10-01T16:36:46.000Z
trec2014/python/cuttsum/sentsim.py
kedz/cuttsum
992c21192af03fd2ef863f5ab7d10752f75580fa
[ "Apache-2.0" ]
null
null
null
trec2014/python/cuttsum/sentsim.py
kedz/cuttsum
992c21192af03fd2ef863f5ab7d10752f75580fa
[ "Apache-2.0" ]
2
2018-04-04T10:44:32.000Z
2021-10-01T16:37:26.000Z
#from .jtest import get_2014_nuggets #from .submissions import Updates # for job in jobs: # articles_chunk, tsv_path = job # sentence_meta = [] # sentence_strings = [] # for si in sc.Chunk(path=articles_chunk, message=corpus.sc_msg()): # si.stream_id ...
37.038732
78
0.55761
#from .jtest import get_2014_nuggets #from .submissions import Updates from .judgements import ( get_2013_nuggets, get_2014_nuggets, get_2013_matches, get_2014_matches ) from .data import Resource, get_resource_manager from .misc import stringify_corenlp_doc, stringify_streamcorpus_sentence import os import signal ...
0
0
0
11,306
0
7,349
0
163
559
6f6e063d294cf646454d8529c7068bb1ca73735c
1,342
py
Python
sql_requests_tests.py
mv-yurchenko/terminal_db_browser
2409e66796b785f05fda729f440924361e84a44d
[ "MIT" ]
null
null
null
sql_requests_tests.py
mv-yurchenko/terminal_db_browser
2409e66796b785f05fda729f440924361e84a44d
[ "MIT" ]
null
null
null
sql_requests_tests.py
mv-yurchenko/terminal_db_browser
2409e66796b785f05fda729f440924361e84a44d
[ "MIT" ]
null
null
null
import unittest if __name__ == "__main__": unittest.main()
43.290323
154
0.640089
import unittest from SQLite import SQLite class testSQL(unittest.TestCase): sql_obj = SQLite("test.db") def test_select_request(self): # Test "SELECT ALL" test_request_1 = "SELECT * FROM test_table" expected_answ_1 = "[(123, '23'), (123, '123'), (1323, '123'), (1323, '123')...
0
0
0
1,224
0
0
0
4
45
7e1e18baf6f67b72ed15fd44cc8d9d3e06a1268e
20,522
py
Python
fusion_tcv/targets.py
mkuiper/deepmind-research
1642ae3499c8d1135ec6fe620a68911091dd25ef
[ "Apache-2.0" ]
2
2022-03-14T18:36:23.000Z
2022-03-14T22:35:20.000Z
fusion_tcv/targets.py
sunjinhao123/deepmind-research
1642ae3499c8d1135ec6fe620a68911091dd25ef
[ "Apache-2.0" ]
null
null
null
fusion_tcv/targets.py
sunjinhao123/deepmind-research
1642ae3499c8d1135ec6fe620a68911091dd25ef
[ "Apache-2.0" ]
null
null
null
# Copyright 2021 DeepMind Technologies Limited. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
32.94061
80
0.682146
# Copyright 2021 DeepMind Technologies Limited. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
0
16,188
0
1,064
0
335
0
30
755
81fd573d1b1a6f1715251e362ff0ec75662ce2bb
1,374
py
Python
NHL/nhl_pull.py
grdavis/box-score-scraper
6b4c1c142ce32f2d6c0dc159cac16b83d67dee35
[ "MIT" ]
3
2021-11-02T11:25:55.000Z
2022-02-06T21:08:35.000Z
NHL/nhl_pull.py
grdavis/box-score-scraper
6b4c1c142ce32f2d6c0dc159cac16b83d67dee35
[ "MIT" ]
null
null
null
NHL/nhl_pull.py
grdavis/box-score-scraper
6b4c1c142ce32f2d6c0dc159cac16b83d67dee35
[ "MIT" ]
null
null
null
URL = 'https://www.espn.com/nhl/scoreboard/_/date/DATE'
39.257143
96
0.71179
from bs4 import BeautifulSoup import requests import re import json URL = 'https://www.espn.com/nhl/scoreboard/_/date/DATE' def fix_dates_for_data(date_obj): #make sure dates are in the format: 20210130 new_month = str(date_obj.month) if len(str(date_obj.month)) == 2 else "0" + str(date_obj.month) new_day = str(da...
0
0
0
0
0
1,203
0
-20
135
1d2a819047adb731986559cd1992550743faf1d8
130
py
Python
tests/set_mrparse_path.py
rigdenlab/MrParse
4dd5286434d96dfb889b7398147922c9041d6628
[ "BSD-3-Clause" ]
null
null
null
tests/set_mrparse_path.py
rigdenlab/MrParse
4dd5286434d96dfb889b7398147922c9041d6628
[ "BSD-3-Clause" ]
8
2019-06-13T16:29:27.000Z
2021-11-19T14:11:55.000Z
tests/set_mrparse_path.py
rigdenlab/MrParse
4dd5286434d96dfb889b7398147922c9041d6628
[ "BSD-3-Clause" ]
null
null
null
import os import sys MRPARSE_DIR = os.path.join(os.path.abspath(os.path.dirname(__file__)),'..') sys.path.insert(0, MRPARSE_DIR)
21.666667
75
0.746154
import os import sys MRPARSE_DIR = os.path.join(os.path.abspath(os.path.dirname(__file__)),'..') sys.path.insert(0, MRPARSE_DIR)
0
0
0
0
0
0
0
0
0
a1927b5d4d55273d313dfa301768944c3c5a9c26
8,970
py
Python
custom_components/victorsmartkill/__init__.py
DTTerastar/victorsmartkill-homeassistant
1bf6d15377127e767a23f633cbec6dccd52fe15b
[ "MIT" ]
null
null
null
custom_components/victorsmartkill/__init__.py
DTTerastar/victorsmartkill-homeassistant
1bf6d15377127e767a23f633cbec6dccd52fe15b
[ "MIT" ]
null
null
null
custom_components/victorsmartkill/__init__.py
DTTerastar/victorsmartkill-homeassistant
1bf6d15377127e767a23f633cbec6dccd52fe15b
[ "MIT" ]
null
null
null
""" Custom integration to integrate victorsmartkill with Home Assistant. For more details about this integration, please refer to https://github.com/toreamun/victorsmartkill-homeassistant """ import logging from homeassistant.config_entries import ConfigEntry from homeassistant.helpers.typing import HomeAssi...
34.902724
89
0.645151
""" Custom integration to integrate victorsmartkill with Home Assistant. For more details about this integration, please refer to https://github.com/toreamun/victorsmartkill-homeassistant """ import asyncio from dataclasses import dataclass, field from datetime import timedelta import logging from typing imp...
0
1,025
4,967
1,199
0
0
0
387
435
1be27c1930794d244f34c1f745653a4bdfd459f9
2,343
py
Python
BBB-firmware/u-boot-v2015.10-rc5/test/py/u_boot_console_exec_attach.py
guileschool/BEAGLEBONE-tutorials
eecd83e0c14941b05ad38eeb77e5a50602cc29ca
[ "MIT" ]
4
2018-09-28T04:33:26.000Z
2021-03-10T06:29:55.000Z
BBB-firmware/u-boot-v2015.10-rc5/test/py/u_boot_console_exec_attach.py
guileschool/BEAGLEBONE-tutorials
eecd83e0c14941b05ad38eeb77e5a50602cc29ca
[ "MIT" ]
4
2016-08-30T11:30:25.000Z
2020-12-27T09:58:07.000Z
BBB-firmware/u-boot-v2015.10-rc5/test/py/u_boot_console_exec_attach.py
guileschool/BEAGLEBONE-tutorials
eecd83e0c14941b05ad38eeb77e5a50602cc29ca
[ "MIT" ]
2
2016-12-30T08:02:57.000Z
2020-05-16T05:59:30.000Z
# Copyright (c) 2015 Stephen Warren # Copyright (c) 2015-2016, NVIDIA CORPORATION. All rights reserved. # # SPDX-License-Identifier: GPL-2.0 # Logic to interact with U-Boot running on real hardware, typically via a # physical serial port.
34.455882
81
0.649595
# Copyright (c) 2015 Stephen Warren # Copyright (c) 2015-2016, NVIDIA CORPORATION. All rights reserved. # # SPDX-License-Identifier: GPL-2.0 # Logic to interact with U-Boot running on real hardware, typically via a # physical serial port. import sys from u_boot_spawn import Spawn from u_boot_console_base import Conso...
0
0
0
1,993
0
0
0
20
90
c3ab9133a30455a5aac4572c6826defc0bace894
574
py
Python
mapreduceterm.py
yulexanova/Big_data_project2
5a308cb98e92a6f215f6abca36a37b438646a415
[ "MIT" ]
null
null
null
mapreduceterm.py
yulexanova/Big_data_project2
5a308cb98e92a6f215f6abca36a37b438646a415
[ "MIT" ]
null
null
null
mapreduceterm.py
yulexanova/Big_data_project2
5a308cb98e92a6f215f6abca36a37b438646a415
[ "MIT" ]
null
null
null
import os import sys from pprint import pprint from operator import add import pyspark from pyspark.context import SparkContext sc = SparkContext() file = "SampleData3.txt" wordcounts = sc.textFile(file) \ .map(lambda l: ((l.split(" ")[0], len([x for x in l.split(" ")[1:] if ("gene_" in x or "disease_" in x)]...
28.7
187
0.592334
import os import sys from pprint import pprint from operator import add import pyspark from pyspark.context import SparkContext sc = SparkContext() file = "SampleData3.txt" wordcounts = sc.textFile(file) \ .map(lambda l: ((l.split(" ")[0], len([x for x in l.split(" ")[1:] if ("gene_" in x or "disease_" in x)]...
0
0
0
0
0
0
0
0
0
8e5990be4d963a9258a9832405e4fdb90f7a7c1c
2,775
py
Python
mall/apps/pay/views.py
xxbsg/meiduo
0e82628833c4b482884cd392b8d22cb8558f1ffd
[ "MIT" ]
null
null
null
mall/apps/pay/views.py
xxbsg/meiduo
0e82628833c4b482884cd392b8d22cb8558f1ffd
[ "MIT" ]
null
null
null
mall/apps/pay/views.py
xxbsg/meiduo
0e82628833c4b482884cd392b8d22cb8558f1ffd
[ "MIT" ]
null
null
null
# Create your views here. """ 1. (appid) 2. (2 ,) 2.1 2.2 , ---public begin--- ---end-- 3. (/ SDK) (SDK ) 4. (, API()) axirmj7487@sandbox.com 111111 """ """ ,id 1. id 2. id 3. alipay 4. order_string 5. url 6. url GET /orders/(?P<order_id>\d+)/payment/ """
30.163043
87
0.642162
from alipay import AliPay from django.shortcuts import render # Create your views here. from rest_framework import status from mall import settings from rest_framework.permissions import IsAuthenticated from rest_framework.response import Response from rest_framework.views import APIView from orders.models import Ord...
885
0
0
1,837
0
0
0
123
222
e5bda155b81afdc76753db301694431c6f0a7ed1
1,698
py
Python
configs/__init__.py
ishine/nlp-dialogue
d47c1438cb5c45c2c2aebfb82fea92bef4c3d65c
[ "Apache-2.0" ]
59
2021-02-15T09:15:12.000Z
2022-03-29T01:48:24.000Z
configs/__init__.py
ishine/nlp-dialogue
d47c1438cb5c45c2c2aebfb82fea92bef4c3d65c
[ "Apache-2.0" ]
null
null
null
configs/__init__.py
ishine/nlp-dialogue
d47c1438cb5c45c2c2aebfb82fea92bef4c3d65c
[ "Apache-2.0" ]
15
2021-02-15T09:16:04.000Z
2022-02-21T07:18:02.000Z
#! -*- coding: utf-8 -*- """ Global Configuration """ # Author: DengBoCong <bocongdeng@gmail.com> # # License: Apache-2.0 License from __future__ import absolute_import from __future__ import division from __future__ import print_function import os import uuid from configs.configs import config from flask import Flas...
26.123077
92
0.743816
#! -*- coding: utf-8 -*- """ Global Configuration """ # Author: DengBoCong <bocongdeng@gmail.com> # # License: Apache-2.0 License from __future__ import absolute_import from __future__ import division from __future__ import print_function import os import uuid from configs.configs import config from configs.constant ...
0
88
0
0
0
0
0
9
45
c8422d03ff6c162a7a235c164df43ce7fd4202c5
1,025
py
Python
setup.py
drougge/wellpapp-pyclient
43d66a1e2a122ac87e477905c5e2460e11be3c26
[ "MIT" ]
null
null
null
setup.py
drougge/wellpapp-pyclient
43d66a1e2a122ac87e477905c5e2460e11be3c26
[ "MIT" ]
null
null
null
setup.py
drougge/wellpapp-pyclient
43d66a1e2a122ac87e477905c5e2460e11be3c26
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 from setuptools import setup fuse_reqs = [ 'fuse-python >= 0.3.1; python_version < "3"', 'fuse-python >= 1.0.0; python_version > "3"', ] readme = open('README.md', 'r').read() readme = readme.replace( '(FUSE.md)', '(https://github.com/drougge/wellpapp-pyclient/blob/master/FUSE.md)' ) setu...
21.808511
85
0.659512
#!/usr/bin/env python3 from setuptools import setup fuse_reqs = [ 'fuse-python >= 0.3.1; python_version < "3"', 'fuse-python >= 1.0.0; python_version > "3"', ] readme = open('README.md', 'r').read() readme = readme.replace( '(FUSE.md)', '(https://github.com/drougge/wellpapp-pyclient/blob/master/FUSE.md)' ) setu...
0
0
0
0
0
0
0
0
0
0552f00cb48be9e0abd175a5d21dfe1fa347b452
1,544
py
Python
tests/html.py
sdss/opscore
dd4f2b2ad525fe3dfe3565463de2c079a7e1232e
[ "BSD-3-Clause" ]
null
null
null
tests/html.py
sdss/opscore
dd4f2b2ad525fe3dfe3565463de2c079a7e1232e
[ "BSD-3-Clause" ]
1
2021-08-17T21:08:14.000Z
2021-08-17T21:08:14.000Z
tests/html.py
sdss/opscore
dd4f2b2ad525fe3dfe3565463de2c079a7e1232e
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python """Unit tests for opscore.utility.html """ # Created 28-Jun-2008 by David Kirkby (dkirkby@uci.edu) import unittest if __name__ == "__main__": unittest.main()
29.132075
86
0.608808
#!/usr/bin/env python """Unit tests for opscore.utility.html """ # Created 28-Jun-2008 by David Kirkby (dkirkby@uci.edu) import unittest from html.parser import HTMLParser import opscore.utility.html as utilHtml class HTMLTests(unittest.TestCase): @staticmethod def validate(doc): parser = HTMLParser...
0
98
0
1,159
0
0
0
31
68
2c25a70e7347753ea1cd9e7e980a6b744ff6e177
5,010
py
Python
tests/test_slope_disp.py
geosharma/pygeems
816b77618820caad6c60edab66d0a7c931b17632
[ "MIT" ]
3
2019-01-11T04:44:29.000Z
2022-01-05T01:09:46.000Z
tests/test_slope_disp.py
geosharma/pygeems
816b77618820caad6c60edab66d0a7c931b17632
[ "MIT" ]
null
null
null
tests/test_slope_disp.py
geosharma/pygeems
816b77618820caad6c60edab66d0a7c931b17632
[ "MIT" ]
1
2021-02-21T17:29:21.000Z
2021-02-21T17:29:21.000Z
import pathlib FPATH_DATA = pathlib.Path(__file__).parent / "data" # Test values from Table 1 in BT07 # Test values from Table 1 in BT07. Authors provided a range of values, which are # interpreted to be log-normally distributed. The median is computed and tested against # Test values from Table 2 of Bray...
32.532468
88
0.652894
import pathlib import numpy as np import pytest from numpy.testing import assert_allclose import pygeems FPATH_DATA = pathlib.Path(__file__).parent / "data" @pytest.mark.parametrize( "yield_coef,pga,mag,pgv,expected", [ # Examples from Rathje et. al (2014) (0.1, 0.54, 6.75, None, 43), ...
0
3,849
0
0
0
395
0
2
316
3515139809088fddf10f5643c392c7d5b7c91f0c
9,522
py
Python
python/aether/src/aether/mxp/session.py
MoysheBenRabi/setp
7619f0bae457e14e2fb41e58bfe517019628c5de
[ "Apache-2.0" ]
1
2021-07-13T12:22:22.000Z
2021-07-13T12:22:22.000Z
python/aether/src/aether/mxp/session.py
MoysheBenRabi/setp
7619f0bae457e14e2fb41e58bfe517019628c5de
[ "Apache-2.0" ]
1
2021-01-04T21:53:56.000Z
2021-01-04T21:59:36.000Z
python/aether/src/aether/mxp/session.py
MoysheBenRabi/setp
7619f0bae457e14e2fb41e58bfe517019628c5de
[ "Apache-2.0" ]
1
2021-09-19T16:18:54.000Z
2021-09-19T16:18:54.000Z
#<Tommil> There is one particular detail in session forming which may not be obvious. The answering party needs to send ack to the connection request message as the very first message #<Tommil> the calling party is using this ack to bind together upstream and downstream session session ids #Enumeration of the various ...
42.891892
183
0.657215
#<Tommil> There is one particular detail in session forming which may not be obvious. The answering party needs to send ack to the connection request message as the very first message #<Tommil> the calling party is using this ack to bind together upstream and downstream session session ids import datetime from collecti...
0
356
0
8,410
0
0
0
21
176
7cd37d34ea6cd7ed7dbf95f32af2daa52478d93b
1,674
py
Python
pro_tes/pro_tes/app.py
andrewcollette/ga4gh_compute_trial
0b9f9ef769925e04ecb48fdca4057d31eede824d
[ "Apache-2.0" ]
null
null
null
pro_tes/pro_tes/app.py
andrewcollette/ga4gh_compute_trial
0b9f9ef769925e04ecb48fdca4057d31eede824d
[ "Apache-2.0" ]
null
null
null
pro_tes/pro_tes/app.py
andrewcollette/ga4gh_compute_trial
0b9f9ef769925e04ecb48fdca4057d31eede824d
[ "Apache-2.0" ]
null
null
null
"""Entry point to start service.""" from pro_tes.config.config_parser import (get_conf) if __name__ == '__main__': connexion_app, config = run_server() # Run app connexion_app.run( use_reloader=get_conf(config, 'server', 'use_reloader') )
31
71
0.76583
"""Entry point to start service.""" from pro_tes.api.register_openapi import register_openapi from pro_tes.config.app_config import parse_app_config from pro_tes.config.config_parser import (get_conf, get_conf_type) from pro_tes.config.log_config import configure_logging from pro_tes.database.register_mongodb import r...
0
0
0
0
0
904
0
304
200
e8278fb2c1cda1a37eb43220c40f8fbf30d27464
4,437
py
Python
paddlenlp/trainer/utils/helper.py
27182812/PaddleNLP
20d1734c7923402dd0e13bd63f33b90f882f7f14
[ "Apache-2.0" ]
null
null
null
paddlenlp/trainer/utils/helper.py
27182812/PaddleNLP
20d1734c7923402dd0e13bd63f33b90f882f7f14
[ "Apache-2.0" ]
null
null
null
paddlenlp/trainer/utils/helper.py
27182812/PaddleNLP
20d1734c7923402dd0e13bd63f33b90f882f7f14
[ "Apache-2.0" ]
null
null
null
# Copyright 2020-present the HuggingFace Inc. team. # Copyright (c) 2022 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.o...
40.336364
119
0.683795
# Copyright 2020-present the HuggingFace Inc. team. # Copyright (c) 2022 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.o...
0
0
0
0
0
845
0
59
67
c462992cdb92886b6cdc022db9824158fb861960
2,399
py
Python
command_14.py
davidecristiani/uavberry_beta
a277e30f5ba86eecf02f4d7b376c0f83ec069ff5
[ "Apache-2.0" ]
null
null
null
command_14.py
davidecristiani/uavberry_beta
a277e30f5ba86eecf02f4d7b376c0f83ec069ff5
[ "Apache-2.0" ]
null
null
null
command_14.py
davidecristiani/uavberry_beta
a277e30f5ba86eecf02f4d7b376c0f83ec069ff5
[ "Apache-2.0" ]
null
null
null
# COMMAND 14 BACK AND FRONT CAMERA - NO FLIGHT from pyparrot.Minidrone import Mambo from ground_inspector.ftp_download import ftp_download from ground_inspector.ground_vision import ground_vision from pyparrot.DroneVision import DroneVision import os mamboAddr = "e0:14:d0:63:3d:d0" os.path.join(os.path.dirname(__file_...
29.617284
100
0.697374
# COMMAND 14 BACK AND FRONT CAMERA - NO FLIGHT from pyparrot.Minidrone import Mambo from ground_inspector.ftp_download import ftp_download from ground_inspector.ground_vision import ground_vision from shelf_detector.simple_qr_scan import qr_scan_image from pyparrot.DroneVision import DroneVision import threading import...
0
0
0
877
0
0
0
8
111
a2a5c8c695998e375079d52583b1a5e9ace40d24
8,637
py
Python
vise/cli/main_functions.py
kumagai-group/vise
8adfe61ad8f31767ec562f02f271e2495f357cd4
[ "MIT" ]
16
2020-07-14T13:14:05.000Z
2022-03-04T13:39:30.000Z
vise/cli/main_functions.py
kumagai-group/vise
8adfe61ad8f31767ec562f02f271e2495f357cd4
[ "MIT" ]
10
2021-03-15T20:47:45.000Z
2021-08-19T00:47:12.000Z
vise/cli/main_functions.py
kumagai-group/vise
8adfe61ad8f31767ec562f02f271e2495f357cd4
[ "MIT" ]
6
2020-03-03T00:42:39.000Z
2022-02-22T02:34:47.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2020. Distributed under the terms of the MIT License. from vise.util.logger import get_logger logger = get_logger(__name__)
38.048458
81
0.669214
# -*- coding: utf-8 -*- # Copyright (c) 2020. Distributed under the terms of the MIT License. from argparse import Namespace from copy import deepcopy from pathlib import Path import yaml from pymatgen.core import Structure from pymatgen.ext.matproj import MPRester from pymatgen.io.vasp import Vasprun, Outcar from v...
0
0
0
2,813
0
4,090
0
802
758
17cb500207d386b65b37360ae824d7998794437c
2,060
py
Python
AppLogger.py
codarrenvelvindron/AppLogger-python
b5cf85dd41f86941fb4b4a22b64cdd19dd693ac3
[ "MIT" ]
1
2021-03-04T05:56:25.000Z
2021-03-04T05:56:25.000Z
AppLogger.py
codarrenvelvindron/AppLogger-python
b5cf85dd41f86941fb4b4a22b64cdd19dd693ac3
[ "MIT" ]
null
null
null
AppLogger.py
codarrenvelvindron/AppLogger-python
b5cf85dd41f86941fb4b4a22b64cdd19dd693ac3
[ "MIT" ]
null
null
null
# AppLogger : The application logger for python # Useful in auditing actions/variables and storing everything to a log file. # Git repo: https://github.com/codarrenvelvindron/AppLogger-python # By Codarren Velvindron # Contact: devildron@gmail.com # 25/02/2021 # Licence: MIT
29.855072
76
0.603398
# AppLogger : The application logger for python # Useful in auditing actions/variables and storing everything to a log file. # Git repo: https://github.com/codarrenvelvindron/AppLogger-python # By Codarren Velvindron # Contact: devildron@gmail.com # 25/02/2021 # Licence: MIT import os from datetime import datetime cl...
0
0
0
1,720
0
0
0
-4
68
4d1885bc99c5341d9a912f2fe2b9851981886013
245
py
Python
release/stubs/Autodesk/Civil/__init__.py
paoloemilioserra/ironpython-stubs
49d92db7f28f25ccd3654c5f6ae83daa0c401fa1
[ "MIT" ]
null
null
null
release/stubs/Autodesk/Civil/__init__.py
paoloemilioserra/ironpython-stubs
49d92db7f28f25ccd3654c5f6ae83daa0c401fa1
[ "MIT" ]
null
null
null
release/stubs/Autodesk/Civil/__init__.py
paoloemilioserra/ironpython-stubs
49d92db7f28f25ccd3654c5f6ae83daa0c401fa1
[ "MIT" ]
null
null
null
# encoding: utf-8 # module Autodesk.Civil calls itself Civil # from Civil3DNodes, Version=13.2.2161.0, Culture=neutral, PublicKeyToken=null # by generator 1.145 # no doc # no imports # no functions # no classes # variables with complex values
20.416667
78
0.755102
# encoding: utf-8 # module Autodesk.Civil calls itself Civil # from Civil3DNodes, Version=13.2.2161.0, Culture=neutral, PublicKeyToken=null # by generator 1.145 # no doc # no imports # no functions # no classes # variables with complex values
0
0
0
0
0
0
0
0
0
0b983899675f2caee588e4976de3376a61f73fe2
2,884
py
Python
backend/app.py
jimbunny/AdminSystem
d9a42e2d8608cb0d9bc88f4c1945da48fb8cc925
[ "MIT" ]
null
null
null
backend/app.py
jimbunny/AdminSystem
d9a42e2d8608cb0d9bc88f4c1945da48fb8cc925
[ "MIT" ]
null
null
null
backend/app.py
jimbunny/AdminSystem
d9a42e2d8608cb0d9bc88f4c1945da48fb8cc925
[ "MIT" ]
null
null
null
#!/usr/bin/env python #-*- coding:utf-8 -*- # author:jingtongyu # datetime:2020/6/7 10:14 # software: PyCharm import string import flask_restful from flask import Flask, abort, jsonify from hashids import Hashids from models import db from common import code, pretty_result # app = Flask(__name__) hash_ids = Hashid...
29.731959
106
0.680305
#!/usr/bin/env python #-*- coding:utf-8 -*- # author:jingtongyu # datetime:2020/6/7 10:14 下午 # software: PyCharm import string import flask_restful from flask import Flask, abort, jsonify, request from hashids import Hashids from models import db from common import code, pretty_result # 添加请求钩子 from common.middlewares ...
210
475
0
0
0
0
0
47
120
ae34e705547c17c1078103ac56bc76654babbf44
571
py
Python
library/expand_fs.py
stevewoolley/pi-fleet
dc998c99ffddbcf67d8459cb88231621182d4f3b
[ "MIT" ]
7
2019-01-14T20:22:46.000Z
2021-12-28T22:12:52.000Z
library/expand_fs.py
stevewoolley/pi-fleet
dc998c99ffddbcf67d8459cb88231621182d4f3b
[ "MIT" ]
null
null
null
library/expand_fs.py
stevewoolley/pi-fleet
dc998c99ffddbcf67d8459cb88231621182d4f3b
[ "MIT" ]
1
2020-09-18T16:07:47.000Z
2020-09-18T16:07:47.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- # https://github.com/mikolak-net/ansible-raspi-config/blob/master/library/expand_fs.py MAIN_PARTITION_NAME = "/dev/mmcblk0p2" main()
30.052632
120
0.695271
#!/usr/bin/python # -*- coding: utf-8 -*- # https://github.com/mikolak-net/ansible-raspi-config/blob/master/library/expand_fs.py from ansible.module_utils.basic import * MAIN_PARTITION_NAME = "/dev/mmcblk0p2" def main(): module = AnsibleModule(argument_spec=dict()) (rc, out, err) = module.run_command(["sud...
0
0
0
0
0
328
0
19
46
ed483ba6ee4aacf830fc947bdc25a23d31b39203
2,513
py
Python
tools/polymer/txt_to_polymer_grdp.py
zipated/src
2b8388091c71e442910a21ada3d97ae8bc1845d3
[ "BSD-3-Clause" ]
2,151
2020-04-18T07:31:17.000Z
2022-03-31T08:39:18.000Z
tools/polymer/txt_to_polymer_grdp.py
cangulcan/src
2b8388091c71e442910a21ada3d97ae8bc1845d3
[ "BSD-3-Clause" ]
395
2020-04-18T08:22:18.000Z
2021-12-08T13:04:49.000Z
tools/polymer/txt_to_polymer_grdp.py
cangulcan/src
2b8388091c71e442910a21ada3d97ae8bc1845d3
[ "BSD-3-Clause" ]
338
2020-04-18T08:03:10.000Z
2022-03-29T12:33:22.000Z
#!/usr/bin/env python # Copyright 2015 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. from __future__ import with_statement import os import sys FILE_TEMPLATE = \ """<?xml version="1.0" encoding="utf-8"?> <!-- This fi...
28.235955
98
0.687624
#!/usr/bin/env python # Copyright 2015 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. from __future__ import with_statement import os import string import sys FILE_TEMPLATE = \ """<?xml version="1.0" encoding="utf-8"?> ...
0
0
0
25
0
700
0
-8
137
45caefa17d2a3f4a4a42349bcd2a76e7aa06834c
586
py
Python
rubicon/domain/metric.py
gforsyth/rubicon
b77c0bdfc73d3f5666f76c83240706c10cd2e88c
[ "Apache-2.0" ]
null
null
null
rubicon/domain/metric.py
gforsyth/rubicon
b77c0bdfc73d3f5666f76c83240706c10cd2e88c
[ "Apache-2.0" ]
null
null
null
rubicon/domain/metric.py
gforsyth/rubicon
b77c0bdfc73d3f5666f76c83240706c10cd2e88c
[ "Apache-2.0" ]
null
null
null
DIRECTIONALITY_VALUES = ["score", "loss"]
26.636364
93
0.733788
from dataclasses import dataclass, field from datetime import datetime from rubicon.domain.utils import uuid DIRECTIONALITY_VALUES = ["score", "loss"] @dataclass(frozen=True) class Metric: name: str value: float id: str = field(default_factory=uuid.uuid4) description: str = None directionality:...
0
409
0
0
0
0
0
43
90
462a56d73267e1d46963161c10088c1c4cd85e10
76,053
py
Python
pysnmp-with-texts/RAID-Adapter-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
8
2019-05-09T17:04:00.000Z
2021-06-09T06:50:51.000Z
pysnmp-with-texts/RAID-Adapter-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
4
2019-05-31T16:42:59.000Z
2020-01-31T21:57:17.000Z
pysnmp-with-texts/RAID-Adapter-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
10
2019-04-30T05:51:36.000Z
2022-02-16T03:33:41.000Z
# # PySNMP MIB module RAID-Adapter-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/RAID-Adapter-MIB # Produced by pysmi-0.3.4 at Wed May 1 14:51:41 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (default, Mar ...
137.528029
6,801
0.76974
# # PySNMP MIB module RAID-Adapter-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/RAID-Adapter-MIB # Produced by pysmi-0.3.4 at Wed May 1 14:51:41 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (default, Mar ...
0
0
0
0
0
0
0
0
0
e13b36df61294af1dcc222c7c8843b049e8b68de
2,435
py
Python
livereload/django/management/commands/runserver.py
n4bz0r/django-livereload-notifier
8807e8e3204547376e435e6c2ff1d761800b6bb3
[ "MIT" ]
null
null
null
livereload/django/management/commands/runserver.py
n4bz0r/django-livereload-notifier
8807e8e3204547376e435e6c2ff1d761800b6bb3
[ "MIT" ]
null
null
null
livereload/django/management/commands/runserver.py
n4bz0r/django-livereload-notifier
8807e8e3204547376e435e6c2ff1d761800b6bb3
[ "MIT" ]
null
null
null
from django.conf import settings if 'django.contrib.staticfiles' in settings.INSTALLED_APPS: from django.contrib.staticfiles.management.commands.runserver import Command as RunserverCommand else:
36.893939
114
0.699795
from livereload.django.template.observers import DjangoTemplateDirectoriesObserver from livereload.server.notifiers import LivereloadServerNotifier from livereload.event.handlers import LivereloadFileEventHandler from django.conf import settings if 'django.contrib.staticfiles' in settings.INSTALLED_APPS: from dja...
0
0
0
1,911
0
0
0
207
115
6186902de6a2335f2ab83c456ec694019c8e93e4
4,017
py
Python
scripts/generate_test_cut_silhouette_curio.py
ahadrauf/dxf_stl_renderer
b9b2aad405004d24da11cd1ac1c8debba8de129c
[ "MIT" ]
null
null
null
scripts/generate_test_cut_silhouette_curio.py
ahadrauf/dxf_stl_renderer
b9b2aad405004d24da11cd1ac1c8debba8de129c
[ "MIT" ]
null
null
null
scripts/generate_test_cut_silhouette_curio.py
ahadrauf/dxf_stl_renderer
b9b2aad405004d24da11cd1ac1c8debba8de129c
[ "MIT" ]
null
null
null
import sys sys.path.append(r"C:\Users\ahadrauf\Desktop\Research\dxf_stl_renderer") from datetime import datetime if __name__ == '__main__': now = datetime.now() name_clarifier = "_test_cut_silhouette_curio_v2" timestamp = now.strftime("%Y%m%d_%H_%M_%S") + name_clarifier print(timestamp) p = gener...
42.734043
119
0.511576
import sys sys.path.append(r"C:\Users\ahadrauf\Desktop\Research\dxf_stl_renderer") from pattern import * from settings import * import numpy as np from datetime import datetime def generate_test_cut_curio(): p = Pattern(setting=LaserCutter) pattern_buffer_x = 20 # mm pattern_buffer_y = 20 # mm ###...
0
0
0
0
0
3,430
0
-2
90
7d3dbadef508f1565f1b08397e96444e2bf92665
598
py
Python
tests/run_all_tests.py
jcartus/SCFInitialGuess
e4a9280e8cbabb126946e47affa652243b74753c
[ "MIT" ]
1
2020-03-02T02:36:59.000Z
2020-03-02T02:36:59.000Z
tests/run_all_tests.py
jcartus/SCFInitialGuess
e4a9280e8cbabb126946e47affa652243b74753c
[ "MIT" ]
null
null
null
tests/run_all_tests.py
jcartus/SCFInitialGuess
e4a9280e8cbabb126946e47affa652243b74753c
[ "MIT" ]
null
null
null
"""This script will run all unit test for the project. It was taken from https://github.com/ralf-meyer/NeuralNetworks/tests/run_all_tests.py. Author: - Ralf Meyer, QCIEP, TU Graz """ import os import sys import unittest from SCFInitialGuess.utilities.usermessages import Messenger as msg if __name__ == '__main_...
28.47619
90
0.73913
"""This script will run all unit test for the project. It was taken from https://github.com/ralf-meyer/NeuralNetworks/tests/run_all_tests.py. Author: - Ralf Meyer, QCIEP, TU Graz """ import os import sys import unittest from SCFInitialGuess.utilities.usermessages import Messenger as msg if __name__ == '__main_...
0
0
0
0
0
0
0
0
0
437e886c6f60bb69b4d030ad952c0c644f2eb6ed
320
py
Python
lesson4.py
arice84/bootcamp
73a5517bcf282fdb2bd8808eb2bfb839eaceadf1
[ "CC-BY-4.0", "MIT" ]
null
null
null
lesson4.py
arice84/bootcamp
73a5517bcf282fdb2bd8808eb2bfb839eaceadf1
[ "CC-BY-4.0", "MIT" ]
null
null
null
lesson4.py
arice84/bootcamp
73a5517bcf282fdb2bd8808eb2bfb839eaceadf1
[ "CC-BY-4.0", "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import bootcamp_utils as booU x = np.random.random(size=100000) x_ecdf, y_ecdf = booU.ecdf(x) plt.plot(x_ecdf[::1000], y_ecdf[::1000], marker='.', linestyle='none', markersize=10) x = np.random.random(size=20) heads = x <=0.5
24.615385
85
0.734375
import numpy as np import matplotlib.pyplot as plt import seaborn as sns import scipy.stats import bootcamp_utils as booU x = np.random.random(size=100000) x_ecdf, y_ecdf = booU.ecdf(x) plt.plot(x_ecdf[::1000], y_ecdf[::1000], marker='.', linestyle='none', markersize=10) x = np.random.random(size=20) heads = x <=0.5
0
0
0
0
0
0
0
-3
44
53578873e58b4b89b08a6f925cf69e0bc5a6b8a8
3,672
py
Python
lightnet/models/_network_darknet19.py
eavise-kul/lightnet
d2d5d3fff8f929c3683c34f176217649375b98e1
[ "MIT" ]
6
2019-10-10T05:42:50.000Z
2022-02-27T04:59:29.000Z
lightnet/models/_network_darknet19.py
eavise-kul/lightnet
d2d5d3fff8f929c3683c34f176217649375b98e1
[ "MIT" ]
null
null
null
lightnet/models/_network_darknet19.py
eavise-kul/lightnet
d2d5d3fff8f929c3683c34f176217649375b98e1
[ "MIT" ]
4
2020-01-25T20:16:23.000Z
2021-04-29T13:02:34.000Z
# # Darknet Darknet19 model # Copyright EAVISE # import torch.nn as nn __all__ = ['Darknet19']
51.71831
124
0.581972
# # Darknet Darknet19 model # Copyright EAVISE # import functools from collections import OrderedDict import torch.nn as nn import lightnet.network as lnn __all__ = ['Darknet19'] class Darknet19(lnn.module.Darknet): """ Darknet19 implementation :cite:`yolo_v2`. Args: num_classes (Number, option...
0
0
0
3,463
0
0
0
18
90
e2b1a4f31488481804f4c984e3b7b8fd3ec9039f
1,035
py
Python
scripts/ensembl/convert_biomart_protein_annotation_to_gff.py
mahajrod/MAVR
4db74dff7376a2ffe4426db720b241de9198f329
[ "MIT" ]
10
2015-04-28T14:15:04.000Z
2021-03-15T00:07:38.000Z
scripts/ensembl/convert_biomart_protein_annotation_to_gff.py
mahajrod/MAVR
4db74dff7376a2ffe4426db720b241de9198f329
[ "MIT" ]
null
null
null
scripts/ensembl/convert_biomart_protein_annotation_to_gff.py
mahajrod/MAVR
4db74dff7376a2ffe4426db720b241de9198f329
[ "MIT" ]
6
2017-03-16T22:38:41.000Z
2021-08-11T00:22:52.000Z
#!/usr/bin/env python __author__ = 'Sergei F. Kliver' import argparse from RouToolPa.Routines import EnsemblRoutines parser = argparse.ArgumentParser() parser.add_argument("-i", "--input", action="store", dest="input", required=True, help="Input file with protein annotations generated from Biomar...
47.045455
108
0.656039
#!/usr/bin/env python __author__ = 'Sergei F. Kliver' import argparse from RouToolPa.Routines import EnsemblRoutines parser = argparse.ArgumentParser() parser.add_argument("-i", "--input", action="store", dest="input", required=True, help="Input file with protein annotations generated from Biomar...
0
0
0
0
0
0
0
0
0
e8ea8ffbc839ca51961c02cf393eb3f1a7ee7e50
3,879
py
Python
CS696/Modelling/embeddings/model.py
tiwarikajal/Stock_fundamental_prediction
df55740bcd9568711fe05d25aaec3a1dd8864a66
[ "MIT" ]
1
2020-03-20T23:24:21.000Z
2020-03-20T23:24:21.000Z
CS696/Modelling/embeddings/model.py
tiwarikajal/Stock_fundamental_prediction
df55740bcd9568711fe05d25aaec3a1dd8864a66
[ "MIT" ]
null
null
null
CS696/Modelling/embeddings/model.py
tiwarikajal/Stock_fundamental_prediction
df55740bcd9568711fe05d25aaec3a1dd8864a66
[ "MIT" ]
1
2020-04-02T01:34:52.000Z
2020-04-02T01:34:52.000Z
import torch device = torch.device('cuda' if torch.cuda.is_available() else 'cpu') # print(device)
44.586207
105
0.599123
from transformers import BertTokenizer, BertModel, BertConfig import torch device = torch.device('cuda' if torch.cuda.is_available() else 'cpu') # print(device) class UnStructuredModel: def __init__(self, model_name, max_length, stride): self.model_name = model_name self.tokenizer = None s...
0
0
0
3,691
0
0
0
40
44
067da8e80078eca138afceabd7fdbf6388aa1218
559
py
Python
template/dataflow/template.py
eric8607242/OSNASLib
43908ab454fb78f835f8a015935205179b9acec4
[ "MIT" ]
3
2021-06-14T11:00:21.000Z
2021-10-18T02:59:54.000Z
template/dataflow/template.py
eric8607242/OneShot_NAS_example
2e758a9e5d9e03eecb9c4cc0e2e6a8ec38cf7052
[ "MIT" ]
1
2021-12-04T07:42:25.000Z
2021-12-04T15:14:12.000Z
template/dataflow/template.py
eric8607242/OneShot_NAS_example
2e758a9e5d9e03eecb9c4cc0e2e6a8ec38cf7052
[ "MIT" ]
null
null
null
def get_{{customize_name}}_dataloader(dataset_path, input_size, batch_size, num_workers, train_portion=1): """ Prepare dataset for training and evaluating pipeline Args: dataset_path (str) input_size (int) batch_size (int) num_workers (int) train_portion (float) Ret...
31.055556
106
0.677996
def get_{{customize_name}}_dataloader(dataset_path, input_size, batch_size, num_workers, train_portion=1): """ Prepare dataset for training and evaluating pipeline Args: dataset_path (str) input_size (int) batch_size (int) num_workers (int) train_portion (float) Ret...
0
0
0
0
0
0
0
0
0
57545d4d70a3fea7ce2a0c2f331ce63b7f48d850
831
py
Python
day10/app10/urls.py
940716tian/PythonStudy
05738c50c9d504d5f073ded9e70b29c2f76f5ea6
[ "Apache-2.0" ]
null
null
null
day10/app10/urls.py
940716tian/PythonStudy
05738c50c9d504d5f073ded9e70b29c2f76f5ea6
[ "Apache-2.0" ]
null
null
null
day10/app10/urls.py
940716tian/PythonStudy
05738c50c9d504d5f073ded9e70b29c2f76f5ea6
[ "Apache-2.0" ]
null
null
null
from django.conf.urls import url urlpatterns = [ url(r"^home$",home,name="home"), url(r"^market$",market,name="market"), url(r"^cart$",cart,name="cart"), url(r"mine$",mine,name="mine"), url(r"market_with_params/(\d+)/(\d+)/(\d+)",market_with_params,name="market_params"), url(r"register$...
37.772727
90
0.624549
from django.conf.urls import url from .views import * urlpatterns = [ url(r"^home$",home,name="home"), url(r"^market$",market,name="market"), url(r"^cart$",cart,name="cart"), url(r"mine$",mine,name="mine"), url(r"market_with_params/(\d+)/(\d+)/(\d+)",market_with_params,name="market_params")...
0
0
0
0
0
0
0
-1
23
c42143022aed6c419e9c5d0f5f8056c62b6dd61d
19,018
py
Python
sdk/packages/object_pose_estimation/apps/pose_cnn_decoder/evaluation/pose_cask_evaluation.py
ddr95070/RMIsaac
ee3918f685f0a88563248ddea11d089581077973
[ "FSFAP" ]
null
null
null
sdk/packages/object_pose_estimation/apps/pose_cnn_decoder/evaluation/pose_cask_evaluation.py
ddr95070/RMIsaac
ee3918f685f0a88563248ddea11d089581077973
[ "FSFAP" ]
null
null
null
sdk/packages/object_pose_estimation/apps/pose_cnn_decoder/evaluation/pose_cask_evaluation.py
ddr95070/RMIsaac
ee3918f685f0a88563248ddea11d089581077973
[ "FSFAP" ]
1
2022-01-28T16:37:51.000Z
2022-01-28T16:37:51.000Z
''' Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved. NVIDIA CORPORATION and its licensors retain all intellectual property and proprietary rights in and to this software, related documentation and any modifications thereto. Any use, reproduction, disclosure or distribution of this software and related docu...
46.727273
100
0.658429
''' Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved. NVIDIA CORPORATION and its licensors retain all intellectual property and proprietary rights in and to this software, related documentation and any modifications thereto. Any use, reproduction, disclosure or distribution of this software and related docu...
0
0
0
0
0
0
0
10
44
54a1f4a760ebb5dad472c36e509ec9b223912779
232
py
Python
___Python/Carsten/p03_lambda/m01_filtern.py
uvenil/PythonKurs201806
85afa9c9515f5dd8bec0c546f077d8cc39568fe8
[ "Apache-2.0" ]
null
null
null
___Python/Carsten/p03_lambda/m01_filtern.py
uvenil/PythonKurs201806
85afa9c9515f5dd8bec0c546f077d8cc39568fe8
[ "Apache-2.0" ]
null
null
null
___Python/Carsten/p03_lambda/m01_filtern.py
uvenil/PythonKurs201806
85afa9c9515f5dd8bec0c546f077d8cc39568fe8
[ "Apache-2.0" ]
null
null
null
celsius = [0.7, 2.1, 4.2, 8.2, 12.5, 15.6, 16.9, 16.3, 13.6, 9.5, 4.6, 2.3] # Alle Temperaturen grer gleich 15 gefiltert = [] for month in celsius: if month >= 15: gefiltert.append(month) print(gefiltert)
21.090909
76
0.581897
celsius = [0.7, 2.1, 4.2, 8.2, 12.5, 15.6, 16.9, 16.3, 13.6, 9.5, 4.6, 2.3] # Alle Temperaturen größer gleich 15 gefiltert = [] for month in celsius: if month >= 15: gefiltert.append(month) print(gefiltert)
4
0
0
0
0
0
0
0
0
e0d63a592719e3bfbdfa029d548db56ac17c014c
2,982
py
Python
conkit/applications/__init__.py
fsimkovic/cptbx
9888e40caa1720a9905c551b963ffd4f99f9c913
[ "BSD-3-Clause" ]
2
2016-10-05T09:00:24.000Z
2016-10-05T21:12:15.000Z
conkit/applications/__init__.py
fsimkovic/cptbx
9888e40caa1720a9905c551b963ffd4f99f9c913
[ "BSD-3-Clause" ]
null
null
null
conkit/applications/__init__.py
fsimkovic/cptbx
9888e40caa1720a9905c551b963ffd4f99f9c913
[ "BSD-3-Clause" ]
null
null
null
# coding=utf-8 # # BSD 3-Clause License # # Copyright (c) 2016-21, University of Liverpool # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the abov...
35.082353
80
0.774648
# coding=utf-8 # # BSD 3-Clause License # # Copyright (c) 2016-21, University of Liverpool # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the abov...
0
0
0
0
0
1,057
0
0
184
2e7e173f1ec3e3d3bb2b15aeffbbdf342189a27d
18,609
py
Python
deepcell/model_zoo/fpn.py
jackstellwagen/deepcell-tf
d9326b8aceb2f25637e0d3934646da8f6a9f9539
[ "Apache-2.0" ]
null
null
null
deepcell/model_zoo/fpn.py
jackstellwagen/deepcell-tf
d9326b8aceb2f25637e0d3934646da8f6a9f9539
[ "Apache-2.0" ]
null
null
null
deepcell/model_zoo/fpn.py
jackstellwagen/deepcell-tf
d9326b8aceb2f25637e0d3934646da8f6a9f9539
[ "Apache-2.0" ]
null
null
null
# Copyright 2016-2019 The Van Valen Lab at the California Institute of # Technology (Caltech), with support from the Paul Allen Family Foundation, # Google, & National Institutes of Health (NIH) under Grant U24CA224309-01. # All rights reserved. # # Licensed under a modified Apache License, Version 2.0 (the "License");...
39.259494
96
0.62631
# Copyright 2016-2019 The Van Valen Lab at the California Institute of # Technology (Caltech), with support from the Paul Allen Family Foundation, # Google, & National Institutes of Health (NIH) under Grant U24CA224309-01. # All rights reserved. # # Licensed under a modified Apache License, Version 2.0 (the "License");...
0
0
0
0
0
0
0
29
22
b443c8019cb14c7586860bc3a599b7c177dbe167
3,638
py
Python
dns_client.py
soerenschneider/dyndns-updater
6990a8c2ab4f8dab97ec280839aa64c95f489445
[ "Apache-2.0" ]
null
null
null
dns_client.py
soerenschneider/dyndns-updater
6990a8c2ab4f8dab97ec280839aa64c95f489445
[ "Apache-2.0" ]
null
null
null
dns_client.py
soerenschneider/dyndns-updater
6990a8c2ab4f8dab97ec280839aa64c95f489445
[ "Apache-2.0" ]
null
null
null
import logging from inspect import getmembers, isfunction import configargparse import ipv4_providers from dyndns_updater import UpdateDetector from notifier import UpdateNotifier from persistence import FilePersistence def read_config(): """ Parse CLI args. """ parser = configargparse.ArgumentParser(prog='...
37.895833
248
0.711105
import logging from inspect import getmembers, isfunction import configargparse import ipv4_providers from prometheus_client import start_http_server from dyndns_updater import UpdateDetector from notifier import UpdateNotifier from persistence import FilePersistence def read_config(): """ Parse CLI args. """ ...
0
0
0
0
0
226
0
26
46
8902c7a32f03c47cdc50690d08dd869bec933e3f
10,580
py
Python
DeepNN_Hardcoded.py
dimitrispapaconstantinou/CourseraDeepLearningSimpleExample
3c8b2d88e73a1105d0068371a7463c1370802f04
[ "MIT" ]
null
null
null
DeepNN_Hardcoded.py
dimitrispapaconstantinou/CourseraDeepLearningSimpleExample
3c8b2d88e73a1105d0068371a7463c1370802f04
[ "MIT" ]
null
null
null
DeepNN_Hardcoded.py
dimitrispapaconstantinou/CourseraDeepLearningSimpleExample
3c8b2d88e73a1105d0068371a7463c1370802f04
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Wed Oct 18 17:29:22 2017 @author: dimitris """ import numpy as np np.random.seed(1) #################################### ##############################3 train_x_orig, train_y, test_x_orig, test_y, classes = load_data() # Reshape the training and tes...
23.563474
127
0.535161
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Wed Oct 18 17:29:22 2017 @author: dimitris """ import numpy as np import h5py np.random.seed(1) def load_data(): train_dataset = h5py.File('datasets/train_catvnoncat.h5', "r") train_set_x_orig = np.array(train_dataset["train_set_x"][:]) # you...
0
0
0
0
0
9,309
0
-10
237
49a12ff8af9218f00db66b5316abb1027675b424
627
py
Python
sst/syntax/token.py
whitegreyblack/sst
e63b8c18080fb6434f0371771d3f2dd184f7970b
[ "MIT" ]
null
null
null
sst/syntax/token.py
whitegreyblack/sst
e63b8c18080fb6434f0371771d3f2dd184f7970b
[ "MIT" ]
null
null
null
sst/syntax/token.py
whitegreyblack/sst
e63b8c18080fb6434f0371771d3f2dd184f7970b
[ "MIT" ]
null
null
null
# token.py """ Holds different grammar and syntax token classes """ # regexes from library to recognize numbers op_token_types = { '.': 'DOT', '..': 'RANGE_INCL', '...': 'RANGE_EXCL', '-': 'MINUS', '+': 'PLUS', '->': 'RARROW' } if __name__ == "__main__": print(Token('->', op_token_types....
17.914286
67
0.61563
# token.py """ Holds different grammar and syntax token classes """ # regexes from library to recognize numbers from tokenize import Floatnumber, Intnumber, Name, group, _compile from dataclasses import dataclass as struct from dataclasses import field class TokenType: OP = 'OP' NAME = 'NAME' NUMBER = '...
0
27
0
65
0
0
0
75
113
adf5e2d6e082ba08f6fa510fd875c6c47396cc89
47
py
Python
tests/__init__.py
inecik/bioidtracker
b82493435ec561131c20498c629bfac953f71eb0
[ "MIT" ]
null
null
null
tests/__init__.py
inecik/bioidtracker
b82493435ec561131c20498c629bfac953f71eb0
[ "MIT" ]
15
2022-03-02T13:33:11.000Z
2022-03-28T12:28:23.000Z
tests/__init__.py
inecik/bioidtracker
b82493435ec561131c20498c629bfac953f71eb0
[ "MIT" ]
null
null
null
"""Test suite for the bioidtracker package."""
23.5
46
0.723404
"""Test suite for the bioidtracker package."""
0
0
0
0
0
0
0
0
0
3a8991d33852366bb4f1fb87e46705e7c02f7e12
1,975
py
Python
webApp/webApp.py
NanoBreeze/Short-Fun-Python-Projects
67e0d40d60073f81a645c0ccff70d236ff651450
[ "MIT" ]
null
null
null
webApp/webApp.py
NanoBreeze/Short-Fun-Python-Projects
67e0d40d60073f81a645c0ccff70d236ff651450
[ "MIT" ]
null
null
null
webApp/webApp.py
NanoBreeze/Short-Fun-Python-Projects
67e0d40d60073f81a645c0ccff70d236ff651450
[ "MIT" ]
null
null
null
''' Copyright 2017 Linyi Cheng Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublic...
42.934783
460
0.748861
''' Copyright 2017 Linyi Cheng Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublic...
0
566
0
0
0
0
0
16
245
a8569f6f4f626d00398db23748558b3fe6bba68e
264
py
Python
fritzconnection/__init__.py
funami-dev/fritzconnection
5525fce72219094108b28b50426e742010a51a57
[ "MIT" ]
2
2016-11-14T18:58:56.000Z
2021-03-12T10:15:03.000Z
fritzconnection/__init__.py
funami-dev/fritzconnection
5525fce72219094108b28b50426e742010a51a57
[ "MIT" ]
2
2015-12-09T20:12:08.000Z
2016-11-02T15:03:19.000Z
fritzconnection/__init__.py
deisi/fritzconnection
b5c14515e1c8e2652b06b6316a7f3913df942841
[ "MIT" ]
7
2016-10-02T18:37:20.000Z
2021-09-14T21:29:28.000Z
# -*- coding: utf-8 -*-
15.529412
30
0.670455
# -*- coding: utf-8 -*- from .fritzconnection import ( FritzConnection, FritzInspection, print_servicenames, print_api, ) from .fritzhosts import ( FritzHosts, print_hosts, ) from .fritzstatus import ( FritzStatus, print_status, )
0
0
0
0
0
0
0
173
67
2026f1296b094f94ec3138ccecb974b042554d90
10,495
py
Python
post-nonlinear_multiview_learning_demo.py
llvqi/post-nonlinear_multiview_learning
8a49e3fa97d793ea4da156759fc02556a1104bb1
[ "Apache-2.0" ]
null
null
null
post-nonlinear_multiview_learning_demo.py
llvqi/post-nonlinear_multiview_learning
8a49e3fa97d793ea4da156759fc02556a1104bb1
[ "Apache-2.0" ]
null
null
null
post-nonlinear_multiview_learning_demo.py
llvqi/post-nonlinear_multiview_learning
8a49e3fa97d793ea4da156759fc02556a1104bb1
[ "Apache-2.0" ]
null
null
null
from __future__ import print_function import sys import torch # Argument parser # Post-Nonlinear Multiview Model # Loss function # Training function # Normalize for better visualization # Dataset class if __name__ == "__main__": main(sys.argv[1:])
30.071633
137
0.590091
from __future__ import print_function import argparse import sys import torch import torch.utils.data from torch import nn, optim from torch.nn import functional as F import scipy.io as sio import numpy as np from torch.utils.data.dataset import Dataset import matplotlib.pyplot as plt import matplotlib import scipy.lin...
0
0
0
3,062
0
6,746
0
51
375
03f71867c1e74a3d34f3bf0be56a576359515c7d
1,231
py
Python
legacy/example_processing.py
smgim/kiltsnielsen
bf8a66f7765c998f8dfecf350f0c307c66889bbe
[ "MIT" ]
30
2019-12-17T20:32:54.000Z
2022-03-06T01:51:29.000Z
legacy/example_processing.py
smgim/kiltsnielsen
bf8a66f7765c998f8dfecf350f0c307c66889bbe
[ "MIT" ]
null
null
null
legacy/example_processing.py
smgim/kiltsnielsen
bf8a66f7765c998f8dfecf350f0c307c66889bbe
[ "MIT" ]
12
2019-12-30T23:38:39.000Z
2021-12-09T02:58:59.000Z
import os # import the nielsenreader import nielsenreader as nielsen from nielsenreader import read_all_data_new # where to read and write from read_dir = os.path.abspath(os.path.expanduser('~') + '/Cereal/') outfile=read_dir+'/raw-cereal-all' # Specify which dmas /modules /columns to keep dmas=[506,517,556, 602, 75...
41.033333
122
0.766044
import sys,os # import the nielsenreader import nielsenreader as nielsen from nielsenreader import read_all_data_new # where to read and write from read_dir = os.path.abspath(os.path.expanduser('~') + '/Cereal/') outfile=read_dir+'/raw-cereal-all' # Specify which dmas /modules /columns to keep dmas=[506,517,556, 602...
0
0
0
0
0
158
0
4
22
a123f1ad90cd814bdc34b97927becd9614fe7438
654
py
Python
QuantitativeSkillsForBusiness_FinalProject/Task4_WorkTogether.py
syedwaleedhyder/Freelance_Projects
7e2b85fc968850fc018014667b5ce9af0f00cb09
[ "MIT" ]
1
2020-08-13T17:26:13.000Z
2020-08-13T17:26:13.000Z
QuantitativeSkillsForBusiness_FinalProject/Task4_WorkTogether.py
syedwaleedhyder/Freelance_Projects
7e2b85fc968850fc018014667b5ce9af0f00cb09
[ "MIT" ]
null
null
null
QuantitativeSkillsForBusiness_FinalProject/Task4_WorkTogether.py
syedwaleedhyder/Freelance_Projects
7e2b85fc968850fc018014667b5ce9af0f00cb09
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Sat Apr 20 23:39:43 2019 @author: Syed Waleed Hyder """ timeA = int(input("Enter hours for Person A completes the task: ")) timeB = int(input("Enter hours for Person B completes the task: ")) print("Person A completes the task in {} hours".format(timeA)) print("Person B complet...
29.727273
72
0.697248
# -*- coding: utf-8 -*- """ Created on Sat Apr 20 23:39:43 2019 @author: Syed Waleed Hyder """ def time_work_together(timeA, timeB): rateA = 1/timeA rateB = 1/timeB rate_total = rateA + rateB time_total = 1/rate_total return time_total timeA = int(input("Enter hours for Person A completes th...
0
0
0
0
0
144
0
0
23
317264227fc12845ffd0995ac6c71d0c11173927
1,670
py
Python
uasyncio_iostream/v3/primitives/condition.py
petrkr/micropython-samples
7429834c6967579f7de8dd2fe0cd9515a3ff3d09
[ "MIT" ]
1
2020-11-06T20:26:18.000Z
2020-11-06T20:26:18.000Z
uasyncio_iostream/v3/primitives/condition.py
aivarannamaa/micropython-samples
7004aa7370d847e6de179b84f9accb1c917ca1b0
[ "MIT" ]
null
null
null
uasyncio_iostream/v3/primitives/condition.py
aivarannamaa/micropython-samples
7004aa7370d847e6de179b84f9accb1c917ca1b0
[ "MIT" ]
null
null
null
try: import uasyncio as asyncio except ImportError: # Condition class # from primitives.condition import Condition
26.09375
74
0.608982
try: import uasyncio as asyncio except ImportError: import asyncio # Condition class # from primitives.condition import Condition class Condition(): def __init__(self, lock=None): self.lock = asyncio.Lock() if lock is None else lock self.events = [] async def acquire(self): aw...
0
0
561
947
0
0
0
-7
49
611a52dc646632fd1c60995e79510e90c7580a9e
37,612
py
Python
SubredditBirthdays/sb.py
voussoir/redd
8f49d735f8e204c4e71efaf7fa08cc6ff9ff6f1b
[ "BSD-3-Clause" ]
444
2015-01-04T02:31:53.000Z
2022-03-22T05:57:08.000Z
SubredditBirthdays/sb.py
voussoir/redd
8f49d735f8e204c4e71efaf7fa08cc6ff9ff6f1b
[ "BSD-3-Clause" ]
12
2015-05-21T07:56:59.000Z
2020-02-18T06:26:39.000Z
SubredditBirthdays/sb.py
voussoir/redd
8f49d735f8e204c4e71efaf7fa08cc6ff9ff6f1b
[ "BSD-3-Clause" ]
199
2015-01-02T14:14:07.000Z
2022-02-12T14:00:09.000Z
import praw3 as praw import random import sqlite3 import string import sys import tkinter import traceback import types from voussoirkit import betterhelp from voussoirkit import mutables from voussoirkit import sqlhelpers from voussoirkit import vlogging log = vlogging.getLogger(__name__, 'sb') USERAGENT = ''' /u/G...
32.480138
129
0.595528
import argparse import bot3 import datetime import praw3 as praw import random import sqlite3 import string import subprocess import sys import time import tkinter import traceback import types from voussoirkit import betterhelp from voussoirkit import mutables from voussoirkit import operatornotify from voussoirkit i...
0
882
0
0
114
16,986
0
-8
774
d5732dc007ce9fa0dc6682aa687b1a9146ea9f49
355
py
Python
blog/migrations/0003_rename_capture_tag_caption.py
MalYou/my_site
8a3d7fdad5d47029f69724e2f324a836d0bc2e53
[ "MIT" ]
null
null
null
blog/migrations/0003_rename_capture_tag_caption.py
MalYou/my_site
8a3d7fdad5d47029f69724e2f324a836d0bc2e53
[ "MIT" ]
null
null
null
blog/migrations/0003_rename_capture_tag_caption.py
MalYou/my_site
8a3d7fdad5d47029f69724e2f324a836d0bc2e53
[ "MIT" ]
null
null
null
# Generated by Django 3.2.3 on 2021-05-16 17:47
18.684211
47
0.574648
# Generated by Django 3.2.3 on 2021-05-16 17:47 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('blog', '0002_post_image_url'), ] operations = [ migrations.RenameField( model_name='tag', old_name='capture', ne...
0
0
0
249
0
0
0
11
46
671b1539695d85543789c2fee3da16aad877ac2c
2,950
py
Python
src/build/android/gyp/dex_jdk_libs.py
goochen/naiveproxy
1d0682ee5bae6e648cd43c65f49b4eefd224f206
[ "BSD-3-Clause" ]
1
2020-06-02T02:28:34.000Z
2020-06-02T02:28:34.000Z
src/build/android/gyp/dex_jdk_libs.py
goochen/naiveproxy
1d0682ee5bae6e648cd43c65f49b4eefd224f206
[ "BSD-3-Clause" ]
null
null
null
src/build/android/gyp/dex_jdk_libs.py
goochen/naiveproxy
1d0682ee5bae6e648cd43c65f49b4eefd224f206
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # # Copyright 2020 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 if __name__ == '__main__': main(sys.argv[1:])
32.777778
80
0.665085
#!/usr/bin/env python # # Copyright 2020 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 argparse import os import shutil import subprocess import sys import zipfile from util import build_utils def _ParseArgs(ar...
0
0
0
0
0
2,527
0
-30
203
f9c5850755fb3fe09094c926860c114599f2c355
4,601
py
Python
src/data/feature_att_model.py
tkrollins/question-answering
f42cc53ebe1691ea5901bdcfb64b72e6fe5e3535
[ "MIT" ]
null
null
null
src/data/feature_att_model.py
tkrollins/question-answering
f42cc53ebe1691ea5901bdcfb64b72e6fe5e3535
[ "MIT" ]
4
2021-06-02T04:06:15.000Z
2022-02-10T05:06:23.000Z
src/data/feature_att_model.py
tkrollins/question-answering
f42cc53ebe1691ea5901bdcfb64b72e6fe5e3535
[ "MIT" ]
null
null
null
import tensorflow as tf from data_generator import DataGenerator import argparse as ap from AttentionLayer import Attention parser = ap.ArgumentParser() parser.add_argument('--train_data', type=str, default="data/interim/SQuAD-v1.1-train_sBERT_embeddings-T.json") parser.add_argument('--val_data', type=str, default="d...
44.669903
177
0.752662
import tensorflow as tf import numpy as np from data_generator import DataGenerator import argparse as ap from AttentionLayer import Attention parser = ap.ArgumentParser() parser.add_argument('--train_data', type=str, default="data/interim/SQuAD-v1.1-train_sBERT_embeddings-T.json") parser.add_argument('--val_data', t...
0
0
0
0
57
0
0
-3
45
996622890e578d66f6f0a471c42163eff697d806
131
py
Python
components/micropython/modules/backup/disobey_bak/_boot.py
badgeteam/Firmware
6192b2902c70beb7a298a256d9087274d045fbc0
[ "Apache-2.0" ]
7
2019-02-11T10:02:14.000Z
2019-08-02T00:08:45.000Z
components/micropython/modules/backup/disobey_bak/_boot.py
badgeteam/Firmware
6192b2902c70beb7a298a256d9087274d045fbc0
[ "Apache-2.0" ]
17
2019-01-05T18:02:11.000Z
2019-03-09T21:46:43.000Z
components/micropython/modules/backup/disobey_bak/_boot.py
badgeteam/Firmware
6192b2902c70beb7a298a256d9087274d045fbc0
[ "Apache-2.0" ]
4
2019-02-15T16:03:20.000Z
2019-06-27T22:23:24.000Z
import badge, gc, uos badge.mount_root() uos.mount(uos.VfsNative(None), '/') try: uos.mkdir('/lib') except: pass gc.collect()
10.916667
35
0.671756
import badge, gc, uos badge.mount_root() uos.mount(uos.VfsNative(None), '/') try: uos.mkdir('/lib') except: pass gc.collect()
0
0
0
0
0
0
0
0
0
813a8ce209fa6c27b191963bd6e67321e4277566
10,579
py
Python
secure_message/common/utilities.py
uk-gov-mirror/ONSdigital.ras-secure-message
741eed651eea47dd1a13c7c93b1b1796584cdf2b
[ "MIT" ]
null
null
null
secure_message/common/utilities.py
uk-gov-mirror/ONSdigital.ras-secure-message
741eed651eea47dd1a13c7c93b1b1796584cdf2b
[ "MIT" ]
null
null
null
secure_message/common/utilities.py
uk-gov-mirror/ONSdigital.ras-secure-message
741eed651eea47dd1a13c7c93b1b1796584cdf2b
[ "MIT" ]
null
null
null
import collections import logging from structlog import wrap_logger from secure_message.constants import MESSAGE_BY_ID_ENDPOINT, MESSAGE_LIST_ENDPOINT, MESSAGE_QUERY_LIMIT from secure_message.services.service_toggles import party, internal_user_service logger = wrap_logger(logging.getLogger(__name__)) MessageArgs = ...
43.714876
154
0.680121
import collections import logging import urllib.parse from structlog import wrap_logger from secure_message.constants import MESSAGE_BY_ID_ENDPOINT, MESSAGE_LIST_ENDPOINT, MESSAGE_QUERY_LIMIT from secure_message.services.service_toggles import party, internal_user_service logger = wrap_logger(logging.getLogger(__nam...
0
0
0
0
0
245
0
-2
45
baf78088b70160aa34799c9f06461e8d81e12d58
178
py
Python
NOV25/08.py
Razdeep/PythonSnippets
76f9313894f511c487a99bc38bdf0fe5e594caf5
[ "MIT" ]
null
null
null
NOV25/08.py
Razdeep/PythonSnippets
76f9313894f511c487a99bc38bdf0fe5e594caf5
[ "MIT" ]
null
null
null
NOV25/08.py
Razdeep/PythonSnippets
76f9313894f511c487a99bc38bdf0fe5e594caf5
[ "MIT" ]
null
null
null
# Count letters using a dictionary text='The quick brown fox jumped over the lazy dog' text=text.upper() counter=dict() for i in text: counter[i]=text.count(i) print(counter)
25.428571
51
0.741573
# Count letters using a dictionary text='The quick brown fox jumped over the lazy dog' text=text.upper() counter=dict() for i in text: counter[i]=text.count(i) print(counter)
0
0
0
0
0
0
0
0
0
d6a8528153909418fca062ab2e2e9edb99a0d6c4
11,536
py
Python
astrodash/classify.py
FoxFortino/adfox
6b8679b07af99418d273ae0b0bf19e043d7b590b
[ "MIT" ]
18
2018-11-06T03:09:12.000Z
2022-02-28T22:44:03.000Z
astrodash/classify.py
FoxFortino/adfox
6b8679b07af99418d273ae0b0bf19e043d7b590b
[ "MIT" ]
18
2017-01-13T00:01:52.000Z
2018-01-18T23:31:32.000Z
astrodash/classify.py
FoxFortino/adfox
6b8679b07af99418d273ae0b0bf19e043d7b590b
[ "MIT" ]
10
2018-08-22T13:31:57.000Z
2022-03-12T22:59:22.000Z
try: except ImportError: print("Warning: You will need to install 'PyQt5' if you want to use the graphical interface. " "Using the automatic library will continue to work.") # # EXAMPLE USAGE: # classification = Classify(filenames=['/Users/dmuthukrishna/Users/dmuthukrishna/DES16E1dic_E1_combined_161125...
49.724138
137
0.606189
import os import sys import pickle import numpy as np from astrodash.download_data_files import download_all_files from astrodash.restore_model import LoadInputSpectra, BestTypesListSingleRedshift, get_training_parameters, \ classification_split from astrodash.false_positive_rejection import RlapCalc, combined_prob...
0
0
0
10,373
0
0
0
311
295
2ce034f93fbcaf826375276dc9307b8587969034
398
py
Python
other/dingding/dingtalk/api/rest/OapiAttendanceListRecordRequest.py
hth945/pytest
83e2aada82a2c6a0fdd1721320e5bf8b8fd59abc
[ "Apache-2.0" ]
null
null
null
other/dingding/dingtalk/api/rest/OapiAttendanceListRecordRequest.py
hth945/pytest
83e2aada82a2c6a0fdd1721320e5bf8b8fd59abc
[ "Apache-2.0" ]
null
null
null
other/dingding/dingtalk/api/rest/OapiAttendanceListRecordRequest.py
hth945/pytest
83e2aada82a2c6a0fdd1721320e5bf8b8fd59abc
[ "Apache-2.0" ]
null
null
null
''' Created by auto_sdk on 2020.07.28 '''
22.111111
47
0.753769
''' Created by auto_sdk on 2020.07.28 ''' from dingtalk.api.base import RestApi class OapiAttendanceListRecordRequest(RestApi): def __init__(self,url=None): RestApi.__init__(self,url) self.checkDateFrom = None self.checkDateTo = None self.isI18n = None self.userIds = None def getHttpMethod(self): return ...
0
0
0
296
0
0
0
16
44
3d68a0b806c83b7e3fd20bdea158e88c24fc0d3b
429
py
Python
shapes/try.py
Danil-Grigorev/swagger-marshmallow-codegen
4c077f6e1ef535bcbdbf1f643f97bc4cbc62c0e8
[ "MIT" ]
49
2017-02-05T17:32:18.000Z
2022-01-30T13:20:22.000Z
shapes/try.py
Danil-Grigorev/swagger-marshmallow-codegen
4c077f6e1ef535bcbdbf1f643f97bc4cbc62c0e8
[ "MIT" ]
62
2016-12-27T15:38:28.000Z
2021-09-30T02:47:00.000Z
shapes/try.py
Danil-Grigorev/swagger-marshmallow-codegen
4c077f6e1ef535bcbdbf1f643f97bc4cbc62c0e8
[ "MIT" ]
10
2017-07-19T12:38:25.000Z
2020-04-07T09:11:22.000Z
from __future__ import annotations import typing as t if t.TYPE_CHECKING: if __name__ == "__main__": from swagger_marshmallow_codegen.cmd import main main(setup)
23.833333
59
0.757576
from __future__ import annotations import typing as t if t.TYPE_CHECKING: from swagger_marshmallow_codegen.driver import Driver def setup(driver: Driver) -> None: driver.config["additional_properties_default"] = False driver.config["emit_schema_even_primitive_type"] = True driver.config["header_comme...
0
0
0
0
0
173
0
32
49
1b5a79a6bdb6c77177f046f3393e1facf0933a88
1,589
py
Python
goldwater/apply_model.py
wenkokke/UoE-MT3-NMT
242a4d8221f8a0462c5c23c057d954e18c88fc34
[ "MIT" ]
null
null
null
goldwater/apply_model.py
wenkokke/UoE-MT3-NMT
242a4d8221f8a0462c5c23c057d954e18c88fc34
[ "MIT" ]
null
null
null
goldwater/apply_model.py
wenkokke/UoE-MT3-NMT
242a4d8221f8a0462c5c23c057d954e18c88fc34
[ "MIT" ]
null
null
null
# coding: utf-8 # In[4]: import getopt import sys # In[2]: # In[5]: if __name__ == "__main__": try: opts,args = getopt.getopt(sys.argv[1:],'i:o:m:',['input','output','model']) except getopt.GetoptError as err: # print help information and exit: print(err) # will print something l...
23.716418
83
0.557583
# coding: utf-8 # In[4]: import getopt import itertools import json import sys # In[2]: def apply_model(model_file,data_file_in,data_file_out): with open(model_file, 'r') as model_file: model = json.load(model_file) with open(data_file_in, 'r') as text_raw: text_raw = text_ra...
0
0
0
0
0
702
0
-15
90
51f54ed53d19bf28a34d7ac214fa4a40f2222ac8
1,396
py
Python
setup.py
antoinecarme/pdf_to_json
b04b264738de3207248eaa17897fc276d19ad663
[ "BSD-3-Clause" ]
null
null
null
setup.py
antoinecarme/pdf_to_json
b04b264738de3207248eaa17897fc276d19ad663
[ "BSD-3-Clause" ]
null
null
null
setup.py
antoinecarme/pdf_to_json
b04b264738de3207248eaa17897fc276d19ad663
[ "BSD-3-Clause" ]
null
null
null
from setuptools import setup from setuptools import find_packages long_description = ''' Python module to Convert a PDF file to a JSON format The goal is to be able to quickly extract all the available information in the document to a python dictionay. The dictionay can then be stored in a database or a csv file (fo...
38.777778
214
0.695559
from setuptools import setup from setuptools import find_packages long_description = ''' Python module to Convert a PDF file to a JSON format The goal is to be able to quickly extract all the available information in the document to a python dictionay. The dictionay can then be stored in a database or a csv file (fo...
0
0
0
0
0
0
0
0
0
fd2254ab7aa532b6e882a6587a7bcdbe9a2dbcbe
7,420
py
Python
bob/bio/base/script/commands.py
bioidiap/bob.bio.base
44b8d192e957eb328591c8110cf0113f602292ef
[ "BSD-3-Clause" ]
16
2016-04-06T20:37:55.000Z
2019-10-19T08:06:25.000Z
bob/bio/base/script/commands.py
bioidiap/bob.bio.base
44b8d192e957eb328591c8110cf0113f602292ef
[ "BSD-3-Clause" ]
25
2015-07-04T17:41:40.000Z
2016-08-08T20:36:01.000Z
bob/bio/base/script/commands.py
bioidiap/bob.bio.base
44b8d192e957eb328591c8110cf0113f602292ef
[ "BSD-3-Clause" ]
7
2015-08-07T17:21:02.000Z
2018-08-13T15:51:54.000Z
""" Click commands for ``bob.bio.base`` """ SCORE_FORMAT = ( "Files must be 4- or 5- columns format, see " ":py:func:`bob.bio.base.score.load.four_column` and " ":py:func:`bob.bio.base.score.load.five_column` for details." ) CRITERIA = ("eer", "min-hter", "far", "mindcf", "cllr", "rr") def rank_option(*...
34.193548
96
0.707547
""" Click commands for ``bob.bio.base`` """ import click from . import figure as bio_figure from bob.bio.base.score import iscsv import bob.measure.script.figure as measure_figure from ..score import load from bob.measure.script import common_options from bob.extension.scripts.click_helper import verbosity_option SC...
0
6,077
0
0
0
427
0
117
389
3abe0503b1dc9fd70145726a2b1bdce575e6e1da
2,838
py
Python
store/function.py
Soemonewho2/pi-ware
86d2cd84ca85e36cbcdbc7511f6a4565b18e81d9
[ "MIT" ]
null
null
null
store/function.py
Soemonewho2/pi-ware
86d2cd84ca85e36cbcdbc7511f6a4565b18e81d9
[ "MIT" ]
null
null
null
store/function.py
Soemonewho2/pi-ware
86d2cd84ca85e36cbcdbc7511f6a4565b18e81d9
[ "MIT" ]
null
null
null
#Import modules #Variables #window = tk.Tk() # Window tabs #tab_control = Notebook(window) #apps_tab = Frame(tab_control) #tree = Treeview(apps_tab) #Functions
33.785714
147
0.668781
#Import modules from tkinter import * from tkinter.ttk import * import tkinter as tk #Variables #window = tk.Tk() # Window tabs #tab_control = Notebook(window) #apps_tab = Frame(tab_control) #tree = Treeview(apps_tab) #Functions def show_desc(apt,*args): item = tree.selection()[0] app = tree.item(item,"text")...
0
0
0
0
0
2,470
0
3
203
9d03e612a5795ce3b2d3a41b33dd7c7b04d6d246
2,583
py
Python
data-processor/src/quality_measurement/__main__.py
cns-iu/map4sci
f7d7901f7a0e058067f56b1aa65c46491b7970a5
[ "MIT" ]
2
2019-02-27T20:24:54.000Z
2020-07-08T16:27:22.000Z
data-processor/src/quality_measurement/__main__.py
cns-iu/map4sci
f7d7901f7a0e058067f56b1aa65c46491b7970a5
[ "MIT" ]
44
2021-02-01T17:48:08.000Z
2022-03-04T13:47:39.000Z
data-processor/src/quality_measurement/__main__.py
cns-iu/map4sci
f7d7901f7a0e058067f56b1aa65c46491b7970a5
[ "MIT" ]
null
null
null
import argparse import subprocess def run_original(args: argparse.Namespace) -> None: """Runs quality measurements using the original algorithms. Parameters ---------- args : argparse.Namespace Metrics configuration arguments. """ metrics = [] if args.crossings: metrics.ap...
34.44
85
0.61866
import argparse import subprocess def run_original(args: argparse.Namespace) -> None: """Runs quality measurements using the original algorithms. Parameters ---------- args : argparse.Namespace Metrics configuration arguments. """ metrics = [] if args.crossings: metrics.ap...
0
0
0
0
0
0
0
0
0
978acaf152750fb62a004b7c18f7d798c2f7e1b9
172
py
Python
plugin/src/test/resources/quickFixes/AddMethodQuickFixTest/addMethodFromMethod_after.py
consulo/consulo-python
586c3eaee3f9c2cc87fb088dc81fb12ffa4b3a9d
[ "Apache-2.0" ]
null
null
null
plugin/src/test/resources/quickFixes/AddMethodQuickFixTest/addMethodFromMethod_after.py
consulo/consulo-python
586c3eaee3f9c2cc87fb088dc81fb12ffa4b3a9d
[ "Apache-2.0" ]
11
2017-02-27T22:35:32.000Z
2021-12-24T08:07:40.000Z
plugin/src/test/resources/quickFixes/AddMethodQuickFixTest/addMethodFromMethod_after.py
consulo/consulo-python
586c3eaee3f9c2cc87fb088dc81fb12ffa4b3a9d
[ "Apache-2.0" ]
null
null
null
# Some comment
11.466667
26
0.488372
class A: def __init__(self): self.x = 1 def foo(self, a): self.y(1, a) def y(self, param, a): pass # Some comment class B: pass
0
0
0
111
0
0
0
0
45
d91b5be27903aa4cfbb523d65b4c0612b875fffc
1,707
py
Python
mezzanine_events/forms.py
unplugstudio/mezzanine-calendar
5338741cf74502ccb791e02fddc520ad29472af5
[ "MIT" ]
null
null
null
mezzanine_events/forms.py
unplugstudio/mezzanine-calendar
5338741cf74502ccb791e02fddc520ad29472af5
[ "MIT" ]
null
null
null
mezzanine_events/forms.py
unplugstudio/mezzanine-calendar
5338741cf74502ccb791e02fddc520ad29472af5
[ "MIT" ]
null
null
null
from __future__ import absolute_import, unicode_literals
29.431034
81
0.654364
from __future__ import absolute_import, unicode_literals from django import forms from .models import EventCategory from .utils import today class GridFilterForm(forms.Form): """ Collection of fields to filter EventDateTimes in the grid view. """ categories = forms.ModelMultipleChoiceField( ...
0
0
0
1,516
0
0
0
18
114
d88aa5bb30b70a1910dde85035f809c2d7aa4561
1,946
py
Python
basic_samples/SDS/Python/SDSPy/Python2/DataviewQueryQuery.py
hanhossain/OCS-Samples
6f0f7878e6d9bccc32b6d663446678e070859d14
[ "Apache-2.0" ]
null
null
null
basic_samples/SDS/Python/SDSPy/Python2/DataviewQueryQuery.py
hanhossain/OCS-Samples
6f0f7878e6d9bccc32b6d663446678e070859d14
[ "Apache-2.0" ]
null
null
null
basic_samples/SDS/Python/SDSPy/Python2/DataviewQueryQuery.py
hanhossain/OCS-Samples
6f0f7878e6d9bccc32b6d663446678e070859d14
[ "Apache-2.0" ]
null
null
null
# DataviewQueryQuery.py # # Copyright (C) 2018 OSIsoft, LLC. All rights reserved. # # THIS SOFTWARE CONTAINS CONFIDENTIAL INFORMATION AND TRADE SECRETS OF # OSIsoft, LLC. USE, DISCLOSURE, OR REPRODUCTION IS PROHIBITED WITHOUT # THE PRIOR EXPRESS WRITTEN PERMISSION OF OSIsoft, LLC. # # RESTRICTED RIGHTS LEGEND # Use, d...
25.605263
92
0.659301
# DataviewQueryQuery.py # # Copyright (C) 2018 OSIsoft, LLC. All rights reserved. # # THIS SOFTWARE CONTAINS CONFIDENTIAL INFORMATION AND TRADE SECRETS OF # OSIsoft, LLC. USE, DISCLOSURE, OR REPRODUCTION IS PROHIBITED WITHOUT # THE PRIOR EXPRESS WRITTEN PERMISSION OF OSIsoft, LLC. # # RESTRICTED RIGHTS LEGEND # Use, d...
0
806
0
526
0
0
0
-10
46
353b414583ba0b3e7c4091b47d1eb5662e4c6c47
13,954
py
Python
traktor/tools_traktor/rekordbox_add_beatmarkers.py
pestrela/music
5e2b7172196c472d381d5d08062f9ff0aa6d7e66
[ "MIT" ]
33
2020-03-31T16:53:08.000Z
2022-02-20T15:01:51.000Z
traktor/tools_traktor/rekordbox_add_beatmarkers.py
pestrela/music
5e2b7172196c472d381d5d08062f9ff0aa6d7e66
[ "MIT" ]
2
2020-06-16T11:26:14.000Z
2020-06-27T10:22:26.000Z
traktor/tools_traktor/rekordbox_add_beatmarkers.py
pestrela/music
5e2b7172196c472d381d5d08062f9ff0aa6d7e66
[ "MIT" ]
7
2020-04-17T19:47:35.000Z
2021-12-21T19:55:48.000Z
#!/usr/bin/env python3 help_text=""" This program takes a Rekorxdbox XML and adds beatmarkers every 8 beats. This is useful to convert later to traktor, that lacks dynamic beatgrids """ help_text2="" import sys, os, glob, string import re # base libraries import argparse import os import ...
26.938224
154
0.622331
#!/usr/bin/env python3 help_text=""" This program takes a Rekorxdbox XML and adds beatmarkers every 8 beats. This is useful to convert later to traktor, that lacks dynamic beatgrids """ help_text2="" import sys, os, glob, string, marshal import string, re # base libraries import argparse ...
0
0
0
434
0
8,662
0
63
609
500d70cd1ddbc71e1944100357c156a9972c33f6
5,606
py
Python
app/modules/fileuploads/models.py
karenc/houston
4eaaaf11d61394035e34b55bb847ea7eb4099c61
[ "Apache-2.0" ]
null
null
null
app/modules/fileuploads/models.py
karenc/houston
4eaaaf11d61394035e34b55bb847ea7eb4099c61
[ "Apache-2.0" ]
2
2021-03-16T20:28:06.000Z
2021-03-29T15:54:11.000Z
app/modules/fileuploads/models.py
karenc/houston
4eaaaf11d61394035e34b55bb847ea7eb4099c61
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ FileUploads database models -------------------- """ import logging log = logging.getLogger(__name__)
33.975758
116
0.631823
# -*- coding: utf-8 -*- """ FileUploads database models -------------------- """ import logging import uuid import os import shutil from flask import current_app from PIL import Image from app.extensions import db, HoustonModel log = logging.getLogger(__name__) def modify_image(source_path, operation, args=(), kwa...
0
1,484
0
3,212
0
597
0
0
180
210f85818ea1cf58f68e27c3fc7586328596d928
2,152
py
Python
demoDay10-NLPAndBayes/nlp_txt/testHyj.py
mozhumz/machine_learning_py
880f6778ac16b0a16a80b31972a35304caa91dc1
[ "MulanPSL-1.0" ]
null
null
null
demoDay10-NLPAndBayes/nlp_txt/testHyj.py
mozhumz/machine_learning_py
880f6778ac16b0a16a80b31972a35304caa91dc1
[ "MulanPSL-1.0" ]
null
null
null
demoDay10-NLPAndBayes/nlp_txt/testHyj.py
mozhumz/machine_learning_py
880f6778ac16b0a16a80b31972a35304caa91dc1
[ "MulanPSL-1.0" ]
null
null
null
import re from common import common_util """ """ text = "he is good, Hello, world! ;!\?()<> "+"\sA-Za-z()%*#+-\.\\\/:=__,;""''?!<>^&{}|=" punc2=r"""~`!#$%^&*()_+-=|\'\\;":/.,?><~@#%&*+-={}!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~""" text=text+punc2 print(common_util.trim_with_space_flag(text,True)) # punctuation =punctuation+ ...
33.625
145
0.565985
import re from string import punctuation from common import common_util """ 去除中英文标点符号 """ text = "he is good, Hello, world! 这里,苹果:我;第!一个程序\?()()<>《》【】 "+"\sA-Za-z~()()【】%*#+-\.\\\/:=:__,,。、;;“”""''’‘??!!<《》>^&{}|=……" punc2=r"""~`!#$%^&*()_+-=|\'\\;":/.,?><~·!@#¥%……&*()——+-=“:’;、。,?》《{}!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~“”...
806
0
0
0
0
0
0
9
22
f494078218cef9d28eecd19bf4aac3db786cc827
2,465
py
Python
hostlist/views.py
Hasal/dzhops
fcd16adc61a941dccdaebee156b545784a5e96a8
[ "Apache-2.0" ]
202
2015-05-18T08:48:52.000Z
2021-07-16T13:59:07.000Z
hostlist/views.py
Hasal/dzhops
fcd16adc61a941dccdaebee156b545784a5e96a8
[ "Apache-2.0" ]
19
2015-11-26T03:54:45.000Z
2019-03-02T13:58:24.000Z
hostlist/views.py
Hasal/dzhops
fcd16adc61a941dccdaebee156b545784a5e96a8
[ "Apache-2.0" ]
172
2015-08-07T15:52:17.000Z
2021-07-16T13:59:11.000Z
# -*- coding: utf-8 -*- import logging log = logging.getLogger('dzhops')
25.412371
90
0.608114
# -*- coding: utf-8 -*- from django.shortcuts import render from django.http import HttpResponse, JsonResponse from django.contrib.auth.decorators import login_required from django.views.decorators.http import require_GET from hostlist.models import DzhUser, DataCenter, HostList import logging log = logging.getLogger...
123
1,588
0
0
0
433
0
146
179
dfeaad006ee38d869b894e5f5c9f501e6fa10795
644
py
Python
tests/Testing_stats_functions/test_mvtstat.py
bthirion/pyrft
275399992b23217131cad1ac094778c2745a9128
[ "MIT" ]
null
null
null
tests/Testing_stats_functions/test_mvtstat.py
bthirion/pyrft
275399992b23217131cad1ac094778c2745a9128
[ "MIT" ]
null
null
null
tests/Testing_stats_functions/test_mvtstat.py
bthirion/pyrft
275399992b23217131cad1ac094778c2745a9128
[ "MIT" ]
null
null
null
# Obtain the size of the array sD = np.shape(data) # Obtain the dimensions Dim = sD[0:-1] # Obtain the number of dimensions D = len(Dim) # Obtain the number of subjects nsubj = sD[-1] # Get the mean and stanard deviation along the number of subjects xbar = data.mean(D) # Rem...
28
89
0.650621
# Obtain the size of the array sD = np.shape(data) # Obtain the dimensions Dim = sD[0:-1] # Obtain the number of dimensions D = len(Dim) # Obtain the number of subjects nsubj = sD[-1] # Get the mean and stanard deviation along the number of subjects xbar = data.mean(D) # Rem...
0
0
0
0
0
0
0
0
0
3b3f2fc15a38bca7baf7258ff4385fabee6d9920
1,838
py
Python
refdata/error.py
Aahbree/reference-data-repository
f318c0532aaf941ec4f00c8375c9dea45c56f186
[ "MIT" ]
null
null
null
refdata/error.py
Aahbree/reference-data-repository
f318c0532aaf941ec4f00c8375c9dea45c56f186
[ "MIT" ]
5
2021-01-27T22:17:19.000Z
2021-12-14T17:13:58.000Z
refdata/error.py
Aahbree/reference-data-repository
f318c0532aaf941ec4f00c8375c9dea45c56f186
[ "MIT" ]
5
2021-12-08T02:33:44.000Z
2021-12-13T03:21:51.000Z
# This file is part of the Reference Data Repository (refdata). # # Copyright (C) 2021 New York University. # # refdata is free software; you can redistribute it and/or modify it under the # terms of the MIT License; see LICENSE file for more details. """Custom error classes raised by different components of the packa...
29.645161
78
0.642546
# This file is part of the Reference Data Repository (refdata). # # Copyright (C) 2021 New York University. # # refdata is free software; you can redistribute it and/or modify it under the # terms of the MIT License; see LICENSE file for more details. """Custom error classes raised by different components of the packa...
0
0
0
1,415
0
0
0
0
92
0cc740513cf38e5f9288b47de72890eeb2b6339d
38,763
py
Python
ops-tests/feature/acl_common_test_suite.py
learnopx/ops-classifierd
8f473be41cacf21b09b9b7d49cd0f730c1ca5fc0
[ "Apache-2.0" ]
null
null
null
ops-tests/feature/acl_common_test_suite.py
learnopx/ops-classifierd
8f473be41cacf21b09b9b7d49cd0f730c1ca5fc0
[ "Apache-2.0" ]
null
null
null
ops-tests/feature/acl_common_test_suite.py
learnopx/ops-classifierd
8f473be41cacf21b09b9b7d49cd0f730c1ca5fc0
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (C) 2016 Hewlett Packard Enterprise Development LP # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # U...
38.647059
79
0.563192
# -*- coding: utf-8 -*- # # Copyright (C) 2016 Hewlett Packard Enterprise Development LP # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # U...
0
0
0
37,699
0
0
0
204
223
bb8261416c79ab8d506ed31f7df0a002c8486c47
53
py
Python
MotunrayoKoyejo/Phase 1/Python Basic 1/Day2/Q2.py
CodedLadiesInnovateTech/-python-challenge-solutions
430cd3eb84a2905a286819eef384ee484d8eb9e7
[ "MIT" ]
6
2020-05-23T19:53:25.000Z
2021-05-08T20:21:30.000Z
MotunrayoKoyejo/Phase 1/Python Basic 1/Day2/Q2.py
CodedLadiesInnovateTech/-python-challenge-solutions
430cd3eb84a2905a286819eef384ee484d8eb9e7
[ "MIT" ]
8
2020-05-14T18:53:12.000Z
2020-07-03T00:06:20.000Z
MotunrayoKoyejo/Phase 1/Python Basic 1/Day2/Q2.py
CodedLadiesInnovateTech/-python-challenge-solutions
430cd3eb84a2905a286819eef384ee484d8eb9e7
[ "MIT" ]
39
2020-05-10T20:55:02.000Z
2020-09-12T17:40:59.000Z
import sys print('Python version') print(sys.version)
17.666667
23
0.792453
import sys print('Python version') print(sys.version)
0
0
0
0
0
0
0
0
0
9aec5b230800b9ec3686697f7334e0d86e372c56
1,890
py
Python
engine/compile/ops/gemm.py
kevinintel/neural-compressor
b57645566aeff8d3c18dc49d2739a583c072f940
[ "Apache-2.0" ]
172
2021-09-14T18:34:17.000Z
2022-03-30T06:49:53.000Z
engine/compile/ops/gemm.py
kevinintel/neural-compressor
b57645566aeff8d3c18dc49d2739a583c072f940
[ "Apache-2.0" ]
40
2021-09-14T02:26:12.000Z
2022-03-29T08:34:04.000Z
engine/compile/ops/gemm.py
kevinintel/neural-compressor
b57645566aeff8d3c18dc49d2739a583c072f940
[ "Apache-2.0" ]
33
2021-09-15T07:27:25.000Z
2022-03-25T08:30:57.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright (c) 2021 Intel Corporation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unl...
34.363636
74
0.579365
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright (c) 2021 Intel Corporation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unl...
0
1,117
0
0
0
0
0
27
67
589feaf69506ca950fc4f8a4b8a6c5f6614dbf1b
8,578
py
Python
python/veles/server/conn.py
pombredanne/veles
e65de5a7c268129acffcdb03034efd8d256d025c
[ "Apache-2.0" ]
918
2017-01-16T17:31:25.000Z
2022-03-27T07:10:31.000Z
python/veles/server/conn.py
pombredanne/veles
e65de5a7c268129acffcdb03034efd8d256d025c
[ "Apache-2.0" ]
193
2017-01-17T13:56:10.000Z
2020-09-01T08:29:48.000Z
python/veles/server/conn.py
pombredanne/veles
e65de5a7c268129acffcdb03034efd8d256d025c
[ "Apache-2.0" ]
112
2017-02-01T01:05:57.000Z
2022-03-29T07:21:12.000Z
# Copyright 2017 CodiLime # # 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, softwar...
33.639216
79
0.616694
# Copyright 2017 CodiLime # # 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, softwar...
0
0
1,144
5,995
0
0
0
395
314
9bf4950fa7dff86cba87c5812448f7591d0ed42f
2,265
py
Python
PyPoll/main.py
sandykolu/PyBankPoll_Challenge
373b892ef034d51360e90828b88f950e3967b8b0
[ "MIT" ]
null
null
null
PyPoll/main.py
sandykolu/PyBankPoll_Challenge
373b892ef034d51360e90828b88f950e3967b8b0
[ "MIT" ]
null
null
null
PyPoll/main.py
sandykolu/PyBankPoll_Challenge
373b892ef034d51360e90828b88f950e3967b8b0
[ "MIT" ]
null
null
null
import os import csv csvpath = os.path.join(".", "Resources", "election_data.csv") output = os.path.join('.', 'analysis', 'election_results.txt') candidate =[] candidate_list = [] votecount = {} winning_candidate = "" winning_count = 0 # def print_poll_results(candidate_name): # The total number of votes cast # A c...
27.289157
77
0.574834
import os import csv csvpath = os.path.join(".", "Resources", "election_data.csv") output = os.path.join('.', 'analysis', 'election_results.txt') candidate =[] candidate_list = [] votecount = {} winning_candidate = "" winning_count = 0 # def print_poll_results(candidate_name): # The total number of votes cast # A c...
0
0
0
0
0
0
0
0
0
c7d1ce5fdb40537f12732894e88e17e0be504515
1,589
py
Python
calweek.py
yuridadt/week_calc
97c553b61d635803f8ceb623d96ffbfe81f6f390
[ "MIT" ]
null
null
null
calweek.py
yuridadt/week_calc
97c553b61d635803f8ceb623d96ffbfe81f6f390
[ "MIT" ]
null
null
null
calweek.py
yuridadt/week_calc
97c553b61d635803f8ceb623d96ffbfe81f6f390
[ "MIT" ]
null
null
null
if __name__ == '__main__': yw = CalWeek('2019-01') print(yw) print(str(yw)) print(yw + 200) print(200 + yw) print(yw + (-100)) print(yw - 100) print(yw - CalWeek('1000-01'))
29.981132
85
0.590308
from datetime import datetime, timedelta class CalWeek: """ Class providing arithmetic operations for year-week date format """ def __init__(self, year_week, format='%G-%V'): self.year, self.week = [int(val) for val in year_week.split('-')] if self.year < 1 or self.year > 9999: ...
0
0
0
1,316
0
0
0
19
45
26529381c9bc11a892e3213d940993c4f1d4dd75
1,640
py
Python
src/feature vector creation/step8_cohort_info.py
arjun-parthi/SSRI-Project
62f610a594e5849ccf0f3c25cd6adcd63888ec2a
[ "MIT" ]
2
2019-02-12T00:37:37.000Z
2021-03-25T05:40:06.000Z
src/feature vector creation/step8_cohort_info.py
arjun-parthi/SSRI-Project
62f610a594e5849ccf0f3c25cd6adcd63888ec2a
[ "MIT" ]
null
null
null
src/feature vector creation/step8_cohort_info.py
arjun-parthi/SSRI-Project
62f610a594e5849ccf0f3c25cd6adcd63888ec2a
[ "MIT" ]
1
2021-03-25T05:40:17.000Z
2021-03-25T05:40:17.000Z
import pandas as pd file1 = '../data/FV2.xlsx' x1 = pd.ExcelFile(file1) feature = x1.parse('Sheet1') print(feature.shape) file2 = '../data/AP_SSRI_PD_PAIN.xlsx' x2 = pd.ExcelFile(file2) cohort1 = x2.parse('Sheet1') print(cohort1.shape) cohort1 = cohort1.drop(['CLASSIFICATION'], axis=1) cohort1 = cohort1.drop_duplicate...
30.37037
65
0.739024
import pandas as pd import numpy as np file1 = '../data/FV2.xlsx' x1 = pd.ExcelFile(file1) feature = x1.parse('Sheet1') print(feature.shape) file2 = '../data/AP_SSRI_PD_PAIN.xlsx' x2 = pd.ExcelFile(file2) cohort1 = x2.parse('Sheet1') print(cohort1.shape) cohort1 = cohort1.drop(['CLASSIFICATION'], axis=1) cohort1 = coh...
0
0
0
0
0
0
0
-3
22
d5caa76a6b5772b51a51975e3431c014ec00ddc5
7,568
py
Python
modularity/GirvanNewman.py
peterwinter/boxcluster
079452dd029a45390f0347e22df3fce048210389
[ "MIT" ]
1
2016-11-14T22:23:25.000Z
2016-11-14T22:23:25.000Z
modularity/GirvanNewman.py
peterwinter/boxcluster
079452dd029a45390f0347e22df3fce048210389
[ "MIT" ]
null
null
null
modularity/GirvanNewman.py
peterwinter/boxcluster
079452dd029a45390f0347e22df3fce048210389
[ "MIT" ]
null
null
null
#! /usr/bin/env python """ Implementation of the GirvanNewman algorithm for finding the best modularity in a network """ # def get_protected_edges(G, similar_sets): # protected_edges = [] # for s in similar_sets: # for u in s: # for v in s[1:]: # if G.has_edge(u, v): # ...
32.62069
80
0.637817
#! /usr/bin/env python """ Implementation of the GirvanNewman algorithm for finding the best modularity in a network """ import copy import random import networkx as nx from .base import modularity from .base import largest_connected def get_graph(filename): G = nx.Graph() f = open(filename) data = f.read...
0
0
0
0
0
6,802
0
3
317
cb56e2e991646f35151e36f241cb42b711fa8f72
1,314
py
Python
backend/company/migrations/0004_auto_20211128_2356.py
mahanfarzaneh2000/ProjeTor
bf21d2cfcd64552c8be5d97eb4ac1c7c3f7d9ca9
[ "Apache-2.0" ]
null
null
null
backend/company/migrations/0004_auto_20211128_2356.py
mahanfarzaneh2000/ProjeTor
bf21d2cfcd64552c8be5d97eb4ac1c7c3f7d9ca9
[ "Apache-2.0" ]
null
null
null
backend/company/migrations/0004_auto_20211128_2356.py
mahanfarzaneh2000/ProjeTor
bf21d2cfcd64552c8be5d97eb4ac1c7c3f7d9ca9
[ "Apache-2.0" ]
null
null
null
# Generated by Django 3.2.8 on 2021-11-28 20:26
39.818182
140
0.644597
# Generated by Django 3.2.8 on 2021-11-28 20:26 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ('company', '0003_alter_co...
0
0
0
1,134
0
0
0
41
90
d522918719c848e139191400a0e4af080f69264b
18,084
py
Python
messageslog/messageslog.py
skylarr1227/Fixator10-Cogs
cef6b2e51d8c400b0462cfcf44b637275d3780d3
[ "MIT" ]
null
null
null
messageslog/messageslog.py
skylarr1227/Fixator10-Cogs
cef6b2e51d8c400b0462cfcf44b637275d3780d3
[ "MIT" ]
null
null
null
messageslog/messageslog.py
skylarr1227/Fixator10-Cogs
cef6b2e51d8c400b0462cfcf44b637275d3780d3
[ "MIT" ]
null
null
null
import logging from redbot.core import commands from redbot.core.i18n import Translator def is_channel_set(channel_type: str): """Checks if server has set channel for logging""" return commands.check(predicate) log = logging.getLogger("red.fixator10-cogs.messageslog") _ = Translator("MessagesLog", __file_...
42.055814
99
0.599536
import logging from datetime import datetime, timezone from pprint import pformat from typing import Union import discord from redbot.core import checks, commands from redbot.core.config import Config from redbot.core.i18n import Translator, cog_i18n, set_contextual_locales_from_guild from redbot.core.utils import Asy...
9
16,989
343
0
0
0
0
175
250