blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 4 721 | content_id stringlengths 40 40 | detected_licenses listlengths 0 57 | license_type stringclasses 2
values | repo_name stringlengths 5 91 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 321
values | visit_date timestamp[ns]date 2016-08-12 09:31:09 2023-09-06 10:45:07 | revision_date timestamp[ns]date 2010-09-28 14:01:40 2023-09-06 06:22:19 | committer_date timestamp[ns]date 2010-09-28 14:01:40 2023-09-06 06:22:19 | github_id int64 426 681M | star_events_count int64 101 243k | fork_events_count int64 0 110k | gha_license_id stringclasses 23
values | gha_event_created_at timestamp[ns]date 2012-06-28 18:51:49 2023-09-14 21:59:16 ⌀ | gha_created_at timestamp[ns]date 2008-02-11 22:55:26 2023-08-10 11:14:58 ⌀ | gha_language stringclasses 147
values | src_encoding stringclasses 26
values | language stringclasses 2
values | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 6 10.2M | extension stringclasses 115
values | filename stringlengths 3 113 | content stringlengths 6 10.2M |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
958d387bfdf88a4823aecddff915b3399bd6d534 | 1b94c7cfd66804fe8d40b5def35e4b9b18d69ba2 | /stubs/googleapiclient/channel.pyi | da9374c9c074bf862fa3bd9901d531bc2adf7ce1 | [
"MIT"
] | permissive | the-blue-alliance/the-blue-alliance | 3dc210a9611ce9b240907ffd420f78040318dcdc | 6d42f3cdb2f785d192f2871419e58aaae3445029 | refs/heads/py3 | 2023-08-22T21:02:36.398100 | 2023-08-22T19:14:01 | 2023-08-22T19:14:01 | 888,427 | 344 | 263 | MIT | 2023-09-14T18:35:20 | 2010-09-04T20:34:11 | HTML | UTF-8 | Python | false | false | 1,125 | pyi | channel.pyi | from googleapiclient import errors as errors
from typing import Any, Optional
EPOCH: Any
CHANNEL_PARAMS: Any
X_GOOG_CHANNEL_ID: str
X_GOOG_MESSAGE_NUMBER: str
X_GOOG_RESOURCE_STATE: str
X_GOOG_RESOURCE_URI: str
X_GOOG_RESOURCE_ID: str
class Notification:
message_number: Any = ...
state: Any = ...
resource... |
63a2becf81feda9ad4391c3164e36ebd6f909fb1 | bb33e6be8316f35decbb2b81badf2b6dcf7df515 | /source/res/scripts/client/gui/prb_control/entities/base/pre_queue/ctx.py | d9900e2f814eed7f7392792a9f7e2f5c59a38fcc | [] | no_license | StranikS-Scan/WorldOfTanks-Decompiled | 999c9567de38c32c760ab72c21c00ea7bc20990c | d2fe9c195825ececc728e87a02983908b7ea9199 | refs/heads/1.18 | 2023-08-25T17:39:27.718097 | 2022-09-22T06:49:44 | 2022-09-22T06:49:44 | 148,696,315 | 103 | 39 | null | 2022-09-14T17:50:03 | 2018-09-13T20:49:11 | Python | UTF-8 | Python | false | false | 1,205 | py | ctx.py | # Python bytecode 2.7 (decompiled from Python 2.7)
# Embedded file name: scripts/client/gui/prb_control/entities/base/pre_queue/ctx.py
from gui.prb_control.entities.base.ctx import PrbCtrlRequestCtx
from gui.prb_control.settings import CTRL_ENTITY_TYPE, REQUEST_TYPE
from gui.prb_control.settings import FUNCTIONAL_FLAG
... |
cf9750ed0f1d3c6032f787805685f3aa0c7ca48c | 81285c396e0fa27f242767bdc7b4f230e624b80a | /tests/unit/test_replays.py | e5ce185a762b141a6abef71fe4291c404783dbb3 | [
"Apache-2.0"
] | permissive | betamaxpy/betamax | b1e3c7d3c1fc220e6c672b3c1a40ab0fa9f4c87a | 8aa9f348d55ee0d584859603474efc74a0b76c49 | refs/heads/main | 2023-09-02T03:10:24.155432 | 2022-12-24T14:17:56 | 2022-12-24T14:17:56 | 11,439,734 | 285 | 40 | NOASSERTION | 2023-05-13T15:05:07 | 2013-07-16T03:23:22 | Python | UTF-8 | Python | false | false | 747 | py | test_replays.py | from betamax import Betamax, BetamaxError
from requests import Session
import unittest
class TestReplays(unittest.TestCase):
def setUp(self):
self.session = Session()
def test_replays_response_on_right_order(self):
s = self.session
opts = {'record': 'none'}
with Betamax(s).us... |
97b374ff93e6ac389abe049527be22d0b57ad4cd | 5da5473ff3026165a47f98744bac82903cf008e0 | /packages/google-cloud-recommendations-ai/google/cloud/recommendationengine_v1beta1/types/catalog_service.py | 17d3815796f6bbfa2ae55db89490e0b437232cf0 | [
"Apache-2.0"
] | permissive | googleapis/google-cloud-python | ed61a5f03a476ab6053870f4da7bc5534e25558b | 93c4e63408c65129422f65217325f4e7d41f7edf | refs/heads/main | 2023-09-04T09:09:07.852632 | 2023-08-31T22:49:26 | 2023-08-31T22:49:26 | 16,316,451 | 2,792 | 917 | Apache-2.0 | 2023-09-14T21:45:18 | 2014-01-28T15:51:47 | Python | UTF-8 | Python | false | false | 5,473 | py | catalog_service.py | # -*- coding: utf-8 -*-
# Copyright 2023 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... |
e2d7ad28221d2b1d2f845a859b6ff9d784d258e2 | d46844ac1c4230579d6c87d800e07fb41bc99592 | /pwncat/modules/linux/enumerate/system/selinux.py | 502b24ddf0d51348bd70135dbd9dd0e4f5a0717b | [
"MIT"
] | permissive | calebstewart/pwncat | 14ade3e424fb70ce3e62b8b5c5053959515799e7 | 37f04d4e16ff47c7fd70e95162f9fccd327cca7e | refs/heads/master | 2023-08-14T04:27:04.773361 | 2022-03-21T20:35:00 | 2022-03-21T20:35:00 | 261,925,766 | 2,177 | 267 | MIT | 2023-05-19T04:33:17 | 2020-05-07T02:02:40 | Python | UTF-8 | Python | false | false | 2,161 | py | selinux.py | #!/usr/bin/env python3
from typing import Dict
import rich.markup
from pwncat.db import Fact
from pwncat.platform.linux import Linux
from pwncat.modules.enumerate import Schedule, EnumerateModule
class SELinuxState(Fact):
def __init__(self, source, state, status):
super().__init__(source=source, types=[... |
40c424866b437d8ea7aa8afb2644510f4f9f01b3 | 99b2aff89dcec2f43cee32a6bdd4c0c43d6c51fa | /tests/__init__.py | 763dbf26c3905b0aebe48f83399f6a570d0ea8d2 | [
"MIT"
] | permissive | baking-bad/pytezos | c4248bde49a5b05521b8cc51eeca588b1a721660 | 19747e3acec2141f06e812025673f497fc07e2d4 | refs/heads/master | 2023-07-06T21:57:09.572985 | 2023-07-05T11:45:27 | 2023-07-05T11:45:27 | 169,243,460 | 115 | 43 | MIT | 2023-07-04T16:28:09 | 2019-02-05T13:12:50 | Python | UTF-8 | Python | false | false | 57 | py | __init__.py | import michelson_kernel # pylint: disable=unused-import
|
d4e075b5653955492d2d9f334839f39dec7a96aa | a41e1498e3c080f47abd8e8e57157548df3ebbf1 | /pandas/tests/util/test_assert_produces_warning.py | 5c27a3ee79d4a82bce83eec56ab9d88e10dc06cd | [
"BSD-3-Clause"
] | permissive | pandas-dev/pandas | e7e639454a298bebc272622e66faa9829ea393bb | c7325d7e7e77ecb4a4e57b48bc25265277c75712 | refs/heads/main | 2023-09-01T12:42:07.927176 | 2023-09-01T11:14:10 | 2023-09-01T11:14:10 | 858,127 | 36,166 | 18,728 | BSD-3-Clause | 2023-09-14T21:18:41 | 2010-08-24T01:37:33 | Python | UTF-8 | Python | false | false | 8,412 | py | test_assert_produces_warning.py | """"
Test module for testing ``pandas._testing.assert_produces_warning``.
"""
import warnings
import pytest
from pandas.errors import (
DtypeWarning,
PerformanceWarning,
)
import pandas._testing as tm
@pytest.fixture(
params=[
RuntimeWarning,
ResourceWarning,
UserWarning,
... |
97ecfb2294bd1db9b596c746e2eb11e22c100c6b | d6aae799e18e907fb413b715200c7832252a87e5 | /3d-object-classification/pointnet2/evaluate.py | a9d2b66325044579adb08afd71a2a25ffebcd3b8 | [
"LicenseRef-scancode-unknown-license-reference",
"BSD-3-Clause",
"MIT",
"LicenseRef-scancode-proprietary-license",
"Apache-2.0",
"CC-BY-NC-4.0"
] | permissive | sony/nnabla-examples | 0d0bbd5df3028996e790bcf07248fdb0932697d1 | 41f71faa6efff7774a76bbd5af3198322a90a6ab | refs/heads/master | 2023-09-04T03:45:54.023899 | 2023-08-22T03:31:21 | 2023-08-22T03:31:21 | 109,625,584 | 308 | 108 | Apache-2.0 | 2023-08-22T03:31:23 | 2017-11-05T23:30:40 | Python | UTF-8 | Python | false | false | 4,889 | py | evaluate.py | # Copyright 2022 Sony Group Corporation.
#
# 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 ... |
f5b3795760a87ca73389397ce08583e990a62025 | 01857ef455ea60eccaf03b5a9059ec83e9803c2e | /nicegui/elements/chart.py | c5b9bc3bd29361c16c1c42baf4cfe7d54e694521 | [
"MIT"
] | permissive | zauberzeug/nicegui | f08312cc1f393deca79e0e84a2506d3a35efff16 | c61b1315f29d51e26cc1168207f5616b302f8df0 | refs/heads/main | 2023-08-18T18:09:30.937322 | 2023-08-18T15:04:00 | 2023-08-18T15:04:00 | 365,250,183 | 5,128 | 271 | MIT | 2023-09-14T01:50:56 | 2021-05-07T13:55:05 | Python | UTF-8 | Python | false | false | 4,578 | py | chart.py | from typing import Callable, Dict, List, Optional
from ..element import Element
from ..events import (ChartPointClickEventArguments, ChartPointDragEventArguments, ChartPointDragStartEventArguments,
ChartPointDropEventArguments, GenericEventArguments, handle_event)
class Chart(Element,
... |
160ba664cee103f37f2245b4aa2beb391d2b5437 | 082cb56436631f16585dc6c667a8b384cee3335f | /script/talk/source/t301500.py | b44c91859e8e2e843beca482ccece7ebe5778f05 | [] | no_license | vawser/Cinders-DS3 | abf2c5e1c163f2e556a0d89e437eead3ddd6992c | d086ebce45b27806f757e04778dad1615e405dab | refs/heads/master | 2023-09-01T00:48:00.500866 | 2023-08-07T12:25:24 | 2023-08-07T12:25:24 | 230,333,994 | 192 | 203 | null | 2022-02-13T21:09:26 | 2019-12-26T22:08:06 | Python | UTF-8 | Python | false | false | 7,515 | py | t301500.py | #-------------------------------------------
#-- Sorcery Scribe
#-------------------------------------------
# -*- coding: utf-8 -*-
#----------------------------------------------------
# Main Loop
#----------------------------------------------------
def t301500_1():
""" State 0,1 """
assert GetCurrentStateE... |
cd499cb2ce7cc7241ba6a5c8415454b80c000fa9 | e76a79816ff5203be2c4061e263a09d31072c940 | /third-party/py/pex/pex/compatibility.py | 1a86d5f8be90568b0efa755c47f57521dc534787 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | facebook/buck | ef3a833334499b1b44c586e9bc5e2eec8d930e09 | 9c7c421e49f4d92d67321f18c6d1cd90974c77c4 | refs/heads/main | 2023-08-25T19:30:28.803205 | 2023-04-19T11:32:59 | 2023-04-19T11:32:59 | 9,504,214 | 8,481 | 1,338 | Apache-2.0 | 2023-05-04T22:13:59 | 2013-04-17T18:12:18 | Java | UTF-8 | Python | false | false | 2,248 | py | compatibility.py | # Copyright 2014 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
# This file contains several 2.x/3.x compatibility checkstyle violations for a reason
# checkstyle: noqa
from abc import ABCMeta
from numbers import Integral, Real
from sys import version... |
3d7301525696e593b42a96eabc4eda52264a247f | f576f0ea3725d54bd2551883901b25b863fe6688 | /sdk/cognitivelanguage/azure-ai-language-questionanswering/samples/async_samples/sample_query_knowledgebase_async.py | e0ac42060591a0b66b6dc28154d7a1f016c694ba | [
"LicenseRef-scancode-generic-cla",
"MIT",
"LGPL-2.1-or-later"
] | permissive | Azure/azure-sdk-for-python | 02e3838e53a33d8ba27e9bcc22bd84e790e4ca7c | c2ca191e736bb06bfbbbc9493e8325763ba990bb | refs/heads/main | 2023-09-06T09:30:13.135012 | 2023-09-06T01:08:06 | 2023-09-06T01:08:06 | 4,127,088 | 4,046 | 2,755 | MIT | 2023-09-14T21:48:49 | 2012-04-24T16:46:12 | Python | UTF-8 | Python | false | false | 2,176 | py | sample_query_knowledgebase_async.py | # coding=utf-8
# ------------------------------------
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.
# ------------------------------------
"""
FILE: sample_query_knowledgebase_async.py
DESCRIPTION:
This sample demonstrates how to ask a question from a knowledge base.
USAGE:
python ... |
01100216dfb458ba7222d311127e0932afd2677c | 14a42aa9e707f70312647fbf86adb96fce7a2f97 | /testing/code/test_code.py | 33809528a06b0b2ef19fa789d91df381257da0e0 | [
"MIT"
] | permissive | pytest-dev/pytest | a0374d435f2b46e8a475b4b26085ab4f3d04aa67 | afb8d66e42a3449476cf9bf4526705b1e36ff5a5 | refs/heads/main | 2023-09-01T14:12:11.863580 | 2023-08-30T11:52:14 | 2023-08-30T11:52:14 | 37,489,525 | 11,423 | 3,125 | MIT | 2023-09-12T22:17:22 | 2015-06-15T20:28:27 | Python | UTF-8 | Python | false | false | 5,501 | py | test_code.py | import re
import sys
from types import FrameType
from unittest import mock
import pytest
from _pytest._code import Code
from _pytest._code import ExceptionInfo
from _pytest._code import Frame
from _pytest._code import Source
from _pytest._code.code import ExceptionChainRepr
from _pytest._code.code import ReprFuncArgs
... |
be39f20e2c06ee7740ec91e8534f4f0446753dbe | 8da41ffa2ccb09e04f95db0f211e0ed69a42a352 | /courses/machine_learning/deepdive2/end_to_end_ml/solutions/pipelines/containers/pipeline/main.py | 47534ea80576fcf2ff99aff1c30144e917964fad | [
"Apache-2.0"
] | permissive | GoogleCloudPlatform/training-data-analyst | 808af9b09a0e5f5657c4ca76cdd205f808d76d89 | 975a95032ce5b7012d1772c7f1f5cfe606eae839 | refs/heads/master | 2023-09-05T19:50:59.722334 | 2023-09-04T14:25:33 | 2023-09-04T14:25:33 | 56,459,948 | 7,311 | 5,917 | Apache-2.0 | 2023-09-13T21:45:54 | 2016-04-17T21:39:27 | Jupyter Notebook | UTF-8 | Python | false | false | 2,570 | py | main.py | # Copyright 2020 Google, LLC.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... |
5dc6292833f07ec832ac01193eca987b4484c166 | fbbe424559f64e9a94116a07eaaa555a01b0a7bb | /pytorch/source/caffe2/python/test_util.py | 947975f2fe59a4e49c415622ac5fe162cb389327 | [
"MIT"
] | permissive | ryfeus/lambda-packs | 6544adb4dec19b8e71d75c24d8ed789b785b0369 | cabf6e4f1970dc14302f87414f170de19944bac2 | refs/heads/master | 2022-12-07T16:18:52.475504 | 2022-11-29T13:35:35 | 2022-11-29T13:35:35 | 71,386,735 | 1,283 | 263 | MIT | 2022-11-26T05:02:14 | 2016-10-19T18:22:39 | Python | UTF-8 | Python | false | false | 1,687 | py | test_util.py | ## @package test_util
# Module caffe2.python.test_util
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import numpy as np
from caffe2.python import core, workspace
import unittest
import os
def rand_array(*dims):
... |
c405f32086495e20f1c641aea31b8b995311c8c2 | a41e1498e3c080f47abd8e8e57157548df3ebbf1 | /doc/make.py | 9db4ea406bc1f1e53477645a46477faacf53741e | [
"BSD-3-Clause"
] | permissive | pandas-dev/pandas | e7e639454a298bebc272622e66faa9829ea393bb | c7325d7e7e77ecb4a4e57b48bc25265277c75712 | refs/heads/main | 2023-09-01T12:42:07.927176 | 2023-09-01T11:14:10 | 2023-09-01T11:14:10 | 858,127 | 36,166 | 18,728 | BSD-3-Clause | 2023-09-14T21:18:41 | 2010-08-24T01:37:33 | Python | UTF-8 | Python | false | false | 11,982 | py | make.py | #!/usr/bin/env python3
"""
Python script for building documentation.
To build the docs you must have all optional dependencies for pandas
installed. See the installation instructions for a list of these.
Usage
-----
$ python make.py clean
$ python make.py html
$ python make.py latex
"""
import argparse
im... |
d31e2aba473b57adf1376973dff3347ceac450a5 | cfb41f392fac304095a80d08497727c621550c00 | /development/advect.py | 5fcc3f4be115c324b3de431f9bbda0ca107f39e1 | [
"BSD-3-Clause"
] | permissive | clawpack/pyclaw | 5b7121b63609c2cf9af30e012c9318e3b5244f18 | 6323b7295b80f33285b958b1a2144f88f51be4b1 | refs/heads/master | 2023-04-16T23:48:31.519427 | 2023-03-21T06:08:21 | 2023-03-21T06:08:21 | 1,628,711 | 124 | 97 | BSD-3-Clause | 2023-09-12T12:22:30 | 2011-04-18T03:11:21 | Fortran | UTF-8 | Python | false | false | 1,673 | py | advect.py | #!/usr/bin/env python
from __future__ import absolute_import
from __future__ import print_function
import sys
from six.moves import range
try:
import numpy as np
from petsc4py import PETSc
except:
sys.path.append("/opt/share/ksl/petsc4py/dev-aug29/ppc450d/lib/python/")
sys.path.append("/opt/share/ksl/n... |
3b3526d372f8a5fef56fff90c862180c91f60e01 | 50203b4a349dcb2ed1e72c9f5463d84db8a6e983 | /skyline/functions/metrics_manager/manage_mute_alerts_on.py | acc3bdbbc2ef008aab7817a1594786ec0db67aa2 | [
"MIT"
] | permissive | earthgecko/skyline | 97e43df824d7c92d68086f529f0f3d051a7debb0 | c2edc451e63d5eb57117ddcfbc6e79100e706460 | refs/heads/master | 2023-08-30T08:36:50.740285 | 2023-06-28T15:33:47 | 2023-06-28T15:33:47 | 20,475,900 | 482 | 74 | NOASSERTION | 2023-06-28T15:33:49 | 2014-06-04T08:33:15 | Python | UTF-8 | Python | false | false | 3,538 | py | manage_mute_alerts_on.py | """
manage_mute_alerts_on.py
"""
import logging
from os import uname
from time import time
from settings import REMOTE_SKYLINE_INSTANCES
from slack_functions import slack_post_message
skyline_app = 'analyzer'
skyline_app_logger = '%sLog' % skyline_app
logger = logging.getLogger(skyline_app_logger)
# @added 20230605... |
b6d143990c367720c629883217c5f3f951e6e0a0 | e8b04bef9aa1ac8e2c109dd315f133c8f4d28ae6 | /projects/samples/robotbenchmark/robot_programming/controllers/supervisor/supervisor.py | 0698858a3681d08242b80f77efe4fd91916e5e50 | [
"Apache-2.0"
] | permissive | cyberbotics/webots | f075dacf4067e8dcebbfd89e8690df8525f6d745 | 8aba6eaae76989facf3442305c8089d3cc366bcf | refs/heads/master | 2023-08-31T09:41:13.205940 | 2023-08-18T10:48:30 | 2023-08-18T10:48:30 | 156,228,018 | 2,495 | 1,525 | Apache-2.0 | 2023-08-28T16:30:33 | 2018-11-05T14:09:10 | C++ | UTF-8 | Python | false | false | 1,576 | py | supervisor.py | """Supervisor of the Robot Programming benchmark."""
from controller import Supervisor
import os
import sys
try:
includePath = os.path.join(os.path.normpath(os.environ.get("WEBOTS_HOME")), 'projects', 'samples', 'robotbenchmark',
'include')
sys.path.append(includePath)
from ... |
81b3086028408995c4f19c993aa4145f2a4c9999 | 9798f5eca599c840bc9f307e9726f43a4c013aa1 | /rest_framework_json_api/schemas/openapi.py | 52f08da6e4d002c9dc9309cbbb9cf87e0e5bf8ae | [
"BSD-2-Clause"
] | permissive | django-json-api/django-rest-framework-json-api | 6e4591d5c85e448a2a9f4f9fe4f1fe7e79c0b72f | cd5f17970123400a2c5b98cfbb11f940d2cf09a9 | refs/heads/main | 2023-09-01T10:39:45.323109 | 2023-08-25T11:39:19 | 2023-08-25T11:39:19 | 21,987,374 | 1,133 | 378 | BSD-2-Clause | 2023-09-07T11:26:39 | 2014-07-18T16:46:14 | Python | UTF-8 | Python | false | false | 36,003 | py | openapi.py | import warnings
from urllib.parse import urljoin
from rest_framework.fields import empty
from rest_framework.relations import ManyRelatedField
from rest_framework.schemas import openapi as drf_openapi
from rest_framework.schemas.utils import is_list_view
from rest_framework_json_api import serializers, views
from res... |
f77d8973e58d92c20359a97e952c2fb79b6850f2 | 3ef70fe63acaa665e2b163f30f1abd0a592231c1 | /stackoverflow/venv/lib/python3.6/site-packages/scrapy/utils/display.py | f6a6c46454efdc08bdf119ce27818b4e6cc93c35 | [
"MIT"
] | permissive | wistbean/learn_python3_spider | 14914b63691ac032955ba1adc29ad64976d80e15 | 40861791ec4ed3bbd14b07875af25cc740f76920 | refs/heads/master | 2023-08-16T05:42:27.208302 | 2023-03-30T17:03:58 | 2023-03-30T17:03:58 | 179,152,420 | 14,403 | 3,556 | MIT | 2022-05-20T14:08:34 | 2019-04-02T20:19:54 | Python | UTF-8 | Python | false | false | 699 | py | display.py | """
pprint and pformat wrappers with colorization support
"""
from __future__ import print_function
import sys
from pprint import pformat as pformat_
def _colorize(text, colorize=True):
if not colorize or not sys.stdout.isatty():
return text
try:
from pygments import highlight
from pyg... |
2cb4e4b675f537c63864330614db08126ca922d5 | ad3ae46b6d8de00d434959fa413dd730fce48055 | /tests/test_project/makemigrations_correct_migration_missing/models.py | c15040f8ba01ef78c03d9e544bb2f3498b559b61 | [
"Apache-2.0"
] | permissive | 3YOURMIND/django-migration-linter | 5f4e5ad1485eca7b740fea7d3f69c3d345448fcd | 3503367f1fcb34e633577cf70df9ab037d1f394c | refs/heads/main | 2023-08-31T15:36:03.626246 | 2023-07-09T12:43:55 | 2023-07-09T12:43:55 | 87,307,127 | 466 | 62 | Apache-2.0 | 2023-09-11T09:08:24 | 2017-04-05T12:33:19 | Python | UTF-8 | Python | false | false | 180 | py | models.py | from __future__ import annotations
from django.db import models
class A(models.Model):
x = models.IntegerField()
new_field = models.CharField(null=True, max_length=255)
|
8116f287c8fa31b370a93f20815b51e171274af6 | acc81cd3c5c9785990479d39706d63fe37417574 | /keyring/backends/fail.py | 9bcdfc8094d0bfaa93560a56e610ccf0abd0efe7 | [
"MIT"
] | permissive | jaraco/keyring | bf91a6cbe9b4ce7cfff585a6a9bf7fecbbbc9c5e | af7233958ece36da8d493509a6388484f5534dfc | refs/heads/main | 2023-08-08T14:53:16.361761 | 2023-07-23T13:01:17 | 2023-07-23T13:01:17 | 31,262,911 | 1,118 | 193 | MIT | 2023-09-13T17:32:33 | 2015-02-24T14:10:21 | Python | UTF-8 | Python | false | false | 929 | py | fail.py | from ..backend import KeyringBackend
from .._compat import properties
from ..errors import NoKeyringError
class Keyring(KeyringBackend):
"""
Keyring that raises error on every operation.
>>> kr = Keyring()
>>> kr.get_password('svc', 'user')
Traceback (most recent call last):
...
keyring.e... |
8db734d3675dd8282faf5a2108e2bbf434569763 | 1373b5f879da9a9b25b53c16d81de86f2f3b222b | /banding_removal/fastmri/checkpointing_mixin.py | ed9e021aa1e226420dade11e6f4412a1cdd1d997 | [
"MIT"
] | permissive | facebookresearch/fastMRI | 316daf77f53c61cd297aa8cb3509d002a8300648 | 84ab6e57748c2631b0e780255dcbc1d6e372269d | refs/heads/main | 2023-09-05T09:54:25.653593 | 2023-06-26T17:03:09 | 2023-06-26T17:03:09 | 154,900,564 | 1,174 | 400 | MIT | 2023-06-26T17:03:10 | 2018-10-26T22:21:23 | Python | UTF-8 | Python | false | false | 7,412 | py | checkpointing_mixin.py | """
Copyright (c) Facebook, Inc. and its affiliates.
This source code is licensed under the MIT license found in the
LICENSE file in the root directory of this source tree.
"""
import os
import signal
import sys
from subprocess import call, Popen, PIPE
import torch
import logging
import pickle
import pdb
from pathlib... |
88572202125ef95326679e62ebcbf0c9fcabdf09 | df1254b56f35b24644e00493c50d4b6eb3c15b7b | /colour/volume/tests/test_macadam_limits.py | fa7cdd3d03eda6bfea38fcb3138e76301116325e | [
"BSD-3-Clause"
] | permissive | colour-science/colour | 908400b227cf81668675e41099256ce50b23ae4b | 1fdf3b3042922e8d4f86b989b00a06e7e5d81102 | refs/heads/develop | 2023-09-01T23:17:07.186869 | 2023-08-26T09:40:45 | 2023-08-26T09:40:45 | 17,114,363 | 1,756 | 301 | BSD-3-Clause | 2023-09-14T10:24:37 | 2014-02-23T18:55:40 | Python | UTF-8 | Python | false | false | 2,454 | py | test_macadam_limits.py | # !/usr/bin/env python
"""Define the unit tests for the :mod:`colour.volume.macadam_limits` module."""
import numpy as np
import unittest
from itertools import product
from colour.volume import is_within_macadam_limits
from colour.utilities import ignore_numpy_errors
__author__ = "Colour Developers"
__copyright__ = ... |
05ecb5610d92cd3a6b86d26bcb1748e972766cd6 | c3e0a6919caf85c35239ef23084df9bbf8dd61c3 | /pypeit/tests/test_procimg.py | d04fe98f350a61da587796b405349d202f8f14e7 | [
"BSD-3-Clause"
] | permissive | pypeit/PypeIt | 6eb9e5afd62acc9d363e497cd9e367d620f86ea4 | 0d2e2196afc6904050b1af4d572f5c643bb07e38 | refs/heads/release | 2023-08-25T21:15:59.113114 | 2023-06-04T15:23:39 | 2023-06-04T15:23:39 | 36,958,428 | 136 | 98 | BSD-3-Clause | 2023-09-12T17:42:15 | 2015-06-05T22:25:37 | Python | UTF-8 | Python | false | false | 5,348 | py | test_procimg.py | """
Module to run tests on core.procimg functions.
"""
import os
from IPython import embed
import numpy as np
from astropy.convolution import convolve
from pypeit.core import procimg
from pypeit import utils
def test_replace_columns():
y = np.zeros((10,3), dtype=float)
y[:,2] = 2
bad_col = np.array([Fa... |
efaa093850eff3ef8462c310bb5407fcf6184943 | 915d6cd33ed4293d83a15a2a03bd126a1f03fc97 | /xknx/remote_value/remote_value_climate_mode.py | 5f688bbe9ccd94ddd2351c6461970a285b261f18 | [
"MIT"
] | permissive | XKNX/xknx | 5e02e3588ab8b2a4dcd7895b94cd39c2894070a8 | 48d4e31365c15e632b275f0d129cd9f2b2b5717d | refs/heads/main | 2023-09-02T11:18:18.093379 | 2023-08-28T11:06:58 | 2023-08-28T11:06:58 | 51,259,458 | 248 | 131 | MIT | 2023-09-11T11:54:55 | 2016-02-07T18:29:39 | Python | UTF-8 | Python | false | false | 10,318 | py | remote_value_climate_mode.py | """
Module for managing an climate mode remote values.
DPT .
"""
from __future__ import annotations
from abc import abstractmethod
from enum import Enum
from typing import TYPE_CHECKING, Any, Optional
from xknx.dpt import (
DPTArray,
DPTBinary,
DPTControllerStatus,
DPTHVACContrMode,
DPTHVACMode,
... |
805a0277497141b74d439b00bca4053f566e3670 | 8e6146819d50f3f6a0a725036f36f261ebbc2951 | /derl/envs/tasks/manipulation.py | ce0f11cb66a21e5cf9da5e21e1394ee14a899c0d | [] | no_license | agrimgupta92/derl | 54399730fe4de08a958ec847b34e0c036a9f30fa | 91e077e355b27bb74fa920c708d606ff9f4d611e | refs/heads/main | 2023-08-21T19:20:05.150847 | 2021-10-09T19:13:05 | 2021-10-09T19:13:05 | 414,080,496 | 107 | 24 | null | null | null | null | UTF-8 | Python | false | false | 5,005 | py | manipulation.py | import numpy as np
from gym import utils
from scipy.spatial import distance as scipy_distance
import derl.utils.mjpy as mu
from derl.config import cfg
from derl.envs.modules.agent import Agent
from derl.envs.modules.objects import Objects
from derl.envs.modules.terrain import Terrain
from derl.envs.tasks.unimal import... |
d7a597d9aa575f41d501f194baeacb56167175af | e04a5b20f946c5033f24d4dd8acda395a98747c5 | /tableau-export/python-lib/tableau_utils.py | c464b4ceb8089a39f920a9ff5500ad05b6992251 | [
"LicenseRef-scancode-free-unknown",
"Apache-2.0",
"BSD-2-Clause",
"MIT",
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference",
"LicenseRef-scancode-other-permissive"
] | permissive | dataiku/dataiku-contrib | 2a2f2fb420d7f2ab49b82d80659cc6f6ec1d8f61 | 9a9f189e8a544a81c205d8a8b3779d4517b88653 | refs/heads/master | 2023-09-04T03:33:58.625093 | 2023-04-26T08:17:34 | 2023-04-26T08:17:34 | 45,074,604 | 103 | 94 | Apache-2.0 | 2023-06-08T21:29:07 | 2015-10-27T22:41:00 | Python | UTF-8 | Python | false | false | 5,269 | py | tableau_utils.py | # -*- coding: utf-8 -*-
from tableausdk import *
from tableausdk.Extract import *
from tableausdk.Server import *
# Because of a bug in Tableau, we need to load Tableau before pandas.
# See http://community.tableau.com/thread/156790 for more info
import dataiku
import os
from dataiku.customrecipe import *
from datetim... |
cce133fef0216cc0bd50fdcfb3ac36a0a72403b3 | 279f415dd1e06c594c6c87deda57e201c73c4542 | /espnet2/spk/pooling/chn_attn_stat_pooling.py | 4bc1678fa7efa4b82d2a6d3747ad44c2cb368379 | [
"Apache-2.0"
] | permissive | espnet/espnet | f7ba47271c1a6b1ed606dbbfb04a7f14220bb585 | bcd20948db7846ee523443ef9fd78c7a1248c95e | refs/heads/master | 2023-08-28T23:43:34.238336 | 2023-08-23T02:51:39 | 2023-08-23T02:51:39 | 114,054,873 | 7,242 | 2,244 | Apache-2.0 | 2023-09-14T08:01:11 | 2017-12-13T00:45:11 | Python | UTF-8 | Python | false | false | 1,548 | py | chn_attn_stat_pooling.py | import torch
import torch.nn as nn
from espnet2.spk.pooling.abs_pooling import AbsPooling
class ChnAttnStatPooling(AbsPooling):
"""
Aggregates frame-level features to single utterance-level feature.
Proposed in B.Desplanques et al., "ECAPA-TDNN: Emphasized Channel
Attention, Propagation and Aggregati... |
a21fbb8c5880b9e753be4612032c4684ff4423ac | dea96d9c6f510d759bb00cb214c4fcd1ac7b32cd | /数据结构/NowCode/2_JumpFloor.py | 169ef182db4f1837c8a7b339f045c8c55f3024d4 | [
"MIT"
] | permissive | moxi624/LearningNotes | cf92103f6a2592b9017f27bdfac57459ef8e1f6a | bb62ae291955944d4d73acaaf4531786314214ac | refs/heads/master | 2023-03-08T03:59:32.137474 | 2022-10-10T15:21:48 | 2022-10-10T15:21:59 | 229,531,057 | 618 | 156 | MIT | 2023-03-07T02:14:59 | 2019-12-22T07:03:57 | Java | UTF-8 | Python | false | false | 561 | py | 2_JumpFloor.py | # 一只青蛙一次可以跳上1级台阶,也可以跳上2级。求该青蛙跳上一个n级的台阶总共有多少种跳法(先后次序不同算不同的结果)
class Solution:
def JumpFloor(self, n):
if n == 0:
return 0;
if n == 1:
return 1;
if n == 2:
return 2;
ret = 0
a = 1
b = 2
for i in range(3, n + 1):
r... |
b2ac827e9a783c1a41466d01cdc5418d0a63d0f0 | d05ff6dda43729011b7d469b0a2bc02ed66b6342 | /frappe/website/web_form/request_data/request_data.py | 1224e3f095eb3f0f2795872ab8b51816679808a3 | [
"MIT"
] | permissive | frappe/frappe | 520c14bed3810c3360629a81dcc33f0ebe21ac4d | dd8f314bf4a8a4739eebbfac741abc533ac58bc1 | refs/heads/develop | 2023-08-30T19:29:10.406706 | 2023-08-30T11:20:40 | 2023-08-30T11:20:40 | 1,864,194 | 5,955 | 3,735 | MIT | 2023-09-14T16:08:04 | 2011-06-08T08:14:16 | Python | UTF-8 | Python | false | false | 32 | py | request_data.py | def get_context(context):
pass
|
0c6f8204736f0d1d2cba25561b7e41bb9b282d47 | 7ff6521386936a2afac803d03e1a285cdb873d8f | /supersuit/vector/multiproc_vec.py | 9901fadaac121e944cd39fa8c02e97c1d2a23111 | [
"Apache-2.0",
"MIT"
] | permissive | Farama-Foundation/SuperSuit | 4671856a4102b528a9b4e4c705fa0abfff99be18 | dc4dc8aa34c2623fc0d0abdb3e53b9f67f468253 | refs/heads/master | 2023-08-03T12:54:52.623837 | 2023-07-21T00:43:26 | 2023-07-21T00:43:26 | 252,030,937 | 156 | 32 | NOASSERTION | 2023-07-20T15:59:02 | 2020-04-01T00:27:34 | Python | UTF-8 | Python | false | false | 8,671 | py | multiproc_vec.py | import copy
import multiprocessing as mp
import time
import traceback
import gymnasium.vector
import numpy as np
from gymnasium.vector.utils import (
concatenate,
create_empty_array,
create_shared_memory,
iterate,
read_from_shared_memory,
write_to_shared_memory,
)
from .utils.shared_array impo... |
c00a29aecbb835e2f393ef735c7577a3f87b7373 | dbb120cceaed09027f250bedbb6f5a8c5d4c71f5 | /netket/nn/fast_masked_linear.py | a8a2b3b90619353a64ad91c242cb71e8e34abd6f | [
"Apache-2.0"
] | permissive | netket/netket | b0ec4dc6e0ed5493299a38b8dbfd06e9f946e3b3 | f4f2844739302fd7e044b722eae8a93d0bfc59ec | refs/heads/master | 2023-08-29T12:03:29.446789 | 2023-08-20T10:21:41 | 2023-08-20T10:21:41 | 130,741,783 | 467 | 181 | Apache-2.0 | 2023-09-14T20:40:47 | 2018-04-23T18:48:08 | Python | UTF-8 | Python | false | false | 16,205 | py | fast_masked_linear.py | # Copyright 2021 The NetKet Authors - All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable ... |
4880a324a1b9a897a7ea11bdf941d288c0be511a | 04e5b6df2ee3bcfb7005d8ec91aab8e380333ac4 | /Extensions/Dependencies/tools/gfortran | 7572943a989932b3558ca339dde23acbfeb273ab | [
"MIT"
] | permissive | ColdGrub1384/Pyto | 64e2a593957fd640907f0e4698d430ea7754a73e | 7557485a733dd7e17ba0366b92794931bdb39975 | refs/heads/main | 2023-08-01T03:48:35.694832 | 2022-07-20T14:38:45 | 2022-07-20T14:38:45 | 148,944,721 | 884 | 157 | MIT | 2023-02-26T21:34:04 | 2018-09-15T22:29:07 | C | UTF-8 | Python | false | false | 4,183 | gfortran | #!/usr/bin/env python3
import sys
import os
import shlex
import subprocess
import string
import random
import shutil
def join_args(args):
return ' '.join(shlex.quote(x) for x in args)
if "-dumpversion" in sys.argv:
print("10.2.0")
sys.exit(0)
arguments = []
sys_args = sys.argv
del sys_args[0]
try:
... | |
5b3fd235aa5fee6d8d90209c226fdf6f45968453 | 83963c19fd120dcc7498b726cc56de7fbb900a47 | /osxphotos/phototables.py | d4f09dfa0f391299d4ebb3b47974e879209473ae | [
"MIT",
"LicenseRef-scancode-public-domain"
] | permissive | RhetTbull/osxphotos | 55ad4f1257bcd26bb3fbadde6ce5dd59c0917354 | 2cb5a4d18a27be6ccf68f5f35abd39418d238016 | refs/heads/main | 2023-09-02T18:11:06.227191 | 2023-09-02T16:06:51 | 2023-09-02T16:06:51 | 192,160,985 | 1,287 | 93 | MIT | 2023-09-14T14:10:58 | 2019-06-16T07:07:49 | Python | UTF-8 | Python | false | false | 8,828 | py | phototables.py | """Provide direct access to the database tables associated with a photo."""
from __future__ import annotations
import sqlite3
from typing import Any
import osxphotos
from ._constants import _DB_TABLE_NAMES
def get_table_columns(conn: sqlite3.Connection, table_name: str) -> list[str]:
cursor = conn.cursor()
... |
c72fff19a1908e45711fbc199114e6029f29e7ea | ed36064525bad62959d9ab739edeea477bf29c1c | /2017-11-09-defcamp-final/hack_tac_toe/toe.py | 218cfc549bad49c2fda7179daac3c3a9c5f59856 | [] | no_license | p4-team/ctf | 2dae496622c8403d7539b21f0e9a286e9889195a | 8280caff137e42b26cb55f2c62411c7c512088de | refs/heads/master | 2023-08-12T03:21:31.021612 | 2023-04-26T23:57:29 | 2023-04-26T23:57:29 | 42,933,477 | 1,899 | 366 | null | 2022-06-07T21:51:40 | 2015-09-22T12:53:15 | Python | UTF-8 | Python | false | false | 724 | py | toe.py | import requests
from crypto_commons.generic import xor_string
s = requests.Session()
def get_state():
return requests.utils.unquote(s.cookies['Encrypted_Game_Session']).decode('base64')
def main():
s.get('http://hacktactoe.dctf-f1nals-2017.def.camp/action.php?action=init')
original_state = get_state()... |
2783b262c575062cbc56a87934da3fbabb65661f | a2b429075098ef615a104845b8434e7fdeff9d14 | /antspynet/utilities/histology.py | e5ceb71c683323adbd46242a27632aa93adf3026 | [
"Apache-2.0"
] | permissive | ANTsX/ANTsPyNet | de95ec1ceca6bd146b99127c36273ba4649be40b | 1703acb58ed053ce3348aa061e4087bac953dd07 | refs/heads/master | 2023-08-09T17:26:33.179674 | 2023-08-04T14:22:18 | 2023-08-04T14:22:18 | 189,067,098 | 171 | 36 | Apache-2.0 | 2023-07-13T15:57:34 | 2019-05-28T16:44:24 | Python | UTF-8 | Python | false | false | 28,682 | py | histology.py | import numpy as np
import ants
import warnings
def arterial_lesion_segmentation(image,
antsxnet_cache_directory=None,
verbose=False):
"""
Perform arterial lesion segmentation using U-net.
Arguments
---------
image : ANTsImage
... |
9272a2a157e45cd05091ca47448c140237120efe | 5a52ccea88f90dd4f1acc2819997fce0dd5ffb7d | /alipay/aop/api/response/AlipayInsDataAutoFraudQueryResponse.py | 66801e8c42dc4e45c839bad0e1cf26318f653c11 | [
"Apache-2.0"
] | permissive | alipay/alipay-sdk-python-all | 8bd20882852ffeb70a6e929038bf88ff1d1eff1c | 1fad300587c9e7e099747305ba9077d4cd7afde9 | refs/heads/master | 2023-08-27T21:35:01.778771 | 2023-08-23T07:12:26 | 2023-08-23T07:12:26 | 133,338,689 | 247 | 70 | Apache-2.0 | 2023-04-25T04:54:02 | 2018-05-14T09:40:54 | Python | UTF-8 | Python | false | false | 1,702 | py | AlipayInsDataAutoFraudQueryResponse.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.response.AlipayResponse import AlipayResponse
from alipay.aop.api.domain.CaseInfoCode import CaseInfoCode
class AlipayInsDataAutoFraudQueryResponse(AlipayResponse):
def __init__(self):
super(AlipayInsDataAutoFraudQueryResponse... |
b25fbfba1f850a24282b97fb977d242372dc8181 | beab4b9703df6c4e9bda54fada11a6d985ea2c5a | /tests/test_json_encoding.py | f581b3e383e800751390d2b41ad253456fa430f6 | [
"MIT"
] | permissive | sanic-org/sanic | d3db62482914061a1f6a8f7d94b6127c2876cb3e | 47215d4635184bdfb1d5cff000d19390f19219ab | refs/heads/main | 2023-09-05T01:04:31.432228 | 2023-08-30T17:03:22 | 2023-08-30T17:03:22 | 59,720,190 | 3,523 | 439 | MIT | 2023-09-14T05:45:11 | 2016-05-26T04:38:22 | Python | UTF-8 | Python | false | false | 2,501 | py | test_json_encoding.py | import sys
from dataclasses import asdict, dataclass
from functools import partial
from json import dumps as sdumps
from string import ascii_lowercase
from typing import Dict
import pytest
try:
import ujson
from ujson import dumps as udumps
ujson_version = tuple(
map(int, ujson.__version__.str... |
136287c7713b128c11e4ebde004e1029259a80dd | d068d41e02ab116cbd83ee9298c9ba357c668f85 | /ipypublish/tests/__init__.py | ea0d1483f847ae8608c5d8e49343c09e06ae1550 | [
"BSD-3-Clause"
] | permissive | chrisjsewell/ipypublish | 01f362cdf0989e119111a089bb307f52e23c1ef7 | 53fa92c4c7f18e36d8a9790b10de27219882f4e4 | refs/heads/develop | 2022-02-08T04:26:32.081511 | 2020-08-14T01:18:09 | 2020-08-14T01:18:09 | 96,322,423 | 233 | 42 | BSD-3-Clause | 2021-11-20T18:58:33 | 2017-07-05T13:29:38 | HTML | UTF-8 | Python | false | false | 161 | py | __init__.py | import os
TEST_FILES_DIR = os.path.join(os.path.dirname(os.path.realpath(__file__)), "test_files")
TEST_PIC_PATH = os.path.join(TEST_FILES_DIR, "example.jpg")
|
819fef3c3d4ec30dbcae644781dcdb4ae3d7a3dd | c89fe3e0595cffefda18e12a28e7aa09faadf783 | /igvc_perception/src/train_eval/IGVCDataset.py | bc8396dd2e05af3c173f6da2228fb354ea4f819d | [
"MIT"
] | permissive | RoboJackets/igvc-software | 5923413dba07d0839628739b380cb08a3a158f57 | bd65158fb92d75cae4c6fea9cd330291e12701fc | refs/heads/master | 2022-08-19T16:49:15.798203 | 2022-07-31T00:18:59 | 2022-07-31T00:18:59 | 16,996,386 | 111 | 159 | MIT | 2022-07-31T00:19:00 | 2014-02-19T19:44:06 | Jupyter Notebook | UTF-8 | Python | false | false | 4,181 | py | IGVCDataset.py | import cv2
import datetime
import glob
import ntpath
import numpy as np
import os
import pickle
from PIL import Image
import pdb
import random
import torch.utils.data as data
class IGVCDataset(data.Dataset):
def __init__(
self,
root,
im_size,
split="train",
transform=None,
... |
29b294a6215575a94baa392fda3e6025ae7c8f32 | b06340ae3dfcb551bacefa362c034b064809fd28 | /src/pytest_check/pseudo_traceback.py | ccbf1d84d6a0700b0de8aea544f3f3ff892bb42c | [
"MIT"
] | permissive | okken/pytest-check | cd3b82ae31932d54550822abb6cc96fa6b4e7c88 | c7e7741e4d5665a07b0985932acc484aac2d5095 | refs/heads/main | 2023-08-19T09:10:40.776832 | 2023-08-11T20:44:36 | 2023-08-11T20:44:36 | 108,791,429 | 282 | 35 | MIT | 2023-08-11T20:37:17 | 2017-10-30T02:22:27 | Python | UTF-8 | Python | false | false | 3,567 | py | pseudo_traceback.py | import inspect
import os
import re
from pprint import pformat
_traceback_style = "auto"
def get_full_context(frame):
(_, filename, line, funcname, contextlist) = frame[0:5]
locals = frame.frame.f_locals
tb_hide = locals.get("__tracebackhide__", False)
try:
filename = os.path.relpath(filename)... |
df370e9814db36a73d8852a45b2a0fb4a2d872f1 | a3d6556180e74af7b555f8d47d3fea55b94bcbda | /tools/perf/core/perfetto_binary_roller/binary_deps_manager.py | 1619dcb78a5262e9de6cefa6644012281eca136c | [
"BSD-3-Clause"
] | permissive | chromium/chromium | aaa9eda10115b50b0616d2f1aed5ef35d1d779d6 | a401d6cf4f7bf0e2d2e964c512ebb923c3d8832c | refs/heads/main | 2023-08-24T00:35:12.585945 | 2023-08-23T22:01:11 | 2023-08-23T22:01:11 | 120,360,765 | 17,408 | 7,102 | BSD-3-Clause | 2023-09-10T23:44:27 | 2018-02-05T20:55:32 | null | UTF-8 | Python | false | false | 9,519 | py | binary_deps_manager.py | # Copyright 2022 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import json
import os
import posixpath
import stat
import subprocess
import sys
import tempfile
import six
# When py_utils from the catapult repo are not available (as is the cas... |
144d2b09984c1c547be8b15c58605d061c6baf12 | cadb6dceb7bb67ce47ef48b2c83f480a65d6b01a | /s3prl/utility/check_hub.py | a5d879946b1636a274fd543eff525541bba523ca | [
"Apache-2.0",
"CC-BY-NC-4.0"
] | permissive | s3prl/s3prl | 52ec2ae4df5a61c786c122085603aa9c5e8c2681 | 76a9432b824f6ae3eae09a35a67782c4ed582832 | refs/heads/main | 2023-08-17T02:26:57.524087 | 2023-06-10T17:12:27 | 2023-06-10T17:12:27 | 196,905,457 | 1,549 | 398 | Apache-2.0 | 2023-09-14T13:07:05 | 2019-07-15T01:54:52 | Python | UTF-8 | Python | false | false | 1,033 | py | check_hub.py | import argparse
import torch
import hubconf
parser = argparse.ArgumentParser()
upstreams = [attr for attr in dir(hubconf) if callable(getattr(hubconf, attr)) and attr[0] != '_']
parser.add_argument('--mode', choices=['list', 'help', 'load'], required=True)
parser.add_argument('--upstream', choices=upstreams)
parser.... |
077ae4b648c61c16f9583aac26a24941285cfeef | fa3f6d4e9169fb95f828013d179d03accdff381b | /grr/server/grr_response_server/export_converters/network.py | fd707ca6ac4629ca450bcd720d859fd925ef84af | [
"Apache-2.0"
] | permissive | google/grr | c51a2bd251ed2f7adae538541990a2cc01fdcc8c | 44c0eb8c938302098ef7efae8cfd6b90bcfbb2d6 | refs/heads/master | 2023-09-05T20:02:36.823914 | 2023-07-26T09:34:09 | 2023-07-26T09:34:09 | 14,909,673 | 4,683 | 927 | Apache-2.0 | 2023-07-26T09:34:10 | 2013-12-04T00:17:53 | Python | UTF-8 | Python | false | false | 4,124 | py | network.py | #!/usr/bin/env python
"""Classes for exporting network-related data."""
from typing import Iterator, List
from grr_response_core.lib.rdfvalues import client_network as rdf_client_network
from grr_response_core.lib.rdfvalues import structs as rdf_structs
from grr_response_proto import export_pb2
from grr_response_serv... |
4595d3f0aa70383df8d225c3f7258f2deef526fe | a2b9d660b4bb57d117dfd5b7aae414f547757c49 | /arknights_/common_operation.py | 43c11957935d8d6806f8148eeb79f3f7916fa376 | [
"MIT"
] | permissive | MangetsuC/arkHelper | 17dd470b73612f7fed87096dbd09b6e766c73f08 | 316d45710adab8d0594e1774d71228fc344be842 | refs/heads/master | 2022-12-07T01:53:00.799907 | 2022-06-01T04:52:37 | 2022-06-01T04:52:37 | 243,768,162 | 162 | 18 | MIT | 2022-11-22T11:01:24 | 2020-02-28T13:25:47 | Python | UTF-8 | Python | false | false | 2,607 | py | common_operation.py | from doctest import FAIL_FAST
from sys import path as spath
from os import getcwd
from time import sleep
from pip import main
spath.append(getcwd())
from user_res import R
from common2 import adb
from image_.match import match_pic
from image_.color_detect import find_color_block, get_point_color, check_point_color, ... |
1d0fdb66b647cb13b85482c8adf952ca15053f8c | 2dfbca22d0bacf7ba2bb4d270b2d3292f5f8a43b | /amulet/level/formats/leveldb_world/interface/chunk/leveldb_8.py | cfbc73963022d6886a4679a5a930c475690db31c | [] | no_license | Amulet-Team/Amulet-Core | 9715d888e2faf6c41f9414fd105aaa926aa501c2 | dafef97fe4fd1f2f713ef1e3503d6b13b20c1c1f | refs/heads/main | 2023-08-18T17:45:48.775423 | 2023-08-16T09:37:55 | 2023-08-16T09:37:55 | 130,729,079 | 117 | 26 | null | 2023-08-16T09:37:57 | 2018-04-23T17:00:04 | Python | UTF-8 | Python | false | false | 7,326 | py | leveldb_8.py | from __future__ import annotations
from .leveldb_7 import (
LevelDB7Interface,
)
from typing import Tuple, Dict, Optional, TYPE_CHECKING, List
import struct
import numpy
from numpy.typing import NDArray
from amulet_nbt import NamedTag, CompoundTag, StringTag, IntTag, ShortTag
from amulet.api.block import Block,... |
742d40ef15fd00e2494b0cb8aa4c084cb2739bc0 | eb9f655206c43c12b497c667ba56a0d358b6bc3a | /python/testData/keywordCompletion/elseInCondExpr.py | 4a73af1eb5e0c0a591403f415abafa8833ff4e47 | [
"Apache-2.0"
] | permissive | JetBrains/intellij-community | 2ed226e200ecc17c037dcddd4a006de56cd43941 | 05dbd4575d01a213f3f4d69aa4968473f2536142 | refs/heads/master | 2023-09-03T17:06:37.560889 | 2023-09-03T11:51:00 | 2023-09-03T12:12:27 | 2,489,216 | 16,288 | 6,635 | Apache-2.0 | 2023-09-12T07:41:58 | 2011-09-30T13:33:05 | null | UTF-8 | Python | false | false | 24 | py | elseInCondExpr.py | a = 1 if True els<caret> |
b8de3bf471cc603c22db99a4206ef863fbb0494d | 0009c76a25c89a0d61d3bc9e10071da58bdfaa5a | /py/ztools/lib/Utils.py | 212ee242fc6307195c274a634ab984487564774e | [
"MIT"
] | permissive | julesontheroad/NSC_BUILDER | 84054e70a80b572088b0806a47ceb398302451b5 | e9083e83383281bdd9e167d3141163dcc56b6710 | refs/heads/master | 2023-07-05T05:23:17.114363 | 2021-11-15T19:34:47 | 2021-11-15T19:34:47 | 149,040,416 | 1,249 | 143 | MIT | 2022-12-15T03:19:33 | 2018-09-16T22:18:01 | Python | UTF-8 | Python | false | false | 3,606 | py | Utils.py | #!/usr/bin/python3
# -*- coding: utf-8 -*-
import os, sys
import io
import re
from binascii import hexlify as hx, unhexlify as uhx
from struct import pack as pk, unpack as upk
def memdump(data, length=16, message=''):
assert data, 'Nothing to dump'
dump = []
first = True
while data:
dump.append(message + ' '.jo... |
83a2aad12a265c68f589b5be3747126378158587 | 7f523c407d45d116860eff67f079e807f2b53339 | /src/third_party/beaengine/tests/0f385c.py | 3064594dccf5efac884203b1b4e55d702ee31e52 | [
"LGPL-3.0-only",
"LGPL-2.0-or-later",
"MIT"
] | permissive | 0vercl0k/rp | a352c96bfe3715eb9ce8c5942831123e65289dac | b24e7f58a594aaf0ce3771745bf06862f6ecc074 | refs/heads/master | 2023-08-30T08:03:14.842828 | 2023-08-09T00:41:00 | 2023-08-09T00:41:00 | 3,554,173 | 1,557 | 239 | MIT | 2023-08-09T00:41:02 | 2012-02-26T19:26:33 | C++ | UTF-8 | Python | false | false | 2,239 | py | 0f385c.py | #!/usr/bin/python
# -*- coding: utf-8 -*-
# This program 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 later version.
#
# This progra... |
6df7f6203c33399ca084b54c93c23936ae0a3b36 | 5a52ccea88f90dd4f1acc2819997fce0dd5ffb7d | /alipay/aop/api/domain/AnttechBlockchainFinanceMylogisticfinsandboxMessagePublishModel.py | 647794746f6e40771a5d1c38a236f4f5e15d3d50 | [
"Apache-2.0"
] | permissive | alipay/alipay-sdk-python-all | 8bd20882852ffeb70a6e929038bf88ff1d1eff1c | 1fad300587c9e7e099747305ba9077d4cd7afde9 | refs/heads/master | 2023-08-27T21:35:01.778771 | 2023-08-23T07:12:26 | 2023-08-23T07:12:26 | 133,338,689 | 247 | 70 | Apache-2.0 | 2023-04-25T04:54:02 | 2018-05-14T09:40:54 | Python | UTF-8 | Python | false | false | 1,407 | py | AnttechBlockchainFinanceMylogisticfinsandboxMessagePublishModel.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.constant.ParamConstants import *
class AnttechBlockchainFinanceMylogisticfinsandboxMessagePublishModel(object):
def __init__(self):
self._data = None
self._method_name = None
@property
def data(self):
... |
0351f7b4a49a6d6e2e704c2d64c6a8dbdc1851e5 | 10ddfb2d43a8ec5d47ce35dc0b8acf4fd58dea94 | /Python/zigzag-iterator.py | be5a5f605f7cdc07c187237a2b0f1b59b2b83390 | [
"MIT"
] | permissive | kamyu104/LeetCode-Solutions | f54822059405ef4df737d2e9898b024f051fd525 | 4dc4e6642dc92f1983c13564cc0fd99917cab358 | refs/heads/master | 2023-09-02T13:48:26.830566 | 2023-08-28T10:11:12 | 2023-08-28T10:11:12 | 152,631,182 | 4,549 | 1,651 | MIT | 2023-05-31T06:10:33 | 2018-10-11T17:38:35 | C++ | UTF-8 | Python | false | false | 602 | py | zigzag-iterator.py | # Time: O(n)
# Space: O(k)
import collections
class ZigzagIterator(object):
def __init__(self, v1, v2):
"""
Initialize your q structure here.
:type v1: List[int]
:type v2: List[int]
"""
self.q = collections.deque([(len(v), iter(v)) for v in (v1, v2) if v])
d... |
b4c61a030962d37fbf215d52a5dd2cb737f30ce6 | 0ba2e5061577f6286ff9265ef1df9aca96769445 | /data_structures/Graphs/graphsearch/a-star-search/python/util/path.py | 5c55f21b1290a95cef5130b8b3e79726fd4d842c | [
"CC0-1.0"
] | permissive | ZoranPandovski/al-go-rithms | 68d5d02f80a61de9baf8e50a81a52e7d0b3983a0 | 4ae6ba54e90af14af236e03e435eb0402dcac787 | refs/heads/master | 2023-09-04T16:04:04.321676 | 2023-06-06T15:22:16 | 2023-06-06T15:22:16 | 93,438,176 | 1,421 | 2,445 | CC0-1.0 | 2023-06-15T14:24:28 | 2017-06-05T19:20:20 | Jupyter Notebook | UTF-8 | Python | false | false | 501 | py | path.py |
class path:
def __init__(self,source,destination,cost):
"""
Described a path from a node to another node including its cost.
:param source: from this node
:param destination: to this node
:param cost: cost to travel the path
"""
self.source=source
se... |
516d74419fa5851971207a4fd109afb332c0ed75 | 71fb04f723b46a1bf45295be239bcec25e07f98c | /keras_cv/models/backbones/efficientnet_v1/efficientnet_v1_backbone.py | c90bebf19846f24ed9f7570504334ee848e96eb2 | [
"Apache-2.0"
] | permissive | keras-team/keras-cv | 9bca4479474e853ec3a1c541b8be20fea2447a1a | e83f229f1b7b847cd712d5cd4810097d3e06d14e | refs/heads/master | 2023-08-31T10:22:08.406394 | 2023-08-30T20:24:57 | 2023-08-30T20:24:57 | 265,079,853 | 818 | 287 | NOASSERTION | 2023-09-12T16:49:01 | 2020-05-18T22:39:21 | Python | UTF-8 | Python | false | false | 16,262 | py | efficientnet_v1_backbone.py | # Copyright 2023 The KerasCV 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in ... |
5f22a1084ea792f0b1b5fa4435811c2d7edd6552 | 4d8df3fd1c531ea93068b56218b6f9aa44fd898e | /ops/pebble.py | 8d107cb8417b423712309f41894a757ebc959c30 | [
"Apache-2.0"
] | permissive | canonical/operator | f7adb02afe5209f1dd711a6b4c25bfaedacb2d02 | c4e3266a6568ba310064ca8b9bff7adb89676224 | refs/heads/main | 2023-09-01T14:07:37.685404 | 2023-08-30T19:55:19 | 2023-08-30T19:55:19 | 212,098,176 | 226 | 109 | Apache-2.0 | 2023-08-30T19:55:20 | 2019-10-01T13:06:11 | Python | UTF-8 | Python | false | false | 102,576 | py | pebble.py | # Copyright 2021 Canonical 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 in writing, s... |
069ff7613ab55f78c90d8cedd6ab11172c358bc6 | dcfc88503e3a8df5d9083b512178d254727d1a31 | /axelrod/strategies/human.py | 190590c124a64cd65154fbe395b1f9bc3892c7b8 | [
"MIT"
] | permissive | Axelrod-Python/Axelrod | b8502822da103fbf1a56ffbc090453b95bf9f2d8 | fa748627cd4f0333bb2dbfcb1454372a78a9098a | refs/heads/dev | 2023-09-04T06:41:55.216809 | 2023-07-10T19:42:54 | 2023-07-14T02:37:16 | 30,959,449 | 673 | 289 | NOASSERTION | 2023-07-14T02:37:18 | 2015-02-18T09:37:17 | Python | UTF-8 | Python | false | false | 5,783 | py | human.py | from os import linesep
from axelrod.action import Action
from axelrod.player import Player
from prompt_toolkit import prompt
from prompt_toolkit.validation import ValidationError, Validator
try: # pragma: no cover
from prompt_toolkit.styles import style_from_dict
from prompt_toolkit.token import Token
t... |
2f465a524c9277642430f129e11bebe46281152e | fba876caecb7a55254cf92434a9a8a629ed47b93 | /apps/challenges/migrations/0088_increase_cpu_workers_and_memory.py | 8e76b06c4af1507295e39890fc81bcb3a9d328f2 | [
"BSD-3-Clause"
] | permissive | Cloud-CV/EvalAI | f6eb96509f679cb5765fd4b4a49e5b3f5a5551d6 | 7e3485f2f3c77b146b72cbbc8de1b15bf0dfe0db | refs/heads/master | 2023-09-04T05:03:59.087293 | 2023-08-30T19:26:13 | 2023-08-30T19:26:13 | 71,516,397 | 1,722 | 983 | NOASSERTION | 2023-09-07T18:02:48 | 2016-10-21T00:51:45 | Python | UTF-8 | Python | false | false | 633 | py | 0088_increase_cpu_workers_and_memory.py | # Generated by Django 2.2.20 on 2022-10-04 16:59
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('challenges', '0087_add_cpu_only_code_upload_job_configs'),
]
operations = [
migrations.AlterField(
model_name='challenge',
... |
c593b28bc230b025e173b05c11b1df465518fe01 | 0010b3d8b8f806d6065e1bb1aa3c18f9714001a7 | /devel/external/AEGIS/clean_pstamp.py | 3464e65b670c1fdab4de97f8e60e34101b53db8c | [
"BSD-3-Clause",
"BSD-2-Clause"
] | permissive | GalSim-developers/GalSim | bfd2d5e57f20874ad81bc735195c5c62efad63eb | f1c0319600cc713373f1cea7459171fbf388848e | refs/heads/main | 2023-08-17T07:30:44.583679 | 2023-08-15T02:52:00 | 2023-08-15T02:52:00 | 3,510,804 | 194 | 104 | NOASSERTION | 2023-09-12T04:03:38 | 2012-02-22T02:51:45 | Python | UTF-8 | Python | false | false | 14,430 | py | clean_pstamp.py | # Copyright (c) 2012-2022 by the GalSim developers team on GitHub
# https://github.com/GalSim-developers
#
# This file is part of GalSim: The modular galaxy image simulation toolkit.
# https://github.com/GalSim-developers/GalSim
#
# GalSim is free software: redistribution and use in source and binary forms,
# with or w... |
3ae0a9c81d9544017696839e48329889a285259d | 085cf6512c946d615eda58a3a0d353c0aa1db8cf | /deepfence_backend/api/license_api.py | 4d4a63386098ed2be4c817509ddb54d819cc8c46 | [
"Apache-2.0"
] | permissive | deepfence/ThreatMapper | 00c38c65ed2f014004c9818f03d5e129496b4dd8 | 748b0c8782507eaf351625b9c9fad46903ad6237 | refs/heads/main | 2023-08-31T11:13:53.813651 | 2023-03-02T00:49:57 | 2023-03-02T00:49:57 | 238,662,977 | 4,540 | 481 | Apache-2.0 | 2023-09-14T13:24:37 | 2020-02-06T10:30:09 | TypeScript | UTF-8 | Python | false | false | 439 | py | license_api.py | from flask import Blueprint
from utils.common import get_eula_text
from utils.response import set_response
license_api = Blueprint("license_api", __name__)
@license_api.route("/eula", methods=["GET"])
def eula():
"""
Eula
Permission: ALL
---
tags:
- LICENSE API
responses:
200:
... |
a98d0d1130bcc15b652e5bfd73957c4a7b6b46e8 | 0ff5c3178e87a28a82165bfa908d9319cf7a2323 | /04. Arrays/ArrayPractice.py | 007afc81752e2338ec5d1764415a64e6876205b1 | [
"MIT"
] | permissive | SR-Sunny-Raj/Hacktoberfest2021-DSA | 40bf8385ed976fd81d27340514579b283c339c1f | 116526c093ed1ac7907483d001859df63c902cb3 | refs/heads/master | 2023-01-31T07:46:26.016367 | 2023-01-26T12:45:32 | 2023-01-26T12:45:32 | 262,236,251 | 261 | 963 | MIT | 2023-03-25T14:22:10 | 2020-05-08T05:36:07 | C++ | UTF-8 | Python | false | false | 1,828 | py | ArrayPractice.py | from array import *
# 1. Create an array and traverse.
my_array = array('i', [1, 2, 3, 4, 5])
for i in my_array:
print(i)
# 2. Access individual elements through indexes
print("Step 2")
print(my_array[3])
# 3. Append any value to the array using append() method
print("Step 3")
my_array.append(6)
print(my_arr... |
23fffc3686be0dfed265369261d8f6ea53737872 | 476c989bfda64cbb23d36d7056aabe6474f49361 | /glazier/lib/actions/base.py | 0dd4d8aeaaec081bc6d1b8dc38826adf617dbfe4 | [
"Apache-2.0"
] | permissive | google/glazier | 77f41697a449708490252a4831f7e87a3f4bb2bd | ec44cb163f54d1393b0a2c2730d5d0d9d0fc8515 | refs/heads/master | 2023-09-03T22:23:55.657479 | 2023-08-30T16:37:43 | 2023-08-30T16:38:16 | 79,817,356 | 1,311 | 116 | Apache-2.0 | 2023-09-12T20:14:24 | 2017-01-23T15:30:21 | Python | UTF-8 | Python | false | false | 2,523 | py | base.py | # Copyright 2016 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or ag... |
e163b8b452b12667c5d396008247f88478fb3284 | 0f11518fb0210b6f95ef1ab322396949dd46b574 | /linkedin_api/client.py | 188d563fb4c44cb6a3c28073fdb23dc877ce584d | [
"MIT"
] | permissive | tomquirk/linkedin-api | e46d2d8c35dbc36e8c91968b12c34ff67b438fd7 | 5273fdfd4845b3eab588c08063a96f4910b560f5 | refs/heads/master | 2023-09-03T18:14:19.123363 | 2023-08-12T22:46:30 | 2023-08-12T22:46:30 | 137,201,683 | 1,310 | 369 | MIT | 2023-09-07T14:38:46 | 2018-06-13T10:40:56 | Python | UTF-8 | Python | false | false | 5,653 | py | client.py | import requests
import logging
from linkedin_api.cookie_repository import CookieRepository
from bs4 import BeautifulSoup
import json
logger = logging.getLogger(__name__)
class ChallengeException(Exception):
pass
class UnauthorizedException(Exception):
pass
class Client(object):
"""
Class to act a... |
62102abdd9b3bff3d2243e05e880b62bd99dfb38 | 6c9e1a5139ca56b7a5df7d1e7cc7ce4f60e1c8af | /histomicstk/preprocessing/color_deconvolution/complement_stain_matrix.py | 7e81f5ebba2dfc69240c071098aef9a7ed7cc946 | [
"LicenseRef-scancode-warranty-disclaimer",
"Apache-2.0"
] | permissive | DigitalSlideArchive/HistomicsTK | 251b016066144fbad3efb2065993d7981265ab04 | c03c852e72f1497d22535c6b7d5aba25c74e620d | refs/heads/master | 2023-08-31T02:32:13.773082 | 2023-08-30T20:40:45 | 2023-08-30T20:40:45 | 44,324,447 | 351 | 125 | Apache-2.0 | 2023-09-13T12:24:13 | 2015-10-15T14:49:21 | Python | UTF-8 | Python | false | false | 844 | py | complement_stain_matrix.py | import numpy as np
def complement_stain_matrix(w):
"""Generates a complemented stain matrix
Used to fill out empty columns of a stain matrix for use with
color_deconvolution. Replaces right-most column with normalized
cross-product of first two columns.
Parameters
----------
w : array_lik... |
402d45efe1714d58b8bcef30e2bda37265b35567 | 1b32a80362ce9c2d8f0eb1948637c6599d85aa99 | /tests/activations_test.py | d7dfe6ec439aff882e0d91d75c23572bd0fec2bd | [
"MIT"
] | permissive | szymonmaszke/torchlayers | 4492c628a49f4db30a76a17b5d38591a85109964 | 1eff7c55fdb3733e0acc180be79354ed35e4167c | refs/heads/master | 2022-07-06T18:02:48.567112 | 2021-05-25T13:58:50 | 2022-06-13T19:09:28 | 201,987,932 | 599 | 47 | MIT | 2022-06-13T19:09:29 | 2019-08-12T18:35:56 | Python | UTF-8 | Python | false | false | 358 | py | activations_test.py | import torch
import pytest
import torchlayers as tl
@pytest.mark.parametrize("klass", ("Swish", "HardSwish", "HardSigmoid"))
def test_object(klass):
getattr(tl, klass)()(torch.randn(4, 5, 6))
@pytest.mark.parametrize("function", ("swish", "hard_swish", "hard_sigmoid"))
def test_functional(function):
getatt... |
f70fbf384bfe7aed1698742cef7b95d9722f6f4a | 3395a234e7c80d011607e79c49cd48bf516f256b | /dependencies/jedi/third_party/typeshed/third_party/2and3/google/protobuf/internal/enum_type_wrapper.pyi | 174002d7a414ff7ebd1a62f203098e29ac329ca3 | [
"MIT",
"Apache-2.0"
] | permissive | srusskih/SublimeJEDI | 67329b72e184bc9584843968dcc534a002c797a1 | 95c185d778425c04536d53517b0e3fe6dedf8e59 | refs/heads/master | 2023-08-24T11:30:37.801834 | 2022-08-30T09:04:17 | 2022-08-30T09:04:17 | 6,241,108 | 669 | 125 | MIT | 2022-08-30T09:04:18 | 2012-10-16T08:23:57 | Python | UTF-8 | Python | false | false | 357 | pyi | enum_type_wrapper.pyi | from typing import Any, List, Tuple
class EnumTypeWrapper(object):
def __init__(self, enum_type: Any) -> None: ...
def Name(self, number: int) -> bytes: ...
def Value(self, name: bytes) -> int: ...
def keys(self) -> List[bytes]: ...
def values(self) -> List[int]: ...
@classmethod
def items(... |
815f11839860ee0dc44d941354b4e92278f66312 | bb33e6be8316f35decbb2b81badf2b6dcf7df515 | /source/res/scripts/client/gui/Scaleform/daapi/view/lobby/event_boards/event_boards_vehicles_overlay.py | 121d937bf4ccc86065e5a30001d650016bdc3ca7 | [] | no_license | StranikS-Scan/WorldOfTanks-Decompiled | 999c9567de38c32c760ab72c21c00ea7bc20990c | d2fe9c195825ececc728e87a02983908b7ea9199 | refs/heads/1.18 | 2023-08-25T17:39:27.718097 | 2022-09-22T06:49:44 | 2022-09-22T06:49:44 | 148,696,315 | 103 | 39 | null | 2022-09-14T17:50:03 | 2018-09-13T20:49:11 | Python | UTF-8 | Python | false | false | 4,391 | py | event_boards_vehicles_overlay.py | # Python bytecode 2.7 (decompiled from Python 2.7)
# Embedded file name: scripts/client/gui/Scaleform/daapi/view/lobby/event_boards/event_boards_vehicles_overlay.py
from gui.Scaleform.daapi.view.lobby.event_boards.event_boards_vos import makeFiltersVO, makeVehicleVO
from gui.Scaleform.daapi.view.lobby.event_boards.even... |
27aa88ff150b6544be43326a0e3aeed001a34bc2 | f80ef3a3cf859b13e8af8433af549b6b1043bf6e | /pyobjc-framework-Photos/PyObjCTest/test_phcloudidentifier.py | f5a1fcf03363419f3684b0624049117985239ac8 | [
"MIT"
] | permissive | ronaldoussoren/pyobjc | 29dc9ca0af838a56105a9ddd62fb38ec415f0b86 | 77b98382e52818690449111cd2e23cd469b53cf5 | refs/heads/master | 2023-09-01T05:15:21.814504 | 2023-06-13T20:00:17 | 2023-06-13T20:00:17 | 243,933,900 | 439 | 49 | null | 2023-06-25T02:49:07 | 2020-02-29T08:43:12 | Python | UTF-8 | Python | false | false | 239 | py | test_phcloudidentifier.py | from PyObjCTools.TestSupport import TestCase, min_os_level
import Photos
class TestPHCloudIdentifier(TestCase):
@min_os_level("10.13")
def testConstants(self):
self.assertIsInstance(Photos.PHLocalIdentifierNotFound, str)
|
983b207ecd1646edb8d4bdec8c7fdd16ee7f046b | 96dcea595e7c16cec07b3f649afd65f3660a0bad | /homeassistant/components/amcrest/binary_sensor.py | e71a5cda538ba342cfbc5996ddbb9d85a2a2c67a | [
"Apache-2.0"
] | permissive | home-assistant/core | 3455eac2e9d925c92d30178643b1aaccf3a6484f | 80caeafcb5b6e2f9da192d0ea6dd1a5b8244b743 | refs/heads/dev | 2023-08-31T15:41:06.299469 | 2023-08-31T14:50:53 | 2023-08-31T14:50:53 | 12,888,993 | 35,501 | 20,617 | Apache-2.0 | 2023-09-14T21:50:15 | 2013-09-17T07:29:48 | Python | UTF-8 | Python | false | false | 9,656 | py | binary_sensor.py | """Support for Amcrest IP camera binary sensors."""
from __future__ import annotations
from contextlib import suppress
from dataclasses import dataclass
from datetime import timedelta
import logging
from typing import TYPE_CHECKING
from amcrest import AmcrestError
import voluptuous as vol
from homeassistant.componen... |
e5f879e0cbd792430e5b4b5ee1419b33dfb08ba5 | 41e1fe34d19118e85640f4174828bfc1aaf2f060 | /examples/datavault2-bigdata-example/dags/acme/hooks/file_hook.py | 6e1d00c7a236bddf45f499fba3241fd28b724b87 | [] | no_license | gtoonstra/etl-with-airflow | 1da72e03ba581190790df6db0d85ec989e9e8070 | 1e069daf9db13de6850c9b25d673742cbcc5c207 | refs/heads/master | 2022-09-08T07:48:12.528587 | 2021-11-27T10:35:15 | 2021-11-27T10:35:15 | 71,038,701 | 1,270 | 294 | null | 2022-08-11T21:15:35 | 2016-10-16T08:31:14 | Shell | UTF-8 | Python | false | false | 1,563 | py | file_hook.py | # -*- coding: utf-8 -*-
#
# 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, software
... |
0aca0497ce4f1b9e4ca83fb86876ef29cc963f7f | 6bbbb8237c93f9b1f302010a65d6ecb6f286f23b | /websauna/tests/crud/test_autoform.py | 3086f5b214091ebc777e247c23cdd7563f1d7d9c | [
"MIT",
"Apache-2.0"
] | permissive | websauna/websauna | ea60d5a6aef59b3725bace0d188dacea72574e63 | a57de54fb8a3fae859f24f373f0292e1e4b3c344 | refs/heads/master | 2023-08-07T08:16:51.664340 | 2020-06-06T19:28:18 | 2020-06-06T19:28:18 | 49,773,298 | 294 | 74 | NOASSERTION | 2020-12-30T01:48:27 | 2016-01-16T12:55:54 | Python | UTF-8 | Python | false | false | 8,695 | py | test_autoform.py | """Test form autogeneration and CRUD."""
# Standard Library
import time
# Pyramid
import transaction
import pytest
from splinter.driver import DriverAPI
# Websauna
import websauna
from websauna.tests.test_utils import create_logged_in_user
from websauna.tests.webserver import customized_web_server
from websauna.util... |
e0501edd6f5df994fb67f8e616a43f1ee677020a | 02bde3948681b41ab5b94553cc87ca2bfd38f159 | /src/embedding/faces/download_img_use_gevent.py | 2ca56272d73a8520684c838e7b3e99b7ddca9cd4 | [
"MIT"
] | permissive | SharpAI/DeepCamera | 84829f615a9fe6e3e3d67cb96b3143304ecbad59 | 6375e7c7cfda90345e9182214e9208a42b5254a7 | refs/heads/master | 2023-06-18T05:07:19.163001 | 2023-01-18T18:03:19 | 2023-01-18T18:03:19 | 173,961,960 | 1,548 | 244 | MIT | 2022-10-07T18:23:20 | 2019-03-05T14:29:23 | JavaScript | UTF-8 | Python | false | false | 1,504 | py | download_img_use_gevent.py | # coding=utf-8
# gevent协程批量下载sqlite保存的url
from gevent import monkey; monkey.patch_all()
import gevent
import urllib2
import os
import Image
from models import TrainSet
img_dir = 'face_dataset'
# dataset = TrainSet.query.all() # 查询所有行,是一个list
dataset_is = TrainSet.query.filter_by(is_or_isnot=True).all()
# dataset_isn... |
fc8d497d30b1ae9eba694d82e328b9ebcf6147ac | b964ac1b4c25dff0c45807f7132d64c941845d78 | /lyrebird/examples/checkers/img_size.py | 190c355f5feb264b246935918737ebc43785e42b | [
"MIT"
] | permissive | Meituan-Dianping/lyrebird | 6db7fe3be32d74565bbcaa0491f03dc72d506214 | b1ec5b081660c63e696454b63dd2f3c2b93a85d9 | refs/heads/master | 2023-08-25T14:44:01.580972 | 2023-08-23T10:04:00 | 2023-08-23T10:04:00 | 140,687,246 | 963 | 175 | MIT | 2023-09-11T09:10:58 | 2018-07-12T08:50:59 | Python | UTF-8 | Python | false | false | 1,509 | py | img_size.py | """
checker example
steps:
- ignore unexepcted object
- prepare useful info
- check data
Info used in channel flow
├── name
└─┬ flow
├── size
├─┬ request
│ └── url
└─┬ response
└─┬ headers
└── Content-Type
"""
from lyrebird import event
from decimal import Decimal
from lyrebird.checker import Ext... |
4485dadb926fce298a331eb8b279b944aef167d0 | 8cc3498e311d15c9a4394aaa341ef489b482dbe6 | /test/language/templates/python/InstantiateTypeAsChoiceFieldTest.py | 8b78451a8f8f7c243ba615d31d5815bd34367abe | [
"BSD-3-Clause"
] | permissive | ndsev/zserio | 3e55c064f72e86219a6da297f116d3dbb565a9a9 | c540c4a97fee4e08bfc6669a2cec0d2b8282d8f6 | refs/heads/master | 2023-08-24T14:56:10.750155 | 2023-08-11T19:36:54 | 2023-08-11T19:36:54 | 141,550,444 | 113 | 23 | BSD-3-Clause | 2023-08-30T11:14:47 | 2018-07-19T08:44:23 | Java | UTF-8 | Python | false | false | 838 | py | InstantiateTypeAsChoiceFieldTest.py | import unittest
import zserio
from testutils import getZserioApi
class InstantiateTypeAsChoiceFieldTest(unittest.TestCase):
@classmethod
def setUpClass(cls):
cls.api = getZserioApi(__file__, "templates.zs").instantiate_type_as_choice_field
def testReadWrite(self):
instantiateTypeAsChoiceF... |
9994ce7e36e3c6252f6ac9e53e8e804cefa892d2 | b347bc4b850dee4a8a9a171b563a3f31230ce1c7 | /sktime/transformations/series/detrend/tests/__init__.py | b523411f9beb03e097950808a5009030ff0ef689 | [
"BSD-3-Clause"
] | permissive | sktime/sktime | 5963962df338c5931a2f9f1794d1203c50ddc27e | 70b2bfaaa597eb31bc3a1032366dcc0e1f4c8a9f | refs/heads/main | 2023-08-22T18:20:08.022950 | 2023-08-22T15:24:39 | 2023-08-22T15:24:39 | 156,401,841 | 1,117 | 268 | BSD-3-Clause | 2023-09-14T20:44:21 | 2018-11-06T15:08:24 | Python | UTF-8 | Python | false | false | 126 | py | __init__.py | """Tests for detrenders."""
# copyright: sktime developers, BSD-3-Clause License (see LICENSE file)
__author__ = ["mloning"]
|
c378f7ccc6c25518ad4540087e83fe63bbcf9f29 | 4c800425b941243c521f0a878c1b12a8f5a50585 | /examples/custom_parameterized_image_label_loss.py | c107adc216ef96fd0159a8dc502cafd1ea43f6d7 | [
"Apache-2.0"
] | permissive | DeepRegNet/DeepReg | f7af4554c89a7a40a53bac9f7fc9939402d1110d | 650a2f1a88ad3c6932be305d6a98a36e26feedc6 | refs/heads/main | 2023-04-06T20:40:38.722315 | 2022-05-18T21:52:19 | 2022-05-18T21:52:19 | 269,365,590 | 509 | 78 | Apache-2.0 | 2023-03-11T12:18:21 | 2020-06-04T13:21:37 | Python | UTF-8 | Python | false | false | 1,439 | py | custom_parameterized_image_label_loss.py | """This script provides an example of using custom backbone for training."""
import tensorflow as tf
from deepreg.registry import REGISTRY
from deepreg.train import train
@REGISTRY.register_loss(name="lp_norm")
class LPNorm(tf.keras.losses.Loss):
"""
L^p norm between y_true and y_pred, p = 1 or 2.
y_tru... |
965c51cd9072f73d79ebc91396ea0cf2d3089239 | 84724b34b3f1e84dc53cbca5f3660590dbc34a9f | /nova/tests/functional/regressions/test_bug_1908075.py | 534163fb2bbf8e52c18170cde70591ed22193791 | [
"Apache-2.0"
] | permissive | openstack/nova | 2c24b64e3677595611715bae6dda14edd3f90a24 | 065c5906d2da3e2bb6eeb3a7a15d4cd8d98b35e9 | refs/heads/master | 2023-08-28T15:10:05.126314 | 2023-08-25T20:31:27 | 2023-08-25T20:31:27 | 790,031 | 2,287 | 2,320 | Apache-2.0 | 2023-07-08T02:10:29 | 2010-07-22T02:04:27 | Python | UTF-8 | Python | false | false | 3,834 | py | test_bug_1908075.py | # Copyright 2020, Red Hat, 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 ... |
e6105d7e69ca18b35068036699173cf818fbbbd2 | c5ddaaa915829e946762f83a610a3ef43ad1f190 | /tests/data/src/pep518_with_extra_and_markers-1.0/setup.py | bfac5b46783d51451a3861b726fd93b4a77f4702 | [
"MIT"
] | permissive | pypa/pip | 4cebef8b5e8f69921a4cbd37d5b2021fd3200a16 | 0778c1c153da7da457b56df55fb77cbba08dfb0c | refs/heads/main | 2023-08-15T01:51:24.039937 | 2023-08-14T06:22:21 | 2023-08-14T06:22:21 | 1,446,467 | 8,612 | 3,321 | MIT | 2023-09-12T07:08:11 | 2011-03-06T14:30:46 | Python | UTF-8 | Python | false | false | 283 | py | setup.py | #!/usr/bin/env python
from setuptools import setup
# ensure dependencies are installed
import simple
import simplewheel
assert simplewheel.__version__ == "2.0"
setup(
name="pep518_with_extra_and_markers",
version="1.0",
py_modules=["pep518_with_extra_and_markers"],
)
|
e4208a778c3057198833b0c87baab627ff5c981c | 8adef741528ac0af5777fd80dbf37a5350da86b1 | /demos/chat-server/apps/app/app.py | 0a8281275709f6b4bf8ea5431e2ca9976d306924 | [
"Apache-2.0"
] | permissive | wecatch/app-turbo | 5ff3a1bfa33febd9b24afa0a7e5b2ab71d00c138 | 809c6fdc54fac18441b1d7730ed2c7c75344d705 | refs/heads/master | 2022-11-23T12:32:56.660264 | 2022-11-19T03:56:46 | 2022-11-19T03:56:46 | 25,961,303 | 159 | 25 | null | 2017-01-15T06:00:20 | 2014-10-30T08:24:27 | Python | UTF-8 | Python | false | false | 1,620 | py | app.py | # -*- coding:utf-8 -*-
import os.path
import uuid
import tornado.escape
import tornado.web
from tornado import gen
import turbo.log
from turbo.flux import state as turbo_state
from . import base
BaseHandler = base.BaseHandler
logger = turbo.log.getLogger(__file__)
global_message_buffer = turbo_state.chat.message... |
1032b2868347ef20cebb4a239f8d62907bb97c06 | 483424524c70852cc043e0d77bf1b757a61d797a | /deepspeed/ops/lamb/fused_lamb.py | 6ccd9d4c6b066601bb2f6e5d8d8def6be09fd22b | [
"Apache-2.0",
"LicenseRef-scancode-generic-cla"
] | permissive | microsoft/DeepSpeed | 810f1af320020718d0794f5a97cde6f1d17af122 | 55d9964c59c0c6e23158b5789a5c36c28939a7b0 | refs/heads/master | 2023-09-06T07:40:52.145692 | 2023-09-05T23:51:23 | 2023-09-05T23:51:23 | 235,860,204 | 27,557 | 3,347 | Apache-2.0 | 2023-09-14T21:38:46 | 2020-01-23T18:35:18 | Python | UTF-8 | Python | false | false | 7,815 | py | fused_lamb.py | # Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: Apache-2.0
# DeepSpeed Team
"""
Copyright NVIDIA/apex
This file is adapted from NVIDIA/apex/optimizer/fused_adam and implements the LAMB optimizer
"""
import types
import torch
from deepspeed.ops.op_builder import FusedLambBuilder
class FusedLamb(torc... |
f573cf2024d885c6aefeb435b4760b3e1d1f548f | 86948ff50c9355062e55b1f6a41029685270b76c | /hyptorch/pmath.py | 92e95a7db65c439dfb412b062cc1acbe94c224d0 | [
"MIT"
] | permissive | leymir/hyperbolic-image-embeddings | c56d0049a190d6e12f83de9e0c65742dd9badbdb | 6633edbbeffd6d90271f0963852a046c64f407d6 | refs/heads/master | 2022-01-29T13:35:04.796969 | 2022-01-12T13:15:29 | 2022-01-12T13:15:29 | 178,893,711 | 233 | 42 | MIT | 2020-06-13T20:36:55 | 2019-04-01T15:34:48 | Python | UTF-8 | Python | false | false | 13,616 | py | pmath.py | """
Implementation of various mathematical operations in the Poincare ball model of hyperbolic space. Some
functions are based on the implementation in https://github.com/geoopt/geoopt (copyright by Maxim Kochurov).
"""
import numpy as np
import torch
from scipy.special import gamma
def tanh(x, clamp=15):
return... |
ef2e6cdf64f9a662ac36b0536ddd97552d3cbb7c | 4b2aa092c09094c872f855ecba9b25c12e08d010 | /pyprof/examples/jit/jit_script_function.py | d3dbf9bb05ad0a07019ed38babc369842258eaa8 | [
"Apache-2.0"
] | permissive | NVIDIA/PyProf | 46aaaa867f3773a20546fcdeafba7772d060f248 | 218dcc183bf7fdf97dbfc648878a3d09aea3b199 | refs/heads/main | 2023-09-04T00:00:41.542539 | 2021-05-14T14:40:29 | 2021-05-14T16:44:27 | 245,519,329 | 461 | 44 | Apache-2.0 | 2022-10-24T20:06:13 | 2020-03-06T21:24:44 | Python | UTF-8 | Python | false | false | 1,258 | py | jit_script_function.py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (c) 2020, NVIDIA CORPORATION. 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/li... |
298a5dd1722ad6daf25215235d5334c55440f68a | 3a50c0712e0a31b88d0a5e80a0c01dbefc6a6e75 | /thrift/compiler/test/fixtures/nolegacy/gen-py3/test/fixtures/nolegacy/module/builders.pyi | d8ecb5febe23379b9e109955bd662ff1c65bae78 | [
"Apache-2.0"
] | permissive | facebook/fbthrift | 3b7b94a533666c965ce69cfd6054041218b1ea6f | 53cf6f138a7648efe5aef9a263aabed3d282df91 | refs/heads/main | 2023-08-24T12:51:32.367985 | 2023-08-24T08:28:35 | 2023-08-24T08:28:35 | 11,131,631 | 2,347 | 666 | Apache-2.0 | 2023-09-01T01:44:39 | 2013-07-02T18:15:51 | C++ | UTF-8 | Python | false | false | 1,234 | pyi | builders.pyi | #
# Autogenerated by Thrift
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
# @generated
#
import typing as _typing
import folly.iobuf as _fbthrift_iobuf
import thrift.py3.builder
import test.fixtures.nolegacy.module.types as _test_fixtures_nolegacy_module_types
class TestError_Builder(thrif... |
85574d3a9dab7cafa7ec26d04ca510ba66ddc283 | be815aacbd7b06ac0ce3f412831639aa0297b988 | /deploy/docker/cp-node-reporter/stats/reporter.py | ec8f83187af50447f155e1f4664a3dc77e8d0ee1 | [
"Apache-2.0"
] | permissive | epam/cloud-pipeline | 8a861dae60d0f86089ff55e2f278e8593fc5e112 | 570dd898e96de931b96e584c86e72296b0e40607 | refs/heads/develop | 2023-08-30T08:03:18.672866 | 2023-08-29T17:07:13 | 2023-08-29T17:07:13 | 174,065,041 | 155 | 73 | Apache-2.0 | 2023-09-14T13:36:36 | 2019-03-06T03:34:40 | Java | UTF-8 | Python | false | false | 5,861 | py | reporter.py | # Copyright 2017-2022 EPAM Systems, Inc. (https://www.epam.com/)
#
# 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 appli... |
be01aa4b5320c24c36554aca7188f564e6385216 | aae3c6fccb2296e4da5bb10310f5dd6baba8b7de | /activitysim/cli/benchmark.py | af46766aaf565908d77b042407f1a625fba7f20d | [
"BSD-3-Clause"
] | permissive | ActivitySim/activitysim | 3d938e616452be76db1bb0c8a1212e12b9216823 | a8e755f96d0e32633a6d3657c4878e3b6a37e59a | refs/heads/main | 2023-08-08T16:02:06.275693 | 2023-05-09T13:08:23 | 2023-05-09T13:08:23 | 20,981,950 | 118 | 89 | BSD-3-Clause | 2023-07-25T14:07:16 | 2014-06-18T23:57:40 | Jupyter Notebook | UTF-8 | Python | false | false | 9,807 | py | benchmark.py | import json
import os
import shutil
import subprocess
import sys
ASV_CONFIG = {
# The version of the config file format. Do not change, unless
# you know what you are doing.
"version": 1,
# The name of the project being benchmarked
"project": "activitysim",
# The project's homepage
"projec... |
4fa0a58125dae241cc9b8d3743a4738865129dc4 | e0cc314aa73c0a965a2022f19900df3ccc8c9f43 | /windows/winobject/device_manager.py | 72d905f7aa2b48b13286d54fde26c10add72c05b | [
"BSD-3-Clause"
] | permissive | hakril/PythonForWindows | 21823e743ee4ae7ff99e376378357833f2e19d26 | 82d0c5cc5c9b4d569dca2c755f26b947e3ff74f5 | refs/heads/master | 2023-06-08T03:25:50.354768 | 2023-05-26T07:31:06 | 2023-05-26T07:31:06 | 49,235,784 | 568 | 111 | BSD-3-Clause | 2023-01-30T12:04:03 | 2016-01-07T22:54:33 | Python | UTF-8 | Python | false | false | 19,645 | py | device_manager.py | import ctypes
import itertools
import windows
from windows import winproxy
import windows.generated_def as gdef
from windows.security import SecurityDescriptor
from windows.utils import fixedproperty
class DeviceManager(object):
"""Represent the device manager"""
@property
def classes(self):
""... |
804b847b7e03cf8ceb11e3a8b89eb85f763655b0 | 03a7f7a7eb8c16b537b65ec21f465bb0335bc3b8 | /pythran/tests/cases/zero.py | e3dba86ead2a2fa7e3490bb979c117e981c76230 | [
"LicenseRef-scancode-unknown-license-reference",
"BSD-3-Clause"
] | permissive | serge-sans-paille/pythran | a0e22af1ac5e1f34f3f29dce36502f4a897b5186 | d8ab07b4b3b690f50603cb4d08ba303d3af18b90 | refs/heads/master | 2023-09-01T16:04:03.289285 | 2023-08-30T09:13:58 | 2023-08-31T08:03:22 | 4,479,494 | 1,882 | 200 | BSD-3-Clause | 2023-09-06T20:08:10 | 2012-05-29T08:02:14 | C++ | UTF-8 | Python | false | false | 142 | py | zero.py | #pythran export zero(int, int)
#runas zero(10,20)
#bench zero(6000,6000)
def zero(n,m): return [[0 for row in range(n)] for col in range(m)]
|
6d6f46316a480ce8653fdf15c2fb23fdf2889c0d | 4e0a88e163d97d873d8d7e58465502c87bc86054 | /tests/test_quality.py | 6b631822684d895758b381fa7c1c0cfba0cc2d72 | [
"Apache-2.0"
] | permissive | HLasse/TextDescriptives | ac70f320de86d227efc0d896f1990de9dde4710a | d73d25fe181975a66584e9d4255e42fa556ffdc9 | refs/heads/main | 2023-08-25T00:13:33.965333 | 2023-08-22T07:28:40 | 2023-08-22T07:28:40 | 236,710,916 | 231 | 19 | Apache-2.0 | 2023-09-12T09:03:00 | 2020-01-28T10:37:59 | Python | UTF-8 | Python | false | false | 9,305 | py | test_quality.py | """ Tests for the quality module."""
from typing import List, Tuple
import pytest
import spacy
import textdescriptives as td
from textdescriptives.components.quality import (
alpha_ratio,
duplicate_ngram_fraction,
mean_word_length,
n_stop_words,
oov_ratio,
proportion_bullet_points,
propor... |
ffcde84ad1fd54b47f8d68485dc5e3ad96043250 | 975b2d421d3661e6770b601929d5f11d981d8985 | /msgraph/generated/models/operation.py | 6529bddb19c584a45c02036fb309e5a79886052f | [
"MIT"
] | permissive | microsoftgraph/msgraph-sdk-python | a7c551b85daadeebf76ec4ae12668664ea639b42 | 27de7ccbe688d7614b2f6bde0fdbcda4bc5cc949 | refs/heads/main | 2023-09-03T21:45:27.989672 | 2023-08-31T06:22:18 | 2023-08-31T06:22:18 | 534,665,999 | 135 | 18 | MIT | 2023-09-14T11:04:11 | 2022-09-09T14:00:17 | Python | UTF-8 | Python | false | false | 3,287 | py | operation.py | from __future__ import annotations
import datetime
from dataclasses import dataclass, field
from kiota_abstractions.serialization import Parsable, ParseNode, SerializationWriter
from typing import Any, Callable, Dict, List, Optional, TYPE_CHECKING, Union
if TYPE_CHECKING:
from .entity import Entity
from .oneno... |
e403b42397ce2716bfe0d42c31059b6c37016419 | e90bf4b372da78ceec15282d060b48d18ba8d4e9 | /supervisor/plugins/audio.py | 558d5fa930436177637417ce50916fb7f9eab8c4 | [
"Apache-2.0"
] | permissive | home-assistant/supervisor | 67f2e1755ff5fbf7cf2084351e1c32c6995274e0 | 4838b280adafed0997f32e021274b531178386cd | refs/heads/main | 2023-08-31T22:51:25.949277 | 2023-08-31T08:01:42 | 2023-08-31T08:01:42 | 84,926,758 | 928 | 477 | Apache-2.0 | 2023-09-14T17:11:27 | 2017-03-14T08:54:15 | Python | UTF-8 | Python | false | false | 7,585 | py | audio.py | """Home Assistant audio plugin.
Code: https://github.com/home-assistant/plugin-audio
"""
import asyncio
from contextlib import suppress
import logging
from pathlib import Path, PurePath
import shutil
from awesomeversion import AwesomeVersion
import jinja2
from ..const import LogLevel
from ..coresys import CoreSys
fr... |
30436dce7ef17d2ca5c349a22e648f4f081c0a0c | 72293b4650b92019f9c046133f7de13ea6f69644 | /zulip/integrations/codebase/zulip_codebase_config.py | 5ea2ed2cb5ba28c0532e79709a2fe1cc36d5b024 | [
"Apache-2.0",
"LicenseRef-scancode-free-unknown"
] | permissive | zulip/python-zulip-api | 820978c36689db4872abf21730b25ce8abb5fbcf | 35a8ff8839ac39cff0638f533fea59665cb9aff3 | refs/heads/main | 2023-09-03T14:04:46.920347 | 2023-06-12T21:03:10 | 2023-08-11T19:36:11 | 96,455,158 | 387 | 437 | Apache-2.0 | 2023-08-11T19:36:12 | 2017-07-06T17:25:46 | Python | UTF-8 | Python | false | false | 1,460 | py | zulip_codebase_config.py | from typing import Optional
# Change these values to configure authentication for your codebase account
# Note that this is the Codebase API Username, found in the Settings page
# for your account
CODEBASE_API_USERNAME = "foo@example.com"
CODEBASE_API_KEY = "1234561234567abcdef"
# The URL of your codebase setup
CODEB... |
d09adc0f93ce3f93846622563c5e1858ea5a1181 | 38fff7bdefd8d62a740d51329b50d0e1e49258bb | /infra/constants.py | e085700c9b2523e156a69dfb23a4e87e308be684 | [
"Apache-2.0"
] | permissive | google/oss-fuzz | 026384c2ada61ef68b147548e830f60730c5e738 | f0275421f84b8f80ee767fb9230134ac97cb687b | refs/heads/master | 2023-08-31T23:30:28.157702 | 2023-08-31T21:49:30 | 2023-08-31T21:49:30 | 63,809,205 | 9,438 | 2,315 | Apache-2.0 | 2023-09-14T20:32:19 | 2016-07-20T19:39:50 | Shell | UTF-8 | Python | false | false | 1,355 | py | constants.py | # Copyright 2021 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, ... |
9c625a2af2462e7b175fb241a04574f0e1d7facf | bb666509f2a6cf07058352f8df63cb58e46a0401 | /translate.py | 79f7e464f4e8ec617b2f79f9640f34e6c03cbf9f | [
"MIT"
] | permissive | gregzaal/Auto-Voice-Channels | f6d1764846ee5e17f98b413e1cbfab8c7a71b05a | 17698450c6f885ae3ee3dae059754ba72931adf6 | refs/heads/master | 2023-05-25T10:10:38.320456 | 2022-10-08T09:09:44 | 2022-10-08T09:09:44 | 237,802,209 | 208 | 189 | MIT | 2023-05-22T22:41:04 | 2020-02-02T16:44:02 | Python | UTF-8 | Python | false | false | 4,643 | py | translate.py | import unicodedata
from utils import match_case
mc = match_case
digits = {
"0": "Zero",
"1": "One",
"2": "Two",
"3": "Three",
"4": "Four",
"5": "Five",
"6": "Six",
"7": "Seven",
"8": "Eight",
"9": "Nine",
}
def uwu(s):
"""Sources:
https://github.com/QuazzyWazzy/UwU-fy... |
f1de7bd8f4c6b96b0d96e13b07c1ed653edc7a47 | c82aceed27b19578708f1aa1497a0a2e7268e891 | /modules/api/src/test/functional/tests/test_data.py | f1f545caea530e8311a661500fac217ed2080479 | [
"MPL-2.0",
"EPL-1.0",
"Apache-2.0"
] | permissive | vinyldns/vinyldns | 441ba87943db67aba61806f47d85de5c5380dd99 | ec54b1d533f744fc7777aa747b6ad4f1c46d0c3e | refs/heads/master | 2023-08-31T04:17:28.072961 | 2023-08-22T14:18:30 | 2023-08-22T14:18:30 | 142,474,323 | 353 | 134 | Apache-2.0 | 2023-09-12T20:26:47 | 2018-07-26T17:43:18 | Scala | UTF-8 | Python | false | false | 2,935 | py | test_data.py | class TestData:
A = {
"zoneId": None,
"name": "test-create-a-ok",
"type": "A",
"ttl": 100,
"account": "foo",
"records": [
{
"address": "10.1.1.1"
},
{
"address": "10.2.2.2"
}
]
... |
e9c9fe1e0bd33f79a8adddc0a408572c5326fdc9 | 0576c3c80fb2c915c7bf50ca3c6276dd6f817ebe | /parliament/statement.py | dbf8766dd39d222609585f97ffa9ae938ad62632 | [
"BSD-3-Clause"
] | permissive | duo-labs/parliament | 0852b6ea1b8f2f5340116513b201c28ad6edbdea | 57f45649f512df3302d4185ecf1ec25226006336 | refs/heads/main | 2023-08-22T10:02:16.217541 | 2023-07-06T19:38:00 | 2023-07-06T19:38:00 | 208,323,795 | 981 | 98 | BSD-3-Clause | 2023-08-07T18:56:02 | 2019-09-13T18:30:15 | Python | UTF-8 | Python | false | false | 40,728 | py | statement.py | import json
import jsoncfg
import re
from . import (
iam_definition,
is_arn_match,
is_arn_strictly_valid,
expand_action,
UnknownActionException,
UnknownPrefixException,
)
from .finding import Finding
from .misc import make_list
def is_condition_key_match(document_key, str):
"""Given a doc... |
27f0e5ef9236ebce6bcf275c210edd440b315c08 | 411c40a6936ee32310014d26977e79fcc6c0092f | /setup.py | f1c3de5f0e095a5bb11389a8096ece2c6da37d82 | [
"MIT"
] | permissive | demotomohiro/remocolab | df37a4071639ee86f40cebb4f8c6ec0e2513950d | 176445b2ca07cacf3a41036cf44bb38caf2c5049 | refs/heads/master | 2022-09-30T10:57:27.578971 | 2022-09-15T10:45:49 | 2022-09-15T10:45:49 | 199,016,083 | 338 | 284 | MIT | 2021-09-22T16:00:01 | 2019-07-26T12:51:56 | Python | UTF-8 | Python | false | false | 238 | py | setup.py | from setuptools import setup
setup(
name = "remocolab.py",
version = "0.1",
py_modules = ['remocolab'],
url = "https://github.com/demotomohiro/remocolab",
author = "demotomohiro",
install_requires = ["pyngrok"]
)
|
69f9c1a98b86ee6d3290f24250d2638021cd2dc0 | 5a52ccea88f90dd4f1acc2819997fce0dd5ffb7d | /alipay/aop/api/domain/AlipayMarketingCampaignTaskQueryModel.py | 43f153756503002b2e85a232c0eed51a3373b628 | [
"Apache-2.0"
] | permissive | alipay/alipay-sdk-python-all | 8bd20882852ffeb70a6e929038bf88ff1d1eff1c | 1fad300587c9e7e099747305ba9077d4cd7afde9 | refs/heads/master | 2023-08-27T21:35:01.778771 | 2023-08-23T07:12:26 | 2023-08-23T07:12:26 | 133,338,689 | 247 | 70 | Apache-2.0 | 2023-04-25T04:54:02 | 2018-05-14T09:40:54 | Python | UTF-8 | Python | false | false | 2,710 | py | AlipayMarketingCampaignTaskQueryModel.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.constant.ParamConstants import *
class AlipayMarketingCampaignTaskQueryModel(object):
def __init__(self):
self._open_id = None
self._task_cen_id = None
self._task_ids = None
self._user_id = None
@p... |
86b3ef5d5067140b0a6f4da7ce6f3db226957f8a | 5d31f28f56b125f7e22d538a735587cfe779cd2d | /tests/handlers/test_base_handler_normalize_images.py | 2a82b712fffdfd26427ec175ec9f2f368e396e94 | [
"MIT"
] | permissive | thumbor/thumbor | c3cb0fbdbf66492d321d4d64e9bc3cb59bfbc1fa | 3e35fc024e895313d4b8c1da29286b96859ae122 | refs/heads/master | 2023-07-19T20:45:22.507924 | 2023-01-27T16:34:15 | 2023-07-14T19:02:46 | 1,488,139 | 7,641 | 839 | MIT | 2023-09-05T21:36:16 | 2011-03-16T17:30:05 | Python | UTF-8 | Python | false | false | 2,392 | py | test_base_handler_normalize_images.py | from unittest.mock import patch
from preggy import expect
from tornado.testing import gen_test
from tests.fixtures.images import default_image
from tests.handlers.test_base_handler import BaseImagingTestCase
from thumbor.config import Config
from thumbor.context import Context, ServerParameters
from thumbor.engines.p... |
1388ee21aa0c904812b99e6be7e6cba7c786ffd3 | cfb638fee5fa2cdd3149a8ea91043e6bc0808275 | /tulip/graphics.py | ae7d4d8751f4a909435fa908d413406d0f21af94 | [
"BSD-3-Clause",
"LicenseRef-scancode-warranty-disclaimer",
"BSD-2-Clause"
] | permissive | tulip-control/tulip-control | a23436a122dc317d39b0980c40f2da5740433ae5 | 83f993c2ae06aa8368e4bbba02bf52d68725e106 | refs/heads/main | 2023-08-22T14:39:02.797004 | 2022-06-23T19:40:03 | 2022-06-23T19:40:03 | 13,993,728 | 107 | 37 | BSD-3-Clause | 2023-09-06T17:29:38 | 2013-10-30T17:15:55 | Python | UTF-8 | Python | false | false | 8,245 | py | graphics.py | # Copyright (c) 2013-2014 by California Institute of Technology
# 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,... |
55c4cc73fe566ec45ee641d932140109f6923d8c | 6958f617af0c5a76304ceb1006c77bc70ca0e195 | /tests/python/test_ast_refactor.py | deab2b0310c444583ee577277492eb2691019fc8 | [
"Apache-2.0"
] | permissive | taichi-dev/taichi | 3fae315a494f1c97392d5b931c939abbbfba1bdc | b30b511f55e3d0ebff765ee048d0aaa4ba9e7667 | refs/heads/master | 2023-09-02T13:28:18.208792 | 2023-08-23T23:22:43 | 2023-08-23T23:22:43 | 74,660,642 | 17,231 | 1,841 | Apache-2.0 | 2023-09-14T11:29:32 | 2016-11-24T10:00:05 | C++ | UTF-8 | Python | false | false | 22,171 | py | test_ast_refactor.py | import sys
import numpy as np
import pytest
from taichi.lang import impl
from taichi.lang.util import has_pytorch
import taichi as ti
from tests import test_utils
if sys.version_info >= (3, 8):
# Import the test case only if the Python version is >= 3.8
from .py38_only import test_namedexpr # noqa
@test_u... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.