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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0467caeb8e03b495ae77e8ee00893b02ec306b65 | faada8dcb8fbb4de1db595ba5849789bb0ecc07d | /Regression/multiple linear/multiple_linear_rgression_with_sklearn.py | a34b45b23fa3b20784b418c755d81771805a582b | [] | no_license | yug95/MachineLearning | 77eec8b8b629ef4854b88b2db058f7136a882946 | e9a1f9bd4bfaba3bf294f2c818eb313c2f373d35 | refs/heads/master | 2023-06-21T19:26:29.885091 | 2023-01-26T07:07:43 | 2023-01-26T07:07:43 | 141,684,199 | 113 | 133 | null | 2023-09-07T14:47:52 | 2018-07-20T08:16:58 | Jupyter Notebook | UTF-8 | Python | false | false | 1,705 | py | multiple_linear_rgression_with_sklearn.py | #Mutliple linear regression using sklearn librery
import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
data = pd.read_csv('50_Startups.csv')
x = data.iloc[:,:-1].values
y = data.iloc[:,4].values
#encoding of categorical variable
from sklearn.preprocessing import LabelEncoder, OneHotEncoder
label... |
6bc32862d5fba942ad795918c00b419510909153 | dac12c9178b13d60f401c4febff5569af8aa2719 | /utils/dataset_manifest/core.py | 1be0976849c68a4514bf5e6d18f6054c19fec19f | [
"LGPL-2.0-or-later",
"MIT",
"GPL-1.0-or-later"
] | permissive | opencv/cvat | 39dc66ca20f972ba40b79c44d7ce43590dc0b0b5 | 899c9fd75146744def061efd7ab1b1c6c9f6942f | refs/heads/develop | 2023-08-19T04:27:56.974498 | 2023-08-18T09:58:25 | 2023-08-18T09:58:25 | 139,156,354 | 6,558 | 1,887 | MIT | 2023-09-14T12:44:39 | 2018-06-29T14:02:45 | TypeScript | UTF-8 | Python | false | false | 29,673 | py | core.py | # Copyright (C) 2021-2022 Intel Corporation
# Copyright (C) 2022-2023 CVAT.ai Corporation
#
# SPDX-License-Identifier: MIT
from enum import Enum
from io import StringIO
import av
import json
import os
from abc import ABC, abstractmethod, abstractproperty, abstractstaticmethod
from contextlib import closing
from PIL i... |
98fd7959a6025719d91f5b3c03db17d6a8f3f375 | d139ef8d18fcde584b06c1d7d25477d7d31ee59b | /google/ads/googleads/v14/errors/types/ad_group_criterion_error.py | 06062defdcdcfb91b10e608277f72f04e554d8fc | [
"Apache-2.0"
] | permissive | googleads/google-ads-python | a53993e6be057d3aa61f276b69e97b8b338d1c12 | 146d7070c1ea2140555d49d73c77892430b37314 | refs/heads/main | 2023-08-31T01:58:16.738997 | 2023-06-05T08:18:42 | 2023-08-28T19:08:38 | 143,435,091 | 422 | 525 | Apache-2.0 | 2023-09-12T17:46:52 | 2018-08-03T14:08:04 | Python | UTF-8 | Python | false | false | 2,569 | py | ad_group_criterion_error.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... |
8782e95b4865552c8f35156979699ee41c8c1ff0 | f62cd59f7e5c8d22b4d9ad130eff0a70d0272341 | /tests/test_tools.py | 8bd022cf2be61adcacbe57d97df83e7992336e78 | [
"MIT"
] | permissive | alexanderlerch/pyACA | 61ea3c1b9350562bc248fa45b7bba3246e98686d | 3ee1dde02999cf0a0e512ee73e021ea618303a89 | refs/heads/master | 2023-05-22T18:43:09.506175 | 2022-09-12T18:37:24 | 2022-09-12T18:37:24 | 195,197,713 | 141 | 37 | MIT | 2022-01-06T15:19:40 | 2019-07-04T08:09:05 | Python | UTF-8 | Python | false | false | 18,513 | py | test_tools.py | import unittest
import numpy as np
import numpy.testing as npt
import pyACA
class TestTools(unittest.TestCase):
def test_nmf(self):
np.random.seed(42)
X = np.random.rand(128, 6) / 20
X[np.arange(4, 128, 4), 0:2] = 1
X[np.arange(7, 128, 7), 2:4] = 1
X[:, 4:6] = 0.7 * X[:, ... |
320d0005ea1e0e02c1bac8907ce78edced889988 | 3afe7348e830a0c5139fb7cf393736e18b59ab4a | /src/clusterfuzz/_internal/platforms/android/settings.py | a70c75ddb6620660f0a5fbb0d4b2319e2d7e7a76 | [
"Apache-2.0"
] | permissive | google/clusterfuzz | 00845899e081dbbb89b70a75ce0b7eba3da73b02 | 6501a839b27a264500244f32bace8bee4d5cb9a2 | refs/heads/master | 2023-09-03T17:34:17.821599 | 2023-09-01T16:11:51 | 2023-09-01T16:11:51 | 168,060,021 | 5,420 | 639 | Apache-2.0 | 2023-09-13T16:40:54 | 2019-01-29T00:19:40 | Python | UTF-8 | Python | false | false | 6,241 | py | settings.py | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... |
061ce8aa8c674df67813e759a5c5d6456dc5aa90 | 88dd4380e0d33d4a118ca4e69e4ca9b1c8f45e1f | /pyspedas/polar/config.py | 82982557a9a73019d80ff3ee3c48b5c118460ab0 | [
"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 | 409 | py | config.py | import os
CONFIG = {'local_data_dir': 'polar_data/',
'remote_data_dir': 'https://spdf.gsfc.nasa.gov/pub/data/polar/'}
# override local data directory with environment variables
if os.environ.get('SPEDAS_DATA_DIR'):
CONFIG['local_data_dir'] = os.sep.join([os.environ['SPEDAS_DATA_DIR'], 'polar'])
if os.e... |
3b9d44f9dc4f5d362ca6c830e76093a16f31f372 | 657541b2f4ba1939b6be28231f721a1251a7062e | /Chapter 06/ch06_r04.py | a4bd3a9bca5a835bf822bb6023add4e4d727d49b | [
"MIT"
] | permissive | PacktPublishing/Modern-Python-Cookbook | 0562237aa479b07ac4ea65000c3c9942fd36383f | 5b76b34b3020789ca1d0412b7cfd9527a7b344a1 | refs/heads/master | 2023-02-05T01:00:37.040849 | 2023-01-30T10:09:08 | 2023-01-30T10:09:08 | 74,134,183 | 121 | 79 | MIT | 2019-03-09T16:17:28 | 2016-11-18T13:57:34 | Python | UTF-8 | Python | false | false | 1,590 | py | ch06_r04.py | """Python Cookbook
Chapter 6, recipe 3 and 4
"""
import random
from collections import namedtuple
Card = namedtuple('Card', ('rank', 'suit'))
class Hand:
"""
>>> h = Hand(1)
>>> h.deal( Card(1,'\N{white heart suit}'))
>>> h.deal( Card(10, '\N{black club suit}'))
>>> h
Hand(1, [Card(rank=1, su... |
b905c1c8eefeca74a68ace255fa3bfad3d4fed4c | 6a468c1650b3c083f102f19ace0b0d6e4d0686f7 | /sympy/calculus/singularities.py | 3a2ea1a17c3b69d9e49a481cec794c0d86df834c | [
"BSD-3-Clause",
"MIT"
] | permissive | sympy/sympy | a5f8accaa7686c59d9b5c94212fef60d746dac4b | 69f98fb2b0d845e76874067a381dba37b577e8c5 | refs/heads/master | 2023-09-01T15:51:37.886107 | 2023-08-31T20:54:33 | 2023-08-31T20:54:33 | 640,534 | 10,928 | 5,362 | NOASSERTION | 2023-09-14T17:29:13 | 2010-04-30T20:37:14 | Python | UTF-8 | Python | false | false | 11,757 | py | singularities.py | """
Singularities
=============
This module implements algorithms for finding singularities for a function
and identifying types of functions.
The differential calculus methods in this module include methods to identify
the following function types in the given ``Interval``:
- Increasing
- Strictly Increasing
- Decre... |
5a1350c1e6617ed1233c6e3e269e11ccc02e96c1 | 4daab5ba90185bae65169ebb8183c635385ab3f8 | /autode/thermochemistry/symmetry.py | 81356a925e6e998bcc93bfb07862720bcbe4dce9 | [
"MIT"
] | permissive | duartegroup/autodE | bcf69440bd04411f97d39df0df0ae1f2bf6feb8c | 4d6667592f083dfcf38de6b75c4222c0a0e7b60b | refs/heads/master | 2023-09-01T15:08:16.028378 | 2023-07-25T08:09:05 | 2023-07-25T08:09:05 | 196,085,570 | 132 | 42 | MIT | 2023-09-12T15:20:54 | 2019-07-09T21:20:27 | Python | UTF-8 | Python | false | false | 8,062 | py | symmetry.py | import numpy as np
from scipy.spatial import distance_matrix
from autode.geom import get_rot_mat_euler
def strip_identical_and_inv_axes(axes, sim_axis_tol):
"""
For a list of axes remove those which are similar to within some distance
tolerance, or are inverses to within that tolerance
--------------... |
f0e368fb823a43aa9998d8ac5a27f05c1ca67776 | bad467391171ac97cb51e1110971e0cc45262526 | /phi/vis/_viewer.py | 1c4b79a0d047b154d9cdb26e64a141a6daa625e3 | [
"MIT"
] | permissive | tum-pbs/PhiFlow | d28f2f3de6ce385c3fa1214966b764ef18f86455 | 66f8e5e63ab7a920f60b43230b24f80b8e78286f | refs/heads/master | 2023-09-03T17:00:48.321319 | 2023-08-29T12:07:25 | 2023-08-30T13:47:50 | 225,903,949 | 982 | 163 | MIT | 2023-08-30T13:47:51 | 2019-12-04T15:55:57 | Python | UTF-8 | Python | false | false | 10,708 | py | _viewer.py | import itertools
import sys
import time
import warnings
from functools import partial
from threading import Event
from typing import Tuple, Union
from ._log import SceneLog
from ._user_namespace import UserNamespace
from ._vis_base import VisModel, Control, Action
from .. import field, math
from ..field import Scene, ... |
28cce9c2c360af44c8745739fe9c2b147b5c241a | fbbe424559f64e9a94116a07eaaa555a01b0a7bb | /Tensorflow/source/tensorflow/contrib/layers/__init__.py | d8ab7c2d70d8a7346c04d326f3a51b40a4f900ea | [
"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 | 3,296 | py | __init__.py | # Copyright 2015 The TensorFlow 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 applica... |
1372a54483d2d4b34a55e634a0b62acd4d767c2d | f312fcd24d94be8b32e2d1e50643b01c619aa23b | /tensorboard/examples/plugins/example_basic/tensorboard_plugin_example/demo.py | d3333380d4fc898ffe91de6a9c051c2b706cd704 | [
"Apache-2.0"
] | permissive | tensorflow/tensorboard | bf316fc5d47f78ef980dd2106c99207892a508d5 | 5961c76dca0fb9bb40d146f5ce13834ac29d8ddb | refs/heads/master | 2023-09-03T23:59:03.264261 | 2023-08-30T22:24:07 | 2023-08-30T22:24:07 | 91,379,993 | 6,766 | 2,063 | Apache-2.0 | 2023-09-14T20:55:56 | 2017-05-15T20:08:07 | TypeScript | UTF-8 | Python | false | false | 1,335 | py | demo.py | # Copyright 2019 The TensorFlow 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 applica... |
36dc3201359562b30cf7568928fdb3d5c08bbc69 | d5693d58b6a0389aa098876a6d465753482e2c8e | /Exec/science/flame_wave/analysis/ash_timeseries.py | 299428e33a075d146e64bfc4c19f44b8cb2bd8ee | [
"BSD-3-Clause-LBNL",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | AMReX-Astro/Castro | 4cebacd8e62638db8779c4d44c4ec0829b24b5d1 | 60a058987642dde487acd8e365923654b8918c87 | refs/heads/main | 2023-08-31T07:05:21.158032 | 2023-08-01T22:54:59 | 2023-08-01T22:54:59 | 29,609,157 | 236 | 106 | NOASSERTION | 2023-09-12T16:26:21 | 2015-01-21T20:10:37 | C++ | UTF-8 | Python | false | false | 3,199 | py | ash_timeseries.py | #!/usr/bin/env python3
import argparse
import os
import re
import sys
from functools import reduce
import matplotlib
import matplotlib.pyplot as plt
import numpy as np
from mpl_toolkits.axes_grid1 import ImageGrid
import yt
from yt.frontends.boxlib.api import CastroDataset
# assume that our data is in CGS
from yt.un... |
9e2f77b093dbf60e27f4d3963ad2e1cfe54e0c23 | 6cbb11d41a69ce704529a99c762e474edf789505 | /sqlite3_to_mysql/debug_info.py | 8d0316a428fa44ed96767e137b9cfe3edd4ad628 | [
"MIT"
] | permissive | techouse/sqlite3-to-mysql | a2538103d28b8578c82d2e041df05b1833aa60e0 | 9349a0f5503c9746b3cf6203c42f18244926247f | refs/heads/master | 2023-08-22T12:51:58.877617 | 2023-08-04T05:39:14 | 2023-08-04T05:39:14 | 135,895,949 | 287 | 51 | MIT | 2023-08-19T00:03:50 | 2018-06-03T10:53:17 | Python | UTF-8 | Python | false | false | 3,303 | py | debug_info.py | """Module containing bug report helper(s).
Adapted from https://github.com/psf/requests/blob/master/requests/help.py
"""
import platform
import sqlite3
import sys
import typing as t
from distutils.spawn import find_executable # pylint: disable=W0402
from subprocess import check_output
import click
import mysql.conn... |
25b83a7cd420489430b37780a9d9bea361540f5c | 5a52ccea88f90dd4f1acc2819997fce0dd5ffb7d | /alipay/aop/api/domain/TradePrecreateConfirmExtendParam.py | f8deb4fa665f4fc0dc525f44472cad3f1b59f579 | [
"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,056 | py | TradePrecreateConfirmExtendParam.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.constant.ParamConstants import *
class TradePrecreateConfirmExtendParam(object):
def __init__(self):
self._precreate_code_from = None
@property
def precreate_code_from(self):
return self._precreate_code_from
... |
cc7637b09d9776f78ff106126915c3ac9a000971 | eb76f82c474a327759888306910ccf584aee7ba1 | /ocrd_network/ocrd_network/rabbitmq_utils/__init__.py | 2d5f55e62cbf2db6397ef176f19e6277efd95923 | [
"Apache-2.0"
] | permissive | OCR-D/core | cc2aa388f43823529437924c1d653e48387a180a | 5d627396a5dfe9abcf11840608c87c94e1353647 | refs/heads/master | 2023-08-19T01:39:53.219760 | 2023-08-18T14:37:02 | 2023-08-18T14:37:02 | 112,337,283 | 112 | 26 | Apache-2.0 | 2023-09-13T16:12:03 | 2017-11-28T13:13:24 | Python | UTF-8 | Python | false | false | 299 | py | __init__.py | __all__ = [
'RMQConsumer',
'RMQConnector',
'RMQPublisher',
'OcrdProcessingMessage',
'OcrdResultMessage'
]
from .consumer import RMQConsumer
from .connector import RMQConnector
from .publisher import RMQPublisher
from .ocrd_messages import (
OcrdProcessingMessage,
OcrdResultMessage
)
|
15b3481f88eafd26aa1ad6fd89398a388309620b | b8bbdfc593b6d816e67a344f720f90ec05236778 | /tests/providers/google/cloud/sensors/test_bigquery.py | 5fe40227c53aed30b15b959b942ae7ad5f1a444a | [
"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 | 17,718 | py | test_bigquery.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... |
45a6283e4fa1066995c2c8e349ee227b463ec526 | 5419846a9e7010847fdbd232aa031fbd3e53e2bd | /AWS SageMaker/Jupyter-Folder/Boosting.py | 2f1f04af3e72eb643589f7068fe9ea7befd7b182 | [] | no_license | RubensZimbres/Repo-2018 | 432d492df83bb6cf9268131d34b03241e0a2cbf5 | 4880ff9f85e5a190f6515d16a810b1cda9288c68 | refs/heads/master | 2021-12-14T08:25:45.171826 | 2021-12-06T22:14:48 | 2021-12-06T22:14:48 | 114,630,397 | 180 | 88 | null | null | null | null | UTF-8 | Python | false | false | 1,648 | py | Boosting.py | import pandas as pd
import numpy as np
import sagemaker
from sagemaker.predictor import csv_serializer
import boto3
import re
import os
from sagemaker import get_execution_role
role = get_execution_role()
df=pd.read_csv('s3://your-repo/DadosTeseLogit.csv',sep=',',header=0)
sel=np.where(df.corr()['selected']>.5)[0][0:... |
8e5011abcf13440fae8e6046b9729d3d91578439 | 1d88dfbd224ba0cdfaf4834dc4202410cba3db16 | /examples/python/visualization/demo_scene.py | cfb5d3d23931c096db0a473923012b3256bde0f4 | [
"MIT"
] | permissive | isl-org/Open3D | 5217d525f505839777078127b5da7adc7b4bba2f | b620539a445206a7e07fed33fb4dcc6dff06c1a5 | refs/heads/master | 2023-09-01T21:42:37.981501 | 2023-09-01T15:08:08 | 2023-09-01T15:08:08 | 75,413,130 | 4,535 | 908 | NOASSERTION | 2023-09-14T18:07:41 | 2016-12-02T16:40:38 | C++ | UTF-8 | Python | false | false | 7,628 | py | demo_scene.py | # ----------------------------------------------------------------------------
# - Open3D: www.open3d.org -
# ----------------------------------------------------------------------------
# Copyright (c) 2018-2023 www.open3d.org
# SPDX-License-Identifier: MIT
# ---------... |
4f783cb3504eb786d1a0402fd4ee5934807d1cac | f6aac61a48a87743be9c40fecdc24344bae4d263 | /scripts/iemre/merge_narr.py | 7a77af64f2195b21485a965e1cb563dcc24d6f10 | [
"MIT"
] | permissive | akrherz/iem | 8714d99b371c8818f7cdde73dd24639e9fc7d42b | 178015584b7fb5b585f65be6013eaf16fb6db0c7 | refs/heads/main | 2023-08-19T02:58:24.507782 | 2023-08-18T12:08:31 | 2023-08-18T12:08:31 | 4,253,774 | 118 | 74 | MIT | 2023-09-14T18:28:41 | 2012-05-07T20:32:59 | Python | UTF-8 | Python | false | false | 1,374 | py | merge_narr.py | """Merge the NARR precip files to netcdf.
Unsure if I have any code that uses these .nc files, alas.
Called from dl/download_narr.py each month around the 9th.
"""
import datetime
import os
import sys
import numpy as np
import pygrib
from pyiem import iemre
from pyiem.util import logger, ncopen
LOG = logger()
def... |
c43068153abb7bc52fa5e493f1bbec37a5b7128d | 997645d6bb9c404f2f195328f29afa0eaa3c55b4 | /piccolo/columns/readable.py | 2748648d8c2e473112bee6957f9a43739b5e0f77 | [
"MIT"
] | permissive | piccolo-orm/piccolo | e43ea13c05c53ac00d9d20474c53ad2c49a40e80 | 83ea66323ef5a8e4010ea3ee19f34163bc881ace | refs/heads/master | 2023-08-08T19:31:37.783445 | 2023-07-28T06:19:35 | 2023-07-28T06:19:35 | 155,008,334 | 1,139 | 90 | MIT | 2023-09-08T16:54:45 | 2018-10-27T20:53:26 | Python | UTF-8 | Python | false | false | 1,485 | py | readable.py | from __future__ import annotations
import typing as t
from dataclasses import dataclass
from piccolo.columns.base import Selectable
if t.TYPE_CHECKING: # pragma: no cover
from piccolo.columns.base import Column
@dataclass
class Readable(Selectable):
"""
This allows a table to specify a 'readable' repr... |
56534a5e7aad3fe209ebaae69c8259a80393594a | 091a6200be74bf6577c86f623665bcc24e16b02b | /BLE_MIDI_Robot_Xylophone/code.py | 9ddac4bb7ee00f5a22d33521e36a9a0ca8106b6f | [
"MIT"
] | permissive | adafruit/Adafruit_Learning_System_Guides | b5f7bce40a16da64e7a79d4b39de032f2cca41d4 | 5eaa7a15a437c533b89f359a25983e24bb6b5438 | refs/heads/main | 2023-09-05T18:31:41.621956 | 2023-09-05T15:36:09 | 2023-09-05T15:36:09 | 105,065,494 | 937 | 937 | MIT | 2023-09-12T18:48:53 | 2017-09-27T20:22:44 | C | UTF-8 | Python | false | false | 3,288 | py | code.py | # SPDX-FileCopyrightText: 2020 Liz Clark for Adafruit Industries
#
# SPDX-License-Identifier: MIT
import time
import board
import busio
from adafruit_mcp230xx.mcp23017 import MCP23017
from digitalio import Direction
import adafruit_ble
from adafruit_ble.advertising.standard import ProvideServicesAdvertisement
import a... |
b36db3ecfd2dd3f22ea0cf7a080cbffbd4b1b5b2 | 6c37d1d2437a08e43b13d621d4a8da4da7135b3a | /yt_dlp/extractor/freespeech.py | aea551379b84dfa4f7fdd133d499b85cbccf54fb | [
"Unlicense",
"GPL-2.0-or-later",
"MPL-2.0",
"BSD-3-Clause",
"GPL-3.0-or-later",
"LGPL-2.1-only",
"BSD-2-Clause",
"MIT"
] | permissive | yt-dlp/yt-dlp | be040bde10cc40258c879c75ab30215686352824 | d3d81cc98f554d0adb87d24bfd6fabaaa803944d | refs/heads/master | 2023-09-05T21:15:21.050538 | 2023-09-05T20:35:23 | 2023-09-05T20:35:23 | 307,260,205 | 52,742 | 5,376 | Unlicense | 2023-09-14T05:22:08 | 2020-10-26T04:22:55 | Python | UTF-8 | Python | false | false | 1,016 | py | freespeech.py | from .common import InfoExtractor
from .youtube import YoutubeIE
class FreespeechIE(InfoExtractor):
IE_NAME = 'freespeech.org'
_VALID_URL = r'https?://(?:www\.)?freespeech\.org/stories/(?P<id>.+)'
_TEST = {
'add_ie': ['Youtube'],
'url': 'http://www.freespeech.org/stories/fcc-announces-net-... |
76bbfb598c975cc61811fd291a8620626af3a33f | 376e1818d427b5e4d32fa6dd6c7b71e9fd88afdb | /lang/python27/patches/patch-Lib___osx__support.py | c377d2a50665e06c6361d690391aed35389fb26e | [] | no_license | NetBSD/pkgsrc | a0732c023519650ef821ab89c23ab6ab59e25bdb | d042034ec4896cc5b47ed6f2e5b8802d9bc5c556 | refs/heads/trunk | 2023-09-01T07:40:12.138283 | 2023-09-01T05:25:19 | 2023-09-01T05:25:19 | 88,439,572 | 321 | 138 | null | 2023-07-12T22:34:14 | 2017-04-16T20:04:15 | null | UTF-8 | Python | false | false | 1,003 | py | patch-Lib___osx__support.py | $NetBSD: patch-Lib___osx__support.py,v 1.1 2021/06/23 18:30:24 schmonz Exp $
macOS arm64 support, via MacPorts.
--- Lib/_osx_support.py.orig 2021-06-22 19:20:03.000000000 +0000
+++ Lib/_osx_support.py
@@ -470,6 +470,8 @@ def get_platform_osx(_config_vars, osnam
if len(archs) == 1:
mach... |
2669318c27591fc5ccdafd55becea285de3d9358 | e5bfe32c855cfda798a064d8076339b46f21c53c | /routeros_api/api_structure.py | 7899956d7f667abd16b5151236f9371b202cec9a | [
"Python-2.0",
"MIT"
] | permissive | socialwifi/RouterOS-api | 04e4012db578c9176de8bb6186ff52b67bf3c1b9 | 5580d046c96867380546ca76699337b50e74aefc | refs/heads/master | 2023-07-08T23:39:14.875793 | 2023-03-15T19:14:24 | 2023-03-15T19:14:24 | 17,862,006 | 234 | 106 | MIT | 2023-06-28T20:24:09 | 2014-03-18T10:33:59 | Python | UTF-8 | Python | false | false | 3,342 | py | api_structure.py | import abc
import collections
import datetime
import ipaddress
import re
class Field(object):
__metaclass__ = abc.ABCMeta
@abc.abstractmethod
def get_mikrotik_value(self, arg):
"""
:rtype: bytes
"""
raise NotImplementedError()
@abc.abstractmethod
def get_python_va... |
005e7f955ddc86fd961e21d56c4eb51a44e310a4 | 00efa24c6c89c2c41e641431c3f685f02f7a26be | /expects/texts.py | 3b1a620b5ec56dab10d98e316451e1a38b87fd70 | [
"Apache-2.0"
] | permissive | jaimegildesagredo/expects | 0e80c3ed4e3063abcbe45fc3b1af79bd248eb832 | 7c1bbb1833fa5f5cd4e3428cfd8859b122011f53 | refs/heads/master | 2022-11-24T23:48:11.458697 | 2022-11-15T17:44:07 | 2022-11-15T17:44:07 | 10,266,355 | 208 | 34 | NOASSERTION | 2022-11-15T09:14:42 | 2013-05-24T12:55:59 | Python | UTF-8 | Python | false | false | 658 | py | texts.py | # -*- coding: utf-8 -*
from .matchers import default_matcher
def plain_enumerate(args, kwargs=None):
if kwargs is None:
kwargs = {}
tokens = []
for arg in args:
tokens.append(repr(arg))
for k, v in _sorted_items(kwargs):
tokens.append('{0!r} {1!r}'.format(k, default_matcher... |
7730b01829e31edc09ce6e127ed7a7b8f7fc2faa | 88ae8695987ada722184307301e221e1ba3cc2fa | /third_party/catapult/skia_bridge/tests/perf_api/query_anomalies_test.py | 2d0dcdcd8aaf3650d26578f8e3560d1c7acab09c | [
"Apache-2.0",
"LGPL-2.0-or-later",
"MIT",
"GPL-1.0-or-later",
"BSD-3-Clause"
] | permissive | iridium-browser/iridium-browser | 71d9c5ff76e014e6900b825f67389ab0ccd01329 | 5ee297f53dc7f8e70183031cff62f37b0f19d25f | refs/heads/master | 2023-08-03T16:44:16.844552 | 2023-07-20T15:17:00 | 2023-07-23T16:09:30 | 220,016,632 | 341 | 40 | BSD-3-Clause | 2021-08-13T13:54:45 | 2019-11-06T14:32:31 | null | UTF-8 | Python | false | false | 7,434 | py | query_anomalies_test.py | # Copyright 2023 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
from __future__ import absolute_import
import json
import os
import sys
from pathlib import Path
import unittest
app_path = Path(__file__).parent.parent.parent
if str(app_path) ... |
d543e11fe3117371e15b2a6521ae874473ac4872 | 5a12bac57dcd949c67de7916e784b06fdbfa25c2 | /kik_unofficial/protobuf/contactlist/v2/contact_list_common_pb2.py | 542876842da507ca28c14b72bc6faa954cc46262 | [
"MIT"
] | permissive | tomer8007/kik-bot-api-unofficial | 582f5e7b06640682873dd6e09bd8174e776f1c56 | c860cfb59c20f5e351add17edb56b814c3d594a6 | refs/heads/new | 2023-08-30T12:26:08.351092 | 2023-08-18T00:20:06 | 2023-08-18T00:20:06 | 95,992,460 | 148 | 120 | MIT | 2023-08-18T00:20:08 | 2017-07-01T23:26:15 | Python | UTF-8 | Python | false | true | 7,218 | py | contact_list_common_pb2.py | # -*- coding: utf-8 -*-
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: contactlist/v2/contact_list_common.proto
"""Generated protocol buffer code."""
from google.protobuf.internal import builder as _builder
from google.protobuf import descriptor as _descriptor
from google.protobuf import descripto... |
7788cdd30507cd92bdbac653243b7cee5745d238 | 407d194b52fe9cf75cca9d6f3c162a565549a1ae | /Utils/test/test_redacted_settings.py | 46962ff6a69a6fb3537559d2a57c83640b1bdd45 | [
"Apache-2.0"
] | permissive | Azure/azure-linux-extensions | 808761f927045f00548aa68e38d4bec8651c0eba | 3cea1567fc4f4eb5beea9884153e92d70610394d | refs/heads/master | 2023-08-27T14:06:05.775617 | 2023-08-23T01:56:05 | 2023-08-23T01:56:05 | 19,841,123 | 300 | 314 | Apache-2.0 | 2023-09-14T04:21:26 | 2014-05-16T01:38:49 | Python | UTF-8 | Python | false | false | 2,015 | py | test_redacted_settings.py | #!/usr/bin/env python
#
# Tests for redacted settings
#
# Copyright 2014 Microsoft 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... |
25840b4641e9bbbd9e3f61a45e12f757913a4063 | 87f6712f676d2b1aad7921e1b4d4387195a3bf96 | /tests/test_helper.py | b1af2859a7e6a093bd232fb220ed73bab66c1d18 | [
"Apache-2.0"
] | permissive | Fatal1ty/mashumaro | e3d53b52029a29a3b495132ff2ea46ef07081549 | c0a4cf8943de51a626bc30681c935a628565cecf | refs/heads/master | 2023-08-07T08:43:30.227999 | 2023-08-02T19:59:28 | 2023-08-02T19:59:28 | 156,855,347 | 617 | 40 | Apache-2.0 | 2023-09-13T18:26:28 | 2018-11-09T11:50:56 | Python | UTF-8 | Python | false | false | 1,918 | py | test_helper.py | from dataclasses import dataclass, field
from datetime import date, datetime
import pytest
from mashumaro import DataClassDictMixin, field_options
from mashumaro.helper import pass_through
from mashumaro.types import SerializationStrategy
def test_field_options_helper():
assert field_options() == {
"ser... |
d7119b6ea08919a7b66e75349c5b5c0f9a4f9f5d | 150a7b11cb531f8bc2a045aefcf2ebe1d151efa3 | /ocs_ci/deployment/helpers/lso_helpers.py | bf8b4f22e0f1c9cb1eb7ce2a4b8f660d0cb41d47 | [
"MIT"
] | permissive | red-hat-storage/ocs-ci | c7ac414e1b86552da0439223dfa9bca39977f31a | 5e9e504957403148e413326f65c3769bf9d8eb39 | refs/heads/master | 2023-08-17T16:19:51.154403 | 2023-08-17T13:27:12 | 2023-08-17T13:27:12 | 179,558,938 | 146 | 210 | MIT | 2023-09-14T16:38:44 | 2019-04-04T19:00:02 | Python | UTF-8 | Python | false | false | 16,713 | py | lso_helpers.py | """
This module contains helpers functions needed for
LSO ( local storage operator ) deployment.
"""
import json
import logging
import tempfile
from ocs_ci.deployment.disconnected import prune_and_mirror_index_image
from ocs_ci.framework import config
from ocs_ci.ocs import constants, ocp, defaults
from ocs_ci.ocs.ex... |
f7cfce83ce0a41a4de308764e62f242a5653c211 | c9ff14ff176600169b6e9f6490ab32f5c3af60e0 | /jcvi/projects/misc.py | 0a287434f9d1f8a6ac75732c0b36b45f6738cd74 | [
"BSD-3-Clause",
"BSD-2-Clause"
] | permissive | tanghaibao/jcvi | c7a070692d53784a34378e19e435cb9a86d2cd2e | 695bd2eee98b14118b54fc37e38cd0222ce6a5e9 | refs/heads/main | 2023-09-01T01:22:04.353148 | 2023-08-30T01:59:11 | 2023-08-30T01:59:11 | 1,130,393 | 641 | 193 | BSD-2-Clause | 2023-09-01T03:17:24 | 2010-12-01T23:18:02 | Python | UTF-8 | Python | false | false | 22,201 | py | misc.py | #!/usr/bin/env python
# -*- coding: UTF-8 -*-
"""
Functions in this script produce figures in various manuscripts.
"""
import os.path as op
import sys
import logging
import numpy as np
from jcvi.graphics.base import Polygon, normalize_axes, panel_labels, plt, savefig
from jcvi.graphics.glyph import GeneGlyph, Round... |
db4f797428e98a86ff62b2be5b34361b814b9a51 | 6c2dbc8d4e536220fb3b1cc72aa8104aea8b0698 | /tests/test_utils/test_magic_filter.py | 097c8365a1dfb6740feeb4791e3261088ab6d17d | [
"MIT"
] | permissive | aiogram/aiogram | f8f98a0beb63bd4d93ea810638d5792569bf354b | 04bd0c9e7c5421c060183b90d515050f41377bc1 | refs/heads/dev-3.x | 2023-08-30T21:20:13.018174 | 2023-08-28T23:01:54 | 2023-08-28T23:01:54 | 111,210,856 | 4,287 | 1,250 | MIT | 2023-09-10T21:34:03 | 2017-11-18T14:11:13 | Python | UTF-8 | Python | false | false | 935 | py | test_magic_filter.py | from dataclasses import dataclass
from re import Match
from aiogram import F
from aiogram.utils.magic_filter import MagicFilter
@dataclass
class MyObject:
text: str
class TestMagicFilter:
def test_operation_as(self):
magic: MagicFilter = F.text.regexp(r"^(\d+)$").as_("match")
assert not ma... |
d9a36b29f5ab981a7ee13c26e6ea4e152faea5e5 | ecc09ad8fca4d48dc905b549b421917c17d57985 | /tests/model/eventsources/test_cloudwatch_event_source.py | 55a7f3245889a5570492eb36858e28e1fccc0f38 | [
"MIT",
"Apache-2.0"
] | permissive | aws/serverless-application-model | 8fd3ea2016560da4929653da2c30298cced41b64 | 0bb862ea715a4aafbb7984b407a81856b3ae19c4 | refs/heads/develop | 2023-08-31T02:22:14.862372 | 2023-08-30T17:52:46 | 2023-08-30T17:52:46 | 70,530,854 | 2,055 | 704 | Apache-2.0 | 2023-09-14T18:02:21 | 2016-10-10T21:36:18 | Python | UTF-8 | Python | false | false | 969 | py | test_cloudwatch_event_source.py | from unittest import TestCase
from samtranslator.model.eventsources.push import CloudWatchEvent
from samtranslator.model.lambda_ import LambdaFunction
class CloudWatchEventSourceTests(TestCase):
def setUp(self):
self.logical_id = "EventLogicalId"
self.func = LambdaFunction("func")
def test_t... |
a09acd1e21b5aea5065098dbb7e65c61507e2153 | 091a6200be74bf6577c86f623665bcc24e16b02b | /IoT_Environment_Sensor/secrets.py | f55951b186671dae1ba494434e851cea808a745a | [
"MIT"
] | permissive | adafruit/Adafruit_Learning_System_Guides | b5f7bce40a16da64e7a79d4b39de032f2cca41d4 | 5eaa7a15a437c533b89f359a25983e24bb6b5438 | refs/heads/main | 2023-09-05T18:31:41.621956 | 2023-09-05T15:36:09 | 2023-09-05T15:36:09 | 105,065,494 | 937 | 937 | MIT | 2023-09-12T18:48:53 | 2017-09-27T20:22:44 | C | UTF-8 | Python | false | false | 410 | py | secrets.py | # SPDX-FileCopyrightText: 2019 Dave Astels for Adafruit Industries
#
# SPDX-License-Identifier: MIT
# This file is where you keep secret settings, passwords, and tokens!
# If you put them in the code you risk committing that info or sharing it
secrets = {
"ssid": b"My_SSID",
"password": b"My_WIFI_Password",
... |
d00cba73bb2eb90902ac518d04bb6d60ba39b8f6 | 182bbadb0ee7f59f1abd154d06484e555a30c6d8 | /bingo/bingo-elastic/python/bingo_elastic/model/helpers.py | 986b17b7b14f6d06c8954f8af595d1f6eb63a6db | [
"Apache-2.0"
] | permissive | epam/Indigo | 08559861adf474122366b6e2e499ed3aa56272d1 | 8e473e69f393c3a57ff75b7728999c5fb4cbf1a3 | refs/heads/master | 2023-09-02T10:14:46.843829 | 2023-08-25T08:39:24 | 2023-08-25T08:39:24 | 37,536,320 | 265 | 106 | Apache-2.0 | 2023-09-14T17:34:00 | 2015-06-16T14:45:56 | C++ | UTF-8 | Python | false | false | 2,810 | py | helpers.py | from pathlib import Path
from typing import Callable, Generator, Optional, Union
from indigo import Indigo, IndigoObject # type: ignore
from bingo_elastic.model.record import (
IndigoRecordMolecule,
IndigoRecordReaction,
)
def iterate_file(
file: Path,
iterator: Optional[str] = None,
error_hand... |
53fce635e9d65e1c3a765f6d7847dd5612a42400 | cb6d0a660cfcb28ee9e8a1c0266925f8f541edfb | /tests/python/test_brb2.py | 89783f308cf7528ff8ea27271f25b04ab39d0126 | [
"Apache-2.0",
"LicenseRef-scancode-proprietary-license",
"GPL-1.0-or-later",
"BSD-3-Clause",
"LicenseRef-scancode-other-copyleft",
"GPL-2.0-only"
] | permissive | iovisor/bcc | 0e002769364523caeb731216021b0a3c881a723f | ec49363e2e9daec026ee6cae4c5fc316f8fab0ff | refs/heads/master | 2023-09-03T22:37:47.238198 | 2023-08-31T14:44:55 | 2023-09-01T11:21:30 | 34,921,116 | 18,467 | 3,907 | Apache-2.0 | 2023-09-13T21:22:53 | 2015-05-01T19:52:32 | C | UTF-8 | Python | false | false | 9,397 | py | test_brb2.py | #!/usr/bin/env python3
# Copyright (c) PLUMgrid, Inc.
# Licensed under the Apache License, Version 2.0 (the "License")
# This program implements a topology likes below:
# pem: physical endpoint manager, implemented as a bpf program
#
# vm1 <--------+ +----> bridge1 <----+
# V V ... |
b0fd3399970f04a0ef4a665850c23d3b3c5856f9 | 96dcea595e7c16cec07b3f649afd65f3660a0bad | /homeassistant/components/rympro/const.py | ed7e2801a1b9f6fb7ad644a40b0ddf48675615c0 | [
"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 | 76 | py | const.py | """Constants for the Read Your Meter Pro integration."""
DOMAIN = "rympro"
|
2c8a1b67d960953eabab897c2de869d2eb79e785 | 019f03d6713a2bc5344b644aeb5ebe70aaf7cfd0 | /src/super_gradients/common/data_interface/__init__.py | 24e57e03122134b2334c458ab581dd8445562567 | [
"LicenseRef-scancode-proprietary-license",
"Apache-2.0"
] | permissive | Deci-AI/super-gradients | 6f52cd15bc2f9f39e3cdc6067292b6512aba5dd0 | 7240726cf6425b53a26ed2faec03672f30fee6be | refs/heads/master | 2023-08-25T17:47:02.595029 | 2023-08-24T11:50:50 | 2023-08-24T11:50:50 | 432,652,408 | 3,237 | 331 | Apache-2.0 | 2023-09-14T11:24:46 | 2021-11-28T07:58:02 | Jupyter Notebook | UTF-8 | Python | false | false | 325 | py | __init__.py | # PACKAGE IMPORTS FOR EXTERNAL USAGE
from super_gradients.common.data_interface.dataset_data_interface import DatasetDataInterface
from super_gradients.common.data_interface.adnn_model_repository_data_interface import ADNNModelRepositoryDataInterfaces
__all__ = ["DatasetDataInterface", "ADNNModelRepositoryDataInterfac... |
7b33b31243e543495692e03acfd29b5883df7170 | 5c363c50c54175a982330ec888401b3e394373ab | /benchmarking/nursery/othpo/plotting/collect_yahpo_evaluations_for_plotting.py | 253ba69ff7023850e3e9d15df18300c2c2aa6106 | [
"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 | 4,206 | py | collect_yahpo_evaluations_for_plotting.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... |
c75aa28e875d510d9e5a9efe3fc37c41ac616c44 | 6b27c39edc10b1353104043b7a523f4981c99ef2 | /pytype/pytd/main.py | bacf4f267739730db0768f8d9b51280adebf189d | [
"Apache-2.0",
"MIT"
] | permissive | google/pytype | ad0ff0b6c1083b4f0a1af1747869d422f2b5f4d8 | bda0b9547af9a084bb2bd1427f58dcde968e48b5 | refs/heads/main | 2023-08-26T17:52:23.546035 | 2023-08-24T22:48:00 | 2023-08-24T22:48:00 | 32,483,713 | 4,595 | 367 | NOASSERTION | 2023-09-13T04:40:45 | 2015-03-18T20:52:08 | Python | UTF-8 | Python | false | false | 3,389 | py | main.py | """Tool for processing pytd files.
pytd is a type declaration language for Python. Each .py file can have an
accompanying .pytd file that specifies classes, argument types, return types
and exceptions.
This binary processes pytd files, typically to optimize them.
Usage:
pytd_tool [flags] <inputfile> <outputfile>
""... |
8fb06f716de4c92bf35e911ba57c2a8e298d74a8 | 010279e2ba272d09e9d2c4e903722e5faba2cf7a | /contrib/python/scipy/py3/scipy/integrate/_ivp/dop853_coefficients.py | f39f2f3650d321e2c475d4e220f9769139118a5e | [
"Apache-2.0",
"Python-2.0",
"LicenseRef-scancode-unknown-license-reference",
"MIT",
"Qhull",
"BSD-3-Clause",
"BSL-1.0",
"BSD-2-Clause"
] | permissive | catboost/catboost | 854c1a1f439a96f1ae6b48e16644be20aa04dba2 | f5042e35b945aded77b23470ead62d7eacefde92 | refs/heads/master | 2023-09-01T12:14:14.174108 | 2023-09-01T10:01:01 | 2023-09-01T10:22:12 | 97,556,265 | 8,012 | 1,425 | Apache-2.0 | 2023-09-11T03:32:32 | 2017-07-18T05:29:04 | Python | UTF-8 | Python | false | false | 7,237 | py | dop853_coefficients.py | import numpy as np
N_STAGES = 12
N_STAGES_EXTENDED = 16
INTERPOLATOR_POWER = 7
C = np.array([0.0,
0.526001519587677318785587544488e-01,
0.789002279381515978178381316732e-01,
0.118350341907227396726757197510,
0.281649658092772603273242802490,
0.3333... |
e003123a0b611afb903c5aadf36d0bf40d46506b | b097b7caa954a0447bef9a7144e15fbc1b08a96b | /test/torchaudio_unittest/assets/wav2vec2/huggingface/generate_huggingface_model_config.py | 68f15a6e70437c6220ffc995239beb218a228cb8 | [
"CC-BY-NC-4.0",
"BSD-2-Clause",
"CC-BY-4.0"
] | 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 | 1,041 | py | generate_huggingface_model_config.py | import json
import os
from transformers import Wav2Vec2Model
_THIS_DIR = os.path.dirname(os.path.abspath(__file__))
def _main():
keys = [
# pretrained
"facebook/wav2vec2-base",
"facebook/wav2vec2-large",
"facebook/wav2vec2-large-lv60",
"facebook/wav2vec2-base-10k-voxpopul... |
09d31ee9072ca924ffb2597ab49a201ec1f9305e | baa2c6f22ff563d417e34692bf3345077eb8fa5f | /IPython/core/tests/test_extension.py | 24ecf7e97e3e56ea51327cc4704ff1fa749c15aa | [
"BSD-3-Clause"
] | permissive | ipython/ipython | c42ea223b6e391bb7dd39888cb959d4d5d6b21a1 | e5103f971233fd66b558585cce7a4f52a716cd56 | refs/heads/main | 2023-08-30T18:27:18.436521 | 2023-08-29T12:16:00 | 2023-08-29T12:16:00 | 658,518 | 13,673 | 4,729 | BSD-3-Clause | 2023-09-12T20:22:09 | 2010-05-10T04:46:06 | Python | UTF-8 | Python | false | false | 3,026 | py | test_extension.py | import os.path
from tempfile import TemporaryDirectory
import IPython.testing.tools as tt
from IPython.utils.syspathcontext import prepended_to_syspath
ext1_content = """
def load_ipython_extension(ip):
print("Running ext1 load")
def unload_ipython_extension(ip):
print("Running ext1 unload")
"""
ext2_conte... |
f25edf20dfc3be5a15a7d5781ee1a942a22260f2 | 2d9a3ce2a04190d0032e8a298829022260b1d76b | /indra/sources/omnipath/processor.py | 02bac3709514fa4f6001e4b6b77ffb94ee010653 | [
"BSD-2-Clause",
"BSD-2-Clause-Views"
] | permissive | sorgerlab/indra | f127a0f9bdd2d3f48df14575883fd31e2f4de4bf | 6d6ca1174792b6c5a05cbf3afcb9f138fabcec6a | refs/heads/master | 2023-08-21T13:25:54.654995 | 2023-06-11T16:46:41 | 2023-06-11T16:46:41 | 22,848,436 | 158 | 61 | BSD-2-Clause | 2023-08-30T21:47:59 | 2014-08-11T17:44:05 | Python | UTF-8 | Python | false | false | 8,626 | py | processor.py | from __future__ import unicode_literals
import copy
import logging
from indra.statements.validate import validate_text_refs
from indra.ontology.standardize import standardize_agent_name
from indra.statements import modtype_to_modclass, Agent, Evidence, Complex, \
get_statement_by_name as stmt_by_name, BoundConditi... |
0595f567e8d4ffc9219bdd86b191bd25d710de83 | 62f756687af4f522b78e4963a6d2262136a9b65d | /tests/import/import3a.py | 2e9d41f71dbdfabb08e12c1cf94ec8dc26db616b | [
"MIT"
] | permissive | micropython/micropython-esp32 | 48ce07832c8d44fcdc530962bd9ae087949b957b | 2f4dac5f121a59fc187c1d9c1f9eade365b3aba1 | refs/heads/esp32 | 2023-08-28T12:00:44.867727 | 2018-02-27T04:06:10 | 2018-02-27T04:06:10 | 76,828,539 | 737 | 238 | MIT | 2023-09-06T02:31:38 | 2016-12-19T04:38:26 | C | UTF-8 | Python | false | false | 34 | py | import3a.py | from import1b import *
print(var)
|
8ebe0bd2a1803269bae21a6695f3a2cedbc25ac7 | 3079aff5691cc3452c86c9a76c0309bf66c920a1 | /python/finufft/examples/simple1d1.py | fea8e5beebfea5ed9aea7cb9fd77bda1a5f77ba4 | [
"Apache-2.0"
] | permissive | flatironinstitute/finufft | dd332853a8900b9ea8a5a6ad21a3842f07bc9fc8 | 0e5f3f3b3ec07ac8b7e7ccd26d88d2c912c1b9a6 | refs/heads/master | 2023-08-30T12:19:36.644780 | 2023-08-22T11:44:39 | 2023-08-23T10:08:35 | 78,682,506 | 209 | 80 | NOASSERTION | 2023-09-08T21:51:05 | 2017-01-11T21:42:14 | C++ | UTF-8 | Python | false | false | 821 | py | simple1d1.py | # demo of 1D type 1 FINUFFT in python. Should stay close to docs/python.rst
# Barnett 8/19/20
import numpy as np
import finufft
import time
np.random.seed(42)
# number of nonuniform points
M = 100000
# input nonuniform points
x = 2 * np.pi * np.random.uniform(size=M)
# their complex strengths
c = (np.random.standar... |
98ddcd723497cabe7efd0b0df5957aab757bd6b0 | 9ed3b16b3da72e4c47a04f2f2e3ef395e9fd9f20 | /main/fontconfig/template.py | ef769d3f2648459ec35347e23385f5a456b003c0 | [
"BSD-2-Clause"
] | permissive | chimera-linux/cports | fdae59dc25856942be3041e10e3533dbf8f883c3 | 714680161cd719dd047452c95fbb9b447bc23a86 | refs/heads/master | 2023-09-03T19:30:40.720670 | 2023-09-03T15:07:40 | 2023-09-03T15:07:40 | 374,000,317 | 118 | 37 | BSD-2-Clause | 2023-09-14T20:31:08 | 2021-06-05T02:07:34 | Python | UTF-8 | Python | false | false | 1,067 | py | template.py | pkgname = "fontconfig"
pkgver = "2.14.2"
pkgrel = 0
build_style = "gnu_configure"
configure_args = [
"--enable-static",
"--enable-docs",
f"--with-cache-dir=/var/cache/{pkgname}",
]
make_cmd = "gmake"
hostmakedepends = ["pkgconf", "gperf", "gmake", "python"]
makedepends = ["libexpat-devel", "freetype-bootstr... |
4296a398ed34f4195e955cc1ea73729b9ec59fa5 | 76fb0a3cfc9d9362ab29174bd1d55e888ea4d7f6 | /tfx/dsl/input_resolution/ops/group_by_lineage_op.py | af8ed7c02970d114dff2486ee93cc11eb483442b | [
"Apache-2.0"
] | permissive | tensorflow/tfx | 0cfc9c55171352ecc98c9dfa8ffe976c689d7073 | 1b328504fa08a70388691e4072df76f143631325 | refs/heads/master | 2023-08-30T11:56:50.894497 | 2023-08-29T22:47:19 | 2023-08-29T22:48:26 | 169,116,405 | 2,116 | 899 | Apache-2.0 | 2023-09-14T21:51:42 | 2019-02-04T17:14:36 | Python | UTF-8 | Python | false | false | 8,869 | py | group_by_lineage_op.py | # Copyright 2023 Google LLC. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... |
7149c7c3938bdeada661cebcc1a87d1461053bbb | fa1ad2e2ac7e376fc7cb3b3a6e1bb88eed3e80be | /studio/micro-services/cube-studio/myapp/views/view_images.py | e386c6227ccb140157076ad77b658fa30659e16e | [
"Apache-2.0",
"BSD-3-Clause",
"EPL-2.0",
"MIT",
"LGPL-2.1-only",
"LicenseRef-scancode-unknown-license-reference",
"LicenseRef-scancode-public-domain",
"BSD-2-Clause"
] | 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 | 7,827 | py | view_images.py | from flask import render_template,redirect
from flask_appbuilder.models.sqla.interface import SQLAInterface
from flask_appbuilder import ModelView, ModelRestApi
from flask_appbuilder import ModelView,AppBuilder,expose,BaseView,has_access
from importlib import reload
from flask_babel import gettext as __
from flas... |
2072de8a1a8c18f310685cd3d30ad7ece1e19710 | 444a9480bce2035565332d4d4654244c0b5cd47b | /research/cv/slowfast/src/datasets/build.py | 0ecb1e8e6d65ad47ac775927d055c2b030715230 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference",
"LicenseRef-scancode-proprietary-license"
] | permissive | mindspore-ai/models | 7ede9c6454e77e995e674628204e1c6e76bd7b27 | eab643f51336dbf7d711f02d27e6516e5affee59 | refs/heads/master | 2023-07-20T01:49:34.614616 | 2023-07-17T11:43:18 | 2023-07-17T11:43:18 | 417,393,380 | 301 | 92 | Apache-2.0 | 2023-05-17T11:22:28 | 2021-10-15T06:38:37 | Python | UTF-8 | Python | false | false | 2,495 | py | build.py | # Copyright 2022 Huawei Technologies Co., Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to... |
33d4bf1bbb28f09367d99814295c91684c22d65f | e30874b3aa20804833dd11788176f839fcd08690 | /python/cudf/cudf/_lib/pylibcudf/__init__.py | 3edff9a53e8c48100e2f5edad1390843eee3de73 | [
"Apache-2.0"
] | permissive | rapidsai/cudf | eaba8948cddde8161c3b02b1b972dab3df8d95b3 | c51633627ee7087542ad4c315c0e139dea58e408 | refs/heads/branch-23.10 | 2023-09-04T07:18:27.194295 | 2023-09-03T06:20:33 | 2023-09-03T06:20:33 | 90,506,918 | 5,386 | 751 | Apache-2.0 | 2023-09-14T00:27:03 | 2017-05-07T03:43:37 | C++ | UTF-8 | Python | false | false | 302 | py | __init__.py | # Copyright (c) 2023, NVIDIA CORPORATION.
from . import copying
from .column import Column
from .gpumemoryview import gpumemoryview
from .table import Table
from .types import DataType, TypeId
__all__ = [
"Column",
"DataType",
"Table",
"TypeId",
"copying",
"gpumemoryview",
]
|
a0ed0a6453e604ba5f0ace192b29b72fc5841762 | c058f51b99f91faebf27183b2b579e9f96e0d8f5 | /botorch/test_functions/multi_fidelity.py | 97b0f139286dbc6321892929c5525c6ace26e465 | [
"MIT"
] | permissive | pytorch/botorch | 255d62f698cc615c750e9343c278a63c7e96a586 | 4cc5ed59b2e8a9c780f786830c548e05cc74d53c | refs/heads/main | 2023-08-22T15:23:51.071048 | 2023-08-22T05:30:38 | 2023-08-22T05:30:38 | 142,940,093 | 2,891 | 373 | MIT | 2023-09-13T00:16:13 | 2018-07-30T23:59:57 | Jupyter Notebook | UTF-8 | Python | false | false | 5,330 | py | multi_fidelity.py | #!/usr/bin/env python3
# Copyright (c) Meta Platforms, Inc. and affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
r"""
Synthetic functions for multi-fidelity optimization benchmarks.
"""
from __future__ import annotations
import ... |
c174f6d58696e77346579dc5de21e564837eb8f4 | 944a49e62bc79622fe01abee62403397a1b0504d | /openstackclient/tests/functional/network/v2/test_subnet_pool.py | f7cb1d74268ba2cee90a80acc9a54e839078375f | [
"Apache-2.0"
] | permissive | openstack/python-openstackclient | 1c22984f9b29ae8ff9bbea26067981e2130ed039 | 78988d1786c0634ee055714910d1e6187f941673 | refs/heads/master | 2023-08-28T15:10:05.542862 | 2023-08-26T12:44:20 | 2023-08-26T12:44:20 | 4,170,310 | 286 | 224 | Apache-2.0 | 2022-09-19T13:29:49 | 2012-04-28T21:07:25 | Python | UTF-8 | Python | false | false | 10,486 | py | test_subnet_pool.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
# d... |
764ab7f7f763f254a9fd703abe87b8fea1fb7c2d | 4d28185e7a78a569f9a449f39f183cac3024f711 | /packages/Python/lldbsuite/test/commands/expression/call-throws/TestCallThatThrows.py | c6b90ba5ba020e692468f2da4022e511e5ae5b5f | [
"NCSA",
"Apache-2.0",
"LLVM-exception"
] | permissive | apple/swift-lldb | 2789bf44f648609a1674ee520ac20b64c95de072 | d74be846ef3e62de946df343e8c234bde93a8912 | refs/heads/stable | 2023-04-06T00:28:15.882479 | 2019-10-25T22:46:59 | 2019-10-25T22:46:59 | 44,838,862 | 780 | 291 | Apache-2.0 | 2020-01-10T19:28:43 | 2015-10-23T21:13:18 | C++ | UTF-8 | Python | false | false | 3,778 | py | TestCallThatThrows.py | """
Test calling a function that throws an ObjC exception, make sure that it doesn't propagate the exception.
"""
from __future__ import print_function
import lldb
from lldbsuite.test.decorators import *
from lldbsuite.test.lldbtest import *
from lldbsuite.test import lldbutil
class ExprCommandWithThrowTestCase(Te... |
e290fd98c11b1cab20e3f57a5be0b6a0e95d02a3 | e22eeb5256e17a96a98b3ff25433aec2d641cd2c | /openstack/tests/functional/network/v2/test_bgp.py | 5c169862027c27b2c319fe669504a1298fff92a9 | [
"Apache-2.0"
] | permissive | openstack/openstacksdk | b4b95fd7869653feea5a3b783e9a5c588235c039 | d474eb84c605c429bb9cccb166cabbdd1654d73c | refs/heads/master | 2023-09-03T22:50:03.398512 | 2023-07-27T14:09:35 | 2023-08-29T16:28:46 | 16,223,378 | 124 | 130 | Apache-2.0 | 2023-09-06T02:52:47 | 2014-01-25T02:48:00 | Python | UTF-8 | Python | false | false | 5,346 | py | test_bgp.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
# distributed under t... |
d9b9d062c5e64d2e87d0d099394e11f0e20486a1 | 643207c42f07413c4723b49426faa91f3c47ff66 | /tests/test_api.py | ccaf321df635c1e10155b8e092e0a02e4e6aa482 | [
"BSD-3-Clause",
"LicenseRef-scancode-public-domain"
] | permissive | sourmash-bio/sourmash | 74da4910c0bad3e14655be2d92c2ba8534813bfa | ba581ea8c6f046b7e19da274155f326d2bdbc8e7 | refs/heads/latest | 2023-09-03T13:13:02.374178 | 2023-08-27T15:01:49 | 2023-08-27T15:01:49 | 55,858,065 | 149 | 23 | NOASSERTION | 2023-09-13T22:25:54 | 2016-04-09T17:35:30 | Python | UTF-8 | Python | false | false | 2,475 | py | test_api.py | import pytest
import sourmash
import sourmash_tst_utils as utils
@utils.in_tempdir
def test_sourmash_signature_api(c):
e = sourmash.MinHash(n=1, ksize=20)
sig = sourmash.SourmashSignature(e)
with open(c.output('xxx.sig'), 'wt') as fp:
sourmash.save_signatures([sig], fp)
sig_x1 = sourmash.loa... |
649bc63d25859e304edfe739a0a535964c6b01d3 | d3ef2463f556d6cd166eb29d3a5f5b210a6402e7 | /cupy/linalg/_product.py | aef7e10cd457b7cbf0d350f49bd04f9395e7278d | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | cupy/cupy | ce7a010a57504dbfe4fb5af10d354a22e79f4907 | 96105afb78aa3f8380834d2516184b8365e23fcb | refs/heads/main | 2023-08-31T00:36:47.967611 | 2023-08-30T09:19:27 | 2023-08-30T09:19:27 | 72,523,920 | 7,505 | 1,072 | MIT | 2023-09-14T01:04:42 | 2016-11-01T09:54:45 | Python | UTF-8 | Python | false | false | 12,853 | py | _product.py | import collections.abc
import numbers
import numpy
import cupy
from cupy import _core
from cupy._core import internal
from cupy._core._gufuncs import _GUFunc
from cupy.linalg import _solve
from cupy.linalg import _util
matmul = _GUFunc(
_core.matmul,
'(n?,k),(k,m?)->(n?,m?)',
supports_batched=True,
... |
1a9cdf1bddc05b9d9962a848ed35cc26d30894e4 | 6c29f457a5e787309b344fec53c133845d8985e8 | /fairscale/nn/pipe/rpc.py | f7d7f37b6b5be5379eb3393108e04448aeed4483 | [
"Apache-2.0",
"MIT",
"BSD-3-Clause",
"BSD-2-Clause"
] | permissive | facebookresearch/fairscale | eb378e44cca951e242fb58f82522d9ba8e87d732 | 164cc0f3170b4a3951dd84dda29c3e1504ac4d6e | refs/heads/main | 2023-09-04T12:48:14.924836 | 2023-04-20T03:41:53 | 2023-04-20T03:41:53 | 277,899,703 | 2,553 | 257 | NOASSERTION | 2023-08-28T19:02:48 | 2020-07-07T19:02:01 | Python | UTF-8 | Python | false | false | 10,227 | py | rpc.py | # Copyright (c) Facebook, Inc. and its affiliates. All rights reserved.
#
# This source code is licensed under the BSD license found in the
# LICENSE file in the root directory of this source tree.
from threading import Event, Lock, Thread
from typing import Any, Callable, Dict, List, Optional, Tuple, Union, cast
imp... |
320c232b34cf96d3419b9271cc5104007b422ecd | eecd5e4c50d8b78a769bcc2675250576bed34066 | /src/binding/petsc4py/demo/legacy/wrap-swig/run_demo.py | 24597e33c4725d2f8733b2bf8e9e1851d32edbcb | [
"BSD-2-Clause"
] | permissive | petsc/petsc | 3b1a04fea71858e0292f9fd4d04ea11618c50969 | 9c5460f9064ca60dd71a234a1f6faf93e7a6b0c9 | refs/heads/main | 2023-08-17T20:51:16.507070 | 2023-08-17T16:08:06 | 2023-08-17T16:08:06 | 8,691,401 | 341 | 169 | NOASSERTION | 2023-03-29T11:02:58 | 2013-03-10T20:55:21 | C | UTF-8 | Python | false | false | 1,915 | py | run_demo.py | import sys, petsc4py
petsc4py.init(sys.argv)
from petsc4py import PETSc
import Bratu3D as Bratu3D
class App(object):
def __init__(self, da, lambda_):
assert da.getDim() == 3
self.da = da
self.params = Bratu3D.Params()
self.params.lambda_ = lambda_
def formInitGuess(self, X):
... |
1835c396c92d47d614aba98d97bad902f78733f2 | 5dc77586e3e0f9de1f032fd2ca68494d8e58928f | /tests/datasource/test_batch_kwargs.py | 191821c75bd5189d512248df032920082a05d237 | [
"Apache-2.0"
] | permissive | great-expectations/great_expectations | dd7c22e6277d6b08bee3ff38a015e6e8cd434df6 | b0290e2fd2aa05aec6d7d8871b91cb4478e9501d | refs/heads/develop | 2023-09-04T09:30:26.395518 | 2023-09-02T00:00:13 | 2023-09-02T00:00:13 | 103,071,520 | 8,931 | 1,535 | Apache-2.0 | 2023-09-14T19:57:16 | 2017-09-11T00:18:46 | Python | UTF-8 | Python | false | false | 2,286 | py | test_batch_kwargs.py | import pytest
from great_expectations.datasource.types import * # noqa: F403
@pytest.mark.unit
def test_batch_kwargs_id():
test_batch_kwargs = PathBatchKwargs({"path": "/data/test.csv"}) # noqa: F405
# When there is only a single "important" key used in batch_kwargs, the ID can prominently include it
a... |
45c0e4a6c6cb678790b8dd19fd4c5923a22196bd | 529e713a78e82de2ae5d44cfb8ef209e0894d72a | /intro-to-bokeh/code-snippets/linked-selection.py | 745457a15c9beaf1c7abd97d694b824275ff381a | [
"MIT",
"CC-BY-SA-4.0"
] | 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,745 | py | linked-selection.py | # Bokeh Libraries
from bokeh.plotting import figure, show
from bokeh.io import output_file
from bokeh.models import (
ColumnDataSource,
CategoricalColorMapper,
NumeralTickFormatter,
)
from bokeh.layouts import gridplot
# Output inline in the notebook
output_file(
"phi-gm-linked-selections.html", title=... |
4078f71769bc42b43538b168ff02fa2dcceaf286 | 53a83642c01a8828e3d7bd0b18e33c3b694c2b84 | /Python/GeeksforGeeks/count_of_smaller_elements.py | 4c5c5e115f8b81dcf6f13fccf56eb7e64ca150ac | [] | no_license | anantkaushik/Competitive_Programming | 1dcd60a28b5b951c23024d6090942be081ad249f | 6dba38fd7aa4e71b5196d01d64e81f9336d08b13 | refs/heads/master | 2022-03-06T15:36:23.797340 | 2022-02-21T12:00:37 | 2022-02-21T12:00:37 | 82,700,948 | 271 | 95 | null | 2020-10-27T17:34:39 | 2017-02-21T16:18:16 | Python | UTF-8 | Python | false | false | 1,049 | py | count_of_smaller_elements.py | """
Given an sorted array of size n. Find number of elements which are less than or equal to given element.
Input:
The first line of input contains an integer T denoting the number of test cases. Then T test cases follow.
Each test case contains an integer n denoting the size of the array. Then the next line contains... |
969b5ce5b08b0ea77da64eb29bfb1036250a1d0d | 3dc647cd07a7361ed401e40d2b7cce8c826c8f6c | /Lib/sre_parse.py | 83119168e6376ee83bb41f7b75d2c9a0cd3058d7 | [
"Python-2.0",
"CC-BY-4.0",
"MIT"
] | permissive | RustPython/RustPython | 5ddce4a9848b9de8c041ffd2634f83c0105d3f39 | b864e5da1f18897fc884180b7093df5aa170024f | refs/heads/main | 2023-09-04T12:38:29.458699 | 2023-09-03T12:33:42 | 2023-09-03T12:33:42 | 135,201,145 | 15,815 | 1,302 | MIT | 2023-09-14T08:11:45 | 2018-05-28T19:27:01 | Rust | UTF-8 | Python | false | false | 40,230 | py | sre_parse.py | #
# Secret Labs' Regular Expression Engine
#
# convert re-style regular expression to sre pattern
#
# Copyright (c) 1998-2001 by Secret Labs AB. All rights reserved.
#
# See the sre.py file for information on usage and redistribution.
#
"""Internal support module for sre"""
# XXX: show string offset and offending ch... |
b4d47b18393f1f5cc91b55b5d14f67fd1b370803 | aa2dd0720ac3cf261c7e2d2cdf3d88dee68360d5 | /kinto/plugins/openid/__init__.py | 40806616ee4fdc0fe0a59233bcbdf13f5dd1cdfc | [
"Apache-2.0"
] | permissive | Kinto/kinto | 3025e269a5f2ecc8077fd44fbb1e6c38ae6a4a8b | 6edf6453033e0106410fe1f8c70323b6fea2f2fe | refs/heads/master | 2023-08-31T13:36:10.987472 | 2023-08-22T09:37:52 | 2023-08-22T09:37:52 | 31,315,021 | 4,764 | 575 | NOASSERTION | 2023-09-13T14:41:08 | 2015-02-25T13:34:23 | Python | UTF-8 | Python | false | false | 4,863 | py | __init__.py | import requests
from pyramid import authentication as base_auth
from pyramid.interfaces import IAuthenticationPolicy
from pyramid.settings import aslist
from zope.interface import implementer
from kinto.core import logger
from kinto.core import utils as core_utils
from kinto.core.openapi import OpenAPI
from .utils im... |
9e8179c7c0b35029fcdde1d00e84972cdd5cdc18 | 9138a287b2553f75566cad948463b04bb6f4ca14 | /phone_numbers.py | de0c83010c43b6ae70ed7cf988e3732108fe095c | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0",
"MIT"
] | permissive | Charcoal-SE/SmokeDetector | 606c3dbfb92564b22b141d9caab42ccec7eacf4d | 83b0ea59b2e90b4dc316719b097c1f374aba1d06 | refs/heads/master | 2023-09-04T02:29:08.555872 | 2023-09-03T21:39:11 | 2023-09-03T21:39:11 | 16,389,919 | 510 | 343 | Apache-2.0 | 2023-09-14T21:02:08 | 2014-01-30T20:29:37 | Python | UTF-8 | Python | false | false | 21,242 | py | phone_numbers.py | # coding=utf-8
import regex
import number_homoglyphs
from helpers import get_only_digits, remove_end_regex_comments
# The NUMBER_REGEXes are used to obtain strings within a post which are considered to be a single "number". While
# it would be nice to be able to just use a single regular expression like:
# r'(?:... |
af612ccbdf372d2d3328d584f8b2d0d24e84a428 | 7944d899365f7bc849f367b72f4cc285e041826c | /submitit/__init__.py | 3051ac611f7afcbfd4edc92aa3177ca605819b4b | [
"MIT"
] | permissive | facebookincubator/submitit | 39edc49ad3c97883dd22cb7fe625d2db55f105d7 | 109f7c7f098de6775397e2b84826d59101a29a9f | refs/heads/main | 2023-08-22T05:39:19.476497 | 2023-08-16T14:00:41 | 2023-08-16T14:00:41 | 258,441,818 | 947 | 111 | MIT | 2023-04-05T15:24:09 | 2020-04-24T07:41:09 | Python | UTF-8 | Python | false | false | 852 | py | __init__.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.
""""Python 3.6+ toolbox for submitting jobs to Slurm"""
# allow explicit reimports (mypy) by renaming all imports
from . import helpers as he... |
5ac9239532fea8ebc2b4bf40ba6792ffe143e80c | fd8ef75bb06383538cdb21ed2a0ef88e570179b7 | /src/openfermion/resource_estimates/pbc/thc/compute_thc_resources_test.py | ec0b82c087a88d48f7ac55a11187c6d59b9223c2 | [
"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 | 3,187 | py | compute_thc_resources_test.py | # coverage: ignore
# 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, so... |
de29053adcf6d7d1c7ff39a8e2f15bdfb8450add | d92d607fe5e4f27a2f2c5f8676e5400e5410674f | /fwtool/util/__init__.py | c3e65dd22b5ef02b32e8256b46de6d939d839c01 | [
"MIT"
] | permissive | ma1co/fwtool.py | 38bfc3018d70421265c246a128e8137ed954d7a6 | cdba742b73eed5981480c326aeb30033aabf0223 | refs/heads/master | 2022-09-21T20:40:53.945202 | 2022-09-14T10:42:23 | 2022-09-14T10:42:23 | 45,698,894 | 147 | 34 | MIT | 2021-05-02T08:16:12 | 2015-11-06T18:14:11 | Python | UTF-8 | Python | false | false | 1,934 | py | __init__.py | """Some utility functions to unpack integers"""
import binascii
import struct
from collections import namedtuple
def parse64be(data):
return struct.unpack('>Q', data)[0]
def dump64be(value):
return struct.pack('>Q', value)
def parse64le(data):
return struct.unpack('<Q', data)[0]
def dump64le(value):
return st... |
0c233916ca5b1938f1982f0295d45a35c9999531 | 08a25eadde07c7489136c61f80bf326651c293f6 | /ros_ws/src/crazyswarm/scripts/test_yamlString.py | d01c8842a1996444c336e054f9a40224eaa08cd1 | [
"MIT"
] | permissive | USC-ACTLab/crazyswarm | 36c03d308882518d998c4ab6b26e7e8f5c05745f | beb05492eaf226462631545bf5972199099267c2 | refs/heads/master | 2023-06-03T04:31:43.944450 | 2022-12-17T19:15:17 | 2022-12-17T19:15:17 | 68,335,694 | 296 | 296 | MIT | 2023-05-12T18:08:28 | 2016-09-15T22:18:11 | Python | UTF-8 | Python | false | false | 664 | py | test_yamlString.py | #!/usr/bin/env python
import numpy as np
from pycrazyswarm import *
def test_yaml_string_load():
crazyflies_yaml = """
crazyflies:
- channel: 100
id: 1
initialPosition: [1.0, 0.0, 0.0]
- channel: 100
id: 10
initialPosition: [0.0, -1.0, 0.0]
"""
swarm = Crazyswarm(craz... |
bd7fc201f4a6045710b58c3d917e187bd45a082c | eb9f655206c43c12b497c667ba56a0d358b6bc3a | /python/testData/inspections/AddKwargsToIncompatibleOverridingMethod_after.py | fb2aea89cc45ad605e441e4f5f8f4394b6b1b1ae | [
"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 | 103 | py | AddKwargsToIncompatibleOverridingMethod_after.py | class Base:
def m(self, x):
pass
class Sub(Base):
def m(self, **kwargs):
pass |
90fd153b66672fd35a957f3f27b6dee87bdfc261 | dcbef06d5a00f07756339b9e62c684dec2fee425 | /tests/basics/ReferencingTest.py | 05760384d7238c5e25b9baa5c86094de254cd0dd | [
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer"
] | permissive | Nuitka/Nuitka | f9543d8d95bfa0b81d4e60af0dfad99fb72893a4 | d87faf2f7e1d6ed9bfe4cf8c1d648f34307e33f2 | refs/heads/develop | 2023-08-28T14:00:32.861328 | 2023-08-27T09:16:45 | 2023-08-27T09:16:45 | 9,626,741 | 8,573 | 599 | Apache-2.0 | 2023-09-13T02:49:41 | 2013-04-23T15:40:33 | Python | UTF-8 | Python | false | false | 23,841 | py | ReferencingTest.py | # Copyright 2023, Kay Hayen, mailto:kay.hayen@gmail.com
#
# Python tests originally created or extracted from other peoples work. The
# parts were too small to be protected.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the ... |
f57748da658712c9a03c8df0cc827ea4d2ff85e7 | d5f7b5be2ef5e8a9d5d170cd45aa949243687d8d | /blog/migrations/0011_setting_enable_multi_user.py | b957596f001b571ac7a004b4d641554de0e17634 | [
"MIT"
] | permissive | enjoy-binbin/Django-blog | 494af449f085e77460da500763037b28d00c560a | 0fcf3709fabeee49874343b3a4ab80582698c466 | refs/heads/master | 2022-12-13T06:16:59.091138 | 2020-12-08T04:21:54 | 2020-12-08T04:21:54 | 171,880,388 | 113 | 24 | MIT | 2022-11-22T04:45:56 | 2019-02-21T13:51:02 | Python | UTF-8 | Python | false | false | 549 | py | 0011_setting_enable_multi_user.py | # Generated by Django 2.1.5 on 2019-06-07 15:42
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('blog', '0010_setting_user_verify_email'),
]
operations = [
migrations.AddField(
model_name='setting',
name='enable_m... |
3603c8f439317528ad8a7e7461d4f73787009cd2 | 1ec0cf2205deb58b97495e1b5d0a8df3b1f3faf1 | /concordia/settings_ecs.py | 2f6718ddcfb3f69f46b97ff1b60f2bb40fe5e7cf | [
"LicenseRef-scancode-public-domain",
"CC0-1.0"
] | permissive | LibraryOfCongress/concordia | f9d937223320bb6b9185f764485d14d22c06f4cd | 2f345cd177c3ae0ec3913e39c21332f5a35f634b | refs/heads/main | 2023-08-22T05:28:58.717760 | 2023-08-21T18:46:22 | 2023-08-21T18:46:22 | 134,269,274 | 152 | 36 | NOASSERTION | 2023-09-14T18:50:49 | 2018-05-21T12:56:57 | Python | UTF-8 | Python | false | false | 2,659 | py | settings_ecs.py | import json
import os
from .secrets import get_secret
from .settings_template import * # NOQA ignore=F405
from .settings_template import CONCORDIA_ENVIRONMENT, DATABASES, INSTALLED_APPS
if os.getenv("AWS"):
ENV_NAME = os.getenv("ENV_NAME")
django_secret_json = get_secret("crowd/%s/Django/SecretKey" % ENV_NA... |
111b5928b7dcf453af8e1da8f423570d5d762cdd | 0e083f405af00029c9ec31849f0f7f81c56844b5 | /mmdeploy/codebase/mmdet3d/deploy/mmdet3d.py | bd817b7593db8a9bd4bf017ee5995ec3fb88a0d7 | [
"Apache-2.0"
] | permissive | open-mmlab/mmdeploy | 39b9e7b611caab2c76a6142fcb99f0bf1d92ad24 | 5479c8774f5b88d7ed9d399d4e305cb42cc2e73a | refs/heads/main | 2023-09-01T21:29:25.315371 | 2023-08-31T09:59:29 | 2023-08-31T09:59:29 | 441,467,833 | 2,164 | 605 | Apache-2.0 | 2023-09-14T10:39:04 | 2021-12-24T13:04:44 | Python | UTF-8 | Python | false | false | 691 | py | mmdet3d.py | # Copyright (c) OpenMMLab. All rights reserved.
from mmengine.registry import Registry
from mmdeploy.codebase.base import CODEBASE, MMCodebase
from mmdeploy.utils import Codebase
MMDET3D_TASK = Registry('mmdet3d_tasks')
@CODEBASE.register_module(Codebase.MMDET3D.value)
class MMDetection3d(MMCodebase):
"""MMDete... |
c2b79a3f9b471e97a5690cd7cd177bad2ea037b7 | ef1f316534f2df302286eb168951255afe137a55 | /pynetdicom/fsm.py | a5fd93c2d4ab4fa59665fe31c352bbc01ee8d642 | [
"MIT"
] | permissive | pydicom/pynetdicom | 5362b4f3d03bc47e570cf3d82684925cb3d4162d | 2aa9ed7e3f7f03a0c9af48fe8b0049c82e74ee48 | refs/heads/master | 2023-08-16T23:09:24.539133 | 2023-07-21T17:38:22 | 2023-07-21T17:38:22 | 69,436,608 | 342 | 122 | MIT | 2023-07-20T19:04:04 | 2016-09-28T07:18:02 | Python | UTF-8 | Python | false | false | 35,804 | py | fsm.py | """
The DUL's finite state machine representation.
"""
import logging
import queue
from typing import TYPE_CHECKING, cast
from pynetdicom import evt
from pynetdicom.pdu import (
A_ASSOCIATE_RQ,
A_ASSOCIATE_RJ,
A_ASSOCIATE_AC,
P_DATA_TF,
A_RELEASE_RQ,
A_RELEASE_RP,
A_ABORT_RQ,
)
from pynetdi... |
50acf9deb4e8c27a8f5eef4d061717f0c4a0a750 | 568fa58296378fa129ab3349adf010daa44ed45b | /third_party/incubator-tvm/tests/python/unittest/test_pass_split_pipeline.py | 380053420f44fc5a1ef25392ab9fb691b6e6413a | [
"Apache-2.0",
"BSD-3-Clause",
"NCSA",
"X11-distribute-modifications-variant",
"Zlib",
"MIT",
"LicenseRef-scancode-unknown-license-reference",
"Unlicense",
"LLVM-exception",
"BSD-2-Clause"
] | permissive | mindspore-ai/akg | 37f471badc66de6a831f1f45ad84344f34d23ef2 | 99f33858d6972741748cbfc9ab0bf9600428fef7 | refs/heads/master | 2023-07-25T23:03:17.672665 | 2023-07-11T07:33:57 | 2023-07-11T07:33:57 | 274,077,856 | 319 | 36 | Apache-2.0 | 2021-12-30T13:43:08 | 2020-06-22T08:09:05 | Python | UTF-8 | Python | false | false | 2,586 | py | test_pass_split_pipeline.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... |
8ebaca8d796ec8ab4e100ea952734e68f97bf9a6 | afd2087e80478010d9df66e78280f75e1ff17d45 | /tools/stats/upload_test_stat_aggregates.py | 38e4177032f6eebe5da811159c95992197fc1fd3 | [
"BSD-3-Clause",
"BSD-2-Clause",
"LicenseRef-scancode-secret-labs-2011",
"LicenseRef-scancode-generic-cla",
"BSL-1.0",
"Apache-2.0"
] | permissive | pytorch/pytorch | 7521ac50c47d18b916ae47a6592c4646c2cb69b5 | a6f7dd4707ac116c0f5fb5f44f42429f38d23ab4 | refs/heads/main | 2023-08-03T05:05:02.822937 | 2023-08-03T00:40:33 | 2023-08-03T04:14:52 | 65,600,975 | 77,092 | 24,610 | NOASSERTION | 2023-09-14T21:58:39 | 2016-08-13T05:26:41 | Python | UTF-8 | Python | false | false | 2,962 | py | upload_test_stat_aggregates.py | import argparse
import ast
import datetime
import json
import os
import re
from typing import Any, List, Union
import rockset # type: ignore[import]
from tools.stats.upload_stats_lib import upload_to_s3
def get_oncall_from_testfile(testfile: str) -> Union[List[str], None]:
path = f"test/{testfile}"
if not ... |
66673b9edd605a7f897fb25f7ab302f3a0ac571e | 0948f5944bcb95af55ac258d6104044ddbedab6b | /setup_examples/epd_waveshare_42_pico.py | 79b8f780635c7a9afecb195cc6511f1475478037 | [
"MIT"
] | permissive | peterhinch/micropython-nano-gui | e9b7ca20535bbb52c695083deb28721074cfa71e | 5eef93317e83bc767da88fba8acdfc2a167db794 | refs/heads/master | 2023-06-22T09:27:18.739604 | 2023-06-12T13:43:47 | 2023-06-12T13:43:47 | 146,632,615 | 360 | 78 | MIT | 2023-09-02T09:08:16 | 2018-08-29T17:07:07 | Python | UTF-8 | Python | false | false | 749 | py | epd_waveshare_42_pico.py | # color_setup.py Customise for your hardware config
# Released under the MIT License (MIT). See LICENSE.
# Copyright (c) 2022 Peter Hinch
# Supports Waveshare 4.2" 400x300 ePaper display with Raspberry Pico
# https://thepihut.com/collections/epaper-displays-for-raspberry-pi/products/4-2-e-paper-display-module-for-ras... |
ce53daa5fd37a81a446735c8c3a99e722ca9e067 | 0b134572e3ac3903ebb44df6d4138cbab9d3327c | /app/grandchallenge/teams/admin.py | 567c2c34d259ad0f7f6e15e5f4ee58175251003f | [
"Apache-2.0"
] | permissive | comic/grand-challenge.org | 660de3bafaf8f4560317f1dfd9ae9585ec272896 | dac25f93b395974b32ba2a8a5f9e19b84b49e09d | refs/heads/main | 2023-09-01T15:57:14.790244 | 2023-08-31T14:23:04 | 2023-08-31T14:23:04 | 4,557,968 | 135 | 53 | Apache-2.0 | 2023-09-14T13:41:03 | 2012-06-05T09:26:39 | Python | UTF-8 | Python | false | false | 393 | py | admin.py | from django.contrib import admin
from grandchallenge.core.admin import (
GroupObjectPermissionAdmin,
UserObjectPermissionAdmin,
)
from grandchallenge.teams.models import (
TeamGroupObjectPermission,
TeamUserObjectPermission,
)
admin.site.register(TeamUserObjectPermission, UserObjectPermissionAdmin)
ad... |
fb13d91f01104c56e450cb7404f95ca00675312f | bbfc9f05efefe29b6ce9832bb3506efb900c1c93 | /tencentcloud/bsca/v20210811/models.py | 92197515fa4b92b105f634058d119e97cf0c74d7 | [
"Apache-2.0"
] | permissive | TencentCloud/tencentcloud-sdk-python | a2fab235926b0a27e9cfdf55e085a8bb15b3f506 | 6baf00a5a56ba58b6a1123423e0a1422d17a0201 | refs/heads/master | 2023-09-04T10:52:28.060438 | 2023-09-01T03:09:16 | 2023-09-01T03:09:16 | 130,147,399 | 594 | 300 | Apache-2.0 | 2023-09-06T07:03:24 | 2018-04-19T02:23:12 | Python | UTF-8 | Python | false | false | 49,093 | py | models.py | # -*- coding: utf8 -*-
# Copyright (c) 2017-2021 THL A29 Limited, a Tencent company. 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... |
3314f624bd47bb4c637d26b7fa7761e7f0b5ee92 | fe56f956d9b0fab1f8f72647a57baaf8d0dd39b7 | /toscaparser/policy.py | 8c9e00a0a92aca178e43ab897d307a687e5f2030 | [
"Apache-2.0"
] | permissive | openstack/tosca-parser | cf05510d62e97aaeed2e4948416c8cf241e975d9 | 283cb6a375070c844547e18e119bcad53e8489ca | refs/heads/master | 2023-09-04T11:02:17.299078 | 2023-07-07T07:02:05 | 2023-07-12T05:39:18 | 41,282,275 | 103 | 63 | Apache-2.0 | 2020-11-05T12:15:17 | 2015-08-24T04:40:10 | Python | UTF-8 | Python | false | false | 3,406 | py | policy.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
# d... |
7cdc090edf0724b3d518278b38561376fc53b2af | 95b5388157d6c0b14883bfc7102d54f8c5737b0a | /src/opnsense/scripts/proxy/lib/__init__.py | 5fd16676b152039c2cb0a111f17834babcf1e439 | [
"BSD-2-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | opnsense/core | f071a087984a8d8b2b2e6ca152cf73645f9bc68a | a702cf9fb3300e125cd7acc8af3813474606e509 | refs/heads/master | 2023-09-01T05:20:10.627528 | 2023-08-31T13:10:59 | 2023-08-31T13:10:59 | 27,965,134 | 2,778 | 1,014 | BSD-2-Clause | 2023-09-14T15:45:24 | 2014-12-13T15:43:50 | PHP | UTF-8 | Python | false | false | 5,774 | py | __init__.py | """
Copyright (c) 2020 Ad Schellevis <ad@opnsense.org>
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,
... |
183893e67668d657083587978087649db1290d5f | 62179a165ec620ba967dbc20016e890978fbff50 | /examples/tensorflow/common/object_detection/utils/yolo_v4_utils.py | b527130a850e9df3f2c5a0b612a884777cfaa37a | [
"Apache-2.0"
] | permissive | openvinotoolkit/nncf | 91fcf153a96f85da166aacb7a70ca4941e4ba4a4 | c027c8b43c4865d46b8de01d8350dd338ec5a874 | refs/heads/develop | 2023-08-24T11:25:05.704499 | 2023-08-23T14:44:05 | 2023-08-23T14:44:05 | 263,687,600 | 558 | 157 | Apache-2.0 | 2023-09-14T17:06:41 | 2020-05-13T16:41:05 | Python | UTF-8 | Python | false | false | 13,070 | py | yolo_v4_utils.py | # Copyright (c) 2023 Intel 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 in writ... |
a9308b8e3993e756d5a1bbdece20ffb0f81ec66e | 67ca269e39935d0c439329c3a63df859e40168bb | /test/test_pipeline/test_metrics.py | 0a40d84bb82905587f634a245094117c8bb3e190 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference",
"LicenseRef-scancode-philippe-de-muyter"
] | permissive | automl/Auto-PyTorch | 2e67ffb44f40d9993470ded9b63f10a5164b41df | 56a2ac1d69c7c61a847c678879a67f5d3672b3e8 | refs/heads/master | 2023-07-14T22:55:57.826602 | 2022-08-23T16:43:15 | 2022-08-23T16:43:15 | 159,791,040 | 2,214 | 280 | Apache-2.0 | 2023-04-04T14:41:15 | 2018-11-30T08:18:34 | Python | UTF-8 | Python | false | false | 13,329 | py | test_metrics.py | import numpy as np
import pytest
import sklearn.metrics
import sktime.performance_metrics.forecasting as forecasting_metrics
from autoPyTorch.constants import (
BINARY,
CONTINUOUS,
OUTPUT_TYPES_TO_STRING,
STRING_TO_TASK_TYPES,
TABULAR_CLASSIFICATION,
TABULAR_REGRESSION,
TASK_TYPES_TO_STR... |
f06a737c39700a7ebd24ce8cd0fa4689316f5de4 | 39220ced634414fa06f3906b4d293cfbd966dd6f | /rf/rfstream.py | 00a7a55c2fba8c7b9c6e240420b9d067ea1527b0 | [
"MIT"
] | permissive | trichter/rf | 817e60823a0a54ed86c723b98a982a0407de6807 | bccd99759559029af4d533b1ba853fea0527c6a8 | refs/heads/master | 2022-11-25T05:14:49.193352 | 2022-11-16T10:36:54 | 2022-11-16T10:36:54 | 8,273,581 | 103 | 74 | MIT | 2021-05-20T09:04:41 | 2013-02-18T17:38:22 | Python | UTF-8 | Python | false | false | 28,059 | py | rfstream.py | # -*- coding: utf-8 -*-
# Copyright 2013-2019 Tom Eulenfeld, MIT license
"""
Classes and functions for receiver function calculation.
"""
import json
from operator import itemgetter
from pkg_resources import resource_filename
import warnings
import numpy as np
from obspy import read, Stream, Trace
from obspy.core impo... |
afb2825c409b91730913bfc84a586a191e8362c7 | 5ef7f5ba06b98319a5406dfa3b25c985257713d4 | /IGC/common/autogen.py | d2306293800d480b49ef47deeefc7b57d72d9675 | [
"MIT"
] | permissive | intel/intel-graphics-compiler | 6a1ae1a84c541e967e70324492f22c941a02e38f | ea522543be6d042ec80e5db8e8878be31af68938 | refs/heads/master | 2023-09-03T20:31:55.215461 | 2023-08-29T18:31:52 | 2023-09-02T08:55:05 | 105,299,467 | 546 | 176 | NOASSERTION | 2023-08-23T08:57:03 | 2017-09-29T17:27:54 | C++ | UTF-8 | Python | false | false | 9,495 | py | autogen.py | # ========================== begin_copyright_notice ============================
#
# Copyright (C) 2017-2023 Intel Corporation
#
# SPDX-License-Identifier: MIT
#
# =========================== end_copyright_notice =============================
import os
import sys
import errno
import re
from typing import List, Tuple, ... |
efafc9045e057701cecdb8f94827f192845bc507 | 3c2ee998c99a693b3b04d44f8c5af0fc5fb2c49d | /tests/backend/integration/api/users/test_tasks.py | 36788d3a737719bd1104c9ad20e76856da314547 | [
"BSD-2-Clause"
] | permissive | hotosm/tasking-manager | 4520a56b31b35ebfc82a337bc7e676f1f8bc946a | 45bf3937c74902226096aee5b49e7abea62df524 | refs/heads/develop | 2023-09-01T02:43:43.875659 | 2023-08-16T21:26:02 | 2023-08-29T13:15:52 | 80,733,077 | 526 | 316 | BSD-2-Clause | 2023-09-14T10:15:55 | 2017-02-02T14:31:35 | JavaScript | UTF-8 | Python | false | false | 8,595 | py | test_tasks.py | from tests.backend.base import BaseTestCase
from tests.backend.helpers.test_helpers import (
create_canned_project,
generate_encoded_token,
)
from backend.models.postgis.task import Task, TaskStatus
from backend.models.postgis.statuses import ProjectStatus
class TetUsersTasksAPI(BaseTestCase):
def setUp(s... |
100d7eb95b7babb92e39757b808b1de6b0a7f875 | 59bb398c5f23770e4725f35f932f3a5fd013efae | /jwst/scripts/migrate_data.py | cc9d1954896ee1f585998a857a87dfc0ba1f49b0 | [
"BSD-2-Clause"
] | permissive | spacetelescope/jwst | 9826d86781c6e01aced951882471f8b967fa1f6e | a4a0e8ad2b88249f01445ee1dcf175229c51033f | refs/heads/master | 2023-09-04T09:54:04.504036 | 2023-08-31T20:19:27 | 2023-08-31T20:19:27 | 60,551,519 | 449 | 106 | NOASSERTION | 2023-09-14T21:21:33 | 2016-06-06T18:34:23 | Jupyter Notebook | UTF-8 | Python | false | false | 6,806 | py | migrate_data.py | #!/usr/bin/env python
"""
Migrate .fits files whose format has changed between jwst package versions.
"""
import argparse
from datetime import datetime
import os
import re
import traceback
import warnings
import asdf
from astropy.io import fits
from astropy.time import Time
import numpy as np
from packaging.specifier... |
925cc34a86ca5948a30c7203071fb271711d436e | 9efca95a55cb4df52d895d42f1ec10331516a734 | /tools/c7n_mailer/c7n_mailer/gcp_mailer/gcp_queue_processor.py | f86a01e808e4e698190b65329ecf04b924c67d6f | [
"Apache-2.0"
] | permissive | cloud-custodian/cloud-custodian | 519e602abe00c642786441b64cc40857ef5bc9de | 27563cf4571040f923124e1acb2463f11e372225 | refs/heads/main | 2023-09-04T10:54:55.963703 | 2023-09-01T17:40:17 | 2023-09-01T17:40:17 | 52,837,350 | 3,327 | 1,096 | Apache-2.0 | 2023-09-14T14:03:30 | 2016-03-01T01:11:20 | Python | UTF-8 | Python | false | false | 3,052 | py | gcp_queue_processor.py | # Copyright The Cloud Custodian Authors.
# SPDX-License-Identifier: Apache-2.0
"""
Google Queue Message Processing
==============================
"""
import base64
import json
import zlib
from c7n_mailer.target import MessageTargetMixin
try:
from c7n_gcp.client import Session
except ImportError:
raise Import... |
1a18d6a3a680157cc10560d6479001bb808241c0 | c4e93e5e88b9a38fb1b5e4a398810c9e165df80f | /devicedefender/script/DDTestRun.py | 601cd88a187ffa1ef5f43e8d82d7e16469c11f2a | [
"Apache-2.0"
] | permissive | aws/aws-iot-device-sdk-cpp-v2 | c7c441024e19a24d3ebf4cc9f05c2ed15a4c2b89 | 1ddf4ab749155abe195acab9f9505791a93b9b45 | refs/heads/main | 2023-09-03T15:05:45.057875 | 2023-09-01T20:33:54 | 2023-09-01T20:33:54 | 157,451,948 | 148 | 108 | Apache-2.0 | 2023-09-01T20:33:56 | 2018-11-13T21:51:08 | C++ | UTF-8 | Python | false | false | 9,165 | py | DDTestRun.py | import boto3
import uuid
import os
import subprocess
import platform
# On something other than Linux? Pass the test instantly since Device Defender is only supported on Linux
if platform.system() != "Linux":
print("[Device Defender]Info: Skipped Test - " + platform.system() +
" not supported (Only Linux ... |
34e98a8b560f35ba6130efccb2bd9101402c4e6a | 307d3837d31f9e3728af2b62ca51ebf63fe6ec6b | /wlwl1011/BOJ/DP/DP_12015.py | 8d011a60a6e085d31b73613b5e902a8f01bb496d | [] | no_license | ellynhan/challenge100-codingtest-study | 905043497d154b8a7333ca536e536d013f6e7454 | bcdc6d04f13b12ba80b42e066f9d244d7c2cc698 | refs/heads/master | 2023-09-01T14:10:13.481013 | 2023-08-27T14:38:52 | 2023-08-27T14:38:52 | 401,561,230 | 162 | 176 | null | 2023-09-09T14:56:25 | 2021-08-31T03:30:36 | C++ | UTF-8 | Python | false | false | 462 | py | DP_12015.py |
import sys
input = sys.stdin.readline
n = int(input())
cases = list(map(int, input().split()))
lis = [-1000000001]
for case in cases:
#print(lis)
if lis[-1]<case:
lis.append(case)
else:
left = 0
right = len(lis)
while left<right:
mid = (right+left)//2
... |
d7d633a99b3fb855ee64ad2ab9a4e8844e97a5c0 | f8c5b73c9706470c4dd60d523096e18bc448a960 | /certbot-ci/certbot_integration_tests/utils/constants.py | 5aabe379ac9a4c0b89519be31f67829b409d9172 | [
"MIT",
"Apache-2.0"
] | permissive | certbot/certbot | 14ab43d76fcf0242d875d551f0d98334c43e7957 | b1978ff18837e40d16eedf2090330af53d8ceaa5 | refs/heads/master | 2023-09-04T00:37:03.739195 | 2023-08-26T23:19:38 | 2023-08-26T23:19:38 | 26,516,210 | 18,581 | 3,265 | NOASSERTION | 2023-09-12T15:18:59 | 2014-11-12T02:52:20 | Python | UTF-8 | Python | false | false | 562 | py | constants.py | """Some useful constants to use throughout certbot-ci integration tests"""
DEFAULT_HTTP_01_PORT = 5002
BOULDER_HTTP_01_PORT = 80
TLS_ALPN_01_PORT = 5001
CHALLTESTSRV_PORT = 8055
BOULDER_V2_CHALLTESTSRV_URL = f'http://10.77.77.77:{CHALLTESTSRV_PORT}'
BOULDER_V2_DIRECTORY_URL = 'http://localhost:4001/directory'
PEBBLE_DI... |
450dea56a1f3ab5aab0c8ca58f5505345dfcc01a | 0f2b08b31fab269c77d4b14240b8746a3ba17d5e | /tools/ci_build/reduce_op_kernels.py | 6b73b1e063e58ceeb41c3982891079e1cbaeecf6 | [
"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 | 14,490 | py | reduce_op_kernels.py | # !/usr/bin/env python3
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
import argparse
import io
import re
import shutil
import sys
import typing
from pathlib import Path
import op_registration_utils
from logger import get_logger
# directory containing the reduced op fi... |
9893c0b58a504634470b13dcdccf60477359728a | e366027ffef496d43350b044d0574127c512d690 | /tools/device_file_generator/dfg/identifiers.py | 2e30d572e33ecf435174839b9acb31843a4c9406 | [] | no_license | roboterclubaachen/xpcc | aa504f3d0a8246861dd00ea437cc7b938a869669 | 010924901947381d20e83b838502880eb2ffea72 | refs/heads/develop | 2021-01-24T11:18:27.233788 | 2019-01-03T18:55:35 | 2019-01-03T18:55:35 | 3,626,127 | 163 | 51 | null | 2018-06-30T19:15:55 | 2012-03-05T10:49:18 | C | UTF-8 | Python | false | false | 5,597 | py | identifiers.py | # -*- coding: utf-8 -*-
# Copyright (c) 2013, Roboterclub Aachen e.V.
# All rights reserved.
#
# The file is part of the xpcc library and is released under the 3-clause BSD
# license. See the file `LICENSE` for the full license governing this code.
# ---------------------------------------------------------------------... |
4c0553cc4581a830597ced881d77af8f5c3a889c | 6032d4c2a046e2c5601099593660807217944019 | /elephant/test/test_spectral.py | d6272af97325744cd8e49b94dd42523bbd499fc0 | [
"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 | 55,129 | py | test_spectral.py | # -*- coding: utf-8 -*-
"""
Unit tests for the spectral module.
:copyright: Copyright 2014-2023 by the Elephant team, see `doc/authors.rst`.
:license: Modified BSD, see LICENSE.txt for details.
"""
import unittest
import neo.core
import numpy as np
import pytest
import quantities as pq
import scipy
import scipy.fft
... |
faf57217de842b0aa4ea07c531cb8ee24e8dec1a | a5a99f646e371b45974a6fb6ccc06b0a674818f2 | /HLTriggerOffline/SMP/python/hltSMPPostProcessor_cfi.py | 9c2388bb06f8689c5988aa0f746027b83a070a4a | [
"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 | 484 | py | hltSMPPostProcessor_cfi.py | import FWCore.ParameterSet.Config as cms
from DQMServices.Core.DQMEDHarvester import DQMEDHarvester
hltSMPPostProcessor = DQMEDHarvester("DQMGenericClient",
subDirs = cms.untracked.vstring('HLT/SMP/*'),
verbose = cms.untracked.uint32(2),
outputFileName = cms.untracked.string(''),
... |
58ba04be9f174b79256354fc7d4fb62221fac471 | 213b8cab639c7d45cbf6a4fd46eb23e379d9d374 | /python/nsound_examples/drum.py | 5952263de3993859017063ce9bf7afbdeaa35c5b | [] | no_license | DevDungeon/Cookbook | f85b04b690ea0a202ddfaeda6460b6ba5797cb70 | a49a1c77f2b89dc303fa9f2563bb3c19777e4c6c | refs/heads/master | 2023-05-12T06:58:50.606019 | 2022-03-30T04:48:16 | 2022-03-30T04:48:16 | 34,371,982 | 307 | 94 | null | 2023-05-03T22:53:45 | 2015-04-22T06:02:53 | HTML | UTF-8 | Python | false | false | 2,215 | py | drum.py | ###############################################################################
#
# $Id: example3.py 718 2012-04-15 23:59:35Z weegreenblobbie $
#
# Simulates a drum. Based on the Csound drum by Hans Mikelson.
#
# source: http://www.csounds.com/ezine/winter2001/synthesis/
#
##########################################... |
5f8d7315fc707e78fbc2677cc980e9a5f94e0e2d | e25a98b616384794ac59e1b1d18f856d2d4507e1 | /rplugin/python3/deoplete/sources/rust.py | 5664f3d9c2581dcb75eadf34f652e15afd2ef46d | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | sebastianmarkow/deoplete-rust | 0ed26c1526b37382485bcbc94b52db921c513717 | 0a86e502113910c33448b337c4d50cabea120d25 | refs/heads/master | 2021-07-16T21:55:52.854385 | 2017-07-18T16:20:47 | 2017-07-18T16:20:47 | 63,178,377 | 146 | 14 | MIT | 2021-03-04T11:42:28 | 2016-07-12T17:24:29 | Vim script | UTF-8 | Python | false | false | 2,745 | py | rust.py | """Rust completion via Racer"""
import os
import re
import subprocess
import tempfile
from .base import Base
from deoplete.logger import getLogger
logger = getLogger('rust')
VAR_RACER_BINARY = 'deoplete#sources#rust#racer_binary'
VAR_RUST_SOURCE = 'deoplete#sources#rust#rust_source_path'
VAR_DUPLICATION = 'deoplete... |
3584d9f857c4cc6aea67627e6f867a6f99538223 | b8441dc1987be9e64fa3081d456b2a3060ec44d1 | /mars/tensor/arithmetic/isreal.py | 3fc405358e8107636fb00e5632929573304b45bc | [
"BSD-3-Clause",
"MIT",
"ISC",
"Apache-2.0",
"CC0-1.0",
"BSD-2-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | mars-project/mars | f99fefbce999d58a9249bc72046787a9731c9c73 | c36c53fa22e10ef9477d9c454401a2f281375f31 | refs/heads/master | 2023-07-23T00:23:55.133015 | 2023-07-03T11:44:54 | 2023-07-03T11:44:54 | 160,543,708 | 2,704 | 362 | Apache-2.0 | 2023-09-11T07:57:35 | 2018-12-05T16:04:03 | Python | UTF-8 | Python | false | false | 1,661 | py | isreal.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright 1999-2021 Alibaba Group Holding 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-... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.