hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
⌀
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
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
⌀
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
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
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
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
0895d3a47be9f7b36dc0b49c5fb8546a7291b006
39
py
Python
fsdet/data/__init__.py
artificially-ai/few-shot-object-detection
2233934871a4a54ad59f6688db074c3f99ae8b87
[ "Apache-2.0" ]
null
null
null
fsdet/data/__init__.py
artificially-ai/few-shot-object-detection
2233934871a4a54ad59f6688db074c3f99ae8b87
[ "Apache-2.0" ]
null
null
null
fsdet/data/__init__.py
artificially-ai/few-shot-object-detection
2233934871a4a54ad59f6688db074c3f99ae8b87
[ "Apache-2.0" ]
null
null
null
from .builtin import register_all_coco
19.5
38
0.871795
ea4933c305ff524a12830749467fc1c4a818b981
3,602
py
Python
docker/scripts/hardware/component/network.py
parauliya/osie
1f0714bf422d7f0c3ce2795b05e36e8638a670d5
[ "Apache-2.0" ]
null
null
null
docker/scripts/hardware/component/network.py
parauliya/osie
1f0714bf422d7f0c3ce2795b05e36e8638a670d5
[ "Apache-2.0" ]
null
null
null
docker/scripts/hardware/component/network.py
parauliya/osie
1f0714bf422d7f0c3ce2795b05e36e8638a670d5
[ "Apache-2.0" ]
null
null
null
import utils from lxml import etree from component.component import Component class Network(Component): @classmethod def list(cls, lshw): xpath = etree.XPath("//node[@class='network'][@handle!=''][logicalname]") networks = [] for network in xpath(lshw): if utils.xml_ev(l...
36.02
161
0.574125
1f704b0da880dbde4b09bf2cc108edb034d7b1a0
45,184
py
Python
research/neural_gpu/neural_gpu_trainer.py
873040/Abhishek
2ddd716e66bc5cc6e6f0787508dd07da0e02e75a
[ "Apache-2.0" ]
3,326
2018-01-26T22:42:25.000Z
2022-02-16T13:16:39.000Z
research/neural_gpu/neural_gpu_trainer.py
873040/Abhishek
2ddd716e66bc5cc6e6f0787508dd07da0e02e75a
[ "Apache-2.0" ]
150
2017-08-28T14:59:36.000Z
2022-03-11T23:21:35.000Z
research/neural_gpu/neural_gpu_trainer.py
873040/Abhishek
2ddd716e66bc5cc6e6f0787508dd07da0e02e75a
[ "Apache-2.0" ]
1,474
2018-02-01T04:33:18.000Z
2022-03-08T07:02:20.000Z
# 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 a...
43.953307
80
0.637239
1646649fae01b6ea07abcc37bc05ad471c72a951
6,185
py
Python
tensorlib/tools.py
pengyuan/markov2tensor
4bcdcba6273dc7b671d81953da934188135dbca3
[ "MIT" ]
1
2018-03-20T08:28:25.000Z
2018-03-20T08:28:25.000Z
tensorlib/tools.py
pengyuan/markov2tensor
4bcdcba6273dc7b671d81953da934188135dbca3
[ "MIT" ]
null
null
null
tensorlib/tools.py
pengyuan/markov2tensor
4bcdcba6273dc7b671d81953da934188135dbca3
[ "MIT" ]
2
2015-12-16T07:21:15.000Z
2018-03-20T08:28:27.000Z
#!/usr/bin/env python import numpy; import cmath; import math; def prod(arg): """ returns the product of elements in arg. arg can be list, tuple, set, and array with numerical values. """ ret = 1; for i in range(0,len(arg)): ret = ret * arg[i]; return ret; def allIndices(dim): """ Fr...
27.367257
100
0.543088
5c962da2cb0697e18f9c16fb461c88a985b36ed2
11,196
py
Python
fsgan/utils/utils.py
RedHenLab/RedHenAnonymizer
3560f1ac5cd5b9c6c7ed8bf322b807d57aedc06a
[ "MIT" ]
1
2022-02-01T04:43:24.000Z
2022-02-01T04:43:24.000Z
fsgan/utils/utils.py
yashkhasbage25/AnonymizingAudioVisualData
76d90950b76850cda57525ca0181c1c7986e2463
[ "MIT" ]
6
2022-01-20T21:34:52.000Z
2022-01-20T23:33:55.000Z
fsgan/utils/utils.py
RedHenLab/RedHenAnonymizer
3560f1ac5cd5b9c6c7ed8bf322b807d57aedc06a
[ "MIT" ]
1
2022-01-16T20:33:53.000Z
2022-01-16T20:33:53.000Z
""" General utilities. """ import os import shutil from functools import partial import torch import random import warnings import requests from tqdm import tqdm import torch.backends.cudnn as cudnn import torch.nn.init as init from fsgan.utils.obj_factory import extract_args, obj_factory def init_weights(m, init_ty...
37.69697
113
0.644069
9b2480c41d35df527e485756694186caccee6985
1,292
py
Python
doc/examples/lpt.py
KirillDZR/supreme
c296722599363bd0cbcce6877bd9de9b066cb74b
[ "BSD-3-Clause" ]
95
2015-01-17T09:48:20.000Z
2021-11-07T16:02:38.000Z
doc/examples/lpt.py
KirillDZR/supreme
c296722599363bd0cbcce6877bd9de9b066cb74b
[ "BSD-3-Clause" ]
4
2015-10-23T15:13:34.000Z
2019-09-23T22:47:10.000Z
doc/examples/lpt.py
KirillDZR/supreme
c296722599363bd0cbcce6877bd9de9b066cb74b
[ "BSD-3-Clause" ]
34
2015-02-22T20:54:40.000Z
2022-02-27T13:39:32.000Z
""" Demonstrate log polar transform. """ import matplotlib.pyplot as plt import os import supreme import supreme.io import supreme.transform images = ['misc/nova_grey.png', 'misc/nova.png', 'misc/nova_alpha.png'] im_descr = {'misc/nova_grey.png': 'Grey-level input', 'misc/nova.png': 'Colour input', ...
27.489362
74
0.618421
458f70098ccf332e80e761ba6b4cfb8fdf63970c
3,728
py
Python
app.py
KenSikes/sqlalchemy-challenge
989ccfbe8bb1cf435060d449d90b06663669c1e0
[ "ADSL" ]
null
null
null
app.py
KenSikes/sqlalchemy-challenge
989ccfbe8bb1cf435060d449d90b06663669c1e0
[ "ADSL" ]
null
null
null
app.py
KenSikes/sqlalchemy-challenge
989ccfbe8bb1cf435060d449d90b06663669c1e0
[ "ADSL" ]
null
null
null
#import dependencies import numpy as np import pandas as pd import datetime as dt import sqlalchemy from sqlalchemy.ext.automap import automap_base from sqlalchemy.orm import Session from sqlalchemy import create_engine, func from flask import Flask, jsonify #Database Setup engine = create_engine("sqlite:///Resour...
34.201835
194
0.720225
e01b09bc4e24b3fc5aeb8a85d24c8457cc83dee6
249
py
Python
instana/helpers.py
darnat/Instana
e085e7bd2dc53fea7d5d4a0e6943322bf7d27b82
[ "MIT" ]
null
null
null
instana/helpers.py
darnat/Instana
e085e7bd2dc53fea7d5d4a0e6943322bf7d27b82
[ "MIT" ]
null
null
null
instana/helpers.py
darnat/Instana
e085e7bd2dc53fea7d5d4a0e6943322bf7d27b82
[ "MIT" ]
1
2020-02-22T23:32:15.000Z
2020-02-22T23:32:15.000Z
import uuid def generate_UUID(): """ Generate a UUID and return it """ return str(uuid.uuid4()) def generate_rank_token(id: int): """ Generate a rank token and return it """ return str(id) + '_' + generate_UUID()
15.5625
42
0.598394
8091a4b1d1db5a24acacf32adff895d8b89df385
25,492
py
Python
google/cloud/aiplatform_v1beta1/types/explanation.py
dizcology/python-aiplatform
1a135775966c8a2303ded529eba514dcf9db7205
[ "Apache-2.0" ]
2
2021-10-02T02:25:44.000Z
2021-11-17T10:35:01.000Z
google/cloud/aiplatform_v1beta1/types/explanation.py
pompipo/python-aiplatform
3612b05c62dfb46822cd2c1798fd47349dba33bc
[ "Apache-2.0" ]
1
2020-10-15T18:51:09.000Z
2020-10-16T22:02:32.000Z
google/cloud/aiplatform_v1beta1/types/explanation.py
pompipo/python-aiplatform
3612b05c62dfb46822cd2c1798fd47349dba33bc
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2020 Google LLC # # 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...
45.440285
150
0.67935
cba65ce42c8287418b0b3842cbde9f10db55f4f7
996
py
Python
lino_book/projects/anna/settings/demo.py
lino-framework/lino_book
4eab916832cd8f48ff1b9fc8c2789f0b437da0f8
[ "BSD-2-Clause" ]
3
2016-08-25T05:58:09.000Z
2019-12-05T11:13:45.000Z
lino_book/projects/anna/settings/demo.py
lino-framework/lino_book
4eab916832cd8f48ff1b9fc8c2789f0b437da0f8
[ "BSD-2-Clause" ]
18
2016-11-12T21:38:58.000Z
2019-12-03T17:54:38.000Z
lino_book/projects/anna/settings/demo.py
lino-framework/lino_book
4eab916832cd8f48ff1b9fc8c2789f0b437da0f8
[ "BSD-2-Clause" ]
9
2016-10-15T11:12:33.000Z
2021-09-22T04:37:37.000Z
# import os ; print "20161219 %s (pid:%s)" % (__name__, os.getpid()) import datetime from ..settings import * class Site(Site): """Defines and instantiates a demo version of Lino Care.""" # default_ui = 'lino_extjs6.extjs6' the_demo_date = datetime.date(2015, 5, 23) languages = "en de fr" ...
26.918919
69
0.641566
af5b6eecf14c8947aace21db99228df4962fbe58
557
py
Python
website/__init__.py
MuhammedCrow/IT_Inventory
bb3eaee160dbc80524a07266e5d60d7ae230ecc2
[ "MIT" ]
null
null
null
website/__init__.py
MuhammedCrow/IT_Inventory
bb3eaee160dbc80524a07266e5d60d7ae230ecc2
[ "MIT" ]
null
null
null
website/__init__.py
MuhammedCrow/IT_Inventory
bb3eaee160dbc80524a07266e5d60d7ae230ecc2
[ "MIT" ]
null
null
null
from flask import Flask from datetime import timedelta def create_app(): app = Flask(__name__) app.config['SECRET_KEY'] = 'SrTtmiCk4rWchPCaxNY7Xtb5XwELFrvV' app.permanent_session_lifetime = timedelta(days=5) from .views import views from .auth import auth from .reports import reports from ...
29.315789
65
0.728905
a58b3f34eb4f57dce64394bb35deceef82dbd0dd
1,826
py
Python
heg/auroraonline.py
morris-frank/heg-plant-monitor
c4f47444369151c606a4597aed5562503842e2f3
[ "MIT" ]
null
null
null
heg/auroraonline.py
morris-frank/heg-plant-monitor
c4f47444369151c606a4597aed5562503842e2f3
[ "MIT" ]
null
null
null
heg/auroraonline.py
morris-frank/heg-plant-monitor
c4f47444369151c606a4597aed5562503842e2f3
[ "MIT" ]
null
null
null
from heg import provider import pandas as pd import requests import urllib3 urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) # The URL for the Powerdog HOST HOST = "https://auroraonline.abbsolarinverters.com/abb/" # How manny minutes between reported data? FREQ = 10 class ProviderAuroraOnline(prov...
36.52
105
0.620482
ad3806fdaec5a86721093647d3f5fe5d49ec2ea7
2,551
py
Python
wellregistry/postgres/migrations/0000_create_database.py
duselmann/well_registry_management
b20c01771e8a270890a71c5434f78957a6f3b442
[ "CC0-1.0" ]
null
null
null
wellregistry/postgres/migrations/0000_create_database.py
duselmann/well_registry_management
b20c01771e8a270890a71c5434f78957a6f3b442
[ "CC0-1.0" ]
null
null
null
wellregistry/postgres/migrations/0000_create_database.py
duselmann/well_registry_management
b20c01771e8a270890a71c5434f78957a6f3b442
[ "CC0-1.0" ]
null
null
null
""" Migrate initial users and roles. https://docs.djangoproject.com/en/3.0/topics/migrations/ This one migration should be run on the 'postgres' database alias. > python manage.py migrate --database=postgres registry 0000 All subsequent migrations should be run on the 'migration' > python manage.py migrate --databas...
31.493827
95
0.640141
70d9d37cf68bdf3072e5acc796ad1efe21c89bc4
3,395
py
Python
test/functional/test_framework/coverage.py
sighttviewliu/michaellaoliu_coin
5d6d3eb2e2a0d4273bd7108744e1a362339697a9
[ "MIT" ]
2
2018-12-05T12:47:59.000Z
2019-06-27T12:01:59.000Z
test/functional/test_framework/coverage.py
sighttviewliu/michaellaoliu_coin
5d6d3eb2e2a0d4273bd7108744e1a362339697a9
[ "MIT" ]
null
null
null
test/functional/test_framework/coverage.py
sighttviewliu/michaellaoliu_coin
5d6d3eb2e2a0d4273bd7108744e1a362339697a9
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) 2015-2017 The Michaellaoliu Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Utilities for doing coverage analysis on the RPC interface. Provides a way to track which RPC co...
30.863636
87
0.66215
5370fbb5467f048a26c9e7e92f8378a885ce6e2e
694
py
Python
flask_example/app.py
authlib/socialism
635823a78a2a92cf8630f9935aebb9afcccb8656
[ "BSD-3-Clause" ]
223
2018-04-23T14:48:17.000Z
2022-03-19T09:27:36.000Z
flask_example/app.py
authlib/socialism
635823a78a2a92cf8630f9935aebb9afcccb8656
[ "BSD-3-Clause" ]
68
2018-04-22T13:55:25.000Z
2022-03-15T15:28:42.000Z
flask_example/app.py
authlib/socialism
635823a78a2a92cf8630f9935aebb9afcccb8656
[ "BSD-3-Clause" ]
86
2018-04-24T21:09:26.000Z
2022-03-17T08:55:34.000Z
from flask import Flask, jsonify from authlib.integrations.flask_client import OAuth from loginpass import create_flask_blueprint from loginpass import Twitter, GitHub, Google app = Flask(__name__) app.config.from_pyfile('config.py') oauth = OAuth(app) #: you can customize this part backends = [Twitter, GitHub, Goo...
23.931034
62
0.71902
1a2629832b5df925f344a02d224f923f145bde98
2,564
py
Python
files/downloader/main.py
AzureBlueCobalt/analyze-gelbooru
694b6e843c06942b3d6110e79e083b9ab71214b9
[ "MIT" ]
null
null
null
files/downloader/main.py
AzureBlueCobalt/analyze-gelbooru
694b6e843c06942b3d6110e79e083b9ab71214b9
[ "MIT" ]
null
null
null
files/downloader/main.py
AzureBlueCobalt/analyze-gelbooru
694b6e843c06942b3d6110e79e083b9ab71214b9
[ "MIT" ]
null
null
null
''' read in some_gelbooru.xml parse lines compute vector space vectorize all entries ml 1 decision tree: tags -> rating ml 2 regression tree: tags -> score data 3: filter out questionable what terms are the most explicit, and what are the most safe? ''' from bs4 import BeautifulSoup import time,...
22.103448
106
0.645866
0a6ad5c2a74c98303fe97bebe433bc6a4f884048
919
py
Python
meiduo_mall/manage.py
Noah-Smith-wgp/meiduo_project
f1350a50dabd33d90c2c5b3509d590603aeda6e4
[ "MIT" ]
null
null
null
meiduo_mall/manage.py
Noah-Smith-wgp/meiduo_project
f1350a50dabd33d90c2c5b3509d590603aeda6e4
[ "MIT" ]
null
null
null
meiduo_mall/manage.py
Noah-Smith-wgp/meiduo_project
f1350a50dabd33d90c2c5b3509d590603aeda6e4
[ "MIT" ]
null
null
null
#!/usr/bin/env python import os import sys if __name__ == "__main__": # os.environ.setdefault("DJANGO_SETTINGS_MODULE", "meiduo_mall.settings") # 默认的开发环境配置文件 os.environ.setdefault("DJANGO_SETTINGS_MODULE", "meiduo_mall.settings.dev") # 新的开发环境配置文件 try: from django.core.management import execute_fro...
38.291667
93
0.658324
c42c6f31b9a7cd6aa1cf6ec8631981596b3a0fb1
1,319
py
Python
Platforms/Web/Processing/Api/Discord/Assignroles/main.py
HeapUnderfl0w/Phaazebot
54e637bd4bc213b8efdaf23d5f331f2569e96843
[ "MIT" ]
null
null
null
Platforms/Web/Processing/Api/Discord/Assignroles/main.py
HeapUnderfl0w/Phaazebot
54e637bd4bc213b8efdaf23d5f331f2569e96843
[ "MIT" ]
null
null
null
Platforms/Web/Processing/Api/Discord/Assignroles/main.py
HeapUnderfl0w/Phaazebot
54e637bd4bc213b8efdaf23d5f331f2569e96843
[ "MIT" ]
null
null
null
from typing import TYPE_CHECKING if TYPE_CHECKING: from Platforms.Discord.main_discord import PhaazebotDiscord from Platforms.Web.index import WebIndex from aiohttp.web import Response, Request from .get import apiDiscordAssignrolesGet from .create import apiDiscordAssignrolesCreate from .edit import apiDiscordAssig...
35.648649
102
0.801365
a36ee73adaea56e60c5ed5ca387ce0811347c647
1,223
py
Python
plaso/formatters/appusage.py
cvandeplas/plaso
b625a2c267ed09505cfac84c9593d8c0922852b1
[ "Apache-2.0" ]
3
2016-03-11T02:47:08.000Z
2016-12-24T03:19:27.000Z
plaso/formatters/appusage.py
cvandeplas/plaso
b625a2c267ed09505cfac84c9593d8c0922852b1
[ "Apache-2.0" ]
null
null
null
plaso/formatters/appusage.py
cvandeplas/plaso
b625a2c267ed09505cfac84c9593d8c0922852b1
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- # # Copyright 2013 The Plaso Project Authors. # Please see the AUTHORS file for details on individual authors. # # 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 L...
35.970588
74
0.735895
a5cfe65c3a203755d30fc926a55c9daa6f367295
19,064
py
Python
salt/renderers/stateconf.py
ageron/salt
72a0a89011e55ce7c875e948b5f0e97e70328153
[ "Apache-2.0" ]
2
2019-03-30T02:12:56.000Z
2021-03-08T18:59:46.000Z
salt/renderers/stateconf.py
ageron/salt
72a0a89011e55ce7c875e948b5f0e97e70328153
[ "Apache-2.0" ]
null
null
null
salt/renderers/stateconf.py
ageron/salt
72a0a89011e55ce7c875e948b5f0e97e70328153
[ "Apache-2.0" ]
null
null
null
''' A flexible renderer that takes a templating engine and a data format :maintainer: Jack Kuan <kjkuan@gmail.com> :maturity: new :platform: all ''' # See http://docs.saltstack.org/en/latest/ref/renderers/all/salt.renderers.stateconf.html # for a guide to using this module. # # FIXME: I really need to review and simpl...
33.982175
89
0.584085
b8b489cded4f71d6e9c5c15e260711fc8fe07384
10,832
py
Python
update-attack.py
adampennin/attack-website
a3c2596a87ad9b3301879fcfcde8204ac697b621
[ "Apache-2.0" ]
null
null
null
update-attack.py
adampennin/attack-website
a3c2596a87ad9b3301879fcfcde8204ac697b621
[ "Apache-2.0" ]
null
null
null
update-attack.py
adampennin/attack-website
a3c2596a87ad9b3301879fcfcde8204ac697b621
[ "Apache-2.0" ]
null
null
null
import argparse import colorama import json import os import requests import time from modules import generate from modules import config from modules import tests from modules import util from string import Template def get_stix_data(args): """Set up proxy if any and get STIX data""" # Set proxy proxy =...
37.480969
189
0.584749
2eb9b662147be8020589a3ef27e222e7b4f992bb
4,856
py
Python
python/scripts/generate_compare_functions.py
ftschindler-work/dune-xt-common
1748530e13dbf683b5bf14289bf3e134485755a8
[ "BSD-2-Clause" ]
2
2016-01-05T14:54:52.000Z
2020-02-08T04:09:13.000Z
python/scripts/generate_compare_functions.py
ftschindler-work/dune-xt-common
1748530e13dbf683b5bf14289bf3e134485755a8
[ "BSD-2-Clause" ]
119
2016-01-06T16:32:14.000Z
2020-03-25T08:28:53.000Z
python/scripts/generate_compare_functions.py
ftschindler-work/dune-xt-common
1748530e13dbf683b5bf14289bf3e134485755a8
[ "BSD-2-Clause" ]
5
2016-04-13T08:03:45.000Z
2020-03-13T10:59:17.000Z
#!/usr/bin/env python # # ~~~ # This file is part of the dune-xt-common project: # https://github.com/dune-community/dune-xt-common # Copyright 2009-2018 dune-xt-common developers and contributors. All rights reserved. # License: Dual licensed as BSD 2-Clause License (http://opensource.org/licenses/BSD-2-Clause) # ...
51.115789
125
0.632414
3330ca041393942901a03d27e568c3b74e128346
33,859
py
Python
sppas/sppas/src/files/filestructure.py
mirfan899/MTTS
3167b65f576abcc27a8767d24c274a04712bd948
[ "MIT" ]
null
null
null
sppas/sppas/src/files/filestructure.py
mirfan899/MTTS
3167b65f576abcc27a8767d24c274a04712bd948
[ "MIT" ]
null
null
null
sppas/sppas/src/files/filestructure.py
mirfan899/MTTS
3167b65f576abcc27a8767d24c274a04712bd948
[ "MIT" ]
null
null
null
# -*- coding: UTF-8 -*- """ .. --------------------------------------------------------------------- ___ __ __ __ ___ / | \ | \ | \ / the automatic \__ |__/ |__/ |___| \__ annotation and \ | | | | \ ...
31.912347
123
0.502318
5dec5afe367ed21ed38a9723a75fc596eaf43721
1,515
py
Python
src/face_detection.py
Pucadopr/Mouse-Controller
e78a472066728a33797e3a0165f7c82d2500d088
[ "MIT" ]
null
null
null
src/face_detection.py
Pucadopr/Mouse-Controller
e78a472066728a33797e3a0165f7c82d2500d088
[ "MIT" ]
3
2021-06-08T22:11:55.000Z
2022-03-12T00:44:58.000Z
src/face_detection.py
Pucadopr/Mouse-Controller
e78a472066728a33797e3a0165f7c82d2500d088
[ "MIT" ]
null
null
null
''' This is the class for the face detection model. This is used to instantiate the face detection model downloaded from the Intel model zoo. Model is used to detect faces in Videos, Images or video streams ''' from model import Model import cv2 import numpy as np class Face_Detector(Model): ''' Class for th...
31.5625
90
0.625743
fdb9c32ec7ba26580f303f3cec128dd3870a7307
577
py
Python
my_rfcn/experiments/dff_rfcn_test.py
xunhen/Deep-Feature-Flow
9fc6e755169bfad4e25553507bf2a98d6f3ee2e0
[ "MIT" ]
1
2019-12-08T09:12:59.000Z
2019-12-08T09:12:59.000Z
my_rfcn/experiments/dff_rfcn_test.py
xunhen/Deep-Feature-Flow
9fc6e755169bfad4e25553507bf2a98d6f3ee2e0
[ "MIT" ]
null
null
null
my_rfcn/experiments/dff_rfcn_test.py
xunhen/Deep-Feature-Flow
9fc6e755169bfad4e25553507bf2a98d6f3ee2e0
[ "MIT" ]
3
2019-05-05T09:39:27.000Z
2021-09-25T15:00:14.000Z
# -------------------------------------------------------- # Deep Feature Flow # Copyright (c) 2017 Microsoft # Licensed under The MIT License [see LICENSE for details] # Written by Yuwen Xiong # -------------------------------------------------------- import os import sys import my_rfcn os.environ['PYTHONUNBUFFERED']...
27.47619
65
0.573657
4b3dd161e7718437beaf7ca3b43f65b34b91c968
1,685
py
Python
tests/template_tests/filter_tests/test_removetags.py
bpeschier/django
f54c0ec06e390dc5bce95fdccbcb51d6423da4f9
[ "BSD-3-Clause" ]
2
2019-01-19T06:57:51.000Z
2022-03-16T13:29:03.000Z
tests/template_tests/filter_tests/test_removetags.py
bpeschier/django
f54c0ec06e390dc5bce95fdccbcb51d6423da4f9
[ "BSD-3-Clause" ]
1
2021-03-24T12:53:33.000Z
2021-03-24T12:53:33.000Z
tests/template_tests/filter_tests/test_removetags.py
bpeschier/django
f54c0ec06e390dc5bce95fdccbcb51d6423da4f9
[ "BSD-3-Clause" ]
4
2016-07-31T14:29:15.000Z
2021-10-19T03:32:44.000Z
from django.template.defaultfilters import removetags from django.test import SimpleTestCase, ignore_warnings from django.utils.deprecation import RemovedInDjango20Warning from django.utils.safestring import mark_safe from ..utils import setup @ignore_warnings(category=RemovedInDjango20Warning) class RemovetagsTests...
33.7
100
0.566172
755e80997d31cbc3e5901f57e7e5a2a65a218802
13,140
py
Python
WebSite/PrayerWall/Wall/views.py
Tinka8ell/Prayer-Wall
e9e6f3b94a88fc68f26a660b7abc5a781bad8f71
[ "Apache-2.0" ]
null
null
null
WebSite/PrayerWall/Wall/views.py
Tinka8ell/Prayer-Wall
e9e6f3b94a88fc68f26a660b7abc5a781bad8f71
[ "Apache-2.0" ]
null
null
null
WebSite/PrayerWall/Wall/views.py
Tinka8ell/Prayer-Wall
e9e6f3b94a88fc68f26a660b7abc5a781bad8f71
[ "Apache-2.0" ]
null
null
null
# Create your views here. import datetime, os, time from django.http import HttpResponse, HttpResponseRedirect, JsonResponse, Http404 from django.views.decorators.csrf import csrf_exempt from django.shortcuts import get_object_or_404, render from django.urls import reverse from django.views import generic from django....
33.77892
88
0.596347
973eff99dc5309efce5a653a74ace1b5a2d91b43
6,323
py
Python
src/datamgr/datamanager/common/kafka.py
Chromico/bk-base
be822d9bbee544a958bed4831348185a75604791
[ "MIT" ]
84
2021-06-30T06:20:23.000Z
2022-03-22T03:05:49.000Z
src/datamgr/datamanager/common/kafka.py
Chromico/bk-base
be822d9bbee544a958bed4831348185a75604791
[ "MIT" ]
7
2021-06-30T06:21:16.000Z
2022-03-29T07:36:13.000Z
src/datamgr/datamanager/common/kafka.py
Chromico/bk-base
be822d9bbee544a958bed4831348185a75604791
[ "MIT" ]
40
2021-06-30T06:21:26.000Z
2022-03-29T12:42:26.000Z
# -*- coding: utf-8 -*- """ Tencent is pleased to support the open source community by making BK-BASE 蓝鲸基础平台 available. Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved. BK-BASE 蓝鲸基础平台 is licensed under the MIT License. License for BK-BASE 蓝鲸基础平台: ---------------------------------------------...
36.33908
111
0.614582
1221cd3041a437c090a71d061c6c87cc05b03035
1,119
py
Python
monai/losses/__init__.py
dylanbuchi/MONAI
1651f1b003b0ffae8b615d191952ad65ad091277
[ "Apache-2.0" ]
3
2020-07-02T18:39:36.000Z
2021-06-16T09:35:53.000Z
monai/losses/__init__.py
dylanbuchi/MONAI
1651f1b003b0ffae8b615d191952ad65ad091277
[ "Apache-2.0" ]
28
2020-06-26T12:47:52.000Z
2020-09-08T00:33:42.000Z
monai/losses/__init__.py
dylanbuchi/MONAI
1651f1b003b0ffae8b615d191952ad65ad091277
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 - 2021 MONAI Consortium # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in wri...
34.96875
97
0.780161
059c337da5452590fbffa8b6958c72ae94769c0f
4,699
py
Python
tests/regression_test/shell_backend_tester.py
danieleades/mdbook-plantuml
9b85686fe639e4eea41b74e2a71280c486b704a0
[ "MIT" ]
null
null
null
tests/regression_test/shell_backend_tester.py
danieleades/mdbook-plantuml
9b85686fe639e4eea41b74e2a71280c486b704a0
[ "MIT" ]
null
null
null
tests/regression_test/shell_backend_tester.py
danieleades/mdbook-plantuml
9b85686fe639e4eea41b74e2a71280c486b704a0
[ "MIT" ]
null
null
null
import unittest import os import shutil import json from parameterized import parameterized from preprocessor_runner import * from file_locations import get_shell_calls_file, get_test_output_dir import markdown_snippets import preprocessor_builder class ShellBackendTester(unittest.TestCase): """ This tester f...
36.426357
82
0.665461
9990387d7ca58abc39fc00daeec23a917bf7f35c
6,870
py
Python
player.py
yeozhenhao/GS_proceduralskills_bot
bbb7790b1e93819359c5fc405d9f5f6885e238f3
[ "MIT" ]
null
null
null
player.py
yeozhenhao/GS_proceduralskills_bot
bbb7790b1e93819359c5fc405d9f5f6885e238f3
[ "MIT" ]
null
null
null
player.py
yeozhenhao/GS_proceduralskills_bot
bbb7790b1e93819359c5fc405d9f5f6885e238f3
[ "MIT" ]
null
null
null
import csv import json import logging from functools import wraps import configdualbot logger = logging.getLogger(__name__) def restricted(func): """Restrict usage of func to allowed users only and replies if necessary""" @wraps(func) def wrapped(update, context, *args, **kwargs): user_id = updat...
49.782609
228
0.586317
1f8622c110bcb67b400e14ea174ebc0781ca893e
950
py
Python
polls/models.py
Yursksf1/DG_pulls20
d80b6dc37a1bf20341572b8850c21467554ea84e
[ "MIT" ]
null
null
null
polls/models.py
Yursksf1/DG_pulls20
d80b6dc37a1bf20341572b8850c21467554ea84e
[ "MIT" ]
null
null
null
polls/models.py
Yursksf1/DG_pulls20
d80b6dc37a1bf20341572b8850c21467554ea84e
[ "MIT" ]
null
null
null
import datetime from django.db import models from django.utils import timezone # Create your models here. class Question(models.Model): question_text = models.CharField(max_length=200) pub_date = models.DateTimeField('date published') def __str__(self): return self.question_text def was...
27.941176
71
0.723158
0c6d07464721a9d01254a0edc513d2bf89d7aa88
2,420
py
Python
src/RGT/XML/SVG/switchNode.py
danrg/RGT-tool
115ba9a93686595699b3e182958921b3d60382b3
[ "MIT" ]
7
2015-02-09T12:12:04.000Z
2019-03-31T08:23:36.000Z
src/RGT/XML/SVG/switchNode.py
danrg/RGT-tool
115ba9a93686595699b3e182958921b3d60382b3
[ "MIT" ]
3
2015-07-05T20:49:14.000Z
2017-07-03T19:45:18.000Z
src/RGT/XML/SVG/switchNode.py
danrg/RGT-tool
115ba9a93686595699b3e182958921b3d60382b3
[ "MIT" ]
1
2021-03-23T14:01:22.000Z
2021-03-23T14:01:22.000Z
from RGT.XML.SVG.baseContainerNode import BaseContainerNode from RGT.XML.SVG.Attribs.conditionalProcessingAttributes import ConditionalProcessingAttributes from RGT.XML.SVG.Attribs.graphicalEventAttributes import GraphicalEventAttributes from types import StringType from RGT.XML.SVG.basicSvgNode import BasicSvgNode...
44
114
0.673967
2921da319ba1f4c67ed80954e09aaedc8ddbc008
606
py
Python
tests/data/stubs-ok/tst-micropython-linux-1_12/time.py
vincent-l-j/micropython-stubber
7dbbc937baffedd7fdbd5ac9f94555f2c93b98d0
[ "MIT" ]
96
2019-04-10T15:03:27.000Z
2022-03-29T09:07:14.000Z
tests/data/stubs-ok/tst-micropython-linux-1_12/time.py
vincent-l-j/micropython-stubber
7dbbc937baffedd7fdbd5ac9f94555f2c93b98d0
[ "MIT" ]
154
2019-06-02T21:30:56.000Z
2022-03-30T12:19:00.000Z
tests/data/stubs-ok/tst-micropython-linux-1_12/time.py
vincent-l-j/micropython-stubber
7dbbc937baffedd7fdbd5ac9f94555f2c93b98d0
[ "MIT" ]
7
2019-06-14T19:54:22.000Z
2022-03-29T05:02:32.000Z
""" Module: 'time' on micropython-linux-1.12 """ # MCU: {'ver': '1.12', 'port': 'linux', 'arch': 'x64', 'sysname': 'unknown', 'release': '1.12.0', 'name': 'micropython', 'mpy': 2821, 'version': '1.12.0', 'machine': 'unknown', 'build': '', 'nodename': 'unknown', 'platform': 'linux', 'family': 'micropython'} # Stubber: 1...
15.538462
258
0.574257
e7959650cfa37d57d08432033d8f7ade3af37255
1,461
py
Python
lib/extensions/mini_browser/script.py
neurodiverseEsoteric/nimbus
a79a37d6001d84116831c9f3f99f5d9acfa7fd19
[ "CC-BY-3.0" ]
3
2015-11-04T10:48:12.000Z
2020-07-12T06:46:27.000Z
lib/extensions/mini_browser/script.py
esotericDisciple/nimbus
a79a37d6001d84116831c9f3f99f5d9acfa7fd19
[ "CC-BY-3.0" ]
null
null
null
lib/extensions/mini_browser/script.py
esotericDisciple/nimbus
a79a37d6001d84116831c9f3f99f5d9acfa7fd19
[ "CC-BY-3.0" ]
1
2021-05-05T13:56:49.000Z
2021-05-05T13:56:49.000Z
name = "Mini Browser" url = "" clip = "" ua = "Mozilla/5.0 (Linux; Android 4.0.4; Galaxy Nexus Build/IMM76B) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.133 Mobile Safari/535.19" if not self.isCheckable(): self.setCheckable(True) self.setChecked(True) if not self.parentWindow().hasSideBar(name): ...
63.521739
211
0.765914
463a06d828fd3c3e3e283666d654457584587122
29,322
py
Python
Ordered.py
yagoocarvalho/cbd-ufrj
999a785ee51c7b29a00498e2769ca91c3c3c8fbf
[ "MIT" ]
null
null
null
Ordered.py
yagoocarvalho/cbd-ufrj
999a785ee51c7b29a00498e2769ca91c3c3c8fbf
[ "MIT" ]
null
null
null
Ordered.py
yagoocarvalho/cbd-ufrj
999a785ee51c7b29a00498e2769ca91c3c3c8fbf
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Fri Oct 12 21:10:36 2018 @author: eduardo """ import os import fileinput import DBHelperFunctions as aux ################################################################################### ################################# AUX FUNCTIONS #################...
40.002729
285
0.615852
16e2a55c3900badf112a6315079bad7d17c73483
2,151
py
Python
solution/25. reverse-nodes-in-k-group.py
sundaycat/Leetcode-Practice
65c3ab0f967331a095fd8a6eb2f3d7765cbf7d5a
[ "MIT" ]
null
null
null
solution/25. reverse-nodes-in-k-group.py
sundaycat/Leetcode-Practice
65c3ab0f967331a095fd8a6eb2f3d7765cbf7d5a
[ "MIT" ]
null
null
null
solution/25. reverse-nodes-in-k-group.py
sundaycat/Leetcode-Practice
65c3ab0f967331a095fd8a6eb2f3d7765cbf7d5a
[ "MIT" ]
null
null
null
# # @lc app=leetcode id=25 lang=python3 # # [25] Reverse Nodes in k-Group # from typing import Optional from LinkedList import * # @lc code=start class Solution: def reverseBetween(self, head, left, right): idx = 1 pre, cur = None, head while cur and idx < left: idx +...
23.9
96
0.493724
663f238ccee473533eeb297ada4ccc37c7d07abc
6,315
py
Python
project_name/settings/base.py
caktus/django-project-template
644148f7327a7bb54e52d3de8a7fe3c03c674b20
[ "Unlicense" ]
184
2015-01-12T23:04:58.000Z
2022-03-23T15:35:18.000Z
project_name/settings/base.py
caktus/django-project-template
644148f7327a7bb54e52d3de8a7fe3c03c674b20
[ "Unlicense" ]
179
2015-01-02T15:26:29.000Z
2022-03-11T23:26:22.000Z
project_name/settings/base.py
caktus/django-project-template
644148f7327a7bb54e52d3de8a7fe3c03c674b20
[ "Unlicense" ]
59
2015-02-09T16:55:08.000Z
2021-10-05T10:57:58.000Z
""" Django settings for {{ project_name }} project. Generated by 'django-admin startproject' using Django {{ django_version }}. For more information on this file, see https://docs.djangoproject.com/en/{{ docs_version }}/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.c...
30.507246
91
0.656215
09938679881ee1d9b48a5fb3b67b5b75e07f72fd
650
py
Python
submissions/single-element-in-a-sorted-array/solution.py
Wattyyy/LeetCode
13a9be056d0a0c38c2f8c8222b11dc02cb25a935
[ "MIT" ]
null
null
null
submissions/single-element-in-a-sorted-array/solution.py
Wattyyy/LeetCode
13a9be056d0a0c38c2f8c8222b11dc02cb25a935
[ "MIT" ]
1
2022-03-04T20:24:32.000Z
2022-03-04T20:31:58.000Z
submissions/single-element-in-a-sorted-array/solution.py
Wattyyy/LeetCode
13a9be056d0a0c38c2f8c8222b11dc02cb25a935
[ "MIT" ]
null
null
null
# https://leetcode.com/problems/single-element-in-a-sorted-array class Solution: def singleNonDuplicate(self, nums): l, r = 0, len(nums) - 1 while l < r: mid = (l + r) // 2 if 0 < mid and nums[mid - 1] == nums[mid]: if (mid - 1) % 2 == 0: ...
28.26087
68
0.376923
a0661d84394dca4719088cdf2d3ea728b9c3c3f9
28,111
py
Python
shards/mishards/service_handler.py
zhoubo0317/milvus
94dbbd31a3fd475aa40470549198935e6276c0f9
[ "Apache-2.0" ]
null
null
null
shards/mishards/service_handler.py
zhoubo0317/milvus
94dbbd31a3fd475aa40470549198935e6276c0f9
[ "Apache-2.0" ]
null
null
null
shards/mishards/service_handler.py
zhoubo0317/milvus
94dbbd31a3fd475aa40470549198935e6276c0f9
[ "Apache-2.0" ]
1
2020-04-23T14:05:06.000Z
2020-04-23T14:05:06.000Z
import logging import time import json import ujson import multiprocessing from concurrent.futures import ThreadPoolExecutor from milvus.grpc_gen import milvus_pb2, milvus_pb2_grpc, status_pb2 from milvus.client import types as Types from milvus import MetricType from mishards import (db, exceptions) from mishards.gr...
40.79971
116
0.613105
7d2260c544a32d62baaa2e132ef3e9fa89d0823d
5,789
py
Python
src/ConstraintNetwork.py
MysteryLEE/Sudoku_JiaweiLi
f52354adfbb69d0e3700ca77f02910f4638c2741
[ "MIT" ]
null
null
null
src/ConstraintNetwork.py
MysteryLEE/Sudoku_JiaweiLi
f52354adfbb69d0e3700ca77f02910f4638c2741
[ "MIT" ]
null
null
null
src/ConstraintNetwork.py
MysteryLEE/Sudoku_JiaweiLi
f52354adfbb69d0e3700ca77f02910f4638c2741
[ "MIT" ]
null
null
null
import Variable import Constraint import SudokuBoard from math import floor """ CSP representation of the problem. Contains the variables, constraints, and many helpful accessors. """ class ConstraintNetwork: # ================================================================== # Constructors # ===...
29.687179
85
0.423562
ace459e8e163006f5a7bdab0c0a14c78828b518c
1,119
py
Python
zendesk/komand_zendesk/actions/show_memberships/schema.py
killstrelok/insightconnect-plugins
911358925f4233ab273dbd8172e8b7b9188ebc01
[ "MIT" ]
1
2020-03-18T09:14:55.000Z
2020-03-18T09:14:55.000Z
zendesk/komand_zendesk/actions/show_memberships/schema.py
killstrelok/insightconnect-plugins
911358925f4233ab273dbd8172e8b7b9188ebc01
[ "MIT" ]
1
2021-02-23T23:57:37.000Z
2021-02-23T23:57:37.000Z
zendesk/komand_zendesk/actions/show_memberships/schema.py
killstrelok/insightconnect-plugins
911358925f4233ab273dbd8172e8b7b9188ebc01
[ "MIT" ]
null
null
null
# GENERATED BY KOMAND SDK - DO NOT EDIT import komand import json class Component: DESCRIPTION = "Show all organization memberships" class Input: USER_ID = "user_id" class Output: MEMBERSHIPS = "memberships" class ShowMembershipsInput(komand.Input): schema = json.loads(""" { "type":...
17.215385
59
0.563003
bca0c065bd8379f1c586a979ba63229e29af351b
4,686
py
Python
src/data/nba.py
kyle-rgb/Setting_Lines_and_Making_Dimes
e2c3fbf5de80c51879bb0e9ad4f86f37f021d150
[ "MIT" ]
1
2021-11-11T17:30:06.000Z
2021-11-11T17:30:06.000Z
src/data/nba.py
kyle-rgb/Setting_Lines_and_Making_Dimes
e2c3fbf5de80c51879bb0e9ad4f86f37f021d150
[ "MIT" ]
null
null
null
src/data/nba.py
kyle-rgb/Setting_Lines_and_Making_Dimes
e2c3fbf5de80c51879bb0e9ad4f86f37f021d150
[ "MIT" ]
1
2021-10-19T20:12:58.000Z
2021-10-19T20:12:58.000Z
import os, requests, bs4, pprint, csv import time, re # Change Directory to Current Repo os.chdir(r"C:\Users\Kyle\Desktop\CodeOandE\Python\Nba_Revised\Setting_Lines_and_Making_Dimes\data\interim") wanted_year = input("Please Enter the Season You Would Like to Scrape (ex. 2019 = 2018-2019 season): ") wanted_year = str(...
41.839286
163
0.527529
18d212cdc9d2ad2d8c0c213d6fc2907c9e45e519
2,913
py
Python
numpy/linalg/tests/test_regression.py
gmabey/numpy
9e9ec3821c1d6a055543e54336ecb2c98ec42c5f
[ "BSD-3-Clause" ]
652
2015-07-26T00:00:17.000Z
2022-02-24T18:30:04.000Z
microblog/flask/venv/lib/python2.7/site-packages/numpy/linalg/tests/test_regression.py
johankaito/fufuka
32a96ecf98ce305c2206c38443e58fdec88c788d
[ "Apache-2.0" ]
8
2015-09-07T03:38:19.000Z
2021-05-23T03:18:51.000Z
microblog/flask/venv/lib/python2.7/site-packages/numpy/linalg/tests/test_regression.py
johankaito/fufuka
32a96ecf98ce305c2206c38443e58fdec88c788d
[ "Apache-2.0" ]
40
2015-07-24T19:45:08.000Z
2021-11-01T14:54:56.000Z
""" Test functions for linalg module """ from __future__ import division, absolute_import, print_function from numpy.testing import * import numpy as np from numpy import linalg, arange, float64, array, dot, transpose rlevel = 1 class TestRegression(TestCase): def test_eig_build(self, level = rlevel): "...
32.010989
78
0.533471
d9dd9c5825eb6a4eb4823dec4487aaf7d4c7ffa4
5,042
py
Python
nova/tests/functional/test_list_servers_ip_filter.py
viveknandavanam/nova
556377b6915936467436c9d5bb33bc0e22244e1e
[ "Apache-2.0" ]
1
2015-11-30T19:44:00.000Z
2015-11-30T19:44:00.000Z
nova/tests/functional/test_list_servers_ip_filter.py
viveknandavanam/nova
556377b6915936467436c9d5bb33bc0e22244e1e
[ "Apache-2.0" ]
5
2018-04-12T16:44:34.000Z
2018-05-08T13:33:05.000Z
nova/tests/functional/test_list_servers_ip_filter.py
viveknandavanam/nova
556377b6915936467436c9d5bb33bc0e22244e1e
[ "Apache-2.0" ]
3
2018-04-04T15:15:01.000Z
2018-04-19T18:14:25.000Z
# Copyright 2017 IBM Corp. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, s...
43.465517
79
0.636454
e7e1f7fae03cfe72fee49416a3ef6d54904a935a
2,351
py
Python
src/scs_ndir/datum/ndir_recorder_datum.py
south-coast-science/scs_ndir
50c1a1a33ca5e5d52ac2203eccc214b956e85252
[ "MIT" ]
null
null
null
src/scs_ndir/datum/ndir_recorder_datum.py
south-coast-science/scs_ndir
50c1a1a33ca5e5d52ac2203eccc214b956e85252
[ "MIT" ]
null
null
null
src/scs_ndir/datum/ndir_recorder_datum.py
south-coast-science/scs_ndir
50c1a1a33ca5e5d52ac2203eccc214b956e85252
[ "MIT" ]
null
null
null
""" Created on 17 Feb 2018 @author: Bruno Beloff (bruno.beloff@southcoastscience.com) document example: {"rec": 840, "pile-ref": 4367, "pile-act": 4785, "thermistor": 10284} """ from collections import OrderedDict from scs_core.data.datum import Datum from scs_core.data.json import JSONable # --------------------...
25.010638
118
0.427478
efcf7f79f70e292db53fad0de393b27415cfe968
10,983
py
Python
googleblog.py
fromHearts/google-ai-blog
d1c5f58fc2ebf95c7b9cff748527439d033973ae
[ "Apache-2.0" ]
null
null
null
googleblog.py
fromHearts/google-ai-blog
d1c5f58fc2ebf95c7b9cff748527439d033973ae
[ "Apache-2.0" ]
null
null
null
googleblog.py
fromHearts/google-ai-blog
d1c5f58fc2ebf95c7b9cff748527439d033973ae
[ "Apache-2.0" ]
null
null
null
import requests import json import time import re from bs4 import BeautifulSoup from os import listdir, mkdir, system from os.path import isfile, join science_parse = "./science-parse-cli-assembly-2.0.3.jar" paper_sites = ["arxiv.org", 'research.google.com'] excluded = ['wikipedia', '.png', '.jpg', '.gif'] # Gets ra...
33.793846
118
0.571246
16408c80aa19608799e9c9c665f8f47f4a7214a3
12,953
py
Python
cfgov/v1/wagtail_hooks.py
chosak/consumerfinance.gov
2007ac860ec7dfff0f94517f1a69e75299b97d20
[ "CC0-1.0" ]
null
null
null
cfgov/v1/wagtail_hooks.py
chosak/consumerfinance.gov
2007ac860ec7dfff0f94517f1a69e75299b97d20
[ "CC0-1.0" ]
null
null
null
cfgov/v1/wagtail_hooks.py
chosak/consumerfinance.gov
2007ac860ec7dfff0f94517f1a69e75299b97d20
[ "CC0-1.0" ]
null
null
null
import logging from django.conf import settings from django.contrib import admin from django.contrib.auth.models import Permission from django.core.exceptions import PermissionDenied from django.shortcuts import render from django.urls import reverse from django.utils.html import format_html_join from wagtail.admin.m...
28.158696
83
0.671196
7e876c4912eb8efd5eac650c69cb6bc4f3766942
7,278
py
Python
redboard.py
RedRobotics/HeadBoard
71f00e96f4cac6617a1b00a245da57e15ac27285
[ "MIT" ]
null
null
null
redboard.py
RedRobotics/HeadBoard
71f00e96f4cac6617a1b00a245da57e15ac27285
[ "MIT" ]
null
null
null
redboard.py
RedRobotics/HeadBoard
71f00e96f4cac6617a1b00a245da57e15ac27285
[ "MIT" ]
null
null
null
#Python library for the Red Robotics 'HeadBoard' and 'SideBoard' Raspberry Pi add on robotics boards. #Simple python commands for controlling motors, servos and Neopixels (WS2812B). #Version 1.22 21/6/2018 # Author: Neil Lambeth. neil@redrobotics.co.uk @NeilRedRobotics from __future__ import print_function # Make pri...
25.900356
101
0.451498
666ecd54e9f1609073aee647e7d239e59998f71a
1,599
py
Python
rl_ctrnn/ranges.py
cooperuser/rl_ctrnn
5f05585dc6f017de60eec9929b8523a8d4da80f7
[ "MIT" ]
1
2021-10-05T13:30:00.000Z
2021-10-05T13:30:00.000Z
rl_ctrnn/ranges.py
cooperuser/rl_ctrnn
5f05585dc6f017de60eec9929b8523a8d4da80f7
[ "MIT" ]
null
null
null
rl_ctrnn/ranges.py
cooperuser/rl_ctrnn
5f05585dc6f017de60eec9929b8523a8d4da80f7
[ "MIT" ]
null
null
null
import numpy as np class Range(object): def __init__(self, min: float, max: float): self.min = min self.max = max def set_clamp(self, value: float): self.min = min(self.min, value) self.max = max(self.max, value) def __repr__(self): return f"Range[{self.min:0.4f} {...
30.169811
65
0.59975
f1993aba311ccd3228b5bf022340877b272a2d3d
4,131
py
Python
Lib/test/test_glob.py
leepro/unladen-swallow
8175e37eaea7ca66ed03283b46bc1d2db0d3f9c3
[ "PSF-2.0" ]
2,293
2015-01-02T12:46:10.000Z
2022-03-29T09:45:43.000Z
python/src/Lib/test/test_glob.py
weiqiangzheng/sl4a
d3c17dca978cbeee545e12ea240a9dbf2a6999e9
[ "Apache-2.0" ]
315
2015-05-31T11:55:46.000Z
2022-01-12T08:36:37.000Z
python/src/Lib/test/test_glob.py
weiqiangzheng/sl4a
d3c17dca978cbeee545e12ea240a9dbf2a6999e9
[ "Apache-2.0" ]
1,033
2015-01-04T07:48:40.000Z
2022-03-24T09:34:37.000Z
import unittest from test.test_support import run_unittest, TESTFN import glob import os import shutil class GlobTests(unittest.TestCase): def norm(self, *parts): return os.path.normpath(os.path.join(self.tempdir, *parts)) def mktemp(self, *parts): filename = self.norm(*parts) base, f...
35.921739
79
0.537642
a3bd26b7e710435bb475fd72ee3216e8d3964834
19,919
py
Python
chia/cmds/init_funcs.py
colinwebber/chia-blockchain
ca781507896b0ceb310ad4a2e5a2205a8c2ce7a1
[ "Apache-2.0" ]
1
2021-11-16T18:59:19.000Z
2021-11-16T18:59:19.000Z
chia/cmds/init_funcs.py
colinwebber/chia-blockchain
ca781507896b0ceb310ad4a2e5a2205a8c2ce7a1
[ "Apache-2.0" ]
2
2022-02-14T00:16:34.000Z
2022-02-14T00:16:44.000Z
chia/cmds/init_funcs.py
neurosis69/chia-blockchain
d346ef89f1e1aa9eec1e06f1ef93862c097f6bd7
[ "Apache-2.0" ]
null
null
null
import os import shutil import sqlite3 from pathlib import Path from typing import Any, Dict, List, Optional, Tuple import yaml from chia import __version__ from chia.consensus.coinbase import create_puzzlehash_for_pk from chia.ssl.create_ssl import ( ensure_ssl_dirs, generate_ca_signed_cert, get_chia_ca_...
38.232246
120
0.642854
d5b8dc835618a0b9c25ecd618765886d3cb876e6
890
py
Python
standup/status/migrations/0022_sitemessage.py
mozilla/standup
7b5a581d784cc7fce4851886e5528f6ab4752658
[ "BSD-3-Clause" ]
58
2015-02-04T15:55:30.000Z
2020-07-21T16:10:35.000Z
standup/status/migrations/0022_sitemessage.py
mozilla/standup
7b5a581d784cc7fce4851886e5528f6ab4752658
[ "BSD-3-Clause" ]
302
2015-01-20T16:22:37.000Z
2018-10-25T20:44:51.000Z
standup/status/migrations/0022_sitemessage.py
mozilla/standup
7b5a581d784cc7fce4851886e5528f6ab4752658
[ "BSD-3-Clause" ]
17
2015-01-31T11:43:17.000Z
2020-08-03T02:04:01.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.11.12 on 2018-06-07 16:58 from __future__ import unicode_literals from django.db import migrations, models import django.utils.timezone class Migration(migrations.Migration): dependencies = [ ('status', '0021_auto_20180607_1617'), ] operations = [...
34.230769
128
0.637079
c3cc007acc0eb959aa3cfa1afbfa06ea69d6c691
6,361
py
Python
opencamlib/src/attic/oct_test2.py
JohnyEngine/CNC
e4c77250ab2b749d3014022cbb5eb9924e939993
[ "Apache-2.0" ]
null
null
null
opencamlib/src/attic/oct_test2.py
JohnyEngine/CNC
e4c77250ab2b749d3014022cbb5eb9924e939993
[ "Apache-2.0" ]
null
null
null
opencamlib/src/attic/oct_test2.py
JohnyEngine/CNC
e4c77250ab2b749d3014022cbb5eb9924e939993
[ "Apache-2.0" ]
1
2020-07-04T13:58:00.000Z
2020-07-04T13:58:00.000Z
import ocl as cam import camvtk import time import vtk import math import datetime red= (1,0,0) green= (0,1,0) blue= (0,0,1) cyan= (0,1,1) yellow= (1,1,0) pink = ( float(255)/255,float(192)/255,float(203)/255) grey = ( float(127)/255,float(127)/255,float(127)/255) orange = ( float(255)/255,float(165)/255,float(0)/255...
28.397321
103
0.547084
629e2b54b12e922cbd03544d445de370eccf1092
158
py
Python
payshare/purchases/apps.py
cb109/payshare
14156978b5bbd98dd89cd90c0e0695cc865f466a
[ "MIT" ]
184
2018-07-18T08:41:39.000Z
2022-03-29T14:07:16.000Z
payshare/purchases/apps.py
Zarathustra2/payshare
7a72780b2bb1f1255c36e07ba3acf7700c9db77d
[ "MIT" ]
42
2018-07-21T11:06:58.000Z
2022-03-11T23:58:37.000Z
payshare/purchases/apps.py
Zarathustra2/payshare
7a72780b2bb1f1255c36e07ba3acf7700c9db77d
[ "MIT" ]
45
2018-07-20T01:02:10.000Z
2021-12-19T13:16:35.000Z
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.apps import AppConfig class PurchasesConfig(AppConfig): name = 'purchases'
17.555556
39
0.740506
475300b7c2d46f3a2115635481fcc2d620805c6c
19,054
py
Python
book_env/Lib/site-packages/matplotlib/tests/test_patches.py
als0052/Hands-On-Data-Analysis-with-Pandas
ea4e94f93a1e00cbccb493f22dde5c8007ed5e76
[ "MIT" ]
11
2019-06-19T03:44:05.000Z
2021-07-30T10:28:14.000Z
book_env/Lib/site-packages/matplotlib/tests/test_patches.py
als0052/Hands-On-Data-Analysis-with-Pandas
ea4e94f93a1e00cbccb493f22dde5c8007ed5e76
[ "MIT" ]
9
2020-08-13T15:27:26.000Z
2022-03-12T00:41:01.000Z
book_env/Lib/site-packages/matplotlib/tests/test_patches.py
als0052/Hands-On-Data-Analysis-with-Pandas
ea4e94f93a1e00cbccb493f22dde5c8007ed5e76
[ "MIT" ]
6
2019-10-25T17:11:06.000Z
2021-12-02T16:05:20.000Z
""" Tests specific to the patches module. """ import numpy as np from numpy.testing import assert_almost_equal, assert_array_equal import pytest from matplotlib.patches import Polygon, Rectangle, FancyArrowPatch from matplotlib.testing.decorators import image_comparison, check_figures_equal import matplotlib.pyplot as...
34.085868
79
0.593051
848c2d03159fa02e19185b07b8bc28c3b80f645c
150
py
Python
ggjjl1/wsgi.py
ggjjl1/ggjjl1
8f9484b8569ba69aaf5fdda92c9857537b404fdf
[ "MIT" ]
null
null
null
ggjjl1/wsgi.py
ggjjl1/ggjjl1
8f9484b8569ba69aaf5fdda92c9857537b404fdf
[ "MIT" ]
null
null
null
ggjjl1/wsgi.py
ggjjl1/ggjjl1
8f9484b8569ba69aaf5fdda92c9857537b404fdf
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ @author: gaojunliang @time: 2021/2/6 下午11:36 """ from ggjjl1 import create_app app = create_app()
13.636364
29
0.646667
8e0815ee083e6d0e4b52ad68ce61d73f51013ff8
5,497
py
Python
MLStudio/supervised/algorithms/optimization/observers/early_stop.py
j2slab/MLStudio
7d7c4b1073617968c28f0e496020e4720b552451
[ "BSD-3-Clause" ]
1
2019-05-13T01:07:23.000Z
2019-05-13T01:07:23.000Z
MLStudio/supervised/algorithms/optimization/observers/early_stop.py
DecisionScients/MLStudio
7d7c4b1073617968c28f0e496020e4720b552451
[ "BSD-3-Clause" ]
1
2020-04-11T22:14:42.000Z
2020-04-11T22:14:42.000Z
MLStudio/supervised/algorithms/optimization/observers/early_stop.py
decisionscients/MLStudio
7d7c4b1073617968c28f0e496020e4720b552451
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 # -*- coding:utf-8 -*- # =========================================================================== # # Project : ML Studio # # Version : 0.1.14 # # File : early_stop.py ...
42.284615
99
0.525196
cfd57e0f35e3b82c5fc106d68115e08982214f9f
14,345
py
Python
faceboxes_train.py
YuxiangJohn/FaceBoxes.keras
a73f1497b94aa585f01b5aed1b2175b0fdbc6f64
[ "Apache-2.0" ]
3
2019-06-24T10:19:33.000Z
2021-12-28T17:32:59.000Z
faceboxes_train.py
YuxiangJohn/FaceBoxes.keras
a73f1497b94aa585f01b5aed1b2175b0fdbc6f64
[ "Apache-2.0" ]
null
null
null
faceboxes_train.py
YuxiangJohn/FaceBoxes.keras
a73f1497b94aa585f01b5aed1b2175b0fdbc6f64
[ "Apache-2.0" ]
4
2019-08-16T15:03:18.000Z
2021-05-12T14:18:36.000Z
from keras.optimizers import Adam, SGD from keras.callbacks import ModelCheckpoint, LearningRateScheduler, TerminateOnNaN, CSVLogger from keras import backend as K from keras.models import load_model from math import ceil import numpy as np from models.FaceBoxes import faceboxes from keras_loss_function.keras_ssd_loss...
47.032787
193
0.632625
9e789ca38878743dc7b943c388379f6e2772443d
282
py
Python
adbutils/extra/performance/exceptions.py
hakaboom/adb-utils
deb6d62fc636be2969a641df613c1348ea889d6c
[ "Apache-2.0" ]
24
2021-07-27T05:23:57.000Z
2022-03-31T17:54:43.000Z
adbutils/extra/performance/exceptions.py
yundouguai/adb-utils
1932f57cd45b14412b4894264f9aa237a09b3f32
[ "Apache-2.0" ]
13
2021-08-11T09:50:14.000Z
2021-12-20T11:37:50.000Z
adbutils/extra/performance/exceptions.py
yundouguai/adb-utils
1932f57cd45b14412b4894264f9aa237a09b3f32
[ "Apache-2.0" ]
12
2021-08-17T07:35:46.000Z
2022-02-07T02:36:11.000Z
# -*- coding: utf-8 -*- from adbutils.exceptions import AdbBaseError class AdbProcessNotFound(AdbBaseError): """ An error while dumpsys meminfo process not found """ class AdbNoInfoReturn(AdbBaseError): """ An error while adb shell did not return the correct result """
25.636364
70
0.730496
0ccb67d0eb5742c34deca72a861d359d7825449b
3,822
py
Python
tests/components/atag/test_climate.py
domwillcode/home-assistant
f170c80bea70c939c098b5c88320a1c789858958
[ "Apache-2.0" ]
6
2020-07-18T16:33:25.000Z
2021-09-26T09:52:04.000Z
tests/components/atag/test_climate.py
domwillcode/home-assistant
f170c80bea70c939c098b5c88320a1c789858958
[ "Apache-2.0" ]
47
2020-07-23T07:14:33.000Z
2022-03-31T06:01:46.000Z
tests/components/atag/test_climate.py
klauern/home-assistant-core
c18ba6aec0627e6afb6442c678edb5ff2bb17db6
[ "Apache-2.0" ]
5
2020-03-29T00:29:13.000Z
2021-09-06T20:58:40.000Z
"""Tests for the Atag climate platform.""" from homeassistant.components.atag import CLIMATE, DOMAIN from homeassistant.components.climate import ( ATTR_HVAC_ACTION, ATTR_HVAC_MODE, ATTR_PRESET_MODE, HVAC_MODE_HEAT, SERVICE_SET_HVAC_MODE, SERVICE_SET_PRESET_MODE, SERVICE_SET_TEMPERATURE, ) ...
35.06422
81
0.710361
d46fb91937d9996700de444f13ceb43bff98eb49
2,704
py
Python
portfolio/Python/scrapy/shoemetro/onlineshoes.py
0--key/lib
ba7a85dda2b208adc290508ca617bdc55a5ded22
[ "Apache-2.0" ]
null
null
null
portfolio/Python/scrapy/shoemetro/onlineshoes.py
0--key/lib
ba7a85dda2b208adc290508ca617bdc55a5ded22
[ "Apache-2.0" ]
null
null
null
portfolio/Python/scrapy/shoemetro/onlineshoes.py
0--key/lib
ba7a85dda2b208adc290508ca617bdc55a5ded22
[ "Apache-2.0" ]
5
2016-03-22T07:40:46.000Z
2021-05-30T16:12:21.000Z
from scrapy.spider import BaseSpider from scrapy.selector import HtmlXPathSelector from scrapy.http import Request #, HtmlResponse from scrapy.utils.url import urljoin_rfc from scrapy.utils.response import get_base_url from product_spiders.items import Product, ProductLoaderWithNameStrip as ProductLoader import loggi...
37.555556
98
0.569527
41e776f4ff4537090eaadf8338627faec0dcf1c9
593
py
Python
lintcode/465.kth-smallest-sum-in-two-sorted-arrays.py
geemaple/algorithm
68bc5032e1ee52c22ef2f2e608053484c487af54
[ "MIT" ]
177
2017-08-21T08:57:43.000Z
2020-06-22T03:44:22.000Z
lintcode/465.kth-smallest-sum-in-two-sorted-arrays.py
geemaple/algorithm
68bc5032e1ee52c22ef2f2e608053484c487af54
[ "MIT" ]
2
2018-09-06T13:39:12.000Z
2019-06-03T02:54:45.000Z
lintcode/465.kth-smallest-sum-in-two-sorted-arrays.py
geemaple/algorithm
68bc5032e1ee52c22ef2f2e608053484c487af54
[ "MIT" ]
23
2017-08-23T06:01:28.000Z
2020-04-20T03:17:36.000Z
import heapq class Solution: """ @param A: an integer arrays sorted in ascending order @param B: an integer arrays sorted in ascending order @param k: An integer @return: An integer """ def kthSmallestSum(self, A, B, k): # write your code here hq = [] for i in range(...
25.782609
63
0.49747
9678eaec6d6ac95667f02123d2982321f16649b1
300
py
Python
Part-03-Understanding-Software-Crafting-Your-Own-Tools/models/edx-platform/openedx/core/djangoapps/demographics/tests/factories.py
osoco/better-ways-of-thinking-about-software
83e70d23c873509e22362a09a10d3510e10f6992
[ "MIT" ]
3
2021-12-15T04:58:18.000Z
2022-02-06T12:15:37.000Z
Part-03-Understanding-Software-Crafting-Your-Own-Tools/models/edx-platform/openedx/core/djangoapps/demographics/tests/factories.py
osoco/better-ways-of-thinking-about-software
83e70d23c873509e22362a09a10d3510e10f6992
[ "MIT" ]
null
null
null
Part-03-Understanding-Software-Crafting-Your-Own-Tools/models/edx-platform/openedx/core/djangoapps/demographics/tests/factories.py
osoco/better-ways-of-thinking-about-software
83e70d23c873509e22362a09a10d3510e10f6992
[ "MIT" ]
1
2019-01-02T14:38:50.000Z
2019-01-02T14:38:50.000Z
""" Factoryboy factories for Demographics. """ import factory from openedx.core.djangoapps.demographics.models import UserDemographics class UserDemographicsFactory(factory.django.DjangoModelFactory): """ UserDemographics Factory """ class Meta: model = UserDemographics
17.647059
72
0.746667
c71c0f2ff5cee518cf7b1db9124b281c46e54e05
2,642
py
Python
neutron/tests/unit/plugins/ml2/drivers/mech_fake_agent.py
knodir/neutron
ac4e28478ac8a8a0c9f5c5785f6a6bcf532c66b8
[ "Apache-2.0" ]
null
null
null
neutron/tests/unit/plugins/ml2/drivers/mech_fake_agent.py
knodir/neutron
ac4e28478ac8a8a0c9f5c5785f6a6bcf532c66b8
[ "Apache-2.0" ]
5
2019-08-14T06:46:03.000Z
2021-12-13T20:01:25.000Z
neutron/tests/unit/plugins/ml2/drivers/mech_fake_agent.py
knodir/neutron
ac4e28478ac8a8a0c9f5c5785f6a6bcf532c66b8
[ "Apache-2.0" ]
2
2020-03-15T01:24:15.000Z
2020-07-22T20:34:26.000Z
# Copyright (C) 2014,2015 VA Linux Systems Japan K.K. # Copyright (C) 2014 Fumihiko Kakuma <kakuma at valinux co jp> # Copyright (C) 2014,2015 YAMAMOTO Takashi <yamamoto at valinux co jp> # All Rights Reserved. # # Based on openvswitch mechanism driver. # # Copyright (c) 2013 OpenStack Foundation # All Rights Reserved....
39.432836
78
0.722559
a99ca55752a2354fa1c242c5e11a8254b868c345
5,791
py
Python
lib/model/faster_rcnn/faster_rcnn.py
raghavgoyal14/faster-rcnn.pytorch
960a703466fb84001cc14e380c9db73f482ca159
[ "MIT" ]
1
2019-05-22T16:25:36.000Z
2019-05-22T16:25:36.000Z
lib/model/faster_rcnn/faster_rcnn.py
raghavgoyal14/faster-rcnn.pytorch
960a703466fb84001cc14e380c9db73f482ca159
[ "MIT" ]
null
null
null
lib/model/faster_rcnn/faster_rcnn.py
raghavgoyal14/faster-rcnn.pytorch
960a703466fb84001cc14e380c9db73f482ca159
[ "MIT" ]
null
null
null
import random import torch import torch.nn as nn import torch.nn.functional as F from torch.autograd import Variable import torchvision.models as models from torch.autograd import Variable import numpy as np from model.utils.config import cfg from model.rpn.rpn import _RPN from model.roi_pooling.modules.roi_pool import...
42.270073
138
0.667242
112f076e551e5a05fb8db895f4e74fe2108425dc
1,638
py
Python
nextdl/extractor/odatv.py
devenu85/nextdl
0b458f556e2e0be80cb94bd9a9b1405ad2e9182d
[ "MIT" ]
1
2021-12-19T13:55:20.000Z
2021-12-19T13:55:20.000Z
nextdl/extractor/odatv.py
devenu85/nextdl
0b458f556e2e0be80cb94bd9a9b1405ad2e9182d
[ "MIT" ]
null
null
null
nextdl/extractor/odatv.py
devenu85/nextdl
0b458f556e2e0be80cb94bd9a9b1405ad2e9182d
[ "MIT" ]
null
null
null
# coding: utf-8 from __future__ import unicode_literals from ..utils import NO_DEFAULT, ExtractorError, remove_start from .common import InfoExtractor class OdaTVIE(InfoExtractor): _VALID_URL = ( r"https?://(?:www\.)?odatv\.com/(?:mob|vid)_video\.php\?.*\bid=(?P<id>[^&]+)" ) _TESTS = [ { ...
28.736842
85
0.514042
0c2c8688dcc405ea1692fd892aa86915ccd856a5
6,757
py
Python
src/utils.py
dalijolijo/electrum-server
236ae6f25ff7b2112d79e096b2c3a2d619eface9
[ "MIT" ]
null
null
null
src/utils.py
dalijolijo/electrum-server
236ae6f25ff7b2112d79e096b2c3a2d619eface9
[ "MIT" ]
null
null
null
src/utils.py
dalijolijo/electrum-server
236ae6f25ff7b2112d79e096b2c3a2d619eface9
[ "MIT" ]
null
null
null
#!/usr/bin/env python # Copyright(C) 2011-2016 Thomas Voegtlin # # Permission is hereby granted, free of charge, to any person # obtaining a copy of this software and associated documentation files # (the "Software"), to deal in the Software without restriction, # including without limitation the rights to use, copy, m...
25.212687
107
0.657984
78a4618dfa5fef0d1c85b9453a8c92e9ad3b35e8
1,940
py
Python
src/test/python/SourceDevicesTest.py
werpu/input_pipe
aba735e1f2a9731d84d50545e8009c9bb1d30b9a
[ "MIT" ]
11
2019-06-05T20:22:27.000Z
2021-02-18T18:27:02.000Z
src/test/python/SourceDevicesTest.py
werpu/input_pipe
aba735e1f2a9731d84d50545e8009c9bb1d30b9a
[ "MIT" ]
1
2020-11-30T10:39:10.000Z
2020-12-01T21:27:04.000Z
src/test/python/SourceDevicesTest.py
werpu/input_pipe
aba735e1f2a9731d84d50545e8009c9bb1d30b9a
[ "MIT" ]
2
2020-02-19T13:35:20.000Z
2020-06-11T13:25:03.000Z
# MIT License # # Copyright (c) 2019 Werner Punz # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, ...
37.307692
104
0.751031
e0e022fc40c764caa9ed7caf9e5a1862c8e2ef31
838
py
Python
02_28 - Plots/es_1-2.py
albertofinardi/FCI_1
e25d8a92100eafc809060dd0ac02fb547e635792
[ "MIT" ]
null
null
null
02_28 - Plots/es_1-2.py
albertofinardi/FCI_1
e25d8a92100eafc809060dd0ac02fb547e635792
[ "MIT" ]
null
null
null
02_28 - Plots/es_1-2.py
albertofinardi/FCI_1
e25d8a92100eafc809060dd0ac02fb547e635792
[ "MIT" ]
null
null
null
import requests urls = ['http://www.google.com', 'http://www.youtube.com', 'http://www.polimi.it', 'http://www.wikipedia.org', 'http://www.amazon.com', 'http://www.twitter.com'] def media(lista): return sum(lista)/len(lista) def best_mean_fn(iterations): means = [] for (i, url) in enumerate(urls): ...
27.933333
161
0.595465
36e59a1e22f64bb9ddbec28d5c08f3b114282d87
812
py
Python
db_search/urls.py
mehul2029/YourTube
4f14b5a277f6a9265fb760b4ae980274de4c3e9b
[ "MIT" ]
null
null
null
db_search/urls.py
mehul2029/YourTube
4f14b5a277f6a9265fb760b4ae980274de4c3e9b
[ "MIT" ]
null
null
null
db_search/urls.py
mehul2029/YourTube
4f14b5a277f6a9265fb760b4ae980274de4c3e9b
[ "MIT" ]
null
null
null
"""db_search URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/1.10/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: url(r'^$', views.home, name='home') Class-...
35.304348
79
0.698276
60c37ee70b1e51d97fbd16dfd9d665636b2be1a8
962
py
Python
packaging/setup/plugins/ovirt-engine-common/ovirt-engine/db/__init__.py
dangel101/ovirt-engine
47bfc7ebc5de447ab457cca2dc03ed936203c1d1
[ "Apache-2.0" ]
1
2018-04-09T02:58:53.000Z
2018-04-09T02:58:53.000Z
packaging/setup/plugins/ovirt-engine-common/ovirt-engine/db/__init__.py
dangel101/ovirt-engine
47bfc7ebc5de447ab457cca2dc03ed936203c1d1
[ "Apache-2.0" ]
null
null
null
packaging/setup/plugins/ovirt-engine-common/ovirt-engine/db/__init__.py
dangel101/ovirt-engine
47bfc7ebc5de447ab457cca2dc03ed936203c1d1
[ "Apache-2.0" ]
null
null
null
# # ovirt-engine-setup -- ovirt engine setup # Copyright (C) 2013-2015 Red Hat, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unl...
26
74
0.748441
6d514801636be159185fc46f3b066ca499eb2f29
1,175
py
Python
aop_mosaic/utils.py
rmg55/aop_mosaic
053059adc56ec2576b8b66f7efc070f02fd57d5c
[ "MIT" ]
null
null
null
aop_mosaic/utils.py
rmg55/aop_mosaic
053059adc56ec2576b8b66f7efc070f02fd57d5c
[ "MIT" ]
null
null
null
aop_mosaic/utils.py
rmg55/aop_mosaic
053059adc56ec2576b8b66f7efc070f02fd57d5c
[ "MIT" ]
null
null
null
import h5py import dask from dask import array as da #Helper def get_obj(hy_obj): return(hy_obj) def h5_zenith_dask(file: str) -> dask.array.core.Array: h = h5py.File(file,'r')['CPER']['Reflectance']['Metadata']['to-sensor_Zenith_Angle'] a = da.array(h) return(a,h.shape) def mapinfo_extents(meta: st...
31.756757
143
0.646809
4e43f603c5f6047d2671a73f9d165c94d223125a
9,283
py
Python
textrenderer/liner.py
GuoLiuFang/text_renderer
c2be1ea53720c3bc895c29cc566f99753d93f12a
[ "MIT" ]
null
null
null
textrenderer/liner.py
GuoLiuFang/text_renderer
c2be1ea53720c3bc895c29cc566f99753d93f12a
[ "MIT" ]
null
null
null
textrenderer/liner.py
GuoLiuFang/text_renderer
c2be1ea53720c3bc895c29cc566f99753d93f12a
[ "MIT" ]
null
null
null
import random import cv2 import numpy as np import math class LineState(object): tableline_x_offsets = range(8, 40) tableline_y_offsets = range(3, 10) tableline_thickness = [1, 2, 2, 2, 2, 2, 2, 2, 2, 3] # 0/1/2/3: 仅单边(左上右下) # 4/5/6/7: 两边都有线(左上,右上,右下,左下) tableline_options = [0, 2, 3, 3, 0, 2, ...
37.132
129
0.553485
beaebc423f79f1ca439234ea8a66b09346ff8189
6,591
py
Python
google/ads/google_ads/v6/proto/errors/campaign_experiment_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
null
null
null
google/ads/google_ads/v6/proto/errors/campaign_experiment_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
null
null
null
google/ads/google_ads/v6/proto/errors/campaign_experiment_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/ads/googleads/v6/errors/campaign_experiment_error.proto """Generated protocol buffer code.""" from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf imp...
45.770833
1,181
0.796389
e98a97073b1670ac16a8691a0fec6e2a08f26c07
33
py
Python
redirect/domain.py
FullBoreStudios/heroku-301
29deb7d0b6169bc994d4435de88bb75e73ff5a39
[ "Unlicense" ]
null
null
null
redirect/domain.py
FullBoreStudios/heroku-301
29deb7d0b6169bc994d4435de88bb75e73ff5a39
[ "Unlicense" ]
5
2019-12-04T23:47:00.000Z
2021-06-09T18:07:13.000Z
redirect/domain.py
FullBoreStudios/heroku-301
29deb7d0b6169bc994d4435de88bb75e73ff5a39
[ "Unlicense" ]
4
2019-07-15T19:06:10.000Z
2020-01-26T12:29:17.000Z
redirect_domain = 'fbstudios.com'
33
33
0.818182
2e0a851d1ca61a2ffd779b3b7629cc532c7d9f41
80,757
py
Python
tests/testUtils.py
momokapapa/hanakapapa
4ce9b032f9dc6ad79eb2756c347be7523fd2a797
[ "MIT" ]
null
null
null
tests/testUtils.py
momokapapa/hanakapapa
4ce9b032f9dc6ad79eb2756c347be7523fd2a797
[ "MIT" ]
null
null
null
tests/testUtils.py
momokapapa/hanakapapa
4ce9b032f9dc6ad79eb2756c347be7523fd2a797
[ "MIT" ]
null
null
null
import copy import decimal import subprocess import time import glob import shutil import time import os import platform from collections import namedtuple import re import string import signal import time import datetime import inspect import sys import random import io import json ###################################...
40.561025
279
0.588135
a5425305f50f0b527cd85df20c4a343ec1b33f62
1,756
py
Python
hard-gists/9397410/snippet.py
jjhenkel/dockerizeme
eaa4fe5366f6b9adf74399eab01c712cacaeb279
[ "Apache-2.0" ]
21
2019-07-08T08:26:45.000Z
2022-01-24T23:53:25.000Z
hard-gists/9397410/snippet.py
jjhenkel/dockerizeme
eaa4fe5366f6b9adf74399eab01c712cacaeb279
[ "Apache-2.0" ]
5
2019-06-15T14:47:47.000Z
2022-02-26T05:02:56.000Z
hard-gists/9397410/snippet.py
jjhenkel/dockerizeme
eaa4fe5366f6b9adf74399eab01c712cacaeb279
[ "Apache-2.0" ]
17
2019-05-16T03:50:34.000Z
2021-01-14T14:35:12.000Z
from execute import execute, Retcode def dd(ifile, ofile, bs, count=None, seek=None): """ Wrapper for the GNU dd command. Inputs: ifile (str): Input file ofile (str): Output file bs (str): Block size count (str): Number of blocks to copy seek (str): Seek x b...
29.762712
71
0.576879
5055cecdcf0f11eca0cb876c46c55e3482891f58
10,134
py
Python
DSGP.py
SK-tklab/DSGP_sampling
53410004afba3251d0f11904407e1007bc5ff27b
[ "MIT" ]
2
2020-11-01T15:56:18.000Z
2020-11-02T02:03:18.000Z
DSGP.py
SK-tklab/DSGP_sampling
53410004afba3251d0f11904407e1007bc5ff27b
[ "MIT" ]
null
null
null
DSGP.py
SK-tklab/DSGP_sampling
53410004afba3251d0f11904407e1007bc5ff27b
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt from scipy.linalg import cholesky, cho_solve import seaborn as sns plt.rcParams['font.size'] = 11 sns.set_style('darkgrid') class GP: def __init__(self, x_train: np.ndarray, y_train: np.ndarray, noise_var: float = 1., lscale: float = 1., k_var: ...
33.335526
114
0.587527
e32900a231a6461c79df070696902dd005381dd4
1,670
py
Python
test/unit/test_email.py
vimc/montagu-task-queue
7ef8e449f10988d3c53b974086873e740e7dea86
[ "MIT" ]
null
null
null
test/unit/test_email.py
vimc/montagu-task-queue
7ef8e449f10988d3c53b974086873e740e7dea86
[ "MIT" ]
26
2020-06-05T09:57:54.000Z
2022-03-23T10:14:11.000Z
test/unit/test_email.py
vimc/montagu-task-queue
7ef8e449f10988d3c53b974086873e740e7dea86
[ "MIT" ]
null
null
null
from unittest.mock import patch, call from src.utils.email import Emailer, send_email from test import ExceptionMatching test_template_values = {"disease": "d1", "report_version_url": "http://test.com/test_report_version", "group": "group1", ...
36.304348
72
0.596407
9ec0ad0d6dfa77ccccc73aeb4db11bd36d3da62c
18,863
py
Python
from_3b1b/active/diffyq/part4/complex_functions.py
Tarang74/manim
df34d6fc0470916cfba63534b023addb69cdec9a
[ "MIT" ]
1
2021-03-26T08:23:35.000Z
2021-03-26T08:23:35.000Z
from_3b1b/active/diffyq/part4/complex_functions.py
Tarang74/manim
df34d6fc0470916cfba63534b023addb69cdec9a
[ "MIT" ]
null
null
null
from_3b1b/active/diffyq/part4/complex_functions.py
Tarang74/manim
df34d6fc0470916cfba63534b023addb69cdec9a
[ "MIT" ]
null
null
null
from manimlib.imports import * class GeneralizeToComplexFunctions(Scene): CONFIG = { "axes_config": { "x_min": 0, "x_max": 10, "x_axis_config": { "stroke_width": 2, }, "y_min": -2.5, "y_max": 2.5, "y_axis_c...
29.02
79
0.557228
85060607e25439363d90a45d40eef313c102fdfa
35,012
py
Python
typeclasses/mixins.py
LeBulldoge/arxcode
c12ca5076b5e37fda1b0aa02946570974a348ce6
[ "MIT" ]
null
null
null
typeclasses/mixins.py
LeBulldoge/arxcode
c12ca5076b5e37fda1b0aa02946570974a348ce6
[ "MIT" ]
null
null
null
typeclasses/mixins.py
LeBulldoge/arxcode
c12ca5076b5e37fda1b0aa02946570974a348ce6
[ "MIT" ]
null
null
null
from evennia_extensions.object_extensions.item_data_handler import ItemDataHandler from server.utils.arx_utils import sub_old_ansi, text_box, lowercase_kwargs import re from datetime import datetime from evennia.utils.utils import lazy_property from evennia.utils.ansi import parse_ansi from typeclasses.exceptions impo...
32.388529
117
0.569433
45368a22103bcbd70f1e9a6a6884007f702a32f1
2,121
py
Python
game/core.py
sergiyz57918/pypboy
ff7af900994fb7490c1de36831f5ea535d0fef26
[ "MIT" ]
1
2022-03-26T03:10:51.000Z
2022-03-26T03:10:51.000Z
game/core.py
sergiyz57918/pypboy
ff7af900994fb7490c1de36831f5ea535d0fef26
[ "MIT" ]
null
null
null
game/core.py
sergiyz57918/pypboy
ff7af900994fb7490c1de36831f5ea535d0fef26
[ "MIT" ]
3
2020-07-21T14:27:26.000Z
2021-08-19T22:33:49.000Z
import pygame import time class Engine(object): EVENTS_UPDATE = pygame.USEREVENT + 1 EVENTS_RENDER = pygame.USEREVENT + 2 def __init__(self, title, width, height, *args, **kwargs): super(Engine, self).__init__(*args, **kwargs) #self.window = pygame.display.set_mode((width, height),pygame.FULLSCREEN) self.wi...
26.185185
76
0.718529
8decf6a557692e09998d4f3305f916202cbe6e0b
85,263
py
Python
brian2/spatialneuron/morphology.py
awillats/brian2
e1107ed0cc4a7d6c69c1e2634b675ba09edfd9fc
[ "BSD-2-Clause" ]
1
2021-06-10T15:28:51.000Z
2021-06-10T15:28:51.000Z
brian2/spatialneuron/morphology.py
awillats/brian2
e1107ed0cc4a7d6c69c1e2634b675ba09edfd9fc
[ "BSD-2-Clause" ]
null
null
null
brian2/spatialneuron/morphology.py
awillats/brian2
e1107ed0cc4a7d6c69c1e2634b675ba09edfd9fc
[ "BSD-2-Clause" ]
null
null
null
''' Neuronal morphology module. This module defines classes to load and build neuronal morphologies. ''' import abc import numbers from abc import abstractmethod from collections import OrderedDict, defaultdict, namedtuple import os from brian2.units.allunits import meter from brian2.utils.logger import get_logger fro...
38.114886
105
0.569004
45627a159f4cbaf001937452648492e5fa9d791c
919
py
Python
det3d/datasets/pipelines/__init__.py
PatrickChoDev/CSA-3D
34aa87194d653a93f16834d485738255f55112f0
[ "Apache-2.0" ]
1,318
2019-09-13T06:57:32.000Z
2022-03-31T07:01:21.000Z
det3d/datasets/pipelines/__init__.py
PatrickChoDev/CSA-3D
34aa87194d653a93f16834d485738255f55112f0
[ "Apache-2.0" ]
142
2019-09-26T04:25:57.000Z
2022-03-29T17:21:03.000Z
det3d/datasets/pipelines/__init__.py
PatrickChoDev/CSA-3D
34aa87194d653a93f16834d485738255f55112f0
[ "Apache-2.0" ]
309
2019-09-21T09:21:38.000Z
2022-03-31T02:06:56.000Z
from .compose import Compose from .formating import Reformat # from .loading import LoadAnnotations, LoadImageFromFile, LoadProposals from .loading import * from .test_aug import MultiScaleFlipAug from .transforms import ( Expand, MinIoURandomCrop, Normalize, Pad, PhotoMetricDistortion, RandomC...
20.422222
72
0.677911
b40b0a7de37735174b6006afd272eb515773926c
4,861
py
Python
parsec/cli.py
erasche/parsec
c2f1bda7ff776f9aa121c7b94d62e3da2fad93f6
[ "Apache-2.0" ]
8
2015-03-27T17:09:15.000Z
2021-07-13T15:33:02.000Z
parsec/cli.py
erasche/parsec
c2f1bda7ff776f9aa121c7b94d62e3da2fad93f6
[ "Apache-2.0" ]
30
2015-02-27T21:21:47.000Z
2021-08-31T14:19:55.000Z
parsec/cli.py
erasche/parsec
c2f1bda7ff776f9aa121c7b94d62e3da2fad93f6
[ "Apache-2.0" ]
12
2017-06-01T03:49:23.000Z
2021-07-13T15:33:06.000Z
from __future__ import absolute_import import os import sys import click import json from .io import error from .config import read_global_config, global_config_path, set_global_config_path # noqa, ditto from .galaxy import get_galaxy_instance, get_toolshed_instance from parsec import __version__ # noqa, ditto CONT...
30.572327
141
0.621271
ddb0a6e9c6f655e3f7b1d0b824ecfcd88a548d93
2,686
py
Python
bugzoo/cli/app.py
pdreiter/BugZoo
e164ee67ff8bd3addfcc87b5e38ff1774992196b
[ "MIT" ]
53
2017-12-02T03:22:06.000Z
2022-03-10T22:20:52.000Z
bugzoo/cli/app.py
pdreiter/BugZoo
e164ee67ff8bd3addfcc87b5e38ff1774992196b
[ "MIT" ]
145
2017-11-29T23:23:06.000Z
2020-09-17T22:17:44.000Z
bugzoo/cli/app.py
pdreiter/BugZoo
e164ee67ff8bd3addfcc87b5e38ff1774992196b
[ "MIT" ]
8
2018-06-26T17:58:49.000Z
2021-09-07T14:03:41.000Z
import sys import os import logging import datetime import cement from .controllers.base import BaseController from .controllers.bug import BugController from .controllers.source import SourceController from .controllers.tool import ToolController from .controllers.container import ContainerController from ..manager ...
29.516484
80
0.646314
421b94deec38762f5dfce15e3af96dc77be0c817
1,155
py
Python
src/recommendation/make_feature/find_specific_product.py
odobenuskr/2019_capstone_FlexAds
e37708484d983326806c0d6a0c5ae7157ea57e59
[ "MIT" ]
12
2019-03-08T15:49:24.000Z
2020-08-03T05:01:44.000Z
src/recommendation/make_feature/find_specific_product.py
kookmin-sw/2019-cap1-2019_4
e64aa4590ac58dca535024118ed4d4bd0b3eb699
[ "MIT" ]
63
2019-03-08T15:23:19.000Z
2019-06-01T07:10:23.000Z
src/recommendation/make_feature/find_specific_product.py
odobenuskr/2019_capstone_FlexAds
e37708484d983326806c0d6a0c5ae7157ea57e59
[ "MIT" ]
11
2019-03-10T02:12:24.000Z
2021-04-02T07:16:01.000Z
import numpy as np # linear algebra import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv) import seaborn as sns import csv import pickle import xgboost as xgb # data from RDS----------------------- db = pymysql.connect(host="", port= , user="",passwd ="", db="") SQL = "SELECT * FROM orders" orders_df...
31.216216
102
0.690043
3661a616278c6ab35b73e0466287057db10c1a4e
1,070
py
Python
shopyo/modules/login/login.py
mghall25/shopyo-1
43a8d7faefd8f9689430cf2d21d3cb201d0f4ff4
[ "MIT" ]
1
2020-04-05T13:03:11.000Z
2020-04-05T13:03:11.000Z
shopyo/modules/login/login.py
mghall25/shopyo-1
43a8d7faefd8f9689430cf2d21d3cb201d0f4ff4
[ "MIT" ]
null
null
null
shopyo/modules/login/login.py
mghall25/shopyo-1
43a8d7faefd8f9689430cf2d21d3cb201d0f4ff4
[ "MIT" ]
null
null
null
from flask import ( Blueprint, render_template, request, redirect, url_for, flash ) from flask_login import login_required, current_user, login_user, logout_user from addon import db, login_manager from modules.admin.models import Users from project_api import base_context login_blueprint = Blueprint('login'...
30.571429
96
0.698131
d3e9bf411d70d5f636d6d006af7eab725d1e3800
994
py
Python
packages/w3af/w3af/core/controllers/misc/tests/test_io.py
ZooAtmosphereGroup/HelloPackages
0ccffd33bf927b13d28c8f715ed35004c33465d9
[ "Apache-2.0" ]
3
2019-04-09T22:59:33.000Z
2019-06-14T09:23:24.000Z
tools/w3af/w3af/core/controllers/misc/tests/test_io.py
sravani-m/Web-Application-Security-Framework
d9f71538f5cba6fe1d8eabcb26c557565472f6a6
[ "MIT" ]
null
null
null
tools/w3af/w3af/core/controllers/misc/tests/test_io.py
sravani-m/Web-Application-Security-Framework
d9f71538f5cba6fe1d8eabcb26c557565472f6a6
[ "MIT" ]
null
null
null
""" test_io.py Copyright 2015 Andres Riancho This file is part of w3af, http://w3af.org/ . w3af 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 version 2 of the License. w3af is distributed in the hope that it ...
30.121212
74
0.750503
0e41db598f9b1c91748ffb5db8afff310b386146
8,075
py
Python
myvenv/lib/python3.5/site-packages/IPython/core/logger.py
tuvapp/tuvappcom
5ca2be19f4b0c86a1d4a9553711a4da9d3f32841
[ "MIT" ]
6,989
2017-07-18T06:23:18.000Z
2022-03-31T15:58:36.000Z
SLpackage/private/thirdparty/pythonpkgs/ipython/ipython_4.0.0/lib/python2.7/site-packages/IPython/core/logger.py
fanglab/6mASCOPE
3f1fdcb7693ff152f17623ce549526ec272698b1
[ "BSD-3-Clause" ]
1,978
2017-07-18T09:17:58.000Z
2022-03-31T14:28:43.000Z
SLpackage/private/thirdparty/pythonpkgs/ipython/ipython_4.0.0/lib/python2.7/site-packages/IPython/core/logger.py
fanglab/6mASCOPE
3f1fdcb7693ff152f17623ce549526ec272698b1
[ "BSD-3-Clause" ]
1,228
2017-07-18T09:03:13.000Z
2022-03-29T05:57:40.000Z
"""Logger class for IPython's logging facilities. """ from __future__ import print_function #***************************************************************************** # Copyright (C) 2001 Janko Hauser <jhauser@zscout.de> and # Copyright (C) 2001-2006 Fernando Perez <fperez@colorado.edu> # # Distribute...
36.373874
83
0.559009
e27b4f00b4df79ce3f93d6e89f0a8cc44d075462
417
py
Python
electionleaflets/apps/parties/urls.py
electionleaflets/electionleaflets
4110e96a3035c32d0b6ff3c9f832c5e003728170
[ "MIT" ]
null
null
null
electionleaflets/apps/parties/urls.py
electionleaflets/electionleaflets
4110e96a3035c32d0b6ff3c9f832c5e003728170
[ "MIT" ]
23
2015-02-19T14:02:23.000Z
2015-04-30T11:14:01.000Z
electionleaflets/apps/parties/urls.py
electionleaflets/electionleaflets
4110e96a3035c32d0b6ff3c9f832c5e003728170
[ "MIT" ]
2
2015-02-02T19:39:54.000Z
2017-02-08T09:19:53.000Z
from django.conf.urls import patterns, include, handler500, url from django.conf import settings from parties.views import view_party, view_attacking_party, view_parties urlpatterns = patterns( '', url(r'^/$', view_parties, name='parties'), url(r'^/(?P<slug>[\w_\-\.]+)/$', view_party,name='party'), ...
32.076923
93
0.669065
6bcd80af417d40c40e03e988f94a062547906d92
663
py
Python
manage.py
Patrickberzins/Tweagle_Final
4a7e426089dc5d3270c99fb4eb1dee243a44f924
[ "MIT" ]
null
null
null
manage.py
Patrickberzins/Tweagle_Final
4a7e426089dc5d3270c99fb4eb1dee243a44f924
[ "MIT" ]
null
null
null
manage.py
Patrickberzins/Tweagle_Final
4a7e426089dc5d3270c99fb4eb1dee243a44f924
[ "MIT" ]
null
null
null
#!/usr/bin/env python """Django's command-line utility for administrative tasks.""" import os import sys def main(): """Run administrative tasks.""" os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'Tweagle.settings') try: from django.core.management import execute_from_command_line except Impo...
28.826087
73
0.678733
6025ba5f907f0f562117b896ea6686d3b0f620ee
1,000
py
Python
nanopose/model/loss/l1_loss.py
674106399/nanopose
d0d973e2bcb105ba57118daeb2b510279a56b5a2
[ "Apache-2.0" ]
null
null
null
nanopose/model/loss/l1_loss.py
674106399/nanopose
d0d973e2bcb105ba57118daeb2b510279a56b5a2
[ "Apache-2.0" ]
null
null
null
nanopose/model/loss/l1_loss.py
674106399/nanopose
d0d973e2bcb105ba57118daeb2b510279a56b5a2
[ "Apache-2.0" ]
null
null
null
import torch import torch.nn as nn class L1Loss(nn.Module): def __init__(self, use_jc_ohkm=False): super(L1Loss, self).__init__() self.use_jc_ohkm = use_jc_ohkm def ohkm(self, loss, topk=8): ohkm_loss = 0. for i in range(loss.size(0)): sub_loss = loss[i] ...
29.411765
79
0.562
0da036bc3dd21915599675aa4073b9e0cee84966
1,857
py
Python
tests/logdir_test.py
timotheecour/ncluster
24baf049c2690505bf4dd63ec7d8822edb81b5a9
[ "MIT" ]
34
2019-05-19T02:49:02.000Z
2021-11-04T18:49:48.000Z
tests/logdir_test.py
timotheecour/ncluster
24baf049c2690505bf4dd63ec7d8822edb81b5a9
[ "MIT" ]
66
2019-05-19T18:46:53.000Z
2019-09-16T00:48:25.000Z
tests/logdir_test.py
timotheecour/ncluster
24baf049c2690505bf4dd63ec7d8822edb81b5a9
[ "MIT" ]
6
2018-09-17T20:45:57.000Z
2019-12-29T08:48:42.000Z
#!/bin/env python # tests to make sure that logdir logic works import inspect import random import sys import threading import ncluster def test_two_jobs(): run = ncluster.make_run('logdir_test') job1 = run.make_job('job1') task1 = job1.tasks[0] task1.run(f'echo hello > {task1.logdir}/message') job2 = run....
24.116883
73
0.700592
84595be827f33b9a57ce1dc52f3de30b5fe34132
866
py
Python
titanic/classifier.py
lbn/kaggle
850dc55d88582fe7c175964b4bb2d523db72f27c
[ "MIT" ]
null
null
null
titanic/classifier.py
lbn/kaggle
850dc55d88582fe7c175964b4bb2d523db72f27c
[ "MIT" ]
null
null
null
titanic/classifier.py
lbn/kaggle
850dc55d88582fe7c175964b4bb2d523db72f27c
[ "MIT" ]
null
null
null
from sklearn.svm import LinearSVC from sklearn.tree import DecisionTreeClassifier from sklearn.ensemble import AdaBoostClassifier, GradientBoostingClassifier, RandomForestClassifier from sklearn.naive_bayes import GaussianNB from sklearn.pipeline import Pipeline from sklearn.linear_model import SGDClassifier from xgb i...
48.111111
99
0.788684
d02b3aa069b63e4d2ee47db284c64bb8f1f6ef88
16,889
py
Python
utils/process_reb.py
Kali-Hac/MG-SCR
abbb0944ab53bf77ed0b2661bd2123e9d52f50d9
[ "MIT" ]
3
2021-06-27T13:24:24.000Z
2022-01-08T13:59:44.000Z
utils/process_reb.py
Kali-Hac/MG-SCR
abbb0944ab53bf77ed0b2661bd2123e9d52f50d9
[ "MIT" ]
null
null
null
utils/process_reb.py
Kali-Hac/MG-SCR
abbb0944ab53bf77ed0b2661bd2123e9d52f50d9
[ "MIT" ]
1
2021-06-08T14:02:39.000Z
2021-06-08T14:02:39.000Z
import numpy as np import pickle as pkl import networkx as nx import scipy.sparse as sp from scipy.sparse.linalg.eigen.arpack import eigsh import sys from sklearn.preprocessing import label_binarize from sklearn.metrics import roc_curve, auc """ Generate training data for each dataset. """ def gen_train_data(dataset...
34.397149
113
0.655575
fcd0400566f0a53eebe62db4c14144ffd84869e3
14,988
py
Python
xarray/core/duck_array_ops.py
martinResearch/xarray
e921d1bfa4785b10310f8b5d46a1efacba7e1cc9
[ "Apache-2.0" ]
1
2019-10-05T18:20:27.000Z
2019-10-05T18:20:27.000Z
xarray/core/duck_array_ops.py
martinResearch/xarray
e921d1bfa4785b10310f8b5d46a1efacba7e1cc9
[ "Apache-2.0" ]
null
null
null
xarray/core/duck_array_ops.py
martinResearch/xarray
e921d1bfa4785b10310f8b5d46a1efacba7e1cc9
[ "Apache-2.0" ]
null
null
null
"""Compatibility module defining operations on duck numpy-arrays. Currently, this means Dask or NumPy arrays. None of these functions should accept or return xarray objects. """ import contextlib import inspect import warnings from functools import partial import numpy as np import pandas as pd from . import dask_ar...
32.37149
87
0.660395
e81e7c8661647fa61eff2661f81e6356343ad60c
5,103
py
Python
third_party/typ/typ/tests/artifacts_test.py
xinghun61/catapult
a120c4f6e011a9830eefdb783b818ab7113aacfd
[ "BSD-3-Clause" ]
null
null
null
third_party/typ/typ/tests/artifacts_test.py
xinghun61/catapult
a120c4f6e011a9830eefdb783b818ab7113aacfd
[ "BSD-3-Clause" ]
5
2020-09-07T12:36:46.000Z
2022-03-02T05:49:30.000Z
third_party/typ/typ/tests/artifacts_test.py
xinghun61/catapult
a120c4f6e011a9830eefdb783b818ab7113aacfd
[ "BSD-3-Clause" ]
1
2020-07-25T00:02:48.000Z
2020-07-25T00:02:48.000Z
# Copyright 2019 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 ag...
39.253846
83
0.707427
449ed6da6995264815ed08f44ae0fb7711546871
7,750
py
Python
sdk/python/pulumi_azure_nextgen/documentdb/v20190801/sql_resource_sql_database.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_nextgen/documentdb/v20190801/sql_resource_sql_database.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_nextgen/documentdb/v20190801/sql_resource_sql_database.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from ... import _utilities, _tables from...
52.364865
564
0.672516