repo_name stringlengths 7 111 | __id__ int64 16.6k 19,705B | blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 5 151 | content_id stringlengths 40 40 | detected_licenses list | license_type stringclasses 2
values | repo_url stringlengths 26 130 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 42 | visit_date timestamp[ns] | revision_date timestamp[ns] | committer_date timestamp[ns] | github_id int64 14.6k 687M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 12
values | gha_fork bool 2
classes | gha_event_created_at timestamp[ns] | gha_created_at timestamp[ns] | gha_updated_at timestamp[ns] | gha_pushed_at timestamp[ns] | gha_size int64 0 10.2M ⌀ | gha_stargazers_count int32 0 178k ⌀ | gha_forks_count int32 0 88.9k ⌀ | gha_open_issues_count int32 0 2.72k ⌀ | gha_language stringlengths 1 16 ⌀ | gha_archived bool 1
class | gha_disabled bool 1
class | content stringlengths 10 2.95M | src_encoding stringclasses 5
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 10 2.95M | extension stringclasses 19
values | num_repo_files int64 1 202k | filename stringlengths 4 112 | num_lang_files int64 1 202k | alphanum_fraction float64 0.26 0.89 | alpha_fraction float64 0.2 0.89 | hex_fraction float64 0 0.09 | num_lines int32 1 93.6k | avg_line_length float64 4.57 103 | max_line_length int64 7 931 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ShannonTully/data-structures-and-algorithms | 12,283,606,469,524 | 59dc1afd081d0911947f411ad958c2e61fd867cb | 1efd977af1638b7afa63c43a36e964ffe5db295a | /challenges/multi-bracket-validation/test_multi_bracket_validation.py | 778e33b27d0b67fd8da4b2bdd2d3655aa5cbdfe8 | [
"MIT"
] | permissive | https://github.com/ShannonTully/data-structures-and-algorithms | 847c8fa99b395efa254c364345302ccafaa6e802 | f43f24f9f60beb37a2717f387c1050c9fd1ece60 | refs/heads/master | 2021-09-14T06:51:48.510869 | 2018-05-09T03:24:26 | 2018-05-09T03:24:26 | 125,955,350 | 0 | 0 | MIT | false | 2018-05-07T21:25:50 | 2018-03-20T03:27:42 | 2018-05-07T21:08:20 | 2018-05-07T21:25:50 | 32,336 | 0 | 0 | 0 | Python | false | null | import multi_bracket_validation
import pytest
def test_basic():
assert multi_bracket_validation.multi_bracket_validation('()') is True
def test_fail():
assert multi_bracket_validation.multi_bracket_validation('(}') is False
def test_complex():
assert multi_bracket_validation.multi_bracket_validation('... | UTF-8 | Python | false | false | 352 | py | 47 | test_multi_bracket_validation.py | 46 | 0.730114 | 0.730114 | 0 | 14 | 24.142857 | 93 |
carden-code/python | 2,473,901,188,308 | 49500361d80edfa1c0a18a39cf3c780c3ac8f1b5 | b6fa182321756b891b84958e2b2c01e63b3f88b2 | /stepik/minute_of_genetics.py | 47ff69a096d269f31de471f1a7f40f7cf50f22e6 | [] | no_license | https://github.com/carden-code/python | 872da0dff5466070153cf945c428f1bc8309ea2b | 64e4df0d9893255ad362a904bb5d9677a383591c | refs/heads/master | 2023-07-05T05:14:16.479392 | 2021-08-22T21:27:36 | 2021-08-22T21:27:36 | 305,476,509 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # На вход программе подается строка генетического кода,
# состоящая из букв А (аденин), Г (гуанин), Ц (цитозин), Т (тимин).
# Напишите программу, которая подсчитывает сколько аденина, гуанина, цитозина и тимина
# входит в данную строку генетического кода.
#
# Формат входных данных
# На вход программе подается строка ге... | UTF-8 | Python | false | false | 1,284 | py | 295 | minute_of_genetics.py | 292 | 0.711443 | 0.711443 | 0 | 21 | 37.285714 | 112 |
dplepage/dfiance | 9,320,079,040,356 | f6e4e8f6f11945286c0848e752dafc19ed1cea44 | 8f0387b86bde8eb44e593ec16a96338843c83ca0 | /dfiance/datetypes.py | cc6a2a0076a3d8368d878e4afa95a9931a4d95cc | [] | no_license | https://github.com/dplepage/dfiance | 84a083b325288fb8730f4b20700d738db3792364 | 3c4c916eadb9fdef1c762491ca40d726f3575258 | refs/heads/master | 2016-08-11T10:14:51.126704 | 2013-08-15T18:08:25 | 2013-08-15T18:08:25 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import datetime
try:
from dateutil.parser import parse as parse_datetime
_have_dateutil = True
except ImportError:
_have_dateutil = False
from base import Invalid, Dictifier
class DateTime(Dictifier):
"""
Dictifier for datetimes.
The 'format' argument determines what format will be used for ... | UTF-8 | Python | false | false | 9,082 | py | 18 | datetypes.py | 17 | 0.605263 | 0.555384 | 0 | 297 | 29.582492 | 89 |
guillaume-havard/testdjango | 3,547,643,025,015 | 6e61c6075490a98a9ce3ba7c46e84ffd2ea70ff9 | ecdbbfbbff48a1199e124daf5c97a26826301c72 | /sitetest/blog/forms.py | 008239a485aa2cff4b6584316e89603539b9d74c | [
"MIT"
] | permissive | https://github.com/guillaume-havard/testdjango | 41aa84570259f511cd2773c9c691e88df1b0b691 | 66176f81660715dcb3ef4da083e4ea584762c27d | refs/heads/master | 2016-08-04T09:57:21.119528 | 2014-12-17T21:12:54 | 2014-12-17T21:12:54 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from django import forms
from blog.models import Article
class ContactForm(forms.Form):
sujet = forms.CharField(max_length=100)
message = forms.CharField(widget=forms.Textarea)
envoyeur = forms.EmailField(label="Votre adresse mail")
renvoi = forms.BooleanField(help_text="Cochez si vous souhaitez obten... | UTF-8 | Python | false | false | 3,159 | py | 26 | forms.py | 16 | 0.674984 | 0.673704 | 0 | 69 | 44.231884 | 122 |
b-liw/cryptopals | 171,798,735,030 | c3954b5fdfc304e00636365154dacc9cf960311a | 7955547961ddde1c5ea1a1a7390538d9c0d0effb | /set2/byte_at_a_time_ecb_decryption_harder.py | 78b1b67343fcced5cf97ab0fbcbacf6a8e09e61e | [] | no_license | https://github.com/b-liw/cryptopals | 83b444f30aa459b2ee5d0ec7081b6ca155234def | 14e19cfc63ff93a55bec498a1c0b2d4746d639f4 | refs/heads/master | 2020-03-27T04:03:52.427917 | 2018-09-09T16:48:20 | 2018-09-09T16:48:20 | 145,909,514 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import base64
from Crypto.Random import get_random_bytes
from set2.aes_ecb import encrypt_aes_128_ecb
from set2.pkcs7_pad import pkcs7_pad
oracle_global_key = get_random_bytes(16)
def brute_force_block_size(ciphertext):
for block_size in range(2, 64):
if len(ciphertext) % block_size == 0:
b... | UTF-8 | Python | false | false | 2,661 | py | 32 | byte_at_a_time_ecb_decryption_harder.py | 31 | 0.640737 | 0.612176 | 0 | 64 | 40.578125 | 195 |
Gunjankushwaha/hackthon2 | 16,492,674,455,208 | aa168b49737aa48d65c8ad896bf7389c6e22a583 | 96f000d16e29fd60199fea8585af515da7818b03 | /gunjan.py | 14ab45213550b08e4ecd2ded6c0ec1006ccaf74d | [] | no_license | https://github.com/Gunjankushwaha/hackthon2 | d80e7b9450398ed1abdca2fc9a49f1cf9c6bc46f | bf7fab859fc45260f7c7aa6f2378deb30d6e616d | refs/heads/main | 2023-09-04T22:32:23.670930 | 2021-11-21T15:08:27 | 2021-11-21T15:08:27 | 430,399,336 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | basic_salary=int(input("enter the basic_salary"))
salary=10000
if basic_salary<=10000:
# print("basic_salary+hrd+da")
hrd=int(input("enter the hrd"))
if hrd%10000==20:
salary%=salary-20
# print("basic_salary%20")
# num2=int(input ("enter the salary"))
# if... | UTF-8 | Python | false | false | 1,436 | py | 16 | gunjan.py | 15 | 0.489554 | 0.438022 | 0 | 72 | 18.708333 | 60 |
lenchevsky/organikos | 16,518,444,253,059 | ac8972fc2694be1fe320b84409dabfc4ec140ab5 | 4b15b39222699e85178c88232fb128a90a9e4c08 | /organikos_cms/core/views.py | 6b55e94c491b356596c54992dcd96ed65eff4b48 | [
"MIT"
] | permissive | https://github.com/lenchevsky/organikos | 118a051bc2c61a04c8eb675ba4167b131cde56b5 | bc54234152a0b6c5a0cc68f07119ce8bdcfd1024 | refs/heads/master | 2018-03-24T07:40:29.375011 | 2017-03-29T00:32:18 | 2017-03-29T00:32:18 | 38,467,574 | 0 | 0 | null | false | 2017-03-28T23:49:39 | 2015-07-03T02:28:41 | 2016-02-24T03:15:33 | 2017-03-28T23:49:39 | 1,202 | 0 | 0 | 5 | JavaScript | null | null | # @Project: Organikos Git Repositories (OGR)
# @Version: 0.6b
# @Author: Oleg Snegirev <ol.snegirev@gmail.com>
# @Functionality: Views
from django.shortcuts import render
from django.http import HttpResponse
from .models import OGRCore, OGRRepo
def allReposIndex(request):
# List all rep... | UTF-8 | Python | false | false | 1,737 | py | 15 | views.py | 7 | 0.694301 | 0.693149 | 0 | 44 | 38.477273 | 92 |
cliffc2/cardano-api-tests | 2,757,369,045,411 | 9312ead5d4a3e51be7ccca6d77e9ae2c1046d59d | 3f91ee669b928b0cbd82e93c644370066b60bbf7 | /ada-ticker.py | c93f355dd9add7d17adf73ce76c66fe9576d119d | [] | no_license | https://github.com/cliffc2/cardano-api-tests | 569ceee3f2a736d338473016e293c06aca05a5ca | 12120c5e592fc677d0953324988a9cb2acc336a1 | refs/heads/master | 2020-11-26T10:12:00.803371 | 2019-12-19T16:37:34 | 2019-12-19T16:37:34 | 229,039,496 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #this is a bitcoin cardano api test
#https://medium.com/@randerson112358/get-bitcoin-price-in-real-time-using-python-98b7393b6152
#Import the requests library
import requests
TICKER_API_URL = 'https://api.coinmarketcap.com/v1/ticker/'
def get_latest_crypto_price(crypto):
response = requests.get(TICKER_API_URL+c... | UTF-8 | Python | false | false | 529 | py | 6 | ada-ticker.py | 1 | 0.758034 | 0.724008 | 0 | 18 | 28.388889 | 93 |
MaximHirschmann/project-euler-solutions | 9,354,438,818,190 | 1c2cfef21d5016073cb5ee842cdac7b2bb120b8e | aeb8f555ccead132a59553977958954b28ac5350 | /Python/798.py | bae2740b3cef3d6cc38f67b93fe4c251faac95ea | [] | no_license | https://github.com/MaximHirschmann/project-euler-solutions | 25ed23e945894654c9c90b7d3dbb3c9c4d0f944e | ca5fff4498d6e884d122c97804a6cc37ca6c2feb | refs/heads/master | 2022-10-13T06:35:19.931133 | 2022-10-11T11:34:48 | 2022-10-11T11:34:48 | 157,978,850 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # NOT FINISHED
from collections import defaultdict
import functools
import itertools
from tabulate import tabulate
from time import time
from sympy import factorint
start = time()
n = 4
s = 6
def other(player):
return -player
def filter_deck(visible, deck):
smallest_of_suit = [n] * s
for num, suit in v... | UTF-8 | Python | false | false | 8,501 | py | 162 | 798.py | 160 | 0.473474 | 0.457828 | 0 | 303 | 27.059406 | 134 |
scadding/MyUniverse | 12,936,441,532,273 | d82449329850b834d598df68200cf1e5ed0f6969 | 6ffde6c22c923e773f791925fa7df6341ccc1402 | /Data.old/Tables/Generators/Sites - Mystic Places.py | bd76bb4cf67127ccc7db264ff2e5bcdc9b703c15 | [] | no_license | https://github.com/scadding/MyUniverse | e2163b57aefbdc5f2dd2533cf836db26fc19d95c | d2b196bae19592784bfe4315baf76a6954261391 | refs/heads/master | 2021-01-15T09:20:21.411904 | 2018-07-03T08:05:31 | 2018-07-03T08:05:31 | 35,813,452 | 0 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | from random import choice
from random import randint
class generator:
def version(self):
return 1.0
def start(self):
result = ''
groups = { 0: self.place() + ' of ' + self.thing(),
1: self.adj() + ' ' + self.place(),
2: self.adj() + ' ' + self.plac... | UTF-8 | Python | false | false | 1,506 | py | 826 | Sites - Mystic Places.py | 626 | 0.549801 | 0.545153 | 0 | 33 | 44.666667 | 389 |
l1berov/Switch | 11,407,433,170,866 | 41403d6ec7921068f0e0596cfa51c07af8811d3b | 5a97f04444c4a05c1e9170a4b751972c550847fa | /liberscripts/fff.py | d226a296f5b609662e49128956f2964325ae93ef | [] | no_license | https://github.com/l1berov/Switch | 1aa20b8229a35355d0ded96b81ae5a750ee8badb | 3d12c0e132cc06cfd83bf9b7d770c98d91e9787d | refs/heads/main | 2023-01-24T00:43:24.084726 | 2020-11-22T18:55:07 | 2020-11-22T18:55:07 | 315,108,179 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import colorama, os, time, vk_api, sys
from os import system
from colorama import Fore , Back , Style
os.system('clear')
print(Fore.YELLOW+'''
______ _ _
| ____| (_) | |
| |__ _ __ _ ___ _ __ __| |
| __| '__| |/ _ \ '_ \ / _` |
| | | | | | __/ | | | (_| |
|_| |_| |_|\... | UTF-8 | Python | false | false | 676 | py | 12 | fff.py | 11 | 0.426205 | 0.423193 | 0 | 27 | 23.62963 | 83 |
OpenDataCubePipelines/opendatacubepipeline.tesp | 10,101,763,100,227 | e83c22a9544c2c1a0f8ffd52dd368e85a3df3b21 | 6e86c22122a5a0a1bb0119844e4d1244d3b962ee | /bin/ard_pbs | dfbf3fd063891a40dde69b0cf9d5fd1aba7c3a50 | [] | no_license | https://github.com/OpenDataCubePipelines/opendatacubepipeline.tesp | 4464160cd48e6eacb9921a13653337dbf8d81410 | 0c20d54adc01f8c6cb370635ab7f4f9c0c4d5929 | refs/heads/master | 2021-04-29T20:11:39.089807 | 2021-04-19T02:53:46 | 2021-04-21T03:48:08 | 121,593,602 | 2 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
"""
PBS submission scripts.
"""
import os
import re
import json
import logging
from os.path import join as pjoin, dirname, exists
from pathlib import Path
import subprocess
import uuid
import click
import math
from wagl.tiling import scatter
PBS_RESOURCES = ("""#!/bin/bash
#PBS -P {project}
#... | UTF-8 | Python | false | false | 17,168 | 27 | ard_pbs | 21 | 0.60374 | 0.594478 | 0 | 425 | 39.395294 | 250 | |
Shakil-1501/Session6 | 10,557,029,628,480 | 3b8e785de4480e9a0c6eabd0c69d7702af9d3ba0 | 669677ac5cccf328426ef141cfdb8e99e8127452 | /session6.py | 8fa1404add9e5fbe962589bfba800e3d8d033e30 | [] | no_license | https://github.com/Shakil-1501/Session6 | f6679ff5c2530e2c2c3b6ff7ae765a2378a6a2f4 | 7886602e463b3cb6c01bff7f8d0cb1d1d7bebdf6 | refs/heads/master | 2022-12-06T10:34:29.550328 | 2020-08-24T15:37:13 | 2020-08-24T15:37:13 | 289,886,461 | 0 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | from typing import List
import time
import sys
import weakref
import random
from math import tan, pi
def poker(vals,suits):
'''
returns the list of 52 created cards in a deck
'''
k=[]
#l=[]
for i in vals:
for j in suits:
k.append((i+j))
return k
... | UTF-8 | Python | false | false | 6,352 | py | 2 | session6.py | 2 | 0.541877 | 0.517317 | 0 | 128 | 47.640625 | 243 |
FeelmyLife-droid/BOT_TG | 8,813,272,902,698 | c62e5483ff2c0adc9ec88052dcd0816039fe2b1e | 5548be9aa1bbc8640e35f3e4d43c32876aaea1f7 | /Keyboards/default/key_start.py | 82cd314be18d267c3c9f3796a162d30fec88984a | [] | no_license | https://github.com/FeelmyLife-droid/BOT_TG | 3dab8bfdde9df9493dcf3e3cb287c42161a5e08a | 8aec6c83886d0f0fbeb4af020919ae42bbed07ba | refs/heads/master | 2023-03-02T02:31:45.215366 | 2021-02-08T06:58:21 | 2021-02-08T06:58:21 | 335,944,264 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from aiogram.types import ReplyKeyboardMarkup, KeyboardButton
key_start = ReplyKeyboardMarkup(
keyboard=[
[
KeyboardButton(text='Новые адреса'),
KeyboardButton(text='Блокировка Фирм')
],
[
KeyboardButton(text='Данные по ИНН'),
Keyboa... | UTF-8 | Python | false | false | 449 | py | 44 | key_start.py | 43 | 0.5725 | 0.5725 | 0 | 14 | 26.571429 | 61 |
jonasguan/FSND-movie-project | 19,198,503,824,629 | bd970a4bda3eb13b19a519ef088558a6cebb7dfb | 9dcb1e586397536db8e0672056be30fe859c9440 | /entertainment_center.py | 22ae7ff24707af891c28c868504281bf6066c40e | [] | no_license | https://github.com/jonasguan/FSND-movie-project | 89e51e73052d9c425dc44603e6617a518943249f | a6d6aa222a30664a649d4700dbea61e9498a874c | refs/heads/master | 2021-01-12T15:14:52.878410 | 2016-10-23T23:51:24 | 2016-10-23T23:51:24 | 71,732,733 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import media
wreck_it_ralph = media.Movie( "Wreck-it Ralph",
"A disliked video game character gains popularity by wrecking things.",
"https://upload.wikimedia.org/wikipedia/en/1/15/Wreckitralphposter.jpeg",
"https://www.youtube.com/watch?v=OzMJkRwOxjs")
the_dark_knight = media.Movie( "The Dark Knight",
... | UTF-8 | Python | false | false | 1,433 | py | 3 | entertainment_center.py | 2 | 0.727146 | 0.69993 | 0 | 27 | 52.074074 | 135 |
sadxiaohu/icbckg | 2,078,764,183,232 | d7640043f97c642b73e9c032619446fff93b2f29 | 44e8497b108806d98a2d9bda293cc425ef3305fa | /tools/spider&extract/spider_from_web_demo/getting_nodes_fromweb.py | f7b930b2cfa1e5af5823aafe71b22731e97a5bbb | [] | no_license | https://github.com/sadxiaohu/icbckg | 138dacdb581b5bb81508250e437ed70a2918a3ac | d005aaf4d46e0d82a34a3a9318a4021d77a1b5da | refs/heads/master | 2020-04-05T11:03:39.040811 | 2018-11-16T11:03:25 | 2018-11-16T11:03:25 | 156,820,824 | 3 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #coding=utf-8
import requests
from bs4 import BeautifulSoup
import json
import codecs
def webNodesGet(word_url_dict):
nodes = []
id = 0
for word in word_url_dict:
url = 'http://www.icbc.com.cn'
url = url+word_url_dict[word]
wb_data = requests.get(url).content
soup = Beautiful... | UTF-8 | Python | false | false | 2,564 | py | 903 | getting_nodes_fromweb.py | 48 | 0.565452 | 0.548882 | 0 | 65 | 36.138462 | 75 |
bridgecrewio/checkov | 16,518,444,250,443 | 20cedb19c9ce77746822d00300ab8389373c2d63 | 45e376ae66b78b17788b1d3575b334b2cb1d0b1c | /tests/terraform/checks/data/example_external_dir/extra_checks/DummyExternalDataCheck.py | 62f6e4377b92be2f288e9121981992a3d142d5d0 | [
"Apache-2.0"
] | permissive | https://github.com/bridgecrewio/checkov | aeb8febed2ed90e61d5755f8f9d80b125362644d | e64cbd27ffb6f09c2c9f081b45b7a821a3aa1a4d | refs/heads/main | 2023-08-31T06:57:21.990147 | 2023-08-30T23:01:47 | 2023-08-30T23:01:47 | 224,386,599 | 5,929 | 1,056 | Apache-2.0 | false | 2023-09-14T20:10:23 | 2019-11-27T08:55:14 | 2023-09-14T18:58:30 | 2023-09-14T20:06:30 | 79,102 | 5,891 | 951 | 149 | Python | false | false | from checkov.terraform.checks.data.base_check import BaseDataCheck
from checkov.common.models.enums import CheckResult, CheckCategories
class DummyExternalDataCheck(BaseDataCheck):
def __init__(self):
name = "check for terraform data entity"
id = "CKV_AWS_999"
supported_resources = ['aws_i... | UTF-8 | Python | false | false | 594 | py | 4,040 | DummyExternalDataCheck.py | 1,890 | 0.713805 | 0.708754 | 0 | 17 | 33.941176 | 101 |
Taeheon-Lee/Programmers | 7,825,430,450,894 | fe80b9fbf0ac32c9ddb90c1eae2900cdb84bc470 | 9b96c37db1f61065094d42bc5c8ad6eb3925961b | /level1/phoneketmon.py | 6d1df017d3d2f70bcb0d8c7792409844d7434c9a | [] | no_license | https://github.com/Taeheon-Lee/Programmers | a97589498c866c498c1aa9192fdf8eec9f8e31f4 | c38b1c7dc4114c99191b77e5d19af432eaf6177e | refs/heads/master | 2023-07-09T21:10:25.064947 | 2021-08-30T05:17:49 | 2021-08-30T05:17:49 | 394,327,802 | 0 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | "폰켓몬"
# 문제 링크 "https://programmers.co.kr/learn/courses/30/lessons/1845"
def solution(nums):
select_num = len(nums) // 2 # 선택할 수 있는 포켓몬 수
types_num = len(set(nums)) # 포켓몬 종류 수
answer = types_num if types_num < select_num else select_n... | UTF-8 | Python | false | false | 552 | py | 58 | phoneketmon.py | 57 | 0.53125 | 0.514423 | 0 | 9 | 45.333333 | 140 |
PuHaoran/jdata | 10,187,662,430,808 | c91752a90a325707a56906543e44380553f1e432 | 9e908f9ae9aebbc6242706249b9ed65c87d1a6c8 | /src/data/concat_action_files.py | 8bb21811173e9f62e572bf9bce2074d6c344e2a1 | [
"BSD-3-Clause"
] | permissive | https://github.com/PuHaoran/jdata | fda13c92b65fc75e7795c64c6988ff91fd40e288 | bb8839d7f7a4a10f3ebcdd8f4d1ce2fa29562868 | refs/heads/master | 2022-04-19T02:41:57.855479 | 2020-03-25T01:49:10 | 2020-03-25T01:49:10 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | """
Concat JData Action Files And Save
"""
import pandas as pd
from .. import DATA_DIR
def main(input_dir=DATA_DIR.joinpath("raw"), output_dir=DATA_DIR.joinpath("interim")):
file_list = list(input_dir.glob("JData_Action*.csv"))
df_list = [pd.read_csv(p) for p in file_list]
actions = pd.concat(df_list)
... | UTF-8 | Python | false | false | 431 | py | 32 | concat_action_files.py | 21 | 0.645012 | 0.645012 | 0 | 18 | 22.944444 | 86 |
julianfloores/AprendiendoPython | 3,848,290,714,518 | 46f89d0e759d1a80bfea3aa9e941f251fd5bcd84 | 8c810aeb40c76e081982fde262e41133440f5b6f | /Tabla.py | 54dc04d672d7f36b3d6ea883d5665f9eaab54a9e | [] | no_license | https://github.com/julianfloores/AprendiendoPython | 7e0635c79ab8eb3d506ef1103c5705a6cd32710b | 4dad650cfde4ab29c8efce9adf7bfc022704f4fd | refs/heads/master | 2020-08-01T10:27:51.543923 | 2019-09-26T01:04:17 | 2019-09-26T01:04:17 | 210,966,863 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | n=input("Dame un numero del 1 al 9: ")
n:int(n)
for i in range (1,11):
salida="{} X {} = {}"
print(salida.format(n,i, i*n))
#Nombre: Francisco Julian Flores Hernandez
#Matricula: 1678204 | UTF-8 | Python | false | false | 202 | py | 9 | Tabla.py | 8 | 0.613861 | 0.554455 | 0 | 8 | 23.5 | 42 |
greseam/module5_python_practice_SMG | 3,556,232,944,931 | 20bdcb605ff642ee1d18206ac24f6ff550165eeb | b769a3992c2bf0b50f8f5860b5a41def32d4764e | /Module 5/mod5_hw1_task4_SMG.py | af51dff2df501bfefe8acb03726ee10f75075083 | [] | no_license | https://github.com/greseam/module5_python_practice_SMG | 540178db60af02bfeeb2e61d56e7c707b6fe0541 | f13e5422866a07e4a9ba06d0599ce6f0dfedbea3 | refs/heads/main | 2023-05-19T05:29:53.786620 | 2021-06-08T21:39:47 | 2021-06-08T21:39:47 | 375,149,924 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | ######
#every third word begin
#
# Sean Gregor
#
#desc: takes a string and only prints every thrid word
######
def SpaceBegone():
userString = input("Enter in a sentence at least 3 words long: ").split(" ")
userEndString = len(userString)
for i in range (2, userEndString, 3):#the range is set to... | UTF-8 | Python | false | false | 515 | py | 9 | mod5_hw1_task4_SMG.py | 7 | 0.629126 | 0.621359 | 0 | 17 | 28.411765 | 143 |
AhmedSeemal/Eclipsegirls | 12,575,664,277,718 | c339fce952354ca96be2236548e0c76bc8d28d48 | e4c97366f620cf4419b2cee370a6a594af90faf8 | /djangogirls/urls.py | 096b23849f3d2158ffa75499bf47b7be344f1a16 | [] | no_license | https://github.com/AhmedSeemal/Eclipsegirls | 476115293298b6d555af15f54d00161f89008f4b | 1ab03fffb0721804a5ca27e93716d5b775a76eef | refs/heads/master | 2021-05-11T10:46:38.051043 | 2018-01-19T10:46:54 | 2018-01-19T10:46:54 | 118,113,425 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | """djangogirls URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/1.11/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: url(r'^$', views.home, name='home')
Clas... | UTF-8 | Python | false | false | 1,264 | py | 12 | urls.py | 10 | 0.691456 | 0.684335 | 0 | 31 | 39.774194 | 86 |
devonproudfoot/vandura | 506,806,166,985 | 6d15a9f5a758500ad9a4ab7c20e4797a305a7c48 | edcce4c7febeba37a91a249a69828f085b84015f | /archivesspace_defaults.py | 1fa4fe54cfed4a30d699bc2bcea2fce26cf541a7 | [] | no_license | https://github.com/devonproudfoot/vandura | 40748819948d5ca526c4d7ed79e9473c0513e865 | d1182f8c442510bf7185567707f59d234bdcf42c | refs/heads/master | 2019-08-08T23:55:53.682532 | 2016-06-29T19:36:54 | 2016-06-29T19:36:54 | 37,989,794 | 0 | 0 | null | true | 2015-06-24T14:32:34 | 2015-06-24T14:32:34 | 2015-06-10T16:39:10 | 2015-06-10T16:39:27 | 28,671 | 0 | 0 | 0 | null | null | null | from vandura.shared.scripts.archivesspace_authenticate import authenticate
from vandura.config import aspace_credentials
import requests
import time
import json
import getpass
from pprint import pprint
def make_note_multipart(note_type, note_content):
note_multipart = {"type":note_type,
"jsonmodel_type":"note_m... | UTF-8 | Python | false | false | 3,864 | py | 1 | archivesspace_defaults.py | 1 | 0.695652 | 0.691253 | 0 | 102 | 36.892157 | 137 |
vvspearlvvs/CodingTest | 13,743,895,385,261 | 5b98146395ad29c6511925bbc47a3402f1251fa2 | 1e168ced1a4bdb53967021e082b98027aea9d38a | /1.알고리즘정리/정렬/삽입정렬.py | 6e0f94afc79ed7d33b51a468d14c6182e85e3d68 | [] | no_license | https://github.com/vvspearlvvs/CodingTest | 3ebf921308570ac11eb87e6660048ccfcaf90ce4 | fc61b71d955f73ef8710f792d008bc671614ef7a | refs/heads/main | 2023-07-13T15:57:11.312519 | 2021-08-25T02:15:28 | 2021-08-25T02:15:28 | 354,232,513 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #삽입정렬
arr = [7, 5, 9, 0, 3, 1, 6, 2, 4, 8]
for i in range(len(arr)):
for j in range(i,0,-1):
if arr[j]<arr[j-1]: #한칸씩 왼쪽으로 이동
arr[j],arr[j-1]=arr[j-1],arr[j]
else:
break
print(arr)
print("최종")
print(arr)
| UTF-8 | Python | false | false | 282 | py | 261 | 삽입정렬.py | 252 | 0.468254 | 0.40873 | 0 | 11 | 21.909091 | 43 |
JoannaPia/Just-ask- | 17,171,279,270,465 | e0011be665b61506fe425bd8d07c4308884569e7 | e6a8470a3bf4e9c770aa2810ca3353a5a106ea62 | /questions_data.py | faae7bc8d959e44e660ecc7052fe8d0f8f6c188d | [] | no_license | https://github.com/JoannaPia/Just-ask- | 6613ef3b1d344925104de15b8f99aa8ea50f71a5 | 20781a043a8d2a95526262bf32e028e6ecd0a752 | refs/heads/main | 2023-03-27T07:24:34.343894 | 2021-03-27T11:10:02 | 2021-03-27T11:10:02 | 352,051,376 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from psycopg2.extras import RealDictCursor, DictCursor
import database_common
@database_common.connection_handler
def get_all_questions(cursor: RealDictCursor) -> dict:
query = """
SELECT id, submission_time, view_number, vote_number, title
FROM question
ORDER BY submission_time... | UTF-8 | Python | false | false | 4,043 | py | 18 | questions_data.py | 6 | 0.593866 | 0.590403 | 0 | 149 | 26.14094 | 117 |
nasutionam/Things_In_Python | 14,164,802,150,015 | 94c4347e2a33fdeb878ad1361660dd349d1be685 | 5d37baf1f73fa7ac406afa079c31e5603b3771ad | /wa.py | a19428a269a281b377bc818c0dc5eac3c8ff5999 | [] | no_license | https://github.com/nasutionam/Things_In_Python | 4ee87bf6af55260892596194f2d27acc4bcb6406 | ae01ce6cb42b7cccd737e1186897c4705c5353de | refs/heads/master | 2022-11-11T19:12:47.016516 | 2020-06-18T17:46:54 | 2020-06-18T17:46:54 | 272,763,922 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import pywhatkit
pywhatkit.sendwhatmsg("+6283","test",00,36) | UTF-8 | Python | false | false | 61 | py | 7 | wa.py | 5 | 0.770492 | 0.639344 | 0 | 3 | 19.666667 | 43 |
arcadigonzalez-uoc/M2.951-Practica2 | 19,121,194,411,727 | db1934d57515d58af5c9b591d082cbc9ea85d3c9 | 546eda2426325e42afad5fddb3872b0eda4346c4 | /normalize/etl.py | 982e7c98875c5e8ec1bd99f56ff905ea9da7fe9c | [
"MIT"
] | permissive | https://github.com/arcadigonzalez-uoc/M2.951-Practica2 | 95ad5d1ba3154ba22dff858633d60e5756b56d59 | 6993251cb257c87377660ada0fad352ed05b9170 | refs/heads/master | 2020-03-29T02:20:45.558921 | 2019-08-20T14:23:08 | 2019-08-20T14:23:08 | 149,431,777 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from normalize.connection import cursor, client
from normalize.custom_sites import monster, indeed, reed
i = 0
for item in cursor:
if i % 100 == 0: print(i)
i += 1
if 'Spider' in item:
try:
if item['Spider'] == 'Monster':
dct = monster.Monster(item['Body'], item['Url'])... | UTF-8 | Python | false | false | 716 | py | 38 | etl.py | 24 | 0.50838 | 0.5 | 0 | 22 | 31.5 | 74 |
Angeliz/text-index | 10,428,180,596,433 | 7e66cc29871fd1f4e44c199f65581c772d108fee | 92687a5b70d771139ab79b91989b99d5ef666a45 | /corpus_to_bunch.py | 62dd12d7ad7fba0999ee7d439973f15b9da43e35 | [] | no_license | https://github.com/Angeliz/text-index | 8a1227a5779ca3edf10824c696c1d99494cb23b8 | cce1685669601ea40f0f723e6be638fb5c14485e | refs/heads/master | 2020-04-04T11:28:12.636946 | 2018-12-27T08:48:11 | 2018-12-27T08:48:11 | 155,892,018 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # encoding=utf-8
import pickle
from sklearn.datasets import base
from utils import read_file, listdir_nohidden
from config_local import seg_path, bunch_path, experiment_seg_path, experiment_bunch_path
def corpus_to_bunch(bunch_path, seg_path):
'''
:param bunch_path: Bunch存储路径
:param seg_path: 分词后语料库路径
... | UTF-8 | Python | false | false | 2,020 | py | 9 | corpus_to_bunch.py | 7 | 0.579615 | 0.579108 | 0 | 61 | 31.327869 | 89 |
mrfrozen97/frozenSpider-A-library-for-complete-machine-learning-algorithms-implementation- | 1,468,878,844,927 | c3518f49b65b154dea865bd85dd55a7e7c132018 | e8d00a3cec4ab65edc3bb7ba0902d162b1637f44 | /frozenSpider/spiderAlgorithmLR.py | db511f0638aa47e5c5697aabcbd2ad172c973fb0 | [
"MIT"
] | permissive | https://github.com/mrfrozen97/frozenSpider-A-library-for-complete-machine-learning-algorithms-implementation- | ce2513db523066794d339cacccae31e6cfb5ff41 | 1d1fee8c4553f7d0c4c5339cef624e02eeb40650 | refs/heads/main | 2023-07-02T06:51:44.189733 | 2021-08-02T11:24:57 | 2021-08-02T11:24:57 | 328,441,861 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | """
Implementation of ML introductory algorithms visulisation as ancillary
Author - mr frozen (or just frozen)
Github - github.com/mrfrozen97
Mail - mrfrozenpeak@gmail.com
This file has class that performs linear regression algorithm to the input data and can also visualise it .
The packages used here are num... | UTF-8 | Python | false | false | 15,373 | py | 20 | spiderAlgorithmLR.py | 18 | 0.578134 | 0.567332 | 0 | 488 | 29.30123 | 369 |
dyingg/rk311_infowise-pub- | 11,742,440,624,462 | 2587a225e6cabb5f66558b5823b873d1ffc9f560 | e3c6c3e035430c8523aefbdb6f295444951b395c | /src/main/scraper-module/AI_retrain.py | 733795f7297c901e9f4e6bf722ba0785469241c0 | [] | no_license | https://github.com/dyingg/rk311_infowise-pub- | acbae670f04727dfd35c40dbb40f241ac62b418b | 48a43c9a75dc7bc191abb602b2ba92e1cac6787a | refs/heads/master | 2023-07-05T14:34:07.503763 | 2021-08-26T08:29:14 | 2021-08-26T08:29:14 | 284,060,242 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import keras
from keras.models import Sequential
from keras.layers import Dense
import pandas as pd
from sklearn.model_selection import train_test_split
from sklearn.preprocessing import MinMaxScaler
import pickle, os
import numpy as np
from Naked.toolshed.shell import muterun_js
import sys
import requests, random
impo... | UTF-8 | Python | false | false | 1,959 | py | 114 | AI_retrain.py | 75 | 0.630934 | 0.623788 | 0 | 86 | 21.790698 | 89 |
linklab/aiclass | 11,373,073,405,860 | 9eff9999ccecd071b291daddd8d38503b3aaf958 | bfdc632d1921c5a2f0877e44f1394f67d4ef6d7a | /1731095004_SiHoRyu/HW2/functions.py | fffb6e342a6db23b90dd52e366efa5b694a7ce99 | [] | no_license | https://github.com/linklab/aiclass | 8f638d5ff0d76ba5cc631c93c2b55ed06e2456e5 | 4655fceee6ff301f47e954d56b1dbacb3ccae8ac | refs/heads/master | 2021-01-19T23:39:45.530750 | 2017-11-28T07:09:58 | 2017-11-28T07:09:58 | 83,782,465 | 4 | 14 | null | false | 2017-04-04T10:06:18 | 2017-03-03T09:38:59 | 2017-03-31T02:42:08 | 2017-04-04T09:17:47 | 16,161 | 2 | 13 | 2 | Jupyter Notebook | null | null | import numpy as np
import math
import matplotlib.pyplot as plt
from scipy.stats import truncnorm
from numba import jit, float64, uint8, void, cuda
def get_truncated_normal(shape, mean=0, sd=1, low=0, upp=10):
x = truncnorm(a=(low - mean) / sd, b=(upp - mean) / sd, loc=mean, scale=sd)
num_elements = 1
for ... | UTF-8 | Python | false | false | 3,357 | py | 116 | functions.py | 72 | 0.546619 | 0.491808 | 0 | 130 | 24.830769 | 80 |
shreyakapadia10/Bike-Rental-System | 18,528,488,929,752 | a06c4bf89ec78a02e221b11ac498ea544c5b59d3 | eda5d1c94b9c8e33ba01692a0d946fc0cade0190 | /BikeRentalSystem/BikeUsers/forms.py | 77c846497921e3ca60bfbc13606e1a5ccfcbe91f | [] | no_license | https://github.com/shreyakapadia10/Bike-Rental-System | 9fca03be0b2465f4552b75533ed6e8ccdc16fbda | 0356d5f66b4d50599633d57a7e2fc592567a5c9c | refs/heads/master | 2023-06-10T19:55:59.338879 | 2021-07-02T06:58:44 | 2021-07-02T06:58:44 | 373,848,485 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from django import forms
from .models import *
from django.contrib.auth.forms import UserCreationForm, UserChangeForm, AuthenticationForm, PasswordChangeForm
'''User Registration Form'''
class CustomerCreationForm(UserCreationForm):
class Meta:
model = Customer
fields = ['role','first_name', 'last_... | UTF-8 | Python | false | false | 2,442 | py | 52 | forms.py | 24 | 0.635545 | 0.635545 | 0 | 69 | 34.405797 | 131 |
StarStudio/StarSSO | 16,604,343,572,568 | 9077e15d13464861059ddcb8de6d57d1ebce2e56 | 7decdbc9b7bab2d0b4d571a8f658d9beebaa619d | /StarMember/lan_agent/submit.py | e88587e907ed10189adc2bc48a5cb2aa5b99d1f0 | [] | no_license | https://github.com/StarStudio/StarSSO | 3a299630e7fc5d6a2e7957adece8b6796c192cd2 | 4402e890eaf02e57b57ad04596490e0e8759a814 | refs/heads/master | 2020-04-03T22:26:57.801834 | 2018-12-30T05:14:55 | 2018-12-30T05:14:55 | 155,602,807 | 1 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | from StarMember.views import SignAPIView, param_error, api_succeed
from StarMember.aspect import post_data_type_checker, post_data_key_checker
from StarMember.utils import get_request_params
from flask import request, current_app
from .network import Network, InvalidNetworkIDError
class LANDeviceSubmit(SignAPIView):
... | UTF-8 | Python | false | false | 941 | py | 60 | submit.py | 48 | 0.650372 | 0.650372 | 0 | 27 | 33.851852 | 75 |
WoolinChoi/WoolinChoi.github.io | 3,882,650,455,075 | 9d8c879f5cb737da5096a0417feb2e9f05fff023 | a9590fdcf3ed0b3776e7d0edf5be9d13bbace255 | /_posts/jupyter/cWebConn/3_beautifulsoup_class/Ex01_element.py | 1029f9e5f0144e1cb99ce818e6c739b516febca9 | [
"MIT"
] | permissive | https://github.com/WoolinChoi/WoolinChoi.github.io | 59aa4ea685dd38f2588fcac662bb44688b4c7d59 | a0f9c8ecc63443acaae61d744eecec6c943d3a26 | refs/heads/master | 2022-10-24T16:57:06.830741 | 2020-04-15T10:21:54 | 2020-04-15T10:21:54 | 182,653,421 | 0 | 1 | NOASSERTION | false | 2022-10-06T10:44:00 | 2019-04-22T08:09:09 | 2020-04-15T10:21:57 | 2022-10-06T10:43:57 | 75,838 | 0 | 0 | 3 | Jupyter Notebook | false | false | """
bs4 라이브러리 : 웹에서 가져온 HTML코드를 파이썬에서 사용하기 편하게 해주는 라이브러리
[참고] 웹에서 가져온 HTML코드 가져오는 방법
- requests 모듈
- urllib 의 request 모듈
BeautifulSoup 모듈
- find()
- find_all()
[참고] 파서의 종류
- lxml : c로 만들어져 속도 빠름
- html5lib : 파이썬으로 만들어서 lxml보다... | UTF-8 | Python | false | false | 1,172 | py | 453 | Ex01_element.py | 89 | 0.541262 | 0.525485 | 0 | 40 | 19.6 | 57 |
ilyakonstantinov95/DjBlog | 14,285,061,231,926 | 93264ebec8e665233eb75c2148ac066085e57ed8 | e2890e6ef04220a09d150aa922376db39bb7853e | /emplist/migrations/0001_initial.py | 693d522e4c0b73b7c98ebae63dbb1ccbeeb932f7 | [] | no_license | https://github.com/ilyakonstantinov95/DjBlog | da243ecbb8c49f6a2a7c42a644791f68d413942b | 3ab34bed10d7a0f58d19dfee90e836daf7bf6ff7 | refs/heads/master | 2017-12-06T10:14:59.004524 | 2017-01-26T08:24:15 | 2017-01-26T08:24:15 | 80,039,147 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-01-23 10:13
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.Crea... | UTF-8 | Python | false | false | 4,460 | py | 17 | 0001_initial.py | 11 | 0.54108 | 0.534507 | 0 | 101 | 41.178218 | 150 |
Yun-Jongwon/TIL | 11,605,001,651,736 | b3f65b69e00c8a9f6f48a8c3daa3b050ff4a4345 | 1346ea1f255d3586442c8fc1afc0405794206e26 | /알고리즘/day15/picnic.py | a0675c0839036358fd7ba4ab78d78e7ec1e146dd | [] | no_license | https://github.com/Yun-Jongwon/TIL | 737b634b6e75723ac0043cda9c4f9acbc2a24686 | a3fc624ec340643cdbf98974bf6e6144eb06a42f | refs/heads/master | 2020-04-12T00:41:03.985080 | 2019-05-01T07:55:25 | 2019-05-01T07:55:25 | 162,208,477 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | def dfs(couple):
global m
global count
if sum(visited)==len(visited):
count+=1
return
for V in range(n):
if visited[V]==0:
visited[V]=1
v=V
break
for w in range(n):
if total_map[v][w]==1 and visited[w]==0:
visited[w]=1
... | UTF-8 | Python | false | false | 739 | py | 220 | picnic.py | 189 | 0.477673 | 0.453315 | 0 | 34 | 20.588235 | 48 |
RussellSk/grokking_algorithms | 13,185,549,612,182 | f57a5ab516edeb1b8dc6d04c6ffab4f028a08c66 | dfa7aaaefb5ccff7fcc016ac1740d52cfbe20caf | /Chapter4/Exercise4.1.py | 7749abba16a976aa7f3b90cd4796ee5356d9c9d6 | [] | no_license | https://github.com/RussellSk/grokking_algorithms | 97ecd387b614b8b7f413c24467b97e2c704a1af8 | 88a2b9c5f21d06d1cba3526c26b68b56dc40e399 | refs/heads/master | 2021-04-14T04:59:44.421724 | 2020-04-16T11:44:01 | 2020-04-16T11:44:01 | 249,208,424 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Exercises 4.1
# Write out the code for the earlier sum function
def sum(arr):
if not arr:
return 0
else:
return arr.pop() + sum(arr)
if __name__ == "__main__":
print(sum([2, 4, 6]))
| UTF-8 | Python | false | false | 216 | py | 9 | Exercise4.1.py | 9 | 0.541667 | 0.513889 | 0 | 13 | 15.615385 | 49 |
tuananh1007/Picasso | 12,850,542,195,905 | 2d4d18f85a1bc1ccc056b60d74d5fc204c2b33e7 | 2e11bf9a4499a962bacd89a742d9dc0ed7108747 | /tf_ops/mesh/unpooling/tf_mesh_unpool3d.py | 7b3864db5d3f04053014653a6149dabb63a57a43 | [] | no_license | https://github.com/tuananh1007/Picasso | df914332a02bf7940d28d5bae80be1601d59cb0c | 5009dd2312ad88635748788696ecc953d5e55116 | refs/heads/main | 2023-03-30T02:52:51.600705 | 2021-03-30T11:44:30 | 2021-03-30T11:44:30 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import tensorflow as tf
import sys, os
base_dir = os.path.dirname(os.path.abspath(__file__))
sys.path.append(base_dir)
unpool3d_module = tf.load_op_library(os.path.join(base_dir, 'tf_unpool3d_so.so'))
def mesh_interpolate(input, vt_replace, vt_map):
'''
During the decimation, we record the vertex cluster... | UTF-8 | Python | false | false | 1,109 | py | 28 | tf_mesh_unpool3d.py | 19 | 0.714157 | 0.706943 | 0 | 25 | 43.28 | 94 |
thiago-allue/portfolio | 11,089,605,580,602 | 697ff03e063255a0200112804cf3ef495e02b7bf | baf3996414315ffb60470c40c7ad797bf4e6897f | /17_boilerplates/prototypes-master/examples/src/elastic/src/old/guide.py | aaaf2aeadce59a30109e14b385347719f1ae7efd | [
"MIT"
] | permissive | https://github.com/thiago-allue/portfolio | 8fbbecca7ce232567aebe97c19944f444508b7f4 | 0acd8253dc7c5150fef9b2d46eead3db83ca42de | refs/heads/main | 2023-03-15T22:10:21.109707 | 2022-09-14T17:04:35 | 2022-09-14T17:04:35 | 207,919,073 | 0 | 0 | null | false | 2019-11-13T18:18:23 | 2019-09-11T22:40:46 | 2019-09-14T03:15:26 | 2019-11-13T18:18:21 | 180,926 | 0 | 0 | 0 | Python | false | false | import requests
r = requests.get(
"http://api.tvmaze.com/singlesearch/shows?q=big-bang-theory&embed=episodes"
)
import json
jd = json.loads(r.content)
print(jd["_embedded"]["episodes"][0])
import re
ldocs = []
for jo in jd["_embedded"]["episodes"][0:200]:
d = {}
d["id"] = jo["id"]
d["season"] = jo[... | UTF-8 | Python | false | false | 1,053 | py | 991 | guide.py | 679 | 0.616334 | 0.598291 | 0 | 47 | 21.404255 | 88 |
duncandc/mb2_python | 274,877,916,344 | 296a16ac9b6b20e78694fa5bdeab81caf614593b | 8e4da43aa0a8af1167482c9cbc1ac3ff4410e95e | /groupcat.py | 79b4d4cb8be334b007ce94c98765f85df446de7d | [] | no_license | https://github.com/duncandc/mb2_python | ef8d93548926368a8d230f2d89ed2232659daae3 | 812f9e7c41083e66c77b9ce5d453b25e286685ea | refs/heads/master | 2020-06-18T10:27:08.322401 | 2019-08-02T20:04:07 | 2019-08-02T20:04:07 | 196,270,866 | 2 | 2 | null | null | null | null | null | null | null | null | null | null | null | null | null | """
File I/O related to the MBII (sub-)halo catalogs
"""
from __future__ import print_function, division
from mb2_python.utils import packarray
from mb2_python.data import subdtype, groupdtype
import numpy as np
__all__=['gcPath', 'shPath']
__author__=['Duncan Campbell']
def gcPath(basePath, snapNum):
"""
... | UTF-8 | Python | false | false | 1,141 | py | 13 | groupcat.py | 10 | 0.646801 | 0.643295 | 0 | 49 | 22.306122 | 59 |
joaogomesufal/scrapping_articles | 11,965,778,902,839 | 90534afcdea2f681a4b95e128c9c47c8a6bf645b | 95ce37521e81309df5faaf18bd38117db9fa8278 | /main.py | f518cd1d4cc3f8a403560226b24c0f6b9e591d18 | [] | no_license | https://github.com/joaogomesufal/scrapping_articles | 58bf2d2f4ccc800627063c1ab9ac9413bcc638c3 | bf6715062127330c6a89a575b273dd88034dfda5 | refs/heads/master | 2020-04-24T07:33:53.263967 | 2019-02-26T12:16:15 | 2019-02-26T12:16:15 | 171,802,698 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from _classes.ScrappingArticle import ScrappingArticle
scrapping = ScrappingArticle('https://scholar.google.com.br/scholar', 'data mining', 2015, 2019, 2, 4)
print("Lista de URLs:")
url_list = scrapping.get_url_list()
print(url_list)
print("Lista de Arquivos:")
file_list = scrapping.get_file_list(url_list)
print(fi... | UTF-8 | Python | false | false | 397 | py | 5 | main.py | 3 | 0.753149 | 0.72796 | 0 | 14 | 27.357143 | 102 |
zhoutian0930ru/StockPredictionApplication | 15,728,170,260,006 | 410bf801ede64d99e54b2a8c14b72a6f67b72711 | 2e00911d07417094f9fd4015be7bf7c94ead0c7f | /venv1/lib/python3.6/site-packages/intriniorealtime/client.py | 282faa2e415e3872e02432dc466844d44501c05b | [] | no_license | https://github.com/zhoutian0930ru/StockPredictionApplication | 005c2b0519bf0b1c8fef26357f818726effe223d | d0c67f4c2cf4a033dee9d412dc30f10dab0a55be | refs/heads/master | 2020-05-04T03:37:38.274093 | 2019-07-28T14:15:24 | 2019-07-28T14:15:24 | 178,950,193 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import time
import base64
import requests
import threading
import websocket
import json
import logging
import queue
SELF_HEAL_TIME = 1
HEARTBEAT_TIME = 3
IEX = "iex"
QUODD = "quodd"
PROVIDERS = [IEX, QUODD]
MAX_QUEUE_SIZE = 10000
class IntrinioRealtimeClient:
def __init__(self, options):
if options is Non... | UTF-8 | Python | false | false | 10,537 | py | 22 | client.py | 14 | 0.530701 | 0.528424 | 0 | 318 | 32.13522 | 114 |
jiewu-stanford/leetcode | 14,250,701,521,205 | 6f8feacc8be74cd5382cebdf629582765db1b75d | e90a772733e73e45b4cdbb5f240ef3b4a9e71de1 | /443. String Compression.py | 7b3c99181fa20c5abbb7b9dbcb358cb76b759b88 | [] | no_license | https://github.com/jiewu-stanford/leetcode | 102829fcbcace17909e4de49c01c3d705b6e6e3a | cbd47f713d3307f900daf55c8f27301c70542fc4 | refs/heads/master | 2022-05-28T18:25:00.885047 | 2022-05-18T05:16:22 | 2022-05-18T05:16:22 | 214,486,622 | 2 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | '''
Title : 443. String Compression
Problem : https://leetcode.com/problems/string-compression/
'''
'''
two-pointer strategy, one read pointer (i) + one write pointer (j)
Reference: https://leetcode.com/problems/string-compression/discuss/92568/Python-Two-Pointers-O(n)-time-O(1)-space
'''
class Solution:
def ... | UTF-8 | Python | false | false | 692 | py | 371 | 443. String Compression.py | 370 | 0.544798 | 0.521676 | 0 | 20 | 33.65 | 114 |
knowledgetranslation/citation-dedupe | 8,203,387,555,402 | beaf6b2776fc050213f9f6ccb5aa7d9558d3c6c2 | 59623891733df19652c97f45b221ea5282f74c77 | /parser.py | efda106c18c0cd72826d3ec70b3d1d00242d666b | [] | no_license | https://github.com/knowledgetranslation/citation-dedupe | b9c4784c7909749b50907f3a51f3d12a5738bea1 | 7c102bda9bfe0b920830421557c85c887abdb74a | refs/heads/master | 2020-04-10T14:56:52.701882 | 2015-06-10T19:09:05 | 2015-06-10T19:09:05 | 32,325,476 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/python3.4
# -*- coding: utf-8 -*-
import os, sys
import mysql.connector
from lxml import etree, objectify
import logging
import json
# import lxml.usedoctest
# import xml.etree.cElementTree as ET
# FILES VARS
PATH = os.path.abspath('.') +'/'
XML_FILE = PATH + 'lite_sample4.xml' # 'CS Lit Search Comp - al... | UTF-8 | Python | false | false | 9,306 | py | 23 | parser.py | 9 | 0.564689 | 0.558994 | 0 | 245 | 36.987755 | 159 |
jdleo/Leetcode-Solutions | 609,885,367,083 | 8b087c2d7ca5930b71315c2e106d1ad80f00bfca | d62d21ea827d5d352515afb07623160ef48c0343 | /solutions/1748/main.py | b3eab5ea55f47155a96762d9843906f491ef0677 | [] | no_license | https://github.com/jdleo/Leetcode-Solutions | e53e77404e358bfa303bb0f873ed9cfe6cb575c0 | cf35874b4ca7fdcdc3e0e7beb0a255d8e98d2385 | refs/heads/main | 2023-03-04T12:26:04.093126 | 2021-02-20T05:40:55 | 2021-02-20T05:40:55 | 326,497,152 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | class Solution:
def sumOfUnique(self, nums: list[int]) -> int:
# array to hold count for each num 1 <= nums[i] <= 100
counts = [0] * 101
# fill counts
for num in nums: counts[num] += 1
# result (sum of uniques)
res = 0
# go thru counts
for i in range(l... | UTF-8 | Python | false | false | 451 | py | 136 | main.py | 135 | 0.518847 | 0.494457 | 0 | 13 | 33.769231 | 62 |
kaituoxu/PyTorch-ASR-AM | 13,125,420,090,203 | 670260cef3b9474a8776f4c99c460a65b58127ae | 475a7a542514167d27e22a51003ac83bb3fd933f | /kaldi-python/scripts/compute-global-cmvn-stats.py | f0362cc152a45353a5aeeb95370e147e503d9f0b | [
"Apache-2.0"
] | permissive | https://github.com/kaituoxu/PyTorch-ASR-AM | ee13061bbfd5e57aba4f60f6e0093855d022656c | 2ea24e9f49b89741979e517cbb6c517f79122c6b | refs/heads/master | 2021-03-27T14:04:45.185189 | 2017-11-30T08:27:36 | 2017-11-30T08:27:36 | 104,466,718 | 4 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
'''
Created on Aug 6, 2014
@author: chorows
'''
import os
import sys
import logging
import argparse
import numpy as np
import kaldi_io
if __name__ == '__main__':
print >>sys.stderr, os.path.basename(sys.argv[0]), " ".join(sys.argv[1:])
logging.basicConfig(level=logging.INFO)
... | UTF-8 | Python | false | false | 1,286 | py | 27 | compute-global-cmvn-stats.py | 21 | 0.588647 | 0.580093 | 0 | 48 | 25.791667 | 115 |
xelaxela13/stock | 11,390,253,314,229 | bcb441ad040031a8625079686930dbe0dfa0e118 | b3452d0dc1650ac75a551ce93e345d79df01c309 | /set_env_vars.py | 3feb571a066300989f21ddee3242adfa2b7fbd44 | [
"MIT"
] | permissive | https://github.com/xelaxela13/stock | 149bf10e93217d7efece76b3ac5ac2498c0ddca7 | ef7df50194be340e7faff915e9de4e3b1ade4eca | refs/heads/master | 2022-08-13T16:19:09.551752 | 2020-02-07T17:55:17 | 2020-02-07T17:55:17 | 169,874,047 | 1 | 0 | MIT | false | 2022-04-22T22:25:21 | 2019-02-09T14:17:25 | 2020-04-04T10:55:08 | 2022-04-22T22:25:18 | 10,479 | 1 | 0 | 1 | CSS | false | false | import random
import string
import os.path
def run():
config = {}
while True:
try:
config['SETTINGS'] = {
'SECRET_KEY': random_string(),
'ALLOWED_HOSTS': '*',
'DEBUG': True,
'IPSTACK_ACCESS_KEY': '0e3e331a2e84afc272c53c97982cc... | UTF-8 | Python | false | false | 1,736 | py | 70 | set_env_vars.py | 39 | 0.456221 | 0.437212 | 0 | 61 | 27.459016 | 111 |
oscar503sv/basicos_python | 42,949,694,097 | 9fa414230d69fde6199564caacce53427599d5c5 | 2cf50a2ff667e6fb686de55baf0e1329b386c777 | /01-ejercicios/triangulo.py | 4675a323640099e85b9fe5f6c11f6f9f09af15e8 | [] | no_license | https://github.com/oscar503sv/basicos_python | d41c5baaa425e18c47bb8693301e4020033a3c92 | dc1ebf240d099ef2de92e238fcd095ab29decc9e | refs/heads/master | 2022-06-30T02:26:59.080959 | 2020-05-14T05:51:56 | 2020-05-14T05:51:56 | 263,519,570 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #Dado de los valores ingresados por el usuario (base, altura) calcular y mostrar en pantalla el área de un triángulo.
print("**********CALCULO DE AREA DE UN TRIANGULO**********")
print("Ingresa la base del triángulo:")
base = float(input())
print ("Ingresa la altura del triángulo:")
altura = float(input())
area = (ba... | UTF-8 | Python | false | false | 359 | py | 60 | triangulo.py | 58 | 0.689266 | 0.686441 | 0 | 11 | 31.181818 | 117 |
JokerWDL/PyAnomaly | 3,023,657,007,622 | 681750dbf489a6a32e9ef1d6f64d493cc252b272 | f6c69a7f7f1bbae5fd5473dfaac5ef5fad840d58 | /lib/datatools/build/__init__.py | 2dcefc70c84d3f4061e0e716788bdf5dca8ba63f | [
"Apache-2.0"
] | permissive | https://github.com/JokerWDL/PyAnomaly | 8c5ca4ca705a1251c70ff1f36c908c8f6f75e7d8 | cf93437e5d7ae87fa916141cf4b5cc2e929b8199 | refs/heads/master | 2022-11-05T11:31:42.345422 | 2020-06-22T17:21:20 | 2020-06-22T17:21:20 | 274,295,638 | 1 | 0 | Apache-2.0 | true | 2020-06-23T03:04:32 | 2020-06-23T03:04:31 | 2020-06-23T03:04:30 | 2020-06-22T17:22:06 | 5,820 | 0 | 0 | 0 | null | false | false | from .. import dataclass # trigger the register in the dataclass package
| UTF-8 | Python | false | false | 74 | py | 80 | __init__.py | 67 | 0.783784 | 0.783784 | 0 | 1 | 72 | 72 |
nilswiersma/dfaplayground | 5,523,327,977,312 | a35e82a2a68b5261aef5bdc9e7bd7bc9cce200e5 | bd3aa6c6847f67597642ce8c9c7e8f9d1cd7580f | /classic.py | ea897e27b2bb9e5c22e774053afeff006439919c | [] | no_license | https://github.com/nilswiersma/dfaplayground | 4c223620f5457e7cd75d0ab21cd5107be7e80f9b | f87baf2c3c1a9144a6d9d756409614c41e642317 | refs/heads/master | 2022-07-19T18:48:18.560203 | 2020-05-13T14:44:28 | 2020-05-13T14:44:28 | 257,861,193 | 5 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from submod.aes.aes import AES, matrix2bytes
from submod.JeanGrey.phoenixAES import phoenixAES
import random, os
import faultmodels
intermediates = [
# 'input',
# 'ark0',
# 'sb1',
# 'sr1',
# 'mc1',
# 'ark1',
# 'sb2',
# 'sr2',
# 'mc2',
# 'ark2',
# 'sb3',
... | UTF-8 | Python | false | false | 12,095 | py | 8 | classic.py | 6 | 0.674742 | 0.5284 | 0 | 274 | 42.149635 | 125 |
yuhong270991/dp | 11,751,030,522,333 | 3efcd53825acf6d3c987f1cd60afca8d3f5da20f | e70b5dab798c183eeb3b861ad96ca654ddafacfc | /Python/KNN/knn.py | 2d197256ec4982988dd127decd5e3cdc2a9c5439 | [] | no_license | https://github.com/yuhong270991/dp | 3054ddaca1bdf466647e5945f698c68da68435a1 | b9107cb2aca129dec78f07d3e5da01764f020baf | refs/heads/master | 2022-04-08T19:37:43.616086 | 2020-03-05T04:59:50 | 2020-03-05T04:59:50 | 149,475,644 | 0 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | import math
import numpy as np
from operator import itemgetter
#normalizes a given dataset X (where X is a n-D array. The last column is not normalized)
def dataNorm(X):
num_col = X.shape[-1]
last_column = X[:, num_col-1]
X_norm = (X - X.min(axis = 0)) / (X.ptp(axis = 0))
X_norm[:, num_col-1] = last_co... | UTF-8 | Python | false | false | 3,939 | py | 187 | knn.py | 163 | 0.629601 | 0.615131 | 0 | 109 | 35.119266 | 110 |
ska-telescope/skampi | 17,952,963,334,781 | f9778352cfe683055d4a79ad22df02b8ecd4daa6 | 0de83c64ff184ce999910782886851606e0b0634 | /tests/resources/models/mvp_model/states.py | b4d389d18f48c16485d71e08a32496f3985a00a1 | [
"BSD-3-Clause"
] | permissive | https://github.com/ska-telescope/skampi | 1ce33740389a0a7489bd58383fab47d5557dc6fc | 3ee1e8df0d6612fda6822702561eae89dd7b9cdb | refs/heads/master | 2023-08-31T05:23:25.038516 | 2023-08-29T08:48:56 | 2023-08-29T08:48:56 | 176,765,819 | 1 | 2 | BSD-3-Clause | false | 2023-02-11T00:47:56 | 2019-03-20T15:40:38 | 2022-11-03T12:16:30 | 2023-02-11T00:47:56 | 12,961 | 5 | 1 | 6 | Python | false | false | """
module containing values for interpreting enumerated values (e.g. ObsState)
"""
import enum
class ObsState(enum.IntEnum):
"""Representation of int ObsState as an Enum."""
EMPTY = 0
RESOURCING = 1
IDLE = 2
CONFIGURING = 3
READY = 4
SCANNING = 5
ABORTING = 6
ABORTED = 7
RES... | UTF-8 | Python | false | false | 365 | py | 225 | states.py | 95 | 0.619178 | 0.586301 | 0 | 21 | 16.380952 | 75 |
zhangbc07/Project | 9,801,115,409,361 | 41cfa9b8ea2ca2de1a61b6361dfa8922cc68759f | c0859588f13a3ad9729bac5907dfd42b83a48a08 | /Mp_loan/Mp_loan.py | 0f579d81b1f23bd688379df8619f9311af71354c | [] | no_license | https://github.com/zhangbc07/Project | 25b9e7744fe2f0089bd92e1ab7252939bb47e1f7 | 68d7b411350e9fb04fd788fda38bbfa7865f1d24 | refs/heads/master | 2022-07-23T19:04:19.914211 | 2019-11-14T11:11:55 | 2019-11-14T11:11:55 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
# coding: utf-8
#数据下载:https://mirror.shileizcc.com/Other/LoanStats3a.csv
# In[1]:
import pandas as pd
import warnings
warnings.filterwarnings('ignore')
loans_2007=pd.read_csv('./LoanStats3a.csv',skiprows=1)
#清除不必要的列
half_count=len(loans_2007)/2
loans_2007=loans_2007.dropna(thresh=half_count,axis... | UTF-8 | Python | false | false | 6,518 | py | 8 | Mp_loan.py | 6 | 0.66672 | 0.624522 | 0 | 304 | 19.644737 | 152 |
Lackadaisica1/pre-college-dump | 3,762,391,394,374 | 6cc9757a4f47d73b6cea60188074f73dbe2ea7f8 | f72ff978288a570ea5d0263c830913c67f47b622 | /starting-out-with-python/chapter-11/2 - Car Class.py | f229f15a09b8bd02f33c9824a6e5f2fd134869f8 | [] | no_license | https://github.com/Lackadaisica1/pre-college-dump | 2feceb37ded8e092f77f275c6de6ddc03ceb54fc | d99fa2e11124bff6d2f313c03f4561298fd832d9 | refs/heads/master | 2020-05-07T10:01:50.633289 | 2019-06-12T01:35:14 | 2019-06-12T01:35:14 | 180,401,902 | 0 | 0 | null | false | 2019-04-09T16:00:37 | 2019-04-09T15:53:15 | 2019-04-09T15:57:24 | 2019-04-09T16:00:37 | 0 | 0 | 0 | 0 | Python | false | false | # A program which creates a Car class, and then creates a couple of functions for
# that object
class Car:
def __init__(self, year_model, make, speed):
self.__year_model = year_model
self.__make = make
self.__speed = 0
def set_make(self, make):
self.__make = self
def... | UTF-8 | Python | false | false | 886 | py | 70 | 2 - Car Class.py | 57 | 0.586907 | 0.575621 | 0 | 28 | 29.428571 | 81 |
JANMAY007/python_practice | 5,909,875,000,938 | 1449c49afebdbc8bb38b2a15c8aae62433ea073f | b6170903be7a09372f92bf8eb22bac8af200f1ef | /Python language practice/code jam solutions/codejam2.py | a7c8a13a0b5ab3258c7db84c1eb1892791c756ae | [] | no_license | https://github.com/JANMAY007/python_practice | 17b1fc3e4416ff2093ef25b759c41d062cf8195f | f087a1d4404a135dc6ae3bc79b7da52357f302d1 | refs/heads/master | 2022-04-24T12:10:05.074731 | 2020-04-28T12:15:47 | 2020-04-28T12:15:47 | 259,626,954 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import numpy as np
T = int(input())
for o in range(1,T+1):
N = int(input())
a = [[int(q) for q in input().split()] for p in range(0,N)]
result = []
x = np.trace(a)
def func(a):
count1=0
for k in range(N):
d = set(a[k])
if len(d) < N:
count1+=1
return(count1)
re... | UTF-8 | Python | false | false | 433 | py | 77 | codejam2.py | 76 | 0.505774 | 0.487298 | 0 | 16 | 25.1875 | 64 |
zopepy/leetcode | 6,708,738,925,650 | 2cbb7a251b0a13266f85ffa14a9564b700620c15 | 0d4ec25fb2819de88a801452f176500ccc269724 | /remove_k_digits.py | e01ac81dfa6f86a3bf70982113d95878c5953047 | [] | no_license | https://github.com/zopepy/leetcode | 7f4213764a6a079f58402892bd0ede0514e06fcf | 3bfee704adb1d94efc8e531b732cf06c4f8aef0f | refs/heads/master | 2022-01-09T16:13:09.399620 | 2019-05-29T20:00:11 | 2019-05-29T20:00:11 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | class Solution:
def removeKdigits(self, num, k):
"""
:type num: str
:type k: int
:rtype: str
"""
def remove_digit(num):
numlist = list(str(num))
if not numlist or not num:
return "0"
l = len(numlist)
found = False
... | UTF-8 | Python | false | false | 994 | py | 799 | remove_k_digits.py | 798 | 0.454728 | 0.445674 | 0 | 42 | 22.619048 | 54 |
Nimitz14/HR_temp_prediction | 2,310,692,421,184 | 6827b9b7d177e7dca03f7a6d874e6240a3262781 | 10817baf530eed2442040eed8d68a4b2b698d4a1 | /predict_temp.py | 833e734b525c301110dce00df74d67c53b2ea625 | [] | no_license | https://github.com/Nimitz14/HR_temp_prediction | 4e94e2384e5fda0e370172c2262019376623f7d9 | da400ff6dd7231b403813238691e4f14fa7ed93b | refs/heads/master | 2017-12-01T08:52:18.139494 | 2016-08-09T16:55:56 | 2016-08-09T16:55:56 | 63,858,731 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from __future__ import division
import numpy as np
import fileinput
'''
See main() at the bottom for top level overview (or read the README).
'''
def get_from_stdin():
'''
Assumes data is being input via stdin. Replaces month names with number. Then creates a by month date-format.
Clean data is then created in ... | UTF-8 | Python | false | false | 4,753 | py | 2 | predict_temp.py | 1 | 0.654955 | 0.632653 | 0 | 158 | 29.056962 | 117 |
shashank231/Programming-quiz | 18,253,611,034,339 | f6274f2a277a07f62c2a8ab8bbd794bc3501f339 | 4b0d68860631717f2e0321a8f02bf9ccc13b1432 | /namo/migrations/0003_subject_card_pic.py | 8990b2f10a0a56a8ce9541818b374aedb9e5e1bf | [] | no_license | https://github.com/shashank231/Programming-quiz | 0adc8f55f5badd136a92385fce90407a6e7898f1 | 630ab458d447cfee16b900a43efe83585cb306b5 | refs/heads/master | 2022-11-07T18:11:00.081969 | 2020-06-22T13:19:54 | 2020-06-22T13:19:54 | 274,135,865 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Generated by Django 3.0.6 on 2020-06-13 10:47
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('namo', '0002_subject_info'),
]
operations = [
migrations.AddField(
model_name='subject',
name='card_pic',
... | UTF-8 | Python | false | false | 401 | py | 21 | 0003_subject_card_pic.py | 15 | 0.581047 | 0.533666 | 0 | 18 | 21.277778 | 73 |
keepalive555/export | 7,559,142,484,736 | d8c6f6f615266c3c0ac1dccdb5e033443a85a3f6 | 2ce198c323a3a09ae79f565d6cacb49258a32b5d | /crawlers/util/cache.py | 1ba3e3bd9f4ff76c616a9f90588014441e19deb5 | [] | no_license | https://github.com/keepalive555/export | 030a6f61f358d7a29ce902f261a9769652182866 | 2d12198ae96c995b723488e5525c89fb32698d07 | refs/heads/master | 2017-12-17T06:31:09.896102 | 2017-11-13T15:00:06 | 2017-11-13T15:00:06 | 77,551,081 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # -*- coding: utf-8 -*-
import os
import shelve
from core.metaclass import Final
class CacheFile(object):
"""缓存文件对象。
Args:
cache_dir (str): 文件所在目录。
cache_file_name (str): 文件名称,不带扩展名。
Returns:
None
"""
def __init__(self, cache_dir, cache_file_name):
self._cache_d... | UTF-8 | Python | false | false | 3,082 | py | 17 | cache.py | 13 | 0.484263 | 0.482475 | 0 | 117 | 22.897436 | 70 |
ulti72/Credit_Saison | 12,146,167,530,086 | 285b1572fac9547f4550743d2c40aa9ab2c9a947 | 4d29c074c432495b7013eaab34a29a7ecf45ec00 | /flaskapi/__init__.py | 9a239a9000286e173550c67a9fee36b9ad4f7d81 | [] | no_license | https://github.com/ulti72/Credit_Saison | b4fe8c81fda12980a2508644da9d8d6745dac429 | 28e46318c1392306905d159af7504d395a541954 | refs/heads/master | 2023-05-12T17:07:45.342125 | 2021-05-29T16:22:51 | 2021-05-29T16:22:51 | 371,811,076 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from flask_sqlalchemy import SQLAlchemy
from flask import Flask
app = Flask(__name__)
app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///db.sqlite3'
db = SQLAlchemy(app)
from flaskapi import routes | UTF-8 | Python | false | false | 265 | py | 6 | __init__.py | 4 | 0.728302 | 0.724528 | 0 | 11 | 22.272727 | 62 |
adrianoff/ml_coursera | 4,492,535,802,548 | 5730af8344b25dfd4f89f405bfebb2dd66e160e0 | ddebe66cb75c86b580418947b823c2543aa318cb | /final_projects/sentiment_analysis/week6/parser.py | 8ff38c1c1d9a65029c6cb3e4c8bf75ae39ee9f82 | [] | no_license | https://github.com/adrianoff/ml_coursera | 5dae7ab8ceb98cf9a774f27c34597fe226dfacf5 | cfdea088cc3417c6852b6266c66a01e08ede7674 | refs/heads/master | 2021-01-19T11:18:21.392267 | 2018-09-17T15:20:18 | 2018-09-17T15:20:18 | 87,952,932 | 2 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | # -*- coding: utf-8 -*-
import requests
import bs4 as bs4
from tqdm import tqdm
import sys
reload(sys)
sys.setdefaultencoding('utf8')
def split_uppercase(string):
x = ''
k = 0
for c in string:
if k == 0:
x += c
elif c.isupper() and not string[k-1].isupper():
x += ... | UTF-8 | Python | false | false | 2,392 | py | 150 | parser.py | 39 | 0.61413 | 0.599498 | 0 | 80 | 28.9 | 112 |
sdck139/ck-leetcode | 19,292,993,114,820 | c3f4cad4846ecc5907166c8d61586d81549b918d | 88cb3315ecb89adc981c80a52cdedff8ac6189f3 | /537-ComplexNumberMultiplication.py | 90f4f8c9868c8d0d4f40a2f1b1648db681e7b59b | [] | no_license | https://github.com/sdck139/ck-leetcode | b61ef40be0948dfd694097160939fbee5f1936b3 | f43574dbb6a872e1c96d367f8948ed8c42b4fde1 | refs/heads/master | 2021-01-20T00:24:11.542989 | 2017-11-01T08:56:47 | 2017-11-01T08:56:47 | 89,125,640 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | class Solution(object):
def complexNumberMultiply(self, a, b):
"""
:type a: str
:type b: str
:rtype: str
"""
a1, a2 = self.strToInt(a)
b1, b2 = self.strToInt(b)
return str(a1*b1-a2*b2) + "+" + str(a1*b2 + a2*b1) + "i"
def strToInt(self, a):
... | UTF-8 | Python | false | false | 388 | py | 60 | 537-ComplexNumberMultiplication.py | 60 | 0.476804 | 0.438144 | 0 | 13 | 28.846154 | 64 |
tdnvl/PyCharm | 7,971,459,303,251 | 20d654ff9390e40df30f8a3f72e677533b15b11c | 6c77e86454e83f8676fb06740c82eff56f2672eb | /Lessons Ray/2018-01-01-make-bricks.py | 94e9aaa2c98738f2f3c86e2786f36326110e17fb | [] | no_license | https://github.com/tdnvl/PyCharm | 7898c473c53853ccc94c42773efcd1fb734c2019 | 2d7ce8d707170fddd641c93fb7d4378beaeffa70 | refs/heads/master | 2021-01-20T03:29:12.507434 | 2018-05-15T21:08:14 | 2018-05-15T21:08:14 | 89,544,974 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | def make_bricks(small, big, goal):
a = goal / 5
# if a >= 1 we can use at least one big brick
# if a < 1 we cannot use a big brick
b = goal % 5
# if b == 0 the goal is a multiple of 5
# if b != 0 we need to check if we have enough small bricks
# to reach the goal
c = int(a)
d = c*big... | UTF-8 | Python | false | false | 893 | py | 53 | 2018-01-01-make-bricks.py | 50 | 0.494961 | 0.478163 | 0 | 31 | 27.806452 | 63 |
upendar245/python | 8,701,603,785,179 | e41215278aac9d4c9e1602ff4584f24982669131 | 4540c5e07a4a439eb8f5f1998be0d4ee1c9291a7 | /recursion.py | f636695099787ca54bb7ad4a0b87605229fd612c | [
"Apache-2.0"
] | permissive | https://github.com/upendar245/python | 60dad510d2f64041340849617f87a5795e58cec7 | ed4d5488b44d385f2d0f75e8558a5b7fc4563d38 | refs/heads/master | 2021-01-25T09:21:05.951513 | 2020-11-08T07:35:21 | 2020-11-08T07:35:21 | 93,823,129 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | def sample(x):
if x == 0 or x == 1:
return 1
else:
return sample(x - 1) + sample(x - 2 )
print sample(6)
| UTF-8 | Python | false | false | 130 | py | 12 | recursion.py | 11 | 0.484615 | 0.438462 | 0 | 7 | 17.571429 | 44 |
zy20091082/trimesh | 9,912,784,522,715 | 1be0294e2b9ccc7cf4b2da535d6550adf92a6b27 | dfed9f12ec0893c5893789cdd91c8e2c3f254f9e | /trimesh/version.py | 6915b25eb17e34bd367b7d46af0244670c476608 | [
"MIT"
] | permissive | https://github.com/zy20091082/trimesh | 689e26fbd9232ebba1f56ad34fc22babafb3be03 | c0a421771ec77ffe4e29731ed3ba340e1c800644 | refs/heads/master | 2020-03-25T06:11:30.155310 | 2018-08-03T17:05:23 | 2018-08-03T17:05:23 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | __version__ = '2.31.50'
| UTF-8 | Python | false | false | 24 | py | 1 | version.py | 1 | 0.5 | 0.291667 | 0 | 1 | 23 | 23 |
Ludovic86/compta | 3,779,571,223,961 | b14bf27604384f4356b3ac4123b164de7b686720 | e93cd698baaa26c9fb10511c354ce40b5d4e854f | /migrations/versions/63634acbf78c_debits_table.py | df769b88afd2a715e88dbc6ab6cb6090b8cc147e | [] | no_license | https://github.com/Ludovic86/compta | e6776cddfc02aa141c52e93c28c70dd496df0830 | 0856a467e59803dae612b321fd54cea1cec5a153 | refs/heads/master | 2023-03-22T22:40:34.802475 | 2021-03-21T14:47:43 | 2021-03-21T14:47:43 | 347,668,966 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | """debits table
Revision ID: 63634acbf78c
Revises:
Create Date: 2021-03-14 16:01:18.145628
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '63634acbf78c'
down_revision = None
branch_labels = None
depends_on = None
def upgrade():
# ### commands auto gener... | UTF-8 | Python | false | false | 1,042 | py | 11 | 63634acbf78c_debits_table.py | 7 | 0.653551 | 0.620921 | 0 | 37 | 27.162162 | 79 |
xdxie/WordArt | 5,712,306,512,725 | 5ff2625c43f38e83811a5a6cf6249eec1b27a353 | 40b42ccf2b6959d6fce74509201781be96f04475 | /mmocr/models/textrecog/recognizer/__init__.py | 818df4996df8a4c1555ebda43e8bcce4f2acb697 | [
"Apache-2.0"
] | permissive | https://github.com/xdxie/WordArt | 2f1414d8e4edaa89333353d0b28e5096e1f87263 | 89bf8a218881b250d0ead7a0287526c69586c92a | refs/heads/main | 2023-05-23T02:04:22.185386 | 2023-03-06T11:51:43 | 2023-03-06T11:51:43 | 515,485,694 | 106 | 12 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Copyright (c) OpenMMLab. All rights reserved.
from .abinet import ABINet
from .base import BaseRecognizer
from .crnn import CRNNNet
from .encode_decode_recognizer import EncodeDecodeRecognizer
from .master import MASTER
from .nrtr import NRTR
from .robust_scanner import RobustScanner
from .sar import SARNet
from .sat... | UTF-8 | Python | false | false | 607 | py | 198 | __init__.py | 149 | 0.777595 | 0.777595 | 0 | 17 | 34.705882 | 86 |
LsoaresA/Projetos-Django | 13,348,758,356,448 | 9d7143da9986a10488a92b5825efe6f100eaf73e | 7155b83b4bffa5fb6efb1a2317692f263e444b6b | /LsoaresA/cadastro/urls.py | 5b8ca533681e0c7fe5f3a120d74afcf0648d9a3e | [] | no_license | https://github.com/LsoaresA/Projetos-Django | bf5c31507c0acc52f6e4a6e2d5b3a61eab51536a | 684dff09b31bdfce575563541f47ec588a29a5ad | refs/heads/master | 2021-09-23T12:05:54.457549 | 2018-09-22T13:22:46 | 2018-09-22T13:22:46 | 108,995,746 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from django.conf.urls import url, include
from django.contrib import admin
from cadastro.views import cadastro
urlpatterns = [
url(r'^cadastro/$', cadastro, name='cadastro'),
url(r'^admin/', admin.site.urls),
]
| UTF-8 | Python | false | false | 217 | py | 18 | urls.py | 12 | 0.728111 | 0.728111 | 0 | 8 | 26.125 | 48 |
DawnsonLi/Senorita | 11,605,001,676,018 | 168d4364e3aa212bd92af1a280fd76ead26b3a98 | 50ee3f186a424e5801f6cbdeb053f43865c87898 | /common/__init__.py | 95dbc1c1ad6b1d49d57f8c5f9e22ad367000c779 | [] | no_license | https://github.com/DawnsonLi/Senorita | 6303d9c626e3f98dbb811c0fd670a7493ba9637d | e09a0b28e21f51aade02072d1fbe3974278f803b | refs/heads/master | 2020-05-07T16:50:18.559534 | 2019-04-11T06:55:03 | 2019-04-11T06:55:03 | 180,701,275 | 10 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | __all__ = ['TSlist','visio'] | UTF-8 | Python | false | false | 28 | py | 12 | __init__.py | 9 | 0.5 | 0.5 | 0 | 1 | 28 | 28 |
miltonleal/MAC0110_Introduction_Computer_Science_IME_USP | 5,841,155,567,076 | 374cef3109836a48b79d790952a6721d5083e74d | 08e052c0c2ee4ad0cd4980fbc8a692c407118659 | /Ex. do Paca/Aula 14/P_14.6.py | c58608177356f9c8a407f14209866e2358c8c550 | [] | no_license | https://github.com/miltonleal/MAC0110_Introduction_Computer_Science_IME_USP | 6fad182f7fbb3e83403080800074bf57456cb0b5 | b47936ce66e715dba79dff44779a750d795192a0 | refs/heads/master | 2023-03-04T11:06:48.092980 | 2021-02-17T14:47:46 | 2021-02-17T14:47:46 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # P14.6) Função Harmonico(epsilon) que recebe número epsilon > 0 bem pequeno (exemplo: 0.00001) e calcula a soma de todos os termos maiores ou iguais a epsilon.
#Ou seja, calcular 1 + 1/2 + 1/3 + ... 1/k, tal que 1/i ≥ epsilon para i = 1, 2, ..., k e 1 / (k+1) < epsilon.
def harmonico(epsilon):
h, k = 0, 1 # ini... | UTF-8 | Python | false | false | 502 | py | 206 | P_14.6.py | 204 | 0.60161 | 0.541247 | 0 | 15 | 31.933333 | 160 |
sholehanshori/PWDK_Modul_2 | 11,012,296,155,443 | 051f396085d6a3d21770b50386a5f8219ba171f1 | 356eefcb3be20771c459d98df87dc66a9451ddff | /Day 27/27.py | b2ba4c3bed3bb6287317d9f5ee7424c28a884ec6 | [] | no_license | https://github.com/sholehanshori/PWDK_Modul_2 | 4df9bb5c01046c3c63d5609f9677d47d04c5ef30 | c12b8b8efa86d8158f18277ed0d43595adba4cc3 | refs/heads/master | 2020-11-25T07:43:59.174589 | 2019-12-18T05:00:20 | 2019-12-18T05:00:20 | 228,561,329 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # ------------------------ Jumat, 29 November 2019 -----------------------------------
import numpy as np
x = np.arange(1, 10).reshape(3, -1)
# print(x)
#----- Swaping -----
# print(x[:, [1,0,2]]) # Berdasarkan index grup
# print(x[:, [0,0,0]]) # Merubah semua kolom berdasarkan index pertama tiap row
#... | UTF-8 | Python | false | false | 1,628 | py | 60 | 27.py | 30 | 0.578624 | 0.554054 | 0 | 47 | 33.659574 | 117 |
renjieliu/leetcode | 11,476,152,656,146 | 50751a40383da59f291201b98ccb9246202cb209 | 8f48d12b88048e424ebb0d72ca6dfab5cf12ae0f | /1001_1499/1401.py | f711e0a92e454794764c80652551afcfedbcdf41 | [] | no_license | https://github.com/renjieliu/leetcode | e1caf13c18a8107ed9252588b339fb76bcb1b246 | 4668b64fcb9320b6c316d8608fc61911ce43b6c7 | refs/heads/master | 2023-03-18T18:16:06.187741 | 2023-03-14T20:31:59 | 2023-03-14T20:31:59 | 128,823,819 | 7 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | class Solution:
def checkOverlap(self, radius: int, x_center: int, y_center: int, x1: int, y1: int, x2: int, y2: int) -> bool:
def distance(A, B):
return ((A[0] - B[0]) ** 2 + (A[1] - B[1]) ** 2) ** 0.5
circle_up = [x_center, y_center + radius]
circle_down = [x_center, y_center ... | UTF-8 | Python | false | false | 1,999 | py | 1,627 | 1401.py | 1,620 | 0.526763 | 0.482241 | 0 | 35 | 56.142857 | 114 |
ncareol/ncharts | 1,374,389,547,787 | d8d36ef21f54c330ed953f1b8d6fa67651d3b7ad | d91c5b489a8d6b6a27455e743050b8b5cca42a3f | /datavis/settings/production.py | 2515c380165ace85d92da332af8a565bc1922aa0 | [
"BSD-2-Clause"
] | permissive | https://github.com/ncareol/ncharts | 3cdf1f8ea6c509810f9ac51ac1a9d8e37de006e8 | 07c97b6ae234ff74f89d0c6d1902764e2773a268 | refs/heads/develop | 2023-08-03T04:39:20.786171 | 2023-06-12T22:38:46 | 2023-06-12T22:38:46 | 56,725,944 | 1 | 0 | null | false | 2016-10-19T21:39:05 | 2016-04-20T22:48:54 | 2016-10-04T18:12:32 | 2016-10-19T21:38:34 | 15,042 | 0 | 0 | 15 | C++ | null | null | #
# datavis.settings.production
# Django production settings
from .default import *
DEBUG = False
os.environ.setdefault("VAR_DIR", "/var")
VAR_DIR = os.environ.get('VAR_DIR')
DEFAULT_LOG_DIR = LOG_DIR
LOG_DIR = os.path.join(VAR_DIR, 'log/django')
PROD_LOG_LEVEL = 'WARNING'
VAR_RUN_DIR = os.path.join(VAR_DIR, 'r... | UTF-8 | Python | false | false | 2,777 | py | 53 | production.py | 22 | 0.684192 | 0.672668 | 0 | 80 | 33.7125 | 125 |
libero/search | 15,771,119,931,223 | dbbd685dede20783c7f2f56feeb8a84cbda02e9d | e4e9a68742294d7cb5fc07ee6b5bb642f6c3fbd7 | /search/settings.py | 47534e2d8ba8b9a90498898d8d9da4bfdaa5b51d | [
"MIT"
] | permissive | https://github.com/libero/search | b411e869c0856fc61c1dd76c3c47ad057d258fbe | f13c7fe2aa5f3cd1e2f62234995788bed7147b91 | refs/heads/master | 2020-04-19T11:17:58.625630 | 2019-07-09T13:22:39 | 2019-07-09T13:22:39 | 168,163,286 | 0 | 3 | MIT | false | 2019-11-21T10:06:11 | 2019-01-29T13:55:30 | 2019-07-09T13:22:42 | 2019-11-21T05:25:03 | 68 | 0 | 3 | 0 | Python | false | false | """
Search application settings.
"""
from typing import List
GATEWAY_URL: str = ''
ELASTICSEARCH_HOSTS: List[str] = []
CONTENT_SERVICES_TO_INDEX: List[str] = []
| UTF-8 | Python | false | false | 164 | py | 40 | settings.py | 24 | 0.682927 | 0.682927 | 0 | 10 | 15.4 | 41 |
maxdrohde/snomed_map | 5,257,039,984,350 | 5ff16e9c16775042d21f7670a474e1acab72d6d9 | d908ab0266fe111c7fa8428fde454d09b873237d | /searcher.py | 65bc81b0a15cd24b2665f7cad70b067c7460dfd3 | [
"MIT"
] | permissive | https://github.com/maxdrohde/snomed_map | dbaa8aed6f61905446c55cb71564cd176b50d5ff | 2ecf24d02ea5e920b503549f6ee872ab748a6e28 | refs/heads/master | 2020-03-29T21:05:04.902966 | 2018-10-24T14:43:54 | 2018-10-24T14:43:54 | 150,348,724 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from helper_tools import sanatize, remove_stopwords, make_ngrams, make_skipgrams, flatten
from search import search, term_to_codes
import pandas as pd
def get_codes(matches):
# helper function to match SNOMED synonyms to their code and FSN
lis = []
for item in matches:
term = item[0]
score ... | UTF-8 | Python | false | false | 2,074 | py | 12 | searcher.py | 8 | 0.633558 | 0.629219 | 0 | 49 | 41.326531 | 110 |
Richard549/Parallel-Flame-Graph | 10,703,058,538,353 | 77727a73934deaad797ecaa3e89e8996b2daa25c | 444c823a911b70609539e489c164d7084718a325 | /src/PfgPlotting.py | 2245f00f78b2d849f161dbcdae7bf39367e64e83 | [
"MIT"
] | permissive | https://github.com/Richard549/Parallel-Flame-Graph | db06f1f1ea325af8f34dde8770f9f9aab7e65b34 | 03c75b2dc55cb673c46b20fc6e84a5a4292ce8ea | refs/heads/master | 2023-02-04T21:42:10.044056 | 2020-10-19T11:25:27 | 2020-10-19T11:25:27 | 291,295,777 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import numpy as np
import matplotlib
import matplotlib.pyplot as plt
import matplotlib.patches as patches
import matplotlib.colors as mcolors
from matplotlib import cm
from matplotlib.transforms import Bbox
import random
import logging
from enum import Enum, auto
from PfgUtil import sizeof_fmt
from PfgTree import Col... | UTF-8 | Python | false | false | 16,530 | py | 7 | PfgPlotting.py | 5 | 0.69395 | 0.677314 | 0 | 536 | 29.828358 | 151 |
ArchiDg/OSISoft-Summer-2018 | 2,482,491,141,151 | 06c54eb811a0f2aca37cf9e13950d7e4989441c9 | 15fa6a6e4c5fdfe0d8e64f61350321c51bf1f7cb | /mqtttopi/Receiver/mqtt_receiver.py | ff388ccb265db9bf64b97d124595a1483435678a | [] | no_license | https://github.com/ArchiDg/OSISoft-Summer-2018 | 41e204aa8575ab5312a753f51a44723b701b97f0 | 5dd4f5e2e9a931f4cda46da80c60b97e19db264b | refs/heads/master | 2020-03-19T12:19:29.969860 | 2018-06-07T20:43:58 | 2018-06-07T20:43:58 | 136,510,832 | 1 | 0 | null | false | 2018-06-07T20:43:59 | 2018-06-07T17:35:37 | 2018-06-07T20:30:43 | 2018-06-07T20:43:59 | 0 | 0 | 0 | 0 | Python | false | null | """
Create mqtt client and connect to mqtt server.
trigger on_connect after connecting to mqtt server.
Triggers on_message callback upon receiving message from mqtt server
"""
import paho.mqtt.client as mqtt
import datetime
import json
import logging
### MAKE CSV FILE
### HOW TO ADD CONFIG FILE
... | UTF-8 | Python | false | false | 9,536 | py | 12 | mqtt_receiver.py | 10 | 0.572462 | 0.570575 | 0 | 223 | 41.766816 | 114 |
RBuractaon/animated-octo-nemesis | 8,057,358,657,700 | 4f8f95561106157d65bba82efcb4c183ba299fea | d6e77317a8a7fadbb1ec4a153911dabf465b245d | /SSH Keystrokes/training/reverse_time.py | 747aa752c615ba97b79c7a30237fab24e0d45efe | [
"Apache-2.0"
] | permissive | https://github.com/RBuractaon/animated-octo-nemesis | 58891f510100def2f455ba531e0107246034b757 | 658f9fd87caffabbfadb246232df4746ba3474f5 | refs/heads/master | 2021-01-21T02:28:17.651069 | 2015-08-20T00:22:59 | 2015-08-20T00:22:59 | 26,342,626 | 0 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/python
# -*- coding: utf-8 -*-
# reverse_time.py
# Syntax: reverse_time.py <user sessions file> <output file>
# normalizes the time of each user session. T = Time - Max(Time) for each user.
# would like to see the ?,"e","x","i","t","\n" sequence
__author__ = 'rburactaon'
import sys
import datetim... | UTF-8 | Python | false | false | 2,551 | py | 20 | reverse_time.py | 12 | 0.543316 | 0.53038 | 0 | 75 | 33.026667 | 112 |
LarsKue/CompPhys20 | 12,051,678,240,932 | 076df8ae0110989ae0520a0777295853b0ad7c61 | 8afc4eb3ebd8b58232a79dcb8708291689270951 | /Uebung_2/Lars/main.py | b031d12ffa06d82638cb1508916cf982927cf6e1 | [] | no_license | https://github.com/LarsKue/CompPhys20 | fbc523fbf2d17ad8fc5d5d001fa4c2076df1bee5 | 1defa433dd4f5edaf4f181c0428206834f281139 | refs/heads/master | 2022-11-09T03:50:37.547404 | 2020-06-26T14:02:49 | 2020-06-26T14:02:49 | 257,870,307 | 0 | 0 | null | false | 2020-04-30T21:08:20 | 2020-04-22T10:39:26 | 2020-04-22T10:39:32 | 2020-04-30T21:08:19 | 7 | 0 | 0 | 0 | null | false | false | import sys
import os
import numpy as np
import math
from matplotlib import animation, pyplot as plt
from vec3 import Vec3
from particle import Particle
from n_particle_system import NParticleSystem
import random # for random particle generation
"""
Submission for Uebung 2 for Computational Physics 2020
Group Members:... | UTF-8 | Python | false | false | 10,111 | py | 31 | main.py | 26 | 0.649194 | 0.624271 | 0 | 278 | 35.370504 | 144 |
FyzHsn/data_structures_and_algorithms | 11,218,454,592,645 | 065ec36d918e2c00f3b6f6f161e41771727e69aa | 08aaeb9ac669eb6de341c3d74b58d1c5b588aace | /algorithms/sort_stack.py | 6654a86819d1dcbe42177b93324ec8a6f3924f91 | [] | no_license | https://github.com/FyzHsn/data_structures_and_algorithms | 7e2daae36cf8a3977a15253dea4e7435f632c020 | 64bbc7edd0b53cfebda8081badff7a481aea0c87 | refs/heads/master | 2022-10-29T22:50:19.334804 | 2020-06-18T02:13:31 | 2020-06-18T02:13:31 | 269,997,062 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from collections import deque
def insert_at_bottom(s, element):
if len(s) == 0 or element >= s[-1]:
s.append(element)
else:
top = s.pop()
insert_at_bottom(s, element)
s.append(top)
return
def sort_stack(s):
"""Time Complexity: O(n^2), Auxilary Space Complexity: O(n)""... | UTF-8 | Python | false | false | 717 | py | 28 | sort_stack.py | 26 | 0.483961 | 0.46583 | 0 | 33 | 20.121212 | 66 |
JoeSteven/v2rayPro-speed | 18,648,748,027,814 | cdaacf7ca6a13b2913f653592efa5235b6734296 | 0554bcc743485341a284992088005142d3324771 | /v2ray/v2ray_ping.py | 0b084c950d974ca6e5c33b74ecc08d89e4a409f3 | [] | no_license | https://github.com/JoeSteven/v2rayPro-speed | c082cb744a57b7e36f5f05ce46af50f909561bf6 | e009c6a7c55eefaa9533690b5082a5b20ec89737 | refs/heads/master | 2020-04-01T00:56:03.661802 | 2018-10-12T09:56:58 | 2018-10-12T09:56:58 | 152,719,282 | 2 | 3 | null | null | null | null | null | null | null | null | null | null | null | null | null | # -*- coding: utf-8 -*-
# !/usr/bin/env python3
# 登陆授权
# 获取服务器列表
# 转换json{
# "SVIP":"svip-kt.v2cloud.xyz",
# "HKT1":"hk-hkt.v2cloud.xyz"}
# 测速
# alias vpn='python3 /Users/joey/PycharmProjects/vpn/v2ray_ping.py [user_name] [password]'
import requests
import json
import os
import sys
json_file = os.getcwd() + "/vpn.jso... | UTF-8 | Python | false | false | 2,020 | py | 5 | v2ray_ping.py | 3 | 0.586578 | 0.566598 | 0 | 80 | 23.4 | 91 |
merdarking/Automation-Fruit-Catalog | 14,912,126,490,099 | d58dc388de36bf94468d08cdc1c898b6e271ce62 | 5d29e9243bab3ed40280f71ad4cc678d8e3f1439 | /run_edited.py | 6b4232f07b3bffa1115fa0c34320e4a7095deba0 | [] | no_license | https://github.com/merdarking/Automation-Fruit-Catalog | dde200c223cfdb7bcaca6392b2a01139e8dd917d | 15fd0111d32b763279360394c5905b2fbaaa7d25 | refs/heads/main | 2023-03-26T04:35:16.318359 | 2021-03-25T02:28:28 | 2021-03-25T02:28:28 | 351,283,311 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #! /usr/bin/python3
import os
import sys
import datetime # NEW
import reports # NEW
'''Get the description file name list in the directory'''
def get_file_list():
# Go into the path in the descriptions
path = os.path.join(os.path.dirname(sys.argv[0]),"supplier-data")
os.chdir(path)
# Get the file na... | UTF-8 | Python | false | false | 2,344 | py | 8 | run_edited.py | 7 | 0.609215 | 0.604096 | 0 | 76 | 29.855263 | 118 |
hanlingzhi/TF-TestBySpider | 3,805,341,071,414 | c9836e116321e248e4074824527cdf4de9aa8e97 | 7a3f3e8e2360459afd0b03c3da080a4c1ff50549 | /test_spider/util/enum.py | 2f9ea1068c5e7dc445fb9c239b0c44badf5dfd76 | [] | no_license | https://github.com/hanlingzhi/TF-TestBySpider | aae2f82174142c0a6b75d31c2e7f63c9f3ad88b1 | 09d3207ec2033ec7699d53d2a29293faa0ddb54b | refs/heads/master | 2020-12-28T02:38:22.477555 | 2020-03-15T13:25:53 | 2020-03-15T13:25:53 | 238,154,601 | 5 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | from enum import Enum, unique
@unique
class CrawlType(Enum):
scrapy = 'scrapy' # normal
selenium = 'selenium'
puppeeter = 'puppeeter'
| UTF-8 | Python | false | false | 150 | py | 19 | enum.py | 17 | 0.666667 | 0.666667 | 0 | 10 | 14 | 30 |
porcofly/face_segmentation | 6,012,954,234,298 | 6dd0b08f76f39d3f7f451dbb9f1ad4b4d4368580 | 966dfbf3db28e0815e86455a68816c59a75ae782 | /face_segment_contour.py | 103662ef240beff9cf9b5ec0b0e884fc794661d2 | [] | no_license | https://github.com/porcofly/face_segmentation | 6bdadcd670cee0c27d43dd82f2dceb319e6b72d8 | 05aad68a971a1218e525b7f4e99969b030eb88a6 | refs/heads/master | 2020-03-23T16:38:12.019116 | 2018-07-21T01:10:58 | 2018-07-21T01:13:50 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
import argparse
from scipy.spatial import ConvexHull
from skimage import draw
import numpy as np
import matplotlib.pyplot as plt
from PIL import Image
from util import read_list, load_landmarks, show_result, CRF
def main(args):
image_paths = read_list(args.image_list)
for path in image_p... | UTF-8 | Python | false | false | 2,207 | py | 4 | face_segment_contour.py | 3 | 0.557771 | 0.53874 | 0 | 55 | 39.036364 | 121 |
joelwking/aci-cyber-ingest | 12,970,801,243,412 | 7a344d031384f2d05fe3280d9f97a656ce680fd4 | eaeea2df868b2315e989005a0e64c1d7438416ad | /Service/atomic_counters.py | 8828bb975bbd1543c8c01246f4d35aa6205dd725 | [
"MIT"
] | permissive | https://github.com/joelwking/aci-cyber-ingest | 5e202bc88213a8c17c57c770425f60db1a42c839 | a5e8f42ef1f6aeb284741319bd68254cee25beed | refs/heads/master | 2020-12-24T05:41:32.291661 | 2016-08-24T14:32:43 | 2016-08-24T14:32:43 | 65,848,094 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
"""
Usage:
atomic_counters.py
use CTRL + c to exit!
This module monitors the atomic counters configured on an ACI fabric and generates a security incident
in Phantom (phantom.us) when the matches on a couter exceeds a threshold.
Copyright (c) 2016 World Wide Technol... | UTF-8 | Python | false | false | 7,927 | py | 5 | atomic_counters.py | 3 | 0.615618 | 0.608048 | 0 | 257 | 29.848249 | 150 |
Zacharias030/ProGraML | 2,980,707,316,705 | e98ff4bb1660e75bd57a6bc701e63a119f304253 | 458ea9901d3fe05c03327c8ec74441814578dbf9 | /deeplearning/ml4pl/models/lstm/graph_lstm_test.py | 2b38a266e5f0532bb430ad96e5164673c3377fb9 | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] | permissive | https://github.com/Zacharias030/ProGraML | 945e6c615afc6950ed7d7c747f3fa03182fab379 | cd99d2c5362acd0b24ee224492bb3e8c4d4736fb | refs/heads/master | 2020-11-28T06:42:53.521864 | 2020-07-22T09:29:42 | 2020-07-22T09:29:42 | 229,731,521 | 0 | 1 | NOASSERTION | true | 2020-08-10T12:45:04 | 2019-12-23T10:40:53 | 2020-07-22T09:30:00 | 2020-08-10T12:45:04 | 78,780 | 0 | 1 | 0 | Jupyter Notebook | false | false | # Copyright 2019 the ProGraML authors.
#
# Contact Chris Cummins <chrisc.101@gmail.com>.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# ... | UTF-8 | Python | false | false | 7,621 | py | 231 | graph_lstm_test.py | 174 | 0.676289 | 0.665923 | 0 | 238 | 31.021008 | 80 |
FihlaTV/backstage | 841,813,596,413 | c9850a7dba35c260919bf4e6db37454466371766 | 31a9016e3b0438989241246912a35e335f1cc448 | /backstage/users/models.py | 3af14c577b8046cf74aa6743b405a5233f2db7e0 | [] | no_license | https://github.com/FihlaTV/backstage | db74f1d2b58c3ae286fe42b87b5d19bbc34e008e | 6ab42aea4d89c634a5d2525693d94fd4315a9654 | refs/heads/master | 2020-04-03T02:45:44.934883 | 2013-09-20T11:01:39 | 2013-09-20T11:01:39 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # coding: UTF-8
'''
Created: 2013-06-20
Author: weixin
Email: weixindlut@gmail.com
Desc:
'''
from django.db import models
from backstage.backend.utilities import get_uuid
class UserInfo(models.Model):
"""
"""
userid = models.CharField(unique=True, blank=False, max_length=50,
... | UTF-8 | Python | false | false | 873 | py | 22 | models.py | 19 | 0.644903 | 0.618557 | 0 | 30 | 28.1 | 73 |
thepavangollapalli/nlp_jskp | 17,755,394,807,112 | b45254bc14a2a0b1a2ca73d194db1240a9e7a881 | e3a683431bcf28f29585f26ebe596b6855bdb143 | /question_generator/questions.py | 37e2140dfa8608eba59f1d0e8bd8a6c837267feb | [] | no_license | https://github.com/thepavangollapalli/nlp_jskp | 6be6766d19d9128d280b231d857443f12339e5bc | bb42d6dfd83794af4dfde9d45be5c4661a395178 | refs/heads/master | 2020-03-29T17:37:37.958431 | 2018-11-29T20:52:56 | 2018-11-29T20:52:56 | 150,173,967 | 0 | 0 | null | false | 2023-02-14T23:19:51 | 2018-09-24T22:01:39 | 2018-11-29T20:52:58 | 2018-11-29T20:52:57 | 50 | 0 | 0 | 0 | Python | false | false | #!/usr/bin/env python -W ignore::DeprecationWarning
#Mute depreciation warning from scikit-learn
def warn(*args, **kwargs):
pass
import warnings
warnings.warn = warn
import nltk
import sys
import copy
from nltk.tag.stanford import StanfordNERTagger, StanfordPOSTagger
stanford_ner_jar = '/home/coreNLP/stanford-ne... | UTF-8 | Python | false | false | 12,040 | py | 7 | questions.py | 4 | 0.460714 | 0.447924 | 0 | 344 | 33.997093 | 124 |
L-Ezray/zpp | 15,247,133,928,781 | 88316af5cd1fa839a4af2495a77f97c47be4ca52 | cb2a7ef60faa649f2c6b97958135d4e182bcdb5e | /18.py | 311ff0446999c175abaa6a4f334f93036f87ce7f | [] | no_license | https://github.com/L-Ezray/zpp | d857df7588bf57924d2f3685c9fbedc93e892df6 | ed715129907aa1f9c473cceb5df4c376f6699b3e | refs/heads/master | 2020-03-22T19:02:03.440262 | 2018-07-17T09:07:48 | 2018-07-17T09:07:48 | 140,499,358 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | 帐号 = '456456456'
密码 = '123123'
money = 100
a = input('请输入帐号:')
b = input('请输入密码:')
if (a==帐号)and(b==密码):
print('开始取钱')
c = input('请输入取钱金额:')
if float(c)<=100:
print('您本次取钱金额为%s,'%c,'您的余额为',100-float(c))
else:
print('没钱取毛线')
else:
print('非法账户')
| UTF-8 | Python | false | false | 383 | py | 32 | 18.py | 32 | 0.530249 | 0.44484 | 0 | 14 | 19 | 51 |
Z19900505/Python.learn | 8,495,445,321,753 | 0dbfddd2806c942a6541697d302b6ffd46dfd847 | c748b5a96187f4eb8ff13c67efdb862b3269d1af | /module/svgwrite/practice/Symbol.example.py | 3d89924dd89479aa87296e676d50fb9f3652d22a | [] | no_license | https://github.com/Z19900505/Python.learn | 29cc75148de867d179788e7d677f4171476a084f | 03144dcaa575d29ffde14a30169e291ac833b9f4 | refs/heads/master | 2020-12-02T08:40:31.192813 | 2016-12-02T08:45:19 | 2016-12-02T08:45:19 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python3
# coding: utf-8
import svgwrite
dwg = svgwrite.Drawing("Symbol.example.svg", (900, 900), debug=True)
symbol = dwg.symbol(id='symbol')
dwg.defs.add(symbol)
symbol.viewbox(0, 0, 10, 10)
symbol.add(dwg.circle((5,5), r=5))
dwg.add(dwg.use(symbol, insert=(100, 100), size=(10, 10), fill='green'))
dw... | UTF-8 | Python | false | false | 763 | py | 364 | Symbol.example.py | 98 | 0.656619 | 0.542595 | 0 | 20 | 37.2 | 73 |
skandix/Dramhack | 12,008,728,598,892 | 2b1409eb7983c8ea0b477752ba4a0c2c1d1f5fb8 | 51d0fe411f4bf8a9bcc9b0bf4ed2a74cb31dfaa8 | /modules/dhsc/fetch.py | c22a94417b2550fefb19f0e7e886ef17f64cb882 | [] | no_license | https://github.com/skandix/Dramhack | 69a1298415a2d3c01fb705d06a383c963dc8fae4 | 8ed970a49f5d00468d12d3c2890da8e021234415 | refs/heads/master | 2017-12-01T21:45:30.297777 | 2017-06-16T23:23:34 | 2017-06-16T23:23:34 | 61,155,771 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import requests
import datetime
import sys
#for handeling shit scandinavian characters
reload(sys)
sys.setdefaultencoding('utf-8')
def fetchAPIData(endpoint, api="https://api.crew.dreamhack.se/1"):
compiledURL = api+endpoint
return requests.get(compiledURL, verify=False).json()
class schedule_fetcher(object... | UTF-8 | Python | false | false | 2,618 | py | 9 | fetch.py | 3 | 0.559587 | 0.557678 | 0 | 87 | 29.091954 | 233 |
storm2513/Task-manager | 9,174,050,154,555 | 12e458b23b5ed0418e0b06e0c295f098d0a0b0b9 | 638ef8d1570533e65f4520447862f2de2bf74694 | /task-manager/library/tests/storage_test.py | e8a0855ca3c7bbdae44ecfc3e02893a4f06bc21d | [] | no_license | https://github.com/storm2513/Task-manager | a325b5beb82407a613da1abbfe0f23ccd60d3152 | 8ea1f92fe56b9b331ade1163521e99b3fb524863 | refs/heads/master | 2020-03-26T00:15:21.365312 | 2018-08-10T16:58:10 | 2018-08-10T16:58:10 | 144,312,524 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import unittest
import datetime
from tmlib.storage.storage_models import (
Task,
UsersReadTasks,
UsersWriteTasks,
Category,
TaskPlan,
Notification,
DatabaseConnector)
from tmlib.storage.category_storage import CategoryStorage
from tmlib.storage.notification_storage import NotificationStorage... | UTF-8 | Python | false | false | 13,867 | py | 56 | storage_test.py | 42 | 0.663085 | 0.658037 | 0 | 319 | 42.470219 | 99 |
Buhua-Liu/Adversarial-examples--Attack-and-Defense | 8,229,157,351,789 | 5ce8a6e60dccc11a7ad5042a3da379795ba2c596 | 4cc7a958e2a7d79001fcb0be176efd52084756a8 | /main.py | 9d9c82e9324bd9a964210320c5f76ac93af1a208 | [
"MIT"
] | permissive | https://github.com/Buhua-Liu/Adversarial-examples--Attack-and-Defense | a8d387554d4a5429251e708c2c2f2865e6b80302 | 8b4ad8e0deea1e60d702806ea7b7a38cfb706e0d | refs/heads/master | 2020-08-19T20:10:52.521051 | 2020-01-08T03:14:20 | 2020-01-08T03:14:20 | 215,950,017 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import tensorflow as tf
import numpy as np
import os
import time
from dknn import DkNNModel, plot_reliability_diagram
from attack.fgsm import FGSM
def main():
# Loading and pre-processing data
(train_images, train_labels), (test_images, test_labels) = tf.keras.datasets.mnist.load_data()
train_images = tra... | UTF-8 | Python | false | false | 3,879 | py | 3 | main.py | 2 | 0.559423 | 0.545501 | 0 | 102 | 37.029412 | 106 |
mrpal39/portflioWebapp | 19,447,611,931,096 | 5518e1772d6a46ee72e76d5cc5adf0af7bbd3139 | 3e05276c6562bbca2c46daec0bf30d765bb6c8d5 | /accounts/decorators.py | 3daa600bfca8acdda42de048d49f9bb8ede334e7 | [] | no_license | https://github.com/mrpal39/portflioWebapp | 762571a74979ddcd4abf90c8ab8684dcd2afa6fa | 898023c0b528557d4ab5ece6c48707f5e61ea296 | refs/heads/master | 2023-08-07T06:17:28.081727 | 2021-10-05T16:30:27 | 2021-10-05T16:30:27 | 414,057,726 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from django.contrib.auth import REDIRECT_FIELD_NAME
from django.contrib.auth.decorators import user_passes_test
def jobseeker_required(funcation=None,redirect_field_name=REDIRECT_FIELD_NAME,login_url='login'):
actual_decorator= user_passes_test(
lambda u:u.is_active and u.jobseeker,
login_url... | UTF-8 | Python | false | false | 832 | py | 62 | decorators.py | 43 | 0.707933 | 0.707933 | 0 | 31 | 25.741935 | 97 |
ericsonj/mse_pds_tp_final | 13,443,247,654,240 | 6897c943d5284659257ca1f6acf48289607886dd | fe72e3476a0ced87470194efffbd72a94f71e861 | /predictor.py | 370fe7ea0411324b93d9bff81fc8b5b5928af1bc | [] | no_license | https://github.com/ericsonj/mse_pds_tp_final | 23ddf736f6c233a2c0aaabab6606ff83dc1e3125 | 02c388fa15bd7a5a3ac76cda5cd47de2fab1c31d | refs/heads/master | 2020-07-04T22:53:16.182098 | 2019-08-16T22:09:48 | 2019-08-16T22:09:48 | 202,448,431 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Wed Aug 14 18:25:51 2019
@author: ericson
"""
import numpy as np
import matplotlib.pyplot as plt
# Señal del problema
N = 100
M = 4
fs = 1000
w0 = 3
phi0 = np.pi/4
amp_noise = 0.02
ts = 1/fs # tiempo de muestreo
tt = np.linspace(0... | UTF-8 | Python | false | false | 772 | py | 3 | predictor.py | 1 | 0.596628 | 0.54345 | 0 | 39 | 18.74359 | 76 |
rochapaulo/Wuohoy | 3,075,196,596,050 | 2865cc82bf49a2732488082452c63652d44fe41a | c120b8972f14fdfa77def0094ff42f170e54200c | /frank/command/vpncommand.py | 2f135c97bb440e83fd426f661fc48433f5af0d5a | [] | no_license | https://github.com/rochapaulo/Wuohoy | 34fc792642d8a093cea111890a14a1c6c9d5ad78 | 4cb8083832bf60cf64069f4c246b0f3b493dfc81 | refs/heads/master | 2015-09-24T12:36:42.763837 | 2015-07-06T14:24:36 | 2015-07-06T14:24:36 | 37,598,827 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
import subprocess
import sys
# [1] vpnPassword
# [2] vpnUser
# [3] vpnAuthGroup
# [4] vpnHost
command = 'sudo echo ' + sys.argv[1] + ' | openconnect --user=' + sys.argv[2] + ' --authgroup=' + sys.argv[3] + ' --passwd-on-stdin --no-cert-check --no-xmlpost ' + sys.argv[4]
print "executing: " + co... | UTF-8 | Python | false | false | 364 | py | 16 | vpncommand.py | 10 | 0.648352 | 0.626374 | 0 | 14 | 25 | 176 |
elomario/tarantinobwah | 7,559,142,478,313 | 0bb288cfb1d7b7413ee78f92d799769b0dc78879 | 191a0b27a670ecd7f8473d25e5a2e7aabea19af2 | /projet_web/events/views.py | bda623bf2fb639462dd0dabb6a491968032004f4 | [] | no_license | https://github.com/elomario/tarantinobwah | a83697b23ce966baeb963bf82fec0165ccbe6513 | 327d1ef5d0d24c8494221d60548aba263cb0aa79 | refs/heads/master | 2021-01-10T19:50:36.067471 | 2014-06-01T09:42:38 | 2014-06-01T09:42:38 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from django.shortcuts import render, get_object_or_404
from django.http import HttpResponse
from django.template import RequestContext, loader
from events.models import Event, Member
from django.contrib.auth.models import User
from ecomments.models import Ecomment
def index(request):
latest_events_list = E... | UTF-8 | Python | false | false | 2,020 | py | 27 | views.py | 23 | 0.700495 | 0.692574 | 0 | 53 | 36.150943 | 120 |
Akhtar-Zaman/Odoo-Practice | 18,519,899,018,229 | 3d2b51064216ee4f61c25ee9dffb4b600cee3fd3 | 3ab59a6e4589ad7f2c5d40199cf562c0b90a15c0 | /hospital_management/models/views/Doctors.py | da4f32f0743d6c5c62052e724972539806d48850 | [] | no_license | https://github.com/Akhtar-Zaman/Odoo-Practice | 517f294073f4975dc9186780e5cd72560e670aa1 | d99142ab84cf96829373798685116aadd81f1e5d | refs/heads/main | 2023-05-10T07:22:49.140858 | 2021-06-08T13:12:48 | 2021-06-08T13:12:48 | 370,238,931 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from odoo import models, fields, api, _
from datetime import date
class HospitalDoctors(models.Model):
_name = 'hospital.doctors'
_rec_name = 'doc_name'
doc_image = fields.Binary('Image', attachment=True)
doc_name = fields.Char('Name')
doc_mobile = fields.Integer('Phone Number')
doc_email ... | UTF-8 | Python | false | false | 1,291 | py | 47 | Doctors.py | 26 | 0.55151 | 0.549961 | 0 | 44 | 27.909091 | 96 |
schmidtbri/task-queue-ml-model-deployment | 17,188,459,124,830 | 0a5c09eb99016c46c93e4840f990417da36e521e | f01953b9dcb236084a1ec792f18302f166ca64a5 | /scripts/concurrent_test.py | 361109553b7215406f8d12179668c0c555ea4423 | [
"MIT"
] | permissive | https://github.com/schmidtbri/task-queue-ml-model-deployment | a0eed5ac7ad6c07a36d81622df062f75ecb6c4c1 | f6d7a944811bba467515c9118a0ace4058dfbb0a | refs/heads/master | 2021-06-22T02:40:37.030068 | 2021-04-21T13:00:26 | 2021-04-21T13:00:26 | 209,553,163 | 9 | 2 | MIT | false | 2021-04-21T13:00:27 | 2019-09-19T12:51:42 | 2020-12-14T02:14:24 | 2021-04-21T13:00:26 | 113 | 5 | 1 | 1 | Python | false | false | """A script to test the model task queue with a concurrent requests"""
import time
from concurrent.futures import ThreadPoolExecutor as Executor
from model_task_queue.celery import app
def request_task(data):
task = app.tasks["model_task_queue.ml_model_task.iris_model"]
result = task.delay(data=data)
# ... | UTF-8 | Python | false | false | 1,146 | py | 14 | concurrent_test.py | 9 | 0.623909 | 0.593368 | 0 | 34 | 32.705882 | 91 |
ZZRebas/python-100- | 1,597,727,841,928 | 9bae1cd92b50b8642e7ce03b4e2b9d0b9a21c642 | b98c6faf3eb68aacb6916af456367d69bda2385b | /question bank/Day_4.py | f6459cd9bd769ca444a4d8d3a03849bf12dc3695 | [] | no_license | https://github.com/ZZRebas/python-100- | 1a7e68a31312bb86724b44f30b30376030cc87f1 | 44c225f000f38cf0772336e7208d78151e39133d | refs/heads/main | 2023-06-19T16:21:37.053273 | 2021-07-01T07:08:18 | 2021-07-01T07:08:18 | 377,105,456 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | '''
#Question 14
#> **_Write a program that accepts a sentence and calculate the number of upper case letters and lower case letters._**
# > **_Suppose the following input is supplied to the program:_**
# Hello world!
# > **_Then, the output should be:_**
# UPPER CASE 1
# LOWER CASE 9
#方法1
import re
st=input()
print('L... | UTF-8 | Python | false | false | 1,102 | py | 25 | Day_4.py | 24 | 0.658135 | 0.635283 | 0 | 37 | 28.567568 | 119 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.