hexsha
stringlengths
40
40
size
int64
7
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
247
max_issues_repo_name
stringlengths
4
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
247
max_forks_repo_name
stringlengths
4
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.77
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
7
1.04M
filtered:remove_function_no_docstring
int64
-102
942k
filtered:remove_class_no_docstring
int64
-354
977k
filtered:remove_delete_markers
int64
0
60.1k
8e33622f2e93a45dd032a9f590ba30c99f8ec7de
850
py
Python
setup.py
appchoose/choixpeau
936831fd47212f4a81f7ffe0970319e30a31a072
[ "MIT" ]
null
null
null
setup.py
appchoose/choixpeau
936831fd47212f4a81f7ffe0970319e30a31a072
[ "MIT" ]
null
null
null
setup.py
appchoose/choixpeau
936831fd47212f4a81f7ffe0970319e30a31a072
[ "MIT" ]
null
null
null
import setuptools with open("README.md", "r") as fh: long_description = fh.read() setuptools.setup( name="choixpeau", version="0.0.9", author="Keurcien Luu", author_email="keurcien@appchoose.io", description="Efficiently assign users to buckets.", long_description=long_description, lon...
26.5625
57
0.647059
import setuptools with open("README.md", "r") as fh: long_description = fh.read() def dependencies(): import os """ Obtain the dependencies from requirements.txt. """ with open('requirements.txt') as reqs: return reqs.read().splitlines() setuptools.setup( name="choixpeau", ver...
162
0
23
8c35737c2c0e2b1af5a4b10af8ccba507d65c08e
2,531
py
Python
sc2g/sc2g/env/attack/multi_attack.py
kiriphorito/COMP3096---MARL
5e05413b0980d60f4a3f2a17123178c93bb0b763
[ "Apache-2.0" ]
1
2018-07-07T09:02:27.000Z
2018-07-07T09:02:27.000Z
sc2g/sc2g/env/attack/multi_attack.py
kiriphorito/COMP3096---MARL
5e05413b0980d60f4a3f2a17123178c93bb0b763
[ "Apache-2.0" ]
null
null
null
sc2g/sc2g/env/attack/multi_attack.py
kiriphorito/COMP3096---MARL
5e05413b0980d60f4a3f2a17123178c93bb0b763
[ "Apache-2.0" ]
null
null
null
#================================ # RESEARCH GROUP PROJECT [RGP] #================================ # This file is part of the COMP3096 Research Group Project. # System import logging # Gym Imports import gym from gym.spaces import Box, Discrete, Tuple # PySC2 Imports from pysc2.lib.actions import FUNCTIONS, Function...
35.152778
145
0.667325
#================================ # RESEARCH GROUP PROJECT [RGP] #================================ # This file is part of the COMP3096 Research Group Project. # System import logging # Gym Imports import gym from gym.spaces import Box, Discrete, Tuple # PySC2 Imports from pysc2.lib.actions import FUNCTIONS, Function...
1,826
17
125
e041767572c63ac66e2d0df131aae92a56d35ce7
776
py
Python
scripts/initialize_session.py
jspanos/ttrv
45838659a8184a33d02560e265ad7c3ce05e83e2
[ "MIT" ]
248
2019-12-12T08:09:27.000Z
2021-11-14T22:28:01.000Z
scripts/initialize_session.py
jspanos/ttrv
45838659a8184a33d02560e265ad7c3ce05e83e2
[ "MIT" ]
29
2019-12-29T20:43:25.000Z
2021-05-14T07:06:55.000Z
scripts/initialize_session.py
jspanos/ttrv
45838659a8184a33d02560e265ad7c3ce05e83e2
[ "MIT" ]
30
2020-03-05T12:59:59.000Z
2021-08-08T07:02:53.000Z
""" Initialize an authenticated instance of PRAW to interact with. $ python -i initialize_session.py """ from ttrv.docs import AGENT from ttrv.packages import praw from ttrv.content import RequestHeaderRateLimiter from ttrv.config import Config config = Config() config.load_refresh_token() reddit = praw.Reddit( ...
25.032258
62
0.771907
""" Initialize an authenticated instance of PRAW to interact with. $ python -i initialize_session.py """ from ttrv.docs import AGENT from ttrv.packages import praw from ttrv.content import RequestHeaderRateLimiter from ttrv.config import Config config = Config() config.load_refresh_token() reddit = praw.Reddit( ...
0
0
0
ce24a308eade4585492f2aa251d512f761a3c6c0
963
py
Python
examples/plot_skewt.py
zssherman/ACT
db87008aa6649d3d21b79ae97ea0f11d7f1f1935
[ "BSD-3-Clause" ]
62
2020-01-13T19:48:49.000Z
2022-03-22T07:56:37.000Z
examples/plot_skewt.py
zssherman/ACT
db87008aa6649d3d21b79ae97ea0f11d7f1f1935
[ "BSD-3-Clause" ]
215
2020-01-07T20:17:11.000Z
2022-03-31T18:49:57.000Z
examples/plot_skewt.py
zssherman/ACT
db87008aa6649d3d21b79ae97ea0f11d7f1f1935
[ "BSD-3-Clause" ]
16
2020-01-13T21:25:55.000Z
2022-03-26T18:01:29.000Z
""" Example on how to plot a Skew-T plot of a sounding -------------------------------------------------- This example shows how to make a Skew-T plot from a sounding and calculate stability indicies. METPy needs to be installed in order to run this example """ import act from matplotlib import pyplot as plt try:...
24.075
69
0.650052
""" Example on how to plot a Skew-T plot of a sounding -------------------------------------------------- This example shows how to make a Skew-T plot from a sounding and calculate stability indicies. METPy needs to be installed in order to run this example """ import act from matplotlib import pyplot as plt try:...
0
0
0
bbfa359d168f09d85503210267ca9eeee11d12a2
1,555
py
Python
geneClassification/predotarOutput.py
jsharbrough/CyMIRA_gene_classification
8c2766b970a2441dae26c35fefa28319f7aa96ef
[ "MIT" ]
null
null
null
geneClassification/predotarOutput.py
jsharbrough/CyMIRA_gene_classification
8c2766b970a2441dae26c35fefa28319f7aa96ef
[ "MIT" ]
null
null
null
geneClassification/predotarOutput.py
jsharbrough/CyMIRA_gene_classification
8c2766b970a2441dae26c35fefa28319f7aa96ef
[ "MIT" ]
null
null
null
import sys predotarOutput(sys.argv[1],sys.argv[2])
35.340909
87
0.470096
import sys def predotarOutput(predotar,fasta): infile = open(fasta,'r') geneList = [] for line in infile: if line[0] == '>': realLine = line while realLine[-1] == '\t' or realLine[-1] == '\n' or realLine[-1] == '\r': realLine = realLine[0:-1] lineS...
1,481
0
22
1651ce50f2518d0d6646b45b02486f4b9c277ef0
2,634
py
Python
preprocess_reddit_nov.py
sara-02/TiDeH
1c5e58bf1b64128a6d2d538dcc71abac98c4c358
[ "MIT" ]
1
2019-09-19T17:56:54.000Z
2019-09-19T17:56:54.000Z
preprocess_reddit_nov.py
sara-02/TiDeH
1c5e58bf1b64128a6d2d538dcc71abac98c4c358
[ "MIT" ]
null
null
null
preprocess_reddit_nov.py
sara-02/TiDeH
1c5e58bf1b64128a6d2d538dcc71abac98c4c358
[ "MIT" ]
null
null
null
""" Author: Sarah Masud Copyright (c): Sarah Masud """ import json import numpy as np from datetime import datetime, timedelta import os import sys main_dir = os.path.join("data", "reddit_data") with open(os.path.join(main_dir, "selected_discussion_nov.jsonlist"), "r") as f: data = f.readlines() n = len...
33.341772
77
0.628702
""" Author: Sarah Masud Copyright (c): Sarah Masud """ import json import numpy as np from datetime import datetime, timedelta import os import sys main_dir = os.path.join("data", "reddit_data") with open(os.path.join(main_dir, "selected_discussion_nov.jsonlist"), "r") as f: data = f.readlines() n = len...
0
0
0
0502816af4a4b97daf2785ad8619224dca136413
1,538
py
Python
diventi/products/migrations/0025_auto_20191006_1746.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
2
2019-06-27T16:00:17.000Z
2020-08-14T07:46:05.000Z
diventi/products/migrations/0025_auto_20191006_1746.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
26
2020-02-15T22:39:35.000Z
2022-02-19T21:09:01.000Z
diventi/products/migrations/0025_auto_20191006_1746.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
1
2021-11-12T22:30:15.000Z
2021-11-12T22:30:15.000Z
# Generated by Django 2.2.4 on 2019-10-06 15:46 from django.db import migrations, models
34.954545
113
0.616385
# Generated by Django 2.2.4 on 2019-10-06 15:46 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('products', '0024_auto_20190813_0943'), ] operations = [ migrations.AlterField( model_name='product', name='courtesy_...
0
1,424
23
fc6ed3dfe2f754e8db5400b7ba3bb37104a2a85b
926
py
Python
ibslib/io/extract.py
songsiwei/Ogre_r_sv
b31dc64133f082ae395196ebedf41c8cc825ebfd
[ "BSD-3-Clause" ]
null
null
null
ibslib/io/extract.py
songsiwei/Ogre_r_sv
b31dc64133f082ae395196ebedf41c8cc825ebfd
[ "BSD-3-Clause" ]
null
null
null
ibslib/io/extract.py
songsiwei/Ogre_r_sv
b31dc64133f082ae395196ebedf41c8cc825ebfd
[ "BSD-3-Clause" ]
null
null
null
from ibslib.io import aims_extractor __author__='Manny Bier' def extract(struct_dir, extractor="aims", extractor_kwargs={}): """ Purpose is to extract information from a specific direcoty format. For example, extract FHI-aims calculation directories to a Structure json file. ...
23.15
93
0.665227
from ibslib.io import aims_extractor __author__='Manny Bier' def extract(struct_dir, extractor="aims", extractor_kwargs={}): """ Purpose is to extract information from a specific direcoty format. For example, extract FHI-aims calculation directories to a Structure json file. ...
0
0
0
ca55b1b738ba3f6e5e18c6b4b70c0664ddb85b58
340
py
Python
TelegramEDT/EDTscoped_session.py
flifloo/TelegramEDT
299dc340af31c4f7e6c601f133a5c10d6396225f
[ "MIT" ]
1
2019-09-19T08:06:13.000Z
2019-09-19T08:06:13.000Z
TelegramEDT/EDTscoped_session.py
flifloo/TelegramEDT
299dc340af31c4f7e6c601f133a5c10d6396225f
[ "MIT" ]
11
2019-09-20T10:27:30.000Z
2021-09-08T01:19:58.000Z
TelegramEDT/EDTscoped_session.py
flifloo/TelegramEDT
299dc340af31c4f7e6c601f133a5c10d6396225f
[ "MIT" ]
null
null
null
from sqlalchemy.orm import scoped_session as ss
26.153846
60
0.726471
from sqlalchemy.orm import scoped_session as ss class scoped_session: def __init__(self, session_factory, scopefunc=None): self.scoped_session = ss(session_factory, scopefunc) def __enter__(self): return self.scoped_session def __exit__(self, exc_type, exc_val, exc_tb): self.scop...
188
0
103
22ea2593ed65592652a2e72b69383a67c861d53c
356
py
Python
lx145.py
ggznmg/spider
04cc769f35ee14e56f05dd10d8d8ee6cacd574ce
[ "Apache-2.0" ]
null
null
null
lx145.py
ggznmg/spider
04cc769f35ee14e56f05dd10d8d8ee6cacd574ce
[ "Apache-2.0" ]
null
null
null
lx145.py
ggznmg/spider
04cc769f35ee14e56f05dd10d8d8ee6cacd574ce
[ "Apache-2.0" ]
null
null
null
import re typ='Extra stings Hello 2134567 World_This is a Regex Demo Extra stings' result = re.search('(Extra) stings Hello 2134567 (.*) is a Regex Demo Extra (.*)',typ ,re.S) print(result.group(1,2,3)) # type="submit" id="su" value="百度一下" class="bg s_btn"></span><span class="tools"><span id="mHolder"><div id="mCon"><...
59.333333
152
0.685393
import re typ='Extra stings Hello 2134567 World_This is a Regex Demo Extra stings' result = re.search('(Extra) stings Hello 2134567 (.*) is a Regex Demo Extra (.*)',typ ,re.S) print(result.group(1,2,3)) # type="submit" id="su" value="百度一下" class="bg s_btn"></span><span class="tools"><span id="mHolder"><div id="mCon"><...
0
0
0
c79999ff35a192bcfb8a5e9dacb937e75a79e418
1,030
py
Python
.idea/VirtualEnvironment/Lib/site-packages/hstest/dynamic/input/input_handler.py
Vladpetr/NewsPortal
cd4127fbc09d9c8f5e65c8ae699856c6d380a320
[ "Apache-2.0" ]
null
null
null
.idea/VirtualEnvironment/Lib/site-packages/hstest/dynamic/input/input_handler.py
Vladpetr/NewsPortal
cd4127fbc09d9c8f5e65c8ae699856c6d380a320
[ "Apache-2.0" ]
5
2021-04-08T22:02:15.000Z
2022-02-10T14:53:45.000Z
.idea/VirtualEnvironment/Lib/site-packages/hstest/dynamic/input/input_handler.py
Vladpetr/NewsPortal
cd4127fbc09d9c8f5e65c8ae699856c6d380a320
[ "Apache-2.0" ]
null
null
null
import io import sys from typing import List from hstest.dynamic.input.dynamic_input_func import DynamicTestFunction, DynamicInputFunction from hstest.dynamic.input.input_mock import InputMock
25.121951
93
0.68835
import io import sys from typing import List from hstest.dynamic.input.dynamic_input_func import DynamicTestFunction, DynamicInputFunction from hstest.dynamic.input.input_mock import InputMock class InputHandler: real_in: io.TextIOWrapper = sys.stdin mock_in: InputMock = InputMock() @staticmethod de...
170
642
23
11fca35b31758384c9ae077df6a74e7efd6e35cd
536
py
Python
ex_starmap.py
xuqinghan/learn-RxPY
92735036ead3bd8874010546a17564a94d596be1
[ "MIT" ]
null
null
null
ex_starmap.py
xuqinghan/learn-RxPY
92735036ead3bd8874010546a17564a94d596be1
[ "MIT" ]
null
null
null
ex_starmap.py
xuqinghan/learn-RxPY
92735036ead3bd8874010546a17564a94d596be1
[ "MIT" ]
null
null
null
import rx from rx import operators as ops import operator def demo_starmap(): '''tuple unpacking''' a = rx.of(1, 2, 3, 4) b = rx.of(2, 2, 4, 4) a.pipe( ops.zip(b), ops.starmap(operator.mul) ).subscribe(print) if __name__ == '__main__': #demo_zip() demo_starmap()
19.142857
63
0.550373
import rx from rx import operators as ops import operator def demo_zip(): a = rx.of(1, 2, 3, 4) b = rx.of(2, 2, 4, 4) a.pipe( ops.zip(b), # returns a tuple with the items of a and b ops.map(lambda z: operator.mul(z[0], z[1])) ).subscribe(print) def demo_starmap(): '''tuple unpack...
199
0
23
52600e1523588ffc964ef10450c34f10c615eb26
1,543
py
Python
tests/integration/custom_resources/ec2/test_nat_gateway.py
CloudWanderer-io/CloudWanderer
bad89c771cebe931790347afb49aa3bd046f3467
[ "MIT" ]
16
2020-12-22T17:01:48.000Z
2022-01-21T10:37:14.000Z
tests/integration/custom_resources/ec2/test_nat_gateway.py
CloudWanderer-io/CloudWanderer
bad89c771cebe931790347afb49aa3bd046f3467
[ "MIT" ]
110
2020-12-07T21:55:48.000Z
2022-01-11T12:10:49.000Z
tests/integration/custom_resources/ec2/test_nat_gateway.py
CloudWanderer-io/CloudWanderer
bad89c771cebe931790347afb49aa3bd046f3467
[ "MIT" ]
2
2021-12-23T21:09:23.000Z
2021-12-23T22:25:24.000Z
import unittest from cloudwanderer import URN from ..helpers import CloudWandererCalls, ExpectedCall, MultipleResourceScenario, NoMotoMock, SingleResourceScenario
32.829787
119
0.605962
import unittest from cloudwanderer import URN from ..helpers import CloudWandererCalls, ExpectedCall, MultipleResourceScenario, NoMotoMock, SingleResourceScenario class TestNatGateways(NoMotoMock, unittest.TestCase): nat_gateway_payload = { "CreateTime": "2021-04-13T09:39:49.000Z", "NatGatewayA...
0
1,354
23
2aa0db54d2d69fc692c1dbb0b9145923a218fff6
13,764
py
Python
app.py
tmt-uet/image_captioning
7b2d4ad565f9276e6112009bbd263378c9a94d1a
[ "MIT" ]
null
null
null
app.py
tmt-uet/image_captioning
7b2d4ad565f9276e6112009bbd263378c9a94d1a
[ "MIT" ]
null
null
null
app.py
tmt-uet/image_captioning
7b2d4ad565f9276e6112009bbd263378c9a94d1a
[ "MIT" ]
null
null
null
import os from flask import Flask, json, Response, request, render_template, send_file, jsonify, send_from_directory from werkzeug.utils import secure_filename import requests from flask_cors import CORS from datetime import datetime import torch import torch.nn.functional as F import numpy as np import json import to...
34.496241
119
0.633319
import os from flask import Flask, json, Response, request, render_template, send_file, jsonify, send_from_directory from werkzeug.utils import secure_filename import requests from flask_cors import CORS from datetime import datetime import torch import torch.nn.functional as F import numpy as np import json import to...
6,320
0
250
31a03099b587aeeeb96296b79c441b86f6b41cd2
348
py
Python
bot/handlers/users/start.py
YoshlikMedia/STT-uzbek-bot
fec5d6a7bec4135aeb35a86970193654637194f5
[ "MIT" ]
null
null
null
bot/handlers/users/start.py
YoshlikMedia/STT-uzbek-bot
fec5d6a7bec4135aeb35a86970193654637194f5
[ "MIT" ]
null
null
null
bot/handlers/users/start.py
YoshlikMedia/STT-uzbek-bot
fec5d6a7bec4135aeb35a86970193654637194f5
[ "MIT" ]
null
null
null
from aiogram import types from aiogram.dispatcher.filters.builtin import CommandStart from loader import dp @dp.message_handler(CommandStart())
31.636364
86
0.735632
from aiogram import types from aiogram.dispatcher.filters.builtin import CommandStart from loader import dp @dp.message_handler(CommandStart()) async def bot_start(message: types.Message): await message.answer(f"<b>Assalom Alaykum, {message.from_user.full_name}!\n\n</b>" f"Botdan foydala...
179
0
22
64884f131266d13ea970b5918aa5dab206b2d99c
1,761
py
Python
test/displays_test.py
theJollySin/pytextgame
62ce5525934b90a0b3ad2a2188315220a05dd1f8
[ "MIT" ]
1
2015-09-11T19:43:29.000Z
2015-09-11T19:43:29.000Z
test/displays_test.py
theJollySin/pytextgame
62ce5525934b90a0b3ad2a2188315220a05dd1f8
[ "MIT" ]
25
2015-09-10T16:18:09.000Z
2015-10-03T22:19:44.000Z
test/displays_test.py
theJollySin/pytextgame
62ce5525934b90a0b3ad2a2188315220a05dd1f8
[ "MIT" ]
1
2019-11-22T10:00:59.000Z
2019-11-22T10:00:59.000Z
import unittest from pytextgame.colors import * from pytextgame.displays import Displays from pytextgame.geometry import * from pytextgame.window import Window if __name__ == '__main__': unittest.main()
33.226415
86
0.634299
import unittest from pytextgame.colors import * from pytextgame.displays import Displays from pytextgame.geometry import * from pytextgame.window import Window class MockWindow(Window): def __init__(ui, stdscr, game, rect, border=WHITE): Window.__init__(ui, stdscr, game, rect, border) class TestDispla...
1,293
21
235
240d4c477fc5a10a913e0fc617380114eb2bd239
1,281
py
Python
test_flying_shapes.py
brain-research/flying-shapes
e9a63576c92f3e1f7ae4933596977ded04b962ad
[ "Apache-2.0" ]
3
2018-06-24T04:05:08.000Z
2020-07-12T23:37:05.000Z
test_flying_shapes.py
brain-research/flying-shapes
e9a63576c92f3e1f7ae4933596977ded04b962ad
[ "Apache-2.0" ]
null
null
null
test_flying_shapes.py
brain-research/flying-shapes
e9a63576c92f3e1f7ae4933596977ded04b962ad
[ "Apache-2.0" ]
3
2018-06-24T04:05:09.000Z
2020-07-12T23:37:09.000Z
# Copyright 2018 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 # https://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, soft...
32.846154
74
0.741608
# Copyright 2018 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 # https://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, soft...
0
0
0
899b10506a0dbb47e4207752eb3dc70380a4e900
682
py
Python
sandbox/python/parse_esc.py
rboman/progs
c60b4e0487d01ccd007bcba79d1548ebe1685655
[ "Apache-2.0" ]
2
2021-12-12T13:26:06.000Z
2022-03-03T16:14:53.000Z
sandbox/python/parse_esc.py
rboman/progs
c60b4e0487d01ccd007bcba79d1548ebe1685655
[ "Apache-2.0" ]
5
2019-03-01T07:08:46.000Z
2019-04-28T07:32:42.000Z
sandbox/python/parse_esc.py
rboman/progs
c60b4e0487d01ccd007bcba79d1548ebe1685655
[ "Apache-2.0" ]
2
2017-12-13T13:13:52.000Z
2019-03-13T20:08:15.000Z
#! /usr/bin/env python3 # -*- coding: utf-8 -*- red='\033[31m' reset='\033[0m' s = "[€€€éä] nice " + red + "colors" + reset + '!\n' print(s) #import tempfile #fd, path = tempfile.mkstemp() #print fd, path """ tmpf = os.fdopen(fd, 'w') try: with as tmp: # do stuff with temp file tmp.write('st...
15.155556
54
0.582111
#! /usr/bin/env python3 # -*- coding: utf-8 -*- red='\033[31m' reset='\033[0m' s = "[€€€éä] nice " + red + "colors" + reset + '!\n' print(s) #import tempfile #fd, path = tempfile.mkstemp() #print fd, path """ tmpf = os.fdopen(fd, 'w') try: with as tmp: # do stuff with temp file tmp.write('st...
0
0
0
5daaa6240a8ebcdb6a4a6613ecb521171d92d71a
5,083
py
Python
gmprocess/subcommands/compute_waveform_metrics.py
dchurchwell-usgs/groundmotion-processing
57aecdde36d98b5f838b819dc281a47a84351256
[ "Unlicense" ]
null
null
null
gmprocess/subcommands/compute_waveform_metrics.py
dchurchwell-usgs/groundmotion-processing
57aecdde36d98b5f838b819dc281a47a84351256
[ "Unlicense" ]
null
null
null
gmprocess/subcommands/compute_waveform_metrics.py
dchurchwell-usgs/groundmotion-processing
57aecdde36d98b5f838b819dc281a47a84351256
[ "Unlicense" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- import os import logging from gmprocess.subcommands.lazy_loader import LazyLoader arg_dicts = LazyLoader( 'arg_dicts', globals(), 'gmprocess.subcommands.arg_dicts') base = LazyLoader('base', globals(), 'gmprocess.subcommands.base') distributed = LazyLoader('distribute...
37.10219
72
0.54397
#!/usr/bin/env python # -*- coding: utf-8 -*- import os import logging from gmprocess.subcommands.lazy_loader import LazyLoader arg_dicts = LazyLoader( 'arg_dicts', globals(), 'gmprocess.subcommands.arg_dicts') base = LazyLoader('base', globals(), 'gmprocess.subcommands.base') distributed = LazyLoader('distribute...
3,604
0
27
b9c6523eb62600db7ffe2af7d6ec31883b7403b8
25,068
py
Python
src/main.py
mkarmann/conway-reversed
a3ae10dd5768affb9caf193a246395ee0fb2bc6f
[ "MIT" ]
null
null
null
src/main.py
mkarmann/conway-reversed
a3ae10dd5768affb9caf193a246395ee0fb2bc6f
[ "MIT" ]
null
null
null
src/main.py
mkarmann/conway-reversed
a3ae10dd5768affb9caf193a246395ee0fb2bc6f
[ "MIT" ]
null
null
null
import pandas as pd import math import cv2 import numpy as np import matplotlib import random from bestguess.bestguess import BestGuessModule, MODEL_CHANNELS from stochastic_optimizer import BestChangeLayer # matplotlib.use('agg') import matplotlib.pyplot as plt import time import torch import torch.nn as nn import ...
38.625578
166
0.593346
import pandas as pd import math import cv2 import numpy as np import matplotlib import random from bestguess.bestguess import BestGuessModule, MODEL_CHANNELS from stochastic_optimizer import BestChangeLayer # matplotlib.use('agg') import matplotlib.pyplot as plt import time import torch import torch.nn as nn import ...
23,236
16
759
e04b27f085886c6943117e834186a94704ba6132
1,553
py
Python
src/compat_func.py
rangell/icff
a24b7b289219caef26d24e8cdbf37e24de49447a
[ "MIT" ]
null
null
null
src/compat_func.py
rangell/icff
a24b7b289219caef26d24e8cdbf37e24de49447a
[ "MIT" ]
null
null
null
src/compat_func.py
rangell/icff
a24b7b289219caef26d24e8cdbf37e24de49447a
[ "MIT" ]
null
null
null
import copy import numpy as np from sparse_dot_mkl import dot_product_mkl from utils import MIN_FLOAT from IPython import embed #def raw_overlap(node, constraint, num_points):
34.511111
74
0.721185
import copy import numpy as np from sparse_dot_mkl import dot_product_mkl from utils import MIN_FLOAT from IPython import embed #def raw_overlap(node, constraint, num_points): def raw_overlap(raw_reps, stacked_constraints, num_points): extreme_raw_reps = copy.deepcopy(raw_reps).astype(float) extreme_raw_re...
1,326
0
45
de704cd31fbc4b18a4d1b37cb1147d6cf312e8b6
9,735
py
Python
the_script.py
IntenseToxicity/Imperial-to-metric-conversion
393d99c9ede1362f69c338c5d73a3f83df5d0f58
[ "MIT" ]
null
null
null
the_script.py
IntenseToxicity/Imperial-to-metric-conversion
393d99c9ede1362f69c338c5d73a3f83df5d0f58
[ "MIT" ]
null
null
null
the_script.py
IntenseToxicity/Imperial-to-metric-conversion
393d99c9ede1362f69c338c5d73a3f83df5d0f58
[ "MIT" ]
null
null
null
""" Name: InsanityNet Last Date Edited: 18-Feb-2022 Description: Imperial and Metric conversion. Feet and Inches to Meters OR Meters to Feet and Inches Requirements: fractions.Fraction function built into Python3 Known Issues: 1. Negative Feet and Positive Inches. I can't be bothered to fix it at 11 ...
32.667785
117
0.564355
""" Name: InsanityNet Last Date Edited: 18-Feb-2022 Description: Imperial and Metric conversion. Feet and Inches to Meters OR Meters to Feet and Inches Requirements: fractions.Fraction function built into Python3 Known Issues: 1. Negative Feet and Positive Inches. I can't be bothered to fix it at 11 ...
6,429
0
22
7224812f862ee6febf65f98bfc55b27264c7263e
1,677
py
Python
tack/commands/HelpCommand.py
mer1dian/anubis_py
cc34364d7da4591758dff0bf72db4a9b3063e843
[ "Unlicense" ]
3
2015-07-07T09:11:13.000Z
2018-05-29T22:36:12.000Z
tack/commands/HelpCommand.py
mer1dian/anubis_py
cc34364d7da4591758dff0bf72db4a9b3063e843
[ "Unlicense" ]
null
null
null
tack/commands/HelpCommand.py
mer1dian/anubis_py
cc34364d7da4591758dff0bf72db4a9b3063e843
[ "Unlicense" ]
2
2015-07-07T09:11:15.000Z
2016-05-28T16:54:06.000Z
# Authors: # Trevor Perrin # Moxie Marlinspike # # See the LICENSE file for legal information regarding use of this file. import sys from tack.version import __version__ from tack.commands.Command import Command from tack.commands.GenerateKeyCommand import GenerateKeyCommand from tack.commands.SignCommand import ...
28.913793
85
0.68873
# Authors: # Trevor Perrin # Moxie Marlinspike # # See the LICENSE file for legal information regarding use of this file. import sys from tack.version import __version__ from tack.commands.Command import Command from tack.commands.GenerateKeyCommand import GenerateKeyCommand from tack.commands.SignCommand import ...
862
306
23
8be2cd9841d9145cd26261f7dfd950f7433f5eea
789
py
Python
ktane/mvc/message_controller.py
hanzikl/ktane-controller
3116e76cd56f2c4348df99427c52db1c8ea065e9
[ "MIT" ]
null
null
null
ktane/mvc/message_controller.py
hanzikl/ktane-controller
3116e76cd56f2c4348df99427c52db1c8ea065e9
[ "MIT" ]
null
null
null
ktane/mvc/message_controller.py
hanzikl/ktane-controller
3116e76cd56f2c4348df99427c52db1c8ea065e9
[ "MIT" ]
null
null
null
import serial from .serial_mock.serial import Serial as SerialMock from time import sleep DELAY_BETWEEN_MESSAGES = 0.05
26.3
90
0.662864
import serial from .serial_mock.serial import Serial as SerialMock from time import sleep DELAY_BETWEEN_MESSAGES = 0.05 class MessageController: def __init__(self, connection): """ :param connection: serial.Serial """ assert isinstance(connection, serial.Serial) or isinstance(con...
357
287
23
075fdd513c640c9c351a31895ef902f02de9af5a
8,996
py
Python
cosilico/base/distribution.py
cosilico/cosilico
983373139aeaf459271c559a47a6439939ec93a5
[ "MIT" ]
null
null
null
cosilico/base/distribution.py
cosilico/cosilico
983373139aeaf459271c559a47a6439939ec93a5
[ "MIT" ]
null
null
null
cosilico/base/distribution.py
cosilico/cosilico
983373139aeaf459271c559a47a6439939ec93a5
[ "MIT" ]
null
null
null
from collections import Collection import altair as alt import pandas as pd def histogram(x, data, opacity=1., maxbins=30, color=None, padding=0,): """Display a histogram. Parameters ---------- x : str value to be binned data : pandas.DataFrame dataframe containing x opacity ...
27.178248
74
0.571699
from collections import Collection import altair as alt import pandas as pd def histogram(x, data, opacity=1., maxbins=30, color=None, padding=0,): """Display a histogram. Parameters ---------- x : str value to be binned data : pandas.DataFrame dataframe containing x opacity ...
0
0
0
7257b7a7a0223a998f334158bbdfce34ad0a62db
897
py
Python
indra/databases/ido_client.py
johnbachman/belpy
1f8052c294fa05b3cd471c544b725f6f0adf9869
[ "BSD-2-Clause" ]
136
2016-02-11T22:06:37.000Z
2022-03-31T17:26:20.000Z
indra/databases/ido_client.py
johnbachman/belpy
1f8052c294fa05b3cd471c544b725f6f0adf9869
[ "BSD-2-Clause" ]
748
2016-02-03T16:27:56.000Z
2022-03-09T14:27:54.000Z
indra/databases/ido_client.py
johnbachman/belpy
1f8052c294fa05b3cd471c544b725f6f0adf9869
[ "BSD-2-Clause" ]
56
2015-08-28T14:03:44.000Z
2022-02-04T06:15:55.000Z
"""A client to OWL.""" from typing import Optional from indra.databases.owl_client import OwlClient _client = OwlClient('ido') def get_ido_name_from_ido_id(ido_id: str) -> Optional[str]: """Return the HP name corresponding to the given HP ID. Parameters ---------- ido_id : The IDO identifi...
22.425
68
0.651059
"""A client to OWL.""" from typing import Optional from indra.databases.owl_client import OwlClient _client = OwlClient('ido') def get_ido_name_from_ido_id(ido_id: str) -> Optional[str]: """Return the HP name corresponding to the given HP ID. Parameters ---------- ido_id : The IDO identifi...
0
0
0
7d528b1a9dad3adfd057fcc208a09913c189b15a
1,007
py
Python
Python/seven_kyu/max_diff.py
Brokenshire/codewars-projects
db9cd09618b8a7085b0d53ad76f73f9e249b9396
[ "Apache-2.0" ]
1
2019-12-20T04:09:56.000Z
2019-12-20T04:09:56.000Z
Python/seven_kyu/max_diff.py
Brokenshire/codewars-projects
db9cd09618b8a7085b0d53ad76f73f9e249b9396
[ "Apache-2.0" ]
null
null
null
Python/seven_kyu/max_diff.py
Brokenshire/codewars-projects
db9cd09618b8a7085b0d53ad76f73f9e249b9396
[ "Apache-2.0" ]
null
null
null
# Python solution for 'max diff - easy' codewars question. # Level: 7 kyu # Tags: FUNDAMENTALS, MATHEMATICS, ALGORITHMS, NUMBERS, COLLECTIONS, LISTS, DATA STRUCTURES, AND ARRAYS. # Author: Jack Brokenshire # Date: 16/07/2020 import unittest def max_diff(lst): """ Finds the difference beteween the largest and...
29.617647
117
0.650447
# Python solution for 'max diff - easy' codewars question. # Level: 7 kyu # Tags: FUNDAMENTALS, MATHEMATICS, ALGORITHMS, NUMBERS, COLLECTIONS, LISTS, DATA STRUCTURES, AND ARRAYS. # Author: Jack Brokenshire # Date: 16/07/2020 import unittest def max_diff(lst): """ Finds the difference beteween the largest and...
278
0
27
340edcacb078a82926d5528e093ea31cb4090ca5
4,391
py
Python
libs/clientQt.py
SilvioGiancola/TCPClient
aa6e5c137feeacb61900a848474730c1720d31bd
[ "MIT" ]
1
2021-12-06T10:47:31.000Z
2021-12-06T10:47:31.000Z
libs/clientQt.py
SilvioGiancola/TCPClient
aa6e5c137feeacb61900a848474730c1720d31bd
[ "MIT" ]
1
2020-05-21T01:40:34.000Z
2020-05-21T01:40:34.000Z
libs/clientQt.py
SilvioGiancola/TCPClient
aa6e5c137feeacb61900a848474730c1720d31bd
[ "MIT" ]
null
null
null
from PyQt5.QtCore import QDataStream, QIODevice, QObject, QByteArray, pyqtSignal from PyQt5.QtCore import * from PyQt5.QtWidgets import QApplication, QDialog, QMainWindow, QLineEdit, QPushButton, QVBoxLayout from PyQt5.QtWidgets import * from PyQt5.QtNetwork import QTcpSocket, QAbstractSocket from PyQt5.QtNetwork impor...
32.286765
99
0.628786
from PyQt5.QtCore import QDataStream, QIODevice, QObject, QByteArray, pyqtSignal from PyQt5.QtCore import * from PyQt5.QtWidgets import QApplication, QDialog, QMainWindow, QLineEdit, QPushButton, QVBoxLayout from PyQt5.QtWidgets import * from PyQt5.QtNetwork import QTcpSocket, QAbstractSocket from PyQt5.QtNetwork impor...
3,307
483
22
52d1f7f89d9e7f47ec3399a3efebc70617bff62b
1,462
py
Python
handrecog/src/util/resize_image.py
hengxyz/hand_detection_recognition
317545056886d7b85947f9258c4cc02e98cfd2fe
[ "MIT" ]
null
null
null
handrecog/src/util/resize_image.py
hengxyz/hand_detection_recognition
317545056886d7b85947f9258c4cc02e98cfd2fe
[ "MIT" ]
null
null
null
handrecog/src/util/resize_image.py
hengxyz/hand_detection_recognition
317545056886d7b85947f9258c4cc02e98cfd2fe
[ "MIT" ]
null
null
null
# from __future__ import absolute_import # from __future__ import division from __future__ import print_function import os import glob import numpy as np from PIL import Image import cv2 if __name__ == '__main__': main()
31.782609
80
0.55814
# from __future__ import absolute_import # from __future__ import division from __future__ import print_function import os import glob import numpy as np from PIL import Image import cv2 def main(): data = '/data/zming/GH/manji/2000_labeled_sample_head' output = '/data/zming/GH/manji/2000_labeled_sample_head...
1,211
0
23
e1aa4fd5a0a8efd8ef5ee8b595a5fc3860e6c737
2,686
py
Python
Sentences from Tatoeba/SentenceFinder.py
tomPlus353/Japanese-Web-Scraping
b76cd72ddddaabf7176274032447d7f8d1326aa6
[ "MIT" ]
null
null
null
Sentences from Tatoeba/SentenceFinder.py
tomPlus353/Japanese-Web-Scraping
b76cd72ddddaabf7176274032447d7f8d1326aa6
[ "MIT" ]
null
null
null
Sentences from Tatoeba/SentenceFinder.py
tomPlus353/Japanese-Web-Scraping
b76cd72ddddaabf7176274032447d7f8d1326aa6
[ "MIT" ]
null
null
null
import csv, os os.chdir('C:\\Users\\tomas\\Desktop\\Multi-Side Flashcard Project\\Sentences from Tatoeba\\') csv_handle = open("jpn_sentences.tsv",'r') csv_read = csv.reader(csv_handle, delimiter="\t") csvList = list(csv_read) #print(len(csvList)) #print(f"Row 1, column 3: {csvList[0][2]}",f"Row 1, column 1: {csv...
38.371429
131
0.629188
import csv, os os.chdir('C:\\Users\\tomas\\Desktop\\Multi-Side Flashcard Project\\Sentences from Tatoeba\\') csv_handle = open("jpn_sentences.tsv",'r') csv_read = csv.reader(csv_handle, delimiter="\t") csvList = list(csv_read) #print(len(csvList)) #print(f"Row 1, column 3: {csvList[0][2]}",f"Row 1, column 1: {csv...
0
0
0
9b8939c98e297f7bb704484058d5a0d9967f3373
1,731
py
Python
models/ssd/links/normalize.py
kumasento/gradient-scaling
0ca435433b9953e33656173c4d60ebd61c5c5e87
[ "MIT" ]
7
2020-08-12T12:04:28.000Z
2021-11-22T15:56:08.000Z
models/ssd/links/normalize.py
kumasento/gradient-scaling
0ca435433b9953e33656173c4d60ebd61c5c5e87
[ "MIT" ]
1
2021-10-07T08:37:39.000Z
2021-10-08T02:41:39.000Z
models/ssd/links/normalize.py
kumasento/gradient-scaling
0ca435433b9953e33656173c4d60ebd61c5c5e87
[ "MIT" ]
null
null
null
import numpy as np import chainer import chainer.functions as F from chainer import initializers from chainer import variable class Normalize(chainer.Link): """Learnable L2 normalization [#]_. This link normalizes input along the channel axis and scales it. The scale factors are trained channel-wise. ...
33.288462
78
0.620451
import numpy as np import chainer import chainer.functions as F from chainer import initializers from chainer import variable class Normalize(chainer.Link): """Learnable L2 normalization [#]_. This link normalizes input along the channel axis and scales it. The scale factors are trained channel-wise. ...
403
0
27
f112c3c7f3993e3a6456b203d747ff3176963dc6
1,366
py
Python
webroot/python/goldXp.py
peemoRoyal/dotadude
a90faee23a6ce7755d0c7266f1dcdb46816a8d6d
[ "MIT" ]
null
null
null
webroot/python/goldXp.py
peemoRoyal/dotadude
a90faee23a6ce7755d0c7266f1dcdb46816a8d6d
[ "MIT" ]
null
null
null
webroot/python/goldXp.py
peemoRoyal/dotadude
a90faee23a6ce7755d0c7266f1dcdb46816a8d6d
[ "MIT" ]
null
null
null
#!/usr/bin/python2.4 # Small script to show PostgreSQL and Pyscopg together # import json import psycopg2 import sys match_id = sys.argv[1] match_id = 2125002095 conn = psycopg2.connect("dbname='postgres' user='petergleixner' host='localhost' password=''") cursor = conn.cursor() cursor.execute('''SELECT replay_file F...
28.458333
150
0.662518
#!/usr/bin/python2.4 # Small script to show PostgreSQL and Pyscopg together # import json import psycopg2 import sys match_id = sys.argv[1] match_id = 2125002095 conn = psycopg2.connect("dbname='postgres' user='petergleixner' host='localhost' password=''") cursor = conn.cursor() cursor.execute('''SELECT replay_file F...
0
0
0
4da811dd32ab7ed910bbf58a7870855477f9d2c5
16,050
py
Python
hermione/module_templates/__NOT_IMPLEMENTED_BASE__/src/ml/analysis/hypothesis_autopilot.py
karenstemartins/hermione
3d411ea7a8a8e1929e3b7f0fb0a0d238d25696d0
[ "Apache-2.0" ]
183
2020-06-03T22:43:14.000Z
2022-03-17T22:39:07.000Z
hermione/module_templates/__NOT_IMPLEMENTED_BASE__/src/ml/analysis/hypothesis_autopilot.py
karenstemartins/hermione
3d411ea7a8a8e1929e3b7f0fb0a0d238d25696d0
[ "Apache-2.0" ]
31
2020-06-03T22:55:18.000Z
2022-03-27T20:06:17.000Z
hermione/module_templates/__NOT_IMPLEMENTED_BASE__/src/ml/analysis/hypothesis_autopilot.py
karenstemartins/hermione
3d411ea7a8a8e1929e3b7f0fb0a0d238d25696d0
[ "Apache-2.0" ]
43
2020-06-03T22:45:03.000Z
2021-12-29T19:43:54.000Z
import pandas as pd import numpy as np import operator import warnings from ml.analysis.hypothesis_testing import HypothesisTester class HTestAutoPilot: """ Chooses what is the most adequate hypothesis test for a given dataset, based on its datatypes and the assumptions of each test """ @staticme...
38.214286
84
0.511402
import pandas as pd import numpy as np import operator import warnings from ml.analysis.hypothesis_testing import HypothesisTester class HTestAutoPilot: """ Chooses what is the most adequate hypothesis test for a given dataset, based on its datatypes and the assumptions of each test """ @staticme...
0
0
0
6b21fb3112526e3c6d130cc689c8ac09c81f6b73
1,032
py
Python
url_shortener/database/migrations/versions/0001_initial_migration.py
tiesjan/url-shortener
395ffc7b88dfe97c88914e8c4047690185b54ea7
[ "BSD-3-Clause" ]
null
null
null
url_shortener/database/migrations/versions/0001_initial_migration.py
tiesjan/url-shortener
395ffc7b88dfe97c88914e8c4047690185b54ea7
[ "BSD-3-Clause" ]
null
null
null
url_shortener/database/migrations/versions/0001_initial_migration.py
tiesjan/url-shortener
395ffc7b88dfe97c88914e8c4047690185b54ea7
[ "BSD-3-Clause" ]
null
null
null
""" Initial migration Revision ID: 4defdf508e78 Revises: (none) Create Date: 2021-10-19 20:14:59.350979 """ from alembic import op import sqlalchemy as sa from url_shortener.database.functions import utc_now # revision identifiers, used by Alembic. revision = '4defdf508e78' down_revision = None branch_labels = Non...
24.571429
92
0.672481
""" Initial migration Revision ID: 4defdf508e78 Revises: (none) Create Date: 2021-10-19 20:14:59.350979 """ from alembic import op import sqlalchemy as sa from url_shortener.database.functions import utc_now # revision identifiers, used by Alembic. revision = '4defdf508e78' down_revision = None branch_labels = Non...
644
0
46
9e6783c49f88b098a9e898f6e0d5fe94e9ffbd08
755
py
Python
SplitterFile.py
abrahamalbert18/Image-Annotation-Application
bd5f0f7adffea2d749de568a41518986744d6846
[ "MIT" ]
null
null
null
SplitterFile.py
abrahamalbert18/Image-Annotation-Application
bd5f0f7adffea2d749de568a41518986744d6846
[ "MIT" ]
null
null
null
SplitterFile.py
abrahamalbert18/Image-Annotation-Application
bd5f0f7adffea2d749de568a41518986744d6846
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Mon Dec 17 16:25:07 2018 @author: Albert """ import pandas as pd import numpy as np df = pd.read_csv("./PreprocessedDataFiles/MergedPreprocessedDataFiles/MergedPreprocessedDrinkingDataLabels v2.csv") # originalDF = df df['index'] = range(0, len(df)) splitRatio = [0.6,0.2,0.2] ...
29.038462
115
0.684768
# -*- coding: utf-8 -*- """ Created on Mon Dec 17 16:25:07 2018 @author: Albert """ import pandas as pd import numpy as np df = pd.read_csv("./PreprocessedDataFiles/MergedPreprocessedDataFiles/MergedPreprocessedDrinkingDataLabels v2.csv") # originalDF = df df['index'] = range(0, len(df)) splitRatio = [0.6,0.2,0.2] ...
253
0
23
c525cf86b9d588c851934b1a4b781869fe7ba93d
11,363
py
Python
doubles/allowance.py
fakeNetflix/uber-repo-doubles
15e68dcf98f709b19a581915fa6af5ef49ebdd8a
[ "MIT" ]
150
2015-01-06T11:40:39.000Z
2022-01-10T10:29:59.000Z
doubles/allowance.py
fakeNetflix/uber-repo-doubles
15e68dcf98f709b19a581915fa6af5ef49ebdd8a
[ "MIT" ]
78
2015-01-13T21:04:13.000Z
2022-02-11T13:22:56.000Z
doubles/allowance.py
fakeNetflix/uber-repo-doubles
15e68dcf98f709b19a581915fa6af5ef49ebdd8a
[ "MIT" ]
22
2015-03-11T18:33:33.000Z
2022-01-13T01:54:19.000Z
import functools import inspect import six from doubles.call_count_accumulator import CallCountAccumulator from doubles.exceptions import MockExpectationError, VerifyingBuiltinDoubleArgumentError import doubles.lifecycle from doubles.verification import verify_arguments _any = object() class Allowance(object):...
31.131507
100
0.627299
import functools import inspect import six from doubles.call_count_accumulator import CallCountAccumulator from doubles.exceptions import MockExpectationError, VerifyingBuiltinDoubleArgumentError import doubles.lifecycle from doubles.verification import verify_arguments _any = object() def _get_future(): try: ...
1,113
0
148
5c6aa066ee7e069fb7f65b98241148db5b7435ae
2,857
py
Python
network/InceptionModule.py
cersar/BasicNetwork
119ebb745e67a9b74b72cc4635fea360db0ed43f
[ "MIT" ]
4
2019-01-02T07:54:51.000Z
2019-01-04T06:11:15.000Z
network/InceptionModule.py
cersar/BasicNetwork
119ebb745e67a9b74b72cc4635fea360db0ed43f
[ "MIT" ]
null
null
null
network/InceptionModule.py
cersar/BasicNetwork
119ebb745e67a9b74b72cc4635fea360db0ed43f
[ "MIT" ]
null
null
null
import tensorflow as tf from network.ConvBlock import conv2d_bn
51.945455
104
0.644732
import tensorflow as tf from network.ConvBlock import conv2d_bn def InceptionModule_V1(input,conv1_n,conv3_reduce,conv3_n,conv5_reduce,conv5_n,pool_proj): conv1 = tf.layers.conv2d(input, conv1_n, (1, 1), (1, 1), padding='same', activation=tf.nn.relu, kernel_initializer=tf.contrib.laye...
2,722
0
69
167eec23d426971e1b913e6c330bb3abd675f342
241
py
Python
simple_wo_blueprint_example/myapp/models.py
gtsofa/mnseriesflask
58a84b698527ff3e790f0f7179193335bd440e3c
[ "MIT" ]
null
null
null
simple_wo_blueprint_example/myapp/models.py
gtsofa/mnseriesflask
58a84b698527ff3e790f0f7179193335bd440e3c
[ "MIT" ]
null
null
null
simple_wo_blueprint_example/myapp/models.py
gtsofa/mnseriesflask
58a84b698527ff3e790f0f7179193335bd440e3c
[ "MIT" ]
null
null
null
# myapp/models.py from myapp import db # define model here
24.1
48
0.684647
# myapp/models.py from myapp import db # define model here class Member(db.Model): id = db.Column(db.Integer, primary_key=True) name = db.Column(db.String(50)) email = db.Column(db.String(50)) random = db.Column(db.Integer)
0
159
22
1b3d360d3d104a1f9e57c1cbb72e5d717d4819c7
2,625
py
Python
external_libs/link/ci/run-tests.py
llloret/sp_link
b87ee622517fc68845b8f1d19c735c0e3bd05176
[ "MIT" ]
null
null
null
external_libs/link/ci/run-tests.py
llloret/sp_link
b87ee622517fc68845b8f1d19c735c0e3bd05176
[ "MIT" ]
null
null
null
external_libs/link/ci/run-tests.py
llloret/sp_link
b87ee622517fc68845b8f1d19c735c0e3bd05176
[ "MIT" ]
1
2021-02-22T11:37:41.000Z
2021-02-22T11:37:41.000Z
#!/usr/bin/env python import argparse import logging import os import sys from distutils.spawn import find_executable from subprocess import call if __name__ == '__main__': logging.basicConfig(format='%(message)s', level=logging.INFO, stream=sys.stdout) sys.exit(run_tests(parse_args()))
27.925532
88
0.649143
#!/usr/bin/env python import argparse import logging import os import sys from distutils.spawn import find_executable from subprocess import call def parse_args(): arg_parser = argparse.ArgumentParser() arg_parser.add_argument( '-t', '--target', help='Target to test') arg_parser.add_ar...
2,205
0
115
c458dae29fdfeaad53ba796122d7d999a3528470
241
py
Python
vnpy/trader/gateway/okcoinGateway/__init__.py
Adam1679/vnpy_adam
91e384c9372ee36689d9bb600fe7f45fbb68976e
[ "MIT" ]
1
2019-03-28T15:45:21.000Z
2019-03-28T15:45:21.000Z
vnpy/trader/gateway/okcoinGateway/__init__.py
Adam1679/vnpy_adam
91e384c9372ee36689d9bb600fe7f45fbb68976e
[ "MIT" ]
null
null
null
vnpy/trader/gateway/okcoinGateway/__init__.py
Adam1679/vnpy_adam
91e384c9372ee36689d9bb600fe7f45fbb68976e
[ "MIT" ]
null
null
null
# encoding: UTF-8 from vnpy.trader import vtConstant from okcoinGateway import OkcoinGateway gatewayClass = OkcoinGateway gatewayName = 'OKEX' gatewayDisplayName = u'OkEx' gatewayType = vtConstant.GATEWAYTYPE_BTC gatewayQryEnabled = True
20.083333
40
0.821577
# encoding: UTF-8 from vnpy.trader import vtConstant from okcoinGateway import OkcoinGateway gatewayClass = OkcoinGateway gatewayName = 'OKEX' gatewayDisplayName = u'OkEx' gatewayType = vtConstant.GATEWAYTYPE_BTC gatewayQryEnabled = True
0
0
0
c4e9bbaf69c142bb6022e73c6da05f216a4b4b48
947
py
Python
tests/unit/_helpers.py
metabolize-forks/booby
4e15e4e263dc387420398f808ffb345b760364d4
[ "Apache-2.0" ]
null
null
null
tests/unit/_helpers.py
metabolize-forks/booby
4e15e4e263dc387420398f808ffb345b760364d4
[ "Apache-2.0" ]
null
null
null
tests/unit/_helpers.py
metabolize-forks/booby
4e15e4e263dc387420398f808ffb345b760364d4
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- import collections
16.910714
42
0.606125
# -*- coding: utf-8 -*- import collections def stub_validator(value): pass class Spy(object): def __init__(self): self.times_called = 0 def __call__(self): self.times_called += 1 class MyList(collections.MutableSequence): def __init__(self, *args): self._store = list(args...
394
38
467
00cfbc4ba62476b2efa5d02b11c24a2c7078eb23
2,250
py
Python
notes/code/trie.py
Divya-Bhargavi/msds689
7bc4e2c5f06ef1889a887d7f49ec367749e473af
[ "MIT" ]
1
2019-08-26T04:11:13.000Z
2019-08-26T04:11:13.000Z
notes/code/trie.py
khanhbrandy/msds689
7f8ee791fda9d4fa65c4b047fef6b37948e5bb7f
[ "MIT" ]
null
null
null
notes/code/trie.py
khanhbrandy/msds689
7f8ee791fda9d4fa65c4b047fef6b37948e5bb7f
[ "MIT" ]
1
2019-07-02T08:58:59.000Z
2019-07-02T08:58:59.000Z
from lolviz import * import time import os import psutil def search(root:TrieNode, s:str, i=0) -> bool: "Return true if s is prefix of word in Trie or full word in Trie" p = root while p is not None: if i>=len(s): return True e = ord(s[i]) - ord('a') if p.edges[e] is None: return ...
25
85
0.577333
from lolviz import * import time import os import psutil class TrieNode: def __init__(self): self.edges = [] # init edges, one per a..z letter for c in range(ord('a'), ord('z')+1): self.edges.append(None) def add(p:TrieNode, s:str, i=0) -> None: if i>=len(s): return e = ord(s[i]) - ord('a...
1,203
-6
164
df67bea4c9819ec52d3d60e17f46ad9238dc3a6d
3,166
py
Python
third_party/blink/renderer/build/scripts/make_runtime_features_utilities.py
zealoussnow/chromium
fd8a8914ca0183f0add65ae55f04e287543c7d4a
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
14,668
2015-01-01T01:57:10.000Z
2022-03-31T23:33:32.000Z
third_party/blink/renderer/build/scripts/make_runtime_features_utilities.py
zealoussnow/chromium
fd8a8914ca0183f0add65ae55f04e287543c7d4a
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
113
2015-05-04T09:58:14.000Z
2022-01-31T19:35:03.000Z
third_party/blink/renderer/build/scripts/make_runtime_features_utilities.py
zealoussnow/chromium
fd8a8914ca0183f0add65ae55f04e287543c7d4a
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
5,941
2015-01-02T11:32:21.000Z
2022-03-31T16:35:46.000Z
# Copyright 2019 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. from collections import defaultdict def _validate_runtime_features_graph(features): """ Raises AssertionError when sanity check failed. @param...
34.791209
94
0.639924
# Copyright 2019 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. from collections import defaultdict def _error_message(message, feature, other_feature=None): message = 'runtime_enabled_features.json5: {}: {}'.format...
552
0
77
16f2f307f2a23c4ea9298468f8941e54ddc89b6d
587
py
Python
K_Mathematical_Modeling/Section 0/solutionExo2.py
oercompbiomed/CBM101
20010dcb99fbf218c4789eb5918dcff8ceb94898
[ "MIT" ]
7
2019-07-03T07:41:55.000Z
2022-02-06T20:25:37.000Z
K_Mathematical_Modeling/Section 0/solutionExo2.py
oercompbiomed/CBM101
20010dcb99fbf218c4789eb5918dcff8ceb94898
[ "MIT" ]
9
2019-03-14T15:15:09.000Z
2019-08-01T14:18:21.000Z
K_Mathematical_Modeling/Section 0/solutionExo2.py
oercompbiomed/CBM101
20010dcb99fbf218c4789eb5918dcff8ceb94898
[ "MIT" ]
11
2019-03-12T10:43:11.000Z
2021-10-05T12:15:00.000Z
Birds_year0 = 100 Birth_rate = 0.5 Death_rate = 0.2 # We repeat the "for" loop with an additional step: every time bird population reaches 1000, an epidemic kills half of them Time=[0] Birds=[100] for year in range (1,51) : Birds = Birds + [Birds[-1] + Birds[-1] * Birth_rate - Birds[-1] * Death_rate ] ...
27.952381
124
0.637138
Birds_year0 = 100 Birth_rate = 0.5 Death_rate = 0.2 # We repeat the "for" loop with an additional step: every time bird population reaches 1000, an epidemic kills half of them Time=[0] Birds=[100] for year in range (1,51) : Birds = Birds + [Birds[-1] + Birds[-1] * Birth_rate - Birds[-1] * Death_rate ] ...
0
0
0
0cd24154039f132d5322d370540651a26ee7c32d
3,682
py
Python
Topic_modelling_output.py
Dushyanttara/ASR_SD
a7bfc07fc8ecb3b77dfd43cdadbfb2a491b66103
[ "MIT" ]
null
null
null
Topic_modelling_output.py
Dushyanttara/ASR_SD
a7bfc07fc8ecb3b77dfd43cdadbfb2a491b66103
[ "MIT" ]
null
null
null
Topic_modelling_output.py
Dushyanttara/ASR_SD
a7bfc07fc8ecb3b77dfd43cdadbfb2a491b66103
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Dec 6 00:06:55 2019 @author: - """ import pandas as pd import numpy as np from matplotlib import pyplot as plt import os from datetime import datetime from gensim import corpora, models, similarities from nltk.tokenize import RegexpTokenizer from nltk.corpus i...
42.813953
156
0.710483
# -*- coding: utf-8 -*- """ Created on Fri Dec 6 00:06:55 2019 @author: - """ import pandas as pd import numpy as np from matplotlib import pyplot as plt import os from datetime import datetime from gensim import corpora, models, similarities from nltk.tokenize import RegexpTokenizer from nltk.corpus i...
787
0
50
75d3beb4b4c7a19de10f0742149b98b76a7a51f4
3,230
py
Python
dakara_server/playlist/management/commands/createplayer.py
DakaraProject/dakara-server
b28fc1a8561e431d562102932f3d6ff3607e545b
[ "MIT" ]
4
2018-07-24T18:22:16.000Z
2020-01-24T16:30:54.000Z
dakara_server/playlist/management/commands/createplayer.py
DakaraProject/dakara-server
b28fc1a8561e431d562102932f3d6ff3607e545b
[ "MIT" ]
88
2017-11-04T08:58:02.000Z
2022-03-30T11:39:08.000Z
dakara_server/playlist/management/commands/createplayer.py
DakaraProject/dakara-server
b28fc1a8561e431d562102932f3d6ff3607e545b
[ "MIT" ]
1
2018-05-05T15:37:20.000Z
2018-05-05T15:37:20.000Z
from getpass import getpass from django.contrib.auth import get_user_model from django.core.management.base import BaseCommand from django.db.utils import IntegrityError UserModel = get_user_model() USERNAME_DEFAULT = "player" class Command(BaseCommand): """Create the player special user.""" help = "Creat...
27.606838
88
0.5613
from getpass import getpass from django.contrib.auth import get_user_model from django.core.management.base import BaseCommand from django.db.utils import IntegrityError UserModel = get_user_model() USERNAME_DEFAULT = "player" class Command(BaseCommand): """Create the player special user.""" help = "Creat...
0
0
0
92bf5938cadd673401ef50232fe50e8eb090235a
24,621
py
Python
python/ga4gh/schemas/ga4gh/genotype_phenotype_service_pb2.py
david4096/ga4gh-schemas
774db498cc047cc64cc070325472c7dba60e6d42
[ "Apache-2.0" ]
114
2015-01-05T22:19:34.000Z
2017-02-18T18:51:22.000Z
python/ga4gh/schemas/ga4gh/genotype_phenotype_service_pb2.py
david4096/ga4gh-schemas
774db498cc047cc64cc070325472c7dba60e6d42
[ "Apache-2.0" ]
608
2015-01-06T00:24:39.000Z
2017-03-09T05:29:16.000Z
python/ga4gh/schemas/ga4gh/genotype_phenotype_service_pb2.py
david4096/ga4gh-schemas
774db498cc047cc64cc070325472c7dba60e6d42
[ "Apache-2.0" ]
98
2015-01-12T18:09:52.000Z
2017-02-15T15:49:17.000Z
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: ga4gh/schemas/ga4gh/genotype_phenotype_service.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from goog...
46.454717
3,000
0.779213
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: ga4gh/schemas/ga4gh/genotype_phenotype_service.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from goog...
0
0
0
a3987566f81f1f390282f04c2e3ede2162a5addc
2,041
py
Python
headlinenews/supasql.py
bradybellini/headline-news
048171443f10236c2d74251f16f83fd1f7a02633
[ "MIT" ]
null
null
null
headlinenews/supasql.py
bradybellini/headline-news
048171443f10236c2d74251f16f83fd1f7a02633
[ "MIT" ]
null
null
null
headlinenews/supasql.py
bradybellini/headline-news
048171443f10236c2d74251f16f83fd1f7a02633
[ "MIT" ]
null
null
null
import os, logging from typing import Any from dotenv import load_dotenv from supabase import create_client, Client from headlinenews import RSSParser from postgrest_py import exceptions
37.109091
85
0.611465
import os, logging from typing import Any from dotenv import load_dotenv from supabase import create_client, Client from headlinenews import RSSParser from postgrest_py import exceptions class SupaPSQL: def __init__(self) -> None: self.logger = logging.getLogger("rogger_logger.supasql.SupaPSQL") s...
1,702
-6
157
910af70fde3d4b24a60b0a876965bc7f748573ce
4,695
py
Python
aiounittest/helpers.py
tmaila/aiounittest
c43d3b619fd6a8fd071758996a5f42310b0293dc
[ "MIT" ]
null
null
null
aiounittest/helpers.py
tmaila/aiounittest
c43d3b619fd6a8fd071758996a5f42310b0293dc
[ "MIT" ]
null
null
null
aiounittest/helpers.py
tmaila/aiounittest
c43d3b619fd6a8fd071758996a5f42310b0293dc
[ "MIT" ]
null
null
null
import asyncio import functools def futurized(o): ''' Makes the given object to be awaitable. :param any o: Object to wrap :return: awaitable that resolves to provided object :rtype: asyncio.Future Anything passed to :code:`futurized` is wrapped in :code:`asyncio.Future`. This makes it await...
30.888158
147
0.594249
import asyncio import functools def futurized(o): ''' Makes the given object to be awaitable. :param any o: Object to wrap :return: awaitable that resolves to provided object :rtype: asyncio.Future Anything passed to :code:`futurized` is wrapped in :code:`asyncio.Future`. This makes it await...
936
0
53
a01937274946e3d3dc59bb59097e6ddcb1f8f4f7
4,528
py
Python
daemon/core/gui/dialogs/alerts.py
kleberango/core
87ca431e73fec22faeaebd6b25fc76e0b165c639
[ "BSD-2-Clause" ]
null
null
null
daemon/core/gui/dialogs/alerts.py
kleberango/core
87ca431e73fec22faeaebd6b25fc76e0b165c639
[ "BSD-2-Clause" ]
null
null
null
daemon/core/gui/dialogs/alerts.py
kleberango/core
87ca431e73fec22faeaebd6b25fc76e0b165c639
[ "BSD-2-Clause" ]
1
2021-09-03T19:18:54.000Z
2021-09-03T19:18:54.000Z
""" check engine light """ import tkinter as tk from tkinter import ttk from typing import TYPE_CHECKING, Dict, Optional from core.gui.dialogs.dialog import Dialog from core.gui.themes import PADX, PADY from core.gui.widgets import CodeText from core.gui.wrappers import ExceptionEvent, ExceptionLevel if TYPE_CHECKING...
39.373913
87
0.628092
""" check engine light """ import tkinter as tk from tkinter import ttk from typing import TYPE_CHECKING, Dict, Optional from core.gui.dialogs.dialog import Dialog from core.gui.themes import PADX, PADY from core.gui.widgets import CodeText from core.gui.wrappers import ExceptionEvent, ExceptionLevel if TYPE_CHECKING...
4,028
6
130
13445cd76a57b0cfb98ffb3231749aa5d5c91508
195
py
Python
gamefixes/356500.py
manueliglesiasgarcia/protonfixes
d676b6bf39f6e4268b4791d3d71c6d74e2127121
[ "BSD-2-Clause" ]
54
2019-06-21T22:03:45.000Z
2022-03-20T19:24:36.000Z
gamefixes/356500.py
manueliglesiasgarcia/protonfixes
d676b6bf39f6e4268b4791d3d71c6d74e2127121
[ "BSD-2-Clause" ]
21
2020-06-13T22:49:18.000Z
2022-03-20T08:28:39.000Z
gamefixes/356500.py
manueliglesiasgarcia/protonfixes
d676b6bf39f6e4268b4791d3d71c6d74e2127121
[ "BSD-2-Clause" ]
53
2019-09-11T15:23:25.000Z
2022-03-20T08:18:49.000Z
""" Game fix for STAR WARS Galactic Battlegrounds Saga """ #pylint: disable=C0103 from protonfixes import util
17.727273
54
0.728205
""" Game fix for STAR WARS Galactic Battlegrounds Saga """ #pylint: disable=C0103 from protonfixes import util def main(): util.protontricks('icodecs') util.protontricks('directplay')
59
0
23
9693d0adc1ee8de233d3015aa07f6141ff5843be
28
py
Python
test/login.py
huang880/test
9c65ffd470dd52633ded4eb2b8e1cd89d3b7c5d0
[ "MIT" ]
null
null
null
test/login.py
huang880/test
9c65ffd470dd52633ded4eb2b8e1cd89d3b7c5d0
[ "MIT" ]
null
null
null
test/login.py
huang880/test
9c65ffd470dd52633ded4eb2b8e1cd89d3b7c5d0
[ "MIT" ]
null
null
null
a=1 b=2 c=3 d=4 你是不是个沙雕 f=6
4
7
0.607143
a=1 b=2 c=3 d=4 你是不是个沙雕 f=6
0
0
0
e051ca2acbd4d511635ff08104c916ea3c6f9804
1,841
py
Python
tests/integration/tasks/test_azure_data_lake.py
gwieloch/viadot
8026c4f5e48e5bec7bf62ea3e3e044e81ef3321f
[ "MIT" ]
23
2021-05-04T13:28:30.000Z
2022-02-16T18:51:24.000Z
tests/integration/tasks/test_azure_data_lake.py
gwieloch/viadot
8026c4f5e48e5bec7bf62ea3e3e044e81ef3321f
[ "MIT" ]
142
2021-05-01T10:48:12.000Z
2022-03-28T15:00:06.000Z
tests/integration/tasks/test_azure_data_lake.py
gwieloch/viadot
8026c4f5e48e5bec7bf62ea3e3e044e81ef3321f
[ "MIT" ]
13
2021-05-14T18:28:10.000Z
2022-03-17T10:17:17.000Z
import os import uuid from viadot.sources import AzureDataLake from viadot.tasks import ( AzureDataLakeDownload, AzureDataLakeToDF, AzureDataLakeUpload, AzureDataLakeCopy, AzureDataLakeList, ) uuid_4 = uuid.uuid4() uuid_4_2 = uuid.uuid4() file_name = f"test_file_{uuid_4}.csv" file_name_2 = f"test...
27.073529
80
0.767518
import os import uuid from viadot.sources import AzureDataLake from viadot.tasks import ( AzureDataLakeDownload, AzureDataLakeToDF, AzureDataLakeUpload, AzureDataLakeCopy, AzureDataLakeList, ) uuid_4 = uuid.uuid4() uuid_4_2 = uuid.uuid4() file_name = f"test_file_{uuid_4}.csv" file_name_2 = f"test...
1,057
0
138
3210d5af97fee381968e118be3cb3f5b7f008957
2,093
py
Python
denoising_autoencoder.py
JiananGao/DP-NMF
be96e67bd8955e46baa4d3f477f40c32a009c1cd
[ "MIT" ]
2
2019-03-16T16:59:39.000Z
2020-12-22T02:09:42.000Z
denoising_autoencoder.py
JiananGao/DP-NMF
be96e67bd8955e46baa4d3f477f40c32a009c1cd
[ "MIT" ]
null
null
null
denoising_autoencoder.py
JiananGao/DP-NMF
be96e67bd8955e46baa4d3f477f40c32a009c1cd
[ "MIT" ]
null
null
null
#Author: Satwik Bhattamishra import tensorflow as tf import numpy as np import tensorflow.examples.tutorials.mnist.input_data as input_data if __name__ == '__main__': denoising_autoencoder()
26.493671
116
0.68753
#Author: Satwik Bhattamishra import tensorflow as tf import numpy as np import tensorflow.examples.tutorials.mnist.input_data as input_data def denoising_autoencoder(hidden_units= 500, prob=0.4): learning_rate = 0.001 batch_size = 50 n_epochs = 10 x = tf.placeholder(tf.float32, [None, 784], name='x') x_ = tf....
1,875
0
23
a7c06cb92e54c73f18c82681723c99eff1f48301
1,097
py
Python
Array/longestMountain/longestMountain.py
qyp1997/leetcoder
4c01f11e5138cbb9aa12b4f6ef0c4a60d25b92c2
[ "MIT" ]
null
null
null
Array/longestMountain/longestMountain.py
qyp1997/leetcoder
4c01f11e5138cbb9aa12b4f6ef0c4a60d25b92c2
[ "MIT" ]
null
null
null
Array/longestMountain/longestMountain.py
qyp1997/leetcoder
4c01f11e5138cbb9aa12b4f6ef0c4a60d25b92c2
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ @Time : 2020/10/25 17:14 @Auth : Qi @IDE : PyCharm @Title: 845. 数组中的最长山脉 @Link : https://leetcode-cn.com/problems/longest-mountain-in-array/ """ if __name__ == '__main__': # 测试用例 s = Solution() print(s.longestMountain([2, 1, 4, 7, 3, 2, 5])) print(s.longestMountain([0, 1,...
29.648649
76
0.441203
# -*- coding: utf-8 -*- """ @Time : 2020/10/25 17:14 @Auth : Qi @IDE : PyCharm @Title: 845. 数组中的最长山脉 @Link : https://leetcode-cn.com/problems/longest-mountain-in-array/ """ class Solution: def longestMountain(self, A) -> int: up, down, maxRet = 0, 0, 0 for i in range(1, len(A)): if A[...
673
-6
49
004dae0bab2e65b2b02c2b31eb46c43d4c61bc03
3,626
py
Python
software/inpainting/inpainting_iterative_rgbd/inpaint_rgbd_tiled.py
venkai/deploy_core3d
6333c634f8f79b3ed9d7b13f39137c406f374a4f
[ "BSD-2-Clause" ]
3
2020-05-03T10:22:46.000Z
2021-06-26T16:17:09.000Z
software/inpainting/inpainting_iterative_rgbd/inpaint_rgbd_tiled.py
venkai/deploy_core3d
6333c634f8f79b3ed9d7b13f39137c406f374a4f
[ "BSD-2-Clause" ]
null
null
null
software/inpainting/inpainting_iterative_rgbd/inpaint_rgbd_tiled.py
venkai/deploy_core3d
6333c634f8f79b3ed9d7b13f39137c406f374a4f
[ "BSD-2-Clause" ]
1
2021-01-19T19:49:58.000Z
2021-01-19T19:49:58.000Z
import os import time import cv2 from inference_new import * import argparse from glob import glob if __name__ == "__main__": parser = argparse.ArgumentParser(description="Command for running the Inpainting Pipeline on RGBD satellite imagery") parser.add_argument('--gpu', type=str, default='0', help='the gpu ...
54.119403
129
0.664368
import os import time import cv2 from inference_new import * import argparse from glob import glob def main(): st = time.time() outputdir = args.outputdir if not os.path.isdir(outputdir): os.makedirs(outputdir) # Load network test_prototxt=args.trn_dir + '/test_' + args.model_type + ('_...
1,839
0
23
6257c7f64cd12ee5ad761bbc7011d80335ead4b9
22,819
py
Python
threeML/utils/time_series/time_series.py
Husky22/threeML
2ef3401e3edf82ceffd85ad0a9ea9e8b2bba3520
[ "BSD-3-Clause" ]
null
null
null
threeML/utils/time_series/time_series.py
Husky22/threeML
2ef3401e3edf82ceffd85ad0a9ea9e8b2bba3520
[ "BSD-3-Clause" ]
null
null
null
threeML/utils/time_series/time_series.py
Husky22/threeML
2ef3401e3edf82ceffd85ad0a9ea9e8b2bba3520
[ "BSD-3-Clause" ]
null
null
null
from __future__ import print_function from __future__ import division from builtins import zip from builtins import range from builtins import object from past.utils import old_div __author__ = 'grburgess' import collections import os import numpy as np import pandas as pd from pandas import HDFStore from threeML.ex...
29.55829
139
0.603401
from __future__ import print_function from __future__ import division from builtins import zip from builtins import range from builtins import object from past.utils import old_div __author__ = 'grburgess' import collections import os import numpy as np import pandas as pd from pandas import HDFStore from threeML.ex...
3,555
18,477
114
0f7f3b70073770b5b01ea972277895a04e2450c4
382
py
Python
serivce/run.py
LupusAnay/gateway-prototype
e40426e05ca7b2a83bfd8d31fec252086f586eb8
[ "MIT" ]
null
null
null
serivce/run.py
LupusAnay/gateway-prototype
e40426e05ca7b2a83bfd8d31fec252086f586eb8
[ "MIT" ]
null
null
null
serivce/run.py
LupusAnay/gateway-prototype
e40426e05ca7b2a83bfd8d31fec252086f586eb8
[ "MIT" ]
null
null
null
import requests import json from flask.cli import FlaskGroup from flask import jsonify from serivce.app import create_app app = create_app() data = json.dumps(dict(name='service', port='8000')) headers = {'Content-type': 'application/json'} requests.post('http://localhost:5000/instance', headers=headers, data=data)...
20.105263
75
0.73822
import requests import json from flask.cli import FlaskGroup from flask import jsonify from serivce.app import create_app app = create_app() data = json.dumps(dict(name='service', port='8000')) headers = {'Content-type': 'application/json'} requests.post('http://localhost:5000/instance', headers=headers, data=data)...
0
0
0
a5de7750593cb2f7bb8b789eae2fd2281336211a
24,635
py
Python
src/dorfromantik_helper/ui.py
mcdonnnj/dorfromantik_helper
adba24c135d54fc38d8879860972a869a0eba59e
[ "MIT" ]
null
null
null
src/dorfromantik_helper/ui.py
mcdonnnj/dorfromantik_helper
adba24c135d54fc38d8879860972a869a0eba59e
[ "MIT" ]
null
null
null
src/dorfromantik_helper/ui.py
mcdonnnj/dorfromantik_helper
adba24c135d54fc38d8879860972a869a0eba59e
[ "MIT" ]
null
null
null
"""Canvas that displays the full game board.""" # Standard Python Libraries import tkinter as tk # Third-Party Libraries import numpy as np from . import constants from .board import DorfBoard
38.372274
97
0.577349
"""Canvas that displays the full game board.""" # Standard Python Libraries import tkinter as tk # Third-Party Libraries import numpy as np from . import constants from .board import DorfBoard class DorfBoardCanvas(tk.Canvas): def __init__( self, master, board, tile_canvas, pix_height, pix_width, *args,...
16,732
7,394
311
8e242ece176dcf825713ef90eb78d86b8b43772e
283
py
Python
recent_updates/recent_updates_lib/__init__.py
djmattyg007/archlinux
268b6356aec59e5f285f67b556e998da1b06a8d2
[ "Unlicense" ]
null
null
null
recent_updates/recent_updates_lib/__init__.py
djmattyg007/archlinux
268b6356aec59e5f285f67b556e998da1b06a8d2
[ "Unlicense" ]
null
null
null
recent_updates/recent_updates_lib/__init__.py
djmattyg007/archlinux
268b6356aec59e5f285f67b556e998da1b06a8d2
[ "Unlicense" ]
null
null
null
import requests from bs4 import BeautifulSoup from tabulate import tabulate
23.583333
42
0.749117
import requests from bs4 import BeautifulSoup from tabulate import tabulate def get_pkg_updates(url): page = requests.get(url) soup = BeautifulSoup(page.text) return soup.find(id="pkg-updates") def print_table(headers, data): print(tabulate(data, headers=headers))
161
0
46
16ba5d46a3f627000bdc25262e6704e3cd4ff7a4
13,288
py
Python
tests/parsers/cups_ipp.py
jonathan-greig/plaso
b88a6e54c06a162295d09b016bddbfbfe7ca9070
[ "Apache-2.0" ]
6
2015-07-30T11:07:24.000Z
2021-07-23T07:12:30.000Z
tests/parsers/cups_ipp.py
jonathan-greig/plaso
b88a6e54c06a162295d09b016bddbfbfe7ca9070
[ "Apache-2.0" ]
null
null
null
tests/parsers/cups_ipp.py
jonathan-greig/plaso
b88a6e54c06a162295d09b016bddbfbfe7ca9070
[ "Apache-2.0" ]
1
2021-07-23T07:12:37.000Z
2021-07-23T07:12:37.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Parser test for MacOS Cups IPP Log files.""" import unittest from dfvfs.helpers import fake_file_system_builder from dfvfs.path import fake_path_spec from plaso.lib import definitions from plaso.lib import errors from plaso.parsers import cups_ipp from tests.parsers...
35.060686
79
0.72637
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Parser test for MacOS Cups IPP Log files.""" import unittest from dfvfs.helpers import fake_file_system_builder from dfvfs.path import fake_path_spec from plaso.lib import definitions from plaso.lib import errors from plaso.parsers import cups_ipp from tests.parsers...
0
0
0
5cc078595469499a2573ffbe88997b94b12bfd24
769
py
Python
Backend/oeda/rtxlib/preprocessors/__init__.py
iliasger/OEDA
0b5d94156cfc2d9252062f5d90dcb266466498d6
[ "Apache-2.0" ]
2
2019-10-11T10:40:11.000Z
2021-05-17T14:56:18.000Z
Backend/oeda/rtxlib/preprocessors/__init__.py
iliasger/OEDA
0b5d94156cfc2d9252062f5d90dcb266466498d6
[ "Apache-2.0" ]
3
2022-02-15T05:11:34.000Z
2022-03-02T13:01:36.000Z
Backend/oeda/rtxlib/preprocessors/__init__.py
iliasger/OEDA
0b5d94156cfc2d9252062f5d90dcb266466498d6
[ "Apache-2.0" ]
2
2019-05-27T13:01:23.000Z
2020-10-23T14:47:31.000Z
from colorama import Fore from oeda.log import * from oeda.rtxlib.preprocessors.SparkPreProcessor import SparkPreProcessor def init_pre_processors(wf): """ we look into the workflows definition and run the required preprocessors """ if hasattr(wf, "pre_processors"): pp = wf.pre_processors for...
29.576923
84
0.622887
from colorama import Fore from oeda.log import * from oeda.rtxlib.preprocessors.SparkPreProcessor import SparkPreProcessor def init_pre_processors(wf): """ we look into the workflows definition and run the required preprocessors """ if hasattr(wf, "pre_processors"): pp = wf.pre_processors for...
0
0
0
aab2fb48530b34760ffc1b2b1c43e3ed7ef58254
260
py
Python
pythainlp/translate/__init__.py
wannaphongcom/pythai-nlp
efcbe7f1881351fadf62d28cc0415d22156a2e71
[ "Apache-2.0" ]
125
2016-06-27T06:16:38.000Z
2017-10-14T08:02:26.000Z
pythainlp/translate/__init__.py
wannaphongcom/pythainlp
efcbe7f1881351fadf62d28cc0415d22156a2e71
[ "Apache-2.0" ]
48
2016-08-31T02:01:03.000Z
2017-10-07T16:33:47.000Z
pythainlp/translate/__init__.py
wannaphongcom/pythai-nlp
efcbe7f1881351fadf62d28cc0415d22156a2e71
[ "Apache-2.0" ]
40
2016-06-27T00:19:12.000Z
2017-10-16T06:32:20.000Z
# -*- coding: utf-8 -*- """ Language translation. """ __all__ = [ "ThZhTranslator", "ZhThTranslator", "Translate" ] from pythainlp.translate.core import Translate from pythainlp.translate.zh_th import ( ThZhTranslator, ZhThTranslator, )
14.444444
46
0.673077
# -*- coding: utf-8 -*- """ Language translation. """ __all__ = [ "ThZhTranslator", "ZhThTranslator", "Translate" ] from pythainlp.translate.core import Translate from pythainlp.translate.zh_th import ( ThZhTranslator, ZhThTranslator, )
0
0
0
23102cfdc377911d6f7c24434ac0713380ea8134
1,005
py
Python
test/unit/ggrc/models/test_custom_attribute_definition.py
ks-manish/ggrc-core
f9499236e0c6d2e29ff9d2acf403fdecd9c8a173
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
test/unit/ggrc/models/test_custom_attribute_definition.py
ks-manish/ggrc-core
f9499236e0c6d2e29ff9d2acf403fdecd9c8a173
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
test/unit/ggrc/models/test_custom_attribute_definition.py
ks-manish/ggrc-core
f9499236e0c6d2e29ff9d2acf403fdecd9c8a173
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# Copyright (C) 2019 Google Inc. # Licensed under http://www.apache.org/licenses/LICENSE-2.0 <see LICENSE file> """Test Custom Attribute Definition validation""" import unittest from mock import MagicMock from ggrc.models import all_models from ggrc.access_control import role as acr class TestCustomAttributeDefini...
34.655172
79
0.753234
# Copyright (C) 2019 Google Inc. # Licensed under http://www.apache.org/licenses/LICENSE-2.0 <see LICENSE file> """Test Custom Attribute Definition validation""" import unittest from mock import MagicMock from ggrc.models import all_models from ggrc.access_control import role as acr class TestCustomAttributeDefini...
306
0
25
0b7b1e425f8017f791073b532d42d48a2786d924
171
py
Python
13.py
kwoshvick/project-euler
d27370b0f22b51ad9ccb15afa912983d8fd8be5c
[ "MIT" ]
null
null
null
13.py
kwoshvick/project-euler
d27370b0f22b51ad9ccb15afa912983d8fd8be5c
[ "MIT" ]
null
null
null
13.py
kwoshvick/project-euler
d27370b0f22b51ad9ccb15afa912983d8fd8be5c
[ "MIT" ]
null
null
null
file = open("13") sum = 0 for numbers in file: #print(numbers.rstrip()) numbers = int(numbers) sum += numbers; print(sum) sum = str(sum) print(sum[:10])
10.6875
28
0.596491
file = open("13") sum = 0 for numbers in file: #print(numbers.rstrip()) numbers = int(numbers) sum += numbers; print(sum) sum = str(sum) print(sum[:10])
0
0
0
41a4a212bdd800f5254430c0e4838186564b6a70
5,422
py
Python
autoencoder_use_mnist.py
deeplearningathome/autoencoder
7cd4a54e1ed47bbcf0cf97e2eafc7cb0cc8ad1af
[ "MIT" ]
3
2017-08-08T09:43:12.000Z
2018-05-23T09:29:41.000Z
autoencoder_use_mnist.py
deeplearningathome/autoencoder
7cd4a54e1ed47bbcf0cf97e2eafc7cb0cc8ad1af
[ "MIT" ]
null
null
null
autoencoder_use_mnist.py
deeplearningathome/autoencoder
7cd4a54e1ed47bbcf0cf97e2eafc7cb0cc8ad1af
[ "MIT" ]
2
2016-12-26T09:27:00.000Z
2019-12-13T13:14:05.000Z
""" MIT License Copyright (c) 2016 deeplearningathome. http://deeplearningathome.com/ 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 ...
50.672897
134
0.71007
""" MIT License Copyright (c) 2016 deeplearningathome. http://deeplearningathome.com/ 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 ...
3,262
0
23
8dc572c5ddfe9278604ffcd87024633538f518d4
9,925
py
Python
www/app/views/api.py
YuiJL/myweblog
82f355d32b6d37cf329f1852459d40d5410de810
[ "MIT" ]
2
2016-09-18T12:41:44.000Z
2016-10-26T04:27:25.000Z
www/app/views/api.py
YuiJL/webblog
82f355d32b6d37cf329f1852459d40d5410de810
[ "MIT" ]
null
null
null
www/app/views/api.py
YuiJL/webblog
82f355d32b6d37cf329f1852459d40d5410de810
[ "MIT" ]
2
2016-09-22T05:31:18.000Z
2016-10-05T18:39:29.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = 'Jiayi Li' import time, os, re from bson.objectid import ObjectId from werkzeug.utils import secure_filename from flask import request, redirect, url_for, jsonify, abort, Blueprint, make_response, g, flash, current_app from app import db from app.models im...
32.224026
109
0.556675
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = 'Jiayi Li' import time, os, re from bson.objectid import ObjectId from werkzeug.utils import secure_filename from flask import request, redirect, url_for, jsonify, abort, Blueprint, make_response, g, flash, current_app from app import db from app.models im...
0
0
0
b37a81a05ea7a387843e0c8e55bac504975a6e81
1,091
py
Python
Python/Misc.py
Spectavi/video-diff
4ad28aea48877937f6b5b25f374f9c14eaf79212
[ "BSD-3-Clause" ]
1
2021-04-18T21:24:42.000Z
2021-04-18T21:24:42.000Z
Python/Misc.py
Spectavi/video-diff
4ad28aea48877937f6b5b25f374f9c14eaf79212
[ "BSD-3-Clause" ]
null
null
null
Python/Misc.py
Spectavi/video-diff
4ad28aea48877937f6b5b25f374f9c14eaf79212
[ "BSD-3-Clause" ]
null
null
null
import cv # TODO: This class doesn't seem to be used and is based on old OpenCV bindings. # Either finish the class or remove it. def convert_np_to_cvmat(img_np): """ This gives a: AttributeError: 'numpy.ndarray' object has no attribute 'from_array' ImageAlignment.template_image = ImageAlignment.temp...
36.366667
116
0.698442
import cv # TODO: This class doesn't seem to be used and is based on old OpenCV bindings. # Either finish the class or remove it. def convert_np_to_cvmat(img_np): """ This gives a: AttributeError: 'numpy.ndarray' object has no attribute 'from_array' ImageAlignment.template_image = ImageAlignment.temp...
441
0
23
148a619326f816979634a70896847110174d2691
6,456
py
Python
python/extract_small_fragments.py
maubarsom/biotico-tools
3e34e1fdde083e49da10f5afdae6a951246b8a94
[ "Apache-2.0" ]
1
2021-01-16T20:47:29.000Z
2021-01-16T20:47:29.000Z
python/extract_small_fragments.py
maubarsom/biotico-tools
3e34e1fdde083e49da10f5afdae6a951246b8a94
[ "Apache-2.0" ]
null
null
null
python/extract_small_fragments.py
maubarsom/biotico-tools
3e34e1fdde083e49da10f5afdae6a951246b8a94
[ "Apache-2.0" ]
1
2015-06-26T18:22:11.000Z
2015-06-26T18:22:11.000Z
#!/usr/bin/env python """ Script that uses output from cutadapt to quickly detect fully overlapping pairs. It is based on the fact that if sequencing adapters are trimmed from both paired-ends, the resulting fragment needs to be shorter than the pair-end length Depends of cutadapt seqio and xopen modules from version ...
33.978947
158
0.74272
#!/usr/bin/env python """ Script that uses output from cutadapt to quickly detect fully overlapping pairs. It is based on the fact that if sequencing adapters are trimmed from both paired-ends, the resulting fragment needs to be shorter than the pair-end length Depends of cutadapt seqio and xopen modules from version ...
3,423
-1
252
1420efe3a125985e64e2524aecee773b66a7a539
5,956
py
Python
models/audio_net.py
CFM-MSG/MTSC_VSS
9536f8dc8d0282c3d0e6e2beee6e2cac490d6cb1
[ "MIT" ]
1
2021-11-20T12:31:24.000Z
2021-11-20T12:31:24.000Z
models/audio_net.py
CFM-MSG/MTSC_VSS
9536f8dc8d0282c3d0e6e2beee6e2cac490d6cb1
[ "MIT" ]
null
null
null
models/audio_net.py
CFM-MSG/MTSC_VSS
9536f8dc8d0282c3d0e6e2beee6e2cac490d6cb1
[ "MIT" ]
null
null
null
import torch import torch.nn as nn import torch.nn.functional as F
48.819672
118
0.662525
import torch import torch.nn as nn import torch.nn.functional as F class Unet(nn.Module): def __init__(self, ngf=64): super(Unet, self).__init__() two_stream = TwoStreamBlock(ngf * 8, ngf * 8) unet_block = UnetBlock(ngf * 8, ngf * 8, upconv_in_dim=ngf * 8 * 2, submodule=two_stream) ...
5,641
18
228
180dcf48c8c5be31604981911aac4f3dde2a1d12
1,864
py
Python
tests/test_grid.py
agonopol/battleship-ai
eef51e972b26e5454dfc0d3685d417cc429969b1
[ "MIT" ]
null
null
null
tests/test_grid.py
agonopol/battleship-ai
eef51e972b26e5454dfc0d3685d417cc429969b1
[ "MIT" ]
null
null
null
tests/test_grid.py
agonopol/battleship-ai
eef51e972b26e5454dfc0d3685d417cc429969b1
[ "MIT" ]
null
null
null
from battleship.grid import Grid, Outcome from battleship.ship import Ship
23.3
43
0.607833
from battleship.grid import Grid, Outcome from battleship.ship import Ship def test_grid_creates_ok(): grid = Grid(10) assert grid.lost( ) def test_grid_places_ship_ok(): grid = Grid(10) assert grid.lost( ) ship = Ship((0,0), (0, 2)) grid.place(ship) assert grid.ships == 3 assert not ...
1,623
0
161
0d426cc28bb3a102172b4a5193fac6badf8ee34e
7,741
py
Python
test/nn/conv/test_message_passing.py
zheng-da/pytorch_geometric
3d23afdf5f5c6f386b17a339790181313c60aae6
[ "MIT" ]
2
2020-12-06T13:10:52.000Z
2021-07-06T06:50:10.000Z
test/nn/conv/test_message_passing.py
zheng-da/pytorch_geometric
3d23afdf5f5c6f386b17a339790181313c60aae6
[ "MIT" ]
null
null
null
test/nn/conv/test_message_passing.py
zheng-da/pytorch_geometric
3d23afdf5f5c6f386b17a339790181313c60aae6
[ "MIT" ]
1
2021-07-06T06:50:21.000Z
2021-07-06T06:50:21.000Z
import copy import pytest from typing import Tuple, Optional import torch from torch_sparse import SparseTensor from torch_sparse.matmul import spmm from torch_geometric.nn import MessagePassing from torch_geometric.utils import softmax edge_index = torch.tensor([ [0, 0, 0, 1, 1], [0, 1, 2, 0, 2], ]) adj_t = ...
31.72541
71
0.6556
import copy import pytest from typing import Tuple, Optional import torch from torch_sparse import SparseTensor from torch_sparse.matmul import spmm from torch_geometric.nn import MessagePassing from torch_geometric.utils import softmax edge_index = torch.tensor([ [0, 0, 0, 1, 1], [0, 1, 2, 0, 2], ]) adj_t = ...
6,169
161
931
37d9b671438cbab3ced21ae57cea76a44b2892f3
4,282
py
Python
src/plot_jhu_data.py
astrophys/covid19
a1978a87a4d090c1de29d38db1c04164c8b0ba8e
[ "MIT" ]
1
2020-03-19T17:39:17.000Z
2020-03-19T17:39:17.000Z
src/plot_jhu_data.py
astrophys/covid19
a1978a87a4d090c1de29d38db1c04164c8b0ba8e
[ "MIT" ]
null
null
null
src/plot_jhu_data.py
astrophys/covid19
a1978a87a4d090c1de29d38db1c04164c8b0ba8e
[ "MIT" ]
null
null
null
# Author : Ali Snedden # Date : 3/21/20 # License: MIT # Purpose: # This code plots the Johns Hoptins Covid-19 Data # # # # Notes : # # References : # 1. https://github.com/CSSEGISandData/COVID-19 # # # Future: # # # import sys import numpy as np import time import pandas as pd from matplotlib imp...
30.15493
111
0.541336
# Author : Ali Snedden # Date : 3/21/20 # License: MIT # Purpose: # This code plots the Johns Hoptins Covid-19 Data # # # # Notes : # # References : # 1. https://github.com/CSSEGISandData/COVID-19 # # # Future: # # # import sys import numpy as np import time import pandas as pd from matplotlib imp...
0
0
0
26bf7610cfe93f9a459dcd52bd651b53365563d4
1,789
py
Python
tkinter_module/tkinter_image.py
kenwaldek/python
e6aaf5616a456a4fb91889c0617bd6511f1a223e
[ "MIT" ]
1
2019-02-24T09:57:16.000Z
2019-02-24T09:57:16.000Z
tkinter_module/tkinter_image.py
kenwaldek/python
e6aaf5616a456a4fb91889c0617bd6511f1a223e
[ "MIT" ]
null
null
null
tkinter_module/tkinter_image.py
kenwaldek/python
e6aaf5616a456a4fb91889c0617bd6511f1a223e
[ "MIT" ]
4
2017-05-21T15:34:53.000Z
2018-09-25T06:56:15.000Z
#! /usr/bin/env python3 # -*- coding:utf-8 -*- ############################################################### # © kenwaldek MIT-license # # Title: tkinter_image Version: 1.0 # Date: 26-12-16 Language: python3 # Description: tkinter inladen van image en text ...
27.953125
73
0.561766
#! /usr/bin/env python3 # -*- coding:utf-8 -*- ############################################################### # © kenwaldek MIT-license # # Title: tkinter_image Version: 1.0 # Date: 26-12-16 Language: python3 # Description: tkinter inladen van image en text ...
1,105
-1
157
eb24c3cd1f6adf2f321fd6a4d6312c8759cb8014
117
py
Python
app_bootstrap_examples/apps.py
bogdandrienko/kostanay-minerals
d266b3899f8403b5182e1dadf74b1f8bb580d17c
[ "MIT" ]
1
2021-02-13T08:40:51.000Z
2021-02-13T08:40:51.000Z
app_bootstrap_examples/apps.py
bogdandrienko/chrysotile-minerals
47a4097e29ee40f2606807e28b2da466dfd7f3f4
[ "MIT" ]
null
null
null
app_bootstrap_examples/apps.py
bogdandrienko/chrysotile-minerals
47a4097e29ee40f2606807e28b2da466dfd7f3f4
[ "MIT" ]
null
null
null
from django.apps import AppConfig
19.5
44
0.811966
from django.apps import AppConfig class AppBootstrapExamplesConfig(AppConfig): name = 'app_bootstrap_examples'
0
59
23
1e000f54ec66535b78129eef7b6df9704797f75b
1,098
py
Python
steps/run-wait/step.py
relay-integrations/relay-puppet
1e0c2b67e778a26fcd91ed6bf2680f120e9a67d8
[ "Apache-2.0" ]
1
2020-11-30T07:20:17.000Z
2020-11-30T07:20:17.000Z
steps/run-wait/step.py
relay-integrations/relay-puppet
1e0c2b67e778a26fcd91ed6bf2680f120e9a67d8
[ "Apache-2.0" ]
null
null
null
steps/run-wait/step.py
relay-integrations/relay-puppet
1e0c2b67e778a26fcd91ed6bf2680f120e9a67d8
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import logging import time from urllib.parse import urljoin import requests from relay_sdk import Interface, Dynamic as D relay = Interface() relay_api_url = relay.get(D.connection.relayAPIURL) relay_api_token = relay.get(D.connection.token) run_id = relay.get(D.id) headers = {'Authorization...
26.780488
105
0.662113
#!/usr/bin/env python import logging import time from urllib.parse import urljoin import requests from relay_sdk import Interface, Dynamic as D relay = Interface() relay_api_url = relay.get(D.connection.relayAPIURL) relay_api_token = relay.get(D.connection.token) run_id = relay.get(D.id) headers = {'Authorization...
0
0
0
6daf6cc726a7f05dfdd45c0c735937d37d9d3b2e
1,671
py
Python
src/config.py
gwohlgen/w2v_ol
bb67a3a1b54ca756cff1f28ef5ca5842e8a9c91d
[ "Apache-2.0" ]
20
2017-04-05T10:37:26.000Z
2022-03-02T17:24:16.000Z
src/config.py
gwohlgen/w2v_ol
bb67a3a1b54ca756cff1f28ef5ca5842e8a9c91d
[ "Apache-2.0" ]
1
2019-04-02T07:33:53.000Z
2019-04-02T07:33:53.000Z
src/config.py
gwohlgen/w2v_ol
bb67a3a1b54ca756cff1f28ef5ca5842e8a9c91d
[ "Apache-2.0" ]
10
2018-02-06T12:10:37.000Z
2021-02-13T05:54:57.000Z
#!/usr/bin/python # you need to config this! # set the model file, and if the model supports big-grams: set seed with bigrams.. ## the conf dict stores all relevant config parameters conf={} conf['model'] = "climate2_2015_7.txt.2gram.small.model" # default dummy model #conf['model'] = "climate2_2015_7.txt.2gram.mod...
30.944444
120
0.666667
#!/usr/bin/python # you need to config this! # set the model file, and if the model supports big-grams: set seed with bigrams.. ## the conf dict stores all relevant config parameters conf={} conf['model'] = "climate2_2015_7.txt.2gram.small.model" # default dummy model #conf['model'] = "climate2_2015_7.txt.2gram.mod...
0
0
0
707397c9f2c573d36024259a0ef46852b223c300
71
py
Python
neumiss/__init__.py
dirty-cat/NeuMiss
dd4c7b4c55d6cf9ccad194bac0caf3cbac320723
[ "BSD-2-Clause" ]
2
2021-08-10T10:04:05.000Z
2021-08-18T16:09:34.000Z
neumiss/__init__.py
dirty-cat/NeuMiss
dd4c7b4c55d6cf9ccad194bac0caf3cbac320723
[ "BSD-2-Clause" ]
null
null
null
neumiss/__init__.py
dirty-cat/NeuMiss
dd4c7b4c55d6cf9ccad194bac0caf3cbac320723
[ "BSD-2-Clause" ]
null
null
null
from .neumiss_layer import NeuMiss from .neumiss_mlp import NeuMissMLP
23.666667
35
0.859155
from .neumiss_layer import NeuMiss from .neumiss_mlp import NeuMissMLP
0
0
0
cb474b9a1b131517c08f3fdabe8b41a8937618ae
1,726
py
Python
app/api/resources.py
XIN-TU/easySpike
727a37e4c88f640427a1c30f80bd0fead8427566
[ "MIT" ]
null
null
null
app/api/resources.py
XIN-TU/easySpike
727a37e4c88f640427a1c30f80bd0fead8427566
[ "MIT" ]
null
null
null
app/api/resources.py
XIN-TU/easySpike
727a37e4c88f640427a1c30f80bd0fead8427566
[ "MIT" ]
null
null
null
""" REST API Resource Routing http://flask-restplus.readthedocs.io """ from datetime import datetime from flask import request from flask_restplus import Resource from .security import require_auth from . import api_rest from .func import * from .engine import * # wildcard import the TTDS lib class SecureResou...
24.657143
61
0.673233
""" REST API Resource Routing http://flask-restplus.readthedocs.io """ from datetime import datetime from flask import request from flask_restplus import Resource from .security import require_auth from . import api_rest from .func import * from .engine import * # wildcard import the TTDS lib class SecureResou...
567
22
284
ed0ad42fc1a7ca3834303f1c38e3ba12b01a27a1
3,470
py
Python
Simple Calc-Tkinter.py
sachinkatageri/Tkinter-Simple-calculator
a5ba889da12f34d2575ce5375cd9829ce2c538eb
[ "Apache-2.0" ]
null
null
null
Simple Calc-Tkinter.py
sachinkatageri/Tkinter-Simple-calculator
a5ba889da12f34d2575ce5375cd9829ce2c538eb
[ "Apache-2.0" ]
null
null
null
Simple Calc-Tkinter.py
sachinkatageri/Tkinter-Simple-calculator
a5ba889da12f34d2575ce5375cd9829ce2c538eb
[ "Apache-2.0" ]
null
null
null
#sachin_katageri #SKATCODE from tkinter import* me=Tk() me.geometry("354x460") me.title("CALCULATOR") melabel = Label(me,text="CALCULATOR",bg='White',font=("Times",30,'bold')) melabel.pack(side=TOP) me.config(background='Dark gray') textin=StringVar() operator="" metext=Entry(me,font=("Courier N...
35.050505
119
0.663112
#sachin_katageri #SKATCODE from tkinter import* me=Tk() me.geometry("354x460") me.title("CALCULATOR") melabel = Label(me,text="CALCULATOR",bg='White',font=("Times",30,'bold')) melabel.pack(side=TOP) me.config(background='Dark gray') textin=StringVar() operator="" def clickbut(number): #lambda:clickbu...
460
0
153
41248fa6c1e374694f0ade81b43b48b465184936
640
py
Python
Solver/Sorting.py
bchaiks/3D_Bin_Packing_Heuristics
f8c4ac1ec73f1b94287eb18fdcdff7bea685ec27
[ "MIT" ]
1
2021-03-17T03:36:58.000Z
2021-03-17T03:36:58.000Z
Solver/Sorting.py
bchaiks/3D_Bin_Packing_Heuristics
f8c4ac1ec73f1b94287eb18fdcdff7bea685ec27
[ "MIT" ]
1
2021-03-13T11:36:54.000Z
2021-03-16T03:42:11.000Z
Solver/Sorting.py
bchaiks/3D_Bin_Packing_Heuristics
f8c4ac1ec73f1b94287eb18fdcdff7bea685ec27
[ "MIT" ]
2
2020-11-10T15:24:16.000Z
2021-03-13T05:38:59.000Z
def SortArrayByArgMinIndex(array,index): ''' MAKE SURE TO SORT BY MOST IMPORTANT INDEX LAST!!! ''' a = array L = len(a) for i in range(L): temp = a[i] flag = 0 j = 0 while j < i and flag == 0: if temp[index] < a[j][index]: a[j+1] = a[j] a[j] = temp j += 1 else: flag = 1 return(a)
19.393939
58
0.61875
def Randomize(partObjects): # eventually want to randomize the order # and re-run the whole thing to get a broader # picture of the solution space return(partObjects) def SortArrayByArgMinIndex(array,index): ''' MAKE SURE TO SORT BY MOST IMPORTANT INDEX LAST!!! ''' a = array L = len(a) for i in range(L): te...
278
0
45
9f8cd2ddde865984af8946621f65626e1d20b95b
132
py
Python
conftest.py
mclellac/connery
d7444a46e023c8f5261d5b462ae970096cfecf0f
[ "EFL-2.0" ]
null
null
null
conftest.py
mclellac/connery
d7444a46e023c8f5261d5b462ae970096cfecf0f
[ "EFL-2.0" ]
null
null
null
conftest.py
mclellac/connery
d7444a46e023c8f5261d5b462ae970096cfecf0f
[ "EFL-2.0" ]
null
null
null
# This file lists files which should be ignored by pytest collect_ignore = ["setup.py", "connery.py", "connery/modules/ipython.py"]
44
73
0.75
# This file lists files which should be ignored by pytest collect_ignore = ["setup.py", "connery.py", "connery/modules/ipython.py"]
0
0
0
858037440c5f062f7910b0e62eaa39b16bfb5efd
252
py
Python
test/test_nas.py
yngtodd/nas
d2642f8b6910f40daf458504be04ff13869d3a75
[ "MIT" ]
6
2019-07-05T09:31:12.000Z
2021-04-28T06:41:09.000Z
test/test_nas.py
yngtodd/nas
d2642f8b6910f40daf458504be04ff13869d3a75
[ "MIT" ]
1
2020-02-28T01:21:41.000Z
2020-02-28T01:21:41.000Z
test/test_nas.py
yngtodd/nas
d2642f8b6910f40daf458504be04ff13869d3a75
[ "MIT" ]
1
2020-08-26T04:31:11.000Z
2020-08-26T04:31:11.000Z
""" Tests for `nas` module. """ import pytest from nas import nas
12.6
29
0.615079
""" Tests for `nas` module. """ import pytest from nas import nas class TestNas(object): @classmethod def setup_class(cls): pass def test_something(self): pass @classmethod def teardown_class(cls): pass
46
116
23
f8cda25e292e2fc1ec31f3eab7e56ffb77666b19
927
py
Python
za/fileToC/test.py
hth945/pytest
83e2aada82a2c6a0fdd1721320e5bf8b8fd59abc
[ "Apache-2.0" ]
null
null
null
za/fileToC/test.py
hth945/pytest
83e2aada82a2c6a0fdd1721320e5bf8b8fd59abc
[ "Apache-2.0" ]
null
null
null
za/fileToC/test.py
hth945/pytest
83e2aada82a2c6a0fdd1721320e5bf8b8fd59abc
[ "Apache-2.0" ]
null
null
null
#%% import os # IN_FILE = 'test.ncm' # OUT_FILE = IN_FILE.split('.')[0] fileToC('up5.html','htmlData') # %%
22.071429
80
0.536138
#%% import os # IN_FILE = 'test.ncm' # OUT_FILE = IN_FILE.split('.')[0] def fileToC(in_file, out_file): # 1 head and open IN_FILE=in_file OUT_FILE=out_file try: in_file = open(IN_FILE, 'rb') except Exception as e: print(e) return out_file = open(OUT_FILE+'.c', 'w') ...
793
0
23
010fc7a46411fd1fb19a7627a5c1ef23cb23efba
38,007
py
Python
model.py
Yan98/S2FGAN
14405875c0182735afa053ae4d8c67cebd1a6ab2
[ "MIT" ]
6
2020-12-08T13:08:08.000Z
2021-12-06T05:04:48.000Z
model.py
Yan98/S2FGAN
14405875c0182735afa053ae4d8c67cebd1a6ab2
[ "MIT" ]
1
2021-04-12T11:43:28.000Z
2021-10-31T23:59:40.000Z
model.py
Yan98/S2FGAN
14405875c0182735afa053ae4d8c67cebd1a6ab2
[ "MIT" ]
1
2021-11-04T00:28:47.000Z
2021-11-04T00:28:47.000Z
""" This module is the concrete implementation of S2FGAN. This module structure is following: make_kernel is used to intialise the kernel for blurring image Blur, a layer used to apply blur kerbel to input PixelNorm, a layer used to apply pixel normalization EqualConv1d, convolution 1d with equalized le...
34.086996
269
0.527876
""" This module is the concrete implementation of S2FGAN. This module structure is following: make_kernel is used to intialise the kernel for blurring image Blur, a layer used to apply blur kerbel to input PixelNorm, a layer used to apply pixel normalization EqualConv1d, convolution 1d with equalized le...
24,635
9,883
1,590
5a1d2a0240e421bf1d94e403e1e15b300f595f14
21,266
py
Python
site-packages/jedi/evaluate/finder.py
oz90210/Pyto
59f185149b71e57e5debeb1c9a61a28739e81720
[ "MIT" ]
null
null
null
site-packages/jedi/evaluate/finder.py
oz90210/Pyto
59f185149b71e57e5debeb1c9a61a28739e81720
[ "MIT" ]
1
2020-04-25T20:36:07.000Z
2020-04-25T20:36:07.000Z
site-packages/jedi/evaluate/finder.py
Wristlebane/Pyto
901ac307b68486d8289105c159ca702318bea5b0
[ "MIT" ]
null
null
null
#\input texinfo """ Searching for names with given scope and name. This is very central in Jedi and Python. The name resolution is quite complicated with descripter, ``__getattribute__``, ``__getattr__``, ``global``, etc. Flow checks +++++++++++ Flow checks are not really mature. There's only a check for ``isinstanc...
38.665455
114
0.622402
#\input texinfo """ Searching for names with given scope and name. This is very central in Jedi and Python. The name resolution is quite complicated with descripter, ``__getattribute__``, ``__getattr__``, ``global``, etc. Flow checks +++++++++++ Flow checks are not really mature. There's only a check for ``isinstanc...
10,655
2,020
91
c7a0017098f53e1aca17da21cef0ed3d90134016
4,135
py
Python
tools/generate-polls/generator/ansi_x931_aes128.py
pingjuiliao/cb-multios
64ededd0b87030eda7c40c4388a4ad8283712d8e
[ "MIT" ]
473
2016-08-01T12:48:16.000Z
2022-03-09T18:13:14.000Z
tools/generate-polls/generator/ansi_x931_aes128.py
pingjuiliao/cb-multios
64ededd0b87030eda7c40c4388a4ad8283712d8e
[ "MIT" ]
71
2016-08-01T03:33:44.000Z
2022-03-09T18:37:04.000Z
tools/generate-polls/generator/ansi_x931_aes128.py
pingjuiliao/cb-multios
64ededd0b87030eda7c40c4388a4ad8283712d8e
[ "MIT" ]
121
2016-08-01T04:07:53.000Z
2022-03-07T11:08:09.000Z
#!/usr/bin/env python """ A Python implementation of ANSI X9.31 using AES 128, following: http://csrc.nist.gov/groups/STM/cavp/documents/rng/931rngext.pdf Copyright (C) 2015 - Brian Caswell <bmc@lungetech.com> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associat...
30.858209
104
0.62636
#!/usr/bin/env python """ A Python implementation of ANSI X9.31 using AES 128, following: http://csrc.nist.gov/groups/STM/cavp/documents/rng/931rngext.pdf Copyright (C) 2015 - Brian Caswell <bmc@lungetech.com> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associat...
0
0
0
be16679000ce269e3f1016e7c63e3ecfdfb22cef
2,061
py
Python
Python/data_structure/segment_tree.py
NatsubiSogan/comp_library
9f06d947951db40e051bd506fd8722fb75c3688b
[ "Apache-2.0" ]
2
2021-09-05T13:17:01.000Z
2021-09-05T13:17:06.000Z
Python/data_structure/segment_tree.py
NatsubiSogan/comp_library
9f06d947951db40e051bd506fd8722fb75c3688b
[ "Apache-2.0" ]
null
null
null
Python/data_structure/segment_tree.py
NatsubiSogan/comp_library
9f06d947951db40e051bd506fd8722fb75c3688b
[ "Apache-2.0" ]
null
null
null
import typing # Segment Tree
22.9
84
0.534692
import typing # Segment Tree class SegmentTree: def __init__( self, lis: list, ele: typing.Any, op: typing.Callable[[typing.Any, typing.Any], typing.Any]) -> None: self.n = len(lis) self.log = (self.n - 1).bit_length() self.size = 1 << self.log self.op = op self.ele = ele self.tree = self._...
1,822
-3
213
ac1ea41500b4841349b0cc2485d44adb0c2d5525
1,292
py
Python
category_encoders/tests/test_cat_boost.py
hell00lleh/categorical-encoding
6a6cf0e9944eab298243635cd074c3f3d14b1b85
[ "BSD-3-Clause" ]
3
2019-09-29T15:10:26.000Z
2019-10-03T08:39:04.000Z
category_encoders/tests/test_cat_boost.py
hell00lleh/categorical-encoding
6a6cf0e9944eab298243635cd074c3f3d14b1b85
[ "BSD-3-Clause" ]
null
null
null
category_encoders/tests/test_cat_boost.py
hell00lleh/categorical-encoding
6a6cf0e9944eab298243635cd074c3f3d14b1b85
[ "BSD-3-Clause" ]
null
null
null
import pandas as pd from unittest2 import TestCase # or `from unittest import ...` if on Python 3.4+ import category_encoders as encoders
43.066667
147
0.575077
import pandas as pd from unittest2 import TestCase # or `from unittest import ...` if on Python 3.4+ import category_encoders as encoders class TestBinaryEncoder(TestCase): def test_catBoost(self): X = pd.DataFrame({'col1': ['A', 'B', 'B', 'C', 'A']}) y = pd.Series([1, 0, 1, 0, 1]) enc ...
1,061
13
77
ec2d3ee64d8ab2ff705f751b7a693c0dcc9904a3
828
py
Python
pythonioc/test/test_depcycle.py
leitelyaya/python-ioc
65e64272ce645a9ded71d30eb58c21832d917702
[ "MIT" ]
1
2017-06-30T13:49:47.000Z
2017-06-30T13:49:47.000Z
pythonioc/test/test_depcycle.py
leitelyaya/python-ioc
65e64272ce645a9ded71d30eb58c21832d917702
[ "MIT" ]
null
null
null
pythonioc/test/test_depcycle.py
leitelyaya/python-ioc
65e64272ce645a9ded71d30eb58c21832d917702
[ "MIT" ]
null
null
null
import unittest import pythonioc class TestDepCycle(unittest.TestCase): """ Regression test for issue #3 dependency cycle on error. """
25.875
83
0.661836
import unittest import pythonioc class SpecificException(Exception): pass class ErrorInitService(object): def postInit(self): raise SpecificException("not working") def doSomething(self): pass class TestDepCycle(unittest.TestCase): """ Regression test for issue #3 dependency cyc...
518
33
127
a897296890225c2cce7c01ab3c21865c3ffad118
1,627
py
Python
dploy/tasks/git.py
anton-shestakov/python-dploy
61ddd906c75bc41afaeeee8bce9d2ad5c7c68002
[ "MIT" ]
2
2018-03-21T17:45:08.000Z
2022-03-07T20:55:39.000Z
dploy/tasks/git.py
anton-shestakov/python-dploy
61ddd906c75bc41afaeeee8bce9d2ad5c7c68002
[ "MIT" ]
null
null
null
dploy/tasks/git.py
anton-shestakov/python-dploy
61ddd906c75bc41afaeeee8bce9d2ad5c7c68002
[ "MIT" ]
2
2018-03-09T09:11:43.000Z
2018-06-20T09:31:34.000Z
import os import fabtools from fabtools import require from fabric.api import task, sudo, cd from fabric.colors import cyan from dploy.context import ctx from dploy.utils import git_dirname @task def checkout(): """ Checkouts the code on the remote location using git """ branch = ctx('git.branch') ...
34.617021
71
0.579594
import os import fabtools from fabtools import require from fabric.api import task, sudo, cd from fabric.colors import cyan from dploy.context import ctx from dploy.utils import git_dirname @task def checkout(): """ Checkouts the code on the remote location using git """ branch = ctx('git.branch') ...
0
0
0
64c47b1f89956e061ac9631658410771a007f9cf
495
py
Python
S1/Q1.py
grharon/HFD
a6abca134f7a3d6766962eb89ab9e33125dab662
[ "CC0-1.0" ]
null
null
null
S1/Q1.py
grharon/HFD
a6abca134f7a3d6766962eb89ab9e33125dab662
[ "CC0-1.0" ]
null
null
null
S1/Q1.py
grharon/HFD
a6abca134f7a3d6766962eb89ab9e33125dab662
[ "CC0-1.0" ]
null
null
null
number = 100 factorialnumber = factorial(number) print(f"Factorial({number}) = {factorialnumber}") sumfactorialnumber = sum_of_digits(factorialnumber) print( f"Sum of digits in the factorial number({number}) = {sumfactorialnumber}")
23.571429
79
0.640404
def factorial(n): if n == 1 or n == 0: return 1 else: return n * factorial(n-1) def sum_of_digits(n): sum_of_digits = 0 for digit in str(n): sum_of_digits += int(digit) return sum_of_digits number = 100 factorialnumber = factorial(number) print(f"Factorial...
198
0
48
9276cadc1fb3cc5a0610a89dfa0a0b7421b2175c
20,617
py
Python
pysnmp-with-texts/HPN-ICF-STACK-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
8
2019-05-09T17:04:00.000Z
2021-06-09T06:50:51.000Z
pysnmp-with-texts/HPN-ICF-STACK-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
4
2019-05-31T16:42:59.000Z
2020-01-31T21:57:17.000Z
pysnmp-with-texts/HPN-ICF-STACK-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
10
2019-04-30T05:51:36.000Z
2022-02-16T03:33:41.000Z
# # PySNMP MIB module HPN-ICF-STACK-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/HPN-ICF-STACK-MIB # Produced by pysmi-0.3.4 at Wed May 1 13:41:29 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (default, Ma...
156.189394
1,999
0.786826
# # PySNMP MIB module HPN-ICF-STACK-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/HPN-ICF-STACK-MIB # Produced by pysmi-0.3.4 at Wed May 1 13:41:29 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (default, Ma...
0
0
0
ddc6fba39e2884441d6015cadffdc8b157512ecc
25,625
py
Python
hwrt/features.py
MartinThoma/hwrt
7b274fa3022292bb1215eaec99f1826f64f98a07
[ "MIT" ]
65
2015-04-08T12:11:22.000Z
2022-02-28T23:46:53.000Z
hwrt/features.py
MartinThoma/hwrt
7b274fa3022292bb1215eaec99f1826f64f98a07
[ "MIT" ]
35
2015-01-05T11:56:30.000Z
2022-03-12T00:55:38.000Z
hwrt/features.py
MartinThoma/hwrt
7b274fa3022292bb1215eaec99f1826f64f98a07
[ "MIT" ]
18
2015-01-19T15:57:25.000Z
2021-02-15T20:38:32.000Z
""" Feature extraction algorithms. Each algorithm works on the HandwrittenData class. They have to be applied like this: >>> import hwrt.features >>> from hwrt.handwritten_data import HandwrittenData >>> data_json = '[[{"time": 123, "x": 45, "y": 67}]]' >>> a = HandwrittenData(raw_data_id=2953, raw_data_json=data_jso...
31.557882
88
0.554302
""" Feature extraction algorithms. Each algorithm works on the HandwrittenData class. They have to be applied like this: >>> import hwrt.features >>> from hwrt.handwritten_data import HandwrittenData >>> data_json = '[[{"time": 123, "x": 45, "y": 67}]]' >>> a = HandwrittenData(raw_data_id=2953, raw_data_json=data_jso...
7,523
0
1,323
8a62813cebb672de3944eea8a62b8afb8631e71b
1,553
py
Python
pinguin/views.py
OpenHackC4H/2017-Gothenburg-Pinguin
aac60014973e130977f3ef9a78b41b67a13cc527
[ "MIT" ]
1
2018-05-05T18:25:47.000Z
2018-05-05T18:25:47.000Z
pinguin/views.py
OpenHackC4H/2017-Gothenburg-Pinguin
aac60014973e130977f3ef9a78b41b67a13cc527
[ "MIT" ]
null
null
null
pinguin/views.py
OpenHackC4H/2017-Gothenburg-Pinguin
aac60014973e130977f3ef9a78b41b67a13cc527
[ "MIT" ]
null
null
null
from rest_framework import permissions, viewsets, generics, filters from .serializers import JobsSerializer, HousingSerializer, ApplicantSerializer, HeatmapSerializer from .models import Jobs, Housing, Applicant, Heatmap from .data_collection.collect_data import CollectData from django.shortcuts import render debug...
36.97619
98
0.777849
from rest_framework import permissions, viewsets, generics, filters from .serializers import JobsSerializer, HousingSerializer, ApplicantSerializer, HeatmapSerializer from .models import Jobs, Housing, Applicant, Heatmap from .data_collection.collect_data import CollectData from django.shortcuts import render debug...
47
1,027
115
130e54d3a59f85155c18c48d82dfb5f339ff8926
5,222
py
Python
app/recipe/views.py
mydjangoprojects/recipe-mpa
bb36b3f488fcce3292be2f23e4201c1286fe113c
[ "MIT" ]
null
null
null
app/recipe/views.py
mydjangoprojects/recipe-mpa
bb36b3f488fcce3292be2f23e4201c1286fe113c
[ "MIT" ]
null
null
null
app/recipe/views.py
mydjangoprojects/recipe-mpa
bb36b3f488fcce3292be2f23e4201c1286fe113c
[ "MIT" ]
null
null
null
from django.views.generic import DetailView from django.contrib.auth.mixins import LoginRequiredMixin, UserPassesTestMixin from django.views.generic.edit import CreateView, UpdateView, DeleteView from django.urls import reverse_lazy from core.views import PaginatedListView from .models import Tag, Ingredient, Recipe ...
27.484211
78
0.684795
from django.views.generic import DetailView from django.contrib.auth.mixins import LoginRequiredMixin, UserPassesTestMixin from django.views.generic.edit import CreateView, UpdateView, DeleteView from django.urls import reverse_lazy from core.views import PaginatedListView from .models import Tag, Ingredient, Recipe ...
1,317
2,600
494
d58f899d295336781afad98b29f2d573fa14549f
510
py
Python
tests/test_encrypt.py
realityone/CetTicket
1a1cb7eec89061bda27435ee618802e30b2bf6f9
[ "MIT" ]
3
2015-05-13T16:10:52.000Z
2015-07-16T10:24:53.000Z
tests/test_encrypt.py
realityone/CetTicket
1a1cb7eec89061bda27435ee618802e30b2bf6f9
[ "MIT" ]
null
null
null
tests/test_encrypt.py
realityone/CetTicket
1a1cb7eec89061bda27435ee618802e30b2bf6f9
[ "MIT" ]
null
null
null
import unittest from libcet import cet
28.333333
94
0.672549
import unittest from libcet import cet class TestEncrypt(unittest.TestCase): def setUp(self): self.crypter = cet.CETCrypter('021yO6d<', 'QghdW;O;') def test_encrypt(self): plaintext = '123456789' self.assertEqual( plaintext, self.crypter.decrypt_ticket_number(...
377
16
76
2143068b1ccbc1e5fe085bbcd5a31d3a3cfd047d
199
py
Python
paranuara/companies/apps.py
SPLAYER-HD/Paranuara
5a42f23d761e16e3b486ba04d9185551614f06a5
[ "MIT" ]
null
null
null
paranuara/companies/apps.py
SPLAYER-HD/Paranuara
5a42f23d761e16e3b486ba04d9185551614f06a5
[ "MIT" ]
4
2021-06-08T20:53:43.000Z
2022-03-12T00:13:51.000Z
paranuara/companies/apps.py
SPLAYER-HD/RestServiceDjango
5a42f23d761e16e3b486ba04d9185551614f06a5
[ "MIT" ]
null
null
null
"""Companies app""" # Django from django.apps import AppConfig class CompaniesAppConfig(AppConfig): """Companies app config""" name = "paranuara.companies" verbose_name = 'Companies'
16.583333
36
0.703518
"""Companies app""" # Django from django.apps import AppConfig class CompaniesAppConfig(AppConfig): """Companies app config""" name = "paranuara.companies" verbose_name = 'Companies'
0
0
0
80f9effd20d0ca021438532f79cd34779410673a
210
py
Python
examples/slots_simple.py
BarnabasSzabolcs/pyquasargui
0ac684094c5a87dbb1a3ed1ff83f33c603d97e5a
[ "MIT" ]
2
2021-09-06T20:23:43.000Z
2022-02-02T18:24:35.000Z
examples/slots_simple.py
BarnabasSzabolcs/pyquasargui
0ac684094c5a87dbb1a3ed1ff83f33c603d97e5a
[ "MIT" ]
1
2022-02-27T01:19:14.000Z
2022-02-27T01:19:14.000Z
examples/slots_simple.py
BarnabasSzabolcs/pyquasargui
0ac684094c5a87dbb1a3ed1ff83f33c603d97e5a
[ "MIT" ]
null
null
null
from quasargui import * layout = QInput( classes='q-ma-lg', label='Your city', children=[ Slot('prepend', [ QIcon('place') ]) ]) run(layout, title='slots example')
16.153846
34
0.528571
from quasargui import * layout = QInput( classes='q-ma-lg', label='Your city', children=[ Slot('prepend', [ QIcon('place') ]) ]) run(layout, title='slots example')
0
0
0
7cd31469139c7761ef44fc5874f8112465fade84
4,716
py
Python
torchvision/prototype/datasets/_builtin/pcam.py
yassineAlouini/vision-1
ee26e9c260a255e2afb5e691e713349529170c8b
[ "BSD-3-Clause" ]
1
2022-02-14T09:16:02.000Z
2022-02-14T09:16:02.000Z
torchvision/prototype/datasets/_builtin/pcam.py
yassineAlouini/vision-1
ee26e9c260a255e2afb5e691e713349529170c8b
[ "BSD-3-Clause" ]
null
null
null
torchvision/prototype/datasets/_builtin/pcam.py
yassineAlouini/vision-1
ee26e9c260a255e2afb5e691e713349529170c8b
[ "BSD-3-Clause" ]
null
null
null
import io import pathlib from collections import namedtuple from typing import Any, Dict, List, Optional, Tuple, Iterator, Union from torchdata.datapipes.iter import IterDataPipe, Mapper, Zipper from torchvision.prototype import features from torchvision.prototype.datasets.utils import ( Dataset, OnlineResourc...
35.19403
105
0.638465
import io import pathlib from collections import namedtuple from typing import Any, Dict, List, Optional, Tuple, Iterator, Union from torchdata.datapipes.iter import IterDataPipe, Mapper, Zipper from torchvision.prototype import features from torchvision.prototype.datasets.utils import ( Dataset, OnlineResourc...
1,872
35
233