hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
⌀
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
⌀
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
⌀
max_issues_repo_path
stringlengths
4
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
⌀
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
⌀
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
⌀
max_forks_repo_path
stringlengths
4
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
⌀
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
⌀
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
⌀
content
stringlengths
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
bee468c964a6fb4903f2629f30bffa047bf79725
323
py
Python
run_tests.py
vatula/capi
ee2f4c01bd4458d71893b850aa95051cd8ebda90
[ "MIT" ]
null
null
null
run_tests.py
vatula/capi
ee2f4c01bd4458d71893b850aa95051cd8ebda90
[ "MIT" ]
null
null
null
run_tests.py
vatula/capi
ee2f4c01bd4458d71893b850aa95051cd8ebda90
[ "MIT" ]
null
null
null
import os from capi.test_common.run_test_command import run_command def main(): print(f"Cwd: {os.getcwd()}") options = [ "--black", "--isort", "--pylint", "--mypy", ] run_command(["python3", "-m", "pytest", *options, "capi/test"]) if __name__ == "__main__": main...
16.15
67
0.535604
7e3c8b768faad640afbaf49307a651f4dacec70e
2,204
py
Python
official/cv/psenet/infer/sdk/dataset.py
mindspore-ai/models
9127b128e2961fd698977e918861dadfad00a44c
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
official/cv/psenet/infer/sdk/dataset.py
mindspore-ai/models
9127b128e2961fd698977e918861dadfad00a44c
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
official/cv/psenet/infer/sdk/dataset.py
mindspore-ai/models
9127b128e2961fd698977e918861dadfad00a44c
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2021 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
39.357143
87
0.642015
b8098dfb9218873869c14a2968cdc7938eda297f
163
py
Python
src/stream/protocol/packets.py
dzikoysk/cefstream
48843b6f4222b68b97237437bfde36910637736c
[ "Apache-2.0" ]
5
2018-02-11T17:04:52.000Z
2020-08-17T10:24:16.000Z
src/stream/protocol/packets.py
dzikoysk/cefstream
48843b6f4222b68b97237437bfde36910637736c
[ "Apache-2.0" ]
2
2018-06-19T21:15:35.000Z
2018-06-19T21:15:40.000Z
src/stream/protocol/packets.py
dzikoysk/CefStream
48843b6f4222b68b97237437bfde36910637736c
[ "Apache-2.0" ]
null
null
null
from enum import Enum class Packets(Enum): SHUTDOWN_SERVERBOUND_PACKET = 0x00 FRAME_DATA_CLIENTBOUND_PACKET = 0x00 FRAME_CLIENTBOUND_PACKET = 0x01
16.3
40
0.773006
4b4305f72c51a9e186107a64ef1d526bf5916e03
343
py
Python
exercise/newfile99.py
LeeBeral/python
9f0d360d69ee5245e3ef13a9dc9fc666374587a4
[ "MIT" ]
null
null
null
exercise/newfile99.py
LeeBeral/python
9f0d360d69ee5245e3ef13a9dc9fc666374587a4
[ "MIT" ]
null
null
null
exercise/newfile99.py
LeeBeral/python
9f0d360d69ee5245e3ef13a9dc9fc666374587a4
[ "MIT" ]
null
null
null
urls = ['<html><h1>www.itcast.cn</h1></html>','<html><h2>www.itcast.cn</h2></html>','<html><h1>www.itcast.com</h1></html>'] import re for url in urls: # ret = re.match(r'<(\w*)><(\w*)>.*?</2></1>',url) ret = re.match(r'<\w*><h1>(.*?)</h1>',url) if ret: print('right url:%s'%ret.group(1)) else: pri...
24.5
124
0.521866
35e925764198d8a9021d30e08d0e4fe928c77727
8,380
py
Python
bot/plugins/listeners.py
Jack-Gledhill/bugbot
08760712c09fcd93045c362deec8e921eb2fc147
[ "MIT" ]
2
2020-07-26T16:12:13.000Z
2020-08-01T02:35:00.000Z
bot/plugins/listeners.py
Jack-Gledhill/bugbot
08760712c09fcd93045c362deec8e921eb2fc147
[ "MIT" ]
4
2020-07-26T16:42:43.000Z
2021-08-24T00:32:34.000Z
bot/plugins/listeners.py
Jack-Gledhill/bugbot
08760712c09fcd93045c362deec8e921eb2fc147
[ "MIT" ]
null
null
null
import discord from aiohttp import ClientSession from datetime import datetime from discord.ext import commands from plugins.postgres import Report def extra(emoji: str, extras: list) -> str: """Formats a list of extras (i.e. approves, denies, notes and attachments) with the provided emoji.""" if ...
41.9
481
0.530668
90227885bdd8e8296ea51b3f98a610372df9161d
265
py
Python
src/api_insee/exeptions/request_exeption.py
mxdev88/api_insee
383143b9c8e63063a889b7797e989dac9fd0de5b
[ "MIT" ]
9
2019-01-10T17:35:24.000Z
2020-04-18T20:44:45.000Z
src/api_insee/exeptions/request_exeption.py
mxdev88/api_insee
383143b9c8e63063a889b7797e989dac9fd0de5b
[ "MIT" ]
5
2020-06-04T21:34:49.000Z
2022-03-14T17:58:03.000Z
src/api_insee/exeptions/request_exeption.py
ln-nicolas/api_insee
383143b9c8e63063a889b7797e989dac9fd0de5b
[ "MIT" ]
3
2020-07-04T18:53:30.000Z
2021-02-04T13:20:03.000Z
class RequestExeption(Exception): def __init__(self, request): self.request = request def badRequest(self): self.message = "bad request url : %s" % self.request.url return self def __str__(self): return self.message
18.928571
64
0.626415
aa3eab9ebd139f109999660fc380d16230cb7507
2,979
py
Python
lip_model/preproc_and_aug.py
souravdeyone/deep_lip_reading
7dea34899c9124400c33566a9a9483c971c2c999
[ "Apache-2.0" ]
154
2019-05-17T07:51:40.000Z
2022-03-21T18:40:30.000Z
lip_model/preproc_and_aug.py
souravdeyone/deep_lip_reading
7dea34899c9124400c33566a9a9483c971c2c999
[ "Apache-2.0" ]
11
2019-05-31T09:37:08.000Z
2022-03-16T05:03:22.000Z
lip_model/preproc_and_aug.py
souravdeyone/deep_lip_reading
7dea34899c9124400c33566a9a9483c971c2c999
[ "Apache-2.0" ]
49
2019-05-21T13:32:10.000Z
2022-03-16T00:00:46.000Z
from util.tf_util import shape_list from tensorflow.python.ops import array_ops, random_ops, math_ops, control_flow_ops import tensorflow as tf def wrap_in_training_phase(train_out, test_out, name=None): # This has been hardcoded for evaluation code where we only use the function for test # time augmentation. For ...
37.708861
110
0.731789
a443d259511e0eb29737bfe44027cf62c41d1af5
13,700
py
Python
multiscale_prey_predator/second_order_model.py
danlessa/multiscale_prey_predator
b1b8cbd526431caf07f2caca2ce8b197dba44548
[ "MIT" ]
null
null
null
multiscale_prey_predator/second_order_model.py
danlessa/multiscale_prey_predator
b1b8cbd526431caf07f2caca2ce8b197dba44548
[ "MIT" ]
null
null
null
multiscale_prey_predator/second_order_model.py
danlessa/multiscale_prey_predator
b1b8cbd526431caf07f2caca2ce8b197dba44548
[ "MIT" ]
null
null
null
import random from uuid import UUID, uuid4 import numpy as np from typing import Sequence, Union # Initialization def new_agent(agent_type: str, location: tuple[int, int], food: int = 10, age: int = 0) -> dict: agent = {'type': agent_type, 'location': location, 'food': fo...
33.743842
145
0.623139
d95faf890098c42b1bb8cae41d3905f03b4e95c8
20,843
py
Python
ceptic/client.py
Kosinkadink/ceptic
06d03ffbad6c28e40c541053218dbea7383eea1c
[ "MIT" ]
2
2017-07-18T03:12:12.000Z
2019-11-21T20:00:25.000Z
ceptic/client.py
Kosinkadink/ceptic
06d03ffbad6c28e40c541053218dbea7383eea1c
[ "MIT" ]
null
null
null
ceptic/client.py
Kosinkadink/ceptic
06d03ffbad6c28e40c541053218dbea7383eea1c
[ "MIT" ]
null
null
null
import json import socket import copy import uuid import threading from ceptic.network import SocketCeptic from ceptic.common import CepticResponse, CepticRequest, CepticException from ceptic.common import CepticStatusCode, command_settings from ceptic.endpointmanager import EndpointManager from ceptic.certificatemana...
45.31087
145
0.63441
c2f8761829b15f53cbb6d1bb554da54a602750ca
7,638
py
Python
experiments/sasha/testing/vae/vae-dense.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
experiments/sasha/testing/vae/vae-dense.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
experiments/sasha/testing/vae/vae-dense.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
import rlkit.misc.hyperparameter as hyp from experiments.murtaza.multiworld.skew_fit.reacher.generate_uniform_dataset import generate_uniform_dataset_reacher from multiworld.envs.mujoco.cameras import sawyer_init_camera_zoomed_in, sawyer_pusher_camera_upright_v2 from rlkit.launchers.launcher_util import run_experiment ...
35.525581
121
0.577376
2a95dd5c14456b5d060bf6d76f1f0b64ebb4bd9d
3,332
py
Python
homeassistant/components/shell_command.py
dauden1184/home-assistant
f4c6d389b77d0efa86644e76604eaea5d21abdb5
[ "Apache-2.0" ]
4
2019-01-10T14:47:54.000Z
2021-04-22T02:06:27.000Z
homeassistant/components/shell_command.py
dauden1184/home-assistant
f4c6d389b77d0efa86644e76604eaea5d21abdb5
[ "Apache-2.0" ]
5
2021-02-08T20:50:07.000Z
2022-03-12T00:39:31.000Z
homeassistant/components/shell_command.py
dauden1184/home-assistant
f4c6d389b77d0efa86644e76604eaea5d21abdb5
[ "Apache-2.0" ]
3
2018-08-29T19:26:20.000Z
2020-01-19T11:58:22.000Z
""" Exposes regular shell commands as services. For more details about this platform, please refer to the documentation at https://home-assistant.io/components/shell_command/ """ import asyncio import logging import shlex import voluptuous as vol from homeassistant.exceptions import TemplateError from homeassistant....
32.666667
77
0.60114
cbf038579f14e439d0af607b0a71c78d679cefc7
148
py
Python
test/foolib/util.py
xkortex/protosanity
1acdeeb8862bbdfe4e304eecccbad815ae6f44b3
[ "MIT" ]
null
null
null
test/foolib/util.py
xkortex/protosanity
1acdeeb8862bbdfe4e304eecccbad815ae6f44b3
[ "MIT" ]
null
null
null
test/foolib/util.py
xkortex/protosanity
1acdeeb8862bbdfe4e304eecccbad815ae6f44b3
[ "MIT" ]
null
null
null
import time try: ns = time.time_ns() time_ns = time.time_ns except AttributeError: def time_ns(): return int(time.time() * 1e9)
18.5
37
0.635135
d7de10a6116c9209b26b6dcf424dbcdc587c53a6
4,711
py
Python
test/py/ganeti.utils.lvm_unittest.py
apyrgio/snf-ganeti
c59bb92f5bf4a98d90b4f10fb509a5a2f11c65b7
[ "BSD-2-Clause" ]
2
2018-09-26T10:09:23.000Z
2018-09-27T07:27:06.000Z
test/py/ganeti.utils.lvm_unittest.py
apyrgio/snf-ganeti
c59bb92f5bf4a98d90b4f10fb509a5a2f11c65b7
[ "BSD-2-Clause" ]
null
null
null
test/py/ganeti.utils.lvm_unittest.py
apyrgio/snf-ganeti
c59bb92f5bf4a98d90b4f10fb509a5a2f11c65b7
[ "BSD-2-Clause" ]
null
null
null
#!/usr/bin/python # # Copyright (C) 2013 Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # 1. Redistributions of source code must retain the above copyright notice, # this list of...
39.588235
77
0.720442
1c5f493d2a89a42180d4079318bf8bf705e7c27c
4,307
py
Python
tests/sae/test_eb_unit_model.py
samplics-org/samplics
b5f49d075194cc24208f567e6a00e86aa24bec26
[ "MIT" ]
14
2021-05-03T19:59:58.000Z
2022-03-27T18:58:36.000Z
tests/sae/test_eb_unit_model.py
samplics-org/samplics
b5f49d075194cc24208f567e6a00e86aa24bec26
[ "MIT" ]
8
2021-06-17T01:13:01.000Z
2022-03-27T18:31:15.000Z
tests/sae/test_eb_unit_model.py
survey-methods/samplics
4a0f6ea6168afb74c2ea2c958fb76c7d27dfba83
[ "MIT" ]
2
2020-05-28T20:09:48.000Z
2021-01-19T17:34:22.000Z
import numpy as np import pandas as pd from samplics.sae.eb_unit_model import EbUnitModel incomesample = pd.read_csv("./tests/sae/incomedata.csv") areas = incomesample["prov"] ys = incomesample["income"] Xs = incomesample[ ["age2", "age3", "age4", "age5", "nat1", "educ1", "educ3", "labor1", "labor2"] ].to_numpy...
22.909574
96
0.623172
b96db73e3929b398bc87f3e065328d11f25920b8
12,490
py
Python
takeover.py
bbhunter/takeover-1
a05864768c8f05025b1008c29b16b01e6a70324d
[ "MIT" ]
688
2018-06-08T21:21:24.000Z
2022-03-31T23:44:16.000Z
takeover.py
bbhunter/takeover-1
a05864768c8f05025b1008c29b16b01e6a70324d
[ "MIT" ]
38
2018-06-14T17:29:22.000Z
2022-02-26T16:21:38.000Z
takeover.py
bbhunter/takeover-1
a05864768c8f05025b1008c29b16b01e6a70324d
[ "MIT" ]
180
2018-06-14T03:21:59.000Z
2022-03-27T09:41:16.000Z
#!/usr/bin/env python3 # takeover - subdomain takeover finder # coded by M'hamed (@m4ll0k) Outaadi import os import json import requests import urllib.parse import concurrent.futures as thread import urllib3 import getopt import sys import re r = '\033[1;31m' g = '\033[1;32m' y = '\033[1;33m' b = '\033[1;34m' r_ = '...
33.940217
157
0.548199
fc079589f36030c91dd2e56b0114681f4980524b
71
py
Python
hypernets/__init__.py
lyhue1991/Hypernets
d726bd297869eacb0cba84376fbac30206bbb60a
[ "Apache-2.0" ]
3
2022-03-25T23:27:44.000Z
2022-03-27T01:32:28.000Z
hypernets/__init__.py
lyhue1991/Hypernets
d726bd297869eacb0cba84376fbac30206bbb60a
[ "Apache-2.0" ]
null
null
null
hypernets/__init__.py
lyhue1991/Hypernets
d726bd297869eacb0cba84376fbac30206bbb60a
[ "Apache-2.0" ]
null
null
null
# -*- coding:utf-8 -*- __author__ = 'yangjian' __version__ = '0.2.5.2'
17.75
23
0.605634
ccd2d3e9b6fdbddd0141057e4d95fe3a1805eb16
2,713
py
Python
src/Diagnostics.AIProjects/SearchAPI/AuthModule/certauth.py
YairoR/Azure-AppServices-Diagnostics
1329c84c6e6cb34914ae9e7ac5c89308db8c171b
[ "MIT" ]
null
null
null
src/Diagnostics.AIProjects/SearchAPI/AuthModule/certauth.py
YairoR/Azure-AppServices-Diagnostics
1329c84c6e6cb34914ae9e7ac5c89308db8c171b
[ "MIT" ]
null
null
null
src/Diagnostics.AIProjects/SearchAPI/AuthModule/certauth.py
YairoR/Azure-AppServices-Diagnostics
1329c84c6e6cb34914ae9e7ac5c89308db8c171b
[ "MIT" ]
null
null
null
from cryptography import x509 from cryptography.hazmat.backends import default_backend from cryptography.x509.oid import NameOID import datetime from SearchModule import app def validateCertificate(certStr): if not certStr: return ("Empty certificate value", False) try: certStr = ''.join(['----...
47.596491
178
0.683745
55357fb9ee806410af61b5f9add794d70876b976
9,979
py
Python
cogs/events/discord_py/on_command_error.py
ylPrayForDope/death-fun
d1350bfbb819fea982fd1f37b4a57f0c0af4fd4a
[ "MIT" ]
null
null
null
cogs/events/discord_py/on_command_error.py
ylPrayForDope/death-fun
d1350bfbb819fea982fd1f37b4a57f0c0af4fd4a
[ "MIT" ]
null
null
null
cogs/events/discord_py/on_command_error.py
ylPrayForDope/death-fun
d1350bfbb819fea982fd1f37b4a57f0c0af4fd4a
[ "MIT" ]
null
null
null
import datetime import os import discord from discord.ext import commands from discord.ext.commands import ( CommandNotFound, MissingRequiredArgument, CommandOnCooldown, BotMissingPermissions, NotOwner, BadArgument, MissingPermissions, Bot, NSFWChannelRequired, DisabledCommand, ) f...
42.46383
192
0.563183
0835c9eb060677b258eefc3f8a3551362c49aafb
3,245
py
Python
Audio_prep.py
tejashwatiwari/Emotional_Audio
6d057637651891528d58eefe9a16b1ef3d0e0cb1
[ "CC-BY-4.0" ]
null
null
null
Audio_prep.py
tejashwatiwari/Emotional_Audio
6d057637651891528d58eefe9a16b1ef3d0e0cb1
[ "CC-BY-4.0" ]
null
null
null
Audio_prep.py
tejashwatiwari/Emotional_Audio
6d057637651891528d58eefe9a16b1ef3d0e0cb1
[ "CC-BY-4.0" ]
null
null
null
import librosa, librosa.display import matplotlib.pyplot as plt import plotly.graph_objects as go import numpy as np file = 'sample_audio.wav' # Waveform_____ # We'll first load the file using librosa.load(), which will take in the path of the file and the sample rate # It shall return signal and the sampl...
42.697368
129
0.706626
585f57766ccbb7946e1e1706bb362a6ff0f40fbb
242,631
py
Python
keystone/tests/unit/test_v3_auth.py
lostmap/keystone
9a9022600e01ea09131cf194ffa5c1757ffeb24f
[ "Apache-2.0" ]
null
null
null
keystone/tests/unit/test_v3_auth.py
lostmap/keystone
9a9022600e01ea09131cf194ffa5c1757ffeb24f
[ "Apache-2.0" ]
null
null
null
keystone/tests/unit/test_v3_auth.py
lostmap/keystone
9a9022600e01ea09131cf194ffa5c1757ffeb24f
[ "Apache-2.0" ]
null
null
null
# Copyright 2012 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in...
42.514631
79
0.628757
5253d10116ab77077c150cdb320d2f8b7a45b6d0
4,927
py
Python
weed_annotator/image_composition/leave_sampler.py
RGring/WeedAnnotator
4afe130b9ecf24a8173ca7ee625667e2032d625d
[ "BSD-3-Clause" ]
10
2020-10-28T13:59:54.000Z
2021-10-12T11:33:24.000Z
weed_annotator/image_composition/leave_sampler.py
RGring/WeedAnnotator
4afe130b9ecf24a8173ca7ee625667e2032d625d
[ "BSD-3-Clause" ]
null
null
null
weed_annotator/image_composition/leave_sampler.py
RGring/WeedAnnotator
4afe130b9ecf24a8173ca7ee625667e2032d625d
[ "BSD-3-Clause" ]
null
null
null
import albumentations as albu import glob import random import cv2 import numpy as np import randomcolor from PIL import ImageColor import sys class LeaveSampler: def __init__(self, crop_folder, aug_config): self._crop_folder = crop_folder self._static_augmentations = self._get_static_augmentations...
38.795276
146
0.642379
601a383314d83222c7ce48c83114dc62b5e5c43b
37,508
py
Python
lingvodoc/utils/statistics.py
IgorBMSTU/lingvodoc
54afdbc8b7380a092bb45e37c8719830a05ec722
[ "Apache-2.0" ]
1
2018-08-23T16:07:34.000Z
2018-08-23T16:07:34.000Z
lingvodoc/utils/statistics.py
IgorBMSTU/lingvodoc
54afdbc8b7380a092bb45e37c8719830a05ec722
[ "Apache-2.0" ]
null
null
null
lingvodoc/utils/statistics.py
IgorBMSTU/lingvodoc
54afdbc8b7380a092bb45e37c8719830a05ec722
[ "Apache-2.0" ]
null
null
null
# Standard library imports. import ast import collections import datetime import io import logging import pdb import pprint import traceback # External imports. from pyramid.response import Response from pyramid.view import view_config from sqlalchemy import and_, BigInteger, cast, extract, func, tuple_ from sqlal...
44.388166
108
0.595633
0f4f5f6d3be573af6663e4d839ad0309ab308197
3,781
py
Python
contrib/macdeploy/custom_dsstore.py
Banxcoin-BXN/Banxcoin
10ee75ed6c22381e51882ff85c0fa92806c03890
[ "MIT" ]
1
2019-08-07T02:48:06.000Z
2019-08-07T02:48:06.000Z
contrib/macdeploy/custom_dsstore.py
Banxcoin-BXN/Banxcoin
10ee75ed6c22381e51882ff85c0fa92806c03890
[ "MIT" ]
null
null
null
contrib/macdeploy/custom_dsstore.py
Banxcoin-BXN/Banxcoin
10ee75ed6c22381e51882ff85c0fa92806c03890
[ "MIT" ]
1
2019-08-28T14:59:05.000Z
2019-08-28T14:59:05.000Z
#!/usr/bin/env python # Copyright (c) 2013-2016 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. from __future__ import division,print_function,unicode_literals import biplist from ds_store import DSStore...
61.983607
1,817
0.72785
d2235a548691bbde36f35b6ce963ab86c8312a87
3,348
py
Python
19T2/11_GUIBasic/mathtui.py
photomz/learn-python3
9dba54c1ec06b9b238b70cb9c697687799616e3a
[ "MIT" ]
null
null
null
19T2/11_GUIBasic/mathtui.py
photomz/learn-python3
9dba54c1ec06b9b238b70cb9c697687799616e3a
[ "MIT" ]
null
null
null
19T2/11_GUIBasic/mathtui.py
photomz/learn-python3
9dba54c1ec06b9b238b70cb9c697687799616e3a
[ "MIT" ]
null
null
null
from random import randint, choice def getIntInput(message, domain=None): cin = None while cin == None: try: cin = int(input(message)) if domain and cin not in domain: cin = None except ValueError: print("Oops! Did you accidentally type a string instead of a...
33.818182
124
0.611708
083700e72fc97fd6f08151ca0f48f93af6f19ebd
3,563
py
Python
DataGeneratorWithKafka/producer.py
joselra98/Data-Project-1
0d90e9e7c9807a9aed60eaf485e9b60f09843053
[ "Apache-2.0" ]
null
null
null
DataGeneratorWithKafka/producer.py
joselra98/Data-Project-1
0d90e9e7c9807a9aed60eaf485e9b60f09843053
[ "Apache-2.0" ]
null
null
null
DataGeneratorWithKafka/producer.py
joselra98/Data-Project-1
0d90e9e7c9807a9aed60eaf485e9b60f09843053
[ "Apache-2.0" ]
null
null
null
# NO TOCAR from faker import Faker import keyboard import time import random from datetime import datetime from time import sleep from json import dumps from kafka import KafkaProducer faker = Faker('es_ES') USERS_TOTAL=100 users={} lat_min=39.4 lat_max=39.5 lon_min=-0.3 lon_max=-0.4 vehicles=["Bike","Train","Car", ...
33.299065
92
0.565254
f86b0956069aea5409709f828d7d19ad6b58536a
2,131
py
Python
services/auto-analyze/setup.py
riyazuddinsyed/namex
c100ef4378794f509b738d38276e3b902d26067a
[ "Apache-2.0" ]
null
null
null
services/auto-analyze/setup.py
riyazuddinsyed/namex
c100ef4378794f509b738d38276e3b902d26067a
[ "Apache-2.0" ]
null
null
null
services/auto-analyze/setup.py
riyazuddinsyed/namex
c100ef4378794f509b738d38276e3b902d26067a
[ "Apache-2.0" ]
null
null
null
# Copyright © 2020 Province of British Columbia. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agr...
30.442857
86
0.699672
4c2f77fa05e11d97343fb7917f7f9fe40606ebbf
7,190
py
Python
kubeflow/components/model/train.py
WillianFuks/pySearchML
321c002911101251e22c987093b07fa39afe785e
[ "MIT" ]
27
2020-07-30T20:54:56.000Z
2022-02-16T17:23:18.000Z
kubeflow/components/model/train.py
WillianFuks/pySearchML
321c002911101251e22c987093b07fa39afe785e
[ "MIT" ]
null
null
null
kubeflow/components/model/train.py
WillianFuks/pySearchML
321c002911101251e22c987093b07fa39afe785e
[ "MIT" ]
3
2021-03-02T10:21:17.000Z
2021-11-08T14:39:38.000Z
import sys import os import argparse import pathlib from datetime import datetime from typing import NamedTuple, Sequence from functools import partial from multiprocessing import Pool from shutil import copyfile import requests from validate import validate_model def main(args: NamedTuple, X: Sequence[str]) -> Non...
32.681818
88
0.614186
814446118932c0d3e1ba391cec6435320750edf4
1,759
py
Python
samples/visual-recognition/compare_face_to_collection.py
ricohapi/ricoh-cloud-sdk-python
740d778c678e6097e3c35478545cbf283276a7ee
[ "MIT" ]
2
2018-08-14T21:01:07.000Z
2019-12-16T07:21:09.000Z
samples/visual-recognition/compare_face_to_collection.py
ricohapi/ricoh-cloud-sdk-python
740d778c678e6097e3c35478545cbf283276a7ee
[ "MIT" ]
null
null
null
samples/visual-recognition/compare_face_to_collection.py
ricohapi/ricoh-cloud-sdk-python
740d778c678e6097e3c35478545cbf283276a7ee
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2017 Ricoh Co., Ltd. All Rights Reserved. """Compare face to collection sample.""" from __future__ import print_function import argparse import json from PIL import Image, ImageDraw from vr_utils import create_vrs_client, draw_rectangle, get_collection_id, ClientError def com...
32.574074
86
0.678226
b5cf1ba36bb0b299b26d3a73ee5efd76c28f54e4
900
py
Python
river/time_series/base.py
fox-ds/river
9ce947ebfc012ec7059de0a09c765b2da7fc1d25
[ "BSD-3-Clause" ]
2,184
2020-11-11T12:31:12.000Z
2022-03-31T16:45:41.000Z
river/time_series/base.py
raphaelsty/river
2e0b25a2ef2d2ba9ec080cf86a491f7465433b18
[ "BSD-3-Clause" ]
262
2020-11-11T17:15:47.000Z
2022-03-31T23:54:03.000Z
river/time_series/base.py
raphaelsty/river
2e0b25a2ef2d2ba9ec080cf86a491f7465433b18
[ "BSD-3-Clause" ]
240
2020-11-11T14:25:03.000Z
2022-03-31T08:25:50.000Z
import abc from .. import base class Forecaster(base.Estimator): @property def _supervised(self): return True def learn_one(self, y: float, x: dict = None) -> "Forecaster": """Updates the model. Parameters ---------- y In the literature this is called...
24.324324
98
0.572222
7c7a868cfe2d1c9f861be12c8cec6e8feb94aaa7
31,021
py
Python
leo/modes/coldfusion.py
ATikhonov2/leo-editor
225aac990a9b2804aaa9dea29574d6e072e30474
[ "MIT" ]
1,550
2015-01-14T16:30:37.000Z
2022-03-31T08:55:58.000Z
leo/modes/coldfusion.py
ATikhonov2/leo-editor
225aac990a9b2804aaa9dea29574d6e072e30474
[ "MIT" ]
2,009
2015-01-13T16:28:52.000Z
2022-03-31T18:21:48.000Z
leo/modes/coldfusion.py
ATikhonov2/leo-editor
225aac990a9b2804aaa9dea29574d6e072e30474
[ "MIT" ]
200
2015-01-05T15:07:41.000Z
2022-03-07T17:05:01.000Z
# Leo colorizer control file for coldfusion mode. # This file is in the public domain. # Properties for coldfusion mode. properties = { "commentEnd": "-->", "commentStart": "<!--", } # Attributes dict for coldfusion_main ruleset. coldfusion_main_attributes_dict = { "default": "null", "digi...
34.544543
149
0.622514
026ae39bb17dea2f5bba27c34b569d77620b9174
1,070
py
Python
CDSB_series/cumul/model_script.py
WFDetector/WFDetection
b16d35b3a3a5de62de9e0bac83eccd21b6358b53
[ "Apache-2.0" ]
null
null
null
CDSB_series/cumul/model_script.py
WFDetector/WFDetection
b16d35b3a3a5de62de9e0bac83eccd21b6358b53
[ "Apache-2.0" ]
null
null
null
CDSB_series/cumul/model_script.py
WFDetector/WFDetection
b16d35b3a3a5de62de9e0bac83eccd21b6358b53
[ "Apache-2.0" ]
null
null
null
import subprocess import argparse import constants as ct from os.path import join, abspath, dirname # Directories BASE_DIR = abspath(join(dirname(__file__))) def parse_arguments(): parser = argparse.ArgumentParser(description='Auto training.') parser.add_argument('t', metavar='<train...
28.918919
79
0.61215
6fd7f34d671f1afea0f9295025fb4eb8b99f253e
562
py
Python
tests/db_engine_specs/hana_tests.py
psbsgic/rabbitai
769e120ba605d56ac076f810a549c38dac410c8e
[ "Apache-2.0" ]
null
null
null
tests/db_engine_specs/hana_tests.py
psbsgic/rabbitai
769e120ba605d56ac076f810a549c38dac410c8e
[ "Apache-2.0" ]
null
null
null
tests/db_engine_specs/hana_tests.py
psbsgic/rabbitai
769e120ba605d56ac076f810a549c38dac410c8e
[ "Apache-2.0" ]
1
2021-07-09T16:29:50.000Z
2021-07-09T16:29:50.000Z
from rabbitai.db_engine_specs.hana import HanaEngineSpec from tests.db_engine_specs.base_tests import TestDbEngineSpec class TestHanaDbEngineSpec(TestDbEngineSpec): def test_convert_dttm(self): dttm = self.get_dttm() self.assertEqual( HanaEngineSpec.convert_dttm("DATE", dttm), ...
31.222222
90
0.653025
cdfb4e6d7bb57384a5a66a5ef6ceb86b1a2d63ca
5,524
py
Python
model_generator/resnet50.py
troyliu0105/onnx2caffe
d369e774ed216f1c9cbc2f3610c8c1b9c3364f97
[ "MIT" ]
null
null
null
model_generator/resnet50.py
troyliu0105/onnx2caffe
d369e774ed216f1c9cbc2f3610c8c1b9c3364f97
[ "MIT" ]
null
null
null
model_generator/resnet50.py
troyliu0105/onnx2caffe
d369e774ed216f1c9cbc2f3610c8c1b9c3364f97
[ "MIT" ]
null
null
null
# import torchvision.models as models import math import os import torch import torch.nn as nn from torch import onnx # model = models.resnet50(False) # dummy_input = torch.randn(1, 3, 224, 224) # onnx.export(model, dummy_input, "resnet50.onnx", verbose=True) def conv3x3(in_planes, out_planes, stride=1): """3x3...
30.351648
85
0.594859
6f9a264014e56f51af0153c1791d8ab21e8186b4
840
py
Python
Lab 2/FFT/FFT.py
LetteraUnica/unipi_lab_courses
5bec20184cba3ca0e61831b193c407dba04651c1
[ "MIT" ]
null
null
null
Lab 2/FFT/FFT.py
LetteraUnica/unipi_lab_courses
5bec20184cba3ca0e61831b193c407dba04651c1
[ "MIT" ]
null
null
null
Lab 2/FFT/FFT.py
LetteraUnica/unipi_lab_courses
5bec20184cba3ca0e61831b193c407dba04651c1
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import scipy.optimize t, V = np.genfromtxt("Battimenti1.txt", unpack=True) t *= 10**-6 # Converte il tempo in secondi fft_V = np.abs(np.fft.rfft(V)) # Trasformata di fourier del segnale V dt_eff = ((t[len(t)-1] - t[0]) / len(t)) # Intervallo medio di tempo t...
28.965517
108
0.675
afe589f2e3bfa50c53be7342e4fa29cf44757d50
15,968
py
Python
yolo3/model.py
gan3sh500/keras-YOLOv3-model-set
1a1108c52073c01c130618dc68607f455adadf28
[ "MIT" ]
null
null
null
yolo3/model.py
gan3sh500/keras-YOLOv3-model-set
1a1108c52073c01c130618dc68607f455adadf28
[ "MIT" ]
null
null
null
yolo3/model.py
gan3sh500/keras-YOLOv3-model-set
1a1108c52073c01c130618dc68607f455adadf28
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ create YOLOv3 models with different backbone & head """ import warnings from functools import partial import tensorflow.keras.backend as K from tensorflow.keras.layers import Input, Lambda from tensorflow.keras.models import Model from tensorflow.keras.optimizers impo...
54.498294
260
0.764279
babfaaf6701f42c0c0311feb4e1dc1f889146702
2,788
py
Python
rl687/environments/cartpole.py
purujitgoyal/rl-framework-687-public
c315ba64267b2f15aa18fe098259243bec521954
[ "MIT" ]
3
2019-09-11T01:35:31.000Z
2019-09-20T00:23:35.000Z
rl687/environments/cartpole.py
purujitgoyal/rl-framework-687-public
c315ba64267b2f15aa18fe098259243bec521954
[ "MIT" ]
null
null
null
rl687/environments/cartpole.py
purujitgoyal/rl-framework-687-public
c315ba64267b2f15aa18fe098259243bec521954
[ "MIT" ]
17
2019-09-12T02:16:40.000Z
2019-10-06T18:32:48.000Z
import numpy as np from typing import Tuple from .skeleton import Environment class Cartpole(Environment): """ The cart-pole environment as described in the 687 course material. This domain is modeled as a pole balancing on a cart. The agent must learn to move the cart forwards and backwards to keep t...
26.301887
112
0.57066
de26d89bac86126758760ab28c52d24fe8f48e86
1,568
py
Python
TestRobustness/ConvNetTrain/instance_model_train_5.23.18_JitterRad-400.0_jitterPerc-1.0.py
aparna-arr/DeepLearningChromatinStructure
f56d36b8fc8b01df407ed7a2526266c4d8e731d4
[ "MIT" ]
3
2021-07-26T02:06:39.000Z
2022-03-20T13:00:25.000Z
TestRobustness/ConvNetTrain/instance_model_train_5.23.18_JitterRad-400.0_jitterPerc-1.0.py
aparna-arr/DeepLearningChromatinStructure
f56d36b8fc8b01df407ed7a2526266c4d8e731d4
[ "MIT" ]
null
null
null
TestRobustness/ConvNetTrain/instance_model_train_5.23.18_JitterRad-400.0_jitterPerc-1.0.py
aparna-arr/DeepLearningChromatinStructure
f56d36b8fc8b01df407ed7a2526266c4d8e731d4
[ "MIT" ]
1
2021-06-09T16:04:52.000Z
2021-06-09T16:04:52.000Z
#!/share/software/user/open/python/3.6.1/bin/python3 from src.ModelDriver import * ## MODIFY THESE PARAMS FOR SPECIFIC RUN ### X_train = "/oak/stanford/groups/aboettig/Aparna/NNreviews/TestRobustness/jitterData/train_5.23.18_JitterRad-400.0_jitterPerc-1.0_xyz.txt" Y_train = "/oak/stanford/groups/aboettig/Aparna/NNproj...
36.465116
137
0.785714
ac2bd6f6ab01854f6ae7dde28c945009e6ccefee
2,489
py
Python
netbox_onboarding/models.py
hoanhan101/ntc-netbox-plugin-onboarding
09764a0ac68e948accbd9346ea0f1ae0af569e3d
[ "Apache-2.0" ]
null
null
null
netbox_onboarding/models.py
hoanhan101/ntc-netbox-plugin-onboarding
09764a0ac68e948accbd9346ea0f1ae0af569e3d
[ "Apache-2.0" ]
null
null
null
netbox_onboarding/models.py
hoanhan101/ntc-netbox-plugin-onboarding
09764a0ac68e948accbd9346ea0f1ae0af569e3d
[ "Apache-2.0" ]
null
null
null
"""OnboardingTask Django model. (c) 2020 Network To Code Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to i...
38.292308
118
0.726396
27a62d4fd3d27807a58f1d22a2640cfcf6225df7
51
py
Python
mypkg/module2.py
pierre-trainings/intro_python
b84512dbc9b559528f317d7b51f411df6e16aa68
[ "MIT" ]
null
null
null
mypkg/module2.py
pierre-trainings/intro_python
b84512dbc9b559528f317d7b51f411df6e16aa68
[ "MIT" ]
null
null
null
mypkg/module2.py
pierre-trainings/intro_python
b84512dbc9b559528f317d7b51f411df6e16aa68
[ "MIT" ]
null
null
null
from mypkg.sub_mypkg.module1 import * mysum(1, 2)
12.75
37
0.745098
7991cabc35eb99eac3841c8cd289adab0c8aefec
650
py
Python
multi_media/util/tried_image_crawler/try_newspaper/test_newspaper.py
Barry-Menglong-Yao/conll2019-snopes-crawling
f803a99e27866036b92175c7d9786611ad1f389b
[ "Apache-2.0" ]
1
2021-12-28T16:28:19.000Z
2021-12-28T16:28:19.000Z
multi_media/util/tried_image_crawler/try_newspaper/test_newspaper.py
Barry-Menglong-Yao/conll2019-snopes-crawling
f803a99e27866036b92175c7d9786611ad1f389b
[ "Apache-2.0" ]
null
null
null
multi_media/util/tried_image_crawler/try_newspaper/test_newspaper.py
Barry-Menglong-Yao/conll2019-snopes-crawling
f803a99e27866036b92175c7d9786611ad1f389b
[ "Apache-2.0" ]
null
null
null
from newspaper import Article import pandas as pd def print_img_url(url): article = Article(url) article.download() # print(article.html) article.parse() # print(article.authors) # print(article.publish_date) # print(article.text) # print(article.top_image) ...
17.105263
80
0.635385
97d0d8b6b710f840568a8e789e5a647ff09103c3
3,682
py
Python
OracleIdentityGovernance/kubernetes/monitoring-service/scripts/deploy-weblogic-monitoring-exporter.py
rishiagarwal-oracle/fmw-kubernetes
cf53d0aac782cacaa26cb1f8f1cdb7130f69d64f
[ "UPL-1.0", "MIT" ]
20
2020-09-18T08:28:06.000Z
2021-11-04T11:48:53.000Z
OracleIdentityGovernance/kubernetes/monitoring-service/scripts/deploy-weblogic-monitoring-exporter.py
rishiagarwal-oracle/fmw-kubernetes
cf53d0aac782cacaa26cb1f8f1cdb7130f69d64f
[ "UPL-1.0", "MIT" ]
17
2020-10-29T03:52:52.000Z
2022-03-29T06:47:05.000Z
OracleIdentityGovernance/kubernetes/monitoring-service/scripts/deploy-weblogic-monitoring-exporter.py
rishiagarwal-oracle/fmw-kubernetes
cf53d0aac782cacaa26cb1f8f1cdb7130f69d64f
[ "UPL-1.0", "MIT" ]
27
2020-04-30T09:06:37.000Z
2022-03-29T06:49:06.000Z
# Copyright (c) 2021, Oracle and/or its affiliates. # Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl. # import sys #======================================================= # Function for fresh plain deployment #=====================================================...
34.735849
139
0.661597
64fea11214a5b4e3c2304c732259c87b1cbe8306
8,427
py
Python
emolga/utils/generic_utils.py
memray/seq2seq-keyphrase-dev
b4039de141c9864f6dabb8d43cba6236a3ce4651
[ "MIT" ]
2
2017-07-19T10:01:29.000Z
2018-08-13T07:12:00.000Z
emolga/utils/generic_utils.py
memray/seq2seq-keyphrase-dev
b4039de141c9864f6dabb8d43cba6236a3ce4651
[ "MIT" ]
null
null
null
emolga/utils/generic_utils.py
memray/seq2seq-keyphrase-dev
b4039de141c9864f6dabb8d43cba6236a3ce4651
[ "MIT" ]
null
null
null
from __future__ import absolute_import from matplotlib.ticker import FuncFormatter import numpy as np import time import sys import six import matplotlib.pyplot as plt import matplotlib def get_from_module(identifier, module_params, module_name, instantiate=False, kwargs=None): if isinstance(identifier, six.string...
31.8
110
0.525573
2134aca61dfdca158ec5a2e04d57641a38f6143c
19,366
py
Python
diofant/tests/polys/test_groebnertools.py
rajkk1/diofant
6b361334569e4ec2e8c7d30dc324387a4ad417c2
[ "BSD-3-Clause" ]
null
null
null
diofant/tests/polys/test_groebnertools.py
rajkk1/diofant
6b361334569e4ec2e8c7d30dc324387a4ad417c2
[ "BSD-3-Clause" ]
null
null
null
diofant/tests/polys/test_groebnertools.py
rajkk1/diofant
6b361334569e4ec2e8c7d30dc324387a4ad417c2
[ "BSD-3-Clause" ]
null
null
null
"""Tests for Gröbner bases.""" import pytest from diofant import QQ, ZZ, grlex, lex, ring from diofant.config import using from diofant.polys.groebnertools import (Num, Polyn, Sign, _representing_matrices, cp_key, critical_pair, f5_redu...
36.402256
166
0.480223
5199d1c74e22230321101119fffe1b28ab9d55c2
75
py
Python
tests/modules/withinheritedconstructor/metricorigin.py
FilippoBoido/py2puml
9f25ca7ea0bcb2f9e7b25751bcda680a0e8f7d90
[ "MIT" ]
59
2020-06-04T11:32:10.000Z
2022-03-22T18:37:28.000Z
tests/modules/withinheritedconstructor/metricorigin.py
mayshukla/py2puml
9f25ca7ea0bcb2f9e7b25751bcda680a0e8f7d90
[ "MIT" ]
21
2020-05-14T14:31:23.000Z
2022-03-25T02:44:05.000Z
tests/modules/withinheritedconstructor/metricorigin.py
mayshukla/py2puml
9f25ca7ea0bcb2f9e7b25751bcda680a0e8f7d90
[ "MIT" ]
11
2021-01-07T04:11:47.000Z
2022-03-01T21:32:32.000Z
from .point import Origin class MetricOrigin(Origin): unit: str = 'm'
15
27
0.693333
b193e63a5fdbed547eadd56cf3782ab652f79925
762
py
Python
angr/engines/vex/expressions/__init__.py
aeflores/angr
ac85a3f168375ed0ee20551b1b716c1bff4ac02b
[ "BSD-2-Clause" ]
1
2020-11-18T16:39:11.000Z
2020-11-18T16:39:11.000Z
angr/engines/vex/expressions/__init__.py
aeflores/angr
ac85a3f168375ed0ee20551b1b716c1bff4ac02b
[ "BSD-2-Clause" ]
1
2019-04-08T12:10:07.000Z
2019-04-08T12:10:07.000Z
angr/engines/vex/expressions/__init__.py
aeflores/angr
ac85a3f168375ed0ee20551b1b716c1bff4ac02b
[ "BSD-2-Clause" ]
1
2020-11-18T16:39:13.000Z
2020-11-18T16:39:13.000Z
import pyvex from .gsptr import SimIRExpr_GSPTR from .vecret import SimIRExpr_VECRET from .rdtmp import SimIRExpr_RdTmp from .get import SimIRExpr_Get from .load import SimIRExpr_Load from .op import SimIRExpr_Unop, SimIRExpr_Binop, SimIRExpr_Triop, SimIRExpr_Qop from .const import SimIRExpr_Const from .ccall import S...
33.130435
101
0.769029
cb3b0e23823613881ac12a37b04f4944dbe7a934
1,903
py
Python
iepy/instantiation/command_line.py
hanjx16/iepy_zh
98c9acf76410a085c0a77dfbe8837daf81c27a48
[ "BSD-3-Clause" ]
1
2018-08-04T05:16:13.000Z
2018-08-04T05:16:13.000Z
iepy/instantiation/command_line.py
hanjx16/iepy_zh
98c9acf76410a085c0a77dfbe8837daf81c27a48
[ "BSD-3-Clause" ]
null
null
null
iepy/instantiation/command_line.py
hanjx16/iepy_zh
98c9acf76410a085c0a77dfbe8837daf81c27a48
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python """ IEPY administration command. Usage: iepy --create <folder_path> [--lang=<lang>] iepy --upgrade <folder_path> iepy --download-third-party-data [--lang=<lang>] Options: --create Creates new IEPY instance --upgrade Upgrades IEPY ...
30.693548
107
0.663689
3a4ace4d85d2f55132dfb1c1ce097270bec0dd0e
4,747
py
Python
1-projects/Data-Structures-master/doubly_linked_list/test_doubly_linked_list.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
1-projects/Data-Structures-master/doubly_linked_list/test_doubly_linked_list.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
1
2020-09-17T05:23:29.000Z
2020-09-17T05:23:29.000Z
1-projects/Data-Structures-master/doubly_linked_list/test_doubly_linked_list.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
import unittest from doubly_linked_list import ListNode from doubly_linked_list import DoublyLinkedList class DoublyLinkedListTests(unittest.TestCase): def setUp(self): self.node = ListNode(1) self.dll = DoublyLinkedList(self.node) def test_list_remove_from_tail(self): self.dll.remove_...
34.904412
59
0.648199
d283285f5e643fb16527dc6c9e22e82ac4ae9a40
5,798
py
Python
querybook/server/clients/google_client.py
froukees/querybook
8db8ac7e39cd33bbbe3953c0107b0a4ca8472c07
[ "Apache-2.0" ]
null
null
null
querybook/server/clients/google_client.py
froukees/querybook
8db8ac7e39cd33bbbe3953c0107b0a4ca8472c07
[ "Apache-2.0" ]
null
null
null
querybook/server/clients/google_client.py
froukees/querybook
8db8ac7e39cd33bbbe3953c0107b0a4ca8472c07
[ "Apache-2.0" ]
null
null
null
from io import BytesIO from os import SEEK_END from datetime import datetime from urllib.parse import quote import requests from env import QuerybookSettings from .common import ChunkReader, FileDoesNotExist from lib.utils.utils import DATETIME_TO_UTC def get_google_credentials(creds_info=None): try: fr...
32.391061
118
0.664367
7b6af08280f8d098fecbb7a843a8740adb11b1ba
669
py
Python
paas-ce/websocket/control/migrations/0008_auto_20200324_1009.py
kerven88/opsany-paas
78b83d0b6a46f3e70226ca99992d736b2af0af72
[ "Apache-2.0" ]
42
2021-06-16T12:06:03.000Z
2022-03-29T13:18:00.000Z
paas-ce/websocket/control/migrations/0008_auto_20200324_1009.py
kerven88/opsany-paas
78b83d0b6a46f3e70226ca99992d736b2af0af72
[ "Apache-2.0" ]
null
null
null
paas-ce/websocket/control/migrations/0008_auto_20200324_1009.py
kerven88/opsany-paas
78b83d0b6a46f3e70226ca99992d736b2af0af72
[ "Apache-2.0" ]
16
2021-07-13T01:17:57.000Z
2022-03-01T12:39:32.000Z
""" Copyright © 2012-2020 OpsAny. All Rights Reserved. 河南我买云信息技术有限公司版权所有 """ # noqa # Generated by Django 2.2.6 on 2020-03-24 10:09 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('control', '0007_agentadmin_host_type'), ] operations = [ ...
24.777778
68
0.609865
87fe495a1d6049de47f9f66fbaac8f98d20c4e9d
3,637
py
Python
poem_generator/utils.py
guruprasaad123/all_dl_projects
04c869f7f001ef94c467740260663d91a34815e0
[ "Apache-2.0" ]
1
2021-12-10T16:06:20.000Z
2021-12-10T16:06:20.000Z
poem_generator/utils.py
guruprasaad123/all_dl_projects
04c869f7f001ef94c467740260663d91a34815e0
[ "Apache-2.0" ]
null
null
null
poem_generator/utils.py
guruprasaad123/all_dl_projects
04c869f7f001ef94c467740260663d91a34815e0
[ "Apache-2.0" ]
null
null
null
import numpy as np import os import torch from torch.nn import functional as f import random from torch.autograd import Variable def decode(c): if c == 1: return 9 elif c == 3: return 13 elif c == 127 - 30: return 10 # converting to lower-case again elif 32 <= c + 30 <= 126:...
20.093923
93
0.593071
60ff7df010cdb5b92cc8f502b86e1b0ff4ebd028
2,734
py
Python
elo/word2vec.py
looselyconnected/fastai
12d38d760393f1a677cc825d99283c8efcffbef5
[ "MIT" ]
null
null
null
elo/word2vec.py
looselyconnected/fastai
12d38d760393f1a677cc825d99283c8efcffbef5
[ "MIT" ]
null
null
null
elo/word2vec.py
looselyconnected/fastai
12d38d760393f1a677cc825d99283c8efcffbef5
[ "MIT" ]
null
null
null
import pandas as pd import numpy as np import gc import matplotlib.pyplot as plt from elo.embedding import load_all_category from gensim.models import Word2Vec, KeyedVectors from sklearn.manifold import TSNE # Train the user and merchant embeddings using per user merchant purchase percentage as target. def train_wo...
39.057143
106
0.694221
a4c08869d02bbbd292afab0dc9272b7c6b5a8048
4,475
py
Python
staticpy/lang/statement.py
SnowWalkerJ/StaticPy
818b7f009af7a6040313791993f543779781dddf
[ "BSD-3-Clause" ]
13
2019-10-14T19:22:11.000Z
2021-08-23T08:39:06.000Z
staticpy/lang/statement.py
SnowWalkerJ/StaticPy
818b7f009af7a6040313791993f543779781dddf
[ "BSD-3-Clause" ]
5
2019-09-30T07:42:18.000Z
2020-01-01T15:07:00.000Z
staticpy/lang/statement.py
SnowWalkerJ/StaticPy
818b7f009af7a6040313791993f543779781dddf
[ "BSD-3-Clause" ]
null
null
null
import abc import typing from ..session import get_session from . import expression as E from .common import auto_add class Statement(abc.ABC): @abc.abstractmethod def translate(self) -> typing.List[str]: pass class VariableDeclaration(Statement): def __init__(self, var, init=None, qualifiers=N...
22.375
71
0.641564
e93e2fcd0b859a9ba53b5210f77df88830a03d2d
4,829
py
Python
rlcard/envs/simpledoudizhu.py
thomasthechen/rlcard
0139d0e403b6d844a8f9107237887d73c7e8d752
[ "MIT" ]
null
null
null
rlcard/envs/simpledoudizhu.py
thomasthechen/rlcard
0139d0e403b6d844a8f9107237887d73c7e8d752
[ "MIT" ]
null
null
null
rlcard/envs/simpledoudizhu.py
thomasthechen/rlcard
0139d0e403b6d844a8f9107237887d73c7e8d752
[ "MIT" ]
null
null
null
import numpy as np from rlcard.envs import Env from rlcard.games.simpledoudizhu import Game from rlcard.games.doudizhu.utils import SPECIFIC_MAP, CARD_RANK_STR from rlcard.games.simpledoudizhu.utils import ACTION_LIST, ACTION_SPACE from rlcard.games.doudizhu.utils import encode_cards from rlcard.games.doudizhu.utils i...
37.146154
95
0.592462
8d5a785d9e38f6793c05ac5ed05c17d45aea47e3
16,643
py
Python
ops/qc.py
annale-8/OpticalPooledScreens
96429d0d351af0d124e1b09be713602da9fa9e54
[ "MIT" ]
null
null
null
ops/qc.py
annale-8/OpticalPooledScreens
96429d0d351af0d124e1b09be713602da9fa9e54
[ "MIT" ]
null
null
null
ops/qc.py
annale-8/OpticalPooledScreens
96429d0d351af0d124e1b09be713602da9fa9e54
[ "MIT" ]
null
null
null
import numpy as np import pandas as pd import seaborn as sns import matplotlib.pyplot as plt def plot_mapping_vs_threshold(df_reads, barcodes, threshold_var='peak',ax=None): """Plot the mapping rate and number of mapped spots against varying thresholds of peak intensity, quality score, or a user-defined metri...
41.297767
132
0.603197
113e3fefef56b693bbe42ad2d9b4b6df4ba51dff
1,920
py
Python
src/archive/LSTM/LSTMAE2000data.py
RiceD2KLab/TCH_CardiacSignals_F20
ea6e84703086ddb7bfc5ba164aa67acdc9e78b7d
[ "BSD-2-Clause" ]
1
2022-01-27T07:03:20.000Z
2022-01-27T07:03:20.000Z
src/archive/LSTM/LSTMAE2000data.py
RiceD2KLab/TCH_CardiacSignals_F20
ea6e84703086ddb7bfc5ba164aa67acdc9e78b7d
[ "BSD-2-Clause" ]
null
null
null
src/archive/LSTM/LSTMAE2000data.py
RiceD2KLab/TCH_CardiacSignals_F20
ea6e84703086ddb7bfc5ba164aa67acdc9e78b7d
[ "BSD-2-Clause" ]
null
null
null
import tensorflow from tensorflow import keras from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Dense, LSTM, Dropout, RepeatVector, TimeDistributed import numpy as np import os import matplotlib.pyplot as plt import sys def create_model(X): model = Sequential() model.add(LSTM...
29.538462
106
0.666146
f1d5f9f061dee283b98ef4c8f32391454f2b00b7
2,279
py
Python
modoboa_installer/scripts/nginx.py
OutsideContextSolutions/modoboa-installer
fd75890047ea06dca49677f343cd12bab59c3de1
[ "MIT" ]
null
null
null
modoboa_installer/scripts/nginx.py
OutsideContextSolutions/modoboa-installer
fd75890047ea06dca49677f343cd12bab59c3de1
[ "MIT" ]
null
null
null
modoboa_installer/scripts/nginx.py
OutsideContextSolutions/modoboa-installer
fd75890047ea06dca49677f343cd12bab59c3de1
[ "MIT" ]
1
2021-03-18T21:20:16.000Z
2021-03-18T21:20:16.000Z
"""Nginx related tools.""" import os from .. import package from .. import system from .. import utils from . import base from .uwsgi import Uwsgi class Nginx(base.Installer): """Nginx installer.""" appname = "nginx" packages = { "deb": ["nginx", "ssl-cert"], "rpm": ["nginx"] } ...
33.514706
79
0.568232
3a9803f2bd36b13795fe25fa34bb22943738a438
86,222
py
Python
src/spring-cloud/azext_spring_cloud/vendored_sdks/appplatform/v2022_03_01_preview/operations/_deployments_operations.py
haroonf/azure-cli-extensions
61c044d34c224372f186934fa7c9313f1cd3a525
[ "MIT" ]
1
2022-01-25T07:33:18.000Z
2022-01-25T07:33:18.000Z
src/spring-cloud/azext_spring_cloud/vendored_sdks/appplatform/v2022_03_01_preview/operations/_deployments_operations.py
haroonf/azure-cli-extensions
61c044d34c224372f186934fa7c9313f1cd3a525
[ "MIT" ]
9
2022-03-25T19:35:49.000Z
2022-03-31T06:09:47.000Z
src/spring-cloud/azext_spring_cloud/vendored_sdks/appplatform/v2022_03_01_preview/operations/_deployments_operations.py
haroonf/azure-cli-extensions
61c044d34c224372f186934fa7c9313f1cd3a525
[ "MIT" ]
1
2022-02-14T21:43:29.000Z
2022-02-14T21:43:29.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
43.767513
254
0.667591
b6867b11b29ec8e921714e6289370eedb26a57cb
401
py
Python
Site-Campus/campusonline/wsgi.py
Benedito-Medeiros-Neto-UnB/TacProgWeb
c7d795a69524e428988d4ed796f4a1c2ded035e3
[ "MIT" ]
1
2021-04-12T13:34:00.000Z
2021-04-12T13:34:00.000Z
Site-Campus/campusonline/wsgi.py
Benedito-Medeiros-Neto-UnB/TacProgWeb
c7d795a69524e428988d4ed796f4a1c2ded035e3
[ "MIT" ]
19
2021-05-14T20:56:29.000Z
2022-02-10T11:59:33.000Z
Site-Campus/campusonline/wsgi.py
Benedito-Medeiros-Neto-UnB/TacProgWeb
c7d795a69524e428988d4ed796f4a1c2ded035e3
[ "MIT" ]
10
2021-05-13T16:18:53.000Z
2021-11-08T14:30:08.000Z
""" WSGI config for campusonline project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault('DJANGO_...
23.588235
78
0.790524
f29927eb4fb44c0c7f70855f49f1fc792931df28
3,182
py
Python
.setup/bin/setup_sample_user_data.py
zeez2030/Submitty
7118944ff4adc6f15d76984eb10a1e862926d724
[ "BSD-3-Clause" ]
411
2016-06-14T20:52:25.000Z
2022-03-31T21:20:25.000Z
.setup/bin/setup_sample_user_data.py
KaelanWillauer/Submitty
cf9b6ceda15ec0a661e2ca81ea7864790094c64a
[ "BSD-3-Clause" ]
5,730
2016-05-23T21:04:32.000Z
2022-03-31T10:08:06.000Z
.setup/bin/setup_sample_user_data.py
KaelanWillauer/Submitty
cf9b6ceda15ec0a661e2ca81ea7864790094c64a
[ "BSD-3-Clause" ]
423
2016-09-22T21:11:30.000Z
2022-03-29T18:55:28.000Z
#!/usr/bin/env python3 """ Setup script that scans over the user_photo zips inside the submitty repo sample files and then generates sample data in the user_data directory. We are only grabbing one image from each zip. """ from datetime import datetime import json import os import shutil from tempfile import Temporar...
37
94
0.612508
4274152afaf749484d02bf86c4a42a7a19dad7da
4,573
py
Python
ece2cmor3/resources/lpjg-grid-content/create_cdo_ingrid_for_lpjgout.py
EC-Earth/ece2cmor3
8df8584563d16827785d0f31e58316ba3aebba96
[ "Apache-2.0" ]
9
2018-11-09T11:28:50.000Z
2022-01-17T21:28:33.000Z
ece2cmor3/resources/lpjg-grid-content/create_cdo_ingrid_for_lpjgout.py
EC-Earth/ece2cmor3
8df8584563d16827785d0f31e58316ba3aebba96
[ "Apache-2.0" ]
502
2018-05-11T11:14:15.000Z
2022-03-30T10:04:37.000Z
ece2cmor3/resources/lpjg-grid-content/create_cdo_ingrid_for_lpjgout.py
EC-Earth/ece2cmor3
8df8584563d16827785d0f31e58316ba3aebba96
[ "Apache-2.0" ]
4
2019-01-21T13:11:19.000Z
2022-03-31T13:22:32.000Z
#!/usr/bin/env python3 # Note that the script gives different precision results for python2 and python3. # The current archived ingrid_T*_unstructured.txt files have been produced with a # miniconda3 environment active (see https://github.com/EC-Earth/ece2cmor3/issues/633). # Call the script like: # ./create_cdo_ing...
33.137681
114
0.595452
b33cf1d00acf10ab40931ec0e07bcea8b8bea725
992
py
Python
Introduction to Artificial Intelligence/PA1/src/check.py
youyl/Programming-Assignments-THU
61e3274f0c623794d35240b0499c253d1d0fc60c
[ "MIT" ]
null
null
null
Introduction to Artificial Intelligence/PA1/src/check.py
youyl/Programming-Assignments-THU
61e3274f0c623794d35240b0499c253d1d0fc60c
[ "MIT" ]
null
null
null
Introduction to Artificial Intelligence/PA1/src/check.py
youyl/Programming-Assignments-THU
61e3274f0c623794d35240b0499c253d1d0fc60c
[ "MIT" ]
null
null
null
import sys if len(sys.argv)!=2: print("Error Check Input!") sys.exit() caseidx=sys.argv[1] print("TestCase ",caseidx,":") outputfilename="../data/case"+caseidx+".out" answerfilename="../data/case"+caseidx+".ans" outputfile=open(outputfilename,'r') answerfile=open(answerfilename,'r',encoding='utf-8') outputlist=ou...
21.565217
52
0.714718
a670f231c32f88a2f922e6906b36c9d093951eb5
6,781
py
Python
sydent/threepid/bind.py
aaronraimist/sydent
5d3b08eddce901e029021cf881fcb7a09508ce07
[ "Apache-2.0" ]
null
null
null
sydent/threepid/bind.py
aaronraimist/sydent
5d3b08eddce901e029021cf881fcb7a09508ce07
[ "Apache-2.0" ]
null
null
null
sydent/threepid/bind.py
aaronraimist/sydent
5d3b08eddce901e029021cf881fcb7a09508ce07
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2014 OpenMarket Ltd # Copyright 2018 New Vector Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # #...
34.42132
126
0.653001
e0633d69d0313765598ef4ef2229cc06cd30bb43
3,193
py
Python
tests/components/filesize/test_sensor.py
erogleva/core
994ae09f69afe772150a698953c0d7386a745de2
[ "Apache-2.0" ]
6
2016-11-25T06:36:27.000Z
2021-11-16T11:20:23.000Z
tests/components/filesize/test_sensor.py
erogleva/core
994ae09f69afe772150a698953c0d7386a745de2
[ "Apache-2.0" ]
45
2020-11-16T07:48:01.000Z
2022-03-31T06:03:18.000Z
tests/components/filesize/test_sensor.py
erogleva/core
994ae09f69afe772150a698953c0d7386a745de2
[ "Apache-2.0" ]
2
2021-03-17T11:01:07.000Z
2021-08-19T15:21:32.000Z
"""The tests for the filesize sensor.""" import os import unittest from homeassistant import config as hass_config from homeassistant.components.filesize import DOMAIN from homeassistant.components.filesize.sensor import CONF_FILE_PATHS from homeassistant.const import SERVICE_RELOAD from homeassistant.setup import asy...
32.581633
88
0.649546
8d55ba58aad8d62588b564a54ea2e7eaf2356983
1,319
py
Python
tests/terraform/checks/resource/yandexcloud/test_ObjectStorageBucketEncryption.py
peaudecastor/checkov
a4804b61c1b1390b7abd44ab53285fcbc3e7e80b
[ "Apache-2.0" ]
null
null
null
tests/terraform/checks/resource/yandexcloud/test_ObjectStorageBucketEncryption.py
peaudecastor/checkov
a4804b61c1b1390b7abd44ab53285fcbc3e7e80b
[ "Apache-2.0" ]
null
null
null
tests/terraform/checks/resource/yandexcloud/test_ObjectStorageBucketEncryption.py
peaudecastor/checkov
a4804b61c1b1390b7abd44ab53285fcbc3e7e80b
[ "Apache-2.0" ]
null
null
null
import os import unittest from checkov.runner_filter import RunnerFilter from checkov.terraform.checks.resource.yandexcloud.ObjectStorageBucketEncryption import check from checkov.terraform.runner import Runner class TestObjectStorageBucketEncryption(unittest.TestCase): def test(self): runner = Runner() ...
33.820513
102
0.711903
7870fc6ac48084b1c9aafb0157a4ec684472050f
1,183
py
Python
python/lensmodelapi/api/profile_list.py
LyneVdV/LensModelAPI
420a59bb488bee1fce24d5335dac0483eeab95c1
[ "MIT" ]
null
null
null
python/lensmodelapi/api/profile_list.py
LyneVdV/LensModelAPI
420a59bb488bee1fce24d5335dac0483eeab95c1
[ "MIT" ]
null
null
null
python/lensmodelapi/api/profile_list.py
LyneVdV/LensModelAPI
420a59bb488bee1fce24d5335dac0483eeab95c1
[ "MIT" ]
null
null
null
__author__ = 'aymgal' from types import ModuleType from typing import Tuple from lensmodelapi.api.base import APIBaseObject from lensmodelapi.api.profiles import mass as mass_profiles_module from lensmodelapi.api.profiles import light as light_profiles_module class ProfileList(list, APIBaseObject): def __init_...
29.575
71
0.675402
e465ea683c4655c841547afd89db5dd40e3a9c5d
69
py
Python
01_Language/01_Functions/python/fgets.py
cliff363825/TwentyFour
09df59bd5d275e66463e343647f46027397d1233
[ "MIT" ]
3
2020-06-28T07:42:51.000Z
2021-01-15T10:32:11.000Z
01_Language/01_Functions/python/fgets.py
cliff363825/TwentyFour
09df59bd5d275e66463e343647f46027397d1233
[ "MIT" ]
9
2021-03-10T22:45:40.000Z
2022-02-27T06:53:20.000Z
01_Language/01_Functions/python/fgets.py
cliff363825/TwentyFour
09df59bd5d275e66463e343647f46027397d1233
[ "MIT" ]
1
2021-01-15T10:51:24.000Z
2021-01-15T10:51:24.000Z
# coding: utf-8 with open("test.txt") as f: print(f.readline())
13.8
27
0.608696
2ae74e02868fdc7f16f09102529918ece7f90463
8,039
py
Python
tests/test_osfs.py
rddaz2013/pyfilesystem2
3856bbf55a715c60e1323735ead9dfdf446b6889
[ "MIT" ]
null
null
null
tests/test_osfs.py
rddaz2013/pyfilesystem2
3856bbf55a715c60e1323735ead9dfdf446b6889
[ "MIT" ]
1
2021-12-17T21:43:32.000Z
2021-12-17T21:43:32.000Z
tests/test_osfs.py
rddaz2013/pyfilesystem2
3856bbf55a715c60e1323735ead9dfdf446b6889
[ "MIT" ]
null
null
null
# coding: utf-8 from __future__ import unicode_literals import errno import io import os import shutil import tempfile import sys import time import unittest import warnings from fs import osfs, open_fs from fs.path import relpath, dirname from fs import errors from fs.test import FSTestCases from six import text_ty...
34.800866
87
0.615624
69af5fcf44709db8c792170b960ef9228557464d
42,405
py
Python
redash/models/__init__.py
vatsaluc/redashuc
0232d1306679096613dcfb5a5adbf2b43cffbe23
[ "BSD-2-Clause" ]
1
2019-06-02T01:57:37.000Z
2019-06-02T01:57:37.000Z
redash/models/__init__.py
zhenyu-captain/redash
71fb1442f17a6c9d3ff53215751fdda0835fb101
[ "BSD-2-Clause" ]
null
null
null
redash/models/__init__.py
zhenyu-captain/redash
71fb1442f17a6c9d3ff53215751fdda0835fb101
[ "BSD-2-Clause" ]
1
2019-09-08T04:14:10.000Z
2019-09-08T04:14:10.000Z
import cStringIO import csv import datetime import calendar import logging import time import pytz import xlsxwriter from six import python_2_unicode_compatible, text_type from sqlalchemy import distinct, or_, and_, UniqueConstraint from sqlalchemy.dialects import postgresql from sqlalchemy.event import listens_for fr...
36.305651
165
0.625728
85fe9a1355e53f7d5d1502dea6e22422147699c6
8,898
py
Python
playground/midi_lib.py
fab-jul/pymodsynth
dcfcb0f7ce66a0b4aa2b9a985097aa9db712f89a
[ "MIT" ]
2
2022-03-06T21:52:24.000Z
2022-03-08T09:00:44.000Z
playground_v2/mz/midi_lib.py
fab-jul/pymodsynth
dcfcb0f7ce66a0b4aa2b9a985097aa9db712f89a
[ "MIT" ]
null
null
null
playground_v2/mz/midi_lib.py
fab-jul/pymodsynth
dcfcb0f7ce66a0b4aa2b9a985097aa9db712f89a
[ "MIT" ]
null
null
null
# Needs # pip install rtmidi # # https://github.com/patrickkidd/pyrtmidi # import argparse import collections import dataclasses import enum import queue import re import sys import threading import typing import platform if platform.system() == 'Windows': import rtmidi2 as rtmidi else: import rtmidi MidiValu...
30.682759
86
0.624747
9076620571cca191c44df35803d545a0dab44040
1,059
py
Python
api-inference-community/docker_images/adapter_transformers/app/pipelines/text_classification.py
mlonaws/huggingface_hub
588f74b98fbcab2cd7e61a74cc6d9649a92e0ef2
[ "Apache-2.0" ]
2
2022-03-24T19:41:23.000Z
2022-03-25T10:41:26.000Z
api-inference-community/docker_images/adapter_transformers/app/pipelines/text_classification.py
mlonaws/huggingface_hub
588f74b98fbcab2cd7e61a74cc6d9649a92e0ef2
[ "Apache-2.0" ]
6
2022-03-16T12:51:45.000Z
2022-03-17T08:40:35.000Z
api-inference-community/docker_images/adapter_transformers/app/pipelines/text_classification.py
mlonaws/huggingface_hub
588f74b98fbcab2cd7e61a74cc6d9649a92e0ef2
[ "Apache-2.0" ]
1
2022-02-25T01:17:27.000Z
2022-02-25T01:17:27.000Z
from typing import Dict, List from app.pipelines import Pipeline from transformers import ( TextClassificationPipeline as TransformersClassificationPipeline, ) class TextClassificationPipeline(Pipeline): def __init__( self, adapter_id: str, ): self.pipeline = self._load_pipeline_i...
33.09375
110
0.627951
116317c53a3f3c4f969ea9e67a99671903730ef5
906
py
Python
tests/test_tableparser.py
kingking888/skyscraper
d710202f9581c3791d2cf7ee3ae33e950e46c0b7
[ "MIT" ]
1
2021-03-21T07:25:43.000Z
2021-03-21T07:25:43.000Z
tests/test_tableparser.py
kingking888/skyscraper
d710202f9581c3791d2cf7ee3ae33e950e46c0b7
[ "MIT" ]
null
null
null
tests/test_tableparser.py
kingking888/skyscraper
d710202f9581c3791d2cf7ee3ae33e950e46c0b7
[ "MIT" ]
1
2021-04-24T11:38:18.000Z
2021-04-24T11:38:18.000Z
from skyscraper.parsers import TableParser def test_read_column(): html = '<table><tr><th>Head1</th><th>Head2</th></tr>' \ + '<tr><td>Value</td><td>Value2</td></tr></table>' parser = TableParser(html, header=0) assert ['Value'] == parser.column('Head1') assert ['Value2'] == parser.column(...
30.2
62
0.584989
61093c5588321f969ecb8bf68cd28c2da0743437
403
py
Python
ProgrammingBasicWithPython-KCL/Chapter-8/SelectionSort.py
mrmyothet/IPND
204e010f815fa10951daf38669a9323cb6b13147
[ "MIT" ]
1
2020-07-04T14:00:48.000Z
2020-07-04T14:00:48.000Z
ProgrammingBasicWithPython-KCL/Chapter-8/SelectionSort.py
mrmyothet/IPND
204e010f815fa10951daf38669a9323cb6b13147
[ "MIT" ]
20
2020-06-01T04:32:16.000Z
2020-09-14T07:18:54.000Z
ProgrammingBasicWithPython-KCL/Chapter-8/SelectionSort.py
mrmyothet/ipnd
204e010f815fa10951daf38669a9323cb6b13147
[ "MIT" ]
null
null
null
def selection_sort(array): for num in range(len(array)): pos_of_min = num for loc in range(num,len(array)) : if array[loc] < array[pos_of_min]: pos_of_min = loc temp = array[num] array[num] = array[pos_of_min] array[pos_of_m...
31
46
0.550868
628b6d7dd834ed67001ec497e99047f14efe7924
7,008
py
Python
server/opendp_apps/analysis/serializers.py
mikephelan/opendp-ux
80c65da0ed17adc01c69b05dbc9cbf3a5973a016
[ "MIT" ]
null
null
null
server/opendp_apps/analysis/serializers.py
mikephelan/opendp-ux
80c65da0ed17adc01c69b05dbc9cbf3a5973a016
[ "MIT" ]
null
null
null
server/opendp_apps/analysis/serializers.py
mikephelan/opendp-ux
80c65da0ed17adc01c69b05dbc9cbf3a5973a016
[ "MIT" ]
null
null
null
from django.conf import settings from django.contrib.auth import get_user_model from rest_framework import serializers from rest_framework.relations import PrimaryKeyRelatedField from opendp_apps.analysis import static_vals as astatic from opendp_apps.analysis.models import AnalysisPlan, ReleaseInfo from opendp_apps.a...
37.475936
103
0.659675
35c2df00fadd4307d17f6774a5da641159c638c6
22,847
py
Python
addons/io_scene_gltf2/blender/exp/gltf2_blender_gather_nodes.py
Vinc3r/glTF-Blender-IO
27bb8521cd5bb2b1e3e76eef4db701d3126ee57d
[ "Apache-2.0" ]
1
2021-06-30T00:39:40.000Z
2021-06-30T00:39:40.000Z
addons/io_scene_gltf2/blender/exp/gltf2_blender_gather_nodes.py
Vinc3r/glTF-Blender-IO
27bb8521cd5bb2b1e3e76eef4db701d3126ee57d
[ "Apache-2.0" ]
null
null
null
addons/io_scene_gltf2/blender/exp/gltf2_blender_gather_nodes.py
Vinc3r/glTF-Blender-IO
27bb8521cd5bb2b1e3e76eef4db701d3126ee57d
[ "Apache-2.0" ]
null
null
null
# Copyright 2018-2019 The glTF-Blender-IO authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ...
43.518095
134
0.659649
361b146bea162e1c929e753278db58a7e2615ba1
374
py
Python
Basics/Fizzbuzz.py
Toughee/Code-samples
08ea6815f6bffee8fd2c31180e7a3bcb905d6106
[ "MIT" ]
null
null
null
Basics/Fizzbuzz.py
Toughee/Code-samples
08ea6815f6bffee8fd2c31180e7a3bcb905d6106
[ "MIT" ]
null
null
null
Basics/Fizzbuzz.py
Toughee/Code-samples
08ea6815f6bffee8fd2c31180e7a3bcb905d6106
[ "MIT" ]
null
null
null
# Write a program that prints the numbers from 1 to 100. # But for multiples of three print “Fizz” instead of the number and for the multiples of five print “Buzz”. # For numbers which are multiples of both three and five print “FizzBuzz”." for i in range(101): if i%3==0: print("Fizz") if i%5==0: ...
37.4
108
0.647059
700528519c644c18961c413edb4e4474e75a523d
14,134
py
Python
boto3_type_annotations_with_docs/boto3_type_annotations/cloudhsmv2/paginator.py
cowboygneox/boto3_type_annotations
450dce1de4e066b939de7eac2ec560ed1a7ddaa2
[ "MIT" ]
119
2018-12-01T18:20:57.000Z
2022-02-02T10:31:29.000Z
boto3_type_annotations_with_docs/boto3_type_annotations/cloudhsmv2/paginator.py
cowboygneox/boto3_type_annotations
450dce1de4e066b939de7eac2ec560ed1a7ddaa2
[ "MIT" ]
15
2018-11-16T00:16:44.000Z
2021-11-13T03:44:18.000Z
boto3_type_annotations_with_docs/boto3_type_annotations/cloudhsmv2/paginator.py
cowboygneox/boto3_type_annotations
450dce1de4e066b939de7eac2ec560ed1a7ddaa2
[ "MIT" ]
11
2019-05-06T05:26:51.000Z
2021-09-28T15:27:59.000Z
from typing import Dict from botocore.paginate import Paginator class DescribeBackups(Paginator): def paginate(self, Filters: Dict = None, SortAscending: bool = None, PaginationConfig: Dict = None) -> Dict: """ Creates an iterator that will paginate through responses from :py:meth:`CloudHSMV2.Clie...
48.07483
224
0.490236
2fc43a104f7983ffad7bc6500717b34de1461d6b
388
py
Python
CONTENT/Resources/guides/__UNSORTED/266_palindrome_permutation/permutation.py
impastasyndrome/DS-ALGO-OFFICIAL
c85ec9cf0af0009f038b7a571a7ac1fb466b7f3a
[ "Apache-2.0" ]
13
2021-03-11T00:25:22.000Z
2022-03-19T00:19:23.000Z
CONTENT/Resources/guides/__UNSORTED/266_palindrome_permutation/permutation.py
impastasyndrome/DS-ALGO-OFFICIAL
c85ec9cf0af0009f038b7a571a7ac1fb466b7f3a
[ "Apache-2.0" ]
162
2021-03-09T01:52:11.000Z
2022-03-12T01:09:07.000Z
CONTENT/Resources/guides/__UNSORTED/266_palindrome_permutation/permutation.py
impastasyndrome/DS-ALGO-OFFICIAL
c85ec9cf0af0009f038b7a571a7ac1fb466b7f3a
[ "Apache-2.0" ]
12
2021-04-26T19:43:01.000Z
2022-01-31T08:36:29.000Z
from collections import defaultdict class Solution(object): def canPermutePalindrome(self, s): """ :type s: str :rtype: bool """ d = defaultdict(int) for c in s: d[c] += 1 odd = 0 for _, c in d.items(): if c % 2: ...
21.555556
55
0.440722
01974ccc112e0b6047be557ba6178967a431953d
7,868
py
Python
organizations/south_migrations/0010_auto__add_field_organization_is_pandi_club__chg_field_organization_sig.py
st8st8/django-organizations
a38f8fd1e85466b33f99ebf09a57bec8cfd43b55
[ "BSD-2-Clause" ]
null
null
null
organizations/south_migrations/0010_auto__add_field_organization_is_pandi_club__chg_field_organization_sig.py
st8st8/django-organizations
a38f8fd1e85466b33f99ebf09a57bec8cfd43b55
[ "BSD-2-Clause" ]
null
null
null
organizations/south_migrations/0010_auto__add_field_organization_is_pandi_club__chg_field_organization_sig.py
st8st8/django-organizations
a38f8fd1e85466b33f99ebf09a57bec8cfd43b55
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from south.utils import datetime_utils as datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'Organization.is_pandi_club' db.add_column(u'organizations...
77.90099
210
0.59545
285a430499243d3008f1d79a5873f0fd6e2ae355
12,348
py
Python
app/routes.py
InfernapeXavier/Webby
ed2db7fe5a6056d8e8535a6bf7c3e3e7faf96c2a
[ "MIT" ]
null
null
null
app/routes.py
InfernapeXavier/Webby
ed2db7fe5a6056d8e8535a6bf7c3e3e7faf96c2a
[ "MIT" ]
null
null
null
app/routes.py
InfernapeXavier/Webby
ed2db7fe5a6056d8e8535a6bf7c3e3e7faf96c2a
[ "MIT" ]
null
null
null
from flask import render_template, flash, redirect, url_for from app import app from app.forms import LoginForm from flask_login import current_user, login_user from app.models import User from flask_login import logout_user from flask_login import login_required from flask import request from werkzeug.urls import url_...
39.324841
145
0.673955
dcf58c18bfca47d049d30cd8e7d06a11e5a8b9ad
1,346
py
Python
lib/googlecloudsdk/command_lib/network_security/completers.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
2
2019-11-10T09:17:07.000Z
2019-12-18T13:44:08.000Z
lib/googlecloudsdk/command_lib/network_security/completers.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
null
null
null
lib/googlecloudsdk/command_lib/network_security/completers.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
1
2020-07-25T01:40:19.000Z
2020-07-25T01:40:19.000Z
# -*- coding: utf-8 -*- # # Copyright 2021 Google LLC. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requir...
36.378378
89
0.767459
d7f9a4231483e169f44c8cf1d4f6ef2a92e87fa7
6,826
py
Python
tf_coder/value_search/value_search_main.py
TomWildenhain-Microsoft/tensorflow-coder
4429d112242ebbf1f89c2db8e2618b05f678212d
[ "Apache-2.0" ]
2
2021-06-09T21:37:46.000Z
2021-06-09T21:37:50.000Z
tf_coder/value_search/value_search_main.py
hstrohm/PyTorch-Coder
2159a5561d8b71d5539e299cf0c4b77eb305df8a
[ "Apache-2.0" ]
null
null
null
tf_coder/value_search/value_search_main.py
hstrohm/PyTorch-Coder
2159a5561d8b71d5539e299cf0c4b77eb305df8a
[ "Apache-2.0" ]
1
2022-01-31T05:01:01.000Z
2022-01-31T05:01:01.000Z
# Copyright 2021 The TF-Coder Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in...
35.73822
80
0.715793
af329026c07daad29a9a5d680a6e7bdd9c8e675f
22,569
py
Python
run_pretraining.py
google-research/ALBERT
a36e095d3066934a30c7e2a816b2eeb3480e9b87
[ "Apache-2.0" ]
1,846
2019-11-26T22:25:45.000Z
2020-03-23T12:37:09.000Z
run_pretraining.py
google-research/ALBERT
a36e095d3066934a30c7e2a816b2eeb3480e9b87
[ "Apache-2.0" ]
140
2019-12-07T02:48:27.000Z
2020-03-22T11:01:21.000Z
run_pretraining.py
google-research/ALBERT
a36e095d3066934a30c7e2a816b2eeb3480e9b87
[ "Apache-2.0" ]
290
2019-12-07T05:31:23.000Z
2020-03-23T03:19:24.000Z
# coding=utf-8 # Copyright 2018 The Google AI Team Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicabl...
39.046713
82
0.688245
903f1538700ea42b644e5ac0cc289fc579107a30
1,362
py
Python
src/dataset/DatasetRegistry.py
sporreking/Evaluation-of-Synthetic-Face-Generation-Approaches
480608524751c8f48445404ad92708133472cd0e
[ "MIT" ]
1
2022-03-10T13:40:05.000Z
2022-03-10T13:40:05.000Z
src/dataset/DatasetRegistry.py
sporreking/Evaluation-of-Synthetic-Face-Generation-Approaches
480608524751c8f48445404ad92708133472cd0e
[ "MIT" ]
55
2022-03-09T13:59:11.000Z
2022-03-31T14:58:47.000Z
src/dataset/DatasetRegistry.py
sporreking/Evaluation-of-Synthetic-Face-Generation-Approaches
480608524751c8f48445404ad92708133472cd0e
[ "MIT" ]
null
null
null
from src.dataset.FFHQDataset import FFHQDataset, FFHQ_NAME from src.dataset.Dataset import Dataset from src.core.Registry import Registry class DatasetRegistry(Registry[type[Dataset]]): """ Static class implementing the abstract Registry class used for initialization and storing of all subclasses of the ...
30.954545
82
0.688693
d7adf89ff7b55a81d09eb5dcfb03792aa28a0962
1,283
py
Python
tests/test_map.py
aefalcon/iterable_collections
8e3b4ea84083a100413f23af30ea27dfd4b838ff
[ "MIT" ]
4
2018-06-05T14:07:56.000Z
2021-04-17T12:09:23.000Z
tests/test_map.py
aefalcon/iterable_collections
8e3b4ea84083a100413f23af30ea27dfd4b838ff
[ "MIT" ]
1
2018-07-10T19:53:54.000Z
2018-07-10T19:58:38.000Z
tests/test_map.py
aefalcon/iterable_collections
8e3b4ea84083a100413f23af30ea27dfd4b838ff
[ "MIT" ]
2
2020-01-29T10:51:11.000Z
2021-11-11T21:37:24.000Z
import unittest from iterable_collections import collect class TestMap(unittest.TestCase): def test_list(self): c = collect(list(range(10))).map(lambda x: x + 1) self.assertEqual(c.list(), list(map(lambda x: x + 1, list(range(10))))) def test_lists(self): c = collect(list(range(10))...
36.657143
91
0.570538
0be4cee3858cc267010a49a000683e7caec35de4
1,117
py
Python
setup.py
2bRich/python-fanotify
6a9adc8c0dd4a5d837e5547fe45874b1ea622777
[ "Apache-2.0" ]
54
2015-10-23T03:33:28.000Z
2021-12-17T19:59:14.000Z
setup.py
2bRich/python-fanotify
6a9adc8c0dd4a5d837e5547fe45874b1ea622777
[ "Apache-2.0" ]
5
2015-12-08T00:59:12.000Z
2020-03-19T16:51:45.000Z
setup.py
2bRich/python-fanotify
6a9adc8c0dd4a5d837e5547fe45874b1ea622777
[ "Apache-2.0" ]
30
2015-12-07T22:17:49.000Z
2021-10-16T23:19:56.000Z
# Copyright 2015 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law ...
29.394737
78
0.697404
4b87b23d2b068f7155a0a3bf9bcb9fa1fd0e9558
257
py
Python
avalanche/models/utils.py
lebrice/avalanche
fe7e1e664ab20697343495fbe1328a20215feffb
[ "MIT" ]
1
2021-07-26T08:01:47.000Z
2021-07-26T08:01:47.000Z
avalanche/models/utils.py
lebrice/avalanche
fe7e1e664ab20697343495fbe1328a20215feffb
[ "MIT" ]
null
null
null
avalanche/models/utils.py
lebrice/avalanche
fe7e1e664ab20697343495fbe1328a20215feffb
[ "MIT" ]
1
2021-06-19T12:37:10.000Z
2021-06-19T12:37:10.000Z
from avalanche.models.dynamic_modules import MultiTaskModule def avalanche_forward(model, x, task_labels): if isinstance(model, MultiTaskModule): return model.forward(x, task_labels) else: # no task labels return model.forward(x)
28.555556
60
0.735409
1781cfb4d5924c5610cc6b6e79d645c5f0e8b57e
43
py
Python
sergeant/killer/__init__.py
adir-intsights/sergeant
76229b045309a3d795ac760d9f08da04b5e0a750
[ "MIT" ]
152
2020-04-05T08:45:37.000Z
2022-02-24T06:10:06.000Z
sergeant/killer/__init__.py
adir-intsights/sergeant
76229b045309a3d795ac760d9f08da04b5e0a750
[ "MIT" ]
29
2020-05-26T10:13:20.000Z
2022-03-31T10:52:39.000Z
sergeant/killer/__init__.py
adir-intsights/sergeant
76229b045309a3d795ac760d9f08da04b5e0a750
[ "MIT" ]
10
2020-06-03T12:30:26.000Z
2022-02-24T06:10:08.000Z
from . import process from . import thread
14.333333
21
0.767442
473d096990c6431a64897548429c8f9038d48dfc
659
py
Python
my_wallet/users/tests/test_urls.py
ibolorino/wallet-backend
99b00caebdbcf4b5e7f0f7b183615231405b15b6
[ "MIT" ]
null
null
null
my_wallet/users/tests/test_urls.py
ibolorino/wallet-backend
99b00caebdbcf4b5e7f0f7b183615231405b15b6
[ "MIT" ]
null
null
null
my_wallet/users/tests/test_urls.py
ibolorino/wallet-backend
99b00caebdbcf4b5e7f0f7b183615231405b15b6
[ "MIT" ]
null
null
null
import pytest from django.urls import resolve, reverse from my_wallet.users.models import User pytestmark = pytest.mark.django_db def test_detail(user: User): assert ( reverse("users:detail", kwargs={"username": user.username}) == f"/users/{user.username}/" ) assert resolve(f"/users/{use...
26.36
74
0.676783
ebb9efc3d909f7bf0b36711520f7eea778d5db36
214,424
py
Python
maya/cmds/__init__.py
arjun-namdeo/py_stubs
605bb167e239978f5417f3f1fc1f5c12e2a243cc
[ "MIT" ]
null
null
null
maya/cmds/__init__.py
arjun-namdeo/py_stubs
605bb167e239978f5417f3f1fc1f5c12e2a243cc
[ "MIT" ]
null
null
null
maya/cmds/__init__.py
arjun-namdeo/py_stubs
605bb167e239978f5417f3f1fc1f5c12e2a243cc
[ "MIT" ]
null
null
null
def combinationShape(*args, **kwargs): pass def AddInfluence(*args, **keywords): pass def NextKey(*args, **keywords): pass def TangetConstraintOptions(*args, **keywords): pass def contextInfo(*args, **kwargs): pass def pose(*args, **kwargs): pass def PixelMoveRight(*args, **keywords)...
13.166155
76
0.675689
7f0b040573415555375da4f37d6a66b33cc8c06b
2,359
py
Python
plenum/test/instances/test_multiple_pre_prepare.py
andkononykhin/plenum
28dc1719f4b7e80d31dafbadb38cfec4da949886
[ "Apache-2.0" ]
148
2017-07-11T19:05:25.000Z
2022-03-16T21:31:20.000Z
plenum/test/instances/test_multiple_pre_prepare.py
andkononykhin/plenum
28dc1719f4b7e80d31dafbadb38cfec4da949886
[ "Apache-2.0" ]
561
2017-06-29T17:59:56.000Z
2022-03-09T15:47:14.000Z
plenum/test/instances/test_multiple_pre_prepare.py
andkononykhin/plenum
28dc1719f4b7e80d31dafbadb38cfec4da949886
[ "Apache-2.0" ]
378
2017-06-29T17:45:27.000Z
2022-03-26T07:27:59.000Z
from functools import partial import pytest from stp_core.loop.eventually import eventually from plenum.common.messages.node_messages import PrePrepare from plenum.common.util import adict from plenum.server.suspicion_codes import Suspicions from plenum.test.helper import getNodeSuspicions from plenum.test.instances....
39.316667
77
0.728699
50726497c2f5a6aab7d953a2578c69c5b6dd2ff2
2,503
py
Python
setup.py
LEv145/python-twitch-client
f1f45cf8afb1da1335b8f29023d4db5855f009bf
[ "MIT" ]
171
2017-02-25T19:22:22.000Z
2022-02-13T22:23:14.000Z
setup.py
LEv145/python-twitch-client
f1f45cf8afb1da1335b8f29023d4db5855f009bf
[ "MIT" ]
55
2017-03-13T01:41:50.000Z
2022-02-11T20:38:54.000Z
setup.py
LEv145/python-twitch-client
f1f45cf8afb1da1335b8f29023d4db5855f009bf
[ "MIT" ]
68
2017-02-25T20:07:46.000Z
2022-02-04T16:48:47.000Z
import re import sys from codecs import open import setuptools from setuptools.command.test import test as TestCommand class PyTest(TestCommand): user_options = [("pytest-args=", "a", "Arguments to pass into pytest")] def initialize_options(self): TestCommand.initialize_options(self) self.py...
26.072917
75
0.632042
0e45dbcb00105f9840edd2d0ab9d55ec9d7d53f6
214
py
Python
kfusiontables/tests/unit/management/commands/test__templates.py
kula1922/kfusiontables
149ddaddb95319a237bb94525db17b1b3a5ac66f
[ "BSD-3-Clause" ]
4
2016-04-10T10:27:36.000Z
2018-10-12T13:45:25.000Z
kfusiontables/tests/unit/management/commands/test__templates.py
kula1922/kfusiontables
149ddaddb95319a237bb94525db17b1b3a5ac66f
[ "BSD-3-Clause" ]
2
2020-06-05T17:30:32.000Z
2021-06-01T21:52:49.000Z
kfusiontables/tests/unit/management/commands/test__templates.py
kula1922/kfusiontables
149ddaddb95319a237bb94525db17b1b3a5ac66f
[ "BSD-3-Clause" ]
null
null
null
from kfusiontables.tests.base import KFTTestCase class KftCommandsTemplatesTestCase(KFTTestCase): def setUp(self): pass def tearDown(self): pass def test_example(self): pass
16.461538
48
0.67757
ac32d1e7ed9af9647a2381cd5a66a9b2556e0c4d
2,500
py
Python
python3/TkUtil/TreeView.py
iceihehe/pipeg
c5ed0a3bde23862bc4fffb0751df0bd2c0334a90
[ "MIT" ]
null
null
null
python3/TkUtil/TreeView.py
iceihehe/pipeg
c5ed0a3bde23862bc4fffb0751df0bd2c0334a90
[ "MIT" ]
null
null
null
python3/TkUtil/TreeView.py
iceihehe/pipeg
c5ed0a3bde23862bc4fffb0751df0bd2c0334a90
[ "MIT" ]
2
2020-01-31T15:17:27.000Z
2020-05-28T13:49:53.000Z
#!/usr/bin/env python3 # Copyright © 2012-13 Qtrac Ltd. All rights reserved. # This program or module is free software: you can redistribute it # and/or modify it under the terms of the GNU General Public License as # published by the Free Software Foundation, either version 3 of the # License, or (at your option) any ...
40.322581
76
0.6664
a37b6a22d511905fc241e70d0f632560adad9a27
5,261
py
Python
nilearn/tests/test_cache_mixin.py
iglpdc/nilearn
a4cc998b7a34fa48a77ce46f9f0b6b4e75d8a2d1
[ "BSD-2-Clause" ]
1
2019-11-26T07:14:52.000Z
2019-11-26T07:14:52.000Z
nilearn/tests/test_cache_mixin.py
iglpdc/nilearn
a4cc998b7a34fa48a77ce46f9f0b6b4e75d8a2d1
[ "BSD-2-Clause" ]
null
null
null
nilearn/tests/test_cache_mixin.py
iglpdc/nilearn
a4cc998b7a34fa48a77ce46f9f0b6b4e75d8a2d1
[ "BSD-2-Clause" ]
1
2020-06-16T15:36:22.000Z
2020-06-16T15:36:22.000Z
""" Test the _utils.cache_mixin module """ import os import shutil import tempfile import json import glob from nose.tools import assert_false, assert_true, assert_equal from sklearn.externals.joblib import Memory import nilearn from nilearn._utils import cache_mixin, CacheMixin from nilearn._utils.testing import as...
33.941935
79
0.661851
1b0fdd07dd5e4a7628f758bb713b9e10927b819d
1,833
py
Python
fairing/builders/cluster/gcs_context.py
Akashdesarda/fairing
de359a7b6b90364ea3f3a280efcd11001838e9bf
[ "Apache-2.0" ]
null
null
null
fairing/builders/cluster/gcs_context.py
Akashdesarda/fairing
de359a7b6b90364ea3f3a280efcd11001838e9bf
[ "Apache-2.0" ]
null
null
null
fairing/builders/cluster/gcs_context.py
Akashdesarda/fairing
de359a7b6b90364ea3f3a280efcd11001838e9bf
[ "Apache-2.0" ]
null
null
null
import os from fairing.cloud import gcp from fairing import utils from fairing.constants import constants from fairing.kubernetes.manager import client, KubeManager from fairing.builders.cluster.context_source import ContextSourceInterface class GCSContextSource(ContextSourceInterface): def __init__(self, ...
35.941176
77
0.607747
651158b9f76fa57a89d505e1b95252b340f183f8
1,203
py
Python
connectors/file_reader.py
Nashrah31/SimDB
67b7b1676a8cb48219686fdb615e602de128a90b
[ "MIT" ]
null
null
null
connectors/file_reader.py
Nashrah31/SimDB
67b7b1676a8cb48219686fdb615e602de128a90b
[ "MIT" ]
null
null
null
connectors/file_reader.py
Nashrah31/SimDB
67b7b1676a8cb48219686fdb615e602de128a90b
[ "MIT" ]
null
null
null
import json import csv class FileReader: def __init__(self, config, global_store, mapper, next_task=None): self.next_task = next_task self.mapper = mapper self._global_store = global_store self.path = config["path"] self.format = config["format"] self.staging_buffer = config["input_staging"]...
30.075
84
0.688279
144dd80c403c5f200c84175c8299b18a6d5de2b9
1,761
py
Python
src/robotframework/common/Selenium2Lib.py
smysnk/sikuli-framework
e1590699948733aa5ee21ef92188eee03e98d1d9
[ "BSD-3-Clause" ]
47
2015-01-07T21:48:30.000Z
2021-04-02T06:46:33.000Z
src/robotframework/common/Selenium2Lib.py
smysnk/sikuli-framework
e1590699948733aa5ee21ef92188eee03e98d1d9
[ "BSD-3-Clause" ]
6
2015-04-29T12:20:36.000Z
2020-09-02T14:23:44.000Z
src/robotframework/common/Selenium2Lib.py
smysnk/sikuli-framework
e1590699948733aa5ee21ef92188eee03e98d1d9
[ "BSD-3-Clause" ]
21
2015-02-03T07:53:40.000Z
2021-09-12T20:28:52.000Z
#Interpreter: Python """ Copyright (c) 2013, SMART Technologies ULC All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this...
48.916667
73
0.799546
97664f4aecc99cca4d806d02efb9ceeba49e066b
13,121
py
Python
stoq/data_classes.py
mmip0stx/stoq
a06e359680927a47cc9eaa3828992e18ce35f6f7
[ "Apache-2.0" ]
null
null
null
stoq/data_classes.py
mmip0stx/stoq
a06e359680927a47cc9eaa3828992e18ce35f6f7
[ "Apache-2.0" ]
null
null
null
stoq/data_classes.py
mmip0stx/stoq
a06e359680927a47cc9eaa3828992e18ce35f6f7
[ "Apache-2.0" ]
1
2019-08-27T13:11:11.000Z
2019-08-27T13:11:11.000Z
#!/usr/bin/env python3 # Copyright 2014-2018 PUNCH Cyber Analytics Group # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Un...
32.317734
108
0.629297
a4a9e88c146d2c49c79004a832dfa571adc72966
1,768
py
Python
test/test_us_me.py
ranked-vote/ranked-vote-import
175f76bc04172198fde78f61115833752ef2a554
[ "MIT" ]
null
null
null
test/test_us_me.py
ranked-vote/ranked-vote-import
175f76bc04172198fde78f61115833752ef2a554
[ "MIT" ]
null
null
null
test/test_us_me.py
ranked-vote/ranked-vote-import
175f76bc04172198fde78f61115833752ef2a554
[ "MIT" ]
null
null
null
from unittest import TestCase from ranked_vote.ballot import Ballot, Candidate, UNDERVOTE, OVERVOTE from ranked_vote_import.formats.us.me import MaineNormalizer class TestUSME(TestCase): def test_normalize_do_nothing(self): normalizer = MaineNormalizer() self.assertEqual( Ballot('332...
36.081633
119
0.598416
e626e15707945d4496c298180bbe6d464f65db06
1,633
py
Python
students/forms.py
muhummadPatel/raspied
ab5362484ca5f4f5ceff9f537d5ed9dcbf06b4a8
[ "MIT" ]
1
2016-11-17T09:15:42.000Z
2016-11-17T09:15:42.000Z
students/forms.py
muhummadPatel/raspied
ab5362484ca5f4f5ceff9f537d5ed9dcbf06b4a8
[ "MIT" ]
null
null
null
students/forms.py
muhummadPatel/raspied
ab5362484ca5f4f5ceff9f537d5ed9dcbf06b4a8
[ "MIT" ]
null
null
null
from django.contrib.auth import get_user_model from django.contrib.auth.forms import AuthenticationForm from django.core.exceptions import ObjectDoesNotExist, ValidationError from django.utils.translation import ugettext_lazy as _ from registration.forms import RegistrationForm from .models import WhitelistedUsername...
37.976744
115
0.723209