hexsha stringlengths 40 40 | size int64 5 2.06M | ext stringclasses 11
values | lang stringclasses 1
value | max_stars_repo_path stringlengths 3 251 | max_stars_repo_name stringlengths 4 130 | max_stars_repo_head_hexsha stringlengths 40 78 | max_stars_repo_licenses listlengths 1 10 | max_stars_count int64 1 191k ⌀ | max_stars_repo_stars_event_min_datetime stringlengths 24 24 ⌀ | max_stars_repo_stars_event_max_datetime stringlengths 24 24 ⌀ | max_issues_repo_path stringlengths 3 251 | max_issues_repo_name stringlengths 4 130 | max_issues_repo_head_hexsha stringlengths 40 78 | max_issues_repo_licenses listlengths 1 10 | max_issues_count int64 1 116k ⌀ | max_issues_repo_issues_event_min_datetime stringlengths 24 24 ⌀ | max_issues_repo_issues_event_max_datetime stringlengths 24 24 ⌀ | max_forks_repo_path stringlengths 3 251 | max_forks_repo_name stringlengths 4 130 | max_forks_repo_head_hexsha stringlengths 40 78 | max_forks_repo_licenses listlengths 1 10 | max_forks_count int64 1 105k ⌀ | max_forks_repo_forks_event_min_datetime stringlengths 24 24 ⌀ | max_forks_repo_forks_event_max_datetime stringlengths 24 24 ⌀ | content stringlengths 1 1.05M | avg_line_length float64 1 1.02M | max_line_length int64 3 1.04M | alphanum_fraction float64 0 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
63b5c11e95ca01d34e674cc2e9e39d8f57bab66d | 9,678 | py | Python | ml3d/tf/modules/pointnet.py | eiiijiiiy/Open3D-ML | 2a04231df0be39e2b8030e480d342cee5574fb9a | [
"MIT"
] | null | null | null | ml3d/tf/modules/pointnet.py | eiiijiiiy/Open3D-ML | 2a04231df0be39e2b8030e480d342cee5574fb9a | [
"MIT"
] | null | null | null | ml3d/tf/modules/pointnet.py | eiiijiiiy/Open3D-ML | 2a04231df0be39e2b8030e480d342cee5574fb9a | [
"MIT"
] | null | null | null | import tensorflow as tf
from typing import List
from ..utils.tf_utils import gen_CNN
from ...utils import MODEL
from ..utils.pointnet import pointnet2_utils
MODEL._register_module(Pointnet2MSG, 'tf')
MODEL._register_module(PointnetSAModule, 'tf')
MODEL._register_module(PointnetFPModule, 'tf')
if __name__... | 36.520755 | 103 | 0.515189 |
63b69e49a561a7a7f6b1bf9ff48c5966ebd4c9f7 | 1,374 | py | Python | utils/config.py | PierreHao/YouGraph | ae8cf5d5bb544f64ee206bcba07ece66d49e00e3 | [
"MIT"
] | 18 | 2021-06-16T07:34:58.000Z | 2022-03-22T11:52:20.000Z | utils/config.py | SuperXiang/YouGraph | fe3dcc77ba901893f2ffa6ae8dd773320ac5f862 | [
"MIT"
] | 1 | 2021-06-16T17:04:33.000Z | 2021-06-22T18:53:08.000Z | utils/config.py | SuperXiang/YouGraph | fe3dcc77ba901893f2ffa6ae8dd773320ac5f862 | [
"MIT"
] | 4 | 2021-07-08T02:09:27.000Z | 2022-03-31T01:08:05.000Z | import argparse
import json
from easydict import EasyDict
if __name__ == '__main__':
config = get_config_from_json('../configs/MUTAG.json')
sub_configurations = config.configurations
print(sub_configurations['pooling'])
| 24.981818 | 66 | 0.636099 |
63b74e1885d1242860e5b1d4ed405f1ff5699ee2 | 1,887 | py | Python | data_prep/train_val_test_splitter.py | GIT-chandra/DeReflectionNet | e214f8574c5d018a8568145cbbe7a78b41026c3b | [
"MIT"
] | null | null | null | data_prep/train_val_test_splitter.py | GIT-chandra/DeReflectionNet | e214f8574c5d018a8568145cbbe7a78b41026c3b | [
"MIT"
] | 1 | 2019-03-04T06:25:16.000Z | 2019-03-13T09:29:11.000Z | data_prep/train_val_test_splitter.py | GIT-chandra/DeReflectionNet | e214f8574c5d018a8568145cbbe7a78b41026c3b | [
"MIT"
] | null | null | null | import shutil
import numpy as np
ALL_SYNTHS_LIST = 'synth_imgs.txt'
TRAIN_IMAGES_LIST = 'train_imgs.txt'
VAL_IMAGES_LIST = 'val_imgs.txt'
TEST_IMAGES_LIST = 'test_imgs.txt'
TRAIN_STOP = 342000
VAL_STOP = TRAIN_STOP + 38000
'''
390000 examples : 342000 train and 38000 val (90/10 splits on 380000), 10000 test
'''
wi... | 34.944444 | 82 | 0.606783 |
63b7a45ec105c6ba1c889efaafdedd671e56a63a | 803 | py | Python | example/fastapi/models.py | cnjlq84/oidc-op | c7ab007327cc1a5e69abba7699c0be5f29534049 | [
"Apache-2.0"
] | 31 | 2020-09-15T21:18:05.000Z | 2022-02-17T02:50:04.000Z | example/fastapi/models.py | cnjlq84/oidc-op | c7ab007327cc1a5e69abba7699c0be5f29534049 | [
"Apache-2.0"
] | 106 | 2021-03-26T17:12:54.000Z | 2022-03-11T07:19:46.000Z | example/fastapi/models.py | cnjlq84/oidc-op | c7ab007327cc1a5e69abba7699c0be5f29534049 | [
"Apache-2.0"
] | 13 | 2020-02-12T16:31:01.000Z | 2022-03-03T09:54:44.000Z | from typing import List
from typing import Optional
from pydantic import BaseModel
| 25.09375 | 69 | 0.711083 |
63b7c7a23f4c13a732afba3bcbd544198bdcf67b | 3,957 | py | Python | fnet/functions.py | HelmholtzAI-Consultants-Munich/pytorch_fnet | 879784bd0f8e76ab8f0ed8de4235180a316e12d8 | [
"Unlicense"
] | null | null | null | fnet/functions.py | HelmholtzAI-Consultants-Munich/pytorch_fnet | 879784bd0f8e76ab8f0ed8de4235180a316e12d8 | [
"Unlicense"
] | null | null | null | fnet/functions.py | HelmholtzAI-Consultants-Munich/pytorch_fnet | 879784bd0f8e76ab8f0ed8de4235180a316e12d8 | [
"Unlicense"
] | null | null | null | import importlib
import json
import os
import pdb
import sys
import fnet
import pandas as pd
import tifffile
import numpy as np
from fnet.transforms import normalize
# code retrieved on 21.05.21 from: https://github.com/pytorch/pytorch/issues/1254
def pearsonr(x, y):
"""
Mimics `scipy.stats.pearsonr`
Argu... | 30.674419 | 97 | 0.635583 |
63b7ef516ba9eb132540a0353455cfa47e2e1ffb | 3,151 | py | Python | scrape_mars.py | neilgbp/MissiontoMarsWebScrapingHW | 4afaf6a30cb03111ed53645afaedd3081cb7bbb7 | [
"ADSL"
] | null | null | null | scrape_mars.py | neilgbp/MissiontoMarsWebScrapingHW | 4afaf6a30cb03111ed53645afaedd3081cb7bbb7 | [
"ADSL"
] | null | null | null | scrape_mars.py | neilgbp/MissiontoMarsWebScrapingHW | 4afaf6a30cb03111ed53645afaedd3081cb7bbb7 | [
"ADSL"
] | null | null | null | import os
import pandas as pd
import pymongo
import requests
import time
from splinter import Browser
from bs4 import BeautifulSoup
from selenium import webdriver
print(os.path.abspath("chromedriver.exe"))
if __name__ == "__main__":
print(scrape()) | 32.484536 | 109 | 0.663916 |
63b9f24ae6a49d0ba7a1154d3162616044c52214 | 3,989 | py | Python | indy_node/test/rich_schema/test_rich_schemas_disabled_by_default.py | Rob-S/indy-node | 0aefbda62c5a7412d7e03b2fb9795c500ea67e9f | [
"Apache-2.0"
] | 627 | 2017-07-06T12:38:08.000Z | 2022-03-30T13:18:43.000Z | indy_node/test/rich_schema/test_rich_schemas_disabled_by_default.py | Rob-S/indy-node | 0aefbda62c5a7412d7e03b2fb9795c500ea67e9f | [
"Apache-2.0"
] | 580 | 2017-06-29T17:59:57.000Z | 2022-03-29T21:37:52.000Z | indy_node/test/rich_schema/test_rich_schemas_disabled_by_default.py | Rob-S/indy-node | 0aefbda62c5a7412d7e03b2fb9795c500ea67e9f | [
"Apache-2.0"
] | 704 | 2017-06-29T17:45:34.000Z | 2022-03-30T07:08:58.000Z | import json
import pytest
from indy_common.constants import JSON_LD_CONTEXT, RS_CONTEXT_TYPE_VALUE, RS_ID, GET_RICH_SCHEMA_OBJECT_BY_ID, \
GET_RICH_SCHEMA_OBJECT_BY_METADATA, RS_NAME, RS_VERSION, RS_TYPE
from indy_node.test.api.helper import sdk_build_rich_schema_request, sdk_write_rich_schema_object_and_check
fr... | 55.402778 | 115 | 0.670093 |
63bc76920a70004a6435e13b986e5d039044a30a | 613 | py | Python | __about__.py | a232319779/python_mmdt | 66458e08bbf6cc5961a3e4134f0969aaa4f21b71 | [
"MIT"
] | 5 | 2021-02-01T07:23:15.000Z | 2022-02-21T11:05:50.000Z | __about__.py | a232319779/python_mmdt | 66458e08bbf6cc5961a3e4134f0969aaa4f21b71 | [
"MIT"
] | null | null | null | __about__.py | a232319779/python_mmdt | 66458e08bbf6cc5961a3e4134f0969aaa4f21b71 | [
"MIT"
] | 1 | 2021-02-01T07:23:17.000Z | 2021-02-01T07:23:17.000Z | # -*- coding: utf-8 -*-
# @Time : 2021/01/05 22:53:23
# @Author : ddvv
# @Site : https://ddvvmmzz.github.io
# @File : about.py
# @Software: Visual Studio Code
__all__ = [
"__author__",
"__copyright__",
"__email__",
"__license__",
"__summary__",
"__title__",
"__uri__",
"__ver... | 21.137931 | 53 | 0.646003 |
63bce965f7a1533a26e799f32a00a0a7b1005f81 | 135 | py | Python | img_transforms.py | martinpflaum/image-augmentation-with-point-clouds | 453947520bd74a0b7ae959c1b59e9776b9dfe7a2 | [
"MIT"
] | null | null | null | img_transforms.py | martinpflaum/image-augmentation-with-point-clouds | 453947520bd74a0b7ae959c1b59e9776b9dfe7a2 | [
"MIT"
] | null | null | null | img_transforms.py | martinpflaum/image-augmentation-with-point-clouds | 453947520bd74a0b7ae959c1b59e9776b9dfe7a2 | [
"MIT"
] | null | null | null | import random
from torchvision.transforms import functional as F
from torchvision.transforms import transforms
from PIL import Image | 33.75 | 51 | 0.851852 |
63bd9e9b810c61a3a53d293b5e2aa48bf52f2c4e | 13,332 | py | Python | sourse/ui/modules/current_settings.py | LeaveMyYard/BitmexGridTrader | e7b8c4b1bfdc3dff6b02c3492ced9fb086e1519a | [
"MIT"
] | 28 | 2020-08-20T13:17:51.000Z | 2022-03-10T19:41:41.000Z | sourse/ui/modules/current_settings.py | LeaveMyYard/BitmexGridTrader | e7b8c4b1bfdc3dff6b02c3492ced9fb086e1519a | [
"MIT"
] | 5 | 2020-09-01T03:14:40.000Z | 2022-01-01T11:39:00.000Z | sourse/ui/modules/current_settings.py | LeaveMyYard/BitmexGridTrader | e7b8c4b1bfdc3dff6b02c3492ced9fb086e1519a | [
"MIT"
] | 16 | 2020-11-02T10:35:11.000Z | 2021-12-08T14:05:24.000Z | from __future__ import annotations
from sourse.ui.modules.base_qdockwidget_module import BaseUIModule
from PyQt5 import QtWidgets, QtCore, QtGui
from sourse.marketmaker import MarketMaker
import typing
import json
| 35.93531 | 100 | 0.586559 |
63be5f6fc2edffc16d8c259349723231c31bc671 | 613 | py | Python | lyrics.py | JamesK2754/COVIDBot | b4ffaa21873baa1f0c5dfd5b4d5ebb30bfd8d1a4 | [
"MIT"
] | null | null | null | lyrics.py | JamesK2754/COVIDBot | b4ffaa21873baa1f0c5dfd5b4d5ebb30bfd8d1a4 | [
"MIT"
] | null | null | null | lyrics.py | JamesK2754/COVIDBot | b4ffaa21873baa1f0c5dfd5b4d5ebb30bfd8d1a4 | [
"MIT"
] | null | null | null | import lyricsgenius
geniustoken = "Akf1AHXpbqaKHSQ06hesk8q1urZkHWJ334bzLr1SwZ1BBPSMGUm3NcbcbDR8ye7Z"
genius = lyricsgenius.Genius(geniustoken)
songname = input("")
#print(song.lyrics) | 36.058824 | 85 | 0.722675 |
63bef9d21b68c3b40a658cb21bf53511e46c9e39 | 987 | py | Python | network.py | wildarch/aiai | 765fb67b42359f8fa0b530d5baf13714de069e90 | [
"MIT"
] | 1 | 2020-12-23T12:47:41.000Z | 2020-12-23T12:47:41.000Z | network.py | wildarch/aiai | 765fb67b42359f8fa0b530d5baf13714de069e90 | [
"MIT"
] | null | null | null | network.py | wildarch/aiai | 765fb67b42359f8fa0b530d5baf13714de069e90 | [
"MIT"
] | null | null | null | import numpy as np
import numpy.random as rand
from functools import reduce
| 28.2 | 109 | 0.663627 |
63c00642ff2e4d391cdfd97b2502db83f3e78004 | 276 | py | Python | al_helper/__init__.py | Taehun/al_helper | 8e304a69359e3807564bb15954df2994e0bb8897 | [
"Apache-2.0"
] | null | null | null | al_helper/__init__.py | Taehun/al_helper | 8e304a69359e3807564bb15954df2994e0bb8897 | [
"Apache-2.0"
] | null | null | null | al_helper/__init__.py | Taehun/al_helper | 8e304a69359e3807564bb15954df2994e0bb8897 | [
"Apache-2.0"
] | null | null | null | """Let's score the unlabeled data for the active learning"""
from al_helper.apis import build
from al_helper.helpers import ALHelper, ALHelperFactory, ALHelperObjectDetection
__version__ = "0.1.0"
__all__ = ["build", "ALHelper", "ALHelperFactory", "ALHelperObjectDetection"]
| 39.428571 | 80 | 0.786232 |
63c1e56c492a20f0ed2af22f56c19c8afeb33a3d | 568 | py | Python | flocka/extensions.py | sleekslush/flocka | 3d1c0ae9bf82b7b8afb03494ee6dd8488157fe68 | [
"BSD-2-Clause"
] | 1 | 2018-10-09T14:09:12.000Z | 2018-10-09T14:09:12.000Z | flocka/extensions.py | sleekslush/flocka | 3d1c0ae9bf82b7b8afb03494ee6dd8488157fe68 | [
"BSD-2-Clause"
] | 11 | 2017-03-22T15:26:05.000Z | 2017-06-01T20:17:52.000Z | flocka/extensions.py | sleekslush/flocka | 3d1c0ae9bf82b7b8afb03494ee6dd8488157fe68 | [
"BSD-2-Clause"
] | null | null | null | from flask_cache import Cache
from flask_debugtoolbar import DebugToolbarExtension
from flask_login import LoginManager
from flask_assets import Environment
from flask_migrate import Migrate
from flocka.models import User
# Setup flask cache
cache = Cache()
# Init flask assets
assets_env = Environment()
# Debug Too... | 19.586207 | 52 | 0.806338 |
63c1f522219bcc2dba5b4f17eb780f21296ad3d6 | 90 | py | Python | django_rest_auth_embedded/tests/__init__.py | Volkova-Natalia/django_rest_auth_embedded | 43fe1d23f59332a7794365348989599cde44af6e | [
"MIT"
] | null | null | null | django_rest_auth_embedded/tests/__init__.py | Volkova-Natalia/django_rest_auth_embedded | 43fe1d23f59332a7794365348989599cde44af6e | [
"MIT"
] | 1 | 2021-02-26T16:56:31.000Z | 2021-03-24T09:47:43.000Z | django_rest_auth_email_confirm_reset/tests/__init__.py | Volkova-Natalia/django_rest_auth_email_confirm_reset | 781e63fd97606e48d69acf84fc6bb011e47b10ca | [
"MIT"
] | null | null | null | from .models import *
from .urls import *
from .views import *
from .integration import *
| 18 | 26 | 0.733333 |
63c2e90768ca94858d6102fd8adcdc5f1544bdda | 137 | py | Python | pycwr/__init__.py | 1271756664/study | 8013dd6c597618949c5fcbf86e38502525a8136d | [
"MIT"
] | 144 | 2019-11-27T14:36:41.000Z | 2022-02-23T08:21:17.000Z | pycwr/__init__.py | 1271756664/study | 8013dd6c597618949c5fcbf86e38502525a8136d | [
"MIT"
] | 32 | 2019-11-29T10:11:53.000Z | 2022-03-14T07:46:44.000Z | pycwr/__init__.py | 1271756664/study | 8013dd6c597618949c5fcbf86e38502525a8136d | [
"MIT"
] | 57 | 2019-11-27T12:51:44.000Z | 2022-01-29T14:50:05.000Z | from . import configure, core, draw, io, interp, retrieve, qc
__all__ = ["configure", "core", "draw", "io", "interp", "qc", "retrieve"]
| 34.25 | 73 | 0.635036 |
63c55b4d12d1d8ec15b4829bd9a5a98bed33f3a3 | 979 | py | Python | app/main.py | aturX/python-swagger-docker | c05167c73205e80bd72479f215a2703565059e1c | [
"MIT"
] | null | null | null | app/main.py | aturX/python-swagger-docker | c05167c73205e80bd72479f215a2703565059e1c | [
"MIT"
] | null | null | null | app/main.py | aturX/python-swagger-docker | c05167c73205e80bd72479f215a2703565059e1c | [
"MIT"
] | 1 | 2020-01-08T13:51:24.000Z | 2020-01-08T13:51:24.000Z | import sys
sys.path.append('../') #
sys.path.append('.') #
from flasgger import Swagger
from flask import Flask
from v1.sum_ab_controller import demo_sum
app = Flask(__name__)
# API
template = {
"swagger": "2.0",
"info": {
"title": "XXX API",
"description": "API ",
"contact": {
"responsible... | 22.767442 | 58 | 0.631256 |
63c5f609080ffa98734dc87a441cdb7f22753616 | 2,169 | py | Python | tests/test_primary_beams.py | Song655/sdp-algorithm-reference | fc7c0da9461d5a1606ebb30ed913a44cdcd9b112 | [
"Apache-2.0"
] | 1 | 2019-10-18T13:11:01.000Z | 2019-10-18T13:11:01.000Z | tests/test_primary_beams.py | Song655/sdp-algorithm-reference | fc7c0da9461d5a1606ebb30ed913a44cdcd9b112 | [
"Apache-2.0"
] | 1 | 2019-01-28T23:07:32.000Z | 2019-01-28T23:07:32.000Z | tests/test_primary_beams.py | Song655/sdp-algorithm-reference | fc7c0da9461d5a1606ebb30ed913a44cdcd9b112 | [
"Apache-2.0"
] | 5 | 2018-03-27T03:30:34.000Z | 2019-10-18T13:05:37.000Z | """Unit tests for testing support
"""
import logging
import os
import unittest
import numpy
from astropy import units as u
from astropy.coordinates import SkyCoord
from arl.data.polarisation import PolarisationFrame
from arl.image.operations import export_image_to_fits
from arl.imaging.base import create_image_fro... | 40.924528 | 103 | 0.674504 |
63c70a3e82f535c37cce5aff704d8df99b4e6ede | 3,676 | py | Python | trees/tree_to_pairwisedistance.py | johned0/EdwardsLab | ae0d8b51a579cd009b414d11224b4110ba13af66 | [
"MIT"
] | 30 | 2015-01-25T16:22:51.000Z | 2022-01-20T15:56:47.000Z | trees/tree_to_pairwisedistance.py | johned0/EdwardsLab | ae0d8b51a579cd009b414d11224b4110ba13af66 | [
"MIT"
] | 2 | 2020-04-13T15:00:37.000Z | 2020-09-23T12:35:59.000Z | trees/tree_to_pairwisedistance.py | johned0/EdwardsLab | ae0d8b51a579cd009b414d11224b4110ba13af66 | [
"MIT"
] | 24 | 2015-04-17T00:52:05.000Z | 2021-11-26T17:50:01.000Z | """
Start with a tree file, use ete3 to create a pairwise distance for all nodes. Basically this is the
distance matrix but as tuples.
if we have a tree like
----A
_____________|y
| |
| ----B
________|z
| ... | 34.35514 | 120 | 0.590588 |
63c7b536e598facda277d873456c65962337d344 | 508 | py | Python | src/hitachi2020_b.py | 06keito/study-atcoder | c859e542079b550d19fa5e5e632e982a0dbb9578 | [
"MIT"
] | 1 | 2021-08-19T07:21:47.000Z | 2021-08-19T07:21:47.000Z | src/hitachi2020_b.py | 06keito/main-repository | c859e542079b550d19fa5e5e632e982a0dbb9578 | [
"MIT"
] | null | null | null | src/hitachi2020_b.py | 06keito/main-repository | c859e542079b550d19fa5e5e632e982a0dbb9578 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
if __name__ == '__main__':
main() | 31.75 | 74 | 0.627953 |
63c88a948245c1382a743f6e1329878390cf91ac | 51,310 | py | Python | gazoo_device/tests/unit_tests/utility_tests/adb_utils_test.py | dedsec-9/gazoo-device | 5ed2867c258da80e53b6aae07ec7a65efe473a28 | [
"Apache-2.0"
] | null | null | null | gazoo_device/tests/unit_tests/utility_tests/adb_utils_test.py | dedsec-9/gazoo-device | 5ed2867c258da80e53b6aae07ec7a65efe473a28 | [
"Apache-2.0"
] | null | null | null | gazoo_device/tests/unit_tests/utility_tests/adb_utils_test.py | dedsec-9/gazoo-device | 5ed2867c258da80e53b6aae07ec7a65efe473a28 | [
"Apache-2.0"
] | null | null | null | # Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... | 47.159926 | 80 | 0.717657 |
63cacc17d61840c87378bcbce1b36a18495e24a2 | 1,269 | py | Python | webapp/apps/dynamic/urls.py | codekansas/PolicyBrain | 83c459db883536bae70cc78ca92ebdcff554ac2d | [
"MIT"
] | null | null | null | webapp/apps/dynamic/urls.py | codekansas/PolicyBrain | 83c459db883536bae70cc78ca92ebdcff554ac2d | [
"MIT"
] | null | null | null | webapp/apps/dynamic/urls.py | codekansas/PolicyBrain | 83c459db883536bae70cc78ca92ebdcff554ac2d | [
"MIT"
] | null | null | null | from django.conf.urls import patterns, include, url
from .views import (show_job_submitted, dynamic_input, dynamic_finished,
ogusa_results, dynamic_landing, dynamic_behavioral,
behavior_results, edit_dynamic_behavioral, elastic_results,
dynamic_elasticities, ... | 57.681818 | 99 | 0.684791 |
63cb3e72171de82701ab61371e19e92285bb291d | 8,866 | py | Python | gbdtmo/gbdtmo.py | samanemami/GBDTMO | 33ee163d5db4dd71dae620c8e1f8295ed33c0a24 | [
"MIT"
] | 2 | 2021-09-15T16:18:15.000Z | 2022-01-12T10:35:18.000Z | gbdtmo/gbdtmo.py | samanemami/GBDTMO | 33ee163d5db4dd71dae620c8e1f8295ed33c0a24 | [
"MIT"
] | null | null | null | gbdtmo/gbdtmo.py | samanemami/GBDTMO | 33ee163d5db4dd71dae620c8e1f8295ed33c0a24 | [
"MIT"
] | null | null | null | import numpy as np
import numpy.ctypeslib as npct
import ctypes
from .histogram import get_bins_maps
from .lib_utils import *
| 46.663158 | 108 | 0.518498 |
63cb9cfcd1d1bed86874e36912a9244d3c5563c5 | 443 | py | Python | hold-tests/test_role_ans_dev.py | pahoughton/ansible-pahoughton | dba7c014e43fa232bea05b84f96d5b9115800089 | [
"CC-BY-3.0"
] | null | null | null | hold-tests/test_role_ans_dev.py | pahoughton/ansible-pahoughton | dba7c014e43fa232bea05b84f96d5b9115800089 | [
"CC-BY-3.0"
] | null | null | null | hold-tests/test_role_ans_dev.py | pahoughton/ansible-pahoughton | dba7c014e43fa232bea05b84f96d5b9115800089 | [
"CC-BY-3.0"
] | null | null | null | #!/usr/bin/env python3
# 2018-10-13 (cc) <paul4hough@gmail.com>
'''
pips:
- testinfra
- molecule
- tox
'''
| 17.72 | 61 | 0.573363 |
63cba68bb6cb48b86439201796c5193de0beeb23 | 8,310 | py | Python | padertorch/contrib/cb/summary.py | jensheit/padertorch | 5827ec6ee768c32ae97348050846c7988b6bd5fa | [
"MIT"
] | null | null | null | padertorch/contrib/cb/summary.py | jensheit/padertorch | 5827ec6ee768c32ae97348050846c7988b6bd5fa | [
"MIT"
] | null | null | null | padertorch/contrib/cb/summary.py | jensheit/padertorch | 5827ec6ee768c32ae97348050846c7988b6bd5fa | [
"MIT"
] | null | null | null |
import collections
import torch
import einops
import cached_property
import padertorch as pt
# loss: torch.Tenso r =None,
# losses: dict =None,
# scalars: dict =None,
# histograms: dict =None,
# audios: dict =None,
# images: dict =None,
| 31.240602 | 121 | 0.536221 |
63cc52215ee9f6507c0099207c8677db1e3b4142 | 907 | py | Python | venv/FlightPlan2.py | zowegoop/DroneMapping | 79d8645f0050cc0114e733d16e44e354e1a959c5 | [
"MIT"
] | null | null | null | venv/FlightPlan2.py | zowegoop/DroneMapping | 79d8645f0050cc0114e733d16e44e354e1a959c5 | [
"MIT"
] | null | null | null | venv/FlightPlan2.py | zowegoop/DroneMapping | 79d8645f0050cc0114e733d16e44e354e1a959c5 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# Rescue mission in the mountains 2
# if running locally, you need to install the djitello module
# run this on your linux or mac machine
# pip3 install djitello
######## PARAMETERS ###########
fspeed = 117/10 # Foward Speed in cm/s (15cm/s)
aspeed = 360/10 # Angular Speed Degrees/s
interval ... | 19.717391 | 61 | 0.701213 |
63cd13cafbe9b72881384584902ce2c4c485f091 | 43,992 | py | Python | ubertool/terrplant/tests/test_terrplant_unittest.py | qed-uber/ubertool | 472a143e110f634afdfe03d503e5f442b1e57b86 | [
"Unlicense"
] | 2 | 2016-01-06T20:20:51.000Z | 2016-03-05T13:26:19.000Z | ubertool/terrplant/tests/test_terrplant_unittest.py | qed-uber/ubertool | 472a143e110f634afdfe03d503e5f442b1e57b86 | [
"Unlicense"
] | 21 | 2017-08-02T18:00:16.000Z | 2019-08-20T15:57:09.000Z | ubertool/terrplant/tests/test_terrplant_unittest.py | quanted/ubertool | 472a143e110f634afdfe03d503e5f442b1e57b86 | [
"Unlicense"
] | null | null | null | import datetime
import inspect
import numpy.testing as npt
import os.path
import pandas as pd
import pandas.util.testing as pdt
import sys
from tabulate import tabulate
import unittest
# #find parent directory and import model
# parentddir = os.path.abspath(os.path.join(os.path.dirname(__file__), os.path.pardir))
# sy... | 49.098214 | 122 | 0.618044 |
63cd283958618a19e423133bb4fbcee1918c23d9 | 3,851 | py | Python | mnist.py | a25765564/MLtest | 03fdb97cd215fc2a1d6d584d76f74eb94ffb2266 | [
"MIT"
] | null | null | null | mnist.py | a25765564/MLtest | 03fdb97cd215fc2a1d6d584d76f74eb94ffb2266 | [
"MIT"
] | null | null | null | mnist.py | a25765564/MLtest | 03fdb97cd215fc2a1d6d584d76f74eb94ffb2266 | [
"MIT"
] | null | null | null | import numpy as np
import sklearn.preprocessing as prep
import tensorflow as tf
from tensorflow.examples.tutorials.mnist import input_data
mnist = input_data.read_data_sets('MNIST_DATA',one_hot=True)
X_tain,X_test = standard_scale(mnist.train.images,mnist.test.images)
n_samples = int(mnist.train.num_examp... | 44.77907 | 118 | 0.731758 |
63cd37f1d19aa602021ac5d7d2664ac5f4cbcbd3 | 1,296 | py | Python | images/migrations/0001_initial.py | Hoofeycheng/Bookmarks | f2721633cd39393f0c92993579071679bb975ab0 | [
"MIT"
] | null | null | null | images/migrations/0001_initial.py | Hoofeycheng/Bookmarks | f2721633cd39393f0c92993579071679bb975ab0 | [
"MIT"
] | null | null | null | images/migrations/0001_initial.py | Hoofeycheng/Bookmarks | f2721633cd39393f0c92993579071679bb975ab0 | [
"MIT"
] | null | null | null | # Generated by Django 2.1.4 on 2019-01-21 03:56
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
| 37.028571 | 149 | 0.604938 |
63cd6a4844d309d64fcae3b172caa3687fb25c61 | 951 | py | Python | src/python/detectors/os_command_injection/os_command_injection.py | martinschaef/amazon-codeguru-reviewer-python-detectors | 7452471b7ac5e1f2e1a0bfbd0f615d98f160e0e4 | [
"Apache-2.0"
] | 18 | 2022-01-27T22:50:22.000Z | 2022-02-15T17:41:24.000Z | src/python/detectors/os_command_injection/os_command_injection.py | martinschaef/amazon-codeguru-reviewer-python-detectors | 7452471b7ac5e1f2e1a0bfbd0f615d98f160e0e4 | [
"Apache-2.0"
] | 1 | 2022-01-31T21:36:18.000Z | 2022-02-22T17:09:54.000Z | src/python/detectors/os_command_injection/os_command_injection.py | martinschaef/amazon-codeguru-reviewer-python-detectors | 7452471b7ac5e1f2e1a0bfbd0f615d98f160e0e4 | [
"Apache-2.0"
] | 7 | 2022-02-10T21:50:50.000Z | 2022-03-28T14:21:10.000Z | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0
# {fact rule=os-command-injection@v1.0 defects=1}
# {/fact}
# {fact rule=os-command-injection@v1.0 defects=0}
# {/fact}
| 32.793103 | 69 | 0.701367 |
63cdddd1832970e9972b2c05b624ca631cca30ea | 922 | py | Python | src/Dao/Parts.py | asarfara/PartCost | 99b7485ad811d41ca86a61b922faf51facdabcd3 | [
"MIT"
] | null | null | null | src/Dao/Parts.py | asarfara/PartCost | 99b7485ad811d41ca86a61b922faf51facdabcd3 | [
"MIT"
] | null | null | null | src/Dao/Parts.py | asarfara/PartCost | 99b7485ad811d41ca86a61b922faf51facdabcd3 | [
"MIT"
] | null | null | null | import logging
import json
from typing import List
from src.Entity.Part import Part
from datetime import date
from sqlite3 import Connection
| 28.8125 | 173 | 0.654013 |
63d0e3d64e13f20d2c0c373757cdad7580a1300b | 4,300 | py | Python | src/utils/plots.py | Light4Code/tensorflow-research | 392c2d7bc376f491fec68d479b130f883d6d028d | [
"MIT"
] | 5 | 2020-02-29T16:28:55.000Z | 2021-11-24T07:47:36.000Z | src/utils/plots.py | Light4Code/tensorflow-research | 392c2d7bc376f491fec68d479b130f883d6d028d | [
"MIT"
] | 3 | 2020-11-13T18:41:57.000Z | 2022-02-10T01:37:51.000Z | src/utils/plots.py | Light4Code/tensorflow-research | 392c2d7bc376f491fec68d479b130f883d6d028d | [
"MIT"
] | 4 | 2020-03-24T10:50:17.000Z | 2020-06-02T13:07:28.000Z | import matplotlib.pyplot as plt
import numpy as np
import numpy.ma as ma
import utils.image_util as iu
from utils.custom_types import Vector
| 31.851852 | 108 | 0.608837 |
63d33b671fe35061f0300b274a32b66e28d0a7ac | 80 | py | Python | pypi_starter/__init__.py | wuhaifengdhu/pypi-starter | 3ccb80dd9490f9d65b986350d82f9a20743af17f | [
"Apache-2.0"
] | null | null | null | pypi_starter/__init__.py | wuhaifengdhu/pypi-starter | 3ccb80dd9490f9d65b986350d82f9a20743af17f | [
"Apache-2.0"
] | null | null | null | pypi_starter/__init__.py | wuhaifengdhu/pypi-starter | 3ccb80dd9490f9d65b986350d82f9a20743af17f | [
"Apache-2.0"
] | null | null | null | """
Your application
"""
from submodule.main import *
from main import *
| 11.428571 | 29 | 0.65 |
63d512d7adf908df92c2f691160d882344e7b9d4 | 4,190 | py | Python | pocx/funcs/fofa.py | antx-code/pocx | c11d3a2bed598f21a32c29ac2b27e098e9dede96 | [
"MIT"
] | 9 | 2022-03-11T01:55:23.000Z | 2022-03-26T03:10:53.000Z | pocx/funcs/fofa.py | antx-code/pocx | c11d3a2bed598f21a32c29ac2b27e098e9dede96 | [
"MIT"
] | null | null | null | pocx/funcs/fofa.py | antx-code/pocx | c11d3a2bed598f21a32c29ac2b27e098e9dede96 | [
"MIT"
] | 1 | 2022-03-26T03:10:56.000Z | 2022-03-26T03:10:56.000Z | import httpx
import json
import base64
from loguru import logger
import urllib3
import ssl
try:
ssl_context = httpx.create_ssl_context()
except:
ssl_context = ssl.create_default_context()
ssl_context.options ^= ssl.OP_NO_TLSv1 # Enable TLS 1.0 back
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestW... | 30.362319 | 139 | 0.582816 |
63d54e098e0531437161c2fb674cb796cbee3e48 | 4,783 | py | Python | check_ec2_events.py | chartbeat/check_ec2_events | 3c72752dcb2908ec8c7c4eaf7e5788c6f88ec5aa | [
"Apache-2.0"
] | 2 | 2015-11-05T11:38:09.000Z | 2019-04-21T12:22:30.000Z | check_ec2_events.py | chartbeat/check_ec2_events | 3c72752dcb2908ec8c7c4eaf7e5788c6f88ec5aa | [
"Apache-2.0"
] | null | null | null | check_ec2_events.py | chartbeat/check_ec2_events | 3c72752dcb2908ec8c7c4eaf7e5788c6f88ec5aa | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
#
# Author: Justin Lintz
# Copyright 2013 Chartbeat
# http://www.chartbeat.com
#
# Nagios check to alert on any retiring instances or
# instances that need rebooting
#
import getopt
import sys
import re
from datetime import datetime
from datetime import timedelta
from boto.ec2 import connect_to_... | 30.081761 | 165 | 0.605896 |
63d5eb9388610a04ecb9974176a0d336a0098ead | 7,917 | py | Python | chc/api/CFunctionCandidateContract.py | Databean/CodeHawk-C | 98720753beb51e0bf5105f8f6838618292fbf55c | [
"MIT"
] | 10 | 2020-08-17T15:35:55.000Z | 2022-03-23T14:39:57.000Z | chc/api/CFunctionCandidateContract.py | kestreltechnology/CodeHawk-C | db0fa92fa630cd919f29021d464533f0e7170fed | [
"MIT"
] | 31 | 2020-07-17T05:45:43.000Z | 2021-05-29T04:49:49.000Z | chc/api/CFunctionCandidateContract.py | kestreltechnology/CodeHawk-C | db0fa92fa630cd919f29021d464533f0e7170fed | [
"MIT"
] | 3 | 2020-06-13T05:32:34.000Z | 2021-09-16T02:31:39.000Z | # ------------------------------------------------------------------------------
# CodeHawk C Analyzer
# Author: Henny Sipma
# ------------------------------------------------------------------------------
# The MIT License (MIT)
#
# Copyright (c) 2017-2020 Kestrel Technology LLC
#
# Permission is hereby granted, free ... | 42.336898 | 88 | 0.619679 |
63d6bfe4aff3255cd21a08c6e08c2856786259e9 | 1,496 | py | Python | amplify/ext/phpfpm/util/version.py | dp92987/nginx-amplify-agent | 1b2eed6eab52a82f35974928d75044451b4bedaf | [
"BSD-2-Clause"
] | 308 | 2015-11-17T13:15:33.000Z | 2022-03-24T12:03:40.000Z | amplify/ext/phpfpm/util/version.py | dp92987/nginx-amplify-agent | 1b2eed6eab52a82f35974928d75044451b4bedaf | [
"BSD-2-Clause"
] | 211 | 2015-11-16T15:27:41.000Z | 2022-03-28T16:20:15.000Z | amplify/ext/phpfpm/util/version.py | dp92987/nginx-amplify-agent | 1b2eed6eab52a82f35974928d75044451b4bedaf | [
"BSD-2-Clause"
] | 80 | 2015-11-16T18:20:30.000Z | 2022-03-02T12:47:56.000Z | # -*- coding: utf-8 -*-
from amplify.agent.common.context import context
from amplify.agent.common.util import subp
__author__ = "Grant Hulegaard"
__copyright__ = "Copyright (C) Nginx, Inc. All rights reserved."
__license__ = ""
__maintainer__ = "Grant Hulegaard"
__email__ = "grant.hulegaard@nginx.com"
VERSION_CMD ... | 31.829787 | 76 | 0.590241 |
891d4ed726e77fd986edee372d297804eaad447d | 385 | py | Python | protera_stability/engine/__init__.py | stepp1/protera-stability | 62f70af00b9475a0b0aeba39fa6ae57f0bb25b34 | [
"MIT"
] | 1 | 2021-11-05T02:14:31.000Z | 2021-11-05T02:14:31.000Z | protera_stability/engine/__init__.py | stepp1/protera-stability | 62f70af00b9475a0b0aeba39fa6ae57f0bb25b34 | [
"MIT"
] | null | null | null | protera_stability/engine/__init__.py | stepp1/protera-stability | 62f70af00b9475a0b0aeba39fa6ae57f0bb25b34 | [
"MIT"
] | null | null | null | from protera_stability.engine.default import get_cfg, setup_train, DefaultTrainer
from protera_stability.engine.lightning_train import (
default_cbs,
DataModule,
LitProteins,
TrainingPl,
)
__all__ = [
"DataModule",
"DefaultTrainer",
"LitProteins",
"TrainingPl",
"default_cbs",
"g... | 19.25 | 81 | 0.698701 |
891d65158f17bd525585b5367fe4ef83f22f5f0b | 416 | py | Python | 1122.py | wilbertgeng/LeetCode_exercise | f00c08e0d28ffa88d61d4262c6d1f49f1fa91ebc | [
"MIT"
] | null | null | null | 1122.py | wilbertgeng/LeetCode_exercise | f00c08e0d28ffa88d61d4262c6d1f49f1fa91ebc | [
"MIT"
] | null | null | null | 1122.py | wilbertgeng/LeetCode_exercise | f00c08e0d28ffa88d61d4262c6d1f49f1fa91ebc | [
"MIT"
] | null | null | null | """1122. Relative Sort Array"""
| 26 | 62 | 0.526442 |
891f7d296bd8553fa96b43de039756b437874319 | 1,037 | py | Python | src/merge_sort.py | Gsllchb/4interview-python | efec766f276039cb3766f5068c7914f31ac74aca | [
"MIT"
] | null | null | null | src/merge_sort.py | Gsllchb/4interview-python | efec766f276039cb3766f5068c7914f31ac74aca | [
"MIT"
] | null | null | null | src/merge_sort.py | Gsllchb/4interview-python | efec766f276039cb3766f5068c7914f31ac74aca | [
"MIT"
] | null | null | null | import itertools
_THRESHOLD = 64
if __name__ == '__main__':
_test()
| 21.163265 | 55 | 0.493732 |
891fe67e35e33d36e5cc37b7ff0cf9fe1518755c | 59,661 | py | Python | code/client/munkilib/adobeutils.py | jlrgraham/munki | 9e0deb754083c671f8005f05e7ec44fbe001b790 | [
"Apache-2.0"
] | null | null | null | code/client/munkilib/adobeutils.py | jlrgraham/munki | 9e0deb754083c671f8005f05e7ec44fbe001b790 | [
"Apache-2.0"
] | null | null | null | code/client/munkilib/adobeutils.py | jlrgraham/munki | 9e0deb754083c671f8005f05e7ec44fbe001b790 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/python
# encoding: utf-8
"""
adobeutils.py
Utilities to enable munki to install/uninstall Adobe CS3/CS4/CS5 products
using the CS3/CS4/CS5 Deployment Toolkits.
"""
# Copyright 2009-2014 Greg Neagle.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in co... | 40.752049 | 80 | 0.593755 |
8921c8342da583a53fe7e6baf0b2a3160c459d31 | 52 | py | Python | examples/fore.py | LyQuid12/colorgb | 78addcf85f0e750ca45a7955e5008f7a8a946281 | [
"MIT"
] | 1 | 2022-01-26T10:26:24.000Z | 2022-01-26T10:26:24.000Z | examples/fore.py | LyQuid12/colorgb | 78addcf85f0e750ca45a7955e5008f7a8a946281 | [
"MIT"
] | null | null | null | examples/fore.py | LyQuid12/colorgb | 78addcf85f0e750ca45a7955e5008f7a8a946281 | [
"MIT"
] | null | null | null | import colorgb
print(colorgb.fore("Hi!", "green"))
| 13 | 35 | 0.692308 |
892211146079eeb490107a06692355e20fadb9be | 1,513 | py | Python | prac/20200310/pygame_intro.py | yaroslavKonst/PythonPracticum | 2215b169252b6d429f1f38e5f2295d1435256785 | [
"Apache-2.0"
] | 2 | 2020-04-10T22:09:19.000Z | 2020-04-10T22:09:24.000Z | prac/20200310/pygame_intro.py | yaroslavKonst/PythonPracticum | 2215b169252b6d429f1f38e5f2295d1435256785 | [
"Apache-2.0"
] | null | null | null | prac/20200310/pygame_intro.py | yaroslavKonst/PythonPracticum | 2215b169252b6d429f1f38e5f2295d1435256785 | [
"Apache-2.0"
] | null | null | null | import sys, pygame
pygame.init()
world_size = width, height = 10000, 9000
speed = [2, 2]
DX, DY = 0.1, 0.1
position = [width / 2, height / 2]
screen_size = int(DX * width), int(DY * height)
black = 0, 0, 0
screen = pygame.display.set_mode(screen_size)
ball = pygame.image.load("intro_ball.gif")
ballrect = ball.get_r... | 29.666667 | 127 | 0.574356 |
8922c6587dd08bd4b2be1a2477201fbaf0a8a712 | 18,808 | py | Python | gh.py | old-beans/isaac-gh-discord-bot | 4c0d704475e4e9b546e8359390f79ea4959fc2a9 | [
"MIT"
] | 2 | 2020-09-22T02:01:52.000Z | 2021-03-28T05:56:59.000Z | gh.py | old-beans/gh-isaacbot | 4c0d704475e4e9b546e8359390f79ea4959fc2a9 | [
"MIT"
] | null | null | null | gh.py | old-beans/gh-isaacbot | 4c0d704475e4e9b546e8359390f79ea4959fc2a9 | [
"MIT"
] | null | null | null | #! python
from airtable import Airtable
import discord, fstrings, re, random, os
from datetime import datetime
# datetime object containing current date and time
AIRTABLE_API_KEY = os.getenv('AIRTABLE_API_KEY') # stored in .env
AIRTABLE_BASE_KEY = os.getenv('AIRTABLE_BASE_KEY') # stored in .env
CAMPAIGN_NAME = os.g... | 41.245614 | 129 | 0.621969 |
892320f63f5d2a0ca42e3afab52c7bbe19958d5f | 13,620 | py | Python | bilbyweb/utility/job.py | ASVO-TAO/SS18B-PLasky | a3c13b05f894fb8cebd5be381c170b8a78adb81a | [
"MIT"
] | null | null | null | bilbyweb/utility/job.py | ASVO-TAO/SS18B-PLasky | a3c13b05f894fb8cebd5be381c170b8a78adb81a | [
"MIT"
] | null | null | null | bilbyweb/utility/job.py | ASVO-TAO/SS18B-PLasky | a3c13b05f894fb8cebd5be381c170b8a78adb81a | [
"MIT"
] | null | null | null | """
Distributed under the MIT License. See LICENSE.txt for more info.
"""
import json
import uuid
from ..utility.display_names import (
OPEN_DATA,
SIMULATED_DATA,
BINARY_BLACK_HOLE,
DYNESTY,
NESTLE,
EMCEE,
FIXED,
UNIFORM,
SKIP,
SUBMITTED,
QUEUED,
IN_PROGRESS,
DRAFT,... | 33.880597 | 114 | 0.602423 |
89287107bf8b41baf6a2e18560e187efeb94ad6b | 574 | py | Python | activities/migrations/0003_alter_currentactivitie_importance_level.py | CiganOliviu/MyWorkflow | 85951c2e8ebdb3e970fcc0b3e24bd319360b852a | [
"Apache-2.0"
] | null | null | null | activities/migrations/0003_alter_currentactivitie_importance_level.py | CiganOliviu/MyWorkflow | 85951c2e8ebdb3e970fcc0b3e24bd319360b852a | [
"Apache-2.0"
] | null | null | null | activities/migrations/0003_alter_currentactivitie_importance_level.py | CiganOliviu/MyWorkflow | 85951c2e8ebdb3e970fcc0b3e24bd319360b852a | [
"Apache-2.0"
] | null | null | null | # Generated by Django 3.2.5 on 2021-07-04 19:36
from django.db import migrations, models
| 30.210526 | 194 | 0.642857 |
8928910327e7aadda89a6e0cb4b8070d90c7134b | 1,209 | py | Python | src/collector/wechat/wechat_utils.py | AI-xiaofour/2c | 4aa40eb18868ea5eccf7b09b7e64939fb505a58c | [
"Apache-2.0"
] | null | null | null | src/collector/wechat/wechat_utils.py | AI-xiaofour/2c | 4aa40eb18868ea5eccf7b09b7e64939fb505a58c | [
"Apache-2.0"
] | null | null | null | src/collector/wechat/wechat_utils.py | AI-xiaofour/2c | 4aa40eb18868ea5eccf7b09b7e64939fb505a58c | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
"""
Created by howie.hu at 2021/4/9.
Description
Changelog: all notable changes to this file will be documented
"""
from ruia import Request
from src.config import Config
from src.databases import MongodbManager
def wechat2url(name_list: list):
"""
wechat-feeds url
:p... | 27.477273 | 88 | 0.682382 |
892b0a91946a1df7a1b4680a474c70df84c8c932 | 857 | py | Python | tests/v2/test_team_response_attributes.py | anbnyc/datadog-api-client-python | 162bd0c6f2523a809aec08a3197e85dc74b78c21 | [
"Apache-2.0"
] | null | null | null | tests/v2/test_team_response_attributes.py | anbnyc/datadog-api-client-python | 162bd0c6f2523a809aec08a3197e85dc74b78c21 | [
"Apache-2.0"
] | null | null | null | tests/v2/test_team_response_attributes.py | anbnyc/datadog-api-client-python | 162bd0c6f2523a809aec08a3197e85dc74b78c21 | [
"Apache-2.0"
] | null | null | null | # coding: utf-8
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
# This product includes software developed at Datadog (https://www.datadoghq.com/).
# Copyright 2019-Present Datadog, Inc.
import sys
import unittest
import datadog_api_client.v2
from datadog... | 25.969697 | 108 | 0.733956 |
892b69c07a92d99e6dd2a8d72d712a862b76cd1f | 442 | py | Python | tests/unit/test_utility_item.py | luiscape/hdxscraper-worldpop | a94ea98d62645a0f2f508f227a642e7168e7281a | [
"MIT"
] | null | null | null | tests/unit/test_utility_item.py | luiscape/hdxscraper-worldpop | a94ea98d62645a0f2f508f227a642e7168e7281a | [
"MIT"
] | 2 | 2016-03-08T15:36:27.000Z | 2016-03-08T15:36:52.000Z | tests/unit/test_utility_item.py | luiscape/hdxscraper-worldpop | a94ea98d62645a0f2f508f227a642e7168e7281a | [
"MIT"
] | null | null | null | #!/usr/bin/python
# -*- coding: utf-8 -*-
'''
Unit tests for the item() utility function.
'''
import unittest
from collector.utilities.item import item
| 21.047619 | 66 | 0.678733 |
892b8c8a1447b39b4b49a43ec0b4a891164798d6 | 1,696 | py | Python | open/core/scripts/writeup_profile_prompt_generate_view.py | awesome-archive/open | 12fb6267c7d1a7e1f1c08f6112073bb0739e7ed9 | [
"MIT"
] | 105 | 2019-06-01T08:34:47.000Z | 2022-03-15T11:48:36.000Z | open/core/scripts/writeup_profile_prompt_generate_view.py | awesome-archive/open | 12fb6267c7d1a7e1f1c08f6112073bb0739e7ed9 | [
"MIT"
] | 111 | 2019-06-04T15:34:14.000Z | 2022-03-12T21:03:20.000Z | open/core/scripts/writeup_profile_prompt_generate_view.py | awesome-archive/open | 12fb6267c7d1a7e1f1c08f6112073bb0739e7ed9 | [
"MIT"
] | 26 | 2019-09-04T06:06:12.000Z | 2022-01-03T03:40:11.000Z | # flake8: noqa
import json
import time
import requests
from django.conf import settings
from websocket import create_connection
from open.core.scripts.swarm_ml_services import get_random_prompt
from open.core.writeup.constants import TEXT_GENERATION_URL
"""
this script's design was to compare performance behind djan... | 28.266667 | 103 | 0.723467 |
892bb5ac486bc86c9bf63c89f4326c4ac07e5e22 | 1,031 | py | Python | utils/whatsthespotprice.py | New-Zealand-Zero/PowerMaker | df1866a838cb4b0bd1629417bf5f5111f60f1cff | [
"Apache-2.0"
] | null | null | null | utils/whatsthespotprice.py | New-Zealand-Zero/PowerMaker | df1866a838cb4b0bd1629417bf5f5111f60f1cff | [
"Apache-2.0"
] | null | null | null | utils/whatsthespotprice.py | New-Zealand-Zero/PowerMaker | df1866a838cb4b0bd1629417bf5f5111f60f1cff | [
"Apache-2.0"
] | 2 | 2021-12-14T01:01:20.000Z | 2021-12-21T07:48:50.000Z | import http.client, urllib.request, urllib.parse, urllib.error, base64, time, json, ast, datetime, math, keys
import logging
logging.basicConfig(filename='io.log', level=logging.INFO, format='%(asctime)s %(message)s')
headers = {
# Request headers
'Ocp-Apim-Subscription-Key': keys.OCP_APIM_SUBSCRIPTION_KEY,
... | 29.457143 | 109 | 0.653734 |
892d73c842c7dab435a1f0f69bb5c20db75d44dd | 518 | py | Python | gen/argo/events/client/__about__.py | argoproj-labs/argo-events-client-python | 3d6e3dffca4a12a490c2963f4ac90c8894948bb5 | [
"Apache-2.0"
] | null | null | null | gen/argo/events/client/__about__.py | argoproj-labs/argo-events-client-python | 3d6e3dffca4a12a490c2963f4ac90c8894948bb5 | [
"Apache-2.0"
] | null | null | null | gen/argo/events/client/__about__.py | argoproj-labs/argo-events-client-python | 3d6e3dffca4a12a490c2963f4ac90c8894948bb5 | [
"Apache-2.0"
] | null | null | null | """About this package."""
__all__ = [
"__title__",
"__summary__",
"__uri__",
"__version__",
"__author__",
"__email__",
"__license__",
"__copyright__",
]
__title__ = "argo-events"
__summary__ = "Community Maintained Python client for Argo Events"
__uri__ = "https://github.com/argoproj-l... | 20.72 | 70 | 0.685328 |
892ea50cc3da67caa05d44561bab96944c809088 | 2,465 | py | Python | mfctracker/management/commands/syncusers.py | kevans91/mfctracker | c86f1538229df126081331edef3bfd19c9ef1345 | [
"BSD-2-Clause"
] | 3 | 2016-10-19T05:01:31.000Z | 2019-06-06T18:20:11.000Z | mfctracker/management/commands/syncusers.py | kevans91/mfctracker | c86f1538229df126081331edef3bfd19c9ef1345 | [
"BSD-2-Clause"
] | 3 | 2017-11-28T17:31:58.000Z | 2021-04-12T02:37:27.000Z | mfctracker/management/commands/syncusers.py | kevans91/mfctracker | c86f1538229df126081331edef3bfd19c9ef1345 | [
"BSD-2-Clause"
] | 1 | 2020-06-26T14:05:53.000Z | 2020-06-26T14:05:53.000Z | # Copyright (c) 2016-2019 Oleksandr Tymoshenko <gonzo@bluezbox.com>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
# 1. Redistributions of source code must retain the above copyright
# ... | 52.446809 | 108 | 0.723732 |
892ff412cb0abfd15e5fd8375b604f4b8bd19d90 | 399 | py | Python | Exercises/015.py | GuilhermeRds1921/Python3-Guanabara | 24cd85b076e1074a5602e54c420bcc8e70cc1854 | [
"MIT"
] | null | null | null | Exercises/015.py | GuilhermeRds1921/Python3-Guanabara | 24cd85b076e1074a5602e54c420bcc8e70cc1854 | [
"MIT"
] | null | null | null | Exercises/015.py | GuilhermeRds1921/Python3-Guanabara | 24cd85b076e1074a5602e54c420bcc8e70cc1854 | [
"MIT"
] | null | null | null | # Escreva um programa que pergunte a quantidade de Km
# percorridos por um carro alugado e a quantidade de dias pelos
# quais ele foi alugado. Calcule o preo a pagar, sabendo que o carro
# custa R$60 por dia e R$0.15 por Km rodado.
km = float(input("Quantos km percorreu?: "))
dia = int(input("Quantos dias ele foi alug... | 49.875 | 69 | 0.704261 |
893019fb8b63370b0487a73ea074042709b31d91 | 3,241 | py | Python | utils/make_package.py | j123123/llilc | 9d6a522deb6b0769e449f27a087a9d3a7ab2a255 | [
"MIT"
] | 1,712 | 2015-04-13T22:16:59.000Z | 2022-03-17T18:44:42.000Z | utils/make_package.py | j123123/llilc | 9d6a522deb6b0769e449f27a087a9d3a7ab2a255 | [
"MIT"
] | 770 | 2015-04-13T22:10:20.000Z | 2022-03-15T01:30:06.000Z | utils/make_package.py | j123123/llilc | 9d6a522deb6b0769e449f27a087a9d3a7ab2a255 | [
"MIT"
] | 206 | 2015-04-13T22:17:19.000Z | 2022-02-19T12:30:19.000Z | #!/usr/bin/env python
import sys
import argparse
import os
import subprocess
import platform
import io
import string
try:
# For Python >= 3.0
from urllib.request import urlopen
except ImportError:
# For Python < 3.0
from urllib2 import urlopen
import shutil
import stat
if __name__ == "__main__":
re... | 30.575472 | 81 | 0.650108 |
8932628f1e0bc2d8c1fc917f3837c4fdac64e6f9 | 192 | py | Python | wireapp/wireapp/doctype/mpesa_payment/mpesa_payment.py | saleemdev/wireapp | 7d39d07391ddad23539cfdf38369082f708d7294 | [
"MIT"
] | null | null | null | wireapp/wireapp/doctype/mpesa_payment/mpesa_payment.py | saleemdev/wireapp | 7d39d07391ddad23539cfdf38369082f708d7294 | [
"MIT"
] | null | null | null | wireapp/wireapp/doctype/mpesa_payment/mpesa_payment.py | saleemdev/wireapp | 7d39d07391ddad23539cfdf38369082f708d7294 | [
"MIT"
] | null | null | null | # Copyright (c) 2021, Salim and contributors
# For license information, please see license.txt
# import frappe
from frappe.model.document import Document
| 21.333333 | 49 | 0.791667 |
8932d8f09ea333a4cd978f80748034ddb383b8b6 | 3,292 | py | Python | Adventure Game.py | CodeMaster7000/Adventure-Game | 7ec5e39315f342d7a4cf442caa1b0c0947bb51b6 | [
"MIT"
] | null | null | null | Adventure Game.py | CodeMaster7000/Adventure-Game | 7ec5e39315f342d7a4cf442caa1b0c0947bb51b6 | [
"MIT"
] | null | null | null | Adventure Game.py | CodeMaster7000/Adventure-Game | 7ec5e39315f342d7a4cf442caa1b0c0947bb51b6 | [
"MIT"
] | null | null | null | import time
import random
main()
| 43.315789 | 156 | 0.526428 |
89333b9df818e24672d6ad9bcfb169b6126774e6 | 2,081 | py | Python | jcpdstools/view/mainwidget.py | SHDShim/JCPDSTools | 4a4c1bd22a3f71c3285b5877d5d22b2702b7550c | [
"Apache-2.0"
] | 3 | 2020-08-06T09:26:00.000Z | 2021-08-10T14:13:58.000Z | jcpdstools/view/mainwidget.py | SHDShim/JCPDSTools | 4a4c1bd22a3f71c3285b5877d5d22b2702b7550c | [
"Apache-2.0"
] | null | null | null | jcpdstools/view/mainwidget.py | SHDShim/JCPDSTools | 4a4c1bd22a3f71c3285b5877d5d22b2702b7550c | [
"Apache-2.0"
] | null | null | null | import os
from PyQt5 import QtWidgets
from .qtd import Ui_MainWindow
from version import __version__
from utils import SpinBoxFixStyle
| 42.469388 | 81 | 0.739068 |
8933583a90eda099c254b38c7fb555a1d3d870bb | 4,622 | py | Python | tests/unit_tests/test_tethys_services/test_admin.py | msouff/tethys | 45795d1e6561d5db8fddd838f4d1ae1d91dbb837 | [
"BSD-2-Clause"
] | 79 | 2015-10-05T13:13:28.000Z | 2022-02-01T12:30:33.000Z | tests/unit_tests/test_tethys_services/test_admin.py | msouff/tethys | 45795d1e6561d5db8fddd838f4d1ae1d91dbb837 | [
"BSD-2-Clause"
] | 542 | 2015-08-12T22:11:32.000Z | 2022-03-29T22:18:08.000Z | tests/unit_tests/test_tethys_services/test_admin.py | msouff/tethys | 45795d1e6561d5db8fddd838f4d1ae1d91dbb837 | [
"BSD-2-Clause"
] | 71 | 2016-01-16T01:03:41.000Z | 2022-03-31T17:55:54.000Z | import unittest
from unittest import mock
from django.utils.translation import ugettext_lazy as _
from tethys_services.models import DatasetService, SpatialDatasetService, WebProcessingService, PersistentStoreService
from tethys_services.admin import DatasetServiceForm, SpatialDatasetServiceForm, WebProcessingServiceF... | 43.603774 | 118 | 0.720251 |
8933611dccd35f84e21b95c6ea6cb9c0aef59e5b | 633 | py | Python | Codefights/arcade/intro/level-6/25.Array-Replace/Python/test.py | RevansChen/online-judge | ad1b07fee7bd3c49418becccda904e17505f3018 | [
"MIT"
] | 7 | 2017-09-20T16:40:39.000Z | 2021-08-31T18:15:08.000Z | Codefights/arcade/intro/level-6/25.Array-Replace/Python/test.py | RevansChen/online-judge | ad1b07fee7bd3c49418becccda904e17505f3018 | [
"MIT"
] | null | null | null | Codefights/arcade/intro/level-6/25.Array-Replace/Python/test.py | RevansChen/online-judge | ad1b07fee7bd3c49418becccda904e17505f3018 | [
"MIT"
] | null | null | null | # Python3
from solution1 import arrayReplace as f
qa = [
([1, 2, 1], 1, 3,
[3, 2, 3]),
([1, 2, 3, 4, 5], 3, 0,
[1, 2, 0, 4, 5]),
([1, 1, 1], 1, 10,
[10, 10, 10]),
([1, 2, 1, 2, 1], 2, 1,
[1, 1, 1, 1, 1]),
([1, 2, 1, 2, 1], 2, 2,
[1, 2, 1, 2, 1]),
([3, 1], 3, 9,
[9... | 19.78125 | 47 | 0.366509 |
8934d1367807f17b7ccddc78c329f89fdb3334b2 | 8,563 | py | Python | tests/inception/test_inception_hardware_perf.py | ispras/avatar2 | 5bab7239c368cc69d4f63d5fbb724808a6aa87b6 | [
"Apache-2.0"
] | 415 | 2017-06-14T07:49:50.000Z | 2022-03-31T12:32:58.000Z | tests/inception/test_inception_hardware_perf.py | HexHive/avatar2 | b406c3512f6bcf6f7635c6bd70a5951bde9ae0a2 | [
"Apache-2.0"
] | 58 | 2017-06-16T14:51:12.000Z | 2022-03-25T14:13:32.000Z | tests/inception/test_inception_hardware_perf.py | HexHive/avatar2 | b406c3512f6bcf6f7635c6bd70a5951bde9ae0a2 | [
"Apache-2.0"
] | 101 | 2017-06-16T09:05:12.000Z | 2022-03-23T12:23:19.000Z | from avatar2 import *
import sys
import os
import logging
import serial
import time
import argparse
import pyudev
import struct
import ctypes
from random import randint
# For profiling
import pstats
logging.basicConfig(filename='/tmp/inception-tests.log', level=logging.INFO)
# ************************************... | 33.84585 | 172 | 0.552727 |
893500b28f3f57e96f65fa9b86818c48a291c5c0 | 1,164 | py | Python | tianshou/env/worker/dummy.py | Leeqh666/tianshou | f71db624bee67b6170caaa06b0d3f68901b87985 | [
"MIT"
] | null | null | null | tianshou/env/worker/dummy.py | Leeqh666/tianshou | f71db624bee67b6170caaa06b0d3f68901b87985 | [
"MIT"
] | null | null | null | tianshou/env/worker/dummy.py | Leeqh666/tianshou | f71db624bee67b6170caaa06b0d3f68901b87985 | [
"MIT"
] | null | null | null | import gym
import numpy as np
from typing import List, Callable, Optional, Any
from tianshou.env.worker import EnvWorker
| 29.1 | 73 | 0.631443 |
89352fbdd1b631cd689cfa66c662c5a6306871c6 | 6,687 | py | Python | beartype/_decor/conf.py | posita/beartype | e56399686e1f2ffd5128a4030b19314504e32450 | [
"MIT"
] | null | null | null | beartype/_decor/conf.py | posita/beartype | e56399686e1f2ffd5128a4030b19314504e32450 | [
"MIT"
] | null | null | null | beartype/_decor/conf.py | posita/beartype | e56399686e1f2ffd5128a4030b19314504e32450 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# --------------------( LICENSE )--------------------
# Copyright (c) 2014-2021 Beartype authors.
# See "LICENSE" for further details.
'''
**Beartype decorator configuration API** (i.e., enumerations, classes,
singletons, and other attributes enabling external callers t... | 46.117241 | 79 | 0.686257 |
89386b743e51694854f66d61583124c986f918df | 349 | py | Python | 001-099/38/38.py | lunixbochs/project-euler | aa974c5ae68547309f33adbb4e633fe040964855 | [
"MIT"
] | 6 | 2015-07-21T20:45:08.000Z | 2021-03-13T14:07:48.000Z | 001-099/38/38.py | lunixbochs/project-euler | aa974c5ae68547309f33adbb4e633fe040964855 | [
"MIT"
] | null | null | null | 001-099/38/38.py | lunixbochs/project-euler | aa974c5ae68547309f33adbb4e633fe040964855 | [
"MIT"
] | 2 | 2017-10-28T09:52:08.000Z | 2019-04-11T00:55:36.000Z | ref = set('123456789')
m = 0
for i in xrange(2, 1000000000):
for z, n in pans(i):
if n > m:
m = n
print z, i, n
| 17.45 | 41 | 0.383954 |
89390457453d455098d6d865b97a3debbac7c065 | 43 | py | Python | sugaroid/version.py | blackxspade/sugaroid | 64e2031c1b432e6647b15f59120879c7e1b9f8f8 | [
"MIT"
] | null | null | null | sugaroid/version.py | blackxspade/sugaroid | 64e2031c1b432e6647b15f59120879c7e1b9f8f8 | [
"MIT"
] | null | null | null | sugaroid/version.py | blackxspade/sugaroid | 64e2031c1b432e6647b15f59120879c7e1b9f8f8 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
VERSION = "v0.22.0"
| 14.333333 | 22 | 0.651163 |
893a18910761a8b9355e949965665e778b901cd2 | 187 | py | Python | nixnet/_session/__init__.py | ni-ldp/nixnet-python | 83f30c5b44098de0dc4828838e263b7be0866228 | [
"MIT"
] | 16 | 2017-06-14T19:44:45.000Z | 2022-02-06T15:14:52.000Z | nixnet/_session/__init__.py | ni-ldp/nixnet-python | 83f30c5b44098de0dc4828838e263b7be0866228 | [
"MIT"
] | 216 | 2017-06-15T16:41:10.000Z | 2021-09-23T23:00:50.000Z | nixnet/_session/__init__.py | ni-ldp/nixnet-python | 83f30c5b44098de0dc4828838e263b7be0866228 | [
"MIT"
] | 23 | 2017-06-14T22:51:08.000Z | 2022-03-03T03:04:40.000Z | from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import typing # NOQA: F401
__all__ = [] # type: typing.List[typing.Text]
| 23.375 | 46 | 0.791444 |
893b8dc20ad6ef7ad20e4051cafdb423c6e82129 | 11,196 | py | Python | hedweb/services.py | hed-standard/hed-web | 8603526266dff78cf07e49e6c0f0c715a9225289 | [
"MIT"
] | null | null | null | hedweb/services.py | hed-standard/hed-web | 8603526266dff78cf07e49e6c0f0c715a9225289 | [
"MIT"
] | null | null | null | hedweb/services.py | hed-standard/hed-web | 8603526266dff78cf07e49e6c0f0c715a9225289 | [
"MIT"
] | 2 | 2022-02-04T19:55:40.000Z | 2022-02-04T21:36:04.000Z | import os
import io
import json
from flask import current_app
from hed import models
from hed.errors import HedFileError
from hed import schema as hedschema
from hedweb.constants import base_constants
from hedweb import events, spreadsheet, sidecar, strings
app_config = current_app.config
def get_inpu... | 41.620818 | 115 | 0.681761 |
893d5a4482f292937557682d8715ef74cab055df | 563 | py | Python | Python/easy/e395.py | tlgs/dailyprogrammer | 6e7d3352616fa54a8e9caf8564a9cfb951eb0af9 | [
"Unlicense"
] | 4 | 2017-10-18T02:17:02.000Z | 2022-02-02T01:19:02.000Z | Python/easy/e395.py | tlseabra/dailyprogrammer | 6e7d3352616fa54a8e9caf8564a9cfb951eb0af9 | [
"Unlicense"
] | 4 | 2016-01-24T20:30:02.000Z | 2017-01-18T16:01:23.000Z | Python/easy/e395.py | tlgs/dailyprogrammer | 6e7d3352616fa54a8e9caf8564a9cfb951eb0af9 | [
"Unlicense"
] | null | null | null | # 22/06/2021
import itertools
assert nonogramrow([]) == []
assert nonogramrow([0, 0, 0, 0, 0]) == []
assert nonogramrow([1, 1, 1, 1, 1]) == [5]
assert nonogramrow([0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1]) == [5, 4]
assert nonogramrow([1, 1, 0, 1, 0, 0, 1, 1, 1, 0, 0]) == [2, 1, 3]
assert nonogramrow([0, 0, 0, 0, 1, 1, 0, 0... | 22.52 | 72 | 0.488455 |
893f8bb01e7634c61b028bca09870c81605af91c | 2,191 | py | Python | paura_lite.py | 777AVY777/Clone_paura | 415bb323e31040154d331ba582617841ef909f64 | [
"MIT"
] | 191 | 2016-09-04T23:27:58.000Z | 2022-03-01T07:08:02.000Z | paura_lite.py | 777AVY777/Clone_paura | 415bb323e31040154d331ba582617841ef909f64 | [
"MIT"
] | 9 | 2017-07-06T14:13:55.000Z | 2021-06-06T12:55:07.000Z | paura_lite.py | 777AVY777/Clone_paura | 415bb323e31040154d331ba582617841ef909f64 | [
"MIT"
] | 42 | 2016-11-15T06:16:13.000Z | 2021-08-11T03:46:45.000Z | # paura_lite:
# An ultra-simple command-line audio recorder with real-time
# spectrogram visualization
import numpy as np
import pyaudio
import struct
import scipy.fftpack as scp
import termplotlib as tpl
import os
# get window's dimensions
rows, columns = os.popen('stty size', 'r').read().split()
buff_size = 0.2 ... | 37.135593 | 73 | 0.671839 |
8940f390419a60889fc99a07fdf4b127ea3f0da6 | 3,398 | py | Python | dataviva/apps/map/views.py | joelvisroman/dataviva-site | b4219558457746fd5c6b8f4b65b04c738c656fbd | [
"MIT"
] | 126 | 2015-03-24T12:30:43.000Z | 2022-01-06T03:29:54.000Z | dataviva/apps/map/views.py | joelvisroman/dataviva-site | b4219558457746fd5c6b8f4b65b04c738c656fbd | [
"MIT"
] | 694 | 2015-01-14T11:55:28.000Z | 2021-02-08T20:23:11.000Z | dataviva/apps/map/views.py | joelvisroman/dataviva-site | b4219558457746fd5c6b8f4b65b04c738c656fbd | [
"MIT"
] | 52 | 2015-06-19T01:54:56.000Z | 2019-09-23T13:10:46.000Z | # -*- coding: utf-8 -*-
from flask import Blueprint, render_template, g, request, make_response
from dataviva.apps.general.views import get_locale
from dataviva.translations.dictionary import dictionary
from dataviva import datavivadir
from config import GZIP_DATA
from dataviva.utils.cached_query import cached_qu... | 31.174312 | 72 | 0.58093 |
89414998e5a7ff84331d610b6b9cc51dadd75709 | 6,364 | py | Python | TransfertFichier.py | Fabien034/TimeLaps | a9fcbdfd6551cf8c12961adeef15dfdfaad8fb3c | [
"CC0-1.0"
] | null | null | null | TransfertFichier.py | Fabien034/TimeLaps | a9fcbdfd6551cf8c12961adeef15dfdfaad8fb3c | [
"CC0-1.0"
] | null | null | null | TransfertFichier.py | Fabien034/TimeLaps | a9fcbdfd6551cf8c12961adeef15dfdfaad8fb3c | [
"CC0-1.0"
] | null | null | null | # !/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright: Fabien Rosso
# Version 0.1.1 - 19 Avril 2016
# Version 0.1.2 - 29 Avril 2016
## Debug VisualStudio
# import ptvsd
# ptvsd.enable_attach(None)
from __future__ import unicode_literals
from __future__ import print_function
import os
import sy... | 36.574713 | 138 | 0.61675 |
89418edd3c2fb8634084937401da418c6baab778 | 388 | py | Python | posts/urls.py | xXcoronaXx/Dblog | 56ee1b8f6f74fabbe0e081921e6cff092661e8df | [
"MIT"
] | null | null | null | posts/urls.py | xXcoronaXx/Dblog | 56ee1b8f6f74fabbe0e081921e6cff092661e8df | [
"MIT"
] | null | null | null | posts/urls.py | xXcoronaXx/Dblog | 56ee1b8f6f74fabbe0e081921e6cff092661e8df | [
"MIT"
] | null | null | null | from django.conf.urls import include, url
urlpatterns = [
url(r'^admin/(?P<slug>[\w\-]+)/', 'posts.views.post_preview', name='post_preview'),
url(r'^tag/(?P<slug>[\w\-]+)/', 'posts.views.posts_view_tag', name='posts_tag'),
url(r'^popular/', 'posts.views.posts_view_popular', name='posts_popular'),
url(r... | 48.5 | 87 | 0.634021 |
8941caffd99fa97347e96be2cc0144b6388f9d9c | 14,320 | py | Python | Basic_if_then/movement.py | BH4/Halite3-bots | 97eb4dcab6bccbfd1649bbac74ef06f0e22035de | [
"MIT"
] | null | null | null | Basic_if_then/movement.py | BH4/Halite3-bots | 97eb4dcab6bccbfd1649bbac74ef06f0e22035de | [
"MIT"
] | null | null | null | Basic_if_then/movement.py | BH4/Halite3-bots | 97eb4dcab6bccbfd1649bbac74ef06f0e22035de | [
"MIT"
] | null | null | null | from hlt.positionals import Position, Direction
from hlt import constants
import random
import logging
# Import my stuff
import helpers
| 37.098446 | 134 | 0.615573 |
8942b3f4142fb4752d39c8c79839362babc520e3 | 2,569 | py | Python | Bert/regressor.py | RohithYogi/Funniness-in-News-Headlines | db6755b4fa66f3aa827b235751cd49f707c321bc | [
"MIT"
] | null | null | null | Bert/regressor.py | RohithYogi/Funniness-in-News-Headlines | db6755b4fa66f3aa827b235751cd49f707c321bc | [
"MIT"
] | null | null | null | Bert/regressor.py | RohithYogi/Funniness-in-News-Headlines | db6755b4fa66f3aa827b235751cd49f707c321bc | [
"MIT"
] | null | null | null | from sklearn.ensemble import RandomForestRegressor, GradientBoostingRegressor
from sklearn.svm import SVR
from sklearn.metrics import mean_squared_error
from sklearn.linear_model import HuberRegressor
import numpy as np
import pickle
from dataloader import HeadlineDataset
from csv import writer
import os, subprocess
im... | 26.760417 | 100 | 0.673803 |
8942f14789d57a93ee819d488c307294d017124c | 108 | py | Python | examples/blogprj/urls.py | pimentech/django-mongoforms | 6220e91e05d73a26e495460f98667e23dc16c5f6 | [
"BSD-3-Clause"
] | 1 | 2017-07-27T05:44:47.000Z | 2017-07-27T05:44:47.000Z | examples/blogprj/urls.py | pimentech/django-mongoforms | 6220e91e05d73a26e495460f98667e23dc16c5f6 | [
"BSD-3-Clause"
] | null | null | null | examples/blogprj/urls.py | pimentech/django-mongoforms | 6220e91e05d73a26e495460f98667e23dc16c5f6 | [
"BSD-3-Clause"
] | null | null | null | from django.conf.urls.defaults import *
urlpatterns = patterns('',
(r'^', include('apps.blog.urls')),
) | 21.6 | 39 | 0.657407 |
894431402e6b83e572b12cd14d0e6138af1aab09 | 2,285 | py | Python | recursive_categories.py | singulart/wikiwalks | 674f4f8ada699619ed52a95eb0a8bd8b8eb093c7 | [
"MIT"
] | null | null | null | recursive_categories.py | singulart/wikiwalks | 674f4f8ada699619ed52a95eb0a8bd8b8eb093c7 | [
"MIT"
] | null | null | null | recursive_categories.py | singulart/wikiwalks | 674f4f8ada699619ed52a95eb0a8bd8b8eb093c7 | [
"MIT"
] | null | null | null | import wikipediaapi
import os
import json
import progressbar
CATEGORY = 'Category:Feminist artists'
#CATEGORY = 'Category:Contemporary artists'
unique_artists = set()
processed_categories = load_categories()
if processed_categories:
print('Loaded %d processed categories' % (len(list(processed_categories))))
else... | 33.115942 | 149 | 0.653392 |
894560d68f6fed0a38a05e50cb3d569b69bc6ff3 | 730 | py | Python | tests/test_handlers/test_yamlHandler/test_yamlHandler.py | UCHIC/ODMStreamingDataLoader | 711886167a068754efff6dfbd604e3e19e545253 | [
"BSD-3-Clause"
] | null | null | null | tests/test_handlers/test_yamlHandler/test_yamlHandler.py | UCHIC/ODMStreamingDataLoader | 711886167a068754efff6dfbd604e3e19e545253 | [
"BSD-3-Clause"
] | null | null | null | tests/test_handlers/test_yamlHandler/test_yamlHandler.py | UCHIC/ODMStreamingDataLoader | 711886167a068754efff6dfbd604e3e19e545253 | [
"BSD-3-Clause"
] | null | null | null | from os import getcwd
from os.path import join
from src.handlers.yamlHandler import YAMLHandler
from tests.test_utils import returnFiles
__author__ = 'jmeline'
| 25.172414 | 84 | 0.663014 |
89497af5999c47772bcb8017e9ebdd35c45a92b6 | 1,031 | py | Python | samples/donut.py | stoneskin/python-minecraft | 29051b8626620245ff54fc4d8ab1278d60d3a1ca | [
"MIT"
] | 7 | 2020-05-26T04:20:15.000Z | 2022-03-09T06:33:20.000Z | samples/donut.py | stoneskin/python-minecraft | 29051b8626620245ff54fc4d8ab1278d60d3a1ca | [
"MIT"
] | 1 | 2020-05-17T18:15:59.000Z | 2020-05-17T21:22:03.000Z | samples/donut.py | stoneskin/python-minecraft | 29051b8626620245ff54fc4d8ab1278d60d3a1ca | [
"MIT"
] | 1 | 2021-12-14T00:14:11.000Z | 2021-12-14T00:14:11.000Z | from mcpi_e.minecraft import Minecraft
from mcpi_e import block
from time import sleep
from random import *
from math import *
serverAddress="server" # change to your minecraft server
playerName ="stoneskin"
pythonApiPort=4712
mc=Minecraft.create(serverAddress,pythonApiPort,playerName)
playerPos=mc.... | 34.366667 | 84 | 0.642095 |
894a5fed9ddf654ea364f9de215cbb93bd3168ae | 582 | py | Python | britecoreproject/orm.py | alis0nc/britecore-project | aa31eb1f87c1c250f8bca9d9aa109eeae1232b9b | [
"MIT"
] | null | null | null | britecoreproject/orm.py | alis0nc/britecore-project | aa31eb1f87c1c250f8bca9d9aa109eeae1232b9b | [
"MIT"
] | 1 | 2018-02-13T00:34:22.000Z | 2018-02-13T00:34:22.000Z | britecoreproject/orm.py | alis0nc/britecore-project | aa31eb1f87c1c250f8bca9d9aa109eeae1232b9b | [
"MIT"
] | null | null | null | """
Define ORM classes.
"""
from sqlobject import *
def create_tables():
"""Create tables in database."""
RiskType.createTable()
Field.createTable()
FieldType.createTable()
| 22.384615 | 39 | 0.671821 |
894b00993b1f21de2137b7f78408f37441e40edc | 16,178 | py | Python | plumbum.py | maxnasonov/cloudwatch-to-graphite | c7eecda02cb3476616b397e4d1699de39e2728dd | [
"Apache-2.0"
] | null | null | null | plumbum.py | maxnasonov/cloudwatch-to-graphite | c7eecda02cb3476616b397e4d1699de39e2728dd | [
"Apache-2.0"
] | null | null | null | plumbum.py | maxnasonov/cloudwatch-to-graphite | c7eecda02cb3476616b397e4d1699de39e2728dd | [
"Apache-2.0"
] | null | null | null | # -*- coding: UTF-8 -*-
"""
Usage:
plumbum <template> <namespace> [region] [options]...
Options:
template path to the jinja2 template
namespace AWS namespace. Currently supports: elasticache, elb, ec2, rds, asg, sqs
region AWS region [default: us-east-1]
options key value combinations, they can be ... | 36.111607 | 135 | 0.701261 |
894dd8d8e0b0dd429807b917fe2e70454c198af1 | 10,440 | py | Python | fixtures/aerl/fabfile.py | bbengfort/honu | 3bfbf6a1959ec60a1e120a287f84996fa333757c | [
"MIT"
] | 2 | 2018-05-28T18:27:35.000Z | 2020-10-07T10:12:38.000Z | fixtures/aerl/fabfile.py | bbengfort/honu | 3bfbf6a1959ec60a1e120a287f84996fa333757c | [
"MIT"
] | 3 | 2021-10-05T00:37:26.000Z | 2021-10-05T01:53:00.000Z | fixtures/aerl/fabfile.py | bbengfort/honu | 3bfbf6a1959ec60a1e120a287f84996fa333757c | [
"MIT"
] | null | null | null | # fabfile
# Fabric command definitions for running anti-entropy reinforcement learning.
#
# Author: Benjamin Bengfort <benjamin@bengfort.com>
# Created: Tue Jun 13 22:26:00 2017 -0400
#
# Copyright (C) 2017 Bengfort.com
# For license information, see LICENSE.txt
#
# ID: fabfile.py [] benjamin@bengfort.com $
"""
Fab... | 26.034913 | 81 | 0.561782 |
894e84bd7eebee8f3642ef1949280cffa18756ab | 2,275 | py | Python | python/657.robot-return-to-origin.py | Zhenye-Na/leetcode | 95196a45f5709ccf7b970ee5ac84a4bf8fe2301e | [
"MIT"
] | 10 | 2019-09-15T00:23:57.000Z | 2022-01-05T12:53:42.000Z | python/657.robot-return-to-origin.py | Zhenye-Na/leetcode | 95196a45f5709ccf7b970ee5ac84a4bf8fe2301e | [
"MIT"
] | 3 | 2021-06-30T00:39:26.000Z | 2021-08-01T07:13:59.000Z | python/657.robot-return-to-origin.py | Zhenye-Na/leetcode | 95196a45f5709ccf7b970ee5ac84a4bf8fe2301e | [
"MIT"
] | 6 | 2020-02-08T02:55:22.000Z | 2022-01-02T22:48:18.000Z | #
# @lc app=leetcode id=657 lang=python3
#
# [657] Robot Return to Origin
#
# https://leetcode.com/problems/robot-return-to-origin/description/
#
# algorithms
# Easy (73.67%)
# Likes: 1228
# Dislikes: 692
# Total Accepted: 274.1K
# Total Submissions: 371K
# Testcase Example: '"UD"'
#
# There is a robot starting ... | 24.202128 | 79 | 0.607033 |
894f30ac75460bc645b7f7aa2b1775bd8ac09220 | 2,171 | py | Python | src/python/pants/backend/swift/goals/tailor.py | danxmoran/pants | 7fafd7d789747c9e6a266847a0ccce92c3fa0754 | [
"Apache-2.0"
] | null | null | null | src/python/pants/backend/swift/goals/tailor.py | danxmoran/pants | 7fafd7d789747c9e6a266847a0ccce92c3fa0754 | [
"Apache-2.0"
] | null | null | null | src/python/pants/backend/swift/goals/tailor.py | danxmoran/pants | 7fafd7d789747c9e6a266847a0ccce92c3fa0754 | [
"Apache-2.0"
] | null | null | null | # Copyright 2022 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
from __future__ import annotations
from dataclasses import dataclass
from typing import Iterable
from pants.backend.swift.target_types import SWIFT_FILE_EXTENSIONS, SwiftSourcesGenerator... | 33.921875 | 95 | 0.748042 |
894fdf877d94231d589d47daadc64f279fa8f303 | 1,059 | py | Python | WP5/KU/SharedResources/get_incrementer.py | MONICA-Project/sfn | 40509e520e83441068b5a2d151864fe3a5814d5e | [
"Apache-2.0"
] | 1 | 2021-10-05T08:00:42.000Z | 2021-10-05T08:00:42.000Z | WP5/KU/SharedResources/get_incrementer.py | MONICA-Project/sfn | 40509e520e83441068b5a2d151864fe3a5814d5e | [
"Apache-2.0"
] | 10 | 2020-03-31T07:49:14.000Z | 2022-03-12T00:17:51.000Z | WP5/KU/SharedResources/get_incrementer.py | MONICA-Project/sfn | 40509e520e83441068b5a2d151864fe3a5814d5e | [
"Apache-2.0"
] | 1 | 2021-10-05T07:59:18.000Z | 2021-10-05T07:59:18.000Z | # get_incrementer.py
"""Helper function to create counter strings with a set length throughout."""
__version__ = '0.2'
__author__ = 'Rob Dupre (KU)'
| 24.627907 | 77 | 0.558074 |
89506cba8d48107a96bebd4fb53108e48e413e52 | 179 | py | Python | Curso_Coursera/Ex1_ParImpar.py | shirleyguimaraes/Linguagem_Python | cb8b871ee4fe85f803c35bfe55ce533cab8150fb | [
"MIT"
] | null | null | null | Curso_Coursera/Ex1_ParImpar.py | shirleyguimaraes/Linguagem_Python | cb8b871ee4fe85f803c35bfe55ce533cab8150fb | [
"MIT"
] | null | null | null | Curso_Coursera/Ex1_ParImpar.py | shirleyguimaraes/Linguagem_Python | cb8b871ee4fe85f803c35bfe55ce533cab8150fb | [
"MIT"
] | null | null | null |
main()
| 11.933333 | 49 | 0.435754 |
89528b5ef79fc793c901837f37deed12889d7c14 | 536 | py | Python | pyro/contrib/oed/__init__.py | cweniger/pyro | ba104f07ca17865d2600e8765d920d549fcb3fbc | [
"MIT"
] | 10 | 2020-03-18T14:41:25.000Z | 2021-07-04T08:49:57.000Z | pyro/contrib/oed/__init__.py | cweniger/pyro | ba104f07ca17865d2600e8765d920d549fcb3fbc | [
"MIT"
] | 19 | 2018-10-30T13:45:31.000Z | 2019-09-27T14:16:57.000Z | pyro/contrib/oed/__init__.py | cweniger/pyro | ba104f07ca17865d2600e8765d920d549fcb3fbc | [
"MIT"
] | 5 | 2020-06-21T23:40:35.000Z | 2021-11-09T16:18:42.000Z | """
The :mod:`pyro.contrib.oed` module provides tools to create optimal experiment
designs for pyro models. In particular, it provides estimators for the
expected information gain (EIG) criterion.
To estimate the EIG for a particular design, use::
def model(design):
...
# Select an appropriate EIG es... | 23.304348 | 78 | 0.701493 |
8953849e85ab59dfe4d9f0bc0daf7168cfaa9806 | 311 | py | Python | tests/serve/test_metadata.py | outerbounds/tempo | 0878ae32ed6163a1c5115f20167d991a28535364 | [
"Apache-2.0"
] | 75 | 2021-02-15T09:49:02.000Z | 2022-03-31T02:06:38.000Z | tests/serve/test_metadata.py | outerbounds/tempo | 0878ae32ed6163a1c5115f20167d991a28535364 | [
"Apache-2.0"
] | 106 | 2021-02-13T09:25:19.000Z | 2022-03-25T16:18:00.000Z | tests/serve/test_metadata.py | outerbounds/tempo | 0878ae32ed6163a1c5115f20167d991a28535364 | [
"Apache-2.0"
] | 21 | 2021-02-12T17:12:50.000Z | 2022-03-04T02:09:26.000Z | import pytest
from tempo.serve.metadata import KubernetesRuntimeOptions
| 19.4375 | 57 | 0.655949 |
895431e6e79bcf654061cac0d31efed8ab34ab25 | 323 | py | Python | referral/faker_factories.py | exolever/django-earlyparrot | 031b7f2d67e1e78d525f85ae10e82d4cc0c198f3 | [
"MIT"
] | null | null | null | referral/faker_factories.py | exolever/django-earlyparrot | 031b7f2d67e1e78d525f85ae10e82d4cc0c198f3 | [
"MIT"
] | 7 | 2019-09-04T10:59:39.000Z | 2019-12-12T22:16:25.000Z | referral/faker_factories.py | exolever/django-earlyparrot | 031b7f2d67e1e78d525f85ae10e82d4cc0c198f3 | [
"MIT"
] | null | null | null | import factory
from faker import Faker
from referral.models import Campaign
faker = Faker()
| 19 | 63 | 0.739938 |
89543e9c996717e15aa0e3c4f48041c92613b895 | 3,703 | py | Python | main.py | djlafferty7/itlookslikedanlaffertyoutside | fc98a4c42911d364c72317abdb9fc96abd70b8b2 | [
"Apache-2.0"
] | null | null | null | main.py | djlafferty7/itlookslikedanlaffertyoutside | fc98a4c42911d364c72317abdb9fc96abd70b8b2 | [
"Apache-2.0"
] | null | null | null | main.py | djlafferty7/itlookslikedanlaffertyoutside | fc98a4c42911d364c72317abdb9fc96abd70b8b2 | [
"Apache-2.0"
] | null | null | null | import json
import requests
import time
from flask import Flask, render_template, request
app = Flask(__name__)
API_KEY='<insert_api_key_here>'
#funstion to set parameters
def setParams():
weather = getWeather()
background, style = getBackground(weather)
condition = weather['weather'][0]['description']
... | 35.266667 | 96 | 0.676479 |
8955852e7532c9fcb8b74321bae9283af152725a | 2,587 | py | Python | meta/dice.py | dkkim93/meta-mapg | 98d4d1be3f5fd628b42e451bed99004f02f553d0 | [
"MIT"
] | 15 | 2021-06-09T09:56:37.000Z | 2022-02-27T18:56:33.000Z | meta/dice.py | dkkim93/meta-mapg | 98d4d1be3f5fd628b42e451bed99004f02f553d0 | [
"MIT"
] | 1 | 2021-11-17T07:38:30.000Z | 2021-11-29T15:27:46.000Z | meta/dice.py | dkkim93/meta-mapg | 98d4d1be3f5fd628b42e451bed99004f02f553d0 | [
"MIT"
] | 2 | 2021-09-14T07:26:25.000Z | 2021-10-03T04:09:24.000Z | import torch
def magic_box(x):
"""DiCE operation that saves computation graph inside tensor
See ``Implementation of DiCE'' section in the DiCE Paper for details
Args:
x (tensor): Input tensor
Returns:
1 (tensor): Tensor that has computation graph saved
References:
https://g... | 41.063492 | 106 | 0.688829 |
8956a32ea669342323a0da4e15ade20f0c7f1b66 | 91 | py | Python | src/coreapis/apps.py | salemzii/ChopFast | 95ea88387ecfdb56bd643970b69425b1a1c6f388 | [
"MIT"
] | null | null | null | src/coreapis/apps.py | salemzii/ChopFast | 95ea88387ecfdb56bd643970b69425b1a1c6f388 | [
"MIT"
] | null | null | null | src/coreapis/apps.py | salemzii/ChopFast | 95ea88387ecfdb56bd643970b69425b1a1c6f388 | [
"MIT"
] | null | null | null | from django.apps import AppConfig
| 15.166667 | 33 | 0.758242 |
895976c032c7db9f729336aff5e0279c9a266299 | 274 | py | Python | project/opendata/parse.py | FelippeJC/besa | 083e62457c9c9beccc869beb89675720be0d248a | [
"MIT"
] | null | null | null | project/opendata/parse.py | FelippeJC/besa | 083e62457c9c9beccc869beb89675720be0d248a | [
"MIT"
] | 2 | 2021-05-10T16:40:12.000Z | 2021-09-05T09:26:07.000Z | project/opendata/parse.py | FelippeJC/besa | 083e62457c9c9beccc869beb89675720be0d248a | [
"MIT"
] | null | null | null | from .request import datastore_search
def get_data_from_datastore(expression):
"""Returns a list of records found in a datastore search"""
response = datastore_search(expression)
result = response.get("result", dict())
return result.get("records", dict())
| 30.444444 | 63 | 0.729927 |
8959f2b49b675b763760dbc29357913d9e63369d | 1,486 | py | Python | dynamicserialize/dstypes/gov/noaa/nws/ncep/common/dataplugin/gempak/request/Station.py | mjames-upc/python-awips | e2b05f5587b02761df3b6dd5c6ee1f196bd5f11c | [
"BSD-3-Clause"
] | null | null | null | dynamicserialize/dstypes/gov/noaa/nws/ncep/common/dataplugin/gempak/request/Station.py | mjames-upc/python-awips | e2b05f5587b02761df3b6dd5c6ee1f196bd5f11c | [
"BSD-3-Clause"
] | null | null | null | dynamicserialize/dstypes/gov/noaa/nws/ncep/common/dataplugin/gempak/request/Station.py | mjames-upc/python-awips | e2b05f5587b02761df3b6dd5c6ee1f196bd5f11c | [
"BSD-3-Clause"
] | null | null | null |
# File auto-generated against equivalent DynamicSerialize Java class
#
# SOFTWARE HISTORY
#
# Date Ticket# Engineer Description
# ------------ ---------- ----------- --------------------------
# Sep 16, 2016 pmoyer Generated
import numpy
| 22.861538 | 77 | 0.588156 |
895aafff76fa0567fe017a820fa38e5c27392a87 | 4,051 | py | Python | gghc/dbcluster.py | opengauss-mirror/openGauss-housekeeper | 6f741efe182ebd5da792faac16534823beb45d20 | [
"MulanPSL-1.0"
] | null | null | null | gghc/dbcluster.py | opengauss-mirror/openGauss-housekeeper | 6f741efe182ebd5da792faac16534823beb45d20 | [
"MulanPSL-1.0"
] | null | null | null | gghc/dbcluster.py | opengauss-mirror/openGauss-housekeeper | 6f741efe182ebd5da792faac16534823beb45d20 | [
"MulanPSL-1.0"
] | null | null | null | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# dbcluster.py
# GGHC cluster class
# Copyright (c) 2021 Chinasoft International Co., Ltd.
#
# gghc is licensed under Mulan PSL v2.
# You can use this software according to the terms
# and conditions of the Mulan PSL v2.
# You may obtain a copy of Mulan PSL v2 at:
#
... | 28.328671 | 96 | 0.534189 |
895af3a6b4f4978f67e07a5374ce2c7a074ba071 | 36,892 | py | Python | ProjectFiles/bin/Release/2.80/scripts/addons_contrib/io_directx_bel/import_x.py | BlazesRus/Bforartists | 126bdd9e47cc984fd97ba5299bfb92ec5278e754 | [
"Naumen",
"Condor-1.1",
"MS-PL"
] | 1 | 2019-07-08T15:51:14.000Z | 2019-07-08T15:51:14.000Z | ProjectFiles/bin/Release/2.80/scripts/addons_contrib/io_directx_bel/import_x.py | BlazesRus/Bforartists | 126bdd9e47cc984fd97ba5299bfb92ec5278e754 | [
"Naumen",
"Condor-1.1",
"MS-PL"
] | null | null | null | ProjectFiles/bin/Release/2.80/scripts/addons_contrib/io_directx_bel/import_x.py | BlazesRus/Bforartists | 126bdd9e47cc984fd97ba5299bfb92ec5278e754 | [
"Naumen",
"Condor-1.1",
"MS-PL"
] | null | null | null | # Blender directX importer
# version baby
# litterature explaining the parser directions :
# I don't want to load the whole file as it can be huge : go chunks
# also I want random access to 3d datas to import pieces, not always everything
# so step1 is a whole file fast parsing, retrieving tokens name and building en... | 37.993821 | 150 | 0.497235 |
895c1ad530c40f1c5d1fb2b8ed674dd74150a4b7 | 49 | py | Python | urduhack/utils/tests/test_text.py | fahdrazavi/urduhack | a2370b0d8c1ee3f260ff90ca5056f45ed9b73ee8 | [
"MIT"
] | null | null | null | urduhack/utils/tests/test_text.py | fahdrazavi/urduhack | a2370b0d8c1ee3f260ff90ca5056f45ed9b73ee8 | [
"MIT"
] | null | null | null | urduhack/utils/tests/test_text.py | fahdrazavi/urduhack | a2370b0d8c1ee3f260ff90ca5056f45ed9b73ee8 | [
"MIT"
] | null | null | null | # coding: utf8
"""Test cases for text.py file"""
| 16.333333 | 33 | 0.653061 |
895c60b9edfa055022804d7ee382f90d6f53e6ab | 1,987 | py | Python | tag_generation/preprocesing.py | krispingal/improved-happiness | 1113e19065fee08a2530bf1fb1d4b2f888155f77 | [
"BSD-3-Clause"
] | null | null | null | tag_generation/preprocesing.py | krispingal/improved-happiness | 1113e19065fee08a2530bf1fb1d4b2f888155f77 | [
"BSD-3-Clause"
] | null | null | null | tag_generation/preprocesing.py | krispingal/improved-happiness | 1113e19065fee08a2530bf1fb1d4b2f888155f77 | [
"BSD-3-Clause"
] | null | null | null | """Preprocessing for tag generation"""
from tag_generation.util import utils
import jsonlines
import csv
# For test
FILE_LOC = '/home/krispin/data/improved-happiness/'
# For dev
#FILE_LOC = '/home/krispin/data/improved-happiness/proto/'
skipped, wrote = 0, 0
if __name__ == '__main__':
main(k=10) | 34.859649 | 99 | 0.613488 |
895c87f9120184e4c7af4de57a702b500aeade12 | 8,263 | py | Python | CDS_GRF/env/wrapper_grf_3vs3.py | ltzheng/CDS | 397282147498647a9f26577adfa451e8478de76d | [
"Apache-2.0"
] | 1 | 2021-06-19T23:57:55.000Z | 2021-06-19T23:57:55.000Z | CDS_GRF/env/wrapper_grf_3vs3.py | ltzheng/CDS | 397282147498647a9f26577adfa451e8478de76d | [
"Apache-2.0"
] | null | null | null | CDS_GRF/env/wrapper_grf_3vs3.py | ltzheng/CDS | 397282147498647a9f26577adfa451e8478de76d | [
"Apache-2.0"
] | null | null | null | import gfootball.env as football_env
from gfootball.env import observation_preprocessing
import gym
import numpy as np
import matplotlib.pyplot as plt
# def make_football_env(seed_dir, dump_freq=1000, representation='extracted', render=False):
def make_football_env_3vs3(dense_reward=False, dump_freq=1000):
'''
... | 37.38914 | 135 | 0.61491 |
895ceb1226f1223073e975c0eb48dfda8072b8fb | 2,136 | py | Python | performance_test/testcase.py | DeqingQu/CacheControlHelper | d9425ff08253f10ef1028b724418c705f8d58bf5 | [
"MIT"
] | null | null | null | performance_test/testcase.py | DeqingQu/CacheControlHelper | d9425ff08253f10ef1028b724418c705f8d58bf5 | [
"MIT"
] | null | null | null | performance_test/testcase.py | DeqingQu/CacheControlHelper | d9425ff08253f10ef1028b724418c705f8d58bf5 | [
"MIT"
] | null | null | null | from cache_control_helper import CacheControlHelper
import time
import sys
import requests
import requests_cache
requests_cache.install_cache('performance_test')
if __name__ == '__main__':
# using CacheControl
# base_url = 'http://localhost:3000/test/'
# t = time.time()
# for i in range(100000)... | 28.48 | 86 | 0.598315 |
895d00024c1c457aa98a15e9b661a4e74c3e68a2 | 1,731 | py | Python | main.py | nimom38/Bangla-letter-frequency-statistics | 7121f7fe36f9e8f5c310d4cc3b49083977dc8ce6 | [
"MIT"
] | null | null | null | main.py | nimom38/Bangla-letter-frequency-statistics | 7121f7fe36f9e8f5c310d4cc3b49083977dc8ce6 | [
"MIT"
] | null | null | null | main.py | nimom38/Bangla-letter-frequency-statistics | 7121f7fe36f9e8f5c310d4cc3b49083977dc8ce6 | [
"MIT"
] | null | null | null | import matplotlib.font_manager as fm
import matplotlib.pyplot as plt
import matplotlib.font_manager as fm
import numpy as np
freq = {}
if __name__ == "__main__":
main()
| 27.47619 | 103 | 0.658579 |