hexsha
stringlengths
40
40
size
int64
4
996k
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
245
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
245
max_issues_repo_name
stringlengths
6
130
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
245
max_forks_repo_name
stringlengths
6
130
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
4
996k
avg_line_length
float64
1.33
58.2k
max_line_length
int64
2
323k
alphanum_fraction
float64
0
0.97
content_no_comment
stringlengths
0
946k
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
f7fcc95deeeeb42de9b52e629a5151cc201fa630
2,161
py
Python
mello/member/models.py
mmbln/mello
baf13571fd6b14130a586cca40ef9c1d739faa60
[ "Apache-2.0" ]
null
null
null
mello/member/models.py
mmbln/mello
baf13571fd6b14130a586cca40ef9c1d739faa60
[ "Apache-2.0" ]
null
null
null
mello/member/models.py
mmbln/mello
baf13571fd6b14130a586cca40ef9c1d739faa60
[ "Apache-2.0" ]
null
null
null
# member/models.py # -*- coding: utf-8 -*- from django.db import models from django.contrib.auth.models import ( AbstractBaseUser, BaseUserManager ) class MemberManager(BaseUserManager): def create_user(self, login_name, email, full_name='', ...
27.705128
54
0.49329
from django.db import models from django.contrib.auth.models import ( AbstractBaseUser, BaseUserManager ) class MemberManager(BaseUserManager): def create_user(self, login_name, email, full_name='', member_img='', ...
true
true
f7fcca0a35e1be8d8151f161a1c5a5e661c20009
2,211
py
Python
archives/tk/mixin.py
mcxiaoke/python-labs
61c0a1f91008ba82fc2f5a5deb19e60aec9df960
[ "Apache-2.0" ]
7
2016-07-08T10:53:13.000Z
2021-07-20T00:20:10.000Z
archives/tk/mixin.py
mcxiaoke/python-labs
61c0a1f91008ba82fc2f5a5deb19e60aec9df960
[ "Apache-2.0" ]
1
2021-05-11T05:20:18.000Z
2021-05-11T05:20:18.000Z
archives/tk/mixin.py
mcxiaoke/python-labs
61c0a1f91008ba82fc2f5a5deb19e60aec9df960
[ "Apache-2.0" ]
7
2016-10-31T06:31:54.000Z
2020-08-31T20:55:00.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Author: mcxiaoke # @Date: 2015-08-10 21:24:18 # GUI编码技术 from __future__ import print_function import sys import os from Tkinter import * from lib import * from tkSimpleDialog import * from tkFileDialog import * from tkMessageBox import * from launchmodes import Porta...
26.638554
73
0.631841
from __future__ import print_function import sys import os from Tkinter import * from lib import * from tkSimpleDialog import * from tkFileDialog import * from tkMessageBox import * from launchmodes import PortableLauncher,System class GuiMixin: def infobox(self,title,text,*args): return showinfo(t...
true
true
f7fcca1eb0939f053393119dec322ffe3e75b582
76,611
py
Python
mlflow/pyfunc/__init__.py
sniafas/mlflow
c577c7f199d9efa076344785dabb2121edb7e6c8
[ "Apache-2.0" ]
null
null
null
mlflow/pyfunc/__init__.py
sniafas/mlflow
c577c7f199d9efa076344785dabb2121edb7e6c8
[ "Apache-2.0" ]
null
null
null
mlflow/pyfunc/__init__.py
sniafas/mlflow
c577c7f199d9efa076344785dabb2121edb7e6c8
[ "Apache-2.0" ]
null
null
null
""" The ``python_function`` model flavor serves as a default model interface for MLflow Python models. Any MLflow Python model is expected to be loadable as a ``python_function`` model. In addition, the ``mlflow.pyfunc`` module defines a generic :ref:`filesystem format <pyfunc-filesystem-format>` for Python models and...
45.251624
114
0.649933
import importlib import tempfile import signal import sys import numpy as np import os import pandas import yaml from copy import deepcopy import logging import threading import collections import subprocess from typing import Any, Union, List, Dict, Iterator, Tuple import mlflow import mlflow.pyfunc.model from mlfl...
true
true
f7fccaa7e6f13b7526e7dafd7be37ba892507bd8
19,447
py
Python
src/genie/libs/parser/iosxr/tests/test_show_static_routing.py
jeremyschulman/genieparser
a8c0e48a75f22b633834d0b25ff95b4a0a7f89f9
[ "Apache-2.0" ]
null
null
null
src/genie/libs/parser/iosxr/tests/test_show_static_routing.py
jeremyschulman/genieparser
a8c0e48a75f22b633834d0b25ff95b4a0a7f89f9
[ "Apache-2.0" ]
null
null
null
src/genie/libs/parser/iosxr/tests/test_show_static_routing.py
jeremyschulman/genieparser
a8c0e48a75f22b633834d0b25ff95b4a0a7f89f9
[ "Apache-2.0" ]
1
2021-07-07T18:07:56.000Z
2021-07-07T18:07:56.000Z
import unittest from unittest.mock import Mock # ATS from ats.topology import Device from genie.metaparser.util.exceptions import SchemaEmptyParserError, \ SchemaMissingKeyError from genie.libs.parser.iosxr.show_static_routing import ShowStaticTopologyDetail # ================...
50.643229
152
0.329871
import unittest from unittest.mock import Mock from ats.topology import Device from genie.metaparser.util.exceptions import SchemaEmptyParserError, \ SchemaMissingKeyError from genie.libs.parser.iosxr.show_static_routing import ShowStaticTopologyDetail class test_show_stat...
true
true
f7fcce2ab6dd01c89a0f5e80b3b1129040edbfaf
5,626
py
Python
platformio/app.py
seryoni/platformio
35a602cfefde288ffe72f6d21436ac6785ffcab4
[ "Apache-2.0" ]
null
null
null
platformio/app.py
seryoni/platformio
35a602cfefde288ffe72f6d21436ac6785ffcab4
[ "Apache-2.0" ]
null
null
null
platformio/app.py
seryoni/platformio
35a602cfefde288ffe72f6d21436ac6785ffcab4
[ "Apache-2.0" ]
1
2019-07-17T07:16:24.000Z
2019-07-17T07:16:24.000Z
# Copyright 2014-2016 Ivan Kravets <me@ikravets.com> # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or...
29.767196
75
0.6262
import json from copy import deepcopy from os import environ, getenv from os.path import getmtime, isfile, join from time import time from lockfile import LockFile from platformio import __version__, util from platformio.exception import InvalidSettingName, InvalidSettingValue DEFAULT_SETTINGS = { ...
true
true
f7fcce60aa6bf1d2109d51dcafd5d010200ebbaf
680
py
Python
challanges/find_maximum_value_binary_tree/test_find_maximum_value_binary_tree.py
Patricia888/data-structures-and-algorithms
8963acf857b9f7069eeeea2884b41376986c3d7c
[ "MIT" ]
null
null
null
challanges/find_maximum_value_binary_tree/test_find_maximum_value_binary_tree.py
Patricia888/data-structures-and-algorithms
8963acf857b9f7069eeeea2884b41376986c3d7c
[ "MIT" ]
null
null
null
challanges/find_maximum_value_binary_tree/test_find_maximum_value_binary_tree.py
Patricia888/data-structures-and-algorithms
8963acf857b9f7069eeeea2884b41376986c3d7c
[ "MIT" ]
null
null
null
from .find_maximum_value_binary_tree import find_maximum_value, BST def test_find_maximum_value_tree_with_one_value(): one_value = BST([5]) assert find_maximum_value(one_value) == 5 def test_find_maximum_value_tree_with_two_values(): one_value = BST([10, 2]) assert find_maximum_value(one_value) == 1...
25.185185
67
0.720588
from .find_maximum_value_binary_tree import find_maximum_value, BST def test_find_maximum_value_tree_with_one_value(): one_value = BST([5]) assert find_maximum_value(one_value) == 5 def test_find_maximum_value_tree_with_two_values(): one_value = BST([10, 2]) assert find_maximum_value(one_value) == 1...
true
true
f7fccf66051670cc2221f2bdee989c483ebfd7d3
2,154
py
Python
tungsten_tempest_plugin/services/contrail/json/virtual_network_client.py
Vegasq/tungsten-tempest
624584cd1a2298b92a44223de1ca7ae23c6f3476
[ "Apache-2.0" ]
1
2019-04-29T09:00:16.000Z
2019-04-29T09:00:16.000Z
tungsten_tempest_plugin/services/contrail/json/virtual_network_client.py
Vegasq/tungsten-tempest
624584cd1a2298b92a44223de1ca7ae23c6f3476
[ "Apache-2.0" ]
11
2018-12-04T14:20:27.000Z
2019-05-30T14:37:13.000Z
tungsten_tempest_plugin/services/contrail/json/virtual_network_client.py
Vegasq/tungsten-tempest
624584cd1a2298b92a44223de1ca7ae23c6f3476
[ "Apache-2.0" ]
9
2018-07-26T18:20:45.000Z
2020-03-27T17:40:56.000Z
# Copyright 2016 AT&T Corp # 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...
28.342105
78
0.616527
from oslo_serialization import jsonutils as json from tungsten_tempest_plugin.services.contrail.json import base class VirtualNetworkClient(base.BaseContrailClient): def list_virtual_networks(self): url = '/virtual-networks' return self.get(url) def create_virtual_networks(s...
true
true
f7fcd003bc9e3f57ec944b1eb041edb86ca93e84
6,381
py
Python
rafiki/model/model.py
dcslin/rafiki
b617ac2536ac13095c4930d6d3f1f9b3c231b5e7
[ "Apache-2.0" ]
null
null
null
rafiki/model/model.py
dcslin/rafiki
b617ac2536ac13095c4930d6d3f1f9b3c231b5e7
[ "Apache-2.0" ]
null
null
null
rafiki/model/model.py
dcslin/rafiki
b617ac2536ac13095c4930d6d3f1f9b3c231b5e7
[ "Apache-2.0" ]
null
null
null
# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not...
39.147239
152
0.692681
import abc import numpy as np from typing import Union, Dict, Optional, Any, List from .knob import BaseKnob KnobConfig = Dict[str, BaseKnob] Knobs = Dict[str, Any] Params = Dict[str, Union[str, int, float, np.ndarray]] class BaseModel(abc.ABC): def __init__(self, **knobs: Knobs): pass...
true
true
f7fcd065302faab42706ab33888811125efb3b4f
2,177
py
Python
tslearn/metrics/sax.py
hoangph3/tslearn
c589de380398379f2587f8cc812571d2a6d75938
[ "BSD-2-Clause" ]
null
null
null
tslearn/metrics/sax.py
hoangph3/tslearn
c589de380398379f2587f8cc812571d2a6d75938
[ "BSD-2-Clause" ]
null
null
null
tslearn/metrics/sax.py
hoangph3/tslearn
c589de380398379f2587f8cc812571d2a6d75938
[ "BSD-2-Clause" ]
null
null
null
from .utils import _cdist_generic from .cysax import cydist_sax __author__ = 'Romain Tavenard romain.tavenard[at]univ-rennes2.fr' def cdist_sax(dataset1, breakpoints_avg, size_fitted, dataset2=None, n_jobs=None, verbose=0): r"""Calculates a matrix of distances (MINDIST) on SAX-transformed data, ...
36.898305
109
0.66881
from .utils import _cdist_generic from .cysax import cydist_sax __author__ = 'Romain Tavenard romain.tavenard[at]univ-rennes2.fr' def cdist_sax(dataset1, breakpoints_avg, size_fitted, dataset2=None, n_jobs=None, verbose=0): return _cdist_generic(cydist_sax, dataset1, dataset2, n_jobs, verbose, ...
true
true
f7fcd07c385c54db18a51dac00e4537cf5d590f6
4,792
py
Python
tests/orchestrator/orchestrator_test_utils.py
priyaananthasankar/azure-functions-durable-python-1
5494962583ff12794d3c856f098e0bded8d74069
[ "MIT" ]
null
null
null
tests/orchestrator/orchestrator_test_utils.py
priyaananthasankar/azure-functions-durable-python-1
5494962583ff12794d3c856f098e0bded8d74069
[ "MIT" ]
null
null
null
tests/orchestrator/orchestrator_test_utils.py
priyaananthasankar/azure-functions-durable-python-1
5494962583ff12794d3c856f098e0bded8d74069
[ "MIT" ]
null
null
null
import json from typing import Callable, Iterator, Any, Dict, List from jsonschema import validate from azure.durable_functions.models import DurableOrchestrationContext, DurableEntityContext from azure.durable_functions.orchestrator import Orchestrator from azure.durable_functions.entity import Entity from .schemas.O...
39.603306
94
0.750417
import json from typing import Callable, Iterator, Any, Dict, List from jsonschema import validate from azure.durable_functions.models import DurableOrchestrationContext, DurableEntityContext from azure.durable_functions.orchestrator import Orchestrator from azure.durable_functions.entity import Entity from .schemas.O...
true
true
f7fcd19b730da61f68f260162f74a6b533ba7c7b
5,640
py
Python
configs/representation/ssb/ssb_r18_nc_sgd_cos_100e_r5_8x8x1_k400.py
happywu/mmaction2-CycleContrast
019734e471dffd1161b7a9c617ba862d2349a96c
[ "Apache-2.0" ]
null
null
null
configs/representation/ssb/ssb_r18_nc_sgd_cos_100e_r5_8x8x1_k400.py
happywu/mmaction2-CycleContrast
019734e471dffd1161b7a9c617ba862d2349a96c
[ "Apache-2.0" ]
null
null
null
configs/representation/ssb/ssb_r18_nc_sgd_cos_100e_r5_8x8x1_k400.py
happywu/mmaction2-CycleContrast
019734e471dffd1161b7a9c617ba862d2349a96c
[ "Apache-2.0" ]
null
null
null
# model settings temperature = 0.2 with_norm = True query_dim = 128 model = dict( type='SimSiamBaseTracker', backbone=dict( type='ResNet', pretrained=None, depth=18, out_indices=(3, ), # strides=(1, 2, 1, 1), norm_cfg=dict(type='SyncBN', requires_grad=True), ...
30.160428
78
0.616312
temperature = 0.2 with_norm = True query_dim = 128 model = dict( type='SimSiamBaseTracker', backbone=dict( type='ResNet', pretrained=None, depth=18, out_indices=(3, ), norm_cfg=dict(type='SyncBN', requires_grad=True), norm_eval=False, zero_init_r...
true
true
f7fcd38e1cc8fb21f3696adb053153039060e030
6,249
py
Python
kademlia/crawling.py
Ketherz/kademlia
1df52909f8cee33b659ac4e60c1acf1e88d118a6
[ "MIT" ]
745
2015-01-05T13:38:18.000Z
2022-03-30T11:43:42.000Z
kademlia/crawling.py
Ketherz/kademlia
1df52909f8cee33b659ac4e60c1acf1e88d118a6
[ "MIT" ]
86
2015-06-04T01:35:12.000Z
2021-10-12T12:15:35.000Z
kademlia/crawling.py
Ketherz/kademlia
1df52909f8cee33b659ac4e60c1acf1e88d118a6
[ "MIT" ]
234
2015-01-09T18:16:13.000Z
2022-01-30T22:03:03.000Z
from collections import Counter import logging from kademlia.node import Node, NodeHeap from kademlia.utils import gather_dict log = logging.getLogger(__name__) # pylint: disable=invalid-name # pylint: disable=too-few-public-methods class SpiderCrawl: """ Crawl the network and look for given 160-bit keys....
33.961957
79
0.601056
from collections import Counter import logging from kademlia.node import Node, NodeHeap from kademlia.utils import gather_dict log = logging.getLogger(__name__) class SpiderCrawl: def __init__(self, protocol, node, peers, ksize, alpha): self.protocol = protocol self.ksize = ksize sel...
true
true
f7fcd3baf0a28568187795a29f36ab0bff17aaae
50
py
Python
add 2 numbers.py
SimranSwain/Days_of_Code
bce154a40c816ddef70a7262a9ed0c7bc6d1bed3
[ "MIT" ]
null
null
null
add 2 numbers.py
SimranSwain/Days_of_Code
bce154a40c816ddef70a7262a9ed0c7bc6d1bed3
[ "MIT" ]
null
null
null
add 2 numbers.py
SimranSwain/Days_of_Code
bce154a40c816ddef70a7262a9ed0c7bc6d1bed3
[ "MIT" ]
null
null
null
x,y=input().split() sum=int(x)+int(y) print(sum)
16.666667
20
0.62
x,y=input().split() sum=int(x)+int(y) print(sum)
true
true
f7fcd4435f07b49fbaf12abc8035608cae23a7a9
41,617
py
Python
google/cloud/bigtable_admin_v2/services/bigtable_table_admin/transports/grpc_asyncio.py
mf2199/python-bigtable
ee3a6c4c5f810fab08671db3407195864ecc1972
[ "Apache-2.0" ]
34
2020-07-27T19:14:01.000Z
2022-03-31T14:46:53.000Z
google/cloud/bigtable_admin_v2/services/bigtable_table_admin/transports/grpc_asyncio.py
mf2199/python-bigtable
ee3a6c4c5f810fab08671db3407195864ecc1972
[ "Apache-2.0" ]
254
2020-01-31T23:44:06.000Z
2022-03-23T22:52:49.000Z
google/cloud/bigtable_admin_v2/services/bigtable_table_admin/transports/grpc_asyncio.py
mf2199/python-bigtable
ee3a6c4c5f810fab08671db3407195864ecc1972
[ "Apache-2.0" ]
30
2020-01-31T20:45:34.000Z
2022-03-23T19:56:42.000Z
# -*- coding: utf-8 -*- # Copyright 2020 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or...
43.85353
104
0.645698
import warnings from typing import Awaitable, Callable, Dict, Optional, Sequence, Tuple, Union from google.api_core import gapic_v1 from google.api_core import grpc_helpers_async from google.api_core import operations_v1 from google.auth import credentials as ga_credentials from google.auth.transport....
true
true
f7fcd50af5aae83442cbf89fb1dca61f56cd3e54
881
py
Python
services/dynamic-sidecar/tests/unit/test_api_mocked.py
colinRawlings/osparc-simcore
bf2f18d5bc1e574d5f4c238d08ad15156184c310
[ "MIT" ]
25
2018-04-13T12:44:12.000Z
2022-03-12T15:01:17.000Z
services/dynamic-sidecar/tests/unit/test_api_mocked.py
colinRawlings/osparc-simcore
bf2f18d5bc1e574d5f4c238d08ad15156184c310
[ "MIT" ]
2,553
2018-01-18T17:11:55.000Z
2022-03-31T16:26:40.000Z
services/dynamic-sidecar/tests/unit/test_api_mocked.py
colinRawlings/osparc-simcore
bf2f18d5bc1e574d5f4c238d08ad15156184c310
[ "MIT" ]
20
2018-01-18T19:45:33.000Z
2022-03-29T07:08:47.000Z
# pylint: disable=redefined-outer-name # pylint: disable=unused-argument import json import pytest from async_asgi_testclient import TestClient from async_asgi_testclient.response import Response pytestmark = pytest.mark.asyncio def assert_200_empty(response: Response) -> bool: assert response.status_code == ...
24.472222
88
0.662883
import json import pytest from async_asgi_testclient import TestClient from async_asgi_testclient.response import Response pytestmark = pytest.mark.asyncio def assert_200_empty(response: Response) -> bool: assert response.status_code == 200, response.text assert json.loads(response.text) == "" retur...
true
true
f7fcd52a0c4a9306acb7afa6782f59365c264c82
599
py
Python
app/backend/src/couchers/constants.py
foormea/couchers
4015769e5cdfbb9b9e10460fd979cccc5f203b88
[ "MIT" ]
226
2020-12-01T23:46:57.000Z
2022-03-30T20:48:48.000Z
app/backend/src/couchers/constants.py
stifler6005/couchers
bf3d1f0fda0f1734aa83f18959639cb64ee2a25d
[ "MIT" ]
1,713
2020-10-06T14:20:02.000Z
2022-03-31T17:22:49.000Z
app/backend/src/couchers/constants.py
stifler6005/couchers
bf3d1f0fda0f1734aa83f18959639cb64ee2a25d
[ "MIT" ]
80
2020-11-19T00:12:55.000Z
2022-03-27T19:21:26.000Z
from datetime import timedelta # terms of service version TOS_VERSION = 2 # community guidelines version GUIDELINES_VERSION = 1 EMAIL_REGEX = r"^[0-9a-z][0-9a-z\-\_\+\.]*@([0-9a-z\-]+\.)*[0-9a-z\-]+\.[a-z]{2,}$" # expiry time for a verified phone number PHONE_VERIFICATION_LIFETIME = timedelta(days=2 * 365) # short...
24.958333
83
0.744574
from datetime import timedelta TOS_VERSION = 2 GUIDELINES_VERSION = 1 EMAIL_REGEX = r"^[0-9a-z][0-9a-z\-\_\+\.]*@([0-9a-z\-]+\.)*[0-9a-z\-]+\.[a-z]{2,}$" PHONE_VERIFICATION_LIFETIME = timedelta(days=2 * 365) PHONE_REVERIFICATION_INTERVAL = timedelta(days=180) SMS_CODE_LIFETIME = timedelta(hours=24) SMS_COD...
true
true
f7fcd5d094d4527c5717a303d4a027799ab3d53a
1,899
py
Python
sa/profiles/Linksys/SPS2xx/get_interface_status.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
84
2017-10-22T11:01:39.000Z
2022-02-27T03:43:48.000Z
sa/profiles/Linksys/SPS2xx/get_interface_status.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
22
2017-12-11T07:21:56.000Z
2021-09-23T02:53:50.000Z
sa/profiles/Linksys/SPS2xx/get_interface_status.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
23
2017-12-06T06:59:52.000Z
2022-02-24T00:02:25.000Z
# --------------------------------------------------------------------- # Linksys.SPS2xx.get_interface_status # --------------------------------------------------------------------- # Copyright (C) 2007-2011 The NOC Project # See LICENSE for details # --------------------------------------------------------------------...
33.910714
97
0.4297
import re from noc.core.script.base import BaseScript from noc.sa.interfaces.igetinterfacestatus import IGetInterfaceStatus class Script(BaseScript): name = "Linksys.SPS2xx.get_interface_status" interface = IGetInterfaceStatus rx_interface_status = re.compile( r"^(?P<interface>\S+)\s+\S...
true
true
f7fcd83f1113785621f870aec8de831dccc8f971
2,131
py
Python
Person Matching Code/code/DeepFeatures/sample.py
pavitradangati/PersonMatching
6d8a9689193fed0ef0e3e9f3fad19710e595d9e0
[ "MIT" ]
null
null
null
Person Matching Code/code/DeepFeatures/sample.py
pavitradangati/PersonMatching
6d8a9689193fed0ef0e3e9f3fad19710e595d9e0
[ "MIT" ]
null
null
null
Person Matching Code/code/DeepFeatures/sample.py
pavitradangati/PersonMatching
6d8a9689193fed0ef0e3e9f3fad19710e595d9e0
[ "MIT" ]
null
null
null
import numpy as np import pandas as pd feature_array = np.load('./faceFeaturesGT.npy') indices_array = (pd.read_csv('./imageListGT.csv')).values print(feature_array.shape, indices_array.shape) print(indices_array[:10, :]) final_array = np.concatenate((feature_array, indices_array), axis = 1) print(final_array.shape) ...
40.980769
101
0.711872
import numpy as np import pandas as pd feature_array = np.load('./faceFeaturesGT.npy') indices_array = (pd.read_csv('./imageListGT.csv')).values print(feature_array.shape, indices_array.shape) print(indices_array[:10, :]) final_array = np.concatenate((feature_array, indices_array), axis = 1) print(final_array.shape) ...
false
true
f7fcd879a9f448ab8fd8168d030097c7aef4b611
812
py
Python
manage.py
managedbyq/mbq.ranch
3bd66c2ce6b508c4b0acdfc97775c04e024bd1ff
[ "Apache-2.0" ]
null
null
null
manage.py
managedbyq/mbq.ranch
3bd66c2ce6b508c4b0acdfc97775c04e024bd1ff
[ "Apache-2.0" ]
1
2019-03-06T19:57:31.000Z
2019-03-06T19:57:31.000Z
manage.py
managedbyq/mbq.ranch
3bd66c2ce6b508c4b0acdfc97775c04e024bd1ff
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import os import sys if __name__ == "__main__": os.environ.setdefault("DJANGO_SETTINGS_MODULE", "tests.settings") try: from django.core.management import execute_from_command_line except ImportError: # The above import may fail for some other reason. Ensure that the ...
33.833333
77
0.639163
import os import sys if __name__ == "__main__": os.environ.setdefault("DJANGO_SETTINGS_MODULE", "tests.settings") try: from django.core.management import execute_from_command_line except ImportError: try: import django except ImportError: ...
true
true
f7fcd8c13db638ebba08b092eacf442cf7166f9c
12,628
py
Python
neo/io/neuroexplorerio.py
pearsonlab/python-neo
8915dfe9e55fd3a36be83d820bdd83ab085e9402
[ "BSD-3-Clause" ]
null
null
null
neo/io/neuroexplorerio.py
pearsonlab/python-neo
8915dfe9e55fd3a36be83d820bdd83ab085e9402
[ "BSD-3-Clause" ]
null
null
null
neo/io/neuroexplorerio.py
pearsonlab/python-neo
8915dfe9e55fd3a36be83d820bdd83ab085e9402
[ "BSD-3-Clause" ]
1
2018-04-13T04:48:48.000Z
2018-04-13T04:48:48.000Z
# -*- coding: utf-8 -*- """ Class for reading data from NeuroExplorer (.nex) Documentation for dev : http://www.neuroexplorer.com/code.html Depend on: Supported : Read Author: sgarcia,luc estebanez """ import os import struct import numpy as np import quantities as pq from neo.io.baseio import BaseIO from neo.c...
38.266667
79
0.460881
import os import struct import numpy as np import quantities as pq from neo.io.baseio import BaseIO from neo.core import Segment, AnalogSignal, SpikeTrain, Epoch, Event class NeuroExplorerIO(BaseIO): is_readable = True is_writable = False supported_objects = [Segment, AnalogSignal, SpikeTrain, Event...
true
true
f7fcd8eaa37b662acbcbb74a9b239347427d0730
4,060
py
Python
threathunter_common_python/threathunter_common/geo/ip.py
threathunterX/python_lib
e2d4052de04c82cb7bccd08042f28db824cab442
[ "Apache-2.0" ]
2
2019-03-17T04:03:08.000Z
2019-05-01T09:42:23.000Z
threathunter_common_python/threathunter_common/geo/ip.py
threathunterX/python_lib
e2d4052de04c82cb7bccd08042f28db824cab442
[ "Apache-2.0" ]
null
null
null
threathunter_common_python/threathunter_common/geo/ip.py
threathunterX/python_lib
e2d4052de04c82cb7bccd08042f28db824cab442
[ "Apache-2.0" ]
4
2019-06-24T05:47:24.000Z
2020-09-29T05:00:31.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- import array __author__ = "nebula" import os import socket import struct try: import mmap except ImportError: mmap = None __all__ = ['IPv4Database', 'find'] _unpack_L = lambda b: struct.unpack("<L", b)[0] _unpack_B = lambda b: struct.unpack(">L", b)[0] def ip2...
25.217391
90
0.526847
import array __author__ = "nebula" import os import socket import struct try: import mmap except ImportError: mmap = None __all__ = ['IPv4Database', 'find'] _unpack_L = lambda b: struct.unpack("<L", b)[0] _unpack_B = lambda b: struct.unpack(">L", b)[0] def ip2int(addr): return struct.unpack("!I", so...
true
true
f7fcd8f7daaba05dcd3deb235395446c973c7019
1,300
py
Python
logistic_lda/utils.py
sam-cts/logistic_lda
405caf212ba0def212feb82f8d9aaec1e491f735
[ "Apache-2.0" ]
16
2019-10-17T16:29:28.000Z
2021-12-09T12:45:18.000Z
logistic_lda/utils.py
sam-cts/logistic_lda
405caf212ba0def212feb82f8d9aaec1e491f735
[ "Apache-2.0" ]
null
null
null
logistic_lda/utils.py
sam-cts/logistic_lda
405caf212ba0def212feb82f8d9aaec1e491f735
[ "Apache-2.0" ]
3
2020-02-19T07:12:25.000Z
2020-09-14T08:45:44.000Z
""" Copyright 2019 Twitter, Inc. Licensed under the Apache License, Version 2.0 http://www.apache.org/licenses/LICENSE-2.0 """ import numpy as np import tensorflow as tf def softmax_cross_entropy(targets, logits): """ Implements a simple softmax cross entropy. $$-\sum_i t_{ni} \cdot (l_{ni} - \ln \sum_j \exp ...
26
89
0.708462
import numpy as np import tensorflow as tf def softmax_cross_entropy(targets, logits): logprobs = logits - tf.reduce_logsumexp(logits, axis=1, keepdims=True) return -tf.reduce_sum(targets * logprobs, axis=1) def create_table(keys, values=None, name=None): if values is None: values = np.arange(len(keys)...
true
true
f7fcd9abd569bddb9f6c8e830195823b867c12ee
2,486
py
Python
courses/machine_learning/deepdive/06_structured/labs/serving/application/main.py
laurenzberger/training-data-analyst
3e2ef4668c5088ab50ad50a4f29673c88fb1bcd3
[ "Apache-2.0" ]
6,140
2016-05-23T16:09:35.000Z
2022-03-30T19:00:46.000Z
courses/machine_learning/deepdive/06_structured/labs/serving/application/main.py
laurenzberger/training-data-analyst
3e2ef4668c5088ab50ad50a4f29673c88fb1bcd3
[ "Apache-2.0" ]
1,384
2016-07-08T22:26:41.000Z
2022-03-24T16:39:43.000Z
courses/machine_learning/deepdive/06_structured/labs/serving/application/main.py
laurenzberger/training-data-analyst
3e2ef4668c5088ab50ad50a4f29673c88fb1bcd3
[ "Apache-2.0" ]
5,110
2016-05-27T13:45:18.000Z
2022-03-31T18:40:42.000Z
# -*- coding: utf-8 -*- # Copyright 2017 Google Inc. # # 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...
28.574713
77
0.706356
import json import os from flask import Flask from flask import jsonify from flask import render_template from flask import request from flask import url_for from googleapiclient import discovery from oauth2client.client import GoogleCredentials from google.appengine.api import app_identity credent...
false
true
f7fcdb8edfb45efe56cc2373fb6484374d41a107
12,455
py
Python
scripts/tutorial_simulation.py
Agnarsh/functions
64a408ecf55773f38c5ce3b2fe75119e7235e9c9
[ "Apache-2.0" ]
null
null
null
scripts/tutorial_simulation.py
Agnarsh/functions
64a408ecf55773f38c5ce3b2fe75119e7235e9c9
[ "Apache-2.0" ]
null
null
null
scripts/tutorial_simulation.py
Agnarsh/functions
64a408ecf55773f38c5ce3b2fe75119e7235e9c9
[ "Apache-2.0" ]
null
null
null
# ***************************************************************************** # © Copyright IBM Corp. 2018. All Rights Reserved. # # This program and the accompanying materials # are made available under the terms of the Apache V2.0 license # which accompanies this distribution, and is available at # http://www.apac...
45.290909
127
0.708551
import json import logging from sqlalchemy import Column, Integer, String, Float, DateTime, Boolean, func from iotfunctions import bif from iotfunctions.metadata import EntityType from iotfunctions.db import Database from iotfunctions.enginelog import EngineLogging import datetime as dt EngineLogging.configu...
true
true
f7fcdbfb237b3efaece2844f03a4bba4be6be0b5
7,867
py
Python
circuit_training/learning/train_ppo_lib.py
sguada/circuit_training
220ca925c83cdc6e67181c305da577f305c602b3
[ "Apache-2.0" ]
null
null
null
circuit_training/learning/train_ppo_lib.py
sguada/circuit_training
220ca925c83cdc6e67181c305da577f305c602b3
[ "Apache-2.0" ]
1
2022-01-18T23:08:19.000Z
2022-01-19T03:04:29.000Z
circuit_training/learning/train_ppo_lib.py
sguada/circuit_training
220ca925c83cdc6e67181c305da577f305c602b3
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # Copyright 2021 The Circuit Training Team Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by ap...
35.922374
80
0.729376
import os import time from absl import flags from absl import logging from circuit_training.learning import agent from circuit_training.learning import learner as learner_lib import reverb import tensorflow as tf from tf_agents.experimental.distributed import reverb_variable_container from tf_agents...
true
true
f7fcde68ea974a3a794023ab79e0f6b36b8568ab
2,541
py
Python
webscripts/prepdata.py
KathrynDH/DataDashboard
1bf61497480f778a1c7cc9ce9fc7fb48b3067606
[ "MIT" ]
null
null
null
webscripts/prepdata.py
KathrynDH/DataDashboard
1bf61497480f778a1c7cc9ce9fc7fb48b3067606
[ "MIT" ]
null
null
null
webscripts/prepdata.py
KathrynDH/DataDashboard
1bf61497480f778a1c7cc9ce9fc7fb48b3067606
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Mon Jun 21 11:04:16 2021 @author: Kathryn Haske Load data and create graphs for webpage Function get_graphs called by myapp/routes.py """ from webscripts.getdata import read_data from webscripts.plotlygraphs import line_graph, scatter_plot, bar_chart def get_graphs(): """ ...
26.46875
84
0.552145
from webscripts.getdata import read_data from webscripts.plotlygraphs import line_graph, scatter_plot, bar_chart def get_graphs(): files = ['data/worldbanklit.csv','data/worldbankpop.csv'] drop_dup_col = 'country' df = read_data(files, drop_dup_col).dropna() figures = [] year_list =...
true
true
f7fcdf63ae1110dd019ce632cb5036fbadd85949
10,585
py
Python
mosec/server.py
secsilm/mosec
89b7d8e6c763b22dcf49dad4ace3796e3ffccb0a
[ "Apache-2.0" ]
null
null
null
mosec/server.py
secsilm/mosec
89b7d8e6c763b22dcf49dad4ace3796e3ffccb0a
[ "Apache-2.0" ]
null
null
null
mosec/server.py
secsilm/mosec
89b7d8e6c763b22dcf49dad4ace3796e3ffccb0a
[ "Apache-2.0" ]
null
null
null
import logging import multiprocessing as mp import os import signal import subprocess import traceback from contextlib import ContextDecorator from multiprocessing.synchronize import Event from os.path import exists from pathlib import Path from shutil import rmtree from time import monotonic, sleep from typing import ...
35.166113
87
0.558904
import logging import multiprocessing as mp import os import signal import subprocess import traceback from contextlib import ContextDecorator from multiprocessing.synchronize import Event from os.path import exists from pathlib import Path from shutil import rmtree from time import monotonic, sleep from typing import ...
true
true
f7fcdf736be5df3949e0c92adefb6b4899fbc42d
17,866
py
Python
vyperlogix/crontab/scheduler.py
raychorn/chrome_gui
f1fade70b61af12ee43c55c075aa9cfd32caa962
[ "CC0-1.0" ]
1
2020-09-29T01:36:33.000Z
2020-09-29T01:36:33.000Z
vyperlogix/crontab/scheduler.py
raychorn/chrome_gui
f1fade70b61af12ee43c55c075aa9cfd32caa962
[ "CC0-1.0" ]
null
null
null
vyperlogix/crontab/scheduler.py
raychorn/chrome_gui
f1fade70b61af12ee43c55c075aa9cfd32caa962
[ "CC0-1.0" ]
null
null
null
#!/usr/bin/env python """ See also: http://code.activestate.com/recipes/577466-cron-like-triggers/ This module provides a class for cron-like scheduling systems, and exposes the function used to convert static cron expressions to Python sets. CronExpression objects are instantiated with a cron formatted string that r...
40.512472
215
0.585022
""" See also: http://code.activestate.com/recipes/577466-cron-like-triggers/ This module provides a class for cron-like scheduling systems, and exposes the function used to convert static cron expressions to Python sets. CronExpression objects are instantiated with a cron formatted string that represents the times w...
false
true
f7fce01e5b9264f55562fa8ffe6cb7e02ca3c449
44
py
Python
tests/dummy/__init__.py
fossabot/mfm
16fb084402ad6239a5b4fb913376392ed859f144
[ "MIT" ]
1
2018-08-11T19:04:40.000Z
2018-08-11T19:04:40.000Z
tests/dummy/__init__.py
fossabot/mfm
16fb084402ad6239a5b4fb913376392ed859f144
[ "MIT" ]
68
2016-05-22T19:56:59.000Z
2018-08-11T18:40:44.000Z
tests/dummy/__init__.py
fossabot/mfm
16fb084402ad6239a5b4fb913376392ed859f144
[ "MIT" ]
2
2016-12-28T17:33:22.000Z
2018-08-11T18:36:35.000Z
from .View import View __all__ = ['View']
8.8
22
0.659091
from .View import View __all__ = ['View']
true
true
f7fce06752c7e0b73a802944e6a8c60b5b50b9f6
2,178
py
Python
gunnery/task/forms.py
dholdaway/gunnery
87664986cd8bf1a17a9cbfb98fb1012cef9adaec
[ "Apache-2.0" ]
null
null
null
gunnery/task/forms.py
dholdaway/gunnery
87664986cd8bf1a17a9cbfb98fb1012cef9adaec
[ "Apache-2.0" ]
1
2021-06-10T23:55:50.000Z
2021-06-10T23:55:50.000Z
gunnery/task/forms.py
dholdaway/gunnery
87664986cd8bf1a17a9cbfb98fb1012cef9adaec
[ "Apache-2.0" ]
null
null
null
from django.forms import * from django.forms.widgets import Textarea, SelectMultiple, HiddenInput from django.forms.models import modelformset_factory, BaseModelFormSet from django.core.exceptions import ValidationError from django.db import models from crispy_forms.helper import FormHelper from crispy_forms.layo...
32.507463
87
0.652893
from django.forms import * from django.forms.widgets import Textarea, SelectMultiple, HiddenInput from django.forms.models import modelformset_factory, BaseModelFormSet from django.core.exceptions import ValidationError from django.db import models from crispy_forms.helper import FormHelper from crispy_forms.layo...
true
true
f7fce09ddc8c9c02aff75f9bc6492a310f90bd8c
81,526
py
Python
django/contrib/admin/options.py
sublime1809/django
9a5fe5b29fd431431a53da63ad8825d878ee5878
[ "BSD-3-Clause" ]
2
2015-01-21T15:45:07.000Z
2015-02-21T02:38:13.000Z
django/contrib/admin/options.py
HenriqueLR/django
d1ca70110f49f0be90206c8da516ac16aebc8c75
[ "BSD-3-Clause" ]
null
null
null
django/contrib/admin/options.py
HenriqueLR/django
d1ca70110f49f0be90206c8da516ac16aebc8c75
[ "BSD-3-Clause" ]
null
null
null
from collections import OrderedDict import copy import operator from functools import partial, reduce, update_wrapper import warnings from django import forms from django.conf import settings from django.contrib import messages from django.contrib.admin import widgets, helpers from django.contrib.admin import validati...
42.32918
119
0.615889
from collections import OrderedDict import copy import operator from functools import partial, reduce, update_wrapper import warnings from django import forms from django.conf import settings from django.contrib import messages from django.contrib.admin import widgets, helpers from django.contrib.admin import validati...
true
true
f7fce0c8d36f9c28a3bc3fff390f8112165c8f69
7,508
py
Python
tools/format/path_generator_test.py
ChrisCummins/format
d42b4dafcd7c4b187311473f1b446e0ca1988b12
[ "Apache-2.0" ]
null
null
null
tools/format/path_generator_test.py
ChrisCummins/format
d42b4dafcd7c4b187311473f1b446e0ca1988b12
[ "Apache-2.0" ]
12
2020-01-12T11:55:03.000Z
2020-01-17T01:00:23.000Z
tools/format/path_generator_test.py
ChrisCummins/format
d42b4dafcd7c4b187311473f1b446e0ca1988b12
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 Chris Cummins <chrisc.101@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.0 # # Unless required by applicable law ...
25.537415
76
0.681273
import os import pathlib from labm8.py import fs from labm8.py import test from tools.format import path_generator as path_generator_lib FLAGS = test.FLAGS @test.Fixture(scope="function") def path_generator(): return path_generator_lib.PathGenerator(".formatignore") def MakeFiles(relpaths): for p...
true
true
f7fce1ad405e292cbbfdc980a20a50c380185185
13,883
py
Python
airflow/providers/salesforce/hooks/salesforce.py
troywinter/airflow
ba66ba0d97941c55d9f00f66329a9d3c7ad673e7
[ "Apache-2.0" ]
3
2015-08-25T13:56:44.000Z
2020-03-21T10:26:58.000Z
airflow/providers/salesforce/hooks/salesforce.py
troywinter/airflow
ba66ba0d97941c55d9f00f66329a9d3c7ad673e7
[ "Apache-2.0" ]
37
2020-07-21T07:50:02.000Z
2022-03-29T22:31:28.000Z
airflow/providers/salesforce/hooks/salesforce.py
troywinter/airflow
ba66ba0d97941c55d9f00f66329a9d3c7ad673e7
[ "Apache-2.0" ]
4
2020-07-17T14:02:28.000Z
2022-02-23T04:29:58.000Z
# # 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...
42.32622
110
0.64064
import logging import time import pandas as pd from simple_salesforce import Salesforce from airflow.hooks.base_hook import BaseHook log = logging.getLogger(__name__) class SalesforceHook(BaseHook): def __init__(self, conn_id): super().__init__() self.conn_id = conn_id ...
true
true
f7fce2460b5ee2d246230f74c5f22cca15697c08
3,467
py
Python
st2reactor/st2reactor/sensor/base.py
kkkanil/st2
07cd195d7a6e177a37dd019e5c9ab8329259d0fa
[ "Apache-2.0" ]
null
null
null
st2reactor/st2reactor/sensor/base.py
kkkanil/st2
07cd195d7a6e177a37dd019e5c9ab8329259d0fa
[ "Apache-2.0" ]
15
2021-02-11T22:58:54.000Z
2021-08-06T18:03:47.000Z
st2reactor/st2reactor/sensor/base.py
kkkanil/st2
07cd195d7a6e177a37dd019e5c9ab8329259d0fa
[ "Apache-2.0" ]
1
2021-07-10T15:02:29.000Z
2021-07-10T15:02:29.000Z
# Copyright 2020 The StackStorm Authors. # Copyright 2019 Extreme Networks, Inc. # # 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 ...
24.415493
90
0.628786
from __future__ import absolute_import import abc import six from st2common.util import concurrency __all__ = [ 'Sensor', 'PollingSensor' ] @six.add_metaclass(abc.ABCMeta) class BaseSensor(object): def __init__(self, sensor_service, config=None): self._sensor_service = sensor_s...
true
true
f7fce3397fc4c51059e6c3820d6a3149533c5571
1,727
py
Python
load-events.py
Pivotal-Data-Engineering/gemfire-samples
141024d5505f1d8bcab15d5abb5bd8dbbf3944f3
[ "BSD-3-Clause" ]
1
2017-07-19T20:13:33.000Z
2017-07-19T20:13:33.000Z
load-events.py
Pivotal-Data-Engineering/gemfire-samples
141024d5505f1d8bcab15d5abb5bd8dbbf3944f3
[ "BSD-3-Clause" ]
null
null
null
load-events.py
Pivotal-Data-Engineering/gemfire-samples
141024d5505f1d8bcab15d5abb5bd8dbbf3944f3
[ "BSD-3-Clause" ]
null
null
null
import httplib import faker import json import os import random import time REST_API_HOST='localhost' REST_API_PORT=10183 REST_API_URL='/gemfire-api/v1/Event' EVENT_TYPE = 'io.pivotal.pde.sample.Event' count = 200 sleep = 1.0 headers = dict() headers['Content-Type'] = 'application/json' if __name__ == '__main__': ...
30.839286
139
0.604517
import httplib import faker import json import os import random import time REST_API_HOST='localhost' REST_API_PORT=10183 REST_API_URL='/gemfire-api/v1/Event' EVENT_TYPE = 'io.pivotal.pde.sample.Event' count = 200 sleep = 1.0 headers = dict() headers['Content-Type'] = 'application/json' if __name__ == '__main__': ...
false
true
f7fce37f8095709be46b3922bfc6eec9c08e922b
2,362
py
Python
sdc/sdc/filters.py
yandex-research/shifts
12c8ca805ff4d18bdc1300611c318b264d79fdec
[ "Apache-2.0" ]
156
2021-07-16T08:54:39.000Z
2022-03-24T11:49:36.000Z
sdc/sdc/filters.py
yandex-research/shifts
12c8ca805ff4d18bdc1300611c318b264d79fdec
[ "Apache-2.0" ]
18
2021-07-21T14:02:46.000Z
2022-02-26T04:07:12.000Z
sdc/sdc/filters.py
yandex-research/shifts
12c8ca805ff4d18bdc1300611c318b264d79fdec
[ "Apache-2.0" ]
41
2021-07-21T05:38:07.000Z
2022-01-13T15:25:51.000Z
""" ** Filtering Info ** To filter scenes by tags one should specify a filter function Scene tags dict has following structure: { 'day_time': one of {'kNight', 'kMorning', 'kAfternoon', 'kEvening'} 'season': one of {'kWinter', 'kSpring', 'kSummer', 'kAutumn'} 'track': one of { 'Moscow' , 'Skolkovo', ...
31.078947
76
0.685859
def filter_moscow_no_precipitation_data(scene_tags_dict): if (scene_tags_dict['track'] == 'Moscow' and scene_tags_dict['precipitation'] == 'kNoPrecipitation'): return True else: return False def filter_ood_development_data(scene_tags_dict): if (scene_tags_dict['track'] in ['S...
true
true
f7fce549598dd86125163ad1467449cd8372b5e0
13,112
py
Python
vega/algorithms/nas/esr_ea/esr_search.py
Lzc06/vega
852d2f57e21caed11473ddc96397124561eacf8a
[ "MIT" ]
12
2020-12-13T08:34:24.000Z
2022-03-20T15:17:17.000Z
vega/algorithms/nas/esr_ea/esr_search.py
Lzc06/vega
852d2f57e21caed11473ddc96397124561eacf8a
[ "MIT" ]
3
2021-03-31T20:15:40.000Z
2022-02-09T23:50:46.000Z
built-in/TensorFlow/Research/cv/image_classification/Darts_for_TensorFlow/automl/vega/algorithms/nas/esr_ea/esr_search.py
Huawei-Ascend/modelzoo
df51ed9c1d6dbde1deef63f2a037a369f8554406
[ "Apache-2.0" ]
2
2021-07-10T12:40:46.000Z
2021-12-17T07:55:15.000Z
# -*- coding:utf-8 -*- # Copyright (C) 2020. Huawei Technologies Co., Ltd. All rights reserved. # This program is free software; you can redistribute it and/or modify # it under the terms of the MIT License. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the ...
44.297297
115
0.624085
import csv import logging import os from bisect import bisect_right from random import random, sample import numpy as np import pandas as pd from vega.core.common.general import General from .conf import ESRConfig from vega.core.common import FileOps from vega.core.common.class_factory import ClassFactory, Cl...
true
true
f7fce6a167660fd64eb86c6b55209849d93a2a6b
7,526
py
Python
cmdmenu.py
arkocal/pycmdmenu
0cb3f55e90f9f64f50ab6ca784a5329439cca2c2
[ "MIT" ]
1
2021-04-27T19:36:16.000Z
2021-04-27T19:36:16.000Z
cmdmenu.py
arkocal/pycmdmenu
0cb3f55e90f9f64f50ab6ca784a5329439cca2c2
[ "MIT" ]
4
2018-10-04T11:28:05.000Z
2018-10-04T12:39:24.000Z
cmdmenu.py
arkocal/pycmdmenu
0cb3f55e90f9f64f50ab6ca784a5329439cca2c2
[ "MIT" ]
null
null
null
"""Automatically create command line menus with arg hiearchies.""" import argparse import copy import inspect import pkgutil from types import ModuleType FUNC_NAME_ARG = "_cmdmenu_func_name" def cmdmenu_function(param, description=None): """Decorator for marking a function to appear in cmdmenu. If it is used...
39.820106
80
0.657056
import argparse import copy import inspect import pkgutil from types import ModuleType FUNC_NAME_ARG = "_cmdmenu_func_name" def cmdmenu_function(param, description=None): def decorator(func): func.cmdmenu_help = param if description is not None: func.cmdmenu_description = description ...
true
true
f7fce7c5ac7c35de29f219370a9c2598b5a8f090
17,819
py
Python
scripts/data_processing/process_climis_unicef_ieconomics_data.py
mwdchang/delphi
c6177f2d614118883eaaa7f5300f3e46f10ddc7e
[ "Apache-2.0" ]
null
null
null
scripts/data_processing/process_climis_unicef_ieconomics_data.py
mwdchang/delphi
c6177f2d614118883eaaa7f5300f3e46f10ddc7e
[ "Apache-2.0" ]
null
null
null
scripts/data_processing/process_climis_unicef_ieconomics_data.py
mwdchang/delphi
c6177f2d614118883eaaa7f5300f3e46f10ddc7e
[ "Apache-2.0" ]
1
2019-07-18T19:13:13.000Z
2019-07-18T19:13:13.000Z
""" Script for cleaning data for 12 month evaluation. """ import os import re import sys import numpy as np import pandas as pd from pprint import pprint from glob import glob from typing import List, Dict from delphi.utils.shell import cd from delphi.paths import data_dir, south_sudan_data from delphi.utils.fp import...
35.496016
191
0.589483
import os import re import sys import numpy as np import pandas as pd from pprint import pprint from glob import glob from typing import List, Dict from delphi.utils.shell import cd from delphi.paths import data_dir, south_sudan_data from delphi.utils.fp import grouper from functools import partial from itertools impo...
true
true
f7fce80c40b6f8a65c0cd284f2acc0ef0b071d44
11,794
py
Python
gooddata-metadata-client/gooddata_metadata_client/model/json_api_metric_in_document.py
hkad98/gooddata-python-sdk
64942080ecb44c2d8e914e57f7a591daa6cca205
[ "MIT" ]
null
null
null
gooddata-metadata-client/gooddata_metadata_client/model/json_api_metric_in_document.py
hkad98/gooddata-python-sdk
64942080ecb44c2d8e914e57f7a591daa6cca205
[ "MIT" ]
null
null
null
gooddata-metadata-client/gooddata_metadata_client/model/json_api_metric_in_document.py
hkad98/gooddata-python-sdk
64942080ecb44c2d8e914e57f7a591daa6cca205
[ "MIT" ]
null
null
null
""" OpenAPI definition No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 The version of the OpenAPI document: v0 Contact: support@gooddata.com Generated by: https://openapi-generator.tech """ import re # noqa: F401 import sy...
42.577617
124
0.564185
import re import sys from gooddata_metadata_client.model_utils import ( ApiTypeError, ModelComposed, ModelNormal, ModelSimple, cached_property, change_keys_js_to_python, convert_js_args_to_python_args, date, datetime, file_type, none_type, validate_get_composed_i...
true
true
f7fce83c4594f2a8a90f733a733619e15b315e1a
4,367
py
Python
venv/Lib/site-packages/engineio/async_drivers/sanic.py
asanka9/Quession-Discussion-App-Socket.Io-NLP
95a49a8afa572dc3908a0bade45e424c3751f191
[ "Apache-2.0" ]
3
2021-09-26T17:30:31.000Z
2022-03-05T13:37:46.000Z
venv/Lib/site-packages/engineio/async_drivers/sanic.py
asanka9/Quession-Discussion-App-Socket.Io-NLP
95a49a8afa572dc3908a0bade45e424c3751f191
[ "Apache-2.0" ]
1
2020-11-29T20:27:13.000Z
2020-11-29T20:27:13.000Z
venv/Lib/site-packages/engineio/async_drivers/sanic.py
asanka9/Quession-Discussion-App-Socket.Io-NLP
95a49a8afa572dc3908a0bade45e424c3751f191
[ "Apache-2.0" ]
2
2020-11-28T19:41:07.000Z
2020-11-29T19:42:22.000Z
import sys from urllib.parse import urlsplit try: # pragma: no cover from sanic.response import HTTPResponse from sanic.websocket import WebSocketProtocol except ImportError: HTTPResponse = None WebSocketProtocol = None import six def create_route(app, engineio_server, engineio_endpoint): # pragma:...
30.117241
78
0.616899
import sys from urllib.parse import urlsplit try: from sanic.response import HTTPResponse from sanic.websocket import WebSocketProtocol except ImportError: HTTPResponse = None WebSocketProtocol = None import six def create_route(app, engineio_server, engineio_endpoint): app.add_route(engineio...
true
true
f7fce857c40b16858e8a511db03496ced1bbfdd7
5,678
py
Python
apps/utils/corsheaders/checks.py
Freen247/dj_blog
f7df1a7b101d41835a334b78cddf3570968799e4
[ "Apache-2.0" ]
51
2020-09-28T09:41:03.000Z
2022-03-19T08:25:19.000Z
apps/utils/corsheaders/checks.py
Freen247/dj_blog
f7df1a7b101d41835a334b78cddf3570968799e4
[ "Apache-2.0" ]
17
2020-09-24T10:26:40.000Z
2022-03-12T00:49:05.000Z
apps/utils/corsheaders/checks.py
Freen247/django_blogback
f7df1a7b101d41835a334b78cddf3570968799e4
[ "Apache-2.0" ]
11
2020-10-10T01:23:09.000Z
2022-02-08T17:06:09.000Z
import re from collections.abc import Sequence from numbers import Integral from urllib.parse import urlparse from django.conf import settings from django.core import checks from apps.utils.corsheaders.conf import conf re_type = type(re.compile("")) @checks.register def check_settings(app_configs, **kwargs): e...
33.4
97
0.525713
import re from collections.abc import Sequence from numbers import Integral from urllib.parse import urlparse from django.conf import settings from django.core import checks from apps.utils.corsheaders.conf import conf re_type = type(re.compile("")) @checks.register def check_settings(app_configs, **kwargs): e...
true
true
f7fce873014ea090979cfd86e57e34a48122a40d
3,546
py
Python
eth/vm/forks/frontier/headers.py
dbfreem/py-evm
02a1f6f38884b1f7a89640c2095ea5b0f20687c3
[ "MIT" ]
1,641
2017-11-24T04:24:22.000Z
2022-03-31T14:59:30.000Z
eth/vm/forks/frontier/headers.py
dbfreem/py-evm
02a1f6f38884b1f7a89640c2095ea5b0f20687c3
[ "MIT" ]
1,347
2017-11-23T10:37:36.000Z
2022-03-20T16:31:44.000Z
eth/vm/forks/frontier/headers.py
dbfreem/py-evm
02a1f6f38884b1f7a89640c2095ea5b0f20687c3
[ "MIT" ]
567
2017-11-22T18:03:27.000Z
2022-03-28T17:49:08.000Z
from typing import ( Any, TYPE_CHECKING, ) from eth.abc import BlockHeaderAPI from eth.validation import ( validate_gt, validate_header_params_for_configuration, ) from eth.constants import ( GENESIS_GAS_LIMIT, DIFFICULTY_ADJUSTMENT_DENOMINATOR, DIFFICULTY_MINIMUM, BOMB_EXPONENTIAL_PER...
31.660714
96
0.698534
from typing import ( Any, TYPE_CHECKING, ) from eth.abc import BlockHeaderAPI from eth.validation import ( validate_gt, validate_header_params_for_configuration, ) from eth.constants import ( GENESIS_GAS_LIMIT, DIFFICULTY_ADJUSTMENT_DENOMINATOR, DIFFICULTY_MINIMUM, BOMB_EXPONENTIAL_PER...
true
true
f7fce8751c7cf5519b1dcbeff315939f47ea406f
105
py
Python
setup.py
MarcelloPerathoner/sphinxcontrib-autojsdoc
fce55cbed369258bcf388a94fee5a35df6f1a0ac
[ "BSD-2-Clause" ]
21
2019-05-05T21:05:32.000Z
2022-02-03T14:45:01.000Z
setup.py
MarcelloPerathoner/sphinxcontrib-autojsdoc
fce55cbed369258bcf388a94fee5a35df6f1a0ac
[ "BSD-2-Clause" ]
12
2019-04-06T06:54:52.000Z
2021-11-30T22:23:56.000Z
setup.py
MarcelloPerathoner/sphinxcontrib-autojsdoc
fce55cbed369258bcf388a94fee5a35df6f1a0ac
[ "BSD-2-Clause" ]
15
2019-07-08T03:08:16.000Z
2022-01-05T13:27:20.000Z
#!/usr/bin/env python import setuptools setuptools.setup( setup_requires=['pbr'], pbr=True, )
10.5
27
0.666667
import setuptools setuptools.setup( setup_requires=['pbr'], pbr=True, )
true
true
f7fce897ee2f59d420de72670135bc610f8f54ac
5,095
py
Python
rally/common/db/schema.py
DeanHwd/rally
d284aa0746c54f1c375470e76dd206d19877a7fd
[ "Apache-2.0" ]
null
null
null
rally/common/db/schema.py
DeanHwd/rally
d284aa0746c54f1c375470e76dd206d19877a7fd
[ "Apache-2.0" ]
null
null
null
rally/common/db/schema.py
DeanHwd/rally
d284aa0746c54f1c375470e76dd206d19877a7fd
[ "Apache-2.0" ]
1
2015-02-07T09:44:47.000Z
2015-02-07T09:44:47.000Z
# 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 agreed to in...
33.300654
78
0.655937
import os import alembic import alembic.config import alembic.migration import alembic.script import sqlalchemy as sa import sqlalchemy.schema from rally.common.db import api from rally.common.db import models from rally import exceptions INITIAL_REVISION_UUID = "ca3626f62937" def _alembic_config(...
true
true
f7fce8c6002bacf99442a27ae532d11e4cf9a454
2,832
py
Python
adminmgr/media/code/A2/python/task/BD_2384_2390_2412.py
IamMayankThakur/test-bigdata
cef633eb394419b955bdce479699d0115d8f99c3
[ "Apache-2.0" ]
9
2019-11-08T02:05:27.000Z
2021-12-13T12:06:35.000Z
adminmgr/media/code/A2/python/task/BD_2384_2390_2412.py
IamMayankThakur/test-bigdata
cef633eb394419b955bdce479699d0115d8f99c3
[ "Apache-2.0" ]
6
2019-11-27T03:23:16.000Z
2021-06-10T19:15:13.000Z
adminmgr/media/code/A2/python/task/BD_2384_2390_2412.py
IamMayankThakur/test-bigdata
cef633eb394419b955bdce479699d0115d8f99c3
[ "Apache-2.0" ]
4
2019-11-26T17:04:27.000Z
2021-12-13T11:57:03.000Z
from __future__ import print_function from operator import add from pyspark.sql import SparkSession import sys import findspark findspark.init() def computeContribs(merged_tuple): batsman_list = merged_tuple[1][0] #list of batsman the bowler has bowled to current_rank = merged_tuple[1][1] #the bowlers cur...
41.647059
157
0.660664
from __future__ import print_function from operator import add from pyspark.sql import SparkSession import sys import findspark findspark.init() def computeContribs(merged_tuple): batsman_list = merged_tuple[1][0] current_rank = merged_tuple[1][1] batsman_num = len(batsman_list) for n in batsman_list:...
true
true
f7fce8f1ea54a5556123684709c0e2bea6bd5faa
5,717
py
Python
plaso/parsers/sqlite_plugins/firefox_cookies.py
cvandeplas/plaso
b625a2c267ed09505cfac84c9593d8c0922852b1
[ "Apache-2.0" ]
3
2016-03-11T02:47:08.000Z
2016-12-24T03:19:27.000Z
plaso/parsers/sqlite_plugins/firefox_cookies.py
cvandeplas/plaso
b625a2c267ed09505cfac84c9593d8c0922852b1
[ "Apache-2.0" ]
null
null
null
plaso/parsers/sqlite_plugins/firefox_cookies.py
cvandeplas/plaso
b625a2c267ed09505cfac84c9593d8c0922852b1
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- # # Copyright 2014 The Plaso Project Authors. # Please see the AUTHORS file for details on individual authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the L...
36.883871
80
0.687948
from plaso.events import time_events from plaso.lib import errors from plaso.lib import eventdata from plaso.lib import timelib from plaso.parsers import cookie_plugins from plaso.parsers import sqlite from plaso.parsers.cookie_plugins import interface as cookie_interface from plaso.parsers.sqlite_...
true
true
f7fcea3b57813b46d8d47059d275ed86aed8544b
7,922
py
Python
zubhub_backend/zubhub/projects/models.py
NdibeRaymond/zubhub
23907202af4f4f4f85a108ed15e811abb3d22407
[ "MIT" ]
1
2022-01-21T14:15:24.000Z
2022-01-21T14:15:24.000Z
zubhub_backend/zubhub/projects/models.py
NdibeRaymond/zubhub
23907202af4f4f4f85a108ed15e811abb3d22407
[ "MIT" ]
null
null
null
zubhub_backend/zubhub/projects/models.py
NdibeRaymond/zubhub
23907202af4f4f4f85a108ed15e811abb3d22407
[ "MIT" ]
null
null
null
import uuid from math import floor from treebeard.mp_tree import MP_Node from django.db import models from django.contrib.auth import get_user_model from django.utils.text import slugify from django.utils import timezone from django.contrib.postgres.search import SearchVectorField from django.contrib.postgres.indexes i...
35.684685
119
0.639485
import uuid from math import floor from treebeard.mp_tree import MP_Node from django.db import models from django.contrib.auth import get_user_model from django.utils.text import slugify from django.utils import timezone from django.contrib.postgres.search import SearchVectorField from django.contrib.postgres.indexes i...
true
true
f7fceb355ad6e06f7c2f6e6e56fe9c61ba1475bf
2,192
py
Python
train.py
rndtestnt/riskAnalysis
36601374b60efd3f7680adee84e9e54e2f2b52a2
[ "Apache-2.0" ]
null
null
null
train.py
rndtestnt/riskAnalysis
36601374b60efd3f7680adee84e9e54e2f2b52a2
[ "Apache-2.0" ]
null
null
null
train.py
rndtestnt/riskAnalysis
36601374b60efd3f7680adee84e9e54e2f2b52a2
[ "Apache-2.0" ]
null
null
null
import os import warnings import sys import pandas as pd import numpy as np from itertools import cycle import matplotlib.pyplot as plt from sklearn.metrics import mean_squared_error, mean_absolute_error, r2_score from sklearn.model_selection import train_test_split from sklearn.linear_model import ElasticNet from skl...
29.621622
77
0.697993
import os import warnings import sys import pandas as pd import numpy as np from itertools import cycle import matplotlib.pyplot as plt from sklearn.metrics import mean_squared_error, mean_absolute_error, r2_score from sklearn.model_selection import train_test_split from sklearn.linear_model import ElasticNet from skl...
true
true
f7fcec19a413a64c81802ce6524bb5662bb070fb
517
py
Python
hashcode/10052.py
noritersand/python-lab
9238d62cb2d8b574a8d3697ac7d8b51f1251bc4b
[ "Unlicense" ]
null
null
null
hashcode/10052.py
noritersand/python-lab
9238d62cb2d8b574a8d3697ac7d8b51f1251bc4b
[ "Unlicense" ]
null
null
null
hashcode/10052.py
noritersand/python-lab
9238d62cb2d8b574a8d3697ac7d8b51f1251bc4b
[ "Unlicense" ]
null
null
null
n=4 m=3 k = {} a=1 b=0 c=0 while c< m*n: for i in range(abs(m)): b=b+1 c=c+1 k[(a,b)] = c if c==m*n: break for i in range(abs(n-1)): a=a+1 c=c+1 k[(a,b)] = c if c==m*n: break for i in range(abs(m-1)): b=b-1 ...
13.972973
29
0.324952
n=4 m=3 k = {} a=1 b=0 c=0 while c< m*n: for i in range(abs(m)): b=b+1 c=c+1 k[(a,b)] = c if c==m*n: break for i in range(abs(n-1)): a=a+1 c=c+1 k[(a,b)] = c if c==m*n: break for i in range(abs(m-1)): b=b-1 ...
true
true
f7fceee9e379c3f537a25770001b3fbabff0277d
717,715
py
Python
hydrus/client/db/ClientDB.py
Asday/hydrus
a09ab839633661f446612a92b680bb8118a46b39
[ "WTFPL" ]
null
null
null
hydrus/client/db/ClientDB.py
Asday/hydrus
a09ab839633661f446612a92b680bb8118a46b39
[ "WTFPL" ]
null
null
null
hydrus/client/db/ClientDB.py
Asday/hydrus
a09ab839633661f446612a92b680bb8118a46b39
[ "WTFPL" ]
null
null
null
import collections import hashlib import itertools import os import random import re import sqlite3 import time import traceback import typing from qtpy import QtCore as QC from qtpy import QtWidgets as QW from hydrus.core import HydrusConstants as HC from hydrus.core import HydrusData from hydrus.core import Hyd...
48.517204
2,093
0.546328
import collections import hashlib import itertools import os import random import re import sqlite3 import time import traceback import typing from qtpy import QtCore as QC from qtpy import QtWidgets as QW from hydrus.core import HydrusConstants as HC from hydrus.core import HydrusData from hydrus.core import Hyd...
true
true
f7fcefa6fed7a7d207c29601ec2b5b1a4ec218e6
4,561
py
Python
crawler.py
sebastianorozco/webcrawler
c34630f27505bbf07d2fea41724b9b05889be9b0
[ "Apache-2.0" ]
null
null
null
crawler.py
sebastianorozco/webcrawler
c34630f27505bbf07d2fea41724b9b05889be9b0
[ "Apache-2.0" ]
null
null
null
crawler.py
sebastianorozco/webcrawler
c34630f27505bbf07d2fea41724b9b05889be9b0
[ "Apache-2.0" ]
null
null
null
""" crawler.py """ from urlparse import urljoin,urlparse from collections import deque import re import traceback from locale import getdefaultlocale import logging import time from bs4 import BeautifulSoup from database import Database from webPage import WebPage from threadPool import ThreadPool log = logging.ge...
33.785185
93
0.60513
""" crawler.py """ from urlparse import urljoin,urlparse from collections import deque import re import traceback from locale import getdefaultlocale import logging import time from bs4 import BeautifulSoup from database import Database from webPage import WebPage from threadPool import ThreadPool log = logging.ge...
false
true
f7fcefd3c4b14bba418ab004458a2203519d7bb4
1,086
py
Python
openerp/addons/l10n_fr_hr_payroll/__init__.py
ntiufalara/openerp7
903800da0644ec0dd9c1dcd34205541f84d45fe4
[ "MIT" ]
3
2016-01-29T14:39:49.000Z
2018-12-29T22:42:00.000Z
odoo/addons/l10n_fr_hr_payroll/__init__.py
tuanquanghpvn/odoo8-tutorial
52d25f1ca5f233c431cb9d3b24b79c3b4fb5127e
[ "MIT" ]
2
2016-03-23T14:29:41.000Z
2017-02-20T17:11:30.000Z
odoo/addons/l10n_fr_hr_payroll/__init__.py
tuanquanghpvn/odoo8-tutorial
52d25f1ca5f233c431cb9d3b24b79c3b4fb5127e
[ "MIT" ]
3
2020-10-08T14:42:10.000Z
2022-01-28T14:12:29.000Z
# -*- encoding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2011 OpenERP SA (<http://openerp.com>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the G...
43.44
78
0.624309
true
true
f7fcf216326d902fad809437d9c0215cd4b51837
146
py
Python
datasets/urls.py
gurupratap-matharu/vuln
e577684d72d4d06ad60705cf7faeefe9392ea7f1
[ "MIT" ]
null
null
null
datasets/urls.py
gurupratap-matharu/vuln
e577684d72d4d06ad60705cf7faeefe9392ea7f1
[ "MIT" ]
8
2021-03-31T20:22:18.000Z
2021-12-13T20:55:25.000Z
datasets/urls.py
gurupratap-matharu/vuln
e577684d72d4d06ad60705cf7faeefe9392ea7f1
[ "MIT" ]
1
2021-01-12T21:39:40.000Z
2021-01-12T21:39:40.000Z
from django.urls import path from datasets.views import DatasetListView urlpatterns = [ path('', DatasetListView.as_view(), name='home'), ]
18.25
53
0.732877
from django.urls import path from datasets.views import DatasetListView urlpatterns = [ path('', DatasetListView.as_view(), name='home'), ]
true
true
f7fcf2afea0cf43878f91a9140b2757c9eb451d2
414
py
Python
www_slcschools_org/wsgi.py
iamjdcollins/districtwebsite
89e2aea47ca3d221665bc23586a4374421be5800
[ "MIT" ]
null
null
null
www_slcschools_org/wsgi.py
iamjdcollins/districtwebsite
89e2aea47ca3d221665bc23586a4374421be5800
[ "MIT" ]
null
null
null
www_slcschools_org/wsgi.py
iamjdcollins/districtwebsite
89e2aea47ca3d221665bc23586a4374421be5800
[ "MIT" ]
null
null
null
""" WSGI config for www_slcschools_org project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/1.11/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("...
24.352941
78
0.797101
import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_SETTINGS_MODULE", "www_slcschools_org.settings") application = get_wsgi_application()
true
true
f7fcf2b5f855ae88428508dfb58bfdcf87cc078c
22,805
py
Python
sctriangulate/metrics.py
alexcwsmith/scTriangulate
ec014a4c575f4fd3270922ee9197493a6ec0846c
[ "MIT" ]
1
2021-10-18T21:44:23.000Z
2021-10-18T21:44:23.000Z
sctriangulate/metrics.py
alexcwsmith/scTriangulate
ec014a4c575f4fd3270922ee9197493a6ec0846c
[ "MIT" ]
null
null
null
sctriangulate/metrics.py
alexcwsmith/scTriangulate
ec014a4c575f4fd3270922ee9197493a6ec0846c
[ "MIT" ]
null
null
null
import scanpy as sc import pandas as pd import numpy as np import anndata as ad import matplotlib.pyplot as plt import seaborn as sns import sys import gseapy as gp import math import os def check_filter_single_cluster(adata,key): vc = adata.obs[key].value_counts() exclude_clusters= vc.loc[vc==1].index tru...
42.546642
208
0.665293
import scanpy as sc import pandas as pd import numpy as np import anndata as ad import matplotlib.pyplot as plt import seaborn as sns import sys import gseapy as gp import math import os def check_filter_single_cluster(adata,key): vc = adata.obs[key].value_counts() exclude_clusters= vc.loc[vc==1].index tru...
true
true
f7fcf2b65de1d32b0e36ec91680fa812b0d37d92
6,535
py
Python
scripts/jinja_helpers.py
jherico/OpenXR-Hpp
a582c75853737ee8269770a2732fef517ac1f9ea
[ "Apache-2.0" ]
null
null
null
scripts/jinja_helpers.py
jherico/OpenXR-Hpp
a582c75853737ee8269770a2732fef517ac1f9ea
[ "Apache-2.0" ]
null
null
null
scripts/jinja_helpers.py
jherico/OpenXR-Hpp
a582c75853737ee8269770a2732fef517ac1f9ea
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python3 -i # # Copyright (c) 2019 The Khronos Group Inc. # Copyright (c) 2019 Collabora, 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...
36.104972
135
0.669013
import os import re from pathlib import Path _ADDED_TO_PATH = False OPENXR = os.getenv("OPENXR_REPO") if not OPENXR: OPENXR = os.path.abspath(os.path.join(os.path.dirname(__file__), '..', '..', 'OpenXR-SDK-Source')) def _add_to_path(): global _ADDED_TO_PATH if not _ADDED_TO_PATH: ...
true
true
f7fcf341ee87b22e586a360dfca375e724590cb3
5,139
py
Python
static/data/functional_tests/random_guides.py
joshim5/CRISPR-Library-Designer
2def1e4351c82056587620f7520ec922761ac8f3
[ "BSD-3-Clause" ]
17
2017-05-24T18:57:56.000Z
2021-04-18T05:00:10.000Z
static/data/functional_tests/random_guides.py
joshim5/CRISPR-Library-Designer
2def1e4351c82056587620f7520ec922761ac8f3
[ "BSD-3-Clause" ]
10
2017-09-11T09:17:51.000Z
2022-03-11T23:18:50.000Z
static/data/functional_tests/random_guides.py
joshim5/CRISPR-Library-Designer
2def1e4351c82056587620f7520ec922761ac8f3
[ "BSD-3-Clause" ]
5
2017-07-28T23:59:51.000Z
2022-01-04T19:22:22.000Z
# Python packages import json import os.path from Queue import PriorityQueue import random import re import time import pickle import numpy as np start_time = time.time() # CLD code from parent directories import os import inspect currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))) ...
31.335366
153
0.678926
import json import os.path from Queue import PriorityQueue import random import re import time import pickle import numpy as np start_time = time.time() import os import inspect currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))) rootdir = os.path.dirname(os.path.dirname(os.path.d...
false
true
f7fcf5be5f4ea2467d0ae6c51612ad43b19030c2
82
py
Python
core/arxiv/submission/services/stream/__init__.py
NeolithEra/arxiv-submission-core
d4f20be62a882d2d5f3d1584eda69e7d90ca2c12
[ "MIT" ]
14
2019-05-26T22:52:17.000Z
2021-11-05T12:26:46.000Z
core/arxiv/submission/services/stream/__init__.py
NeolithEra/arxiv-submission-core
d4f20be62a882d2d5f3d1584eda69e7d90ca2c12
[ "MIT" ]
30
2018-01-31T19:16:08.000Z
2018-12-08T08:41:04.000Z
core/arxiv/submission/services/stream/__init__.py
NeolithEra/arxiv-submission-core
d4f20be62a882d2d5f3d1584eda69e7d90ca2c12
[ "MIT" ]
8
2019-01-10T22:01:39.000Z
2021-11-20T21:44:51.000Z
"""Emits events to the submission stream.""" from .stream import StreamPublisher
20.5
44
0.768293
from .stream import StreamPublisher
true
true
f7fcf5eed351ac2824c32556f398df8a9228f07d
66,833
py
Python
bcdi/postprocessing/facet_recognition.py
DSimonne/bcdi
5740a75576d7c3760ac72358acfb51321d51f82b
[ "CECILL-B" ]
1
2021-11-03T08:49:41.000Z
2021-11-03T08:49:41.000Z
bcdi/postprocessing/facet_recognition.py
DSimonne/bcdi
5740a75576d7c3760ac72358acfb51321d51f82b
[ "CECILL-B" ]
null
null
null
bcdi/postprocessing/facet_recognition.py
DSimonne/bcdi
5740a75576d7c3760ac72358acfb51321d51f82b
[ "CECILL-B" ]
null
null
null
# -*- coding: utf-8 -*- # BCDI: tools for pre(post)-processing Bragg coherent X-ray diffraction imaging data # (c) 07/2017-06/2019 : CNRS UMR 7344 IM2NP # (c) 07/2019-05/2021 : DESY PHOTON SCIENCE # authors: # Jerome Carnis, carnis_jerome@yahoo.fr """Functions related to facet recognition of nanocrys...
37.504489
88
0.581479
import sys from numbers import Real import numpy as np from matplotlib import patches from matplotlib import pyplot as plt from scipy import ndimage, stats from scipy.interpolate import RegularGridInterpolator, griddata from scipy.ndimage.measurements import center_of_mass from scipy.signal import convolve fro...
true
true
f7fcf6d6614c0a5eecfa0ac0d46e9ca33e2d8077
4,981
py
Python
tests/test_sorting.py
deepsingh9868/pygorithm
c4aaa6acf15f78630d1fe8866e491ece4fdafef1
[ "MIT" ]
2
2020-08-26T10:00:46.000Z
2020-08-27T19:47:57.000Z
tests/test_sorting.py
realChainLife/pygorithm
f72e666ee913836b95f09cced47bcc03ad68a05d
[ "MIT" ]
null
null
null
tests/test_sorting.py
realChainLife/pygorithm
f72e666ee913836b95f09cced47bcc03ad68a05d
[ "MIT" ]
null
null
null
import unittest import random from pygorithm.sorting import ( bubble_sort, insertion_sort, selection_sort, merge_sort, quick_sort, counting_sort, bucket_sort, shell_sort, heap_sort, brick_sort, tim_sort, cocktail_sort, gnome_sort ) class TestSor...
24.536946
77
0.636017
import unittest import random from pygorithm.sorting import ( bubble_sort, insertion_sort, selection_sort, merge_sort, quick_sort, counting_sort, bucket_sort, shell_sort, heap_sort, brick_sort, tim_sort, cocktail_sort, gnome_sort ) class TestSor...
true
true
f7fcf6f5099c3dc6ff35609546fe2c90c186de2a
6,318
py
Python
tests/regressiontests/generic_views/views.py
kix/django
5262a288df07daa050a0e17669c3f103f47a8640
[ "BSD-3-Clause" ]
3
2015-10-14T09:13:48.000Z
2021-01-01T06:31:25.000Z
tests/regressiontests/generic_views/views.py
kix/django
5262a288df07daa050a0e17669c3f103f47a8640
[ "BSD-3-Clause" ]
1
2016-02-19T00:22:18.000Z
2016-02-19T00:22:18.000Z
tests/regressiontests/generic_views/views.py
kix/django
5262a288df07daa050a0e17669c3f103f47a8640
[ "BSD-3-Clause" ]
1
2019-07-15T02:35:16.000Z
2019-07-15T02:35:16.000Z
from __future__ import absolute_import from django.contrib.auth.decorators import login_required from django.core.paginator import Paginator from django.core.urlresolvers import reverse from django.utils.decorators import method_decorator from django.views import generic from .forms import AuthorForm from .models imp...
25.893443
89
0.731719
from __future__ import absolute_import from django.contrib.auth.decorators import login_required from django.core.paginator import Paginator from django.core.urlresolvers import reverse from django.utils.decorators import method_decorator from django.views import generic from .forms import AuthorForm from .models imp...
true
true
f7fcf6f7e2eba96181cf6d743971d1ed2037837c
1,605
py
Python
regression/main.py
vinnamkim/examples
aa6b820964fd903a0b5795a7d40ffd332d83e6d7
[ "BSD-3-Clause" ]
20
2018-07-27T15:14:44.000Z
2022-03-10T06:44:46.000Z
regression/main.py
JingshuaiLiu/examples
f1838619141d7f2a2553f7282c642a6f51a4df48
[ "BSD-3-Clause" ]
1
2020-11-18T22:15:54.000Z
2020-11-18T22:15:54.000Z
regression/main.py
JingshuaiLiu/examples
f1838619141d7f2a2553f7282c642a6f51a4df48
[ "BSD-3-Clause" ]
19
2018-07-27T07:42:22.000Z
2021-05-12T01:36:10.000Z
#!/usr/bin/env python from __future__ import print_function from itertools import count import torch import torch.nn.functional as F POLY_DEGREE = 4 W_target = torch.randn(POLY_DEGREE, 1) * 5 b_target = torch.randn(1) * 5 def make_features(x): """Builds features i.e. a matrix with columns [x, x^2, x^3, x^4]."""...
23.26087
73
0.623053
from __future__ import print_function from itertools import count import torch import torch.nn.functional as F POLY_DEGREE = 4 W_target = torch.randn(POLY_DEGREE, 1) * 5 b_target = torch.randn(1) * 5 def make_features(x): x = x.unsqueeze(1) return torch.cat([x ** i for i in range(1, POLY_DEGREE+1)], 1) d...
true
true
f7fcf71f4c1ce16d87fdc9952fba51e30607b51d
6,221
py
Python
first_strike/controller_helpers.py
WoolleySheep/first-strike
15f93cccba3cfdb2c2b75524004a08bfef42235a
[ "MIT" ]
null
null
null
first_strike/controller_helpers.py
WoolleySheep/first-strike
15f93cccba3cfdb2c2b75524004a08bfef42235a
[ "MIT" ]
null
null
null
first_strike/controller_helpers.py
WoolleySheep/first-strike
15f93cccba3cfdb2c2b75524004a08bfef42235a
[ "MIT" ]
null
null
null
""" Collection of functions that are useful in the construction of both rocket and turret controllers. """ import math from dataclasses import dataclass from typing import Optional from helpers import Helpers from history import History from math_helpers import normalise_angle from parameters import ObstacleParameter...
34.949438
123
0.678669
import math from dataclasses import dataclass from typing import Optional from helpers import Helpers from history import History from math_helpers import normalise_angle from parameters import ObstacleParameters, Parameters from physics import Physics @dataclass class ControllerHelpers: parameters: Parameters ...
true
true
f7fcf7559948b6752dd0ee377be44bd42c092522
351
py
Python
forest_lite/server/lib/palette.py
uk-gov-mirror/MetOffice.forest-lite
9406b53f7e6a9651eb675e0ac2e5945421b25557
[ "BSD-3-Clause" ]
6
2020-08-05T16:12:57.000Z
2022-01-06T01:34:19.000Z
forest_lite/server/lib/palette.py
uk-gov-mirror/MetOffice.forest-lite
9406b53f7e6a9651eb675e0ac2e5945421b25557
[ "BSD-3-Clause" ]
49
2020-08-14T13:58:32.000Z
2021-06-29T11:42:32.000Z
forest_lite/server/lib/palette.py
uk-gov-mirror/MetOffice.forest-lite
9406b53f7e6a9651eb675e0ac2e5945421b25557
[ "BSD-3-Clause" ]
2
2020-12-03T09:24:13.000Z
2021-04-11T06:10:36.000Z
import bokeh.palettes def all_palettes(): """List of palette definitions""" for name in bokeh.palettes.all_palettes: for number in bokeh.palettes.all_palettes[name]: yield { "name": name, "number": number, "palette": bokeh.palettes.all_palett...
27
68
0.566952
import bokeh.palettes def all_palettes(): for name in bokeh.palettes.all_palettes: for number in bokeh.palettes.all_palettes[name]: yield { "name": name, "number": number, "palette": bokeh.palettes.all_palettes[name][number] }
true
true
f7fcf941f3cd4af62f3f9eb6cc7c272feecf370e
841
py
Python
salt/runners/http.py
dr4Ke/salt
8ffa4903c9ed10c81e1a6c7b967dc9532f320c0b
[ "Apache-2.0" ]
1
2015-08-20T21:55:17.000Z
2015-08-20T21:55:17.000Z
salt/runners/http.py
dr4Ke/salt
8ffa4903c9ed10c81e1a6c7b967dc9532f320c0b
[ "Apache-2.0" ]
null
null
null
salt/runners/http.py
dr4Ke/salt
8ffa4903c9ed10c81e1a6c7b967dc9532f320c0b
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- ''' Module for making various web calls. Primarily designed for webhooks and the like, but also useful for basic http testing. ''' # Import salt libs import salt.output import salt.utils.http def query(url, output=True, **kwargs): ''' Query a resource, and decode the return data ...
24.735294
76
0.631391
import salt.output import salt.utils.http def query(url, output=True, **kwargs): if 'node' not in kwargs: kwargs['node'] = 'master' ret = salt.utils.http.query(url=url, opts=__opts__, **kwargs) if output: salt.output.display_output(ret, '', __opts__) return ret
true
true
f7fcf96d3c14550d50ca53e82769bf24822182de
2,034
py
Python
src/z3c/autoinclude/dependency.py
datakurre/z3c.autoinclude
5e42815357d97d2704bff61f3eb7ed2ddc891907
[ "ZPL-2.1" ]
null
null
null
src/z3c/autoinclude/dependency.py
datakurre/z3c.autoinclude
5e42815357d97d2704bff61f3eb7ed2ddc891907
[ "ZPL-2.1" ]
null
null
null
src/z3c/autoinclude/dependency.py
datakurre/z3c.autoinclude
5e42815357d97d2704bff61f3eb7ed2ddc891907
[ "ZPL-2.1" ]
null
null
null
import os import logging from zope.dottedname.resolve import resolve from pkg_resources import resource_exists from pkg_resources import get_provider from pkg_resources import get_distribution from z3c.autoinclude.utils import DistributionManager from z3c.autoinclude.utils import ZCMLInfo class DependencyFinder(Distri...
41.510204
83
0.67355
import os import logging from zope.dottedname.resolve import resolve from pkg_resources import resource_exists from pkg_resources import get_provider from pkg_resources import get_distribution from z3c.autoinclude.utils import DistributionManager from z3c.autoinclude.utils import ZCMLInfo class DependencyFinder(Distri...
true
true
f7fcf99f3451a0205655041b775aba1dff36b6fe
65,510
py
Python
discord/state.py
rldnyt/discord.pyc
e9d190b79ce6df798f144d1abea19f863e3fdbb9
[ "MIT" ]
23
2021-08-28T10:14:19.000Z
2021-12-24T15:10:58.000Z
discord/state.py
Sengolda/discord.py
5cd31dd6c2fe1a7b5d9538ff949fc371e92ec26b
[ "MIT" ]
2
2021-08-31T08:16:17.000Z
2021-08-31T15:21:40.000Z
discord/state.py
Sengolda/discord.py
5cd31dd6c2fe1a7b5d9538ff949fc371e92ec26b
[ "MIT" ]
3
2021-08-31T07:37:40.000Z
2021-09-14T11:59:47.000Z
""" The MIT License (MIT) Copyright (c) 2015-present Rapptz Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merg...
36.844769
118
0.586002
from __future__ import annotations import asyncio from collections import deque, OrderedDict import copy import datetime import itertools import logging from typing import ( Dict, Optional, TYPE_CHECKING, Union, Callable, Any, List, TypeVar, Coroutine, Sequence, Tuple, ...
true
true
f7fcfa53832ebec3a80de6aa8f5f22eb81c7f930
4,802
py
Python
AppDB/test/unit/test_cassandra_backup.py
Honcharov12/appscale
be1cf90fcd24f1a5a88848f7eb73331b6e4e66d9
[ "Apache-2.0" ]
null
null
null
AppDB/test/unit/test_cassandra_backup.py
Honcharov12/appscale
be1cf90fcd24f1a5a88848f7eb73331b6e4e66d9
[ "Apache-2.0" ]
null
null
null
AppDB/test/unit/test_cassandra_backup.py
Honcharov12/appscale
be1cf90fcd24f1a5a88848f7eb73331b6e4e66d9
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import re import subprocess import sys import time import unittest from flexmock import flexmock from appscale.common import appscale_info from appscale.common import appscale_utils from appscale.common.unpackaged import INFRASTRUCTURE_MANAGER_DIR from appscale.datastore.backup import backup_exc...
38.725806
79
0.708247
import re import subprocess import sys import time import unittest from flexmock import flexmock from appscale.common import appscale_info from appscale.common import appscale_utils from appscale.common.unpackaged import INFRASTRUCTURE_MANAGER_DIR from appscale.datastore.backup import backup_exceptions from appscale...
true
true
f7fcfaa7231e0891f3c44841a657fb8765e8b0e6
24,355
py
Python
tokenio/proto/security_pb2.py
overcat/token-io
f1b14fef9fd64989b9c9e5c076272f72253b39ed
[ "MIT" ]
null
null
null
tokenio/proto/security_pb2.py
overcat/token-io
f1b14fef9fd64989b9c9e5c076272f72253b39ed
[ "MIT" ]
2
2019-02-26T08:15:50.000Z
2019-08-06T12:58:21.000Z
tokenio/proto/security_pb2.py
overcat/token-io
f1b14fef9fd64989b9c9e5c076272f72253b39ed
[ "MIT" ]
1
2019-08-05T12:36:22.000Z
2019-08-05T12:36:22.000Z
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: security.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _refl...
42.209705
2,233
0.746377
import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database _sym_db =...
true
true
f7fcfbcd61db1c5d878dc58959a5ca91df076e2e
5,327
py
Python
docs/source/conf.py
pierfra-ro/allesfitter
a6a885aaeb3253fec0d924ef3b45e8b7c473b181
[ "MIT" ]
null
null
null
docs/source/conf.py
pierfra-ro/allesfitter
a6a885aaeb3253fec0d924ef3b45e8b7c473b181
[ "MIT" ]
null
null
null
docs/source/conf.py
pierfra-ro/allesfitter
a6a885aaeb3253fec0d924ef3b45e8b7c473b181
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # # Configuration file for the Sphinx documentation builder. # # This file does only contain a selection of the most common options. For a # full list see the documentation: # http://www.sphinx-doc.org/en/master/config # -- Path setup ------------------------------------------------------------...
29.926966
79
0.650648
project = 'allesfitter' copyright = '2019, Maximilian N. Guenther, Tansu Daylan' author = 'Maximilian N. Guenther, Tansu Daylan' version = '1.1.2' release = '1.1.2' extensions = [ 'sphinx.ext.autodoc', ] templates_path = ['_templates'] source_suffix = '.rst' master_doc = ...
true
true
f7fcfcc1fae130bab9a576a40d64638e126925d4
16,547
py
Python
eth/db/chain.py
mneedham91/py-evm
512b6809ce9c33ebed088702e6e22128bf6183af
[ "MIT" ]
null
null
null
eth/db/chain.py
mneedham91/py-evm
512b6809ce9c33ebed088702e6e22128bf6183af
[ "MIT" ]
null
null
null
eth/db/chain.py
mneedham91/py-evm
512b6809ce9c33ebed088702e6e22128bf6183af
[ "MIT" ]
null
null
null
import functools import itertools from abc import ( abstractmethod ) from typing import ( Dict, Iterable, List, Tuple, Type, TYPE_CHECKING, ) import rlp from trie import ( HexaryTrie, ) from eth_typing import ( BlockNumber, Hash32 ) from eth_utils import ( to_list, t...
34.983087
100
0.642533
import functools import itertools from abc import ( abstractmethod ) from typing import ( Dict, Iterable, List, Tuple, Type, TYPE_CHECKING, ) import rlp from trie import ( HexaryTrie, ) from eth_typing import ( BlockNumber, Hash32 ) from eth_utils import ( to_list, t...
true
true
f7fcfe5e24cdaa982f988067061dd23deefbc33b
3,092
py
Python
tests/test_tutorial/test_query_params_str_validations/test_tutorial012.py
jfunez/fastapi
7372f6ba11abb515a7f11814dba52a1d1c0925f0
[ "MIT" ]
2
2020-04-09T07:11:28.000Z
2020-12-12T14:04:35.000Z
tests/test_tutorial/test_query_params_str_validations/test_tutorial012.py
jfunez/fastapi
7372f6ba11abb515a7f11814dba52a1d1c0925f0
[ "MIT" ]
1
2021-03-27T18:37:32.000Z
2021-05-25T15:08:24.000Z
tests/test_tutorial/test_query_params_str_validations/test_tutorial012.py
jfunez/fastapi
7372f6ba11abb515a7f11814dba52a1d1c0925f0
[ "MIT" ]
1
2021-02-03T00:43:04.000Z
2021-02-03T00:43:04.000Z
from fastapi.testclient import TestClient from query_params_str_validations.tutorial012 import app client = TestClient(app) openapi_schema = { "openapi": "3.0.2", "info": {"title": "FastAPI", "version": "0.1.0"}, "paths": { "/items/": { "get": { "responses": { ...
31.876289
86
0.362225
from fastapi.testclient import TestClient from query_params_str_validations.tutorial012 import app client = TestClient(app) openapi_schema = { "openapi": "3.0.2", "info": {"title": "FastAPI", "version": "0.1.0"}, "paths": { "/items/": { "get": { "responses": { ...
true
true
f7fcff5ac53a3ca1369e4f24a20c47901f44dd52
2,473
py
Python
homework/Testing with Examples (Data Format)/impl-name05.py
rvprasad/software-testing-course
3803851dcf9f7bbd0f0b89fca6c9c5e3a48f22e0
[ "CC-BY-4.0" ]
11
2018-02-08T05:23:28.000Z
2021-05-24T13:23:56.000Z
homework/Testing with Examples (Data Format)/impl-name05.py
rvprasad/software-testing-course
3803851dcf9f7bbd0f0b89fca6c9c5e3a48f22e0
[ "CC-BY-4.0" ]
null
null
null
homework/Testing with Examples (Data Format)/impl-name05.py
rvprasad/software-testing-course
3803851dcf9f7bbd0f0b89fca6c9c5e3a48f22e0
[ "CC-BY-4.0" ]
2
2020-09-15T08:51:22.000Z
2021-01-26T12:07:18.000Z
import re class PhysicalInfo(object): def set_date(self, date): if not isinstance(date, str): raise ValueError("date should be a string") t = date.split("-") if len(t) != 3: raise ValueError("date should be in MM-DD-YYYY format") if re.search(r'[^0-9\-...
36.910448
82
0.545896
import re class PhysicalInfo(object): def set_date(self, date): if not isinstance(date, str): raise ValueError("date should be a string") t = date.split("-") if len(t) != 3: raise ValueError("date should be in MM-DD-YYYY format") if re.search(r'[^0-9\-...
true
true
f7fd00376c4dd032a2ad19860a436906fd08f432
3,804
py
Python
frcnn/viewer.py
skmatz/frcnn
eae9d42f964a5883f72dc294984c019b3c75e837
[ "MIT" ]
null
null
null
frcnn/viewer.py
skmatz/frcnn
eae9d42f964a5883f72dc294984c019b3c75e837
[ "MIT" ]
null
null
null
frcnn/viewer.py
skmatz/frcnn
eae9d42f964a5883f72dc294984c019b3c75e837
[ "MIT" ]
null
null
null
"""Module for (demo) viewer.""" import os from dataclasses import dataclass from glob import glob from logging import getLogger from os.path import basename, join from typing import List, Optional, Tuple import cv2 import numpy as np import seaborn as sns import torch import torch.cuda import torchvision from hydra.u...
28.177778
120
0.610147
import os from dataclasses import dataclass from glob import glob from logging import getLogger from os.path import basename, join from typing import List, Optional, Tuple import cv2 import numpy as np import seaborn as sns import torch import torch.cuda import torchvision from hydra.utils import to_absolute_path fr...
true
true
f7fd02249303ea1ba2fc488eea425a12ce8bf85a
1,195
py
Python
src/GameTools/Tools/Messaging.py
spidertyler2005/GameTools
f64a8ec0ebb4a357e04b90317136853d831d3553
[ "MIT" ]
1
2021-06-07T18:33:09.000Z
2021-06-07T18:33:09.000Z
src/GameTools/Tools/Messaging.py
spidertyler2005/GameTools
f64a8ec0ebb4a357e04b90317136853d831d3553
[ "MIT" ]
null
null
null
src/GameTools/Tools/Messaging.py
spidertyler2005/GameTools
f64a8ec0ebb4a357e04b90317136853d831d3553
[ "MIT" ]
null
null
null
global messageDict messageDict={} def send_Message(messageName, index=None, *args,**kwargs): ''' tells functions that are listening to this message to run with whatever args are specified You can also specify and index if there are multiple function in that list. usage: send_Message("Default...
29.146341
95
0.700418
global messageDict messageDict={} def send_Message(messageName, index=None, *args,**kwargs): global messageDict if index==None: for func in messageDict[messageName]: func(*args,**kwargs) else: messageDict[messageName][index](*args) def recv_Message(messageName): global messageDict def inn...
true
true
f7fd02406db0cdbed19282f63a503c5fbd99b5d4
5,413
py
Python
tests/data/packages/fetchai/protocols/t_protocol_no_ct/dialogues.py
valory-xyz/agents-aea
8f38efa96041b0156ed1ae328178e395dbabf2fc
[ "Apache-2.0" ]
null
null
null
tests/data/packages/fetchai/protocols/t_protocol_no_ct/dialogues.py
valory-xyz/agents-aea
8f38efa96041b0156ed1ae328178e395dbabf2fc
[ "Apache-2.0" ]
null
null
null
tests/data/packages/fetchai/protocols/t_protocol_no_ct/dialogues.py
valory-xyz/agents-aea
8f38efa96041b0156ed1ae328178e395dbabf2fc
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # ------------------------------------------------------------------------------ # # Copyright 2022 fetchai # # 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 # #...
36.328859
91
0.663403
from abc import ABC from typing import Callable, Dict, FrozenSet, Type, cast from aea.common import Address from aea.protocols.base import Message from aea.protocols.dialogue.base import Dialogue, DialogueLabel, Dialogues from tests.data.packages.fetchai.protocols.t_protocol_no_ct.message import (...
true
true
f7fd026958d367e8ee9648bd479d624f5a249641
22,426
py
Python
wang/trainModel.py
zhangqx/movie_recommender
93eddb89f7ac2a8358bbe5c91b26e7e2b4184c38
[ "MIT" ]
1
2019-12-03T16:20:01.000Z
2019-12-03T16:20:01.000Z
wang/trainModel.py
zhangqx/movie_recommender
93eddb89f7ac2a8358bbe5c91b26e7e2b4184c38
[ "MIT" ]
null
null
null
wang/trainModel.py
zhangqx/movie_recommender
93eddb89f7ac2a8358bbe5c91b26e7e2b4184c38
[ "MIT" ]
3
2019-06-24T15:59:42.000Z
2019-12-03T16:20:02.000Z
import os # # # % matplotlib inline # % config InlineBackend.figure_format = 'retina' import matplotlib matplotlib.use('TkAgg') import matplotlib.pyplot as plt import time import datetime import numpy as np from sklearn.model_selection import train_test_split import pandas as pd import pickle import tensorflow as tf #...
40.189964
190
0.65919
import os import matplotlib matplotlib.use('TkAgg') import matplotlib.pyplot as plt import time import datetime import numpy as np from sklearn.model_selection import train_test_split import pandas as pd import pickle import tensorflow as tf title_count, title_set, genres2int, features, targets_values, rat...
true
true
f7fd031b3050ebbc13593e25c2968f68853a9554
6,401
py
Python
ogs6py/classes/processes.py
bilke/ogs6py
b6d9364bf7275f65b324a466e38a2bbef9ca076b
[ "BSD-3-Clause" ]
null
null
null
ogs6py/classes/processes.py
bilke/ogs6py
b6d9364bf7275f65b324a466e38a2bbef9ca076b
[ "BSD-3-Clause" ]
null
null
null
ogs6py/classes/processes.py
bilke/ogs6py
b6d9364bf7275f65b324a466e38a2bbef9ca076b
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ Copyright (c) 2012-2021, OpenGeoSys Community (http://www.opengeosys.org) Distributed under a Modified BSD License. See accompanying file LICENSE or http://www.opengeosys.org/project/license """ # pylint: disable=C0103, R0902, R0914, R0913 from ogs6py...
32.994845
94
0.471333
from ogs6py.classes import build_tree class Processes(build_tree.BuildTree): def __init__(self): self.tree = { 'processes': { 'tag': 'processes', 'text': '', 'attr': {}, 'children': {} } } self.tree['p...
true
true
f7fd0323381cfecd8177a419dced559b61c4db17
4,975
py
Python
acme/agents/jax/dqn/agent.py
Tsaousis/acme
14278693bcc5fef0839ac60792d452d3d80acfd7
[ "Apache-2.0" ]
2,650
2020-06-01T16:31:25.000Z
2022-03-31T07:32:41.000Z
acme/agents/jax/dqn/agent.py
Tsaousis/acme
14278693bcc5fef0839ac60792d452d3d80acfd7
[ "Apache-2.0" ]
199
2020-06-02T01:09:09.000Z
2022-03-31T17:11:20.000Z
acme/agents/jax/dqn/agent.py
Tsaousis/acme
14278693bcc5fef0839ac60792d452d3d80acfd7
[ "Apache-2.0" ]
344
2020-06-01T16:45:21.000Z
2022-03-30T11:15:09.000Z
# python3 # Copyright 2018 DeepMind Technologies Limited. 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 re...
34.310345
80
0.721005
from acme import specs from acme.agents import agent from acme.agents import replay from acme.agents.jax import actor_core as actor_core_lib from acme.agents.jax import actors from acme.agents.jax.dqn import config as dqn_config from acme.agents.jax.dqn import learning_lib from acme.agents.jax.dqn impor...
true
true
f7fd039edd681255dcaaa15a917813ccf078b23f
1,830
py
Python
common/tests.py
jyothishankit/flask-example
15739bcf9aa7ac469184927becb17fe98c962307
[ "MIT" ]
68
2015-02-27T17:22:20.000Z
2021-02-07T15:06:10.000Z
common/tests.py
jyothishankit/flask-example
15739bcf9aa7ac469184927becb17fe98c962307
[ "MIT" ]
3
2015-04-12T02:11:34.000Z
2018-01-08T04:57:22.000Z
common/tests.py
jyothishankit/flask-example
15739bcf9aa7ac469184927becb17fe98c962307
[ "MIT" ]
53
2015-04-03T10:39:32.000Z
2021-11-09T17:27:07.000Z
# -*- coding: utf-8 -*- from flask import template_rendered, url_for from contextlib import contextmanager import unittest from application import create_app class BaseTestCase(unittest.TestCase): def __call__(self, result=None): self._pre_setup() super(BaseTestCase, self).__call__(result) ...
26.521739
70
0.609836
from flask import template_rendered, url_for from contextlib import contextmanager import unittest from application import create_app class BaseTestCase(unittest.TestCase): def __call__(self, result=None): self._pre_setup() super(BaseTestCase, self).__call__(result) self._post_teardown...
true
true
f7fd043933dd2ed0f75a42886a9a752fe1af9843
13,278
py
Python
airflow/gcp/operators/kubernetes_engine.py
InigoSJ/airflow
8b97a387dc30d8c88390d500ec99333798c20f1c
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
null
null
null
airflow/gcp/operators/kubernetes_engine.py
InigoSJ/airflow
8b97a387dc30d8c88390d500ec99333798c20f1c
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
1
2017-05-11T22:57:49.000Z
2017-05-11T22:57:49.000Z
airflow/gcp/operators/kubernetes_engine.py
InigoSJ/airflow
8b97a387dc30d8c88390d500ec99333798c20f1c
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
1
2020-11-16T09:03:58.000Z
2020-11-16T09:03:58.000Z
# -*- coding: utf-8 -*- # # 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 #...
40.855385
150
0.646483
import os import subprocess import tempfile from typing import Union, Dict, Optional from google.auth.environment_vars import CREDENTIALS from google.cloud.container_v1.types import Cluster from airflow import AirflowException from airflow.gcp.hooks.kubernetes_engine import GKEClusterHook from air...
true
true
f7fd05639b438cdae4d7aae8cad7a4e0733f299b
14,563
py
Python
dnn_utils.py
santamm/DeepNet
fd05804200eb1bd62fb3a80a793b22794e4ec7d2
[ "MIT" ]
null
null
null
dnn_utils.py
santamm/DeepNet
fd05804200eb1bd62fb3a80a793b22794e4ec7d2
[ "MIT" ]
null
null
null
dnn_utils.py
santamm/DeepNet
fd05804200eb1bd62fb3a80a793b22794e4ec7d2
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import h5py def sigmoid(Z): """ Implements the sigmoid activation in numpy Arguments: Z -- numpy array of any shape Returns: A -- output of sigmoid(z), same shape as Z cache -- returns Z as well, useful during backpropagation """ ...
32.947964
143
0.628373
import numpy as np import matplotlib.pyplot as plt import h5py def sigmoid(Z): A = 1/(1+np.exp(-Z)) cache = Z return A, cache def relu(Z): A = np.maximum(0,Z) assert(A.shape == Z.shape) cache = Z return A, cache def relu_backward(dA, cache): Z = cache dZ = np.array(dA, cop...
true
true
f7fd059a13914c97c85675154d9a8ef45a5e7a71
807
py
Python
analyse.py
lrobidou/kbf
443da37c9c9c450292bb43bd149c2a32fde1acf0
[ "BSD-2-Clause" ]
null
null
null
analyse.py
lrobidou/kbf
443da37c9c9c450292bb43bd149c2a32fde1acf0
[ "BSD-2-Clause" ]
null
null
null
analyse.py
lrobidou/kbf
443da37c9c9c450292bb43bd149c2a32fde1acf0
[ "BSD-2-Clause" ]
null
null
null
# don't mind me, I'm a quick and dirty python script # I extract false positive rate from the output files of kbf def lire(filemane): TP, TN, FP, FN = 0, 0, 0, 0 with open(filemane, "r") as fichier: for ligne in fichier: cols = ligne.split() if cols[1] == "0": i...
25.21875
60
0.469641
def lire(filemane): TP, TN, FP, FN = 0, 0, 0, 0 with open(filemane, "r") as fichier: for ligne in fichier: cols = ligne.split() if cols[1] == "0": if cols[2] == "0": TN += 1 else: FN += 1 else...
true
true
f7fd05e739992e4c1f58efd11d8a7dfa9ef68ff8
65,714
py
Python
env/lib/python3.8/site-packages/attr/_make.py
avdhari/enigma
b7e965a91ca5f0e929c4c719d695f15ccb8b5a2c
[ "MIT" ]
445
2019-01-26T13:50:26.000Z
2022-03-18T05:17:38.000Z
env/lib/python3.8/site-packages/attr/_make.py
avdhari/enigma
b7e965a91ca5f0e929c4c719d695f15ccb8b5a2c
[ "MIT" ]
242
2019-01-29T15:48:27.000Z
2022-03-31T22:09:21.000Z
env/lib/python3.8/site-packages/attr/_make.py
avdhari/enigma
b7e965a91ca5f0e929c4c719d695f15ccb8b5a2c
[ "MIT" ]
31
2019-03-10T09:51:27.000Z
2022-02-14T23:11:12.000Z
from __future__ import absolute_import, division, print_function import copy import hashlib import linecache import sys import threading import warnings from operator import itemgetter from . import _config from ._compat import ( PY2, isclass, iteritems, metadata_proxy, ordered_dict, set_clos...
32.291892
95
0.576772
from __future__ import absolute_import, division, print_function import copy import hashlib import linecache import sys import threading import warnings from operator import itemgetter from . import _config from ._compat import ( PY2, isclass, iteritems, metadata_proxy, ordered_dict, set_clos...
true
true
f7fd0651dececa1cf9a855ddc9e39003857e7617
1,943
py
Python
Chapter12/object_detection.py
poshan0126/TensorFlow-Machine-Learning-Projects
5b8d7988b86e39ffdd8babec2b8e3c791b5e853e
[ "MIT" ]
74
2019-01-19T23:37:26.000Z
2022-03-30T12:59:34.000Z
Chapter12/object_detection.py
poshan0126/TensorFlow-Machine-Learning-Projects
5b8d7988b86e39ffdd8babec2b8e3c791b5e853e
[ "MIT" ]
46
2019-01-23T05:02:43.000Z
2022-03-12T01:04:37.000Z
Chapter12/object_detection.py
poshan0126/TensorFlow-Machine-Learning-Projects
5b8d7988b86e39ffdd8babec2b8e3c791b5e853e
[ "MIT" ]
54
2018-08-07T00:56:48.000Z
2022-03-22T18:06:37.000Z
# To allow Python to find Spark driver import findspark findspark.init('/home/ubuntu/spark-2.4.0-bin-hadoop2.7') import os SUBMIT_ARGS = "--packages databricks:spark-deep-learning:1.3.0-spark2.4-s_2.11 pyspark-shell" os.environ["PYSPARK_SUBMIT_ARGS"] = SUBMIT_ARGS from pyspark.sql import SparkSession spark = SparkS...
35.327273
93
0.750901
import findspark findspark.init('/home/ubuntu/spark-2.4.0-bin-hadoop2.7') import os SUBMIT_ARGS = "--packages databricks:spark-deep-learning:1.3.0-spark2.4-s_2.11 pyspark-shell" os.environ["PYSPARK_SUBMIT_ARGS"] = SUBMIT_ARGS from pyspark.sql import SparkSession spark = SparkSession.builder \ .appName("Image...
true
true
f7fd0758dd89f675c47e152e462219a5f97f6d03
310
py
Python
setup.py
ShuzhiLiu/MaskRCNN
02602c20f17d583621e1baff6d81901c0869098e
[ "MIT" ]
9
2020-02-16T04:05:58.000Z
2022-02-08T05:23:45.000Z
setup.py
ShuzhiLiu/MaskRCNN
02602c20f17d583621e1baff6d81901c0869098e
[ "MIT" ]
1
2020-04-03T11:41:48.000Z
2020-04-04T07:03:59.000Z
setup.py
ShuzhiLiu/MaskRCNN
02602c20f17d583621e1baff6d81901c0869098e
[ "MIT" ]
2
2020-04-03T12:36:02.000Z
2020-06-28T07:52:36.000Z
import os dir_list = ['SavedModels', 'SavedDebugImages', 'TensorboardLogs'] for directory in dir_list: if not os.path.isdir(directory): print(f"directory: {directory} doesn't exist, create now") os.mkdir(directory) print(f"created directory: {directory}")
25.833333
66
0.632258
import os dir_list = ['SavedModels', 'SavedDebugImages', 'TensorboardLogs'] for directory in dir_list: if not os.path.isdir(directory): print(f"directory: {directory} doesn't exist, create now") os.mkdir(directory) print(f"created directory: {directory}")
true
true
f7fd0765402602733631ae03e2147097f87c6cdc
376
py
Python
rapidsms/contrib/messagelog/tables.py
catalpainternational/rapidsms
eb7234d04ceb31e4d57187f2d6ba2806d0c54e15
[ "BSD-3-Clause" ]
330
2015-01-11T03:00:14.000Z
2022-03-21T11:34:23.000Z
rapidsms/contrib/messagelog/tables.py
catalpainternational/rapidsms
eb7234d04ceb31e4d57187f2d6ba2806d0c54e15
[ "BSD-3-Clause" ]
45
2015-01-06T16:14:19.000Z
2022-03-16T13:12:53.000Z
rapidsms/contrib/messagelog/tables.py
catalpainternational/rapidsms
eb7234d04ceb31e4d57187f2d6ba2806d0c54e15
[ "BSD-3-Clause" ]
166
2015-01-30T19:53:38.000Z
2021-11-09T18:44:44.000Z
#!/usr/bin/env python # vim: ai ts=4 sts=4 et sw=4 import django_tables2 as tables from rapidsms.contrib.messagelog.models import Message class MessageTable(tables.Table): class Meta: model = Message exclude = ('id', ) order_by = ('-date', ) attrs = { 'class': 'table ...
22.117647
73
0.617021
import django_tables2 as tables from rapidsms.contrib.messagelog.models import Message class MessageTable(tables.Table): class Meta: model = Message exclude = ('id', ) order_by = ('-date', ) attrs = { 'class': 'table table-striped table-bordered table-condensed' ...
true
true
f7fd08828e31e14203c94603aec1e4a1bc2ec669
12,054
py
Python
python/ccxt/async_support/base/exchange.py
invao/ccxt
a255988654c0052adb2ccc99cff54e4e0c28028d
[ "MIT" ]
null
null
null
python/ccxt/async_support/base/exchange.py
invao/ccxt
a255988654c0052adb2ccc99cff54e4e0c28028d
[ "MIT" ]
null
null
null
python/ccxt/async_support/base/exchange.py
invao/ccxt
a255988654c0052adb2ccc99cff54e4e0c28028d
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # ----------------------------------------------------------------------------- __version__ = '1.18.472' # ----------------------------------------------------------------------------- import asyncio import concurrent import socket import time import math import random import certifi import ...
42.146853
355
0.611581
__version__ = '1.18.472' import asyncio import concurrent import socket import time import math import random import certifi import aiohttp import ssl import sys import yarl from ccxt.async_support.base.throttle import throttle from ccxt.base.errors import ExchangeError from ccxt.base.errors import Exchang...
true
true
f7fd099ffcd67116bb077ce15304ec63da9d0195
5,923
py
Python
pymathics/setup.py
Jankyboy/Mathics
d79a0af13d21c10f5e8d1df399d1ac13399b479a
[ "Apache-2.0" ]
null
null
null
pymathics/setup.py
Jankyboy/Mathics
d79a0af13d21c10f5e8d1df399d1ac13399b479a
[ "Apache-2.0" ]
2
2020-10-12T23:17:05.000Z
2021-08-07T22:37:06.000Z
pymathics/setup.py
Jankyboy/Mathics
d79a0af13d21c10f5e8d1df399d1ac13399b479a
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import print_function from __future__ import absolute_import """Setuptools based setup script for Mathics. For the easiest installation just type the following command (you'll probably need root privileges): python setup.py install This will install...
29.17734
88
0.638528
from __future__ import print_function from __future__ import absolute_import import sys import platform import os from setuptools import setup, Command, Extension if sys.version_info < (3, 6): print("Mathics support Python 3.6 and above; you have %d.%d" % sys.version_info[:2]) sys.exit(-1) exec(compile...
true
true
f7fd0bb02f6429066eb47f9dbcc6f8d27b28445a
428
py
Python
extract.py
akusumoto/sample_dash
431d4b8a0e524ed8eb6f616594afbb67f5dcd428
[ "BSD-3-Clause" ]
null
null
null
extract.py
akusumoto/sample_dash
431d4b8a0e524ed8eb6f616594afbb67f5dcd428
[ "BSD-3-Clause" ]
null
null
null
extract.py
akusumoto/sample_dash
431d4b8a0e524ed8eb6f616594afbb67f5dcd428
[ "BSD-3-Clause" ]
1
2021-11-03T07:48:25.000Z
2021-11-03T07:48:25.000Z
import numpy as np def random(texture, num): # idx = np.random.choice(texture.shape[0], num, replace=False) # 乱数を抽出するときに重複を許さない場合(ただし、サンプル数が少ないとエラーになりやすい) idx = np.random.choice(texture.shape[0], num) # 乱数を抽出するときに重複を許す場合(ただし、サンプル数が少ない時でも安定) return texture[idx] def stat(texture, num): pass ...
22.526316
113
0.670561
import numpy as np def random(texture, num): um) return texture[idx] def stat(texture, num): pass def hybrid(texture, num): pass method = {'random': random, 'STAT': stat, 'HybridIA': hybrid}
true
true
f7fd0bb889bd2a74fc08867527386634f53f6475
2,682
py
Python
quorra/methods.py
bprinty/quorra-python
82b6583992c6db4f16ee0d74ea7b1fe5e84cf03c
[ "Apache-2.0" ]
null
null
null
quorra/methods.py
bprinty/quorra-python
82b6583992c6db4f16ee0d74ea7b1fe5e84cf03c
[ "Apache-2.0" ]
null
null
null
quorra/methods.py
bprinty/quorra-python
82b6583992c6db4f16ee0d74ea7b1fe5e84cf03c
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # # Methods for interacting with quorra plots. # # @author <bprinty@gmail.com> # ------------------------------------------------ # imports # ------- import os # config # ------ _open = None _app = None __src__ = os.path.dirname(os.path.realpath(__file__)) __cwd__ = os.getcwd() __templates__...
31.186047
90
0.585011
import os _open = None _app = None __src__ = os.path.dirname(os.path.realpath(__file__)) __cwd__ = os.getcwd() __templates__ = os.path.join(__src__, 'tmpl') def export(plot, filename, width=800, height=600): import signal import uuid from selenium.webdriver import PhantomJS global __te...
true
true
f7fd0c6cb84faeeb14bf0efb52b65decb817042e
3,495
py
Python
piano_keys/generate_keys.py
rebpdx/blender-scripts
7557fc6029da250b53d7e677169b83b80773e62d
[ "MIT" ]
1
2021-12-16T20:26:57.000Z
2021-12-16T20:26:57.000Z
piano_keys/generate_keys.py
rebpdx/blender-scripts
7557fc6029da250b53d7e677169b83b80773e62d
[ "MIT" ]
null
null
null
piano_keys/generate_keys.py
rebpdx/blender-scripts
7557fc6029da250b53d7e677169b83b80773e62d
[ "MIT" ]
null
null
null
""" This script generates an object of basic keys for testing with so that a full piano does not need to be rendered when testing actuating the keyboard """ __author__ = "Robert Brown" __copyright__ = "Copyright 2018" __license__ = "MIT" __version__ = "1.0.0" __maintainer__ = "Rob Brown" __email__ = "hi@robbrown.io" _...
32.663551
98
0.630901
__author__ = "Robert Brown" __copyright__ = "Copyright 2018" __license__ = "MIT" __version__ = "1.0.0" __maintainer__ = "Rob Brown" __email__ = "hi@robbrown.io" __status__ = "Prototype" from math import floor import bpy PADDING = 0.05 NUMBER_OF_OCTIVES = 8 STARTING_KEY = 4 NUMBER_OF_WKEYS = NUMBER_OF_OCTIVES * 7 ...
true
true
f7fd0c731492d0af481cee2954e3b25724e77f07
7,114
py
Python
docs/report/cloudmesh-openapi/tests/generator-natural-lang/test_generator_natural_language.py
rickotten/cybertraining-dsc.github.io
c8ea59be4f09fd543040ba0908af118df5820a70
[ "Apache-2.0" ]
7
2020-02-29T14:53:19.000Z
2021-01-17T17:08:44.000Z
docs/report/cloudmesh-openapi/tests/generator-natural-lang/test_generator_natural_language.py
rickotten/cybertraining-dsc.github.io
c8ea59be4f09fd543040ba0908af118df5820a70
[ "Apache-2.0" ]
27
2020-02-29T13:38:11.000Z
2020-09-02T20:24:59.000Z
docs/report/cloudmesh-openapi/tests/generator-natural-lang/test_generator_natural_language.py
rickotten/cybertraining-dsc.github.io
c8ea59be4f09fd543040ba0908af118df5820a70
[ "Apache-2.0" ]
6
2020-03-02T17:09:14.000Z
2020-10-30T22:48:01.000Z
############################################################### # pytest -v --capture=no ./tests/generator-natural-lang/test_generator_natural_language.py # pytest -v ./tests/generator-natural-lang/test_generator_natural_language.py # pytest -v --capture=no ./tests/generator-natural-lang/test_generator_natural_langua...
32.336364
127
0.6535
def test_provider_vm_create(self): HEADING() os.system(f"cms vm list --cloud={cloud}") name_generator.incr() Benchmark.Start() data = provider.create(key=pub_key) Benchmark.Stop() VERBOSE(data) name = str(Name()) sta...
true
true
f7fd0d5c8afcedae5b6b321b8947b40cc1efca58
5,155
py
Python
analysis/src/python/evaluation/inspectors/diffs_between_df.py
eartser/hyperstyle-analyze
58e2d361662e73e1e047919f57ab840055783b7a
[ "Apache-2.0" ]
1
2022-03-15T09:46:06.000Z
2022-03-15T09:46:06.000Z
analysis/src/python/evaluation/inspectors/diffs_between_df.py
eartser/hyperstyle-analyze
58e2d361662e73e1e047919f57ab840055783b7a
[ "Apache-2.0" ]
1
2022-02-14T13:53:38.000Z
2022-02-14T13:53:38.000Z
analysis/src/python/evaluation/inspectors/diffs_between_df.py
eartser/hyperstyle-analyze
58e2d361662e73e1e047919f57ab840055783b7a
[ "Apache-2.0" ]
3
2022-02-13T16:49:53.000Z
2022-02-17T13:53:07.000Z
import argparse from pathlib import Path import pandas as pd from hyperstyle.src.python.review.quality.model import QualityType from analysis.src.python.evaluation.common.pandas_util import ( get_inconsistent_positions, get_issues_by_row, get_solutions_df, get_solutions_df_by_file_path, ) from analysis.src.python....
46.863636
115
0.704559
import argparse from pathlib import Path import pandas as pd from hyperstyle.src.python.review.quality.model import QualityType from analysis.src.python.evaluation.common.pandas_util import ( get_inconsistent_positions, get_issues_by_row, get_solutions_df, get_solutions_df_by_file_path, ) from analysis.src.python....
true
true
f7fd0e264e2bcd977dbd22a91f28692ff3e6303c
90
py
Python
test/__init__.py
sjbrownrigg/mediafile
b851e032869462ecb79e83bffa6a71350229c9a1
[ "MIT" ]
79
2016-06-15T09:18:38.000Z
2022-03-19T16:30:05.000Z
test/__init__.py
sjbrownrigg/mediafile
b851e032869462ecb79e83bffa6a71350229c9a1
[ "MIT" ]
56
2016-07-03T02:41:55.000Z
2022-03-30T11:44:08.000Z
test/__init__.py
sjbrownrigg/mediafile
b851e032869462ecb79e83bffa6a71350229c9a1
[ "MIT" ]
27
2016-07-03T02:29:51.000Z
2022-01-16T08:42:27.000Z
# -*- coding: utf-8 -*- from __future__ import division, absolute_import, print_function
22.5
64
0.744444
from __future__ import division, absolute_import, print_function
true
true
f7fd0ef23d781430f2fcb7377e4252960dfdb48b
6,287
py
Python
sdk/python/pulumi_azure_nextgen/compute/v20190701/gallery.py
pulumi/pulumi-azure-nextgen
452736b0a1cf584c2d4c04666e017af6e9b2c15c
[ "Apache-2.0" ]
31
2020-09-21T09:41:01.000Z
2021-02-26T13:21:59.000Z
sdk/python/pulumi_azure_nextgen/compute/v20190701/gallery.py
pulumi/pulumi-azure-nextgen
452736b0a1cf584c2d4c04666e017af6e9b2c15c
[ "Apache-2.0" ]
231
2020-09-21T09:38:45.000Z
2021-03-01T11:16:03.000Z
sdk/python/pulumi_azure_nextgen/compute/v20190701/gallery.py
pulumi/pulumi-azure-nextgen
452736b0a1cf584c2d4c04666e017af6e9b2c15c
[ "Apache-2.0" ]
4
2020-09-29T14:14:59.000Z
2021-02-10T20:38:16.000Z
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from ... import _utilities, _tables from...
40.824675
418
0.642914
import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from ... import _utilities, _tables from . import outputs __all__ = ['Gallery'] class Gallery(pulumi.CustomResource): def __init__(__self__, resource_name: str, opt...
true
true
f7fd0fb94825ccf6cf45cea8de36bcaf49154ed7
1,944
py
Python
words_stat.py
grinya007/streaming_rnn
71ad0c1640c5e482da1b74e28625025c6c7b3d5a
[ "MIT" ]
null
null
null
words_stat.py
grinya007/streaming_rnn
71ad0c1640c5e482da1b74e28625025c6c7b3d5a
[ "MIT" ]
null
null
null
words_stat.py
grinya007/streaming_rnn
71ad0c1640c5e482da1b74e28625025c6c7b3d5a
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import argparse from data import read_texts_csv, strip_words from plot import save_plot from static_vocabulary import StaticVocabulary from dynamic_vocabulary_2q import DynamicVocabulary2Q VOCABSIZE = 110000 FILLVOCAB = 10000000 RUNTESTON = 100000000 PLOTEVERY = 2000000 def plot_unknown_word...
24.607595
82
0.610082
import argparse from data import read_texts_csv, strip_words from plot import save_plot from static_vocabulary import StaticVocabulary from dynamic_vocabulary_2q import DynamicVocabulary2Q VOCABSIZE = 110000 FILLVOCAB = 10000000 RUNTESTON = 100000000 PLOTEVERY = 2000000 def plot_unknown_words_ratio(input_csv): ...
true
true
f7fd0ff6e498597ff0bf1f48967a9c926ad4a86e
216
py
Python
t1.py
paulc/streamlit-hello
f41623efe049db982ac63af725ee2316477360e3
[ "MIT" ]
null
null
null
t1.py
paulc/streamlit-hello
f41623efe049db982ac63af725ee2316477360e3
[ "MIT" ]
null
null
null
t1.py
paulc/streamlit-hello
f41623efe049db982ac63af725ee2316477360e3
[ "MIT" ]
null
null
null
import streamlit as st import pandas as pd st.write("Here's our first attempt at using data to create a table:") st.write(pd.DataFrame({ 'first column': [1, 2, 3, 4], 'second column': [10, 20, 30, 40] }))
19.636364
69
0.648148
import streamlit as st import pandas as pd st.write("Here's our first attempt at using data to create a table:") st.write(pd.DataFrame({ 'first column': [1, 2, 3, 4], 'second column': [10, 20, 30, 40] }))
true
true
f7fd10e30d6ec15ffd4a350ad33fe5232cf11eda
3,174
py
Python
src/reading_stimuli.py
aslansd/DNNforVPL
7cda3eb327050f98b0867a4eca4cadb813d2c466
[ "MIT" ]
null
null
null
src/reading_stimuli.py
aslansd/DNNforVPL
7cda3eb327050f98b0867a4eca4cadb813d2c466
[ "MIT" ]
null
null
null
src/reading_stimuli.py
aslansd/DNNforVPL
7cda3eb327050f98b0867a4eca4cadb813d2c466
[ "MIT" ]
null
null
null
""" Created by Aslan Satary Dizaji (a.satarydizaji@eni-g.de) """ import gc import glob import numpy as np import os import random import torch import torchvision.transforms as transforms from PIL import Image def reading_stimuli(file_names, file_name_paths, orientation, spatial_frequency) ...
37.785714
105
0.499685
""" Created by Aslan Satary Dizaji (a.satarydizaji@eni-g.de) """ import gc import glob import numpy as np import os import random import torch import torchvision.transforms as transforms from PIL import Image def reading_stimuli(file_names, file_name_paths, orientation, spatial_frequency) ...
false
true