hexsha
stringlengths
40
40
size
int64
7
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
247
max_issues_repo_name
stringlengths
4
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
247
max_forks_repo_name
stringlengths
4
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.77
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
7
1.04M
filtered:remove_function_no_docstring
int64
-102
942k
filtered:remove_class_no_docstring
int64
-354
977k
filtered:remove_delete_markers
int64
0
60.1k
520a7f4acd6be66e1e35cfdf50ea1d1b2f8b1157
1,703
py
Python
{{cookiecutter.project_slug}}/backend/auth/deps.py
SnkSynthesis/fastapi-svelte-template
88cd1e4f5d0e0827f1460666b0acbbaddb0ef727
[ "MIT" ]
2
2021-06-30T19:14:26.000Z
2021-07-31T10:14:51.000Z
{{cookiecutter.project_slug}}/backend/auth/deps.py
SnkSynthesis/fastapi-svelte-template
88cd1e4f5d0e0827f1460666b0acbbaddb0ef727
[ "MIT" ]
null
null
null
{{cookiecutter.project_slug}}/backend/auth/deps.py
SnkSynthesis/fastapi-svelte-template
88cd1e4f5d0e0827f1460666b0acbbaddb0ef727
[ "MIT" ]
1
2021-06-29T23:40:31.000Z
2021-06-29T23:40:31.000Z
from fastapi import HTTPException, status, Depends from fastapi.security import SecurityScopes from jose import jwt, JWTError from .context import oauth2_scheme, TokenData from ..crud.user_crud import UserCRUD, UserInDB from pydantic import ValidationError from ..crud.deps import get_crud_obj from ..configuration impor...
34.06
75
0.692308
from fastapi import HTTPException, status, Depends from fastapi.security import SecurityScopes from jose import jwt, JWTError from .context import oauth2_scheme, TokenData from ..crud.user_crud import UserCRUD, UserInDB from pydantic import ValidationError from ..crud.deps import get_crud_obj from ..configuration impor...
1,352
0
23
75e66994ac462ccb0158bdead31a2030e04785b3
2,129
py
Python
Examples/ApiExamples/ex_digital_signature_collection.py
alex-dudin/Aspose.Words-for-Python-via-.NET
02b257df8da9892fcce671c473c2ef27b68b5087
[ "MIT" ]
3
2021-12-04T22:17:28.000Z
2022-02-22T03:30:01.000Z
Examples/ApiExamples/ex_digital_signature_collection.py
alex-dudin/Aspose.Words-for-Python-via-.NET
02b257df8da9892fcce671c473c2ef27b68b5087
[ "MIT" ]
4
2021-11-26T10:01:06.000Z
2021-12-14T15:01:11.000Z
Examples/ApiExamples/ex_digital_signature_collection.py
alex-dudin/Aspose.Words-for-Python-via-.NET
02b257df8da9892fcce671c473c2ef27b68b5087
[ "MIT" ]
2
2021-10-20T18:06:22.000Z
2021-10-29T20:59:18.000Z
# Copyright (c) 2001-2022 Aspose Pty Ltd. All Rights Reserved. # # This file is part of Aspose.Words. The source code in this file # is only intended as a supplement to the documentation, and is provided # "as is", without warranty of any kind, either expressed or implied. import aspose.words as aw from api_example_b...
42.58
146
0.689526
# Copyright (c) 2001-2022 Aspose Pty Ltd. All Rights Reserved. # # This file is part of Aspose.Words. The source code in this file # is only intended as a supplement to the documentation, and is provided # "as is", without warranty of any kind, either expressed or implied. import aspose.words as aw from api_example_b...
1,695
30
50
0fbda78303ff8b27eb8eaa358796fd58f30039f0
5,082
py
Python
TweakApi/models/__init__.py
tweak-com-public/tweak-api-client-python
019f86da11fdb12683d516f8f37db5d717380bcc
[ "Apache-2.0" ]
null
null
null
TweakApi/models/__init__.py
tweak-com-public/tweak-api-client-python
019f86da11fdb12683d516f8f37db5d717380bcc
[ "Apache-2.0" ]
null
null
null
TweakApi/models/__init__.py
tweak-com-public/tweak-api-client-python
019f86da11fdb12683d516f8f37db5d717380bcc
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ tweak-api Tweak API to integrate with all the Tweak services. You can find out more about Tweak at <a href='https://www.tweak.com'>https://www.tweak.com</a>, #tweak. OpenAPI spec version: 1.0.8-beta.0 Generated by: https://github.com/swagger-api/swagger-codegen.git ...
43.810345
165
0.860685
# coding: utf-8 """ tweak-api Tweak API to integrate with all the Tweak services. You can find out more about Tweak at <a href='https://www.tweak.com'>https://www.tweak.com</a>, #tweak. OpenAPI spec version: 1.0.8-beta.0 Generated by: https://github.com/swagger-api/swagger-codegen.git ...
0
0
0
05816eae8bb3a31aa4455e83e5b9fa46a8cf2d0b
1,836
py
Python
tt_wall/app/models.py
trucktar/tt-wall
c355e97f515cc67b272d540be4be8381f07024b3
[ "MIT" ]
null
null
null
tt_wall/app/models.py
trucktar/tt-wall
c355e97f515cc67b272d540be4be8381f07024b3
[ "MIT" ]
8
2021-03-30T14:33:47.000Z
2022-01-13T03:02:31.000Z
tt_wall/app/models.py
trucktar/tt-wall
c355e97f515cc67b272d540be4be8381f07024b3
[ "MIT" ]
null
null
null
from cloudinary.models import CloudinaryField from django.db import models
28.246154
69
0.673747
from cloudinary.models import CloudinaryField from django.db import models class CrudMixin: def save_model(self): """Save model instance to the database.""" self.save() def delete_model(self): """Delete model instance from the database.""" self.delete() def update_model(s...
62
1,603
92
27ec9ea8554b038c7d6ac555c28a7996ae92dec9
93
py
Python
setup/settings_jqueryui.py
sayanjap/DynamicForms
071707de36d109fe3a17ae5df239240ea5ba707f
[ "BSD-3-Clause" ]
42
2018-01-18T14:50:05.000Z
2022-03-24T18:34:19.000Z
setup/settings_jqueryui.py
sayanjap/DynamicForms
071707de36d109fe3a17ae5df239240ea5ba707f
[ "BSD-3-Clause" ]
14
2018-12-05T21:39:23.000Z
2022-02-27T06:43:48.000Z
setup/settings_jqueryui.py
sayanjap/DynamicForms
071707de36d109fe3a17ae5df239240ea5ba707f
[ "BSD-3-Clause" ]
5
2018-01-18T16:32:20.000Z
2021-06-07T10:15:18.000Z
from .settings import * DYNAMICFORMS.update({ 'template': 'dynamicforms/jquery_ui/', })
15.5
42
0.698925
from .settings import * DYNAMICFORMS.update({ 'template': 'dynamicforms/jquery_ui/', })
0
0
0
3eabf56ecceb7d52909f079836ef7985df5292e6
1,460
py
Python
django_stormpath/management/commands/create_social_directory.py
stormpath/stormpath-django
af60eb5da2115d94ac313613c5d4e6b9f3d16157
[ "Apache-2.0" ]
36
2015-01-13T00:21:07.000Z
2017-11-07T11:45:25.000Z
django_stormpath/management/commands/create_social_directory.py
stormpath/stormpath-django
af60eb5da2115d94ac313613c5d4e6b9f3d16157
[ "Apache-2.0" ]
55
2015-01-07T09:53:50.000Z
2017-02-07T00:31:20.000Z
django_stormpath/management/commands/create_social_directory.py
stormpath/stormpath-django
af60eb5da2115d94ac313613c5d4e6b9f3d16157
[ "Apache-2.0" ]
24
2015-01-06T16:17:33.000Z
2017-04-21T14:00:16.000Z
import sys from django.core.management.base import BaseCommand try: input = raw_input except NameError: pass from stormpath.error import Error as StormpathError from stormpath.resources.provider import Provider from django_stormpath import social
29.2
119
0.641096
import sys from django.core.management.base import BaseCommand try: input = raw_input except NameError: pass from stormpath.error import Error as StormpathError from stormpath.resources.provider import Provider from django_stormpath import social class Command(BaseCommand): help = 'Creates a Directory...
1,047
129
23
5049a90f19df0d67fe41e46688df041718c9387c
5,351
py
Python
conference/schedule/models.py
djangocon/2017.djangocon.eu
d811a9cd5b24f48f6e224d0dd4abe9173f7f97d7
[ "BSD-3-Clause" ]
7
2016-11-21T12:53:37.000Z
2020-03-30T23:22:48.000Z
conference/schedule/models.py
djangocon/2017.djangocon.eu
d811a9cd5b24f48f6e224d0dd4abe9173f7f97d7
[ "BSD-3-Clause" ]
17
2016-11-17T19:25:48.000Z
2017-04-06T08:43:46.000Z
conference/schedule/models.py
FuzzyBrains/DjangoConEurope2017
d811a9cd5b24f48f6e224d0dd4abe9173f7f97d7
[ "BSD-3-Clause" ]
7
2016-11-05T11:18:40.000Z
2016-11-09T17:14:52.000Z
# -*- coding: utf-8 -*- from __future__ import absolute_import, print_function, unicode_literals import datetime as dt from autoslug import AutoSlugField from autoslug.utils import slugify from django.core.exceptions import ValidationError from django.db import models from django.template.defaultfilters import trunca...
33.236025
113
0.649038
# -*- coding: utf-8 -*- from __future__ import absolute_import, print_function, unicode_literals import datetime as dt from autoslug import AutoSlugField from autoslug.utils import slugify from django.core.exceptions import ValidationError from django.db import models from django.template.defaultfilters import trunca...
2,245
110
449
28968d94eeec5a5775805c46a7c1dbf2b011c175
2,778
py
Python
gdb/makecfg/make_cfg.py
task4233/malgrapher
eabea7b63860c9c8a9cd0269b12ad1d04d807623
[ "MIT" ]
13
2021-01-29T13:44:23.000Z
2021-06-08T17:58:36.000Z
gdb/makecfg/make_cfg.py
task4233/malgrapher
eabea7b63860c9c8a9cd0269b12ad1d04d807623
[ "MIT" ]
7
2021-01-23T20:48:19.000Z
2022-01-11T05:43:43.000Z
gdb/makecfg/make_cfg.py
task4233/malgrapher
eabea7b63860c9c8a9cd0269b12ad1d04d807623
[ "MIT" ]
2
2021-01-30T12:02:49.000Z
2021-03-01T04:02:44.000Z
import subprocess import os from makecfg.config import Config
37.540541
98
0.593593
import subprocess import os from makecfg.config import Config class Register: def __init__(self, register_file_path): self.regs = {} outs = [] with open(register_file_path, 'r') as f: outs = f.readlines() for reg in outs: tmp = reg.split(' ') tmp ...
2,556
-13
214
dbd56c4445315d86e4854f2f4eab79374778f361
1,331
py
Python
comments/forms.py
MinXiaoBo/django_blog
3ce199a8144dda417b20595bf210ccfe42c0ff4e
[ "MIT" ]
1
2019-09-25T07:58:45.000Z
2019-09-25T07:58:45.000Z
comments/forms.py
MinXiaoBo/django_blog
3ce199a8144dda417b20595bf210ccfe42c0ff4e
[ "MIT" ]
null
null
null
comments/forms.py
MinXiaoBo/django_blog
3ce199a8144dda417b20595bf210ccfe42c0ff4e
[ "MIT" ]
null
null
null
#!/usr/bin/env python # encoding: utf-8 from .models import Comment from django import forms from django.forms import ModelForm from django.contrib.auth.models import User from django.contrib.auth import get_user_model
25.596154
84
0.499624
#!/usr/bin/env python # encoding: utf-8 from .models import Comment from django import forms from django.forms import ModelForm from django.contrib.auth.models import User from django.contrib.auth import get_user_model class CommentForm(ModelForm): url = forms.URLField( label='网址', required=False...
0
1,136
23
f7c50d1fc8e413db30c3f8776c6f4c101dfd8964
1,718
py
Python
setup.py
SofienM/py-gitguardian
f1379eafb5d73e90c6a4ee213a08b14c1b567062
[ "MIT" ]
null
null
null
setup.py
SofienM/py-gitguardian
f1379eafb5d73e90c6a4ee213a08b14c1b567062
[ "MIT" ]
null
null
null
setup.py
SofienM/py-gitguardian
f1379eafb5d73e90c6a4ee213a08b14c1b567062
[ "MIT" ]
null
null
null
import io import os import re from setuptools import find_packages, setup VERSION_RE = re.compile(r"__version__\s*=\s*\"(.*?)\"") HERE = os.path.abspath(os.path.dirname(__file__)) def read(*args): """Reads complete file contents.""" return io.open(os.path.join(HERE, *args), encoding="utf-8").read() def g...
31.814815
97
0.657159
import io import os import re from setuptools import find_packages, setup VERSION_RE = re.compile(r"__version__\s*=\s*\"(.*?)\"") HERE = os.path.abspath(os.path.dirname(__file__)) def read(*args): """Reads complete file contents.""" return io.open(os.path.join(HERE, *args), encoding="utf-8").read() def g...
0
0
0
a12c32111000f8ba96b8da14ff920ccfb1daa150
968
py
Python
src/domain/Contest/usecase/contest_repository.py
SoyBeansLab/daizu-online-judge-backend
873f81fdad2f216e28b83341a6d88b0e21078d6e
[ "MIT" ]
7
2019-05-14T08:40:35.000Z
2019-08-20T08:15:21.000Z
src/domain/Contest/usecase/contest_repository.py
SoyBeansLab/daizu-online-judge-backend
873f81fdad2f216e28b83341a6d88b0e21078d6e
[ "MIT" ]
76
2019-05-14T08:56:40.000Z
2020-10-18T16:25:33.000Z
src/domain/Contest/usecase/contest_repository.py
SoyBeansLab/daizu-online-judge-backend
873f81fdad2f216e28b83341a6d88b0e21078d6e
[ "MIT" ]
3
2019-12-12T01:44:31.000Z
2020-11-22T03:24:40.000Z
from abc import ABC, abstractmethod from typing import List from domain.Contest.contest import Contest
24.820513
64
0.68905
from abc import ABC, abstractmethod from typing import List from domain.Contest.contest import Contest class ContestRepository(ABC): @abstractmethod def find_all(self) -> List[Contest]: raise NotImplementedError() @abstractmethod def find_upcoming(self) -> List[Contest]: raise NotImp...
457
383
23
eebbddfa426e80782d085b44deb10238b5221f1e
2,796
py
Python
dsutil/general.py
tabbartley/python-ds-util
4bb8a5f387f5b064e9cb9b0566069adc0db63796
[ "MIT" ]
4
2019-02-23T18:09:04.000Z
2020-02-26T22:45:49.000Z
dsutil/general.py
tabbartley/python-ds-util
4bb8a5f387f5b064e9cb9b0566069adc0db63796
[ "MIT" ]
7
2019-03-16T20:58:37.000Z
2021-06-30T01:08:00.000Z
dsutil/general.py
tabbartley/python-ds-util
4bb8a5f387f5b064e9cb9b0566069adc0db63796
[ "MIT" ]
3
2019-03-17T17:24:26.000Z
2019-08-20T12:08:38.000Z
# -*- coding: utf-8 -*- import pandas as pd from sklearn.base import BaseEstimator, TransformerMixin # here you define the operation it should perform # just return self class SelectColumnsTransfomer(BaseEstimator, TransformerMixin): """ Select dataframe columns """ class DataframeFunctionTransform...
33.686747
114
0.614807
# -*- coding: utf-8 -*- import pandas as pd from sklearn.base import BaseEstimator, TransformerMixin class ToDenseTransformer(BaseEstimator,TransformerMixin): # here you define the operation it should perform def transform(self, X, y=None, **fit_params): return X.todense() # just return self ...
1,454
36
210
07521eba62d18592f9425a4cbad3085445a07129
1,718
py
Python
qrcodes.py
singhsidhukuldeep/QR-Code-decryption-with-tensorflow
ec7236454bb6a3e65d31291e5c4f01a71dbe336e
[ "MIT" ]
2
2020-03-29T09:56:52.000Z
2020-04-18T05:10:07.000Z
qrcodes.py
singhsidhukuldeep/QR-Code-decryption-with-tensorflow
ec7236454bb6a3e65d31291e5c4f01a71dbe336e
[ "MIT" ]
null
null
null
qrcodes.py
singhsidhukuldeep/QR-Code-decryption-with-tensorflow
ec7236454bb6a3e65d31291e5c4f01a71dbe336e
[ "MIT" ]
1
2020-04-18T05:10:08.000Z
2020-04-18T05:10:08.000Z
import multiprocessing import qrcode import random import string import numpy as np IMAGE_SIZE = 21 STRING_LENGTH = 10 CHARACTER_SET = string.ascii_lowercase + string.ascii_uppercase + \ string.digits def randomString(): """ Return a random string where characters are drawn from a fixed set of chara...
24.197183
80
0.665891
import multiprocessing import qrcode import random import string import numpy as np IMAGE_SIZE = 21 STRING_LENGTH = 10 CHARACTER_SET = string.ascii_lowercase + string.ascii_uppercase + \ string.digits def randomString(): """ Return a random string where characters are drawn from a fixed set of chara...
0
0
0
c057e1f2ebf696ab14bda72cfb9ab7648f2a8c67
1,754
py
Python
Dependencies/gyp-master/test/win/win-tool/gyptest-win-tool-handles-readonly-files.py
knight666/exlibris
b21b46e0c84e5c4f81f8048022cda88e7bb3dca2
[ "MIT" ]
null
null
null
Dependencies/gyp-master/test/win/win-tool/gyptest-win-tool-handles-readonly-files.py
knight666/exlibris
b21b46e0c84e5c4f81f8048022cda88e7bb3dca2
[ "MIT" ]
null
null
null
Dependencies/gyp-master/test/win/win-tool/gyptest-win-tool-handles-readonly-files.py
knight666/exlibris
b21b46e0c84e5c4f81f8048022cda88e7bb3dca2
[ "MIT" ]
null
null
null
#!/usr/bin/env python # Copyright (c) 2014 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Make sure overwriting read-only files works as expected (via win-tool). """ import TestGyp import filecmp import os impo...
31.321429
81
0.684151
#!/usr/bin/env python # Copyright (c) 2014 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Make sure overwriting read-only files works as expected (via win-tool). """ import TestGyp import filecmp import os impo...
0
0
0
b8062a9d8a66a2f4afef8b6b392b2dbc4a92eeee
4,521
py
Python
sys-metrics-using-psutil.py
PSJoshi/python_scripts
740b502e24b44648ff530f0ff9428f5a460fd645
[ "Apache-2.0" ]
null
null
null
sys-metrics-using-psutil.py
PSJoshi/python_scripts
740b502e24b44648ff530f0ff9428f5a460fd645
[ "Apache-2.0" ]
null
null
null
sys-metrics-using-psutil.py
PSJoshi/python_scripts
740b502e24b44648ff530f0ff9428f5a460fd645
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import psutil import netifaces import sys import logging import subprocess # Add various metrics from this code - https://gitlab.ncl.ac.uk/cs-support-group/lcd-monitor-panel/blob/master/data.py # logging logging.basicConfig(stream=sys.stdout, level=logging.ERROR) logger = logging.getLogger(__nam...
36.459677
125
0.764211
#!/usr/bin/env python import psutil import netifaces import sys import logging import subprocess # Add various metrics from this code - https://gitlab.ncl.ac.uk/cs-support-group/lcd-monitor-panel/blob/master/data.py # logging logging.basicConfig(stream=sys.stdout, level=logging.ERROR) logger = logging.getLogger(__nam...
3,186
0
138
286ce0a7d072d9fe57d2a2641ce59bb2b52419d1
1,094
py
Python
files/default/ec2_dev_2_volid.py
Canufindme/cfncluster-cookbook
677413dcdd2de792912b6e29391598776d8f2f49
[ "Apache-2.0" ]
null
null
null
files/default/ec2_dev_2_volid.py
Canufindme/cfncluster-cookbook
677413dcdd2de792912b6e29391598776d8f2f49
[ "Apache-2.0" ]
null
null
null
files/default/ec2_dev_2_volid.py
Canufindme/cfncluster-cookbook
677413dcdd2de792912b6e29391598776d8f2f49
[ "Apache-2.0" ]
1
2022-01-26T20:12:53.000Z
2022-01-26T20:12:53.000Z
#!/usr/bin/env python import boto.ec2 import urllib2 import sys import os # Get dev try: dev = str(sys.argv[1]) except IndexError: print "Provide block device i.e. xvdf" sys.exit(1) # Convert dev to mapping format if 'nvme' in dev: # For newer instances which expose EBS volumes as NVMe devices, translate the...
24.863636
108
0.720293
#!/usr/bin/env python import boto.ec2 import urllib2 import sys import os # Get dev try: dev = str(sys.argv[1]) except IndexError: print "Provide block device i.e. xvdf" sys.exit(1) # Convert dev to mapping format if 'nvme' in dev: # For newer instances which expose EBS volumes as NVMe devices, translate the...
0
0
0
e1b0d3de9fb20bc1e31ccaa8f8449d9906b02af1
211
py
Python
tasks.py
judy2k/dj-nexmo
03341eddd79817e17135c967361031120038cbab
[ "Apache-2.0" ]
3
2018-06-26T15:23:14.000Z
2021-03-17T00:00:57.000Z
tasks.py
judy2k/dj-nexmo
03341eddd79817e17135c967361031120038cbab
[ "Apache-2.0" ]
11
2018-10-26T17:34:19.000Z
2019-05-04T09:04:01.000Z
tasks.py
Nexmo/dj-nexmo
03341eddd79817e17135c967361031120038cbab
[ "Apache-2.0" ]
7
2018-08-07T15:05:51.000Z
2019-05-23T05:33:29.000Z
from invoke import task @task @task
16.230769
64
0.649289
from invoke import task @task def build(c): # c.run("pandoc -f markdown -t rst -o README.rst README.md") c.run("python setup.py bdist_wheel sdist") @task def clean(c): c.run("rm -rf build dist")
127
0
44
04ff2a56f55835cd6913620c27ad17f5ba44e320
1,635
py
Python
sonia_flexbe_states/src/sonia_flexbe_states/create_absolute_depth.py
sonia-auv/sonia-behaviors
28519551f954616e83b474e6cab6ba3762d238f2
[ "BSD-3-Clause" ]
null
null
null
sonia_flexbe_states/src/sonia_flexbe_states/create_absolute_depth.py
sonia-auv/sonia-behaviors
28519551f954616e83b474e6cab6ba3762d238f2
[ "BSD-3-Clause" ]
1
2022-02-16T01:31:51.000Z
2022-02-21T22:30:46.000Z
sonia_flexbe_states/src/sonia_flexbe_states/create_absolute_depth.py
sonia-auv/sonia-behaviors
28519551f954616e83b474e6cab6ba3762d238f2
[ "BSD-3-Clause" ]
1
2021-11-09T13:34:43.000Z
2021-11-09T13:34:43.000Z
#!/usr/bin/env python #-*- coding: utf-8 -*- import rospy from flexbe_core import EventState, Logger from sonia_common.msg import AddPose from geometry_msgs.msg import Point, Vector3 from nav_msgs.msg import Odometry class create_absolute_depth(EventState): ''' (!!!! DEPRECATED !!!!!) Move the submarine...
30.849057
121
0.614067
#!/usr/bin/env python #-*- coding: utf-8 -*- import rospy from flexbe_core import EventState, Logger from sonia_common.msg import AddPose from geometry_msgs.msg import Point, Vector3 from nav_msgs.msg import Odometry class create_absolute_depth(EventState): ''' (!!!! DEPRECATED !!!!!) Move the submarine...
975
0
143
6b2a2281c2e648681fbebdd1ad30f57c99980b32
746
py
Python
Bot_Saves_Princess.py
Aditya148/Hackerrank-Artificial-Intelligence
5abbe561115b75cb28397661b7b0d7d53486ffee
[ "MIT" ]
null
null
null
Bot_Saves_Princess.py
Aditya148/Hackerrank-Artificial-Intelligence
5abbe561115b75cb28397661b7b0d7d53486ffee
[ "MIT" ]
null
null
null
Bot_Saves_Princess.py
Aditya148/Hackerrank-Artificial-Intelligence
5abbe561115b75cb28397661b7b0d7d53486ffee
[ "MIT" ]
null
null
null
n = int(input()) matrix = [] for i in range(n): a = input().strip() matrix.append(a) if 'm' in a: m_r = i m_c = a.index('m') if 'p' in a: p_r = i p_c = a.index('p') r_diff = m_r - p_r c_diff = m_c - p_c while True: if r_diff != 0: if r_diff<0: ...
14.346154
35
0.406166
n = int(input()) matrix = [] for i in range(n): a = input().strip() matrix.append(a) if 'm' in a: m_r = i m_c = a.index('m') if 'p' in a: p_r = i p_c = a.index('p') r_diff = m_r - p_r c_diff = m_c - p_c while True: if r_diff != 0: if r_diff<0: ...
0
0
0
cbaa48c7037c0c6e9418858d7adfd9278944b1a3
32,685
py
Python
tests/test_relations.py
relaxdiego/charms.reactive
e37e781432e77c12b63d2c739bd6cd70d3230c3a
[ "Apache-2.0" ]
null
null
null
tests/test_relations.py
relaxdiego/charms.reactive
e37e781432e77c12b63d2c739bd6cd70d3230c3a
[ "Apache-2.0" ]
null
null
null
tests/test_relations.py
relaxdiego/charms.reactive
e37e781432e77c12b63d2c739bd6cd70d3230c3a
[ "Apache-2.0" ]
null
null
null
# Copyright 2014-2017 Canonical Limited. # # This file is part of charms.reactive. # # charms.reactive is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License version 3 as # published by the Free Software Foundation. # # charm-helpers is distributed in the h...
43.813673
115
0.623069
# Copyright 2014-2017 Canonical Limited. # # This file is part of charms.reactive. # # charms.reactive is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License version 3 as # published by the Free Software Foundation. # # charm-helpers is distributed in the h...
27,053
4,563
241
648fc4fbe8f331546ba71eb9b858ffcc2def9fb4
1,601
py
Python
s3contents/chunks.py
pisontechnology/s3contents
11aebbe2d7945e5ca3dacf4b72ee10455a3700cb
[ "Apache-2.0" ]
2
2021-02-19T01:43:46.000Z
2021-04-19T19:03:20.000Z
s3contents/chunks.py
pisontechnology/s3contents
11aebbe2d7945e5ca3dacf4b72ee10455a3700cb
[ "Apache-2.0" ]
null
null
null
s3contents/chunks.py
pisontechnology/s3contents
11aebbe2d7945e5ca3dacf4b72ee10455a3700cb
[ "Apache-2.0" ]
3
2021-01-13T21:09:39.000Z
2022-03-17T05:26:56.000Z
""" Utilities for managing chunked file uploads. See https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#chunked-saving """ import base64 import contextvars import time # Used as a "registry" for uploads. content_chunks = contextvars.ContextVar("jupyterlab_content_chunks", default={}) def sto...
26.683333
92
0.697689
""" Utilities for managing chunked file uploads. See https://jupyter-notebook.readthedocs.io/en/stable/extending/contents.html#chunked-saving """ import base64 import contextvars import time # Used as a "registry" for uploads. content_chunks = contextvars.ContextVar("jupyterlab_content_chunks", default={}) def sto...
0
0
0
f5f8ebf3085032f3cde6b3f0f4d029a233ca6c53
8,092
py
Python
ultracart/models/email_commseq_webhook_send_test_request.py
UltraCart/rest_api_v2_sdk_python
d734ea13fabc7a57872ff68bac06861edb8fd882
[ "Apache-2.0" ]
1
2018-03-15T16:56:23.000Z
2018-03-15T16:56:23.000Z
ultracart/models/email_commseq_webhook_send_test_request.py
UltraCart/rest_api_v2_sdk_python
d734ea13fabc7a57872ff68bac06861edb8fd882
[ "Apache-2.0" ]
null
null
null
ultracart/models/email_commseq_webhook_send_test_request.py
UltraCart/rest_api_v2_sdk_python
d734ea13fabc7a57872ff68bac06861edb8fd882
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ UltraCart Rest API V2 UltraCart REST API Version 2 # noqa: E501 OpenAPI spec version: 2.0.0 Contact: support@ultracart.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six class EmailCommseqWebhookSendT...
29.75
160
0.62259
# coding: utf-8 """ UltraCart Rest API V2 UltraCart REST API Version 2 # noqa: E501 OpenAPI spec version: 2.0.0 Contact: support@ultracart.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six class EmailCommseqWebhookSendT...
0
0
0
5bcb05c60361341b7b761f5f7dd88766c76c2fa0
5,520
py
Python
experiments/testing_env/process_result.py
michalnand/reinforcement_learning_experiments
105bcfacd30cfbd1bbd9893859fc7d203e0df1e9
[ "MIT" ]
null
null
null
experiments/testing_env/process_result.py
michalnand/reinforcement_learning_experiments
105bcfacd30cfbd1bbd9893859fc7d203e0df1e9
[ "MIT" ]
null
null
null
experiments/testing_env/process_result.py
michalnand/reinforcement_learning_experiments
105bcfacd30cfbd1bbd9893859fc7d203e0df1e9
[ "MIT" ]
null
null
null
import RLAgents import numpy import matplotlib.pyplot as plt raw_score_col = 3 norm_score_col = 4 result_path = "./results/" files = [] files.append("./models/ppo_baseline/run_0/result/result.log") files.append("./models/ppo_baseline/run_1/result/result.log") files.append("./models/ppo_baseline/run_2/result/resul...
41.503759
125
0.766123
import RLAgents import numpy import matplotlib.pyplot as plt raw_score_col = 3 norm_score_col = 4 result_path = "./results/" files = [] files.append("./models/ppo_baseline/run_0/result/result.log") files.append("./models/ppo_baseline/run_1/result/result.log") files.append("./models/ppo_baseline/run_2/result/resul...
0
0
0
b6b91ffcd93cb5ad4bf4f5a11113e6b457abb61a
3,999
py
Python
tributary/lazy/graph.py
Ferev/tributary
df38e489f2c93415e889006475464e254b4433a1
[ "Apache-2.0" ]
null
null
null
tributary/lazy/graph.py
Ferev/tributary
df38e489f2c93415e889006475464e254b4433a1
[ "Apache-2.0" ]
null
null
null
tributary/lazy/graph.py
Ferev/tributary
df38e489f2c93415e889006475464e254b4433a1
[ "Apache-2.0" ]
null
null
null
import types from .node import Node # noqa: F401 from ..base import TributaryException class LazyGraph(object): """Wrapper class around a collection of lazy nodes.""" def node(self, name, readonly=False, nullable=True, value=None): # noqa: F811 """method to create a lazy node attached to a graph. ...
42.094737
139
0.531133
import types from .node import Node # noqa: F401 from ..base import TributaryException class LazyGraph(object): """Wrapper class around a collection of lazy nodes.""" def __init__(self, *args, **kwargs): # the last thing we do is go through all of our methods and ensure that all `_callable_args` in ...
2,762
0
81
9d484cdc3161d834ec06a2eb4451c025ee3c7cf8
313
py
Python
COTLR/bots/testbot.py
Destructible-Watermelon/COTLR
241fb850ce127ea54e0beaf8ec83e25be863645d
[ "MIT" ]
null
null
null
COTLR/bots/testbot.py
Destructible-Watermelon/COTLR
241fb850ce127ea54e0beaf8ec83e25be863645d
[ "MIT" ]
null
null
null
COTLR/bots/testbot.py
Destructible-Watermelon/COTLR
241fb850ce127ea54e0beaf8ec83e25be863645d
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import player
19.5625
30
0.578275
#!/usr/bin/env python3 import player class Bam(player.Player): name = "DropDead" def __init__(self): self.health = 3 self.gun_loaded = True self.carrying = False self.turn = 0 def play(self, scores): return "derp" def inform(self, message): pass
148
105
22
7233481f8ec7679b8e29b77a5465fe46b86344a5
1,411
py
Python
supports/pyload/src/pyload/plugins/downloaders/UpfileVn.py
LuckyNicky/pycrawler
4b3fe2f6e8e51f236d95a64a89a44199e4e97743
[ "Apache-2.0" ]
1
2020-04-02T17:03:39.000Z
2020-04-02T17:03:39.000Z
supports/pyload/src/pyload/plugins/downloaders/UpfileVn.py
LuckyNicky/pycrawler
4b3fe2f6e8e51f236d95a64a89a44199e4e97743
[ "Apache-2.0" ]
null
null
null
supports/pyload/src/pyload/plugins/downloaders/UpfileVn.py
LuckyNicky/pycrawler
4b3fe2f6e8e51f236d95a64a89a44199e4e97743
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- import hashlib import json from ..base.simple_downloader import SimpleDownloader
30.021277
85
0.589653
# -*- coding: utf-8 -*- import hashlib import json from ..base.simple_downloader import SimpleDownloader class UpfileVn(SimpleDownloader): __name__ = "UpfileVn" __type__ = "downloader" __version__ = "0.01" __status__ = "testing" __pyload_version__ = "0.5" __pattern__ = r"http://(?:www\.)?u...
389
891
23
abdcb13dbeb10c79ea899fce759d4e09bf099f86
4,664
py
Python
ee/clickhouse/queries/funnels/funnel.py
alx-a/posthog
a76959bb2a7640ca8cf367a4d3a0e4ca67f65a5e
[ "MIT" ]
null
null
null
ee/clickhouse/queries/funnels/funnel.py
alx-a/posthog
a76959bb2a7640ca8cf367a4d3a0e4ca67f65a5e
[ "MIT" ]
null
null
null
ee/clickhouse/queries/funnels/funnel.py
alx-a/posthog
a76959bb2a7640ca8cf367a4d3a0e4ca67f65a5e
[ "MIT" ]
null
null
null
from typing import List from ee.clickhouse.queries.funnels.base import ClickhouseFunnelBase
37.015873
153
0.60699
from typing import List from ee.clickhouse.queries.funnels.base import ClickhouseFunnelBase class ClickhouseFunnel(ClickhouseFunnelBase): def get_query(self): steps_per_person_query = self.get_step_counts_query() max_steps = len(self._filter.entities) breakdown_clause = self._get_breakd...
4,309
24
238
4c42fcf3fa9eca6388488f41cdf35bf3faab311d
2,082
py
Python
src/service/music_list_service.py
kanbang/music-player
852e65f112b887fb13d75c2a6184dc6570db141f
[ "MIT" ]
null
null
null
src/service/music_list_service.py
kanbang/music-player
852e65f112b887fb13d75c2a6184dc6570db141f
[ "MIT" ]
null
null
null
src/service/music_list_service.py
kanbang/music-player
852e65f112b887fb13d75c2a6184dc6570db141f
[ "MIT" ]
null
null
null
import time from src.dao.music_dao import MusicDao from src.dao.music_list_dao import MusicListDao from src.entity.music import Music from src.entity.music_list import MusicList from src.service.play_list import PlayList if __name__ == "__main__": pass
30.173913
74
0.654179
import time from src.dao.music_dao import MusicDao from src.dao.music_list_dao import MusicListDao from src.entity.music import Music from src.entity.music_list import MusicList from src.service.play_list import PlayList class MusicListService: def __init__(self) -> None: super().__init__() self....
114
1,864
23
48ca1c27c02cf5e2ee05c667df25a6ceebb59255
2,055
py
Python
data_structures/queues.py
ahcode0919/python-ds-algorithms
0d617b78c50b6c18da40d9fa101438749bfc82e1
[ "MIT" ]
null
null
null
data_structures/queues.py
ahcode0919/python-ds-algorithms
0d617b78c50b6c18da40d9fa101438749bfc82e1
[ "MIT" ]
null
null
null
data_structures/queues.py
ahcode0919/python-ds-algorithms
0d617b78c50b6c18da40d9fa101438749bfc82e1
[ "MIT" ]
3
2020-10-07T20:24:45.000Z
2020-12-16T04:53:19.000Z
from typing import Generic, TypeVar, List from data_structures.doubly_linked_list import DoublyLinkedList T = TypeVar('T') class QueueList(Generic[T]): """ Basic queue backed with a list. Not optimal since list has O(N) complexity for inserting and removing elements at the beginning """ class Queue...
22.582418
82
0.56253
from typing import Generic, TypeVar, List from data_structures.doubly_linked_list import DoublyLinkedList T = TypeVar('T') class QueueList(Generic[T]): """ Basic queue backed with a list. Not optimal since list has O(N) complexity for inserting and removing elements at the beginning """ def __in...
837
555
237
03ce825503a2e97cd29f7c49f114542b8d2a2ae6
5,854
py
Python
models/networks/__init__.py
usama13o/codeServerEPI
de00366799ae533948b9318d05eaf44802b20fc4
[ "MIT" ]
null
null
null
models/networks/__init__.py
usama13o/codeServerEPI
de00366799ae533948b9318d05eaf44802b20fc4
[ "MIT" ]
null
null
null
models/networks/__init__.py
usama13o/codeServerEPI
de00366799ae533948b9318d05eaf44802b20fc4
[ "MIT" ]
null
null
null
from models.networks.nestedT import Nest from models.networks.swin_unet import SwinTransformerSys from models.networks.swin_transformer import SwinTransformer from models.networks.axialnet import axialunet, logo,MedT,gated from models.networks.vit_seg_modeling_gate import VisionTransformer_AG from .unet_2D import * fro...
48.380165
220
0.653058
from models.networks.nestedT import Nest from models.networks.swin_unet import SwinTransformerSys from models.networks.swin_transformer import SwinTransformer from models.networks.axialnet import axialunet, logo,MedT,gated from models.networks.vit_seg_modeling_gate import VisionTransformer_AG from .unet_2D import * fro...
5,023
0
46
6adc2f6f3c50593a9a72e68ac5dd03220aacffd5
1,766
py
Python
src/Modules/Web/web_rooms.py
bopopescu/PyHouse_1
6444ed0b4c38ab59b9e419e4d54d65d598e6a54e
[ "MIT" ]
1
2016-09-21T19:30:21.000Z
2016-09-21T19:30:21.000Z
src/Modules/Web/web_rooms.py
bopopescu/PyHouse_1
6444ed0b4c38ab59b9e419e4d54d65d598e6a54e
[ "MIT" ]
null
null
null
src/Modules/Web/web_rooms.py
bopopescu/PyHouse_1
6444ed0b4c38ab59b9e419e4d54d65d598e6a54e
[ "MIT" ]
1
2020-07-23T11:13:36.000Z
2020-07-23T11:13:36.000Z
""" -*- test-case-name: PyHouse.src.Modules.web.test.test_web_rooms -*- @name: PyHouse/src/Modules/web/web_rooms.py @author: D. Brian Kimmel @contact: D.BrianKimmel@gmail.com @copyright: (c) 2013-2016 by D. Brian Kimmel @license: MIT License @note: Created on Jun 3, 2013 @summary: Web interface to r...
30.448276
92
0.704417
""" -*- test-case-name: PyHouse.src.Modules.web.test.test_web_rooms -*- @name: PyHouse/src/Modules/web/web_rooms.py @author: D. Brian Kimmel @contact: D.BrianKimmel@gmail.com @copyright: (c) 2013-2016 by D. Brian Kimmel @license: MIT License @note: Created on Jun 3, 2013 @summary: Web interface to r...
164
701
23
43cd8d61fa8902b32ca154a5534033a5f854568f
9,222
py
Python
pybelt.py
srcecde/Pybelt
91c80cfceccababa4df9569934ee81745bf23855
[ "MIT" ]
2
2020-06-04T13:47:07.000Z
2020-07-02T19:19:44.000Z
pybelt.py
srcecde/Pybelt
91c80cfceccababa4df9569934ee81745bf23855
[ "MIT" ]
null
null
null
pybelt.py
srcecde/Pybelt
91c80cfceccababa4df9569934ee81745bf23855
[ "MIT" ]
3
2020-07-14T19:46:07.000Z
2022-02-20T14:09:45.000Z
import argparse import random import re import socket import sys from urllib2 import HTTPError # Libraries from lib.core.dork_check import DorkScanner from lib.core.errors import GoogleBlockException from lib.core.hash_cracking import HashCracker from lib.core.hash_cracking.hash_checker import HashChecker from lib.cor...
55.221557
120
0.619063
import argparse import random import re import socket import sys from urllib2 import HTTPError # Libraries from lib.core.dork_check import DorkScanner from lib.core.errors import GoogleBlockException from lib.core.hash_cracking import HashCracker from lib.core.hash_cracking.hash_checker import HashChecker from lib.cor...
0
0
0
e5278ee77cee868cac1bcc2773304ea0c522b306
658
py
Python
examples/models/train_gan.py
gugarosa/feelyng
95a427049b9b82b0f5bc2ad200443ae7fc85eb6c
[ "MIT" ]
1
2018-10-01T20:15:31.000Z
2018-10-01T20:15:31.000Z
examples/models/train_gan.py
gugarosa/feelyng
95a427049b9b82b0f5bc2ad200443ae7fc85eb6c
[ "MIT" ]
null
null
null
examples/models/train_gan.py
gugarosa/feelyng
95a427049b9b82b0f5bc2ad200443ae7fc85eb6c
[ "MIT" ]
1
2018-10-01T20:15:37.000Z
2018-10-01T20:15:37.000Z
import tensorflow as tf from nalp.datasets import ImageDataset from nalp.models import GAN # Loading the MNIST dataset (x, y), (_, _) = tf.keras.datasets.mnist.load_data() # Creating an Image Dataset dataset = ImageDataset(x, batch_size=256, shape=(x.shape[0], 784), normalize=True) # Creating the GAN gan = GAN(inpu...
25.307692
82
0.74772
import tensorflow as tf from nalp.datasets import ImageDataset from nalp.models import GAN # Loading the MNIST dataset (x, y), (_, _) = tf.keras.datasets.mnist.load_data() # Creating an Image Dataset dataset = ImageDataset(x, batch_size=256, shape=(x.shape[0], 784), normalize=True) # Creating the GAN gan = GAN(inpu...
0
0
0
e3caa2b096a2cc3e218c774d8cdd359537423390
291
py
Python
blog/migrations/0005_delete_image.py
BITS-SU-Tech-Team/Bloggers-Park
e3ace847728dd10d4bbb4a1a5196e73fb820c33f
[ "Apache-2.0" ]
null
null
null
blog/migrations/0005_delete_image.py
BITS-SU-Tech-Team/Bloggers-Park
e3ace847728dd10d4bbb4a1a5196e73fb820c33f
[ "Apache-2.0" ]
13
2019-06-24T22:52:41.000Z
2022-03-11T23:51:02.000Z
blog/migrations/0005_delete_image.py
BITS-SU-Tech-Team/Bloggers-Park
e3ace847728dd10d4bbb4a1a5196e73fb820c33f
[ "Apache-2.0" ]
1
2019-06-24T13:49:32.000Z
2019-06-24T13:49:32.000Z
# Generated by Django 2.2.2 on 2019-06-24 17:22 from django.db import migrations
17.117647
47
0.597938
# Generated by Django 2.2.2 on 2019-06-24 17:22 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('blog', '0004_auto_20190624_1325'), ] operations = [ migrations.DeleteModel( name='Image', ), ]
0
185
23
8ec06f1f58dcab1c890f561485a795d7c5260659
692
py
Python
oops_fhir/r4/value_set/communication_not_done_reason.py
Mikuana/oops_fhir
77963315d123756b7d21ae881f433778096a1d25
[ "MIT" ]
null
null
null
oops_fhir/r4/value_set/communication_not_done_reason.py
Mikuana/oops_fhir
77963315d123756b7d21ae881f433778096a1d25
[ "MIT" ]
null
null
null
oops_fhir/r4/value_set/communication_not_done_reason.py
Mikuana/oops_fhir
77963315d123756b7d21ae881f433778096a1d25
[ "MIT" ]
null
null
null
from pathlib import Path from fhir.resources.valueset import ValueSet as _ValueSet from oops_fhir.utils import ValueSet from oops_fhir.r4.code_system.communication_not_done_reason import ( CommunicationNotDoneReason as CommunicationNotDoneReason_, ) __all__ = ["CommunicationNotDoneReason"] _resource = _Value...
22.322581
69
0.768786
from pathlib import Path from fhir.resources.valueset import ValueSet as _ValueSet from oops_fhir.utils import ValueSet from oops_fhir.r4.code_system.communication_not_done_reason import ( CommunicationNotDoneReason as CommunicationNotDoneReason_, ) __all__ = ["CommunicationNotDoneReason"] _resource = _Value...
0
19
27
159d69e092c7c06a1c59413f9d0f8c186024d90e
1,562
py
Python
loafang/methods.py
Adwaith-Rajesh/loafang
2ccea64ddbc19b7a4ba5219ec2bb5185919146be
[ "MIT" ]
3
2021-11-17T13:32:21.000Z
2021-11-27T04:20:48.000Z
loafang/methods.py
Adwaith-Rajesh/loafang
2ccea64ddbc19b7a4ba5219ec2bb5185919146be
[ "MIT" ]
null
null
null
loafang/methods.py
Adwaith-Rajesh/loafang
2ccea64ddbc19b7a4ba5219ec2bb5185919146be
[ "MIT" ]
null
null
null
from argparse import Namespace from typing import Any from typing import Dict from typing import List from typing import Optional from typing import TYPE_CHECKING if TYPE_CHECKING: from .query import QueryBuilder # this class is what is used to generate the output for the each query in the execution block
33.956522
93
0.699104
from argparse import Namespace from typing import Any from typing import Dict from typing import List from typing import Optional from typing import TYPE_CHECKING if TYPE_CHECKING: from .query import QueryBuilder class MethodsError(Exception): def __init__(self, code: int = 614, msg: str = "Some error occur...
984
2
261
df2bac2b00ccb8f1edd7c14ed2cb9499563f7387
506
py
Python
editfilterloganalyzer.py
mmiyer/galobot
363b29949f8b3fde1cbe7fe5b12b2305ba16d89e
[ "MIT" ]
null
null
null
editfilterloganalyzer.py
mmiyer/galobot
363b29949f8b3fde1cbe7fe5b12b2305ba16d89e
[ "MIT" ]
null
null
null
editfilterloganalyzer.py
mmiyer/galobot
363b29949f8b3fde1cbe7fe5b12b2305ba16d89e
[ "MIT" ]
null
null
null
import regex from botbase import * args = sys.argv query = p.data.api.ListGenerator("abuselog", aflprop = "details", aflfilter = args[1], site = site) query.set_maximum_items(args[2]) query.set_query_increment(50) extra = r".{,100}" pattern = regex.compile (r"(?V1)"+extra+r"(?:"+input("Regex: ")+r")"+extra, flags = ...
26.631579
101
0.687747
import regex from botbase import * args = sys.argv query = p.data.api.ListGenerator("abuselog", aflprop = "details", aflfilter = args[1], site = site) query.set_maximum_items(args[2]) query.set_query_increment(50) extra = r".{,100}" pattern = regex.compile (r"(?V1)"+extra+r"(?:"+input("Regex: ")+r")"+extra, flags = ...
0
0
0
4ce3a45dc2403bf404442eb68925427a762761d6
13,337
py
Python
figaxe.py
trwaters/FigAxe
445efff4e371593e1f74a8bddf59df1c8eef71f0
[ "MIT" ]
null
null
null
figaxe.py
trwaters/FigAxe
445efff4e371593e1f74a8bddf59df1c8eef71f0
[ "MIT" ]
null
null
null
figaxe.py
trwaters/FigAxe
445efff4e371593e1f74a8bddf59df1c8eef71f0
[ "MIT" ]
null
null
null
import warnings import numpy as np import pylab as plt from matplotlib.gridspec import GridSpec from matplotlib.cbook import mplDeprecation from mpl_toolkits.axes_grid1.axes_divider import make_axes_locatable # always reload gridspec_helper.py from importlib import reload import gridspec_helper; reload(gridspec_helper...
32.608802
88
0.554398
import warnings import numpy as np import pylab as plt from matplotlib.gridspec import GridSpec from matplotlib.cbook import mplDeprecation from mpl_toolkits.axes_grid1.axes_divider import make_axes_locatable # always reload gridspec_helper.py from importlib import reload import gridspec_helper; reload(gridspec_helper...
4,963
0
133
c08f47427a1e26148637bf9fbbea5f0a40bd7b06
3,434
py
Python
node_editor/dataframe_model/dataframe_viewer.py
lcopey/node_editor
04d56ae4c7f2149e46903d5dd2e46f3906ef69e6
[ "MIT" ]
1
2021-04-30T11:28:42.000Z
2021-04-30T11:28:42.000Z
node_editor/dataframe_model/dataframe_viewer.py
lcopey/node_editor
04d56ae4c7f2149e46903d5dd2e46f3906ef69e6
[ "MIT" ]
null
null
null
node_editor/dataframe_model/dataframe_viewer.py
lcopey/node_editor
04d56ae4c7f2149e46903d5dd2e46f3906ef69e6
[ "MIT" ]
null
null
null
from PyQt5.QtWidgets import * from PyQt5.QtCore import Qt, QObject, QEvent from .datatable_view import DataTableView from .datatable_header import HeaderView import pandas as pd from typing import Dict, List, Union, Iterable, Any
46.405405
114
0.7053
from PyQt5.QtWidgets import * from PyQt5.QtCore import Qt, QObject, QEvent from .datatable_view import DataTableView from .datatable_header import HeaderView import pandas as pd from typing import Dict, List, Union, Iterable, Any class DataFrameView(QWidget): def __init__(self, parent=None, dataframe: Union[pd.D...
2,718
461
23
ae9283d998a172604db6e5e5629ab4fc7791ece9
509
py
Python
rock_paper_scissors_matrix.py
Welf06/Beginnner_Projects
61e1c56f3bd7497c4b711a52053fec6f21f67fe1
[ "MIT" ]
1
2022-01-22T15:53:01.000Z
2022-01-22T15:53:01.000Z
rock_paper_scissors_matrix.py
Welf06/Beginnner_Projects
61e1c56f3bd7497c4b711a52053fec6f21f67fe1
[ "MIT" ]
null
null
null
rock_paper_scissors_matrix.py
Welf06/Beginnner_Projects
61e1c56f3bd7497c4b711a52053fec6f21f67fe1
[ "MIT" ]
null
null
null
from random import randint # 0: draw 1:lost 2:won matrix = [[0,1,2], [2,0,1], [1,2,0]] choices = ["rock", "paper", "scissors"] choice_map = {"rock": 0, "paper":1, "scissors":2} comp_choice = randint(0,2) user_choice = input("Please choose rock, paper or scissors:\n").lower().strip() user_choice = ch...
29.941176
79
0.660118
from random import randint # 0: draw 1:lost 2:won matrix = [[0,1,2], [2,0,1], [1,2,0]] choices = ["rock", "paper", "scissors"] choice_map = {"rock": 0, "paper":1, "scissors":2} comp_choice = randint(0,2) user_choice = input("Please choose rock, paper or scissors:\n").lower().strip() user_choice = ch...
0
0
0
568666d43f7e69a8b4e0515dd2bd2eda64ce2beb
5,254
py
Python
rcnn/core/loader.py
sjiang17/keypoint-maskrcnn
f78562d4701a57fe1b95ba56f946e33658d7d039
[ "Apache-2.0" ]
3
2018-12-13T09:00:01.000Z
2019-09-11T03:38:02.000Z
rcnn/core/loader.py
sjiang17/keypoint-maskrcnn
f78562d4701a57fe1b95ba56f946e33658d7d039
[ "Apache-2.0" ]
null
null
null
rcnn/core/loader.py
sjiang17/keypoint-maskrcnn
f78562d4701a57fe1b95ba56f946e33658d7d039
[ "Apache-2.0" ]
1
2019-12-01T09:22:36.000Z
2019-12-01T09:22:36.000Z
import mxnet as mx import numpy as np import Queue import threading import time from rcnn.io.rpn import get_rpn_testbatch
30.905882
113
0.584888
import mxnet as mx import numpy as np import Queue import threading import time from rcnn.io.rpn import get_rpn_testbatch class SequentialLoader(mx.io.DataIter): def __init__(self, iters): super(SequentialLoader, self).__init__() self.iters = iters self.exhausted = [False] * len(iters) ...
4,513
570
46
dd8fc399d77c2364a5be739c2a28cec119cf2378
206
py
Python
assignments/catclasstest.py
noelleclement/pythoncourse
37d6b26aaf7c8d4537f13fd1b92bfa2d5e4d5128
[ "MIT" ]
null
null
null
assignments/catclasstest.py
noelleclement/pythoncourse
37d6b26aaf7c8d4537f13fd1b92bfa2d5e4d5128
[ "MIT" ]
null
null
null
assignments/catclasstest.py
noelleclement/pythoncourse
37d6b26aaf7c8d4537f13fd1b92bfa2d5e4d5128
[ "MIT" ]
null
null
null
cat = Cat('Harry', 2) cat.speak()
20.6
71
0.61165
class Cat: def __init__ (self, name, age): self.name = name self.age = age def speak (self): print('Miauw! I am', self.name, 'and I am', self.age, 'year(s) old!') cat = Cat('Harry', 2) cat.speak()
114
-11
69
c63819c77e268341d2f61286224b9527ed992ac2
1,631
py
Python
models.py
piller-imre/notte
9303252e0f4806532a27dee5e830928b37a27065
[ "MIT" ]
null
null
null
models.py
piller-imre/notte
9303252e0f4806532a27dee5e830928b37a27065
[ "MIT" ]
null
null
null
models.py
piller-imre/notte
9303252e0f4806532a27dee5e830928b37a27065
[ "MIT" ]
null
null
null
import json from app import db class Note(db.Model): """A note about an information item""" __tablename__ = 'notes' id = db.Column(db.Integer, primary_key=True) location = db.Column(db.String, nullable=None) description = db.Column(db.String) tags = db.Column(db.String) def to_dict(self...
28.12069
80
0.621704
import json from app import db class Note(db.Model): """A note about an information item""" __tablename__ = 'notes' id = db.Column(db.Integer, primary_key=True) location = db.Column(db.String, nullable=None) description = db.Column(db.String) tags = db.Column(db.String) def to_dict(self...
0
0
0
0bbb45ce3759533fcc1286711302711cf7b9e0ad
4,405
py
Python
main_vrp.py
MichaelAllen1966/2004_covid_dialysis
62c6842fc14acee07aee12ac2f238cbd1c3881d6
[ "MIT" ]
null
null
null
main_vrp.py
MichaelAllen1966/2004_covid_dialysis
62c6842fc14acee07aee12ac2f238cbd1c3881d6
[ "MIT" ]
1
2020-05-15T11:11:53.000Z
2020-05-15T11:11:53.000Z
main_vrp.py
MichaelAllen1966/2004_covid_dialysis
62c6842fc14acee07aee12ac2f238cbd1c3881d6
[ "MIT" ]
null
null
null
import pandas as pd import numpy as np from joblib import Parallel, delayed import vrp.io as io import vrp.constructive as c import vrp.sim as sim from vrp.constructive import SequentialClarkeWright from vrp.sim import ILSWithConstructive def multiple_replications(scenario, n_reps=10, n_jobs=1): ''' Multiple...
32.873134
79
0.556186
import pandas as pd import numpy as np from joblib import Parallel, delayed import vrp.io as io import vrp.constructive as c import vrp.sim as sim from vrp.constructive import SequentialClarkeWright from vrp.sim import ILSWithConstructive def multiple_replications(scenario, n_reps=10, n_jobs=1): ''' Multiple...
0
0
0
5f51a5119f89bbb5389aa873cec2bb5a5146cff8
32
py
Python
asce/engine/env.py
sbeddall/azure-storage-console-explorer
19320cb34a4391534dbc945464db590e87911bfd
[ "MIT" ]
null
null
null
asce/engine/env.py
sbeddall/azure-storage-console-explorer
19320cb34a4391534dbc945464db590e87911bfd
[ "MIT" ]
null
null
null
asce/engine/env.py
sbeddall/azure-storage-console-explorer
19320cb34a4391534dbc945464db590e87911bfd
[ "MIT" ]
null
null
null
INPUT_FIELD_NAME = "input_data"
16
31
0.8125
INPUT_FIELD_NAME = "input_data"
0
0
0
ec27606d9eaaf608050ed7907e49a666f66dfc69
90
py
Python
abc/088/a/answer.py
TakuyaNoguchi/atcoder
d079402e6fe9c9aaf3a6fc9272331ee71fc497da
[ "MIT" ]
null
null
null
abc/088/a/answer.py
TakuyaNoguchi/atcoder
d079402e6fe9c9aaf3a6fc9272331ee71fc497da
[ "MIT" ]
null
null
null
abc/088/a/answer.py
TakuyaNoguchi/atcoder
d079402e6fe9c9aaf3a6fc9272331ee71fc497da
[ "MIT" ]
null
null
null
N, A = int(input()), int(input()) if N % 500 <= A: print('Yes') else: print('No')
15
33
0.488889
N, A = int(input()), int(input()) if N % 500 <= A: print('Yes') else: print('No')
0
0
0
3e25f9b2f74f6e87f28136e40188056eea27f5f2
11,614
py
Python
pyramid/security.py
danielpronych/pyramid-doxygen
ad95a8c151c2c4e029e03aed2feda2993380f36f
[ "BSD-2-Clause" ]
null
null
null
pyramid/security.py
danielpronych/pyramid-doxygen
ad95a8c151c2c4e029e03aed2feda2993380f36f
[ "BSD-2-Clause" ]
null
null
null
pyramid/security.py
danielpronych/pyramid-doxygen
ad95a8c151c2c4e029e03aed2feda2993380f36f
[ "BSD-2-Clause" ]
null
null
null
from zope.interface import providedBy from pyramid.interfaces import ( IAuthenticationPolicy, IAuthorizationPolicy, ISecuredView, IView, IViewClassifier, ) from pyramid.compat import map_ from pyramid.threadlocal import get_current_registry Everyone = 'system.Everyone' Authenticated = 'system...
39.104377
78
0.670312
from zope.interface import providedBy from pyramid.interfaces import ( IAuthenticationPolicy, IAuthorizationPolicy, ISecuredView, IView, IViewClassifier, ) from pyramid.compat import map_ from pyramid.threadlocal import get_current_registry Everyone = 'system.Everyone' Authenticated = 'system...
1,242
253
124
18039515b6df32233c7d79ef59e2763cfecc0af7
7,530
py
Python
src/client.py
jasonzliang/dcs
3ead5d744b73e1b1335709242af67c8da1c1f99d
[ "Unlicense" ]
null
null
null
src/client.py
jasonzliang/dcs
3ead5d744b73e1b1335709242af67c8da1c1f99d
[ "Unlicense" ]
null
null
null
src/client.py
jasonzliang/dcs
3ead5d744b73e1b1335709242af67c8da1c1f99d
[ "Unlicense" ]
null
null
null
import os, time, sys, random, string, subprocess, pprint from server import DEFAULT_CONFIG from util import Logger, getTime, full_path, randString, updateConfig from queue import FIFOQueue, TaskObject, ShortestTaskQueue if __name__ == "__main__": if len(sys.argv) < 2: c = CompletionServiceClient() elif len(sy...
37.277228
94
0.678619
import os, time, sys, random, string, subprocess, pprint from server import DEFAULT_CONFIG from util import Logger, getTime, full_path, randString, updateConfig from queue import FIFOQueue, TaskObject, ShortestTaskQueue class CompletionServiceClient(object): def __init__(self, config_file=None, runmode="local"): ...
6,790
17
247
fc2c0be438a7783eb9290dad118370b68ccf561a
6,882
py
Python
eth_account/_utils/keyfile.py
KyrinCode/python-sdk
57dd02388d6b8552ad346d72838c2fd8177fec65
[ "MIT" ]
61
2019-07-03T07:40:17.000Z
2022-03-06T13:30:53.000Z
eth_account/_utils/keyfile.py
KyrinCode/python-sdk
57dd02388d6b8552ad346d72838c2fd8177fec65
[ "MIT" ]
105
2019-07-25T08:48:59.000Z
2022-03-23T03:47:34.000Z
eth_account/_utils/keyfile.py
KyrinCode/python-sdk
57dd02388d6b8552ad346d72838c2fd8177fec65
[ "MIT" ]
61
2019-07-03T06:58:42.000Z
2022-02-16T08:50:14.000Z
import hashlib import hmac import json import uuid import os from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes from cryptography.hazmat.backends import default_backend from Crypto.Protocol.KDF import scrypt from eth_keys import keys from eth_utils import ( big_endian_to_int, decode_...
25.583643
89
0.643272
import hashlib import hmac import json import uuid import os from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes from cryptography.hazmat.backends import default_backend from Crypto.Protocol.KDF import scrypt from eth_keys import keys from eth_utils import ( big_endian_to_int, decode_...
5,916
0
342
e9e016a5503cb2ea79dc209a5bd222a928df7e20
3,857
py
Python
nets/coco_dataset.py
MrYYYYYYYYYYY/SESF-Fuse
1b7789dc880c53d2400f94ce794a0292d82908a3
[ "MIT" ]
1
2020-06-18T05:45:57.000Z
2020-06-18T05:45:57.000Z
nets/coco_dataset.py
MrYYYYYYYYYYY/SESF-Fuse
1b7789dc880c53d2400f94ce794a0292d82908a3
[ "MIT" ]
null
null
null
nets/coco_dataset.py
MrYYYYYYYYYYY/SESF-Fuse
1b7789dc880c53d2400f94ce794a0292d82908a3
[ "MIT" ]
null
null
null
import os import random import cv2 import numpy as np import PIL.Image from torch.utils.data.dataset import Dataset from torch.utils.data import DataLoader import torchvision.transforms as transforms from nets.nets_utility import * import torchvision.transforms.functional as F if __name__ == "__main__": batch_si...
35.385321
120
0.667617
import os import random import cv2 import numpy as np import PIL.Image from torch.utils.data.dataset import Dataset from torch.utils.data import DataLoader import torchvision.transforms as transforms from nets.nets_utility import * import torchvision.transforms.functional as F class COCODataset(Dataset): def __in...
2,166
6
238
5ef047db2e3e6be89c15f240798dbc89b1924c5f
11,169
py
Python
src/optimizations/thumbnailcache.py
etianen/django-optimizations
c9614c3eeb1cb3482eb2db84d3951356d7fb44a3
[ "BSD-3-Clause" ]
12
2015-05-06T21:34:11.000Z
2021-07-31T04:49:25.000Z
src/optimizations/thumbnailcache.py
etianen/django-optimizations
c9614c3eeb1cb3482eb2db84d3951356d7fb44a3
[ "BSD-3-Clause" ]
3
2015-02-11T16:23:13.000Z
2018-04-17T09:07:36.000Z
src/optimizations/thumbnailcache.py
etianen/django-optimizations
c9614c3eeb1cb3482eb2db84d3951356d7fb44a3
[ "BSD-3-Clause" ]
4
2015-02-11T10:21:31.000Z
2019-07-24T20:29:28.000Z
"""A cache for thumbnailed images.""" from __future__ import unicode_literals import collections import sys import os.path try: from io import BytesIO as StringIO except Exception as e: from cStringIO import StringIO from PIL import Image from django.core.files.base import File from optimizations.assetcach...
34.260736
118
0.627451
"""A cache for thumbnailed images.""" from __future__ import unicode_literals import collections import sys import os.path try: from io import BytesIO as StringIO except Exception as e: from cStringIO import StringIO from PIL import Image from django.core.files.base import File from optimizations.assetcach...
74
0
26
f0d267b4e4bdf64ad2e8d8fd6d788dcbaa4efd87
8,034
py
Python
GAN/src/evaluate.py
efikalti/2D-Level-Generator
a63571761922e98e0748841bbaa9a7173b5de5fd
[ "Apache-2.0" ]
null
null
null
GAN/src/evaluate.py
efikalti/2D-Level-Generator
a63571761922e98e0748841bbaa9a7173b5de5fd
[ "Apache-2.0" ]
null
null
null
GAN/src/evaluate.py
efikalti/2D-Level-Generator
a63571761922e98e0748841bbaa9a7173b5de5fd
[ "Apache-2.0" ]
null
null
null
import numpy as np from models import Vector, Bounds from data_info import TILE_TYPES, DUNGEON_DIMENSION
35.39207
80
0.562609
import numpy as np from models import Vector, Bounds from data_info import TILE_TYPES, DUNGEON_DIMENSION class Evaluator: def __init__(self): self.data = np.ndarray(shape=(DUNGEON_DIMENSION, DUNGEON_DIMENSION), dtype=int) self.rooms = None ...
7,554
-5
373
aa8f8f04fa420c881e5266dc7126668c63864f34
1,483
py
Python
practica03/bcd.py
kyordhel/FSEm
4082a99e06d624807a8f9ef9febfb746df508b95
[ "MIT" ]
1
2020-03-01T19:59:19.000Z
2020-03-01T19:59:19.000Z
practica03/bcd.py
kyordhel/FSEm
4082a99e06d624807a8f9ef9febfb746df508b95
[ "MIT" ]
null
null
null
practica03/bcd.py
kyordhel/FSEm
4082a99e06d624807a8f9ef9febfb746df508b95
[ "MIT" ]
1
2020-02-17T19:40:13.000Z
2020-02-17T19:40:13.000Z
#!/usr/bin/env python3 # ## ############################################### # # pwm.py # Controls a 7-segments display using Raspberry Pi # and a 74LS47 driver # # Autor: Mauricio Matamoros # License: MIT # # ## ############################################### # Future imports (Python 2.7 compatibility) from __future__...
28.519231
68
0.685098
#!/usr/bin/env python3 # ## ############################################### # # pwm.py # Controls a 7-segments display using Raspberry Pi # and a 74LS47 driver # # Autor: Mauricio Matamoros # License: MIT # # ## ############################################### # Future imports (Python 2.7 compatibility) from __future__...
269
0
22
869b1c8b1d268cf1f323c55eb2573d0c5fb000b3
1,325
py
Python
error_posts/migrations/0001_initial.py
vintasoftware/curly-enigma
7248f93dbe2ba22e4f883786189215cea7cf72d5
[ "MIT" ]
null
null
null
error_posts/migrations/0001_initial.py
vintasoftware/curly-enigma
7248f93dbe2ba22e4f883786189215cea7cf72d5
[ "MIT" ]
null
null
null
error_posts/migrations/0001_initial.py
vintasoftware/curly-enigma
7248f93dbe2ba22e4f883786189215cea7cf72d5
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations
35.810811
203
0.53434
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ] operations = [ migrations.CreateModel( name='Answer', fields=[ ('id', models.AutoField(verbo...
0
1,195
23
646cda1ef782adb1a1d7fa97f0ecb6580d5d0f1f
1,971
py
Python
ESRGAN.py
DavidInWuhanChina/CartoonizerTheWorldUsingTFLite
e11ec9e38495815753498896d20a2a790fe57127
[ "MIT" ]
5
2020-10-21T01:41:52.000Z
2022-01-25T09:19:40.000Z
ESRGAN.py
DavidInWuhanChina/CartoonizerTheWorldUsingTFLite
e11ec9e38495815753498896d20a2a790fe57127
[ "MIT" ]
null
null
null
ESRGAN.py
DavidInWuhanChina/CartoonizerTheWorldUsingTFLite
e11ec9e38495815753498896d20a2a790fe57127
[ "MIT" ]
1
2020-12-09T11:41:52.000Z
2020-12-09T11:41:52.000Z
import tensorflow as tf import cv2 import numpy as np from PIL import Image import matplotlib.pyplot as plt #Utility for image loading and prepeocessing\ #Load the image low_res_image = load_img('./cartoonized_image.jpg', None, './cartoonized_image.jpg') #Load the model interpreter = tf.lite.Interpreter(model_path=f...
28.157143
84
0.695586
import tensorflow as tf import cv2 import numpy as np from PIL import Image import matplotlib.pyplot as plt #Utility for image loading and prepeocessing\ def load_img(path_to_img, scale_factor=4, save_path="downsampled_image.jpg"): img = tf.io.read_file(path_to_img) img = tf.io.decode_image(img, channels=3) ...
914
0
45
99a7c36f53fc1ce7c13d1155fc9ca3918a1bd3c3
365
py
Python
Problem 045.py
Junipyr/Project-Euler
dcc97636d27e9f16a6f80b361689c6bfbd943751
[ "FSFAP" ]
null
null
null
Problem 045.py
Junipyr/Project-Euler
dcc97636d27e9f16a6f80b361689c6bfbd943751
[ "FSFAP" ]
null
null
null
Problem 045.py
Junipyr/Project-Euler
dcc97636d27e9f16a6f80b361689c6bfbd943751
[ "FSFAP" ]
null
null
null
# We iterate hexagonal numbers and check whether they are pentagonal. # By definition, every hexagonal number is a triangle number. import math n_h = 144 n_p = 0.5 while not n_p.is_integer(): h = n_h*(2*n_h - 1) n_p = (1 + math.sqrt(1 + 24*h))/6 n_h += 1 print(h) # Copyright Junipyr. All r...
19.210526
70
0.652055
# We iterate hexagonal numbers and check whether they are pentagonal. # By definition, every hexagonal number is a triangle number. import math n_h = 144 n_p = 0.5 while not n_p.is_integer(): h = n_h*(2*n_h - 1) n_p = (1 + math.sqrt(1 + 24*h))/6 n_h += 1 print(h) # Copyright Junipyr. All r...
0
0
0
eaaf9f99b660cf1b71324ade15ae7f3431377cd8
498
py
Python
webapp/drf_network_pipeline/index.py
jay-johnson/train-ai-with-django-swagger-jwt
3cdd798709b02047eadebccbe2fc9b855cfcac4f
[ "Apache-2.0" ]
79
2018-02-03T08:41:08.000Z
2022-02-01T20:22:04.000Z
webapp/drf_network_pipeline/index.py
webclinic017/train-ai-with-django-swagger-jwt
3cdd798709b02047eadebccbe2fc9b855cfcac4f
[ "Apache-2.0" ]
1
2020-10-26T12:05:25.000Z
2020-10-26T12:05:25.000Z
webapp/drf_network_pipeline/index.py
webclinic017/train-ai-with-django-swagger-jwt
3cdd798709b02047eadebccbe2fc9b855cfcac4f
[ "Apache-2.0" ]
23
2018-04-10T10:57:58.000Z
2021-12-05T02:59:06.000Z
from django.conf import settings from django.shortcuts import render def handle_sphinx_doc_index( request, data=None): """handle_sphinx_doc_index Generic handler for sending the browser to the sphinx documentation index: <repo>/webapp/drf_network_pipeline/docs/build/html/index.html ...
22.636364
65
0.714859
from django.conf import settings from django.shortcuts import render def handle_sphinx_doc_index( request, data=None): """handle_sphinx_doc_index Generic handler for sending the browser to the sphinx documentation index: <repo>/webapp/drf_network_pipeline/docs/build/html/index.html ...
0
0
0
e4519bb6f3cd7df82f7f6b54f3cd148f37b9349d
2,900
py
Python
qa/tasks/object_source_down.py
rpratap-bot/ceph
9834961a66927ae856935591f2fd51082e2ee484
[ "MIT" ]
4
2020-04-08T03:42:02.000Z
2020-10-01T20:34:48.000Z
qa/tasks/object_source_down.py
rpratap-bot/ceph
9834961a66927ae856935591f2fd51082e2ee484
[ "MIT" ]
93
2020-03-26T14:29:14.000Z
2020-11-12T05:54:55.000Z
qa/tasks/object_source_down.py
rpratap-bot/ceph
9834961a66927ae856935591f2fd51082e2ee484
[ "MIT" ]
23
2020-03-24T10:28:44.000Z
2020-09-24T09:42:19.000Z
""" Test Object locations going down """ import logging import time from teuthology import misc as teuthology from tasks import ceph_manager from tasks.util.rados import rados log = logging.getLogger(__name__) def task(ctx, config): """ Test handling of object location going down """ if config is None...
28.431373
81
0.632069
""" Test Object locations going down """ import logging import time from teuthology import misc as teuthology from tasks import ceph_manager from tasks.util.rados import rados log = logging.getLogger(__name__) def task(ctx, config): """ Test handling of object location going down """ if config is None...
0
0
0
f2091cfb8c032872fbd4bfe35f203cdfbc4a433f
1,178
py
Python
data/server/king_phisher/alembic/versions/b76eab0a059_schema_v7.py
chachabooboo/king-phisher
8a91b9043de0f12b5cad9a5f1d64ebd0179a6c4d
[ "BSD-3-Clause" ]
1,143
2015-01-12T15:05:16.000Z
2020-04-12T16:10:19.000Z
data/server/king_phisher/alembic/versions/b76eab0a059_schema_v7.py
chachabooboo/king-phisher
8a91b9043de0f12b5cad9a5f1d64ebd0179a6c4d
[ "BSD-3-Clause" ]
399
2015-01-22T15:20:03.000Z
2020-04-08T23:01:46.000Z
data/server/king_phisher/alembic/versions/b76eab0a059_schema_v7.py
chachabooboo/king-phisher
8a91b9043de0f12b5cad9a5f1d64ebd0179a6c4d
[ "BSD-3-Clause" ]
351
2015-02-02T21:39:38.000Z
2020-03-21T11:45:20.000Z
"""Schema v7 Revision ID: b76eab0a059 Revises: a695de64338 Create Date: 2016-12-07 """ # revision identifiers, used by Alembic. revision = 'b76eab0a059' down_revision = 'a695de64338' import os import sys sys.path.insert(1, os.path.abspath(os.path.join(os.path.dirname(__file__), *['..'] * 5))) from alembic import o...
25.608696
89
0.763158
"""Schema v7 Revision ID: b76eab0a059 Revises: a695de64338 Create Date: 2016-12-07 """ # revision identifiers, used by Alembic. revision = 'b76eab0a059' down_revision = 'a695de64338' import os import sys sys.path.insert(1, os.path.abspath(os.path.join(os.path.dirname(__file__), *['..'] * 5))) from alembic import o...
728
0
46
d3d2dfaebf5c667bae583950e27af7876490b277
815
py
Python
openpose_ros2/setup.py
Rits-Interaction-Laboratory/openpose_ros2
9771501e9a37cc8a6a22077af24b839e30c96da4
[ "MIT" ]
1
2021-12-20T22:46:33.000Z
2021-12-20T22:46:33.000Z
openpose_ros2/setup.py
Rits-Interaction-Laboratory/openpose_ros2
9771501e9a37cc8a6a22077af24b839e30c96da4
[ "MIT" ]
null
null
null
openpose_ros2/setup.py
Rits-Interaction-Laboratory/openpose_ros2
9771501e9a37cc8a6a22077af24b839e30c96da4
[ "MIT" ]
null
null
null
import os from glob import glob from setuptools import setup package_name = 'openpose_ros2' setup( name=package_name, version='1.0.0', packages=[package_name], data_files=[ ('share/ament_index/resource_index/packages', ['resource/' + package_name]), ('share/' + package_nam...
26.290323
67
0.634356
import os from glob import glob from setuptools import setup package_name = 'openpose_ros2' setup( name=package_name, version='1.0.0', packages=[package_name], data_files=[ ('share/ament_index/resource_index/packages', ['resource/' + package_name]), ('share/' + package_nam...
0
0
0
37ef8dbdb1b299a1aa2830d0d07751f700d1cedb
791
py
Python
abstrys/cli/cascading_cli_time.py
EronHennessey/abstrys-cli-demos
36c12dfd85930737ad170256b10f60d85552a90d
[ "BSD-2-Clause" ]
null
null
null
abstrys/cli/cascading_cli_time.py
EronHennessey/abstrys-cli-demos
36c12dfd85930737ad170256b10f60d85552a90d
[ "BSD-2-Clause" ]
null
null
null
abstrys/cli/cascading_cli_time.py
EronHennessey/abstrys-cli-demos
36c12dfd85930737ad170256b10f60d85552a90d
[ "BSD-2-Clause" ]
null
null
null
# # "Cascading CLI" pattern "time" CLI # # This CLI provides a "time" command for the main CLI. import time from abstrys.cli.common import CliCommand class TimeCommand(CliCommand): """ A CLI command that returns the current time. """ def set_up_parser(self, parser): """ Set up the ti...
21.972222
65
0.553729
# # "Cascading CLI" pattern "time" CLI # # This CLI provides a "time" command for the main CLI. import time from abstrys.cli.common import CliCommand class TimeCommand(CliCommand): """ A CLI command that returns the current time. """ def set_up_parser(self, parser): """ Set up the ti...
0
0
0
41a00d16dda5f2a2558b68f5bf967f3b5fd71fe2
313
py
Python
src/riot_games_api/models/champion_mastery.py
esbraff/riot_games_api
09d2e0f90190e30d16b69f68577dbb27b7568db8
[ "MIT" ]
null
null
null
src/riot_games_api/models/champion_mastery.py
esbraff/riot_games_api
09d2e0f90190e30d16b69f68577dbb27b7568db8
[ "MIT" ]
null
null
null
src/riot_games_api/models/champion_mastery.py
esbraff/riot_games_api
09d2e0f90190e30d16b69f68577dbb27b7568db8
[ "MIT" ]
null
null
null
from .base import BaseModel
22.357143
41
0.760383
from .base import BaseModel class ChampionMasteryDto(BaseModel): champion_points_until_next_level: int chest_granted: bool champion_id: int last_play_time: int champion_level: int summoner_id: str champion_points: int champion_points_since_last_level: int tokens_earned: int
0
261
23
29b3ac4e270f15f7ffef63281dc071489155dcaa
2,217
py
Python
main.py
ride90/asyncio-opencv-face-detection
e2c2a24aa0803372dfe53ed47847034abfd6852f
[ "MIT" ]
2
2021-06-26T04:09:47.000Z
2022-02-20T22:52:09.000Z
main.py
ride90/asyncio-opencv-face-detection
e2c2a24aa0803372dfe53ed47847034abfd6852f
[ "MIT" ]
null
null
null
main.py
ride90/asyncio-opencv-face-detection
e2c2a24aa0803372dfe53ed47847034abfd6852f
[ "MIT" ]
1
2022-02-20T22:52:26.000Z
2022-02-20T22:52:26.000Z
import os import ssl import cv2 as cv import numpy as np from distutils.util import strtobool import aiohttp from aiohttp import web import jinja2 import aiohttp_jinja2 from camera import VideoCamera # settings DEBUG = strtobool(os.environ.get('DEBUG', 'True')) PORT = int(os.environ.get('PORT', 8088)) SSL = strtobo...
28.423077
86
0.678394
import os import ssl import cv2 as cv import numpy as np from distutils.util import strtobool import aiohttp from aiohttp import web import jinja2 import aiohttp_jinja2 from camera import VideoCamera # settings DEBUG = strtobool(os.environ.get('DEBUG', 'True')) PORT = int(os.environ.get('PORT', 8088)) SSL = strtobo...
964
0
44
fc335f673564a1327a64ecbfbe3fdf83500ccdb6
18,992
py
Python
routenet/routenet.py
thebambooguy/net2vec
918d86b2612570be50d46b2ce165902ea8717cad
[ "BSD-3-Clause" ]
11
2019-08-19T15:45:25.000Z
2021-02-14T02:41:33.000Z
routenet/routenet.py
thebambooguy/net2vec
918d86b2612570be50d46b2ce165902ea8717cad
[ "BSD-3-Clause" ]
null
null
null
routenet/routenet.py
thebambooguy/net2vec
918d86b2612570be50d46b2ce165902ea8717cad
[ "BSD-3-Clause" ]
7
2019-01-18T10:44:52.000Z
2021-04-12T13:20:28.000Z
# Copyright (c) 2018-2019, Krzysztof Rusek # 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 above copyright notice, this # list of conditions an...
38.290323
143
0.627896
# Copyright (c) 2018-2019, Krzysztof Rusek # 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 above copyright notice, this # list of conditions an...
11,869
2,282
184
ac82214017517f35f91fae61c2f6889f9a66a956
1,375
py
Python
Modules/find_mean_stddev.py
roshantac/EVA4-Phase2
8950dc6eeafbe1996a259cab876593e4be0d6c04
[ "Apache-2.0" ]
null
null
null
Modules/find_mean_stddev.py
roshantac/EVA4-Phase2
8950dc6eeafbe1996a259cab876593e4be0d6c04
[ "Apache-2.0" ]
null
null
null
Modules/find_mean_stddev.py
roshantac/EVA4-Phase2
8950dc6eeafbe1996a259cab876593e4be0d6c04
[ "Apache-2.0" ]
2
2020-08-26T02:33:33.000Z
2021-03-16T10:51:40.000Z
"""Code to calculate the mean and standard deviation of dataset. Author: Srinivasan G """ import os from PIL import Image import numpy as np import time def find_mean_standard_deviation(image_dir): """Return the mean and standard deviation of dataset. Mean and Standard Deviation required for image normaliza...
25.462963
65
0.597818
"""Code to calculate the mean and standard deviation of dataset. Author: Srinivasan G """ import os from PIL import Image import numpy as np import time def find_mean_standard_deviation(image_dir): """Return the mean and standard deviation of dataset. Mean and Standard Deviation required for image normaliza...
0
0
0
be93036802da23efa93b1f0162d7d51f89a12fe1
2,338
py
Python
ocr.py
mftnakrsu/Comparison-of-OCR
abbb731ed83ddcae3cf0a6d95d09e849f5cdeaa7
[ "MIT" ]
10
2022-03-02T20:22:47.000Z
2022-03-20T20:40:48.000Z
ocr.py
mftnakrsu/Comparison-of-OCR
abbb731ed83ddcae3cf0a6d95d09e849f5cdeaa7
[ "MIT" ]
null
null
null
ocr.py
mftnakrsu/Comparison-of-OCR
abbb731ed83ddcae3cf0a6d95d09e849f5cdeaa7
[ "MIT" ]
null
null
null
import cv2 import os import keras_ocr import numpy as np import pytesseract import easyocr import matplotlib.pyplot as plt
33.884058
92
0.608212
import cv2 import os import keras_ocr import numpy as np import pytesseract import easyocr import matplotlib.pyplot as plt class OCR(): def __init__(self,image_folder): self.image_folder= image_folder self.images = self.load_images_from_folder() self.pipeline = self._keras_mod...
1,976
-9
232
c029406c5aaf7addcbf5ff3376bf284011749e0e
108
py
Python
information-disclosure/exploiting/infoleak-via-backup-files.py
brandonaltermatt/penetration-testing-scripts
433b5d000a5573e60b9d8e49932cedce74937ebc
[ "MIT" ]
null
null
null
information-disclosure/exploiting/infoleak-via-backup-files.py
brandonaltermatt/penetration-testing-scripts
433b5d000a5573e60b9d8e49932cedce74937ebc
[ "MIT" ]
null
null
null
information-disclosure/exploiting/infoleak-via-backup-files.py
brandonaltermatt/penetration-testing-scripts
433b5d000a5573e60b9d8e49932cedce74937ebc
[ "MIT" ]
null
null
null
""" https://portswigger.net/web-security/information-disclosure/exploiting/lab-infoleak-via-backup-files """
36
100
0.796296
""" https://portswigger.net/web-security/information-disclosure/exploiting/lab-infoleak-via-backup-files """
0
0
0
dfbf5ce98be5b26c4c6b1c59117d7883be44ca49
12,922
py
Python
trafcap/trafcapEthernetPacket.py
protectus/pfring-to-mongo
60410d61a8e0b7ed4417cbb40782d169412aa4e0
[ "MIT" ]
2
2020-04-10T22:08:22.000Z
2020-04-19T15:50:00.000Z
trafcap/trafcapEthernetPacket.py
protectus/pfring-to-mongo
60410d61a8e0b7ed4417cbb40782d169412aa4e0
[ "MIT" ]
null
null
null
trafcap/trafcapEthernetPacket.py
protectus/pfring-to-mongo
60410d61a8e0b7ed4417cbb40782d169412aa4e0
[ "MIT" ]
null
null
null
# trafcapEthernetPacket.py # # Copyright (c) 2013 Protectus,LLC. All Rights Reserved. # # Classes to help pull data off the wire and update mongo import subprocess import time from trafcap import trafcap from datetime import datetime import traceback import sys class EthernetPacket(object): """ Parent class f...
35.795014
140
0.468426
# trafcapEthernetPacket.py # # Copyright (c) 2013 Protectus,LLC. All Rights Reserved. # # Classes to help pull data off the wire and update mongo import subprocess import time from trafcap import trafcap from datetime import datetime import traceback import sys class EthernetPacket(object): """ Parent class f...
8,965
0
468
37e7e593de6685542e3e030b269ca8e3b27e52c5
1,126
py
Python
addon_common/common/ui_settings.py
Unnoen/retopoflow
73c7cfc10a0b58937198d60e308ba5248b446490
[ "OML" ]
1,600
2015-03-19T12:26:15.000Z
2022-03-30T21:07:37.000Z
addon_common/common/ui_settings.py
Unnoen/retopoflow
73c7cfc10a0b58937198d60e308ba5248b446490
[ "OML" ]
1,026
2015-03-18T22:17:42.000Z
2022-03-28T17:47:04.000Z
addon_common/common/ui_settings.py
Unnoen/retopoflow
73c7cfc10a0b58937198d60e308ba5248b446490
[ "OML" ]
241
2015-03-19T13:44:36.000Z
2022-03-30T21:07:39.000Z
''' Copyright (C) 2021 CG Cookie http://cgcookie.com hello@cgcookie.com Created by Jonathan Denning, Jonathan Williamson This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 ...
31.277778
84
0.714032
''' Copyright (C) 2021 CG Cookie http://cgcookie.com hello@cgcookie.com Created by Jonathan Denning, Jonathan Williamson This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 ...
0
0
0
11c80539e1f577ca6dd67fdb56d31c90276d1a98
1,518
py
Python
modules/extra_tabs/messages.py
sharabeshj/course-editor-test
9af15d10ef1f039fdf5758134a7cb72384ccf3f5
[ "Apache-2.0" ]
1
2021-01-06T17:58:30.000Z
2021-01-06T17:58:30.000Z
modules/extra_tabs/messages.py
priyankagohil/coursebuilder-assessment
559e867a2a846dd773471c6bc76cf6005a57098f
[ "Apache-2.0" ]
27
2016-08-31T19:04:46.000Z
2016-09-29T00:22:32.000Z
modules/extra_tabs/messages.py
priyankagohil/coursebuilder-assessment
559e867a2a846dd773471c6bc76cf6005a57098f
[ "Apache-2.0" ]
null
null
null
# Copyright 2015 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ...
33
78
0.754941
# Copyright 2015 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ...
0
0
0
b1820fe9945cb2cf6cb5c29d3823e9a9f74f657a
344
py
Python
Codility_18.py
Bartoshko/codility-python-training
5ac53e85948692c8e6c44090e68b93136b263f9c
[ "MIT" ]
null
null
null
Codility_18.py
Bartoshko/codility-python-training
5ac53e85948692c8e6c44090e68b93136b263f9c
[ "MIT" ]
null
null
null
Codility_18.py
Bartoshko/codility-python-training
5ac53e85948692c8e6c44090e68b93136b263f9c
[ "MIT" ]
null
null
null
# works 100% Size = [4,3,2,1,5] Dir = [0,1,0,0,0] print(solution(Size, Dir))
13.76
26
0.526163
# works 100% Size = [4,3,2,1,5] Dir = [0,1,0,0,0] def solution(A, B): alive = 0 stack = [] for i in range(len(A)): if B[i] == 0: while len(stack) != 0: if stack[-1] > A[i]: break else: stack.pop() else: alive += 1 else: stack.append(A[i]) alive += len(stack) return alive pr...
240
0
23
14c0f59a7b99c781c33ae604239995f0eff72b48
3,629
py
Python
benchmark_on_flyingthings3d.py
tlkvstepan/PracticalDeepStereo_NIPS2018
1f76b4bf414cbde6f9cd976f9d80189ab5414286
[ "BSD-2-Clause" ]
63
2018-11-01T23:02:45.000Z
2021-11-22T11:45:34.000Z
benchmark_on_flyingthings3d.py
tlkvstepan/PracticalDeepStereo_NIPS2018
1f76b4bf414cbde6f9cd976f9d80189ab5414286
[ "BSD-2-Clause" ]
5
2019-01-16T20:41:21.000Z
2021-07-19T08:11:34.000Z
benchmark_on_flyingthings3d.py
tlkvstepan/PracticalDeepStereo_NIPS2018
1f76b4bf414cbde6f9cd976f9d80189ab5414286
[ "BSD-2-Clause" ]
9
2019-01-07T09:06:58.000Z
2021-03-04T08:49:31.000Z
#!/usr/bin/env python # Copyrights. All rights reserved. # ECOLE POLYTECHNIQUE FEDERALE DE LAUSANNE, Switzerland, # Space Center (eSpace), 2018 # See the LICENSE.TXT file for more details. """Script performs benchmarking on flyingthings3D. Benchmarking in performed with maximum disparity of 191 on 960 x 540 full-size ...
37.412371
79
0.754202
#!/usr/bin/env python # Copyrights. All rights reserved. # ECOLE POLYTECHNIQUE FEDERALE DE LAUSANNE, Switzerland, # Space Center (eSpace), 2018 # See the LICENSE.TXT file for more details. """Script performs benchmarking on flyingthings3D. Benchmarking in performed with maximum disparity of 191 on 960 x 540 full-size ...
1,147
0
45
e8933f646021766d3f668951c3d416b918378a09
1,623
py
Python
datasets/imagenet_dog.py
balansky/pytorch_gan
92999f1e65d819486e0e36182a7df5920fa63393
[ "MIT" ]
20
2018-11-03T12:45:42.000Z
2021-04-19T21:02:32.000Z
datasets/imagenet_dog.py
balansky/pytorch_gan
92999f1e65d819486e0e36182a7df5920fa63393
[ "MIT" ]
1
2018-12-02T11:03:18.000Z
2019-01-30T16:08:38.000Z
datasets/imagenet_dog.py
balansky/pytorch_gan
92999f1e65d819486e0e36182a7df5920fa63393
[ "MIT" ]
6
2019-01-01T15:46:35.000Z
2020-06-20T11:09:46.000Z
from datasets.dataset import Dataset from torchvision import datasets, transforms import torch import random
30.055556
97
0.59581
from datasets.dataset import Dataset from torchvision import datasets, transforms import torch import random class Crop(object): def __init__(self, augmentation=True, crop_ratio=0.9): self.augmentation = augmentation self.crop_ratio = crop_ratio def __call__(self, img): w, h = img.si...
1,348
11
150
553d00c82cf03aa407e69294b108eebe1fc8c7bd
13,063
py
Python
tc_gan/tests/test_legacy_drivers.py
ahmadianlab/tc-gan
06c549e8ae74bc6af62fddeed698565ea1f548c5
[ "MIT" ]
4
2019-06-04T08:15:43.000Z
2020-10-03T13:59:15.000Z
tc_gan/tests/test_legacy_drivers.py
ahmadianlab/tc-gan
06c549e8ae74bc6af62fddeed698565ea1f548c5
[ "MIT" ]
null
null
null
tc_gan/tests/test_legacy_drivers.py
ahmadianlab/tc-gan
06c549e8ae74bc6af62fddeed698565ea1f548c5
[ "MIT" ]
null
null
null
from __future__ import print_function from types import SimpleNamespace from unittest import mock import collections import functools import io import lasagne import numpy as np import pytest from .. import drivers from .. import execution from .. import recorders from ..execution import DataTables, DataStore from ....
31.251196
78
0.642502
from __future__ import print_function from types import SimpleNamespace from unittest import mock import collections import functools import io import lasagne import numpy as np import pytest from .. import drivers from .. import execution from .. import recorders from ..execution import DataTables, DataStore from ....
10,443
1,144
620
d588f6a87c411fe8a97c1726c5e01863027c6a64
2,393
py
Python
tests/tester/test_tester.py
Rajpratik71/workload-collocation-agent
6cf7bdab97ff61d85c21c3effecea632a225c668
[ "Apache-2.0" ]
40
2019-05-16T16:42:33.000Z
2021-11-18T06:33:03.000Z
tests/tester/test_tester.py
Rajpratik71/workload-collocation-agent
6cf7bdab97ff61d85c21c3effecea632a225c668
[ "Apache-2.0" ]
72
2019-05-09T02:30:25.000Z
2020-11-17T09:24:44.000Z
tests/tester/test_tester.py
Rajpratik71/workload-collocation-agent
6cf7bdab97ff61d85c21c3effecea632a225c668
[ "Apache-2.0" ]
26
2019-05-20T09:13:38.000Z
2021-12-15T17:57:21.000Z
# Copyright (c) 2019 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 # # Unless required by applicable law or agreed to in w...
35.191176
74
0.708734
# Copyright (c) 2019 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 # # Unless required by applicable law or agreed to in w...
1,443
0
22
0ba0916da11f6bbefd8774301e4b2968769533b2
800
py
Python
web/addons/product_email_template/__openerp__.py
diogocs1/comps
63df07f6cf21c41e4527c06e2d0499f23f4322e7
[ "Apache-2.0" ]
1
2019-12-29T11:53:56.000Z
2019-12-29T11:53:56.000Z
odoo/addons/product_email_template/__openerp__.py
tuanquanghpvn/odoo8-tutorial
52d25f1ca5f233c431cb9d3b24b79c3b4fb5127e
[ "MIT" ]
null
null
null
odoo/addons/product_email_template/__openerp__.py
tuanquanghpvn/odoo8-tutorial
52d25f1ca5f233c431cb9d3b24b79c3b4fb5127e
[ "MIT" ]
3
2020-10-08T14:42:10.000Z
2022-01-28T14:12:29.000Z
# -*- coding: utf-8 -*- { 'name': 'Product Email Template', 'depends': ['account'], 'author': 'OpenERP SA', 'category': 'Accounting & Finance', 'description': """ Add email templates to products to be send on invoice confirmation ================================================================== W...
30.769231
120
0.58875
# -*- coding: utf-8 -*- { 'name': 'Product Email Template', 'depends': ['account'], 'author': 'OpenERP SA', 'category': 'Accounting & Finance', 'description': """ Add email templates to products to be send on invoice confirmation ================================================================== W...
0
0
0
79bbfbe61ecf71e337f284e6424613fdda0a101c
1,789
py
Python
data_gen/gen_walls.py
yifan-you-37/rl_swiss
8b0ee7caa5c1fa93860916004cf4fd970667764f
[ "MIT" ]
56
2019-10-20T03:09:02.000Z
2022-03-25T09:21:40.000Z
data_gen/gen_walls.py
yifan-you-37/rl_swiss
8b0ee7caa5c1fa93860916004cf4fd970667764f
[ "MIT" ]
3
2020-10-01T07:33:51.000Z
2021-05-12T03:40:57.000Z
data_gen/gen_walls.py
yifan-you-37/rl_swiss
8b0ee7caa5c1fa93860916004cf4fd970667764f
[ "MIT" ]
10
2019-11-04T16:56:09.000Z
2022-03-25T09:21:41.000Z
import numpy as np WALL_LEN = 20.0 NUM_PATHS = 8.0 WALL_FROM_CENTER = 8.0 TARGET_DIST = 25.0 xml_block = '<body mocap=\"true\" pos=\"{x} {y} 1\" euler="0 0 {z_rot}\">\n\ \t<geom type=\"box\" size=\"{wall_len} 0.5 2\" group=\"1\" condim=\"3\" conaffinity=\"1\"/>\n\ </body>' increments = 2*np.pi / NUM_PATHS half_incre...
29.816667
116
0.4673
import numpy as np WALL_LEN = 20.0 NUM_PATHS = 8.0 WALL_FROM_CENTER = 8.0 TARGET_DIST = 25.0 xml_block = '<body mocap=\"true\" pos=\"{x} {y} 1\" euler="0 0 {z_rot}\">\n\ \t<geom type=\"box\" size=\"{wall_len} 0.5 2\" group=\"1\" condim=\"3\" conaffinity=\"1\"/>\n\ </body>' increments = 2*np.pi / NUM_PATHS half_incre...
0
0
0
7817d63b4af50e8e1bedc94186b4695607af3f1c
6,554
py
Python
matrix_extrapolation/product_formula.py
ochsnerd/Hamiltonian_Extrapolation
a91e651a9515a22d6e279d567340182658bcd2f6
[ "Apache-2.0" ]
null
null
null
matrix_extrapolation/product_formula.py
ochsnerd/Hamiltonian_Extrapolation
a91e651a9515a22d6e279d567340182658bcd2f6
[ "Apache-2.0" ]
null
null
null
matrix_extrapolation/product_formula.py
ochsnerd/Hamiltonian_Extrapolation
a91e651a9515a22d6e279d567340182658bcd2f6
[ "Apache-2.0" ]
null
null
null
from abc import ABC, abstractmethod from typing import List from mpmath import eye, mpc, matrix from mpmath import expm as mp_expm from numpy import ndarray, identity from numpy.linalg import matrix_power from scipy.linalg import expm as scipy_expm from .matrices import Matrix class TrotterFirstOrder(ProductFormul...
30.915094
81
0.555081
from abc import ABC, abstractmethod from typing import List from mpmath import eye, mpc, matrix from mpmath import expm as mp_expm from numpy import ndarray, identity from numpy.linalg import matrix_power from scipy.linalg import expm as scipy_expm from .matrices import Matrix class ProductFormula(ABC): @abstra...
107
2,861
131
160199e61b9aad392c4d304bf1624d6ebd0c51ea
2,297
py
Python
cohesity_management_sdk/models/sql_server_instance_version.py
chandrashekar-cohesity/management-sdk-python
9e6ec99e8a288005804b808c4e9b19fd204e3a8b
[ "Apache-2.0" ]
1
2021-01-07T20:36:22.000Z
2021-01-07T20:36:22.000Z
cohesity_management_sdk/models/sql_server_instance_version.py
chandrashekar-cohesity/management-sdk-python
9e6ec99e8a288005804b808c4e9b19fd204e3a8b
[ "Apache-2.0" ]
null
null
null
cohesity_management_sdk/models/sql_server_instance_version.py
chandrashekar-cohesity/management-sdk-python
9e6ec99e8a288005804b808c4e9b19fd204e3a8b
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2019 Cohesity Inc. class SQLServerInstanceVersion(object): """Implementation of the 'SQLServerInstanceVersion' model. Specifies the Server Instance Version. Attributes: build (int): Specfies the build. major_version (int): Specfies the major version. ...
29.831169
81
0.605137
# -*- coding: utf-8 -*- # Copyright 2019 Cohesity Inc. class SQLServerInstanceVersion(object): """Implementation of the 'SQLServerInstanceVersion' model. Specifies the Server Instance Version. Attributes: build (int): Specfies the build. major_version (int): Specfies the major version. ...
0
0
0
5c2c1b5e629370daa360eddd5dff748492cdec4d
226
py
Python
fatorial.py
maledicente/codes-python
1ab2cb150ae66a21517147696029c46c6bd743ca
[ "MIT" ]
null
null
null
fatorial.py
maledicente/codes-python
1ab2cb150ae66a21517147696029c46c6bd743ca
[ "MIT" ]
null
null
null
fatorial.py
maledicente/codes-python
1ab2cb150ae66a21517147696029c46c6bd743ca
[ "MIT" ]
null
null
null
print("Entre com o numero: ") num=int(input()) print("Fatorial de ", num, " igual a:", fat(num))
18.833333
49
0.539823
def fat(n): resultado = 1 while n > 0: resultado = resultado * n n = n - 1 return resultado print("Entre com o numero: ") num=int(input()) print("Fatorial de ", num, " igual a:", fat(num))
104
0
22
9d330cf9d292d0b8040a67ff298de429b9a0dabf
220
py
Python
First_sentence.py
GloomyGhost-MosquitoSeal/AutoPoem
493813627bc03b745224d6a030085148bb748345
[ "MIT" ]
2
2020-03-02T16:21:02.000Z
2020-04-04T04:53:09.000Z
First_sentence.py
YuzukiTsuru/AutoPoem
493813627bc03b745224d6a030085148bb748345
[ "MIT" ]
null
null
null
First_sentence.py
YuzukiTsuru/AutoPoem
493813627bc03b745224d6a030085148bb748345
[ "MIT" ]
1
2021-09-27T16:19:30.000Z
2021-09-27T16:19:30.000Z
from AutoPoem.Model import * from config import Config if __name__ == '__main__': model = PoetryModel(Config) for i in range(3): # 给出第一句话进行预测 sen = model.predict_sen('山为斜好几,') print(sen)
22
41
0.631818
from AutoPoem.Model import * from config import Config if __name__ == '__main__': model = PoetryModel(Config) for i in range(3): # 给出第一句话进行预测 sen = model.predict_sen('山为斜好几,') print(sen)
0
0
0
44dca0edda4b24dea9c173c057ee7042eeb6b726
1,931
py
Python
simpa_tests/automatic_tests/test_device_UUID.py
IMSY-DKFZ/simpa
b8bddcf43a4bff2564f0ec208dc511b82e49bfb4
[ "MIT" ]
3
2022-03-14T15:40:09.000Z
2022-03-20T02:34:25.000Z
simpa_tests/automatic_tests/test_device_UUID.py
jgroehl/simpa
e56f0802e5a8555ee8bb139dd4f776025e7e9267
[ "MIT" ]
3
2022-03-18T07:19:12.000Z
2022-03-30T12:15:19.000Z
simpa_tests/automatic_tests/test_device_UUID.py
IMSY-DKFZ/simpa
b8bddcf43a4bff2564f0ec208dc511b82e49bfb4
[ "MIT" ]
null
null
null
# SPDX-FileCopyrightText: 2021 Division of Intelligent Medical Systems, DKFZ # SPDX-FileCopyrightText: 2021 Janek Groehl # SPDX-License-Identifier: MIT import unittest from simpa.core.device_digital_twins import RSOMExplorerP50 from simpa.core.device_digital_twins import InVision256TF from simpa.core.device_digital_tw...
47.097561
96
0.751424
# SPDX-FileCopyrightText: 2021 Division of Intelligent Medical Systems, DKFZ # SPDX-FileCopyrightText: 2021 Janek Groehl # SPDX-License-Identifier: MIT import unittest from simpa.core.device_digital_twins import RSOMExplorerP50 from simpa.core.device_digital_twins import InVision256TF from simpa.core.device_digital_tw...
1,381
19
50
86c2bac9524b083c2ef8d3f5794a22d814972f80
19,723
py
Python
ammf/core/box_8c_encoder.py
bangquanxie/ASM3D
09a6a6b51599e80dd7ef5226f326d58cf7b5de8e
[ "MIT" ]
1
2021-08-21T02:09:57.000Z
2021-08-21T02:09:57.000Z
ammf/core/box_8c_encoder.py
bangquanxie/ASM3D
09a6a6b51599e80dd7ef5226f326d58cf7b5de8e
[ "MIT" ]
null
null
null
ammf/core/box_8c_encoder.py
bangquanxie/ASM3D
09a6a6b51599e80dd7ef5226f326d58cf7b5de8e
[ "MIT" ]
null
null
null
import numpy as np import tensorflow as tf from ammf.core import format_checker from ammf.core import box_3d_encoder def np_box_3d_to_box_8co(box_3d): """Computes the 3D bounding box corner positions from Box3D format. The order of corners are preserved during this conversion. Args: box_3d: 1 x...
34.005172
79
0.586675
import numpy as np import tensorflow as tf from ammf.core import format_checker from ammf.core import box_3d_encoder def np_box_3d_to_box_8co(box_3d): """Computes the 3D bounding box corner positions from Box3D format. The order of corners are preserved during this conversion. Args: box_3d: 1 x...
0
0
0
2701b1af17d2048d5443870e37753ea10812487c
422
py
Python
app/Table.py
cothan/chinese-chess
f896efda7da2b448ffaa1e92ac04397014bde24a
[ "MIT" ]
null
null
null
app/Table.py
cothan/chinese-chess
f896efda7da2b448ffaa1e92ac04397014bde24a
[ "MIT" ]
null
null
null
app/Table.py
cothan/chinese-chess
f896efda7da2b448ffaa1e92ac04397014bde24a
[ "MIT" ]
null
null
null
"""Table Model.""" from config.database import Model from orator.orm import belongs_to class Table(Model): """Table Model.""" __fillable__ = ['user_id', 'oppo_id', 'token', 'move', 'completed', 'last_move_timestamp', 'next_id', 'owner', 'winner', 'msg'] __table__ = 'chesses' @bel...
24.823529
79
0.609005
"""Table Model.""" from config.database import Model from orator.orm import belongs_to class Table(Model): """Table Model.""" __fillable__ = ['user_id', 'oppo_id', 'token', 'move', 'completed', 'last_move_timestamp', 'next_id', 'owner', 'winner', 'msg'] __table__ = 'chesses' @bel...
48
0
26
7a76d2bc099d2e1456a2842f4260550cd89ee39c
9,929
py
Python
plots.py
982543386/Risk_aware_MEC_offloading
62c90954e52e6b37e0fba06ebad37c58f30125f4
[ "MIT" ]
17
2020-04-27T13:06:53.000Z
2022-03-30T06:55:12.000Z
plots.py
982543386/Risk_aware_MEC_offloading
62c90954e52e6b37e0fba06ebad37c58f30125f4
[ "MIT" ]
1
2021-06-01T11:02:55.000Z
2021-09-10T14:29:50.000Z
plots.py
vinPopulaire/Risk_aware_MEC_offloading
4dcbd8dd40b3d5d72132e05557e2b68f0b382131
[ "MIT" ]
8
2020-05-25T00:49:34.000Z
2022-02-09T07:35:20.000Z
''' Plot functions to graphically present simulation results ''' import numpy as np import matplotlib import matplotlib.pyplot as plt import matplotlib.lines as mlines from mpl_toolkits.axes_grid1 import host_subplot import mpl_toolkits.axisartist as AA def setup_plots(suptitle): ''' Basic setup of plots so ...
30.457055
106
0.640649
''' Plot functions to graphically present simulation results ''' import numpy as np import matplotlib import matplotlib.pyplot as plt import matplotlib.lines as mlines from mpl_toolkits.axes_grid1 import host_subplot import mpl_toolkits.axisartist as AA def setup_plots(suptitle): ''' Basic setup of plots so ...
0
0
0
d75fc0d051e1e3c9866e4b1dc02911cf7680e082
793
py
Python
src/front-end/lists/api_wrapper/users.py
rrickgauer/lists
371de6af332789ef386392fd24857702794d05a6
[ "Apache-2.0" ]
null
null
null
src/front-end/lists/api_wrapper/users.py
rrickgauer/lists
371de6af332789ef386392fd24857702794d05a6
[ "Apache-2.0" ]
67
2021-12-14T22:30:56.000Z
2022-03-15T18:28:27.000Z
src/front-end/lists/api_wrapper/users.py
rrickgauer/lists
371de6af332789ef386392fd24857702794d05a6
[ "Apache-2.0" ]
null
null
null
import requests from .base_wrapper import ApiWrapperBase, ApiUrls, RequestParms
30.5
63
0.461538
import requests from .base_wrapper import ApiWrapperBase, ApiUrls, RequestParms class ApiWrapperUsers(ApiWrapperBase): URL = ApiUrls.USERS #------------------------------------------------------ # Send POST /users request to the API #------------------------------------------------------ def post...
276
412
23
937dc813498bac4705b84d2b72b8a093f184bf7e
1,805
py
Python
sentiment/comments/views.py
Ernesttt/sentiment-analysis
60b8924457d35228d5a752d99dd6e786fb49ce55
[ "BSD-3-Clause" ]
1
2017-07-19T09:19:56.000Z
2017-07-19T09:19:56.000Z
sentiment/comments/views.py
Ernesttt/sentiment-analysis
60b8924457d35228d5a752d99dd6e786fb49ce55
[ "BSD-3-Clause" ]
null
null
null
sentiment/comments/views.py
Ernesttt/sentiment-analysis
60b8924457d35228d5a752d99dd6e786fb49ce55
[ "BSD-3-Clause" ]
null
null
null
from comments.serializers import CommentSerializer from django.http import Http404 from rest_framework.views import APIView from rest_framework.response import Response from rest_framework import status from classifier.classification import Classification from classifier.classification_json import JSONClassificationRes...
40.111111
110
0.708587
from comments.serializers import CommentSerializer from django.http import Http404 from rest_framework.views import APIView from rest_framework.response import Response from rest_framework import status from classifier.classification import Classification from classifier.classification_json import JSONClassificationRes...
0
0
0
51e75060e91f6e03ec3138c9f97b745b5f452370
7,191
py
Python
util/dataset.py
nonstop1962/pytorch-dental_age_estimation
9bbe72b0dbf83514d900aeebc511fcfd3ab17202
[ "MIT" ]
1
2021-04-20T17:22:39.000Z
2021-04-20T17:22:39.000Z
util/dataset.py
nonstop1962/pytorch-dental_age_estimation
9bbe72b0dbf83514d900aeebc511fcfd3ab17202
[ "MIT" ]
1
2022-03-14T10:55:54.000Z
2022-03-14T10:55:54.000Z
util/dataset.py
nonstop1962/pytorch-dental_age_estimation
9bbe72b0dbf83514d900aeebc511fcfd3ab17202
[ "MIT" ]
1
2022-01-31T09:03:44.000Z
2022-01-31T09:03:44.000Z
import os import sys from os.path import join as pjoin sys.path.append(os.path.join(os.path.dirname(__file__), "..")) import logging from PIL import Image import numpy as np import torch import torch.nn.functional as F from torch.utils import data from torchvision import transforms logger = logging.getLogger("Logg...
27.342205
95
0.550132
import os import sys from os.path import join as pjoin sys.path.append(os.path.join(os.path.dirname(__file__), "..")) import logging from PIL import Image import numpy as np import torch import torch.nn.functional as F from torch.utils import data from torchvision import transforms logger = logging.getLogger("Logg...
6,444
29
476
b2be1b1fa9fb7bf7b5377ac4fdb62588f6cde9e4
9,793
py
Python
Feature/AdaptedLesk.py
blodstone/CCS590v2
8cf5d487568116203816839bb76c800dc02331c1
[ "MIT" ]
null
null
null
Feature/AdaptedLesk.py
blodstone/CCS590v2
8cf5d487568116203816839bb76c800dc02331c1
[ "MIT" ]
null
null
null
Feature/AdaptedLesk.py
blodstone/CCS590v2
8cf5d487568116203816839bb76c800dc02331c1
[ "MIT" ]
null
null
null
''' Created on Feb 27, 2011 @author: Blodstone ''' from nltk.corpus import wordnet, stopwords from nltk.tokenize import word_tokenize import string import time from operator import itemgetter from IOPreprocessing.DataPreparation import DataRetrieval #definitely false but for testing sake ...
44.112613
295
0.529153
''' Created on Feb 27, 2011 @author: Blodstone ''' from nltk.corpus import wordnet, stopwords from nltk.tokenize import word_tokenize import string import time from operator import itemgetter from IOPreprocessing.DataPreparation import DataRetrieval class AdaptedLesk: def __init__(self,k): ...
8,463
-3
233
4d3b2b67ffedb3da13db63e0dc189cea59901a98
7,795
py
Python
gui/wellplot/toolbar/logsettingstoolbar.py
adriangrepo/qreservoir
20fba1b1fd1a42add223d9e8af2d267665bec493
[ "MIT" ]
2
2019-10-04T13:54:51.000Z
2021-05-21T19:36:15.000Z
gui/wellplot/toolbar/logsettingstoolbar.py
adriangrepo/qreservoir
20fba1b1fd1a42add223d9e8af2d267665bec493
[ "MIT" ]
3
2019-11-19T17:06:09.000Z
2020-01-18T20:39:54.000Z
gui/wellplot/toolbar/logsettingstoolbar.py
adriangrepo/qreservoir
20fba1b1fd1a42add223d9e8af2d267665bec493
[ "MIT" ]
2
2020-07-02T13:20:48.000Z
2020-11-11T00:18:51.000Z
from __future__ import absolute_import from PyQt4.QtGui import QToolBar, QLabel, QPixmap, QApplication, QCursor from PyQt4 import QtGui, QtCore from PyQt4.QtCore import pyqtSlot, Qt from views.core import centraltabwidget from gui.wellplot.subplots.wellplotwidget import WellPlotWidget from globalvalues.appsetting...
43.305556
155
0.708403
from __future__ import absolute_import from PyQt4.QtGui import QToolBar, QLabel, QPixmap, QApplication, QCursor from PyQt4 import QtGui, QtCore from PyQt4.QtCore import pyqtSlot, Qt from views.core import centraltabwidget from gui.wellplot.subplots.wellplotwidget import WellPlotWidget from globalvalues.appsetting...
5,546
1,367
147
894a3a1cf6d57faf1bd36d1eda4cba436fc31a29
4,661
py
Python
server.py
HananBar/esp8266_workshop
80cffb208fd3639e291db5d4349d627676e9819f
[ "MIT" ]
null
null
null
server.py
HananBar/esp8266_workshop
80cffb208fd3639e291db5d4349d627676e9819f
[ "MIT" ]
null
null
null
server.py
HananBar/esp8266_workshop
80cffb208fd3639e291db5d4349d627676e9819f
[ "MIT" ]
null
null
null
from flask import Flask, jsonify, request from flask_cors import CORS from pymongo import MongoClient from db_access import WorkshopDb from config_manager import ConfigManager from task01_connect import Task01_Connect from task02_static import Task02_StaticIp from task03_webserver import Task03_WebServer from task04_ap...
30.464052
104
0.646642
from flask import Flask, jsonify, request from flask_cors import CORS from pymongo import MongoClient from db_access import WorkshopDb from config_manager import ConfigManager from task01_connect import Task01_Connect from task02_static import Task02_StaticIp from task03_webserver import Task03_WebServer from task04_ap...
3,001
0
176
43c518103fc02ea05d97461bec0b5db564d45b29
6,752
py
Python
scapy/modules/nmap.py
kosciolek/J-Tracert
89ed802f700e02600138ad7132e6a856463620dd
[ "MIT" ]
3
2019-04-09T22:59:33.000Z
2019-06-14T09:23:24.000Z
scapy/modules/nmap.py
kosciolek/J-Tracert
89ed802f700e02600138ad7132e6a856463620dd
[ "MIT" ]
null
null
null
scapy/modules/nmap.py
kosciolek/J-Tracert
89ed802f700e02600138ad7132e6a856463620dd
[ "MIT" ]
1
2018-11-15T12:37:04.000Z
2018-11-15T12:37:04.000Z
## This file is part of Scapy ## See http://www.secdev.org/projects/scapy for more informations ## Copyright (C) Philippe Biondi <phil@secdev.org> ## This program is published under a GPLv2 license """Clone of Nmap's first generation OS fingerprinting. This code works with the first-generation OS detection and nmap-o...
30.414414
80
0.54843
## This file is part of Scapy ## See http://www.secdev.org/projects/scapy for more informations ## Copyright (C) Philippe Biondi <phil@secdev.org> ## This program is published under a GPLv2 license """Clone of Nmap's first generation OS fingerprinting. This code works with the first-generation OS detection and nmap-o...
4,745
0
186
3f2ea56d4d70ee4e15661743478b006703934d50
2,399
py
Python
infer.py
constanreedjohn/Dogs_Cats_Classification_Resnet50
cbe662e181144a4f6b2d99810200b5c944250341
[ "Apache-2.0" ]
null
null
null
infer.py
constanreedjohn/Dogs_Cats_Classification_Resnet50
cbe662e181144a4f6b2d99810200b5c944250341
[ "Apache-2.0" ]
null
null
null
infer.py
constanreedjohn/Dogs_Cats_Classification_Resnet50
cbe662e181144a4f6b2d99810200b5c944250341
[ "Apache-2.0" ]
null
null
null
from eval import load_model import torch import matplotlib.pyplot as plt from torchvision import transforms from torch.utils.data import DataLoader from PIL import Image import cv2 import argparse import os if __name__ == "__main__": device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu") print...
32.418919
127
0.604835
from eval import load_model import torch import matplotlib.pyplot as plt from torchvision import transforms from torch.utils.data import DataLoader from PIL import Image import cv2 import argparse import os def Inference(device, model, img_path, out_path): count = 0 if not os.path.exists(out_path): ...
1,730
0
58
dd5989ab7a6b1d8c7db0efc9678ea8c050ddc599
1,687
py
Python
adventofcode2020/08.py
matslindh/codingchallenges
b6792808b03ea07304fda7e74c874c2c4d200dac
[ "MIT" ]
2
2016-12-28T09:40:07.000Z
2020-12-08T13:58:15.000Z
adventofcode2020/08.py
matslindh/codingchallenges
b6792808b03ea07304fda7e74c874c2c4d200dac
[ "MIT" ]
null
null
null
adventofcode2020/08.py
matslindh/codingchallenges
b6792808b03ea07304fda7e74c874c2c4d200dac
[ "MIT" ]
null
null
null
import copy if __name__ == '__main__': print(parse_and_execute([x.strip() for x in open('input/08').readlines()])) print(parse_modify_and_execute([x.strip() for x in open('input/08').readlines()]))
24.808824
96
0.602845
import copy def parse(raw_instructions): instructions = [] for r_i in raw_instructions: p = r_i.split(' ') instructions.append( [p[0], int(p[1])] ) return instructions def parse_and_execute(raw_instructions): instructions = parse(raw_instructions) return exe...
1,337
0
138
4d0e6a700fdd100085067e81e7e3555f70d236cd
322
py
Python
webservice/manage.py
wilcarllopez/capstone
bdb984f93d020ffa7584fafd29cc8955b896eafb
[ "MIT" ]
null
null
null
webservice/manage.py
wilcarllopez/capstone
bdb984f93d020ffa7584fafd29cc8955b896eafb
[ "MIT" ]
1
2021-06-02T00:40:55.000Z
2021-06-02T00:40:55.000Z
webservice/manage.py
wilcarllopez/capstone
bdb984f93d020ffa7584fafd29cc8955b896eafb
[ "MIT" ]
null
null
null
import os from flask_script import Manager from flask_migrate import Migrate, MigrateCommand from app import app, db env_name = os.getenv('FLASK_ENV') app = app(env_name) migrate = Migrate(app=app, db=db) manager = Manager(app=app) manager.add_command('db', MigrateCommand) if __name__ == '__main__': manager.run(...
21.466667
49
0.757764
import os from flask_script import Manager from flask_migrate import Migrate, MigrateCommand from app import app, db env_name = os.getenv('FLASK_ENV') app = app(env_name) migrate = Migrate(app=app, db=db) manager = Manager(app=app) manager.add_command('db', MigrateCommand) if __name__ == '__main__': manager.run(...
0
0
0
341c9eba0762d38d517d439e95f02672cfe49104
12,779
py
Python
app/main/views.py
qingduyu/BackManager
4227ea7b3608c1f814e9496382772a3ace0dbff9
[ "Apache-2.0" ]
32
2016-11-10T12:59:53.000Z
2021-09-17T12:24:47.000Z
app/main/views.py
ljb-2000/BackManager
4227ea7b3608c1f814e9496382772a3ace0dbff9
[ "Apache-2.0" ]
1
2019-01-09T01:33:17.000Z
2019-01-09T01:33:17.000Z
app/main/views.py
linuxyan/BackManager
4227ea7b3608c1f814e9496382772a3ace0dbff9
[ "Apache-2.0" ]
33
2016-07-21T15:07:13.000Z
2022-01-07T07:44:19.000Z
#!/usr/bin/python # coding=utf-8 #__author__ = 'CY' from flask import render_template, request, flash,abort,redirect,url_for from flask.ext.login import login_required, current_user from . import main from .. import db from sqlalchemy import and_,desc,or_ from app.models import users,backhosts,customers,backar...
47.505576
170
0.649503
#!/usr/bin/python # coding=utf-8 #__author__ = 'CY' from flask import render_template, request, flash,abort,redirect,url_for from flask.ext.login import login_required, current_user from . import main from .. import db from sqlalchemy import and_,desc,or_ from app.models import users,backhosts,customers,backar...
11,501
0
254
ac025dac5cda286434f34519afebf46029bf14dd
1,816
py
Python
mirnet/model/residual_resizing_modules.py
prachigaikwad201994/https-github.com-prachi12345-MIRNet
c6812f5bc4ac87e4e63af21aa4e0db84597a17c8
[ "Apache-2.0" ]
78
2020-12-04T10:38:58.000Z
2022-03-22T09:16:53.000Z
mirnet/model/residual_resizing_modules.py
prachigaikwad201994/https-github.com-prachi12345-MIRNet
c6812f5bc4ac87e4e63af21aa4e0db84597a17c8
[ "Apache-2.0" ]
3
2021-01-14T21:46:34.000Z
2022-02-23T17:20:41.000Z
mirnet/model/residual_resizing_modules.py
prachigaikwad201994/https-github.com-prachi12345-MIRNet
c6812f5bc4ac87e4e63af21aa4e0db84597a17c8
[ "Apache-2.0" ]
26
2020-12-18T00:56:20.000Z
2022-03-13T19:30:19.000Z
import tensorflow as tf def down_sampling_module(input_tensor): """Downsampling Module""" channels = list(input_tensor.shape)[-1] main_branch = tf.keras.layers.Conv2D( channels, kernel_size=(1, 1))(input_tensor) main_branch = tf.nn.relu(main_branch) # main_branch = tf.keras.layers.Conv2D( ...
43.238095
69
0.689427
import tensorflow as tf def down_sampling_module(input_tensor): """Downsampling Module""" channels = list(input_tensor.shape)[-1] main_branch = tf.keras.layers.Conv2D( channels, kernel_size=(1, 1))(input_tensor) main_branch = tf.nn.relu(main_branch) # main_branch = tf.keras.layers.Conv2D( ...
0
0
0
7dafc93a1444426f1091e413070ddf8fef3aef98
3,032
py
Python
sqlsite/routing.py
j4mie/sqlsite
f2dadb8db5ed7880f8872b6591d8cb1487f777ea
[ "Unlicense" ]
192
2020-01-13T17:12:07.000Z
2021-08-13T21:44:38.000Z
sqlsite/routing.py
j4mie/sqlsite
f2dadb8db5ed7880f8872b6591d8cb1487f777ea
[ "Unlicense" ]
6
2020-01-12T15:55:32.000Z
2020-02-08T03:29:26.000Z
sqlsite/routing.py
j4mie/sqlsite
f2dadb8db5ed7880f8872b6591d8cb1487f777ea
[ "Unlicense" ]
3
2020-01-16T18:42:33.000Z
2022-02-06T23:21:38.000Z
from functools import lru_cache from sqlsite.database import install_function import re PATH_MATCH_FUNCTION_NAME = "PATH_MATCH" PATTERN_COMPONENT_RE = re.compile(r"<(?P<param_type>[a-z]+):(?P<param_name>[a-z_]+)>") PATTERN_PARAM_TYPES = { "str": "[^/]+", "int": "[0-9]+", "slug": "[-a-zA-Z0-9_]+", "u...
29.72549
86
0.637203
from functools import lru_cache from sqlsite.database import install_function import re PATH_MATCH_FUNCTION_NAME = "PATH_MATCH" PATTERN_COMPONENT_RE = re.compile(r"<(?P<param_type>[a-z]+):(?P<param_name>[a-z_]+)>") PATTERN_PARAM_TYPES = { "str": "[^/]+", "int": "[0-9]+", "slug": "[-a-zA-Z0-9_]+", "u...
718
103
73
ea35159cff103f93a7907f26ef238d5f98de108c
103
py
Python
corpusAnalyzer/apps.py
gisney-land/410_corpus_analysis
62c831cd44b5015021d8298dcac4e3d63a37cb79
[ "MIT" ]
3
2019-03-23T08:32:54.000Z
2019-04-13T01:42:53.000Z
corpusAnalyzer/apps.py
gisney-land/410_corpus_analysis
62c831cd44b5015021d8298dcac4e3d63a37cb79
[ "MIT" ]
null
null
null
corpusAnalyzer/apps.py
gisney-land/410_corpus_analysis
62c831cd44b5015021d8298dcac4e3d63a37cb79
[ "MIT" ]
1
2021-03-29T12:07:02.000Z
2021-03-29T12:07:02.000Z
from django.apps import AppConfig
17.166667
38
0.786408
from django.apps import AppConfig class CorpusanalyzerConfig(AppConfig): name = 'corpusAnalyzer'
0
45
23
f4bdd6e3b86836c5fb0f99888a4715b01e1da4c4
6,169
py
Python
apply/src/awsqs_kubernetes_resource/vpc.py
aws-quickstart/quickstart-kubernetes-resource-provider
f54ddce8f89cd3996b0ba79f1a0ada1945e8c539
[ "Apache-2.0" ]
11
2020-08-18T19:20:27.000Z
2022-01-30T16:17:06.000Z
apply/src/awsqs_kubernetes_resource/vpc.py
aws-quickstart/quickstart-kubernetes-resource-provider
f54ddce8f89cd3996b0ba79f1a0ada1945e8c539
[ "Apache-2.0" ]
23
2020-10-21T12:46:36.000Z
2022-03-31T23:19:45.000Z
apply/src/awsqs_kubernetes_resource/vpc.py
aws-quickstart/quickstart-kubernetes-resource-provider
f54ddce8f89cd3996b0ba79f1a0ada1945e8c539
[ "Apache-2.0" ]
11
2020-11-06T09:46:03.000Z
2022-03-06T12:00:24.000Z
import boto3 import os import traceback from string import ascii_lowercase from random import choice import json import logging import time from typing import Optional, Union from pathlib import Path from cloudformation_cli_python_lib import SessionProxy, exceptions LOG = logging.getLogger(__name__) LOG.setLevel(logg...
36.502959
120
0.64662
import boto3 import os import traceback from string import ascii_lowercase from random import choice import json import logging import time from typing import Optional, Union from pathlib import Path from cloudformation_cli_python_lib import SessionProxy, exceptions LOG = logging.getLogger(__name__) LOG.setLevel(logg...
5,646
0
184