hexsha stringlengths 40 40 | size int64 1 1.03M | ext stringclasses 10
values | lang stringclasses 1
value | max_stars_repo_path stringlengths 3 239 | max_stars_repo_name stringlengths 5 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 239 | max_issues_repo_name stringlengths 5 130 | max_issues_repo_head_hexsha stringlengths 40 78 | max_issues_repo_licenses listlengths 1 10 | max_issues_count int64 1 67k ⌀ | max_issues_repo_issues_event_min_datetime stringlengths 24 24 ⌀ | max_issues_repo_issues_event_max_datetime stringlengths 24 24 ⌀ | max_forks_repo_path stringlengths 3 239 | max_forks_repo_name stringlengths 5 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.03M | avg_line_length float64 1 958k | max_line_length int64 1 1.03M | alphanum_fraction float64 0 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4a1d9a438f2f3703f822efeaa971b9f5ab6ef6db | 1,381 | py | Python | pymocap/manager.py | markkorput/PyMoCap | b0fd963309326f7556ed4de9d4715af1b840a17e | [
"MIT"
] | 3 | 2016-12-15T23:08:54.000Z | 2021-02-28T08:46:36.000Z | pymocap/manager.py | markkorput/PyMoCap | b0fd963309326f7556ed4de9d4715af1b840a17e | [
"MIT"
] | null | null | null | pymocap/manager.py | markkorput/PyMoCap | b0fd963309326f7556ed4de9d4715af1b840a17e | [
"MIT"
] | null | null | null | from pymocap.event import Event
from pymocap.color_terminal import ColorTerminal
try:
import optirx as rx
except ImportError:
ColorTerminal().warn("importing embedded version of the optirx library for PyMoCap.Manager")
import pymocap.dependencies.optirx as rx
class Manager:
def __init__(self):
... | 32.880952 | 96 | 0.661115 |
4a1d9a79d0c32f0bf6cd0426c55a192e410c63f8 | 1,910 | py | Python | src/algorithms/pad.py | kristery/dmcontrol-generalization-benchmark | c732d3292e23ef70b9a5e1a9f573b51a5195d28d | [
"MIT"
] | 75 | 2020-11-30T07:59:09.000Z | 2022-03-30T21:26:53.000Z | src/algorithms/pad.py | kristery/dmcontrol-generalization-benchmark | c732d3292e23ef70b9a5e1a9f573b51a5195d28d | [
"MIT"
] | 12 | 2021-02-02T09:03:44.000Z | 2022-03-29T19:17:39.000Z | src/algorithms/pad.py | kristery/dmcontrol-generalization-benchmark | c732d3292e23ef70b9a5e1a9f573b51a5195d28d | [
"MIT"
] | 18 | 2020-12-04T03:48:34.000Z | 2022-03-21T15:10:08.000Z | import numpy as np
import torch
import torch.nn as nn
import torch.nn.functional as F
from copy import deepcopy
import utils
import algorithms.modules as m
from algorithms.sac import SAC
class PAD(SAC):
def __init__(self, obs_shape, action_shape, args):
super().__init__(obs_shape, action_shape, args)
self.aux_up... | 29.84375 | 90 | 0.743455 |
4a1d9aec3e7c7cdfbda54f92812392c9b457f015 | 4,616 | py | Python | src/qnet/printing/sreprprinter.py | amitkumarj441/QNET | 4d4818b25b7e8e4497d017b7c21e622945326c6a | [
"MIT"
] | 54 | 2015-02-12T15:13:41.000Z | 2022-03-04T06:53:14.000Z | src/qnet/printing/sreprprinter.py | amitkumarj441/QNET | 4d4818b25b7e8e4497d017b7c21e622945326c6a | [
"MIT"
] | 90 | 2015-03-24T23:39:32.000Z | 2021-09-25T11:45:43.000Z | src/qnet/printing/sreprprinter.py | amitkumarj441/QNET | 4d4818b25b7e8e4497d017b7c21e622945326c6a | [
"MIT"
] | 21 | 2017-07-05T18:03:17.000Z | 2021-11-19T17:51:04.000Z | """Provides printers for a full-structured representation"""
from textwrap import dedent, indent
from sympy.core.basic import Basic as SympyBasic
from .base import QnetBasePrinter
from .sympy import SympyReprPrinter
from ._render_head_repr import render_head_repr
from qnet.algebra.core.abstract_algebra import Expres... | 36.0625 | 78 | 0.566508 |
4a1d9b30e265617d32c4e357e624e00479f17527 | 593 | py | Python | src/dc/core/OutgoingMessage.py | dc-blockchain/dc-core | fc6af8ce04d7b52f94c069f6ec05b0e419e07d70 | [
"MIT"
] | 1 | 2021-03-05T14:24:32.000Z | 2021-03-05T14:24:32.000Z | src/dc/core/OutgoingMessage.py | dc-blockchain/dc-core | fc6af8ce04d7b52f94c069f6ec05b0e419e07d70 | [
"MIT"
] | null | null | null | src/dc/core/OutgoingMessage.py | dc-blockchain/dc-core | fc6af8ce04d7b52f94c069f6ec05b0e419e07d70 | [
"MIT"
] | null | null | null | # coding=utf-8
# Distributed under the MIT software license, see the accompanying
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
from dc.core import config
from dc.core.misc import ntp
class OutgoingMessage:
def __init__(self, priority, message):
self.priority = priority
sel... | 31.210526 | 83 | 0.721754 |
4a1d9b4be3833573fe419c2c3fc8ea6fa6186958 | 1,003 | py | Python | kubernetes/test/test_authentication_v1_api.py | L3T/python | b6e4ae81a2afb49f668a142eb7d1c6e2571ef478 | [
"Apache-2.0"
] | 2 | 2020-06-21T08:03:18.000Z | 2020-06-21T09:53:29.000Z | kubernetes/test/test_authentication_v1_api.py | L3T/python | b6e4ae81a2afb49f668a142eb7d1c6e2571ef478 | [
"Apache-2.0"
] | null | null | null | kubernetes/test/test_authentication_v1_api.py | L3T/python | b6e4ae81a2afb49f668a142eb7d1c6e2571ef478 | [
"Apache-2.0"
] | 1 | 2020-12-10T07:28:08.000Z | 2020-12-10T07:28:08.000Z | # coding: utf-8
"""
Kubernetes
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501
OpenAPI spec version: release-1.16
Generated by: https://openapi-generator.tech
"""
from __future__ import absolute_import
import unittest
import... | 21.804348 | 124 | 0.706879 |
4a1d9d44e6ab37c8c363c1cbdd2c378f87bb29bf | 12,371 | py | Python | var/spack/repos/builtin/packages/openssl/package.py | michael-afanasiev/spack | 5b2ea726a0c1cc90f11bc0ae6e1e55bc73d58575 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | null | null | null | var/spack/repos/builtin/packages/openssl/package.py | michael-afanasiev/spack | 5b2ea726a0c1cc90f11bc0ae6e1e55bc73d58575 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | null | null | null | var/spack/repos/builtin/packages/openssl/package.py | michael-afanasiev/spack | 5b2ea726a0c1cc90f11bc0ae6e1e55bc73d58575 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | null | null | null | # Copyright 2013-2022 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
import re
import llnl.util.tty as tty
from spack import *
class Openssl(Package): # Uses Fake Autotools, s... | 53.323276 | 113 | 0.702368 |
4a1d9da76bf73a25deec856f5cad0d495c6935cc | 985 | py | Python | project_euler/problem_25/sol3.py | JB1959/Python | b6ca263983933c3ecc06ed0083dd11b6faf870c8 | [
"MIT"
] | 14 | 2020-10-03T05:43:48.000Z | 2021-11-01T21:02:26.000Z | project_euler/problem_25/sol3.py | JB1959/Python | b6ca263983933c3ecc06ed0083dd11b6faf870c8 | [
"MIT"
] | 8 | 2020-03-24T17:47:23.000Z | 2022-03-12T00:33:21.000Z | project_euler/problem_25/sol3.py | JB1959/Python | b6ca263983933c3ecc06ed0083dd11b6faf870c8 | [
"MIT"
] | 12 | 2020-10-03T05:44:19.000Z | 2022-01-16T05:37:54.000Z | """
The Fibonacci sequence is defined by the recurrence relation:
Fn = Fn−1 + Fn−2, where F1 = 1 and F2 = 1.
Hence the first 12 terms will be:
F1 = 1
F2 = 1
F3 = 2
F4 = 3
F5 = 5
F6 = 8
F7 = 13
F8 = 21
F9 = 34
F10 = 55
F11 = 89
F12 = 144
The 12th term, F12, is the ... | 17.280702 | 79 | 0.523858 |
4a1d9df5d6224b85751c3f1794044588a812f920 | 4,502 | py | Python | pubscience/translate/custom_translate_google.py | bramiozo/PubScience | 78b6a9ef81ea8764b2ed0adaddee4c1185d36fe5 | [
"Apache-2.0"
] | null | null | null | pubscience/translate/custom_translate_google.py | bramiozo/PubScience | 78b6a9ef81ea8764b2ed0adaddee4c1185d36fe5 | [
"Apache-2.0"
] | null | null | null | pubscience/translate/custom_translate_google.py | bramiozo/PubScience | 78b6a9ef81ea8764b2ed0adaddee4c1185d36fe5 | [
"Apache-2.0"
] | null | null | null | import six
from google.cloud import translate
import argparse
import benedict
import re
import os
from collections import deque
class Translate():
def __init__(self,
input_loc = None,
output_loc = None,
glos_loc = None,
source_lang='en',
... | 43.288462 | 119 | 0.607286 |
4a1d9ea71ddbc9275e8d03da01d80ba1392c0776 | 20,468 | py | Python | examples/terran/mass_reaper.py | Talv/python-sc2 | 436805aad8ae37998f10827dddee1bde9ea7885f | [
"MIT"
] | null | null | null | examples/terran/mass_reaper.py | Talv/python-sc2 | 436805aad8ae37998f10827dddee1bde9ea7885f | [
"MIT"
] | null | null | null | examples/terran/mass_reaper.py | Talv/python-sc2 | 436805aad8ae37998f10827dddee1bde9ea7885f | [
"MIT"
] | null | null | null | """
Bot that stays on 1base, goes 4 rax mass reaper
This bot is one of the first examples that are micro intensive
Bot has a chance to win against elite (=Difficulty.VeryHard) zerg AI
Bot made by Burny
"""
import random
import sc2
from sc2 import Race, Difficulty
from sc2.constants import *
from sc2.position import... | 51.949239 | 214 | 0.605775 |
4a1d9f0cc485e3b84001b782f5b11851b7fedfa4 | 305 | py | Python | python/rank4.py | berquist/eg | 4c368b12eaaffcf0af8032f10348cf8bc1c3957a | [
"Unlicense"
] | null | null | null | python/rank4.py | berquist/eg | 4c368b12eaaffcf0af8032f10348cf8bc1c3957a | [
"Unlicense"
] | null | null | null | python/rank4.py | berquist/eg | 4c368b12eaaffcf0af8032f10348cf8bc1c3957a | [
"Unlicense"
] | null | null | null | def rank4_simple(a, b):
assert a.shape == b.shape
da, db, dc, dd = a.shape
s = 0
for iia in range(da):
for iib in range(db):
for iic in range(dc):
for iid in range(dd):
s += a[iia, iib, iic, iid] * b[iia, iib, iic, iid]
return s
| 27.727273 | 70 | 0.47541 |
4a1d9f4099b1d0a40dd713ddbd8c1bb9623fba3e | 878 | py | Python | scripts/clean_lib.py | stajichlab/localizaTE | 31dd4fa22b2a38703855f7a86595f68547298048 | [
"MIT"
] | 1 | 2017-09-13T14:27:37.000Z | 2017-09-13T14:27:37.000Z | scripts/clean_lib.py | stajichlab/localizaTE | 31dd4fa22b2a38703855f7a86595f68547298048 | [
"MIT"
] | null | null | null | scripts/clean_lib.py | stajichlab/localizaTE | 31dd4fa22b2a38703855f7a86595f68547298048 | [
"MIT"
] | null | null | null | #######################################
#script for cleaning headers
##########################################
lib=open('all_TEs_cryne', 'r') # change here the input filename when necessary
for line in lib:
line=line.strip()
if ';seqs=' in line:
linef=line.strip()
linef=linef.split(';seqs')
linea=l... | 21.95 | 87 | 0.57631 |
4a1da03fc1060a1c19c78a7f990f45c47ae310f2 | 6,365 | py | Python | common/src/autogluon/common/features/infer_types.py | Kota28/autogluon | 83e18a3d3764ba89efa843c6af71164d4ae09b7f | [
"Apache-2.0"
] | 1 | 2022-02-19T13:22:26.000Z | 2022-02-19T13:22:26.000Z | common/src/autogluon/common/features/infer_types.py | Kota28/autogluon | 83e18a3d3764ba89efa843c6af71164d4ae09b7f | [
"Apache-2.0"
] | 3 | 2021-12-30T20:28:01.000Z | 2022-02-09T20:19:21.000Z | common/src/autogluon/common/features/infer_types.py | engsarah365/autogluon | bdbaac2d13d14d075b7aa751561f0bbd39927789 | [
"Apache-2.0"
] | null | null | null | import logging
from collections import defaultdict
from typing import List
import numpy as np
import pandas as pd
from pandas import DataFrame, Series
logger = logging.getLogger(__name__)
def get_type_family_raw(dtype) -> str:
"""From dtype, gets the dtype family."""
try:
if isinstance(dtype, pd.Spa... | 34.972527 | 170 | 0.666457 |
4a1da18a8a855097d76925fc7f9d8f798b1efae8 | 6,803 | py | Python | path_planning/helpers/geometry.py | omuryildirim/vecihi | 76de1ea31954b74d4107b027ed1fcc30532a61bc | [
"MIT"
] | null | null | null | path_planning/helpers/geometry.py | omuryildirim/vecihi | 76de1ea31954b74d4107b027ed1fcc30532a61bc | [
"MIT"
] | null | null | null | path_planning/helpers/geometry.py | omuryildirim/vecihi | 76de1ea31954b74d4107b027ed1fcc30532a61bc | [
"MIT"
] | null | null | null | # Helpful geometry functions
# Author -- Shikhar Dev Gupta
from math import *
from random import *
# Define a point class
from urllib3.connectionpool import xrange
class point:
def __init__(self, x, y, obstacle=-1, test=-1):
self.x = x
self.y = y
self.obstacle = obstacle
# Kind of a radioactive tracker! S... | 25.965649 | 117 | 0.615611 |
4a1da1a7f5cb6cf537e10f24dbecaad7897228ab | 6,726 | py | Python | msgraph-cli-extensions/beta/financials_beta/azext_financials_beta/vendored_sdks/financials/operations/_financials_financials_operations.py | thewahome/msgraph-cli | 33127d9efa23a0e5f5303c93242fbdbb73348671 | [
"MIT"
] | null | null | null | msgraph-cli-extensions/beta/financials_beta/azext_financials_beta/vendored_sdks/financials/operations/_financials_financials_operations.py | thewahome/msgraph-cli | 33127d9efa23a0e5f5303c93242fbdbb73348671 | [
"MIT"
] | null | null | null | msgraph-cli-extensions/beta/financials_beta/azext_financials_beta/vendored_sdks/financials/operations/_financials_financials_operations.py | thewahome/msgraph-cli | 33127d9efa23a0e5f5303c93242fbdbb73348671 | [
"MIT"
] | null | null | null | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may ... | 42.840764 | 133 | 0.66399 |
4a1da1bde53a073a4b3841c4f6ee67bbeea73f5b | 79,936 | py | Python | stubs.min/System/Windows/Forms/__init___parts/DataGrid.py | denfromufa/ironpython-stubs | 4d2b405eda3ceed186e8adca55dd97c332c6f49d | [
"MIT"
] | 1 | 2017-07-07T11:15:45.000Z | 2017-07-07T11:15:45.000Z | stubs.min/System/Windows/Forms/__init___parts/DataGrid.py | hdm-dt-fb/ironpython-stubs | 4d2b405eda3ceed186e8adca55dd97c332c6f49d | [
"MIT"
] | null | null | null | stubs.min/System/Windows/Forms/__init___parts/DataGrid.py | hdm-dt-fb/ironpython-stubs | 4d2b405eda3ceed186e8adca55dd97c332c6f49d | [
"MIT"
] | null | null | null | class DataGrid(Control,IComponent,IDisposable,IOleControl,IOleObject,IOleInPlaceObject,IOleInPlaceActiveObject,IOleWindow,IViewObject,IViewObject2,IPersist,IPersistStreamInit,IPersistPropertyBag,IPersistStorage,IQuickActivate,ISupportOleDropSource,IDropTarget,ISynchronizeInvoke,IWin32Window,IArrangedElement,IBindableCo... | 33.086093 | 373 | 0.706278 |
4a1da43c9174e328f4efb1fe56a91cea4a44d016 | 8,455 | py | Python | social_auth/tests/odnoklassniki.py | Memrise/django-social-auth | ddfecb6f78f1dc53e66689264f1c95fc81b5d3be | [
"BSD-2-Clause",
"BSD-3-Clause"
] | 1 | 2018-06-11T17:35:10.000Z | 2018-06-11T17:35:10.000Z | social_auth/tests/odnoklassniki.py | Memrise/django-social-auth | ddfecb6f78f1dc53e66689264f1c95fc81b5d3be | [
"BSD-2-Clause",
"BSD-3-Clause"
] | null | null | null | social_auth/tests/odnoklassniki.py | Memrise/django-social-auth | ddfecb6f78f1dc53e66689264f1c95fc81b5d3be | [
"BSD-2-Clause",
"BSD-3-Clause"
] | null | null | null | # -*- coding:utf-8 -*-
from unittest import skipUnless
from django.conf import settings
from django.core.urlresolvers import reverse
from django.test.testcases import LiveServerTestCase, SimpleTestCase
from django.test.utils import override_settings
from selenium.webdriver.firefox.webdriver import WebDriver
from selen... | 54.548387 | 192 | 0.723714 |
4a1da5dc1b36a29eb0ff025cb0c08e8d9054960a | 14,970 | py | Python | ixnetwork_restpy/testplatform/sessions/ixnetwork/topology/configmdlevelsparams_1bf3d8514855f50e409c0aef7ac6bf1e.py | Vibaswan/ixnetwork_restpy | 239fedc7050890746cbabd71ea1e91c68d9e5cad | [
"MIT"
] | null | null | null | ixnetwork_restpy/testplatform/sessions/ixnetwork/topology/configmdlevelsparams_1bf3d8514855f50e409c0aef7ac6bf1e.py | Vibaswan/ixnetwork_restpy | 239fedc7050890746cbabd71ea1e91c68d9e5cad | [
"MIT"
] | null | null | null | ixnetwork_restpy/testplatform/sessions/ixnetwork/topology/configmdlevelsparams_1bf3d8514855f50e409c0aef7ac6bf1e.py | Vibaswan/ixnetwork_restpy | 239fedc7050890746cbabd71ea1e91c68d9e5cad | [
"MIT"
] | null | null | null | # MIT LICENSE
#
# Copyright 1997 - 2020 by IXIA Keysight
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"),
# to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify,... | 36.246973 | 431 | 0.654041 |
4a1da61fd1b57fc4cd34addeecd92efebffe4e4d | 9,681 | py | Python | apps/files/tasks.py | spasovski/zamboni | c7f4714029e3b2dc918ddfc2103f8e051193c14d | [
"BSD-3-Clause"
] | 1 | 2021-07-29T00:51:09.000Z | 2021-07-29T00:51:09.000Z | apps/files/tasks.py | imclab/olympia | 35bc9c484e384bafab520ca8b5d5b0f8da5b62c0 | [
"BSD-3-Clause"
] | null | null | null | apps/files/tasks.py | imclab/olympia | 35bc9c484e384bafab520ca8b5d5b0f8da5b62c0 | [
"BSD-3-Clause"
] | null | null | null | import hashlib
import logging
import os
import urllib
import urllib2
import urlparse
import uuid
from datetime import datetime
import django.core.mail
from django.conf import settings
from django.core.files.storage import default_storage as storage
from django.db import transaction
import jingo
from celeryutils impor... | 36.532075 | 79 | 0.622663 |
4a1da6f77351c45a4596cf09893fe6bf21db91d4 | 1,659 | py | Python | apyec/logs/parse_log.py | HazenBabcock/APyEC | 2377e4e6ae242ffc324487112541f1a2cf8b499c | [
"MIT"
] | 3 | 2015-09-30T14:08:02.000Z | 2021-02-18T02:49:01.000Z | apyec/logs/parse_log.py | HazenBabcock/APyEC | 2377e4e6ae242ffc324487112541f1a2cf8b499c | [
"MIT"
] | 4 | 2015-10-01T17:24:36.000Z | 2016-02-18T16:27:25.000Z | apyec/logs/parse_log.py | HazenBabcock/APyEC | 2377e4e6ae242ffc324487112541f1a2cf8b499c | [
"MIT"
] | null | null | null | #!/usr/bin/env python
#
## @file
#
# This parses log file series (i.e. log, log.1, log.2, etc..) to
# make it easier to see which functions / methods call which other
# functions / methods. It is used mostly to make sure that what
# we expect to happen is actually happening, and to try and
# identify unnecessary functi... | 26.333333 | 86 | 0.521398 |
4a1da7cdf7546536f339b7e4d30aac99e980b76b | 76,054 | py | Python | vobject/icalendar.py | karalan/google-tasks-porter | 58754f4ee5d478a780bc316bbeea5a5a82e1f6f7 | [
"Apache-2.0"
] | 1 | 2015-08-29T18:40:43.000Z | 2015-08-29T18:40:43.000Z | vobject/icalendar.py | karalan/google-tasks-porter | 58754f4ee5d478a780bc316bbeea5a5a82e1f6f7 | [
"Apache-2.0"
] | 4 | 2021-03-19T15:38:56.000Z | 2021-09-08T02:47:16.000Z | vendor-local/lib/python/vobject/icalendar.py | Acidburn0zzz/airmozilla | 7b03af6d6efe9af00a6070f5327e10fb755c3766 | [
"BSD-3-Clause"
] | 1 | 2019-11-02T23:29:13.000Z | 2019-11-02T23:29:13.000Z | """Definitions and behavior for iCalendar, also known as vCalendar 2.0"""
import string
import behavior
import dateutil.rrule
import dateutil.tz
import StringIO, cStringIO
import datetime
import socket, random #for generating a UID
import itertools
from base import (VObjectError, NativeError, ValidateError, ParseErro... | 39.673448 | 106 | 0.517369 |
4a1da7f53bffa9dfd6d061b5ca60bed559e2c638 | 11,213 | py | Python | data/prepare_retailrocket_dataset.py | btwardow/dml4rec | 3bc2ca4d85ef9f8d94f0ee0a07d1d67cec671e66 | [
"MIT"
] | 6 | 2021-03-29T14:47:43.000Z | 2021-11-19T08:19:25.000Z | data/prepare_retailrocket_dataset.py | btwardow/dml4rec | 3bc2ca4d85ef9f8d94f0ee0a07d1d67cec671e66 | [
"MIT"
] | null | null | null | data/prepare_retailrocket_dataset.py | btwardow/dml4rec | 3bc2ca4d85ef9f8d94f0ee0a07d1d67cec671e66 | [
"MIT"
] | 2 | 2021-01-24T17:16:36.000Z | 2021-10-19T07:50:06.000Z | import csv
import os
import json
import gzip
import math
from collections import deque
from datetime import datetime
import numpy as np
import pandas as pd
from rec.dataset.dataset import Dataset
import rec.model as m
directory = 'data/retailrocket/'
directory_input = directory + 'raw/'
input_path_events = directory... | 38.010169 | 123 | 0.595915 |
4a1da855698e8928b8bf01d8e594a7b036de6893 | 1,159 | py | Python | main.py | quervernetzt/active-directory-search-user-in-group | 80cadad6dc210095ac88b18b0eee6b0ade246f2d | [
"MIT"
] | null | null | null | main.py | quervernetzt/active-directory-search-user-in-group | 80cadad6dc210095ac88b18b0eee6b0ade246f2d | [
"MIT"
] | null | null | null | main.py | quervernetzt/active-directory-search-user-in-group | 80cadad6dc210095ac88b18b0eee6b0ade246f2d | [
"MIT"
] | null | null | null | from tests.tests_search import TestCasesSearch
from solution.group import Group
from solution.search import Search
if __name__ == "__main__":
###################################
# Tests
###################################
tests: TestCasesSearch = TestCasesSearch()
tests.execute_tests_is_user_in_gr... | 31.324324 | 74 | 0.647972 |
4a1daa471b61c17b61d5ac7fd5f6a1f8d79e31ef | 103 | py | Python | Miniature Hospital Management System/hospital_app/apps.py | Abdullah0297445/Django-Projects | 4864f48357cea4355bb618f46ef4930ac6e41126 | [
"MIT"
] | null | null | null | Miniature Hospital Management System/hospital_app/apps.py | Abdullah0297445/Django-Projects | 4864f48357cea4355bb618f46ef4930ac6e41126 | [
"MIT"
] | null | null | null | Miniature Hospital Management System/hospital_app/apps.py | Abdullah0297445/Django-Projects | 4864f48357cea4355bb618f46ef4930ac6e41126 | [
"MIT"
] | null | null | null | from django.apps import AppConfig
class hospitalAppConfig(AppConfig):
name = 'hospital_app'
| 17.166667 | 36 | 0.737864 |
4a1daa728e552abcb559c054f1880fa9356b861f | 666 | py | Python | abupy/AlphaBu/__init__.py | luqin/firefly | 2e5ab17f2d20deb3c68c927f6208ea89db7c639d | [
"MIT"
] | 1 | 2019-05-28T05:54:42.000Z | 2019-05-28T05:54:42.000Z | abupy/AlphaBu/__init__.py | momantang/cobrass | f11435d4836aa29078a3cd4beb4ca88967300c84 | [
"Apache-2.0"
] | 9 | 2020-03-24T16:45:25.000Z | 2022-03-11T23:40:51.000Z | abupy/AlphaBu/__init__.py | luqin/firefly | 2e5ab17f2d20deb3c68c927f6208ea89db7c639d | [
"MIT"
] | 1 | 2021-09-08T17:39:58.000Z | 2021-09-08T17:39:58.000Z | from __future__ import absolute_import
from .ABuPickBase import AbuPickTimeWorkBase, AbuPickStockWorkBase
from .ABuPickStockMaster import AbuPickStockMaster
from .ABuPickStockWorker import AbuPickStockWorker
from .ABuPickTimeWorker import AbuPickTimeWorker
from .ABuPickTimeMaster import AbuPickTimeMaster
from . imp... | 23.785714 | 66 | 0.795796 |
4a1dab25a34c6d2b76df54050bab0ede4c738591 | 6,119 | py | Python | cm/app/api_v1/my_calculation_module_directory/CM/CM_TUW23/f2_investment.py | HotMaps/dh_economic_assessment | 28393250b8f7a68552b90f7d8612fef216cc69e0 | [
"Apache-2.0"
] | null | null | null | cm/app/api_v1/my_calculation_module_directory/CM/CM_TUW23/f2_investment.py | HotMaps/dh_economic_assessment | 28393250b8f7a68552b90f7d8612fef216cc69e0 | [
"Apache-2.0"
] | 1 | 2022-03-08T21:10:00.000Z | 2022-03-08T21:10:00.000Z | cm/app/api_v1/my_calculation_module_directory/CM/CM_TUW23/f2_investment.py | HotMaps/dh_economic_assessment | 28393250b8f7a68552b90f7d8612fef216cc69e0 | [
"Apache-2.0"
] | null | null | null | import os
import sys
import numpy as np
from osgeo import gdal
path = os.path.dirname(os.path.dirname(os.path.dirname(os.path.
abspath(__file__))))
if path not in sys.path:
sys.path.append(path)
from CM.CM_TUW0.rem_mk_dir import rm_file
from CM.CM_TUW19 import ... | 44.664234 | 153 | 0.680994 |
4a1dac3a1e7b43e1a13aa25af08d5de86c5d4b5a | 361 | py | Python | psatlib/contingency.py | nie93/psatlib | 19947658fb4162f325e729eab086121947d8306a | [
"MIT"
] | null | null | null | psatlib/contingency.py | nie93/psatlib | 19947658fb4162f325e729eab086121947d8306a | [
"MIT"
] | 2 | 2018-06-19T20:53:13.000Z | 2018-11-01T20:11:45.000Z | psatlib/contingency.py | nie93/psatlib | 19947658fb4162f325e729eab086121947d8306a | [
"MIT"
] | null | null | null | """ Contingency functions management. (To be dropped if not necessary)"""
__author__ = "Zhijie Nie"
import sys
if sys.version_info[0] == 2:
if sys.version_info[1] == 5:
from psat_python25 import *
elif sys.version_info[1] == 7:
from psat_python27 import *
elif sys.version_info[0] == 3:
from psa... | 24.066667 | 73 | 0.684211 |
4a1dac6ee14f83bfb763df7a5be3ad344de97294 | 2,197 | py | Python | unical_accounts/models.py | alranel/uniAuth | 1d9dd044b7c3722d40162fc116d536fe3dfd5c7b | [
"Apache-2.0"
] | null | null | null | unical_accounts/models.py | alranel/uniAuth | 1d9dd044b7c3722d40162fc116d536fe3dfd5c7b | [
"Apache-2.0"
] | null | null | null | unical_accounts/models.py | alranel/uniAuth | 1d9dd044b7c3722d40162fc116d536fe3dfd5c7b | [
"Apache-2.0"
] | 1 | 2020-01-09T08:57:28.000Z | 2020-01-09T08:57:28.000Z | import pycountry
from django.db import models
from django.utils.translation import ugettext_lazy as _
from django.contrib.auth.models import AbstractUser
from django.contrib.contenttypes.models import ContentType
from django.conf import settings
class User(AbstractUser):
GENDER= (
( 'male', _('Ma... | 45.770833 | 104 | 0.577151 |
4a1dacaacc72e64dff6c38cd7602e3a9155640fd | 8,000 | py | Python | custom/icds/management/commands/sanitize_phone_numbers.py | kkrampa/commcare-hq | d64d7cad98b240325ad669ccc7effb07721b4d44 | [
"BSD-3-Clause"
] | 1 | 2020-05-05T13:10:01.000Z | 2020-05-05T13:10:01.000Z | custom/icds/management/commands/sanitize_phone_numbers.py | kkrampa/commcare-hq | d64d7cad98b240325ad669ccc7effb07721b4d44 | [
"BSD-3-Clause"
] | 1 | 2019-12-09T14:00:14.000Z | 2019-12-09T14:00:14.000Z | custom/icds/management/commands/sanitize_phone_numbers.py | MaciejChoromanski/commcare-hq | fd7f65362d56d73b75a2c20d2afeabbc70876867 | [
"BSD-3-Clause"
] | 5 | 2015-11-30T13:12:45.000Z | 2019-07-01T19:27:07.000Z | from __future__ import absolute_import
from __future__ import unicode_literals
import csv342 as csv
import six
import sys
import time
from datetime import (
datetime,
date,
timedelta,
)
from io import open
from xml.etree import cElementTree as ElementTree
from django.core.management.base import BaseComma... | 40 | 112 | 0.67425 |
4a1daee1dad218c964895258b051f1446cf59455 | 14,871 | py | Python | keras/initializers.py | pokey/keras | 3e81b668ea0997d136f43baf32a57246ed6410a2 | [
"MIT"
] | 2 | 2018-01-14T04:05:14.000Z | 2021-07-11T04:41:54.000Z | keras/initializers.py | pokey/keras | 3e81b668ea0997d136f43baf32a57246ed6410a2 | [
"MIT"
] | null | null | null | keras/initializers.py | pokey/keras | 3e81b668ea0997d136f43baf32a57246ed6410a2 | [
"MIT"
] | null | null | null | from __future__ import absolute_import
import numpy as np
import six
from . import backend as K
from .utils.generic_utils import serialize_keras_object
from .utils.generic_utils import deserialize_keras_object
class Initializer(object):
"""Initializer base class: all initializers inherit from this class.
"""
... | 31.707889 | 79 | 0.601574 |
4a1dafaf1931f61c7a6dddb9ec38637ccb75d528 | 2,230 | py | Python | Authda/models.py | kryptn/Authda | 4716a34c0758c3e38efa0254f29d8ca68f01d6a4 | [
"MIT"
] | null | null | null | Authda/models.py | kryptn/Authda | 4716a34c0758c3e38efa0254f29d8ca68f01d6a4 | [
"MIT"
] | null | null | null | Authda/models.py | kryptn/Authda | 4716a34c0758c3e38efa0254f29d8ca68f01d6a4 | [
"MIT"
] | null | null | null | import bcrypt
from flask_sqlalchemy import SQLAlchemy
db = SQLAlchemy()
class Status:
invited = 'invited'
rejected = 'rejected'
submitted = 'submitted'
resubmitted = 'resubmitted'
@property
def enum(self):
return (self.invited,
self.rejected,
self.subm... | 26.235294 | 73 | 0.601794 |
4a1dafbba0a29ac2b5b5823dc945dff04bc7146c | 912 | py | Python | personal_utilities/chebyshev.py | dbstein/personal_utilities | 3a4c7d2416b13a87f88fc0e400b299d648e1e541 | [
"Apache-2.0"
] | null | null | null | personal_utilities/chebyshev.py | dbstein/personal_utilities | 3a4c7d2416b13a87f88fc0e400b299d648e1e541 | [
"Apache-2.0"
] | null | null | null | personal_utilities/chebyshev.py | dbstein/personal_utilities | 3a4c7d2416b13a87f88fc0e400b299d648e1e541 | [
"Apache-2.0"
] | null | null | null | import numpy as np
from .transformations import affine_transformation
def get_chebyshev_nodes(lb, ub, order):
"""
Provides chebyshev quadratures nodes
scaled to live on the interval [lb, ub], of specified order
The nodes are reversed from traditional chebyshev nodes
(so that the lowest valued ... | 32.571429 | 81 | 0.66557 |
4a1db0117b5f1f8dca3c5ba77a8b9c55a9201f34 | 91 | py | Python | finances/apps.py | ericmuh/recruitment-system | d9964e7c48ac8af74995e28f489135c1d8f940be | [
"MIT"
] | 2 | 2021-02-07T12:08:47.000Z | 2021-02-22T07:12:53.000Z | finances/apps.py | Paphra/recruitment-cms | 2894d5285a6da4ff47c114377968c8fda95c24b6 | [
"MIT"
] | null | null | null | finances/apps.py | Paphra/recruitment-cms | 2894d5285a6da4ff47c114377968c8fda95c24b6 | [
"MIT"
] | null | null | null | from django.apps import AppConfig
class FinancesConfig(AppConfig):
name = 'finances'
| 15.166667 | 33 | 0.758242 |
4a1db1607f8dad83b44cb0dbba143a9d435220a0 | 3,102 | py | Python | Kaggle_FinalProject.py | iSriBalaji/MachineLearning | 6c1c5ac954485a0a385a9409cdbf00f7692cd4a1 | [
"MIT"
] | null | null | null | Kaggle_FinalProject.py | iSriBalaji/MachineLearning | 6c1c5ac954485a0a385a9409cdbf00f7692cd4a1 | [
"MIT"
] | null | null | null | Kaggle_FinalProject.py | iSriBalaji/MachineLearning | 6c1c5ac954485a0a385a9409cdbf00f7692cd4a1 | [
"MIT"
] | null | null | null | # Code you have previously used to load data
import pandas as pd
from sklearn.ensemble import RandomForestRegressor
from sklearn.metrics import mean_absolute_error
from sklearn.model_selection import train_test_split
from sklearn.tree import DecisionTreeRegressor
# Set up code checking
import os
# if not os.path.exist... | 38.775 | 103 | 0.779819 |
4a1db16677cd6bb753faa4af41f3f7666d60e789 | 14,728 | py | Python | sympy/functions/elementary/miscellaneous.py | lidavidm/sympy | 971aa94ee6d0774eacfb4aed6965195c4a59e104 | [
"BSD-3-Clause"
] | null | null | null | sympy/functions/elementary/miscellaneous.py | lidavidm/sympy | 971aa94ee6d0774eacfb4aed6965195c4a59e104 | [
"BSD-3-Clause"
] | null | null | null | sympy/functions/elementary/miscellaneous.py | lidavidm/sympy | 971aa94ee6d0774eacfb4aed6965195c4a59e104 | [
"BSD-3-Clause"
] | null | null | null | from __future__ import print_function, division
from sympy.core import S, C, sympify
from sympy.core.add import Add
from sympy.core.basic import Basic
from sympy.core.containers import Tuple
from sympy.core.numbers import Rational
from sympy.core.operations import LatticeOp, ShortCircuit
from sympy.core.function impor... | 26.536937 | 80 | 0.544541 |
4a1db1da613d143233f5561646a1828a90110f45 | 3,133 | py | Python | sample_code_mixed_words_model_meta.py | onai/code-mixing-toolbox | b5b53ca12f8f356fb8b38cceb82105c8c2f7f03c | [
"Apache-2.0"
] | null | null | null | sample_code_mixed_words_model_meta.py | onai/code-mixing-toolbox | b5b53ca12f8f356fb8b38cceb82105c8c2f7f03c | [
"Apache-2.0"
] | null | null | null | sample_code_mixed_words_model_meta.py | onai/code-mixing-toolbox | b5b53ca12f8f356fb8b38cceb82105c8c2f7f03c | [
"Apache-2.0"
] | null | null | null | from fastText import load_model
import joblib
import numpy as np
import sys
def isEnglish(s):
try:
s.encode(encoding='utf-8').decode('ascii')
except UnicodeDecodeError:
return False
else:
return True
def is_fence_word(w_embed, center1, center2):
distance1 = np.linalg.norm(w_emb... | 28.743119 | 110 | 0.532397 |
4a1db20289da0e284fc2ec5b7c6baf51bc7fe618 | 184 | py | Python | basic_grammar/tuple_usecase.py | OnoYuta/python_programing | 5d191bef5666c0a826f6daa0bd45bc9dd6603d59 | [
"MIT"
] | null | null | null | basic_grammar/tuple_usecase.py | OnoYuta/python_programing | 5d191bef5666c0a826f6daa0bd45bc9dd6603d59 | [
"MIT"
] | null | null | null | basic_grammar/tuple_usecase.py | OnoYuta/python_programing | 5d191bef5666c0a826f6daa0bd45bc9dd6603d59 | [
"MIT"
] | null | null | null | # 選択肢が書き換えられないようにlistではなくtupleを使う
chose_from_two = ('A', 'B', 'C')
answer = []
answer.append('A')
answer.append('C')
print(chose_from_two)
# ('A', 'B', 'C')
print(answer)
# ['A', 'C'] | 18.4 | 33 | 0.625 |
4a1db24c1cc44f6ced025c7dd4965261762a90d1 | 13,019 | py | Python | rubymarshal/reader.py | Inejka/rvdata2_parser | 2f99c84b552b634012f13b2259945622cf5a85e3 | [
"WTFPL"
] | null | null | null | rubymarshal/reader.py | Inejka/rvdata2_parser | 2f99c84b552b634012f13b2259945622cf5a85e3 | [
"WTFPL"
] | null | null | null | rubymarshal/reader.py | Inejka/rvdata2_parser | 2f99c84b552b634012f13b2259945622cf5a85e3 | [
"WTFPL"
] | null | null | null | import io
import re
import zlib
link_error_str = "LINK_ERROR_IND_"
class MyList(list):
def __hash__(self):
temp_hash = 0
for i in self:
temp_hash += hash(i)
return temp_hash
class MyDict(dict):
def __hash__(self):
temp_hash = 0
for i in self:
... | 34.81016 | 153 | 0.529764 |
4a1db27406b1279987d4e01fd3ca6777f37ac5b3 | 588 | py | Python | leopy/algorithm/recursion.py | pobingxiaoxiao/leopy | c6fc291cfcd5a8fa58614873edac9b09f20f2e0a | [
"MIT"
] | null | null | null | leopy/algorithm/recursion.py | pobingxiaoxiao/leopy | c6fc291cfcd5a8fa58614873edac9b09f20f2e0a | [
"MIT"
] | null | null | null | leopy/algorithm/recursion.py | pobingxiaoxiao/leopy | c6fc291cfcd5a8fa58614873edac9b09f20f2e0a | [
"MIT"
] | 1 | 2019-06-10T02:09:46.000Z | 2019-06-10T02:09:46.000Z | def recursion_sum(data_list):
if data_list == []:
return 0
else:
sum_1 = data_list.pop(0)
return sum_1+recursion_sum(data_list)
def recursion_listCount(data_list):
if data_list == []:
return 0
else:
data_list.pop(0)
return 1+recursion_listCount(data_list)... | 23.52 | 47 | 0.613946 |
4a1db306666b3dfb3d27309790117993457e4cf7 | 2,562 | py | Python | topo_processor/metadata/csv_loader/tests/csv_loader_test.py | linz/processor-aerial-imagery | cf6425560cea381278fe7857865e3d9158b28d7e | [
"MIT"
] | null | null | null | topo_processor/metadata/csv_loader/tests/csv_loader_test.py | linz/processor-aerial-imagery | cf6425560cea381278fe7857865e3d9158b28d7e | [
"MIT"
] | 15 | 2020-07-21T04:56:31.000Z | 2020-09-21T06:28:57.000Z | topo_processor/metadata/csv_loader/tests/csv_loader_test.py | linz/processor-aerial-imagery | cf6425560cea381278fe7857865e3d9158b28d7e | [
"MIT"
] | null | null | null | import csv
import os
import tempfile
import pytest
from topo_processor.metadata.csv_loader.csv_loader import read_csv
def test_read_csv() -> None:
metadata_path = os.path.join(os.getcwd(), "test_data", "historical_aerial_photos_metadata.csv")
metadata = read_csv(metadata_path, "raw_filename", "sufi")
a... | 25.62 | 126 | 0.554254 |
4a1db3c071ddb26e3c870ed3b1cb393528c49529 | 2,623 | py | Python | improviser-client/improviser_client/api/exercises_to_tags/post_exercises_to_tags_resource_list.py | acidjunk/improviser-api-client | f4c9ad69f2cbb0ac677cf49115f0f541035160da | [
"MIT"
] | null | null | null | improviser-client/improviser_client/api/exercises_to_tags/post_exercises_to_tags_resource_list.py | acidjunk/improviser-api-client | f4c9ad69f2cbb0ac677cf49115f0f541035160da | [
"MIT"
] | null | null | null | improviser-client/improviser_client/api/exercises_to_tags/post_exercises_to_tags_resource_list.py | acidjunk/improviser-api-client | f4c9ad69f2cbb0ac677cf49115f0f541035160da | [
"MIT"
] | null | null | null | from typing import Any, Dict, Optional, Union
import httpx
from ...client import Client
from ...models.exercise_to_tag import ExerciseToTag
from ...types import UNSET, Response, Unset
def _get_kwargs(
*,
client: Client,
json_body: ExerciseToTag,
x_fields: Union[Unset, str] = UNSET,
) -> Dict[str, An... | 22.042017 | 76 | 0.632101 |
4a1db642ce67f01fbf13e5e1e9b4ac1d315b4015 | 3,497 | py | Python | DepreciatedPlayers/Player_Nega.py | karlflores/WatchYourBackProject | 00a7c32e46ea0b75580d17ea6a22372e4a005627 | [
"Unlicense"
] | null | null | null | DepreciatedPlayers/Player_Nega.py | karlflores/WatchYourBackProject | 00a7c32e46ea0b75580d17ea6a22372e4a005627 | [
"Unlicense"
] | null | null | null | DepreciatedPlayers/Player_Nega.py | karlflores/WatchYourBackProject | 00a7c32e46ea0b75580d17ea6a22372e4a005627 | [
"Unlicense"
] | null | null | null | from Constants import constant
from DepreciatedBoard.Board import Board
from Agents.Negamax import Negamax
# from Agents.GreedyAlphaBeta import GreedyAlphaBetaMinimax
class Player:
def __init__(self, colour):
if colour == 'white':
self.colour = constant.WHITE_PIECE
elif colour == 'bla... | 39.292135 | 87 | 0.648556 |
4a1db7bfbe0a19db3510ab41a966d2a31fe0e487 | 21,292 | py | Python | esrally/mechanic/team.py | akhil-rane/rally | bc5513ca3a5a9faaebabf952af196335467a289a | [
"Apache-2.0"
] | null | null | null | esrally/mechanic/team.py | akhil-rane/rally | bc5513ca3a5a9faaebabf952af196335467a289a | [
"Apache-2.0"
] | null | null | null | esrally/mechanic/team.py | akhil-rane/rally | bc5513ca3a5a9faaebabf952af196335467a289a | [
"Apache-2.0"
] | null | null | null | import os
import logging
import configparser
from enum import Enum
import tabulate
from esrally import exceptions, PROGRAM_NAME
from esrally.utils import console, repo, io, modules
TEAM_FORMAT_VERSION = 1
def _path_for(team_root_path, team_member_type):
root_path = os.path.join(team_root_path, team_member_type... | 43.364562 | 140 | 0.630472 |
4a1dba9fe73f65c511d86263fdbaeda7b751a440 | 1,513 | py | Python | PixivRanking.py | hsheric0210/PixivUtil2 | 95ca633ec869169d091be55695cf863a0b582d6a | [
"BSD-2-Clause"
] | 1 | 2022-02-08T10:29:40.000Z | 2022-02-08T10:29:40.000Z | PixivRanking.py | hsheric0210/PixivUtil2 | 95ca633ec869169d091be55695cf863a0b582d6a | [
"BSD-2-Clause"
] | null | null | null | PixivRanking.py | hsheric0210/PixivUtil2 | 95ca633ec869169d091be55695cf863a0b582d6a | [
"BSD-2-Clause"
] | null | null | null | import json
from PixivException import PixivException
class PixivRanking:
mode = ""
curr_page = 0
next_page = None
prev_page = None
curr_date = ""
next_date = None
prev_date = None
rank_total = 0
contents = list()
filters = None
def __init__(self, js_str, filters):
... | 27.017857 | 90 | 0.607403 |
4a1dbaaee7965d093e4b82b5af5b8c8c77a3e4b3 | 1,055 | py | Python | python/pycylon/examples/table_math_operators.py | chathurawidanage/cylon | ac61b7a50880138fe67de21adee208016a94979a | [
"Apache-2.0"
] | null | null | null | python/pycylon/examples/table_math_operators.py | chathurawidanage/cylon | ac61b7a50880138fe67de21adee208016a94979a | [
"Apache-2.0"
] | null | null | null | python/pycylon/examples/table_math_operators.py | chathurawidanage/cylon | ac61b7a50880138fe67de21adee208016a94979a | [
"Apache-2.0"
] | null | null | null | ##
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the... | 21.530612 | 74 | 0.708057 |
4a1dbd5e4608108903210d6751da9c63a297c61a | 2,941 | py | Python | spark-1.3.0/python/build/py4j/tests/java_map_test.py | iflink/spark | 3b6b0c2cbdc1f939fb60ef5717ffbe232ebceee5 | [
"Apache-2.0"
] | null | null | null | spark-1.3.0/python/build/py4j/tests/java_map_test.py | iflink/spark | 3b6b0c2cbdc1f939fb60ef5717ffbe232ebceee5 | [
"Apache-2.0"
] | null | null | null | spark-1.3.0/python/build/py4j/tests/java_map_test.py | iflink/spark | 3b6b0c2cbdc1f939fb60ef5717ffbe232ebceee5 | [
"Apache-2.0"
] | 1 | 2020-07-23T22:14:41.000Z | 2020-07-23T22:14:41.000Z | '''
Created on Feb 5, 2010
@author: barthelemy
'''
from __future__ import unicode_literals, absolute_import
from multiprocessing import Process
import subprocess
import time
import unittest
from py4j.java_gateway import JavaGateway
from py4j.tests.java_gateway_test import PY4J_JAVA_PATH, safe_shutdown
def start_ex... | 24.714286 | 72 | 0.565794 |
4a1dbe69f4769cccdcc705d2c7843d9f46a58011 | 212 | py | Python | configs/_base_/schedules/imagenet_bs256.py | anthracene/mmclassification | 4b46fd6dc75d26b5604fdec75f6cc49e1d96d2a7 | [
"Apache-2.0"
] | 31 | 2020-11-14T02:47:54.000Z | 2021-12-14T06:26:10.000Z | configs/_base_/schedules/imagenet_bs256.py | anthracene/mmclassification | 4b46fd6dc75d26b5604fdec75f6cc49e1d96d2a7 | [
"Apache-2.0"
] | null | null | null | configs/_base_/schedules/imagenet_bs256.py | anthracene/mmclassification | 4b46fd6dc75d26b5604fdec75f6cc49e1d96d2a7 | [
"Apache-2.0"
] | 4 | 2021-01-14T18:12:38.000Z | 2021-11-11T11:46:50.000Z | # optimizer
optimizer = dict(type='SGD', lr=0.1, momentum=0.9, weight_decay=0.0001)
optimizer_config = dict(grad_clip=None)
# learning policy
lr_config = dict(policy='step', step=[30, 60, 90])
total_epochs = 100
| 30.285714 | 71 | 0.731132 |
4a1dbe78a0b3edbd7171df2545b2f3e259980540 | 339 | py | Python | 8_Tran_Vu_Ngoc_Thach/bai 2.4.py | lpython2006e/exercies | 84343eae57d86708a7984aa02f77183a4688a508 | [
"MIT"
] | null | null | null | 8_Tran_Vu_Ngoc_Thach/bai 2.4.py | lpython2006e/exercies | 84343eae57d86708a7984aa02f77183a4688a508 | [
"MIT"
] | null | null | null | 8_Tran_Vu_Ngoc_Thach/bai 2.4.py | lpython2006e/exercies | 84343eae57d86708a7984aa02f77183a4688a508 | [
"MIT"
] | 8 | 2020-07-10T14:13:54.000Z | 2020-08-03T08:17:50.000Z | """Write a function that returns the elements on odd positions in a list."""
def odd_elements_list(a):
odd_list = []
for i in range(0, len(a)):
if i % 2 != 0:
odd_list.append(a[i])
else:
i += 1
return odd_list
mylist = [1, 4, 5, 100, 2, 1, -1, -7]
odd = odd_elements_list(... | 19.941176 | 76 | 0.569322 |
4a1dbe89ce8a5f1ad91bb7865aff8ba48addfce9 | 246 | py | Python | encoder/data_objects/__init__.py | fujiaxiang/Real-Time-Voice-Cloning | 3b182258724c7d2cda94d418a3ad0c03dd29b302 | [
"MIT"
] | null | null | null | encoder/data_objects/__init__.py | fujiaxiang/Real-Time-Voice-Cloning | 3b182258724c7d2cda94d418a3ad0c03dd29b302 | [
"MIT"
] | null | null | null | encoder/data_objects/__init__.py | fujiaxiang/Real-Time-Voice-Cloning | 3b182258724c7d2cda94d418a3ad0c03dd29b302 | [
"MIT"
] | null | null | null | from encoder.data_objects.speaker_verification_dataset import SpeakerVerificationDataset
from encoder.data_objects.speaker_verification_dataset import SpeakerVerificationDataLoader
from encoder.data_objects.iemocap_dataset import IemocapDataset
| 49.2 | 91 | 0.922764 |
4a1dbe92044620b666a68392c4f361306a2e6260 | 2,632 | py | Python | zulip_bots/zulip_bots/bots/merels/libraries/game_data.py | benjaoming/python-zulip-api | d46935218022d82fed262fb485e112caa1aefd11 | [
"Apache-2.0"
] | 1 | 2020-06-17T06:47:15.000Z | 2020-06-17T06:47:15.000Z | zulip_bots/zulip_bots/bots/merels/libraries/game_data.py | benjaoming/python-zulip-api | d46935218022d82fed262fb485e112caa1aefd11 | [
"Apache-2.0"
] | 7 | 2017-10-05T07:43:32.000Z | 2017-10-14T06:56:47.000Z | zulip_bots/zulip_bots/bots/merels/libraries/game_data.py | benjaoming/python-zulip-api | d46935218022d82fed262fb485e112caa1aefd11 | [
"Apache-2.0"
] | 1 | 2020-08-25T19:25:25.000Z | 2020-08-25T19:25:25.000Z | """This serves as a bridge between the database and the other modules.
In a nutshell, this module parses a tuple from database then translates it
into a more convenient naming for easier access. It also adds certain
functions that are useful for the function of the game.
"""
from . import mechanics
from .interface im... | 29.573034 | 83 | 0.590046 |
4a1dbfdf52541aaf98007989f74a978492dc6486 | 3,550 | py | Python | data_analysis/heat_maps/create_heatmaps/individual_populations_performance.py | migbash/energy-intern-backend | 41b9d2acf5e8d30c8d8d55b006c33b97267dc497 | [
"MIT"
] | null | null | null | data_analysis/heat_maps/create_heatmaps/individual_populations_performance.py | migbash/energy-intern-backend | 41b9d2acf5e8d30c8d8d55b006c33b97267dc497 | [
"MIT"
] | null | null | null | data_analysis/heat_maps/create_heatmaps/individual_populations_performance.py | migbash/energy-intern-backend | 41b9d2acf5e8d30c8d8d55b006c33b97267dc497 | [
"MIT"
] | 3 | 2019-09-11T04:14:15.000Z | 2021-03-01T15:16:57.000Z | import ast
import sys
import os
import pandas as pd
import seaborn as sns
import matplotlib.pyplot as plt
from typing import List
""" Creates heat maps summarising the satisfaction levels for each agent type when they make up 100% of the population.
This is completed for each simulation version.
Parameters
---------
... | 36.22449 | 156 | 0.700282 |
4a1dc0ea536020f110b45b8cedeeed1704f811a6 | 4,312 | py | Python | examples/FasterRCNN/dataset/dataset.py | s36934512/tensorpack | 78a16615f8c9e6993c2a14961ca3fdd05f7c273c | [
"Apache-2.0"
] | 4,404 | 2018-05-30T23:38:42.000Z | 2022-03-31T22:30:11.000Z | examples/FasterRCNN/dataset/dataset.py | s36934512/tensorpack | 78a16615f8c9e6993c2a14961ca3fdd05f7c273c | [
"Apache-2.0"
] | 771 | 2018-06-01T09:54:00.000Z | 2022-03-31T23:12:29.000Z | examples/FasterRCNN/dataset/dataset.py | s36934512/tensorpack | 78a16615f8c9e6993c2a14961ca3fdd05f7c273c | [
"Apache-2.0"
] | 1,412 | 2018-06-01T00:29:43.000Z | 2022-03-26T17:37:39.000Z | # -*- coding: utf-8 -*-
from collections import defaultdict
__all__ = ['DatasetRegistry', 'DatasetSplit']
class DatasetSplit():
"""
A class to load datasets, evaluate results for a datast split (e.g., "coco_train_2017")
To use your own dataset that's not in COCO format, write a subclass that
implem... | 35.344262 | 103 | 0.612477 |
4a1dc1222cf77efc73a21763cb4b30cf5f52c1cc | 3,520 | py | Python | ddpg.py | Kaixhin/spinning-up-basic | ac5f2219c3c6c657b460c3150572d8deb3abfba0 | [
"MIT"
] | 190 | 2019-01-18T16:20:05.000Z | 2022-01-20T05:28:03.000Z | ddpg.py | Kaixhin/spinning-up-basic | ac5f2219c3c6c657b460c3150572d8deb3abfba0 | [
"MIT"
] | 2 | 2019-01-26T18:16:33.000Z | 2019-03-03T23:05:06.000Z | ddpg.py | Kaixhin/spinning-up-basic | ac5f2219c3c6c657b460c3150572d8deb3abfba0 | [
"MIT"
] | 17 | 2019-01-24T11:17:59.000Z | 2021-06-27T10:08:44.000Z | from collections import deque
import random
import torch
from torch import optim
from tqdm import tqdm
from env import Env
from hyperparams import ACTION_NOISE, OFF_POLICY_BATCH_SIZE as BATCH_SIZE, DISCOUNT, HIDDEN_SIZE, LEARNING_RATE, MAX_STEPS, POLYAK_FACTOR, REPLAY_SIZE, TEST_INTERVAL, UPDATE_INTERVAL, UPDATE_START
... | 42.926829 | 196 | 0.710227 |
4a1dc14fd1c9f6fab7de6590537de88e041b8dc2 | 1,091 | py | Python | core/src/zeit/cms/repository/browser/unknown.py | rickdg/vivi | 16134ac954bf8425646d4ad47bdd1f372e089355 | [
"BSD-3-Clause"
] | 5 | 2019-05-16T09:51:29.000Z | 2021-05-31T09:30:03.000Z | core/src/zeit/cms/repository/browser/unknown.py | rickdg/vivi | 16134ac954bf8425646d4ad47bdd1f372e089355 | [
"BSD-3-Clause"
] | 107 | 2019-05-24T12:19:02.000Z | 2022-03-23T15:05:56.000Z | core/src/zeit/cms/repository/browser/unknown.py | rickdg/vivi | 16134ac954bf8425646d4ad47bdd1f372e089355 | [
"BSD-3-Clause"
] | 3 | 2020-08-14T11:01:17.000Z | 2022-01-08T17:32:19.000Z | # coding: utf8
import pprint
import zeit.cms.interfaces
import zope.component
class View(object):
def get_excerpt(self):
data = self.context.data.strip()
if len(data) < 100:
return data
return data[:100] + u'…'
def get_properties(self):
properties = zeit.connector... | 22.265306 | 75 | 0.628781 |
4a1dc1e523b20881e39f77e5e24cd2b574de469e | 44,147 | py | Python | second/pytorch/train.py | panfengsu/train_point_pillars | 016a126e080044c7b5f3a19c7404a79c0689c650 | [
"Apache-2.0"
] | null | null | null | second/pytorch/train.py | panfengsu/train_point_pillars | 016a126e080044c7b5f3a19c7404a79c0689c650 | [
"Apache-2.0"
] | null | null | null | second/pytorch/train.py | panfengsu/train_point_pillars | 016a126e080044c7b5f3a19c7404a79c0689c650 | [
"Apache-2.0"
] | null | null | null | import os
import pathlib
import pickle
import shutil
import time
from functools import partial
import fire
import numpy as np
import torch
from google.protobuf import text_format
from tensorboardX import SummaryWriter
import torchplus
import second.data.kitti_common as kitti
from second.builder import target_assigner... | 43.927363 | 131 | 0.574603 |
4a1dc202d2dc676f2573bfb84a86b41a4e07e3ac | 5,327 | py | Python | Proyecto_parqueadero/Proyecto_parqueadero.py | Erikarodriguez22/Clasealgoritmosyprogramacion | 518b5d49bbb6e4217f1395117f67a1f412870987 | [
"MIT"
] | 1 | 2021-09-18T19:06:14.000Z | 2021-09-18T19:06:14.000Z | Proyecto_parqueadero/Proyecto_parqueadero.py | Erikarodriguez22/Clasealgoritmosyprogramacion | 518b5d49bbb6e4217f1395117f67a1f412870987 | [
"MIT"
] | null | null | null | Proyecto_parqueadero/Proyecto_parqueadero.py | Erikarodriguez22/Clasealgoritmosyprogramacion | 518b5d49bbb6e4217f1395117f67a1f412870987 | [
"MIT"
] | null | null | null | """"
Entradas:
Nombre-->str-->n
Numerocedula-->int-->cd
tipodevehiculo-->int-->tipo
Registroplaca-->str-->placa
Salida:
valorapagar-->int-->vpag
tipoparqueadero-->int-->tipo
valorapagarcondescuento-->desc
lugardeparqueo-->int-->parqueo
"""
print("¡¡BIENVENIDO AL PARQUEADERO DE LA UNIVERSIDAD EAN!! 🥳 🤓")
usuario=int... | 30.44 | 257 | 0.635067 |
4a1dc255bf27523e4ff72381c2d0890bcdf89fb2 | 23 | py | Python | samtranslator/__init__.py | Rondineli/serverless-application-model | 895fcd5818cf7bcef1fe24afc3fd13b1eb796e17 | [
"Apache-2.0"
] | 1 | 2021-11-09T10:23:05.000Z | 2021-11-09T10:23:05.000Z | samtranslator/__init__.py | Rondineli/serverless-application-model | 895fcd5818cf7bcef1fe24afc3fd13b1eb796e17 | [
"Apache-2.0"
] | null | null | null | samtranslator/__init__.py | Rondineli/serverless-application-model | 895fcd5818cf7bcef1fe24afc3fd13b1eb796e17 | [
"Apache-2.0"
] | null | null | null | __version__ = "1.36.0"
| 11.5 | 22 | 0.652174 |
4a1dc4610a5aef21bcaaca3838652a385228fad5 | 289 | py | Python | molecule/ua/tests/test_default.py | GSA/datagov-deploy-common | 89371c869477ae9ddc9596c4c9248dd32b655fe6 | [
"CC0-1.0"
] | 3 | 2019-03-25T04:36:13.000Z | 2022-03-09T16:48:16.000Z | molecule/ua/tests/test_default.py | GSA/datagov-deploy-common | 89371c869477ae9ddc9596c4c9248dd32b655fe6 | [
"CC0-1.0"
] | 31 | 2019-04-02T19:58:51.000Z | 2021-09-23T23:34:44.000Z | molecule/ua/tests/test_default.py | GSA/datagov-deploy-common | 89371c869477ae9ddc9596c4c9248dd32b655fe6 | [
"CC0-1.0"
] | 2 | 2019-10-31T21:01:46.000Z | 2020-04-24T13:55:49.000Z | import os
import testinfra.utils.ansible_runner
testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner(
os.environ['MOLECULE_INVENTORY_FILE']).get_hosts('all')
def test_ua_package(host):
package = host.package("ubuntu-advantage-tools")
assert package.is_installed
| 22.230769 | 63 | 0.785467 |
4a1dc586bea2fbc2e9ca442424b96944f701c733 | 1,319 | py | Python | flask/test/data/setup_tables.py | spaudanjo/boxtribute | c29311a38721277a07b5e1dbcf36cf12bcd8b727 | [
"Apache-2.0"
] | null | null | null | flask/test/data/setup_tables.py | spaudanjo/boxtribute | c29311a38721277a07b5e1dbcf36cf12bcd8b727 | [
"Apache-2.0"
] | null | null | null | flask/test/data/setup_tables.py | spaudanjo/boxtribute | c29311a38721277a07b5e1dbcf36cf12bcd8b727 | [
"Apache-2.0"
] | null | null | null | from data.base import create_default_bases
from data.box import create_default_box
from data.box_state import create_default_box_state
from data.location import create_default_location
from data.organisation import create_default_organisation
from data.product import create_default_product
from data.product_category im... | 39.969697 | 80 | 0.8605 |
4a1dc6d2825fbccd6933d98485bebd6ceb241389 | 3,888 | py | Python | tensorflow_model_analysis/eval_saved_model/example_trainers/linear_classifier.py | hakanhp/chanel | 6825b60e86c46daabb18f40f1e45d3de2ff8e983 | [
"Apache-2.0"
] | null | null | null | tensorflow_model_analysis/eval_saved_model/example_trainers/linear_classifier.py | hakanhp/chanel | 6825b60e86c46daabb18f40f1e45d3de2ff8e983 | [
"Apache-2.0"
] | null | null | null | tensorflow_model_analysis/eval_saved_model/example_trainers/linear_classifier.py | hakanhp/chanel | 6825b60e86c46daabb18f40f1e45d3de2ff8e983 | [
"Apache-2.0"
] | null | null | null | # Copyright 2018 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... | 37.028571 | 80 | 0.709362 |
4a1dc8c3187291f9843e2385e5074b0f232dbc1b | 315 | py | Python | src/test/python/unit/collector/test_const.py | ettoreleandrotognoli/etto-robot | 602b6c00ac925ccdbf33e60f06feb5835c246d31 | [
"Apache-2.0"
] | null | null | null | src/test/python/unit/collector/test_const.py | ettoreleandrotognoli/etto-robot | 602b6c00ac925ccdbf33e60f06feb5835c246d31 | [
"Apache-2.0"
] | 6 | 2020-12-17T10:19:15.000Z | 2021-03-31T23:23:19.000Z | src/test/python/unit/collector/test_const.py | ettoreleandrotognoli/etto-robot | 602b6c00ac925ccdbf33e60f06feb5835c246d31 | [
"Apache-2.0"
] | 1 | 2021-08-30T20:38:00.000Z | 2021-08-30T20:38:00.000Z | from aiounittest import AsyncTestCase
from robot.collector.shortcut import *
class ConstCollectorTest(AsyncTestCase):
async def test_const(self):
any_value = 'any value'
collector = const(any_value)
_, result = await collector(None, None)
self.assertEqual(result, any_value)
| 24.230769 | 47 | 0.707937 |
4a1dc8fe6c6558a3a3083b5f3b48d93812b13e68 | 7,818 | py | Python | nova/tests/console/test_console.py | bopopescu/nova_vmware_compute_driver | 60d3936b68030647b9f11970c9e0d060fc286dd9 | [
"Apache-2.0"
] | null | null | null | nova/tests/console/test_console.py | bopopescu/nova_vmware_compute_driver | 60d3936b68030647b9f11970c9e0d060fc286dd9 | [
"Apache-2.0"
] | null | null | null | nova/tests/console/test_console.py | bopopescu/nova_vmware_compute_driver | 60d3936b68030647b9f11970c9e0d060fc286dd9 | [
"Apache-2.0"
] | 2 | 2019-07-08T22:12:35.000Z | 2020-07-24T08:27:24.000Z | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright (c) 2010 OpenStack, LLC.
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You ... | 39.484848 | 78 | 0.629957 |
4a1dc912fac52d8e0b02f8c21c45410cc382b487 | 391 | py | Python | Diploma/wsgi.py | imuno/Diploma | 8d41dd8e09492900b72339fb5a1c753334deb1bc | [
"MIT"
] | 3 | 2019-09-07T15:01:53.000Z | 2020-01-15T09:17:47.000Z | Diploma/wsgi.py | imuno/Diploma | 8d41dd8e09492900b72339fb5a1c753334deb1bc | [
"MIT"
] | 22 | 2020-06-05T22:53:41.000Z | 2022-03-11T23:58:42.000Z | Diploma/wsgi.py | imuno/Diploma | 8d41dd8e09492900b72339fb5a1c753334deb1bc | [
"MIT"
] | 2 | 2020-01-15T09:14:33.000Z | 2020-10-25T19:02:53.000Z | """
WSGI config for Diploma project.
It exposes the WSGI callable as a module-level variable named ``application``.
For more information on this file, see
https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
"""
import os
from django.core.wsgi import get_wsgi_application
os.environ.setdefault('DJANGO_SETTI... | 23 | 78 | 0.785166 |
4a1dc9501d23ccdbc912598419b70cefdc4459e3 | 387 | py | Python | btplda/category_explainer.py | RaviSoji/btplda | 8e25e1863ae249b39d898b4435fb5d4451b3d1cd | [
"Apache-2.0"
] | null | null | null | btplda/category_explainer.py | RaviSoji/btplda | 8e25e1863ae249b39d898b4435fb5d4451b3d1cd | [
"Apache-2.0"
] | null | null | null | btplda/category_explainer.py | RaviSoji/btplda | 8e25e1863ae249b39d898b4435fb5d4451b3d1cd | [
"Apache-2.0"
] | null | null | null | # class Explainer:
# def __init__(self, fitted_plda_classifier):
# self.model =
#
#
# def explain_category(self, category, n_ts=5, ts_sz=1):
# assert category in self.model.get_categories
#
# teaching_sets =
#
# highlighter = FeatureHighlighter(
# highlighted, filte... | 25.8 | 60 | 0.633075 |
4a1dcaae4c90effd4b5fd01b9dab45a79c0e0f64 | 1,877 | py | Python | src/modules/report/base.py | sakshamtaneja21/kube-hunter | e982f291e928a54b4322b15ecc7d954cc477f24d | [
"Apache-2.0"
] | 1 | 2019-09-25T12:31:33.000Z | 2019-09-25T12:31:33.000Z | src/modules/report/base.py | sakshamtaneja21/kube-hunter | e982f291e928a54b4322b15ecc7d954cc477f24d | [
"Apache-2.0"
] | null | null | null | src/modules/report/base.py | sakshamtaneja21/kube-hunter | e982f291e928a54b4322b15ecc7d954cc477f24d | [
"Apache-2.0"
] | null | null | null | from .collector import services, vulnerabilities, hunters, services_lock, vulnerabilities_lock
from src.core.types import Discovery
class BaseReporter(object):
def get_nodes(self):
nodes = list()
node_locations = set()
services_lock.acquire()
for service in services:
nod... | 40.804348 | 123 | 0.606287 |
4a1dcb0433a8680a95fdddb0bc9ca439233f85dd | 18,251 | py | Python | diofant/tests/utilities/test_lambdify.py | rajkk1/diofant | 6b361334569e4ec2e8c7d30dc324387a4ad417c2 | [
"BSD-3-Clause"
] | null | null | null | diofant/tests/utilities/test_lambdify.py | rajkk1/diofant | 6b361334569e4ec2e8c7d30dc324387a4ad417c2 | [
"BSD-3-Clause"
] | 1 | 2021-06-23T08:27:17.000Z | 2021-06-23T08:27:17.000Z | diofant/tests/utilities/test_lambdify.py | rajkk1/diofant | 6b361334569e4ec2e8c7d30dc324387a4ad417c2 | [
"BSD-3-Clause"
] | 1 | 2021-06-23T07:58:58.000Z | 2021-06-23T07:58:58.000Z | import itertools
import math
import mpmath
import pytest
import diofant
from diofant import (ITE, And, Float, Function, I, Integral, Lambda, Matrix,
Max, Min, Not, Or, Piecewise, Rational, cos, exp, false,
lambdify, oo, pi, sin, sqrt, symbols, true)
from diofant.abc import t,... | 31.305317 | 89 | 0.585612 |
4a1dcb405a364865fdbc62d5a4a6212f0d1ad556 | 376 | py | Python | EndBlock.py | KRHS-GameProgramming-2014/the-temple-of-the-lobsterman-2 | df4d6beddf207d10a0a6b6fb43bb8dbf1b4220a1 | [
"BSD-2-Clause"
] | null | null | null | EndBlock.py | KRHS-GameProgramming-2014/the-temple-of-the-lobsterman-2 | df4d6beddf207d10a0a6b6fb43bb8dbf1b4220a1 | [
"BSD-2-Clause"
] | null | null | null | EndBlock.py | KRHS-GameProgramming-2014/the-temple-of-the-lobsterman-2 | df4d6beddf207d10a0a6b6fb43bb8dbf1b4220a1 | [
"BSD-2-Clause"
] | null | null | null | import pygame
class EndBlock(pygame.sprite.Sprite):
def __init__(self, pos = [0,0]):
pygame.sprite.Sprite.__init__(self, self.containers)
self.image = pygame.image.load("Resources/Objects/Wall/End.png")
self.rect = self.image.get_rect()
self.place(pos)
self.living = True
def place(self, pos):
self.rec... | 23.5 | 66 | 0.699468 |
4a1dcb50e4dd7125d24c22ce9fa19871af07e390 | 2,906 | py | Python | LAB/Kasir/kasir.py | HudaFiqri/belajarPython | 8bc03e10339ce455afa052c635657b959abef493 | [
"Apache-2.0"
] | 5 | 2019-05-04T03:20:31.000Z | 2021-02-15T12:35:52.000Z | LAB/Kasir/kasir.py | kuhakuu04/belajarPython | 8bc03e10339ce455afa052c635657b959abef493 | [
"Apache-2.0"
] | null | null | null | LAB/Kasir/kasir.py | kuhakuu04/belajarPython | 8bc03e10339ce455afa052c635657b959abef493 | [
"Apache-2.0"
] | null | null | null | #modul
import os
import time
#mesin kalkulator
def tam(a, b):
return (a + b)
def kur(a, b):
return a - b
def kal(a, b):
return a * b
def bag(a, b):
return a / b
#menu
if __name__ == '__main__':
while True:
os.system('cls')
os.system('color 0b')
print(... | 25.716814 | 58 | 0.456986 |
4a1dcb70ea43341de423c68976e0cc57c3119a36 | 3,560 | py | Python | oncopolicy/utils/generic.py | yala/Tempo | bf3e0e78d64869bb2079c582a4a35982f78386ad | [
"MIT"
] | 6 | 2022-01-15T11:57:19.000Z | 2022-02-13T21:15:22.000Z | oncopolicy/utils/generic.py | yala/Tempo | bf3e0e78d64869bb2079c582a4a35982f78386ad | [
"MIT"
] | null | null | null | oncopolicy/utils/generic.py | yala/Tempo | bf3e0e78d64869bb2079c582a4a35982f78386ad | [
"MIT"
] | 2 | 2022-02-02T13:09:29.000Z | 2022-02-18T07:06:19.000Z | import datetime
import hashlib
import numpy as np
from copy import deepcopy
import torch
import pdb
INVALID_DATE_STR = "Date string not valid! Received {}, and got exception {}"
ISO_FORMAT = '%Y-%m-%d %H:%M:%S'
CGMH_ISO_FORMAT ='%Y%m%d'
DAYS_IN_YEAR = 365
DAYS_IN_MO = 30
MAX_MO_TO_CANCER = 1200
MIN_MO_TO_CANCER = 3
MA... | 33.584906 | 132 | 0.69691 |
4a1dcc23a77736f3758e0465bf9606a15fa81616 | 4,682 | py | Python | scripts/convert_publications.py | gqlo/website | 90237b0e1643eaceec812a765df363ce63542fd1 | [
"MIT"
] | 5 | 2020-02-17T06:28:59.000Z | 2022-01-27T10:25:16.000Z | scripts/convert_publications.py | gqlo/website | 90237b0e1643eaceec812a765df363ce63542fd1 | [
"MIT"
] | 49 | 2020-02-22T10:20:16.000Z | 2022-01-27T01:37:34.000Z | scripts/convert_publications.py | gqlo/website | 90237b0e1643eaceec812a765df363ce63542fd1 | [
"MIT"
] | 6 | 2020-04-17T06:49:56.000Z | 2021-12-21T21:55:10.000Z | from datetime import datetime, timedelta
import json
import sys
header_ja = """---
# Documentation: https://sourcethemes.com/academic/docs/managing-content/
title: "業績 (過去5年分)"
subtitle: ""
summary: ""
authors: []
tags: []
categories: []
date: 2020-02-17T18:32:18+09:00
featured: false
draft: false
# Featured image
... | 28.901235 | 100 | 0.587142 |
4a1dcc828538e5d118cabc429db9ed43b34291b5 | 336 | py | Python | exercises/exc_03_06.py | rklymentiev/py-for-neuro | 6bb163347483642c79eac429e5a9289edff7ce09 | [
"MIT"
] | 7 | 2021-04-28T13:12:16.000Z | 2022-01-15T00:21:11.000Z | exercises/exc_03_06.py | rklymentiev/py-for-neuro | 6bb163347483642c79eac429e5a9289edff7ce09 | [
"MIT"
] | 2 | 2021-04-02T18:42:55.000Z | 2021-05-20T08:43:06.000Z | exercises/exc_03_06.py | rklymentiev/py-for-neuro | 6bb163347483642c79eac429e5a9289edff7ce09 | [
"MIT"
] | 2 | 2021-07-04T22:57:29.000Z | 2021-07-29T19:28:43.000Z | import pandas as pd
table_1 = pd.read_json("exercises/data/table1.json")
table_2 = pd.read_json("exercises/data/table2.json")
joined_table = ___ # join two tables together
joined_table.___(labels=___, ___=1, inplace=___) # drop the redundant column
___ # replace the missing values in a column
displa... | 30.545455 | 76 | 0.738095 |
4a1dcd0f5c5a6f61424705a02bb0d7c611cbdf3b | 1,299 | py | Python | deploy.py | lucasalexsorensen/mlops | 2d8157eb493061775bdab9a8e176d2bdcc2c166e | [
"MIT"
] | null | null | null | deploy.py | lucasalexsorensen/mlops | 2d8157eb493061775bdab9a8e176d2bdcc2c166e | [
"MIT"
] | null | null | null | deploy.py | lucasalexsorensen/mlops | 2d8157eb493061775bdab9a8e176d2bdcc2c166e | [
"MIT"
] | null | null | null | from google.cloud import aiplatform
CUSTOM_PREDICTOR_IMAGE_URI = (
"europe-west4-docker.pkg.dev/dtumlops-project-mask-no-mask/dtu-mlops/serve"
)
VERSION = 1
model_display_name = f"mask-v{VERSION}"
model_description = "PyTorch based text classifier with custom container"
MODEL_NAME = "mask"
health_route = "/ping"
... | 27.0625 | 79 | 0.806005 |
4a1dcfa763728b3bdad70aaa7eabb22cd3d68980 | 3,026 | py | Python | dlrs/clearlinux/pytorch/mkl/scripts/generate_defaults.py | rahulunair/stacks | 92635edb582e9d2a16139deb3afba8cd98355344 | [
"Apache-2.0"
] | 32 | 2020-01-14T16:06:04.000Z | 2021-10-06T10:42:20.000Z | dlrs/clearlinux/pytorch/mkl/scripts/generate_defaults.py | rahulunair/stacks | 92635edb582e9d2a16139deb3afba8cd98355344 | [
"Apache-2.0"
] | 31 | 2019-10-31T16:44:44.000Z | 2021-04-30T17:31:01.000Z | dlrs/clearlinux/pytorch/mkl/scripts/generate_defaults.py | rahulunair/stacks | 92635edb582e9d2a16139deb3afba8cd98355344 | [
"Apache-2.0"
] | 22 | 2019-10-29T21:45:48.000Z | 2021-12-15T22:20:58.000Z | #!/usr/bin/env python
#
# Copyright (c) 2020 Intel Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appli... | 32.191489 | 118 | 0.639458 |
4a1dcfb2922c88d088bf3496a84abe92f9edb699 | 462 | py | Python | DatosGraficas/Datos_Para_Entrenamiento/TimeJumps.py | Rodrigo2118/IDMotor | 5a0ac6675cd4cde49efcc0af50bae891e6d256c9 | [
"MIT"
] | null | null | null | DatosGraficas/Datos_Para_Entrenamiento/TimeJumps.py | Rodrigo2118/IDMotor | 5a0ac6675cd4cde49efcc0af50bae891e6d256c9 | [
"MIT"
] | 1 | 2020-02-13T03:02:13.000Z | 2020-02-13T03:02:13.000Z | DatosGraficas/Datos_Para_Entrenamiento/TimeJumps.py | Rodrigo2118/IDMotor | 5a0ac6675cd4cde49efcc0af50bae891e6d256c9 | [
"MIT"
] | null | null | null | import csv
import sys
import random
p0=0.5
file=open(sys.argv[1],'r')
#csv_reader=csv.reader(file, delimiter=',',lineterminator='\n')
nfile=open(r"tj_"+sys.argv[1],"w")
#csv_writer=csv.writer(nfile,delimiter=',',lineterminator='\n')
string=file.read().split('\n')
#print(string)
first = True
for row in string:
r=ran... | 17.769231 | 63 | 0.67316 |
4a1dd1baac85cadb05ed10d80aa4df6c97f9419d | 800 | py | Python | remove_white.py | l0stpenguin/MegaDepth | ae060cabd60c9210291b0cd158650e6e9041496b | [
"MIT"
] | null | null | null | remove_white.py | l0stpenguin/MegaDepth | ae060cabd60c9210291b0cd158650e6e9041496b | [
"MIT"
] | null | null | null | remove_white.py | l0stpenguin/MegaDepth | ae060cabd60c9210291b0cd158650e6e9041496b | [
"MIT"
] | null | null | null | import torch
import sys
from torch.autograd import Variable
import numpy as np
from data.data_loader import CreateDataLoader
from models.models import create_model
from skimage import io
from skimage.transform import resize
import glob
import os
from pathlib import Path
import cv2
#remove all depth maps which are almo... | 28.571429 | 77 | 0.73375 |
4a1dd443dec5bd34813b5a5686805c5ddea1a1c6 | 1,497 | py | Python | pizzaProject/pizzaApp/models.py | martinezlucas98/pizzapro | 15fe1f6feea20b14e954cbc1dd8648ba2df28049 | [
"MIT"
] | null | null | null | pizzaProject/pizzaApp/models.py | martinezlucas98/pizzapro | 15fe1f6feea20b14e954cbc1dd8648ba2df28049 | [
"MIT"
] | null | null | null | pizzaProject/pizzaApp/models.py | martinezlucas98/pizzapro | 15fe1f6feea20b14e954cbc1dd8648ba2df28049 | [
"MIT"
] | null | null | null | from django.db import models
# El modelo Pizza
class Pizza (models.Model):
id = models.CharField(max_length=32, primary_key=True)
nombre = models.CharField(max_length=32)
precio = models.PositiveIntegerField()
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
self... | 31.851064 | 95 | 0.696059 |
4a1dd560ca2b3c0f98f93bf96a1c314f344d3f35 | 1,486 | py | Python | teacher/urls.py | rummansadik/Admission-Automation | a2fd305644cf60bfd0a381b855fb8c2810507f36 | [
"MIT"
] | null | null | null | teacher/urls.py | rummansadik/Admission-Automation | a2fd305644cf60bfd0a381b855fb8c2810507f36 | [
"MIT"
] | null | null | null | teacher/urls.py | rummansadik/Admission-Automation | a2fd305644cf60bfd0a381b855fb8c2810507f36 | [
"MIT"
] | null | null | null | from django.contrib.auth.views import LoginView
from django.urls import path
from teacher import views
urlpatterns = [
path('teacherclick', views.teacherclick_view),
path('teacherlogin', LoginView.as_view(
template_name='teacher/teacherlogin.html'), name='teacherlogin'),
path('teachersignup', view... | 47.935484 | 83 | 0.719381 |
4a1dd58ddb4c55392a8bae0639e01f9553698d66 | 558 | py | Python | var/spack/repos/builtin/packages/perl-array-utils/package.py | kkauder/spack | 6ae8d5c380c1f42094b05d38be26b03650aafb39 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 2 | 2019-02-10T13:47:48.000Z | 2019-04-17T13:05:17.000Z | var/spack/repos/builtin/packages/perl-array-utils/package.py | kkauder/spack | 6ae8d5c380c1f42094b05d38be26b03650aafb39 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 32 | 2020-12-15T17:29:20.000Z | 2022-03-21T15:08:31.000Z | var/spack/repos/builtin/packages/perl-array-utils/package.py | kkauder/spack | 6ae8d5c380c1f42094b05d38be26b03650aafb39 | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 2 | 2018-04-06T09:04:11.000Z | 2020-01-24T12:52:12.000Z | # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack import *
class PerlArrayUtils(PerlPackage):
"""Small utils for array manipulation"""
homepage = "htt... | 34.875 | 94 | 0.74552 |
4a1dd625dcb71f58f25dd34536fb870fba81d264 | 389 | py | Python | app/litrev/wsgi.py | ipa/litrev | 01550417872b0e2b0c0541a3b7f6b28d18d874c9 | [
"MIT"
] | 2 | 2020-04-09T11:46:36.000Z | 2022-02-01T00:56:11.000Z | app/litrev/wsgi.py | ipa/litrev | 01550417872b0e2b0c0541a3b7f6b28d18d874c9 | [
"MIT"
] | 5 | 2021-03-30T13:01:04.000Z | 2021-09-22T18:50:40.000Z | app/litrev/wsgi.py | ipa/litrev | 01550417872b0e2b0c0541a3b7f6b28d18d874c9 | [
"MIT"
] | null | null | null | """
WSGI config for litrev project.
It exposes the WSGI callable as a module-level variable named ``application``.
For more information on this file, see
https://docs.djangoproject.com/en/3.0/howto/deployment/wsgi/
"""
import os
from django.core.wsgi import get_wsgi_application
os.environ.setdefault('DJANGO_SETTIN... | 22.882353 | 78 | 0.784062 |
4a1dd6e288c2e4b81c1f6d6e68d7ec5a0dcd0043 | 51,477 | py | Python | python/ray/scripts/scripts.py | lavanyashukla/ray | 9c1a75b6ff82a842131e6beb3c260188befc21df | [
"Apache-2.0"
] | 1 | 2020-10-21T22:24:27.000Z | 2020-10-21T22:24:27.000Z | python/ray/scripts/scripts.py | mfitton/ray | fece8db70d703da1aad192178bd50923e83cc99a | [
"Apache-2.0"
] | 1 | 2020-12-04T02:39:55.000Z | 2020-12-04T02:39:55.000Z | python/ray/scripts/scripts.py | mfitton/ray | fece8db70d703da1aad192178bd50923e83cc99a | [
"Apache-2.0"
] | null | null | null | import click
import copy
from datetime import datetime
import json
import logging
import os
import subprocess
import sys
import time
import urllib
import urllib.parse
import yaml
from socket import socket
import ray
import psutil
import ray._private.services as services
from ray.autoscaler._private.commands import (
... | 34.548322 | 79 | 0.633176 |
4a1dd70e18f744e9f06b1a6aaf2c1a0aba24ce02 | 5,459 | py | Python | private/templates/skeleton/config.py | hitesh96db/eden | 8e1b22d7d4b92c0bce5b6172d57298949a2f0582 | [
"MIT"
] | null | null | null | private/templates/skeleton/config.py | hitesh96db/eden | 8e1b22d7d4b92c0bce5b6172d57298949a2f0582 | [
"MIT"
] | null | null | null | private/templates/skeleton/config.py | hitesh96db/eden | 8e1b22d7d4b92c0bce5b6172d57298949a2f0582 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
try:
# Python 2.7
from collections import OrderedDict
except:
# Python 2.6
from gluon.contrib.simplejson.ordered_dict import OrderedDict
from gluon import current
from gluon.storage import Storage
T = current.T
settings = current.deployment_settings
"""
Template settings
... | 35.448052 | 137 | 0.644807 |
4a1dd724f7bae2c03e874e52ed6ab77c8adef5c2 | 10,872 | py | Python | train.py | Archie7777/spectral-graph-augmentation | c3f22094b79a61357be55aa284d5f5a7df43928d | [
"MIT"
] | null | null | null | train.py | Archie7777/spectral-graph-augmentation | c3f22094b79a61357be55aa284d5f5a7df43928d | [
"MIT"
] | null | null | null | train.py | Archie7777/spectral-graph-augmentation | c3f22094b79a61357be55aa284d5f5a7df43928d | [
"MIT"
] | null | null | null | import numpy as np
import torch
import torch.nn as nn
import torch.nn.functional as F
from sklearn.model_selection import GridSearchCV, StratifiedKFold
from process.dataset import load
class GCNLayer(nn.Module):
def __init__(self, in_ft, out_ft, bias=True):
super(GCNLayer, self).__init__()
self.fc... | 31.331412 | 98 | 0.578734 |
4a1dd72afb04c845062ab9e5ba4b6a9ef729cfd4 | 3,423 | py | Python | bitmovin_api_sdk/encoding/filters/audio_mix/audio_mix_api.py | hofmannben/bitmovin-api-sdk-python | 71aae5cd8a31aa0ad54ca07a6f546a624e8686a9 | [
"MIT"
] | null | null | null | bitmovin_api_sdk/encoding/filters/audio_mix/audio_mix_api.py | hofmannben/bitmovin-api-sdk-python | 71aae5cd8a31aa0ad54ca07a6f546a624e8686a9 | [
"MIT"
] | 1 | 2020-07-06T07:13:43.000Z | 2020-07-06T07:13:43.000Z | bitmovin_api_sdk/encoding/filters/audio_mix/audio_mix_api.py | hofmannben/bitmovin-api-sdk-python | 71aae5cd8a31aa0ad54ca07a6f546a624e8686a9 | [
"MIT"
] | 1 | 2020-07-06T07:07:26.000Z | 2020-07-06T07:07:26.000Z | # coding: utf-8
from __future__ import absolute_import
from bitmovin_api_sdk.common import BaseApi, BitmovinApiLoggerBase
from bitmovin_api_sdk.common.poscheck import poscheck_except
from bitmovin_api_sdk.models.audio_mix_filter import AudioMixFilter
from bitmovin_api_sdk.models.bitmovin_response import BitmovinRespo... | 33.558824 | 120 | 0.654689 |
4a1dd736b4349772465a4b26815288c5fd175573 | 2,317 | py | Python | modelexp/models/sas/_superball.py | DomiDre/modelexp | 1ec25f71e739dac27716f9a8637fa6ab067499b9 | [
"MIT"
] | null | null | null | modelexp/models/sas/_superball.py | DomiDre/modelexp | 1ec25f71e739dac27716f9a8637fa6ab067499b9 | [
"MIT"
] | null | null | null | modelexp/models/sas/_superball.py | DomiDre/modelexp | 1ec25f71e739dac27716f9a8637fa6ab067499b9 | [
"MIT"
] | null | null | null | from modelexp.models.sas import SAXSModel
from fortSAS import superball
from numpy.polynomial.hermite import hermgauss
from numpy.polynomial.legendre import leggauss
class Superball(SAXSModel):
def initParameters(self):
self.params.add('r', 100)
self.params.add('pVal', 2.3)
self.params.add('sldCore', 40... | 30.090909 | 74 | 0.644799 |
4a1dd9111d2e81b088f482dcca110cedf05c1162 | 5,832 | py | Python | pywraps/py_kernwin_plgform.py | diamondo25/src | 15b9ab2535222e492cd21b8528c27f763fb799d6 | [
"BSD-3-Clause"
] | 2 | 2019-07-08T11:58:27.000Z | 2019-07-08T13:23:57.000Z | pywraps/py_kernwin_plgform.py | Bia10/src | 15b9ab2535222e492cd21b8528c27f763fb799d6 | [
"BSD-3-Clause"
] | null | null | null | pywraps/py_kernwin_plgform.py | Bia10/src | 15b9ab2535222e492cd21b8528c27f763fb799d6 | [
"BSD-3-Clause"
] | null | null | null | from __future__ import print_function
#<pycode(py_kernwin_plgform)>
import sys
class PluginForm(object):
"""
PluginForm class.
This form can be used to host additional controls. Please check the PyQt example.
"""
WOPN_MDI = 0x01 # no-op
WOPN_TAB = 0x02
"""attached by default to a... | 32.4 | 98 | 0.650034 |
4a1dd972e7c436062cc4ea5e1615cb7d629ef3bf | 9,282 | py | Python | openstack_dashboard/dashboards/admin/overview/tests.py | maofutian/horizon | dab92e7d2f576caea8f81c8e22a516fb45633794 | [
"Apache-2.0"
] | null | null | null | openstack_dashboard/dashboards/admin/overview/tests.py | maofutian/horizon | dab92e7d2f576caea8f81c8e22a516fb45633794 | [
"Apache-2.0"
] | null | null | null | openstack_dashboard/dashboards/admin/overview/tests.py | maofutian/horizon | dab92e7d2f576caea8f81c8e22a516fb45633794 | [
"Apache-2.0"
] | null | null | null | # Copyright 2012 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
#
# Copyright 2012 Nebula, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the... | 45.950495 | 78 | 0.588128 |
4a1dd9804fb20637dc6db43b3ea0d447b7bcb304 | 9,416 | py | Python | docs/conf.py | Labaien96/DeepConvLSTM_Keras | d537e1a896de54ce1321f023798e39ac62075b0f | [
"Apache-2.0"
] | 5 | 2020-06-18T22:36:02.000Z | 2022-02-21T19:44:20.000Z | docs/conf.py | Labaien96/DeepConvLSTM_Keras | d537e1a896de54ce1321f023798e39ac62075b0f | [
"Apache-2.0"
] | null | null | null | docs/conf.py | Labaien96/DeepConvLSTM_Keras | d537e1a896de54ce1321f023798e39ac62075b0f | [
"Apache-2.0"
] | 2 | 2020-12-06T11:11:33.000Z | 2021-03-07T18:50:07.000Z | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# mcfly documentation build configuration file, created by
# sphinx-quickstart on Wed Oct 5 10:42:14 2016.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# auto... | 31.918644 | 79 | 0.717184 |
4a1ddddada47353c36759efa957eef42288310d0 | 2,933 | py | Python | nicos_demo/vsans1/setups/sample_table_1.py | jkrueger1/nicos | 5f4ce66c312dedd78995f9d91e8a6e3c891b262b | [
"CC-BY-3.0",
"Apache-2.0",
"CC-BY-4.0"
] | null | null | null | nicos_demo/vsans1/setups/sample_table_1.py | jkrueger1/nicos | 5f4ce66c312dedd78995f9d91e8a6e3c891b262b | [
"CC-BY-3.0",
"Apache-2.0",
"CC-BY-4.0"
] | null | null | null | nicos_demo/vsans1/setups/sample_table_1.py | jkrueger1/nicos | 5f4ce66c312dedd78995f9d91e8a6e3c891b262b | [
"CC-BY-3.0",
"Apache-2.0",
"CC-BY-4.0"
] | null | null | null | description = 'bottom sample table devices'
group = 'lowlevel'
devices = dict(
st1_omg = device('nicos.devices.generic.Axis',
description = 'table 1 omega axis',
pollinterval = 15,
maxage = 60,
fmtstr = '%.2f',
abslimits = (-180, 180),
precision = 0.01,
moto... | 28.201923 | 61 | 0.505626 |
4a1ddddee344067e2ffc3ffbbe443bbcf3d21014 | 5,453 | py | Python | tests/validator/test_page_validator.py | JBBalling/core | b9977a28118d33e40656f5ea95e819d8cc496f32 | [
"Apache-2.0"
] | null | null | null | tests/validator/test_page_validator.py | JBBalling/core | b9977a28118d33e40656f5ea95e819d8cc496f32 | [
"Apache-2.0"
] | null | null | null | tests/validator/test_page_validator.py | JBBalling/core | b9977a28118d33e40656f5ea95e819d8cc496f32 | [
"Apache-2.0"
] | null | null | null | from tests.base import TestCase, assets, main # pylint: disable=import-error,no-name-in-module
from ocrd.resolver import Resolver
from ocrd_validators import PageValidator
from ocrd_validators.page_validator import get_text, set_text, ConsistencyError
from ocrd_models.ocrd_page import parse, TextEquivType
from ocrd_uti... | 53.990099 | 140 | 0.721254 |
4a1ddeb6c943bbeb167d9a6262c0bb65dd423b3b | 666 | py | Python | __init__.py | viralinkio/viralink-python-client-sdk | 110d0f9ac2f69ce496a16608ddacb8d4dad7b736 | [
"Apache-2.0"
] | null | null | null | __init__.py | viralinkio/viralink-python-client-sdk | 110d0f9ac2f69ce496a16608ddacb8d4dad7b736 | [
"Apache-2.0"
] | null | null | null | __init__.py | viralinkio/viralink-python-client-sdk | 110d0f9ac2f69ce496a16608ddacb8d4dad7b736 | [
"Apache-2.0"
] | null | null | null | # Copyright 2021. ViraLink
# #
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
# #
# http://www.apache.org/licenses/LICENSE-2.0
# #
# Unless required by app... | 35.052632 | 79 | 0.689189 |
4a1ddf1357c44369bd84f4d9dd1b4712a3a758ff | 4,182 | py | Python | venv/lib/python3.6/site-packages/ansible_collections/community/network/plugins/modules/network/avi/avi_gslbgeodbprofile.py | usegalaxy-no/usegalaxy | 75dad095769fe918eb39677f2c887e681a747f3a | [
"MIT"
] | 1 | 2020-01-22T13:11:23.000Z | 2020-01-22T13:11:23.000Z | venv/lib/python3.6/site-packages/ansible_collections/community/network/plugins/modules/network/avi/avi_gslbgeodbprofile.py | usegalaxy-no/usegalaxy | 75dad095769fe918eb39677f2c887e681a747f3a | [
"MIT"
] | 12 | 2020-02-21T07:24:52.000Z | 2020-04-14T09:54:32.000Z | venv/lib/python3.6/site-packages/ansible_collections/community/network/plugins/modules/network/avi/avi_gslbgeodbprofile.py | usegalaxy-no/usegalaxy | 75dad095769fe918eb39677f2c887e681a747f3a | [
"MIT"
] | null | null | null | #!/usr/bin/python
#
# @author: Gaurav Rastogi (grastogi@avinetworks.com)
# Eric Anderson (eanderson@avinetworks.com)
# module_check: supported
# Avi Version: 17.1.2
#
# Copyright: (c) 2017 Gaurav Rastogi, <grastogi@avinetworks.com>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses... | 32.418605 | 105 | 0.64132 |
4a1ddf71b181ff18fdeacd48dac64c7087f909f1 | 3,287 | py | Python | test/test_semi_structured_datatypes.py | zuarbase/snowflake-sqlalchemy | 6615f51444c539d56ade2be08c542dd4827a70a8 | [
"Apache-2.0"
] | 1 | 2020-08-04T08:30:58.000Z | 2020-08-04T08:30:58.000Z | test/test_semi_structured_datatypes.py | zuarbase/snowflake-sqlalchemy | 6615f51444c539d56ade2be08c542dd4827a70a8 | [
"Apache-2.0"
] | null | null | null | test/test_semi_structured_datatypes.py | zuarbase/snowflake-sqlalchemy | 6615f51444c539d56ade2be08c542dd4827a70a8 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (c) 2012-2019 Snowflake Computing Inc. All right reserved.
#
import json
import pytest
from parameters import CONNECTION_PARAMETERS
from snowflake.sqlalchemy import ARRAY, OBJECT, VARIANT
from sqlalchemy import Column, Integer, MetaData, Table, inspect
from ... | 29.881818 | 74 | 0.647399 |
4a1ddfec317aa26d03a90a81c32f9d9b7bc26c40 | 19,309 | py | Python | saleor/dashboard/views.py | glosoftgroup/glosoftgroup-django-pos | b489c402939b9ebabd164c449e7da38fe849d550 | [
"BSD-3-Clause"
] | 2 | 2017-07-11T12:40:59.000Z | 2017-10-18T18:02:46.000Z | saleor/dashboard/views.py | glosoftgroup/glosoftgroup-django-pos | b489c402939b9ebabd164c449e7da38fe849d550 | [
"BSD-3-Clause"
] | 12 | 2017-06-19T07:20:41.000Z | 2022-03-15T19:03:33.000Z | saleor/dashboard/views.py | glosoftgroup/glosoftgroup-django-pos | b489c402939b9ebabd164c449e7da38fe849d550 | [
"BSD-3-Clause"
] | null | null | null | from django.contrib.admin.views.decorators import \
staff_member_required as _staff_member_required
from django.template.response import TemplateResponse
from payments import PaymentStatus
from ..order.models import Order, Payment
from ..order import OrderStatus
from ..sale.models import Sales, SoldItem
from... | 49.383632 | 174 | 0.573411 |
4a1ddff18e3240cfbf72674fdb891adf25b249eb | 3,934 | py | Python | contrib/macdeploy/custom_dsstore.py | Benitoitedev/Benitoitecoin | 45e4762128d9c0e888ffda37b34feddc7680ca71 | [
"MIT"
] | null | null | null | contrib/macdeploy/custom_dsstore.py | Benitoitedev/Benitoitecoin | 45e4762128d9c0e888ffda37b34feddc7680ca71 | [
"MIT"
] | null | null | null | contrib/macdeploy/custom_dsstore.py | Benitoitedev/Benitoitecoin | 45e4762128d9c0e888ffda37b34feddc7680ca71 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# Copyright (c) 2013-2016 The Bitcoin Core developers
# Copyright (c) 2018 The LightCoinPay developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
from __future__ import division,print_function,unicode_lit... | 61.46875 | 1,817 | 0.708185 |
4a1de078fd24f0e3aefe5bcd80bbafa87f795aa1 | 19,464 | py | Python | hw/ip/otbn/dv/rig/rig/gens/straight_line_insn.py | vsukhoml/opentitan | bb0bd16b3eca0ef2dd4144b5df49b8663c59101f | [
"Apache-2.0"
] | 1 | 2020-05-11T05:18:20.000Z | 2020-05-11T05:18:20.000Z | hw/ip/otbn/dv/rig/rig/gens/straight_line_insn.py | vsukhoml/opentitan | bb0bd16b3eca0ef2dd4144b5df49b8663c59101f | [
"Apache-2.0"
] | null | null | null | hw/ip/otbn/dv/rig/rig/gens/straight_line_insn.py | vsukhoml/opentitan | bb0bd16b3eca0ef2dd4144b5df49b8663c59101f | [
"Apache-2.0"
] | null | null | null | # Copyright lowRISC contributors.
# Licensed under the Apache License, Version 2.0, see LICENSE for details.
# SPDX-License-Identifier: Apache-2.0
import random
from typing import List, Optional, Tuple
from shared.insn_yaml import Insn, InsnsFile
from shared.lsu_desc import LSUDesc
from shared.operand import ImmOpera... | 40.890756 | 80 | 0.569307 |
4a1de125d05c0c36dfe539886cadbfcc8f39cc36 | 1,067 | py | Python | test/test_account_response_body.py | mxenabled/mx-platform-python | 060dae7ddb02fdcf41fa7f7aebfa4b8a0273afac | [
"MIT"
] | null | null | null | test/test_account_response_body.py | mxenabled/mx-platform-python | 060dae7ddb02fdcf41fa7f7aebfa4b8a0273afac | [
"MIT"
] | 14 | 2021-11-30T21:56:19.000Z | 2022-02-07T18:47:10.000Z | test/test_account_response_body.py | mxenabled/mx-platform-python | 060dae7ddb02fdcf41fa7f7aebfa4b8a0273afac | [
"MIT"
] | 1 | 2022-01-12T14:59:39.000Z | 2022-01-12T14:59:39.000Z | """
MX Platform API
The MX Platform API is a powerful, fully-featured API designed to make aggregating and enhancing financial data easy and reliable. It can seamlessly connect your app or website to tens of thousands of financial institutions. # noqa: E501
The version of the OpenAPI document: 0.1.0
... | 28.078947 | 242 | 0.737582 |
4a1de2a9adf4e69c067f73de6056ca17154fd7a4 | 1,198 | py | Python | music_site/tracks/models.py | UVG-Teams/music-space | 8f464b6b1cbe59afea3be3ab1b9ed4e25ab0b424 | [
"MIT"
] | null | null | null | music_site/tracks/models.py | UVG-Teams/music-space | 8f464b6b1cbe59afea3be3ab1b9ed4e25ab0b424 | [
"MIT"
] | null | null | null | music_site/tracks/models.py | UVG-Teams/music-space | 8f464b6b1cbe59afea3be3ab1b9ed4e25ab0b424 | [
"MIT"
] | null | null | null | from django.db import models
#Track
class Track(models.Model):
id = models.IntegerField(primary_key=True, blank=False, null=False)
name = models.CharField(max_length=200, blank=False, null=False)
composer = models.CharField(max_length=220, blank=True, null=True)
milliseconds = models.IntegerField(blank... | 47.92 | 194 | 0.711185 |
4a1de2df1781101d2753dc9e4c4d6261390d79ae | 933 | py | Python | adventure_game/game_objects/puzzles/bathtub_dilemma.py | Def4l71diot/adventure-game-base | 6f62ecf07980beba8804114b007d6bd7a4f55cc7 | [
"MIT"
] | 2 | 2017-10-23T14:40:35.000Z | 2017-10-23T14:40:38.000Z | adventure_game/game_objects/puzzles/bathtub_dilemma.py | Def4l71diot/A-Day-in-the-Kremlin | 6f62ecf07980beba8804114b007d6bd7a4f55cc7 | [
"MIT"
] | null | null | null | adventure_game/game_objects/puzzles/bathtub_dilemma.py | Def4l71diot/A-Day-in-the-Kremlin | 6f62ecf07980beba8804114b007d6bd7a4f55cc7 | [
"MIT"
] | null | null | null | from adventure_game.models import Puzzle
from adventure_game.exceptions import PlayerDeadException
NOT_ENOUGH_BUBBLES_ERROR_MESSAGE = "YOU'VE FAILED COMRADE! Stalin loves bubbles. Try with more next time. GULAG!"
FLOODED_BATH_ERROR_MESSAGE = "The whole room turns into a bathtub. Stalin rushes in with fury and sends yo... | 32.172414 | 118 | 0.700965 |
4a1de3e84b2a1c3d9a27c48da319a50b1dd7bb64 | 31 | py | Python | codigoRama.py | RobertVJ/HCAP2021 | a5176d5785c85aa9f27b04ce85570f831c9210ae | [
"MIT"
] | null | null | null | codigoRama.py | RobertVJ/HCAP2021 | a5176d5785c85aa9f27b04ce85570f831c9210ae | [
"MIT"
] | null | null | null | codigoRama.py | RobertVJ/HCAP2021 | a5176d5785c85aa9f27b04ce85570f831c9210ae | [
"MIT"
] | null | null | null | print("Archivo nuevo en rama")
| 15.5 | 30 | 0.741935 |
4a1de46b11cd64204597e55ead982f68e7260135 | 2,563 | py | Python | src/seller_products/migrations/0006_auto_20211007_2124.py | evis-market/web-interface-backend | f8930ff1c009ad18e522ab29680b4bcd50a6020e | [
"MIT"
] | 2 | 2021-08-30T22:58:32.000Z | 2021-12-12T10:47:52.000Z | src/seller_products/migrations/0006_auto_20211007_2124.py | evis-market/web-interface-backend | f8930ff1c009ad18e522ab29680b4bcd50a6020e | [
"MIT"
] | null | null | null | src/seller_products/migrations/0006_auto_20211007_2124.py | evis-market/web-interface-backend | f8930ff1c009ad18e522ab29680b4bcd50a6020e | [
"MIT"
] | 1 | 2021-08-22T19:12:44.000Z | 2021-08-22T19:12:44.000Z | # Generated by Django 3.2.7 on 2021-10-07 21:24
import django.db.models.deletion
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('product_data_types', '0001_initial'),
('data_delivery_types', '0001_initial'),
('seller_products', '0005_aut... | 44.964912 | 147 | 0.668748 |
4a1de56e918a3de42da4510f054e9b33962de358 | 40,971 | py | Python | python/ccxt/exmo.py | gslopez/ccxt | 2ea6857dce788f1f556ee94f08a58757decf0900 | [
"MIT"
] | 13 | 2019-01-26T14:41:37.000Z | 2022-03-26T03:33:12.000Z | python/ccxt/exmo.py | gslopez/ccxt | 2ea6857dce788f1f556ee94f08a58757decf0900 | [
"MIT"
] | 17 | 2018-10-02T04:43:13.000Z | 2018-11-01T17:07:37.000Z | python/ccxt/exmo.py | gslopez/ccxt | 2ea6857dce788f1f556ee94f08a58757decf0900 | [
"MIT"
] | 12 | 2018-12-24T02:19:02.000Z | 2022-03-26T05:04:25.000Z | # -*- coding: utf-8 -*-
# PLEASE DO NOT EDIT THIS FILE, IT IS GENERATED AND WILL BE OVERWRITTEN:
# https://github.com/ccxt/ccxt/blob/master/CONTRIBUTING.md#how-to-contribute-code
from ccxt.base.exchange import Exchange
# -----------------------------------------------------------------------------
try:
basestri... | 42.369183 | 194 | 0.464499 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.