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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
f6e1f7647b60fef3a5175db89e79a4186e1503a5 | 816 | py | Python | data/count_office31.py | mo6zes/Reproducing-Deep-Fair-Clustering | 91f915436821eb05cdd021d3e9eb050a248fe993 | [
"Unlicense"
] | 4 | 2021-01-30T12:36:18.000Z | 2022-03-23T10:10:45.000Z | data/count_office31.py | mo6zes/Reproducing-Deep-Fair-Clustering | 91f915436821eb05cdd021d3e9eb050a248fe993 | [
"Unlicense"
] | 1 | 2021-11-05T09:16:36.000Z | 2021-11-05T15:27:25.000Z | data/count_office31.py | mo6zes/Reproducing-Deep-Fair-Clustering | 91f915436821eb05cdd021d3e9eb050a248fe993 | [
"Unlicense"
] | 1 | 2021-03-21T19:44:45.000Z | 2021-03-21T19:44:45.000Z | from office31 import office31
from office31 import download_and_extract_office31
from pathlib import Path
import os
#Hacky script to count how many images are in each folder/cluster in both sources
out_name = "./data/office31/office31_count.txt"
file_open=open(out_name, "w")
file_open.write('')
count_items("amazon"... | 30.222222 | 81 | 0.634804 |
f6e28a13700fedee22ada39a3fa8792554af7720 | 11,213 | py | Python | mm2s5/mm2s5.py | scottkirkwood/mm2s5 | 05160ead97b28a82e3d6f529672c8cd2067ff27c | [
"Apache-2.0"
] | null | null | null | mm2s5/mm2s5.py | scottkirkwood/mm2s5 | 05160ead97b28a82e3d6f529672c8cd2067ff27c | [
"Apache-2.0"
] | null | null | null | mm2s5/mm2s5.py | scottkirkwood/mm2s5 | 05160ead97b28a82e3d6f529672c8cd2067ff27c | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
# -*- encoding: latin1 -*-
#
# Copyright 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless ... | 33.471642 | 116 | 0.605725 |
f6e2d912d61b57a1bc1a9fc88cfe7298ffc1b85b | 480 | py | Python | covid19sweden/__init__.py | martinbenes1996/covid19sweden | 100993e41c302ffd96fa39857dd8ddd21267f1ed | [
"MIT"
] | 1 | 2020-06-06T21:02:10.000Z | 2020-06-06T21:02:10.000Z | covid19sweden/__init__.py | martinbenes1996/covid19sweden | 100993e41c302ffd96fa39857dd8ddd21267f1ed | [
"MIT"
] | 1 | 2020-06-25T00:18:21.000Z | 2020-06-26T02:34:19.000Z | covid19sweden/__init__.py | martinbenes1996/covid19sweden | 100993e41c302ffd96fa39857dd8ddd21267f1ed | [
"MIT"
] | 1 | 2020-06-06T21:04:22.000Z | 2020-06-06T21:04:22.000Z | # -*- coding: utf-8 -*-
"""Webscraper for Swedish data.
Reference: https://www.scb.se/hitta-statistik/statistik-efter-amne/befolkning/befolkningens-sammansattning/befolkningsstatistik/pong/tabell-och-diagram/preliminar-statistik-over-doda/
Todo:
* caching
"""
import pkg_resources
from .main import *
from . impo... | 24 | 183 | 0.75625 |
f6e364a4d8935e2990712e28b098a07099b88272 | 395 | py | Python | public/ViPER/modules/head.py | severnake/ViPER | e788f73bfe894f7fd03081782c87778de38a8df2 | [
"MIT"
] | 23 | 2016-11-26T06:55:44.000Z | 2021-07-27T19:28:05.000Z | public/ViPER/modules/head.py | severnake/ViPER | e788f73bfe894f7fd03081782c87778de38a8df2 | [
"MIT"
] | 2 | 2021-03-11T04:35:03.000Z | 2021-05-11T22:03:33.000Z | public/ViPER/modules/head.py | severnake/ViPER | e788f73bfe894f7fd03081782c87778de38a8df2 | [
"MIT"
] | 7 | 2017-08-12T10:44:41.000Z | 2022-03-22T05:49:49.000Z | import requests
from termcolor.termcolor import colored, cprint
| 23.235294 | 60 | 0.531646 |
f6e4193df3aa52bc4f5ce439f49c5d54acb0e849 | 1,190 | py | Python | src/airflow_actionproject/callables/action.py | actionprojecteu/airflow-actionproject | 6518e73e5709ebce927e0b463b5e36d80194491c | [
"MIT"
] | null | null | null | src/airflow_actionproject/callables/action.py | actionprojecteu/airflow-actionproject | 6518e73e5709ebce927e0b463b5e36d80194491c | [
"MIT"
] | null | null | null | src/airflow_actionproject/callables/action.py | actionprojecteu/airflow-actionproject | 6518e73e5709ebce927e0b463b5e36d80194491c | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# ----------------------------------------------------------------------
# Copyright (c) 2021
#
# See the LICENSE file for details
# see the AUTHORS file for authors
# ----------------------------------------------------------------------
#--------------------
# System wide imports
# ----------... | 24.285714 | 122 | 0.512605 |
f6e5c99d7184da2fbbd07b8e09ae981f7738a398 | 5,838 | py | Python | stp_raet/test/test_communication.py | ArtObr/indy-plenum | c568eefb0042b3ec3aec84e9241cb1b5df419365 | [
"Apache-2.0"
] | null | null | null | stp_raet/test/test_communication.py | ArtObr/indy-plenum | c568eefb0042b3ec3aec84e9241cb1b5df419365 | [
"Apache-2.0"
] | null | null | null | stp_raet/test/test_communication.py | ArtObr/indy-plenum | c568eefb0042b3ec3aec84e9241cb1b5df419365 | [
"Apache-2.0"
] | null | null | null | from ioflo.base.consoling import getConsole
from stp_core.crypto.nacl_wrappers import Signer as NaclSigner, Privateer
from raet.raeting import AutoMode, Acceptance
from raet.road.estating import RemoteEstate
from raet.road.stacking import RoadStack
from stp_raet.test.helper import handshake, sendMsgs, cleanup, getRemo... | 29.484848 | 73 | 0.577595 |
f6e6fadb85ba7a38ec23f0b2f12e5f4cc663ece0 | 14,393 | py | Python | RedYoshiBot/server/CTGP7ServerDatabase.py | mariohackandglitch/RedYoshiBot | 436d4d22b75673f1b10e1ac478e797f8544e388d | [
"Apache-2.0"
] | 4 | 2018-03-12T17:02:57.000Z | 2021-03-26T18:44:21.000Z | RedYoshiBot/server/CTGP7ServerDatabase.py | mariohackandglitch/RedYoshiBot | 436d4d22b75673f1b10e1ac478e797f8544e388d | [
"Apache-2.0"
] | null | null | null | RedYoshiBot/server/CTGP7ServerDatabase.py | mariohackandglitch/RedYoshiBot | 436d4d22b75673f1b10e1ac478e797f8544e388d | [
"Apache-2.0"
] | null | null | null | import threading
import sqlite3
from enum import Enum
import time
import datetime
from ..CTGP7Defines import CTGP7Defines
current_time_min = lambda: int(round(time.time() / 60)) | 39.111413 | 155 | 0.556868 |
f6e7d67ad18d6db3685d0903fe664237cb666d24 | 299 | py | Python | autographql/apps.py | ehsu0407/django-autographql | 95147501b2e542ee2a4b7903546665fb84d5115e | [
"MIT"
] | 1 | 2021-11-20T03:52:51.000Z | 2021-11-20T03:52:51.000Z | autographql/apps.py | ehsu0407/django-autographql | 95147501b2e542ee2a4b7903546665fb84d5115e | [
"MIT"
] | null | null | null | autographql/apps.py | ehsu0407/django-autographql | 95147501b2e542ee2a4b7903546665fb84d5115e | [
"MIT"
] | null | null | null | from django.apps import AppConfig
| 24.916667 | 56 | 0.735786 |
f6ea9490bd3489c0fea713bbe5332c6ac5c901a3 | 982 | py | Python | FD_wave_example.py | miaoziemm/Seismic_Forward_Engine | 163a589254389772820744452e406f947e29e085 | [
"MIT"
] | 1 | 2021-11-05T13:17:02.000Z | 2021-11-05T13:17:02.000Z | FD_wave_example.py | miaoziemm/Seismic_Forward_Engine | 163a589254389772820744452e406f947e29e085 | [
"MIT"
] | null | null | null | FD_wave_example.py | miaoziemm/Seismic_Forward_Engine | 163a589254389772820744452e406f947e29e085 | [
"MIT"
] | null | null | null | import taichi as ti
from FD_wave.wave_module_2d4d import wave
from FD_wave.receiver_module import receiver
import Visualization.SFE_visual as vis
ti.init(arch=ti.gpu)
frame = 1
c = ti.field(dtype=ti.f32, shape=(600,600))
c_s = ti.field(dtype=ti.f32, shape=(1000, 1000))
wave_cs = wave(300, 400, 600, 600, 10.0, 10.0, 1... | 23.380952 | 69 | 0.704684 |
f6eaf7e5bb35cf8e7466e792deece88534700ba4 | 3,425 | py | Python | ENGR 102.py | jemmypotter/Python | c8fc5c49c5289dc0598c93eef4cfbcb5701c2b32 | [
"bzip2-1.0.6"
] | null | null | null | ENGR 102.py | jemmypotter/Python | c8fc5c49c5289dc0598c93eef4cfbcb5701c2b32 | [
"bzip2-1.0.6"
] | null | null | null | ENGR 102.py | jemmypotter/Python | c8fc5c49c5289dc0598c93eef4cfbcb5701c2b32 | [
"bzip2-1.0.6"
] | null | null | null | critics={'Lisa Rose': {'Lady in the Water': 2.5, 'Snakes on a Plane': 3.5, 'Just My Luck': 3.0, 'Superman Returns': 3.5, 'You, Me and Dupree': 2.5, 'The Night Listener': 3.0},
'Gene Seymour': {'Lady in the Water': 3.0, 'Snakes on a Plane': 3.5, 'Just My Luck': 1.5, 'Superman Returns': 5.0, 'The Night Listener'... | 38.483146 | 191 | 0.637664 |
f6ec3cd9ae8ae57a80bd9ab3c56c8873b3588b8f | 110 | py | Python | src/applications/core/admin.py | sleonvaz/rindus-task | fc3fc1454d5b29bb8df6194a86612ad6462ee08c | [
"MIT"
] | null | null | null | src/applications/core/admin.py | sleonvaz/rindus-task | fc3fc1454d5b29bb8df6194a86612ad6462ee08c | [
"MIT"
] | null | null | null | src/applications/core/admin.py | sleonvaz/rindus-task | fc3fc1454d5b29bb8df6194a86612ad6462ee08c | [
"MIT"
] | null | null | null | from django.contrib import admin
from applications.core.models import Clients
admin.site.register(Clients)
| 15.714286 | 44 | 0.827273 |
f6ecd0aafed1e62eb63756a09afea3562d8bef9e | 99 | py | Python | api/newsCategory/apps.py | jhonatantft/ckl | 8a0d533922fa091ac5f2dbe50caee3920ec2b90d | [
"MIT"
] | null | null | null | api/newsCategory/apps.py | jhonatantft/ckl | 8a0d533922fa091ac5f2dbe50caee3920ec2b90d | [
"MIT"
] | 2 | 2021-05-08T21:26:43.000Z | 2022-02-19T00:26:17.000Z | api/newsCategory/apps.py | jhonatantft/ckl | 8a0d533922fa091ac5f2dbe50caee3920ec2b90d | [
"MIT"
] | null | null | null | from django.apps import AppConfig
| 16.5 | 36 | 0.777778 |
f6ed93bc4cbe3c8880ecf1e3e007e8f0fa6018d9 | 77,326 | py | Python | cfdm/data/data.py | NCAS-CMS/cfdm | 8e6ac54c1a2966ad5c07cd51ef609005a1fd70cc | [
"MIT"
] | 22 | 2018-11-07T18:16:22.000Z | 2022-03-16T16:05:21.000Z | cfdm/data/data.py | davidhassell/cfdm | 8e6ac54c1a2966ad5c07cd51ef609005a1fd70cc | [
"MIT"
] | 119 | 2019-04-08T08:00:24.000Z | 2022-03-22T08:21:22.000Z | cfdm/data/data.py | davidhassell/cfdm | 8e6ac54c1a2966ad5c07cd51ef609005a1fd70cc | [
"MIT"
] | 8 | 2019-04-09T10:12:26.000Z | 2021-07-22T02:41:15.000Z | import itertools
import logging
import netCDF4
import numpy
from .. import core
from ..constants import masked as cfdm_masked
from ..decorators import (
_inplace_enabled,
_inplace_enabled_define_and_cleanup,
_manage_log_level_via_verbosity,
)
from ..functions import abspath
from ..mixin.container import C... | 28.692393 | 116 | 0.477239 |
f6efdf1a1e2ca3bc054152966617543b747082cb | 9,458 | py | Python | alipay/aop/api/domain/ArInvoiceReceiptQueryOpenApiDTO.py | antopen/alipay-sdk-python-all | 8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c | [
"Apache-2.0"
] | 213 | 2018-08-27T16:49:32.000Z | 2021-12-29T04:34:12.000Z | alipay/aop/api/domain/ArInvoiceReceiptQueryOpenApiDTO.py | antopen/alipay-sdk-python-all | 8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c | [
"Apache-2.0"
] | 29 | 2018-09-29T06:43:00.000Z | 2021-09-02T03:27:32.000Z | alipay/aop/api/domain/ArInvoiceReceiptQueryOpenApiDTO.py | antopen/alipay-sdk-python-all | 8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c | [
"Apache-2.0"
] | 59 | 2018-08-27T16:59:26.000Z | 2022-03-25T10:08:15.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.constant.ParamConstants import *
from alipay.aop.api.domain.MultiCurrencyMoneyOpenApi import MultiCurrencyMoneyOpenApi
from alipay.aop.api.domain.MultiCurrencyMoneyOpenApi import MultiCurrencyMoneyOpenApi
from alipay.aop.api.domain.MultiCurr... | 32.279863 | 86 | 0.591774 |
f6f037d5301de39668019ccf1a2625274e621032 | 14,051 | py | Python | Model/lookalike-model/tests/pipeline/test_main_clean.py | rangaswamymr/blue-marlin | 2ab39a6af01e14f40386f640fe087aeb284b5524 | [
"Apache-2.0"
] | null | null | null | Model/lookalike-model/tests/pipeline/test_main_clean.py | rangaswamymr/blue-marlin | 2ab39a6af01e14f40386f640fe087aeb284b5524 | [
"Apache-2.0"
] | null | null | null | Model/lookalike-model/tests/pipeline/test_main_clean.py | rangaswamymr/blue-marlin | 2ab39a6af01e14f40386f640fe087aeb284b5524 | [
"Apache-2.0"
] | null | null | null | # Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may... | 44.46519 | 142 | 0.647925 |
f6f09641b35ebd494e5edb18cd6f3b2853290c77 | 8,663 | py | Python | src/nemo/datasets.py | thomasjo/nemo-redux | c4196c0d99633dca011d60008be0cb7667c348b7 | [
"MIT"
] | null | null | null | src/nemo/datasets.py | thomasjo/nemo-redux | c4196c0d99633dca011d60008be0cb7667c348b7 | [
"MIT"
] | null | null | null | src/nemo/datasets.py | thomasjo/nemo-redux | c4196c0d99633dca011d60008be0cb7667c348b7 | [
"MIT"
] | null | null | null | import json
from pathlib import Path
import numpy as np
import torch
import torchvision as vision
import yaml
from PIL import Image
from sklearn.model_selection import train_test_split
from torch.utils.data import DataLoader, Dataset, SubsetRandomSampler
from torch.utils.data.dataset import Subset
from torchvision.d... | 34.931452 | 136 | 0.669399 |
f6f1181b9d63e4b1e1908205531b518c477401af | 6,255 | py | Python | ever2text/converter.py | nicholaskuechler/ever2text | dc21ca86b691f2ee793ce273035341e55374448e | [
"MIT"
] | 13 | 2016-12-16T18:57:53.000Z | 2021-04-30T22:14:45.000Z | ever2text/converter.py | nicholaskuechler/ever2text | dc21ca86b691f2ee793ce273035341e55374448e | [
"MIT"
] | 2 | 2017-01-21T19:46:10.000Z | 2020-11-16T11:03:27.000Z | ever2text/converter.py | nicholaskuechler/ever2text | dc21ca86b691f2ee793ce273035341e55374448e | [
"MIT"
] | 3 | 2016-09-16T02:10:04.000Z | 2021-04-30T22:16:08.000Z | # -*- coding: utf-8 -*-
from __future__ import print_function
from __future__ import unicode_literals
from __future__ import division
from __future__ import absolute_import
from builtins import open
from builtins import str
import json
import os
import sys
from dateutil.parser import parse
from html2text import HTML2Te... | 40.096154 | 79 | 0.566107 |
f6f2d88af8b19a330bc99f6628aa11a5d1619261 | 4,055 | pyw | Python | randomopgavergui.pyw | jensjacobt/randomopgaver | 24a2b032bcd1bccd90dface0365feff419819d58 | [
"MIT"
] | null | null | null | randomopgavergui.pyw | jensjacobt/randomopgaver | 24a2b032bcd1bccd90dface0365feff419819d58 | [
"MIT"
] | null | null | null | randomopgavergui.pyw | jensjacobt/randomopgaver | 24a2b032bcd1bccd90dface0365feff419819d58 | [
"MIT"
] | null | null | null | # The GUI of Randomopgaver
# -*- coding: utf-8 -*-
import os
import tkinter
from tkinter import *
from tkinter import scrolledtext
from tkinter import messagebox
from tkinter.filedialog import askopenfilename
from tkinter.filedialog import askdirectory
from filegenerator import create_randomopgaver
global doc_file, ta... | 28.356643 | 87 | 0.641184 |
f6f3a7cb2f1f74649f7392db25208bff5b69d6eb | 8,325 | py | Python | reb/plain.py | workingenius/reb | ebc597d95f79d6f2d89a401940f24d7a2c4274f0 | [
"MIT"
] | 1 | 2021-04-27T04:03:21.000Z | 2021-04-27T04:03:21.000Z | reb/plain.py | workingenius/reb | ebc597d95f79d6f2d89a401940f24d7a2c4274f0 | [
"MIT"
] | null | null | null | reb/plain.py | workingenius/reb | ebc597d95f79d6f2d89a401940f24d7a2c4274f0 | [
"MIT"
] | null | null | null | """Reb plain Implementation"""
from typing import Iterator, List, Optional
from functools import singledispatch
from .parse_tree import PTNode, VirtualPTNode
from .pattern import (
Finder,
Pattern,
PText, PAnyChar, PTag, PNotInChars, PInChars,
PAny, PRepeat, PAdjacent,
PExample,
PStarting, PEn... | 33.3 | 106 | 0.599399 |
f6f524b71daa4dbc98c31cccc8cb7fce4eac5538 | 881 | py | Python | AdversarialAttack/SST/gen_pos.py | thunlp/DictSKB | ac7c328db4d25cf6bdc3c64aefa9b773854ba525 | [
"MIT"
] | 2 | 2021-11-21T13:42:06.000Z | 2022-01-11T05:33:43.000Z | AdversarialAttack/SST/gen_pos.py | thunlp/DictSKB | ac7c328db4d25cf6bdc3c64aefa9b773854ba525 | [
"MIT"
] | null | null | null | AdversarialAttack/SST/gen_pos.py | thunlp/DictSKB | ac7c328db4d25cf6bdc3c64aefa9b773854ba525 | [
"MIT"
] | 3 | 2021-09-14T06:40:51.000Z | 2021-12-23T09:41:22.000Z | import pickle
with open('./aux_files/dataset_13837.pkl','rb') as fp:
dataset=pickle.load(fp)
from nltk.tag import StanfordPOSTagger
jar = 'stanford-postagger-full-2018-10-16/stanford-postagger.jar'
model = 'stanford-postagger-full-2018-10-16/models/english-left3words-distsim.tagger'
pos_tagger = StanfordPOSTagger... | 32.62963 | 85 | 0.76277 |
f6f688d8a5f12a882c462a7d43fb10da64d6fa89 | 5,009 | py | Python | PiCam/picam.py | alexwtz/pciam | 7e90dd22a8e97e41fb480cb85cdf95cefd2d974e | [
"MIT"
] | null | null | null | PiCam/picam.py | alexwtz/pciam | 7e90dd22a8e97e41fb480cb85cdf95cefd2d974e | [
"MIT"
] | null | null | null | PiCam/picam.py | alexwtz/pciam | 7e90dd22a8e97e41fb480cb85cdf95cefd2d974e | [
"MIT"
] | null | null | null | import serial
import time
import atexit
from functools import wraps
from flask import Flask, render_template, request, Response
app = Flask(__name__)
def check_auth(username, password):
"""This function is called to check if a username /
password combination is valid.
"""
return username == 'admin' and... | 28.787356 | 84 | 0.609503 |
f6f935040202abf72d1e7c6636a1df716225a0b0 | 7,834 | py | Python | simplemfa/helpers.py | mwhawkins/django-simple-mfa | 58b5188473a776f5fcebda9843e2147123dce59f | [
"MIT"
] | 3 | 2020-07-17T09:14:09.000Z | 2020-12-15T09:26:56.000Z | simplemfa/helpers.py | mwhawkins/django-simple-mfa | 58b5188473a776f5fcebda9843e2147123dce59f | [
"MIT"
] | 1 | 2020-11-25T10:41:02.000Z | 2020-11-25T10:41:02.000Z | simplemfa/helpers.py | mwhawkins/django-simple-mfa | 58b5188473a776f5fcebda9843e2147123dce59f | [
"MIT"
] | 2 | 2020-11-25T10:47:20.000Z | 2021-11-04T15:41:21.000Z | from django import template
from django.core.mail import send_mail
from django.template.loader import get_template
from django.conf import settings
from django.shortcuts import reverse
from twilio.twiml.voice_response import VoiceResponse, Say
from twilio.rest import Client
from django.utils import timezone
... | 34.359649 | 111 | 0.616033 |
f6fad38b5c6177592103f90dc3306807b04807de | 443 | py | Python | wsgi/djkatta/cabshare/urls.py | ashishnitinpatil/mukatta | dfec9cd65d08f6b7d76b686fae3605986b31b80d | [
"BSD-2-Clause-FreeBSD",
"PSF-2.0",
"Apache-2.0",
"MIT",
"BSD-3-Clause"
] | null | null | null | wsgi/djkatta/cabshare/urls.py | ashishnitinpatil/mukatta | dfec9cd65d08f6b7d76b686fae3605986b31b80d | [
"BSD-2-Clause-FreeBSD",
"PSF-2.0",
"Apache-2.0",
"MIT",
"BSD-3-Clause"
] | null | null | null | wsgi/djkatta/cabshare/urls.py | ashishnitinpatil/mukatta | dfec9cd65d08f6b7d76b686fae3605986b31b80d | [
"BSD-2-Clause-FreeBSD",
"PSF-2.0",
"Apache-2.0",
"MIT",
"BSD-3-Clause"
] | null | null | null | from django.conf.urls import patterns, url
# App specific URL patterns
urlpatterns = patterns("djkatta.cabshare.views",
# post new req
url(r'new_post/$', 'new_post', name='new_post'),
# view posts by the user
url(r'my_posts/$', 'my_posts', name='my_posts'),
# modify old req
url(r'(?P<post_id... | 24.611111 | 59 | 0.611738 |
f6fadb640578e054ade2f1f7f1755e165fd9b8bc | 3,035 | py | Python | GANs/WGAN/train.py | sushant097/Deep-Learning-Paper-Scratch-Implementation | e1e5cbd0f1f10dd9ed0673e8a0506f33c94f6725 | [
"MIT"
] | 4 | 2022-01-07T14:48:13.000Z | 2022-02-24T10:10:24.000Z | GANs/WGAN/train.py | sushant097/Deep-Learning-Paper-Scratch-Implementation | e1e5cbd0f1f10dd9ed0673e8a0506f33c94f6725 | [
"MIT"
] | null | null | null | GANs/WGAN/train.py | sushant097/Deep-Learning-Paper-Scratch-Implementation | e1e5cbd0f1f10dd9ed0673e8a0506f33c94f6725 | [
"MIT"
] | null | null | null | import torch
from torchvision.utils import save_image
from torchvision import datasets
from torchvision.transforms import transforms
import os
from model import Generator, Discriminator, init_weights, denorm_image
from config import *
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
# create a d... | 28.364486 | 105 | 0.632619 |
f6fb3b9906e2a0e989b1efec9cae5a714bfdf274 | 5,969 | py | Python | examples/mpi_based_distributed_execution/MODIS_Aggregation_MPI.py | big-data-lab-umbc/MODIS_Aggregation | 43b79c44b0f62affdc3befb9c089a296e840893a | [
"Apache-2.0"
] | 3 | 2021-05-02T10:11:19.000Z | 2021-12-24T22:00:10.000Z | examples/mpi_based_distributed_execution/MODIS_Aggregation_MPI.py | big-data-lab-umbc/MODIS_Aggregation | 43b79c44b0f62affdc3befb9c089a296e840893a | [
"Apache-2.0"
] | 5 | 2019-11-26T21:09:35.000Z | 2022-03-03T19:23:25.000Z | examples/mpi_based_distributed_execution/MODIS_Aggregation_MPI.py | big-data-lab-umbc/MODIS_Aggregation | 43b79c44b0f62affdc3befb9c089a296e840893a | [
"Apache-2.0"
] | 4 | 2020-08-18T14:26:01.000Z | 2021-10-20T12:42:14.000Z | #!/usr/bin/env python
# coding:utf8
# -*- coding: utf-8 -*-
"""
Main Program: Run MODIS AGGREGATION IN MPI WITH FLEXIBLE STATISTICS
Created on 2020
@author: Jianyu Zheng (Email: jzheng3@umbc.edu)
"""
import os
import sys
import h5py
import timeit
import random
import calendar
import numpy as np
import pandas as pd
f... | 37.074534 | 171 | 0.68638 |
f6fb899f61687e61712367affa88a5603ababa3e | 5,631 | py | Python | repack_img.py | Illidanz/VampireTranslation | d57e88d0dcd7d5d1c9dcaaff2d6e5ea098d842b6 | [
"MIT"
] | 3 | 2021-12-02T07:12:21.000Z | 2022-02-16T04:26:21.000Z | repack_img.py | Illidanz/VampireTranslation | d57e88d0dcd7d5d1c9dcaaff2d6e5ea098d842b6 | [
"MIT"
] | 1 | 2021-12-07T17:54:58.000Z | 2021-12-07T17:54:59.000Z | repack_img.py | Illidanz/VampireTranslation | d57e88d0dcd7d5d1c9dcaaff2d6e5ea098d842b6 | [
"MIT"
] | null | null | null | import os
from hacktools import common, nitro
import images
| 45.780488 | 161 | 0.485171 |
f6fbcb6ce3a18a3d1314248bf99c7af9b4df0da9 | 1,741 | py | Python | src/waffle/downloader.py | JasonMWhite/congenial-waffle | 281513b4f566c43a3c326947c88ea53d60cc5fc3 | [
"MIT"
] | null | null | null | src/waffle/downloader.py | JasonMWhite/congenial-waffle | 281513b4f566c43a3c326947c88ea53d60cc5fc3 | [
"MIT"
] | 1 | 2021-12-13T19:53:44.000Z | 2021-12-13T19:53:44.000Z | src/waffle/downloader.py | JasonMWhite/congenial-waffle | 281513b4f566c43a3c326947c88ea53d60cc5fc3 | [
"MIT"
] | null | null | null | import typing
from lxml import html
import requests
from dataclasses import dataclass
from waffle.logger import LOG
from waffle.law_url import LawUrl
class Downloader:
LAWS = {
'english': "eng/acts/",
'french': "fra/lois/",
}
| 30.54386 | 117 | 0.643308 |
f6fc765a80d06b184d48204318ac290f02c0daa1 | 756 | py | Python | ozone-framework-python-server/people/urls.py | aamduka/ozone | 3fdbf232f5ea70661204a632e45310ca9d374973 | [
"Apache-2.0"
] | 6 | 2020-02-21T22:06:31.000Z | 2020-12-08T10:48:07.000Z | ozone-framework-python-server/people/urls.py | aamduka/ozone | 3fdbf232f5ea70661204a632e45310ca9d374973 | [
"Apache-2.0"
] | 12 | 2019-12-26T17:38:40.000Z | 2022-02-10T14:15:55.000Z | ozone-framework-python-server/people/urls.py | aamduka/ozone | 3fdbf232f5ea70661204a632e45310ca9d374973 | [
"Apache-2.0"
] | 4 | 2019-08-05T13:22:29.000Z | 2021-07-21T16:04:03.000Z | from django.urls import path
from rest_framework import routers
from .administration.views import AdministrationOfUserAPIView
from .views import PersonDetailView, PersonDashboardsWidgetsView, PersonWidgetDefinitionViewSet, PersonStackViewset
router = routers.SimpleRouter()
router.register(r'admin/users', Administrati... | 42 | 115 | 0.806878 |
f6fe49f2caf10f8c0e6901c9acd0a24f3952045a | 3,899 | py | Python | 00_CoinMarketCap_PullCryptoStats.py | prajwal-skdlove/CryptoCurrencyAnalysis | fd3dcc54c4e36722bb44405f16a4064452d83920 | [
"MIT"
] | 1 | 2021-12-05T19:37:58.000Z | 2021-12-05T19:37:58.000Z | 00_CoinMarketCap_PullCryptoStats.py | prajwal-skdlove/CryptoCurrencyAnalysis | fd3dcc54c4e36722bb44405f16a4064452d83920 | [
"MIT"
] | null | null | null | 00_CoinMarketCap_PullCryptoStats.py | prajwal-skdlove/CryptoCurrencyAnalysis | fd3dcc54c4e36722bb44405f16a4064452d83920 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
'''This code pulls all coins from Conmarketcap.com
It stores it in a pandas dataframe'''
from bs4 import BeautifulSoup
import requests
import pandas as pd
import json
import collections
def coinmarketcap_coins(n):
'''This function pulls all the cryptocurrencies and its relat... | 43.808989 | 97 | 0.611952 |
f6fee774c750964c054daa25511fd9a0fd69478c | 903 | py | Python | api/views/logs/resources.py | bdeprez/machinaris | 233d6e60ae6526b999fb660d9b87a895341de96f | [
"Apache-2.0"
] | null | null | null | api/views/logs/resources.py | bdeprez/machinaris | 233d6e60ae6526b999fb660d9b87a895341de96f | [
"Apache-2.0"
] | null | null | null | api/views/logs/resources.py | bdeprez/machinaris | 233d6e60ae6526b999fb660d9b87a895341de96f | [
"Apache-2.0"
] | null | null | null | import json
import re
import traceback
from flask import request, make_response, abort
from flask.views import MethodView
from api import app
from api.extensions.api import Blueprint
from api.commands import log_parser
blp = Blueprint(
'Log',
__name__,
url_prefix='/logs',
description="Operations on ... | 23.763158 | 127 | 0.687708 |
f6fefb9a652b9bf59e233f2f5acfc1fedff02992 | 11,550 | py | Python | train_hg_seqnet.py | middleprince/fashionAi | c512936b4983c2fb093008f06e04753180af0a90 | [
"Apache-2.0"
] | 316 | 2018-06-01T16:21:21.000Z | 2022-03-22T03:25:20.000Z | train_hg_seqnet.py | middleprince/fashionAi | c512936b4983c2fb093008f06e04753180af0a90 | [
"Apache-2.0"
] | 8 | 2018-06-02T07:07:49.000Z | 2019-07-11T06:55:43.000Z | train_hg_seqnet.py | middleprince/fashionAi | c512936b4983c2fb093008f06e04753180af0a90 | [
"Apache-2.0"
] | 91 | 2018-06-01T17:12:21.000Z | 2022-03-19T06:54:34.000Z | # Copyright 2018 Changan Wang
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
# http://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agreed to in writing, so... | 39.690722 | 153 | 0.638874 |
f6ff14536113c487785785cf8713fabd87f3391a | 34,386 | py | Python | W_conv.py | jeongjuns/Control_yolact | dad800dcc1aa0b02445e302256b4508b7688880c | [
"MIT"
] | null | null | null | W_conv.py | jeongjuns/Control_yolact | dad800dcc1aa0b02445e302256b4508b7688880c | [
"MIT"
] | null | null | null | W_conv.py | jeongjuns/Control_yolact | dad800dcc1aa0b02445e302256b4508b7688880c | [
"MIT"
] | null | null | null |
import math
import warnings
import torch
from torch import Tensor
from torch.nn.parameter import Parameter
import torch.nn.functional as F
import torch.nn.init as init
from torch.nn.modules.module import Module
from torch.nn.modules.utils import _single, _pair, _triple, _reverse_repeat_tuple
from torch.autograd impor... | 34.351648 | 120 | 0.529663 |
1001525132d1016af0a89108b37f0bd4e52435e6 | 2,246 | py | Python | instapyper.py | rriehle/instapyper | 0a2e01793a971ccaa47dac1cc32b6d6209ad7d77 | [
"MIT"
] | 1 | 2017-09-27T19:17:18.000Z | 2017-09-27T19:17:18.000Z | instapyper.py | rriehle/instapyper | 0a2e01793a971ccaa47dac1cc32b6d6209ad7d77 | [
"MIT"
] | null | null | null | instapyper.py | rriehle/instapyper | 0a2e01793a971ccaa47dac1cc32b6d6209ad7d77 | [
"MIT"
] | null | null | null | # encoding: utf-8
import requests
from requests_oauthlib import OAuth1
| 25.522727 | 93 | 0.547195 |
10016d95225710db6712e5ab81370184805de3d2 | 4,732 | py | Python | tests/parser/test_mamanger.py | Sungup/sungup-utils | 6ef3f9d65aaf5d9f11c683356823ead174c5793b | [
"MIT"
] | null | null | null | tests/parser/test_mamanger.py | Sungup/sungup-utils | 6ef3f9d65aaf5d9f11c683356823ead174c5793b | [
"MIT"
] | null | null | null | tests/parser/test_mamanger.py | Sungup/sungup-utils | 6ef3f9d65aaf5d9f11c683356823ead174c5793b | [
"MIT"
] | null | null | null | import os
import re
import string
from collections import namedtuple, defaultdict
from tests import utils
from tests.parser import ParserTestCase
from sglove.parser.exception import *
from sglove.parser import _OptionManager
| 37.259843 | 79 | 0.595097 |
1003316b1ac47d4a3dfc26a90b05ca7e035820e5 | 6,333 | py | Python | gitea_api/models/internal_tracker.py | awalker125/gitea-api | 2dea0493d4b6a92d6e63a7284afb2c80cbf35cf7 | [
"MIT"
] | null | null | null | gitea_api/models/internal_tracker.py | awalker125/gitea-api | 2dea0493d4b6a92d6e63a7284afb2c80cbf35cf7 | [
"MIT"
] | null | null | null | gitea_api/models/internal_tracker.py | awalker125/gitea-api | 2dea0493d4b6a92d6e63a7284afb2c80cbf35cf7 | [
"MIT"
] | 1 | 2022-01-27T14:12:40.000Z | 2022-01-27T14:12:40.000Z | # coding: utf-8
"""
Gitea API.
This documentation describes the Gitea API. # noqa: E501
OpenAPI spec version: 1.15.3
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
import pprint
import re # noqa: F401
import six
from gitea_api.configuration import Configuration
... | 34.796703 | 160 | 0.657666 |
1003df02d14e656596e0f0e0b34b98df84ded585 | 2,501 | py | Python | tests/unit/flow/test_flow_except.py | gvvynplaine/jina | 1441f40f849d22c21b8397527960b4307ff0d5a3 | [
"Apache-2.0"
] | 1 | 2021-09-07T05:10:24.000Z | 2021-09-07T05:10:24.000Z | tests/unit/flow/test_flow_except.py | gvvynplaine/jina | 1441f40f849d22c21b8397527960b4307ff0d5a3 | [
"Apache-2.0"
] | null | null | null | tests/unit/flow/test_flow_except.py | gvvynplaine/jina | 1441f40f849d22c21b8397527960b4307ff0d5a3 | [
"Apache-2.0"
] | null | null | null | import unittest
from jina.executors.crafters import BaseCrafter
from jina.flow import Flow
from jina.proto import jina_pb2
from tests import JinaTestCase
if __name__ == '__main__':
unittest.main()
| 35.225352 | 94 | 0.608956 |
10058581bb6dbcacbc9e94927325b0900f7918f8 | 5,734 | py | Python | Operator/server.py | ale9412/Operator | 353f873878018503015113cd26592ac7bf08bfc8 | [
"MIT"
] | null | null | null | Operator/server.py | ale9412/Operator | 353f873878018503015113cd26592ac7bf08bfc8 | [
"MIT"
] | null | null | null | Operator/server.py | ale9412/Operator | 353f873878018503015113cd26592ac7bf08bfc8 | [
"MIT"
] | null | null | null | import socketserver
import multiprocessing as mp
from shunting_yard_algorithm import evaluate
if __name__ == "__main__":
mp.freeze_support()
# If an ip address wants to be used instead, change localhost by the ip. If multiple interfaces want to be used
# you could change localhost... | 40.380282 | 120 | 0.647367 |
10075c04799cef519143b0f99e086bee68012233 | 16,539 | py | Python | cbh.py | jensengroup/fragreact | 2a9113505fd469e934eec6c6ac8200de67f65dd6 | [
"MIT"
] | 2 | 2018-10-01T00:40:12.000Z | 2020-01-16T15:02:51.000Z | cbh.py | jensengroup/fragreact | 2a9113505fd469e934eec6c6ac8200de67f65dd6 | [
"MIT"
] | null | null | null | cbh.py | jensengroup/fragreact | 2a9113505fd469e934eec6c6ac8200de67f65dd6 | [
"MIT"
] | 1 | 2021-04-24T10:53:30.000Z | 2021-04-24T10:53:30.000Z | #!/usr/bin/env python
import numpy as np
import re
from rdkit import Chem
from rdkit.Chem import rdMolDescriptors
from itertools import combinations
import copy
def canonical(smiles):
"""
SMILES provided is canonical, so the output should be the same no matter
how a particular molecule is input
"""... | 23.459574 | 98 | 0.587279 |
1007feef6144ad7d9a7ba9c6b18904b4be96b045 | 2,075 | py | Python | dlchord2/parser/accidentals_parser.py | anime-song/DLChord-2 | 10487b4c96ae1606974f52e08c0cb2e11940f5d0 | [
"MIT"
] | null | null | null | dlchord2/parser/accidentals_parser.py | anime-song/DLChord-2 | 10487b4c96ae1606974f52e08c0cb2e11940f5d0 | [
"MIT"
] | null | null | null | dlchord2/parser/accidentals_parser.py | anime-song/DLChord-2 | 10487b4c96ae1606974f52e08c0cb2e11940f5d0 | [
"MIT"
] | null | null | null | from enum import Enum
from dlchord2.const import ACCIDENTALS_SHARP, ACCIDENTALS_FLAT
from dlchord2.exceptions.accidentals_exceptions import AccidentalsParseError
| 23.314607 | 76 | 0.619277 |
1009bd5fe50141546afdc9a3c7299fc08481285f | 6,144 | py | Python | tests/unit/utils/test_instantiate.py | schiotz/nequip | c343ce25ecfeb64f6df92e96022e673a7714e3a6 | [
"MIT"
] | 153 | 2021-06-20T20:12:01.000Z | 2022-03-31T13:57:45.000Z | tests/unit/utils/test_instantiate.py | schiotz/nequip | c343ce25ecfeb64f6df92e96022e673a7714e3a6 | [
"MIT"
] | 25 | 2021-06-17T16:00:16.000Z | 2022-03-29T07:04:00.000Z | tests/unit/utils/test_instantiate.py | schiotz/nequip | c343ce25ecfeb64f6df92e96022e673a7714e3a6 | [
"MIT"
] | 25 | 2021-06-21T22:25:22.000Z | 2022-03-30T04:39:46.000Z | import pytest
import yaml
from nequip.utils import instantiate
simple_default = {"b": 1, "d": 31}
nested_default = {"d": 37}
def test_default():
"""
check the default value will not contaminate the other class
"""
c, params = instantiate(
builder=NestedExample,
prefix="pref... | 26.144681 | 87 | 0.60791 |
100e849d7eae3f15a11b1eea05ca93095bd322e6 | 9,160 | py | Python | models/wct2.py | momenator/spine_uda | 3d6c9cd2431bcdb084d7603d0cc3101163b0902c | [
"MIT"
] | 1 | 2020-12-15T08:46:39.000Z | 2020-12-15T08:46:39.000Z | models/wct2.py | momenator/spine_uda | 3d6c9cd2431bcdb084d7603d0cc3101163b0902c | [
"MIT"
] | null | null | null | models/wct2.py | momenator/spine_uda | 3d6c9cd2431bcdb084d7603d0cc3101163b0902c | [
"MIT"
] | null | null | null | import torch
import torch.nn as nn
import os
import torch.optim as optim
import torch.optim.lr_scheduler as lr_scheduler
from .modules import WavePool, WaveUnpool, ImagePool, NLayerDiscriminator
from utils.metrics import compute_dice_metric
from utils.losses import DiceLoss
import numpy as np
| 34.179104 | 96 | 0.569978 |
100fae21e6b69b129ccd390195c8899a6d2d0807 | 1,188 | py | Python | api/public/urls.py | marinimau/wayne_django_rest | eeaef0b9e3544c0f678b7f66684ac56f5ef90759 | [
"MIT"
] | null | null | null | api/public/urls.py | marinimau/wayne_django_rest | eeaef0b9e3544c0f678b7f66684ac56f5ef90759 | [
"MIT"
] | 5 | 2021-04-08T20:43:19.000Z | 2021-09-22T19:42:03.000Z | api/public/urls.py | marinimau/wayne_django_rest | eeaef0b9e3544c0f678b7f66684ac56f5ef90759 | [
"MIT"
] | null | null | null | #
# copyright 2020 - all rights reserved
# Created at: 03/11/20
# By: mauromarini
# License: MIT
# Repository: https://github.com/marinimau/wayne_django_rest
# Credits: @marinimau (https://github.com/marinimau)
#
from django.urls import path
from api.user import views as user_views
from api.social import... | 45.692308 | 120 | 0.591751 |
1012347db29b0e7431b7d278a87031a83ffc0e9a | 419 | py | Python | mentoring_app/migrations/0007_mentoringprogram_is_published.py | ShouravAhmed/Luminar | f80c621028f81ef7f657592560e4c95fd8e91699 | [
"MIT"
] | null | null | null | mentoring_app/migrations/0007_mentoringprogram_is_published.py | ShouravAhmed/Luminar | f80c621028f81ef7f657592560e4c95fd8e91699 | [
"MIT"
] | null | null | null | mentoring_app/migrations/0007_mentoringprogram_is_published.py | ShouravAhmed/Luminar | f80c621028f81ef7f657592560e4c95fd8e91699 | [
"MIT"
] | null | null | null | # Generated by Django 3.2.7 on 2021-12-28 05:56
from django.db import migrations, models
| 22.052632 | 63 | 0.630072 |
1013ecf59bc70ab9d79d68b8649884c783a2823a | 6,613 | py | Python | csdaily/data.py | qytz/cn_stock_daily | 93950c7be37f6717d1448e0f6c0f93947fdcafce | [
"Apache-2.0"
] | 1 | 2018-05-29T09:13:05.000Z | 2018-05-29T09:13:05.000Z | csdaily/data.py | qytz/cn_stock_daily | 93950c7be37f6717d1448e0f6c0f93947fdcafce | [
"Apache-2.0"
] | 1 | 2018-04-14T02:04:39.000Z | 2018-04-14T06:30:36.000Z | csdaily/data.py | qytz/csdaily | 93950c7be37f6717d1448e0f6c0f93947fdcafce | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# This file is part of CSDaily.
# Copyright (C) 2018-present qytz <hhhhhf@foxmail.com>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/l... | 36.535912 | 97 | 0.556782 |
101537d3feef1a4dbbd2ef2f6aa60048ff8c781a | 1,265 | py | Python | RecordSpider/beian.py | wjcIvan/oschinaLearning | 4f172b068ab00063b4b0e6217d031e0dcb48f492 | [
"MIT"
] | 1 | 2020-07-29T07:00:32.000Z | 2020-07-29T07:00:32.000Z | RecordSpider/beian.py | wjcIvan/oschinaLearning | 4f172b068ab00063b4b0e6217d031e0dcb48f492 | [
"MIT"
] | 4 | 2020-07-30T08:44:04.000Z | 2020-07-30T08:45:14.000Z | RecordSpider/beian.py | wjcIvan/oschinaLearning | 4f172b068ab00063b4b0e6217d031e0dcb48f492 | [
"MIT"
] | null | null | null | # coding:utf-8
import sys
from PyQt5 import QtWidgets
import window
import recordSpider
if __name__ == "__main__":
MainWindow()
| 30.119048 | 62 | 0.618972 |
10182dc2e471f5a0f909b79006a7d28c08916403 | 509 | py | Python | querybook/server/datasources_socketio/connect.py | shivammmmm/querybook | 71263eb7db79e56235ea752f2cf3339ca9b3a092 | [
"Apache-2.0"
] | 1,144 | 2021-03-30T05:06:16.000Z | 2022-03-31T10:40:31.000Z | querybook/server/datasources_socketio/connect.py | shivammmmm/querybook | 71263eb7db79e56235ea752f2cf3339ca9b3a092 | [
"Apache-2.0"
] | 593 | 2021-07-01T10:34:25.000Z | 2022-03-31T23:24:40.000Z | querybook/server/datasources_socketio/connect.py | shivammmmm/querybook | 71263eb7db79e56235ea752f2cf3339ca9b3a092 | [
"Apache-2.0"
] | 113 | 2021-03-30T00:07:20.000Z | 2022-03-31T07:18:43.000Z | from flask_login import current_user
from flask_socketio import ConnectionRefusedError
from app.flask_app import socketio
from const.data_doc import DATA_DOC_NAMESPACE
from const.query_execution import QUERY_EXECUTION_NAMESPACE
socketio.on("connect", namespace=DATA_DOC_NAMESPACE)(connect)
socketio.on("connect", nam... | 31.8125 | 87 | 0.827112 |
1019beaa3b165ae0d0bc9fd6b35ceadc23df9167 | 587 | py | Python | python/alibiexplainer/tests/utils.py | owennewo/kfserving | 89f73c87525b8e06ea799f69f2979c4ad272fcb3 | [
"Apache-2.0"
] | 2 | 2020-10-06T09:20:22.000Z | 2022-01-18T15:04:57.000Z | python/alibiexplainer/tests/utils.py | owennewo/kfserving | 89f73c87525b8e06ea799f69f2979c4ad272fcb3 | [
"Apache-2.0"
] | 15 | 2020-11-13T19:05:44.000Z | 2022-03-12T00:49:45.000Z | python/alibiexplainer/tests/utils.py | owennewo/kfserving | 89f73c87525b8e06ea799f69f2979c4ad272fcb3 | [
"Apache-2.0"
] | 2 | 2020-10-06T09:24:31.000Z | 2020-12-20T15:10:56.000Z | import kfserving
from typing import List, Union
import numpy as np
| 30.894737 | 69 | 0.623509 |
101a10a127a273feed1bef4adf70f1e5a220a9a0 | 2,186 | py | Python | relations/views.py | Mansouroopi/DRF | 057c6d77c012386734deee9c9076264c005d0221 | [
"MIT"
] | null | null | null | relations/views.py | Mansouroopi/DRF | 057c6d77c012386734deee9c9076264c005d0221 | [
"MIT"
] | null | null | null | relations/views.py | Mansouroopi/DRF | 057c6d77c012386734deee9c9076264c005d0221 | [
"MIT"
] | null | null | null |
from snippets.permissions import IsOwnerOrReadOnly
from rest_framework import permissions
from rest_framework import viewsets
from .models import Album, Track, Student, Module
from .serializers import AlbumSerializer, StudentSerializer, ModuleSerializer, TrackSerializer
from rest_framework.response import Response
... | 31.681159 | 94 | 0.663769 |
101a86c8d6437538ab20c4171397229b83fd18f9 | 184,923 | py | Python | venv/lib/python3.7/site-packages/torch/testing/_internal/common_methods_invocations.py | GOOGLE-M/SGC | 78ad8d02b80808302e38559e2d0f430f66a809bd | [
"MIT"
] | null | null | null | venv/lib/python3.7/site-packages/torch/testing/_internal/common_methods_invocations.py | GOOGLE-M/SGC | 78ad8d02b80808302e38559e2d0f430f66a809bd | [
"MIT"
] | null | null | null | venv/lib/python3.7/site-packages/torch/testing/_internal/common_methods_invocations.py | GOOGLE-M/SGC | 78ad8d02b80808302e38559e2d0f430f66a809bd | [
"MIT"
] | null | null | null | from functools import reduce, wraps, partial
from itertools import product
from operator import mul, itemgetter
import collections
import operator
import torch
import numpy as np
from torch._six import inf, istuple
from torch.autograd import Variable
import collections.abc
from typing import List, Tuple, Dict, Any
f... | 52.639624 | 129 | 0.546352 |
101a8bad1d0114bbb79e68c96eb4371364f2ff83 | 771 | py | Python | examples/python/numpy_functions.py | benedicteb/FYS2140-Resources | 31b572e455c3ac8dff868db903f18687e363f1bf | [
"MIT"
] | null | null | null | examples/python/numpy_functions.py | benedicteb/FYS2140-Resources | 31b572e455c3ac8dff868db903f18687e363f1bf | [
"MIT"
] | null | null | null | examples/python/numpy_functions.py | benedicteb/FYS2140-Resources | 31b572e455c3ac8dff868db903f18687e363f1bf | [
"MIT"
] | null | null | null | #!/usr/bin/env python
"""
Created on Mon 2 Dec 2013
Script viser import av funksjoner fra numpy og bruk av noen.
@author Benedicte Emilie Braekken
"""
from numpy import *
print 'e^1 =', exp( 1 ) # Eksponentialfunksjonen
print 'cos(pi) =', cos( pi ) # Cosinus
print 'sqrt(4) =', sqrt... | 28.555556 | 72 | 0.553826 |
63d7715ef7d63209fb2728483a0c7ddffb7d19ed | 4,261 | py | Python | homeassistant/components/automation/sun.py | instantchow/home-assistant | 6797365d4fd74328a0c9e961f652cfb37f48bc7d | [
"MIT"
] | null | null | null | homeassistant/components/automation/sun.py | instantchow/home-assistant | 6797365d4fd74328a0c9e961f652cfb37f48bc7d | [
"MIT"
] | null | null | null | homeassistant/components/automation/sun.py | instantchow/home-assistant | 6797365d4fd74328a0c9e961f652cfb37f48bc7d | [
"MIT"
] | null | null | null | """
Offer sun based automation rules.
For more details about this automation rule, please refer to the documentation
at https://home-assistant.io/components/automation/#sun-trigger
"""
import logging
from datetime import timedelta
import homeassistant.util.dt as dt_util
from homeassistant.components import sun
from h... | 28.986395 | 78 | 0.633185 |
63d787602e9b9889274c51a3e392c5c66b98f987 | 4,821 | py | Python | docs/source/conf.py | tanlin2013/Tensor-Network | 5b9a48076db57fc16f874ee453fe1ededdc5ebf6 | [
"Apache-2.0"
] | 1 | 2020-09-07T21:35:34.000Z | 2020-09-07T21:35:34.000Z | docs/source/conf.py | tanlin2013/Tensor-Network | 5b9a48076db57fc16f874ee453fe1ededdc5ebf6 | [
"Apache-2.0"
] | null | null | null | docs/source/conf.py | tanlin2013/Tensor-Network | 5b9a48076db57fc16f874ee453fe1ededdc5ebf6 | [
"Apache-2.0"
] | null | null | null | # Configuration file for the Sphinx documentation builder.
#
# This file only contains a selection of the most common options. For a full
# list see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html
# -- Path setup --------------------------------------------------------------
# If ex... | 30.512658 | 95 | 0.669156 |
63d7cdd21b779bfe16c82daade1776e92192157f | 1,963 | py | Python | tests/modules/organizations/test_models.py | karenc/houston | 4eaaaf11d61394035e34b55bb847ea7eb4099c61 | [
"Apache-2.0"
] | null | null | null | tests/modules/organizations/test_models.py | karenc/houston | 4eaaaf11d61394035e34b55bb847ea7eb4099c61 | [
"Apache-2.0"
] | 2 | 2021-03-16T20:28:06.000Z | 2021-03-29T15:54:11.000Z | tests/modules/organizations/test_models.py | karenc/houston | 4eaaaf11d61394035e34b55bb847ea7eb4099c61 | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# pylint: disable=invalid-name,missing-docstring
import sqlalchemy
import logging
| 32.716667 | 85 | 0.745288 |
63d7f9a0fc8895b2908acd7758b7421d434e3c58 | 5,097 | py | Python | Chapter 12/ch12_r03.py | PacktPublishing/Modern-Python-Cookbook | 40ff656c64421ddf6c288e058bb99a929f6d4c39 | [
"MIT"
] | 107 | 2016-11-30T02:13:39.000Z | 2022-03-31T06:38:59.000Z | Chapter 12/ch12_r03.py | fengfanzhiwu/Modern-Python-Cookbook | 8eff962f6eae514d531beca9051aefa34941ef4d | [
"MIT"
] | 2 | 2017-04-19T04:08:21.000Z | 2019-03-09T16:18:33.000Z | Chapter 12/ch12_r03.py | fengfanzhiwu/Modern-Python-Cookbook | 8eff962f6eae514d531beca9051aefa34941ef4d | [
"MIT"
] | 71 | 2017-01-16T06:35:17.000Z | 2022-03-01T21:25:54.000Z | """
{
"swagger": "2.0",
"info": {
"title": "Python Cookbook\\nChapter 12, recipe 3.",
"version": "1.0"
},
"schemes": "http",
"host": "127.0.0.1:5000",
"basePath": "/dealer",
"consumes": "application/json",
"produces": "application/json",
"paths": {
"/hands": {
... | 29.125714 | 120 | 0.476947 |
63d8ff7291ec00834c06722d6f791ed6401a8d77 | 158 | py | Python | Desafios/desafio053.py | josivantarcio/Desafios-em-Python | c747eed785b9640e15c498262fc5f8f5afd4337e | [
"MIT"
] | null | null | null | Desafios/desafio053.py | josivantarcio/Desafios-em-Python | c747eed785b9640e15c498262fc5f8f5afd4337e | [
"MIT"
] | 1 | 2021-04-23T15:11:11.000Z | 2021-05-21T22:36:56.000Z | Desafios/desafio053.py | josivantarcio/Desafios-em-Python | c747eed785b9640e15c498262fc5f8f5afd4337e | [
"MIT"
] | null | null | null | frase = str(input('Digite a frase: ')).strip().upper()
palavras = frase.split()
juntarPalavras = ''.join(palavras)
trocar = juntarPalavras[::-1]
print(trocar) | 31.6 | 54 | 0.702532 |
63dc294f098bbd41379d16d4e24791b73958a2ea | 1,345 | py | Python | python/examples/test_tds.py | dmillard/autogen | c14790f01b7e6ff4c140331317ad981c33e9b40f | [
"MIT"
] | 33 | 2021-10-29T21:33:39.000Z | 2022-03-31T11:02:43.000Z | python/examples/test_tds.py | dmillard/autogen | c14790f01b7e6ff4c140331317ad981c33e9b40f | [
"MIT"
] | 8 | 2021-08-13T07:01:05.000Z | 2021-11-16T19:07:33.000Z | python/examples/test_tds.py | dmillard/autogen | c14790f01b7e6ff4c140331317ad981c33e9b40f | [
"MIT"
] | 4 | 2021-10-31T10:59:44.000Z | 2021-11-06T07:21:45.000Z | import pytinydiffsim_ad as dp
import autogen as ag
import numpy as np
import math
TIME_STEPS = 20
f = ag.trace(func, [1.0] * TIME_STEPS)
gen = ag.GeneratedCppAD(f)
x = [2.0] * TIME_STEPS
y = f.forward(x)
print("y = ", y)
J = f.jacobian(x)
print("j = ", J) | 28.617021 | 147 | 0.692193 |
63dec534870631fac5a7cfc546198847fb5658b4 | 5,923 | py | Python | tf_rl/examples/NerveNet/network/ggnn.py | Rowing0914/TF2_RL | c1b7f9b376cbecf01deb17f76f8e761035ed336a | [
"MIT"
] | 8 | 2020-01-13T03:29:50.000Z | 2021-11-19T00:59:42.000Z | tf_rl/examples/NerveNet/network/ggnn.py | Rowing0914/TF2_RL | c1b7f9b376cbecf01deb17f76f8e761035ed336a | [
"MIT"
] | 5 | 2020-11-13T17:40:40.000Z | 2022-03-12T00:11:33.000Z | tf_rl/examples/NerveNet/network/ggnn.py | Rowing0914/TF2_RL | c1b7f9b376cbecf01deb17f76f8e761035ed336a | [
"MIT"
] | 1 | 2021-04-02T13:42:39.000Z | 2021-04-02T13:42:39.000Z | import tensorflow as tf
import tensorflow_probability as tfp
XAVIER_INIT = tf.contrib.layers.xavier_initializer()
| 48.950413 | 134 | 0.668749 |
63df36dd82f3b996a2b0bac96c47e201bb8f3bbf | 98 | py | Python | docsie_universal_importer/providers/google_drive/__init__.py | Zarif99/test-universal | 062972ed64d9f048de702ab1edf4025cffca2abb | [
"BSD-3-Clause"
] | null | null | null | docsie_universal_importer/providers/google_drive/__init__.py | Zarif99/test-universal | 062972ed64d9f048de702ab1edf4025cffca2abb | [
"BSD-3-Clause"
] | 16 | 2021-06-16T15:00:41.000Z | 2021-06-30T11:57:15.000Z | docsie_universal_importer/providers/google_drive/__init__.py | Zarif99/test-universal | 062972ed64d9f048de702ab1edf4025cffca2abb | [
"BSD-3-Clause"
] | 1 | 2021-11-17T19:24:45.000Z | 2021-11-17T19:24:45.000Z | default_app_config = 'docsie_universal_importer.providers.google_drive.apps.GoogleDriveAppConfig'
| 49 | 97 | 0.897959 |
63e0394902396da9e64268bf1086a084ded28c6f | 3,312 | py | Python | agent/h42backup/h42backup/container.py | gilles67/h42-backup | 24dcc6dad784b7a8f3586824bba801fc3333cb58 | [
"MIT"
] | null | null | null | agent/h42backup/h42backup/container.py | gilles67/h42-backup | 24dcc6dad784b7a8f3586824bba801fc3333cb58 | [
"MIT"
] | null | null | null | agent/h42backup/h42backup/container.py | gilles67/h42-backup | 24dcc6dad784b7a8f3586824bba801fc3333cb58 | [
"MIT"
] | null | null | null | import docker, json
VALID_PROFILE = ['volume', 'mariadb']
| 43.578947 | 140 | 0.520833 |
63e23b1440c3348f5642d4b2129b21ed8312660c | 7,309 | py | Python | testarch/unet/runs.py | weihao94/deepdyn | e8a1d6620f48094b76ea3d272c57d40c9ae6d949 | [
"MIT"
] | 42 | 2019-11-07T03:18:53.000Z | 2021-12-08T09:42:00.000Z | testarch/unet/runs.py | LucasLee-ff/deepdyn | 48018b62a245dd791e45d60b28068489a8c32742 | [
"MIT"
] | 17 | 2020-01-25T12:58:18.000Z | 2022-03-11T23:32:44.000Z | testarch/unet/runs.py | aksish/ature | 48018b62a245dd791e45d60b28068489a8c32742 | [
"MIT"
] | 21 | 2019-11-21T08:34:54.000Z | 2022-02-27T16:24:00.000Z | import copy
import os
import random
import numpy as np
sep = os.sep
####################### GLOBAL PARAMETERS ##################################################
############################################################################################
Params = {
'num_channels': 1,
'num_classes': 2,
'ba... | 36.914141 | 112 | 0.543166 |
63e27f210990b9b90b5a11bf73d8896f5729b462 | 3,673 | py | Python | mysql_table_generator.py | zed31/mongo_vs_mysql | 53c84c40a5f316b05445b1d9baf329c4ea85aa97 | [
"MIT"
] | null | null | null | mysql_table_generator.py | zed31/mongo_vs_mysql | 53c84c40a5f316b05445b1d9baf329c4ea85aa97 | [
"MIT"
] | null | null | null | mysql_table_generator.py | zed31/mongo_vs_mysql | 53c84c40a5f316b05445b1d9baf329c4ea85aa97 | [
"MIT"
] | null | null | null | #!/usr/bin/python3
import MySQLdb
from sys import argv, exit
from random import choice
arr_prefix = [
"sit",
"eiusmod",
"nulla",
"tempor",
"exercitation",
"Lorem",
"consectetur",
"qui",
"aute",
"laborum",
"culpa",
"sunt",
"sunt",
"enim",
"cupidatat",
"ipsum",
"nulla",
"consectetur"... | 18.183168 | 160 | 0.553771 |
63e3b897fe069846ad271c86ccffde7cfa2ad187 | 1,964 | py | Python | tests/test_database.py | rahulg/mongorm | 511611dc68b444317e8e3fe4a9e07cfe5d5032a2 | [
"BSD-2-Clause"
] | 4 | 2015-06-22T05:16:39.000Z | 2018-10-10T15:33:08.000Z | tests/test_database.py | rahulg/mongorm | 511611dc68b444317e8e3fe4a9e07cfe5d5032a2 | [
"BSD-2-Clause"
] | null | null | null | tests/test_database.py | rahulg/mongorm | 511611dc68b444317e8e3fe4a9e07cfe5d5032a2 | [
"BSD-2-Clause"
] | null | null | null | import unittest
from mongorm import Database
| 27.277778 | 72 | 0.63391 |
63e423f755852b992268e18edda0f5773e6503d3 | 760 | py | Python | heap/binary_heap_test.py | dyc-it/algorithm | 68b866c9bf5ee2b479be124d70d2362144d568bb | [
"Apache-2.0"
] | null | null | null | heap/binary_heap_test.py | dyc-it/algorithm | 68b866c9bf5ee2b479be124d70d2362144d568bb | [
"Apache-2.0"
] | null | null | null | heap/binary_heap_test.py | dyc-it/algorithm | 68b866c9bf5ee2b479be124d70d2362144d568bb | [
"Apache-2.0"
] | null | null | null | import unittest
import random
from binary_heap import BinaryHeap
| 24.516129 | 63 | 0.607895 |
63e5242ca320b82cfe9f818b9dabb8b7721af332 | 22,418 | py | Python | src/alfred3/element/action.py | mate-code/alfred | e687e9318ecefe3a49565027841ca8d910647978 | [
"MIT"
] | 9 | 2020-05-11T08:13:12.000Z | 2022-01-20T11:35:14.000Z | src/alfred3/element/action.py | mate-code/alfred | e687e9318ecefe3a49565027841ca8d910647978 | [
"MIT"
] | 77 | 2019-02-22T07:34:58.000Z | 2022-02-23T15:32:34.000Z | src/alfred3/element/action.py | mate-code/alfred | e687e9318ecefe3a49565027841ca8d910647978 | [
"MIT"
] | 6 | 2020-11-11T16:51:04.000Z | 2022-02-21T10:29:02.000Z | """
Provides elements that make stuff happen.
.. moduleauthor: Johannes Brachem <jbrachem@posteo.de>
"""
from typing import Union
from typing import List
from uuid import uuid4
import cmarkgfm
from cmarkgfm.cmark import Options as cmarkgfmOptions
from emoji import emojize
from ..exceptions import AlfredError
from .... | 32.442836 | 183 | 0.576724 |
63e5fd80b31040b98f86d3e9a1070894b979bab4 | 6,147 | py | Python | agent/main_runner.py | velteyn/agent57 | b0dd7b54fd4c3560b529fe196f62e9d51bfed82e | [
"MIT"
] | 48 | 2020-07-13T03:19:27.000Z | 2022-03-05T12:05:40.000Z | agent/main_runner.py | andreanvictor6374/agent57 | 175c8367254107d3f7e7ff12d40f01708b7ee75b | [
"MIT"
] | 10 | 2020-07-14T08:09:54.000Z | 2021-11-20T00:40:05.000Z | agent/main_runner.py | andreanvictor6374/agent57 | 175c8367254107d3f7e7ff12d40f01708b7ee75b | [
"MIT"
] | 14 | 2020-07-21T14:35:02.000Z | 2022-02-10T10:32:17.000Z | import gym
from keras.optimizers import Adam
import traceback
import os
from .dqn import DQN
from .agent57 import Agent57
from .model import InputType, DQNImageModel, LstmType
from .policy import AnnealingEpsilonGreedy
from .memory import PERRankBaseMemory, PERProportionalMemory
from .env_play import EpisodeSave, Epi... | 29.271429 | 100 | 0.616561 |
63e72dba0fb4b89d7e9e4db6bf070ba06e155aae | 1,473 | py | Python | Fred/7_Gestures/Reactions.py | ProjectHewitt/Fred_Inmoov | 179be5ba18c89fe6b2c64efc0b88c9db8e40b75b | [
"Apache-2.0"
] | 6 | 2021-02-25T02:14:56.000Z | 2021-06-13T16:13:00.000Z | Fred/7_Gestures/Reactions.py | ProjectHewitt/Fred_Inmoov | 179be5ba18c89fe6b2c64efc0b88c9db8e40b75b | [
"Apache-2.0"
] | null | null | null | Fred/7_Gestures/Reactions.py | ProjectHewitt/Fred_Inmoov | 179be5ba18c89fe6b2c64efc0b88c9db8e40b75b | [
"Apache-2.0"
] | 4 | 2021-02-07T00:14:32.000Z | 2021-10-02T03:32:44.000Z | ##############################################################
# Program Code for Fred Inmoov #
# Of the Cyber_One YouTube Channel #
# https://www.youtube.com/cyber_one #
# #
# Thi... | 37.769231 | 68 | 0.376782 |
63e79a57d87beb222b4d338e8505178a6b213db0 | 7,019 | py | Python | StormPyTwitter/src/main/multilang/resources/python/twitter_storm/twitter_components.py | juanrh/data42 | b42006917bfaf6bdf5aabf88f9b2714e879bf8f3 | [
"Apache-2.0"
] | 1 | 2016-04-06T09:21:42.000Z | 2016-04-06T09:21:42.000Z | StormPyTwitter/src/main/multilang/resources/python/twitter_storm/twitter_components.py | juanrh/data42 | b42006917bfaf6bdf5aabf88f9b2714e879bf8f3 | [
"Apache-2.0"
] | null | null | null | StormPyTwitter/src/main/multilang/resources/python/twitter_storm/twitter_components.py | juanrh/data42 | b42006917bfaf6bdf5aabf88f9b2714e879bf8f3 | [
"Apache-2.0"
] | 3 | 2015-12-14T00:16:31.000Z | 2019-03-24T13:35:55.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
'''
Based on storm.py module from https://github.com/nathanmarz/storm/blob/master/storm-core/src/multilang/py/storm.py, and the examples from https://github.com/apache/incubator-storm/blob/master/examples/storm-starter/multilang/resources/splitsentence.py and http://storm.... | 54.410853 | 397 | 0.695541 |
63e7de70cee4c80bf1a84446fed435049d34cefe | 1,329 | py | Python | nuremberg/core/urls.py | emmalemma/nuremberg | 10a5f789f5668aa4e7902e1765737c2c764ff2b2 | [
"MIT"
] | null | null | null | nuremberg/core/urls.py | emmalemma/nuremberg | 10a5f789f5668aa4e7902e1765737c2c764ff2b2 | [
"MIT"
] | null | null | null | nuremberg/core/urls.py | emmalemma/nuremberg | 10a5f789f5668aa4e7902e1765737c2c764ff2b2 | [
"MIT"
] | null | null | null | from django.conf.urls import include, url
from django.contrib import admin
from httpproxy.views import HttpProxy
from django.views.generic.base import RedirectView
from django.http import HttpResponse
urlpatterns = [
url(r'^admin/', admin.site.urls),
url(r'^transcripts/', include('nuremberg.transcripts.urls'))... | 49.222222 | 113 | 0.717833 |
63e9684d10afbc91d9cdbd324d7a08494f2c12d6 | 5,125 | py | Python | signin/jd_job/common.py | nujabse/simpleSignin | e818f9880d97d39beddcadccb53dc23e18fe6d8e | [
"MIT"
] | 11 | 2018-03-07T04:13:05.000Z | 2019-11-28T04:43:55.000Z | signin/jd_job/common.py | nujabse/simpleSignin | e818f9880d97d39beddcadccb53dc23e18fe6d8e | [
"MIT"
] | 2 | 2018-03-04T15:08:01.000Z | 2018-05-28T07:42:47.000Z | signin/jd_job/common.py | nujabse/simpleSignin | e818f9880d97d39beddcadccb53dc23e18fe6d8e | [
"MIT"
] | 15 | 2018-01-25T10:54:06.000Z | 2019-11-05T07:09:20.000Z | #!/usr/bin/env python
# encoding: utf-8
# author: Vincent
# refer: https://github.com/vc5
import re
import time
from requests import Response
from selenium.common.exceptions import NoSuchElementException
from selenium.webdriver.common.touch_actions import TouchActions
from ..chrome import mobile_emulation
from lib.se... | 31.441718 | 118 | 0.617756 |
63e9b0dfa031eb19f53844081f610705e8c0629f | 3,046 | py | Python | tests/test_parse.py | adamrp/emperor | ee12881953cdd65e13325c09d5adf87db7e63afd | [
"MIT"
] | null | null | null | tests/test_parse.py | adamrp/emperor | ee12881953cdd65e13325c09d5adf87db7e63afd | [
"MIT"
] | null | null | null | tests/test_parse.py | adamrp/emperor | ee12881953cdd65e13325c09d5adf87db7e63afd | [
"MIT"
] | null | null | null | #!/usr/bin/env python
from __future__ import division
__author__ = "Jose Antonio Navas Molina"
__copyright__ = "Copyright 2013, The Emperor Project"
__credits__ = ["Jose Antonio Navas Molina"]
__license__ = "BSD"
__version__ = "0.9.3-dev"
__maintainer__ = "Jose Antonio Navas Molina"
__email__ = "josenavasmolina@gmail... | 28.46729 | 79 | 0.601116 |
63eb09455a488d9193ff41ee088a0eccb9993357 | 998 | py | Python | Nmapscript.py | WhiteRedTHT/port-scann | bb4a6731f3c4ae484d1978fa7527f55520cb7e99 | [
"MIT"
] | null | null | null | Nmapscript.py | WhiteRedTHT/port-scann | bb4a6731f3c4ae484d1978fa7527f55520cb7e99 | [
"MIT"
] | null | null | null | Nmapscript.py | WhiteRedTHT/port-scann | bb4a6731f3c4ae484d1978fa7527f55520cb7e99 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
import os
import vulners
print("---------------------------------------------------------------")
print(""" P4RS Script Ho Geldiniz
Program kullanmak iin sadece IP adresini yazmanz yeterlidir.
Program altrmak iin; Medusa aralar, searcsploit ve brutespray uygulamalar gerekmektedir. BruteSpra... | 26.263158 | 179 | 0.61022 |
63ee6c3b647155df5b389065b12bf3169080b2cc | 1,276 | py | Python | portal/migrations/versions/a031e26dc1bd_.py | ivan-c/truenth-portal | 0b9d39ae43f42ea3413ed9634f295f5d856cbc77 | [
"BSD-3-Clause"
] | 3 | 2017-01-15T10:11:57.000Z | 2018-10-02T23:46:44.000Z | portal/migrations/versions/a031e26dc1bd_.py | uwcirg/true_nth_usa_portal | e2434731aed86f1c43f15d428dde8ffc28ac7e5f | [
"BSD-3-Clause"
] | 876 | 2016-04-04T20:45:11.000Z | 2019-02-28T00:10:36.000Z | portal/migrations/versions/a031e26dc1bd_.py | uwcirg/truenth-portal | 459a0d157982f010175c50b9cccd860a61790370 | [
"BSD-3-Clause"
] | 9 | 2016-04-13T01:18:55.000Z | 2018-09-19T20:44:23.000Z | from alembic import op
import sqlalchemy as sa
import sqlalchemy_utils
"""empty message
Revision ID: a031e26dc1bd
Revises: 8efa45d83a3b
Create Date: 2018-08-06 16:03:36.820890
"""
# revision identifiers, used by Alembic.
revision = 'a031e26dc1bd'
down_revision = '8efa45d83a3b'
| 28.355556 | 67 | 0.576019 |
63f048c44468cdaab3bbd671bedb7f73b50abad5 | 7,048 | py | Python | gui/main_window/reservations/add_reservations/gui.py | Just-Moh-it/HotinGo | 13f3d0d9ed7991336dfbb4f50c2b87a7d9d19810 | [
"MIT"
] | 14 | 2022-02-08T02:40:34.000Z | 2022-03-24T19:17:57.000Z | gui/main_window/reservations/add_reservations/gui.py | Just-Moh-it/HotinGo | 13f3d0d9ed7991336dfbb4f50c2b87a7d9d19810 | [
"MIT"
] | 2 | 2022-02-03T13:22:04.000Z | 2022-02-08T06:16:57.000Z | gui/main_window/reservations/add_reservations/gui.py | SnazzyCoder/HotinGo | 13f3d0d9ed7991336dfbb4f50c2b87a7d9d19810 | [
"MIT"
] | 1 | 2022-03-21T00:05:47.000Z | 2022-03-21T00:05:47.000Z | from pathlib import Path
from tkinter import Frame, Canvas, Entry, Text, Button, PhotoImage, messagebox
import controller as db_controller
OUTPUT_PATH = Path(__file__).parent
ASSETS_PATH = OUTPUT_PATH / Path("./assets")
| 32.036364 | 87 | 0.539444 |
63f0dcedfc927c0b523f3a53c332513bb2498eb2 | 8,977 | py | Python | lib/util/ImageProcessing/homopgrahy.py | Thukor/MazeSolver | c953e193ce27a7348e8ec9c5592144426dfce193 | [
"MIT"
] | 5 | 2018-02-06T22:48:34.000Z | 2020-01-07T20:19:05.000Z | lib/util/ImageProcessing/homopgrahy.py | Thukor/MazeSolver | c953e193ce27a7348e8ec9c5592144426dfce193 | [
"MIT"
] | 11 | 2018-01-31T21:47:49.000Z | 2018-04-21T16:42:52.000Z | lib/util/ImageProcessing/homopgrahy.py | Thukor/MazeSolver | c953e193ce27a7348e8ec9c5592144426dfce193 | [
"MIT"
] | 2 | 2020-06-18T05:40:03.000Z | 2022-02-02T03:46:30.000Z | import cv2
import numpy as np
import imutils
from collections import defaultdict
# mouse callback function
def segment_by_angle_kmeans(lines,k=2, **kwargs):
"""Groups lines based on angle with k-means.
Uses k-means on the coordinates of the angle on the unit circle
to segment `k` angles inside `lines`.
... | 33.003676 | 102 | 0.614236 |
63f426a7b9bb1a0814ac7f14e6b624d2906c52be | 8,729 | py | Python | chime.py | alexklapheke/chime | 2a0ed71310488cfc5cf5daeacd3dcb62558d44dc | [
"MIT"
] | null | null | null | chime.py | alexklapheke/chime | 2a0ed71310488cfc5cf5daeacd3dcb62558d44dc | [
"MIT"
] | null | null | null | chime.py | alexklapheke/chime | 2a0ed71310488cfc5cf5daeacd3dcb62558d44dc | [
"MIT"
] | null | null | null | import argparse
import configparser
import os
import pathlib
import platform
import random
import subprocess as sp
import sys
import typing
import warnings
if platform.system() == 'Windows':
import winsound
try:
from IPython.core import magic
IPYTHON_INSTALLED = True
except ImportError:
IPYTHON_INSTAL... | 27.799363 | 99 | 0.613701 |
63f4fd4ae3791d5d16a0a77ceadc4495ca195f7c | 7,733 | py | Python | tests/Omega/test_Omega_ligand_preparation.py | niladell/DockStream | 75f06d24a95699cdc06fe1ea021e213e1d9fa5b3 | [
"Apache-2.0"
] | 34 | 2021-08-05T06:28:30.000Z | 2022-03-17T02:42:49.000Z | tests/Omega/test_Omega_ligand_preparation.py | niladell/DockStream | 75f06d24a95699cdc06fe1ea021e213e1d9fa5b3 | [
"Apache-2.0"
] | 9 | 2021-08-31T10:35:51.000Z | 2022-02-03T08:57:58.000Z | tests/Omega/test_Omega_ligand_preparation.py | niladell/DockStream | 75f06d24a95699cdc06fe1ea021e213e1d9fa5b3 | [
"Apache-2.0"
] | 10 | 2021-08-12T02:32:11.000Z | 2022-01-19T11:51:33.000Z | import unittest
import os
from dockstream.core.OpenEyeHybrid.Omega_ligand_preparator import OmegaLigandPreparator
from dockstream.core.ligand.ligand_input_parser import LigandInputParser
from dockstream.utils.enums.docking_enum import DockingConfigurationEnum
from dockstream.utils.enums.Omega_enums import OmegaExecu... | 46.305389 | 112 | 0.655114 |
63f58c76597e10765889d7945f69878a414cf4fc | 1,989 | py | Python | tests/test_blog/test_post_search.py | florimondmanca/personal-api | 6300f965d3f51d1bf5f10cf1eb15d673bd627631 | [
"MIT"
] | 4 | 2018-08-17T08:06:06.000Z | 2020-02-20T15:15:56.000Z | tests/test_blog/test_post_search.py | florimondmanca/personal-api | 6300f965d3f51d1bf5f10cf1eb15d673bd627631 | [
"MIT"
] | 2 | 2018-10-08T15:59:58.000Z | 2018-10-20T16:50:13.000Z | tests/test_blog/test_post_search.py | florimondmanca/personal-api | 6300f965d3f51d1bf5f10cf1eb15d673bd627631 | [
"MIT"
] | 1 | 2019-09-14T23:15:10.000Z | 2019-09-14T23:15:10.000Z | """Test searching the list of blog posts."""
from typing import List
from rest_framework.test import APITestCase
from blog.factories import PostFactory
from tests.decorators import authenticated
| 33.15 | 78 | 0.676219 |
63f6b54840467413595924d2498a90042e914026 | 10,641 | py | Python | yo/schema.py | RailCoin/yo | c5384cedd30771b36d4603d7a28b30d7a1273433 | [
"MIT"
] | 10 | 2017-10-22T20:07:40.000Z | 2018-08-01T21:48:49.000Z | client-libs/yo/yo/schema.py | Blurt-Blockchain/steem | fbffd373cdb0f6192aa8806d07e8671e219c3767 | [
"MIT"
] | 81 | 2017-08-19T15:38:32.000Z | 2020-05-12T09:56:14.000Z | client-libs/yo/yo/schema.py | Blurt-Blockchain/steem | fbffd373cdb0f6192aa8806d07e8671e219c3767 | [
"MIT"
] | 9 | 2017-09-19T07:12:20.000Z | 2021-05-25T17:09:27.000Z | # coding=utf-8
from enum import IntEnum
NOTIFICATION_TYPES = [i.name for i in NotificationType]
TRANSPORT_TYPES = [i.name for i in TransportType]
EVENT_ORIGINS = [i.name for i in EventOrigin]
EVENT_PRIORITIES = [i.name for i in EventPriority]
'''
Example Notification
-------
{
"notify_id": 39,
... | 26.871212 | 253 | 0.423926 |
63f6c1a6e6d4382fdea90513c54f2d68c07f76d8 | 2,491 | py | Python | iu_mongo/session.py | intelligenceunion/mongo-driver | 02bbc6839c8264d4b06b053e8cc83d42147ede17 | [
"MIT"
] | null | null | null | iu_mongo/session.py | intelligenceunion/mongo-driver | 02bbc6839c8264d4b06b053e8cc83d42147ede17 | [
"MIT"
] | null | null | null | iu_mongo/session.py | intelligenceunion/mongo-driver | 02bbc6839c8264d4b06b053e8cc83d42147ede17 | [
"MIT"
] | 1 | 2019-06-21T17:49:08.000Z | 2019-06-21T17:49:08.000Z | from pymongo.read_concern import ReadConcern
from pymongo.read_preferences import ReadPreference
from pymongo.write_concern import WriteConcern
from pymongo.errors import InvalidOperation
from iu_mongo.errors import TransactionError
__all__ = ['Session', 'TransactionContext']
DEFAULT_READ_CONCERN = ReadConcern('major... | 32.350649 | 96 | 0.734243 |
63f8d4f926db9084fff0778f781e3d35e9ba0d24 | 5,009 | py | Python | bin/ingredient_phrase_tagger/training/cli.py | Deekshith1994/Recipes | 5dfc98b249f6caf90571c037eb35560417b6818e | [
"Apache-2.0"
] | null | null | null | bin/ingredient_phrase_tagger/training/cli.py | Deekshith1994/Recipes | 5dfc98b249f6caf90571c037eb35560417b6818e | [
"Apache-2.0"
] | null | null | null | bin/ingredient_phrase_tagger/training/cli.py | Deekshith1994/Recipes | 5dfc98b249f6caf90571c037eb35560417b6818e | [
"Apache-2.0"
] | null | null | null | import re
import decimal
import optparse
import pandas as pd
from ingredient_phrase_tagger.training import utils
| 30.730061 | 102 | 0.553404 |
63f969d5f629381bf59ef7c423c9e80ade88f17b | 726 | py | Python | snowballs.py | GYosifov88/Python-Fundamentals | b46ba2822bd2dac6ff46830c6a520e559b448442 | [
"MIT"
] | null | null | null | snowballs.py | GYosifov88/Python-Fundamentals | b46ba2822bd2dac6ff46830c6a520e559b448442 | [
"MIT"
] | null | null | null | snowballs.py | GYosifov88/Python-Fundamentals | b46ba2822bd2dac6ff46830c6a520e559b448442 | [
"MIT"
] | null | null | null | import sys
number_of_snowballs = int(input())
highest_value = -sys.maxsize
highest_quality = -sys.maxsize
highest_weight = -sys.maxsize
highest_time = -sys.maxsize
for i in range (number_of_snowballs):
weight_of_snowball = int(input())
time_of_reaching = int(input())
quality_of_snowball = int(input())
... | 31.565217 | 91 | 0.746556 |
63f9f32e4e0b138503ce2018f80b9a8c535cec3c | 1,871 | py | Python | altperf-server/apps/start-api.py | ynakaoku/altperf | eb4e9e8e76820ddf0325a047eed20a64accb9cf8 | [
"MIT"
] | null | null | null | altperf-server/apps/start-api.py | ynakaoku/altperf | eb4e9e8e76820ddf0325a047eed20a64accb9cf8 | [
"MIT"
] | null | null | null | altperf-server/apps/start-api.py | ynakaoku/altperf | eb4e9e8e76820ddf0325a047eed20a64accb9cf8 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from flask import Flask, jsonify, request, Markup, abort, make_response
# import peewee
# import json
api = Flask(__name__)
if __name__ == '__main__':
api.run(host='0.0.0.0', port=8000)
| 32.824561 | 82 | 0.597007 |
63fa568f646d17018a9b9b6a0c301f61efae8ec9 | 4,212 | py | Python | ESAN.py | wnxbwyc/ESAN | 9f97c4cf0d323e893ac2205ec945b6c37320aaf3 | [
"MIT"
] | null | null | null | ESAN.py | wnxbwyc/ESAN | 9f97c4cf0d323e893ac2205ec945b6c37320aaf3 | [
"MIT"
] | null | null | null | ESAN.py | wnxbwyc/ESAN | 9f97c4cf0d323e893ac2205ec945b6c37320aaf3 | [
"MIT"
] | null | null | null | import functools
import torch.nn as nn
import torch.nn.functional as F
import torch.nn.init as init
| 33.428571 | 92 | 0.555793 |
63fb8b0b09023645d9ad10a5e8feb048ac8c77ad | 3,478 | py | Python | problems/tsptw/problem_tsptw.py | cem0963/dpdp | 86f91a1e425826a3f31bcc175724c26a349fdb96 | [
"MIT"
] | null | null | null | problems/tsptw/problem_tsptw.py | cem0963/dpdp | 86f91a1e425826a3f31bcc175724c26a349fdb96 | [
"MIT"
] | null | null | null | problems/tsptw/problem_tsptw.py | cem0963/dpdp | 86f91a1e425826a3f31bcc175724c26a349fdb96 | [
"MIT"
] | null | null | null | import math
import numpy as np
from scipy.spatial.distance import cdist
from torch.utils.data import Dataset
import torch
import os
import pickle
from problems.tsptw.state_tsptw import StateTSPTWInt
from utils.functions import accurate_cdist
| 33.76699 | 135 | 0.587407 |
63fc18b2a0a8c8afa137abd0e9e8f89ed4b67b71 | 11,089 | py | Python | thespian/test/__init__.py | dendron2000/Thespian | 0acbc5a0803f6d2be3421ea6eb08c6beecbf3802 | [
"MIT"
] | 210 | 2015-08-31T19:39:34.000Z | 2020-01-10T08:07:48.000Z | thespian/test/__init__.py | dendron2000/Thespian | 0acbc5a0803f6d2be3421ea6eb08c6beecbf3802 | [
"MIT"
] | 85 | 2017-04-08T19:28:42.000Z | 2022-03-23T15:25:49.000Z | thespian/test/__init__.py | dendron2000/Thespian | 0acbc5a0803f6d2be3421ea6eb08c6beecbf3802 | [
"MIT"
] | 47 | 2015-09-01T19:24:20.000Z | 2020-01-02T20:03:05.000Z | """Defines various classes and definitions that provide assistance for
unit testing Actors in an ActorSystem."""
import unittest
import pytest
import logging
import time
from thespian.actors import ActorSystem
def simpleActorTestLogging():
"""This function returns a logging dictionary that can be passed as
... | 39.74552 | 133 | 0.646497 |
63fc46927ba7027c56b95c5435a784c8f5cc9d72 | 2,454 | py | Python | main.py | JeffSpies/nonwordlist | 3f4e3c3c4d81d36f28ce03baf10f2a29b1272722 | [
"Apache-2.0"
] | null | null | null | main.py | JeffSpies/nonwordlist | 3f4e3c3c4d81d36f28ce03baf10f2a29b1272722 | [
"Apache-2.0"
] | null | null | null | main.py | JeffSpies/nonwordlist | 3f4e3c3c4d81d36f28ce03baf10f2a29b1272722 | [
"Apache-2.0"
] | 2 | 2016-05-19T07:14:25.000Z | 2019-05-09T03:14:50.000Z | from process import wordlist
import itertools
import time
import os
import re
ALPHABET = '23456789abcdefghjkmnpqrstuvwxyz'
if __name__ == '__main__':
main()
| 27.266667 | 85 | 0.5978 |
63fd18d9cde24eebf1bd28cfec8a2e3f2f9d0dd4 | 10,400 | py | Python | src/PPO.py | thurbridi/mo436-project-1 | 6d29bb4536d684a79b1a271e4d8505aca40db03b | [
"MIT"
] | null | null | null | src/PPO.py | thurbridi/mo436-project-1 | 6d29bb4536d684a79b1a271e4d8505aca40db03b | [
"MIT"
] | null | null | null | src/PPO.py | thurbridi/mo436-project-1 | 6d29bb4536d684a79b1a271e4d8505aca40db03b | [
"MIT"
] | null | null | null | import numpy as np
import random
import gym
import time
import itertools
from numpy.random.mtrand import gamma
import torch
from torch import nn
from torch._C import dtype
from torch.optim import Adam
from torch.distributions import Categorical
def PPO_clip(env: gym.Env, actor, critic, actor_lr, critic_lr, epochs... | 30.3207 | 121 | 0.590096 |
63fe55bbd1c58b24c66f67e3ef0288edddb3e0ab | 4,052 | pyw | Python | python/macRC.pyw | drs251/MacRC | 35bcf8d8b7c64d48d90fcde3aa83786f820e5b0c | [
"MIT"
] | null | null | null | python/macRC.pyw | drs251/MacRC | 35bcf8d8b7c64d48d90fcde3aa83786f820e5b0c | [
"MIT"
] | null | null | null | python/macRC.pyw | drs251/MacRC | 35bcf8d8b7c64d48d90fcde3aa83786f820e5b0c | [
"MIT"
] | null | null | null | from subprocess import Popen, PIPE
from distutils.util import strtobool
import serial
import sys
import time
import glob
import serial.tools.list_ports_posix
get_volume_script = b'''output volume of (get volume settings)'''
set_volume_script = b'''
on run {x}
set volume output volume x
end run'''
vo... | 26.834437 | 98 | 0.55849 |
63ffa1929e247b6219607c1f68157af18847d3fb | 4,275 | py | Python | tryopenapi.py | fakegit/eave | 3b4e5183a3f6df952685d63cf983d03c2157dff6 | [
"MIT"
] | null | null | null | tryopenapi.py | fakegit/eave | 3b4e5183a3f6df952685d63cf983d03c2157dff6 | [
"MIT"
] | null | null | null | tryopenapi.py | fakegit/eave | 3b4e5183a3f6df952685d63cf983d03c2157dff6 | [
"MIT"
] | null | null | null |
import json
import yaml
import dnode
from eave import *
openapi_yaml = open('openapi.yaml').read()
openapi_json = open('openapi.json').read()
yaml_data = yaml.safe_load(openapi_yaml)
json_data = json.loads(openapi_json)
assert yaml_data == json_data
root = DNode(json_data)
doc = Doc()
info = root.info
if info:... | 28.311258 | 87 | 0.564211 |
63fffacd17d14f9d91e78c33cd2cb358957bdfb0 | 12,939 | py | Python | memory.py | Matioz/World-Models | e0eb98b78b4fa6b8828fef8098f867a4ccf06a36 | [
"MIT"
] | 9 | 2018-08-21T14:25:50.000Z | 2021-12-15T12:10:51.000Z | memory.py | Matioz/World-Models | e0eb98b78b4fa6b8828fef8098f867a4ccf06a36 | [
"MIT"
] | 5 | 2018-08-25T10:29:05.000Z | 2018-09-19T15:18:40.000Z | memory.py | Matioz/World-Models | e0eb98b78b4fa6b8828fef8098f867a4ccf06a36 | [
"MIT"
] | 3 | 2018-10-01T00:55:12.000Z | 2019-05-09T07:33:31.000Z | import logging as log
import numpy as np
import h5py
import humblerl as hrl
from humblerl import Callback, Interpreter
import torch
import torch.nn as nn
import torch.optim as optim
from torch.distributions import Normal
from torch.utils.data import Dataset
from common_utils import get_model_path_if_exists
from third... | 42.00974 | 104 | 0.64464 |
12004752447a3c322e24283675f1768106bc32b5 | 761 | py | Python | wagtailrelated/utils.py | torchbox/wagtail-related | b0e811e5093d6d5c1554cab66f3c5097d6d474ad | [
"BSD-3-Clause"
] | 2 | 2018-09-03T15:09:30.000Z | 2020-11-29T02:23:01.000Z | wagtailrelated/utils.py | torchbox/wagtail-related | b0e811e5093d6d5c1554cab66f3c5097d6d474ad | [
"BSD-3-Clause"
] | null | null | null | wagtailrelated/utils.py | torchbox/wagtail-related | b0e811e5093d6d5c1554cab66f3c5097d6d474ad | [
"BSD-3-Clause"
] | null | null | null | from bs4 import BeautifulSoup
from wagtail.core.fields import StreamField
def extract_text(obj):
"""Extracts data, concatenates and removes html tags
from fields listed in a obj.related_source_fields list.
"""
related_source_fields = getattr(obj._meta.model, 'related_source_fields', None)
if not r... | 29.269231 | 83 | 0.703022 |
12012366643f4f22b21641dcce1d6d36c1aaaf3a | 1,233 | py | Python | codes/globo_videos_cuts/core/tests/models/programs_model_test_case.py | lariodiniz/teste_meta | 3bf043df3ee76871d68a3f8aea7c3ecd53765fec | [
"MIT"
] | null | null | null | codes/globo_videos_cuts/core/tests/models/programs_model_test_case.py | lariodiniz/teste_meta | 3bf043df3ee76871d68a3f8aea7c3ecd53765fec | [
"MIT"
] | null | null | null | codes/globo_videos_cuts/core/tests/models/programs_model_test_case.py | lariodiniz/teste_meta | 3bf043df3ee76871d68a3f8aea7c3ecd53765fec | [
"MIT"
] | null | null | null | # coding: utf-8
__author__ = "Lrio dos Santos Diniz"
from django.test import TestCase
from model_mommy import mommy
from core.models import Programs
| 33.324324 | 106 | 0.680454 |
1201648d14db637a8c539982bbb05d716a282c19 | 8,002 | py | Python | figures/plot_occurrence.py | wdlynch/symbolic_experiments | 8c0c9bf93edc8f58ed1e027cf5704dadd57e853a | [
"MIT"
] | null | null | null | figures/plot_occurrence.py | wdlynch/symbolic_experiments | 8c0c9bf93edc8f58ed1e027cf5704dadd57e853a | [
"MIT"
] | null | null | null | figures/plot_occurrence.py | wdlynch/symbolic_experiments | 8c0c9bf93edc8f58ed1e027cf5704dadd57e853a | [
"MIT"
] | 1 | 2022-01-25T18:35:44.000Z | 2022-01-25T18:35:44.000Z |
import os
import pandas as pd
import numpy as np
import seaborn as sns
import matplotlib.pyplot as plt
from matplotlib.lines import Line2D
from matplotlib import rcParams
params = {
# 'text.latex.preamble': ['\\usepackage{gensymb}'],
# 'text.usetex': True,
'font.family': 'Helvetica',
'lines.solid_capstyle'... | 29.970037 | 142 | 0.661335 |
1201b7d36d1bc8f3a1d15295c1c59670a006d89d | 1,164 | py | Python | Chapter04/apriori.py | PacktPublishing/Mastering-Machine-Learning-Algorithms-Second-Edition | 706d76fdb91b8c59223879cb236ce2bb6cc7e768 | [
"MIT"
] | 40 | 2019-08-23T13:33:12.000Z | 2022-02-24T12:48:41.000Z | Chapter04/apriori.py | PacktPublishing/Mastering-Machine-Learning-Algorithms-Second-Edition | 706d76fdb91b8c59223879cb236ce2bb6cc7e768 | [
"MIT"
] | null | null | null | Chapter04/apriori.py | PacktPublishing/Mastering-Machine-Learning-Algorithms-Second-Edition | 706d76fdb91b8c59223879cb236ce2bb6cc7e768 | [
"MIT"
] | 33 | 2019-10-21T09:47:51.000Z | 2022-01-14T17:21:54.000Z | import numpy as np
# Install the library using: pip install -U efficient-apriori
from efficient_apriori import apriori
# Set random seed for reproducibility
np.random.seed(1000)
nb_users = 100
nb_products = 100
if __name__ == "__main__":
# Create the dataset
items = [i for i in range(nb_products)]
t... | 25.304348 | 61 | 0.534364 |
12027780d9f17722cbac1d89fef4396c4df419ca | 1,202 | py | Python | graph_nn-master/utils.py | allisontam/graph_coattention | 5edc98615d5526269452b519bb13512ec5e952da | [
"MIT"
] | null | null | null | graph_nn-master/utils.py | allisontam/graph_coattention | 5edc98615d5526269452b519bb13512ec5e952da | [
"MIT"
] | null | null | null | graph_nn-master/utils.py | allisontam/graph_coattention | 5edc98615d5526269452b519bb13512ec5e952da | [
"MIT"
] | null | null | null | import numpy as np | 42.928571 | 107 | 0.591514 |
1203c3903ddc96149a5651577ae2b0829fdbb6b4 | 498 | py | Python | dingus/block.py | ricott1/dingus | ef0edd9fff164f54171b354714e600f410a3bbe9 | [
"MIT"
] | null | null | null | dingus/block.py | ricott1/dingus | ef0edd9fff164f54171b354714e600f410a3bbe9 | [
"MIT"
] | null | null | null | dingus/block.py | ricott1/dingus | ef0edd9fff164f54171b354714e600f410a3bbe9 | [
"MIT"
] | null | null | null | import dingus.codec
import utils
import transaction
| 17.172414 | 51 | 0.616466 |
120470c227d9ba2b49eaf7b4e99557346482221f | 34,609 | py | Python | sigpy/block.py | EfratShimron/sigpy | d140abf0fe7268851aec3be74d238a5ba8d2dd28 | [
"BSD-3-Clause"
] | null | null | null | sigpy/block.py | EfratShimron/sigpy | d140abf0fe7268851aec3be74d238a5ba8d2dd28 | [
"BSD-3-Clause"
] | null | null | null | sigpy/block.py | EfratShimron/sigpy | d140abf0fe7268851aec3be74d238a5ba8d2dd28 | [
"BSD-3-Clause"
] | null | null | null | # -*- coding: utf-8 -*-
"""Block reshape functions.
"""
import numpy as np
import numba as nb
from sigpy import backend, config, util
__all__ = ['array_to_blocks', 'blocks_to_array']
def array_to_blocks(input, blk_shape, blk_strides):
"""Extract blocks from an array in a sliding window manner.
Args:
... | 40.8125 | 79 | 0.38464 |
12047d5e2a741823096dbc33bf5afe683749bd26 | 1,531 | py | Python | awscdk/app.py | jaliste/mi_coop | 66be4328117c39026d85a3d6cc9b8635bde49077 | [
"MIT"
] | 54 | 2019-08-11T03:39:22.000Z | 2022-01-06T02:16:33.000Z | awscdk/app.py | jaliste/mi_coop | 66be4328117c39026d85a3d6cc9b8635bde49077 | [
"MIT"
] | 11 | 2020-02-12T01:17:38.000Z | 2021-05-10T06:22:22.000Z | awscdk/app.py | jaliste/mi_coop | 66be4328117c39026d85a3d6cc9b8635bde49077 | [
"MIT"
] | 20 | 2019-09-07T20:04:08.000Z | 2021-12-05T04:43:20.000Z | #!/usr/bin/env python3
import os
from aws_cdk import core
from awscdk.app_stack import ApplicationStack
# naming conventions, also used for ACM certs, DNS Records, resource naming
# Dynamically generated resource names created in CDK are used in GitLab CI
# such as cluster name, task definitions, etc.
environment_na... | 36.452381 | 79 | 0.766819 |
1204c9abc6db283ce3d3831f239b7fd8af24dbea | 4,563 | py | Python | test_phase_equilibrium.py | khuston/interfacial_transport | dfca4288e2876de81683fb46704c14393afdf422 | [
"MIT"
] | 1 | 2020-05-07T09:25:24.000Z | 2020-05-07T09:25:24.000Z | test_phase_equilibrium.py | khuston/interfacial_transport | dfca4288e2876de81683fb46704c14393afdf422 | [
"MIT"
] | null | null | null | test_phase_equilibrium.py | khuston/interfacial_transport | dfca4288e2876de81683fb46704c14393afdf422 | [
"MIT"
] | null | null | null | import numpy as np
import logging
from interfacial_transport import compute_one_phase_equilibrium, compute_mass_balance_one_phase
from interfacial_transport import compute_two_phase_equilibrium, compute_mass_balance_two_phase
from numpy.testing import assert_almost_equal
logger = logging.getLogger(__name__)
# Check o... | 31.909091 | 201 | 0.60881 |
1205020ea522f7b1fd7bb580cbb7689312826db5 | 3,914 | py | Python | testbed1/scratchnet_single_switch_test.py | Benny93/SDNMininetScripts | 16844ac1cecfdf27e25ca0f758029c81030b9ba1 | [
"MIT"
] | null | null | null | testbed1/scratchnet_single_switch_test.py | Benny93/SDNMininetScripts | 16844ac1cecfdf27e25ca0f758029c81030b9ba1 | [
"MIT"
] | null | null | null | testbed1/scratchnet_single_switch_test.py | Benny93/SDNMininetScripts | 16844ac1cecfdf27e25ca0f758029c81030b9ba1 | [
"MIT"
] | null | null | null | #!/usr/bin/python
"""
Build a simple network from scratch, using mininet primitives.
This is more complicated than using the higher-level classes,
but it exposes the configuration details and allows customization.
For most tasks, the higher-level API will be preferable.
"""
import csv
import sys
import time
from mini... | 29.877863 | 143 | 0.648441 |