hexsha
stringlengths
40
40
size
int64
1
1.03M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
239
max_stars_repo_name
stringlengths
5
130
max_stars_repo_head_hexsha
stringlengths
40
78
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
3
239
max_issues_repo_name
stringlengths
5
130
max_issues_repo_head_hexsha
stringlengths
40
78
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
3
239
max_forks_repo_name
stringlengths
5
130
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.03M
avg_line_length
float64
1
958k
max_line_length
int64
1
1.03M
alphanum_fraction
float64
0
1
4a102362397af8fb5c0a1ce280ddc752356d7ab2
4,840
py
Python
cipher/process_multitask.py
kaczmarj/cipher
e1ad5bb4ca86a7c45f54bb4fdb6f05d6c4a1b1a9
[ "MIT" ]
null
null
null
cipher/process_multitask.py
kaczmarj/cipher
e1ad5bb4ca86a7c45f54bb4fdb6f05d6c4a1b1a9
[ "MIT" ]
null
null
null
cipher/process_multitask.py
kaczmarj/cipher
e1ad5bb4ca86a7c45f54bb4fdb6f05d6c4a1b1a9
[ "MIT" ]
null
null
null
""" This script will take the following arguments in the command line, import helper functions from an external script, and conduct all preprocessing steps Parameters: ----------- metadata: str location for metadata table containing experiment information data_dir: str directory containing corresponding sequen...
30.440252
88
0.651033
4a10244368b2afb1e88e770cad4cacbab409fc36
8,304
py
Python
setup.py
dnaveenr/datasets
f144ba69aee057e9e1447796712302adc3d6558a
[ "Apache-2.0" ]
null
null
null
setup.py
dnaveenr/datasets
f144ba69aee057e9e1447796712302adc3d6558a
[ "Apache-2.0" ]
null
null
null
setup.py
dnaveenr/datasets
f144ba69aee057e9e1447796712302adc3d6558a
[ "Apache-2.0" ]
null
null
null
# Lint as: python3 """ HuggingFace/Datasets is an open library of datasets. Note: VERSION needs to be formatted following the MAJOR.MINOR.PATCH convention (we need to follow this convention to be able to retrieve versioned scripts) Simple check list for release from AllenNLP repo: https://github.com/allenai/al...
31.574144
129
0.645352
4a10245e274ca2fa0f82248ba13daab998aa1510
1,736
py
Python
code/a.py
PaulRenauld/k-mean-cuda
3a905e875e3f2f80e4087ef142d100c7c1d86180
[ "MIT" ]
null
null
null
code/a.py
PaulRenauld/k-mean-cuda
3a905e875e3f2f80e4087ef142d100c7c1d86180
[ "MIT" ]
null
null
null
code/a.py
PaulRenauld/k-mean-cuda
3a905e875e3f2f80e4087ef142d100c7c1d86180
[ "MIT" ]
null
null
null
import sys import matplotlib.pyplot as plt if __name__ == '__main__': f1 = "../results/n100000k50.csv" f2 = "../results/n100000k50a.csv" y_col = 1 x1_buf = [] x2_buf = [] y1_buf = [] y2_buf = [] with open(f1) as file1: with open(f2) as file2: lines1 = file1.readlines...
35.428571
99
0.521889
4a1024eca226a73fb9d6e97b0f88955ef27d860d
443
py
Python
pb2.4/run_google24.py
bumptech/cypb
e3bff4757d86ab8b8b99f6be2352549c180999c3
[ "BSD-3-Clause" ]
2
2021-01-03T17:03:41.000Z
2021-06-14T17:38:33.000Z
pb2.4/run_google24.py
bumptech/cypb
e3bff4757d86ab8b8b99f6be2352549c180999c3
[ "BSD-3-Clause" ]
null
null
null
pb2.4/run_google24.py
bumptech/cypb
e3bff4757d86ab8b8b99f6be2352549c180999c3
[ "BSD-3-Clause" ]
1
2021-01-13T11:16:34.000Z
2021-01-13T11:16:34.000Z
import time import connexiopb from connexio_pb2 import * msg = "CiAKBUF0YXNoGghBdGFtdXJhZCINSGV6cmV0a3VsaXlldioUChJhdGFteXJhdEBnbWFpbC5jb20q\nFAoSYXRhbXVyYWRAY29ubmV4LmlvKhQKEmF0YW11cmFkQGdtYWlsLmNvbTIOCgwrOTkzNjc2NDI2\nNDIyDgoMKzk5MzEyMjcwMjAzYh50aGlzIGlzIG5vdGUgZmllbGQgZm9yIGNvbnRhY3Q=\n".decode("base64") start = ...
26.058824
251
0.835214
4a102629af76facf5aaa672ee52027e95f45c43f
14,025
py
Python
dev.py
Schrodinger1926/Project-4
3a5a79529d141895031ce7007e1119d02d2e0ce0
[ "MIT" ]
null
null
null
dev.py
Schrodinger1926/Project-4
3a5a79529d141895031ce7007e1119d02d2e0ce0
[ "MIT" ]
null
null
null
dev.py
Schrodinger1926/Project-4
3a5a79529d141895031ce7007e1119d02d2e0ce0
[ "MIT" ]
null
null
null
import sys import os import numpy as np import cv2 import matplotlib.pyplot as plt import matplotlib.image as mpimg from moviepy.editor import VideoFileClip IMG_INPUT_DIR = 'test_images' IMG_OUTPUT_DIR = 'test_images' CALIB_DATA_DIR = 'camera_cal' RND_DIR = 'rnd' M, Minv = None, None def get_img_points(img_abs_path...
34.715347
158
0.654046
4a102686355f01e24a42730f62ab9bd096cac652
2,815
py
Python
cirq-core/cirq/contrib/paulistring/pauli_string_optimize.py
Nexuscompute/Cirq
640ef8f82d6a56ec95361388ce7976e096cca906
[ "Apache-2.0" ]
null
null
null
cirq-core/cirq/contrib/paulistring/pauli_string_optimize.py
Nexuscompute/Cirq
640ef8f82d6a56ec95361388ce7976e096cca906
[ "Apache-2.0" ]
4
2022-01-16T14:12:15.000Z
2022-02-24T03:58:46.000Z
cirq-core/cirq/contrib/paulistring/pauli_string_optimize.py
Nexuscompute/Cirq
640ef8f82d6a56ec95361388ce7976e096cca906
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 The Cirq Developers # # 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 ...
38.561644
97
0.728242
4a1026a3dcc69dc3d3616fbdc94627c1ba6847ce
1,470
py
Python
scripts/cleanup_datasets/remove_renamed_datasets_from_disk.py
igorhollaender/sirv_dashboard
85aec60b80ef6f561d89398e3da5963d3d0f2aa4
[ "CC-BY-3.0" ]
2
2018-10-14T16:42:39.000Z
2018-10-14T16:42:41.000Z
scripts/cleanup_datasets/remove_renamed_datasets_from_disk.py
igorhollaender/OBSOLETE_sirv_dashboard
85aec60b80ef6f561d89398e3da5963d3d0f2aa4
[ "CC-BY-3.0" ]
null
null
null
scripts/cleanup_datasets/remove_renamed_datasets_from_disk.py
igorhollaender/OBSOLETE_sirv_dashboard
85aec60b80ef6f561d89398e3da5963d3d0f2aa4
[ "CC-BY-3.0" ]
null
null
null
#!/usr/bin/env python """ Removes a dataset file ( which was first renamed by appending _purged to the file name ) from disk. Usage: python remove_renamed_datasets_from_disk.py renamed.log """ import os import sys assert sys.version_info[:2] >= ( 2, 4 ) def usage(prog) : print "usage: %s file" % prog print ...
29.4
105
0.606122
4a10283533154e55905b5c45d4a14f88ff89e5a3
19,802
py
Python
modules/pytket-honeywell/pytket/extensions/honeywell/backends/api_wrappers.py
CQCL/pytket-extensions
45d36ff16636a194046c37e64060164611559d19
[ "Apache-2.0" ]
22
2021-03-02T15:17:22.000Z
2022-03-20T21:17:10.000Z
modules/pytket-honeywell/pytket/extensions/honeywell/backends/api_wrappers.py
CQCL/pytket-extensions
45d36ff16636a194046c37e64060164611559d19
[ "Apache-2.0" ]
132
2021-03-03T08:30:05.000Z
2022-03-31T21:11:58.000Z
modules/pytket-honeywell/pytket/extensions/honeywell/backends/api_wrappers.py
CQCL/pytket-extensions
45d36ff16636a194046c37e64060164611559d19
[ "Apache-2.0" ]
13
2021-03-05T17:01:19.000Z
2022-03-17T15:38:02.000Z
# -*- coding: utf-8 -*- """" Functions used to submit jobs with Honeywell Quantum Solutions API. Adapted from original file provided by Honeywell Quantum Solutions """ import datetime import time from http import HTTPStatus from typing import Optional, Dict, Any, Tuple import asyncio import json import getpass import...
35.172291
89
0.551055
4a1028ebe509064e9d636e8e8da08896df084436
74,077
py
Python
scipy/stats/tests/test_distributions.py
jetuk/scipy
8a9310265464d81d51a56baf499336cf07acc8e5
[ "BSD-3-Clause" ]
null
null
null
scipy/stats/tests/test_distributions.py
jetuk/scipy
8a9310265464d81d51a56baf499336cf07acc8e5
[ "BSD-3-Clause" ]
null
null
null
scipy/stats/tests/test_distributions.py
jetuk/scipy
8a9310265464d81d51a56baf499336cf07acc8e5
[ "BSD-3-Clause" ]
1
2019-08-13T21:23:57.000Z
2019-08-13T21:23:57.000Z
""" Test functions for stats module """ from __future__ import division, print_function, absolute_import import warnings import re import sys from numpy.testing import (TestCase, run_module_suite, assert_equal, assert_array_equal, assert_almost_equal, assert_array_almost_equal, assert_allclose, assert_, asse...
37.48836
86
0.588928
4a10291c430e69e2696c7a5be61e579fe8f8b483
4,176
py
Python
glomeruli_segmentation/api_interface.py
theodore-evans/hubmap-kidney-segmentation
7842655d49080be28682a9cf0394bcbe53172ddc
[ "MIT" ]
null
null
null
glomeruli_segmentation/api_interface.py
theodore-evans/hubmap-kidney-segmentation
7842655d49080be28682a9cf0394bcbe53172ddc
[ "MIT" ]
null
null
null
glomeruli_segmentation/api_interface.py
theodore-evans/hubmap-kidney-segmentation
7842655d49080be28682a9cf0394bcbe53172ddc
[ "MIT" ]
null
null
null
from io import BytesIO from logging import Logger from typing import Tuple, Type, Union import desert from aiohttp import ClientSession, TCPConnector from marshmallow import EXCLUDE from PIL import Image from glomeruli_segmentation.aiohttp_hooks import get_logging_hooks from glomeruli_segmentation.data_classes import...
34.8
143
0.633142
4a10295b92dd20b77d763cfd6182b90950f823e4
1,599
py
Python
src/pipe/pipe.py
Ochmar/kivy_floppy_bird
0ef38ecc7b160e723dbb99cf6d71dba0024b0836
[ "MIT" ]
null
null
null
src/pipe/pipe.py
Ochmar/kivy_floppy_bird
0ef38ecc7b160e723dbb99cf6d71dba0024b0836
[ "MIT" ]
null
null
null
src/pipe/pipe.py
Ochmar/kivy_floppy_bird
0ef38ecc7b160e723dbb99cf6d71dba0024b0836
[ "MIT" ]
null
null
null
from kivy.uix.widget import Widget from kivy.properties import NumericProperty, ObjectProperty, ListProperty from kivy.uix.image import Image from kivy.clock import Clock class Pipe(Widget): GAP_SIZE = NumericProperty(100) CAP_SIZE = NumericProperty(20) pipe_center = NumericProperty(0) bottom_body_pos...
35.533333
79
0.693558
4a102a037ec43a6ba7dabf95381c352ed0fe2ce0
2,296
py
Python
src/GimelStudio/corenodes/blend/composite_node.py
iwoithe/Gimel-Studio
e2750576e72edee6f2f4c268045b81459df82d89
[ "Apache-2.0" ]
47
2020-05-22T09:10:05.000Z
2021-04-08T06:27:50.000Z
src/GimelStudio/corenodes/blend/composite_node.py
iwoithe/Gimel-Studio
e2750576e72edee6f2f4c268045b81459df82d89
[ "Apache-2.0" ]
24
2020-08-26T13:51:10.000Z
2021-04-18T01:41:51.000Z
src/GimelStudio/corenodes/blend/composite_node.py
iwoithe/Gimel-Studio
e2750576e72edee6f2f4c268045b81459df82d89
[ "Apache-2.0" ]
9
2020-08-16T14:27:14.000Z
2021-02-17T19:04:34.000Z
# THIS FILE IS A PART OF GIMEL STUDIO AND IS LICENSED UNDER THE SAME TERMS: # ---------------------------------------------------------------------------- # Gimel Studio Copyright 2019-2021 by Noah Rahm and contributors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file exce...
35.875
99
0.630662
4a102aaceb9253ea6edf5251bb0d6ce384f17c25
25,148
py
Python
analysis/webservice/algorithms_spark/TimeSeriesSpark.py
tloubrieu-jpl/incubator-sdap-nexus
5bf903f04f12eb27f25ea2aa738c617ca404a87b
[ "Apache-2.0" ]
1
2019-11-25T18:49:26.000Z
2019-11-25T18:49:26.000Z
analysis/webservice/algorithms_spark/TimeSeriesSpark.py
ifenty/incubator-sdap-nexus
3059c66f53d3f3d24c74d557c7632bdcc7f1eeec
[ "Apache-2.0" ]
null
null
null
analysis/webservice/algorithms_spark/TimeSeriesSpark.py
ifenty/incubator-sdap-nexus
3059c66f53d3f3d24c74d557c7632bdcc7f1eeec
[ "Apache-2.0" ]
null
null
null
# Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not use ...
43.965035
180
0.562589
4a102b1ac6c5d339c6ed016a53f757c9e9d82a9b
309
py
Python
italian_csv_type_prediction/features/feature.py
LucaCappelletti94/italian_csv_type_prediction
a6332c4fd5b29d3b52e9b940fe964c9fffa2b3b4
[ "MIT" ]
null
null
null
italian_csv_type_prediction/features/feature.py
LucaCappelletti94/italian_csv_type_prediction
a6332c4fd5b29d3b52e9b940fe964c9fffa2b3b4
[ "MIT" ]
1
2021-02-24T11:01:06.000Z
2021-02-24T11:01:06.000Z
italian_csv_type_prediction/features/feature.py
LucaCappelletti94/italian_csv_type_prediction
a6332c4fd5b29d3b52e9b940fe964c9fffa2b3b4
[ "MIT" ]
null
null
null
class Feature: """A text related feature.""" @property def name(self): """Return type identified by this predictor.""" return self.__class__.__name__[:-4] def score(self, value)->float: raise NotImplementedError("This method must be implemented in children classes.")
30.9
89
0.656958
4a102ce9001a95136a4bbcc87204cf7de7bed6bd
1,845
py
Python
pdx-base/usr/share/pdx/python/pdx-poweroff.py
hoopsurfer/pdxnew
8fd71916b6fbf1f020c409a206e34573784e528f
[ "Apache-2.0" ]
10
2020-01-29T16:11:30.000Z
2021-05-29T11:43:57.000Z
pdx-base/usr/share/pdx/python/pdx-poweroff.py
hoopsurfer/pdxnew
8fd71916b6fbf1f020c409a206e34573784e528f
[ "Apache-2.0" ]
2
2020-02-02T08:59:35.000Z
2020-09-12T20:42:06.000Z
pdx-base/usr/share/pdx/python/pdx-poweroff.py
hoopsurfer/pdxnew
8fd71916b6fbf1f020c409a206e34573784e528f
[ "Apache-2.0" ]
4
2020-02-13T21:15:55.000Z
2020-05-07T15:33:21.000Z
#!/user/bin/env python # pdx-poweroff.py - oneshot service so do your thing and exit # # We are in poweroff processing because shutdown has started for whatever reason. # This code can do any needed poweroff specific processing for power management. # The critical activity is a long press of the power button through G...
34.811321
81
0.746883
4a102d0cc2ac15e2bcd2c2bf8fcc400a592cc288
111,365
py
Python
tests/cache/tests.py
danhayden/django
49b470b9187b6be60e573fed08c8f4a87f133750
[ "BSD-3-Clause", "0BSD" ]
2
2021-12-17T07:27:44.000Z
2021-12-17T19:16:52.000Z
tests/cache/tests.py
danhayden/django
49b470b9187b6be60e573fed08c8f4a87f133750
[ "BSD-3-Clause", "0BSD" ]
6
2022-01-13T17:38:02.000Z
2022-03-15T15:24:12.000Z
tests/cache/tests.py
danhayden/django
49b470b9187b6be60e573fed08c8f4a87f133750
[ "BSD-3-Clause", "0BSD" ]
2
2020-01-01T18:36:17.000Z
2022-02-21T14:00:56.000Z
# Unit tests for cache framework # Uses whatever cache backend is set in the test settings file. import copy import io import os import pickle import re import shutil import sys import tempfile import threading import time import unittest from pathlib import Path from unittest import mock, skipIf from django.conf impo...
38.099555
88
0.626085
4a102d3616f0c455be159f217c9ddd40b3d9710d
39,321
py
Python
get_together/views/events.py
thiagoferreiraw/GetTogether
0cfa2bcf0915dd03ed5e5b9fab641b058eee1ca3
[ "BSD-2-Clause" ]
null
null
null
get_together/views/events.py
thiagoferreiraw/GetTogether
0cfa2bcf0915dd03ed5e5b9fab641b058eee1ca3
[ "BSD-2-Clause" ]
null
null
null
get_together/views/events.py
thiagoferreiraw/GetTogether
0cfa2bcf0915dd03ed5e5b9fab641b058eee1ca3
[ "BSD-2-Clause" ]
null
null
null
from django.utils.translation import ugettext_lazy as _ from django.utils.safestring import mark_safe from django.contrib import messages from django.contrib.auth.models import User from django.contrib.auth.decorators import login_required from django.shortcuts import render, redirect, reverse, get_object_or_404 from ...
40.789419
159
0.643091
4a102d71d0b862c8bd7a54f36b0f0722b30a51eb
4,361
py
Python
src/planning/settings/base.py
stuttup/planning
0932a6af171a616ad3de50c343aed417ee25a222
[ "MIT" ]
null
null
null
src/planning/settings/base.py
stuttup/planning
0932a6af171a616ad3de50c343aed417ee25a222
[ "MIT" ]
null
null
null
src/planning/settings/base.py
stuttup/planning
0932a6af171a616ad3de50c343aed417ee25a222
[ "MIT" ]
null
null
null
""" Django settings for planning project. For more information on this file, see https://docs.djangoproject.com/en/dev/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/dev/ref/settings/ """ from django.core.urlresolvers import reverse_lazy from os.path import dirn...
27.601266
74
0.711534
4a102e9c827376b727a4ac2009a82650bb7e9875
2,554
py
Python
backend/pyrogram/raw/types/update_message_poll_vote.py
appheap/social-media-analyzer
0f9da098bfb0b4f9eb38e0244aa3a168cf97d51c
[ "Apache-2.0" ]
5
2021-09-11T22:01:15.000Z
2022-03-16T21:33:42.000Z
backend/pyrogram/raw/types/update_message_poll_vote.py
iamatlasss/social-media-analyzer
429d1d2bbd8bfce80c50c5f8edda58f87ace668d
[ "Apache-2.0" ]
null
null
null
backend/pyrogram/raw/types/update_message_poll_vote.py
iamatlasss/social-media-analyzer
429d1d2bbd8bfce80c50c5f8edda58f87ace668d
[ "Apache-2.0" ]
3
2022-01-18T11:06:22.000Z
2022-02-26T13:39:28.000Z
# Pyrogram - Telegram MTProto API Client Library for Python # Copyright (C) 2017-2021 Dan <https://github.com/delivrance> # # This file is part of Pyrogram. # # Pyrogram is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published # by the Free...
31.530864
103
0.629601
4a102eb7d56be9c99be1a0ab70fd7a608b0c12ed
21,492
py
Python
test/oscprob3nu_plot.py
mbustama/NuOscProbExact
76c816e75a995fbeeb98b0249a7b9e03769aa12b
[ "MIT" ]
14
2019-04-30T01:40:45.000Z
2022-03-23T05:00:13.000Z
test/oscprob3nu_plot.py
mbustama/NuOscProbExact
76c816e75a995fbeeb98b0249a7b9e03769aa12b
[ "MIT" ]
1
2022-03-11T14:33:03.000Z
2022-03-11T14:33:03.000Z
test/oscprob3nu_plot.py
mbustama/NuOscProbExact
76c816e75a995fbeeb98b0249a7b9e03769aa12b
[ "MIT" ]
9
2019-04-30T16:47:25.000Z
2022-03-23T05:00:19.000Z
# -*- coding: utf-8 -*- r"""Routines to plot three-neutrino flavor-transition probabilities. This module contains contains routines to plot three-neutrino oscillation probabilities vs. the neutrino baseline and energy. These routines are used by run_testsuite.py to produce a suite of test plots. Routine listings ---...
38.724324
81
0.582217
4a102f2ef68dd46f3302b11915681d4ede4009a8
8,170
py
Python
nectar/theanoutil/model.py
Y0mingZhang/nectar
ca2bebdfedf46dfee9a2cb2d1bc82ad5c0871c93
[ "MIT" ]
null
null
null
nectar/theanoutil/model.py
Y0mingZhang/nectar
ca2bebdfedf46dfee9a2cb2d1bc82ad5c0871c93
[ "MIT" ]
null
null
null
nectar/theanoutil/model.py
Y0mingZhang/nectar
ca2bebdfedf46dfee9a2cb2d1bc82ad5c0871c93
[ "MIT" ]
null
null
null
"""Standard utilties for a theano model.""" import collections import numbers import numpy as np import pickle import random import sys import theano import time from tkinter import TclError from . import __init__ as ntu from .. import log, secs_to_str class TheanoModel(object): """A generic theano model. This c...
32.165354
94
0.673929
4a103193f94515ec2f023399574112431af531a2
2,089
py
Python
certbot-dns-cloudxns/setup.py
singhdeepu/certificateprovider
ed2168aaa8c8a7e1bef449e60167b53d501d173a
[ "Apache-2.0" ]
null
null
null
certbot-dns-cloudxns/setup.py
singhdeepu/certificateprovider
ed2168aaa8c8a7e1bef449e60167b53d501d173a
[ "Apache-2.0" ]
808
2018-11-09T05:14:26.000Z
2021-08-03T05:26:10.000Z
certbot-dns-cloudxns/setup.py
singhdeepu/certificateprovider
ed2168aaa8c8a7e1bef449e60167b53d501d173a
[ "Apache-2.0" ]
null
null
null
import sys from setuptools import setup from setuptools import find_packages version = '0.21.0.dev0' # Please update tox.ini when modifying dependency version requirements install_requires = [ 'acme=={0}'.format(version), 'certbot=={0}'.format(version), 'dns-lexicon', 'mock', # For pkg_resources...
30.275362
78
0.624222
4a103194f3f86c61093a0498b29d52e41aee3003
3,231
py
Python
certbot-compatibility-test/certbot_compatibility_test/configurators/nginx/common.py
lpmitchell/certbot
fe0c0dc3ae6c25c6087e51717a223f38a9b23d2f
[ "Apache-2.0" ]
null
null
null
certbot-compatibility-test/certbot_compatibility_test/configurators/nginx/common.py
lpmitchell/certbot
fe0c0dc3ae6c25c6087e51717a223f38a9b23d2f
[ "Apache-2.0" ]
null
null
null
certbot-compatibility-test/certbot_compatibility_test/configurators/nginx/common.py
lpmitchell/certbot
fe0c0dc3ae6c25c6087e51717a223f38a9b23d2f
[ "Apache-2.0" ]
1
2022-03-31T07:54:20.000Z
2022-03-31T07:54:20.000Z
"""Provides a common base for Nginx proxies""" import os import shutil import subprocess from typing import Set from typing import Tuple from certbot_compatibility_test import errors from certbot_compatibility_test import util from certbot_compatibility_test.configurators import common as configurators_common from cer...
35.505495
86
0.662953
4a10322dfd2f6b2d7093c0438917071792e81daf
101,029
py
Python
macmini-liz/anode/src/main/python/anode/plugin/plugin.py
ggear/asystem
c949a1624812eab5b063681f46a88ccc9527266e
[ "Apache-2.0" ]
4
2019-03-26T13:57:54.000Z
2021-11-04T04:55:49.000Z
macmini-liz/anode/src/main/python/anode/plugin/plugin.py
ggear/asystem
c949a1624812eab5b063681f46a88ccc9527266e
[ "Apache-2.0" ]
1
2021-04-03T01:10:11.000Z
2021-04-03T01:10:11.000Z
macmini-liz/anode/src/main/python/anode/plugin/plugin.py
ggear/asystem
c949a1624812eab5b063681f46a88ccc9527266e
[ "Apache-2.0" ]
2
2019-04-02T19:20:34.000Z
2019-08-13T16:39:52.000Z
from __future__ import print_function import sys sys.path.append('./main/python') import HTMLParser import StringIO import abc import base64 import calendar import datetime import decimal import io import json import logging import numbers import operator import os.path import re import shutil import time import url...
61.867116
140
0.585515
4a10330f9d8ea805a53cae3ced9e32910ab976fc
1,298
py
Python
biobakery_workflows/scripts/remove_if_exists.py
tkuntz-hsph/biobakery_workflows
e861705d939354178362fd5b26e59dcc696489d2
[ "MIT" ]
47
2020-08-18T20:51:02.000Z
2022-03-21T19:43:13.000Z
biobakery_workflows/scripts/remove_if_exists.py
tkuntz-hsph/biobakery_workflows
e861705d939354178362fd5b26e59dcc696489d2
[ "MIT" ]
18
2020-06-12T21:26:46.000Z
2022-03-19T08:24:55.000Z
biobakery_workflows/scripts/remove_if_exists.py
tkuntz-hsph/biobakery_workflows
e861705d939354178362fd5b26e59dcc696489d2
[ "MIT" ]
15
2020-07-24T16:41:46.000Z
2022-02-22T09:02:01.000Z
#!/usr/bin/env python """ This script will remove a file if it exists. It will report error messages from trying to remove the file. """ import sys import shutil try: import argparse except ImportError: sys.exit("Please upgrade to at least python v2.7") import os def parse_arguments(args): ...
27.617021
96
0.642527
4a10349ed4dec2af6df81ee777ad8422925930e9
1,254
py
Python
1. Algorithmic Toolbox/week2_algorithmic_warmup/8_last_digit_of_the_sum_of_squares_of_fibonacci_numbers.py
vishweshwartyagi/Data-Structures-and-Algorithms-UCSD
de942b3a0eb2bf56f949f47c297fad713aa81489
[ "MIT" ]
null
null
null
1. Algorithmic Toolbox/week2_algorithmic_warmup/8_last_digit_of_the_sum_of_squares_of_fibonacci_numbers.py
vishweshwartyagi/Data-Structures-and-Algorithms-UCSD
de942b3a0eb2bf56f949f47c297fad713aa81489
[ "MIT" ]
null
null
null
1. Algorithmic Toolbox/week2_algorithmic_warmup/8_last_digit_of_the_sum_of_squares_of_fibonacci_numbers.py
vishweshwartyagi/Data-Structures-and-Algorithms-UCSD
de942b3a0eb2bf56f949f47c297fad713aa81489
[ "MIT" ]
null
null
null
# Uses python3 from sys import stdin def fibonacci_sum_squares_naive(n): if n <= 1: return n previous = 0 current = 1 sum = 1 for _ in range(n - 1): previous, current = current, previous + current sum += current * current return sum % 10 def mat_mul(A, B, q): ...
19
65
0.49362
4a1034aa06543aae909aa89e3607c39cf2e87ca0
6,811
py
Python
hvac/api/secrets_engines/consul.py
leongyh/hvac
4697d5ec097809def0e0bacd166f6db520db7d94
[ "Apache-2.0" ]
1
2020-12-14T04:01:10.000Z
2020-12-14T04:01:10.000Z
hvac/api/secrets_engines/consul.py
TerryHowe/hvac
a6b7f904bfaba3c1133ccc7fa5a0cff0d29340c7
[ "Apache-2.0" ]
null
null
null
hvac/api/secrets_engines/consul.py
TerryHowe/hvac
a6b7f904bfaba3c1133ccc7fa5a0cff0d29340c7
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """Consul methods module.""" from hvac import exceptions, utils from hvac.api.vault_api_base import VaultApiBase DEFAULT_MOUNT_POINT = "consul" class Consul(VaultApiBase): """Copnsul Secrets Engine (API). Reference: https://www.vaultproject.io/api/secret/consul/...
42.04321
122
0.641316
4a103526a51a8ad88b3c9f227139ecefef9f419e
5,100
py
Python
src/lcd16x2.py
dooley-ch/microbit-grove
e25213de74d982b8ab49412e6f8b2dbe205ca932
[ "MIT" ]
null
null
null
src/lcd16x2.py
dooley-ch/microbit-grove
e25213de74d982b8ab49412e6f8b2dbe205ca932
[ "MIT" ]
null
null
null
src/lcd16x2.py
dooley-ch/microbit-grove
e25213de74d982b8ab49412e6f8b2dbe205ca932
[ "MIT" ]
null
null
null
# ------------------------------------------------------------------------------------------ # Copyright James A. Dooley 2021. # # Distributed under the MIT License. # (See accompanying file license.md file or copy at http://opensource.org/licenses/MIT) # # --------------------------------------------------------------...
29.479769
92
0.622941
4a103532642f5a3aaebbe39ea6373ce2230e0455
5,185
py
Python
equatorial_UVW.py
jgagneastro/jg_kinematics
cd1469ab342240d15b01b75ca038d545dbaf227a
[ "MIT" ]
1
2018-12-04T21:54:07.000Z
2018-12-04T21:54:07.000Z
equatorial_UVW.py
jgagneastro/jg_kinematics
cd1469ab342240d15b01b75ca038d545dbaf227a
[ "MIT" ]
null
null
null
equatorial_UVW.py
jgagneastro/jg_kinematics
cd1469ab342240d15b01b75ca038d545dbaf227a
[ "MIT" ]
null
null
null
import numpy as np #Numpy maths #Initiate some global constants #1 AU/yr to km/s divided by 1000 kappa = 0.004743717361 #Not using "from astropy import units as u; kappa=u.au.to(u.km)/u.year.to(u.s)" because astropy defines one year as exactly 365.25 days instead of 365 days #Galactic Coordinates matrix TGAL = (np.ar...
46.294643
183
0.724204
4a103602e3067486420afe003535c56a8147050c
11,253
py
Python
tests/test_commands.py
Gobot1234/steam
ffcd3a6c4d531fbf174f359f0b66d9a9525d62cb
[ "MIT" ]
79
2020-02-26T19:20:07.000Z
2022-03-24T11:12:57.000Z
tests/test_commands.py
Gobot1234/steam
ffcd3a6c4d531fbf174f359f0b66d9a9525d62cb
[ "MIT" ]
34
2020-04-26T01:55:31.000Z
2022-03-15T17:38:34.000Z
tests/test_commands.py
Gobot1234/steam
ffcd3a6c4d531fbf174f359f0b66d9a9525d62cb
[ "MIT" ]
14
2020-07-15T14:50:14.000Z
2022-01-26T21:51:30.000Z
import contextlib import traceback from copy import copy from io import StringIO from typing import Any, Generator, Optional, TypeVar, Union import pytest from typing_extensions import TypeAlias import steam from steam.ext import commands from tests.mocks import GROUP_MESSAGE CE = TypeVar("CE", bound=commands.Comman...
28.560914
111
0.64445
4a103648a367a8f44cb00908c0b56beb2aa894c8
2,017
py
Python
collection/launcher.py
L0adinggg/Braised-vegetables
d979bb0affd6257178f5b22e675d6350ece41b44
[ "CC0-1.0" ]
20
2021-06-02T03:20:34.000Z
2021-11-10T03:29:25.000Z
collection/launcher.py
L0adinggg/Braised-vegetables
d979bb0affd6257178f5b22e675d6350ece41b44
[ "CC0-1.0" ]
null
null
null
collection/launcher.py
L0adinggg/Braised-vegetables
d979bb0affd6257178f5b22e675d6350ece41b44
[ "CC0-1.0" ]
2
2022-03-17T04:06:47.000Z
2022-03-17T06:17:04.000Z
#!/usr/bin/python3 # coding: utf-8 import queue import simplejson import threading import subprocess import requests import warnings warnings.filterwarnings(action='ignore') urls_queue = queue.Queue() tclose=0 def opt2File(paths): try: f = open('crawl_result.txt','a') f.write(paths + '\n') fi...
23.729412
186
0.650471
4a1038cb2f56ce8aa6f61ec4c863614a3d27c93e
1,320
py
Python
assignments/03_days/days.py
charlesb107/biosystems-analytics-2020
38d61c2db203626777db384ca720695723d61e8f
[ "MIT" ]
null
null
null
assignments/03_days/days.py
charlesb107/biosystems-analytics-2020
38d61c2db203626777db384ca720695723d61e8f
[ "MIT" ]
null
null
null
assignments/03_days/days.py
charlesb107/biosystems-analytics-2020
38d61c2db203626777db384ca720695723d61e8f
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """ Author : charlesb107 Date : 2020-02-17 Purpose: Repeat the days of the week Reference: Tiny Python Projects (Book)/Biosystems Analytics (BE534), Spring 2020 """ import argparse import os import sys # -------------------------------------------------- def get_args(): """Get command-li...
25.882353
80
0.520455
4a10395677bb4896012a15f4307c081c65ba0db1
1,479
py
Python
app/core/tools/integrals.py
Matexer/BSPR
a503a8795cb0f4cebe2eedd148aa00aea75b570e
[ "MIT" ]
null
null
null
app/core/tools/integrals.py
Matexer/BSPR
a503a8795cb0f4cebe2eedd148aa00aea75b570e
[ "MIT" ]
null
null
null
app/core/tools/integrals.py
Matexer/BSPR
a503a8795cb0f4cebe2eedd148aa00aea75b570e
[ "MIT" ]
null
null
null
import numpy as np class Integrals: @staticmethod def rect(prep_p_sur, smp_time): return smp_time * sum(prep_p_sur) @staticmethod def trapeze(prep_p_sur, smp_time): if len(prep_p_sur) < 2: return prep_p_sur[0] * smp_time A = (prep_p_sur[0] + prep_p_sur[-1]) / 2 ...
25.5
103
0.441515
4a1039a00afcb8202e0a77c3558e4bf3c77500ec
1,323
py
Python
aalh_iit_jdoylewitgencollection/merge-description-columns.py
johndewees/iitmigration
4dadfbecda719d6e7d60af076a231aedec3c862f
[ "Unlicense" ]
null
null
null
aalh_iit_jdoylewitgencollection/merge-description-columns.py
johndewees/iitmigration
4dadfbecda719d6e7d60af076a231aedec3c862f
[ "Unlicense" ]
null
null
null
aalh_iit_jdoylewitgencollection/merge-description-columns.py
johndewees/iitmigration
4dadfbecda719d6e7d60af076a231aedec3c862f
[ "Unlicense" ]
null
null
null
from openpyxl import load_workbook filename = 'aalh_iit_jdoylewitgencollection.xlsx' wb = load_workbook(filename) ws = wb['Metadata Template'] minimumcol = 8 maximumcol = 8 minimumrow = 7 maximumrow = 203 iterationrow = 7 targetcol = 46 linkstring = 'Terms associated with the photograph are: ' for ro...
40.090909
105
0.684807
4a1039eabafb7111bfb00e642c818ac7c4d16733
1,007
py
Python
env/lib/python3.6/site-packages/dipy/tracking/tests/test_learning.py
Raniac/NEURO-LEARN
3c3acc55de8ba741e673063378e6cbaf10b64c7a
[ "Apache-2.0" ]
8
2019-05-29T09:38:30.000Z
2021-01-20T03:36:59.000Z
env/lib/python3.6/site-packages/dipy/tracking/tests/test_learning.py
Raniac/neurolearn_dev
3c3acc55de8ba741e673063378e6cbaf10b64c7a
[ "Apache-2.0" ]
12
2021-03-09T03:01:16.000Z
2022-03-11T23:59:36.000Z
env/lib/python3.6/site-packages/dipy/tracking/tests/test_learning.py
Raniac/NEURO-LEARN
3c3acc55de8ba741e673063378e6cbaf10b64c7a
[ "Apache-2.0" ]
1
2020-07-17T12:49:49.000Z
2020-07-17T12:49:49.000Z
""" Testing track_metrics module """ import numpy as np from dipy.testing import assert_true, assert_false from numpy.testing import (assert_array_equal, assert_array_almost_equal, assert_equal, assert_almost_equal) from dipy.tracking import metrics as tm from dipy.tracking import distances ...
29.617647
73
0.602781
4a103a118e1c971902cf6bf85399180a06392ffd
411
py
Python
polylexis/wsgi.py
heitorchang/polylexis
22589560fb015cffb6419308349c5518a5c38551
[ "MIT" ]
null
null
null
polylexis/wsgi.py
heitorchang/polylexis
22589560fb015cffb6419308349c5518a5c38551
[ "MIT" ]
null
null
null
polylexis/wsgi.py
heitorchang/polylexis
22589560fb015cffb6419308349c5518a5c38551
[ "MIT" ]
null
null
null
""" WSGI config for polylexis 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.setdefaul...
24.176471
79
0.756691
4a103b325b9af15f0acd6a82f419f608c8be3f48
3,322
py
Python
product_analysis/ebike_analysis/ebike_specs.py
STNichols/product_analysis
cba20f17d7f30da534ccd2c3fc14bdeb9564d25b
[ "BSD-2-Clause" ]
null
null
null
product_analysis/ebike_analysis/ebike_specs.py
STNichols/product_analysis
cba20f17d7f30da534ccd2c3fc14bdeb9564d25b
[ "BSD-2-Clause" ]
1
2020-06-13T23:39:27.000Z
2020-06-13T23:39:27.000Z
product_analysis/ebike_analysis/ebike_specs.py
STNichols/product_analysis
cba20f17d7f30da534ccd2c3fc14bdeb9564d25b
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Tue May 12 13:11:23 2020 @author: Sean """ import re import numpy as np import pandas as pd from ..utilities.web_browsing import make_soup base_url = "https://electricbikereview.com/category/bikes/" all_specs = { "make":{ "num":False }, "mod...
25.751938
77
0.484648
4a103b51d00b6618eb6cf61270c1608a750915ec
967
py
Python
treasurySS/migrations/0003_data.py
uktrade/fadmin2
0f774400fb816c9ca30e30b25ae542135966e185
[ "MIT" ]
3
2020-01-05T16:46:42.000Z
2021-08-02T08:08:39.000Z
treasurySS/migrations/0003_data.py
uktrade/fadmin2
0f774400fb816c9ca30e30b25ae542135966e185
[ "MIT" ]
30
2019-11-28T15:16:35.000Z
2021-08-16T14:49:58.000Z
treasurySS/migrations/0003_data.py
uktrade/fadmin2
0f774400fb816c9ca30e30b25ae542135966e185
[ "MIT" ]
null
null
null
# Generated by Django 3.2.4 on 2021-07-29 08:49 from django.db import migrations def create_organizations(apps, schema_editor): OrganizationCode = apps.get_model("treasurySS", "OrganizationCode") Segment = apps.get_model("treasurySS", "Segment") organization_obj = OrganizationCode.objects.create( ...
31.193548
89
0.703206
4a103d11a39917fbbc4402c9e4a2d20c31a0b897
97
py
Python
Chapter_1/misc/new_test.py
aquib-sh/C_Programming_Exercises
6753164dd8e4f090751db5f988eb27f1bc7363f8
[ "CC0-1.0" ]
null
null
null
Chapter_1/misc/new_test.py
aquib-sh/C_Programming_Exercises
6753164dd8e4f090751db5f988eb27f1bc7363f8
[ "CC0-1.0" ]
null
null
null
Chapter_1/misc/new_test.py
aquib-sh/C_Programming_Exercises
6753164dd8e4f090751db5f988eb27f1bc7363f8
[ "CC0-1.0" ]
null
null
null
while True: try: got = input() print(got) except EOFError: break
13.857143
21
0.484536
4a103dc50cc62cf19625f100631d54e2b40ae601
518
py
Python
array/1701_average_waiting_time/1701_average_waiting_time.py
zdyxry/LeetCode
33371285d0f3302158230f46e8b1b63b9f4639c4
[ "Xnet", "X11" ]
6
2019-09-16T01:50:44.000Z
2020-09-17T08:52:25.000Z
array/1701_average_waiting_time/1701_average_waiting_time.py
zdyxry/LeetCode
33371285d0f3302158230f46e8b1b63b9f4639c4
[ "Xnet", "X11" ]
null
null
null
array/1701_average_waiting_time/1701_average_waiting_time.py
zdyxry/LeetCode
33371285d0f3302158230f46e8b1b63b9f4639c4
[ "Xnet", "X11" ]
4
2020-02-07T12:43:16.000Z
2021-04-11T06:38:55.000Z
from typing import List class Solution: def averageWaitingTime(self, customers: List[List[int]]) -> float: cur = customers[0][0] total = 0 for c in customers: if cur >= c[0]: cur = cur + c[1] total += cur - c[0] else: ...
24.666667
70
0.482625
4a103e8e4b061031a7b0e38b7a21f41596712267
4,204
py
Python
tests/clvm/coin_store.py
Storch-Network/chialite
587fc53e8ef452e07c6f3f266f58962d065feb5c
[ "Apache-2.0" ]
2
2021-06-29T14:05:41.000Z
2021-07-15T19:28:26.000Z
tests/clvm/coin_store.py
Storch-Network/chialite
587fc53e8ef452e07c6f3f266f58962d065feb5c
[ "Apache-2.0" ]
31
2021-06-26T23:11:46.000Z
2022-03-29T00:12:30.000Z
tests/clvm/coin_store.py
Storch-Network/chialite
587fc53e8ef452e07c6f3f266f58962d065feb5c
[ "Apache-2.0" ]
null
null
null
from collections import defaultdict from dataclasses import dataclass, replace from typing import Dict, Iterator, Set from chialite.full_node.mempool_check_conditions import mempool_check_conditions_dict from chialite.types.blockchain_format.coin import Coin from chialite.types.blockchain_format.sized_bytes import byt...
38.925926
117
0.682207
4a1041663ade8650287aee98ca4620160a1e51a5
1,517
py
Python
utils.py
jeccec51/WordPrediction
53607414bd8f44a3fd0d2c2ec6f0d3f0fc7bbba3
[ "BSD-2-Clause" ]
1
2020-11-21T07:12:55.000Z
2020-11-21T07:12:55.000Z
utils.py
jeccec51/WordPrediction
53607414bd8f44a3fd0d2c2ec6f0d3f0fc7bbba3
[ "BSD-2-Clause" ]
null
null
null
utils.py
jeccec51/WordPrediction
53607414bd8f44a3fd0d2c2ec6f0d3f0fc7bbba3
[ "BSD-2-Clause" ]
null
null
null
import re from collections import Counter def preprocess(text): # Replace punctuation with tokens so we can use them in our model text = text.lower() text = text.replace('.', ' <PERIOD> ') text = text.replace(',', ' <COMMA> ') text = text.replace('"', ' <QUOTATION_MARK> ') text = text.replace...
33.711111
73
0.644034
4a1041b3af332d5688b2676e560580c5c3893d8b
292
py
Python
tests/__main__.py
CaioRuizz/DevOps_Curso_Ftt
ca71114b003eed9dc2551d4c7ce5b1d3af56c5dd
[ "MIT" ]
null
null
null
tests/__main__.py
CaioRuizz/DevOps_Curso_Ftt
ca71114b003eed9dc2551d4c7ce5b1d3af56c5dd
[ "MIT" ]
null
null
null
tests/__main__.py
CaioRuizz/DevOps_Curso_Ftt
ca71114b003eed9dc2551d4c7ce5b1d3af56c5dd
[ "MIT" ]
null
null
null
import unittest import sys if __name__ == "__main__": test_suite = unittest.defaultTestLoader.discover('./tests', '*_test.py') test_runner = unittest.TextTestRunner(resultclass=unittest.TextTestResult) result = test_runner.run(test_suite) sys.exit(not result.wasSuccessful())
36.5
78
0.756849
4a1042cc3e50c8920ec2fdee597e68c3aa8e8d12
20,318
py
Python
mapclientplugins/cimconverterstep/SurfaceExtractor.py
HiiKevin/mapclientplugins.cimconverterstep
66a2ebc5482b9eb3f3c58ab6fb7cec9531ef6140
[ "Apache-2.0" ]
null
null
null
mapclientplugins/cimconverterstep/SurfaceExtractor.py
HiiKevin/mapclientplugins.cimconverterstep
66a2ebc5482b9eb3f3c58ab6fb7cec9531ef6140
[ "Apache-2.0" ]
null
null
null
mapclientplugins/cimconverterstep/SurfaceExtractor.py
HiiKevin/mapclientplugins.cimconverterstep
66a2ebc5482b9eb3f3c58ab6fb7cec9531ef6140
[ "Apache-2.0" ]
1
2022-01-17T04:05:45.000Z
2022-01-17T04:05:45.000Z
from datetime import time import numpy as np import csv import os import glob import natsort import pandas as pd import re import warnings import matplotlib.pyplot as plt from mpl_toolkits.mplot3d import Axes3D, art3d class Subdivision_Surface(): ''' This class create a surface from the control mesh, based on...
50.542289
164
0.538783
4a1044acbfe38f26f5164aeaffff4e3a888ea775
953
py
Python
tweet_builder.py
hundvalp/puppy-pills
50e691c6a6882ff1d1d7c9fd13cbd663862c7e9c
[ "MIT" ]
null
null
null
tweet_builder.py
hundvalp/puppy-pills
50e691c6a6882ff1d1d7c9fd13cbd663862c7e9c
[ "MIT" ]
null
null
null
tweet_builder.py
hundvalp/puppy-pills
50e691c6a6882ff1d1d7c9fd13cbd663862c7e9c
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- class TweetBuilder(object): """Constructs tweets to specific users""" def __init__(self, mention_users): """Create a new tweet builder which will mention the given users""" super(TweetBuilder, self).__init__() # Convert lists to a space separated string ...
39.708333
95
0.654774
4a1044ed5e788d2e53d28a30dbe18165a2afbd9a
21,410
py
Python
solartf/core/block.py
solarfresh/solartf
69a5f2ed9990f71e7e19054c4e6e1206396f24e3
[ "Apache-2.0" ]
null
null
null
solartf/core/block.py
solarfresh/solartf
69a5f2ed9990f71e7e19054c4e6e1206396f24e3
[ "Apache-2.0" ]
null
null
null
solartf/core/block.py
solarfresh/solartf
69a5f2ed9990f71e7e19054c4e6e1206396f24e3
[ "Apache-2.0" ]
null
null
null
from tensorflow.keras import backend as K from tensorflow.keras.initializers import RandomNormal from tensorflow.keras import layers from tensorflow.keras.regularizers import l2 from . import activation as solar_activation from . import layer as solartf_layers from .util import (get_filter_nb_by_depth,) class Conv2DB...
34.98366
103
0.572303
4a104512a0315071dc7d0af7d39bb216d720ad4a
8,416
py
Python
sdk/python/pulumi_gcp/logging/folder_sink.py
23doors/pulumi-gcp
ded01b199f95b164884266ea3e6f8206c8231270
[ "ECL-2.0", "Apache-2.0" ]
1
2019-12-20T22:08:20.000Z
2019-12-20T22:08:20.000Z
sdk/python/pulumi_gcp/logging/folder_sink.py
pellizzetti/pulumi-gcp
fad74dd55a0cf7723f73046bb0e6fcbfd948ba84
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
sdk/python/pulumi_gcp/logging/folder_sink.py
pellizzetti/pulumi-gcp
fad74dd55a0cf7723f73046bb0e6fcbfd948ba84
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import json import warnings import pulumi import pulumi.runtime from typing import Union from .. import utilities, tables class Folder...
53.948718
200
0.683341
4a1045bf2cfebffff6d30bc1fdbbacdfa74f3d17
5,493
py
Python
offb_posctl/scripts/GPM_test.py
SensenLiu/aggrecup
0c381ee259b388684205c1fa5fc41265a7e849b3
[ "MIT" ]
null
null
null
offb_posctl/scripts/GPM_test.py
SensenLiu/aggrecup
0c381ee259b388684205c1fa5fc41265a7e849b3
[ "MIT" ]
null
null
null
offb_posctl/scripts/GPM_test.py
SensenLiu/aggrecup
0c381ee259b388684205c1fa5fc41265a7e849b3
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # coding=utf-8 import socket from scipy.optimize import minimize import numpy as np import time from numba import jit, float64 import matplotlib matplotlib.use('TkAgg') import matplotlib.pyplot as plt import datetime # global variable start >>> n = 7 t0 = 0 tf = 2 discret...
30.687151
121
0.532132
4a1045ec4252fa814150d3bae82056091352db45
3,773
py
Python
parser.py
misaelnieto/tracey
bb6c1cd88130fc903561b5122ee2320deb8d9f6c
[ "Apache-2.0" ]
null
null
null
parser.py
misaelnieto/tracey
bb6c1cd88130fc903561b5122ee2320deb8d9f6c
[ "Apache-2.0" ]
null
null
null
parser.py
misaelnieto/tracey
bb6c1cd88130fc903561b5122ee2320deb8d9f6c
[ "Apache-2.0" ]
null
null
null
#!/bin/env python3 class DevsimData(object): """ Simple object contains the coordinates Should probably be replace with numpy's dtype and loadtxt """ def __init__(self, filename): self.filename = filename self.regions = {} self.name = None self.coordinates = None ...
49.644737
108
0.401802
4a10466ead3a43189a6138b2fde341af0e5edce2
3,053
py
Python
src/oci/identity_data_plane/models/authenticate_user_result.py
LaudateCorpus1/oci-python-sdk
b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015
[ "Apache-2.0", "BSD-3-Clause" ]
null
null
null
src/oci/identity_data_plane/models/authenticate_user_result.py
LaudateCorpus1/oci-python-sdk
b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015
[ "Apache-2.0", "BSD-3-Clause" ]
null
null
null
src/oci/identity_data_plane/models/authenticate_user_result.py
LaudateCorpus1/oci-python-sdk
b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015
[ "Apache-2.0", "BSD-3-Clause" ]
null
null
null
# coding: utf-8 # Copyright (c) 2016, 2022, Oracle and/or its affiliates. All rights reserved. # This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may c...
29.931373
245
0.657714
4a10470e1f69e3ab4601f894a6ac2b68f0561075
4,776
py
Python
homework2/replay_buffer.py
IrohXu/NYU_Deep_Reinforcement_Learning
bb8025464b430687c7604e627eefb2908317cfa7
[ "MIT" ]
null
null
null
homework2/replay_buffer.py
IrohXu/NYU_Deep_Reinforcement_Learning
bb8025464b430687c7604e627eefb2908317cfa7
[ "MIT" ]
null
null
null
homework2/replay_buffer.py
IrohXu/NYU_Deep_Reinforcement_Learning
bb8025464b430687c7604e627eefb2908317cfa7
[ "MIT" ]
null
null
null
import numpy as np import torch import torch.nn as nn import torch.nn.functional as F import utils from segment_tree import SumSegmentTree, MinSegmentTree class ReplayBuffer(object): def __init__(self, obs_shape, capacity, device): self.capacity = capacity self.device = device self.obse...
34.608696
79
0.609925
4a1047d99fe50e2345f1feba1295e7cb2f2f7814
10,363
py
Python
misc/train.py
RyanC1681/RCAI1122
c9683110b58c255a7a78d880ff73df7ff2329405
[ "Apache-2.0" ]
18
2020-10-16T00:38:55.000Z
2022-03-03T06:01:49.000Z
misc/train.py
RyanC1681/RCAI1122
c9683110b58c255a7a78d880ff73df7ff2329405
[ "Apache-2.0" ]
20
2020-07-23T03:50:50.000Z
2021-11-09T04:00:26.000Z
misc/train.py
RyanC1681/RCAI1122
c9683110b58c255a7a78d880ff73df7ff2329405
[ "Apache-2.0" ]
140
2019-11-20T22:46:02.000Z
2022-03-29T13:26:17.000Z
from keras.models import load_model import numpy as np import cv2 from pathlib import Path import os import glob import h5py from keras import __version__ as keras_version from typing import List import tensorflow as tf try: from model import nvidia_model, simple_model except: from .model import nvidia_model, ...
32.794304
116
0.655505
4a10485a1e7ad7385a598dcbd4b4ed63c75940c7
2,042
py
Python
main.py
RhnSaxena/KonfHub
09efc83556880469710f05209c6190b8c99e3d97
[ "MIT" ]
null
null
null
main.py
RhnSaxena/KonfHub
09efc83556880469710f05209c6190b8c99e3d97
[ "MIT" ]
null
null
null
main.py
RhnSaxena/KonfHub
09efc83556880469710f05209c6190b8c99e3d97
[ "MIT" ]
null
null
null
import json import config from source.requestUtil import requestGet from source.readable import createReadableDict from source.replicas import createDict, findExactReplicas, findSimilar from source.fileWriter import writeToJSONFile, writeToTXT def driver(): # Perform the GET operation on the link # and recei...
30.029412
87
0.660627
4a1048a0aaf7dc7e8e4422085370e34328979564
2,506
py
Python
neuroConstruct/pythonScripts/RunTestsLEMS.py
OpenSourceBrain/L5bPyrCellHayEtAl2011
23d938d8c4ba1fb83cdd99810ac324ae4f58bd7c
[ "MIT" ]
4
2020-06-15T13:10:23.000Z
2022-02-17T18:20:05.000Z
neuroConstruct/pythonScripts/RunTestsLEMS.py
OpenSourceBrain/L5bPyrCellHayEtAl2011
23d938d8c4ba1fb83cdd99810ac324ae4f58bd7c
[ "MIT" ]
null
null
null
neuroConstruct/pythonScripts/RunTestsLEMS.py
OpenSourceBrain/L5bPyrCellHayEtAl2011
23d938d8c4ba1fb83cdd99810ac324ae4f58bd7c
[ "MIT" ]
1
2022-02-17T11:23:37.000Z
2022-02-17T11:23:37.000Z
# # # File to test current configuration of project # # Author: Padraig Gleeson # # This file has been developed as part of the neuroConstruct project # This work has been funded by the Wellcome Trust # # import sys import os try: from java.io import File except ImportError: print "No...
27.538462
97
0.557861
4a1048d610ce8c0fec2c04e456a510c421edb520
860
py
Python
tests/test_basic.py
saksham219/scvelo
41fb2a90ae6a71577cf2c55b80e1ade4407891b7
[ "BSD-3-Clause" ]
null
null
null
tests/test_basic.py
saksham219/scvelo
41fb2a90ae6a71577cf2c55b80e1ade4407891b7
[ "BSD-3-Clause" ]
null
null
null
tests/test_basic.py
saksham219/scvelo
41fb2a90ae6a71577cf2c55b80e1ade4407891b7
[ "BSD-3-Clause" ]
null
null
null
import scvelo as scv import numpy as np def test_einsum(): from scvelo.tools.utils import prod_sum_obs, prod_sum_var, norm Ms, Mu = np.random.rand(5, 4), np.random.rand(5, 4) assert np.allclose(prod_sum_obs(Ms, Mu), np.sum(Ms * Mu, 0)) assert np.allclose(prod_sum_var(Ms, Mu), np.sum(Ms * Mu, 1)) a...
30.714286
75
0.661628
4a1048e5c89539832b9a87bd683699939a79ba5d
1,733
py
Python
bureau/assignments/views.py
clairempr/bureau
c9fd114e637829b4e9ff643459d15602cc2efc2f
[ "Apache-2.0" ]
1
2019-02-15T09:05:35.000Z
2019-02-15T09:05:35.000Z
bureau/assignments/views.py
clairempr/bureau
c9fd114e637829b4e9ff643459d15602cc2efc2f
[ "Apache-2.0" ]
null
null
null
bureau/assignments/views.py
clairempr/bureau
c9fd114e637829b4e9ff643459d15602cc2efc2f
[ "Apache-2.0" ]
null
null
null
from django.views.generic import ListView from assignments.models import Assignment from places.models import Place class AssignmentListView(ListView): model = Assignment queryset = Assignment.objects.all() ordering = ['start_date', 'positions__title', 'employee__last_name', 'employee__first_name'] t...
32.698113
104
0.691864
4a104972b02fe1199013f78dd4348a37afde5a22
16,120
py
Python
homeassistant/components/homekit/type_media_players.py
twrecked/core
d3ae8a938cdea9b6e0d443c91c37ac3dbbd459ab
[ "Apache-2.0" ]
2
2021-09-13T21:44:02.000Z
2021-12-17T21:20:51.000Z
homeassistant/components/homekit/type_media_players.py
twrecked/core
d3ae8a938cdea9b6e0d443c91c37ac3dbbd459ab
[ "Apache-2.0" ]
5
2021-02-08T20:55:25.000Z
2022-03-12T00:51:18.000Z
homeassistant/components/homekit/type_media_players.py
twrecked/core
d3ae8a938cdea9b6e0d443c91c37ac3dbbd459ab
[ "Apache-2.0" ]
2
2020-11-04T07:40:01.000Z
2021-09-13T21:44:03.000Z
"""Class to hold all media player accessories.""" import logging from pyhap.const import CATEGORY_SWITCH, CATEGORY_TELEVISION from homeassistant.components.media_player import ( ATTR_INPUT_SOURCE, ATTR_INPUT_SOURCE_LIST, ATTR_MEDIA_VOLUME_LEVEL, ATTR_MEDIA_VOLUME_MUTED, DOMAIN, SERVICE_SELECT_...
38.75
88
0.649132
4a104a1e2413b328cbeb4d1ad5165b75f352a2f4
1,780
py
Python
Dynamic Programming/Candies.py
adgarciaar/HackerRankExercises
0d71dafcc437bac200034faf8be1c2794775b05d
[ "MIT" ]
null
null
null
Dynamic Programming/Candies.py
adgarciaar/HackerRankExercises
0d71dafcc437bac200034faf8be1c2794775b05d
[ "MIT" ]
null
null
null
Dynamic Programming/Candies.py
adgarciaar/HackerRankExercises
0d71dafcc437bac200034faf8be1c2794775b05d
[ "MIT" ]
null
null
null
#!/bin/python3 import math import os import random import re import sys def candiesAux(n, arr, i, direction, previousInAuxArray): numberCandies = None if(direction == 0): # left to right if( arr[i-1] < arr[i] ): numberCandies = previousInAuxArray + 1 else: if( i+1 < n )...
23.421053
65
0.493258
4a104add6b9d0f7fa1a86d845f64e6e6ffdd5295
18,085
py
Python
src/poke_env/environment/pokemon.py
BrunoMNDantas/poke-env
1e7ac23619ebd869d47862a1b9edd12525eabdac
[ "MIT" ]
null
null
null
src/poke_env/environment/pokemon.py
BrunoMNDantas/poke-env
1e7ac23619ebd869d47862a1b9edd12525eabdac
[ "MIT" ]
3
2022-03-05T14:22:08.000Z
2022-03-29T10:36:47.000Z
src/poke_env/environment/pokemon.py
darrenswhite/poke-env
1116d7ef765fdf1048083801adfa528df3f7215e
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from typing import Any from typing import Dict from typing import List from typing import Optional from typing import Set from typing import Tuple from typing import Union from poke_env.data import POKEDEX from poke_env.environment.effect import Effect from poke_env.environment.pokemon_gender i...
28.302034
88
0.572795
4a104b81000c52b9ed674f2eccfc682d72b81fd4
1,078
py
Python
Desafio 59.py
MoomenEltelbany/PythonDesafios
aa2f44d3104cf3607f58dc42c2f8fc8023f128de
[ "MIT" ]
null
null
null
Desafio 59.py
MoomenEltelbany/PythonDesafios
aa2f44d3104cf3607f58dc42c2f8fc8023f128de
[ "MIT" ]
null
null
null
Desafio 59.py
MoomenEltelbany/PythonDesafios
aa2f44d3104cf3607f58dc42c2f8fc8023f128de
[ "MIT" ]
null
null
null
num1 = int(input('Digite o primeiro número: ')) num2 = int(input('Digite o segundo número: ')) opcao = 0 while opcao != 5: opcao = int(input('''Solicite a sua escolha: [ 1 ] Somar [ 2 ] Multiplicar [ 3 ] Maior [ 4 ] Novo números [ 5 ] Sair do Programa ''')) if opcao == 1: s...
30.8
65
0.499072
4a104b93cd86febbcb517e5d4db7fc9200a24e0e
487
py
Python
functions/decorators/failsafe.py
kashifali-m398/advanced_python
988f407e986403b3238c9d1ea30b7d6fddf88c84
[ "MIT" ]
1
2021-01-04T18:33:08.000Z
2021-01-04T18:33:08.000Z
functions/decorators/failsafe.py
kashifali-m398/advanced_python
988f407e986403b3238c9d1ea30b7d6fddf88c84
[ "MIT" ]
null
null
null
functions/decorators/failsafe.py
kashifali-m398/advanced_python
988f407e986403b3238c9d1ea30b7d6fddf88c84
[ "MIT" ]
null
null
null
class Failsafe: ''' Catches I/O errors. ''' def __init__(self, func): self.function = func def __call__(self, *args): try: self.function(*args) except IOError: print('An I/O error was caught when opening file "{}"'.format(args[0])) ...
18.037037
84
0.570842
4a104b96b91a47c07a2242d935e7222e65b9efb1
352
py
Python
aliyun/api/rest/Ram20140214ListUserPoliciesRequest.py
francisar/rds_manager
458298669bf7d1990a85648b466b88f905256690
[ "MIT" ]
14
2015-11-30T02:35:18.000Z
2019-05-14T11:49:24.000Z
aliyun/api/rest/Ram20140214ListUserPoliciesRequest.py
francisar/rds_manager
458298669bf7d1990a85648b466b88f905256690
[ "MIT" ]
2
2015-11-30T02:51:40.000Z
2017-03-16T01:51:45.000Z
aliyun/api/rest/Ram20140214ListUserPoliciesRequest.py
francisar/rds_manager
458298669bf7d1990a85648b466b88f905256690
[ "MIT" ]
12
2016-01-04T06:48:17.000Z
2020-11-07T14:08:25.000Z
''' Created by auto_sdk on 2015.06.23 ''' from aliyun.api.base import RestApi class Ram20140214ListUserPoliciesRequest(RestApi): def __init__(self,domain='ram.aliyuncs.com',port=80): RestApi.__init__(self,domain, port) self.AccountSpace = None self.UserName = None def getapiname(self): return 'ram.aliyuncs.c...
27.076923
55
0.767045
4a104bfa1b905dbec9f041916018d49157800e15
327
py
Python
tql/ml/optimizer/__init__.py
Jie-Yuan/1_DataMining
f5338388b4f883233f350d4fb9c5903180883430
[ "Apache-2.0" ]
14
2019-06-25T13:46:32.000Z
2020-10-27T02:04:59.000Z
tql/ml/optimizer/__init__.py
Jie-Yuan/2_DataMining
f5338388b4f883233f350d4fb9c5903180883430
[ "Apache-2.0" ]
null
null
null
tql/ml/optimizer/__init__.py
Jie-Yuan/2_DataMining
f5338388b4f883233f350d4fb9c5903180883430
[ "Apache-2.0" ]
7
2019-06-25T13:26:16.000Z
2020-10-27T02:05:03.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Project : tql-Python. # @File : __init__.py # @Time : 2020/9/8 2:55 下午 # @Author : yuanjie # @Email : yuanjie@xiaomi.com # @Software : PyCharm # @Description : from .F1Optimizer import F1Optimizer from .BaseOptimizer import BaseOpt...
25.153846
40
0.605505
4a104d0a8bcaea1ca12561a24cde974d81f59308
43,065
py
Python
salt/utils/vmware.py
cournape/salt
39bcb8671a9dd04409923c0d34d15652b9fc3c06
[ "Apache-2.0" ]
null
null
null
salt/utils/vmware.py
cournape/salt
39bcb8671a9dd04409923c0d34d15652b9fc3c06
[ "Apache-2.0" ]
null
null
null
salt/utils/vmware.py
cournape/salt
39bcb8671a9dd04409923c0d34d15652b9fc3c06
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- ''' Connection library for VMware .. versionadded:: 2015.8.2 This is a base library used by a number of VMware services such as VMware ESX, ESXi, and vCenter servers. :codeauthor: Nitin Madhok <nmadhok@clemson.edu> :codeauthor: Alexandru Bleotu <alexandru.bleotu@morganstaley.com> Dependencie...
36.007525
133
0.630698
4a104d2d8718e90031699e6e582547c7755b70ce
2,737
py
Python
tests/test_autobib.py
HDembinski/autobib
f4fa004a4496f912acbf251d3092271c45b2fcb3
[ "MIT" ]
5
2021-05-09T12:39:04.000Z
2021-08-25T11:35:39.000Z
tests/test_autobib.py
HDembinski/autobib
f4fa004a4496f912acbf251d3092271c45b2fcb3
[ "MIT" ]
2
2021-05-13T11:34:25.000Z
2021-05-13T11:35:45.000Z
tests/test_autobib.py
HDembinski/autobib
f4fa004a4496f912acbf251d3092271c45b2fcb3
[ "MIT" ]
null
null
null
import subprocess as subp import shutil from pathlib import Path from autobib.util import find_in_path, get_bib_keys import pytest cwd = Path(__file__).parent test_document_path = cwd / "data" @pytest.mark.skipif(not find_in_path("latex"), reason="requires latex") def test_autobib(tmpdir): for fn in ("main.tex",...
28.510417
74
0.618926
4a104dca866ad6fc4108087b2047f2320270a293
1,128
py
Python
app.py
DheerajKumar97/Drug-Review-Sentiment-Analysis-RNN-Bidirectional-lstm--Flask-Deployment
6eff5dd7ab7ff833f9bfad04a65af6c79b19a1f6
[ "MIT" ]
5
2020-10-27T07:25:16.000Z
2021-09-09T09:56:01.000Z
app.py
DheerajKumar97/Drug-Review-Sentiment-Analysis-RNN-Bidirectional-lstm--Flask-Deployment
6eff5dd7ab7ff833f9bfad04a65af6c79b19a1f6
[ "MIT" ]
null
null
null
app.py
DheerajKumar97/Drug-Review-Sentiment-Analysis-RNN-Bidirectional-lstm--Flask-Deployment
6eff5dd7ab7ff833f9bfad04a65af6c79b19a1f6
[ "MIT" ]
null
null
null
from flask import Flask,render_template,url_for,request import numpy as np import pickle import pandas as pd from keras.models import load_model from tensorflow.keras.preprocessing.text import Tokenizer from tensorflow.keras.preprocessing.sequence import pad_sequences from keras.models import model_from_json from numpy...
26.232558
65
0.702128
4a104e6460757188d16c755155c80f0400838954
2,389
py
Python
envs/d4rl/d4rl_content/gym_minigrid/fourroom_controller.py
AliengirlLiv/babyai
51421ee11538bf110c5b2d0c84a15f783d854e7d
[ "MIT" ]
2
2022-02-24T08:47:48.000Z
2022-03-23T09:44:22.000Z
envs/d4rl/d4rl_content/gym_minigrid/fourroom_controller.py
AliengirlLiv/babyai
51421ee11538bf110c5b2d0c84a15f783d854e7d
[ "MIT" ]
null
null
null
envs/d4rl/d4rl_content/gym_minigrid/fourroom_controller.py
AliengirlLiv/babyai
51421ee11538bf110c5b2d0c84a15f783d854e7d
[ "MIT" ]
1
2021-12-27T19:03:38.000Z
2021-12-27T19:03:38.000Z
import numpy as np import random from envs.d4rl.d4rl_content.pointmaze import q_iteration from envs.d4rl.d4rl_content.pointmaze.gridcraft import grid_env from envs.d4rl.d4rl_content.pointmaze.gridcraft import grid_spec MAZE = \ "###################\\"+\ "#OOOOOOOO#OOOOOOOO#\\"+\ "#OOOOOOOO#OOOOOOOO#\\"+\ "#OOOOOOOOOO...
28.105882
89
0.614483
4a10503783da86c5b736f1472232b4a05ef7490a
7,753
py
Python
InApp.py
LHoBiz/ols_engine
9bdbd827f7be17aee95d416255a7f483472c4315
[ "MIT" ]
1
2022-01-05T07:38:06.000Z
2022-01-05T07:38:06.000Z
InApp.py
LHoBiz/ols_engine
9bdbd827f7be17aee95d416255a7f483472c4315
[ "MIT" ]
null
null
null
InApp.py
LHoBiz/ols_engine
9bdbd827f7be17aee95d416255a7f483472c4315
[ "MIT" ]
null
null
null
# -*- coding: cp1252 -*- import sys import os import math import OLSDims import EnvSettings from osgeo import osr import mdl ip = mdl.Data() f=ip.f AppOLS = OLSDims.AppDim.AppOLS AppOLSNAME=OLSDims.AppDim.AppOLSNAME AppOLSDIMS=OLSDims.AppDim.AppOLSDIMS NRunwayInfo=ip.NRunwayInfo SRunwayInfo=ip.SRunwayInfo NIns = ip.NI...
34.30531
98
0.402554
4a10521b6b4c4eb6dfff3e7e4d661dc62a5ce115
7,835
py
Python
bot.py
ARBNonay32/DnD_CascenE
b09d4633aa1401d722517fc94dc1ed40560908eb
[ "MIT" ]
null
null
null
bot.py
ARBNonay32/DnD_CascenE
b09d4633aa1401d722517fc94dc1ed40560908eb
[ "MIT" ]
null
null
null
bot.py
ARBNonay32/DnD_CascenE
b09d4633aa1401d722517fc94dc1ed40560908eb
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import nest_asyncio nest_asyncio.apply() import os, ssl if (not os.environ.get('PYTHONHTTPSVERIFY', '') and getattr(ssl, '_create_unverified_context', None)): ssl._create_default_https_context = ssl._create_unverified_context #import discord from discord.ext import commands import cv2 fr...
24.561129
119
0.555329
4a1052aac6c7ee3c8b6e37dda72f4cca84cc717a
13,397
py
Python
python/example_code/s3/file_transfer/demo_file_transfer.py
AllanFly120/aws-doc-sdk-examples
380d46c4af7192d8bc73b2ea941f92f60500cf2d
[ "Apache-2.0" ]
1
2020-03-09T17:23:38.000Z
2020-03-09T17:23:38.000Z
python/example_code/s3/file_transfer/demo_file_transfer.py
AllanFly120/aws-doc-sdk-examples
380d46c4af7192d8bc73b2ea941f92f60500cf2d
[ "Apache-2.0" ]
null
null
null
python/example_code/s3/file_transfer/demo_file_transfer.py
AllanFly120/aws-doc-sdk-examples
380d46c4af7192d8bc73b2ea941f92f60500cf2d
[ "Apache-2.0" ]
1
2020-01-27T20:42:30.000Z
2020-01-27T20:42:30.000Z
# # Copyright 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. # # This file is licensed under the Apache License, Version 2.0 (the "License"). # You may not use this file except in compliance with the License. A copy of # the License is located at # # http://aws.amazon.com/apache2.0/ # # This file is dist...
39.058309
81
0.623871
4a1053654f4f34eb5af21add8424debd753f6fcd
3,942
py
Python
oarepo_communities/api.py
oarepo/oarepo-communities
eb05dbdd5caf29e8741df5213456220d8f359cfa
[ "MIT" ]
null
null
null
oarepo_communities/api.py
oarepo/oarepo-communities
eb05dbdd5caf29e8741df5213456220d8f359cfa
[ "MIT" ]
24
2021-02-01T17:30:33.000Z
2022-02-08T09:54:22.000Z
oarepo_communities/api.py
oarepo/oarepo-communities
eb05dbdd5caf29e8741df5213456220d8f359cfa
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (C) 2021 CESNET. # # OARepo-Communities is free software; you can redistribute it and/or modify # it under the terms of the MIT License; see LICENSE file for more details. """OArepo module that adds support for communities""" import sqlalchemy from flask import current_app from in...
36.841121
87
0.660832
4a105453151158fe7f108cff9a1eaa8a0e0fcef0
3,995
py
Python
source/process_global_variables.py
WuphonsReach/BeggarsDiplomacy
e6b7f3790e28f458eca0a42250a6bbf41bef8d30
[ "MIT" ]
14
2018-09-20T23:01:27.000Z
2021-05-25T11:05:09.000Z
source/process_global_variables.py
WuphonsReach/BeggarsDiplomacy
e6b7f3790e28f458eca0a42250a6bbf41bef8d30
[ "MIT" ]
44
2018-09-15T03:05:50.000Z
2022-03-22T02:46:24.000Z
source/process_global_variables.py
WuphonsReach/BeggarsDiplomacy
e6b7f3790e28f458eca0a42250a6bbf41bef8d30
[ "MIT" ]
13
2018-10-02T11:45:24.000Z
2021-08-22T18:41:44.000Z
#import string #import types from module_info import * from module_triggers import * from module_dialogs import * from module_simple_triggers import * from module_presentations import * from module_variables import * from process_common import * from process_operations import * #-----------------------------------...
29.813433
135
0.717647
4a1055e910f2b5dff285720613a9b37ce29fb75e
4,090
py
Python
RsaEncryptionOaepSha256String/RsaEncryptionOaepSha256.py
likloadm/cross_platform_crypto
e828c9c9504c022d3882d174f7a8fd424aa19991
[ "Unlicense" ]
15
2020-11-14T09:50:50.000Z
2022-03-13T16:39:19.000Z
RsaEncryptionOaepSha256String/RsaEncryptionOaepSha256.py
likloadm/cross_platform_crypto
e828c9c9504c022d3882d174f7a8fd424aa19991
[ "Unlicense" ]
1
2021-04-26T07:42:27.000Z
2021-07-06T07:39:17.000Z
RsaEncryptionOaepSha256String/RsaEncryptionOaepSha256.py
likloadm/cross_platform_crypto
e828c9c9504c022d3882d174f7a8fd424aa19991
[ "Unlicense" ]
6
2021-11-03T11:28:36.000Z
2022-03-16T13:03:20.000Z
from Crypto.PublicKey import RSA from Crypto.Cipher import PKCS1_OAEP from Crypto.Hash import SHA256 import base64 def base64Encoding(input): dataBase64 = base64.b64encode(input) dataBase64P = dataBase64.decode("UTF-8") return dataBase64P def base64Decoding(input): return base64.decodebytes(input...
44.456522
94
0.839609
4a10568d86aff60ddd208382f4b54a4e1e0cb9e5
7,853
py
Python
tensorflow_graphics/geometry/deformation_energy/tests/as_conformal_as_possible_test.py
jackd/graphics
736b99a3306e302674a9b7599e3e2857b85fdb74
[ "Apache-2.0" ]
null
null
null
tensorflow_graphics/geometry/deformation_energy/tests/as_conformal_as_possible_test.py
jackd/graphics
736b99a3306e302674a9b7599e3e2857b85fdb74
[ "Apache-2.0" ]
null
null
null
tensorflow_graphics/geometry/deformation_energy/tests/as_conformal_as_possible_test.py
jackd/graphics
736b99a3306e302674a9b7599e3e2857b85fdb74
[ "Apache-2.0" ]
1
2020-04-11T10:37:36.000Z
2020-04-11T10:37:36.000Z
# Copyright 2020 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, s...
42.912568
84
0.663823
4a1056b38fda05e8c12a1c4fca5d13db0a01eca6
3,402
py
Python
main.py
PotatoHD1/KlainMakklasky
898e5dc25d4eb4112a669afdb2456260ee240fb0
[ "MIT" ]
1
2021-04-12T08:15:08.000Z
2021-04-12T08:15:08.000Z
main.py
PotatoHD1/KlainMakklasky
898e5dc25d4eb4112a669afdb2456260ee240fb0
[ "MIT" ]
null
null
null
main.py
PotatoHD1/KlainMakklasky
898e5dc25d4eb4112a669afdb2456260ee240fb0
[ "MIT" ]
null
null
null
import collections import pandas as pd import random def F4(table, inp, res): temp = dict(table) for k in res: table = dict(temp) for i in inp: f = F1(bin(i + 16)[3:]) if i in k[0]: table[f] -= 1 if all([i > 0 for i in table.values()]): ...
24.3
94
0.423868
4a1056c96214cb38d86a8593d5de26ccd86eb2a5
2,390
py
Python
src/python/coref/models/entity/TitleModel.py
nmonath/coref_tools
542659170897ad05f7612639cb918886859ae9d6
[ "Apache-2.0" ]
null
null
null
src/python/coref/models/entity/TitleModel.py
nmonath/coref_tools
542659170897ad05f7612639cb918886859ae9d6
[ "Apache-2.0" ]
null
null
null
src/python/coref/models/entity/TitleModel.py
nmonath/coref_tools
542659170897ad05f7612639cb918886859ae9d6
[ "Apache-2.0" ]
null
null
null
""" Copyright (C) 2018 University of Massachusetts Amherst. This file is part of "coref_tools" http://github.com/nmonath/coref_tools 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....
33.194444
72
0.641423
4a1056e2eeac6344989c69776f621fd3ea9d4699
347
py
Python
cd2vec/python/my_test/func4.py
Kirili4ik/code2vec
4867647eb68ec3708fb77d3500d4f3fc48331374
[ "MIT" ]
2
2020-08-11T13:33:02.000Z
2020-10-27T05:07:05.000Z
cd2vec/python/my_test/func4.py
Kirili4ik/code2vec
4867647eb68ec3708fb77d3500d4f3fc48331374
[ "MIT" ]
2
2020-12-03T13:15:55.000Z
2022-02-10T02:06:22.000Z
cd2vec/python/my_test/func4.py
Kirili4ik/code2vec
4867647eb68ec3708fb77d3500d4f3fc48331374
[ "MIT" ]
2
2021-04-08T14:51:01.000Z
2021-09-22T07:57:37.000Z
def plotting(): ts_fare_diff = log_ts_fare - log_ts_fare.shift() ts_fare_diff.dropna(inplace = True)t1 = plot_line(ts_fare_diff.index,ts_fare_diff['fare_amount'], 'blue','Differenced log series') lay = plot_layout('Differenced log series') fig = go.Figure(data = [t1],layout=lay) py.iplot(fig)stati...
34.7
98
0.723343
4a105713da4ee2e0d6bd9e405ac25d6faa27802e
3,346
py
Python
hw3/china.py
dgketchum/csci547
bbba91c1cd09f672342b11280f79e551968a0037
[ "Apache-2.0" ]
null
null
null
hw3/china.py
dgketchum/csci547
bbba91c1cd09f672342b11280f79e551968a0037
[ "Apache-2.0" ]
null
null
null
hw3/china.py
dgketchum/csci547
bbba91c1cd09f672342b11280f79e551968a0037
[ "Apache-2.0" ]
null
null
null
# ============================================================================================= # Copyright 2018 dgketchum # # 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.apach...
32.173077
96
0.639868
4a1057b6fdeba601577f38260adc6c6bc812b7d6
2,503
py
Python
TrackerDash/templates/logpage.py
wedgieedward/TrackerDash
53c3ecc7b9124740f05847dbd235b068601c621e
[ "Beerware" ]
null
null
null
TrackerDash/templates/logpage.py
wedgieedward/TrackerDash
53c3ecc7b9124740f05847dbd235b068601c621e
[ "Beerware" ]
2
2015-04-08T23:20:35.000Z
2015-04-08T23:21:57.000Z
TrackerDash/templates/logpage.py
wedgieedward/TrackerDash
53c3ecc7b9124740f05847dbd235b068601c621e
[ "Beerware" ]
null
null
null
from twisted.web.template import XMLFile, renderer, XMLString from twisted.python.filepath import FilePath from TrackerDash.templates.basewebpage import BasePage class LogPage(BasePage): """ LogPage """ DEFAULT_TAG = XMLString('<span class="label label-default"> Log </span>') INFO_TAG = XMLString...
31.683544
79
0.609668
4a1057f3f0f57643fd54c4aa7a355978ea31169c
1,490
py
Python
util/syn_gen.py
yangop8/Noah-GED
31c6a737321c227d25c787625b3fe1cc2846f51e
[ "MIT" ]
5
2021-09-01T15:53:30.000Z
2022-03-26T13:37:24.000Z
util/syn_gen.py
yangop8/Noah-GED
31c6a737321c227d25c787625b3fe1cc2846f51e
[ "MIT" ]
1
2021-10-12T13:16:38.000Z
2021-10-12T13:16:38.000Z
util/syn_gen.py
yangop8/Noah-GED
31c6a737321c227d25c787625b3fe1cc2846f51e
[ "MIT" ]
1
2021-12-21T11:53:36.000Z
2021-12-21T11:53:36.000Z
import networkx as nx import random import os data_path = '/home/yanglei/GraphEditDistance/Syn/test/' if not os.path.exists(data_path): os.makedirs(data_path) nodes = 100 for i in range(2000): G = nx.fast_gnp_random_graph(nodes,0.2) nx.write_gexf(G,data_path+str(i)+'_1.gexf') edge_num = nx.number_of_e...
38.205128
95
0.679195
4a105871116583bf46b7c172518ce031100a958e
4,098
py
Python
ARCHIVE/mozlz4a.py
nodiscc/toolbox
84c0a917369fc2d0efd471c8606725ac407c2c9f
[ "Unlicense", "MIT" ]
10
2017-05-27T16:59:00.000Z
2022-03-28T02:30:55.000Z
ARCHIVE/mozlz4a.py
nodiscc/toolbox
84c0a917369fc2d0efd471c8606725ac407c2c9f
[ "Unlicense", "MIT" ]
null
null
null
ARCHIVE/mozlz4a.py
nodiscc/toolbox
84c0a917369fc2d0efd471c8606725ac407c2c9f
[ "Unlicense", "MIT" ]
2
2018-03-03T18:40:25.000Z
2018-03-05T06:09:47.000Z
#!/usr/bin/env python # #Description: Decompressor/compressor for files in Mozilla's "mozLz4" format # Firefox uses this file format to compress e. g. bookmark backups (*.jsonlz4). # # This file format is in fact just plain LZ4 data with a custom header (magic number [8 bytes] and # uncompressed file size [4 bytes, lit...
35.327586
109
0.695705
4a10599c9bd064d5e27114757131f1c9a6619736
543
py
Python
rogal/__main__.py
kosciak/ecs-rogal
d553104e0ea350d11272d274a900419620b9389e
[ "MIT" ]
4
2021-01-23T13:25:46.000Z
2021-03-19T03:08:05.000Z
rogal/__main__.py
kosciak/ecs-rogal
d553104e0ea350d11272d274a900419620b9389e
[ "MIT" ]
null
null
null
rogal/__main__.py
kosciak/ecs-rogal
d553104e0ea350d11272d274a900419620b9389e
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import argparse from . import main if __name__ == "__main__": parser = argparse.ArgumentParser() # parser.add_argument( # 'wrapper', # nargs='?', # choices=sorted(main.WRAPPERS.keys()), # default='tcod', # ) for wrapper in sorted(main.WRAPPERS...
19.392857
80
0.585635
4a1059fdc99a880d7a8f4ba6f1b8e52c4672c814
1,283
py
Python
imlib/image/objects.py
noisysky/imlib
625193be4a586d9040a48df9d51dbdd3a17c7d06
[ "MIT" ]
null
null
null
imlib/image/objects.py
noisysky/imlib
625193be4a586d9040a48df9d51dbdd3a17c7d06
[ "MIT" ]
6
2020-04-17T12:02:56.000Z
2020-05-12T15:20:18.000Z
imlib/image/objects.py
noisysky/imlib
625193be4a586d9040a48df9d51dbdd3a17c7d06
[ "MIT" ]
4
2020-02-05T18:53:30.000Z
2022-02-21T18:50:14.000Z
import numpy as np from skimage.measure import label def get_largest_non_zero_object(label_image): """ In a labelled (each object assigned an int) numpy array. Return the largest object with a value >= 1. :param label_image: Output of skimage.measure.label :return: Boolean numpy array or largest o...
32.075
75
0.696804
4a105a4c4aaa37aee07d4029794be791db13d82a
3,888
py
Python
Tests/uninitialized_local_variable_rule_test.py
colobot/colobot-lint
30921edb55b49dbda27d645357e24d6d22f5c48f
[ "BSD-3-Clause" ]
7
2015-08-28T14:26:51.000Z
2020-05-18T01:37:27.000Z
Tests/uninitialized_local_variable_rule_test.py
piotrdz/colobot-lint
30921edb55b49dbda27d645357e24d6d22f5c48f
[ "BSD-3-Clause" ]
7
2015-07-31T20:54:10.000Z
2015-08-24T22:26:55.000Z
Tests/uninitialized_local_variable_rule_test.py
piotrdz/colobot-lint
30921edb55b49dbda27d645357e24d6d22f5c48f
[ "BSD-3-Clause" ]
2
2015-09-09T15:11:28.000Z
2018-11-14T20:34:35.000Z
import test_support class UnintializedLocalVariableRuleTest(test_support.TestBase): def setUp(self): self.set_default_rules_selection(['UninitializedLocalVariableRule']) self.set_default_error_id('uninitialized local variable') self.set_default_error_severity('error') def test_function...
34.40708
141
0.434928
4a105b96ca8818b95ecb626a22f89bf5982988c4
2,079
py
Python
scripts/eval/evaluate_loss.py
galberding/FleckDetect
787a3306261754a15f32e69ca57599f81cb378fa
[ "Apache-2.0" ]
null
null
null
scripts/eval/evaluate_loss.py
galberding/FleckDetect
787a3306261754a15f32e69ca57599f81cb378fa
[ "Apache-2.0" ]
1
2022-03-12T00:10:08.000Z
2022-03-12T00:10:08.000Z
scripts/eval/evaluate_loss.py
galberding/FleckDetect
787a3306261754a15f32e69ca57599f81cb378fa
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python """ Short script used to extract the minimal loss value and plot values from csv files. """ import argparse import sys import numpy as np import matplotlib.pyplot as plt def parse_loss_csv(filename): iterations = [] losses = [] min_loss = sys.maxsize min_index = -1 index =...
28.479452
139
0.611833
4a105bcaff9650e687a442f45fed5955a561b9e1
5,762
py
Python
xharvest/handlers/main.py
vyscond/py-xharvest
10cb6a78ddd86d2b0cf73f1eaaf47d97e839fbe8
[ "MIT" ]
null
null
null
xharvest/handlers/main.py
vyscond/py-xharvest
10cb6a78ddd86d2b0cf73f1eaaf47d97e839fbe8
[ "MIT" ]
21
2020-04-26T18:22:24.000Z
2020-08-09T23:23:20.000Z
xharvest/handlers/main.py
vyscond/py-xharvest
10cb6a78ddd86d2b0cf73f1eaaf47d97e839fbe8
[ "MIT" ]
null
null
null
from datetime import datetime from gi.repository import Gtk from gi.repository import Gdk from xharvest.data import get_img_path from xharvest.auth import AuthenticationManager from xharvest.threads import GtkThread from xharvest.threads import gtk_thread_cb from xharvest.models import Shortcuts from xharvest.handlers....
38.15894
80
0.634675
4a105c84c5e46f611ef6884abba0e2b90ba66ef1
5,279
py
Python
src/freemoovr/geometry/rectangle.py
loopbio/FreemooVR
5d22951f869621dda27fb10c501253c02374c3a7
[ "Zlib" ]
1
2021-05-20T06:55:09.000Z
2021-05-20T06:55:09.000Z
src/freemoovr/geometry/rectangle.py
loopbio/FreemooVR
5d22951f869621dda27fb10c501253c02374c3a7
[ "Zlib" ]
3
2016-08-05T12:56:12.000Z
2016-08-09T14:20:09.000Z
src/freemoovr/geometry/rectangle.py
loopbio/FreemooVR
5d22951f869621dda27fb10c501253c02374c3a7
[ "Zlib" ]
null
null
null
from freemoovr.geometry.common import ModelBase, point_dict_to_vec import numpy as np class PlanarRectangle(ModelBase): def __init__(self, lowerleft=None, upperleft=None, lowerright=None): self.left_lower_corner = point_dict_to_vec(lowerleft) self.left_upper_corner = point_dict_to_vec(upperleft) ...
36.916084
109
0.562796
4a105c894f01b68f1d2a372c617dc8bd30471954
4,239
py
Python
gcalcli/utils.py
shaicoleman/gcalcli
96f7cf45e4f8180923ec27776e932cba954f08ce
[ "MIT" ]
null
null
null
gcalcli/utils.py
shaicoleman/gcalcli
96f7cf45e4f8180923ec27776e932cba954f08ce
[ "MIT" ]
1
2020-06-18T16:11:47.000Z
2020-06-18T16:11:47.000Z
gcalcli/utils.py
shaicoleman/gcalcli
96f7cf45e4f8180923ec27776e932cba954f08ce
[ "MIT" ]
null
null
null
import calendar import time import locale import re from dateutil.tz import tzlocal from dateutil.parser import parse as dateutil_parse from datetime import datetime, timedelta from parsedatetime.parsedatetime import Calendar locale.setlocale(locale.LC_ALL, '') fuzzy_date_parse = Calendar().parse fuzzy_datetime_parse...
29.034247
77
0.588818
4a105e0ded4ab89c3f6a7f84b1aebaa7b0db390a
2,810
py
Python
docs_src/source/conf.py
seeq12/seeq-udf-ui
96a7151abc46ad18b6faae78be27a420ddbd1a48
[ "Apache-2.0" ]
null
null
null
docs_src/source/conf.py
seeq12/seeq-udf-ui
96a7151abc46ad18b6faae78be27a420ddbd1a48
[ "Apache-2.0" ]
5
2022-03-01T00:32:22.000Z
2022-03-23T21:14:15.000Z
docs_src/source/conf.py
seeq12/seeq-udf-ui
96a7151abc46ad18b6faae78be27a420ddbd1a48
[ "Apache-2.0" ]
null
null
null
# Configuration file for the Sphinx documentation builder. # # This file only contains a selection of the most common options. For a full # list see the documentation: # https://www.sphinx-doc.org/en/master/usage/configuration.html # -- Path setup -------------------------------------------------------------- # If ex...
33.452381
79
0.690747
4a105ea1cb5adf3df6c1cfeb86c3bfdae1d17417
1,645
py
Python
panda/models/user_proxy.py
newsapps/panda
7553fd8cbc9c9c92a1b8be2e073141ec1b2ef903
[ "MIT" ]
4
2015-07-28T19:01:03.000Z
2018-12-21T01:57:03.000Z
panda/models/user_proxy.py
NUKnightLab/panda
c8b81151cad9f23ecd439e4354e86cca1eb49bb1
[ "MIT" ]
null
null
null
panda/models/user_proxy.py
NUKnightLab/panda
c8b81151cad9f23ecd439e4354e86cca1eb49bb1
[ "MIT" ]
null
null
null
#!/usr/bin/env python from django.contrib.auth.models import User from django.conf import settings from panda import solr class UserProxy(User): """ User Django's ProxyModel concept to track changes to the User model without overriding it. This way related datasets can be updated when user details ch...
32.9
106
0.662006
4a105efd8b20263e48319c151d4f0958952d4e34
297
py
Python
accounts/forms.py
arkarhtethan/django-library-management-system
f505b85f9609e62e30d4459f8028a6b5418fbf7d
[ "MIT" ]
1
2022-01-17T06:28:44.000Z
2022-01-17T06:28:44.000Z
accounts/forms.py
arkarhtethan/django-library-management-system
f505b85f9609e62e30d4459f8028a6b5418fbf7d
[ "MIT" ]
10
2020-06-05T22:48:54.000Z
2022-03-11T23:57:22.000Z
accounts/forms.py
arkarhtethan/django-library-management-system
f505b85f9609e62e30d4459f8028a6b5418fbf7d
[ "MIT" ]
1
2020-06-05T11:23:57.000Z
2020-06-05T11:23:57.000Z
from django.contrib.auth.forms import UserCreationForm from django.contrib.auth.models import User from django import forms class SignUpForm(UserCreationForm): email = forms.EmailField() class Meta: model = User fields = ('username', 'email', 'password1', 'password2')
22.846154
64
0.713805
4a105f5a34532cf85e46526dddc4b28f3788c7cd
13,663
py
Python
models/egan_model.py
shiming-chen/CDE-GAN
6d67dfee5087fdd91791a33a7f73bb5914678ff0
[ "MIT" ]
9
2020-09-08T07:53:55.000Z
2022-01-17T12:23:59.000Z
models/egan_model.py
shiming-chen/CDE-GAN
6d67dfee5087fdd91791a33a7f73bb5914678ff0
[ "MIT" ]
2
2020-09-08T07:53:03.000Z
2021-03-23T01:29:21.000Z
models/egan_model.py
shiming-chen/CDE-GAN
6d67dfee5087fdd91791a33a7f73bb5914678ff0
[ "MIT" ]
1
2021-12-21T09:04:38.000Z
2021-12-21T09:04:38.000Z
"""Model class template This module provides a template for users to implement custom models. You can specify '--model template' to use this model. The class name should be consistent with both the filename and its model option. The filename should be <model>_dataset.py The class name should be <Model>Dataset.py It im...
49.147482
170
0.616629
4a105f9a8494e298740f0e1d1c2d8342fb96e1b0
8,647
py
Python
google-cloud-recaptcha_enterprise/synth.py
pradeepbhadani/google-cloud-ruby
765eac0f1a5277cb113293bf2fd271e1495a12f5
[ "Apache-2.0" ]
null
null
null
google-cloud-recaptcha_enterprise/synth.py
pradeepbhadani/google-cloud-ruby
765eac0f1a5277cb113293bf2fd271e1495a12f5
[ "Apache-2.0" ]
null
null
null
google-cloud-recaptcha_enterprise/synth.py
pradeepbhadani/google-cloud-ruby
765eac0f1a5277cb113293bf2fd271e1495a12f5
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, s...
32.753788
130
0.683821
4a105f9f496ffbbc59e57e75c45afe70028d2868
4,238
py
Python
model/resnet.py
venuc13/CIFARConfidenceSet
f9505d753c77465e005db83600ccc00a996e2930
[ "Apache-2.0" ]
null
null
null
model/resnet.py
venuc13/CIFARConfidenceSet
f9505d753c77465e005db83600ccc00a996e2930
[ "Apache-2.0" ]
null
null
null
model/resnet.py
venuc13/CIFARConfidenceSet
f9505d753c77465e005db83600ccc00a996e2930
[ "Apache-2.0" ]
null
null
null
'''ResNet in PyTorch. For Pre-activation ResNet, see 'preact_resnet.py'. Reference: [1] Kaiming He, Xiangyu Zhang, Shaoqing Ren, Jian Sun Deep Residual Learning for Image Recognition. arXiv:1512.03385 ''' import torch import torch.nn as nn import torch.nn.functional as F class BasicBlock(nn.Module): ...
33.904
84
0.577159
4a1060ac497dceea673991e85b49ec33716319d8
1,689
py
Python
packages/tencent-cloud-sdk-core/tencent/cloud/core/__init__.py
nobody-night/tencent-cloud-sdk-python
4b02c49c587da002c96fff6cadbd0cf6dbae40f9
[ "MIT" ]
3
2020-07-31T13:29:20.000Z
2021-04-07T09:06:39.000Z
packages/tencent-cloud-sdk-core/tencent/cloud/core/__init__.py
nobody-night/tencent-cloud-sdk-python
4b02c49c587da002c96fff6cadbd0cf6dbae40f9
[ "MIT" ]
null
null
null
packages/tencent-cloud-sdk-core/tencent/cloud/core/__init__.py
nobody-night/tencent-cloud-sdk-python
4b02c49c587da002c96fff6cadbd0cf6dbae40f9
[ "MIT" ]
1
2020-02-06T16:54:56.000Z
2020-02-06T16:54:56.000Z
# tencent.cloud.core.__init__ is python-3.6 source file # MIT License # # Copyright (c) 2021 Handle. # # 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 withou...
38.386364
80
0.762581
4a10613321f7530b95af7ad4035e7d5677eed42a
61,248
py
Python
srctools/dmx.py
TeamSpen210/srctools
0ccea9bc9e00236dd452518af8a7b4ac31e23150
[ "MIT" ]
29
2016-06-12T17:35:50.000Z
2022-03-25T08:37:56.000Z
srctools/dmx.py
TeamSpen210/srctools
0ccea9bc9e00236dd452518af8a7b4ac31e23150
[ "MIT" ]
8
2020-09-22T00:22:35.000Z
2021-12-04T00:53:07.000Z
srctools/dmx.py
TeamSpen210/srctools
0ccea9bc9e00236dd452518af8a7b4ac31e23150
[ "MIT" ]
12
2018-09-03T10:39:46.000Z
2022-01-18T13:21:22.000Z
"""Handles DataModel eXchange trees, in both binary and text (keyvalues2) format. As an extension, optionally all strings may become full UTF-8, marked by a new set of 'unicode_XXX' encoding formats. """ import struct import sys from enum import Enum from typing import ( Union, NamedTuple, TypeVar, Generic, NewTyp...
37.621622
128
0.556622
4a1063a24b6461ef3609c112f94ed92a4179a45f
865
py
Python
tests/area_attention/test_multi_head_area_attention.py
mikomel/area-attention
06f219e9067b473da33a1c4b087778641012e8c8
[ "MIT" ]
8
2020-11-26T03:02:34.000Z
2022-02-04T08:41:10.000Z
tests/area_attention/test_multi_head_area_attention.py
mikomel/area-attention
06f219e9067b473da33a1c4b087778641012e8c8
[ "MIT" ]
null
null
null
tests/area_attention/test_multi_head_area_attention.py
mikomel/area-attention
06f219e9067b473da33a1c4b087778641012e8c8
[ "MIT" ]
1
2021-12-23T06:18:11.000Z
2021-12-23T06:18:11.000Z
import pytest import torch from area_attention import AreaAttention, MultiHeadAreaAttention area_attention = AreaAttention( key_query_size=32, area_key_mode='max', area_value_mode='mean', max_area_height=2, max_area_width=2, memory_height=4, memory_width=4, dropout_rate=0.2, top_k_...
23.378378
64
0.677457
4a1063e1c85cfa49cd421ea140d4635841c82fd4
18,031
py
Python
rally/common/db/sqlalchemy/api.py
ewhseo/rally
37e5475b7785e987173e118e89dbab357cd64b66
[ "Apache-2.0" ]
null
null
null
rally/common/db/sqlalchemy/api.py
ewhseo/rally
37e5475b7785e987173e118e89dbab357cd64b66
[ "Apache-2.0" ]
null
null
null
rally/common/db/sqlalchemy/api.py
ewhseo/rally
37e5475b7785e987173e118e89dbab357cd64b66
[ "Apache-2.0" ]
null
null
null
# Copyright 2013: Mirantis 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 b...
34.741811
79
0.615828
4a1064744f3c459c03eb09ea55e06674a1a41bf9
430
py
Python
app/tests/utils/utils.py
nubilfi/fastapi-starter-kit
99a326099c3446584dd0ef18b123c42ba360d364
[ "MIT" ]
null
null
null
app/tests/utils/utils.py
nubilfi/fastapi-starter-kit
99a326099c3446584dd0ef18b123c42ba360d364
[ "MIT" ]
1
2021-03-17T08:24:12.000Z
2021-03-17T08:24:12.000Z
app/tests/utils/utils.py
nubilfi/fastapi-starter-kit
99a326099c3446584dd0ef18b123c42ba360d364
[ "MIT" ]
null
null
null
""" Just a utils function """ import random import string def random_lower_string() -> str: """generate random lowercase str""" return "".join(random.choices(string.ascii_lowercase, k=32)) def random_email() -> str: """generate a random email""" return f"{random_lower_string()}@{random_lower_string(...
20.47619
65
0.686047
4a1064b76d1c8c75368d950c82e0ea5412c63761
636
py
Python
move.py
jpgualdarrama/pokescrape
dcfed3fc7b887c2c7c4720ef414247aa79dc749b
[ "MIT" ]
21
2015-03-28T15:30:05.000Z
2020-08-03T12:27:27.000Z
move.py
jpgualdarrama/pokescrape
dcfed3fc7b887c2c7c4720ef414247aa79dc749b
[ "MIT" ]
1
2015-04-28T22:19:51.000Z
2015-04-29T00:37:57.000Z
move.py
jpgualdarrama/pokescrape
dcfed3fc7b887c2c7c4720ef414247aa79dc749b
[ "MIT" ]
3
2016-12-08T18:55:53.000Z
2020-01-30T03:04:49.000Z
from pk import * class Move: def __init__(self): self.name = 'None' self.type = 0 self.pp = 0 self.power = 0 self.accuracy = 0 self.category = 0 self.damage = 0 self.description = 'None' def __str__(self): return ('Name: %s' % self.name + '\nType: %i (%s)' % (self.type, PkIType[self.type]) + ...
24.461538
76
0.59434