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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
da6aa8182c706c593f77cdfe96acc5fc18c46609 | 783bcccb13591e80b439e29782ecb977ae67c1f1 | /testing/local-binder-k8s-hub/install-jupyterhub-chart | afa9214e29efa08166d95ac50a576c52e06f3aeb | [
"LicenseRef-scancode-unknown-license-reference",
"BSD-3-Clause"
] | permissive | jupyterhub/binderhub | 3ff86c5e896e68c17c6fd000f1426837237cb186 | 84b1db907335d5e0307222fbfcb6de77a98db8a2 | refs/heads/main | 2023-08-29T14:10:35.419954 | 2023-08-02T08:28:21 | 2023-08-02T08:28:21 | 89,419,368 | 2,422 | 420 | BSD-3-Clause | 2023-09-05T09:08:40 | 2017-04-26T00:28:26 | Python | UTF-8 | Python | false | false | 2,031 | install-jupyterhub-chart | #!/usr/bin/env python3
"""
Makes a standalone installation of the JupyterHub Helm chart of the version
specified in the BinderHub Helm chart's Chart.yaml file, and use the
configuration for the JupyterHub Helm chart nested in the BinderHub helm chart's
configuration.
"""
import os
import sys
from subprocess import chec... | |
2b0d9eda0ae1291e2b6f87e3aa40e3eccc865c9d | 011ff3bff551529ce95ab0f115ea51dc02400c9e | /paystackapi/tests/test_cpanel.py | 46998a40fcf09738fa4c3f7600c0fa278d2bcd1c | [
"MIT"
] | permissive | andela-sjames/paystack-python | 05ecd5622917c4ec80f6ba7ea91a1c145a48df12 | bcc55546c6aacd6e27596f114d2ad9e6d14295af | refs/heads/master | 2023-07-09T12:49:09.898397 | 2023-06-19T13:47:44 | 2023-06-19T13:47:44 | 51,199,027 | 110 | 44 | MIT | 2023-06-28T18:14:32 | 2016-02-06T10:53:12 | Python | UTF-8 | Python | false | false | 1,241 | py | test_cpanel.py | import httpretty
from paystackapi.tests.base_test_case import BaseTestCase
from paystackapi.cpanel import ControlPanel
class TestPage(BaseTestCase):
@httpretty.activate
def test_fetch_payment_session_timeout(self):
"""Method defined to test fetch payment session timeout."""
httpretty.registe... |
55099eac6337caee301840f879862a545ffc60bb | c4cdad5ab1fbd5829bd75c1cb7e796f104d7352a | /tests/test_core.py | 4b90f4b916c6e5f8f7b306f5c324e9b16bb09261 | [
"MIT"
] | permissive | sampsyo/wideq | 7bd2eab6d4b86eb8c7661e8f97e1d7a644cac5e8 | 511e342e5d3d5c3ae3c18d8fef7f922bf4c1f43c | refs/heads/master | 2023-08-31T18:31:52.839607 | 2022-05-12T19:33:07 | 2022-05-12T19:34:41 | 116,520,474 | 325 | 162 | MIT | 2022-03-20T08:32:23 | 2018-01-06T22:34:44 | Python | UTF-8 | Python | false | false | 2,228 | py | test_core.py | import unittest
import responses
import wideq.core
class SimpleTest(unittest.TestCase):
@responses.activate
def test_gateway_en_US(self):
responses.add(
responses.POST,
"https://kic.lgthinq.com:46030/api/common/gatewayUriList",
json={
"lgedmRoot": {... |
3d0aac741b0a203dfd9b90a70d5d71b86dae96ec | 4b1b3cf75b4582bbaa7b0f80e4d833cb98d9c5c8 | /src/canmatrix/j1939_decoder.py | 3cd03c6f439cdf47c1975b4db5f2349d7906ab46 | [
"BSD-2-Clause"
] | permissive | ebroecker/canmatrix | e16ff9c4c8b9e67e75ec84c3de24c78708bda2ca | ac1a2378f084f90f3ea9da4b3f21491f3ea05c3a | refs/heads/development | 2023-09-04T19:08:53.231876 | 2023-08-07T21:55:12 | 2023-08-07T21:55:12 | 9,304,497 | 835 | 398 | BSD-2-Clause | 2023-08-07T21:55:14 | 2013-04-08T19:08:14 | Python | UTF-8 | Python | false | false | 4,440 | py | j1939_decoder.py | # -*- coding: utf-8 -*-
from __future__ import absolute_import, division, print_function
from builtins import *
import attr
import canmatrix.formats
try:
from importlib.resources import read_binary
except ImportError:
from pkgutil import get_data as read_binary
@attr.s
class j1939_decoder(object):
str... |
d7025672ae5697917cb91b85f5c5d8fd4c3e24ef | 49600905e4aaa4929758997c5d1df09ff693534a | /njunmt/encoders/rnn_encoder.py | 7f3a1c717eab3cd9b1ead10c30cd97ca2d9afa7d | [
"Apache-2.0"
] | permissive | zhaocq-nlp/NJUNMT-tf | 3466d967cdc96b2dc6b0fb6a3e769ec1b83010d2 | 01155c740705f1641ebf3134829cea0e212f2d28 | refs/heads/v0.6 | 2018-12-04T18:55:36.641444 | 2018-01-26T06:39:42 | 2018-01-26T06:39:42 | 115,672,915 | 114 | 44 | Apache-2.0 | 2018-01-27T13:54:31 | 2017-12-29T01:17:43 | Python | UTF-8 | Python | false | false | 5,852 | py | rnn_encoder.py | # Copyright 2017 Natural Language Processing Group, Nanjing University, zhaocq.nlp@gmail.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... |
b721bfac00adac69a38ea9931e4ae89d6604ae8e | 5c363c50c54175a982330ec888401b3e394373ab | /benchmarking/nursery/benchmark_multiobjective/benchmark_definitions.py | eb269cb0a4bb8ec6da5b68bcf84dc896ef4a780c | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | awslabs/syne-tune | b14fb008f63def6a172bea6cc451f4e1906647f5 | c35686e1b5947d45384fd1d41a44e013da53ef43 | refs/heads/main | 2023-08-14T14:21:48.995716 | 2023-08-03T12:57:13 | 2023-08-03T12:57:13 | 417,499,108 | 313 | 47 | Apache-2.0 | 2023-09-14T14:06:54 | 2021-10-15T12:54:45 | Python | UTF-8 | Python | false | false | 2,107 | py | benchmark_definitions.py | # Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License").
# You may not use this file except in compliance with the License.
# A copy of the License is located at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# or in the "license... |
e7834ece43f9eefd7db7d4cba0fb33cf6f30113c | 38d1c6a920b3d9534f191fa0bfcd6d7d4625d643 | /my/instagram/common.py | 36c6b83a018cec0bc5b04a4b39ef9a7b8ce0f652 | [
"MIT",
"LicenseRef-scancode-proprietary-license"
] | permissive | karlicoss/HPI | ab87dcbfd8e3af788144990c35e030577227966b | c283e542e3457ecd778fb09e54e725d67104a49a | refs/heads/master | 2023-08-31T11:38:23.547022 | 2023-08-24T22:29:14 | 2023-08-24T22:46:23 | 209,134,309 | 1,252 | 65 | MIT | 2023-09-07T01:36:27 | 2019-09-17T18:59:05 | Python | UTF-8 | Python | false | false | 2,461 | py | common.py | from dataclasses import replace
from datetime import datetime
from itertools import chain
from typing import Iterator, Dict, Any, Protocol
from my.core import warn_if_empty, Res
class User(Protocol):
id: str
username: str
full_name: str
class Message(Protocol):
created: datetime
text: str
t... |
8206242c23e27ba1d4c2e273b4e953d182d140f5 | fd8ef75bb06383538cdb21ed2a0ef88e570179b7 | /src/openfermion/ops/operators/symbolic_operator_test.py | 2c5691ce1c2d29b33521ee6c97b054fcdb030edc | [
"LicenseRef-scancode-generic-cla",
"Apache-2.0"
] | permissive | quantumlib/OpenFermion | d1147383f99573d19005bd0f3e0120e9e9bed04c | 788481753c798a72c5cb3aa9f2aa9da3ce3190b0 | refs/heads/master | 2023-09-04T11:00:32.124157 | 2023-08-24T21:54:30 | 2023-08-24T21:54:30 | 104,403,768 | 1,481 | 406 | Apache-2.0 | 2023-08-24T21:54:31 | 2017-09-21T22:10:28 | Python | UTF-8 | Python | false | false | 46,765 | py | symbolic_operator_test.py | # 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
# distribu... |
54a4baca72fbe3521a3d8c7814cc9f30fd8ed249 | a5b66100762c0ca7076de26645ef1b732e0ee2d8 | /test_python_toolbox/test_combi/test_chain_space.py | 7fbcc4174ed073d3b4ad6600736275495be6cd68 | [
"MIT",
"BSD-3-Clause",
"Apache-2.0"
] | permissive | cool-RR/python_toolbox | 63400bbc004c63b32fe421b668a64bede4928e90 | cb9ef64b48f1d03275484d707dc5079b6701ad0c | refs/heads/master | 2022-01-26T14:41:29.194288 | 2021-12-25T06:49:40 | 2021-12-25T06:49:40 | 3,066,283 | 130 | 15 | NOASSERTION | 2021-12-25T06:49:41 | 2011-12-29T01:39:51 | Python | UTF-8 | Python | false | false | 1,157 | py | test_chain_space.py | # Copyright 2009-2017 Ram Rachum.
# This program is distributed under the MIT license.
from python_toolbox import cute_testing
from python_toolbox.combi import *
def test_chain_spaces():
chain_space = ChainSpace((range(3), 'meow', range(22, 19, -1)))
assert tuple(chain_space) == (0, 1, 2, 'm', 'e', 'o', 'w'... |
e05fbc4dd42b664795590c3e986b4e1cf279ca4d | 11d0cc8470722b737ac1d83610f227ffb98ea71a | /old_code/lgf_vweb.py | ddd2ed7a53f95422197a6d4d9e3b3b54995f2770 | [] | no_license | EdoardoCarlesi/PyRCODIO | d86e5298877f08b597f92a07aac0c9b634dbfa39 | d3f84efb7aeec0032ef6bde839fe9440ee82b392 | refs/heads/master | 2021-04-03T04:58:26.219884 | 2021-03-21T12:22:19 | 2021-03-21T12:22:19 | 125,036,704 | 148 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,979 | py | lgf_vweb.py | from libio.read_ascii import *
import pickle
import numpy as np
import os
# Root path for the vweb files
dirBase='/z/carlesi/CLUES/DATA/512/'
#dirBase='/z/carlesi/CLUES/DATA/LGF/SNAPS/512/'
#dirBase='/work2/eduardo/DATA/512/VWEB/'
fileWeb1='vweb_lgf_054.000064.Vweb-ascii'
fileWeb2='vweb_127.000064.Vweb-ascii'
#fileLGs... |
e1ddcc0f0bdc731f2982634aa575ecd0004dd1ed | b43e0384ec4bfacec2571a2bb41ce563267db449 | /jesse/modes/import_candles_mode/drivers/Binance/BinancePerpetualFuturesTestnet.py | fe418fa5af3d382ddf939c9afc68fd9bc5a5e3c5 | [
"MIT"
] | permissive | jesse-ai/jesse | 55b73448b767492a20f8bc56c28306a1a24f8599 | fadb03b5fcc06f0655c6a5d877435fb872a97c5e | refs/heads/master | 2023-08-24T15:28:52.875208 | 2023-08-24T13:53:31 | 2023-08-24T13:53:31 | 156,847,937 | 5,259 | 722 | MIT | 2023-09-10T13:51:26 | 2018-11-09T10:38:44 | Python | UTF-8 | Python | false | false | 424 | py | BinancePerpetualFuturesTestnet.py | from .BinanceMain import BinanceMain
from jesse.enums import exchanges
class BinancePerpetualFuturesTestnet(BinanceMain):
def __init__(self) -> None:
from .BinanceSpot import BinanceSpot
super().__init__(
name=exchanges.BINANCE_PERPETUAL_FUTURES_TESTNET,
rest_endpoint='htt... |
b08b638b6cc84bcabd4e73424e4b8ce6d0ffea91 | 3daa53a2190f365ee2e2acae39ca4e84919f2f50 | /test/probe/test_empty_device_handoff.py | 9a7f4234ca73b82fe0da15effab51ef4fd5ab1cf | [
"Apache-2.0"
] | permissive | openstack/swift | 4c8e4a14c1c6f7efb049f983ede28e89bd2e9140 | f06e5369579599648cc78e4b556887bc6d978c2b | refs/heads/master | 2023-08-28T15:04:33.200849 | 2023-08-24T20:35:07 | 2023-08-24T21:05:48 | 790,019 | 2,370 | 957 | Apache-2.0 | 2023-06-22T02:45:53 | 2010-07-22T01:50:07 | Python | UTF-8 | Python | false | false | 7,656 | py | test_empty_device_handoff.py | #!/usr/bin/python -u
# Copyright (c) 2010-2012 OpenStack Foundation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by ap... |
0c63b22e9fe9a1d81378ee93fcbf6824eeb0719c | 65078b8087c2040cf0188e2550ea298d20518f62 | /src/bentoml/_internal/utils/uri.py | ec9032dbf62ad243ec9d86f2631225e87b69034b | [
"Apache-2.0"
] | permissive | bentoml/BentoML | 20ab6f8351b1c5cd116d6d60a28098246a1581b3 | 4a14f073d8a3e700aff29483b17ea053058c0c63 | refs/heads/main | 2023-09-05T16:03:08.909692 | 2023-09-04T18:54:33 | 2023-09-04T18:54:33 | 178,976,529 | 5,712 | 732 | Apache-2.0 | 2023-09-14T20:07:54 | 2019-04-02T01:39:27 | Python | UTF-8 | Python | false | false | 1,197 | py | uri.py | import os
import pathlib
from urllib.parse import quote
from urllib.parse import unquote
from urllib.parse import urlparse
from urllib.request import url2pathname
import psutil
def path_to_uri(path: str) -> str:
"""
Convert a path to a URI.
Args:
path: Path to convert to URI.
Returns:
... |
8302d9b5756a01ca43debb66849db4d81921fdc9 | 3b6e0306b7a14de87ec40bec5e44039a3c7d55d8 | /dts_test_project/customers/models.py | b6f1fe10d4041aad9bca6b9e2e147d8873925234 | [
"MIT"
] | permissive | bernardopires/django-tenant-schemas | 5a4810714c6d4f4472c5088cc63076e69bc6da5b | a77655c2170b9e6d50003cd5806cc87589dd3bd8 | refs/heads/master | 2023-08-10T20:14:05.867506 | 2023-07-02T19:48:20 | 2023-07-02T19:48:20 | 4,761,556 | 1,234 | 473 | MIT | 2023-07-02T19:50:06 | 2012-06-23T10:54:34 | Python | UTF-8 | Python | false | false | 252 | py | models.py | from django.db import models
from tenant_schemas.models import TenantMixin
class Client(TenantMixin):
name = models.CharField(max_length=100)
description = models.TextField(max_length=200)
created_on = models.DateField(auto_now_add=True)
|
f1606ca4faf5d20449becf732ed313b5e3be881e | 45826bdfebbd1d7638ab607906ac480031d6118b | /lib/models/nets/segfix.py | d645586d9a2daeeafc5ea71a982ed1a83d5cf2d2 | [
"MIT"
] | permissive | openseg-group/openseg.pytorch | b75cec5c95b6ff71707d8daf7806001bab89ecb3 | aefc75517b09068d7131a69420bc5f66cb41f0ee | refs/heads/master | 2023-09-06T10:19:57.749113 | 2022-08-07T09:10:20 | 2022-08-07T09:10:20 | 166,743,301 | 1,227 | 159 | MIT | 2021-07-14T06:10:44 | 2019-01-21T03:34:59 | Python | UTF-8 | Python | false | false | 3,021 | py | segfix.py | ##+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
## Created by: RainbowSecret
## Microsoft Research
## yuyua@microsoft.com
## Copyright (c) 2019
##
## This source code is licensed under the MIT-style license found in the
## LICENSE file in the root directory of this source tree
##++++++++++++... |
862e1ad9aeae517a717a5dcb168a4acf13a4da77 | 52a677b94056d3397b4a499bc9185adb68a63f05 | /util/headers.py | 86c8b4810cb292d6be03cbb1ee7d68143bb6929f | [
"Apache-2.0"
] | permissive | quay/quay | 9b6fcff54efc0dbf7c6d91fa80676950555b6f1a | e400a0c22c5f89dd35d571654b13d262b1f6e3b3 | refs/heads/master | 2023-08-28T15:08:38.001842 | 2023-08-28T13:52:31 | 2023-08-28T13:52:31 | 220,517,730 | 2,363 | 322 | Apache-2.0 | 2023-09-14T17:43:48 | 2019-11-08T17:37:05 | Python | UTF-8 | Python | false | false | 512 | py | headers.py | import base64
def parse_basic_auth(header_value):
"""
Attempts to parse the given header value as a Base64-encoded Basic auth header.
"""
if not header_value:
return None
parts = header_value.split(" ")
if len(parts) != 2 or parts[0].lower() != "basic":
return None
try:
... |
7bccc6971fa462e2f8a6ee8ef5d5182a51eda016 | b42752f5b4509c2641cf840304900073ae287464 | /script/get_workspace_symbols.py | 77f9de9c23e717a3835f39e29323d0a5bce827d5 | [
"MIT"
] | permissive | antoinemadec/coc-fzf | d854f4dcdf982d3d3cb4b5ffc3ba23edcf07fd32 | 5fae5a15497750483e21fc207aa6005f340f02f2 | refs/heads/master | 2023-08-25T04:31:57.828317 | 2023-01-30T18:34:01 | 2023-01-30T18:34:01 | 236,263,116 | 442 | 40 | null | 2023-01-30T18:34:03 | 2020-01-26T03:42:15 | Vim Script | UTF-8 | Python | false | false | 3,742 | py | get_workspace_symbols.py | #!/usr/bin/env python3
import argparse
import re
from urllib.parse import unquote
from pynvim import attach
# --------------------------------------------------------------
# functions
# --------------------------------------------------------------
kind_dict = {}
kind_dict[1] = 'File'
kind_dict[2] = 'Module'
kind_... |
e6d436625488d30a76c6903f315b39d0d2c694a3 | b097b7caa954a0447bef9a7144e15fbc1b08a96b | /examples/tutorials/streamreader_advanced_tutorial.py | 7d3a4bd09eeb136d0bf39a5c265386b57dd78038 | [
"CC-BY-NC-4.0",
"BSD-2-Clause"
] | permissive | pytorch/audio | 3fa7006404020c9ce731f27b94f0257195d2efe3 | e057d7d144e2716588b80255f0a143662fd5c10d | refs/heads/main | 2023-09-03T15:46:06.918708 | 2023-09-02T00:39:15 | 2023-09-02T00:39:15 | 90,321,822 | 2,319 | 675 | BSD-2-Clause | 2023-09-13T22:09:20 | 2017-05-05T00:38:05 | Python | UTF-8 | Python | false | false | 13,963 | py | streamreader_advanced_tutorial.py | """
StreamReader Advanced Usages
============================
**Author**: `Moto Hira <moto@meta.com>`__
This tutorial is the continuation of
`StreamReader Basic Usages <./streamreader_basic_tutorial.html>`__.
This shows how to use :py:class:`~torchaudio.io.StreamReader` for
- Device inputs, such as microphone, webc... |
bbb80891269a2e7573657a9a0dae21e9fa50eb51 | 0349e502733a4c25f020fbcad4715f598d686799 | /tutorials/python_invocation_example.py | 091a137ff491d25ca91ce85395bb7ad48b74b13a | [
"Apache-2.0"
] | permissive | IntelLabs/coach | 679592e9887f5788229fef9d77a1a7975e959bc4 | 2c60cb5acd8cd3c9c381a5066c208e69fc273c7b | refs/heads/master | 2023-09-05T17:56:19.435416 | 2022-12-11T17:54:06 | 2022-12-11T17:54:06 | 105,468,219 | 497 | 102 | Apache-2.0 | 2021-12-27T09:52:30 | 2017-10-01T19:27:43 | Python | UTF-8 | Python | false | false | 612 | py | python_invocation_example.py | from rl_coach.agents.clipped_ppo_agent import ClippedPPOAgentParameters
from rl_coach.core_types import EnvironmentSteps
from rl_coach.environments.gym_environment import GymVectorEnvironment
from rl_coach.graph_managers.basic_rl_graph_manager import BasicRLGraphManager
from rl_coach.graph_managers.graph_manager import... |
4437b3f690e2d92e7cf70f98abfe16b3eef3cd30 | a2b20597759990445081057d35d113434cfcf970 | /stubs/typeshed/typeshed/stubs/stripe/stripe/api_resources/alipay_account.pyi | f18475a6774f1d327ae5facda9506b71fee763b2 | [
"MIT",
"Apache-2.0"
] | permissive | facebook/pyre-check | 34059599c02b65605c574f13555229f3b931fd4e | fe8ccedc572cc1faa1fd01e9138f65e982875002 | refs/heads/main | 2023-09-03T19:10:11.587028 | 2023-09-02T07:40:35 | 2023-09-02T07:40:35 | 110,274,488 | 6,703 | 575 | MIT | 2023-09-13T17:02:32 | 2017-11-10T17:31:36 | OCaml | UTF-8 | Python | false | false | 700 | pyi | alipay_account.pyi | from _typeshed import Incomplete
from typing import NoReturn
from stripe.api_resources.abstract import (
DeletableAPIResource as DeletableAPIResource,
UpdateableAPIResource as UpdateableAPIResource,
)
from stripe.api_resources.customer import Customer as Customer
class AlipayAccount(DeletableAPIResource, Upda... |
9b5b4c794237efedfe351eb363874afb558f1e8a | d947e08de661346384f81e8bdb8aca8f201376f1 | /src/dist.py | 7ebddf5061ff85632f7c6e48db13d8587cecc0b8 | [
"Apache-2.0"
] | permissive | JetBrains/kotlin-web-site | 48813e763124dbade34234f6215906239677f88a | cd33fb0ae0c9caef79c1eac9b42d70485866f1ba | refs/heads/master | 2023-09-01T04:43:38.247946 | 2023-08-30T13:46:30 | 2023-08-30T13:53:51 | 14,397,208 | 1,509 | 4,069 | Apache-2.0 | 2023-09-14T09:27:55 | 2013-11-14T14:26:54 | JavaScript | UTF-8 | Python | false | false | 2,111 | py | dist.py | from bs4 import BeautifulSoup
from os import path, walk
dist_path = path.join(path.dirname(__file__), "../", "dist")
def get_dist_page_content(url):
path_file = dist_path + url
if url.endswith('/'):
path_file += 'index.html'
if path.exists(path_file):
with open(path_file, 'r', encoding... |
0aa56c2a2472fd20b9af07a0909b594b2baaed74 | a2882062b8ce4252afeb92ae5bade1299bc97501 | /synthesize.py | f03fc08ab5ecccf4d5ca1357bde330f75ddd5db2 | [
"MIT"
] | permissive | keonlee9420/Comprehensive-E2E-TTS | 526425b5abc7b623a24e0d0b60af8f28e6753acc | 0b5d0a597f95f3fd4b3a80ae8cf5d07013cadb83 | refs/heads/main | 2023-05-24T01:14:03.042390 | 2022-06-06T12:30:10 | 2022-06-06T12:30:10 | 475,779,002 | 127 | 21 | null | 2022-06-06T12:30:11 | 2022-03-30T08:02:49 | Python | UTF-8 | Python | false | false | 7,692 | py | synthesize.py | import re
import os
import json
import argparse
from string import punctuation
import torch
import yaml
import numpy as np
from torch.utils.data import DataLoader
from g2p_en import G2p
from tqdm import tqdm
import audio as Audio
from utils.model import get_model
from utils.tools import get_configs_of,... |
d7e7afae5cc91f681801d69f56095028a4bd467c | 9784a90cac667e8e0aaba0ca599b4255b215ec67 | /tensorflow2/tf2cv/models/nvpattexp.py | 1b92025774308d8f998b98ecbbd3ed97f99c29fc | [
"MIT"
] | permissive | osmr/imgclsmob | d2f48f01ca541b20119871393eca383001a96019 | f2993d3ce73a2f7ddba05da3891defb08547d504 | refs/heads/master | 2022-07-09T14:24:37.591824 | 2021-12-14T10:15:31 | 2021-12-14T10:15:31 | 140,285,687 | 3,017 | 624 | MIT | 2022-07-04T15:18:37 | 2018-07-09T12:57:46 | Python | UTF-8 | Python | false | false | 10,488 | py | nvpattexp.py | """
Neural Voice Puppetry Audio-to-Expression net for speech-driven facial animation, implemented in TensorFlow.
Original paper: 'Neural Voice Puppetry: Audio-driven Facial Reenactment,' https://arxiv.org/abs/1912.05566.
"""
__all__ = ['NvpAttExp', 'nvpattexp116bazel76']
import os
import tensorflow as tf
impo... |
46dc69599f4261e9b2ef6df2f322f7c15be8ffbe | 233676e340835a58e8041bdc82c313e599af415c | /aslam_offline_calibration/kalibr/python/kalibr_imu_camera_calibration/__init__.py | 1c4c3ecefc43bee6bbf3042b66e4815fd583dc84 | [
"BSD-3-Clause"
] | permissive | ethz-asl/kalibr | 9213daa87ed191ce1e05fba9f7424204c2d9734c | 94bb8437a72a0d97a491097a7085bf3db4f93bba | refs/heads/master | 2023-08-29T17:04:47.774244 | 2023-08-14T02:08:46 | 2023-08-14T02:08:46 | 20,293,077 | 3,744 | 1,341 | NOASSERTION | 2023-09-10T02:18:47 | 2014-05-29T12:31:48 | C++ | UTF-8 | Python | false | false | 124 | py | __init__.py | from .IccCalibrator import *
from . import IccUtil as util
from . import IccPlots as plots
from . import IccSensors as sens
|
daa0113695a073ff357c0d404a4ad744a542691d | 93713f46f16f1e29b725f263da164fed24ebf8a8 | /Library/lib/python3.7/site-packages/networkx/utils/tests/test_decorators.py | f8c5e2440a82f12112e8d3b91b4fe64f539c8f0d | [
"BSD-3-Clause"
] | permissive | holzschu/Carnets | b83d15136d25db640cea023abb5c280b26a9620e | 1ad7ec05fb1e3676ac879585296c513c3ee50ef9 | refs/heads/master | 2023-02-20T12:05:14.980685 | 2023-02-13T15:59:23 | 2023-02-13T15:59:23 | 167,671,526 | 541 | 36 | BSD-3-Clause | 2022-11-29T03:08:22 | 2019-01-26T09:26:46 | Python | UTF-8 | Python | false | false | 8,712 | py | test_decorators.py | import tempfile
import os
import random
from nose.tools import *
from nose import SkipTest
import networkx as nx
from networkx.utils.decorators import open_file, not_implemented_for
from networkx.utils.decorators import nodes_or_number, preserve_random_state, \
py_random_state, np_random_state, random_state
from ... |
d1a420cad3400ad805676037c38aa575a25833e8 | 820b6af9fd43b270749224bb278e5f714f655ac9 | /Utilities/Maintenance/vtk_reindent_code.py | 5ac86ee88d3b7a381f45762c70a165aefd6d4084 | [
"BSD-3-Clause"
] | permissive | Kitware/VTK | 49dee7d4f83401efce8826f1759cd5d9caa281d1 | dd4138e17f1ed5dfe6ef1eab0ff6643fdc07e271 | refs/heads/master | 2023-09-01T10:21:57.496189 | 2023-09-01T08:20:15 | 2023-09-01T08:21:05 | 631,615 | 2,253 | 1,243 | NOASSERTION | 2023-09-14T07:53:03 | 2010-04-27T15:12:58 | C++ | UTF-8 | Python | false | false | 16,384 | py | vtk_reindent_code.py | #!/usr/bin/env python
"""
Usage: python vtk_reindent_code.py [--test] <file1> [<file2> ...]
This script takes old-style "Whitesmiths" indented VTK source files as
input, and re-indents the braces according to the new VTK style.
Only the brace indentation is modified.
If called with the --test option, then it will pri... |
a5ef5cbec509c68ba16227ba7de7a67690c4f72d | 542ce6e738757d34fdea675349cbe1a0f975662b | /benchscripts/benchstat2 | 45f8fa05c94ae084eb7c9233b20e67605f178c9a | [
"BSD-3-Clause"
] | permissive | aclements/go-misc | 7f598ef0aa3720dffb7ac02541ae2d3199b47033 | dbc22aabbcfb1e8d54725a10315fa16f7054ed48 | refs/heads/master | 2023-08-29T05:33:45.473551 | 2023-08-21T21:01:50 | 2023-08-21T21:03:38 | 34,076,292 | 230 | 23 | BSD-3-Clause | 2023-03-07T02:25:27 | 2015-04-16T19:33:13 | Go | UTF-8 | Python | false | false | 3,906 | benchstat2 | #!/usr/bin/python3
import os
import sys
import tempfile
import subprocess
import argparse
import re
def expandHash(commits, h):
x = None
for c in commits:
if c.startswith(h):
if x != None:
raise ValueError("ambiguous commit hash " + h)
x = c
return x
def ma... | |
4afd285af61b029cb7192211ab749f53576dc6d1 | f305f84ea6f721c2391300f0a60e21d2ce14f2a5 | /22_专题/区间问题/区间操作/贪心/906_区间分组-小根堆.py | 64bb9c325ae1f8cc642230c6e0720abda50f5782 | [] | no_license | 981377660LMT/algorithm-study | f2ada3e6959338ae1bc21934a84f7314a8ecff82 | 7e79e26bb8f641868561b186e34c1127ed63c9e0 | refs/heads/master | 2023-09-01T18:26:16.525579 | 2023-09-01T12:21:58 | 2023-09-01T12:21:58 | 385,861,235 | 225 | 24 | null | null | null | null | UTF-8 | Python | false | false | 1,619 | py | 906_区间分组-小根堆.py | # 1. 左端点从小到大排序
# 2. 遍历区间,判断能否判断放入现有组中
# 给定 N 个闭区间 [ai,bi],
# 请你将这些区间分成若干组,
# 使得每组内部的区间两两之间(包括端点)没有交集,
# 并使得组数尽可能小。
# 输出最小组数。
# !n<=1e4
# !start<end<1e9
#######################################################################
# 解答:
# !区间按照左端点排序
# 小根堆存放所有组的右端点值,堆顶存放最小的右端点值
# 如果当前区间左端点大于堆顶元素,说明可以加入堆顶元素所在组,... |
9590cdbc7650897d64d6f9464cc2a19366276756 | 5d55e0885bacd718588f25b71675c1127c93fc0a | /river/time_series/holt_winters.py | 52241be66a9a03c4570c4b6db4085fd932e02756 | [
"BSD-3-Clause"
] | permissive | online-ml/river | 5698b60e65493eba28d0c0c1992f19eb996c0bfa | c658393084ed4147a782daa6bcd4a467c3abb0cb | refs/heads/main | 2023-09-03T00:12:55.121301 | 2023-08-29T12:04:20 | 2023-08-29T12:04:20 | 167,388,434 | 3,372 | 389 | BSD-3-Clause | 2023-09-12T08:11:15 | 2019-01-24T15:18:26 | Python | UTF-8 | Python | false | false | 6,681 | py | holt_winters.py | from __future__ import annotations
import operator
import statistics
from collections import deque
from river import time_series
__all__ = ["HoltWinters"]
class Component(deque):
...
class AdditiveLevel(Component):
def __init__(self, alpha):
super().__init__([], maxlen=2)
self.alpha = alp... |
35b8745b891aca0c5c950b43dac45e85a23ea049 | f54739ec8ca9a9012eefda5c4759a62db3fef3c2 | /src/api-engine/api/utils/__init__.py | b5bc027672d08aacae133e1b1fbce4ca0373979c | [
"CC-BY-4.0",
"Apache-2.0"
] | permissive | hyperledger/cello | 6e615ab0df9724262ef6c2028d45f2f642254fe2 | cb4d24347228ad9d1ae24cd0d6188bf29b1b8cbe | refs/heads/main | 2023-09-03T15:33:35.844553 | 2023-08-29T03:47:41 | 2023-08-29T03:47:41 | 78,610,786 | 957 | 559 | Apache-2.0 | 2023-09-12T00:53:55 | 2017-01-11T06:47:08 | Python | UTF-8 | Python | false | false | 1,527 | py | __init__.py | #
# SPDX-License-Identifier: Apache-2.0
#
import logging
from rest_framework.views import exception_handler
from rest_framework.exceptions import ValidationError, ParseError
from api.common.enums import ErrorCode
from rest_framework import status
from rest_framework.exceptions import ErrorDetail
from .common import zi... |
161fb43e3678581ca3348cd87616383a7b58d331 | 6b6d42eadf53e90b08ce564fb188a9a4b126ef12 | /testsuite/python_support/utils.py | 681016d930472964c2c159fc56247b158ba74a37 | [
"Apache-2.0",
"LLVM-exception",
"NCSA"
] | permissive | AdaCore/libadalang | f97b95d1672cb1e5083c49ee632c6f9c787d36c2 | 50d658afa70ccbf46b8f7d9d43a21d45d56b206c | refs/heads/master | 2023-09-01T18:34:26.976692 | 2023-08-25T15:53:43 | 2023-08-25T15:53:43 | 47,627,172 | 158 | 49 | Apache-2.0 | 2022-12-14T10:29:45 | 2015-12-08T14:28:22 | Ada | UTF-8 | Python | false | false | 2,324 | py | utils.py | import os
import os.path
import pipes
import re
import subprocess
LAL_ROOTDIR = os.path.abspath(os.environ['LIBADALANG_ROOTDIR'])
LAL_DISABLE_SHARED = bool(int(os.environ['LIBADALANG_DISABLE_SHARED']))
LAL_BUILD_MODE = os.environ['LIBADALANG_BUILD_MODE'] or "dev"
DIRECTORY_MISSING_RE = re.compile(
r'.*\.gpr:\d+:... |
029b49223debc02bb943115d5d87989f9de63bff | 0ba2e5061577f6286ff9265ef1df9aca96769445 | /data_structures/Graphs/graphsearch/graph_coloring/python/graph_color_greedy.py | 375d3918902001b208be86022cfda0174a0c4228 | [
"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 | 743 | py | graph_color_greedy.py | from collections import defaultdict
class Graph:
def __init__(self,V,directed=False):
self.V = V
self.directed = directed
self.graph = defaultdict(list)
def add_edge(self,a,b):
self.graph[a].append(b)
if not self.directed:
self.graph[b].append(a)
def color_greedy(self):
result = [-1]*self.V
... |
b72d3c207323817ed08d925618bc4a569b1d52b6 | bf5acb19d44d031e2d8a9e37266acd55c5697863 | /pybamm/parameters/parameter_values.py | c78cb70c91c9cf16cca2118e0411a1fbac1b312b | [
"LicenseRef-scancode-unknown-license-reference",
"BSD-3-Clause"
] | permissive | pybamm-team/PyBaMM | 82ecf9bebb580aab1a4e67aa7d0297d2698a0b51 | b4432b6da7331f992b1831912a9cf89be1f7578f | refs/heads/develop | 2023-08-19T04:29:21.151964 | 2023-08-18T22:43:38 | 2023-08-18T22:43:38 | 155,538,761 | 713 | 362 | BSD-3-Clause | 2023-09-14T18:20:04 | 2018-10-31T10:26:29 | Python | UTF-8 | Python | false | false | 32,690 | py | parameter_values.py | #
# Parameter values for a simulation
#
import numpy as np
import pybamm
import numbers
from pprint import pformat
from collections import defaultdict
class ParameterValues:
"""
The parameter values for a simulation.
Note that this class does not inherit directly from the python dictionary class as
t... |
0343995f48d441fd38aa92a2478cf7007bc70115 | 81a0a8218a45edcc8f295de5d41a3fd29cdc3ce6 | /switch_model/balancing/unserved_load.py | d06156b540f974a6d85f718dbb24fd85d7e9984e | [
"Apache-2.0"
] | permissive | switch-model/switch | af5ea212a141d97613ef1f13e550ee898fa352da | 35bd3596a031fac7891f762cc87af610ded13615 | refs/heads/master | 2023-06-19T17:57:22.298285 | 2022-11-01T23:56:15 | 2022-11-01T23:56:15 | 33,576,546 | 114 | 81 | NOASSERTION | 2023-01-29T17:30:41 | 2015-04-08T00:59:34 | Python | UTF-8 | Python | false | false | 2,283 | py | unserved_load.py | # Copyright (c) 2015-2022 The Switch Authors. All rights reserved.
# Licensed under the Apache License, Version 2.0, which is in the LICENSE file.
"""
Defines components to allow leaving some load unserved. This module is
specially useful when running production costing simulations, though not
strictly required in all... |
eb9c013dffd7f8267764f396d66a80f38f249eca | 6032d4c2a046e2c5601099593660807217944019 | /elephant/statistics.py | 139c737449d21d3d9987e918412b4cd18e5e3d6d | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | NeuralEnsemble/elephant | 6130fc70fcfd4e3e1a91add4ad0273c4bca4782d | 2bd871aec145d897031aed327a7a4af0102c47cb | refs/heads/master | 2023-09-02T03:31:14.531100 | 2023-07-20T14:00:50 | 2023-07-20T14:00:50 | 10,311,278 | 162 | 89 | BSD-3-Clause | 2023-09-14T13:47:26 | 2013-05-27T08:59:34 | Python | UTF-8 | Python | false | false | 63,884 | py | statistics.py | # -*- coding: utf-8 -*-
"""
Statistical measures of spike trains (e.g., Fano factor) and functions to
estimate firing rates.
Rate estimation
***************
.. autosummary::
:toctree: _toctree/statistics/
mean_firing_rate
instantaneous_rate
time_histogram
optimal_kernel_bandwidth
Spike interval... |
0bd6d7757a1b9d0209c2a80aa0f608155b920931 | ae72088480e7c2112a5465fadac23a14fbd0ede9 | /zookeeper-contrib/zookeeper-contrib-monitoring/check_zookeeper.py | 0a08e84a7cc876c67463c6b7342ea03364eeac34 | [
"Apache-2.0",
"BSD-3-Clause",
"MIT"
] | permissive | apache/zookeeper | f4a45cf12957a8da03c9f1f88f6194e7ce11d6d7 | 03a36d08e257c43e8377e5549d5524805fc6b8bb | refs/heads/master | 2023-08-31T17:46:25.779817 | 2023-08-30T03:25:41 | 2023-08-30T03:25:41 | 160,999 | 12,080 | 7,860 | Apache-2.0 | 2023-09-10T14:36:38 | 2009-03-27T15:41:56 | Java | UTF-8 | Python | false | false | 13,057 | py | check_zookeeper.py | #! /usr/bin/env python
# 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
# "... |
6b3c9e957c6a982e7d90549c482b009a1586a8b0 | 7260860cc391503e839929d77722004d17e47681 | /django_dynamic_fixture/tests/test_ddf_teaching_and_lessons.py | d15639bdb00de04171288dc6983956b0e524fc81 | [
"MIT",
"Apache-2.0"
] | permissive | paulocheque/django-dynamic-fixture | 5937e144a4504ab84e05da673c7bf3ce90ad9d1e | 5b5ffaca3bef3640feb2031feb3e895971b3b939 | refs/heads/master | 2023-08-30T20:56:47.857000 | 2023-08-27T01:29:16 | 2023-08-27T01:29:16 | 3,934,109 | 212 | 47 | NOASSERTION | 2023-09-05T20:29:14 | 2012-04-04T22:54:41 | Python | UTF-8 | Python | false | false | 9,709 | py | test_ddf_teaching_and_lessons.py | import re
from django.test import TestCase
import pytest
from django_dynamic_fixture.models_test import *
from django_dynamic_fixture.ddf import *
from django_dynamic_fixture.fixture_algorithms.sequential_fixture import SequentialDataFixture
data_fixture = SequentialDataFixture()
class DDFTestCase(TestCase):
... |
d43486d879a17b344dac1a686a5af4cc0cf20017 | c6759b857e55991fea3ef0b465dbcee53fa38714 | /tools/nntool/nntool/interpreter/commands/aquant.py | 1bb479f6892a642e5c45415428eea1a28f345963 | [
"AGPL-3.0-or-later",
"AGPL-3.0-only",
"GPL-1.0-or-later",
"LicenseRef-scancode-other-copyleft",
"Apache-2.0"
] | permissive | GreenWaves-Technologies/gap_sdk | 1b343bba97b7a5ce62a24162bd72eef5cc67e269 | 3fea306d52ee33f923f2423c5a75d9eb1c07e904 | refs/heads/master | 2023-09-01T14:38:34.270427 | 2023-08-10T09:04:44 | 2023-08-10T09:04:44 | 133,324,605 | 145 | 96 | Apache-2.0 | 2023-08-27T19:03:52 | 2018-05-14T07:50:29 | C | UTF-8 | Python | false | false | 5,458 | py | aquant.py | # Copyright (C) 2020 GreenWaves Technologies, SAS
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
# This progr... |
1db4ea7478160606b4eea480aef773b7ed773e5a | f45e5600447a7ee2d4f6ba7c1ebdce5299a283aa | /test_project/views.py | 6bcb6da98f7ef19d7867947d95da2a4854d50d40 | [
"MIT"
] | permissive | GeeWee/django-auto-prefetching | bad658b1640afddb0c1abd70365128ea309651c5 | a7e1936961bb095f18ca53442ee558ce4fc82942 | refs/heads/master | 2023-08-11T10:13:21.972061 | 2023-08-02T09:36:10 | 2023-08-02T09:36:10 | 181,546,261 | 238 | 23 | MIT | 2023-08-02T09:36:12 | 2019-04-15T18:44:28 | Python | UTF-8 | Python | false | false | 1,464 | py | views.py | # Create your views here.
from rest_framework.viewsets import ModelViewSet
from django_auto_prefetching import AutoPrefetchViewSetMixin
import django_auto_prefetching
from test_project.serializers.child_a_serializer import ChildASerializer
from test_project.serializers.child_b_serializers import ChildBSerializer
from ... |
32f24b71b5fa89a6bc6a162688a101103effbf1f | bcabfb2a3cfb7a06004774dcf1a64412f0e70738 | /setting.py | 966ee270eb44c537b38f0d8b7cd6490a54b3f889 | [
"Apache-2.0"
] | permissive | CarryChang/Customer_Satisfaction_Analysis | afea9cd90d1df0f37ea551daa94a6461e871bc9f | ff3c99bdb567fa648cc5e71a38e2b5d0db0010e2 | refs/heads/master | 2023-01-11T15:35:14.414156 | 2022-12-27T10:50:46 | 2022-12-27T10:50:46 | 162,680,457 | 403 | 122 | null | null | null | null | UTF-8 | Python | false | false | 1,721 | py | setting.py | # -*- coding: utf-8 -*-
# @USER: CarryChang
# 设置词典大小为 n_features
n_features = 3000
# 存储断句的文件夹
sentence_cut_path = 'data/sentence_cut.txt'
# 主题句文件夹
topic_path = 'topic_text'
# 基于字典的查找
topic_words_list = {
'环境': {'环境', '周边', '风景', '空气', '江景', '小区', '景点', '夜景', '街', '周围', '景区', '声音', '景色'},
'价格': {'价格', '房价', ... |
2317e3df6d65ab3ec5cfd324812303fefa84264e | 529e713a78e82de2ae5d44cfb8ef209e0894d72a | /tic-tac-toe-ai-python/source_code_bonus/tic-tac-toe/frontends/console/args.py | 20b79f9a9d3ae6c155320c6c1a03de9c4bd06025 | [
"MIT"
] | permissive | realpython/materials | cd2f548276be2c82f134ca03eadb1cd279e0f26e | d2d62756d3854f54a12a767f2bf9470486c0ceef | refs/heads/master | 2023-09-05T22:12:29.806738 | 2023-08-31T20:56:28 | 2023-08-31T20:56:28 | 132,374,697 | 4,678 | 6,482 | MIT | 2023-09-12T22:22:06 | 2018-05-06T20:46:18 | HTML | UTF-8 | Python | false | false | 1,203 | py | args.py | import argparse
from typing import NamedTuple
from tic_tac_toe.game.players import (
MinimaxComputerPlayer,
Player,
RandomComputerPlayer,
)
from tic_tac_toe.logic.models import Mark
from .players import ConsolePlayer
PLAYER_CLASSES = {
"human": ConsolePlayer,
"random": RandomComputerPlayer,
"... |
c3f4237fe7e976f689bce910976edebb9a51ca36 | 8eb4e39e33969389aca96a79b56f298abcca6872 | /setup.py | 0297e7467f8ee603876d159d16604a2a6442cd6a | [
"BSD-3-Clause"
] | permissive | cpplint/cpplint | 8e4084109e0512dc8d196e178120ba2d09bc9edc | 7b88b68187e3516540fab3caa900988d2179ed24 | refs/heads/develop | 2023-03-18T17:48:54.664951 | 2023-02-03T15:16:23 | 2023-02-13T20:52:21 | 47,154,941 | 1,392 | 318 | NOASSERTION | 2023-09-01T03:24:19 | 2015-12-01T00:33:44 | Python | UTF-8 | Python | false | false | 3,081 | py | setup.py | #! /usr/bin/env python
from setuptools import setup, Command
from subprocess import check_call
from distutils.spawn import find_executable
import cpplint as cpplint
class Cmd(Command):
'''
Superclass for other commands to run via setup.py, declared in setup.cfg.
These commands will auto-install setup_requ... |
8297fdfb43d094c990d29786eabc93bef965f819 | 4f3bf85beb89f27b025339ba62fa4162b1338623 | /pinax/referrals/middleware.py | db73f6ac3ae2821a73fff7a4397af1d3cac0b1b4 | [
"MIT"
] | permissive | pinax/pinax-referrals | d13b41dd9b50bc905ef02ff3d2adf4dad2a3534e | 6ad4640c71718ac31191ad2dc7d964f0af6930f0 | refs/heads/master | 2023-08-17T06:53:34.629111 | 2023-01-12T14:41:13 | 2023-01-12T14:41:13 | 2,397,676 | 151 | 69 | MIT | 2023-01-12T14:35:50 | 2011-09-16T06:21:34 | Python | UTF-8 | Python | false | false | 1,265 | py | middleware.py | from django.core.exceptions import ImproperlyConfigured
from .models import Referral
try:
from django.utils.deprecation import MiddlewareMixin as MiddlewareBaseClass
except ImportError:
MiddlewareBaseClass = object
class SessionJumpingMiddleware(MiddlewareBaseClass):
def process_request(self, request):... |
76b57aae7d36e17db72b9e6ed35bc3ab1b97d044 | d689b3caab44773d1c27327c7635748b7510eef0 | /barbican/plugin/interface/secret_store.py | 1eeb54565cdeaeeb7a4563ff9fb8f47717d4cc30 | [
"Apache-2.0"
] | permissive | openstack/barbican | e9d8cd8c7821fbd0cd42381358040540e010d885 | c8e3dc14e6225f1d400131434e8afec0aa410ae7 | refs/heads/master | 2023-09-04T03:08:34.120188 | 2023-08-28T08:06:46 | 2023-08-28T08:06:46 | 20,115,712 | 189 | 93 | Apache-2.0 | 2021-07-27T06:00:23 | 2014-05-23T22:15:27 | Python | UTF-8 | Python | false | false | 25,738 | py | secret_store.py | # Copyright (c) 2014 Johns Hopkins University Applied Physics Laboratory
#
# 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 ... |
477612ad52e88c71b5d3326e35ec87dfa0bfa5e1 | 4ac8b14961a608ed79a483da306e746021165c78 | /effect/test_parallel_performers.py | 05b2dbf6be968f8873da9db203e9526a568c1900 | [
"MIT"
] | permissive | python-effect/effect | ffae552b9c638b141c6ce728392bfe320e5e705f | cd21859ad2babebcbf12fa372aef34b9cd25a10e | refs/heads/master | 2022-07-06T20:44:12.265058 | 2022-06-26T16:45:10 | 2022-06-26T16:45:10 | 20,022,094 | 289 | 17 | null | 2021-08-24T16:34:22 | 2014-05-21T13:26:42 | Python | UTF-8 | Python | false | false | 2,488 | py | test_parallel_performers.py | from functools import partial
import attr
from testtools.matchers import MatchesStructure, Equals
from . import Effect, raise_
from ._intents import Constant, Func, FirstError, parallel
from ._sync import sync_perform
from ._test_utils import MatchesReraisedExcInfo
@attr.s(hash=True)
class EquitableException(Excep... |
d2c4e2d51d378d2af222d741e0e97904bde992a1 | 01857ef455ea60eccaf03b5a9059ec83e9803c2e | /examples/trello_cards/main.py | aa7cf0493a4324c3790505a9355f35283cc83a51 | [
"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 | 747 | py | main.py | #!/usr/bin/env python3
from dataclasses import dataclass
import draganddrop as dnd
from nicegui import ui
@dataclass
class ToDo:
title: str
def handle_drop(todo: ToDo, location: str):
ui.notify(f'"{todo.title}" is now in {location}')
with ui.row():
with dnd.column('Next', on_drop=handle_drop):
... |
f044ecf6b044d4097a31d4c021d122e74e5e91f0 | 94a69d05880fdb03ad915a63f3575ff01e5df0e6 | /isobar/io/netclock/__init__.py | 12a6a4a93c43402da206af7fbfa33338b3c438c6 | [
"MIT"
] | permissive | ideoforms/isobar | 06f2a5553b33e8185c6f9aed06224811589f7b70 | 12b03500ea882f17c3521700f7f74b0e36e4b335 | refs/heads/master | 2023-07-20T20:31:13.040686 | 2023-07-17T19:19:01 | 2023-07-17T19:19:01 | 2,155,202 | 320 | 53 | MIT | 2023-05-01T21:29:46 | 2011-08-04T15:12:03 | Python | UTF-8 | Python | false | false | 81 | py | __init__.py | from .receiver import NetworkClockReceiver
from .sender import NetworkClockSender |
b45d03baf5c9eeacbab5807511c79339545d25af | 8c4af05e0257661195c95b0b9e0873eeb6391dab | /packages/python-packages/doc-warden/warden/cmd_entry.py | 681553f5f4e06830e9e487b4ab1bc1ab65775ef0 | [
"MIT",
"LicenseRef-scancode-generic-cla"
] | permissive | Azure/azure-sdk-tools | 6d171054800807fcbe7b8b878c5903a202d31faa | 2dce521dedc3f5169007d4c481ae8ec077be4450 | refs/heads/main | 2023-09-01T00:00:32.662190 | 2023-08-31T22:21:44 | 2023-08-31T22:21:44 | 170,592,186 | 113 | 174 | MIT | 2023-09-14T21:53:41 | 2019-02-13T22:55:46 | C# | UTF-8 | Python | false | false | 10,640 | py | cmd_entry.py | # Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
from __future__ import print_function
from .enforce_target_file_presence import find_missing_target_files
from .enforce_readme_content import verify_readme_content
from .enforce_changelog_content import verify_changelog_conte... |
e9f44eebb04a3bb7e153204db04e6fd54e260088 | 5da5473ff3026165a47f98744bac82903cf008e0 | /packages/google-cloud-enterpriseknowledgegraph/google/cloud/enterpriseknowledgegraph/__init__.py | 4323129d052fb3e97c9ee6cd2799b8c5aa65d25b | [
"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 | 2,766 | py | __init__.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... |
08fdbb3fbd34f31ffab470d9857ff33b0551b718 | 37e88c82b29bb92819ee7f82d6d24d778f78ab99 | /run.py | 407e561634d5bfad5b3d5aaf845f1f7fc03d0393 | [
"Apache-2.0"
] | permissive | phage-nz/ph0neutria | 134fc27b074618bd4b6a7685235ec5dd525eebbb | 865aae37d8503d3f580f6762aa67f65958355ba7 | refs/heads/master | 2022-07-04T15:14:29.136172 | 2020-04-24T23:37:23 | 2020-04-24T23:37:23 | 70,286,606 | 281 | 65 | Apache-2.0 | 2020-04-12T06:46:57 | 2016-10-07T22:12:20 | Python | UTF-8 | Python | false | false | 73 | py | run.py | #!/usr/bin/python3
from core.core_utils import start_core
start_core()
|
ba5e2b3f2ea512ec970212e5bd350a295075a456 | cfb5afe81701fa29c45c3fd759b0ebd46e2eb076 | /onmt/modules/embeddings.py | 87eddd39ec04add489564d275e486a5c468599bb | [
"MIT"
] | permissive | OpenNMT/OpenNMT-py | 00b533d451d6a2b907a41f531898c3d70830f16e | 2b13ed1a0f50d4555d2e1d8729a2de42940be5e4 | refs/heads/master | 2023-09-03T17:44:52.635771 | 2023-08-29T13:18:14 | 2023-08-29T13:18:14 | 82,841,862 | 6,680 | 2,749 | MIT | 2023-09-13T14:00:30 | 2017-02-22T19:01:50 | Python | UTF-8 | Python | false | false | 15,550 | py | embeddings.py | """ Embeddings module """
import math
import warnings
import torch
import torch.nn as nn
from onmt.modules.util_class import Elementwise
from onmt.utils.logging import logger
class SequenceTooLongError(Exception):
pass
class PositionalEncoding(nn.Module):
"""Sinusoidal positional encoding for non-recurren... |
d903537f7113d003d157e3d626c1ec6c7ed82bf8 | 8e90a7759ec7143427823547e0fbff58e0343aaa | /docker_sdk_api/domain/exceptions/api_request_exception.py | 44b26547bdc1570df7804ac0e9e400457d8f1700 | [
"LicenseRef-scancode-free-unknown",
"Apache-2.0"
] | permissive | BMW-InnovationLab/BMW-TensorFlow-Training-GUI | 646a6f86f26887e94351b4c572b7fe7f0842f75c | 06531dae14365986c86baf735fd149317f4bb67a | refs/heads/master | 2023-07-20T01:48:27.299962 | 2023-07-12T15:22:22 | 2023-07-12T15:22:22 | 227,429,492 | 1,030 | 198 | Apache-2.0 | 2023-05-22T17:40:23 | 2019-12-11T18:06:11 | Python | UTF-8 | Python | false | false | 300 | py | api_request_exception.py | from domain.exceptions.application_error import ApplicationError
class ApiRequestException(ApplicationError):
def __init__(self, additional_message: str = '', container_name: str = ''):
super().__init__('Api Request failed for container {}: '.format(container_name), additional_message) |
daa67b33a717c3851c69f677978620a9b38e42be | 0f2b08b31fab269c77d4b14240b8746a3ba17d5e | /tools/ci_build/github/js/validate-npm-packages.py | b009330764973da1d2a3825c7db54526f10ca775 | [
"MIT"
] | permissive | microsoft/onnxruntime | f75aa499496f4d0a07ab68ffa589d06f83b7db1d | 5e747071be882efd6b54d7a7421042e68dcd6aff | refs/heads/main | 2023-09-04T03:14:50.888927 | 2023-09-02T07:16:28 | 2023-09-02T07:16:28 | 156,939,672 | 9,912 | 2,451 | MIT | 2023-09-14T21:22:46 | 2018-11-10T02:22:53 | C++ | UTF-8 | Python | false | false | 7,821 | py | validate-npm-packages.py | #!/usr/bin/env python3
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
import os
import sys
# This is a script to validate NPM packages.
# If package version, publish tag and filename does not fulfill the requirement, an error will raise.
# arg.1 - Folder of extracted ar... |
8559d1c502471ff5db4917f88a75067829c8e5aa | 31cf77b4c0342c6148b35ae2613d5e2501d5e755 | /src/encoded/tests/fixtures/schemas/computational_model.py | 799af5e6a968f5e5c944178f3dbfaf4ccba8233b | [
"MIT"
] | permissive | ENCODE-DCC/encoded | 096de8a6d60c959a783cc9517f1d60bd6c21b71f | 80e05610c79b46d0890228555bb03e436b2fef11 | refs/heads/dev | 2023-08-08T15:45:07.493187 | 2023-08-03T20:01:24 | 2023-08-03T20:01:24 | 7,045,549 | 110 | 69 | MIT | 2023-09-12T23:59:45 | 2012-12-07T00:52:21 | JavaScript | UTF-8 | Python | false | false | 1,257 | py | computational_model.py | import pytest
@pytest.fixture
def computational_model(testapp, lab, award):
return{
'lab': lab['@id'],
'award': award['@id'],
'computational_model_type': 'imputation'
}
@pytest.fixture
def computational_model_unique_software(computational_model, software_version1, software_version2):
... |
ee36a564ac10183ef7f65a1553cbad114db4841b | a38bf459ae380f67e0de22f7106a8df4385a7076 | /tests/unit/common_types.py | a5d4a88d692222c5932f82665134e88c598a7017 | [
"Apache-2.0"
] | permissive | googleapis/gapic-generator-python | 73ce9d52f6f5bb2652d49b237b24263d6637b1da | 4eee26181e8db9fb5144eef5a76f178c1594e48a | refs/heads/main | 2023-09-04T11:12:14.728757 | 2023-09-02T10:34:44 | 2023-09-02T10:34:44 | 129,809,857 | 116 | 65 | Apache-2.0 | 2023-09-12T18:57:01 | 2018-04-16T21:47:04 | Python | UTF-8 | Python | false | false | 5,256 | py | common_types.py | # Copyright (C) 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 writi... |
275e9bcd282b12d2918dcce334af42ef6fac2358 | c3e0a6919caf85c35239ef23084df9bbf8dd61c3 | /pypeit/core/skysub.py | 565091517024b2b91b422549ffbed36e10d91a58 | [
"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 | 77,806 | py | skysub.py | """ Module for sky subtraction
.. include common links, assuming primary doc root is up one directory
.. include:: ../include/links.rst
"""
import numpy as np
import scipy.ndimage
import scipy.special
import matplotlib.pyplot as plt
from IPython import embed
from pypeit.images import imagebitmask
from pypeit.core ... |
313ae7fddb01eaa6434e21e224e8abfad36163a3 | aae3c6fccb2296e4da5bb10310f5dd6baba8b7de | /activitysim/cli/test/test_cli.py | b8f0fc3842a09c2b3eeda7ba66fba5dfa688ed12 | [
"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 | 2,168 | py | test_cli.py | # ActivitySim
# See full license in LICENSE.txt.
import os
import shutil
import subprocess
import sys
import pytest
if sys.version_info < (3, 7):
pytest.skip("capture_output introduced in Python 3.7", allow_module_level=True)
def test_help():
# cp = completed process
cp = subprocess.run(["activitysim",... |
59ca4b05ab5ef1af209d2961972061ac00e45b1c | a935ec8dab61675b6a3e348511fb9f8c5d490026 | /docs/conf.py | 4a6b9aba5fe70c8fef13f13ae1b51c0d022f79e5 | [
"MIT"
] | permissive | libAudioFlux/audioFlux | d604c54941c17d90e1ef42f04ba353ef6e244926 | 3ae59434e2c1cacb6da43562677ed4899d7047c7 | refs/heads/master | 2023-04-28T05:17:22.649299 | 2023-04-25T09:45:59 | 2023-04-25T09:45:59 | 589,514,195 | 1,701 | 85 | MIT | 2023-04-25T09:00:05 | 2023-01-16T09:53:04 | C | UTF-8 | Python | false | false | 2,425 | py | conf.py | import os
import sys
sys.path.insert(0, os.path.abspath("../python")) # NOQA
import audioflux
# Configuration file for the Sphinx documentation builder.
#
# For the full list of built-in configuration values, see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html
# -- Project informa... |
1967feb178c5425662dbf8b32faecbfbf72a1652 | 9803232b04daa00eb4038be338b833907fd1625f | /blender_bindings/source1/bsp/entities/abstract_entity_handlers.py | 18e70fcf0abfe502233052fbed61f10da9e86902 | [
"MIT"
] | permissive | REDxEYE/SourceIO | a0ff3cff37504afdb906e4ee20c1077a8daf2912 | 85661fe057cef1ad2a779a9d48e810ea214f4f07 | refs/heads/master | 2023-08-08T18:35:28.771447 | 2023-08-07T22:26:59 | 2023-08-07T22:26:59 | 170,197,673 | 409 | 53 | MIT | 2023-08-23T18:40:38 | 2019-02-11T20:33:55 | Python | UTF-8 | Python | false | false | 15,529 | py | abstract_entity_handlers.py | import math
import re
from pathlib import Path
from pprint import pformat
from typing import List
import bpy
import numpy as np
from mathutils import Euler
from ....operators.import_settings_base import BSPSettings
from .....library.shared.content_providers.content_manager import \
ContentManager
from .....librar... |
3167d0398441995e7e8664513789d61fc069e9f1 | 98f1a0bfa5b20a0b81e9e555d76e706c62d949c9 | /examples/sparse/pagerank.py | 516c07a13ab71155e1ff07fa1b05b3e90e464607 | [
"Apache-2.0"
] | permissive | dmlc/dgl | 3a8fbca3a7f0e9adf6e69679ad62948df48dfc42 | bbc8ff6261f2e0d2b5982e992b6fbe545e2a4aa1 | refs/heads/master | 2023-08-31T16:33:21.139163 | 2023-08-31T07:49:22 | 2023-08-31T07:49:22 | 130,375,797 | 12,631 | 3,482 | Apache-2.0 | 2023-09-14T15:48:24 | 2018-04-20T14:49:09 | Python | UTF-8 | Python | false | false | 792 | py | pagerank.py | import dgl.sparse as dglsp
import networkx as nx
import torch
N = 100
DAMP = 0.85
K = 10
def pagerank(A):
D = A.sum(0)
V = torch.ones(N) / N
for _ in range(K):
########################################################################
# (HIGHLIGHT) Take the advantage of DGL sparse APIs to c... |
be8a263ffcb075085766845286dda0b34f30d9d3 | 36ef8b40191c13344a5b3fb6bb2ab1cfb64b83a8 | /December-11/python_UjjwalPrahladka_Dec11.py | 0306899586f4be8a08e3e979cb41c72aba754f0e | [
"MIT"
] | permissive | SVCE-ACM/A-December-of-Algorithms-2019 | a9e2436b29db8ed5e488719c6e45c78ccbd49bec | d15a4e8284c8576b7080c999d4b46748f4d1d09b | refs/heads/master | 2023-02-03T20:45:17.211079 | 2022-08-13T07:41:13 | 2022-08-13T07:41:13 | 222,771,373 | 231 | 193 | MIT | 2023-06-18T04:02:23 | 2019-11-19T19:18:36 | JavaScript | UTF-8 | Python | false | false | 220 | py | python_UjjwalPrahladka_Dec11.py | import re
regex = '^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$'
email = input("Enter email: ")
if(re.search(regex,email)):
print("Valid Email")
else:
print("Invalid Email")
|
7795b3bfb9812301dd9428f857fc1918513d1020 | 0db05f7b843e8450bafd5ae23f8f70f9a9a8c151 | /Src/StdLib/Lib/site-packages/win32/Demos/BackupRead_BackupWrite.py | e35ad5888e835d026a14d446db587e853f9372c4 | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0",
"BSD-3-Clause",
"Python-2.0",
"LGPL-2.0-only"
] | permissive | IronLanguages/ironpython2 | 9c7f85bd8e6bca300e16f8c92f6384cecb979a6a | d00111890ce41b9791cb5bc55aedd071240252c4 | refs/heads/master | 2023-01-21T21:17:59.439654 | 2023-01-13T01:52:15 | 2023-01-13T01:52:15 | 91,620,472 | 1,171 | 288 | Apache-2.0 | 2023-01-13T01:52:16 | 2017-05-17T21:11:51 | Python | UTF-8 | Python | false | false | 3,556 | py | BackupRead_BackupWrite.py | ## demonstrates using BackupRead and BackupWrite to copy all of a file's data streams
import win32file, win32api, win32con, win32security, ntsecuritycon
from win32com import storagecon
import pythoncom, pywintypes
import struct, traceback
from pywin32_testutil import str2bytes, ob2memory
all_sd_info=win32security.DAC... |
6c0c7cb6f4db5c2dd808f7ac31fbca61c16ad6cb | 88dd4380e0d33d4a118ca4e69e4ca9b1c8f45e1f | /pyspedas/rbsp/load.py | 8137ec4a8ee666ddfa9ed7dc7e02c5b47dfdd220 | [
"MIT"
] | permissive | spedas/pyspedas | 16d34015961e3a4d3eaf8637d3cb6abca95df1b1 | 1d07b148753afa96e148c5835ed9545c507577da | refs/heads/master | 2023-09-01T16:07:47.131334 | 2023-08-25T17:15:35 | 2023-08-25T17:15:35 | 167,614,292 | 125 | 61 | MIT | 2023-09-08T18:41:27 | 2019-01-25T21:11:14 | Python | UTF-8 | Python | false | false | 5,244 | py | load.py | from pyspedas.utilities.dailynames import dailynames
from pyspedas.utilities.download import download
from pytplot import time_clip as tclip
from pytplot import cdf_to_tplot
from .config import CONFIG
def load(trange=['2018-11-5', '2018-11-6'],
probe='a',
instrument='emfisis',
level='l3',... |
581ffe6e886b4ec12e251a0c397d0d579224d6a5 | 704976ea552111c6a5af9cd7cb62b9d9abaf3996 | /pypy/module/cpyext/pystrtod.py | 775db1194701dc532f0c9c1f1c9a9a7e5afedb42 | [
"BSD-3-Clause"
] | permissive | mesalock-linux/mesapy | 4f02c5819ce7f2f6e249d34840f1aa097577645d | ed546d59a21b36feb93e2309d5c6b75aa0ad95c9 | refs/heads/mesapy2.7 | 2023-08-16T21:33:02.239581 | 2019-08-13T10:29:43 | 2019-08-13T18:06:45 | 136,080,721 | 396 | 33 | NOASSERTION | 2020-04-01T03:05:18 | 2018-06-04T20:45:17 | Python | UTF-8 | Python | false | false | 5,084 | py | pystrtod.py | import errno
from pypy.interpreter.error import oefmt
from pypy.module.cpyext.api import cpython_api, CONST_STRING
from pypy.module.cpyext.pyobject import PyObject
from rpython.rlib import rdtoa
from rpython.rlib import rfloat
from rpython.rlib import rposix, jit
from rpython.rlib.rarithmetic import intmask
from rpytho... |
de3db362623c536ac281e2ff9b38567030b75e77 | f3806d9fb54773908cd9704121a543b114470aca | /angr/procedures/glibc/__ctype_toupper_loc.py | 521a433d1aae7f4cd31da2f6980d9a23013abbe3 | [
"BSD-2-Clause"
] | permissive | angr/angr | 8ae95fceca51b0a001de56477d984dd01193ac1d | 37e8ca1c3308ec601ad1d7c6bc8081ff38a7cffd | refs/heads/master | 2023-08-17T03:15:21.007865 | 2023-08-15T18:44:57 | 2023-08-15T18:44:57 | 40,328,394 | 7,184 | 1,306 | BSD-2-Clause | 2023-09-14T20:14:23 | 2015-08-06T21:46:55 | Python | UTF-8 | Python | false | false | 892 | py | __ctype_toupper_loc.py | import angr
######################################
# __ctype_toupper_loc
######################################
class __ctype_toupper_loc(angr.SimProcedure):
"""
Following is the description from linuxfoundation.org:
The __ctype_toupper_loc() function shall return a pointer into an array
of characte... |
1c82f77c8f09515f78c389bb4ae2c9b41ae2b097 | e51ec12f619d0adf0bad7cc4a8851415ed89ddab | /torch_struct/cky_crf.py | f9e16a129c70a8d49956ffeda40b4d18365d8fbd | [
"MIT"
] | permissive | harvardnlp/pytorch-struct | 9cc0e3167b4fe00e025216176ca054bb537f600e | 7146de5659ff17ad7be53023c025ffd099866412 | refs/heads/master | 2023-07-10T10:23:57.946098 | 2022-01-30T19:49:08 | 2022-01-30T19:49:08 | 204,547,575 | 1,139 | 91 | MIT | 2022-01-30T19:49:10 | 2019-08-26T19:34:30 | Jupyter Notebook | UTF-8 | Python | false | false | 1,391 | py | cky_crf.py | import torch
from .helpers import _Struct, Chart
A, B = 0, 1
class CKY_CRF(_Struct):
def _check_potentials(self, edge, lengths=None):
batch, N, _, NT = self._get_dimension(edge)
edge = self.semiring.convert(edge)
if lengths is None:
lengths = torch.LongTensor([N] * batch).to(e... |
830ddf2b1dd51ef6e79f197160e4418d83059d73 | 73305ddcc6dc9775b1e9a71506e2f3c74f678edc | /starthinker_ui/website/management/commands/announce.py | 869e63a5fe5dc0cb14f1bdb9d207b24f909eeb40 | [
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer"
] | permissive | google/starthinker | ef359557da4140275a8524d0d813eecf022ece9e | b596df09c52511e2e0c0987f6245aa4607190dd0 | refs/heads/master | 2023-08-25T21:16:45.578012 | 2023-07-17T22:19:18 | 2023-07-17T22:20:10 | 123,017,995 | 167 | 64 | Apache-2.0 | 2023-08-02T01:24:51 | 2018-02-26T19:15:09 | Python | UTF-8 | Python | false | false | 4,195 | py | announce.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
#
# https://www.apache.org/l... |
b8b284273226d8710523588c550dbe0a2a881493 | dcee09bdd347bbb0e46b6133a7e348f0be90d9f3 | /tests/test_RunJob.py | 4c871b564343785696f8bb117ed22a85374db19a | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | Accenture/jenkins-attack-framework | 01a7964fa6561d748bbfaa1a78a3f32dba2315f4 | ce0de8e2c014ccc42ae0f159e40f36415a86e9e3 | refs/heads/master | 2023-04-18T14:15:32.116078 | 2021-05-11T13:47:56 | 2021-05-11T13:47:56 | 364,371,887 | 511 | 54 | MIT | 2021-05-11T13:47:57 | 2021-05-04T20:01:00 | Python | UTF-8 | Python | false | false | 12,237 | py | test_RunJob.py | import concurrent.futures
import os
import random
import string
import tempfile
import unittest
import warnings
from libs.JAF.BaseCommandLineParser import BaseCommandLineParser
from libs.JAF.plugin_RunJob import RunJob, RunJobParser
from .configuration import (
computer_linux,
computer_windows_admin,
comp... |
8f62ceb617f30072de639bfd1366a4423ea8aec9 | f487532281c1c6a36a5c62a29744d8323584891b | /sdk/python/pulumi_azure/appservice/hybrid_connection.py | 0f3fd4eb067fc522d7cb454e86f59556190151f8 | [
"BSD-3-Clause",
"MPL-2.0",
"Apache-2.0"
] | permissive | pulumi/pulumi-azure | a8f8f21c46c802aecf1397c737662ddcc438a2db | c16962e5c4f5810efec2806b8bb49d0da960d1ea | refs/heads/master | 2023-08-25T00:17:05.290397 | 2023-08-24T06:11:55 | 2023-08-24T06:11:55 | 103,183,737 | 129 | 57 | Apache-2.0 | 2023-09-13T05:44:10 | 2017-09-11T20:19:15 | Java | UTF-8 | Python | false | false | 27,790 | py | hybrid_connection.py | # 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 copy
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
fr... |
d6a62ce5a6b3a9353f03bc40b1a85ccf47bb0922 | a5a99f646e371b45974a6fb6ccc06b0a674818f2 | /HLTrigger/Configuration/python/HLT_75e33/psets/lowPtQuadStepTrajectoryFilter_cfi.py | 7fe52f635e599e365ea6e51c183e85425cacf826 | [
"Apache-2.0"
] | permissive | cms-sw/cmssw | 4ecd2c1105d59c66d385551230542c6615b9ab58 | 19c178740257eb48367778593da55dcad08b7a4f | refs/heads/master | 2023-08-23T21:57:42.491143 | 2023-08-22T20:22:40 | 2023-08-22T20:22:40 | 10,969,551 | 1,006 | 3,696 | Apache-2.0 | 2023-09-14T19:14:28 | 2013-06-26T14:09:07 | C++ | UTF-8 | Python | false | false | 376 | py | lowPtQuadStepTrajectoryFilter_cfi.py | import FWCore.ParameterSet.Config as cms
lowPtQuadStepTrajectoryFilter = cms.PSet(
ComponentType = cms.string('CompositeTrajectoryFilter'),
filters = cms.VPSet(
cms.PSet(
refToPSet_ = cms.string('lowPtQuadStepTrajectoryFilterBase')
),
cms.PSet(
refToPSet_ = cms.s... |
b3d334902e36cd7bac29c4637c69ca1602609b1f | 1ccc111bcdc11bf10309d0ec6df731b6105b6d95 | /tests/test_cu/models.py | e9c8202dd9d4b2513bd7b4284b6b97c296b863e5 | [
"BSD-3-Clause"
] | permissive | django/django-localflavor | 1d7b2d84a85302bf2c0a04b30ece69705c56dea9 | c539612758ded5fcb3fbb5cb5ff20f1b0de96fcc | refs/heads/master | 2023-09-03T03:15:09.070463 | 2023-04-24T09:13:53 | 2023-04-24T09:13:53 | 10,264,130 | 703 | 274 | BSD-3-Clause | 2023-07-28T04:48:02 | 2013-05-24T10:20:36 | Python | UTF-8 | Python | false | false | 409 | py | models.py | from django.db import models
from localflavor.cu.models import CUIdentityCardNumberField, CUPostalCodeField, CUProvinceField, CURegionField
class CUSomebody(models.Model):
province_1 = CUProvinceField()
province_2 = CUProvinceField(blank=True)
region_1 = CURegionField()
region_2 = CURegionField(blank... |
1675a2d972d9f20d7998215a9ccd0772868a3b83 | 5130754859e274cd06f63260439e5203c2000a11 | /core/jobs/transforms/validation/question_validation_test.py | c2e238b17857b64318e476323e522369ff1ce73e | [
"Apache-2.0"
] | permissive | oppia/oppia | 8ebc9c7c7f2b336e9a79ce04533abe3956f48cbe | d16fdf23d790eafd63812bd7239532256e30a21d | refs/heads/develop | 2023-09-04T07:50:13.661276 | 2023-09-03T09:21:32 | 2023-09-03T09:21:32 | 40,687,563 | 6,172 | 4,666 | Apache-2.0 | 2023-09-14T18:25:11 | 2015-08-14T00:16:14 | Python | UTF-8 | Python | false | false | 9,676 | py | question_validation_test.py | # coding: utf-8
#
# Copyright 2021 The Oppia 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 requi... |
ea1c4d3312f95e1cc7e7a51201ba8d2daba60111 | 54ab1a59d528c4f6e15193daf129e6d58856ba8b | /guess.py | 8fb3b11ef471b7cb354898fc2165f20e01a2ffa6 | [] | no_license | mjhea0/python-ruby | bfd52b3f790b33924aea9b52457685a534e18aaf | c79432e1fb64db865209911db1ae66c3b9b1f5a7 | refs/heads/master | 2023-06-30T20:26:18.940912 | 2021-12-04T15:48:32 | 2021-12-04T15:48:32 | 16,994,945 | 265 | 43 | null | 2021-12-04T15:48:33 | 2014-02-19T18:55:32 | Python | UTF-8 | Python | false | false | 660 | py | guess.py | #!/usr/bin/python3
import random
number = random.randint(1, 20)
guesses = 0
print('Hello! What is your name?')
name = input()
print(f"Hi, {name}. I'm thinking of a number from 1 and 20.")
while guesses < 6:
print(f'What is your guess? You have {6 - guesses} more guesses.')
guess = input()
guess = int(... |
35cc2ad414d7872c87273bf8ae5922dce5f214f7 | 5a52ccea88f90dd4f1acc2819997fce0dd5ffb7d | /alipay/aop/api/domain/AlipayEbppInvoiceExpenserulesProjectemployeeModifyModel.py | 97882dccbaf29eceff776d8970f2280fefd21f0c | [
"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 | 6,579 | py | AlipayEbppInvoiceExpenserulesProjectemployeeModifyModel.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.constant.ParamConstants import *
class AlipayEbppInvoiceExpenserulesProjectemployeeModifyModel(object):
def __init__(self):
self._account_id = None
self._add_employee_list = None
self._add_employee_open_id_list... |
14d9e0008a0f5df18719f31d506d720e21bc8cd2 | cf018ce220ee461704e7fedf842dbf074025da54 | /pytest/test_002_personalize_reset.py | dfacdeba0a3ad740342c02f0f53581c74cfb5078 | [] | no_license | solokeys/openpgp | fdc0096b2f294746959519e5858aa9eec841ecf7 | 5e5080f2b258b11921573dab87167d69cebef00d | refs/heads/master | 2021-06-26T05:53:10.663925 | 2021-06-14T16:11:17 | 2021-06-14T16:11:17 | 187,276,756 | 122 | 11 | null | 2021-06-25T01:30:28 | 2019-05-17T20:20:30 | C | UTF-8 | Python | false | false | 42 | py | test_002_personalize_reset.py | from card_test_personalize_reset import *
|
21970d73f6360a5b8bf598a885f89029545cb6be | 76f23cc69dc10c44bc7cf00b78e37db04c7a9c45 | /datalad/distribution/utils.py | 3ef3ca4be07d45047f5f232e57ad4f83572eb244 | [
"BSD-3-Clause",
"MIT"
] | permissive | datalad/datalad | 2d9c247344d340325ba84e7ab674ac320e57f30c | 40332b5ad25bf8744f7399f6c3575f7d28f71384 | refs/heads/maint | 2023-09-04T11:03:02.264714 | 2023-08-10T15:56:19 | 2023-08-10T15:56:19 | 14,052,034 | 453 | 134 | NOASSERTION | 2023-09-14T19:10:18 | 2013-11-01T19:40:08 | Python | UTF-8 | Python | false | false | 5,157 | py | utils.py | # emacs: -*- mode: python; py-indent-offset: 4; tab-width: 4; indent-tabs-mode: nil -*-
# ex: set sts=4 ts=4 sw=4 et:
# ## ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ##
#
# See COPYING file distributed along with the datalad package for the
# copyright and license terms.
#
# ## ### ### ... |
d10638a463dd7c2fae7aadc93c0cecc9fe58ba42 | f576f0ea3725d54bd2551883901b25b863fe6688 | /sdk/cognitiveservices/azure-cognitiveservices-language-luis/azure/cognitiveservices/language/luis/authoring/operations/_train_operations.py | c48ed5feb317af90e53f8867af314c322597823d | [
"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 | 6,694 | py | _train_operations.py | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes ... |
6037bac294374fa4c504c6c302ff2aa597a3dcae | 7af0ff378525ef6132f74bac0b1eb54ce4c40c08 | /indico/modules/events/registration/forms.py | 8c0077cd1f93856de8b0fb21499fabeff0af9186 | [
"MIT"
] | permissive | indico/indico | 1126ee0ac3e9d36510a64989ce71be9c02680831 | 463951511d3a8409f944f98f29875c4323f3e897 | refs/heads/master | 2023-08-31T11:15:00.092526 | 2023-08-30T11:07:25 | 2023-08-30T11:07:25 | 2,113,067 | 1,549 | 429 | MIT | 2023-09-13T20:09:56 | 2011-07-27T13:56:30 | Python | UTF-8 | Python | false | false | 34,465 | py | forms.py | # This file is part of Indico.
# Copyright (C) 2002 - 2023 CERN
#
# Indico is free software; you can redistribute it and/or
# modify it under the terms of the MIT License; see the
# LICENSE file for more details.
from datetime import time, timedelta
from operator import itemgetter
import jsonschema
from flask import ... |
8aa087623b133486d16a6732fafadf5bf8870b20 | fa1ad2e2ac7e376fc7cb3b3a6e1bb88eed3e80be | /olap/ByConity/tests/testflows/rbac/tests/privileges/show/show_columns.py | 108200e7a579652bf40cb9f3e7ab793710610427 | [
"Apache-2.0",
"BSD-3-Clause",
"MIT"
] | permissive | alldatacenter/alldata | 7bc7713c9f1d56ad6b8e59ea03206d1073b7e047 | 8d5f9a2d49ab8f9e85ccf058cb02c2fda287afc6 | refs/heads/master | 2023-08-05T07:32:25.442740 | 2023-08-03T13:17:24 | 2023-08-03T13:17:24 | 213,321,771 | 774 | 250 | Apache-2.0 | 2023-09-06T17:35:32 | 2019-10-07T07:36:18 | null | UTF-8 | Python | false | false | 8,318 | py | show_columns.py | from testflows.core import *
from testflows.asserts import error
from rbac.requirements import *
from rbac.helper.common import *
import rbac.helper.errors as errors
@TestSuite
def describe_with_privilege_granted_directly(self, node=None):
"""Check that user is able to execute DESCRIBE on a table if and only if
... |
c51a3725bdb42d1db6cec8329f80e9ec11898266 | b3950a2a6912c9b494d22b9353322c3357df0110 | /tock/api/views.py | d0de0c995cfb8cf199ea04baf49402f23b7005c4 | [
"CC0-1.0",
"LicenseRef-scancode-public-domain",
"MIT"
] | permissive | 18F/tock | df1fa5e817e690ce0bff315a15799e2f78915882 | 99005d8f6c4605a69fbb620c41f38447ecbee459 | refs/heads/main | 2023-08-31T01:34:55.299577 | 2023-08-23T18:49:10 | 2023-08-23T18:49:10 | 30,162,008 | 135 | 50 | NOASSERTION | 2023-09-07T18:40:30 | 2015-02-01T22:19:32 | Python | UTF-8 | Python | false | false | 16,038 | py | views.py | import collections
import datetime
from django.contrib.auth import get_user_model
from django.db import connection
from django.db.models import Count, F
from django.utils.html import escape
from rest_framework import serializers, generics
from rest_framework.exceptions import ParseError
from hours.models import Time... |
9dbd47b0d3e4a50976e7d61b0b3995d499e0fc69 | 03666e5f961946fc1a0ac67781ac1425562ef0d7 | /src/visitpy/visit_flow/flow/src/core/workspace.py | 128dc7b241d906cc27ebb15cbe362b3e25ed690d | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | visit-dav/visit | e9f81b4d4b9b9930a0db9d5282cd1bcabf465e2e | 601ae46e0bef2e18425b482a755d03490ade0493 | refs/heads/develop | 2023-09-06T08:19:38.397058 | 2023-09-05T21:29:32 | 2023-09-05T21:29:32 | 165,565,988 | 335 | 120 | BSD-3-Clause | 2023-09-14T00:53:37 | 2019-01-13T23:27:26 | C | UTF-8 | Python | false | false | 18,192 | py | workspace.py | # Copyright (c) Lawrence Livermore National Security, LLC and other VisIt
# Project developers. See the top-level LICENSE file for dates and other
# details. No copyright assignment is required to contribute to VisIt.
"""
file: workspace.py
author: Cyrus Harrison <cyrush@llnl.gov>
created: 10/14/2010
description... |
ba3589413d92c82682d3682bcc91df552ff73644 | 5ef6c8d47864f471e26b9902d61f8c687e941f05 | /src/genie/libs/parser/nxos/tests/ShowIpOspfInterface/cli/equal/golden_output_3_expected.py | cdda27c542ddfcc6853d4ccd8d817a1f9d4ab162 | [
"Apache-2.0"
] | permissive | CiscoTestAutomation/genieparser | 169c196558f1c1a0f0d10650876096f993224917 | b531eff760b2e44cd69d7a2716db6f866907c239 | refs/heads/master | 2023-09-03T08:56:18.831340 | 2023-08-29T22:32:02 | 2023-08-29T22:32:02 | 131,621,824 | 247 | 409 | Apache-2.0 | 2023-08-29T22:32:04 | 2018-04-30T16:51:50 | Python | UTF-8 | Python | false | false | 14,731 | py | golden_output_3_expected.py |
expected_output = {
'vrf': {
'GENIE-CORE': {
'address_family': {
'ipv4': {
'instance': {
'1000': {
'areas': {
'0.0.0.1': {
'interfaces': {... |
036c688eddb01d27c564952dbe2c69f64091d52a | 364774e29ef2474552ea3839de0951e63cbae0a6 | /wouso/games/quest/forms.py | 6748188558afd6d7e60c9bbafb45255518e13b7c | [
"Apache-2.0"
] | permissive | rosedu/wouso | 66c50ef750cf79d6959768f7df93cc08607cc266 | ed34c62ac925db719388f27fe5acb40376d8d0c1 | refs/heads/master | 2022-10-29T14:28:51.818073 | 2022-09-24T18:54:04 | 2022-09-24T18:54:04 | 2,965,476 | 121 | 97 | NOASSERTION | 2019-11-15T09:33:50 | 2011-12-12T16:15:01 | Python | UTF-8 | Python | false | false | 541 | py | forms.py | from django.forms import CharField, Form, ModelForm, TextInput
from models import Quest
from bootstrap3_datetime import widgets
class QuestForm(Form):
answer = CharField(max_length=4000, widget=TextInput)
class QuestCpanel(ModelForm):
class Meta:
model = Quest
widgets = {
'star... |
2ad2da1d46da54c851d85763fa75baf8fa67d757 | de187dda5faed88c256d743dc2b15cc25294878d | /newton-4.00/applications/toolsAndWrapers/newtonPy/newtonWorld.py | 26e6ccb89b2bde0464a80e092bb9a6272de082f2 | [
"Zlib"
] | permissive | MADEAPPS/newton-dynamics | 77cb9db982f205559bd23b6053281726ea6cf3d5 | 7e8a2e09a44a04a24e2553e203cf50fd8e9dea05 | refs/heads/master | 2023-08-30T20:45:08.566223 | 2023-08-30T16:47:29 | 2023-08-30T16:47:29 | 21,649,756 | 1,145 | 248 | NOASSERTION | 2023-06-03T16:24:56 | 2014-07-09T11:21:47 | HTML | UTF-8 | Python | false | false | 3,931 | py | newtonWorld.py | # Copyright (c) <2003-2021> <Newton Game Dynamics>
# This software is provided 'as-is', without any express or implied
# warranty. In no event will the authors be held liable for any damages
# arising from the use of this software.
# Permission is granted to anyone to use this software for any purpose,
# including ... |
8dcd0d522bdcad3a319fce5e9439f281339b73da | 362196f32e8248e025cb2f6cf0b88f812c9a059c | /juriscraper/opinions/united_states/state/nc.py | 473c637650a1a104375b9f00b517621a5a958997 | [
"BSD-3-Clause",
"LicenseRef-scancode-generic-cla",
"LicenseRef-scancode-unknown-license-reference",
"BSD-2-Clause"
] | permissive | freelawproject/juriscraper | 0fea8d4bb512808cb1e036aaaf819e9cc0847a6b | d2c6672696e13e33ec9981a1901b87047d8108c5 | refs/heads/main | 2023-08-09T13:27:21.357915 | 2023-07-06T22:33:01 | 2023-07-06T22:33:01 | 22,757,589 | 283 | 97 | BSD-2-Clause | 2023-09-08T22:59:36 | 2014-08-08T12:50:35 | HTML | UTF-8 | Python | false | false | 6,813 | py | nc.py | """Scraper for North Carolina Supreme Court
CourtID: nc
Court Short Name: N.C.
Reviewer:
History:
2014-05-01: Created by Brian Carver
2014-08-04: Rewritten by Jon Andersen with complete backscraper
"""
import re
import traceback
from datetime import date, datetime
from lxml import html
from juriscraper.lib.e... |
5b0118114f43dfff9864fed56a0de1e5434ef0c5 | 4e83833ce426ec867bc26252f7aa1d9dd940092f | /pfrl/experiments/train_agent_batch.py | add7cda81d597f2a93ab8fed51bdf038974c4078 | [
"MIT"
] | permissive | pfnet/pfrl | 66803adbaeb33bf7a71b4dbaa17b76f5cc21fd1b | b29533b77c82f88fbc074714274ee8aa63dc270f | refs/heads/master | 2023-07-25T23:47:01.208427 | 2023-07-16T15:16:10 | 2023-07-16T15:16:10 | 274,629,316 | 1,115 | 167 | MIT | 2023-07-16T15:16:11 | 2020-06-24T09:31:50 | Python | UTF-8 | Python | false | false | 9,144 | py | train_agent_batch.py | import logging
import os
from collections import deque
import numpy as np
from pfrl.experiments.evaluator import Evaluator, save_agent
def train_agent_batch(
agent,
env,
steps,
outdir,
checkpoint_freq=None,
log_interval=None,
max_episode_len=None,
step_offset=0,
evaluator=None,
... |
9299973a0cdcffec161efe881bad747b5d1005c9 | 3ec38f732b21b0a00e822dac730bdc1748902144 | /test/unit/oscar/test_controller.py | 7324a762ca918219f9a24af60246b40e120ff242 | [
"Apache-2.0"
] | permissive | grycap/scar | e5594c1eb79a0730409c97d48bc511757a05dcbd | e6c8b06a43b310d2c1e58d7826239e259dd826d7 | refs/heads/master | 2023-08-22T00:39:28.004454 | 2023-05-22T11:01:10 | 2023-05-22T11:01:10 | 91,441,209 | 613 | 59 | Apache-2.0 | 2022-11-29T06:36:46 | 2017-05-16T09:35:57 | Python | UTF-8 | Python | false | false | 3,563 | py | test_controller.py | #! /usr/bin/python
# Copyright (C) GRyCAP - I3M - UPV
#
# 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 ... |
58082603ddfde3181876ef291bf603607548cb9a | 0a16415a4e7657570b95e96c16a9bffbeeddd279 | /kapture/core/Observations.py | f9cd002aa2b3f2774dcd7c7d83377285d12d2000 | [
"MIT",
"BSD-3-Clause"
] | permissive | naver/kapture | 13fda56217751ac12c77f0be658815ea6a598fa8 | 392677fb974aaa7c9c7c65d05c09abdb8a681124 | refs/heads/main | 2023-08-24T16:25:20.195565 | 2023-03-29T15:58:07 | 2023-03-29T15:58:07 | 275,164,995 | 386 | 64 | BSD-3-Clause | 2023-09-04T15:48:49 | 2020-06-26T13:40:30 | Python | UTF-8 | Python | false | false | 4,470 | py | Observations.py | # Copyright 2020-present NAVER Corp. Under BSD 3-clause license
from typing import Dict, List, Tuple, Union
class Observations(Dict[int, Dict[str, List[Tuple[str, int]]]]):
"""
Observations. This can be used like this:
- observations[point3d_idx][keypoints_type] = list( observation )
- observation =... |
8be55f05e28060e88811edd14ec7b5b4ec4c660e | d110546d747d7e3865ce5742d5fca09f404623c0 | /salt/sdb/redis_sdb.py | 1419e3813c8f4026ef6224bf61f7f644bf0019a7 | [
"Apache-2.0",
"MIT",
"BSD-2-Clause"
] | permissive | saltstack/salt | 354fc86a7be1f69514b3dd3b2edb9e6f66844c1d | 1ef90cbdc7203f97775edb7666db86a41eb9fc15 | refs/heads/master | 2023-07-19T20:56:20.210556 | 2023-06-29T23:12:28 | 2023-07-19T11:47:47 | 1,390,248 | 11,026 | 6,296 | Apache-2.0 | 2023-09-14T20:45:37 | 2011-02-20T20:16:56 | Python | UTF-8 | Python | false | false | 1,766 | py | redis_sdb.py | """
Redis SDB module
================
.. versionadded:: 2019.2.0
This module allows access to Redis using an ``sdb://`` URI.
Like all SDB modules, the Redis module requires a configuration profile to
be configured in either the minion or master configuration file. This profile
requires very little. For example:
.... |
1b97162336d9a7ed7a8264f7889942c8b62ecb81 | 6be59c81f3f6a17c14b812be0de3346a82eb33dd | /data_science/pandas_demo/groupby_demo.py | d271010c6890d7e79b5aeef9613513d7639a291f | [] | no_license | chunhuizhang/bilibili_vlogs | 6851fdcd43f08fcf7195e345b0bc85d99c0b9128 | 0efd921b24f2af43f5972ea6909deb2fc069d305 | refs/heads/master | 2023-08-17T15:47:04.299072 | 2023-08-14T13:46:31 | 2023-08-14T13:46:31 | 220,612,967 | 170 | 70 | null | null | null | null | UTF-8 | Python | false | false | 440 | py | groupby_demo.py | import pandas as pd
import numpy as np
df = pd.DataFrame([('bird', 'Falconiformes', 389.0),
('bird', 'Psittaciformes', 24.0),
('mammal', 'Carnivora', 80.2),
('mammal', 'Primates', np.nan),
('mammal', 'Carnivora', 58)],
index=... |
4e51dcf6a4dce59c7130c17f73fc72ad79d0dae5 | b8bbdfc593b6d816e67a344f720f90ec05236778 | /airflow/providers/cncf/kubernetes/kubernetes_helper_functions.py | b54519fe27339b471e77a6a81d5f7773677f16da | [
"Apache-2.0",
"BSD-3-Clause",
"MIT"
] | permissive | apache/airflow | ed78db0a8bab7e096990e143926e52f518e288ab | 1b122c15030e99cef9d4ff26d3781a7a9d6949bc | refs/heads/main | 2023-09-01T08:37:34.556097 | 2023-09-01T06:49:05 | 2023-09-01T06:49:05 | 33,884,891 | 22,756 | 11,558 | Apache-2.0 | 2023-09-14T20:12:36 | 2015-04-13T18:04:58 | Python | UTF-8 | Python | false | false | 4,741 | py | kubernetes_helper_functions.py | # Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... |
ad09f1178489249f0bbe1ac89b8c04992d14a89e | 11d0cc8470722b737ac1d83610f227ffb98ea71a | /convert/ahf2csv.py | 806bfe4ea9ced908b9a5b9164efc7b63a5b04e65 | [] | no_license | EdoardoCarlesi/PyRCODIO | d86e5298877f08b597f92a07aac0c9b634dbfa39 | d3f84efb7aeec0032ef6bde839fe9440ee82b392 | refs/heads/master | 2021-04-03T04:58:26.219884 | 2021-03-21T12:22:19 | 2021-03-21T12:22:19 | 125,036,704 | 148 | 0 | null | null | null | null | UTF-8 | Python | false | false | 452 | py | ahf2csv.py | '''
Python Routines for COsmology and Data I/ (PyRCODIO) v0.2
Edoardo Carlesi 2020
ecarlesi83@gmail.com
ahf2csv.py: convert (and compress) AHF halo catalogs to csv files
'''
import pandas as pd
import sys
sys.path.insert(1, '/home/edoardo/CLUES/PyRCODIO/')
import read_files as rf
this_ahf = sys.argv[... |
23f8b0d0848b9d4a6fb37bd5ce49e98ce656ff37 | e3bb1df7fa4c51900dec7e9ddf5295e1a80938bd | /test/connector/exchange/coinbase_pro/test_coinbase_pro_user_stream_tracker.py | 38a0ad4808843b1dbbefe7b2c59b1a95e2bf24ad | [
"Apache-2.0"
] | permissive | CoinAlpha/hummingbot | 0d1e2bd94de1280748647108c7d7800a09546eb8 | c3f101759ab7e7a2165cd23a3a3e94c90c642a9b | refs/heads/development | 2023-09-01T11:24:43.322137 | 2023-08-31T03:08:06 | 2023-08-31T03:08:06 | 439,330,952 | 135 | 98 | Apache-2.0 | 2023-08-30T13:55:08 | 2021-12-17T12:50:42 | Python | UTF-8 | Python | false | false | 8,164 | py | test_coinbase_pro_user_stream_tracker.py | import asyncio
import contextlib
import logging
import time
import unittest
from decimal import Decimal
from typing import Optional
import conf
from hummingbot.connector.exchange.coinbase_pro.coinbase_pro_exchange import CoinbaseProAuth, CoinbaseProExchange
from hummingbot.connector.exchange.coinbase_pro.coinbase_pro_... |
54f4101301999c6518e86ac766c527a2ea42b7d4 | d8810093406a2ba401ac6ea300ed414bfab6b6a0 | /tests/test_dataset.py | 2fee9e315c115ec37a3f80b24bb558cd3700329d | [
"Apache-2.0"
] | permissive | mittagessen/kraken | 11b8eeaff5dcfaa62a96b0af73ebe65bc2d9bef2 | 3e966a3e5c881394b882da95fa5941c4305aec43 | refs/heads/main | 2023-08-29T05:52:06.301403 | 2023-08-17T11:25:56 | 2023-08-17T11:25:56 | 35,872,353 | 565 | 140 | Apache-2.0 | 2023-09-08T10:28:33 | 2015-05-19T09:24:38 | Python | UTF-8 | Python | false | false | 11,240 | py | test_dataset.py | # -*- coding: utf-8 -*-
import unittest
from pathlib import Path
from pytest import raises
from PIL import Image
from kraken.lib.dataset import ImageInputTransforms, BaselineSet
from kraken.lib.util import is_bitonal
from kraken.lib.exceptions import KrakenInputException
thisfile = Path(__file__).resolve().parent
r... |
585dc5b9219eff30a900bdaf1d1ca7e604af4ab2 | d75359fde22b08a4109b30bb39c9db27961fa417 | /setup.py | 5d6424034b3d9f2d743ba7becc12154686528c53 | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | authlib/loginpass | 58f0881b4e5975c305e633337d1b86657bea907b | 635823a78a2a92cf8630f9935aebb9afcccb8656 | refs/heads/master | 2022-06-08T13:08:09.271879 | 2020-12-08T06:04:39 | 2020-12-08T06:04:39 | 128,506,236 | 280 | 95 | BSD-3-Clause | 2022-05-13T19:30:54 | 2018-04-07T07:26:46 | Python | UTF-8 | Python | false | false | 1,613 | py | setup.py | #!/usr/bin/env python
import re
from setuptools import setup
_version_re = re.compile(r"version\s=\s'(.*)'")
with open('loginpass/_consts.py', 'r') as f:
version = _version_re.search(f.read()).group(1)
with open('README.rst') as read_me:
long_description = read_me.read()
setup(
name='loginpass',
... |
fbdf8aa1895ed37bba792e08c00df4e4d6219f2a | 020d68f6a3dc1d448551c4bd803bc9b9d7d7c34c | /easy_maps/migrations/0001_initial.py | 1c2e19b052524c5c5be1f86b63c0500f6fab0776 | [
"MIT"
] | permissive | bashu/django-easy-maps | be8c8cadff034934eef56c77175d3d52afec6e9e | 99930f091ee52380afa8814bd99687ef9eddc97d | refs/heads/develop | 2021-12-10T09:22:37.935387 | 2021-11-29T08:14:47 | 2021-12-01T03:49:42 | 3,122,074 | 123 | 59 | MIT | 2021-09-25T12:10:16 | 2012-01-07T00:00:24 | Python | UTF-8 | Python | false | false | 1,092 | py | 0001_initial.py | from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = []
operations = [
migrations.CreateModel(
name="Address",
fields=[
("id", models.AutoField(verbose_name="ID", serialize=False, auto_created=True, primary_key=True)),... |
836e0f9c413e717ae4a328a2ca2a73ffc0f24997 | 59f64b5cf799e31c97b11828dba4787afb8f3f17 | /batch/batch/front_end/validate.py | d18dd839f19eb320b87b891fa1a8fcd872f24a15 | [
"MIT"
] | permissive | hail-is/hail | 2089e6f3b38548f13fa5c2a8ab67f5cfdd67b4f1 | 07a483ae0f46c66f3ed6fd265b48f48c06298f98 | refs/heads/main | 2023-09-01T15:03:01.450365 | 2023-09-01T02:46:35 | 2023-09-01T02:46:35 | 45,069,467 | 913 | 262 | MIT | 2023-09-14T21:53:32 | 2015-10-27T20:55:42 | Python | UTF-8 | Python | false | false | 7,160 | py | validate.py | from hailtop.batch_client.parse import (
CPU_REGEX,
CPU_REGEXPAT,
MEMORY_REGEX,
MEMORY_REGEXPAT,
STORAGE_REGEX,
STORAGE_REGEXPAT,
)
from hailtop.utils.validate import (
ValidationError,
anyof,
bool_type,
dictof,
int_type,
keyed,
listof,
non_empty_str_type,
nul... |
9eb7830cb8fc23e1a73b9e6ec322a3d34313b1d9 | ee87c715e5d937b0380ddb87d56e9ebc4877a02b | /build_tools/circle/list_versions.py | 345e08b4bece4b83b735e6adf02990aa0d45d662 | [
"BSD-3-Clause"
] | permissive | scikit-learn/scikit-learn | 27a2196f3173e0f32f7a5c5d652b70a6c57c7644 | 061f8777b48e5491b0c57bb8e0bc7067c103079d | refs/heads/main | 2023-08-18T15:32:59.764468 | 2023-08-18T14:39:08 | 2023-08-18T14:39:08 | 843,222 | 58,456 | 29,777 | BSD-3-Clause | 2023-09-14T19:08:34 | 2010-08-17T09:43:38 | Python | UTF-8 | Python | false | false | 3,737 | py | list_versions.py | #!/usr/bin/env python3
# List all available versions of the documentation
import json
import re
import sys
from urllib.request import urlopen
from sklearn.utils.fixes import parse_version
def json_urlread(url):
try:
return json.loads(urlopen(url).read().decode("utf8"))
except Exception:
prin... |
f81eb423e7ef7b3b93b810db68d55d56242e81d6 | 974d04d2ea27b1bba1c01015a98112d2afb78fe5 | /test/xpu/test_c_concat.py | d2490aa3772dcd91f1d59af3073857314d6db0c3 | [
"Apache-2.0"
] | permissive | PaddlePaddle/Paddle | b3d2583119082c8e4b74331dacc4d39ed4d7cff0 | 22a11a60e0e3d10a3cf610077a3d9942a6f964cb | refs/heads/develop | 2023-08-17T21:27:30.568889 | 2023-08-17T12:38:22 | 2023-08-17T12:38:22 | 65,711,522 | 20,414 | 5,891 | Apache-2.0 | 2023-09-14T19:20:51 | 2016-08-15T06:59:08 | C++ | UTF-8 | Python | false | false | 1,543 | py | test_c_concat.py | # Copyright (c) 2018 PaddlePaddle 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 app... |
b9bf1075c75723e0de0ca40c75608bb05384462b | eb9f655206c43c12b497c667ba56a0d358b6bc3a | /python/helpers/typeshed/stubs/openpyxl/openpyxl/writer/excel.pyi | 57e9d2ac1884bc1f24c0b6362d940510db66028c | [
"MIT",
"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 | 358 | pyi | excel.pyi | from typing import Any
class ExcelWriter:
workbook: Any
manifest: Any
vba_modified: Any
def __init__(self, workbook, archive) -> None: ...
def write_data(self) -> None: ...
def write_worksheet(self, ws) -> None: ...
def save(self) -> None: ...
def save_workbook(workbook, filename): ...
def... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.