blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 2 616 | content_id stringlengths 40 40 | detected_licenses listlengths 0 69 | license_type stringclasses 2
values | repo_name stringlengths 5 118 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 63 | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 2.91k 686M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 23
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 213
values | src_encoding stringclasses 30
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 2 10.3M | extension stringclasses 246
values | content stringlengths 2 10.3M | authors listlengths 1 1 | author_id stringlengths 0 212 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
7bd0879f9babbc70ad3e7b46acda567a0352685e | 1dacbf90eeb384455ab84a8cf63d16e2c9680a90 | /pkgs/nltk-3.2-py27_0/lib/python2.7/site-packages/nltk/chunk/util.py | 0027fab667b850ac00ae34418c66c68f13313f1e | [
"Apache-2.0",
"BSD-3-Clause",
"LicenseRef-scancode-unknown"
] | permissive | wangyum/Anaconda | ac7229b21815dd92b0bd1c8b7ec4e85c013b8994 | 2c9002f16bb5c265e0d14f4a2314c86eeaa35cb6 | refs/heads/master | 2022-10-21T15:14:23.464126 | 2022-10-05T12:10:31 | 2022-10-05T12:10:31 | 76,526,728 | 11 | 10 | Apache-2.0 | 2022-10-05T12:10:32 | 2016-12-15T05:26:12 | Python | UTF-8 | Python | false | false | 21,251 | py | # Natural Language Toolkit: Chunk format conversions
#
# Copyright (C) 2001-2015 NLTK Project
# Author: Edward Loper <edloper@gmail.com>
# Steven Bird <stevenbird1@gmail.com> (minor additions)
# URL: <http://nltk.org/>
# For license information, see LICENSE.TXT
from __future__ import print_function, unic... | [
"wgyumg@mgail.com"
] | wgyumg@mgail.com |
991cbc95070acdf5c80c693df59fb131362feff3 | b7c538adde4712a5be459b3c7cf39c574fdb30c8 | /macro1/matlab/Sugarkhuu_Macroeconomics_PS2/compute_medians.py | 984cfa199dedb74cd41427a2981ca5347c23fdb9 | [] | no_license | Sugarkhuu/bonn_phd | b3f9351628270a55d01204e8210c94cdba1bcde4 | 3b45b1c8462ab1e8c09ba3df9a90d57a74bc70cf | refs/heads/main | 2023-09-02T17:27:39.681537 | 2021-11-12T09:15:28 | 2021-11-12T09:15:28 | 420,656,790 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,491 | py | ### Code to compute income and networth medians from SCF data
# =============================================================================
# IMPORT PACKAGES
# =============================================================================
import pandas as pd
import numpy as np
import os
# ========================... | [
"py4econ@gmail.com"
] | py4econ@gmail.com |
381cbb9843c8e8a7b93fece9104cde8dc161688a | af373596f14347bb7a3483a14ead3004efd45aa1 | /particle.py | 5a99e874dc274413c9daecaac20f208b440ea466 | [] | no_license | bharath-r/2D-SLAM | 7ed1b519aa38b92bf99fdfcea53a29cd3f20ff41 | f1116f16cbaaaea6c08962c91843e7eade23c989 | refs/heads/master | 2020-05-03T00:34:05.574200 | 2019-03-29T01:56:21 | 2019-03-29T01:56:21 | 178,312,968 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,353 | py | import numpy as np
import math as m
import cv2
class particle(object):
# Particle has weight w and the current state x
def __init__(self, w,x):
self.w = w
self.x = x
# Update the map by finding hit coordinates in the world frame using the head/neck angles, local frame
# coordi... | [
"noreply@github.com"
] | bharath-r.noreply@github.com |
55ebb1748fdf42a82be27411918d1825e97a3dba | 3a88c807b9343d7e609edf6c5c77386ff258af8c | /day24/day24.py | 8fd81017776ae4f24962663b96e1f9a56adfebda | [] | no_license | cdmaher/adv_of_code_2019 | 0e9d66fd852207744d5da1ce8c6d6a9e81af71dd | 4051daeda28d64be771bce312355b3a92bffa962 | refs/heads/master | 2022-12-17T06:39:37.570316 | 2020-09-18T18:47:02 | 2020-09-18T18:47:02 | 296,703,033 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,525 | py | import sys
import copy
import math
from functools import reduce
from sets import Set
file = open(sys.argv[1], 'r')
lines = file.readlines()
erisArea = [[['.' for i in range(5)] for j in range(5)]
for depth in range(300)]
lineN = 0
firstArea = erisArea[150]
for line in lines:
splitL = list(line.rstrip(... | [
"cdmaher@fb.com"
] | cdmaher@fb.com |
ea8ca2060f2262c3ecaf0c88506fad93bb81a001 | eb54d732b5f14f03d9bf2988c6157605c80bbdd5 | /bubble_sort.py | e599bb7065016d2e01b3e67d5e93e3dc4947d828 | [] | no_license | tngo0508/practice_coding | 2e60519fed83a9b3c28b52c2d5ec1ee1d2a609ed | 453c9a7b9a8aa80f37b245f9df447525a9b0a2d1 | refs/heads/master | 2022-03-27T01:44:56.589650 | 2020-01-05T18:58:31 | 2020-01-05T18:58:31 | 225,294,423 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 270 | py | def bubble_sort(nums):
for i in range(len(nums) - 1, 0, -1):
for j in range(i):
if nums[j] > nums[j + 1]:
nums[j], nums[j+1] = nums[j+1], nums[j]
print(nums)
return nums
print(bubble_sort([4, 1, 0, 3, 5, 1, 2, 6]))
| [
"tngo0508@gmail.com"
] | tngo0508@gmail.com |
71ae82df16f921dba43e0a9720d746745210aa0c | dcb2700636da30ca8e2a86e8a76fb5e796650922 | /app/geocode.py | 64843a6543b1d571817e8df242917048df3b7cd4 | [] | no_license | Tepau/GrandPyBot | 17820200595d1f7de4da4eb920b7a56cd7eeb62b | 63bbc85b6fa9e945819ecc45fd318b842ebdfd89 | refs/heads/master | 2022-12-13T16:06:11.440161 | 2020-05-04T13:21:23 | 2020-05-04T13:21:23 | 201,489,329 | 0 | 0 | null | 2022-12-08T06:10:18 | 2019-08-09T15:02:07 | Python | UTF-8 | Python | false | false | 1,486 | py | import googlemaps
import os
class GoogleMap:
"""class who recovers informations about
a place through the api "googlemap\""""
def __init__(self):
self.gmaps = googlemaps.Client(key=os.environ.get('KEY'))
def find_adress(self, search):
# Get the full adress of a place
geocod... | [
"malaury.lemaitresalmon@gmail.com"
] | malaury.lemaitresalmon@gmail.com |
eb79ae9da300d2daa7953889856eb0652be4ea4c | d08c8bcbe0f67cb3ff2a01afc9fad390dafc4f0a | /test/Search.py | 160ad7cdc68be1100fd06521f140ffba64b3240b | [
"BSD-2-Clause",
"BSD-3-Clause"
] | permissive | Dibyadarshan/mezzanine | 6e6a1cafdba03660a18df29238b271a83357a9b0 | 6bc046f086c70c1f6bda3458eafbbe2da54df0c8 | refs/heads/master | 2020-07-22T07:29:35.759238 | 2019-11-06T17:14:04 | 2019-11-06T17:14:04 | 207,116,582 | 0 | 0 | BSD-2-Clause | 2019-09-08T13:27:44 | 2019-09-08T13:27:44 | null | UTF-8 | Python | false | false | 2,564 | py | import unittest
from selenium import webdriver
import time
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support.ui import Select... | [
"hanmol123@outlook.com"
] | hanmol123@outlook.com |
86a2d304179a0d4d021966bafce213f4365d57c2 | 84290c584128de3e872e66dc99b5b407a7a4612f | /Statistical Thinking in Python (Part 2)/Bootstrap confidence intervals/Visualizing bootstrap samples.py | 325418de26f528e09ecafe5c6554c241dae959c8 | [] | no_license | BautizarCodigo/DataAnalyticEssentials | 91eddc56dd1b457e9e3e1e3db5fbbb2a85d3b789 | 7f5f3d8936dd4945ee0fd854ef17f04a04eb7b57 | refs/heads/main | 2023-04-11T04:42:17.977491 | 2021-03-21T19:05:17 | 2021-03-21T19:05:17 | 349,784,608 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 534 | py | for _ in range(50):
# Generate bootstrap sample: bs_sample
bs_sample = np.random.choice(rainfall, size=len(rainfall))
# Compute and plot ECDF from bootstrap sample
x, y = ecdf(bs_sample)
_ = plt.plot(x, y, marker='.', linestyle='none',
color='gray', alpha=0.1)
# Compute and plot E... | [
"78171986+BautizarCodigo@users.noreply.github.com"
] | 78171986+BautizarCodigo@users.noreply.github.com |
391a306f78fe5c96c880603c95534afa317eb828 | 874f8db726d5ce5da971dbd54aac58f0b3176d78 | /aa通用的工具类或方法/一个通用的mongodb类.py | 688e8d6c4c304fd0c6613395dc49c4fed7d13fcf | [] | no_license | Social-Engineering-OrigData/python | a8442ab5b3a772ddfc568eb5e386b11074c5bf93 | 6dde78f75e2a3306bccdc0085a44751cf2b901ca | refs/heads/master | 2021-09-09T12:56:09.781127 | 2018-03-16T09:34:17 | 2018-03-16T09:34:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,035 | py | #!/usr/bin/env python
# encoding: utf-8
'''
@contact: wersonliugmail.com
@File : 一个通用的mongodb类.py
'''
from pymongo import MongoClient
"""
在爬虫存数据时使用,不需要事先建立数据库,直接存字典
"""
class MyMongo:
def __init__(self, dbname, colname):
"""
:param dbname: 初始化 命名自己的库
:param colname: 初始化 命名自己的表(集合)... | [
"wersonliu@gmail.com"
] | wersonliu@gmail.com |
a7f70dfb73aff910024e9703786cfdab163c284e | 9231d5ab3c99f328f6134df4982e7910e1db69b2 | /gui/wx/panel.py | 06cef3a5ef40d3c28afdfa79c6d64478a1a7b114 | [] | no_license | liviaerxin/python-tutorials | 6a908a93b894b29022bba15bac345e6594665454 | 5cb84861d9d616973637312711e23c5eb44f4fb5 | refs/heads/master | 2021-02-21T11:50:18.418465 | 2020-03-06T07:55:08 | 2020-03-06T07:55:08 | 245,357,735 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,326 | py | import wx
class ExamplePanel(wx.Panel):
def __init__(self, parent):
wx.Panel.__init__(self, parent)
# create some sizers
mainSizer = wx.BoxSizer(wx.VERTICAL)
grid = wx.GridBagSizer(hgap=5, vgap=5)
hSizer = wx.BoxSizer(wx.HORIZONTAL)
self.quote = wx.StaticText(self,... | [
"1yue8haogaoqi@gmail.com"
] | 1yue8haogaoqi@gmail.com |
95c11fc532001a60bcf89f67ab4b82459082e79d | 21bb5da0c2bbb840edd893539acffa35b04c614c | /tvshow_folder.py | e8039b06f46f6c8ecb4597c79343e1055c48a636 | [] | no_license | guiszk/tvshow | adef03e7859cb4efc46f028d2a6041797de8464d | 85f4b4ecfcb06bf8ff77043589e91f277dacdd05 | refs/heads/master | 2023-03-04T23:11:07.523762 | 2021-02-07T02:40:29 | 2021-02-07T02:40:29 | 337,578,820 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,686 | py | #!/usr/bin/env python3.7
import os, sys, re, requests
from bs4 import BeautifulSoup as bs
if(len(sys.argv) != 4):
sys.stderr.write("{0} <name> <path> <*name>\n".format(sys.argv[0]))
sys.exit(1)
if not (os.path.isdir(sys.argv[2])):
sys.stderr.write("<path> must be a directory\n")
sys.exit(1)
allowed = ... | [
"guiszk@protonmail.com"
] | guiszk@protonmail.com |
93059852d29c8eae57585fb1868438b234082be1 | 18aedf3de6badbdab79c7c1de632f7cc75b6540a | /livedata/forms.py | b7c03b74d8cc499c0b7a81f4ce97467071619d0e | [] | no_license | nrjadkry/covid19 | e4fada0ba1fa12088a8aa4a6594298d774174617 | 1f165a0820af9b3fa584aa2cbfade582801401c9 | refs/heads/master | 2022-09-05T12:03:53.675421 | 2020-05-27T11:00:06 | 2020-05-27T11:00:06 | 266,482,983 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 95 | py | from django import forms
class CovidForm(forms.Form):
country=forms.CharField(required=True)
| [
"nrjadkry@gmail.com"
] | nrjadkry@gmail.com |
c8cb7b527e6e5bd43755eaa0f580c076ec82f12e | f3bbfe35555030afce1fd6d430f0b90e02e96ced | /Directory Scan/dirScan.py | 9e448afcc1b3304e844393c5d35a9cc94477b88a | [] | no_license | git618/py-scripts | cb42e871fa2e085c81172d8678292bb6798a315b | b24404b393c2e7d8480435b70cbee1c3114b51a3 | refs/heads/master | 2022-01-09T16:49:40.129004 | 2018-09-13T03:19:36 | 2018-09-13T03:19:36 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,255 | py | # -*- coding:utf-8 -*-
import requests
from threading import Thread, activeCount
import queue
def dir_scan(url):
"""
扫描url
"""
headers = {
'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.... | [
"1162248131@qq.com"
] | 1162248131@qq.com |
e8e6486efd70d55478ed082df7d817b27d8eed70 | 5c0ca1a0c9c057a3ffc328a45e66b5a0bcbadd5a | /a.py | 5350b1468de4ae0e15c59023c556f6b57932215d | [] | no_license | 190330126/Project0202 | 516d75c4256704130bf6238afc6ff1e736bdb512 | e0b6b7629fc2e4eb9267ea01bc5bac9ac16b2293 | refs/heads/master | 2023-02-26T11:18:10.367685 | 2021-02-02T05:02:03 | 2021-02-02T05:02:03 | 335,174,001 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 76 | py | def do():
print("I can not do")
def play():
print("I play cricket")
| [
"190330126@klh.edu.in"
] | 190330126@klh.edu.in |
b663d23bffb53cf3aed33855ca26ce68dc91cab8 | e9b513db9bfcd9cbc8e59b3bc18498d03fbc9a3c | /preprocessing.py | 9cfa7ba7e590b24951a769d5e694f9684e250c8a | [] | no_license | ruirae123/appliedML-group_project | 97398107bda83604560b562b598a320079c5ca1d | 9c56c31403854a67229f8fe8711d22addc657776 | refs/heads/main | 2023-04-21T14:05:41.315758 | 2021-05-10T23:24:42 | 2021-05-10T23:24:42 | 352,131,686 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,617 | py | import ast
import os
import csv
import argparse
import constant
import pickle
import numpy as np
def _commandline_parser():
"""Commandline parser."""
parser = argparse.ArgumentParser()
parser.add_argument('--input_filename', type=str, default='framingham.csv')
parser.add_argument('--num_evals', type=int, defau... | [
"tianqi.kiko.zhou@gmail.com"
] | tianqi.kiko.zhou@gmail.com |
c084b8ef3203190d108bbb035c3c5f0dd2efccc3 | 48bccafbc774f82a7598ec514ccadf8962ec06d0 | /10/jacksyntax.py | 8415ac34c62438730f1d73e67bce9216533a304b | [] | no_license | waddlepon/nand2tetris | 9378be45b05205b94169b47aa5efa1c84846668d | 963fc5be3c1192f189b55db63a8a5466aca8dd5e | refs/heads/master | 2020-03-30T11:47:17.884896 | 2018-10-02T03:01:16 | 2018-10-02T03:01:16 | 151,192,782 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 16,427 | py | import argparse
import tempfile
import os
from enum import Enum
def isInt(s):
try:
int(s)
return True
except ValueError:
return False
class TokenType(Enum):
KEYWORD = 0
SYMBOL = 1
IDENTIFIER = 2
INT_CONST = 3
STRING_CONST = 4
class JackTokenizer:
SYMBOLS = ['{'... | [
"tylpoon@bigcity.local"
] | tylpoon@bigcity.local |
bbbfb80122a53747480b05910a3ddbde0647a7ed | 0ad2bcd3881c691ffdc8ba83d9af7611e7827220 | /pad2drums.py | 587c3b5c2e75052f1b5107f7daff50ccc664b1f7 | [] | no_license | SimmaLimma/pad2drums | e028691e4fd9562d935576d4d0941637aac2ad25 | f7d6b95681f65c94337c28e012fcfeadab9170a3 | refs/heads/master | 2020-04-10T04:42:46.297097 | 2018-12-25T21:24:30 | 2018-12-25T21:24:30 | 160,806,952 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 874 | py | from DrumGenerator import DrumGenerator
from detection import detect_sound
from utils import load_wav, save_wav
def pad2drums(read_from_fname, save_to_fname):
"""
Reads .wav-file in folder "raw_audio" from a drum pad (with mic about 10 cm away)
and converts it to an .wav-file with drum sounds in place of... | [
"simonmaartensson@gmail.com"
] | simonmaartensson@gmail.com |
35380b0997d3dc37aa77773fe400ca9768d179f3 | 9c05ec071dda2aa98ea1b12d9703dd91df19c87d | /quantum/hooks.py | 2c6a587a6d593503d2bbf9fee3977197c254c5db | [
"Apache-2.0"
] | permissive | DestinyOneSystems/quantum | af6ff44dd5e8cff944e53946f60adb11efb47bd5 | d7eafd8ffa719d91108b230221ecf27531a3530d | refs/heads/master | 2020-04-05T18:59:00.584768 | 2013-10-21T02:41:15 | 2013-10-21T02:41:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,109 | py | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2013 Hewlett-Packard Development Company, L.P.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://... | [
"mordred@inaugust.com"
] | mordred@inaugust.com |
73c381a2286a4c3eea64c1b22a9c5b3837ec8992 | deb6f0cb8f18c57de1bb6d31bdee293db7273796 | /DIABETES/urls.py | 2be7a8b7bae42caaeb584d2577d17639a65ff03c | [] | no_license | pratikrj1601/Health-Monitoring-using-Machine-learning | abf722fe1185560fd53e95ff2368f683a807e569 | 046b2e4863d0d64614278870be04727287e6f916 | refs/heads/master | 2023-09-02T03:00:09.308417 | 2021-11-12T12:09:15 | 2021-11-12T12:09:15 | 427,341,028 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 178 | py | from django.urls import path
from . import views
urlpatterns = [
path('', views.diabetes, name="diabetes"),
path('/prediction', views.predict, name="predict"),
]
| [
"noreply@github.com"
] | pratikrj1601.noreply@github.com |
5c97cdd91470bad1c6f42403f56fa17b169b7aa4 | e50a4820db6f5230c852ba3ef1b7fd12bbce9aac | /file/favority_number.py | 34448be22d245de0db738ce9497cfbca4f9d10a2 | [] | no_license | LeoSilvaGomes/pythonPlayground | 078773b6a3cf67e0e87d68c8c008733e40a29261 | bfb65f5cf4d60a3c1240be028a1d7ece3f127d77 | refs/heads/master | 2022-04-24T02:32:36.311181 | 2020-04-29T02:32:13 | 2020-04-29T02:32:13 | 259,804,126 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 244 | py | import json
def write_number():
'''Write on file the favority number'''
number = input("Tell me your favority number: ")
filename = 'favority_number.json'
with open(filename, 'w') as f_obj:
json.dump(number, f_obj) | [
"leonardodasigomes@gmail.com"
] | leonardodasigomes@gmail.com |
f138655f1c273477db99f1f85129ea718053c624 | 1a2cbc44bfcda1eafe4e8513de8541d8cd49bd08 | /fts/test_t1_amend_user2.py | f8bebf459f343d1e016841a1993e789e179cfd24 | [
"LicenseRef-scancode-public-domain"
] | permissive | DonaldMc/gdms | d62d34585a3914330cc933476dcb0d3ab750b7d8 | 7bfdf40d929afab2e204256c781c3700f6e24443 | refs/heads/master | 2021-01-18T12:38:55.798638 | 2016-05-30T18:59:55 | 2016-05-30T18:59:55 | 56,460,151 | 0 | 0 | null | 2016-05-30T20:59:22 | 2016-04-17T21:44:40 | Python | UTF-8 | Python | false | false | 3,486 | py | from functional_tests import FunctionalTest, ROOT, USERS
from ddt import ddt, data, unpack
from selenium.webdriver.support.ui import WebDriverWait
import time
from selenium.webdriver.support.ui import Select
# Testuser1 - stays as unspecified
# Testuser2 - specifies Africa and unspecified country and subdivision
# Te... | [
"donaldm2020@gmail.com"
] | donaldm2020@gmail.com |
01dbe7ced71ab19257a6164a20f22849cf0e5720 | 20cf7f9fdc5a9fa32a7332017a46dcf3d15dd3ad | /Lesson_10 (Classes)/Task3.py | 7777218dea95f3a1efdde46abd8f6ea895656f8f | [] | no_license | AlexSmolko/bitroot_repo | ee426e266946b5495f390817f305ead1901f6d0d | f8e767167f7a5dfe71d3e84ceba54fda54ba48cd | refs/heads/master | 2022-11-21T18:12:33.207560 | 2020-07-01T10:10:16 | 2020-07-01T10:10:16 | 254,702,073 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,489 | py | # TV controller
Channels = ["Discovery", "A1", "EuroSport", "MTV"]
class TVController:
def __init__(self, channels):
self.channels = channels
self.num_of_channel = 1
def first_channel(self):
print(self.channels[0])
def last_channel(self):
print(self.channels[-1])
d... | [
"34611935+Aresnadro@users.noreply.github.com"
] | 34611935+Aresnadro@users.noreply.github.com |
3a7a14f6ee378d42a4cee70efcbd88a5ae6688f4 | 72e87e5547ecd7f53695f2b1e3d7af089b75314c | /python/exercises/ex26.py | e13f67ac5d641183e8f7ff1066a636e681d43a9b | [] | no_license | SpencerArtisan/experiments | 7b3990d942874c90e239a9a7ba74a1864dca1f97 | d45ea5dec57da8b91f009e260ba06b5441eda911 | refs/heads/develop | 2021-01-01T18:29:12.303031 | 2012-07-06T14:07:39 | 2012-07-06T14:07:39 | 4,161,603 | 0 | 1 | null | 2018-04-09T19:10:30 | 2012-04-27T19:12:42 | Python | UTF-8 | Python | false | false | 2,285 | py | def break_words(stuff):
"""This function will break up words for us."""
words = stuff.split(' ')
return words
def sort_words(words):
"""Sorts the words."""
return sorted(words)
def print_first_word(words):
"""Prints the first word after popping it off."""
word = words.pop(0)
print word... | [
"spencerward@hotmail.com"
] | spencerward@hotmail.com |
30d846d37eefcc314ee9a952bf9d18e7cb2cc2b1 | f3e1c6702610b3104efaca3c177a050838f25e05 | /script/flask/bin/flask | 3da26d547b5f391ac0e9ae7f928b472ef7fd3456 | [] | no_license | cycfsabo/thesis | 5153aac15e81bfbe2d90af82d26dbdb495aba634 | d9124d97cc16896a343e43d55bdc9d41bad15067 | refs/heads/master | 2023-01-03T00:20:17.746874 | 2020-10-31T06:30:06 | 2020-10-31T06:30:06 | 308,819,040 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 223 | #!/home/hungcao/flask/bin/python2
# -*- coding: utf-8 -*-
import re
import sys
from flask.cli import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(main())
| [
"huuhungf@gmail.com"
] | huuhungf@gmail.com | |
2c940a23b570ef8251077537155455093097c2d3 | d1d366fe205dd8bb0469df4c9f80df488bccfa22 | /script/model/type.py | 8fc98bc7607cc6d5bd86dbab07e1c7e377b98f35 | [
"MIT"
] | permissive | kjobanputra/noisepage | 0403ed062350ad657178e943635ed2092c67a432 | e675b0befb55fcfaa78c23628e32800374a10a24 | refs/heads/master | 2023-04-01T07:49:09.715971 | 2020-10-30T00:56:01 | 2020-10-30T00:56:01 | 294,547,389 | 0 | 0 | MIT | 2020-12-01T04:50:46 | 2020-09-10T23:45:03 | C++ | UTF-8 | Python | false | false | 2,379 | py | """All the types (defined using Enum).
This should be the only module that you directly import classes, instead of the higher-level module.
"""
import enum
class Target(enum.IntEnum):
"""The output targets for the operating units
"""
START_TIME = 0
CPU_ID = 1,
CPU_CYCLES = 2,
INSTRUCTIONS = 3,... | [
"noreply@github.com"
] | kjobanputra.noreply@github.com |
36fc39d1390c434d3e34fec2e3c7d1f93053f360 | 7ae140103459547a514e11b0f51adec173843dce | /Administrador.py | d14f276cb56d09500a14e3d92126601375ae9239 | [] | no_license | Mintic-Team7-Inventario/Inventario_App | 94af71fd874ca8145a536778b6800502ce434b88 | 548bf122be82809359de5ede343a09b02fd9d0ab | refs/heads/master | 2023-08-20T02:34:50.931717 | 2021-10-28T15:16:17 | 2021-10-28T15:16:17 | 416,175,481 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 810 | py |
from UsuarioFinal import UsuarioFinal
from db import get_db
from db import close_db
class Administrador(UsuarioFinal):
def __init__(self,codigo,name, apellido, contraseña, celular,email,rol):
super().__init__(codigo,name, apellido, contraseña, celular,email,rol)
def buscarUsuario(self,label,value):... | [
"egarciasolano@outlook.com"
] | egarciasolano@outlook.com |
d1c1bbb2db6a84b96958926b348b6b210bbea91b | 31bee02c2f76b7c541007856659d0df7ba8d5b01 | /image_resize.py | 84a5f0265db2c5fe4c0b060a5c43b56267995240 | [] | no_license | hikaru7719/Image-Preprocessing | 6473b7b947b61407654bec4c3dc5521bdd4f57e1 | d6532ce0deead523e6f1451daf1254dceae44075 | refs/heads/master | 2021-04-09T16:26:32.824014 | 2018-03-25T02:57:06 | 2018-03-25T02:57:06 | 125,794,528 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,024 | py | from google.cloud import vision
from google.cloud.vision import types
import io
import os
from PIL import Image
import argparse
def image_function(image,size,file_path):
im = Image.open(image)
resize = im.resize(size)
rotate = resize.rotate(-90)
rotate.save(str(file_path))
def file_enums(dir_name):
... | [
"j148016s@st.u-gakugei.ac.jp"
] | j148016s@st.u-gakugei.ac.jp |
233285c17f75cb0cf8903cbacdeb74bbe001281d | 8fcdcec1bf0f194d23bba4acd664166a04dc128f | /packages/gcTool.py | bd22a08d82b189ff60330613fa6b6795e709fd48 | [] | no_license | grid-control/grid-control | e51337dd7e5d158644a8da35923443fb0d232bfb | 1f5295cd6114f3f18958be0e0618ff6b35aa16d7 | refs/heads/master | 2022-11-13T13:29:13.226512 | 2021-10-01T14:37:59 | 2021-10-01T14:37:59 | 13,805,261 | 32 | 30 | null | 2023-02-19T16:22:47 | 2013-10-23T14:39:28 | Python | UTF-8 | Python | false | false | 19 | py | grid_control_api.py | [
"stober@cern.ch"
] | stober@cern.ch |
6fa8dff4fc69d605b416ee01c4cf493f73020b64 | 86b4e40a0e9ad265c49e9287af5ebf6d0871987d | /Valid Parentheses/code.py | a99a498bb4d2e4fa2ac3f7b37c221da074ec8ed4 | [] | no_license | Jason-Woo/leetcode_problemset | 52abe06ae554c77213d7cad824310517b64a9fb0 | 8c22875b458dd8720e4c43caf70a0a6c7a5fdb6b | refs/heads/master | 2023-03-27T12:27:52.099188 | 2021-03-10T22:51:58 | 2021-03-10T22:51:58 | 263,157,060 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 341 | py | class Solution(object): #Atten
def isValid(self, s):
left, right, stack = "({[", ")}]", []
for item in s:
if item in left:
stack.append(item)
else:
if not stack or left.find(stack.pop()) != right.find(item):
return False
... | [
"4everjasonwoo@gmail.com"
] | 4everjasonwoo@gmail.com |
ab312889eb22efbe7f28a5feb579980812890a7a | 025eaa18456cebaa08e95b33f6e85474665feb1a | /NSC_Script.py | 47a2093aae048545cdaeefb370f1fa8f34e659f8 | [] | no_license | Rlopezra/NSC-Student-Tracker-Reduction-Script | 3f156179bd4e652a0584b8ba4145e577ee737404 | c13d30ad9335c2961d3d0b9edc402e695a1083ab | refs/heads/master | 2021-09-05T20:38:53.205100 | 2018-01-30T21:31:16 | 2018-01-30T21:31:16 | 111,505,980 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,367 | py | import pandas as pd
#This line loads the csv into a pandas data frame, you'll have to change it to the location of your NSC file
data = pd.read_csv("C:/Users/rjlopez/Desktop/EVC Tracker.csv")
#formatting the dates columns to proper date format, some interpreters will change these columns to a number if we don't form... | [
"noreply@github.com"
] | Rlopezra.noreply@github.com |
2f05d2d6c9b5c603f7c63f6fd86869c5371b1baa | 374615e05818a861b077253a484dd73e27ed65d3 | /batch/batch_learners.py | f4f0422b4b7396559881e73bb690b13924ff2ce3 | [] | no_license | wdbronac/m_car_python | bcdb4d6042b966ec855a77c901ec02a7e235b29f | 21e8ce7a6cadca6fa2774dc3b1847a7ff105be5c | refs/heads/master | 2021-05-31T11:23:26.666237 | 2016-05-24T09:52:25 | 2016-05-24T09:52:25 | 58,363,158 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,063 | py | # -*- coding: utf-8 -*-
"""
Module batch_learners
"""
import numpy as np
from sklearn.ensemble import ExtraTreesRegressor
from sklearn.linear_model import LinearRegression
class fittedQ:
"""
The fittedQ algorithm
Parameters
----------
regressor : a regressor from scikit-l... | [
"ubuntu@ip-172-31-1-251.eu-west-1.compute.internal"
] | ubuntu@ip-172-31-1-251.eu-west-1.compute.internal |
c283385eb0e04fff394a718c3a315e144b525bb9 | 35349ee872a16cc1e286c71d09496fc5e383efb5 | /svm_with_csk_svm.py | bfae4faf1bf402a13abcfef1923b6e9ca9cd705b | [] | no_license | aipjn/Dissertation_project | 3593d1e4524dee54f783f4f7eafdd4c8820a8ee1 | 1df15d24a632e092ba8146f885d27c6452f4a4a1 | refs/heads/master | 2020-03-22T22:10:53.872773 | 2018-09-10T00:06:11 | 2018-09-10T00:06:11 | 140,737,838 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,267 | py | """\
------------------------------------------------------------
USE: Using common sense to update SVM model
------------------------------------------------------------\
"""
import time
from utils.dataset import Dataset
from utils.utils import stemming, vocabulary
from utils.evaluation import Evaluation
from utils.bi... | [
"1058134934@qq.com"
] | 1058134934@qq.com |
458197f8501b21000576d09954086272fbca03f4 | acd2ce470c68d3f407c9bc022a6d115fdb962713 | /coroutine/iterable.py | b71c2cf5edf996c490b82c866d92ed51d46a6d13 | [] | no_license | wwd-0/python-base | 080ff0065eebc8209b7c4079a44a2726a3c67c63 | c4f900ce7cd735a2f57ebc88cfde7ffcfb437444 | refs/heads/master | 2022-06-26T15:01:29.718456 | 2020-05-10T12:36:09 | 2020-05-10T12:36:09 | 262,716,587 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 596 | py | #coding=utf-8
from collections import Iterable
import time
class ClassMate(object):
def __init__(self):
self.names = list()
self.current_num = 0
def add(self,name):
self.names.append(name)
def __iter__(self):
return self
def __next__(self):
if self.current_num < len(self.names):
ret = self.names[... | [
"wwd@localhost.localdomain"
] | wwd@localhost.localdomain |
fb43ed68a6f884a2cf5bfcfb9b67d3a2702633cb | 3f27c94566dc5ef905fb8a13a84f8a4801d2dc78 | /dataStructures/arrays/find_summing_numbers/find_summing_numbers.py | 1cb124da676efb54dba96fe58ecbc7762fa7fd90 | [] | no_license | trotrem/algo-rythmes | 26a9ac2735e94d8bd9b33ee56c9f536f9f8ec24a | fc9a183225be889d2aa0220cce6d12637ade3e93 | refs/heads/master | 2020-03-17T22:19:48.121377 | 2018-07-27T17:05:35 | 2018-07-27T17:05:35 | 133,999,344 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,106 | py | #!/usr/bin/env python
#Given an array of integers, return indices of the two numbers such that they add up to a specific target.
#You may assume that each input would have exactly one solution, and you may not use the same element twice.
class Solution:
# set O(n) O(n)
def twoSum_set(self, nums, target):
... | [
"jeanchristophe.buteau@gmail.com"
] | jeanchristophe.buteau@gmail.com |
2dba7604593e623d6fd2c527a1c032919cf5f2e2 | 5ea45cbeeb59353282bb5bfc070ad3f4b2c4630f | /snippets/views.py | d6372e628b3b5a9b015e51f3f9cef4f320251ae6 | [
"MIT"
] | permissive | tomaszd/rest_django | 4289c7309f83d5e6300062954be00792229f3a5d | 3366406e3d96b6dfe30a5388aba6de0498cabbca | refs/heads/main | 2023-02-11T02:14:48.658417 | 2021-01-09T01:10:10 | 2021-01-09T01:10:10 | 328,037,557 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,699 | py | from rest_framework import generics, viewsets
from rest_framework import permissions
from rest_framework import renderers
from rest_framework.decorators import api_view, action
from rest_framework.response import Response
from rest_framework.reverse import reverse
from snippets.models import Snippet
from snippets.permi... | [
"tomasz.dudziec@redembedded.com"
] | tomasz.dudziec@redembedded.com |
13200077a023a7b18121b8ac2256a596ef327e45 | 03dc722fea38f25844a45cd9606db2ccdc92dbaf | /projekt.py | 39428f9dbb1d7cf4b0ee6302f8e234309e614b66 | [] | no_license | Marcin8899/Grafika | 1c0a5fa5d911db215349ca6e7eb38ba2245398be | cce118609bd502da1f50945fe8691d4613de083b | refs/heads/master | 2023-04-21T09:05:42.527155 | 2021-04-20T09:15:59 | 2021-04-20T09:15:59 | 359,212,259 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 14,341 | py | import pygame
from pygame.locals import *
import keyboard
import numpy as np
from math import *
import sys
width = 800
height = 500
screen=pygame.display.set_mode((width,height))
screen.fill((0,0,0))
camera = 1000
zoom = 1
step = 20
angle = 0.02
#wczytanine pliku z danymi
f = open("bryly.txt", "r")
tekst = f.read(... | [
"marcinbaranowski8899@gmail.com"
] | marcinbaranowski8899@gmail.com |
56583f3316a24edddd70b4a0f9c935cbd4ceb946 | 3b79a802f8dd9f26bee0bfde4630ac0cab932803 | /srcSegcls/getEventSegDF.py | b004b92f2a243f693794a4efdb8cca0d07350ef9 | [] | no_license | qolina/Twevent | 87fc4706564088361e9db6ddc44efc10647e67fe | 4b90b0604493b20dee90448c17e0a8e0d557165e | refs/heads/master | 2021-06-24T19:06:02.022882 | 2017-08-15T05:20:09 | 2017-08-15T05:20:09 | 100,341,172 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,338 | py | #! /usr/bin/env python
#coding=utf-8
import time
import re
import os
import math
import cPickle
############################
## load tweetID-usrID
def loadUsrId(filepath):
usrFile = file(filepath,"r")
tweIdToUsrIdHash = cPickle.load(usrFile)
usrFile.close()
return tweIdToUsrIdHash
####... | [
"qolina@gmail.com"
] | qolina@gmail.com |
df75da1c4cd20551725bfd015ced8926d141dbca | 62e4030268aa2835a4806864cb70055675724471 | /docs/conf.py | 1016182d33de160fe22db4afafdff318e041a7bc | [] | no_license | aisis/FoxDotCode | 291507fe16f5a56b8fed312827712db213d78e83 | 186175f76873771e13b4aa1fa714201ab98c4efe | refs/heads/master | 2021-01-15T13:35:20.524593 | 2016-03-13T13:16:44 | 2016-03-13T13:16:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,385 | py | # -*- coding: utf-8 -*-
#
# FoxDot documentation build configuration file, created by
# sphinx-quickstart on Sun Feb 21 22:04:59 2016.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# Al... | [
"ryankirkbride26@gmail.com"
] | ryankirkbride26@gmail.com |
ede138d3bc51c61545e5ac67a26e7478adae7361 | 3f21aab01358400321d14ea68513f8fd5b2075e9 | /Calculate_Electricity_Bill_Example_1.py | 51c984411b92f145dc5f4d651c4aed9efd6783e2 | [] | no_license | AAKASH707/PYTHON | c3f991f3517259ee0fc14ab68a8b8bb6c01e4b70 | cadb4f4849f4a5e99647d2173cdbb8e953ad038e | refs/heads/master | 2021-03-12T05:44:12.914266 | 2021-03-02T18:18:37 | 2021-03-02T18:18:37 | 246,594,637 | 1 | 1 | null | 2021-01-25T17:48:38 | 2020-03-11T14:33:28 | Python | UTF-8 | Python | false | false | 562 | py | # ********* Python Program to Calculate Electricity Bill *********** #
units = int(input(" Please enter Number of Units you Consumed : "))
if(units < 50):
amount = units * 2.60
surcharge = 25
elif(units <= 100):
amount = 130 + ((units - 50) * 3.25)
surcharge = 35
e... | [
"noreply@github.com"
] | AAKASH707.noreply@github.com |
ccfd614cc9917c7b23572f95c1d1f85958ab5721 | d17d407c0e8d05a3cbc1b390e7d1d6f8a4cfe2ad | /rango/models.py | 35d46db39c80a42ee1c0b2dc36bdc55f4387e4bd | [] | no_license | sp6pe/tango_with_django_project | 75400654f8cec0772a2fd32a57f17163f1de1197 | a6cb1cd61e07bd857751bfe8d9689219059f9a76 | refs/heads/master | 2020-07-20T12:43:30.408047 | 2015-07-31T14:17:58 | 2015-07-31T14:17:58 | 39,037,052 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,206 | py | from django.db import models
from django.template.defaultfilters import slugify
from django.contrib.auth.models import User
# Create your models here.
class Category(models.Model):
name = models.CharField(max_length=128, unique=True)
likes = models.IntegerField(default=0)
views = models.IntegerField(default=0)
slu... | [
"sp6pe@virginia.edu"
] | sp6pe@virginia.edu |
92fd71893fb2c2abeccd87ac9e76f3529a90d3d3 | 145648d14728076d3e9859ee3293b4210d21f67f | /3_lists.py | e73606d28cfdd3b0b792e2e6883113728a85f085 | [] | no_license | ankitmazumder/executeoncommand | 7d1bb9ad402a6840a3b622a7fe1680fc8fb688e6 | 4000d21b87ad4e9540a8714be820983149f70cf8 | refs/heads/master | 2023-08-22T14:47:27.937082 | 2021-09-28T16:33:25 | 2021-09-28T16:33:25 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,914 | py | list_name = list()
print(list_name)
string_list = ["one", "two", "three"]
print(string_list)
num_list = [1, 2, 3]
print(num_list)
mixed_list = [1, 2, 3, "one", "two", "three", [4, 5, 6], {"key":"value"}]
print(mixed_list)
vegetables = ["Potatoes", "Carrots", "Cauliflower", "Broccoli", "Bell Pepper"]
print(vegetabl... | [
"noreply@github.com"
] | ankitmazumder.noreply@github.com |
0d1ed554911585ef093b2a5e0d0b9f8eab5a70c3 | 5962cf5c30d69b4b57d2ec598e11c3a81c6df083 | /old/frontend_mpl_basemap.py | c5619e6296c99f49301064adc4a61433adac319e | [] | no_license | sergeimoiseev/othodi_code | 1584f4006c2bddd8ddbbc6e7439b782c1f93c313 | 87f11374fc1f332752d426af4e047306aefcbd81 | refs/heads/master | 2021-01-10T04:17:45.407696 | 2016-01-26T20:23:59 | 2016-01-26T20:23:59 | 48,580,790 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,318 | py | # -*- coding: utf-8 -*-
import numpy as np
import matplotlib
# matplotlib.use('nbagg')
# import matplotlib.pyplot as plt
# import matplotlib.cm as cm
# import mpld3
# matplotlib.use('nbagg')
def plot_route(coord_pairs,annotes):
# matplotlib.use('nbagg')
import matplotlib.pyplot as plt
import matplotlib.c... | [
"moiseev.sergei@gmail.com"
] | moiseev.sergei@gmail.com |
736895652d7acd47dd0b3beb52f7fe26a8ea60e4 | 7baf7106a41a9101e2677ccf336d7163f744d4c9 | /ScreenShot_App.py | 8a3a65d51bb7f27aba1aca06cdbd9d138b05946f | [] | no_license | nirsa1001/Python_Projects | 39b5c6a0cd9d9570380ee9aa575742b6dd987357 | d73f23d82fe06a1c3737b0c08d7be2ac62199019 | refs/heads/master | 2022-11-17T22:58:52.715689 | 2020-07-18T16:41:41 | 2020-07-18T16:41:41 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 636 | py | import time
import pyautogui
import tkinter as tk
def screenshot():
name = int(round(time.time() * 1000))
name = 'C:/Users/gsc-30431/PycharmProjects/test1.py/Screenshot_App/{}.png'.format(name)
# Update the Directory path above where the screenshots will be saved.
img = pyautogui.screenshot... | [
"noreply@github.com"
] | nirsa1001.noreply@github.com |
f50b218007abef8fad7e58bf1ef26cba7d9cde1b | c634c8dd46673eed049631c95527a4174a822198 | /ProductionScripts/ConfigFiles/FullSim/DIGI2_cfg.py | b2f38e155310cb34030c2716f4fd4bfec1cb4fb7 | [] | no_license | nicolastonon/EFTSimPheno | ad79bd721a519405b97db83040c6ee8e1cf63e96 | fb6c068611b3b746d72108bf76080297b68b76fd | refs/heads/master | 2023-07-25T08:37:13.170427 | 2021-09-06T16:49:28 | 2021-09-06T16:49:28 | 228,392,657 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,210 | py | # Auto generated configuration file
# using:
# Revision: 1.19
# Source: /local/reps/CMSSW/CMSSW/Configuration/Applications/python/ConfigBuilder.py,v
# with command line options: step2 --filein file:DIGI1.root --fileout file:DIGI2.root --python_filename DIGI2_cfg.py --mc --eventcontent AODSIM --runUnscheduled --datatier... | [
"nicolas.tonon@cern.ch"
] | nicolas.tonon@cern.ch |
49306970580db9ada7e0fe1475f50d1b04f37a57 | b66e43ad7128a62ebbfacc0cce19386e2d273090 | /image_server/get_latest_distro.py | 7d111b27e930a2c4398b7039c98bbdcb1585b417 | [] | no_license | dorkamotorka/ImageBuild | 4e22c26eed40a6dec4650c4145bd45ec3f28e40b | fb99981017cb1692cc442e3460ed519b12ad6061 | refs/heads/master | 2023-08-19T14:31:45.585481 | 2021-10-18T07:27:17 | 2021-10-18T07:27:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,290 | py | #!/usr/bin/env python
import sys
import xmltodict
from urllib.request import urlopen
import os
import subprocess
import dateutil.parser
from os import path
def execute(command, cwd):
proc = subprocess.Popen(command, shell=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, cwd=cwd)
re... | [
"tp4348@student.uni-lj.si"
] | tp4348@student.uni-lj.si |
cd4907ec3488eeaa4af0b6adb78c6fe463d8811d | 4142b8c513d87361da196631f7edd82f11465abb | /python/round135/219A.py | 84c2546d1739cabe735229c97479d28929b9d4e4 | [] | no_license | npkhanhh/codeforces | b52b66780426682ea1a3d72c66aedbe6dc71d7fe | 107acd623b0e99ef0a635dfce3e87041347e36df | refs/heads/master | 2022-02-08T17:01:01.731524 | 2022-02-07T10:29:52 | 2022-02-07T10:29:52 | 228,027,631 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 247 | py | from collections import Counter
k = int(input())
s = input()
d = Counter(s)
res = ''
for t in d:
val = d[t]
if val % k == 0:
res += t * (val // k)
else:
res = '-1'
break
if res != '-1':
res *= k
print(res)
| [
"npkhanh93@gmail.com"
] | npkhanh93@gmail.com |
243a57f48705fe5f22f30fb80a4ffa1f1e9fcd60 | 81abaf1a5ed956ec22fb1a547dac1624e54e7c30 | /third-party/typeshed/stdlib/2and3/warnings.pyi | 2e95533f7fc16ff0b3a56d7f88e3f703e4099031 | [
"Unlicense",
"MIT",
"Apache-2.0"
] | permissive | joschu/blobfile | 11573372ea4749fdab6ab94421a55796e4cbffdc | 0a534f3ad33ca0ba8f5ab27d3f5e41aec2914883 | refs/heads/master | 2021-07-13T19:08:39.695706 | 2019-11-24T22:41:06 | 2019-11-24T22:41:21 | 224,252,657 | 1 | 0 | Unlicense | 2019-11-26T17:49:09 | 2019-11-26T17:49:08 | null | UTF-8 | Python | false | false | 2,353 | pyi | # Stubs for warnings
import sys
from typing import Any, Dict, List, NamedTuple, Optional, overload, TextIO, Tuple, Type, Union, ContextManager
from types import ModuleType
if sys.version_info >= (3, 8):
from typing import Literal
else:
from typing_extensions import Literal
@overload
def warn(message: str, ca... | [
"48501609+cshesse@users.noreply.github.com"
] | 48501609+cshesse@users.noreply.github.com |
b6c7bc0863d3be11b0c5fdaf4028d0651061b62a | 3ee0418421955d01558b1c623def251932bcfc01 | /python-examples/marble_sort/write_json.py | b3388c9cc682286c4a2476f1d08641cbb8ddb79c | [
"MIT"
] | permissive | pep-dortmund/mindstorms | 89f426930516155bb75f52b9fdd24a0b64fc0951 | 9e6be52545e21ab8ba3bca7e1b0e64ed2320366d | refs/heads/master | 2021-01-01T19:19:26.508803 | 2017-04-29T11:39:35 | 2017-04-29T11:39:35 | 38,932,641 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 658 | py | from argparse import ArgumentParser
import zmq
import json
parser = ArgumentParser()
parser.add_argument('outputfile')
parser.add_argument('-p', '--port', type=int, default=5000)
context = zmq.Context()
socket = context.socket(zmq.REP)
def main():
args = parser.parse_args()
socket.bind('tcp://0.0.0.0:{}'.fo... | [
"maximilian.noethe@tu-dortmund.de"
] | maximilian.noethe@tu-dortmund.de |
9184b987dcf3cf5d222de59fba7989facf1216c2 | 72a3c7f7b7b5a4a533fa1b53b03b56630779ab87 | /common/urls.py | f47028742b482f03fd1fd87b8984e253461052ba | [] | no_license | sdarbucks/pyweb | 7cb8b84b909ffa5f5dd86131cd7cfd6c01a565b7 | bfb8c92d65d252d06d05c3b3e01a7d0a63dca59e | refs/heads/main | 2023-08-25T18:58:43.250648 | 2021-10-22T01:54:05 | 2021-10-22T01:54:05 | 415,763,736 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 397 | py | from django.urls import path
from django.contrib.auth import views as auth_views
from . import views
app_name = 'common'
urlpatterns = [
# 127.0.0.1:8000/common/login
path('login/', auth_views.LoginView.as_view(
template_name='common/login.html'), name='login'),
path('logout/', auth_views.LogoutView.a... | [
"kdh797979@naver.com"
] | kdh797979@naver.com |
1390212b59f1a609de481080cfa340b8b55b6dfd | b144928d199550e0fd2a0a0a21224e4f463e4bc6 | /src/cmssh/filemover.py | bbc8b2abf265ef902f6c600bfe786fe4a2ff5e37 | [] | no_license | dmwm/cmssh | 84f91ca1bb401dc052dcde1f58f42ecee48a3438 | 0cd6e104185938d21b10b053479e890c9f4f3b57 | refs/heads/master | 2016-09-10T19:13:29.567153 | 2014-03-06T20:45:05 | 2014-03-06T20:45:05 | 2,615,169 | 2 | 0 | null | 2012-11-28T18:24:41 | 2011-10-20T18:23:41 | Python | UTF-8 | Python | false | false | 27,912 | py | #!/usr/bin/env python
"""Filemover cli equivalent"""
# system modules
import os
import re
import sys
import json
import stat
import time
import thread
import urllib
import urllib2
import datetime
from multiprocessing import Process
# for DBS2 XML parsing
import xml.etree.ElementTree as ET
# cmssh modules
from cmssh... | [
"vkuznet@gmail.com"
] | vkuznet@gmail.com |
a44eef4aa7259c94d66a70938ae38b76bea2755e | 0761c57443d2491b00753a6545395f682be27273 | /PythonProgramming/4-20/dictionary.py | 21f380ac66cc8613b2783f781af26fdf851de376 | [] | no_license | MorgFost96/School-Projects | 842835f97c025ee97e106540f2e6f03f5fdac563 | 9c86a4133e7cb587d7ad15af8da962278636db1f | refs/heads/master | 2020-09-21T22:19:49.494044 | 2019-11-30T22:19:56 | 2019-11-30T22:19:56 | 224,951,541 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,920 | py | # Dictionary
# - An objet that stores a collection of data.
# - Each element has two parts:
# - Key
# - Value
# - The key is used to locate a specific value
# ------------------
# English Dictionary
# ------------------
# - The word = Key
# - Definition = Value
#
# - emp_ID = Key
# - emp_name = Value
#... | [
"morgfost96@gmail.com"
] | morgfost96@gmail.com |
c85113890b4775751eea8a0787ac818401ea92d5 | c660fdd49861211926a9dac0206d3856002ff2a8 | /smbl/prog/plugins/samtools.py | e203b8094d9a9201ecb7919fbc2f9595a2242875 | [
"MIT"
] | permissive | hermanzhaozzzz/smbl | d493a8b7ecfaf961c7ca7280d94c945a3e4e3b92 | 5922fa2fc4060d86172e991361a1cceb0af51af8 | refs/heads/master | 2021-06-23T11:27:57.869235 | 2017-08-19T02:21:51 | 2017-08-19T02:21:51 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 754 | py | import smbl
import snakemake
import os
from ._program import *
SAMTOOLS = get_bin_file_path("samtools")
##########################################
##########################################
class SamTools(Program):
@classmethod
def get_installation_files(cls):
return [
SAMTOOLS,
]
... | [
"karel.brinda@gmail.com"
] | karel.brinda@gmail.com |
39404acc2db6c62f24ba2846e40a3ce78fde1adb | 23560875366953541985d881a8f767dca545c718 | /python3-virtualenv/lib/python3.6/site-packages/pip/_vendor/cachecontrol/serialize.py | 4e4baa55963e4cfc3eb1597188278eac7e7b1356 | [
"MIT"
] | permissive | GinaJame/Portfolio_MLH | cffccdfa0e7004afaf8634427b94d64359c1a488 | 541709dcf034ddca885a8b08f9922dc352c113f8 | refs/heads/master | 2023-06-21T00:27:14.795285 | 2021-07-28T01:40:29 | 2021-07-28T01:40:29 | 380,074,076 | 0 | 0 | MIT | 2021-07-28T01:40:30 | 2021-06-24T23:31:24 | Python | UTF-8 | Python | false | false | 7,090 | py | import base64
import io
import json
import zlib
from pip._vendor import msgpack
from pip._vendor.requests.structures import CaseInsensitiveDict
from .compat import HTTPResponse, pickle, text_type
def _b64_decode_bytes(b):
return base64.b64decode(b.encode("ascii"))
def _b64_decode_str(s):
return _b64_decod... | [
"dakshinabp@berkeley.edu"
] | dakshinabp@berkeley.edu |
47ede935441605d7d56f33de91b7e10d1f544291 | 930309163b930559929323647b8d82238724f392 | /sumitb2019_c.py | 8ebf6c2adc23f64ec6e3e5122b0e1896defd65e2 | [] | no_license | GINK03/atcoder-solvers | 874251dffc9f23b187faa77c439b445e53f8dfe1 | b1e7ac6e9d67938de9a85df4a2f9780fb1fbcee7 | refs/heads/master | 2021-11-07T14:16:52.138894 | 2021-09-12T13:32:29 | 2021-09-12T13:32:29 | 11,724,396 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 210 | py | import itertools
X = int(input())
ps = [100, 101, 102, 103, 104, 105]
dp=[0]*(X+1)
dp[0] = 1
for p in ps:
for i in range(len(dp)):
if i >= p:
dp[i] = max(dp[i], dp[i-p])
print(dp[X])
| [
"gim.kobayashi@gmail.com"
] | gim.kobayashi@gmail.com |
6afad1eb9a9749a808aa04ff852f4ed7cf4fb72b | 889d13d15084f12e84731f48f50c72169f4ca45f | /public/class03demos/class03p10.py | d49c82eb8a80a9c4ac35087d43a3a802aada5e9c | [] | no_license | puneet-khatod/ml4us | 1bb4a661f3d59d8d0b7ff9e959b2f51324c7a9c9 | 917cdac85086bfc82f03e3db3ba8e7b15f9c407b | refs/heads/master | 2021-05-06T15:59:13.646649 | 2017-12-09T08:03:30 | 2017-12-09T08:03:30 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 665 | py | """
class03p10.py
This script should use Pandas to plot prices of GSPC for 2016.
"""
import pandas as pd
import matplotlib.pyplot as plt
csvfile = 'http://spy611.herokuapp.com/csv/allpredictions.csv'
# Goog: In pandas how to sort a dataframe?
cp_df = pd.read_csv(csvfile).sort_values(['cdate'])
# Goog: In pandas how ... | [
"bikle@bikle.com"
] | bikle@bikle.com |
ee8aad80ea9fe488f536a12acb866395bcbdfc70 | c26dc7928b1facac2c0912f6532076d35c19e835 | /devel/lib/python2.7/dist-packages/cob_object_detection_msgs/srv/__init__.py | 8d01ac1030bab33d482fd8bc39a91912a52446bc | [] | no_license | mattedminster/inmoov_ros | 33c29a2ea711f61f15ad5e2c53dd9db65ef6437f | e063a90b61418c3612b8df7876a633bc0dc2c428 | refs/heads/master | 2021-01-23T02:39:36.090746 | 2017-08-09T02:56:42 | 2017-08-09T02:56:42 | 85,995,826 | 0 | 0 | null | 2017-03-23T20:45:32 | 2017-03-23T20:45:32 | null | UTF-8 | Python | false | false | 309 | py | from ._AcquireObjectImage import *
from ._BaTestEnvironment import *
from ._BagTrainObject import *
from ._ComputeGraspsVacuumGripper import *
from ._DetectObjects import *
from ._SaveRecordedObject import *
from ._StartObjectRecording import *
from ._StopObjectRecording import *
from ._TrainObject import *
| [
"mattedminster@gmail.com"
] | mattedminster@gmail.com |
c6c285a03178805fd2966399625ea4b885c8db09 | 96b0fdb57d99add48823cd80dfb822af0df18e22 | /bin/wheel | 166f9b141ab4b9f56da78f02d68d2e79b6dd5d69 | [] | no_license | sebfio/mte546project | 39e368dd0a1aff20f8f480b242bebba9fe24ae0c | 98027eec4382c2449d0a7cfd4fd43354457f3d76 | refs/heads/master | 2023-02-03T15:25:03.388192 | 2020-01-08T03:08:35 | 2020-01-08T03:08:35 | 176,009,525 | 0 | 0 | null | 2023-02-02T04:54:08 | 2019-03-16T18:29:41 | Python | UTF-8 | Python | false | false | 224 | #!/home/sxf/mte546/bin/python3
# -*- coding: utf-8 -*-
import re
import sys
from wheel.cli import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.argv[0])
sys.exit(main())
| [
"sebf465@gmail.com"
] | sebf465@gmail.com | |
b7d7f1bc6ee38581a5c6d1a8bdc2310c73124071 | ad8ad2e32f8d83e4ef00bdd78ce475776258702a | /square_sum_recursion_all_variants.py | 0c8081d89c882c4062f4e2f52e4ce295d2fba650 | [
"MIT"
] | permissive | GudniNathan/square_sum | b640255f7e73bc90c9e46b7144d4b8ed74fe2447 | 917c5cf4ae92d601a1981a7a706727dfe7d727a6 | refs/heads/master | 2022-12-18T06:51:25.577352 | 2019-03-23T01:48:12 | 2019-03-23T01:48:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,447 | py | # This variant of the program will show every single possible way to complete a Square-Sum Hamiltonian Path
# with the chosen number.
# Note that half of these are just the reverse of the other half.
import threading
import time
from timeit import default_timer as timer
print("Choose length:")
count = int(input())
s... | [
"1493259+GudniNatan@users.noreply.github.com"
] | 1493259+GudniNatan@users.noreply.github.com |
6f1ae0b6a986c2ed2588756e942fa6923ab9c265 | 3958007e70f061b77c3637024f98dfc8b6187534 | /DataProvider/ModisProvider.py | 8afaedc96a67c2896e392f2aab320ba5a46eb6fc | [] | no_license | lijiao19320/ProjectTransform | d040b02c766db642cb044b0e8d550379da2789d0 | 302a2fb30fa7ae63d2ceb560ab2d1d7fbecb1385 | refs/heads/master | 2020-12-25T22:19:01.756560 | 2016-09-05T02:27:28 | 2016-09-05T02:27:28 | 64,626,631 | 0 | 0 | null | 2016-08-01T01:46:00 | 2016-08-01T01:46:00 | null | UTF-8 | Python | false | false | 10,476 | py | from DataProvider import *
from HdfOperator import *
import types
import numpy as N
from Parameters import *
from natsort import natsorted, ns
class ModisProvider(DataProvider):
def __init__(self):
super(ModisProvider, self).__init__()
self.__AuxiliaryDataNamesList = dict()
self.__HdfFile... | [
"21797lijiao"
] | 21797lijiao |
3ca06b13017075a0b08c397157ed7c355b8b5328 | 5f262dbebb61d8ddd67d4e605fb61c194ef47df8 | /windmill/models/schemas/__init__.py | af299db61f166b36b3980dc4fcfa6a59a5b3b757 | [
"Apache-2.0"
] | permissive | bhavaniravi/windmill | 5d157794c80cc416a122e601c07e1ee40b843b2a | 0bae5c34652d8366f6fff08ff7879d24a76c91b5 | refs/heads/master | 2021-04-04T04:54:31.841580 | 2020-03-23T11:35:22 | 2020-03-23T11:35:53 | 248,425,735 | 1 | 0 | Apache-2.0 | 2020-03-19T06:17:38 | 2020-03-19T06:17:37 | null | UTF-8 | Python | false | false | 25 | py | from . import app_schemas | [
"micsalama@gmail.com"
] | micsalama@gmail.com |
0037015439481d0e18bcfef36abb4692897ad45d | 6fad6f220c4ac5e52b7a7a082c63b81320102a2a | /proyectos/10/src/jackGrammarVisitor.py | ad1f0c487b2dbd750bda5c7d858324ed42a7349b | [] | no_license | lmvasquezg/Computer-architecture | 512ba5fc85dacaa85803a8c9e3fa1a847b1427b1 | 1352b9ce6b95f335d4d3d1e2c3080cbc4625213a | refs/heads/master | 2022-04-11T07:53:41.237720 | 2020-03-09T14:16:37 | 2020-03-09T14:16:37 | 192,032,115 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 4,871 | py | # Generated from jackGrammar.g4 by ANTLR 4.7.1
from antlr4 import *
if __name__ is not None and "." in __name__:
from .jackGrammarParser import jackGrammarParser
else:
from jackGrammarParser import jackGrammarParser
# This class defines a complete generic visitor for a parse tree produced by jackGrammar... | [
"lmvasquezg@MacBook-Pro-de-Luisa-2.local"
] | lmvasquezg@MacBook-Pro-de-Luisa-2.local |
4ffb6ea7c83ee437d39a2753bb202e509645745e | bd0f1da30c87101267fc53386a378f847c9fd0cd | /dbgtype.py | ac3d163a57e746ae58a740154a58b7770644da17 | [
"BSD-3-Clause"
] | permissive | fengjixuchui/LKD | cf2db9bf0023d832a8e9c08982801b4218ce97c1 | f388b5f8c08b7bba2a31c5a16ea64add6cc2dd1a | refs/heads/master | 2020-04-17T02:32:43.294752 | 2015-10-21T13:59:36 | 2015-10-21T13:59:36 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,741 | py | # # Experimental code # #
# Idea: make 2 type
# One for field (with field name / bitfield / parentclass / etc)
# One for the type above (fieldname.type)
# That have info about array size and co
import struct
from windows.generated_def.winstructs import *
class DbgEngTypeBase(object):
def __init__(self, module, t... | [
"firstname.lastname@sogeti.com"
] | firstname.lastname@sogeti.com |
4970dcdf1544b9e15abe1d6a4a00f1534ace0616 | f9e5613901957409ca535468af7301ddfbf2512e | /lmru.py | 2f0f1eb4021c923e59517e4f26eae4fbe2cac9dd | [] | no_license | OlgaP-1/Metods-sbora-i-obrabotki-bases | 6f3b0d6a283086dc6315328bd93303dca179d29c | a0a4ed4478079880fee3f7dad68ad76ece218e45 | refs/heads/main | 2023-04-01T10:57:42.167990 | 2021-03-30T18:17:06 | 2021-03-30T18:17:06 | 344,433,801 | 0 | 0 | null | 2021-04-08T22:09:39 | 2021-03-04T10:22:35 | Python | UTF-8 | Python | false | false | 2,217 | py | import scrapy
from scrapy.http import HtmlResponse
from leruaMerlen.items import LeruamerlenItem
from scrapy.loader import ItemLoader
class LmruSpider(scrapy.Spider):
name = 'lmru'
allowed_domains = ['leroymerlin.ru']
def __init__(self, search):
super().__init__()
self.start_urls = [f'http... | [
"noreply@github.com"
] | OlgaP-1.noreply@github.com |
f7d6009afe642598dd42b9bec2f9d912ca79f499 | 99b3a729c1240b022b7d58a31dd0d6236ba62243 | /codes/verify_data.py | 9201cf86dfa142d3ff85649d4bdf05a881f4ed07 | [
"Apache-2.0"
] | permissive | deergoose/BasicSR | bdc92a4510bcf68f86392410bad5832722ae86d2 | d8ee9e84a308ad47e7cc97adc4a282f34cbdb956 | refs/heads/master | 2020-07-06T00:02:59.398073 | 2019-04-27T20:22:17 | 2019-04-27T20:22:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 506 | py | import argparse
import matplotlib.pyplot as plt
from data.dstl_dataset.dataset import DstlDataset
import options.options as option
parser = argparse.ArgumentParser()
parser.add_argument('-opt', type=str, required=True, help='Path to option JSON file.')
opt = option.parse(parser.parse_args().opt, is_train=True)
opt =... | [
"zhoufang@ucsd.edu"
] | zhoufang@ucsd.edu |
362de125dfff44ad410d7bef2f1dd56984cbfb60 | bdcfcb7924633a11ef1cfacc283ee2116ebf87e3 | /neuralTPPs/tpp/models/base/process.py | a10e0aab4f111779348bfcc758b6e2ce0e2e3eb2 | [
"Apache-2.0"
] | permissive | lithces/tpps | d36c98f3554123a82524f96366fdb419606c9a85 | 0bdf84f37c91023ffbe06146efa1889d9a1e9f9b | refs/heads/master | 2023-08-23T13:24:02.128993 | 2021-11-05T22:35:48 | 2021-11-05T22:35:48 | 425,101,008 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,777 | py | import abc
import torch as th
import torch.nn as nn
from typing import Dict, Optional, Tuple
from tpp.utils.events import Events
class Process(nn.Module):
def __init__(self, name: str, marks: Optional[int] = 1, **kwargs):
"""A parametric process.
Args:
name: The name of the process.
... | [
"lithium7456@gmail.com"
] | lithium7456@gmail.com |
52f9e019ca59ad581223697ba63f672d9198b805 | 87390bcd42b1b56a3c6235f5a4a304386b8be963 | /src/evaluation.py | 87776a238d1308b23102bb669ec461c1c7896584 | [] | no_license | emalgorithm/rna-design | d195a79c829e2e9d9beaeea5e177704ad53ab380 | aec77a18abe4850958d6736ec185a6f8cbfdf20c | refs/heads/master | 2020-04-22T10:24:14.593635 | 2019-05-11T22:11:23 | 2019-05-11T22:11:23 | 170,304,409 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 11,239 | py | from sklearn.metrics import hamming_loss
import numpy as np
import torch
import RNA
from src.data_util.data_processing import one_hot_embed_sequence, prepare_sequences, decode_sequence
from src.data_util.data_constants import word_to_ix, tag_to_ix, ix_to_word, ix_to_tag
from sklearn.metrics import accuracy_score, f1_sc... | [
"emanuele.rossi1909@gmail.com"
] | emanuele.rossi1909@gmail.com |
ec66bc0543ba3c33f0203126bbdc78da3258cd28 | 38d8d417c3ba38b11fd33d82acb3899c65342b23 | /Actividad4.py | eb27e34bdf92e80f982573b237c74ff7212c60b7 | [] | no_license | kevinalx/PythonTkinter | 41a11ef025b4ddc2f8753dc053c20bad87d2fb58 | a9fbdf4d2b892e475d817ecd6b6eabece5de2bea | refs/heads/master | 2022-12-04T14:22:40.942465 | 2020-08-26T03:22:08 | 2020-08-26T03:22:08 | 290,383,794 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,610 | py | #Un alumno desea saber cual será su calificación final en la materia de Algoritmos. Dicha
#calificación se compone de los siguientes porcentajes:
#55% del promedio de sus tres calificaciones parciales.
#30% de la calificación del examen final.
#15% de la calificación de un trabajo final.
#Leer c1, c2, c3, ef, tf
#prom ... | [
"kevintorres1208@gmail.com"
] | kevintorres1208@gmail.com |
566469cd1b76d202192417ecad22a99c3b57c032 | 357891fd990f30bf7e7a4e5bca6f8e74ed288e07 | /seleniumdemo.py | 3f93e8691b5f75a7fa6741a1e962e8f121d4a238 | [] | no_license | shuo502/seleniumdemo | 984b93b3dc7e32ae1ba6214a69f304e5f958d447 | 9805d0f80fec7863dec223f651bac0f6d665638a | refs/heads/master | 2020-06-24T12:24:53.819201 | 2019-08-15T10:36:47 | 2019-08-15T10:36:47 | 198,962,010 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 12,403 | py | # -*- coding: utf-8 -*-
# @Time : 2019/7/25 18:36
# @Author : Yo
# @Email : shuo502@163.com
# @File : seleniumdemo.py
# @Software: PyCharm
# @models: ..
# @function: ...
# @Git: https://gitee.com/m7n9/PyCharm.git
# @Edit: yo
# path = "/chromedriver"
# driver = webdriver.Chrome(path)
# driver=driver.ChromeOp... | [
"shuo502@163.com"
] | shuo502@163.com |
b1c393d0df4595e8737420b0882fdf0ac70e062d | 3aaa3640b929ac46dc7a4b9fada59be615079576 | /demos/helloworld/helloworld.py | 06eac9290f968b6e70163a72e50faebe22da1aeb | [
"Apache-2.0"
] | permissive | joobih/tornado_redis_yield | f840c44362cc57b0cd4fd813b9875b3a29369381 | 9c2a81a87bbbbca50b57d23029e4b78192bedf17 | refs/heads/master | 2021-05-25T09:14:49.990681 | 2018-04-02T08:53:23 | 2018-04-02T08:53:23 | 126,953,130 | 1 | 1 | Apache-2.0 | 2021-04-20T17:19:10 | 2018-03-27T08:19:46 | Python | UTF-8 | Python | false | false | 1,222 | py | #!/usr/bin/env python
#
# Copyright 2009 Facebook
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... | [
"1006536507@qq.com"
] | 1006536507@qq.com |
d769330af821d7a74f0e733e79db3212a3b06fbd | 85f95f90f0512d7771f4d3a4a7e949182d72f5b4 | /jumble_solve2.py | 37b406f81d9517cd9bb166dfb44754df267f5b84 | [] | no_license | Mattmlm/jumblesolve | b35ca25dcc650265fb2dd089603e79ab10ad1e52 | ba870c42c5249b76d011ca31b154f592d8233c04 | refs/heads/master | 2016-09-05T19:09:53.756483 | 2014-02-18T20:19:28 | 2014-02-18T20:19:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,001 | py | # jumble_solve2.py
import sys
def prefix_tree(filename):
dictionary_tree = dict()
fin = open(filename)
for line in fin:
word = line.strip()
if word[0] in dictionary_tree.keys():
updated_list = dictionary_tree[word[0]] + [word]
dictionary_tree[word[0]] = updated_list
else:
dictionary_tree[word[0]] = ... | [
"matthew.l.mo@gmail.com"
] | matthew.l.mo@gmail.com |
c03a4aa677a7ee28e15c3cdb81e2a3b9d4b0830f | bfc551b280079889255383ebf0fede2a5a724198 | /bin/django-admin.py | b6c7819ebd994a7e6f06b38970ebe032a73f5e76 | [] | no_license | Wolf4091/AdvertisingMat-site | ebf1b602fdbf6bfefdb2e1a82b9d8642b1ae2d1c | c26798dcb24309a13f280bbdcdddcba8198b00b4 | refs/heads/master | 2020-03-18T18:33:22.459061 | 2018-06-11T06:52:21 | 2018-06-11T06:52:21 | 135,100,853 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 158 | py | #!/home/ian/pythonprojs/selfsite/MySite/bin/python2
from django.core import management
if __name__ == "__main__":
management.execute_from_command_line()
| [
"iclark@idevops.io"
] | iclark@idevops.io |
855e7d3b3e1a062a0a4d29cccd95979c6e39f28d | cd85cac1855e533f47d91735b072a640e4d032c9 | /blog/migrations/0002_comment.py | d111b7f248fb9b54d2d06623bede6d5b676d8ef4 | [] | no_license | Rem1219/Sunduk | 154fc52d35f1921a2607a08bacc4eb24064d44bd | 4f1bd9224a53432bdc7036a12819e571cd05d0cb | refs/heads/master | 2021-01-17T23:21:25.107415 | 2016-06-24T18:17:57 | 2016-06-24T18:17:57 | 61,186,370 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 969 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.9 on 2016-06-24 16:10
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
dependencies = [
('blog', '0001_initial'),
]
... | [
"rem12191@gmail.com"
] | rem12191@gmail.com |
a4f838f0cb967caac7da1085f97a7e03189b5fa5 | 4fbe62e09f468b6ad413efd5f121d6b26d367d60 | /controller/helper.py | 5caff02d1f68bae012c8ffd8bf25bad0a943fd51 | [] | no_license | ztao/dmgae | d331da0f30b6e9ca36581b8349e9c98bdf02b06d | 6629bf2eb0fa2bbcd473031b32f27733995d8295 | refs/heads/master | 2021-01-24T06:39:10.283052 | 2013-08-12T19:13:06 | 2013-08-12T19:13:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,335 | py | import json
from ast import literal_eval
from model.event import EventModel, Activity, Relation, Place
def json2model(event_obj):
print event_obj
event_obj = json.loads(event_obj.replace('\r\n', '\\r\\n'))
id = int(event_obj["ID"])
event = EventModel.query(EventModel.eid == id).get()
if not event:... | [
"ziwang.tao@gmail.com"
] | ziwang.tao@gmail.com |
e7ac3e943d33f282eac4d0e7a3b4aac178f27edb | f2eb2e5bbb2b7c8d09094ea92105fc119956ab2d | /category/migrations/0001_initial.py | fb781b98ff210712a4765ed6244264712ec62e47 | [] | no_license | MichangaVictor/greatkart | ada27fcec3e44efe2322b7b487138f8045e5eeae | 3d35a884fe25fd67382827d174fa2477a382225d | refs/heads/main | 2023-09-01T07:08:19.158330 | 2021-09-25T11:14:21 | 2021-09-25T11:14:21 | 407,810,786 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 886 | py | # Generated by Django 3.1 on 2021-09-17 10:46
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Category',
fields=[
('id', models.AutoField(a... | [
"onyango.vic@yandex.com"
] | onyango.vic@yandex.com |
7e043518a2f136a4085f8d4d13121670413127d1 | 298f0799a6c7ff0ae2ed4994160b22527c0e2a3d | /cars.py | 4d665eed95666238b833bc8a15916f9c16ec75c3 | [] | no_license | marinacruzjordao/Python_Rent_A_Car | 2d90155eb7eb2ac34d66de4aee4e721aada534e7 | 5b82642d66d46ecac66d8a861876d9420288f43a | refs/heads/master | 2023-03-07T02:47:51.237946 | 2021-02-20T15:14:24 | 2021-02-20T15:14:24 | 338,102,134 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,456 | py |
import sqlite3
import images
from PySimpleGUI import PySimpleGUI as sg
class RentACar:
def __init__(self):
#layout
sg.theme('Reddit')
def wind_initial(self):
self.layout=[
[sg.Button(image_data=images.imge)],
[sg.Button('Cars Catalogue',size=(20,... | [
"marinacruzjordao@gmail.com"
] | marinacruzjordao@gmail.com |
e92bb7009b48dbf53be81f216d049bab6787cdce | 5d61565651b7ba5fa8fade3313a5e82fca8b6686 | /login/migrations/0003_auto_20190709_2213.py | 58c72a12c002fd6586fd9fbdb94b2ed1aaacc6c2 | [] | no_license | lonelyxmas/ISMS | d597b00072bfa77907875f575b866fbb1fb53295 | 08c5e2f3518fc639cf1a1f2869f4b2f3ae58e306 | refs/heads/master | 2023-08-14T12:02:59.001215 | 2021-03-22T03:34:58 | 2021-03-22T03:34:58 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 679 | py | # Generated by Django 2.1.4 on 2019-07-09 14:13
from django.db import migrations, models
import uuid
class Migration(migrations.Migration):
dependencies = [
('login', '0002_auto_20190704_0826'),
]
operations = [
migrations.AlterField(
model_name='user',
name='FID... | [
"11325818@qq.com"
] | 11325818@qq.com |
f5dd2bb68d941f22a8ece354d5ebe4a7ff628fca | 736250d9d14552c5fa0aca25b25d9c8a28fcd1a0 | /mtmpro/mtmapp/migrations/0001_initial.py | 42368fcde0eff7c119ef4b9236f3139dcdb96da7 | [] | no_license | maheswatapradhan/feedback | 57f052a2082902cb8a72b474e0b863b7a00d1c9c | 31c7dcb113a38e29b3a56481fcb9ae2fce7d61a2 | refs/heads/master | 2020-09-15T23:42:32.041306 | 2019-11-23T12:54:25 | 2019-11-23T12:54:25 | 223,585,900 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,254 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.9 on 2019-09-16 11:09
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Course',
... | [
"test@test.com"
] | test@test.com |
edf06fc59a34181ad65492c202910cb9eb9876f2 | bf0f5fd1b11e988767c9493a7d3b2e97da457ca2 | /uniq_samples/code_samples/CommandRunner/src/cmd_runner.py | b96c9a2231c0201c424126c59ce6aa8bedffd834 | [
"Apache-2.0"
] | permissive | jorschul/dnac-samples-aradford | 6fe818c93c5de49fa24b4bdaa4508d47802333e2 | 8d6ab78c1b00904beba8a5f433b92df67a61f150 | refs/heads/master | 2021-09-15T19:06:19.311079 | 2018-06-08T20:26:43 | 2018-06-08T20:26:43 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,135 | py | #!/usr/bin/env python
import ast
import os, sys
sys.path.append(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))))
from login import login
import json
import jtextfsm as textfsm
from argparse import ArgumentParser
def run_command(dnac, devs, cmds):
if cmds is [None]:
cmds =["... | [
"aradford@cisco.com"
] | aradford@cisco.com |
276977c5c0f0c8513d7f9b377f884740796791cd | 34876b55af2c25629a7617a329f209de6c9f274f | /env/lib/python3.6/functools.py | 8559f5b0239570c6be959bba2b19de7ea3dd3b89 | [] | no_license | Fastwriter/django-rest-framework-tutorial | 350a239b85e31ebd7e3f0946e7841d1aa04fe165 | 72429f51d645d6c2357ae8107bb6021ef2cb5a9e | refs/heads/master | 2020-04-11T13:08:53.681228 | 2018-12-14T15:40:45 | 2018-12-14T15:40:45 | 161,805,236 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 57 | py | /Users/demeuovdaulet/anaconda3/lib/python3.6/functools.py | [
"demeuov.daulet.nis.ura@gmail.com"
] | demeuov.daulet.nis.ura@gmail.com |
6ef3b6ebd24d6353ea1c4341f997729f76f1d7e8 | 2b2cabd2e436ec5350717bf4f2a798c20cf09efb | /Evaluation/textgrid_2_textfile.py | 65f0b3a006da939e3ce5698d590777aa4337cd6f | [] | no_license | miastra/SwedishForcedAligner | 1ac9db7a33a6c639f1249acbe57f48f312d84938 | 6fb14bd480f67d6e674579d7541d427c2a1ea3b9 | refs/heads/master | 2021-04-06T01:08:32.019060 | 2018-04-06T07:34:14 | 2018-04-06T07:34:14 | 125,353,297 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,626 | py | import os
import re
# Extract labels and start and end times from a TextGrid
def extract_word_alignments(tg_path):
textgrid = open(tg_path)
lines = textgrid.readlines()
intervaltier_idx = []
for i in range(0, len(lines)):
if re.search('IntervalTier', lines[i]):
intervaltier_idx.appe... | [
"miastra@kth.se"
] | miastra@kth.se |
29494c29a43d43c4bf909ceb1816cc265b8acc9c | cffabf7d1a1583fe6987feba508d4c2e8e5637df | /src/us-co/scrape-statcode-us-co | e39418dd5e1333e9ca5b22d0b76288301cd0bf0c | [
"CC0-1.0"
] | permissive | esbranson/openlaw | 62e4b486a84b0156a25728fd4464bd981ad77c2e | d3fd06b53f7bc5917fc91527ca6ad717e739e667 | refs/heads/master | 2022-12-11T08:37:19.713993 | 2022-04-29T17:56:09 | 2022-04-29T17:56:09 | 17,883,540 | 17 | 6 | null | null | null | null | UTF-8 | Python | false | false | 37,653 | #! /usr/bin/python3 -uW all
# -*- coding: utf-8 -*-
usage="""
scrape-statcode-us-co - convert the Colorado Revised Statutes into Akoma Ntoso
See <https://en.wikipedia.org/wiki/Colorado_Revised_Statutes>. Given titles as
RTF files, in order, this will output them as an Akoma Ntoso XML file.
Usage: scrape-statcode-us-... | [
"esbranson@gmail.com"
] | esbranson@gmail.com | |
9d7639d189d421797740d682aac51312abee9e92 | d554b1aa8b70fddf81da8988b4aaa43788fede88 | /5 - Notebooks e Data/1 - Análises numéricas/Arquivos David/Atualizados/logDicas-master/data/2019-1/225/users/4011/codes/1745_1531.py | f673af6f93026f7831e6b2d8cc72542a9d884f67 | [] | no_license | JosephLevinthal/Research-projects | a3bc3ca3b09faad16f5cce5949a2279cf14742ba | 60d5fd6eb864a5181f4321e7a992812f3c2139f9 | refs/heads/master | 2022-07-31T06:43:02.686109 | 2020-05-23T00:24:26 | 2020-05-23T00:24:26 | 266,199,309 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 244 | py | from math import*
x = eval(input("radiano: "))
k = int(input("Quantidade de termos da serie: "))
n = 0
soma =
while(n < k):
n = n + 1
sinal = (x**(2 + 2*n)/factorial(2*n))
sinal = - sinal
soma = sinal + sinal
print(round(serie, 10)) | [
"jvlo@icomp.ufam.edu.br"
] | jvlo@icomp.ufam.edu.br |
0a016c76968b4e068f1c591451a39f1691413058 | 1ffe0a2e874eb48c8f6d41d353fc43ec9652372e | /SScriptCompiler/src/conf/SMpu9250.py | 6e43b4c00ad171995d823e5c9423452ae3541f5d | [
"MIT"
] | permissive | alklasil/SScript | 77c03acef77fba0894f085becbe2f5670e3e8b50 | de4481bf96e79b9ee157e266ea9fe8b1bfb3701e | refs/heads/master | 2021-03-27T11:30:21.073203 | 2018-05-25T16:40:56 | 2018-05-25T16:40:56 | 122,749,015 | 0 | 0 | MIT | 2018-03-28T19:44:23 | 2018-02-24T14:47:26 | Python | UTF-8 | Python | false | false | 2,452 | py | """Helper module for accessing functions."""
from src.SFunction import SFunction
from src.SVariable import SVariable
class SMpu9250:
"""Standard functions class for SScript."""
def __init__(self, useVariables=True):
self.useVariables = useVariables
def getFunctions(self):
""""Return a lis... | [
"alklasil@student.oulu.fi"
] | alklasil@student.oulu.fi |
94fe269b557ee98918bd55d5831a8de7b0bca7e3 | 9f0c4fdcebf2bdf83765841b565414c0d0db5038 | /8.3 - Emparelhamento Bipartido (Ponderado)/EmparelhamentoBipartidoPonderado.py | 77f6246e9d5d275268168a03be3f8b47227adfce | [] | no_license | gabrielgpavan2/Algoritmo-de-Grafos | b528cc1ba826db99c4ad5b4326ecd728f7ad2629 | 162a42dccb1dc6355441e005705f56e55746269b | refs/heads/master | 2020-04-30T02:26:36.639257 | 2019-03-19T16:57:57 | 2019-03-19T16:57:57 | 176,559,680 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,353 | py | # -*- coding: utf-8 -*-
# Autoria:
# Fabiano S. Oliveira
# Paulo E. D. Pinto
#
# A correção e a análise de complexidade deste programa
# encontram-se no livro
#
# Teoria Computacional de Grafos, Elsevier, 2018
# Jayme L. Szwarcfiter
#Algoritmo 8.3: Emparelhamento Bipartido (Ponderado)
... | [
"noreply@github.com"
] | gabrielgpavan2.noreply@github.com |
db9503f8d4917677b10f97a48c4f912d05a9290a | acc244c97a943d8e2074339afa1bff1274ae4cfc | /CGATPipelines/PipelineMedip.py | 3f12a921f960aaedb163d725a83b325930f8e7fb | [] | no_license | eromasko/cgat | 00114f4c95b439ba6595ddf2092d1a3307347401 | d82d197f3913b8d65b656c0b205ca48854fdb2a6 | refs/heads/master | 2021-01-17T09:37:17.168278 | 2015-02-20T09:03:31 | 2015-02-20T09:03:31 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,824 | py | '''
PipelineMedip.py - tasks associated with MedipSeq analysis
==========================================================
'''
import re
import os
import collections
import sqlite3
import CGAT.Experiment as E
import CGAT.Pipeline as P
import CGAT.Database as Database
import CGAT.IOTools as IOTools
from rpy2.robject... | [
"andreas.heger@gmail.com"
] | andreas.heger@gmail.com |
fd7b776d413ae841b4dd9e59749cbab4d90619df | 1d56e929916154812e76583337fd14ba91dd5b91 | /Seqstat.py | 4cd5ce8699d841e105c407cffbf058a387dff632 | [
"MIT"
] | permissive | Archieyoung/pySeqkit | 60a9565ff8d4989998ca83b234d4d85e527d9d18 | 27e575bea3542919c9baa2cb4155559157b44199 | refs/heads/master | 2020-03-18T03:29:33.529571 | 2018-04-17T13:30:19 | 2018-04-17T13:30:19 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,102 | py | #!/usr/bin/env python
"""
This script is used to statistics on a list of fastq files
copyright@fanjunpeng (jpfan@whu.edu.cn)
2018/1/15: init by fanjunpeng
"""
import argparse
from multiprocessing import Pool
from FastqReader import open_fastq
from FastaReader import open_fasta
def get_length(filename, index, min_l... | [
"schooiboy@qq.com"
] | schooiboy@qq.com |
6ee99c0fb1e4c9f4f6261a6f986415fe77cd8534 | 113641697bd7db550eed62a6f2194e12dd2125af | /Tests/AddBookTests.py | 371ed95c50f9f5fc74e211e1a07fe988e371e412 | [] | no_license | mohabayman/BookStore-PythonAutomation | 79debd340cc733dbdefc129f692ff54e30a0da2e | 0093d380541833f367db1fc876cc5039b7f1c348 | refs/heads/master | 2020-12-02T06:45:50.603637 | 2018-12-18T17:25:56 | 2018-12-18T17:25:56 | 96,895,186 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,034 | py | from PageObjects.HomePage import HomePage
from PageObjects.LoginPage import LoginPage
from PageObjects.AdminPage import AdminPage
from PageObjects.BooksPage import BooksPage
from PageObjects.AddBookPage import AddBookPage
from Utils.DriverFactory import DriverFactory
from time import sleep
class AddBookTests... | [
"seltahan@integrant.com"
] | seltahan@integrant.com |
9fa1ef1faa86b56dd8b2d4ab8a53d48258f7bed6 | b45fc189b5dc879d179a7f90c450fb08f661e686 | /convertNBG.py | 2168cd7804a5b4815d72ee7f74ff7cbac1e14984 | [] | no_license | eigeneko/ATF | 30096572ac7cbb442acbc5717085fec7611f53e5 | 8e97f5f250dac50f01ec81b551f3a9d391406a9d | refs/heads/master | 2020-04-15T04:43:35.692435 | 2019-01-07T07:40:31 | 2019-01-07T07:40:31 | 158,235,179 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 515 | py | import os
import subprocess
import argparse
from utils import autoNBG
if __name__ == "__main__":
parser = argparse.ArgumentParser(description='FreeEnCal Outfile Compare')
parser.add_argument(dest='task', metavar='task', nargs=1, help='Input the name of logic fragments you want to compare')
... | [
"observelily@gmail.com"
] | observelily@gmail.com |
c1e309ba4de5e590737e4abc08092bc2eecb0f47 | 569906ef0204e7de0947b3a17be20145da6c325a | /exampleCode/heatConduction3DUnsteady.py | f479a9750c26843f3f6734ebf56c440ed1fce9d6 | [] | no_license | amikkonen/NumericalTechniquesForProcessModelling | 1a28678f75ac4d7b7c8419e963f39fffbe721e0b | d9a31f09f1e01f8be5dddf3b8e3ebc2052c5a055 | refs/heads/master | 2023-02-08T16:50:37.693290 | 2023-02-05T16:26:06 | 2023-02-05T16:26:06 | 116,688,697 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 11,514 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
A course example of unsteady 3D heat conduction.
Constant propersties, contant temperature boundary, zero gradient (insulated)
boundary, transient.
NOTE: USE OF SPARSE MATRIXES IN MatrixA
Created on Sat Jan 13 13:10:11 2018
@author: Antti Mikkonen, a.mikkonen@iki.... | [
"a.mikkonen@iki.fi"
] | a.mikkonen@iki.fi |
966fdf7eb6a1eec1702eaaaca18fe580ed0748ef | a7870a13babdcac3b680980edb516591a4a4fb07 | /shared/inspect.py | 70ee76c020289fa67c6b547a213a6657bad2835e | [] | no_license | mustafaghali/clouds_dist | 2cc6da2fcbfc1c3c61005ea8316ae31208879f5b | 57d5be4e15c3d4171fda7a58832225eb289f3b8c | refs/heads/master | 2022-04-08T19:00:37.981332 | 2020-02-10T15:12:50 | 2020-02-10T15:12:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,519 | py | #!/usr/bin/env python
"""
Utilities to Study Model Results
"""
from src.data import get_loader, get_transforms
from src.stats import get_stats
from src.utils import get_opts
import argparse
import numpy as np
import pandas
import pathlib
import seaborn as sns
import src.gan as gan
import torch
def infer(model, loader... | [
"sankaran.kris@gmail.com"
] | sankaran.kris@gmail.com |
2d493828a291e0d20a0b71cb7adc4a216c1109a8 | a83d577557b0d1cb348560879468d0563ababa11 | /ecommerce/forms.py | 664bf5947e9b5a53e83e60dd04b854e800bb70c3 | [] | no_license | MaazAr/Mark-Django | 7856edf2fb8cefd4158daa9a3376823101eb3731 | e8ae75a05a4e0975e704de7412099a130602f5fb | refs/heads/master | 2023-01-05T18:17:43.804007 | 2020-11-02T13:40:11 | 2020-11-02T13:40:11 | 309,380,520 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 480 | py | from django import forms
from django.contrib.auth import get_user_model
User = get_user_model()
class ContactForm(forms.Form):
fullname = forms.CharField(widget=forms.TextInput(attrs={"class": "form-control", "placeholder": "your full name"}))
email = forms.EmailField(widget=forms.EmailInput(attrs={"class": ... | [
"maazabdul@ymail.com"
] | maazabdul@ymail.com |
beb8c8d74b03478d2ab23ab25ba45c5ef6828866 | 63adbb3123e8cdc9afa46075a16e9ec45bba55c9 | /assignment9.py | c87338f65e9e121b786fe7596d56544cf8352142 | [] | no_license | ranveer1691/python | db1fd275721158d72633fa9d22785f35b2e33ec6 | ceafa13494f9cee85ec72e64a0c7dab504d80c7d | refs/heads/master | 2020-03-26T17:13:47.282600 | 2018-09-07T18:55:27 | 2018-09-07T18:55:27 | 145,149,187 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 731 | py | # ASSIGNMENT-9
#Question-1
try:
a = 3
a < 4
a = a / (a - 3)
except ZeroDivisionError as msg:
print('wrong', msg)
#Queation-2
try:
l = [1, 2, 3]
print(l[3])
except IndexError as msg:
print('something went wrong', msg)
#Question-3
'''
NameError:hi there
'''
#Question-4
... | [
"noreply@github.com"
] | ranveer1691.noreply@github.com |
ac7445a68c219f3dd9d06e99c7644d3df11f37fd | 43fa572169fb7f07e360afcbdde393abc0508b14 | /GOLsparseMatrix.py | 876f998a7e04faa0e3e52f583ddf5873cd6ce92b | [] | no_license | ankitamishra1998/GameofLife | c445674f4d3cd56e8eb6c040da5ff0a001e329e8 | 8732ab05569da63344ca3df071e0c9b82fbf44f8 | refs/heads/master | 2021-05-10T13:46:43.098566 | 2018-01-25T05:30:17 | 2018-01-25T05:30:17 | 118,489,184 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,154 | py | print ("Game of Life")
import sys
import time
import tkinter
from tkinter import *
import numpy as np
from scipy.sparse import csr_matrix
def count(arr, tup, d, x):
if tup[0] >= 0 and tup[0] < d and tup[1] >= 0 and tup[1] < d :
if arr[tup] == 1:
x += 1
return x
##row = [1,0,1,2,2]
##col =... | [
"ankitamishra1998@gmail.com"
] | ankitamishra1998@gmail.com |
44f99ab506d13bdff1cbf6562817d69a237ad312 | 55fced1ccebe4e517b75b2efffce21ed908b9fbc | /getVeryCode.py | a3652fe4320d4a282ef7631cb18787504398aa48 | [] | no_license | Jashin-Hitagi/cpquery-spider | 353373f74cbdce436045c9a5ac7ea31b29091958 | fda0230a4bc577f307b06b441aa7cc8de2edb48d | refs/heads/master | 2023-07-06T23:36:03.265782 | 2021-08-12T02:40:04 | 2021-08-12T02:40:04 | 395,161,675 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,384 | py | import json
from aip import AipOcr
import re
def binarizing(img): # input: gray image
threshold = 200
pixdata = img.load()
w, h = img.size
for y in range(h):
for x in range(w):
if pixdata[x, y] < threshold:
pixdata[x, y] = 0
else:
pixdat... | [
"wh775349543@gmail.com"
] | wh775349543@gmail.com |
5bf3b709d650e67287d4bfbbb1887821906461cd | fd1b7ffd30143dc0aa0918cab6107f1013b8c4ea | /series/migrations/0005_auto__add_language__add_userserial.py | c48926f92a8931ecabc44c70ec119af1855ae306 | [] | no_license | apelliciari/watch-the-series | 4861ea9a063a7e6cda25feaf0f9a4a996cca20a7 | cec2b92edd1439f81a529685301bdfed2eb991ee | refs/heads/master | 2021-01-22T07:10:38.818076 | 2013-05-16T16:25:29 | 2013-05-16T16:25:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,929 | py | # -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'Language'
db.create_table(u'language', (
(u'id', self.gf('django.db.models.field... | [
"isac.newton@gmail.com"
] | isac.newton@gmail.com |
bd7ff72f18a4bbea1188117dfed8fe4b78f612df | 28a9db1536877930b7376cb66d18fafa2d01a1fe | /driftproject/routes.py | f2a77620e1181d6ab613806758a0e81eb6155150 | [] | no_license | reinaldo1526/drftprojectweek4hw | c3b409f6c4b8fb26e6620cbffce823ebd7f07d5b | 76b854b4ef59971dce251c4f148ac69552ff7f6c | refs/heads/master | 2020-12-10T21:15:21.404322 | 2020-01-13T23:10:52 | 2020-01-13T23:10:52 | 233,712,593 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,305 | py | from driftproject import app, db
from flask import render_template, request, redirect, url_for
from driftproject.forms import SignupForm,LoginForm,PostForm,CheckForm
from werkzeug.security import check_password_hash
from flask_login import login_user, current_user,login_required
from driftproject.models import User... | [
"Juny@reinaldos-MacBook-Air.local"
] | Juny@reinaldos-MacBook-Air.local |
7a821db6e73317f1eda8b4668d934a936b9bc173 | efb3d0c2f9fcc5be631323e31f4b8dfcdd0ab676 | /compiler/tests/14_replica_column_test.py | c8d50a539879db74ee9e9e7d09880960e2cc6270 | [
"BSD-3-Clause"
] | permissive | kanokkorn/OpenRAM | 5f30beb35e3c161fbf0d233b59fe7d7805d3c348 | 3a9693e37fd3afbd52001839966b0f2811fb4ccd | refs/heads/master | 2022-06-03T12:53:47.750245 | 2022-05-27T15:53:05 | 2022-05-27T15:53:05 | 189,780,330 | 0 | 0 | BSD-3-Clause | 2021-04-07T06:49:08 | 2019-06-01T21:47:50 | Python | UTF-8 | Python | false | false | 1,291 | py | #!/usr/bin/env python3
# See LICENSE for licensing information.
#
# Copyright (c) 2016-2021 Regents of the University of California
# All rights reserved.
#
import unittest
from testutils import *
import sys, os
sys.path.append(os.getenv("OPENRAM_HOME"))
import globals
from globals import OPTS
from sram_factory import ... | [
"mrg@ucsc.edu"
] | mrg@ucsc.edu |
278c8f0ddb3c42fcfe4c7fc1b142419697180d07 | dd81260c780c3697bb98b5e93f268eed5ebbed71 | /mysite/settings.py | 185358c81c7684816b6fe53f73df0c3437efc548 | [] | no_license | josecd85/my-first-blog | 08a00adae0dd6cda047b09d53a56d92430e24e13 | 5f24ae1cfbc94e6d5f4a19875560381faeea1f0f | refs/heads/master | 2021-06-25T13:28:27.968413 | 2020-11-13T12:15:06 | 2020-11-13T12:15:06 | 169,381,371 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,442 | py | """
Django settings for mysite project.
Generated by 'django-admin startproject' using Django 2.0.10.
For more information on this file, see
https://docs.djangoproject.com/en/2.0/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/2.0/ref/settings/
"""
import os
#... | [
"joscabdor@gmail.com"
] | joscabdor@gmail.com |
7b205e91d3d2e6bea20b6b48b78dc7bf2b245db8 | c908dacdc0006e247aa529dddb98bc1d67fbf7c8 | /user.py | c2f9669f15bbddd02c3b88046a27e25547ba194d | [] | no_license | TomeCirun/flask_blog | 40e3bd041fd7ba376c181073c92e19f296aca928 | de34ac14e2e3e2044e3f327e288eefadf34b7faf | refs/heads/main | 2023-03-05T13:51:37.335673 | 2021-02-17T12:04:00 | 2021-02-17T12:04:00 | 339,709,097 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 232 | py |
class User():
def __init__(self,id,username,password):
self.id = id
self.username = username
self.password = password
def __str__(self):
return f'User Id: {self.id}' | [
"cirun@live.com"
] | cirun@live.com |
29a430dbc328601d477386f8cabc243e74005619 | 5df9c5d9f84198f71dc4d6395f60f9735745ac74 | /una_sym_util.py | d2ef2ebd352cd6f4319c2c3e558de5c2ecdf8cbf | [] | no_license | natteruw/crystal_pymolscripts | 545843209397ff6668666df5c4a538e85761499a | 19cb06dd247a0c5727eca6a6c6408f75ed192101 | refs/heads/master | 2021-01-19T11:48:39.268407 | 2018-03-01T22:15:09 | 2018-03-01T22:15:09 | 87,993,264 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 20,974 | py | # -*- mode:python;tab-width:2;indent-tabs-mode:t;show-trailing-whitespace:t;rm-trailing-spaces:t -*-
import sys,os,inspect,functools
newpath = os.path.dirname(inspect.getfile(inspect.currentframe())) # script directory
if not newpath in sys.path: sys.path.append(newpath)
import string,re,gzip,itertools
import collectio... | [
"natteruw@sill.dhcp.baker"
] | natteruw@sill.dhcp.baker |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.