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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
a047d0ac5a16d636bbec804560bb56282540b1b2 | 13,172 | py | Python | remit/settings.py | naamara/blink | 326c035b2f0ef0feae4cd7aa2d4e73fa4a40171a | [
"Unlicense",
"MIT"
] | null | null | null | remit/settings.py | naamara/blink | 326c035b2f0ef0feae4cd7aa2d4e73fa4a40171a | [
"Unlicense",
"MIT"
] | 10 | 2019-12-26T17:31:31.000Z | 2022-03-21T22:17:33.000Z | remit/settings.py | naamara/blink | 326c035b2f0ef0feae4cd7aa2d4e73fa4a40171a | [
"Unlicense",
"MIT"
] | null | null | null | ''' settings for Django '''
import os
import django.conf.global_settings as DEFAULT_SETTINGS
LOCALHOST = False
DEBUG = False
TEMPLATE_DEBUG = DEBUG
DEBUG_PAYMENTS = DEBUG
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
BASE_DIR = os.path.abspath(
os.path.join(os.path.dirname(__file__), os.... | 24.994307 | 109 | 0.719708 |
a04c74859e147b481962d7389a2144e8a4b8236e | 1,151 | py | Python | tests/integration/test_issue_1447.py | alexey-tereshenkov-oxb/pex | 2e2d1e50e604fdee48b0d51aea482ca255521ff0 | [
"Apache-2.0"
] | 2,160 | 2015-01-06T17:57:39.000Z | 2022-03-30T19:59:01.000Z | tests/integration/test_issue_1447.py | alexey-tereshenkov-oxb/pex | 2e2d1e50e604fdee48b0d51aea482ca255521ff0 | [
"Apache-2.0"
] | 1,242 | 2015-01-22T14:56:46.000Z | 2022-03-31T18:02:38.000Z | tests/integration/test_issue_1447.py | Satertek/pex | 64de1c4cf031118ef446ac98a8c164c91c23bb9b | [
"Apache-2.0"
] | 248 | 2015-01-15T13:34:50.000Z | 2022-03-26T01:24:18.000Z | # Copyright 2021 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
import os
import shutil
import subprocess
import sys
from pex.pex_info import PexInfo
from pex.testing import run_pex_command
from pex.typing import TYPE_CHECKING
from pex.variables import... | 29.512821 | 85 | 0.730669 |
a04cf7b68b006d07caae20b361bd4e847b1b78eb | 13,900 | py | Python | tests/gfp.py | mcepl/git-packaging-tools | de705a9ac2efd1752754e4feb093fe85821f9224 | [
"MIT"
] | 8 | 2017-08-15T12:51:34.000Z | 2020-10-07T09:58:34.000Z | tests/gfp.py | mcepl/git-packaging-tools | de705a9ac2efd1752754e4feb093fe85821f9224 | [
"MIT"
] | 5 | 2017-02-04T12:32:16.000Z | 2020-07-01T14:13:19.000Z | tests/gfp.py | mcepl/git-packaging-tools | de705a9ac2efd1752754e4feb093fe85821f9224 | [
"MIT"
] | 6 | 2017-02-07T13:31:21.000Z | 2021-02-10T23:14:03.000Z | #!/usr/bin/python3
#
# Copyright (c) 2017-2020, SUSE LLC
#
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# Redistributions of source code must retain the above copyright notice,
# this list ... | 36.197917 | 129 | 0.606475 |
a04efbad847960e56a6c9a8e43d4465164fb4801 | 5,455 | py | Python | modules/dispatch.py | kex5n/Vehicles-Dispatch-Simulator | d0cca03fbf56e4b0ceeef8dafc59de105c1d4507 | [
"MIT"
] | null | null | null | modules/dispatch.py | kex5n/Vehicles-Dispatch-Simulator | d0cca03fbf56e4b0ceeef8dafc59de105c1d4507 | [
"MIT"
] | null | null | null | modules/dispatch.py | kex5n/Vehicles-Dispatch-Simulator | d0cca03fbf56e4b0ceeef8dafc59de105c1d4507 | [
"MIT"
] | null | null | null | from dataclasses import dataclass
import random
from typing import List
import numpy as np
import torch
from config import Config
from domain import DispatchMode
from models import DQN
from modules.state import FeatureManager
from objects import Area, Vehicle
from objects.area import AreaManager
from objects.vehicle ... | 40.110294 | 148 | 0.700642 |
a04f7f2d5934d5148efee6d0cd9e612d55de51c8 | 4,716 | py | Python | dice_vtk/geometries/geometry_base.py | dicehub/dice_vtk | ab8d9f34ae359461db5687d05bf38548bbaca6ea | [
"MIT"
] | null | null | null | dice_vtk/geometries/geometry_base.py | dicehub/dice_vtk | ab8d9f34ae359461db5687d05bf38548bbaca6ea | [
"MIT"
] | null | null | null | dice_vtk/geometries/geometry_base.py | dicehub/dice_vtk | ab8d9f34ae359461db5687d05bf38548bbaca6ea | [
"MIT"
] | null | null | null | # Standard Python modules
# =======================
import weakref
from abc import ABCMeta, abstractmethod, abstractproperty
# External modules
# ================
from vtk import vtkActor
from vtk import vtkMapper
from vtk import vtkPolyDataAlgorithm
from vtk import vtkBoundingBox
# DICE modules
# ============
from d... | 23.117647 | 71 | 0.601569 |
a05379809d542906a1e8b3ecab8d346bf1a2d752 | 2,272 | py | Python | tests/integration/sts/replayer_integration_test.py | jhall11/sts | b484f184824c9fe59864103f24fdfa24ff8bcdcd | [
"Apache-2.0"
] | 5 | 2016-03-18T15:12:04.000Z | 2019-01-28T20:18:24.000Z | tests/integration/sts/replayer_integration_test.py | jhall11/sts | b484f184824c9fe59864103f24fdfa24ff8bcdcd | [
"Apache-2.0"
] | null | null | null | tests/integration/sts/replayer_integration_test.py | jhall11/sts | b484f184824c9fe59864103f24fdfa24ff8bcdcd | [
"Apache-2.0"
] | 1 | 2019-11-02T22:04:48.000Z | 2019-11-02T22:04:48.000Z | #!/usr/bin/env python
#
# Copyright 2011-2013 Colin Scott
#
# 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... | 33.910448 | 116 | 0.677377 |
a054dcd6697f8d246a99e2b87deb291ef103d4ce | 101 | py | Python | add.py | Harshillab/python | 877d5fa6769ce7bcc28ca75c247df42ed7375e55 | [
"MIT"
] | null | null | null | add.py | Harshillab/python | 877d5fa6769ce7bcc28ca75c247df42ed7375e55 | [
"MIT"
] | null | null | null | add.py | Harshillab/python | 877d5fa6769ce7bcc28ca75c247df42ed7375e55 | [
"MIT"
] | null | null | null | import os
a=input("enter username:")
if a.isalpha():
os.system("useradd "+a)
os.system("passwd a")
| 16.833333 | 26 | 0.673267 |
a055c0b6a8a397cfaf7bde8f028637510c8a76bc | 3,733 | py | Python | responsive_dashboard/views.py | rhooper/django-responsive-dashboard | 039d634cbefb87be610334c01bda1a790cf5cd71 | [
"BSD-3-Clause"
] | 28 | 2015-07-08T01:03:17.000Z | 2022-03-11T13:30:49.000Z | responsive_dashboard/views.py | burke-software/django-responsive-dashboard | e08d7a12155d87d78cb3928bcc58f2701d326b69 | [
"BSD-3-Clause"
] | 4 | 2018-09-03T14:15:42.000Z | 2021-06-10T17:24:09.000Z | responsive_dashboard/views.py | rhooper/django-responsive-dashboard | 039d634cbefb87be610334c01bda1a790cf5cd71 | [
"BSD-3-Clause"
] | 13 | 2015-01-15T14:33:30.000Z | 2021-08-23T02:39:38.000Z | """Views."""
from django.conf import settings
from django.contrib.auth.decorators import login_required
from django.http import HttpResponse, Http404
from django.shortcuts import render, redirect
from responsive_dashboard.dashboard import dashboards
from responsive_dashboard.models import UserDashboard, UserDashlet
... | 34.88785 | 114 | 0.698902 |
a05679a1770f12c767a08a09a8c1456749cc03d4 | 769 | py | Python | app/config.py | tomakado/markovscope-api | 3dd60439d980e3b77429850f1b43cb37ffd02f99 | [
"BSD-3-Clause"
] | 1 | 2021-03-06T06:36:25.000Z | 2021-03-06T06:36:25.000Z | app/config.py | tomakado/markovscope-api | 3dd60439d980e3b77429850f1b43cb37ffd02f99 | [
"BSD-3-Clause"
] | null | null | null | app/config.py | tomakado/markovscope-api | 3dd60439d980e3b77429850f1b43cb37ffd02f99 | [
"BSD-3-Clause"
] | null | null | null | import os
from dataclasses import dataclass
CONFIG = Config.create_from_env()
| 25.633333 | 80 | 0.595579 |
a0578bb9313ba5a000fe92b2495ddd4a94b1be7e | 15,486 | py | Python | atlas/atlas.py | pythseq/atlas | 6fd8d9e8ad05d234fc408aef8e0989da199f3b48 | [
"BSD-3-Clause"
] | 1 | 2020-12-31T14:54:49.000Z | 2020-12-31T14:54:49.000Z | atlas/atlas.py | pythseq/atlas | 6fd8d9e8ad05d234fc408aef8e0989da199f3b48 | [
"BSD-3-Clause"
] | null | null | null | atlas/atlas.py | pythseq/atlas | 6fd8d9e8ad05d234fc408aef8e0989da199f3b48 | [
"BSD-3-Clause"
] | null | null | null | import click
import logging
import multiprocessing
import os
import sys
from atlas import __version__
from atlas.conf import make_config
from atlas.parsers import refseq_parser
from atlas.tables import merge_tables
from atlas.workflows import download, run_workflow
logging.basicConfig(level=logging.INFO, datefmt="%Y-... | 54.336842 | 323 | 0.694692 |
a0590b43efec682503f6e281362973bb8f85de85 | 1,101 | py | Python | tests/unit/core/types/test_relationships.py | jeffsawatzky/python-jsonapi | 8f181d6764b525f58d06517c65b1f0d24f3c2282 | [
"MIT"
] | null | null | null | tests/unit/core/types/test_relationships.py | jeffsawatzky/python-jsonapi | 8f181d6764b525f58d06517c65b1f0d24f3c2282 | [
"MIT"
] | 237 | 2020-07-23T05:53:22.000Z | 2022-03-30T23:02:35.000Z | tests/unit/core/types/test_relationships.py | jeffsawatzky/python-jsonapi | 8f181d6764b525f58d06517c65b1f0d24f3c2282 | [
"MIT"
] | null | null | null | """Test cases for the python_jsonapi.core.types.relationships module."""
from python_jsonapi.core.types.relationships import Relationship
from python_jsonapi.core.types.relationships import RelationshipsMixin
def test_relationship_init() -> None:
"""Can init a new relationships."""
sut = Relationship()
as... | 34.40625 | 74 | 0.735695 |
a0595a142eaf248d183d94e735f0ba479dc117a7 | 48 | py | Python | needlestack/indices/__init__.py | needlehaystack/needlestack | e00529a2a7c2d85059936a85f54dfb55e515b6ef | [
"Apache-2.0"
] | 3 | 2019-10-03T22:15:21.000Z | 2022-02-08T09:05:41.000Z | needlestack/indices/__init__.py | cungtv/needlestack | e00529a2a7c2d85059936a85f54dfb55e515b6ef | [
"Apache-2.0"
] | 1 | 2021-04-30T21:08:47.000Z | 2021-04-30T21:08:47.000Z | needlestack/indices/__init__.py | cungtv/needlestack | e00529a2a7c2d85059936a85f54dfb55e515b6ef | [
"Apache-2.0"
] | 2 | 2019-08-02T19:13:09.000Z | 2019-10-25T01:47:17.000Z | from needlestack.indices.index import BaseIndex
| 24 | 47 | 0.875 |
a05a419a9ddf5084b706e695f35bb68b2e11e8f7 | 698 | py | Python | app/accounts/utilities.py | porowns/Krypted-Auth | ed171bfbd1c98a4c171ddf6a20b18691330b1646 | [
"MIT"
] | 6 | 2017-12-13T21:53:05.000Z | 2018-10-04T02:47:05.000Z | app/accounts/utilities.py | porowns/Krypted-Auth | ed171bfbd1c98a4c171ddf6a20b18691330b1646 | [
"MIT"
] | 106 | 2019-08-11T23:00:39.000Z | 2021-06-10T19:45:54.000Z | app/accounts/utilities.py | KryptedGaming/kryptedauth | ed171bfbd1c98a4c171ddf6a20b18691330b1646 | [
"MIT"
] | 10 | 2020-01-18T11:28:44.000Z | 2022-02-21T06:08:39.000Z | from django.conf import settings
from django.contrib.auth.models import User
from django.core.mail import send_mail
| 33.238095 | 123 | 0.684814 |
a05b0d63377d071367b35f0034a3b68acdab2c2d | 245 | py | Python | run/lemmatize.py | osmanbaskaya/mapping-impact | 8024dd3b916ac2dfc336221dd32faba4c0a98442 | [
"MIT"
] | 1 | 2016-03-14T15:28:22.000Z | 2016-03-14T15:28:22.000Z | run/lemmatize.py | osmanbaskaya/mapping-impact | 8024dd3b916ac2dfc336221dd32faba4c0a98442 | [
"MIT"
] | null | null | null | run/lemmatize.py | osmanbaskaya/mapping-impact | 8024dd3b916ac2dfc336221dd32faba4c0a98442 | [
"MIT"
] | null | null | null | #! /usr/bin/python
# -*- coding: utf-8 -*-
__author__ = "Osman Baskaya"
from nltk.stem.wordnet import WordNetLemmatizer
import sys
lmtzr = WordNetLemmatizer()
for line in sys.stdin:
print ' '.join(map(lmtzr.lemmatize, line.split()))
| 14.411765 | 54 | 0.689796 |
a05cc4dfec88f66003f8b833c676b2a3c02c79c3 | 4,066 | py | Python | markov.py | garybake/markov_lyrics | 816043acd849b77097aa5bd504b123c6b306b801 | [
"MIT"
] | null | null | null | markov.py | garybake/markov_lyrics | 816043acd849b77097aa5bd504b123c6b306b801 | [
"MIT"
] | null | null | null | markov.py | garybake/markov_lyrics | 816043acd849b77097aa5bd504b123c6b306b801 | [
"MIT"
] | null | null | null | # https://realpython.com/blog/python/lyricize-a-flask-app-to-create-lyrics-using-markov-chains/
from random import choice
import sys
text = "some sample text"
text = """
An old man turned ninety-eight
He won the lottery and died the next day
It's a black fly in your Chardonnay
It's a death row pardon two minutes too ... | 30.571429 | 175 | 0.734629 |
a05d8bd7f43816678e051cbb74ff64ee556b6710 | 1,545 | py | Python | curriculum_tools/curriculum_tools/NamedEnv.py | darpa-l2m/meta-arcade | 9c9539c1feef89e9d1d55507bf4f75c965a25038 | [
"MIT"
] | 2 | 2021-12-17T19:54:41.000Z | 2021-12-20T06:08:31.000Z | curriculum_tools/curriculum_tools/NamedEnv.py | darpa-l2m/meta-arcade | 9c9539c1feef89e9d1d55507bf4f75c965a25038 | [
"MIT"
] | 1 | 2021-12-17T20:45:07.000Z | 2021-12-21T16:30:24.000Z | curriculum_tools/curriculum_tools/NamedEnv.py | darpa-l2m/meta-arcade | 9c9539c1feef89e9d1d55507bf4f75c965a25038 | [
"MIT"
] | null | null | null | """
Copyright 2021 The Johns Hopkins University Applied Physics Laboratory LLC
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 us... | 33.586957 | 82 | 0.741748 |
a05f0813319812f0e9d30a1ddfef3dd56345c333 | 9,265 | py | Python | scirex/metrics/paired_bootstrap.py | viswavi/SciREX | 8e4b402e95d438c92eeecee315d389903a963b8d | [
"Apache-2.0"
] | null | null | null | scirex/metrics/paired_bootstrap.py | viswavi/SciREX | 8e4b402e95d438c92eeecee315d389903a963b8d | [
"Apache-2.0"
] | null | null | null | scirex/metrics/paired_bootstrap.py | viswavi/SciREX | 8e4b402e95d438c92eeecee315d389903a963b8d | [
"Apache-2.0"
] | null | null | null | # Adapted from Graham Neubig's Paired Bootstrap script
# https://github.com/neubig/util-scripts/blob/master/paired-bootstrap.py
import numpy as np
from sklearn.metrics import f1_score, precision_score, recall_score
from tqdm import tqdm
EVAL_TYPE_ACC = "acc"
EVAL_TYPE_BLEU = "bleu"
EVAL_TYPE_BLEU_DETOK = "bleu_detok"... | 40.814978 | 135 | 0.681705 |
a05f5a0fc89824667b995e5851cdb833729517df | 970 | py | Python | mypage/paginator.py | kirill-ivanov-a/mypage-flask | b803dfdf3d38d32879d81b8682d51e387c8f709f | [
"MIT"
] | null | null | null | mypage/paginator.py | kirill-ivanov-a/mypage-flask | b803dfdf3d38d32879d81b8682d51e387c8f709f | [
"MIT"
] | null | null | null | mypage/paginator.py | kirill-ivanov-a/mypage-flask | b803dfdf3d38d32879d81b8682d51e387c8f709f | [
"MIT"
] | null | null | null | from paginate_sqlalchemy import SqlalchemyOrmPage
| 34.642857 | 88 | 0.609278 |
a060c7c4400126644e1d48eb927d2de5fe556729 | 4,915 | py | Python | models/deeplab_v2.py | iamsofancyyoualreadyknow/IHC-based-labels-generation-and-semantic-segmentation-for-lung-cancer | 57904544c6d6b43dcd5937afeb474c0a47456d98 | [
"MIT"
] | null | null | null | models/deeplab_v2.py | iamsofancyyoualreadyknow/IHC-based-labels-generation-and-semantic-segmentation-for-lung-cancer | 57904544c6d6b43dcd5937afeb474c0a47456d98 | [
"MIT"
] | null | null | null | models/deeplab_v2.py | iamsofancyyoualreadyknow/IHC-based-labels-generation-and-semantic-segmentation-for-lung-cancer | 57904544c6d6b43dcd5937afeb474c0a47456d98 | [
"MIT"
] | null | null | null | import tensorflow as tf
# import slim
# conv layers
layers = tf.contrib.layers
arg_scope = tf.contrib.framework.arg_scope
| 56.494253 | 99 | 0.585554 |
a06437850e2dae1448abd64b704f6b42218ef386 | 968 | py | Python | Python/logging.py | saurabhcommand/Hello-world | 647bad9da901a52d455f05ecc37c6823c22dc77e | [
"MIT"
] | 1,428 | 2018-10-03T15:15:17.000Z | 2019-03-31T18:38:36.000Z | Python/logging.py | saurabhcommand/Hello-world | 647bad9da901a52d455f05ecc37c6823c22dc77e | [
"MIT"
] | 1,162 | 2018-10-03T15:05:49.000Z | 2018-10-18T14:17:52.000Z | Python/logging.py | saurabhcommand/Hello-world | 647bad9da901a52d455f05ecc37c6823c22dc77e | [
"MIT"
] | 3,909 | 2018-10-03T15:07:19.000Z | 2019-03-31T18:39:08.000Z | import datetime
# Log parm(File_name)
| 31.225806 | 86 | 0.572314 |
a064737d7eb5496d755ad0d39ca50e2c9279c4d9 | 10,541 | py | Python | tfep/utils/cli/tool.py | andrrizzi/tfep | a98ec870007a2ceb72cab147d9e0dfffb7dc8849 | [
"MIT"
] | 5 | 2021-07-30T16:01:46.000Z | 2021-12-14T15:24:29.000Z | tfep/utils/cli/tool.py | andrrizzi/tfep | a98ec870007a2ceb72cab147d9e0dfffb7dc8849 | [
"MIT"
] | 2 | 2021-08-13T12:19:13.000Z | 2021-10-06T08:04:18.000Z | tfep/utils/cli/tool.py | andrrizzi/tfep | a98ec870007a2ceb72cab147d9e0dfffb7dc8849 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# =============================================================================
# MODULE DOCSTRING
# =============================================================================
"""
Utility classes to wrap command line tools.
The module provides a class :class:`.CLITool` that provides boilerp... | 36.223368 | 103 | 0.626411 |
a06853a9eca27d640f292fe2b2ffaac04fbafad7 | 1,128 | py | Python | invite2app/lib/facebook_auth.py | andresgz/invite2app | 3531db131c4f0646ae01b511971d6642128361e0 | [
"BSD-3-Clause"
] | null | null | null | invite2app/lib/facebook_auth.py | andresgz/invite2app | 3531db131c4f0646ae01b511971d6642128361e0 | [
"BSD-3-Clause"
] | null | null | null | invite2app/lib/facebook_auth.py | andresgz/invite2app | 3531db131c4f0646ae01b511971d6642128361e0 | [
"BSD-3-Clause"
] | null | null | null | # -*- coding: utf-8 -*-
import facebook
from allauth.socialaccount.models import SocialToken
from django.core.exceptions import ObjectDoesNotExist
| 27.512195 | 71 | 0.638298 |
a068b901b478d011dc44a977f7e4cc0f17632eaf | 11,386 | py | Python | visualize_high_LOO/visualize_high_LOO_cifar_norb.py | mkuchnik/Efficient_Augmentation | a82190c02509682c34f2df782fb58f8ffd3b11da | [
"MIT"
] | 11 | 2019-05-09T22:43:29.000Z | 2021-01-13T22:26:48.000Z | visualize_high_LOO/visualize_high_LOO_cifar_norb.py | mkuchnik/Efficient_Augmentation | a82190c02509682c34f2df782fb58f8ffd3b11da | [
"MIT"
] | 1 | 2020-10-07T14:03:47.000Z | 2020-10-07T14:03:47.000Z | visualize_high_LOO/visualize_high_LOO_cifar_norb.py | mkuchnik/Efficient_Augmentation | a82190c02509682c34f2df782fb58f8ffd3b11da | [
"MIT"
] | 6 | 2019-03-05T02:26:01.000Z | 2021-05-11T14:35:41.000Z | import pprint
import time
import keras
import numpy as np
import joblib
import dataset_loaders
import selection_policy
import augmentations
import experiments
import experiments_util
import featurized_classifiers
import visualization_util
import matplotlib.pyplot as plt
mem = joblib.Memory(cachedir="./cache", verbo... | 36.031646 | 84 | 0.584138 |
a06ffffb39b0434296021e5eee8841761190d6b0 | 370 | py | Python | backend/main_app/serializers.py | RTUITLab/Avia-Hack-2021-RealityX | ca700492d314a28e23fa837cd2dfa04dd67c167c | [
"Apache-2.0"
] | null | null | null | backend/main_app/serializers.py | RTUITLab/Avia-Hack-2021-RealityX | ca700492d314a28e23fa837cd2dfa04dd67c167c | [
"Apache-2.0"
] | null | null | null | backend/main_app/serializers.py | RTUITLab/Avia-Hack-2021-RealityX | ca700492d314a28e23fa837cd2dfa04dd67c167c | [
"Apache-2.0"
] | null | null | null | from rest_framework import serializers
from .models import *
| 30.833333 | 125 | 0.672973 |
a0767541c421c26c6de084316db254c59c03c5d0 | 17,875 | py | Python | web_site/wx/lib.py | Fixdq/dj-deep | 6712a722c7f620b76f21b1ebf0b618f42eb4a58a | [
"MIT"
] | null | null | null | web_site/wx/lib.py | Fixdq/dj-deep | 6712a722c7f620b76f21b1ebf0b618f42eb4a58a | [
"MIT"
] | null | null | null | web_site/wx/lib.py | Fixdq/dj-deep | 6712a722c7f620b76f21b1ebf0b618f42eb4a58a | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on 2014-5-13
@author: skycrab
"""
import json
import time
import random
import string
import urllib
import hashlib
import threading
import traceback
import xml.etree.ElementTree as ET
import logging
from urllib import request as urllib2
from functools import wraps
from .config imp... | 38.690476 | 190 | 0.658238 |
a076da17c1234915c44f55110c45dfe832f020a4 | 4,723 | py | Python | argo_dsl/tasks.py | zen-xu/argo-dsl | 76b18073c8dd850b212ccaee2a0c95f718c67db6 | [
"Apache-2.0"
] | null | null | null | argo_dsl/tasks.py | zen-xu/argo-dsl | 76b18073c8dd850b212ccaee2a0c95f718c67db6 | [
"Apache-2.0"
] | null | null | null | argo_dsl/tasks.py | zen-xu/argo-dsl | 76b18073c8dd850b212ccaee2a0c95f718c67db6 | [
"Apache-2.0"
] | null | null | null | from __future__ import annotations
from contextlib import contextmanager
from typing import TYPE_CHECKING
from typing import Any
from typing import Callable
from typing import Dict
from typing import List
from typing import Optional
from typing import Union
from argo_dsl.api.io.argoproj.workflow import v1alpha1
if ... | 28.79878 | 106 | 0.645988 |
a07710f0bb90f929f1fc7e78cba178a4fc0fa117 | 1,007 | py | Python | tests/article_test.py | Kabu1/flashnews | 30852077c465ce828452125ec5e2b21115609c38 | [
"Unlicense"
] | null | null | null | tests/article_test.py | Kabu1/flashnews | 30852077c465ce828452125ec5e2b21115609c38 | [
"Unlicense"
] | null | null | null | tests/article_test.py | Kabu1/flashnews | 30852077c465ce828452125ec5e2b21115609c38 | [
"Unlicense"
] | null | null | null | import unittest
from app.models import Article
| 45.772727 | 569 | 0.715988 |
a0779d0acb5d0ce28e46508caa76d16adb915bd8 | 474 | py | Python | intern/conv_java_import.py | zaqwes8811/smart-vocabulary-cards | abeab5c86b1c6f68d8796475cba80c4f2c6055ff | [
"Apache-2.0"
] | null | null | null | intern/conv_java_import.py | zaqwes8811/smart-vocabulary-cards | abeab5c86b1c6f68d8796475cba80c4f2c6055ff | [
"Apache-2.0"
] | 11 | 2015-01-25T14:22:52.000Z | 2015-09-08T09:59:38.000Z | intern/conv_java_import.py | zaqwes8811/vocabulary-cards | abeab5c86b1c6f68d8796475cba80c4f2c6055ff | [
"Apache-2.0"
] | null | null | null | # coding: utf-8
'''
Created on 18.04.2013
@author:
'''
import dals.os_io.io_wrapper as dal
if __name__=='__main__':
sets = dal.get_utf8_template()
sets['name'] = 'test_import_to_jy.txt'
readed = dal.file2list(sets)
map(convert_one_line, readed)
print 'Done'
| 19.75 | 43 | 0.594937 |
a078916cfe94a2866d1c06904964969d62a237ec | 25 | py | Python | relatives/__init__.py | treyhunner/django-relatives | a578ab135f865df2835957cedfd00476c4b65e18 | [
"MIT"
] | 10 | 2015-08-14T00:22:52.000Z | 2021-09-16T08:15:14.000Z | relatives/__init__.py | treyhunner/django-relatives | a578ab135f865df2835957cedfd00476c4b65e18 | [
"MIT"
] | 12 | 2015-03-09T20:17:16.000Z | 2021-09-30T18:46:11.000Z | relatives/__init__.py | treyhunner/django-relatives | a578ab135f865df2835957cedfd00476c4b65e18 | [
"MIT"
] | 3 | 2016-01-05T15:20:10.000Z | 2018-08-03T10:51:23.000Z | __version__ = '1.3.0.a3'
| 12.5 | 24 | 0.64 |
a07a7419dbe104e7dbe0af27f725918587fdc9f2 | 4,596 | py | Python | handlers/class_handler.py | Hargre/faltometro-bot | 271772dc52c9d0454d96ef3c43e3a0da32075743 | [
"MIT"
] | null | null | null | handlers/class_handler.py | Hargre/faltometro-bot | 271772dc52c9d0454d96ef3c43e3a0da32075743 | [
"MIT"
] | 2 | 2019-04-02T13:18:23.000Z | 2019-04-11T14:00:06.000Z | handlers/class_handler.py | Hargre/faltometro-bot | 271772dc52c9d0454d96ef3c43e3a0da32075743 | [
"MIT"
] | null | null | null | import logging
import math
from emoji import emojize
from peewee import DoesNotExist
from telegram import ParseMode
from telegram.ext import CommandHandler
from telegram.ext import ConversationHandler
from telegram.ext import Filters
from telegram.ext import MessageHandler
from telegram.ext import RegexHandler
from... | 27.035294 | 110 | 0.647302 |
a07ca3f53342a4c5c568050fc58fa24424a4bf96 | 1,137 | py | Python | jupyter/aBasic/a_datatype_class/Ex01_valuable.py | WoolinChoi/test | a0f9c8ecc63443acaae61d744eecec6c943d3a26 | [
"MIT"
] | null | null | null | jupyter/aBasic/a_datatype_class/Ex01_valuable.py | WoolinChoi/test | a0f9c8ecc63443acaae61d744eecec6c943d3a26 | [
"MIT"
] | 1 | 2021-03-30T09:01:47.000Z | 2021-03-30T09:01:47.000Z | jupyter/aBasic/a_datatype_class/Ex01_valuable.py | WoolinChoi/test | a0f9c8ecc63443acaae61d744eecec6c943d3a26 | [
"MIT"
] | 1 | 2019-12-06T18:21:10.000Z | 2019-12-06T18:21:10.000Z | """
-
`
` ,
` ,
[]
[] Run shift + alt + F10
[] ctrl + q
"""
""" """
#
# print("")
# print('hello')
# print("""""")
# print('''''')
# : ctrl + shift + F10
# '' "" .
'''
a = 7
7 a. ( )
... | 15.364865 | 50 | 0.504837 |
a07d57857f23110458e28cf9b4145b1716e6f940 | 2,502 | py | Python | convert.py | povle/SP-SR2-converter | 7a675204e15b340deac2b98634805cdf75e6fd4a | [
"MIT"
] | 3 | 2021-01-09T20:11:31.000Z | 2022-03-31T02:05:52.000Z | convert.py | povle/SP-SR2-converter | 7a675204e15b340deac2b98634805cdf75e6fd4a | [
"MIT"
] | null | null | null | convert.py | povle/SP-SR2-converter | 7a675204e15b340deac2b98634805cdf75e6fd4a | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
import argparse
import sys
import io
import os.path
import shutil
import requests
from convert_file import convert_file
from gooey import Gooey, GooeyParser
if len(sys.argv) >= 2:
if '--ignore-gooey' not in sys.argv:
sys.argv.append('--ignore-gooey')
if __name__ == '__main__':
... | 43.137931 | 133 | 0.688649 |
a07db8162c85985e5fa4859871927e9c03a5f877 | 5,289 | py | Python | bsd2/vagrant-ansible/ansible/lib/ansible/runner/action_plugins/fetch.py | dlab-berkeley/collaboratool-archive | fa474e05737f78e628d6b9398c58cf7c966a7bba | [
"Apache-2.0"
] | 1 | 2016-01-20T14:36:02.000Z | 2016-01-20T14:36:02.000Z | bsd2/vagrant-ansible/ansible/lib/ansible/runner/action_plugins/fetch.py | dlab-berkeley/collaboratool-archive | fa474e05737f78e628d6b9398c58cf7c966a7bba | [
"Apache-2.0"
] | null | null | null | bsd2/vagrant-ansible/ansible/lib/ansible/runner/action_plugins/fetch.py | dlab-berkeley/collaboratool-archive | fa474e05737f78e628d6b9398c58cf7c966a7bba | [
"Apache-2.0"
] | null | null | null | # (c) 2012, Michael DeHaan <michael.dehaan@gmail.com>
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any lat... | 42.653226 | 135 | 0.626962 |
a07ebd61f61d120e3815b7fb4a6cf2eeafd36431 | 4,563 | py | Python | src/plot_by_genome.py | MaaT-Pharma/AMBER | 76aa10e2295265b16337b7bfab769d67d3bea66a | [
"Apache-2.0"
] | null | null | null | src/plot_by_genome.py | MaaT-Pharma/AMBER | 76aa10e2295265b16337b7bfab769d67d3bea66a | [
"Apache-2.0"
] | null | null | null | src/plot_by_genome.py | MaaT-Pharma/AMBER | 76aa10e2295265b16337b7bfab769d67d3bea66a | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
import argparse
import os
import sys
import matplotlib
import numpy as np
matplotlib.use('Agg')
import matplotlib.pyplot as plt
import os, sys, inspect
currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
parentdir = os.path.dirname(currentdir)
sys.path.insert(... | 38.669492 | 153 | 0.67368 |
a080d1b200263a36cd31a3e857bf790cbd1e3259 | 16,548 | py | Python | tests/test_references.py | isprojects/djangorestframework-inclusions | c6669f404a8a80f2c524a8adfb6548b2eef235c7 | [
"MIT"
] | null | null | null | tests/test_references.py | isprojects/djangorestframework-inclusions | c6669f404a8a80f2c524a8adfb6548b2eef235c7 | [
"MIT"
] | 4 | 2019-11-15T10:21:20.000Z | 2021-04-22T13:37:32.000Z | tests/test_references.py | isprojects/djangorestframework-inclusions | c6669f404a8a80f2c524a8adfb6548b2eef235c7 | [
"MIT"
] | null | null | null | from django.urls import reverse
from rest_framework.test import APITestCase
from testapp.models import (
A,
B,
C,
Child,
ChildProps,
Container,
Entry,
MainObject,
Parent,
Tag,
)
from .mixins import InclusionsMixin
| 32.383562 | 87 | 0.435098 |
a08113f70d1b07cff7761da1bc92b7750832a572 | 1,508 | py | Python | q2_fondue/get_all.py | misialq/q2-fondue | a7a541ee017381b34d38ef766de39d5d62588465 | [
"BSD-3-Clause"
] | 10 | 2022-03-21T16:07:22.000Z | 2022-03-31T09:33:48.000Z | q2_fondue/get_all.py | misialq/q2-fondue | a7a541ee017381b34d38ef766de39d5d62588465 | [
"BSD-3-Clause"
] | null | null | null | q2_fondue/get_all.py | misialq/q2-fondue | a7a541ee017381b34d38ef766de39d5d62588465 | [
"BSD-3-Clause"
] | 4 | 2022-03-21T06:51:44.000Z | 2022-03-29T15:56:14.000Z | # ----------------------------------------------------------------------------
# Copyright (c) 2022, Bokulich Laboratories.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file LICENSE, distributed with this software.
# --------------------------------------------------------... | 32.085106 | 78 | 0.657825 |
a08175a3e80e168fe04fe33684d0de9087ed3e33 | 2,652 | py | Python | markups/restructuredtext.py | LukeC8/pymarkups | eec6edbc870fc6fe50c56d30f3caa8b8ee4e239a | [
"BSD-3-Clause"
] | null | null | null | markups/restructuredtext.py | LukeC8/pymarkups | eec6edbc870fc6fe50c56d30f3caa8b8ee4e239a | [
"BSD-3-Clause"
] | null | null | null | markups/restructuredtext.py | LukeC8/pymarkups | eec6edbc870fc6fe50c56d30f3caa8b8ee4e239a | [
"BSD-3-Clause"
] | null | null | null | # vim: ts=8:sts=8:sw=8:noexpandtab
# This file is part of python-markups module
# License: 3-clause BSD, see LICENSE file
# Copyright: (C) Dmitry Shachnev, 2012-2018
import markups.common as common
from markups.abstract import AbstractMarkup, ConvertedMarkup
| 30.837209 | 99 | 0.735294 |
a0827c33ad3c6db021a834ac073ebf6c9ba882a7 | 8,025 | py | Python | Intelligent Systems and Decision Support Systems/pm-test1.py | johnpras/Uni_work | 1edd8fd56e4d54cdcc0058f0a21799ef6015e3f6 | [
"MIT"
] | null | null | null | Intelligent Systems and Decision Support Systems/pm-test1.py | johnpras/Uni_work | 1edd8fd56e4d54cdcc0058f0a21799ef6015e3f6 | [
"MIT"
] | null | null | null | Intelligent Systems and Decision Support Systems/pm-test1.py | johnpras/Uni_work | 1edd8fd56e4d54cdcc0058f0a21799ef6015e3f6 | [
"MIT"
] | null | null | null | import pandas as pd
from pm4py.objects.log.importer.xes import importer as xes_import
from pm4py.objects.log.util import log as utils
from pm4py.statistics.start_activities.log.get import get_start_activities
from pm4py.statistics.end_activities.log.get import get_end_activities
from pm4py.algo.filtering.log.end_a... | 42.68617 | 102 | 0.761994 |
a083ee0517e616b51836bbd85b01482cd453d3cf | 9,480 | py | Python | utils/job_placement/nonuniformRandom/routers.py | scalability-llnl/damselfly | 394e39b3165388e262a90da415dc3338d0f44734 | [
"BSD-Source-Code",
"BSD-3-Clause-LBNL",
"FSFAP"
] | 5 | 2016-02-25T04:50:00.000Z | 2020-06-11T03:00:45.000Z | utils/job_placement/nonuniformRandom/routers.py | scalability-llnl/damselfly | 394e39b3165388e262a90da415dc3338d0f44734 | [
"BSD-Source-Code",
"BSD-3-Clause-LBNL",
"FSFAP"
] | null | null | null | utils/job_placement/nonuniformRandom/routers.py | scalability-llnl/damselfly | 394e39b3165388e262a90da415dc3338d0f44734 | [
"BSD-Source-Code",
"BSD-3-Clause-LBNL",
"FSFAP"
] | 1 | 2017-02-07T05:43:53.000Z | 2017-02-07T05:43:53.000Z | #!/usr/bin/env python
##############################################################################
# Copyright (c) 2014, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# Written by:
# Nikhil Jain <nikhil.jain@acm.org>
# Abhinav Bhatele <bhatele@llnl.gov... | 28.902439 | 175 | 0.59673 |
a0853c6f068e5b0ba0007116f943ea7455d91729 | 46,894 | py | Python | src/scml_vis/presenter.py | yasserfarouk/scml-vis | a8daff36bb29867a67c9a36bcdca9ceef9350e53 | [
"Apache-2.0"
] | null | null | null | src/scml_vis/presenter.py | yasserfarouk/scml-vis | a8daff36bb29867a67c9a36bcdca9ceef9350e53 | [
"Apache-2.0"
] | 2 | 2021-05-07T22:45:42.000Z | 2021-09-22T04:35:15.000Z | src/scml_vis/presenter.py | yasserfarouk/scml-vis | a8daff36bb29867a67c9a36bcdca9ceef9350e53 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
import shutil
import itertools
import random
import sys
import traceback
from pathlib import Path
import altair as alt
import pandas as pd
import plotly as plotly
import plotly.express as px
import plotly.graph_objects as go
import streamlit as st
from pandas.api.types import is_numeric_dtype
fro... | 35.338357 | 233 | 0.565403 |
a08cb54701ee8d7129f53895ca2daa2a379bad89 | 4,431 | py | Python | QFA/MO_1QFA.py | gustawlippa/QFA | 7f1f8bd0d2c9cb9aeeeb924b2f002c9e849523be | [
"MIT"
] | 2 | 2021-01-30T23:14:36.000Z | 2021-02-17T01:41:56.000Z | QFA/MO_1QFA.py | gustawlippa/QFA | 7f1f8bd0d2c9cb9aeeeb924b2f002c9e849523be | [
"MIT"
] | null | null | null | QFA/MO_1QFA.py | gustawlippa/QFA | 7f1f8bd0d2c9cb9aeeeb924b2f002c9e849523be | [
"MIT"
] | null | null | null | import numpy as np
from typing import List
from math import sqrt
from QFA.Automaton import Automaton
from math import cos, sin, pi
if __name__ == "__main__":
example()
| 31.425532 | 120 | 0.643421 |
a08cc063efc183d6784f567bb7e999cbddbf1bbf | 2,292 | py | Python | whats_in_the_cupboard/search/views.py | brandonholderman/whats_in_the_cupboard | 8f8b0abe8b94547fa488db689261a4f475a24779 | [
"MIT"
] | null | null | null | whats_in_the_cupboard/search/views.py | brandonholderman/whats_in_the_cupboard | 8f8b0abe8b94547fa488db689261a4f475a24779 | [
"MIT"
] | 10 | 2020-02-11T23:36:20.000Z | 2022-03-11T23:57:52.000Z | whats_in_the_cupboard/search/views.py | brandonholderman/whats_in_the_cupboard | 8f8b0abe8b94547fa488db689261a4f475a24779 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.views.generic import TemplateView, ListView
from django.shortcuts import render
from rest_framework.authentication import TokenAuthentication
from rest_framework import viewsets, mixins
from rest_framework.response import Response
from rest_fra... | 27.614458 | 67 | 0.654887 |
a08ec5f751e5c0ed745a1196c05685644187a34f | 591 | py | Python | scripts/freq_shecker.py | Fumiya-K/ros_myo | dac160aae5d0cd75211c60261bd1232ef089e530 | [
"MIT"
] | null | null | null | scripts/freq_shecker.py | Fumiya-K/ros_myo | dac160aae5d0cd75211c60261bd1232ef089e530 | [
"MIT"
] | null | null | null | scripts/freq_shecker.py | Fumiya-K/ros_myo | dac160aae5d0cd75211c60261bd1232ef089e530 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import rospy
from geometry_msgs.msg import Vector3
from sensor_msgs.msg import Imu
import numpy as np
c_imu, c_angle = 0, 0
if __name__ == "__main__":
rospy.init_node("freq_checker")
imu_sub = rospy.Subscriber("/myo_raw/myo_ori", Vector3, cb_angle)
ang_sub = rospy.Subscriber("/myo_raw/myo_i... | 21.107143 | 66 | 0.717428 |
a0921c92865225de5297219ccf69a9133b387063 | 2,431 | py | Python | dist/snippets/woosmap_http_zones_collection_request/woosmap_http_zones_collection_request.py | woosmap/openapi-specification | 7f934628a75695884db2fa29dd1d04efd1fb20de | [
"MIT"
] | null | null | null | dist/snippets/woosmap_http_zones_collection_request/woosmap_http_zones_collection_request.py | woosmap/openapi-specification | 7f934628a75695884db2fa29dd1d04efd1fb20de | [
"MIT"
] | 3 | 2021-12-20T16:15:13.000Z | 2022-02-15T00:44:19.000Z | dist/snippets/woosmap_http_zones_collection_request/woosmap_http_zones_collection_request.py | woosmap/openapi-specification | 7f934628a75695884db2fa29dd1d04efd1fb20de | [
"MIT"
] | null | null | null | # [START woosmap_http_zones_collection_request]
import requests
import json
url = "https://api.woosmap.com/zones?private_key=YOUR_PRIVATE_API_KEY"
payload = json.dumps({
"zones": [
{
"zone_id": "ZoneA",
"description": "Delivery Zone for Store A",
"store_id": "STORE_ID_1... | 52.847826 | 562 | 0.65035 |
a0963df40f1df1fa608416915de9bf22beecf414 | 1,692 | py | Python | src/CyPhyMasterInterpreter/run_master_interpreter_sample.py | lefevre-fraser/openmeta-mms | 08f3115e76498df1f8d70641d71f5c52cab4ce5f | [
"MIT"
] | null | null | null | src/CyPhyMasterInterpreter/run_master_interpreter_sample.py | lefevre-fraser/openmeta-mms | 08f3115e76498df1f8d70641d71f5c52cab4ce5f | [
"MIT"
] | null | null | null | src/CyPhyMasterInterpreter/run_master_interpreter_sample.py | lefevre-fraser/openmeta-mms | 08f3115e76498df1f8d70641d71f5c52cab4ce5f | [
"MIT"
] | null | null | null | import win32com.client
# Disable early binding: full of race conditions writing the cache files,
# and changes the semantics since inheritance isn't handled correctly
import win32com.client.gencache
_savedGetClassForCLSID = win32com.client.gencache.GetClassForCLSID
win32com.client.gencache.GetClassForCLSID = lam... | 38.454545 | 115 | 0.785461 |
a097f2e9cca87b9c4ab3fbfbe7eb9b74f83ce331 | 4,051 | py | Python | image_utils.py | datascisteven/Flictionary-Flask | 9437f0b6377b11cecfa37c8a94eb68cc4e7018f8 | [
"MIT"
] | null | null | null | image_utils.py | datascisteven/Flictionary-Flask | 9437f0b6377b11cecfa37c8a94eb68cc4e7018f8 | [
"MIT"
] | null | null | null | image_utils.py | datascisteven/Flictionary-Flask | 9437f0b6377b11cecfa37c8a94eb68cc4e7018f8 | [
"MIT"
] | null | null | null | import numpy as np
import matplotlib.pyplot as plt
from PIL import Image
from PIL import ImageOps
| 28.935714 | 132 | 0.621328 |
a098e971e8b1b7172d8860ca8ed8514362a25eea | 360 | py | Python | src/lqc/generate/web_page/ui_tools/create.py | tysmith/layout-quickcheck | c5ba9431a40f650a594140541e32af7c8ff21695 | [
"MIT"
] | null | null | null | src/lqc/generate/web_page/ui_tools/create.py | tysmith/layout-quickcheck | c5ba9431a40f650a594140541e32af7c8ff21695 | [
"MIT"
] | null | null | null | src/lqc/generate/web_page/ui_tools/create.py | tysmith/layout-quickcheck | c5ba9431a40f650a594140541e32af7c8ff21695 | [
"MIT"
] | null | null | null | import os
| 25.714286 | 82 | 0.633333 |
a09ac1675173bac590c8d099736901eb4fe0b015 | 886 | py | Python | students/K33422/laboratory_works/Moruga_Elina/lr_2/simple_django_web_projects(1)/django_project_Moruga/project_first_app/views.py | Elyavor/ITMO_ICT_WebDevelopment_2021-2022 | 63fad07bcdc0a9a6b85d46eacf97182162262181 | [
"MIT"
] | null | null | null | students/K33422/laboratory_works/Moruga_Elina/lr_2/simple_django_web_projects(1)/django_project_Moruga/project_first_app/views.py | Elyavor/ITMO_ICT_WebDevelopment_2021-2022 | 63fad07bcdc0a9a6b85d46eacf97182162262181 | [
"MIT"
] | null | null | null | students/K33422/laboratory_works/Moruga_Elina/lr_2/simple_django_web_projects(1)/django_project_Moruga/project_first_app/views.py | Elyavor/ITMO_ICT_WebDevelopment_2021-2022 | 63fad07bcdc0a9a6b85d46eacf97182162262181 | [
"MIT"
] | null | null | null | from django.shortcuts import render
from django.http import Http404
from .models import CarOwner
| 59.066667 | 192 | 0.767494 |
a09b9af2b847bf39b063ead0a72aab28cd93427e | 126 | py | Python | wtpy/apps/__init__.py | Huijun-Cui/wtpy | 9a8243a20b944fbb37aa33d81215b7b36ac7b1e2 | [
"MIT"
] | null | null | null | wtpy/apps/__init__.py | Huijun-Cui/wtpy | 9a8243a20b944fbb37aa33d81215b7b36ac7b1e2 | [
"MIT"
] | null | null | null | wtpy/apps/__init__.py | Huijun-Cui/wtpy | 9a8243a20b944fbb37aa33d81215b7b36ac7b1e2 | [
"MIT"
] | null | null | null | from .WtBtAnalyst import WtBtAnalyst
from .WtCtaOptimizer import WtCtaOptimizer
__all__ = ["WtBtAnalyst","WtCtaOptimizer"] | 31.5 | 43 | 0.809524 |
a09c1cbcccf7a63039a5587fbbf109f0b5dc595c | 608 | py | Python | grove_potentiometer.py | cpmpercussion/empi_controller | 178d3952994d7e13067674cbcd261d945e6b4799 | [
"MIT"
] | null | null | null | grove_potentiometer.py | cpmpercussion/empi_controller | 178d3952994d7e13067674cbcd261d945e6b4799 | [
"MIT"
] | null | null | null | grove_potentiometer.py | cpmpercussion/empi_controller | 178d3952994d7e13067674cbcd261d945e6b4799 | [
"MIT"
] | null | null | null | import math
import sys
import time
from grove.adc import ADC
Grove = GroveRotaryAngleSensor
if __name__ == '__main__':
main()
| 17.882353 | 58 | 0.626645 |
a09c77edcb165aec8e2b0d92f741bba565b1c3ad | 627 | py | Python | ad2web/api/forms.py | billfor/alarmdecoder-webapp | 43c3ebb2b44c7291cd89a2a7a31bbdfdb3ec06dc | [
"BSD-3-Clause",
"MIT"
] | 46 | 2015-06-14T02:19:16.000Z | 2022-03-24T03:11:19.000Z | ad2web/api/forms.py | billfor/alarmdecoder-webapp | 43c3ebb2b44c7291cd89a2a7a31bbdfdb3ec06dc | [
"BSD-3-Clause",
"MIT"
] | 66 | 2015-03-14T16:30:43.000Z | 2021-08-28T22:20:01.000Z | ad2web/api/forms.py | billfor/alarmdecoder-webapp | 43c3ebb2b44c7291cd89a2a7a31bbdfdb3ec06dc | [
"BSD-3-Clause",
"MIT"
] | 44 | 2015-02-13T19:23:37.000Z | 2021-12-30T04:17:21.000Z | # -*- coding: utf-8 -*-
import string
from flask_wtf import FlaskForm as Form
from wtforms.fields.html5 import URLField, EmailField, TelField
from wtforms import (ValidationError, HiddenField, TextField, HiddenField,
PasswordField, SubmitField, TextAreaField, IntegerField, RadioField,
FileField, Decima... | 34.833333 | 81 | 0.773525 |
a09e18ee423836b7c3ce0e61bbbd9d1885bd9f19 | 73 | py | Python | modelator_py/util/tla/__init__.py | informalsystems/modelator-py | d66464096c022799e680e6201590a2ead69be32d | [
"Apache-2.0"
] | null | null | null | modelator_py/util/tla/__init__.py | informalsystems/modelator-py | d66464096c022799e680e6201590a2ead69be32d | [
"Apache-2.0"
] | 3 | 2022-03-30T16:01:49.000Z | 2022-03-31T13:40:03.000Z | modelator_py/util/tla/__init__.py | informalsystems/modelator-py | d66464096c022799e680e6201590a2ead69be32d | [
"Apache-2.0"
] | null | null | null | """TLA+ parser and syntax tree."""
from .parser import parse, parse_expr
| 24.333333 | 37 | 0.726027 |
a0a2f155643acffd9a5b5d44e3b912311ab75ced | 2,084 | py | Python | runai/mp/keras/layers/core.py | bamps53/runai | 0c868160f64e1e063c6eb6f660d42917322d40c5 | [
"MIT"
] | 86 | 2020-01-23T18:56:41.000Z | 2022-02-14T22:32:08.000Z | runai/mp/keras/layers/core.py | bamps53/runai | 0c868160f64e1e063c6eb6f660d42917322d40c5 | [
"MIT"
] | 18 | 2020-01-24T17:55:18.000Z | 2021-12-01T01:01:32.000Z | runai/mp/keras/layers/core.py | bamps53/runai | 0c868160f64e1e063c6eb6f660d42917322d40c5 | [
"MIT"
] | 12 | 2020-02-03T14:30:44.000Z | 2022-01-08T16:06:59.000Z | import keras.backend as K
import keras.layers
import runai.mp
from .keep import Keep
from .parallelised import Parallelised
Activation = Keep.create('Activation')
Dropout = Keep.create('Dropout')
Flatten = Keep.create('Flatten')
| 31.575758 | 151 | 0.600768 |
a0a7abf53aec9f31e9e5488c61a3e3d5fb017c5d | 461 | py | Python | graphics.py | Nemo20k/lactose_multistability_model | e50d68bb508e243d0a775d1d562bd8e8b88b3b30 | [
"MIT"
] | null | null | null | graphics.py | Nemo20k/lactose_multistability_model | e50d68bb508e243d0a775d1d562bd8e8b88b3b30 | [
"MIT"
] | null | null | null | graphics.py | Nemo20k/lactose_multistability_model | e50d68bb508e243d0a775d1d562bd8e8b88b3b30 | [
"MIT"
] | null | null | null | from matplotlib import pyplot as plt
import numpy as np
| 27.117647 | 109 | 0.724512 |
a0a9d841059677b45b6f09a062af0ebdbc1dceea | 5,394 | py | Python | webapp/element43/apps/common/util.py | Ososope/eve_online | b368f77aaff403e5f1523a1a0e01d105fed0ada9 | [
"BSD-3-Clause"
] | null | null | null | webapp/element43/apps/common/util.py | Ososope/eve_online | b368f77aaff403e5f1523a1a0e01d105fed0ada9 | [
"BSD-3-Clause"
] | null | null | null | webapp/element43/apps/common/util.py | Ososope/eve_online | b368f77aaff403e5f1523a1a0e01d105fed0ada9 | [
"BSD-3-Clause"
] | null | null | null | # utility functions
import ast
import urllib
import datetime
import pytz
import pylibmc
# Import settings
from django.conf import settings
# API Models
from apps.api.models import APIKey, Character, APITimer
# Eve_DB Models
from eve_db.models import MapSolarSystem
# API Access Masks
CHARACTER_API_ACCESS_MASKS = {'A... | 31 | 134 | 0.561735 |
a0ade23395d3069649385af2893a0f1454cfd97f | 349 | py | Python | forms/views/field.py | alphagov/submit-forms | 6339b40debbab668263246162ab33c68391ef744 | [
"MIT"
] | 3 | 2017-11-20T18:17:47.000Z | 2019-08-09T14:59:36.000Z | forms/views/field.py | alphagov/submit-forms | 6339b40debbab668263246162ab33c68391ef744 | [
"MIT"
] | null | null | null | forms/views/field.py | alphagov/submit-forms | 6339b40debbab668263246162ab33c68391ef744 | [
"MIT"
] | 3 | 2019-08-29T11:55:16.000Z | 2021-04-10T19:52:14.000Z | from django.shortcuts import render
from ..models import Field
| 20.529412 | 61 | 0.670487 |
a0af5afc99a71406be5ffead3cb66d5a5fbdf490 | 2,608 | py | Python | crafting/CraftingHandler.py | uuk0/mcpython-4 | 1ece49257b3067027cc43b452a2fc44908d3514c | [
"MIT"
] | 2 | 2019-08-21T08:23:45.000Z | 2019-09-25T13:20:28.000Z | crafting/CraftingHandler.py | uuk0/mcpython-4 | 1ece49257b3067027cc43b452a2fc44908d3514c | [
"MIT"
] | 11 | 2019-08-21T08:46:01.000Z | 2021-09-08T01:18:04.000Z | crafting/CraftingHandler.py | uuk0/mcpython-4 | 1ece49257b3067027cc43b452a2fc44908d3514c | [
"MIT"
] | 5 | 2019-08-30T08:19:57.000Z | 2019-10-26T03:31:16.000Z | """mcpython - a minecraft clone written in python licenced under MIT-licence
authors: uuk, xkcdjerry
original game by forgleman licenced under MIT-licence
minecraft by Mojang
blocks based on 1.14.4.jar of minecraft, downloaded on 20th of July, 2019"""
import globals as G
import crafting.IRecipeType
import json
import... | 35.243243 | 113 | 0.657209 |
a0b0788c0fdd53bb74359f134c5cbbe7dd53cb63 | 1,625 | py | Python | xcache.py | ATLAS-Analytics/AlarmAndAlertService | a167439b0c3f3c9594af52bd21fe8713b5f47bf1 | [
"MIT"
] | null | null | null | xcache.py | ATLAS-Analytics/AlarmAndAlertService | a167439b0c3f3c9594af52bd21fe8713b5f47bf1 | [
"MIT"
] | 1 | 2021-05-26T02:21:42.000Z | 2021-05-26T02:21:42.000Z | xcache.py | ATLAS-Analytics/AlarmAndAlertService | a167439b0c3f3c9594af52bd21fe8713b5f47bf1 | [
"MIT"
] | null | null | null | # Checks number of concurrent connections from XCaches to MWT2 dCache.
# Creates alarm if more than 200 from any server.
# ====
# It is run every 30 min from a cron job.
import json
from datetime import datetime
import requests
from alerts import alarms
config_path = '/config/config.json'
with open(con... | 30.092593 | 88 | 0.619692 |
a0b0d03bf62e28fff9360da39608230424f15bea | 769 | py | Python | Question3_Competetive_Programming/solution.py | Robotrek-TechTatva/big-pp | 5790075638aa7f39d787dfc390f43da1cdb4ed56 | [
"MIT"
] | null | null | null | Question3_Competetive_Programming/solution.py | Robotrek-TechTatva/big-pp | 5790075638aa7f39d787dfc390f43da1cdb4ed56 | [
"MIT"
] | null | null | null | Question3_Competetive_Programming/solution.py | Robotrek-TechTatva/big-pp | 5790075638aa7f39d787dfc390f43da1cdb4ed56 | [
"MIT"
] | null | null | null | import csv
filename = "traingles.csv"
with open(filename, 'r') as csv_file:
csv_reader = csv.reader(csv_file)
next(csv_reader)
for line in csv_reader:
if line:
print(isInside(line)) | 21.361111 | 49 | 0.470741 |
a0b1f6e65ee6e7176da940ac100c95bce2eaea30 | 238 | py | Python | tutorials/W0D4_Calculus/solutions/W0D4_Tutorial2_Solution_359be293.py | vasudev-sharma/course-content | 46fb9be49da52acb5df252dda43f11b6d1fe827f | [
"CC-BY-4.0",
"BSD-3-Clause"
] | 1 | 2021-06-09T09:56:21.000Z | 2021-06-09T09:56:21.000Z | tutorials/W0D4_Calculus/solutions/W0D4_Tutorial2_Solution_359be293.py | macasal/course-content | 0fc5e1a0d736c6b0391eeab587012ed0ab01e462 | [
"CC-BY-4.0",
"BSD-3-Clause"
] | 1 | 2021-06-16T05:41:08.000Z | 2021-06-16T05:41:08.000Z | tutorials/W0D4_Calculus/solutions/W0D4_Tutorial2_Solution_359be293.py | macasal/course-content | 0fc5e1a0d736c6b0391eeab587012ed0ab01e462 | [
"CC-BY-4.0",
"BSD-3-Clause"
] | null | null | null | t = np.arange(0, 10, 0.1) # Time from 0 to 10 years in 0.1 steps
with plt.xkcd():
p = np.exp(0.3 * t)
fig = plt.figure(figsize=(6, 4))
plt.plot(t, p)
plt.ylabel('Population (millions)')
plt.xlabel('time (years)')
plt.show() | 21.636364 | 64 | 0.60084 |
a0b4e94b3b4a3e4439a5b84940a160611b866816 | 1,063 | py | Python | test/python/squarepants_test/plugins/test_link_resources_jars.py | ericzundel/mvn2pants | 59776864939515bc0cae28e1b89944ce55b98b21 | [
"Apache-2.0"
] | 8 | 2015-04-14T22:37:56.000Z | 2021-01-20T19:46:40.000Z | test/python/squarepants_test/plugins/test_link_resources_jars.py | ericzundel/mvn2pants | 59776864939515bc0cae28e1b89944ce55b98b21 | [
"Apache-2.0"
] | 1 | 2016-01-13T23:19:14.000Z | 2016-01-22T22:47:48.000Z | test/python/squarepants_test/plugins/test_link_resources_jars.py | ericzundel/mvn2pants | 59776864939515bc0cae28e1b89944ce55b98b21 | [
"Apache-2.0"
] | 3 | 2015-12-13T08:35:34.000Z | 2018-08-01T17:44:59.000Z | # Tests for code in squarepants/src/main/python/squarepants/plugins/copy_resources/tasks/copy_resource_jars
#
# Run with:
# ./pants test squarepants/src/test/python/squarepants_test/plugins:copy_resources
from pants.backend.jvm.targets.jar_dependency import JarDependency
from pants.backend.jvm.targets.jar_library impo... | 40.884615 | 107 | 0.804327 |
a0b646cbb8b05a36f6c66a8ee0acf369718630ee | 2,339 | py | Python | src/binwalk/__main__.py | puppywang/binwalk | fa0c0bd59b8588814756942fe4cb5452e76c1dcd | [
"MIT"
] | 5,504 | 2017-11-30T21:25:07.000Z | 2022-03-31T17:00:58.000Z | src/binwalk/__main__.py | puppywang/binwalk | fa0c0bd59b8588814756942fe4cb5452e76c1dcd | [
"MIT"
] | 247 | 2017-12-07T06:09:56.000Z | 2022-03-23T05:34:47.000Z | src/binwalk/__main__.py | puppywang/binwalk | fa0c0bd59b8588814756942fe4cb5452e76c1dcd | [
"MIT"
] | 953 | 2017-12-01T17:05:17.000Z | 2022-03-26T13:15:33.000Z | import os
import sys
# If installed to a custom prefix directory, binwalk may not be in
# the default module search path(s). Try to resolve the prefix module
# path and make it the first entry in sys.path.
# Ensure that 'src/binwalk' becomes '.' instead of an empty string
_parent_dir = os.path.dirname(os.path.dirname(... | 35.984615 | 97 | 0.595554 |
a0b73f136f5ae88a402fa6be43272da9242cdedc | 642 | py | Python | MINI_WEB/mini_web/framework/mini_frame_4.py | GalphaXie/LaoX | b7e8f9744292dc052c870e4d873052e9bfec19ee | [
"MIT"
] | null | null | null | MINI_WEB/mini_web/framework/mini_frame_4.py | GalphaXie/LaoX | b7e8f9744292dc052c870e4d873052e9bfec19ee | [
"MIT"
] | 12 | 2020-03-24T17:39:25.000Z | 2022-03-12T00:01:24.000Z | MINI_WEB/mini_web/framework/mini_frame_4.py | GalphaXie/LaoX | b7e8f9744292dc052c870e4d873052e9bfec19ee | [
"MIT"
] | null | null | null | #!/usr/bin/python3
# file: mini_frame.py
# Created by Guang at 19-7-19
# description:
# *-* coding:utf8 *-*
import time
| 21.4 | 106 | 0.619938 |
a0b7ca82a2ce39606a44ac65893f26c1b02da5d3 | 3,174 | py | Python | server.py | AndrewB330/BinanceTerminal | 3699a295d2b2af810d30ff692bab4e106ec44392 | [
"MIT"
] | 14 | 2020-03-09T04:08:03.000Z | 2021-12-29T14:53:32.000Z | server.py | AndrewB330/BinanceTerminal | 3699a295d2b2af810d30ff692bab4e106ec44392 | [
"MIT"
] | null | null | null | server.py | AndrewB330/BinanceTerminal | 3699a295d2b2af810d30ff692bab4e106ec44392 | [
"MIT"
] | null | null | null | import time
import pymongo
import schedule
from order import *
from utils import *
# MONGODB
db = pymongo.MongoClient("mongodb://localhost:27017/")["ShaurmaBinanceTerminal"]
order_db = db["orders"]
JOB_INTERVAL = 10.0 # interval of updating
jobs_pool = {}
if __name__ == '__main__':
# initialize_test_db()... | 31.74 | 116 | 0.598614 |
a0b8186276c361f655fc43a3b80aba5c60bd0210 | 4,979 | py | Python | sarenka/backend/api_searcher/searcher_full.py | adolabsnet/sarenka | 2032aa6ddebfc69b0db551b7793080d17282ced2 | [
"MIT"
] | 380 | 2019-12-05T09:37:47.000Z | 2022-03-31T09:37:27.000Z | sarenka/backend/api_searcher/searcher_full.py | watchmen-coder/sarenka | d7fc0928e4992de3dbb1546137ca6a158e930ba8 | [
"MIT"
] | 14 | 2020-09-26T17:49:42.000Z | 2022-02-04T18:16:16.000Z | sarenka/backend/api_searcher/searcher_full.py | watchmen-coder/sarenka | d7fc0928e4992de3dbb1546137ca6a158e930ba8 | [
"MIT"
] | 60 | 2021-01-01T16:25:30.000Z | 2022-03-26T18:48:03.000Z | """
Modu spiajcy wszystkie wyszukiwania w jedn klas - wszystkei dane dla adresu ip/domeny.
Klasa bezporednio uywana w widoku Django.
"""
from rest_framework.reverse import reverse
from typing import List, Dict
import whois
import socket
from connectors.credential import CredentialsNotFoundError
from api_searcher.searc... | 40.811475 | 126 | 0.589677 |
a0ba9ed937616e6ee4572b155cab4164464097a6 | 75 | py | Python | Codewars/8kyu/get-the-mean-of-an-array/Python/solution1.py | RevansChen/online-judge | ad1b07fee7bd3c49418becccda904e17505f3018 | [
"MIT"
] | 7 | 2017-09-20T16:40:39.000Z | 2021-08-31T18:15:08.000Z | Codewars/8kyu/get-the-mean-of-an-array/Python/solution1.py | RevansChen/online-judge | ad1b07fee7bd3c49418becccda904e17505f3018 | [
"MIT"
] | null | null | null | Codewars/8kyu/get-the-mean-of-an-array/Python/solution1.py | RevansChen/online-judge | ad1b07fee7bd3c49418becccda904e17505f3018 | [
"MIT"
] | null | null | null | # Python - 3.6.0
get_average = lambda marks: int(sum(marks) / len(marks))
| 18.75 | 56 | 0.666667 |
a0bb420692799a6a79988f6528e8182e5954185a | 3,234 | py | Python | cifar10/train.py | ashawkey/hawtorch | a6e28422da9258458b6268f5981c68d60623e12f | [
"MIT"
] | 1 | 2019-12-01T05:48:00.000Z | 2019-12-01T05:48:00.000Z | cifar10/train.py | ashawkey/hawtorch | a6e28422da9258458b6268f5981c68d60623e12f | [
"MIT"
] | null | null | null | cifar10/train.py | ashawkey/hawtorch | a6e28422da9258458b6268f5981c68d60623e12f | [
"MIT"
] | null | null | null | import torch
import torch.nn as nn
import torch.optim as optim
from torch.optim import lr_scheduler
import torchvision
from torchvision import datasets, transforms
from torch.utils.data import DataLoader
import hawtorch
import hawtorch.io as io
from hawtorch import Trainer
from hawtorch.metrics import ClassificationM... | 34.042105 | 119 | 0.62987 |
a0bbcdf05486aa95d06b89b25ca7866a985c51bb | 718 | py | Python | examples/scatterplot.py | ajduberstein/slayer | e4f2b6e0277ac38fe71ec99eaf3ee4769057b0ea | [
"MIT"
] | 2 | 2019-02-26T23:55:06.000Z | 2019-02-26T23:56:09.000Z | examples/scatterplot.py | ajduberstein/slayer | e4f2b6e0277ac38fe71ec99eaf3ee4769057b0ea | [
"MIT"
] | 1 | 2019-02-10T07:00:39.000Z | 2019-02-10T07:00:39.000Z | examples/scatterplot.py | ajduberstein/slayer | e4f2b6e0277ac38fe71ec99eaf3ee4769057b0ea | [
"MIT"
] | null | null | null | """
Example of how to make a Scatterplot with a time component
"""
import slayer as sly
import pandas as pd
DATA_URL = 'https://raw.githubusercontent.com/ajduberstein/sf_growth/master/public/data/business.csv'
businesses = pd.read_csv(DATA_URL)
FUCHSIA_RGBA = [255, 0, 255, 140]
color_scale = sly.ColorScale(
pal... | 26.592593 | 101 | 0.693593 |
a0bc99badd8c414f8e67c165139e1e1864acd087 | 3,699 | py | Python | test_dictondisk.py | MKuranowski/dictondisk | ca25f8fed2f60d8ee63d6c5eaa9e620555581383 | [
"MIT"
] | null | null | null | test_dictondisk.py | MKuranowski/dictondisk | ca25f8fed2f60d8ee63d6c5eaa9e620555581383 | [
"MIT"
] | null | null | null | test_dictondisk.py | MKuranowski/dictondisk | ca25f8fed2f60d8ee63d6c5eaa9e620555581383 | [
"MIT"
] | null | null | null | import dictondisk
import random
import pytest
import os
remove_keys = {0, (33, 12.23), "c", ""}
vanilla_dict = {
0: 1337, 1: 3.14, 2: 2.71, 3: 1.61,
"a": "", "b": "!", "c": "", "": "",
(1, .5): "lorem", (33, 12.23): "ipsum",
-1: ["one", "two", "three"]
}
| 20.324176 | 58 | 0.593674 |
a0bd4d5ee3152479bb0efe0eaded5fd65042adf4 | 1,904 | py | Python | backend/src/users/models.py | moatom/alistice | 222217928d9634b14e3c192abedc8c7d419ab868 | [
"MIT"
] | null | null | null | backend/src/users/models.py | moatom/alistice | 222217928d9634b14e3c192abedc8c7d419ab868 | [
"MIT"
] | null | null | null | backend/src/users/models.py | moatom/alistice | 222217928d9634b14e3c192abedc8c7d419ab868 | [
"MIT"
] | null | null | null | from src.extentions import db
from flask_login import UserMixin
from werkzeug.security import generate_password_hash, check_password_hash
import datetime as dt
# https://help.twitter.com/en/managing-your-account/twitter-username-rules
# https://office-hack.com/gmail/password/
| 46.439024 | 87 | 0.628151 |
a0bead6599200d03855aef8174ff835ecca2f74f | 76,496 | py | Python | commonroad/scenario/lanelet.py | CommonRoad/commonroad-io | 93824961da9c41eb7768b5cf1acbed9a07446dc2 | [
"BSD-3-Clause"
] | 3 | 2022-01-05T09:10:18.000Z | 2022-03-22T15:09:43.000Z | commonroad/scenario/lanelet.py | CommonRoad/commonroad-io | 93824961da9c41eb7768b5cf1acbed9a07446dc2 | [
"BSD-3-Clause"
] | null | null | null | commonroad/scenario/lanelet.py | CommonRoad/commonroad-io | 93824961da9c41eb7768b5cf1acbed9a07446dc2 | [
"BSD-3-Clause"
] | null | null | null | import copy
import enum
from typing import *
import numpy as np
from shapely.geometry import MultiPolygon as ShapelyMultiPolygon
from shapely.geometry import Point as ShapelyPoint
from shapely.geometry import Polygon as ShapelyPolygon
from shapely.strtree import STRtree
import commonroad.geometry.transform
from commo... | 45.103774 | 120 | 0.629314 |
a0bf221732ca55e79444af87da162c6c9266b8fc | 363 | py | Python | djangoProject/djangoProject/myApp/urls.py | EldiiarDzhunusov/Code | 6b0708e4007233d3efdc74c09d09ee5bc377a45d | [
"MIT"
] | 2 | 2020-10-12T06:50:03.000Z | 2021-06-08T17:19:43.000Z | djangoProject/djangoProject/myApp/urls.py | EldiiarDzhunusov/Code | 6b0708e4007233d3efdc74c09d09ee5bc377a45d | [
"MIT"
] | null | null | null | djangoProject/djangoProject/myApp/urls.py | EldiiarDzhunusov/Code | 6b0708e4007233d3efdc74c09d09ee5bc377a45d | [
"MIT"
] | 1 | 2020-12-22T16:44:50.000Z | 2020-12-22T16:44:50.000Z |
from django.urls import path
from . import views
urlpatterns = [
path("test/", views.index, name = "index"),
path('completed/',views.show_completed,name= "completed"),
path('<int:action_id>/', views.show_action, name='action'),
path('update/', views.update_status, name="update_status"),
path('new/... | 33 | 63 | 0.674931 |
a0c050b20614c1dbb61208ccd768082e1160610d | 14,673 | py | Python | tests/test_data_frame.py | gordonwatts/dataframe_expressions | cf135415f739377e9c2accb82606957417c7e0e6 | [
"MIT"
] | 4 | 2020-03-16T14:22:33.000Z | 2021-09-08T17:56:47.000Z | tests/test_data_frame.py | gordonwatts/dataframe_expressions | cf135415f739377e9c2accb82606957417c7e0e6 | [
"MIT"
] | 26 | 2020-05-28T20:58:42.000Z | 2020-10-21T01:27:17.000Z | tests/test_data_frame.py | gordonwatts/dataframe_expressions | cf135415f739377e9c2accb82606957417c7e0e6 | [
"MIT"
] | null | null | null | import ast
from typing import List, Optional, cast
import pytest
from dataframe_expressions import (
Column, DataFrame, ast_Callable, ast_Column, ast_DataFrame, define_alias)
from .utils_for_testing import reset_var_counter # NOQA
# numpy math functions (??)
# Advanced math operators
# (https://docs.python.... | 28.827112 | 122 | 0.647584 |
a0c2eb12b9028951da45c66cf06efe7db3fad008 | 520 | py | Python | redis/redismq/redismq.py | dineshkumar2509/learning-python | e8af11ff0b396da4c3f2cfe21d14131bae4b2adb | [
"MIT"
] | 86 | 2015-06-13T16:53:55.000Z | 2022-03-24T20:56:42.000Z | redis/redismq/redismq.py | pei-zheng-yi/learning-python | 55e350dfe44cf04f7d4408e76e72d2f467bd42ce | [
"MIT"
] | 9 | 2015-05-27T07:52:44.000Z | 2022-03-29T21:52:40.000Z | redis/redismq/redismq.py | pei-zheng-yi/learning-python | 55e350dfe44cf04f7d4408e76e72d2f467bd42ce | [
"MIT"
] | 124 | 2015-12-10T01:17:18.000Z | 2021-11-08T04:03:38.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import redis
rc = redis.StrictRedis(host='localhost', port=6379, db=0)
| 15.294118 | 57 | 0.634615 |
a0c41cacd5163331beb9572314dcb4bf4d9b8235 | 12,660 | py | Python | main.py | ESSAKHI10/SharpZone | 1d145cb22c5a8f6777d2f6e05a9a16f8e528c92c | [
"MIT"
] | null | null | null | main.py | ESSAKHI10/SharpZone | 1d145cb22c5a8f6777d2f6e05a9a16f8e528c92c | [
"MIT"
] | null | null | null | main.py | ESSAKHI10/SharpZone | 1d145cb22c5a8f6777d2f6e05a9a16f8e528c92c | [
"MIT"
] | null | null | null | # import encode
import eel
import cv2
import io
import numpy as np
import base64
import os
import time
import face_recognition
import pickle
import imutils
import datetime
from multiprocessing.pool import ThreadPool
import random
import shutil
from database import *
from camera import VideoCamera
fro... | 29.648712 | 169 | 0.562243 |
39f81d8b6eef50e0aea91f95d8884d5a0a59d256 | 3,713 | py | Python | models/job.py | k-wojcik/kylin_client_tool | 0fe827d1c8a86e3da61c85c48f78ce03c9260f3c | [
"Apache-2.0"
] | null | null | null | models/job.py | k-wojcik/kylin_client_tool | 0fe827d1c8a86e3da61c85c48f78ce03c9260f3c | [
"Apache-2.0"
] | null | null | null | models/job.py | k-wojcik/kylin_client_tool | 0fe827d1c8a86e3da61c85c48f78ce03c9260f3c | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
__author__ = 'Huang, Hua'
from models.object import JsonSerializableObj
| 30.434426 | 75 | 0.622408 |
39f8dcdaeba92c1fff96ab2beb0ef7065bdd2f6c | 1,770 | py | Python | stakingsvc/walletgui/views/paymentmethodview.py | biz2013/xwjy | 8f4b5e3e3fc964796134052ff34d58d31ed41904 | [
"Apache-2.0"
] | 1 | 2019-12-15T16:56:44.000Z | 2019-12-15T16:56:44.000Z | stakingsvc/walletgui/views/paymentmethodview.py | biz2013/xwjy | 8f4b5e3e3fc964796134052ff34d58d31ed41904 | [
"Apache-2.0"
] | 87 | 2018-01-06T10:18:31.000Z | 2022-03-11T23:32:30.000Z | stakingsvc/walletgui/views/paymentmethodview.py | biz2013/xwjy | 8f4b5e3e3fc964796134052ff34d58d31ed41904 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/python
# -*- coding: utf-8 -*-
import logging, sys
from django.contrib.auth.decorators import login_required
from django.shortcuts import render
from walletgui.controller.global_constants import *
from walletgui.controller.crypto_utils import CryptoUtility
from walletgui.controller.walletmanager import Wal... | 37.659574 | 76 | 0.70565 |
39f8e72f0d8a4ab5e6ca1adccd579c3125c23d90 | 1,643 | py | Python | tools.py | yflyzhang/cascade_virality | 9d856a3fbe45330a9434ba4bad9d5f248e2f1dd5 | [
"MIT"
] | 6 | 2020-09-09T15:31:02.000Z | 2022-02-16T04:57:55.000Z | tools.py | yflyzhang/cascade_virality | 9d856a3fbe45330a9434ba4bad9d5f248e2f1dd5 | [
"MIT"
] | null | null | null | tools.py | yflyzhang/cascade_virality | 9d856a3fbe45330a9434ba4bad9d5f248e2f1dd5 | [
"MIT"
] | null | null | null | import numpy as np
import networkx as nx
# For illustration purpose only [easy to understand the process]
# -----------------------------
def pure_cascade_virality(G):
'''G is a directed graph(tree)'''
if not nx.is_weakly_connected(G):
# return None
return
nodes = [k for (k,v) in G.... | 23.471429 | 105 | 0.57395 |
39f9818d1295e4cbcfc1bb13178c81b8bc72f7ba | 1,492 | py | Python | pyjira/actions.py | FulcrumIT/pyjira | 8ed0d22136808ba95ace253e66dd4ad7bb6b387a | [
"MIT"
] | 1 | 2020-11-05T10:24:15.000Z | 2020-11-05T10:24:15.000Z | pyjira/actions.py | FulcrumIT/pyjira | 8ed0d22136808ba95ace253e66dd4ad7bb6b387a | [
"MIT"
] | null | null | null | pyjira/actions.py | FulcrumIT/pyjira | 8ed0d22136808ba95ace253e66dd4ad7bb6b387a | [
"MIT"
] | 2 | 2017-05-15T20:06:25.000Z | 2020-11-17T09:46:34.000Z | import pyjira.api as _api
import json as _json
def get_issues(id, limit=50):
"""Return 50 issues for a project.
Parameters:
- id: id of a project.
- limit: max number of results to be returned.
"""
return _api.rest("/search?jql=project=" + str(id) + "&maxResults=" + str(limit))
def get_issue... | 24.866667 | 84 | 0.589812 |
39fb765d92c4d3395b8dec3f9fb952f0fa19dddd | 963 | py | Python | gongish/cli/serve.py | meyt/gongish | 0e3cd478677c19c9331a2b563ce792d16f2860b3 | [
"MIT"
] | null | null | null | gongish/cli/serve.py | meyt/gongish | 0e3cd478677c19c9331a2b563ce792d16f2860b3 | [
"MIT"
] | 1 | 2021-09-11T22:53:48.000Z | 2021-09-11T22:53:48.000Z | gongish/cli/serve.py | meyt/gongish | 0e3cd478677c19c9331a2b563ce792d16f2860b3 | [
"MIT"
] | null | null | null | import importlib
from argparse import ArgumentParser
from wsgiref.simple_server import make_server
p = ArgumentParser(
prog="gongish serve", description="Serve a WSGI application"
)
p.add_argument(
"module",
nargs="?",
help="Module and application name (e.g: myapp:app)",
type=str,
)
p.add_argument... | 22.395349 | 64 | 0.626168 |
39fbc1222f2bd73553fac90c67abef716e48ef7b | 2,248 | py | Python | tests/test_cmd_trie.py | ncloudioj/rhino-rox | 7e3c70edebca5cc0f847d777c2bff02218b4ca69 | [
"BSD-3-Clause"
] | 1 | 2016-06-14T11:16:43.000Z | 2016-06-14T11:16:43.000Z | tests/test_cmd_trie.py | ncloudioj/rhino-rox | 7e3c70edebca5cc0f847d777c2bff02218b4ca69 | [
"BSD-3-Clause"
] | null | null | null | tests/test_cmd_trie.py | ncloudioj/rhino-rox | 7e3c70edebca5cc0f847d777c2bff02218b4ca69 | [
"BSD-3-Clause"
] | null | null | null | import unittest
import redis
import random
| 35.125 | 77 | 0.607651 |
39fbe8706a2051eee9dadaa5adf1cf67f5342a04 | 325 | py | Python | 4. 01.07.2021/0. Secret Messages. New position.py | AntonVasko/CodeClub-2021-SUMMER | 14a80168bb7c2eb3c0c157d6d5b7630c05decb31 | [
"CC0-1.0"
] | null | null | null | 4. 01.07.2021/0. Secret Messages. New position.py | AntonVasko/CodeClub-2021-SUMMER | 14a80168bb7c2eb3c0c157d6d5b7630c05decb31 | [
"CC0-1.0"
] | null | null | null | 4. 01.07.2021/0. Secret Messages. New position.py | AntonVasko/CodeClub-2021-SUMMER | 14a80168bb7c2eb3c0c157d6d5b7630c05decb31 | [
"CC0-1.0"
] | null | null | null | #Secret Messages. New position
alphabet = 'abcdefghijklmnopqrstuvwxyz'
key = 3
character = input('Please enter a character ')
position = alphabet.find(character)
print('Position of a character ', character, ' is ', position)
newPosition = position + key
print('New position of a character ', character, ' is ', newPosit... | 32.5 | 69 | 0.747692 |
39fcb7feb468394c971a4be4fe1ebd1c774cf3a6 | 1,376 | py | Python | examples/plot/lines.py | beidongjiedeguang/manim-express | e9c89b74da3692db3ea9b568727e78d5cbcef503 | [
"MIT"
] | 12 | 2021-06-14T07:28:29.000Z | 2022-02-25T02:49:49.000Z | examples/plot/lines.py | beidongjiedeguang/manim-kunyuan | e9c89b74da3692db3ea9b568727e78d5cbcef503 | [
"MIT"
] | 1 | 2022-02-01T12:30:14.000Z | 2022-02-01T12:30:14.000Z | examples/plot/lines.py | beidongjiedeguang/manim-express | e9c89b74da3692db3ea9b568727e78d5cbcef503 | [
"MIT"
] | 2 | 2021-05-13T13:24:15.000Z | 2021-05-18T02:56:22.000Z | from examples.example_imports import *
from manim_express.eager import PlotObj
scene = EagerModeScene(screen_size=Size.bigger)
graph = Line().scale(0.2)
# t0 = time.time()
#
# delta_t = 0.5
# for a in np.linspace(3, 12, 3):
# graph2 = ParametricCurve(lambda t: [t,
# 0.8 * n... | 27.52 | 111 | 0.5625 |
39fede8d13d0249be971c45d4492a0a209527ae6 | 785 | py | Python | get_observation.py | RadixSeven/FhirGaP | 1fb8ff8b86089cdec9b1f796e06aeb0e20db14a0 | [
"Apache-2.0"
] | null | null | null | get_observation.py | RadixSeven/FhirGaP | 1fb8ff8b86089cdec9b1f796e06aeb0e20db14a0 | [
"Apache-2.0"
] | null | null | null | get_observation.py | RadixSeven/FhirGaP | 1fb8ff8b86089cdec9b1f796e06aeb0e20db14a0 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
# Note that this is python3 only
import argparse
import requests
parser = argparse.ArgumentParser(
"Get an observation from a FHIR server with authentication")
parser.add_argument(
"id", help="The observation id to retrieve")
parser.add_argument(
"auth", default="Admin",
help="The... | 30.192308 | 78 | 0.699363 |
39ff330d14f36471f4ac2d1038f80fb721a10e6c | 14,331 | py | Python | resources/src/mythbox/mythtv/enums.py | bopopescu/ServerStatus | a883598248ad6f5273eb3be498e3b04a1fab6510 | [
"MIT"
] | null | null | null | resources/src/mythbox/mythtv/enums.py | bopopescu/ServerStatus | a883598248ad6f5273eb3be498e3b04a1fab6510 | [
"MIT"
] | 1 | 2015-04-21T22:05:02.000Z | 2015-04-22T22:27:15.000Z | resources/src/mythbox/mythtv/enums.py | GetSomeBlocks/Score_Soccer | a883598248ad6f5273eb3be498e3b04a1fab6510 | [
"MIT"
] | 2 | 2018-04-17T17:34:39.000Z | 2020-07-26T03:43:33.000Z | #
# MythBox for XBMC - http://mythbox.googlecode.com
# Copyright (C) 2010 analogue@yahoo.com
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at yo... | 29.670807 | 114 | 0.526551 |
2600aabf67e890934f21d69c79a38729246c8b46 | 3,989 | py | Python | model_training_scripts/image_processing.py | jc2554/iVending | 2a6b04143a56e202eba99b0a509945cf31aa956d | [
"MIT"
] | null | null | null | model_training_scripts/image_processing.py | jc2554/iVending | 2a6b04143a56e202eba99b0a509945cf31aa956d | [
"MIT"
] | null | null | null | model_training_scripts/image_processing.py | jc2554/iVending | 2a6b04143a56e202eba99b0a509945cf31aa956d | [
"MIT"
] | null | null | null | """
script to post-process training images by using OpenCV face detection
and normalization
MIT License
Copyright (c) 2019 JinJie Chen
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 re... | 36.263636 | 102 | 0.656806 |
260184f873fdef40a6660e5cdbc4d152fa8c734a | 1,816 | py | Python | flask_map.py | zenranda/proj5-map | 13dc8866483f45ac806342c1b3aa2eec1354a0dc | [
"Artistic-2.0"
] | null | null | null | flask_map.py | zenranda/proj5-map | 13dc8866483f45ac806342c1b3aa2eec1354a0dc | [
"Artistic-2.0"
] | null | null | null | flask_map.py | zenranda/proj5-map | 13dc8866483f45ac806342c1b3aa2eec1354a0dc | [
"Artistic-2.0"
] | null | null | null | import flask
from flask import render_template
from flask import request
from flask import url_for
import json
import logging
###
# Globals
###
app = flask.Flask(__name__)
import CONFIG
###
# Pages
###
#############
#
# Set up to run from cgi-bin script, from
# gunicorn, or stand-alone.
#
app.secret_key = CO... | 25.222222 | 91 | 0.614537 |
2602aa16755c35ffe309d7e1deefd2b15d53fedd | 3,717 | py | Python | tcvx21/grillix_post/observables/parallel_gradient_m.py | dsoliveir/TCV-X21 | 784c55adb33417e21a6736e2504a3895a9348dbe | [
"CC-BY-4.0"
] | 1 | 2021-12-13T11:52:39.000Z | 2021-12-13T11:52:39.000Z | tcvx21/grillix_post/observables/parallel_gradient_m.py | dsoliveir/TCV-X21 | 784c55adb33417e21a6736e2504a3895a9348dbe | [
"CC-BY-4.0"
] | 2 | 2021-12-18T17:18:52.000Z | 2022-01-26T09:23:23.000Z | tcvx21/grillix_post/observables/parallel_gradient_m.py | dsoliveir/TCV-X21 | 784c55adb33417e21a6736e2504a3895a9348dbe | [
"CC-BY-4.0"
] | 2 | 2021-12-13T12:56:09.000Z | 2022-01-25T20:30:28.000Z | import xarray as xr
import numpy as np
from pathlib import Path
from tcvx21.grillix_post.components import FieldlineTracer
from tcvx21.grillix_post.lineouts import Lineout
xr.set_options(keep_attrs=True)
def initialise_lineout_for_parallel_gradient(
lineout, grid, equi, norm, npol, stored_trace: Path = None
):
... | 37.17 | 117 | 0.684154 |
2603181f0b3082fdc38b19973a3aa85c33523f68 | 22,466 | py | Python | tests/hwsim/test_ap_ht.py | rzr/wpasupplicant | 3f7ac05878ba965e941f2b5b80b8cb744e63f506 | [
"Unlicense"
] | 19 | 2015-04-02T13:50:00.000Z | 2022-01-19T02:45:18.000Z | tests/hwsim/test_ap_ht.py | jku/hostap | a61fcc131aa6a7e396eee6a3c613001bf0475cd1 | [
"Unlicense"
] | 3 | 2016-03-16T13:46:10.000Z | 2016-08-30T12:42:52.000Z | tests/hwsim/test_ap_ht.py | jku/hostap | a61fcc131aa6a7e396eee6a3c613001bf0475cd1 | [
"Unlicense"
] | 11 | 2015-05-18T07:37:12.000Z | 2021-11-12T10:28:50.000Z | # Test cases for HT operations with hostapd
# Copyright (c) 2013-2014, Jouni Malinen <j@w1.fi>
#
# This software may be distributed under the terms of the BSD license.
# See README for more details.
import time
import logging
logger = logging.getLogger()
import struct
import subprocess
import hostapd
def test_ap_ht4... | 37.694631 | 199 | 0.582614 |
26043d5d77004fcf11c43eb7691efa8015b6c1e6 | 1,039 | py | Python | rhymes.py | hayderkharrufa/arabic_poetry_generator | 82f2ed726ec6270c3ee1d2f7c7aa1783df973708 | [
"MIT"
] | 72 | 2020-05-29T19:58:22.000Z | 2022-03-11T18:53:56.000Z | rhymes.py | mahfoudhich/arabic_poem_generator | 82f2ed726ec6270c3ee1d2f7c7aa1783df973708 | [
"MIT"
] | 1 | 2020-06-12T11:03:45.000Z | 2020-08-05T17:52:27.000Z | rhymes.py | mahfoudhich/arabic_poem_generator | 82f2ed726ec6270c3ee1d2f7c7aa1783df973708 | [
"MIT"
] | 34 | 2020-06-04T14:38:39.000Z | 2022-03-16T20:50:56.000Z | # coding: utf-8
# author: Haydara https://www.youtube.com/haydara
import pickle
with open('vocabs.pkl', 'rb') as pickle_load:
voc_list = pickle.load(pickle_load)
allowed_chars = ['', '', '', '', '', '', '', '', '', '', '', '', '',
'', '', '', '', '', '', '', '', '', '', '', '', '', '', '',... | 29.685714 | 102 | 0.505294 |
2604cf6f50e982afd7ab5c70c9417b6682140a5d | 6,513 | py | Python | tests/test_facade.py | seucolega/lista-de-listas-cli | 48815fac9cf3332c5e4fbc935d6ddd09be2738a8 | [
"MIT"
] | null | null | null | tests/test_facade.py | seucolega/lista-de-listas-cli | 48815fac9cf3332c5e4fbc935d6ddd09be2738a8 | [
"MIT"
] | null | null | null | tests/test_facade.py | seucolega/lista-de-listas-cli | 48815fac9cf3332c5e4fbc935d6ddd09be2738a8 | [
"MIT"
] | null | null | null | import facade
import pytest
import schemas
| 24.484962 | 79 | 0.76094 |
2607fe4913aa92b0a573f52ce885f77ac1e7a144 | 17,667 | py | Python | ots_eval/outlier_detection/doots.py | YellowOfTheEgg/ots-eval | 8ec08e60330d41f8f7ffd571dd6301cdedaefd99 | [
"BSD-3-Clause"
] | 3 | 2021-03-28T14:46:57.000Z | 2022-01-03T17:25:19.000Z | ots_eval/outlier_detection/doots.py | YellowOfTheEgg/ots-eval | 8ec08e60330d41f8f7ffd571dd6301cdedaefd99 | [
"BSD-3-Clause"
] | null | null | null | ots_eval/outlier_detection/doots.py | YellowOfTheEgg/ots-eval | 8ec08e60330d41f8f7ffd571dd6301cdedaefd99 | [
"BSD-3-Clause"
] | 1 | 2022-01-11T10:56:14.000Z | 2022-01-11T10:56:14.000Z | import pandas
import numpy as np
from .reference_histogram_outlier import HistOutlier
from typing import Union, Tuple
| 49.487395 | 138 | 0.572819 |
260902dd3e508f3dd93dbd19435e62ca56223adf | 3,405 | py | Python | SWIG_fast_functions/test.py | twni2016/OrganSegRSTN_PyTorch | bf571320e718c8f138e04d48645e3b4dfe75801d | [
"MIT"
] | 100 | 2018-08-01T04:42:36.000Z | 2022-03-23T07:01:21.000Z | SWIG_fast_functions/test.py | bharat3012/OrganSegRSTN_PyTorch | aff23489b1f3006761e3270178adfcccb63d0de9 | [
"MIT"
] | 12 | 2018-08-07T10:35:47.000Z | 2022-02-21T09:09:42.000Z | SWIG_fast_functions/test.py | bharat3012/OrganSegRSTN_PyTorch | aff23489b1f3006761e3270178adfcccb63d0de9 | [
"MIT"
] | 35 | 2018-08-06T21:27:36.000Z | 2021-11-03T10:20:16.000Z | import numpy as np
import fast_functions as ff
import time
print('python')
G = np.zeros((512,512,240),dtype=np.uint8)
G[128:384,128:384,60:180]=1
volume_data = np.load('1.npz')
F = volume_data['volume'].astype(np.uint8)
start_time = time.time()
F = post_processing(F, F, 1.0, False)
print(time.time() - start_time)
st... | 29.608696 | 85 | 0.595888 |
260aad7a8e1f7dc10f9fc0b29cb23cbf4ba1d39e | 221 | py | Python | smart-chatbot-zero/Rerank/data_preprocess1.py | WenRichard/Customer-Chatbot | 48508c40574ffac8ced414a5bea799e2c85341ca | [
"MIT"
] | 268 | 2019-07-26T01:40:43.000Z | 2022-03-28T14:54:57.000Z | xiaotian-chatbot1.0/Rerank/data_preprocess1.py | abc668/Customer-Chatbot | 48508c40574ffac8ced414a5bea799e2c85341ca | [
"MIT"
] | 7 | 2019-08-13T04:17:55.000Z | 2020-08-06T08:57:34.000Z | xiaotian-chatbot1.0/Rerank/data_preprocess1.py | abc668/Customer-Chatbot | 48508c40574ffac8ced414a5bea799e2c85341ca | [
"MIT"
] | 113 | 2019-07-26T01:40:47.000Z | 2022-03-18T13:22:44.000Z | # -*- coding: utf-8 -*-
# @Time : 2019/5/25 16:09
# @Author : Alan
# @Email : xiezhengwen2013@163.com
# @File : data_preprocess2.py
# @Software: PyCharm
# | 20.090909 | 36 | 0.638009 |
260b023afea60f62495ec2404352213dae65708e | 1,160 | py | Python | PageMonitor/project/lib/config.py | DanylZhang/IdeaWorkspace | 726be80db4ca7dac4104ebaa22b795f37aca73e0 | [
"MIT"
] | null | null | null | PageMonitor/project/lib/config.py | DanylZhang/IdeaWorkspace | 726be80db4ca7dac4104ebaa22b795f37aca73e0 | [
"MIT"
] | null | null | null | PageMonitor/project/lib/config.py | DanylZhang/IdeaWorkspace | 726be80db4ca7dac4104ebaa22b795f37aca73e0 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# coding:utf-8
import pymysql
default_config = {
'host': '139.196.96.149',
'port': 13306,
'user': 'dataway-rw',
'password': 'QqHVMhmN*8',
'db': 'jumei',
'charset': 'utf8mb4'
}
apollo_config = {
'host': '127.0.0.1',
'port': 11306,
'user': 'apollo-rw',
'passw... | 20.714286 | 45 | 0.546552 |
260b70a7a637b6e3448163b26c95e89556398218 | 70 | py | Python | 24/aoc24-1-cython.py | combs/AdventOfCode2021 | 925df8a3526cb9c0dde368cf828673f345096e06 | [
"MIT"
] | null | null | null | 24/aoc24-1-cython.py | combs/AdventOfCode2021 | 925df8a3526cb9c0dde368cf828673f345096e06 | [
"MIT"
] | null | null | null | 24/aoc24-1-cython.py | combs/AdventOfCode2021 | 925df8a3526cb9c0dde368cf828673f345096e06 | [
"MIT"
] | null | null | null | import pyximport
pyximport.install()
from aoc24 import do_it
do_it()
| 11.666667 | 23 | 0.8 |
260b9f9c6262684a4bbfdcc0510786d9313421e4 | 358 | py | Python | tests/main.py | zodiuxus/opensimplex | d8c761d91834a809e51987d25439549c50f0effb | [
"MIT"
] | null | null | null | tests/main.py | zodiuxus/opensimplex | d8c761d91834a809e51987d25439549c50f0effb | [
"MIT"
] | null | null | null | tests/main.py | zodiuxus/opensimplex | d8c761d91834a809e51987d25439549c50f0effb | [
"MIT"
] | null | null | null | from opensimplex import OpenSimplex
import torch, time
print(opensimplex_test('cuda'))
print('')
print(opensimplex_test('cpu')) | 27.538462 | 47 | 0.701117 |
260c11b37ca0f5a211fd4291ad4e8a2a93dbd3d4 | 83 | py | Python | pybktreespellchecker/__init__.py | tomasrasymas/pybktree-spell-checker | e1f7547957a4257a9b6ce470ebc8bcc95767c5d4 | [
"MIT"
] | 3 | 2019-01-07T21:34:29.000Z | 2020-07-20T23:43:01.000Z | pybktreespellchecker/__init__.py | tomasrasymas/pybktree-spell-checker | e1f7547957a4257a9b6ce470ebc8bcc95767c5d4 | [
"MIT"
] | null | null | null | pybktreespellchecker/__init__.py | tomasrasymas/pybktree-spell-checker | e1f7547957a4257a9b6ce470ebc8bcc95767c5d4 | [
"MIT"
] | null | null | null | from .levenshtein_distance import levenshtein_distance
from .bk_tree import BKTree
| 27.666667 | 54 | 0.879518 |
260d3744fb17af1e21703f4ae4917654e0d07e54 | 10,731 | py | Python | part1/ELMo/modules/elmo.py | peter850706/Contextual-embeddings-for-sequence-classification | e26ba68f6aa30ec07319dcd37a04a8f56e07d7b0 | [
"MIT"
] | null | null | null | part1/ELMo/modules/elmo.py | peter850706/Contextual-embeddings-for-sequence-classification | e26ba68f6aa30ec07319dcd37a04a8f56e07d7b0 | [
"MIT"
] | null | null | null | part1/ELMo/modules/elmo.py | peter850706/Contextual-embeddings-for-sequence-classification | e26ba68f6aa30ec07319dcd37a04a8f56e07d7b0 | [
"MIT"
] | null | null | null | import torch
import torch.nn as nn
from torch.nn.utils.rnn import pack_padded_sequence, pad_packed_sequence
from collections import namedtuple
from ELMo.modules.char_embedding import CharEmbedding
| 63.875 | 191 | 0.594353 |
260d56541b9590ff3dcf8aa4ac7f649e63e42413 | 3,106 | py | Python | src/app/externalOutages/createRealTimeOutage.py | nagasudhirpulla/wrldc_codebook | 8fbc795074e16e2012b29ae875b99aa721a7f021 | [
"MIT"
] | null | null | null | src/app/externalOutages/createRealTimeOutage.py | nagasudhirpulla/wrldc_codebook | 8fbc795074e16e2012b29ae875b99aa721a7f021 | [
"MIT"
] | 21 | 2021-01-08T18:03:32.000Z | 2021-02-02T16:17:34.000Z | src/app/externalOutages/createRealTimeOutage.py | nagasudhirpulla/wrldc_codebook | 8fbc795074e16e2012b29ae875b99aa721a7f021 | [
"MIT"
] | null | null | null | import datetime as dt
import cx_Oracle
from src.app.externalOutages.getReasonId import getReasonId
def createRealTimeOutage(pwcDbConnStr: str, elemTypeId: int, elementId: int, outageDt: dt.datetime, outageTypeId: int,
reason: str, elementName: str, sdReqId: int, outageTagId: int) -> int:
... | 36.541176 | 118 | 0.640052 |