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
56185b126c1c6cd1aee3411e9637e3f4ba5da646
4,933
py
Python
glue/viewers/image/compat.py
sergiopasra/glue
c25a217a122a11818382672c99cb21f57a30636f
[ "BSD-3-Clause" ]
1
2019-12-17T07:58:35.000Z
2019-12-17T07:58:35.000Z
glue/viewers/image/compat.py
sergiopasra/glue
c25a217a122a11818382672c99cb21f57a30636f
[ "BSD-3-Clause" ]
null
null
null
glue/viewers/image/compat.py
sergiopasra/glue
c25a217a122a11818382672c99cb21f57a30636f
[ "BSD-3-Clause" ]
1
2019-08-04T14:10:12.000Z
2019-08-04T14:10:12.000Z
from __future__ import absolute_import, division, print_function import uuid import numpy as np from glue.viewers.image.state import ImageLayerState, ImageSubsetLayerState from glue.viewers.scatter.state import ScatterLayerState STATE_CLASS = {} STATE_CLASS['ImageLayerArtist'] = ImageLayerState STATE_CLASS['ScatterL...
38.24031
95
0.588283
369fa80b40b091564f7a909c251fea12a1999b8f
48
py
Python
config.py
ydogukan/TRON_Discord_Bot
87c1ec8fa8fb1291ecf332b13fe5f6b856bdf8fc
[ "MIT" ]
null
null
null
config.py
ydogukan/TRON_Discord_Bot
87c1ec8fa8fb1291ecf332b13fe5f6b856bdf8fc
[ "MIT" ]
null
null
null
config.py
ydogukan/TRON_Discord_Bot
87c1ec8fa8fb1291ecf332b13fe5f6b856bdf8fc
[ "MIT" ]
null
null
null
queues = {} global now_playing now_playing = []
12
18
0.708333
22cbeee3d5e38481ae49455caaa4b2d29cb018ea
2,359
py
Python
scripts/Reader_RDM6300.py
emhal/RPi-Jukebox-RFID
0914ef7b1b018f3c39a127ab33d95e3a306e1e06
[ "MIT" ]
null
null
null
scripts/Reader_RDM6300.py
emhal/RPi-Jukebox-RFID
0914ef7b1b018f3c39a127ab33d95e3a306e1e06
[ "MIT" ]
null
null
null
scripts/Reader_RDM6300.py
emhal/RPi-Jukebox-RFID
0914ef7b1b018f3c39a127ab33d95e3a306e1e06
[ "MIT" ]
null
null
null
""" Support for the RDM6300 serial RFID module 1.) Connect the RDM6300 module ------------------------------ Connect the RDM6300 module to the serial GPIO pins 14 and 15. 2.) Enable GPIO serial port --------------------------- Edit the /boot/config.txt (sudo nano /boot/config.txt) and add the following line: enab...
31.039474
86
0.529462
b98ca19a1ebd063a0776d50ba072626e515fcf84
3,600
py
Python
src/sphinx/conf.py
cvogt/sbt
1432d633e2652c51baa8af1c84411bd0517b6bf9
[ "MIT", "Apache-2.0", "BSD-3-Clause" ]
null
null
null
src/sphinx/conf.py
cvogt/sbt
1432d633e2652c51baa8af1c84411bd0517b6bf9
[ "MIT", "Apache-2.0", "BSD-3-Clause" ]
null
null
null
src/sphinx/conf.py
cvogt/sbt
1432d633e2652c51baa8af1c84411bd0517b6bf9
[ "MIT", "Apache-2.0", "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- import sys, os sys.path.append(os.path.abspath('_sphinx/exts')) extensions = ['sphinxcontrib.issuetracker', 'sphinx.ext.extlinks', 'howto', 'codeliteral', 'key'] # Project variables project = 'sbt' version = os.environ['sbt.partial.version'] site_version = os.environ['sbt.site.version'] rele...
32.727273
101
0.750278
48926be6fe65f47f8f85f12dafc9f1e8f6f9f47b
3,731
py
Python
onadata/apps/logger/management/commands/create_image_thumbnails.py
BuildAMovement/whistler-kobocat
7f61dd0761bb0aa5b27c909bcff8c29453d3311d
[ "BSD-2-Clause" ]
38
2017-02-28T05:39:40.000Z
2019-01-16T04:39:04.000Z
onadata/apps/logger/management/commands/create_image_thumbnails.py
BuildAMovement/whistler-kobocat
7f61dd0761bb0aa5b27c909bcff8c29453d3311d
[ "BSD-2-Clause" ]
48
2019-03-18T09:26:31.000Z
2019-05-27T08:12:03.000Z
onadata/apps/logger/management/commands/create_image_thumbnails.py
BuildAMovement/whistler-kobocat
7f61dd0761bb0aa5b27c909bcff8c29453d3311d
[ "BSD-2-Clause" ]
5
2017-02-22T12:25:19.000Z
2019-01-15T11:16:40.000Z
#!/usr/bin/env python from optparse import make_option from django.contrib.auth.models import User from django.core.management.base import BaseCommand, CommandError from django.core.files.storage import get_storage_class from django.conf import settings from onadata.apps.logger.models.attachment import Attachment fro...
46.061728
79
0.56044
df2a7bb93d330dfda915e0af01b5e654b0e6dac0
11,784
py
Python
lib/py/src/server/TServer.py
Jimexist/thrift
684ee0717472e1c084f4858f3faf650b6f17b451
[ "Apache-2.0" ]
8,514
2015-01-02T12:00:14.000Z
2022-03-31T10:34:56.000Z
lib/py/src/server/TServer.py
Jimexist/thrift
684ee0717472e1c084f4858f3faf650b6f17b451
[ "Apache-2.0" ]
1,623
2015-01-01T08:06:24.000Z
2022-03-30T19:48:52.000Z
lib/py/src/server/TServer.py
Jimexist/thrift
684ee0717472e1c084f4858f3faf650b6f17b451
[ "Apache-2.0" ]
3,849
2015-01-01T02:13:43.000Z
2022-03-31T06:23:34.000Z
# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
36.37037
92
0.588425
9ccc0fba52e34bd2b0a37ce9e1b9e5280862df48
9,934
py
Python
federal_spending/usaspending/management/commands/import_updates.py
rlugojr/federal_spending
e06f5a0018c1a0c581e8659472acb1574919dc50
[ "CC0-1.0" ]
20
2015-01-15T18:59:50.000Z
2022-01-31T03:37:53.000Z
federal_spending/usaspending/management/commands/import_updates.py
rlugojr/federal_spending
e06f5a0018c1a0c581e8659472acb1574919dc50
[ "CC0-1.0" ]
null
null
null
federal_spending/usaspending/management/commands/import_updates.py
rlugojr/federal_spending
e06f5a0018c1a0c581e8659472acb1574919dc50
[ "CC0-1.0" ]
7
2015-01-16T15:47:06.000Z
2020-01-09T07:14:45.000Z
from federal_spending.usaspending.models import Contract, Grant from federal_spending.usaspending.scripts.usaspending.contracts_loader import Loader from federal_spending.usaspending.scripts.usaspending.fpds import FIELDS as CONTRACT_FIELDS, CALCULATED_FIELDS as CONTRACT_CALCULATED_FIELDS from federal_spending.usaspend...
39.895582
140
0.567042
336ee2de3be52b01d6cad9e93f839072131d5334
235
py
Python
venv/Lib/site-packages/konlpy/user.py
movierecommend-chatbot/chat-bot
fc40c1937e8f597230578c1957305ad22f8280e4
[ "bzip2-1.0.6" ]
null
null
null
venv/Lib/site-packages/konlpy/user.py
movierecommend-chatbot/chat-bot
fc40c1937e8f597230578c1957305ad22f8280e4
[ "bzip2-1.0.6" ]
null
null
null
venv/Lib/site-packages/konlpy/user.py
movierecommend-chatbot/chat-bot
fc40c1937e8f597230578c1957305ad22f8280e4
[ "bzip2-1.0.6" ]
null
null
null
#! /usr/bin/python2.7 # -*- coding: utf-8 -*- import os from . import utils def addterm(term): dicfilename = os.path.join(utils.installpath, "data", "dictionary.tsv") with open(dicfilename, 'a') as f: f.write(term)
18.076923
75
0.629787
acc3e751b854448b31c3ed7fc7ffff9e3a36fa95
842
py
Python
setup.py
NotFaizen/popcat_wrapper
f2ea07a07cfa8084115645272cdbdee718012b90
[ "MIT" ]
null
null
null
setup.py
NotFaizen/popcat_wrapper
f2ea07a07cfa8084115645272cdbdee718012b90
[ "MIT" ]
null
null
null
setup.py
NotFaizen/popcat_wrapper
f2ea07a07cfa8084115645272cdbdee718012b90
[ "MIT" ]
2
2021-09-10T00:27:21.000Z
2022-02-02T19:46:48.000Z
import setuptools with open("README.md", "r", encoding="utf-8") as fh: long_description = fh.read() setuptools.setup( name="popcat_wrapper", version="1.6", author="NotFaizen", author_email="munavir370@gmail.com", url = "https://github.com/NotFaizen/popcat_wrapper", description="...
35.083333
99
0.649644
159f0d39b309f0056b77a3459098dbe0a5aac1c6
54,356
py
Python
estrategias/2021_Kasparov.py
rsouza/jogos_vorazes
807031a981b18e8fed0a73b5edb35fa4d486c269
[ "MIT" ]
null
null
null
estrategias/2021_Kasparov.py
rsouza/jogos_vorazes
807031a981b18e8fed0a73b5edb35fa4d486c269
[ "MIT" ]
null
null
null
estrategias/2021_Kasparov.py
rsouza/jogos_vorazes
807031a981b18e8fed0a73b5edb35fa4d486c269
[ "MIT" ]
19
2016-01-15T17:24:45.000Z
2021-01-28T18:12:50.000Z
import pickle import numpy as np import random from .jogadores import Jogador class MeuJogador(Jogador): '''Entao, meu plano inicial era usar uma rede neural, mas acabei desistindo da ideia, porque estava tendo problemas em importar o tensorflow em uma maquina que nao possui instalando usando apenas um pip install...
24.551039
1,108
0.745566
e3237089ce1b23c5dc87d26edef94adbe690edd7
2,010
py
Python
dl/models/gcn.py
salemilab/DeepDynaTree
a1cd0b8e6cbc415dd91425667e6ef722eb4138a5
[ "MIT" ]
null
null
null
dl/models/gcn.py
salemilab/DeepDynaTree
a1cd0b8e6cbc415dd91425667e6ef722eb4138a5
[ "MIT" ]
null
null
null
dl/models/gcn.py
salemilab/DeepDynaTree
a1cd0b8e6cbc415dd91425667e6ef722eb4138a5
[ "MIT" ]
null
null
null
#!/usr/bin/env # -*- coding: utf-8 -*- """ gcn.py: """ import torch import torch.nn as nn import torch.nn.functional as F from dgl.nn.pytorch.conv import GraphConv from dl import feat_dict class Net(nn.Module): def __init__(self, args): super(Net, self).__init__() in_feats = len(feat_dict[args.n...
28.309859
109
0.555224
2f4b313f3251ebe4344d789f7f2be826e3c4fea7
5,424
py
Python
docs/conf.py
lesamouraipourpre/Adafruit_CircuitPython_IL0398
b37e709588b999e8d1fe2ba05621fe274668979a
[ "Unlicense", "MIT-0", "MIT" ]
1
2021-07-13T14:58:31.000Z
2021-07-13T14:58:31.000Z
docs/conf.py
lesamouraipourpre/Adafruit_CircuitPython_IL0398
b37e709588b999e8d1fe2ba05621fe274668979a
[ "Unlicense", "MIT-0", "MIT" ]
2
2019-09-03T23:21:57.000Z
2021-09-27T16:45:13.000Z
docs/conf.py
lesamouraipourpre/Adafruit_CircuitPython_IL0398
b37e709588b999e8d1fe2ba05621fe274668979a
[ "Unlicense", "MIT-0", "MIT" ]
7
2019-08-21T01:40:25.000Z
2022-03-27T14:09:33.000Z
# -*- coding: utf-8 -*- # SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries # # SPDX-License-Identifier: MIT import os import sys sys.path.insert(0, os.path.abspath("..")) # -- General configuration ------------------------------------------------ # Add any Sphinx extension module names here, as strings...
29.639344
85
0.669432
c94621cc4618b48094f33d32a4ba2fcd11e19b83
205
py
Python
drf_haystack/__init__.py
advantch/drf-haystack
e625264508b505074349c374cd7f0ab0e63f89b6
[ "MIT" ]
201
2015-02-14T08:17:35.000Z
2019-07-10T04:19:04.000Z
drf_haystack/__init__.py
advantch/drf-haystack
e625264508b505074349c374cd7f0ab0e63f89b6
[ "MIT" ]
138
2015-02-17T09:28:33.000Z
2019-07-30T10:29:52.000Z
drf_haystack/__init__.py
advantch/drf-haystack
e625264508b505074349c374cd7f0ab0e63f89b6
[ "MIT" ]
60
2015-04-01T14:51:18.000Z
2019-05-12T15:31:52.000Z
# -*- coding: utf-8 -*- from __future__ import unicode_literals __title__ = "drf-haystack" __version__ = "1.8.11" __author__ = "Rolf Haavard Blindheim" __license__ = "MIT License" VERSION = __version__
18.636364
39
0.731707
51b4192e5b540a160f4c815cd7e08861f4ef00f9
3,142
py
Python
pythonforandroid/recipes/android/__init__.py
wo01/python-for-android
df0866d95c9c508299a6f948302454beb971e3ac
[ "MIT" ]
1
2018-12-21T03:40:18.000Z
2018-12-21T03:40:18.000Z
pythonforandroid/recipes/android/__init__.py
wo01/python-for-android
df0866d95c9c508299a6f948302454beb971e3ac
[ "MIT" ]
null
null
null
pythonforandroid/recipes/android/__init__.py
wo01/python-for-android
df0866d95c9c508299a6f948302454beb971e3ac
[ "MIT" ]
null
null
null
from __future__ import unicode_literals from pythonforandroid.recipe import CythonRecipe, IncludedFilesBehaviour from pythonforandroid.util import current_directory from pythonforandroid.patching import will_build from pythonforandroid import logger from os.path import join class AndroidRecipe(IncludedFilesBehaviour...
32.729167
77
0.559835
40c00e8eb4445f185ade400935bee7e2ac1f7559
1,475
py
Python
build/lib/adapter/estimator/xgboost_classification.py
mozjay0619/scikit-optimize-adapter
6550b6cba1667a0f0bf2c082a6ab64981cedb3e0
[ "BSD-3-Clause" ]
null
null
null
build/lib/adapter/estimator/xgboost_classification.py
mozjay0619/scikit-optimize-adapter
6550b6cba1667a0f0bf2c082a6ab64981cedb3e0
[ "BSD-3-Clause" ]
null
null
null
build/lib/adapter/estimator/xgboost_classification.py
mozjay0619/scikit-optimize-adapter
6550b6cba1667a0f0bf2c082a6ab64981cedb3e0
[ "BSD-3-Clause" ]
null
null
null
from .base_estimator import BaseEstimator import xgboost as xgb from sklearn.metrics import mean_absolute_error as mae # add more metrics class XgboostClassification(BaseEstimator): def __init__(self, **kwargs): self.n_jobs = kwargs["n_jobs"] def fit(self, X, y, params): lear...
33.522727
86
0.527458
2acaeb0de8b6ff094473ca6554657ef7bc07a0ea
267
py
Python
precompute_syllables.py
superMDguy/nanogenmo-2018
26f72dc922948a0f2bc464b33b70a3a37f376b61
[ "MIT" ]
1
2021-05-04T14:11:11.000Z
2021-05-04T14:11:11.000Z
precompute_syllables.py
superMDguy/nanogenmo-2018
26f72dc922948a0f2bc464b33b70a3a37f376b61
[ "MIT" ]
1
2018-12-20T20:59:48.000Z
2019-01-19T17:11:29.000Z
precompute_syllables.py
superMDguy/nanogenmo-2018
26f72dc922948a0f2bc464b33b70a3a37f376b61
[ "MIT" ]
null
null
null
import cmudict from tqdm import tqdm import re with open('cmu_pronouncing.txt', 'w') as f: only_stress = re.compile(r'[^012]') for word, phonemes in tqdm(cmudict.dict().items()): f.write(f"{word} {re.sub(only_stress, '', ''.join(phonemes[0]))}\n")
26.7
76
0.640449
64cac1588112331a9f5b080991b8bc61eee56aec
2,423
py
Python
astrodenoisepygui-package-dist.py
kalgecin/astro-csbdeep
a216642750e0357b9b59002eaff1d69c54eb2316
[ "BSD-3-Clause" ]
1
2022-01-24T13:51:12.000Z
2022-01-24T13:51:12.000Z
astrodenoisepygui-package-dist.py
kalgecin/astro-csbdeep
a216642750e0357b9b59002eaff1d69c54eb2316
[ "BSD-3-Clause" ]
null
null
null
astrodenoisepygui-package-dist.py
kalgecin/astro-csbdeep
a216642750e0357b9b59002eaff1d69c54eb2316
[ "BSD-3-Clause" ]
null
null
null
import sys from cx_Freeze import setup, Executable build_exe_options = { "build_exe": "astrodenoisepy\\dist-gui", "packages": ["kivy"], "include_files": [ "LICENSE.txt", ["astrodenoisepy\\dist-models\\main", "models\\default"], ["astrodenoisepy\\data", "astrodenoisepy\\data"], ...
39.721311
65
0.588114
0859380d064e5fd3ce40f77b016f9678d66b0d7a
9,513
py
Python
test/functional/test_framework/blocktools.py
rednaxus/bitcoin
a47ac9e98bb3c1ead00843cf8068ac298543d536
[ "MIT" ]
1
2020-10-27T09:27:31.000Z
2020-10-27T09:27:31.000Z
test/functional/test_framework/blocktools.py
blackzilla2126/bitcoin
88271184e82222f556d67511cc64230b0532f40d
[ "MIT" ]
18
2020-10-31T01:04:18.000Z
2020-11-03T19:25:27.000Z
test/functional/test_framework/blocktools.py
blackzilla2126/bitcoin
88271184e82222f556d67511cc64230b0532f40d
[ "MIT" ]
1
2021-09-18T04:39:58.000Z
2021-09-18T04:39:58.000Z
#!/usr/bin/env python3 # Copyright (c) 2015-2019 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Utilities for manipulating blocks and transactions.""" from binascii import a2b_hex import io import s...
37.305882
108
0.706612
de530323577d058947b6914880479ebcbffb6ac7
10,902
py
Python
contextPred/chem/finetune.py
thomasly/slgnn
caa1e7814498da41ad025b4e62c569fe511848ff
[ "MIT" ]
2
2020-08-31T00:55:31.000Z
2020-09-01T19:59:30.000Z
contextPred/chem/finetune.py
thomasly/slgnn
caa1e7814498da41ad025b4e62c569fe511848ff
[ "MIT" ]
null
null
null
contextPred/chem/finetune.py
thomasly/slgnn
caa1e7814498da41ad025b4e62c569fe511848ff
[ "MIT" ]
null
null
null
import argparse from .loader import MoleculeDataset from torch_geometric.data import DataLoader import torch import torch.nn as nn import torch.nn.functional as F import torch.optim as optim from tqdm import tqdm import numpy as np from .model import GNN, GNN_graphpred from sklearn.metrics import roc_auc_score fro...
29.786885
95
0.593469
bb3abd3741997f065425533cb5360b15fac3df61
2,874
py
Python
CAIL2020/sfksz/tools/eval_tool.py
ShenDezhou/CAIL
c4cfa98ab4ecedbce34a7a5a186830486047540c
[ "Apache-2.0" ]
71
2020-07-16T01:49:27.000Z
2022-03-27T16:55:00.000Z
CAIL2020/sfksz/tools/eval_tool.py
ShenDezhou/CAIL
c4cfa98ab4ecedbce34a7a5a186830486047540c
[ "Apache-2.0" ]
11
2020-09-18T14:26:25.000Z
2022-02-09T23:49:33.000Z
CAIL2020/sfksz/tools/eval_tool.py
ShenDezhou/CAIL
c4cfa98ab4ecedbce34a7a5a186830486047540c
[ "Apache-2.0" ]
16
2020-07-15T07:24:30.000Z
2022-03-19T05:41:11.000Z
import logging import os import torch from torch.autograd import Variable from torch.optim import lr_scheduler from tensorboardX import SummaryWriter from timeit import default_timer as timer logger = logging.getLogger(__name__) def gen_time_str(t): t = int(t) minute = t // 60 second = t % 60 return ...
29.030303
105
0.549408
e11d1a30dc9a72975b031e3eae91c45ca3bcf30d
687
py
Python
files/question histoire pygame/thorpy_reaction_(show_place_mouse_onclick).py
HenraL/NSI_1ereG6_Programme_Python
9f46b848fa2331daca57e5e2e11cba41da45a67f
[ "Unlicense" ]
1
2021-06-15T13:44:47.000Z
2021-06-15T13:44:47.000Z
files/question histoire pygame/thorpy_reaction_(show_place_mouse_onclick).py
HenraL/NSI_1ereG6_Programme_Python
9f46b848fa2331daca57e5e2e11cba41da45a67f
[ "Unlicense" ]
null
null
null
files/question histoire pygame/thorpy_reaction_(show_place_mouse_onclick).py
HenraL/NSI_1ereG6_Programme_Python
9f46b848fa2331daca57e5e2e11cba41da45a67f
[ "Unlicense" ]
null
null
null
import thorpy, pygame def my_func_reaction(event):#Reactions functions must take an event as first arg print("My reaction displays the pos of event:", event.pos) #We declare a Reaction. Note that we do not filter the event here. my_reaction = thorpy.Reaction(reacts_to=pygame.MOUSEBUTTONDOWN, ...
36.157895
80
0.754003
bc1ef50c3683fccefcc1680447d2bc2b43077777
27,227
py
Python
ax/plot/helper.py
stevemandala/Ax
8e289a154e3a2ed237bf27ddb90e09963c0d6a97
[ "MIT" ]
null
null
null
ax/plot/helper.py
stevemandala/Ax
8e289a154e3a2ed237bf27ddb90e09963c0d6a97
[ "MIT" ]
null
null
null
ax/plot/helper.py
stevemandala/Ax
8e289a154e3a2ed237bf27ddb90e09963c0d6a97
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import math from collections import Counter from typing import Any, Dict, List, Optional, Set, Tuple, Union import num...
32.413095
88
0.592684
681c2dbcba09fc1f35e2ca0aae6848e63780e95e
678
py
Python
temboo/core/Library/Yahoo/Weather/__init__.py
jordanemedlock/psychtruths
52e09033ade9608bd5143129f8a1bfac22d634dd
[ "Apache-2.0" ]
7
2016-03-07T02:07:21.000Z
2022-01-21T02:22:41.000Z
temboo/core/Library/Yahoo/Weather/__init__.py
jordanemedlock/psychtruths
52e09033ade9608bd5143129f8a1bfac22d634dd
[ "Apache-2.0" ]
null
null
null
temboo/core/Library/Yahoo/Weather/__init__.py
jordanemedlock/psychtruths
52e09033ade9608bd5143129f8a1bfac22d634dd
[ "Apache-2.0" ]
8
2016-06-14T06:01:11.000Z
2020-04-22T09:21:44.000Z
from temboo.Library.Yahoo.Weather.GetTemperature import GetTemperature, GetTemperatureInputSet, GetTemperatureResultSet, GetTemperatureChoreographyExecution from temboo.Library.Yahoo.Weather.GetWeather import GetWeather, GetWeatherInputSet, GetWeatherResultSet, GetWeatherChoreographyExecution from temboo.Library.Yahoo....
135.6
201
0.917404
66d5412d318d71e6cdc64b643cf0ad07e785f465
1,671
py
Python
setup.py
arnaud-morvan/papyrus
04ce5730e0af229cbded40fc96dfee132300f4f7
[ "BSD-2-Clause" ]
null
null
null
setup.py
arnaud-morvan/papyrus
04ce5730e0af229cbded40fc96dfee132300f4f7
[ "BSD-2-Clause" ]
null
null
null
setup.py
arnaud-morvan/papyrus
04ce5730e0af229cbded40fc96dfee132300f4f7
[ "BSD-2-Clause" ]
null
null
null
from setuptools import setup, find_packages import os version = '2.3' here = os.path.abspath(os.path.dirname(__file__)) README = open(os.path.join(here, 'README.rst')).read() TODO = open(os.path.join(here, 'TODO.rst')).read() CHANGES = open(os.path.join(here, 'CHANGES.rst')).read() install_requires = [ 'pyramid>...
32.134615
72
0.59605
24ce098b8e56d95ed789f5a04072350ecc609c5c
65,757
py
Python
reviewboard/testing/testcase.py
LloydFinch/reviewboard
563c1e8d4dfd860f372281dc0f380a0809f6ae15
[ "MIT" ]
2
2020-06-19T14:57:49.000Z
2020-06-19T15:17:40.000Z
reviewboard/testing/testcase.py
LloydFinch/reviewboard
563c1e8d4dfd860f372281dc0f380a0809f6ae15
[ "MIT" ]
null
null
null
reviewboard/testing/testcase.py
LloydFinch/reviewboard
563c1e8d4dfd860f372281dc0f380a0809f6ae15
[ "MIT" ]
null
null
null
from __future__ import unicode_literals import os import re import warnings from contextlib import contextmanager from datetime import timedelta from django.conf import settings from django.contrib.auth.models import AnonymousUser, Permission, User from django.core.cache import cache from django.core.files import Fil...
36.390149
85
0.567118
87e25da31bde304141f5902a30ed0de46184dbf2
273
py
Python
day5/d5p4.py
Akankshasharmaa/100DaysOfCode
395bd8bd063495af7d04ec7b2f819923f502059f
[ "MIT" ]
2
2021-12-22T07:43:14.000Z
2021-12-24T12:07:33.000Z
day5/d5p4.py
Akankshasharmaa/100DaysOfCode
395bd8bd063495af7d04ec7b2f819923f502059f
[ "MIT" ]
null
null
null
day5/d5p4.py
Akankshasharmaa/100DaysOfCode
395bd8bd063495af7d04ec7b2f819923f502059f
[ "MIT" ]
1
2021-12-22T07:43:26.000Z
2021-12-22T07:43:26.000Z
def make_abba(a, b): newstr = a + b + b + a if len(a) >= 0 and len(b) >= 0: return newstr else: return False result = make_abba('Hi', 'Bye') print(result) result = make_abba('Yo', 'Alice') print(result) result = make_abba('x', '') print(result)
21
35
0.575092
08bcb9abe4d7956bfe9c1ebe44296bce9e3a337f
14,774
py
Python
A1 - Search and Games/fishing_game_core/app.py
NickSmyr/ai-player-agents
f8972d02c53a2ba566b541b1270a0637e3d3e5c7
[ "MIT" ]
null
null
null
A1 - Search and Games/fishing_game_core/app.py
NickSmyr/ai-player-agents
f8972d02c53a2ba566b541b1270a0637e3d3e5c7
[ "MIT" ]
null
null
null
A1 - Search and Games/fishing_game_core/app.py
NickSmyr/ai-player-agents
f8972d02c53a2ba566b541b1270a0637e3d3e5c7
[ "MIT" ]
null
null
null
import json import sys from datetime import datetime from io import UnsupportedOperation from os.path import join from pathlib import Path import numpy as np from kivy.app import App from kivy.clock import Clock from kivy.core.window import Window from kivy.lang import Builder from fishing_game_core.communicator impo...
34.438228
119
0.607554
2d8c76401c7b11b1b733325ce1fb21cba63a5b30
1,036
py
Python
Alt/saliencymapper/api.py
MalcolmGomes/SoftwareEng2
2cc9417a30cd1350980bc6e272d1024e866397a6
[ "MIT" ]
null
null
null
Alt/saliencymapper/api.py
MalcolmGomes/SoftwareEng2
2cc9417a30cd1350980bc6e272d1024e866397a6
[ "MIT" ]
null
null
null
Alt/saliencymapper/api.py
MalcolmGomes/SoftwareEng2
2cc9417a30cd1350980bc6e272d1024e866397a6
[ "MIT" ]
null
null
null
from flask import Flask, request, send_file from flask_restful import Resource, Api from saliency_mapper import * import os import requests import torch import time import sys from torchvision import models from torchvision import transforms app = Flask(__name__) api = Api(app) class SaliencyMapAPI(Resource): def ...
25.268293
61
0.732625
029c948456cb89b831f5a1ffdc142e7ca4638310
10,364
py
Python
verde/vector.py
djhoese/verde
ad14acf94717ee5c6672559f40576f65989753a5
[ "BSD-3-Clause" ]
null
null
null
verde/vector.py
djhoese/verde
ad14acf94717ee5c6672559f40576f65989753a5
[ "BSD-3-Clause" ]
null
null
null
verde/vector.py
djhoese/verde
ad14acf94717ee5c6672559f40576f65989753a5
[ "BSD-3-Clause" ]
null
null
null
""" Vector gridding using elasticity Green's functions from Sandwell and Wessel (2016). """ import numpy as np from sklearn.utils.validation import check_is_fitted from .base import check_fit_input from .spline import Spline from .coordinates import get_region class Vector2D(Spline): r""" Elastically coupled...
40.015444
85
0.65988
2ae10782e28b42c62b64daf4ca0ae47ffbf83626
1,335
py
Python
app/core/tests/test_admin.py
AliSayyah/recipe-app-api
42c689ba2fd709dad35508d5f09452daa33f81ea
[ "MIT" ]
null
null
null
app/core/tests/test_admin.py
AliSayyah/recipe-app-api
42c689ba2fd709dad35508d5f09452daa33f81ea
[ "MIT" ]
null
null
null
app/core/tests/test_admin.py
AliSayyah/recipe-app-api
42c689ba2fd709dad35508d5f09452daa33f81ea
[ "MIT" ]
null
null
null
from django.test import TestCase from django.contrib.auth import get_user_model from django.urls import reverse from django.test import Client class AdminSiteTests(TestCase): def setUp(self): self.client = Client() self.admin_user = get_user_model().objects.create_superuser( email='al...
31.785714
68
0.643446
eebe676f07082cced8c7fbd96dd3cb896c4776b4
5,125
py
Python
src/pykeen/models/unimodal/pair_re.py
rpatil524/pykeen
b76239ab68f15bbf52af744c2821c73c2115b5aa
[ "MIT" ]
null
null
null
src/pykeen/models/unimodal/pair_re.py
rpatil524/pykeen
b76239ab68f15bbf52af744c2821c73c2115b5aa
[ "MIT" ]
null
null
null
src/pykeen/models/unimodal/pair_re.py
rpatil524/pykeen
b76239ab68f15bbf52af744c2821c73c2115b5aa
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Implementation of PairRE.""" from typing import Any, ClassVar, Mapping, Optional from torch.nn import functional from torch.nn.init import uniform_ from ..nbase import ERModel from ...constants import DEFAULT_EMBEDDING_HPO_EMBEDDING_DIM_RANGE from ...nn.emb import EmbeddingSpecification f...
40.674603
177
0.677268
a8c79c79f3f09c0650c3ca9075b2f343a1ca6b1b
1,640
py
Python
constant/base.py
MacHu-GWU/constant-project
de44b1973d0457b856d47d6e17b3997b3611179e
[ "MIT" ]
null
null
null
constant/base.py
MacHu-GWU/constant-project
de44b1973d0457b856d47d6e17b3997b3611179e
[ "MIT" ]
null
null
null
constant/base.py
MacHu-GWU/constant-project
de44b1973d0457b856d47d6e17b3997b3611179e
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Similar to ``collections.namedtuple``, ``nameddict`` is a data container class. **中文文档** 和 ``collections.namedtuple`` 类似, ``nameddict`` 是一种数据容器类。提供了方便的方法 对属性, 值进行for循环, 以及和list, dict之间的IO交互。 """ try: from .pkg import nameddict, name_convention except: from c...
26.031746
85
0.590854
41d5809adb7d350a2852159d1a56f85a78d56f9c
6,362
py
Python
code/zoltar-scripts/upload_covid19_forecasts_to_zoltar.py
Yannael/covid19-forecast-hub
a16c9a147df5536ea75f2870b1f8a0227ef6d3ee
[ "MIT" ]
null
null
null
code/zoltar-scripts/upload_covid19_forecasts_to_zoltar.py
Yannael/covid19-forecast-hub
a16c9a147df5536ea75f2870b1f8a0227ef6d3ee
[ "MIT" ]
null
null
null
code/zoltar-scripts/upload_covid19_forecasts_to_zoltar.py
Yannael/covid19-forecast-hub
a16c9a147df5536ea75f2870b1f8a0227ef6d3ee
[ "MIT" ]
null
null
null
from zoltpy.quantile_io import json_io_dict_from_quantile_csv_file from zoltpy import util from zoltpy.connection import ZoltarConnection from zoltpy.covid19 import VALID_TARGET_NAMES, covid19_row_validator, validate_quantile_csv_file import os import sys import yaml import hashlib import pickle # meta info project_na...
39.515528
172
0.649167
2afcc43ccfa943fff4102358ceb907ab6f08151c
1,031
py
Python
www/SYS/FILE.py
ranyxr/infoVis
307c2ffc4c7d6cf87ed000310a1f2b6233bd7a3b
[ "MIT" ]
2
2020-05-27T11:12:41.000Z
2020-12-17T19:33:41.000Z
www/SYS/FILE.py
ranyxr/infoVis
307c2ffc4c7d6cf87ed000310a1f2b6233bd7a3b
[ "MIT" ]
null
null
null
www/SYS/FILE.py
ranyxr/infoVis
307c2ffc4c7d6cf87ed000310a1f2b6233bd7a3b
[ "MIT" ]
3
2020-03-18T19:20:24.000Z
2020-12-17T17:37:24.000Z
from SYS import DIR import os "picture-info.csv" _meta_data_fnm = "metadatas.csv" _meta_data_uri = os.path.join(DIR.raw_data, _meta_data_fnm) meta_data_uri = _meta_data_uri _meta_level_meta_fnm = "picture-description.csv" _meta_level_meta_uri = os.path.join(DIR.raw_data, _meta_level_meta_fnm) pic_desc_uri = _meta_lev...
30.323529
71
0.845781
1ab40d03f981526d9e031f31a0832b6f0bb50bd7
81,522
py
Python
sectionproperties/pre/nastran_sections.py
audunarn/section-properties
6dd68d0cb6b31adcaffeb5ea9f78f985a8955f95
[ "MIT" ]
2
2021-01-18T08:04:55.000Z
2021-03-06T01:23:39.000Z
sectionproperties/pre/nastran_sections.py
audunarn/section-properties
6dd68d0cb6b31adcaffeb5ea9f78f985a8955f95
[ "MIT" ]
null
null
null
sectionproperties/pre/nastran_sections.py
audunarn/section-properties
6dd68d0cb6b31adcaffeb5ea9f78f985a8955f95
[ "MIT" ]
null
null
null
from sectionproperties.pre.sections import ( Geometry, RectangularSection, CustomSection, MergedSection ) from sectionproperties.pre.pre import create_mesh import numpy as np class BARSection(Geometry): """Constructs a BAR section with the center at the origin *(0, 0)*, with two parameters defining dimens...
36.475168
99
0.590466
477cd6d865b307291a4a798405b8d7b2ff819de1
17,248
py
Python
tests/providers/google/cloud/hooks/test_dataproc.py
dorranh/airflow
1a9a2cadcf8606cfcb729d1323dd33dfacc64633
[ "Apache-2.0" ]
null
null
null
tests/providers/google/cloud/hooks/test_dataproc.py
dorranh/airflow
1a9a2cadcf8606cfcb729d1323dd33dfacc64633
[ "Apache-2.0" ]
1
2019-05-14T14:32:40.000Z
2019-05-14T14:32:40.000Z
tests/providers/google/cloud/hooks/test_dataproc.py
dorranh/airflow
1a9a2cadcf8606cfcb729d1323dd33dfacc64633
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the #...
37.577342
94
0.659439
661e7836a9d7a82b1ef6be7a3b4f25e82394b3ce
1,643
py
Python
src/python/zquantum/core/bitstring_distribution/distance_measures/clipped_negative_log_likelihood.py
alexjuda2/z-quantum-core
c258100dbd091f0b22495b77b36399426ae9abac
[ "Apache-2.0" ]
24
2020-04-15T17:36:59.000Z
2022-01-25T05:02:14.000Z
src/python/zquantum/core/bitstring_distribution/distance_measures/clipped_negative_log_likelihood.py
alexjuda2/z-quantum-core
c258100dbd091f0b22495b77b36399426ae9abac
[ "Apache-2.0" ]
177
2020-04-23T15:19:59.000Z
2022-03-30T18:06:17.000Z
src/python/zquantum/core/bitstring_distribution/distance_measures/clipped_negative_log_likelihood.py
alexjuda2/z-quantum-core
c258100dbd091f0b22495b77b36399426ae9abac
[ "Apache-2.0" ]
19
2020-06-24T10:56:02.000Z
2021-09-30T13:02:21.000Z
import math from typing import TYPE_CHECKING, Dict if TYPE_CHECKING: from zquantum.core.bitstring_distribution import BitstringDistribution def compute_clipped_negative_log_likelihood( target_distribution: "BitstringDistribution", measured_distribution: "BitstringDistribution", distance_measure_param...
36.511111
88
0.736458
e219461fe40ed8a26ec6ec4adcd87016828bf126
1,858
py
Python
easy/python3/c0168_690_employee-importance/00_leetcode_0168.py
drunkwater/leetcode
8cc4a07763e71efbaedb523015f0c1eff2927f60
[ "Ruby" ]
null
null
null
easy/python3/c0168_690_employee-importance/00_leetcode_0168.py
drunkwater/leetcode
8cc4a07763e71efbaedb523015f0c1eff2927f60
[ "Ruby" ]
null
null
null
easy/python3/c0168_690_employee-importance/00_leetcode_0168.py
drunkwater/leetcode
8cc4a07763e71efbaedb523015f0c1eff2927f60
[ "Ruby" ]
3
2018-02-09T02:46:48.000Z
2021-02-20T08:32:03.000Z
# DRUNKWATER TEMPLATE(add description and prototypes) # Question Title and Description on leetcode.com # Function Declaration and Function Prototypes on leetcode.com #690. Employee Importance #You are given a data structure of employee information, which includes the employee's unique id, his importance value and his d...
48.894737
371
0.700215
7a23de5c5144bde724c8cecbda2be9d2ac255baf
8,652
py
Python
pyro/distributions/transforms/planar.py
chiragnagpal/pyro
9b67c84798f39310345a6cf80f602195c0571166
[ "Apache-2.0" ]
null
null
null
pyro/distributions/transforms/planar.py
chiragnagpal/pyro
9b67c84798f39310345a6cf80f602195c0571166
[ "Apache-2.0" ]
null
null
null
pyro/distributions/transforms/planar.py
chiragnagpal/pyro
9b67c84798f39310345a6cf80f602195c0571166
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2017-2019 Uber Technologies, Inc. # SPDX-License-Identifier: Apache-2.0 import math from functools import partial import torch import torch.nn as nn import torch.nn.functional as F from torch.distributions import Transform, constraints from pyro.distributions.conditional import ConditionalTransformMo...
35.170732
106
0.67337
ef6ded6a2a27334d79faf61095e7a422571f9097
668
py
Python
src/ndc/create_hist.py
TEI-EAJ/auto_aozora_tei
5535abef680a1e186f8a7dc6efc30a1dcf4efeec
[ "CC0-1.0" ]
3
2019-02-12T13:28:22.000Z
2021-07-25T20:58:07.000Z
src/ndc/create_hist.py
TEI-EAJ/auto_aozora_tei
5535abef680a1e186f8a7dc6efc30a1dcf4efeec
[ "CC0-1.0" ]
null
null
null
src/ndc/create_hist.py
TEI-EAJ/auto_aozora_tei
5535abef680a1e186f8a7dc6efc30a1dcf4efeec
[ "CC0-1.0" ]
1
2019-02-12T22:04:00.000Z
2019-02-12T22:04:00.000Z
import json with open('data/ndc.json', 'r') as f: data = json.load(f) with open('data/subjects.json', 'r') as f: subjects = json.load(f) arr = data["children"] for lev1 in arr: for lev2 in lev1["children"]: for lev3 in lev2["children"]: for lev4 in lev3["children"]: ...
24.740741
98
0.523952
febc05664ea50c97d67b8f34fd7a95fd90ce24a7
6,471
py
Python
torchseq/models/samplers/parallel_nucleus.py
tomhosking/torchseq
1b08c16822a553ecb77b96289fb21eb0a13d9c6b
[ "Apache-2.0" ]
17
2021-02-25T14:24:06.000Z
2021-12-12T07:12:26.000Z
torchseq/models/samplers/parallel_nucleus.py
tomhosking/torchseq
1b08c16822a553ecb77b96289fb21eb0a13d9c6b
[ "Apache-2.0" ]
null
null
null
torchseq/models/samplers/parallel_nucleus.py
tomhosking/torchseq
1b08c16822a553ecb77b96289fb21eb0a13d9c6b
[ "Apache-2.0" ]
null
null
null
import torch import torch.nn as nn from torchseq.utils.tokenizer import Tokenizer from torchseq.utils.functions import onehot # FROM: https://gist.github.com/thomwolf/1a5a29f6962089e871b94cbd09daf317 def top_k_top_p_filtering(logits, top_k=0, top_p=0.0, filter_value=-float("Inf")): """Filter a distribution of ...
44.321918
119
0.643332
20bebc733d7674e861ad7c07684a3007af031c69
3,160
py
Python
activelearning/settings.py
evanlouie/activelearning
7ee6e9d2d795f85a441ad70e70ac0d8de9c25e31
[ "MIT" ]
null
null
null
activelearning/settings.py
evanlouie/activelearning
7ee6e9d2d795f85a441ad70e70ac0d8de9c25e31
[ "MIT" ]
null
null
null
activelearning/settings.py
evanlouie/activelearning
7ee6e9d2d795f85a441ad70e70ac0d8de9c25e31
[ "MIT" ]
1
2019-01-03T18:03:18.000Z
2019-01-03T18:03:18.000Z
""" Django settings for activelearning project. Generated by 'django-admin startproject' using Django 2.1.2. For more information on this file, see https://docs.djangoproject.com/en/2.1/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.1/ref/settings/ """ impor...
25.901639
90
0.705696
2a9ee1efeb8c721c00cc33cda209834c6a1353bd
783
py
Python
bacchus/celery.py
hudecof/bacchus
1d7bafa2331535b27b336b42f07f8fe328f6d131
[ "Apache-2.0" ]
1
2020-04-15T14:31:48.000Z
2020-04-15T14:31:48.000Z
bacchus/celery.py
hudecof/bacchus
1d7bafa2331535b27b336b42f07f8fe328f6d131
[ "Apache-2.0" ]
4
2019-04-13T08:35:51.000Z
2019-04-13T15:08:47.000Z
bacchus/celery.py
hudecof/bacchus
1d7bafa2331535b27b336b42f07f8fe328f6d131
[ "Apache-2.0" ]
1
2019-03-25T07:48:29.000Z
2019-03-25T07:48:29.000Z
from __future__ import absolute_import, unicode_literals import os from celery import Celery # set the default Django settings module for the 'celery' program. os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'bacchus.settings') app = Celery('bacchus') # Using a string here means the worker don't have to serialize # ...
29
67
0.773946
998662d5fc197c662c69592197835dcd1578e87b
2,468
py
Python
js/analysis.py
Omar-Ceesay/2048-AI
520a319b2f3cdf56e0f298e49e08cb7f0864b52c
[ "MIT" ]
null
null
null
js/analysis.py
Omar-Ceesay/2048-AI
520a319b2f3cdf56e0f298e49e08cb7f0864b52c
[ "MIT" ]
null
null
null
js/analysis.py
Omar-Ceesay/2048-AI
520a319b2f3cdf56e0f298e49e08cb7f0864b52c
[ "MIT" ]
null
null
null
import matplotlib import matplotlib.pyplot as plt import numpy as np from os import listdir from os.path import isfile, join import json file_path = "./data" all_data_files = [f for f in listdir(file_path) if isfile(join(file_path, f))] all_data = [] for filename in all_data_files: f = open("./data/"+filename, "...
22.642202
113
0.561588
b7b81266e65b2023132e0196ca92bab0cd73f2d4
617
py
Python
workload-traces/mysql/tpcc/extract_lock_names.py
spcl/vldb19-distributed-locking
efa9ffa4065cf17ccdf0b59672c173eb2d23934c
[ "MIT" ]
8
2019-11-04T19:05:40.000Z
2022-01-19T06:05:21.000Z
workload-traces/mysql/tpcc/extract_lock_names.py
spcl/vldb19-distributed-locking
efa9ffa4065cf17ccdf0b59672c173eb2d23934c
[ "MIT" ]
null
null
null
workload-traces/mysql/tpcc/extract_lock_names.py
spcl/vldb19-distributed-locking
efa9ffa4065cf17ccdf0b59672c173eb2d23934c
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import fileinput import json from collections import OrderedDict locks = set() for line in fileinput.input(): data = json.loads(line) # Get only lock events if data.get('action') not in ['lock', 'unlock']: continue # Insert ware house where missing (home ware house by...
24.68
88
0.672609
a9a988c3221786da4c41b780858f77a389d50793
550
py
Python
thumbor/detectors/glasses_detector/__init__.py
jairhenrique/thumbor
fa29ba0efab2dd420c6840616a079756fd75293a
[ "MIT" ]
6,837
2015-01-01T14:33:12.000Z
2022-03-31T22:21:05.000Z
thumbor/detectors/glasses_detector/__init__.py
jairhenrique/thumbor
fa29ba0efab2dd420c6840616a079756fd75293a
[ "MIT" ]
1,055
2015-01-03T22:22:05.000Z
2022-03-31T21:56:17.000Z
thumbor/detectors/glasses_detector/__init__.py
jairhenrique/thumbor
fa29ba0efab2dd420c6840616a079756fd75293a
[ "MIT" ]
744
2015-01-05T03:49:31.000Z
2022-03-30T02:35:16.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- # thumbor imaging service # https://github.com/thumbor/thumbor/wiki # Licensed under the MIT license: # http://www.opensource.org/licenses/mit-license # Copyright (c) 2011 globo.com thumbor@googlegroups.com from thumbor.detectors.local_detector import CascadeLoaderDetector ...
30.555556
86
0.761818
4aa954cf6c840968e8d972c9934f8f658bedecb6
4,394
py
Python
src/addit/ncf.py
HajimeKawahara/addit
7b19006bd338d7887f1a600b66fc74fc72c21c70
[ "MIT" ]
3
2021-06-28T15:40:50.000Z
2021-07-13T17:53:06.000Z
src/addit/ncf.py
HajimeKawahara/addit
7b19006bd338d7887f1a600b66fc74fc72c21c70
[ "MIT" ]
4
2021-07-13T22:02:56.000Z
2021-08-13T00:47:02.000Z
src/addit/ncf.py
HajimeKawahara/addit
7b19006bd338d7887f1a600b66fc74fc72c21c70
[ "MIT" ]
1
2021-08-10T09:43:36.000Z
2021-08-10T09:43:36.000Z
"""Neighbouring Contribution Function (new version updated Aug 10th 2021) * Assume a given x-grid xv[k], and a value x. For a 1D case, the Neighbouring Contribution Function gives ncf(k,x) = (x-xv[s])/dv for k=s, (xv[s]-x)/dv for k=s+1, and 0 elsewhere, where s is the nearest index of xv[k] to x but xv[k]<x. * ...
32.548148
239
0.565316
2aebd98258592fe26c2e32d74e3485c8f047ecb3
6,920
py
Python
plugins/action/node_deployment.py
steinzi/ansible-ise
0add9c8858ed8e0e5e7219fbaf0c936b6d7cc6c0
[ "MIT" ]
null
null
null
plugins/action/node_deployment.py
steinzi/ansible-ise
0add9c8858ed8e0e5e7219fbaf0c936b6d7cc6c0
[ "MIT" ]
null
null
null
plugins/action/node_deployment.py
steinzi/ansible-ise
0add9c8858ed8e0e5e7219fbaf0c936b6d7cc6c0
[ "MIT" ]
null
null
null
from __future__ import (absolute_import, division, print_function) __metaclass__ = type from ansible.plugins.action import ActionBase try: from ansible_collections.ansible.utils.plugins.module_utils.common.argspec_validate import ( AnsibleArgSpecValidator, ) except ImportError: ANSIBLE_UTILS_IS_INST...
34.427861
128
0.606936
6d476c15a429eadd7dbd717a575d515102beb574
39,738
py
Python
robot_sim/robots/ur3_dual/ur3_dual.py
liang324/wrs
46eadec355c61a9c7bac1fa0f3cf419b2aac19aa
[ "MIT" ]
null
null
null
robot_sim/robots/ur3_dual/ur3_dual.py
liang324/wrs
46eadec355c61a9c7bac1fa0f3cf419b2aac19aa
[ "MIT" ]
null
null
null
robot_sim/robots/ur3_dual/ur3_dual.py
liang324/wrs
46eadec355c61a9c7bac1fa0f3cf419b2aac19aa
[ "MIT" ]
null
null
null
import os import math import numpy as np import basis.robot_math as rm import modeling.model_collection as mc import modeling.collision_model as cm import robot_sim._kinematics.jlchain as jl import robot_sim.manipulators.ur3.ur3 as ur import robot_sim.end_effectors.grippers.robotiq85.robotiq85 as rtq from panda3d.core ...
52.424802
121
0.555614
5a2a509d3147a39a338049132f2f0356fb20e1f4
4,513
py
Python
lib/roi_data_layer/roidb.py
aaamourao/faster-rcnn.pytorch
e5f476360fbdc8af9ae6a4981b3eaac3b744cee9
[ "MIT" ]
null
null
null
lib/roi_data_layer/roidb.py
aaamourao/faster-rcnn.pytorch
e5f476360fbdc8af9ae6a4981b3eaac3b744cee9
[ "MIT" ]
null
null
null
lib/roi_data_layer/roidb.py
aaamourao/faster-rcnn.pytorch
e5f476360fbdc8af9ae6a4981b3eaac3b744cee9
[ "MIT" ]
null
null
null
"""Transform a roidb into a trainable roidb by adding a bunch of metadata.""" from __future__ import absolute_import from __future__ import division from __future__ import print_function import os import pickle import datasets import numpy as np from model.utils.config import cfg from datasets.factory import get_imdb...
30.910959
77
0.662087
bce455de8873952dd4d49cf03dcb314bc8611f78
1,751
py
Python
test/feature/test_scale_space_detector.py
tdchaitanya/kornia
6dd16563f66f979c7a95846ef86678894b7d54fd
[ "Apache-2.0" ]
1
2019-11-21T13:18:56.000Z
2019-11-21T13:18:56.000Z
test/feature/test_scale_space_detector.py
tdchaitanya/kornia
6dd16563f66f979c7a95846ef86678894b7d54fd
[ "Apache-2.0" ]
null
null
null
test/feature/test_scale_space_detector.py
tdchaitanya/kornia
6dd16563f66f979c7a95846ef86678894b7d54fd
[ "Apache-2.0" ]
2
2020-01-08T17:11:34.000Z
2020-10-14T00:44:18.000Z
import pytest import kornia.testing as utils # test utils import kornia from torch.testing import assert_allclose from torch.autograd import gradcheck from kornia.feature.scale_space_detector import * class TestScaleSpaceDetector: def test_shape(self): inp = torch.rand(1, 1, 32, 32) n_feats = 10...
35.02
86
0.6008
8b861a4d6360161dcb30202dddad4ded13612036
4,504
py
Python
slot/a/__init__.py
LorentzB/dl
c2af8498ba868abcd2ddb08eb9e4b4bb79594ba2
[ "Apache-2.0" ]
45
2018-12-30T14:19:37.000Z
2021-01-28T08:16:41.000Z
slot/a/__init__.py
LorentzB/dl
c2af8498ba868abcd2ddb08eb9e4b4bb79594ba2
[ "Apache-2.0" ]
23
2019-01-07T22:32:00.000Z
2019-10-04T10:23:02.000Z
slot/a/__init__.py
LorentzB/dl
c2af8498ba868abcd2ddb08eb9e4b4bb79594ba2
[ "Apache-2.0" ]
36
2019-01-11T21:38:02.000Z
2021-01-28T08:16:53.000Z
from slot import * from ability import Ability from collections import defaultdict class Amulet(AmuletBase): a = [] def __init__(self): self.mod = [] self.conf = Conf() self.mmax = { 'a' : 0.20, # attack 's' : 0.40, # skill damage ...
32.637681
141
0.37833
f8ce34cf1949eddb3fbe5b13b838cd17283a54af
397
py
Python
magma/config.py
Kuree/magma
be2439aa897768c5810be72e3a55a6f772ac83cf
[ "MIT" ]
null
null
null
magma/config.py
Kuree/magma
be2439aa897768c5810be72e3a55a6f772ac83cf
[ "MIT" ]
null
null
null
magma/config.py
Kuree/magma
be2439aa897768c5810be72e3a55a6f772ac83cf
[ "MIT" ]
null
null
null
__COMPILE_DIR = 'normal' def set_compile_dir(target): global __COMPILE_DIR assert target in ['normal', 'callee_file_dir'] __COMPILE_DIR = target def get_compile_dir(): return __COMPILE_DIR __DEBUG_MODE = False def set_debug_mode(value=True): global __DEBUG_MODE assert value in {True, Fal...
15.88
50
0.725441
c09f30d44726e2b15a51003e0329ee3d1c49e5a9
13,739
py
Python
python/oneflow/nn/modules/constant.py
L-Net-1992/oneflow
4dc08d65caea36fdd137841ac95551218897e730
[ "Apache-2.0" ]
1
2022-03-14T11:17:56.000Z
2022-03-14T11:17:56.000Z
python/oneflow/nn/modules/constant.py
L-Net-1992/oneflow
4dc08d65caea36fdd137841ac95551218897e730
[ "Apache-2.0" ]
null
null
null
python/oneflow/nn/modules/constant.py
L-Net-1992/oneflow
4dc08d65caea36fdd137841ac95551218897e730
[ "Apache-2.0" ]
1
2021-12-15T02:14:49.000Z
2021-12-15T02:14:49.000Z
""" Copyright 2020 The OneFlow Authors. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
36.442971
196
0.628576
dd8b44021ee9134ebd2a4d988f8f4d28a476fdbd
3,543
py
Python
lz4steg.py
jvarho/lz77steg
09b78ed226139e554d21fc52b599502661d81a3a
[ "MIT" ]
null
null
null
lz4steg.py
jvarho/lz77steg
09b78ed226139e554d21fc52b599502661d81a3a
[ "MIT" ]
null
null
null
lz4steg.py
jvarho/lz77steg
09b78ed226139e554d21fc52b599502661d81a3a
[ "MIT" ]
null
null
null
#!/usr/bin/env python # # Copyright (c) 2014, Jan Varho <jan@varho.org> # Some rights reserved, see COPYING import argparse import sys from lz77steg import LZ77Steg, _hash class LZ4Steg(LZ77Steg): TOK_LITERAL = 1 TOK_MATCH = 2 def init(self, cover): super(LZ4Steg, self).init(cover) se...
29.525
80
0.544736
c31eead604399b77c2a3111c2ca12b71f51b722a
12,036
py
Python
zerver/data_import/gitter.py
pranayshahxyz/zulip
3da483487af79fde9dce2d21124dfa39b94936a5
[ "Apache-2.0" ]
1
2020-04-09T18:34:44.000Z
2020-04-09T18:34:44.000Z
zerver/data_import/gitter.py
pranayshahxyz/zulip
3da483487af79fde9dce2d21124dfa39b94936a5
[ "Apache-2.0" ]
null
null
null
zerver/data_import/gitter.py
pranayshahxyz/zulip
3da483487af79fde9dce2d21124dfa39b94936a5
[ "Apache-2.0" ]
null
null
null
import os import dateutil.parser import logging import subprocess import ujson from django.conf import settings from django.forms.models import model_to_dict from django.utils.timezone import now as timezone_now from typing import Any, Dict, List, Set, Tuple from zerver.models import UserProfile, Recipient from zerve...
42.083916
108
0.640329
44d7a50a47788884bd8198a0fa340ce382afe25b
3,823
py
Python
dhcp/forms.py
jlin/inventory
c098c98e570c3bf9fadfd811eb75e1213f6ea428
[ "BSD-3-Clause" ]
22
2015-01-16T01:36:32.000Z
2020-06-08T00:46:18.000Z
dhcp/forms.py
jlin/inventory
c098c98e570c3bf9fadfd811eb75e1213f6ea428
[ "BSD-3-Clause" ]
9
2019-03-15T11:39:32.000Z
2019-04-30T00:59:50.000Z
dhcp/forms.py
jlin/inventory
c098c98e570c3bf9fadfd811eb75e1213f6ea428
[ "BSD-3-Clause" ]
13
2015-01-13T20:56:22.000Z
2022-02-23T06:01:17.000Z
from django import forms from django.forms.extras.widgets import SelectDateWidget import models class AddDHCPScopeForm(forms.Form): scope_name = forms.CharField(max_length=32, required=True, widget=forms.TextInput(attrs={'size':'48'})) scope_description = forms.CharField(max_length=32, required=True, widget=f...
50.302632
123
0.588805
faeafd869188374215d860a3e647c2b440b2371f
418
py
Python
vtkplotter_examples/volumetric/probePlaneUGrid.py
ismarou/vtkplotter-examples
1eefcc026be169ab7a77a5bce6dec8044c33b554
[ "MIT" ]
4
2020-07-30T02:38:29.000Z
2021-09-12T14:30:18.000Z
vtkplotter_examples/volumetric/probePlaneUGrid.py
ismarou/vtkplotter-examples
1eefcc026be169ab7a77a5bce6dec8044c33b554
[ "MIT" ]
null
null
null
vtkplotter_examples/volumetric/probePlaneUGrid.py
ismarou/vtkplotter-examples
1eefcc026be169ab7a77a5bce6dec8044c33b554
[ "MIT" ]
null
null
null
"""Probe a vtkUnStructuredGrid with a plane""" from vtkplotter import * # same could be done with vtkRectilinearGrid etc.. data = loadUnStructuredGrid(datadir+"ugrid.vtk") # create the outline of the data outermesh = Mesh(data).alpha(0.2).wireframe() orig = data.GetCenter() pl = probePlane(data, origin=orig, normal=...
24.588235
54
0.727273
58c6d8c54c31cdf1aae4643f65e4ab4e67bc8c3f
731
py
Python
release/stubs.min/System/Windows/Forms/__init___parts/ListViewItemMouseHoverEventArgs.py
tranconbv/ironpython-stubs
a601759e6c6819beff8e6b639d18a24b7e351851
[ "MIT" ]
null
null
null
release/stubs.min/System/Windows/Forms/__init___parts/ListViewItemMouseHoverEventArgs.py
tranconbv/ironpython-stubs
a601759e6c6819beff8e6b639d18a24b7e351851
[ "MIT" ]
null
null
null
release/stubs.min/System/Windows/Forms/__init___parts/ListViewItemMouseHoverEventArgs.py
tranconbv/ironpython-stubs
a601759e6c6819beff8e6b639d18a24b7e351851
[ "MIT" ]
null
null
null
class ListViewItemMouseHoverEventArgs(EventArgs): """ Provides data for the System.Windows.Forms.ListView.ItemMouseHover event. ListViewItemMouseHoverEventArgs(item: ListViewItem) """ def Instance(self): """ This function has been arbitrarily put into the stubs""" return ListViewItemMouseHoverEvent...
28.115385
76
0.70725
79813757233743f26c579fa95ec121acc5f9ff67
261
py
Python
pyvisdk/enums/host_unresolved_vmfs_resolution_spec_vmfs_uuid_resolution.py
Infinidat/pyvisdk
f2f4e5f50da16f659ccc1d84b6a00f397fa997f8
[ "MIT" ]
null
null
null
pyvisdk/enums/host_unresolved_vmfs_resolution_spec_vmfs_uuid_resolution.py
Infinidat/pyvisdk
f2f4e5f50da16f659ccc1d84b6a00f397fa997f8
[ "MIT" ]
null
null
null
pyvisdk/enums/host_unresolved_vmfs_resolution_spec_vmfs_uuid_resolution.py
Infinidat/pyvisdk
f2f4e5f50da16f659ccc1d84b6a00f397fa997f8
[ "MIT" ]
null
null
null
######################################## # Automatically generated, do not edit. ######################################## from pyvisdk.thirdparty import Enum HostUnresolvedVmfsResolutionSpecVmfsUuidResolution = Enum( 'forceMount', 'resignature', )
18.642857
58
0.524904
30ddcd586781074a0952c680467261ec209612bf
5,871
py
Python
C/.ycm_extra_conf.py
Kwpolska/roman_numerals
887e648a39fa73583f4b7cf330436f94bf88325e
[ "BSD-3-Clause" ]
null
null
null
C/.ycm_extra_conf.py
Kwpolska/roman_numerals
887e648a39fa73583f4b7cf330436f94bf88325e
[ "BSD-3-Clause" ]
null
null
null
C/.ycm_extra_conf.py
Kwpolska/roman_numerals
887e648a39fa73583f4b7cf330436f94bf88325e
[ "BSD-3-Clause" ]
null
null
null
# This file is NOT licensed under the GPLv3, which is the license for the rest # of YouCompleteMe. # # Here's the license text for this file: # # This is free and unencumbered software released into the public domain. # # Anyone is free to copy, modify, publish, use, compile, sell, or # distribute this software, either...
35.79878
80
0.720491
5ce744a9d09ba9ccc548371f8d8c425687b14425
3,558
py
Python
sktime/forecasting/compose/_ensemble.py
MFaroukB/sktime
29932fc071ab04797bc2f5c00cd533726b31eb46
[ "BSD-3-Clause" ]
null
null
null
sktime/forecasting/compose/_ensemble.py
MFaroukB/sktime
29932fc071ab04797bc2f5c00cd533726b31eb46
[ "BSD-3-Clause" ]
null
null
null
sktime/forecasting/compose/_ensemble.py
MFaroukB/sktime
29932fc071ab04797bc2f5c00cd533726b31eb46
[ "BSD-3-Clause" ]
1
2021-04-30T08:12:18.000Z
2021-04-30T08:12:18.000Z
#!/usr/bin/env python3 -u # -*- coding: utf-8 -*- # copyright: sktime developers, BSD-3-Clause License (see LICENSE file) __author__ = ["Markus Löning"] __all__ = ["EnsembleForecaster"] import pandas as pd from sktime.forecasting.base._base import DEFAULT_ALPHA from sktime.forecasting.base._meta import _Heterogenous...
31.767857
88
0.61692
e88f5c7e5c5526a23be42528470ea313e6284e45
420
py
Python
app/commands.py
nattesharan/delhivery
3ef419d403b27fc490a8557590d81f50a8dbfc4f
[ "MIT" ]
2
2019-06-02T04:32:54.000Z
2021-01-05T12:27:50.000Z
app/commands.py
nattesharan/delhivery
3ef419d403b27fc490a8557590d81f50a8dbfc4f
[ "MIT" ]
null
null
null
app/commands.py
nattesharan/delhivery
3ef419d403b27fc490a8557590d81f50a8dbfc4f
[ "MIT" ]
null
null
null
from flask_script import Command from app.settings import ROLES from delhivery.models import DelhiveryHierarchy class CreateRoles(Command): def run(self): print("Creating roles in database") for role in ROLES: DelhiveryHierarchy.objects.create(name=role['name'], role=role['role'], featu...
35
110
0.730952
15552e06d8192e717651395e0c5336c7682d37ce
15,273
py
Python
src/gluonts/model/san/_layers.py
unibeck/gluon-ts
73d0e9de689ab4bb014cdb4423642dff030e7678
[ "Apache-2.0" ]
1
2019-10-15T01:47:40.000Z
2019-10-15T01:47:40.000Z
src/gluonts/model/san/_layers.py
unibeck/gluon-ts
73d0e9de689ab4bb014cdb4423642dff030e7678
[ "Apache-2.0" ]
null
null
null
src/gluonts/model/san/_layers.py
unibeck/gluon-ts
73d0e9de689ab4bb014cdb4423642dff030e7678
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 Amazon.com, Inc. or its affiliates. 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. # A copy of the License is located at # # http://www.apache.org/licenses/LICENSE-2.0 # # or in the "license...
35.191244
95
0.521443
b9f14e24661a562864244ce1401a8c6a7371104d
2,287
py
Python
logic/reserved/save_row.py
rdevost/pymixup
9004fbdc7939033014b0eefa669056014647a0c8
[ "MIT" ]
5
2017-01-02T15:12:31.000Z
2021-09-03T15:51:39.000Z
logic/reserved/save_row.py
rdevost/pymixup
9004fbdc7939033014b0eefa669056014647a0c8
[ "MIT" ]
null
null
null
logic/reserved/save_row.py
rdevost/pymixup
9004fbdc7939033014b0eefa669056014647a0c8
[ "MIT" ]
1
2021-09-03T15:51:41.000Z
2021-09-03T15:51:41.000Z
from peewee import IntegrityError, DoesNotExist from data.base import obfuscatedb from data.save_row import save_row from logic.reserved import reserved_prefixes def save_reserved(reserved_row, **kwargs): """Save a Reserved row.""" from logic.identifier import get_identifier_by_name, \ get_identifier...
35.184615
77
0.609532
f01e4e692f228accacfe185a6c2aef5402234333
10,821
py
Python
tensorflow_transform/coders/example_proto_coder_test.py
devidipak/transform
56efe455b29fa3d0a29ce2f8872adc41ed6012c3
[ "Apache-2.0" ]
2
2021-07-19T02:00:30.000Z
2021-07-19T02:00:37.000Z
tensorflow_transform/coders/example_proto_coder_test.py
devidipak/transform
56efe455b29fa3d0a29ce2f8872adc41ed6012c3
[ "Apache-2.0" ]
null
null
null
tensorflow_transform/coders/example_proto_coder_test.py
devidipak/transform
56efe455b29fa3d0a29ce2f8872adc41ed6012c3
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # # Copyright 2017 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 ap...
39.349091
86
0.651049
abe3a1d1717f7c2c95e1e56375fac48249fea210
23,334
py
Python
Main.py
dydx-git/Calcy
fba4510220599a1a148dad15da0cbb508905034c
[ "MIT" ]
null
null
null
Main.py
dydx-git/Calcy
fba4510220599a1a148dad15da0cbb508905034c
[ "MIT" ]
null
null
null
Main.py
dydx-git/Calcy
fba4510220599a1a148dad15da0cbb508905034c
[ "MIT" ]
null
null
null
#<--------------------------------------------------------------------------------------IMPORTS------------------------------------------------------------------------> from tkinter import * import add, subtract, multiply, divide, sin, cos, tan, asin, acos, atan, sinh, cosh, tanh, asinh, acosh, atanh, log, ln, x2, xy...
39.085427
180
0.577955
f6eff9e897288c7563a293b83e2a0c82907ad90e
632
py
Python
jass/mongo_utils.py
crim-ca/JASS
8a2d0bdd4cb50021c890fbb3059e75fa6f9adebb
[ "MIT", "Python-2.0", "BSD-2-Clause", "Apache-2.0" ]
1
2017-01-18T13:05:21.000Z
2017-01-18T13:05:21.000Z
jass/mongo_utils.py
crim-ca/JASS
8a2d0bdd4cb50021c890fbb3059e75fa6f9adebb
[ "MIT", "Python-2.0", "BSD-2-Clause", "Apache-2.0" ]
null
null
null
jass/mongo_utils.py
crim-ca/JASS
8a2d0bdd4cb50021c890fbb3059e75fa6f9adebb
[ "MIT", "Python-2.0", "BSD-2-Clause", "Apache-2.0" ]
1
2017-05-18T18:38:53.000Z
2017-05-18T18:38:53.000Z
#!/usr/bin/env python # coding:utf-8 """ Various utilities for mongoDB usage. """ from bson.objectid import ObjectId def changeDocIdToString(mongoDoc): """ Changes the _id to string. Will crash if mongoDoc is not a valid Mongo Document """ if(mongoDoc is not None): mongoDoc['_id'] = str(...
20.387097
68
0.664557
051ca1df8e3e82a4bdd0c9d489e4643cfa3fbb5b
4,386
py
Python
generate.py
CodeProcessor/python-project-template
5dd9c461aca011458d2f52ccd0b67f3ffa90254b
[ "MIT" ]
null
null
null
generate.py
CodeProcessor/python-project-template
5dd9c461aca011458d2f52ccd0b67f3ffa90254b
[ "MIT" ]
null
null
null
generate.py
CodeProcessor/python-project-template
5dd9c461aca011458d2f52ccd0b67f3ffa90254b
[ "MIT" ]
null
null
null
""" Copyright (C) CUBE Content Governance Global Limited - All Rights Reserved Unauthorized copying of this file, via any medium is strictly prohibited Proprietary and confidential Written by Dulan Jayasuriya <dulan.jayasuriya@cube.global>, 11 February 2022 """ import json import os.path from datetime import datetime ...
36.247934
127
0.618103
f58d2ccac4af29972b878702f522bd7071a45924
2,106
py
Python
generateDates.py
Husterknupp/2020-oster-squash
43e8742c89ad1225119e8d2c4d2dba6a2914dd0d
[ "MIT" ]
1
2020-03-06T16:06:00.000Z
2020-03-06T16:06:00.000Z
generateDates.py
Husterknupp/2020-oster-squash
43e8742c89ad1225119e8d2c4d2dba6a2914dd0d
[ "MIT" ]
1
2021-06-10T18:36:46.000Z
2021-06-10T18:36:46.000Z
generateDates.py
Husterknupp/2020-oster-squash
43e8742c89ad1225119e8d2c4d2dba6a2914dd0d
[ "MIT" ]
1
2020-03-05T23:38:21.000Z
2020-03-05T23:38:21.000Z
# 2017-09-14T03:21:47.070-04:00 # VERSION 3 days = {} for day in range(7, 12): timeFrames = [] for hour in range(14, 18): timeFrames.append(hour) days[day] = timeFrames for day, hours in days.items(): if day < 10: print(f'{{day: "2020-04-0{day}", hours: {hours}}}') else: pr...
26.325
65
0.575024
5b9d1385a38db639b838aaf556603ad2f7af03c9
895
py
Python
lightkit/nn/_protocols.py
borchero/lightkit
725cde3dff1cfbccf78bf10b9e922145a43959ca
[ "MIT" ]
1
2022-01-26T07:58:04.000Z
2022-01-26T07:58:04.000Z
lightkit/nn/_protocols.py
borchero/lightkit
725cde3dff1cfbccf78bf10b9e922145a43959ca
[ "MIT" ]
null
null
null
lightkit/nn/_protocols.py
borchero/lightkit
725cde3dff1cfbccf78bf10b9e922145a43959ca
[ "MIT" ]
null
null
null
# pylint: disable=missing-class-docstring,missing-function-docstring from typing import Generic, Iterator, OrderedDict, Protocol, Tuple, Type, TypeVar import torch from torch import nn from lightkit.utils import PathType C = TypeVar("C", covariant=True) M = TypeVar("M", bound="ConfigurableModule") # type: ignore cl...
26.323529
82
0.64581
7b5a18350f540be7cf4eaf8053f1a8c17a766f2c
1,120
py
Python
setup.py
kbarnhart/corebreakout
fa8dc7575b330b7c1ce47a35b44deca7856bd05c
[ "MIT" ]
20
2019-12-09T23:56:32.000Z
2021-08-11T18:57:59.000Z
setup.py
kbarnhart/corebreakout
fa8dc7575b330b7c1ce47a35b44deca7856bd05c
[ "MIT" ]
13
2019-11-05T00:13:39.000Z
2021-08-20T19:08:13.000Z
setup.py
kbarnhart/corebreakout
fa8dc7575b330b7c1ce47a35b44deca7856bd05c
[ "MIT" ]
12
2019-12-12T17:35:44.000Z
2021-10-05T05:45:49.000Z
#!/usr/bin/env python3 import os from setuptools import find_packages try: from setuptools import setup except ImportError: raise UserWarning('`distutils` is not supported since you must use Python>=3.6') try: import tensorflow except ImportError: raise UserWarning('`tensorflow` or `tensorflow-gpu` mu...
23.829787
100
0.68125
e4bc7012aeb298951ce85df5077a9bd74ccebb69
213
py
Python
project_system/config/desktop.py
pradyotr/frappe-project-sys
ec4bc793e445ddd8f37f286e30f329369b51bb11
[ "MIT" ]
null
null
null
project_system/config/desktop.py
pradyotr/frappe-project-sys
ec4bc793e445ddd8f37f286e30f329369b51bb11
[ "MIT" ]
null
null
null
project_system/config/desktop.py
pradyotr/frappe-project-sys
ec4bc793e445ddd8f37f286e30f329369b51bb11
[ "MIT" ]
null
null
null
from frappe import _ def get_data(): return [ { "module_name": "Project System", "color": "grey", "icon": "octicon octicon-file-directory", "type": "module", "label": _("Project System") } ]
16.384615
44
0.596244
14be349ed04493c43141190033835920909e1dae
369
py
Python
projects/migrations/0004_rename_name_userprofile_username.py
sling254/msHackthorn
82fb627c9e521e1a24c583b28c63df44db7860d9
[ "MIT" ]
null
null
null
projects/migrations/0004_rename_name_userprofile_username.py
sling254/msHackthorn
82fb627c9e521e1a24c583b28c63df44db7860d9
[ "MIT" ]
null
null
null
projects/migrations/0004_rename_name_userprofile_username.py
sling254/msHackthorn
82fb627c9e521e1a24c583b28c63df44db7860d9
[ "MIT" ]
null
null
null
# Generated by Django 3.2.9 on 2021-12-11 20:48 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('projects', '0003_auto_20211211_2255'), ] operations = [ migrations.RenameField( model_name='userprofile', old_name='name', ...
19.421053
48
0.590786
9f6503581e582d13b54be9ade22689a2e1f432d8
2,120
py
Python
utils/models_utils.py
ermekaitygulov/STIT
93dca8d589b555fa99a5c5438a8517a52d8898c3
[ "BSD-3-Clause", "BSD-2-Clause", "MIT" ]
6
2022-03-11T23:42:12.000Z
2022-03-28T09:39:25.000Z
utils/models_utils.py
bycloudai/STIT-Windows
cadb2a01457bfd1c90bcd8d220587b48e1c2327a
[ "BSD-3-Clause", "BSD-2-Clause", "MIT" ]
null
null
null
utils/models_utils.py
bycloudai/STIT-Windows
cadb2a01457bfd1c90bcd8d220587b48e1c2327a
[ "BSD-3-Clause", "BSD-2-Clause", "MIT" ]
null
null
null
import copy import pickle from argparse import Namespace import torch from configs import paths_config, global_config from models.e4e.psp import pSp from training.networks import Generator def save_tuned_G(generator, pivots, quads, run_id): generator = copy.deepcopy(generator).cpu() pivots = copy.deepcopy(p...
31.641791
95
0.713208
1cfc4917b463b78e9058131327b07dce7af2d133
39,145
py
Python
job_search-ad_targeting-search_engine-advanced_use_cases.py
MDRCS/Redis
5315ce48d4a771f14129efe8bd2deefcec465f24
[ "MIT" ]
null
null
null
job_search-ad_targeting-search_engine-advanced_use_cases.py
MDRCS/Redis
5315ce48d4a771f14129efe8bd2deefcec465f24
[ "MIT" ]
null
null
null
job_search-ad_targeting-search_engine-advanced_use_cases.py
MDRCS/Redis
5315ce48d4a771f14129efe8bd2deefcec465f24
[ "MIT" ]
null
null
null
import math import re import unittest import uuid import redis # Search Engine - Use case : AVERAGE_PER_1K = {} # <start id="tokenize-and-index"/> STOP_WORDS = set('''able about across after all almost also am among an and any are as at be because been but by can cannot could dear did do does either else ever ever...
44.994253
192
0.567557
98190be3cb4d7cd798c48d3d94ec4f5848355f07
2,072
py
Python
backend/pharmacy/api/views/medical/medicine.py
rahul007-bit/pharmaService
73191f64569eae7c7851f5b7bf9187f3f01b7a6e
[ "MIT" ]
4
2022-01-28T13:05:07.000Z
2022-01-31T12:24:56.000Z
backend/pharmacy/api/views/medical/medicine.py
rahul007-bit/pharmaService
73191f64569eae7c7851f5b7bf9187f3f01b7a6e
[ "MIT" ]
6
2022-01-30T11:53:31.000Z
2022-02-02T06:17:30.000Z
backend/pharmacy/api/views/medical/medicine.py
rahul007-bit/pharmaService
73191f64569eae7c7851f5b7bf9187f3f01b7a6e
[ "MIT" ]
3
2022-01-28T13:41:03.000Z
2022-01-30T12:23:11.000Z
# pylint: disable=missing-module-docstring # # Copyright (C) 2022 by YadavGulshan@Github, < https://github.com/YadavGulshan >. # # This file is part of < https://github.com/Yadavgulshan/pharmaService > project, # and is released under the "BSD 3-Clause License Agreement". # Please see < https://github.com/YadavGulshan/...
35.724138
85
0.726834
00345485045dc5f4f7fed4443a3b831e24371cee
4,740
py
Python
test/unit/test_cmdline.py
jsiverskog/pyOCD
8b75633482a2f1856a8ab6af9ebb5c1b2f9d8285
[ "Apache-2.0" ]
1
2020-07-11T09:24:25.000Z
2020-07-11T09:24:25.000Z
test/unit/test_cmdline.py
ARMmbed/pyOCD-Samsung
03242b6eb57d2170a4b531d00f1a0577e2b0abde
[ "Apache-2.0" ]
null
null
null
test/unit/test_cmdline.py
ARMmbed/pyOCD-Samsung
03242b6eb57d2170a4b531d00f1a0577e2b0abde
[ "Apache-2.0" ]
null
null
null
# pyOCD debugger # Copyright (c) 2015,2018-2019 Arm Limited # SPDX-License-Identifier: Apache-2.0 # # 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/LICENS...
41.217391
100
0.65211
662f721e6bf897cea9dd650362875a4f927de112
3,595
py
Python
tests/unit/test_protocol_errors.py
dcolligan/ga4gh-server
dd0b00a52de9684609b7f04a9d70946c36afa8a5
[ "Apache-2.0" ]
83
2015-01-05T22:21:11.000Z
2017-02-20T01:25:28.000Z
tests/unit/test_protocol_errors.py
dcolligan/ga4gh-server
dd0b00a52de9684609b7f04a9d70946c36afa8a5
[ "Apache-2.0" ]
1,508
2015-01-02T14:06:12.000Z
2017-03-08T19:49:18.000Z
tests/unit/test_protocol_errors.py
dcolligan/ga4gh-server
dd0b00a52de9684609b7f04a9d70946c36afa8a5
[ "Apache-2.0" ]
99
2015-01-14T20:48:56.000Z
2017-03-08T18:35:06.000Z
""" Unit tests for frontend error conditions. """ from __future__ import division from __future__ import print_function from __future__ import unicode_literals import unittest import ga4gh.server.frontend as frontend import ga4gh.server.exceptions as exceptions import ga4gh.schemas.protocol as protocol class TestF...
38.244681
79
0.664256
8639cebd5b3ff50ceacb82ea2b2485b775145b52
1,115
py
Python
pacific-factbook/flag.py
kaunta/pacific-factbook
ccf3f08c0d6121d852e5dd0319e21e0a9ec44e3d
[ "MIT" ]
5
2020-01-23T04:08:46.000Z
2020-04-02T05:19:34.000Z
pacific-factbook/flag.py
kaunta/pacific-factbook
ccf3f08c0d6121d852e5dd0319e21e0a9ec44e3d
[ "MIT" ]
23
2019-11-22T01:56:54.000Z
2020-02-08T23:45:10.000Z
pacific-factbook/flag.py
kaunta/pacific-factbook
ccf3f08c0d6121d852e5dd0319e21e0a9ec44e3d
[ "MIT" ]
null
null
null
from fractions import Fraction from random import choice def generate() -> str: """ Generate a random flag. Outputs SVG blob. """ colors = set("red blue white green yellow black orange brown gray purple".split()) color_background = choice(list(colors)) color_shape = choice(list(colors - {colo...
31.857143
152
0.584753
37bfa76cc51a0d3dcd589ba75b34bc72511475c3
6,723
py
Python
lighttpd/datadog_checks/lighttpd/lighttpd.py
glasser/integrations-core
1dd515d49b1690a1369ee5195713605b1b072b1f
[ "BSD-3-Clause" ]
null
null
null
lighttpd/datadog_checks/lighttpd/lighttpd.py
glasser/integrations-core
1dd515d49b1690a1369ee5195713605b1b072b1f
[ "BSD-3-Clause" ]
null
null
null
lighttpd/datadog_checks/lighttpd/lighttpd.py
glasser/integrations-core
1dd515d49b1690a1369ee5195713605b1b072b1f
[ "BSD-3-Clause" ]
null
null
null
# (C) Datadog, Inc. 2010-2017 # All rights reserved # Licensed under Simplified BSD License (see LICENSE) import re import requests from six.moves.urllib.parse import urlparse from datadog_checks.checks import AgentCheck VERSION_REGEX = re.compile(r".*/(\d)") class Lighttpd(AgentCheck): """Tracks basic connec...
41.5
119
0.625614
233391949dea48d8da274bc5b7e7be2c1ffac7f7
3,568
py
Python
sdks/python/appcenter_sdk/models/BlobInfo.py
Brantone/appcenter-sdks
eeb063ecf79908b6e341fb00196d2cd9dc8f3262
[ "MIT" ]
null
null
null
sdks/python/appcenter_sdk/models/BlobInfo.py
Brantone/appcenter-sdks
eeb063ecf79908b6e341fb00196d2cd9dc8f3262
[ "MIT" ]
6
2019-10-23T06:38:53.000Z
2022-01-22T07:57:58.000Z
sdks/python/appcenter_sdk/models/BlobInfo.py
Brantone/appcenter-sdks
eeb063ecf79908b6e341fb00196d2cd9dc8f3262
[ "MIT" ]
2
2019-10-23T06:31:05.000Z
2021-08-21T17:32:47.000Z
# coding: utf-8 """ App Center Client Microsoft Visual Studio App Center API # noqa: E501 OpenAPI spec version: preview Contact: benedetto.abbenanti@gmail.com Project Repository: https://github.com/b3nab/appcenter-sdks """ import pprint import re # noqa: F401 import six class BlobInfo(objec...
26.043796
90
0.539238
2501b593dd91359dd470ec59d0b5a796aa1d77c7
13,195
py
Python
GeoHealthCheck/probe.py
SteveR1984/GeoHealthCheck
52a13c1bd42e79dec547fa29324d583aea5e3773
[ "MIT" ]
null
null
null
GeoHealthCheck/probe.py
SteveR1984/GeoHealthCheck
52a13c1bd42e79dec547fa29324d583aea5e3773
[ "MIT" ]
null
null
null
GeoHealthCheck/probe.py
SteveR1984/GeoHealthCheck
52a13c1bd42e79dec547fa29324d583aea5e3773
[ "MIT" ]
null
null
null
import logging import sys import datetime import requests from factory import Factory from init import App from plugin import Plugin from result import ProbeResult LOGGER = logging.getLogger(__name__) class Probe(Plugin): """ Base class for specific implementations to run a Probe with Checks. Most Pr...
33.070175
78
0.59371
b20f5bb5243c099ecde48102e2c5b3241ad8c242
1,215
py
Python
blog/feeds.py
josephdubon/boilerplate_dubon_django_blog
1dbe470006be066b12dd6486eb26a41d304206f8
[ "Unlicense", "MIT" ]
null
null
null
blog/feeds.py
josephdubon/boilerplate_dubon_django_blog
1dbe470006be066b12dd6486eb26a41d304206f8
[ "Unlicense", "MIT" ]
2
2021-06-10T20:43:00.000Z
2021-09-22T19:55:41.000Z
blog/feeds.py
josephdubon/boilerplate_dubon_django_blog
1dbe470006be066b12dd6486eb26a41d304206f8
[ "Unlicense", "MIT" ]
null
null
null
from django.contrib.syndication.views import Feed from django.template.defaultfilters import truncatewords from django.urls import reverse_lazy from .models import Post # First subclass the Feed class of the syndication framework class LatestPostFeed(Feed): # The title, link, and description attributes correspon...
40.5
105
0.721811
732af64a825fbb52eff7ca5348fcccf84ffaf7b6
6,857
py
Python
tests/unit/python/foglamp/services/core/api/test_plugin_discovery_api.py
christoofar/FogLAMP
3aaae302104038a8534c54ff8a3ed0fefd4f3201
[ "Apache-2.0" ]
null
null
null
tests/unit/python/foglamp/services/core/api/test_plugin_discovery_api.py
christoofar/FogLAMP
3aaae302104038a8534c54ff8a3ed0fefd4f3201
[ "Apache-2.0" ]
null
null
null
tests/unit/python/foglamp/services/core/api/test_plugin_discovery_api.py
christoofar/FogLAMP
3aaae302104038a8534c54ff8a3ed0fefd4f3201
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # FOGLAMP_BEGIN # See: http://foglamp.readthedocs.io/ # FOGLAMP_END import json from unittest.mock import patch import pytest from aiohttp import web from foglamp.services.core import routes from foglamp.common.plugin_discovery import PluginDiscovery __author__ = "Ashish Jabble" __copyright_...
62.336364
450
0.612221
996b118d17d717560f4a0af453b7ab64ecd26aa2
14,016
py
Python
bcbio/variation/freebayes.py
SciLifeLab/bcbio-nextgen
370b3f316c423b41523accc5e212d51a5b7ecaa9
[ "MIT" ]
3
2015-11-18T07:17:54.000Z
2021-04-28T13:58:37.000Z
bcbio/variation/freebayes.py
SciLifeLab/bcbio-nextgen
370b3f316c423b41523accc5e212d51a5b7ecaa9
[ "MIT" ]
null
null
null
bcbio/variation/freebayes.py
SciLifeLab/bcbio-nextgen
370b3f316c423b41523accc5e212d51a5b7ecaa9
[ "MIT" ]
null
null
null
"""Bayesian variant calling with FreeBayes. https://github.com/ekg/freebayes """ import os import sys from bcbio import bam, utils from bcbio.distributed.transaction import file_transaction from bcbio.pipeline import config_utils from bcbio.pipeline.shared import subset_variant_regions from bcbio.provenance import d...
46.564784
111
0.625571
059477a5e9673a4c2633fe2f8f66cc7e6ad70934
722
py
Python
dataworkspace/dataworkspace/apps/core/migrations/0009_alter_newslettersubscription_user.py
uktrade/analysis-workspace
2de79c6172cf391c1954ca3789c5c0dc0030ec25
[ "MIT" ]
1
2019-06-10T08:22:56.000Z
2019-06-10T08:22:56.000Z
dataworkspace/dataworkspace/apps/core/migrations/0009_alter_newslettersubscription_user.py
uktrade/analysis-workspace
2de79c6172cf391c1954ca3789c5c0dc0030ec25
[ "MIT" ]
2
2019-05-17T13:10:42.000Z
2019-06-17T10:48:46.000Z
dataworkspace/dataworkspace/apps/core/migrations/0009_alter_newslettersubscription_user.py
uktrade/analysis-workspace
2de79c6172cf391c1954ca3789c5c0dc0030ec25
[ "MIT" ]
null
null
null
# Generated by Django 3.2.13 on 2022-05-30 16:36 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ("core", "0008_newsletter...
26.740741
66
0.620499
92bef292d32f033bf6fc1a3129d3ad91496c15f1
735
py
Python
third_party/WebKit/LayoutTests/http/tests/websocket/count-received-bytes_wsh.py
google-ar/chromium
2441c86a5fd975f09a6c30cddb57dfb7fc239699
[ "Apache-2.0", "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
777
2017-08-29T15:15:32.000Z
2022-03-21T05:29:41.000Z
third_party/WebKit/LayoutTests/http/tests/websocket/count-received-bytes_wsh.py
harrymarkovskiy/WebARonARCore
2441c86a5fd975f09a6c30cddb57dfb7fc239699
[ "Apache-2.0", "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
66
2017-08-30T18:31:18.000Z
2021-08-02T10:59:35.000Z
third_party/WebKit/LayoutTests/http/tests/websocket/count-received-bytes_wsh.py
harrymarkovskiy/WebARonARCore
2441c86a5fd975f09a6c30cddb57dfb7fc239699
[ "Apache-2.0", "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
123
2017-08-30T01:19:34.000Z
2022-03-17T22:55:31.000Z
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import codecs def web_socket_do_extra_handshake(request): request.ws_extension_processors = [] request.received_bytes = 0 def web_socket_transfe...
27.222222
72
0.69932
0dc7a0e33f43683e9d3893c734939f1b47d95db7
3,853
py
Python
Website/site/gravi_site.py
NPPC-UK/Gravimetrics
a4a4bada6da5e2c3dd6f58e7fa4ca226fc374d86
[ "MIT" ]
4
2016-11-19T00:34:45.000Z
2021-12-30T14:27:01.000Z
Website/site/gravi_site.py
NPPC-UK/Gravimetrics
a4a4bada6da5e2c3dd6f58e7fa4ca226fc374d86
[ "MIT" ]
null
null
null
Website/site/gravi_site.py
NPPC-UK/Gravimetrics
a4a4bada6da5e2c3dd6f58e7fa4ca226fc374d86
[ "MIT" ]
null
null
null
#!/usr/bin/python3 from flask import Flask, render_template, request, redirect, url_for, session, flash, make_response from functools import wraps import pandas as pd from login_manager import login_user from data_manager import get_experiments, get_experiment_plants, get_all_water_data, get_all_balance_data, end_expe...
31.072581
167
0.634051
80c66543b75d2ff9a7750f02411603a70d48e236
3,171
py
Python
louvain_to_gephi_giraph.py
ErathosthemesAmmoro/track-communities
7afd60aaa62ed0b81c7f785974ea0a8687ea136e
[ "Apache-2.0" ]
12
2015-02-02T13:13:52.000Z
2022-03-16T12:35:32.000Z
louvain_to_gephi_giraph.py
ErathosthemesAmmoro/track-communities
7afd60aaa62ed0b81c7f785974ea0a8687ea136e
[ "Apache-2.0" ]
null
null
null
louvain_to_gephi_giraph.py
ErathosthemesAmmoro/track-communities
7afd60aaa62ed0b81c7f785974ea0a8687ea136e
[ "Apache-2.0" ]
3
2015-10-05T00:27:38.000Z
2020-03-02T17:51:39.000Z
# # Copyright 2016 Sotera Defense Solutions Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
32.690722
168
0.639546
a911e61793ef8f41cbc108968858cbe169ca9be7
854
py
Python
maza/modules/creds/cameras/avigilon/ssh_default_creds.py
ArturSpirin/maza
56ae6325c08bcedd22c57b9fe11b58f1b38314ca
[ "MIT" ]
2
2020-02-06T20:24:31.000Z
2022-03-08T19:07:16.000Z
maza/modules/creds/cameras/avigilon/ssh_default_creds.py
ArturSpirin/maza
56ae6325c08bcedd22c57b9fe11b58f1b38314ca
[ "MIT" ]
null
null
null
maza/modules/creds/cameras/avigilon/ssh_default_creds.py
ArturSpirin/maza
56ae6325c08bcedd22c57b9fe11b58f1b38314ca
[ "MIT" ]
null
null
null
from maza.core.exploit import * from maza.modules.creds.generic.ssh_default import Exploit as SSHDefault class Exploit(SSHDefault): __info__ = { "name": "Avigilon Camera Default SSH Creds", "description": "Module performs dictionary attack against Avigilon Camera SSH service. " ...
37.130435
112
0.633489
1a846b94245e2d6772d0bc9c4ad377131f0e9ab0
842
py
Python
molecool/io/xyz.py
aatishpr/molecool
73a52479b41ae2847b32707b2c32ca4e23ca83c4
[ "BSD-3-Clause" ]
null
null
null
molecool/io/xyz.py
aatishpr/molecool
73a52479b41ae2847b32707b2c32ca4e23ca83c4
[ "BSD-3-Clause" ]
null
null
null
molecool/io/xyz.py
aatishpr/molecool
73a52479b41ae2847b32707b2c32ca4e23ca83c4
[ "BSD-3-Clause" ]
null
null
null
""" xyz.py read and write xyz files """ import numpy as np def open_xyz(file_location): # Open an xyz file and return symbols and coordinates. xyz_file = np.genfromtxt(fname=file_location, skip_header=2, dtype='unicode') symbols = xyz_file[:,0] coords = (xyz_file[:,1:]) coords = coords.asty...
27.16129
100
0.597387
e104fb385828ad6c784935c829f1b6493d240a92
4,142
py
Python
packages/core/minos-microservice-common/minos/common/exceptions.py
sorasful/minos-python
1189330eebf6444627a2af6b29f347670f95a4dd
[ "MIT" ]
247
2022-01-24T14:55:30.000Z
2022-03-25T12:06:17.000Z
packages/core/minos-microservice-common/minos/common/exceptions.py
sorasful/minos-python
1189330eebf6444627a2af6b29f347670f95a4dd
[ "MIT" ]
400
2021-04-03T08:51:40.000Z
2022-01-28T11:51:22.000Z
packages/core/minos-microservice-common/minos/common/exceptions.py
sorasful/minos-python
1189330eebf6444627a2af6b29f347670f95a4dd
[ "MIT" ]
21
2022-02-06T17:25:58.000Z
2022-03-27T04:50:29.000Z
from __future__ import ( annotations, ) from typing import ( Any, Type, ) class MinosException(Exception): """Exception class for import packages or modules""" __slots__ = "_message" def __init__(self, error_message: str): self._message = error_message def __repr__(self): ...
27.986486
116
0.714148
26dda6dadc85793b3ded36754e694ede7a1ba805
2,394
py
Python
tests/test_environment.py
mclaffey/dfx
29f223e4d2be924f25f8903bcbac10b91915d6fb
[ "MIT" ]
null
null
null
tests/test_environment.py
mclaffey/dfx
29f223e4d2be924f25f8903bcbac10b91915d6fb
[ "MIT" ]
null
null
null
tests/test_environment.py
mclaffey/dfx
29f223e4d2be924f25f8903bcbac10b91915d6fb
[ "MIT" ]
null
null
null
#!/usr/bin/env python import os import sys import unittest import unittest_dfx import dfx.ui_curses import dfx.datasets class EnvTest(unittest_dfx.AbstractDfTestCase): """Test functionality of ui_curses.Environment """ def test_load_file(self): """Providing a path to a csv loads a new Dfview nam...
32.351351
67
0.629073
52e16dff99c9662b47b99315d3e8de64bfb65f4e
374
py
Python
contests/20210123/abc189/b/main.py
yamap55/atcoder_python
eb000b8df3037a2bba3d3527014bc12770018cb6
[ "MIT" ]
null
null
null
contests/20210123/abc189/b/main.py
yamap55/atcoder_python
eb000b8df3037a2bba3d3527014bc12770018cb6
[ "MIT" ]
7
2021-01-23T06:51:03.000Z
2021-07-26T15:05:44.000Z
contests/20210123/abc189/b/main.py
yamap55/atcoder_python
eb000b8df3037a2bba3d3527014bc12770018cb6
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 a = [int(_) for _ in input().split()] N = a[0] X = a[1] l = [input().split() for _ in range(N)] al = 0 result = -1 for i, r in enumerate(l): v = int(r[0]) p = int(r[1]) # al = al + (v * p / 100) # if X < al: # 小数点以下は誤差が出るので100倍して比較 al = al + (v * p) if (X * 100) < al...
17
39
0.475936
7d75044ee36eb1c5bd509405675bedcbc9d547da
2,564
py
Python
library_samples/Python3/ocs_sample_library_preview/SDS/SdsStreamViewMap.py
osi-awoodall/OSI-Samples-OCS
1995ccda20e4fe2ae66f3b67afbc1127d638a6fc
[ "Apache-2.0" ]
null
null
null
library_samples/Python3/ocs_sample_library_preview/SDS/SdsStreamViewMap.py
osi-awoodall/OSI-Samples-OCS
1995ccda20e4fe2ae66f3b67afbc1127d638a6fc
[ "Apache-2.0" ]
null
null
null
library_samples/Python3/ocs_sample_library_preview/SDS/SdsStreamViewMap.py
osi-awoodall/OSI-Samples-OCS
1995ccda20e4fe2ae66f3b67afbc1127d638a6fc
[ "Apache-2.0" ]
null
null
null
# SdsStreamViewMap.py # import json from .SdsStreamViewProperty import SdsStreamViewProperty class SdsStreamViewMap(object): """ SdsStreamViewMap definitions """ @property def SourceTypeId(self): """ required :return: """ return self.__sourceTypeId @S...
24.188679
69
0.583463
b57289300e28fa87dba472d7101a480343463701
7,606
py
Python
graphsaint/pytorch_version/models.py
sandl99/KGraph
bb1a9e90b785315ecb501593a0ac19e6fafc2f28
[ "MIT" ]
null
null
null
graphsaint/pytorch_version/models.py
sandl99/KGraph
bb1a9e90b785315ecb501593a0ac19e6fafc2f28
[ "MIT" ]
1
2021-04-14T15:22:45.000Z
2021-04-14T15:22:45.000Z
graphsaint/pytorch_version/models.py
sandl99/Simple-KGCN-GraphSAINT
bb1a9e90b785315ecb501593a0ac19e6fafc2f28
[ "MIT" ]
null
null
null
import torch from torch import nn import torch.nn.functional as F import numpy as np from graphsaint.utils import * import graphsaint.pytorch_version.layers as layers class GraphSAINT(nn.Module): def __init__(self, num_classes, arch_gcn, train_params, feat_full, label_full, cpu_eval=False): """ ...
42.49162
103
0.58822
093c4535c1ce61b59f9d327f2b10e216bb19b0d4
5,319
py
Python
test/sagemaker_tests/mxnet/training/resources/mnist/mnist.py
Elizaaaaa/deep-learning-containers
6274ecb264645070d11b27e5c7e60d2e4110537d
[ "Apache-2.0" ]
383
2020-05-19T18:09:10.000Z
2022-03-29T22:41:05.000Z
test/sagemaker_tests/mxnet/training/resources/mnist/mnist.py
Elizaaaaa/deep-learning-containers
6274ecb264645070d11b27e5c7e60d2e4110537d
[ "Apache-2.0" ]
551
2020-05-27T17:25:50.000Z
2022-03-31T18:00:35.000Z
test/sagemaker_tests/mxnet/training/resources/mnist/mnist.py
Elizaaaaa/deep-learning-containers
6274ecb264645070d11b27e5c7e60d2e4110537d
[ "Apache-2.0" ]
263
2020-05-19T18:17:12.000Z
2022-03-29T22:41:10.000Z
# Copyright 2018-2020 Amazon.com, Inc. or its affiliates. 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. # A copy of the License is located at # # http://www.apache.org/licenses/LICENSE-2.0 # # or in the "li...
36.682759
96
0.679263
4aad679f22b6819115723b88865258ef950cad8a
10,061
py
Python
stage/test_google_bigquery_destination.py
streamsets/datacollector-tests
6c3e908768e1d4a586e9183e2141096921ecd5be
[ "Apache-2.0" ]
14
2019-03-04T10:12:39.000Z
2021-11-24T16:17:09.000Z
stage/test_google_bigquery_destination.py
Pragatibs/datacollector-tests
aac53b2f0e056009ef0e437c8430651e3cf4d502
[ "Apache-2.0" ]
48
2019-03-08T14:59:06.000Z
2021-08-13T14:49:56.000Z
stage/test_google_bigquery_destination.py
Pragatibs/datacollector-tests
aac53b2f0e056009ef0e437c8430651e3cf4d502
[ "Apache-2.0" ]
23
2018-09-24T20:49:17.000Z
2021-11-24T16:17:11.000Z
# Copyright 2020 StreamSets Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writi...
43.180258
116
0.688898
f01bdf47ea08dc3c9aac49fe707dbd4b07f65f71
12,939
py
Python
sympy/core/symbol.py
tesseralis/sympy
0c2f7e06b1a43d25ba93bac65e93f8d5f323be7a
[ "BSD-3-Clause" ]
1
2020-11-17T07:35:20.000Z
2020-11-17T07:35:20.000Z
sympy/core/symbol.py
tesseralis/sympy
0c2f7e06b1a43d25ba93bac65e93f8d5f323be7a
[ "BSD-3-Clause" ]
null
null
null
sympy/core/symbol.py
tesseralis/sympy
0c2f7e06b1a43d25ba93bac65e93f8d5f323be7a
[ "BSD-3-Clause" ]
null
null
null
from sympy.core.assumptions import StdFactKB from basic import Basic from core import C from sympify import sympify from singleton import S from expr import Expr, AtomicExpr from cache import cacheit from function import FunctionClass from sympy.core.logic import fuzzy_bool from sympy.logic.boolalg import Boolean from ...
29.141892
88
0.567277