blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 281 | content_id stringlengths 40 40 | detected_licenses listlengths 0 57 | license_type stringclasses 2
values | repo_name stringlengths 6 116 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 313
values | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 18.2k 668M ⌀ | star_events_count int64 0 102k | fork_events_count int64 0 38.2k | gha_license_id stringclasses 17
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 107
values | src_encoding stringclasses 20
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 4 6.02M | extension stringclasses 78
values | content stringlengths 2 6.02M | authors listlengths 1 1 | author stringlengths 0 175 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
fb125fa8acb5c1f5dfb931330794b6f3a4afe128 | c8539e19bfc783c41f76ab23cdccdab919c341b4 | /changes-for-FreeROI/froi/widgets/surfaceview.py | 9d4c6a9d9e1ac9beee1354f6b56c78fa2d655a61 | [] | no_license | sunshineDrizzle/backups-for-forked-repo | 2dbf4a0750aef9d9009f6b921198fecb35ead7c7 | 8f905a6f53b6189e91f7925ac950f1e94f478169 | refs/heads/master | 2020-07-26T20:34:51.247940 | 2016-11-24T03:46:28 | 2016-11-24T03:46:28 | 73,715,560 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,230 | py | import os
import sys
import sip
from traits.api import HasTraits, Instance
from traitsui.api import View, Item
from tvtk.api import tvtk
from PyQt4.QtGui import *
from mayavi.core.ui.api import SceneEditor, MayaviScene, MlabSceneModel
from mayavi import mlab
import numpy as np
from treemodel import TreeModel
# Help... | [
"954830460@qq.com"
] | 954830460@qq.com |
ed7dbfe8a4d867bb7f31bb99aa021aed9a7b1869 | 89594edf581b8512d262768fb4c3e0ad001996a9 | /colibris/shortcuts.py | 458659843d933d06ecd650c70b38b096a2de2902 | [
"BSD-3-Clause"
] | permissive | colibris-framework/colibris | b8524ac31a100c987dcbb5954b23f8c309370be3 | 9655016637888c480f49f92711caa6088013e442 | refs/heads/master | 2023-08-08T11:45:36.191451 | 2023-08-07T07:15:32 | 2023-08-07T07:15:32 | 193,250,040 | 7 | 2 | BSD-3-Clause | 2021-09-12T21:52:07 | 2019-06-22T15:35:53 | Python | UTF-8 | Python | false | false | 1,001 | py |
from aiohttp.web import Response
from colibris import api
from colibris import template
def get_object_or_404(model, pk, select_related=None):
select_related = set(select_related or ())
try:
q = model.select(model, *select_related).where(model._meta.primary_key == pk)
for m in select_relate... | [
"ccrisan@gmail.com"
] | ccrisan@gmail.com |
207107255f53ed6ae3eef426412a7e55ab125751 | 3f0720a59fb89d5a35bbf765a8f8f077a1b6eb35 | /QuickSort.py | bdde6701746a6870f7ec68beb65b6a121661b5fd | [] | no_license | illium6/NIT-Testing | c24048b0a5fd87b3a70ffbb76c786b26054116fd | d46f75c1a5ee7a6e8efda4b0e9337088b5a4a1bf | refs/heads/master | 2020-04-27T12:47:40.403205 | 2019-03-07T16:39:07 | 2019-03-07T16:39:07 | 174,344,647 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,155 | py | import random
def reversed_quick_sort(Array, start_point, ArrayLen_m1):
if start_point >= ArrayLen_m1:
return
else:
q = random.choice(Array[start_point:ArrayLen_m1 + 1])
i = start_point
j = ArrayLen_m1
while i <= j:
while Array[i] > q:
... | [
"noreply@github.com"
] | noreply@github.com |
25026cdba2e348635313075c18f8377af57abdc8 | 764fb20685a52e19d01782ff0da6c1a61bd34da8 | /speechAPI.py | 6983981d69cd0da2057ff2cdccffd98c9248e315 | [] | no_license | aksh98md/Jason | 367134f5b592daa2791d4e86278371be2a66ac1b | b2f662f29df0c488aa8aa1778ae33b0e7bf40c72 | refs/heads/master | 2020-03-22T13:14:44.962766 | 2018-04-15T17:54:32 | 2018-04-15T17:54:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,081 | py | import pyaudio
import wave
import audioop
from collections import deque
import os, sys
import time
import math
import requests
import http.client
import uuid
import json
LANG_CODE = 'zh-TW' # Language to use
# Microphone stream config.
CHUNK = 1024 # CHUNKS of bytes to read each time from mic
FORMAT = pyaudio... | [
"b04901112@ntu.edu.tw"
] | b04901112@ntu.edu.tw |
fcbc1a2c3dce5ff711033e550d925ddd94dee24a | 477630571cef77ad3bf5f9d06890bab39c3abad9 | /backend/posts/urls.py | 2721d73eb674691ea165d87bd3ad1e5cf3eb787d | [] | no_license | lumenwrites/webacademy | 52da663a36a2c403ac1ec97ba2687671f28a7c3f | 4f8bdd4a15b781d7d0a1a7ae312914eaa0d1bd8d | refs/heads/master | 2021-06-11T09:29:00.778011 | 2017-02-24T16:38:51 | 2017-02-24T16:38:51 | 82,233,069 | 4 | 0 | null | null | null | null | UTF-8 | Python | false | false | 736 | py | from django.conf.urls import url
from .views import BrowseView, TagView
from .views import PostDetailView, post_create, post_edit, post_delete
from .views import upvote, unupvote
urlpatterns = [
# url(r'^post/(?P<slug>[^\.]+)/edit$', PostUpdateView.as_view()),
url(r'^post/(?P<slug>[^\.]+)/edit$', post_edit), ... | [
"raymestalez@gmail.com"
] | raymestalez@gmail.com |
18d76baf7b5045db633e81c57a1bd79a1a926626 | e3b8d4a345201513aa9a1b08b34c0e06d4550f97 | /add.py | 8123083a1e92a4381fbe4b993ad42c1ae0329333 | [] | no_license | A3ex1984/python_scripts | c5048c9a523f79a73b8ed94d02c045c3eda508b0 | 578c3a00e28dd9abd8c0d68b08196676800f21a9 | refs/heads/master | 2020-04-07T22:11:19.720310 | 2018-11-23T00:38:50 | 2018-11-23T00:38:50 | 158,759,077 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 45 | py | def add (a, b):
return a+b
print add (1, 2)
| [
"voets.alexander@gmail.com"
] | voets.alexander@gmail.com |
36640c37c2511ff5b8ee371d5115356049c617b8 | e6627f2649edd2df64ff800dd43338ed2021e594 | /mybot_description/src/ball_control.py | 6b57a5b6a15d9a21c9cf0d28d59aae6052735724 | [] | no_license | Gallium29/ball_finder | a61e0888f9ec8d6803dc5a6b65b4c37bf8b7eedb | 9090a5e4cddadd0da0f6a8a017360505cc82373e | refs/heads/master | 2020-05-16T00:02:01.239599 | 2019-05-02T02:52:55 | 2019-05-02T02:52:55 | 182,568,899 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,570 | py | #!/usr/bin/env python
# license removed for brevity
import rospy
from sensor_msgs.msg import LaserScan
from geometry_msgs.msg import Twist
from gazebo_msgs.msg import LinkStates
import numpy as np
from std_msgs.msg import Float64
def connect():
try:
global slider_publisher,holder_publisher,arm_publisher
... | [
"lahirunuwanisme@gmail.com"
] | lahirunuwanisme@gmail.com |
b3a6e46a2bc5b143d264546e2a72b770304bb67f | 4ade889ce5467f00df0134267562db3ac55426d6 | /test/Test.py | 814ca773d9913b3df0d9052a26327533b77e177b | [] | no_license | alou-hhm/back-end-do | 8e859f45545725d381fb16b6a4aeb522501b20a4 | c486f75197bbf04b6ceb2a0840265d54a054187e | refs/heads/main | 2023-03-18T11:53:42.263162 | 2021-03-03T17:54:11 | 2021-03-03T17:54:11 | 344,464,979 | 1 | 0 | null | 2021-03-04T12:22:08 | 2021-03-04T12:22:08 | null | UTF-8 | Python | false | false | 579 | py | import sys
import os
projectPath = os.path.abspath(os.path.join(os.getcwd()))
sys.path.append(projectPath)
print(projectPath)
from flask import Flask
from flask import session
from control.Msession import MySessionInterface
app = Flask(__name__)
app.secret_key = 'A0Zr98j/3yX R~XHH!jmN]LWX/,?RT'
app.session_interfa... | [
"mumten120@outlook.com"
] | mumten120@outlook.com |
19135b5eb9ac3da347543db2b97a3dd704af7b45 | 8cab07cf225785028b90ae81514b5990240cc23b | /tesseract/tesserocr-master/tesserocr.pyx | aff9019d8d748bc543d21def84f8f2f63635e2fa | [
"MIT"
] | permissive | Kiruan/PythonDateImageProcessing | 963a7af44b711fa657709ee47fe7b3a935a2eda1 | 7eb86d80c58f7f6105cefb018a4be90802de148e | refs/heads/master | 2022-12-14T18:12:58.522140 | 2020-09-18T09:12:56 | 2020-09-18T09:12:56 | 294,716,629 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 92,716 | pyx | #!python
#cython: c_string_type=unicode, c_string_encoding=utf-8
"""Python wrapper around the Tesseract-OCR C++ API
This module provides a wrapper class :class:`PyTessBaseAPI` to call
Tesseract API methods. See :class:`PyTessBaseAPI` for details.
In addition, helper functions are provided for ocr operations:
>>> tex... | [
"alois.van@gmail.com"
] | alois.van@gmail.com |
11d6f54d9853fa653c3a02b869f3de60122e7fff | 1d90fef6f101d744287e1cf793e7e5e57132f835 | /3a_en+es_cnn_train.py | edf131ac04042c1e3240fb8bee065562d952e9a9 | [] | no_license | leebond/Emoji-prediction-with-NMT | e1d7a363efe3b90d3bd4bc7b6421b2f2323ab786 | 427087e0f3924ee405763fb134cd51c4e7a7f740 | refs/heads/master | 2021-07-20T10:17:36.526340 | 2020-07-07T07:42:17 | 2020-07-07T07:42:17 | 190,970,420 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,983 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Sun Apr 28 13:04:04 2019
@author: macbook
"""
import os
import re
import sys
import math
import pickle
import collections
import numpy as np
import pandas as pd
from sklearn.model_selection import train_test_split
from sklearn.preprocessing import LabelBin... | [
"leebond_guanhua@hotmail.com"
] | leebond_guanhua@hotmail.com |
6f0d4727f55fccdaa4a352f6ce8b76a8c9b5cc76 | 80b48ad3384bc3903e106011d3cf37ddf91cd462 | /imageToPixels.py | a5ad06deeddb8e4f58cb35490e00ef0934ea3f00 | [] | no_license | katiecanada/cs221Project | 43f5ddf72257e0fa014c4aaff7977e5a196cf0c6 | dbaf83be798a6e765755e39dd75148bef209607b | refs/heads/master | 2020-04-06T06:47:57.604222 | 2014-12-12T23:30:18 | 2014-12-12T23:30:18 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,270 | py | #Converts all 213 jaffe images to pixel lists, then outputs all data to the file 'jaffePixelData.txt'
#jaffePixelData.txt can be viewed in Excel (choose commas as the delimiter), though the number of
#pixels in one row (256X256) exceeds the Excel limit, so all data will not be displayed.
#The first column of jaffePixe... | [
"rohisha@gmail.com"
] | rohisha@gmail.com |
333736f16e42f3d62a9ef89453470cd2cb0930ba | 15b1940db109e72849d219abb00986a46ea84c77 | /spy_details.py | 5a997153e6faf5f707c487762de3b346c0bfeb3b | [] | no_license | Gurjeetkaur31/spychat | 264c22328815de4e409db899c1ae212f46fcddba | 089626e5380491af29bab8ed8eab1d1aff82f501 | refs/heads/master | 2021-09-04T22:33:01.041176 | 2018-01-22T21:28:55 | 2018-01-22T21:28:55 | 115,903,697 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 788 | py | from datetime import datetime, time
class Spy:
def __init__(self, name, salutation, age, rating):
self.name = name
self.salutation = salutation
self.age = age
self.rating = rating
self.is_online = True
self.chats = []
self.current_status_message = None
class ChatMessage:
def __init... | [
"gurjeetsingh1209@gmail.com"
] | gurjeetsingh1209@gmail.com |
fea9c4307373e33443947a88d918860229ccc42a | 8bcabc02c2f9f5a57cbf891faf9faa2a0067afd6 | /projects/unusable/catboost_model.py | e2919d83d74fbde11fe404ed1009dd5cb6c6eb52 | [] | no_license | filaPro/soil_line | 2e70336252567019ebc7d2f51ec24e998490fbf5 | 7c4c6051288e6ed424f881bc93e9308865226516 | refs/heads/master | 2023-02-21T19:46:38.755108 | 2023-02-09T21:53:11 | 2023-02-09T21:53:11 | 42,715,124 | 0 | 1 | null | 2021-11-16T20:54:00 | 2015-09-18T10:26:36 | Jupyter Notebook | UTF-8 | Python | false | false | 1,473 | py | import torch
import numpy as np
import scipy.stats
def get_day(base_file_name):
string = base_file_name.split('_')[1]
day = int(string[:2]) * 30 + int(string[2:])
return day
def get_satellite(base_file_name):
if 'LT04' in base_file_name:
return 4
elif 'LT05' in base_file_name:
re... | [
"danrukh@gmail.com"
] | danrukh@gmail.com |
cc98821e9c2bcf9c5ae2b5ae389aee64efd71647 | 83179abbad0032fd3c8c38a54260ac4239ba9df3 | /2021/python/day10/day10.py | 2ee58cf3e9445b7b4a7506c6e49d6c8b259878b4 | [] | no_license | yulrizka/adventofcode | 448ac89ae543c8a7ee46bb5f86abc62887e3a9ee | 74b89528e07ae6282763968d5bb3d8eea38e07ba | refs/heads/master | 2023-01-13T03:57:20.688851 | 2022-12-22T11:11:59 | 2022-12-22T11:11:59 | 225,181,497 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,443 | py | import fileinput
import unittest
import collections
data = [i.strip() for i in fileinput.input("../../input/day10")]
# print(data)
open = '([{<'
close = ')]}>'
point = [1, 2, 3, 4]
def part1():
count = {}
for line in data:
s = collections.deque()
for c in line:
if c in open:
... | [
"yulrizka@users.noreply.github.com"
] | yulrizka@users.noreply.github.com |
8c326a9f5b917f0c00f6be14192f9f51fcdbbc62 | 142362be3c4f8b19bd118126baccab06d0514c5b | /apps/afisha/models.py | 584eac76f905a53e8ae27099f259719cb122eca0 | [] | no_license | dkramorov/astwobytes | 84afa4060ffed77d5fd1a6e8bf5c5c69b8115de6 | 55071537c5c84d0a27757f11ae42904745cc1c59 | refs/heads/master | 2023-08-27T07:10:51.883300 | 2023-08-02T16:52:17 | 2023-08-02T16:52:17 | 191,950,319 | 0 | 0 | null | 2022-11-22T09:15:42 | 2019-06-14T13:44:23 | HTML | UTF-8 | Python | false | false | 4,622 | py | # -*- coding: utf-8 -*-
import os
from django.db import models
from apps.main_functions.string_parser import translit
from apps.main_functions.models import Standard
class Rubrics(Standard):
"""Рубрикатор мест"""
name = models.CharField(max_length=255, blank=True, null=True, db_index=True)
# tag = ссылка... | [
"zergo01@yandex.ru"
] | zergo01@yandex.ru |
a816af14490ca391bf2ac3fdacb0b9266a488650 | 42467deeaf55540f98887d397ceb878fccca8fe4 | /mahjong/migrations/0001_initial.py | a64c9a6334f975f4299b79370289d6beb7a94b50 | [] | no_license | YotaroTakagi/django-app | 05d7233b886028fb3c82fdc63747b0bc1d5203fe | badd183aaa0835619ab487d5d695a42a318559af | refs/heads/master | 2023-01-28T17:34:48.464197 | 2020-12-11T05:51:50 | 2020-12-11T05:51:50 | 317,711,599 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 989 | py | # Generated by Django 2.0.2 on 2020-12-01 09:09
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
migrations.swappable_dependency(settings.AUT... | [
"ec2-user@ip-172-31-42-119.ec2.internal"
] | ec2-user@ip-172-31-42-119.ec2.internal |
1acccd4cca9d0d59a9e7fdfa5146b3e487426765 | f41b17d9e1d4c703c235b3cb0cd20d9e9f8b3296 | /app/views.py | a50a4cb41b80ed931954bc47b9ac3d7d3dd967fd | [] | no_license | Ezugworie08/nosj | 7fafd2fb984e296f2e9aa3876db3ef736fbbef3d | 71f50bd2943cd75ec5a09cbd8be48c0433bc7e20 | refs/heads/master | 2021-05-02T08:34:00.186185 | 2018-09-28T15:27:33 | 2018-09-28T15:27:33 | 41,447,609 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,042 | py | import os
import json
# from django.core.exceptions import ValidationError
from django.core.urlresolvers import reverse_lazy
from django.views.generic import FormView, TemplateView
from app.forms import JSONUploadForm
# Create your views here.
# Based on my research, Python has this ultimate file MIME checker called... | [
"ezugworie.ikechukwu@live.com"
] | ezugworie.ikechukwu@live.com |
3f055a563b5c7896715f775067bc9f135129f98b | 4e561812de854492f879a0ebc357e505eea622de | /questions/MyTest.py | 1c4600ac7ed3db75e5169198e8d09e907a4b8879 | [] | no_license | bairaginath/PythonQuantum | 0782996860dda7db53c0ebe11aac440e733b02cb | 653fa407b9adb1ac4ccd1d4ad85d2732150853de | refs/heads/master | 2016-09-06T18:46:49.314572 | 2016-03-07T14:02:58 | 2016-03-07T14:02:58 | 42,348,486 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 488 | py | __author__ = 'veradocs-web'
def fun(n,shrape,strength):
for i in n:
if strength[i]>shrape[i]:
return "NO"
else:
return "YES"
testcases=raw_input()
for testcase in range(int(testcases)):
total_animal =int(raw_input())
shrape=[x for x in str(raw_input()).split(' ')]
shrape... | [
"mail2bairagi@gmail.com"
] | mail2bairagi@gmail.com |
a2f62df7fa3ae239583acbbdec12088814036ef0 | 429ed49861d4d0dda5fb7b9ca99f0aff35fe2fdc | /plot/roc_apoe_plot.py | e6574b3a9f49d974803eaffd3ef09b3dfc0bf54b | [
"MIT"
] | permissive | ZainUlHaq/brain2020 | 7a1eaff7b3561bd5f14d7192ad806d595179870e | b1a0f1e26e63a404c2cf2501756b6d67bcdbb361 | refs/heads/master | 2023-03-16T14:15:32.379652 | 2021-02-17T17:52:12 | 2021-02-17T17:52:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,229 | py | from utils_stat import get_roc_info, get_pr_info, load_neurologist_data, calc_neurologist_statistics, read_raw_score
import matplotlib.pyplot as plt
from utils_plot import plot_curve, plot_legend, plot_neorologist
from time import time
from matrix_stat import confusion_matrix, stat_metric
import collections
# collect ... | [
"shangran@bu.edu"
] | shangran@bu.edu |
f284fd6be0a46aa76cc52abd420b55323886360e | 2cd986dee35becd91cbd93ba7b35414e80e33f4f | /venv/lib/python3.7/encodings/rot_13.py | 5384b27a6ffb68cae8f463176b02898642d1ab3d | [] | no_license | HernanG234/sensors_async_sim | 95ccb4e4fd188b8fc5be206bae3af4302f23e3e2 | fce3701e2a0865198c0977ede5f42da77b8a7853 | refs/heads/master | 2020-05-07T09:43:57.354059 | 2019-05-11T19:07:23 | 2019-05-11T19:07:23 | 180,387,282 | 0 | 1 | null | 2019-04-29T15:42:53 | 2019-04-09T14:37:38 | Python | UTF-8 | Python | false | false | 44 | py | /usr/local/lib/python3.7/encodings/rot_13.py | [
"hernan.gonzalez@incluit.com"
] | hernan.gonzalez@incluit.com |
57af1a0a76151d4b618724945c15377b7d23b49b | bc441bb06b8948288f110af63feda4e798f30225 | /easy_work_service_sdk/model/patch_manager/patch_manager_host_pb2.py | f25062699d42370fe847f9abf6b7f44077b1e90c | [
"Apache-2.0"
] | permissive | easyopsapis/easyops-api-python | 23204f8846a332c30f5f3ff627bf220940137b6b | adf6e3bad33fa6266b5fa0a449dd4ac42f8447d0 | refs/heads/master | 2020-06-26T23:38:27.308803 | 2020-06-16T07:25:41 | 2020-06-16T07:25:41 | 199,773,131 | 5 | 0 | null | null | null | null | UTF-8 | Python | false | true | 9,427 | py | # -*- coding: utf-8 -*-
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: patch_manager_host.proto
import sys
_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.p... | [
"service@easyops.cn"
] | service@easyops.cn |
7c18737b82a909bba6e99a42f36247a2b1da5b1d | c3c515733147897d56598c3e4d8efc9da1fa7b49 | /20_to_29.py | 02b44eb604bccec6bf208e5b0f104f101c9f9995 | [] | no_license | Konchannel/100_knocks | 764565edae2ab546488a0ecc0c6a079df73ce934 | bc16479b460992711c4a056435f57fac4af5458a | refs/heads/master | 2020-12-12T09:20:29.554393 | 2020-03-24T14:59:59 | 2020-03-25T13:10:55 | 234,097,978 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 10,181 | py | """
Wikipediaの記事を以下のフォーマットで書き出したファイルjawiki-country.json.gzがある.
1行に1記事の情報がJSON形式で格納される
各行には記事名が"title"キーに,記事本文が"text"キーの辞書オブジェクトに格納され,そのオブジェクトがJSON形式で書き出される
ファイル全体はgzipで圧縮される
以下の処理を行うプログラムを作成せよ.
20. JSONデータの読み込み
Wikipedia記事のJSONファイルを読み込み,「イギリス」に関する記事本文を表示せよ.問題21-29では,ここで抽出した記事本文に対して実行せよ.
==============================... | [
"konchan2416@gmail.com"
] | konchan2416@gmail.com |
71f7d6132aa7c3c9ca61152af102f84724447538 | 3ca6529a3e47606cd525931bfec6eaede008fe7b | /11-videogames/Referencia/07-Bullets/map.py | d06a54566ee17f7558bb4d9f644f72a7a38dbea0 | [] | no_license | DarelShroo/eoi | 6e3f0506873a3ba0120fc5ed11cf249eb90d472c | fcb5c3f1861ccf9659fa0a00ddfea45649a1771f | refs/heads/master | 2022-11-12T09:14:25.328244 | 2020-07-06T19:10:41 | 2020-07-06T19:10:41 | 279,555,296 | 1 | 0 | null | 2020-07-14T10:33:28 | 2020-07-14T10:33:27 | null | UTF-8 | Python | false | false | 1,704 | py | import random
from os import path
from settings import *
from sprites import *
class Map:
def __init__(self):
self.entry_point = (0, 0)
self.map_data = []
self.map_width = 0
self.map_height = 0
self.pixel_width = 0
self.pixel_height = 0
pass
def load_f... | [
"info@luisanton.es"
] | info@luisanton.es |
b169a2fff44358250ffc955c849eb5755337cd51 | db870b76eeafc20680d0e37001e6c471b427d344 | /code/src/db/decisions.py | 977c332dc2c078f7af6705f5c8a12750eb34fce6 | [
"MIT"
] | permissive | fabiangunzinger/sample_project | f658d07816a66732b0e42e5846715caddfcd4ac0 | a5c87d0c3ff2f6ed39f3e3a18557c0ab439f6b42 | refs/heads/main | 2022-12-30T00:42:13.416430 | 2020-10-18T15:29:19 | 2020-10-18T15:29:19 | 303,098,510 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,728 | py | import re
import numpy as np
import pandas as pd
from collections import Counter
from .registries import decision
def active_months(df):
"""Keep user-month observations with at least 12 txs."""
mnths = df.transaction_date.dt.to_period('M')
g = df.groupby(['user_id', mnths])
mask = g.transaction_id.tra... | [
"fa.gunzinger@gmail.com"
] | fa.gunzinger@gmail.com |
9aff8fe42f3ef76ccebeceaaab4baa446f5804fe | 463d2ec5da7c7908b27d06d26a51d9645b3d52f1 | /DeepLearning/mnist.py | f98a72a28bb702e2345994bbf5084e1fdb3d3279 | [] | no_license | zhangdavids/workspace | 7b899d7385d0921be78658c60ad18578c12ab10a | 91f3c3e9b27018283132e3928ad2b84db5cc4b77 | refs/heads/master | 2021-07-11T13:21:32.445158 | 2018-11-02T01:04:06 | 2018-11-02T01:04:06 | 104,007,756 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 994 | py | import tensorflow as tf
from tensorflow.examples.tutorials.mnist import input_data
mnist = input_data.read_data_sets("MNIST_data/", one_hot=True)
print("Download Done!")
x = tf.placeholder(tf.float32, [None, 784])
# paras
W = tf.Variable(tf.zeros([784, 10]))
b = tf.Variable(tf.zeros([10]))
y = tf.nn.softmax(tf.matm... | [
"1269969739@qq.com"
] | 1269969739@qq.com |
4e5fdcd6c890b044d6c9f07e3c8b685c79120f4e | 7a573ce47e75f1188f04dc0790fad5723b7185aa | /building classifier/preprocessing/test.py | 820e05967739529617c25ff3c024950d61301d2b | [] | no_license | apriilbee/Tagalog-Categorization | 492a47257562c32f65c97652bebbfc82ebb99ebd | c3fc7ba6ce779cb7ead34a3ecaaeb815ca59df55 | refs/heads/master | 2021-01-02T22:17:55.166248 | 2017-06-08T16:17:31 | 2017-06-08T16:17:31 | 78,724,990 | 1 | 2 | null | null | null | null | UTF-8 | Python | false | false | 102 | py | import nltk
from nltk.corpus import stopwords
w = stopwords.words('english')
for i in w:
print i
| [
"adaecb@gmail.com"
] | adaecb@gmail.com |
2e6966e24a50673bb6b43effb5659f725776b6fb | 10b7b4730f718e84357dc0c0d9188f4e7992c992 | /survay/questionnaire/urls.py | adf8711dabbe8f8af5b9b13d9697611d9313b5d4 | [] | no_license | tmichae1/surveyApp | 8435f976f5ed24bff3b9c4fe5fce5a05c1f433f3 | 2587e6fc722cb3a5561bec213bff748c5c2b9a76 | refs/heads/main | 2023-06-20T04:46:00.301688 | 2021-07-15T23:51:53 | 2021-07-15T23:51:53 | 385,607,959 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 713 | py | from django.urls import path
from . import views
urlpatterns = [
path('', views.home, name='home'),
path('create/', views.create_survey, name='create'),
path('create/section/<url_id>/', views.add_section, name="add-section"),
path('survey/<url_id>/<token>/', views.take_questionnaire, name='take-survey')... | [
"87375035+tmichae1@users.noreply.github.com"
] | 87375035+tmichae1@users.noreply.github.com |
5b42179d8ae598f9315778f48ca3c476646ccea0 | f8172aa9b6d2cdbb3a2236d6500013502b6b81d1 | /django_project/settings.py | 837d2ffe06f5ba27b420877ccab473b51802ef9e | [] | no_license | pwilson802/django-blog-example | bb4a776f0e7302a063191d9294dcd8aafbdc2eed | 6a10dafc1873ee328d610c8aa9fb9bd640ca2b05 | refs/heads/master | 2022-11-25T09:58:38.002034 | 2019-11-22T12:24:44 | 2019-11-22T12:24:44 | 223,022,951 | 0 | 0 | null | 2022-11-22T04:50:27 | 2019-11-20T20:37:50 | Python | UTF-8 | Python | false | false | 4,314 | py | """
Django settings for django_project project.
Generated by 'django-admin startproject' using Django 2.2.7.
For more information on this file, see
https://docs.djangoproject.com/en/2.2/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/2.2/ref/settings/
"""
impor... | [
"pwilson802@gmail.com"
] | pwilson802@gmail.com |
7167b3842fc17b7024911e5ae77cf64ac2deb3b2 | cd1bab290ca96018a2b02627bf116b7ec3c470e7 | /todo_app/migrations/0001_initial.py | 10a0e374bf022e1ad170711e99fda01d6975cbf7 | [] | no_license | hnagiyev/todo_proje | 3538ea109e1aa518f2c0f34b482c5206b11ba13a | 1b8e4442c603aace28afa736b0afe84736e975a1 | refs/heads/main | 2023-06-27T02:31:13.086651 | 2021-07-29T17:39:48 | 2021-07-29T17:39:48 | 390,729,065 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 741 | py | # Generated by Django 3.2.5 on 2021-07-26 09:59
import datetime
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Todos',
fields=[
('id', mod... | [
"huseyn.naghiyev@gmail.com"
] | huseyn.naghiyev@gmail.com |
517c79463ce84945bfd6999fc3880e19969a696c | e572d31abf99d45ea0106cd89c8de8e9189b2142 | /_build/jupyter_execute/py_dt_global_crop_yields.py | 7247740ffafdf601934905a6cb9c8d9e96d71a6d | [] | no_license | myamullaciencia/datatable_cook_book | f04172c3edf67a09e2b1651387ac0c857f7dea06 | 82d615250278d8dfeb490c25df34b9e5c4e30b8e | refs/heads/master | 2023-02-08T17:47:37.692907 | 2020-12-28T06:11:42 | 2020-12-28T06:11:42 | 292,996,694 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,883 | py | # Py : Tidy data analysis - Global Crop Yields
**Introduction** :
Our data on agricultural yields across crop types and by country are much more extensive from 1960 onwards. The UN Food and Agricultural Organization (FAO) publish yield estimates across a range of crop commodities by country over this period. The FAO ... | [
"myamulla.cienica@gmail.com"
] | myamulla.cienica@gmail.com |
00ac629f421ae2913e9cf1065ce83632df727c6f | ae7a7e4e41b4834f1a66443579125a0b77000173 | /mmaction/models/tenons/backbones/resnet_i3d.py | 978b7dc90ea6e7f363c27ac8b23effd739eb9927 | [
"Apache-2.0"
] | permissive | Solo777/mmaction | 213192487fd5144baaecd63716fb189ea70e9628 | 40580ee6da148f639842d87edf899ac523060a49 | refs/heads/master | 2021-08-10T23:25:20.292879 | 2020-07-02T13:34:38 | 2020-07-02T13:34:38 | 198,738,105 | 1 | 0 | Apache-2.0 | 2019-07-25T01:59:13 | 2019-07-25T01:59:13 | null | UTF-8 | Python | false | false | 18,429 | py | import logging
import torch.nn as nn
import torch.utils.checkpoint as cp
from ....utils.misc import rgetattr, rhasattr
from .resnet import ResNet
from mmcv.cnn import constant_init, kaiming_init
from mmcv.runner import load_checkpoint
from ..utils.nonlocal_block import build_nonlocal_block
from ..spatial_temporal_m... | [
"thuzhaoyue@gmail.com"
] | thuzhaoyue@gmail.com |
13d20f9eb3fdf4b9d9aa3b5455c41b921f47a0b9 | 00cb8ef573927889e962b8af7a4efb4f851a5c8a | /src/models/io/k8s/api/autoscaling/v2beta1.py | 8fd7bb7fe9668a56f02a7af4a699607dcffab75c | [] | no_license | paultiplady/pykube-models | 3689664825f0cf757724d9dbc3ca667dd6b9446c | d96f89f9e8c41ff7074601cac5d9e1593b1e1955 | refs/heads/master | 2023-07-14T21:22:08.697241 | 2021-08-27T14:59:25 | 2021-08-27T14:59:25 | 400,521,529 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 19,639 | py | # generated by datamodel-codegen:
# filename: swagger.json
# timestamp: 2021-08-27T12:09:44+00:00
from __future__ import annotations
from typing import List, Optional
from pydantic import BaseModel, Field
from ...apimachinery.pkg.api import resource
from ...apimachinery.pkg.apis.meta import v1
class CrossVer... | [
"paul@qwil.co"
] | paul@qwil.co |
4d7e6ad7cf367c7dc42829c8c7da8bcb08208e8a | 1b6a315ab88e5ae7e6abc5dcd08ef8ba63d7f7fe | /user_login/models.py | 1cfa963d9f4a200d9b71bd0c9224a278ffd0f95c | [
"Apache-2.0"
] | permissive | LMuter/StockTool | 9ee52596de688ba7f82846e6cd5fec92ca721859 | 2ae604774cd8c271ffc49a4a39fcc412bcaf4577 | refs/heads/master | 2021-07-11T18:52:52.324040 | 2017-10-07T11:09:27 | 2017-10-07T11:09:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 10,425 | py | from django.db import models
from django.contrib.auth.models import User
from django.contrib.auth import authenticate
from user_login.constants import *
from django.db.models import Q
from user_login.user_login_errors import *
import re
from django.utils import timezone
# Run python manage.py makemigrations to create... | [
"laurens.muter@careweb.nl"
] | laurens.muter@careweb.nl |
212c41ec373956010f7a1f0dc36b217f764d4888 | 3ce00b07471c9775968ca0fd07b025fe09bf001c | /site_na/site_na/settings.py | 23d9eab2620d17bba7646422676a4341c9d4a202 | [] | no_license | RicardoGomez77/my-first-blog | b53ae5e7fe4e00d5cfd00d428824342712f88511 | e530f9d0ffd38d48bc754c19e80dc2084226f239 | refs/heads/master | 2021-01-18T16:37:03.840167 | 2017-03-30T20:58:19 | 2017-03-30T20:58:19 | 86,748,297 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,111 | py | """
Django settings for site_na project.
Generated by 'django-admin startproject' using Django 1.10.5.
For more information on this file, see
https://docs.djangoproject.com/en/1.10/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.10/ref/settings/
"""
import os... | [
"GomezRicardo027@gmail.com"
] | GomezRicardo027@gmail.com |
badb56f269035fdfb3c8b1c7af469bdf0816f797 | 91992db8c28646f0aae3393e8bbe0af66c0144ea | /ejercicios python/tp3 prog-Piccadaci.py | 6bee80a1d3f2cdc8339d49389f483ccfa67baf0c | [] | no_license | Pato38/EDI | 626e33247c4e8850dc29dfe55af45b7f0fbad2ee | 04f244c3b859f2c2a566c3670f21fb9f606d18ab | refs/heads/master | 2021-07-16T16:07:42.499775 | 2020-07-23T15:05:16 | 2020-07-23T15:05:16 | 194,303,248 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,054 | py | #1. Implementaremos una clase llamada Persona que tendrá como atributo (variable) el nombre de la persona y dos métodos (funciones).
# El primero de los métodos inicializará el atributo nombre y el segundo mostrará por pantalla el contenido del mismo.
# Definir dos instancias (objetos) de la clase Persona.
class Person... | [
"patriciapiccadaci@gmail.com"
] | patriciapiccadaci@gmail.com |
c7f69a99827f9898d781abe688c7d8f36bfcbecd | b08870f8fe7b3cf1bbab3c52a7bacbb36ee1dcc6 | /verp/verp_integrations/doctype/shopify_log/shopify_log.py | d7025f8e8f220fc107ce8a2e605e779ba5b39c99 | [] | no_license | vsadminpk18/verpfinalversion | 7148a64fe6134e2a6371470aceb1b57cc4b5a559 | 93d164b370ad9ca0dd5cda0053082dc3abbd20da | refs/heads/master | 2023-07-13T04:11:59.211046 | 2021-08-27T06:26:48 | 2021-08-27T06:26:48 | 400,410,611 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,244 | py | # -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
import json
from frappe.model.document import Document
from verp.verp_integrations.utils import get_webhook_address
class... | [
"admin@vespersolutions.tech"
] | admin@vespersolutions.tech |
34a1b66fec28c74b42ac8a3f86b866b688311e79 | b34959cc520c612051b6570046df19cd4a352950 | /models/model.py | d36e51fa83776f523d257cf9ae2ba837bef7b39e | [
"MIT"
] | permissive | apllolulu/SRN-Learning-to-see-in-the-dark | 505d80c57fc3ebce85cde70d75d450a5e81baaaa | 94512bdcf2123ca20c1620998e11e5509472a45d | refs/heads/master | 2020-06-05T00:42:36.475906 | 2019-06-17T01:27:47 | 2019-06-17T01:27:47 | 192,254,638 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 21,853 | py | from __future__ import print_function
from __future__ import division
import os
import time
import random
import datetime
import scipy.misc
from datetime import datetime
from util.util import *
from util.BasicConvLSTMCell import *
from util.SEBlock import *
from util.SE_ResNeXt import *
import os, time, scipy.io
imp... | [
"1254468141@qq.com"
] | 1254468141@qq.com |
0e6151d875319fda41471cf819ca8ca31d25cd8a | 45b7b988ce3de07f28adbb9f53d390e013dcae51 | /iaa_2018/aux_func.py | bc146cc8ab8d58b34ce26314da8a256369fb22e4 | [
"MIT"
] | permissive | felixlapalma/diplodatos_2018 | d30313cee9576b2485741e7b326a585c0b842394 | ec36c646ca08902c676e6c947acfa7d328fcf22d | refs/heads/master | 2021-07-14T06:29:25.563233 | 2018-12-04T00:23:56 | 2018-12-04T00:23:56 | 130,107,673 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 16,004 | py | # Auxiliary
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
from matplotlib.colors import ListedColormap
from ml.visualization import plot_confusion_matrix, classifier_boundary
from sklearn.datasets import load_boston, load_breast_cancer, load_iris
from sklearn.linear_model import LinearRegress... | [
"felixlapalma@gmail.com"
] | felixlapalma@gmail.com |
fc320749b5ee2c46efd8972dc6f9054af3958b30 | 75000fc26e0110f475d33ff4c818c7f77de9f17f | /SchoolSystem/pupils/migrations/0004_pupils_user.py | de0deaca5bf353797183dd81283b511fb960bd10 | [
"MIT"
] | permissive | fallprojects/SchoolSystem | 87a686e6ea35ea2ddd360321a35c09e55b0063cd | 39138aa3539e75f108c168bfe7205cf2571bd7e6 | refs/heads/master | 2023-02-01T15:10:00.921052 | 2020-12-10T10:29:51 | 2020-12-10T10:29:51 | 317,192,228 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 589 | py | # Generated by Django 3.1.3 on 2020-12-04 11:18
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
('pupils', '0003_auto_2020... | [
"johnydepp2002@mail.ru"
] | johnydepp2002@mail.ru |
be16d737ceafa54211919bced84e18c537a7a6ab | afb01d9de77fcaed46d9c5b287174032858c812b | /migrations/versions/3fbbff1e59af_criacao_da_model_instituicao.py | 79390f28278657009b07caa8afe5fcb9c15183e8 | [] | no_license | victorroli/api_v1 | 37a322f9380adba49bdbac23b919d0cb54819364 | e3aa2c138b170dc55c4cd7883f431eaff83faa3d | refs/heads/master | 2022-09-28T01:31:46.633137 | 2020-11-26T21:11:43 | 2020-11-26T21:11:43 | 181,601,230 | 1 | 1 | null | 2022-09-16T18:13:39 | 2019-04-16T02:40:12 | Python | UTF-8 | Python | false | false | 1,333 | py | """Criacao da Model Instituicao
Revision ID: 3fbbff1e59af
Revises: 53ae2cb2a02c
Create Date: 2019-08-14 21:56:21.875870
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '3fbbff1e59af'
down_revision = '53ae2cb2a02c'
branch_labels = None
depends_on = None
def up... | [
"victorfelipe1608@gmail.com"
] | victorfelipe1608@gmail.com |
559cb4199d30977fd83ba38872c41780b2108f1d | 7dd3e1379932a1354b0f0a43dead0f51bcd6dc4a | /connection.py | b636f7fcb754876423e52d4a313149bf2f4fbe89 | [] | no_license | sridattayalla/Spend-N-Share-Flask | 4ef988ce74392f8bd7395224a661c666042de3a1 | 9918440785f2366b07bb08aa87a78d719935210f | refs/heads/master | 2021-05-20T09:53:40.697075 | 2020-04-10T10:09:29 | 2020-04-10T10:09:29 | 252,235,258 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 139 | py | import mysql.connector
mydb = mysql.connector.connect(
host="34.93.179.253",
user="datta",
passwd="9898",
database="sns"
) | [
"sridatta555@gmail.com"
] | sridatta555@gmail.com |
c9acb84f3165dbab77265aeca76ea0ea6b26acf8 | 6db51cdaff653a9f0f9b2d149d5dbb62f2232339 | /ml/code/c6.py | 4b6fd4a232ed565cad32dca2e95bc17d71e6b3c4 | [] | no_license | imgoodman/chepai | bd2ce3a7738d34165164a8e51fe29c6fa4127a0d | 60b99879c30bb0915bb33693b24b624303b8e394 | refs/heads/master | 2020-06-30T20:14:55.826739 | 2017-02-13T10:09:04 | 2017-02-13T10:09:04 | 74,354,770 | 2 | 2 | null | null | null | null | UTF-8 | Python | false | false | 113 | py | import NLTKBOW
from sklearn.feature_extraction import DictVectorizer
from sklearn.naive_bayes import BernoulliNB | [
"jan8611@163.com"
] | jan8611@163.com |
ca187d9ad3d6ab1e47c8a3605fe78dde9be87942 | 5d79430371e86a27717c69c0a96542f6c96e5537 | /simplesocialmine/simplesocialmine/settings.py | 3baae548cce0b7342bf64ee1857ccd4a5578b3a9 | [] | no_license | anucoder/Social-Media-Project | 705e21cf0890703738a5bc2b9cc237f51b28a748 | 9f58c4a0c295aea042098bab84e28736ca6857bc | refs/heads/master | 2021-03-14T09:25:03.744350 | 2020-03-12T06:00:18 | 2020-03-12T06:00:18 | 246,755,613 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,439 | py | """
Django settings for simplesocialmine project.
Generated by 'django-admin startproject' using Django 2.0.3.
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/
"""
imp... | [
"anagha.t.sasidharan@ericsson.com"
] | anagha.t.sasidharan@ericsson.com |
27625b0ca9959a66b5419c730f9e3b38cbd8bdad | 23392f060c85b5fee645d319f2fd5560653dfd5c | /01_jumptopy/chap05/Restaurant_v1.py | b8143f488dacff28b307454d80cb4ad6bba75307 | [] | no_license | heyhello89/openbigdata | 65192f381de83e4d153c072ff09fa7574f003037 | b35ff237c32013c3e5380eee782085a64edb9d80 | refs/heads/master | 2021-10-22T04:29:00.852546 | 2019-03-08T02:14:34 | 2019-03-08T02:14:34 | 125,938,319 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 613 | py | class Restaurant:
def __init__(self, input_name):
self.restaurant_name = input_name.split()[0]
self.cuisine_type = input_name.split()[1]
def describe_restaurant(self):
print("저희 레스토랑 명칭은 %s이고 %s 전문점입니다."%(self.restaurant_name, self.cuisine_type))
def open_restaurant(self):
... | [
"heyhello89@hanmail.net"
] | heyhello89@hanmail.net |
45586f2a611468494d1cd0e3b5cccc9b9768fbb0 | 58305a1236f473991e4f9a88db64eb8d1ef029ce | /memory/lib/range_tree.py.bak | 75224a8c635f8d59b2ab40507f5faaaeefe61036 | [
"BSD-2-Clause"
] | permissive | anrddh/memsight | aa012ae1878844a370ae33abc26d3a1851cacde5 | 9e279ade02926543a34fce452e66a161f7fede7d | refs/heads/master | 2021-03-05T22:34:26.425581 | 2020-04-19T22:53:21 | 2020-04-19T22:53:21 | 246,158,634 | 1 | 1 | BSD-2-Clause | 2020-04-12T15:04:04 | 2020-03-09T22:53:23 | Python | UTF-8 | Python | false | false | 7,970 | bak | import math
import sys
class RangeTree(object):
def __init__(self):
self.root = None
self.cutoff = 4
self.count = 1
pass
def add(self, start, end, obj):
# l = end - start
# l2 = math.pow(2, math.ceil(math.log(l, 2)))
lower = int(math.pow(2, math.flo... | [
"me@anrddh.me"
] | me@anrddh.me |
0b4ee30ae8b83514de5d2ea2f2367df3dbd745f1 | 4a8ca74837b6c156a1c4ca957ebed92d46eb56c2 | /problem11/robot.py | 010b7c0d64eed3e6bfc30cf7d8a6b0ede145991c | [] | no_license | mattnworb/advent-of-code-2019 | 38b9be92e05ff7d6829b8af737932a9cb73077dc | cd8d6c090496246d17b75dfc9f70175379aebeb8 | refs/heads/master | 2021-06-28T11:32:43.201646 | 2020-01-04T21:16:02 | 2020-01-04T21:16:02 | 226,387,870 | 0 | 0 | null | 2021-04-20T19:01:10 | 2019-12-06T18:33:39 | Jupyter Notebook | UTF-8 | Python | false | false | 3,042 | py | import computer
import enum
class Direction(enum.Enum):
UP = 0
LEFT = 1
DOWN = 2
RIGHT = 3
def rotate_left(self):
return Direction((self.value + 1) % 4)
def rotate_right(self):
return Direction((self.value - 1) % 4)
# outputs from IntCode program
# colors
PAINT_BLACK = 0
PA... | [
"mattbrown@spotify.com"
] | mattbrown@spotify.com |
22560643599d72243e5ddef6f955e9de7bed99f9 | 13aa7b9d76c364eb6b112ad057f81ea2fa63da3a | /modules/password-recovery/wordsmith.py | 84229a517a8159f4f3710f24bc70a80a4741c003 | [] | no_license | trustedsec/ptf | df2ed6671c9efd05db756faec41298fbfb50bc5a | f87dfa8b3b62f2157fc51e8abe31bf3f0bf8541c | refs/heads/master | 2023-08-31T08:01:58.033518 | 2023-03-15T17:04:49 | 2023-03-15T17:04:49 | 35,505,904 | 5,087 | 1,434 | null | 2023-08-27T22:33:41 | 2015-05-12T18:37:25 | Python | UTF-8 | Python | false | false | 767 | py | #!/usr/bin/env python
#####################################
# Installation module for Wordsmith
#####################################
# AUTHOR OF MODULE NAME
AUTHOR="Sanjiv Kawa (@skawasec)"
# DESCRIPTION OF THE MODULE
DESCRIPTION="This module will install/update Wordsmith, a tailored wordlist generator based on geo... | [
"skawa@paysw.com"
] | skawa@paysw.com |
8c51524baf821e201369d1d24c1f5464ed8181ef | 6be39b8de21a5ceb0fe79c670533454f32276d40 | /py_THW/ex39.py | a70ba838fd33a9252dec70fa9dd743073506f6ea | [] | no_license | pholton/PyTraining | e4c244db62a53b0409ea4a4ef2b8fb1da7dcb259 | 23fe549630e9d0527cf4037d13699cff08357af1 | refs/heads/master | 2021-01-10T06:17:28.717077 | 2016-04-09T19:08:03 | 2016-04-09T19:08:03 | 55,104,649 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,823 | py | #!/usr/bin/python
def main():
# create a mapping of stat to abbreviation
states = {
'Oregon': 'OR',
'Florida': 'FL',
'California': 'CA',
'New York': 'NY',
'Michigan': 'MI'
}
# create a basic set of states and some cities in them
cities = ... | [
"the.peter.holton@gmail.com"
] | the.peter.holton@gmail.com |
9e94b93f9c625b41373b4d71fa584993116a74ed | ad1e55b9a67c798cf4b4ce41c76b26977f8b4e8d | /rockit/music/models.py | 83ff6ae4fca6390c25d1ac6f1e39a2e711c26f0a | [
"BSD-3-Clause"
] | permissive | kumar303/rockit | 7a6ac84bb8c37e5f3b65d7dcecf9b9c549902cf5 | fc347b5b143835ddd77fd0c1ea4e6f2007a21972 | refs/heads/master | 2021-01-10T19:51:30.638073 | 2020-07-26T19:00:37 | 2020-07-26T19:00:37 | 4,219,328 | 0 | 2 | BSD-3-Clause | 2020-07-26T19:00:38 | 2012-05-03T22:03:24 | Python | UTF-8 | Python | false | false | 4,007 | py | import hashlib
import os
from django.conf import settings
from django.db import models
from rockit.base.models import ModelBase
from rockit.base.util import filetype
from rockit.sync import s3
class VerifiedEmail(ModelBase):
email = models.CharField(max_length=255, db_index=True, unique=True)
upload_key = m... | [
"kumar.mcmillan@gmail.com"
] | kumar.mcmillan@gmail.com |
71d13fcb449b1bcc8a34f1382eeb9646cb8c0919 | fd6a47d9596213d9eca4d0bb4c9087ebb476a3b3 | /5.chatbot_tutorial_telegram_openpyxl/tuto02(data parsing)/app.py | 2bbdda8a9f9693125b9d4f8432970c04dc101649 | [] | no_license | yourchikorita/study_things | 29fe9b91a1df306a980e8c11af0f682abf66efe3 | b54f4de2d98838ae40d7f39bfffc0f41f8457fdb | refs/heads/master | 2023-03-09T01:27:22.198112 | 2020-11-01T10:01:39 | 2020-11-01T10:01:39 | 200,755,378 | 0 | 0 | null | 2023-02-22T06:05:40 | 2019-08-06T01:41:10 | Jupyter Notebook | UTF-8 | Python | false | false | 711 | py | # -*- coding: utf-8 -*-
from flask import Flask, request, Response
import json
API_KEY = '804123401:AAEYMlSuNQmGfb67aGvTY3tNQtyFVdCrYno'
# Flask 객체를 생성 __name__ 을 인수로 입력
app = Flask(__name__)
# 경로 설정, URL 설정
@app.route('/', methods=['POST', 'GET'])
def index():
if request.method == 'POST':
message = req... | [
"yourchikorita@gmail.com"
] | yourchikorita@gmail.com |
af85c3d57f311d7ceaaf6234d16e697b691c7a68 | 5363e4eaa1af6fe4ba2e8c7f182c125d7b090efd | /Sunny/Python/Flask/app.py | 28d23f9f5e3b921ad6f7bce7314db4dd40acd9e3 | [] | no_license | Sunnyryu/DaebakStudy | a87a24e651491a482b9c92b98e01eae3c3bfc6c9 | 32732f11dd99d3e10625b7695e431e535edeeab1 | refs/heads/master | 2022-07-11T21:50:55.018842 | 2020-07-20T07:11:13 | 2020-07-20T07:11:13 | 244,505,943 | 0 | 0 | null | 2022-06-22T02:31:06 | 2020-03-03T00:32:20 | JavaScript | UTF-8 | Python | false | false | 1,289 | py | from flask import Flask, render_template, request, redirect, send_file
from scrapper import get_jobs
from exporter import save_to_file
app = Flask("SuperScrapper")
db = {}
@app.route("/")
def home():
return render_template("home.html")
@app.route("/report")
def report():
word = request.args.get("word")
i... | [
"sunny_ryu@outlook.com"
] | sunny_ryu@outlook.com |
c5b779463647a8e3fa6fecf71535059d56028f41 | 3f85ca01d9fcac1a81054fed6c0daa97413da3cd | /Cluster.py | 717861cab2dd0f7d4a144fae2ddb59d301643756 | [] | no_license | liammccarthy93/Google-Ngram-Dating | 5acca7f640664fa01b1cce761b3721fbd4da58d5 | 267d65501e1e2df892f8e5f8619ab9f2033dcf86 | refs/heads/master | 2021-01-19T22:47:25.600146 | 2017-04-20T11:42:49 | 2017-04-20T11:42:49 | 88,858,982 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,969 | py | import numpy as np
from sklearn.cluster import DBSCAN
import matplotlib.pyplot as plt
import warnings, sys
warnings.filterwarnings("error") # allows warnings to be caught as errors
class Cluster:
def __init__(self, points):
self.points = np.array(points)
self.samples_threshold = 5#int(0.4*len(points)) # minimum... | [
"noreply@github.com"
] | noreply@github.com |
9ae81e8a01eeee92a692b06395871d252e3baef4 | cb7484468143ee6b24876f51f31c813db3648aea | /LA-VITON/testMask.py | 6aa0a5f124bb905b2efaa135b92f902fd079422c | [
"MIT"
] | permissive | thaithanhtuan/FashionProject | 68d806a155c3f9dca9c81cc81ccd186320f1a5c3 | 6f1f1618250a1f7fb2444bebc921079864659155 | refs/heads/master | 2021-07-20T00:23:45.680902 | 2020-05-22T09:28:26 | 2020-05-22T09:28:26 | 161,261,627 | 5 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,868 | py | #coding=utf-8
import torch
import torch.nn as nn
import torch.nn.functional as F
import argparse
import os
import time
from cp_dataset import CPDataset, CPDataLoader
from networks import GMMMask, GMM, UnetGenerator, load_checkpoint
from tensorboardX import SummaryWriter
from visualization import board_add_image, boar... | [
"noreply@github.com"
] | noreply@github.com |
272970ee34d4da0102078dfb3e025b0ff87c558d | 48aa9d9b41a6392a8d6fd881f68b52f7ccc44499 | /topovske_project/wsgi.py | 1135a1abb973992dc11fd695021982e7071f603e | [] | no_license | Matje1979/topovske_project | af756b1853732fd1442ce40852f86521bdc7ecd1 | 1d98d391a4faa8e8004c62d61e984817e777e892 | refs/heads/master | 2022-11-23T06:51:33.766764 | 2020-07-28T12:39:49 | 2020-07-28T12:39:49 | 246,941,506 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 409 | py | """
WSGI config for topovske_project project.
It exposes the WSGI callable as a module-level variable named ``application``.
For more information on this file, see
https://docs.djangoproject.com/en/2.1/howto/deployment/wsgi/
"""
import os
from django.core.wsgi import get_wsgi_application
os.environ.setdefault('DJA... | [
"damircicic@gmail.com"
] | damircicic@gmail.com |
26435057bf8dbc2b185ba05f1b59eadb43fe185d | 6d2771b64ed1a0a69f74c1559bd164cfd1b737ec | /code/kPrototypes.py | 4939dc247eacbeb27579c597dbde1ddf39c4fb8d | [] | no_license | greenCyber11/mixed-data-clustering | 9ef92ab9cea07c52646270511d57ec3bb5066da3 | a9a802ed93b4f5996a1a554e0d8d5faf30a40a24 | refs/heads/master | 2021-01-19T19:40:04.314235 | 2017-07-14T09:16:07 | 2017-07-14T09:16:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 965 | py | # -*- coding: utf-8 -*-
"""
Created on Sun Apr 10 14:20:40 2016
@author: Mindaugas
"""
import distances as ds
def Kprototypes(dataset,CatAtr,NumAtr,Z,z,x):
subsetCat = dataset[CatAtr].as_matrix()
subsetNum = dataset[NumAtr].as_matrix()
Ar = len(NumAtr)
Ac = len(CatAtr)
A = Ar+Ac
SN = 0
... | [
"venckus.mindaugas1@gmail.com"
] | venckus.mindaugas1@gmail.com |
bf782c0d8b7a36cfab4a38f44f407929fc265470 | c5c8f1dbaa77a90c4152bcdea4b3213278bbdc33 | /python/isbn-verifier/isbn_verifier.py | 44756e905e0eb47e84fb80b6301370c07abe5551 | [] | no_license | 93fk/exercism | 482c7d68fd463840075b4591a2f09fd094ea3de5 | a9346bcc634417af677f3bcfc7a57765b8546cb9 | refs/heads/master | 2020-04-30T16:34:48.274814 | 2019-03-25T20:18:27 | 2019-03-25T20:18:27 | 176,952,673 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 637 | py | import numpy as np
coefs = [i for i in range(10,0,-1)]
legal_characters = [str(i) for i in range(10)]+['X']
def verify(isbn):
isbn = isbn.replace('-', '')
cond_1 = len(isbn) == 10
cond_2 = 'X' not in isbn[:-1]
cond_3 = set(isbn).issubset(set(legal_characters))
if cond_1 and cond_2 and cond_3:
... | [
"noreply@github.com"
] | noreply@github.com |
ae0c8628679324ba9c4c2d12b8ec5a6b1b53700f | 7de993087fbdba3059b62d2d7a8490e81984483c | /app/core/custom_routing.py | b12fec9f0513df55275ae88cb88c3e7064ecfddb | [] | no_license | wanganhong/fastapi_example_project | d327546598f7f94fd8e173dde3c9f952fbd02f1b | 83fbe84990adb834006449442eb82df0b9c32952 | refs/heads/master | 2023-06-14T18:34:35.695636 | 2021-07-08T02:26:34 | 2021-07-08T02:26:34 | 383,977,082 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,242 | py | #!/usr/bin/env python
# -*- coding:utf-8 -*-
import time
from typing import Callable
from uuid import uuid4
from fastapi import Response, Request
from fastapi.routing import APIRoute
from loguru import logger
class ContextIncludedRoute(APIRoute):
def get_route_handler(self) -> Callable:
original_route_... | [
"773624972@qq.com"
] | 773624972@qq.com |
30c9e82b2f37282ea65de77a35f2187b8f3ca5cb | a41520fe9dd9d71acd66130eca9a41ecc3bc313f | /01-Premier_Script.py | 10f3332aee248de79b728487d09dd5b85fd40fd9 | [] | no_license | lxkrv/Formation_Python | 05feefcd98799c0265487ee29b252d1594760d4c | 04acff85ee4dc64d5b4a67e2bb0c9dc498cd967b | refs/heads/master | 2022-04-14T11:30:32.189078 | 2020-04-20T13:01:47 | 2020-04-20T13:01:47 | 254,882,394 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 248 | py | #coding:utf-8
print("Hello world")
"""
ceci est un commentaire
"""
### ceci est un commentaire
print('L\'envers du décor')
print("L'envers du décor")
print("L'envers du\ndécors") #passage à la ligne
print("\tL'envers du décor") #tabulation | [
"alxkorova@gmail.com"
] | alxkorova@gmail.com |
a7a998efb431ef7988553f1b40f792317a4794ab | 41e7f1b0f6d034dfb188ea7ccc6419d3110e9d90 | /lgms/students/models.py | 6e4140b137fcde3359efd6697ad7f0b24b196c80 | [] | no_license | 42force/lgmsv1 | cbf3881a7a3f047cd0ea8a962883780a73ec13c1 | 2caee52db3914019af01432ddd85703afcd8f73b | refs/heads/master | 2020-03-25T06:13:41.755085 | 2018-08-05T08:51:33 | 2018-08-05T08:51:33 | 143,490,195 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 23,840 | py | from django.contrib.auth.models import AbstractUser, BaseUserManager, User
from django.db import models
from django.urls import reverse
import django.utils.timezone
from datetime import date
from crispy_forms.helper import FormHelper
from phonenumber_field.modelfields import PhoneNumberField
from django.conf import set... | [
"42force@gmail.com"
] | 42force@gmail.com |
0faf2071c29f58b4adca92358faf479474d2a970 | 16c435a6b016574103255e7b5a76ab0798e43a1d | /Project4 Lucas Kanade Tracker/imagesProcessing.py | a2b2d11acfc14202127c817531666c5f0495b160 | [] | no_license | hfang743/Computer-Vision | 9c9f009cd16420bdb179df7ecbfeeab8435929fb | 1fb20a0cce81f4c13a642e40921db6f9b07136e7 | refs/heads/master | 2022-06-10T20:48:35.901782 | 2020-05-05T04:06:08 | 2020-05-05T04:06:08 | 257,430,100 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,111 | py | import cv2
import os
import numpy as np
def firstTemplateAndSecondFrameAndImageList(path, flag_covertToGray=True):
images = []
cv_img = []
for image in os.listdir(path):
images.append(image)
images.sort()
for image in images:
img = cv2.imread("%s/%s" % (path, image))
if fla... | [
"58123475+hfang743@users.noreply.github.com"
] | 58123475+hfang743@users.noreply.github.com |
9eb4852114ba3ef446d5eba0a3bb77119585fec6 | 70d7337381fa7ef0fc0e7b9f6a3bc83a13009132 | /db_repository/versions/002_migration.py | cb98c047f9ef3ec7949a2b4f2078d32989a0a242 | [] | no_license | bryan-oliveira/alfred | 99d81bc7fb6ac75f8abecfdf2d7eda6a31027c18 | 6c69f816ded823b6152a3c80a449a8a397ab393f | refs/heads/master | 2021-07-29T09:37:52.256440 | 2017-01-27T01:07:40 | 2017-01-27T01:07:40 | 66,364,597 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,567 | py | from sqlalchemy import *
from migrate import *
from migrate.changeset import schema
pre_meta = MetaData()
post_meta = MetaData()
allergies = Table('allergies', pre_meta,
Column('id', INTEGER, primary_key=True, nullable=False),
Column('soy', BOOLEAN, nullable=False),
Column('milk', BOOLEAN, nullable=False)... | [
"vicdaruf@yahoo.com"
] | vicdaruf@yahoo.com |
d3518bd45a36d1c157cd28ed4479a231feb28b7c | 629b6e3357f2222d037f23f41a012c94ab722b51 | /venv/bin/pip | a4d04ee40048b91059a836512044e6bc968de9fd | [] | no_license | andrinelo/goto | 49d9f6107206065f6a74c53d484ff6288c369e0e | cb4e8d7a65b999826cd64ab6b86f4baf5c2dbe89 | refs/heads/master | 2020-06-30T14:10:52.716416 | 2018-09-19T22:26:12 | 2018-09-19T22:26:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 234 | #!/Users/bea/workspace/fb_short/venv/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from pip import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(main())
| [
"bianca.subion@gmail.com"
] | bianca.subion@gmail.com | |
fc4a776a7e5d699395aebb86fbe4b1e6d011eca0 | 8245b3132989ca19eb896c8004d45d7b0090bb59 | /practice02/06.py | 380275c5f8e19b2047db12064ce05935edd26247 | [] | no_license | hanvv3/BIT-python-basics | d34c9436cb5568a9f0a2cc1b0819b9f023532669 | 6b30c04e24864dfa741ede643f77c1abeef4acb3 | refs/heads/master | 2023-03-30T02:31:19.236882 | 2021-04-04T17:34:47 | 2021-04-04T17:34:47 | 352,827,149 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 766 | py | # 6.
import os
from random import random
while True:
low, high, cnt = 1, 100, 1
os.system("clear")
answer = int(random()*100)+1
print("수를 결정하였습니다. 맞추어 보세요.")
while True:
print("{}-{}".format(low, high))
try:
num = int(input("{}>>".format(cnt)))
except ValueErr... | [
"hanvv3@gmail.com"
] | hanvv3@gmail.com |
3118ba5d4d1c08a62716d49b3a89bfbe1ae388d2 | 84b5294300db6bd6d6cb424629facc9b3145c4c6 | /06_Canopy_AbsAppMag_Phase_ForEachBand_Main.py | 637eb43dfa921df5eaba873d7b74b7a4366649f9 | [] | no_license | GraCosPA/SNIRfit | 041e91443a4190df17149c4ef121d58410a84ea8 | bdd39be92be7aae7bfc583f87de3e5d4c3632174 | refs/heads/master | 2023-03-16T05:30:29.912633 | 2019-08-30T04:26:27 | 2019-08-30T04:26:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 21,072 | py | #!/usr/bin/env python
# coding: utf-8
# # Create text files of:
# # - (phase, absolute mag, error mag) and
# # - (phase, apparent mag, error mag)
#
# ### User interface
from snpy import *
# from numpy import *
import numpy as np
from matplotlib import pyplot as plt
import json
import glob # To read file names in a di... | [
"aavelino@cfa.harvard.edu"
] | aavelino@cfa.harvard.edu |
b9f51acabb4e2a2cfaa5b7155f4922809e32e023 | f82dbfd620abe9e599c437b60cd9705d8a180bf9 | /server/init_db.py | 3c488a39514cd919d9cd483d14ca2cb57f528638 | [] | no_license | jpajukan/pwpproj | 692d3249c6f493e019b9befc4d6dd717cbb67df9 | cfa44aca5eff8fd50aaa4198a5b20184c59b108f | refs/heads/master | 2020-03-21T05:35:38.027818 | 2018-06-21T12:38:19 | 2018-06-21T12:38:19 | 138,167,940 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,845 | py | import logging
from hashlib import sha256
from server.app import init_app, init_db
from server.db.api import *
logger = logging.getLogger(__name__)
USERS = [
("Matti Matikainen", "matti@matikainen.fi", "0501234567"),
("Mervi Matikainen", "mervi@matikainen.fi", "0509894172"),
("Heikki Herranen"... | [
"kkk@kkk.fi"
] | kkk@kkk.fi |
f319937ac408753abfdf1a78a30afe9a621bac03 | 087253eb5ea496bbcf8d39dc8d7ebbf02b91d11d | /titlebar.py | b208a400aa2bb4a2de164099dcc439e9d4569ce4 | [] | no_license | vandyleapheng0/tkinter-titlebar | 1bf21229ab7bc03d152e82e206e071658cea2770 | 102e4a6bfc76394e5c5b4cde1626d0a4ae571c19 | refs/heads/main | 2023-09-03T14:05:51.561164 | 2021-11-17T09:35:01 | 2021-11-17T09:35:01 | 428,595,634 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 12,171 | py | import tkinter as tk
from ctypes import windll
class LabelButton(tk.Label):
def __init__(self, master, **kwargs):
super().__init__(master, **self.valid_kwargs(kwargs))
self.rebind()
def rebind(self):
# button hover
self.bind(
"<Enter>",
lam... | [
"noreply@github.com"
] | noreply@github.com |
1fa51628b147cc015e6fa7fe29386185d9a42a00 | 94cc4c70bbc8ddbdfc68a18bb5a505b455f488f1 | /beginner_tutorials/src/keys_to_twist.py | 053a5ad3a7f2511004490e35dc0eaee9dc21c5ce | [] | no_license | markminch562/Nano-ROSbot | 576f905cc3d13c59706ae926451589ec5731ad4f | c6665b873745d6a59916e1dc6352424fd5e80abd | refs/heads/master | 2022-04-24T14:40:07.222371 | 2020-04-24T20:29:05 | 2020-04-24T20:29:05 | 258,613,358 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,519 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*
import rospy
import math
from std_msgs.msg import String
from geometry_msgs.msg import Twist
key_mapping = { 'w': [ 0, 1], 'x': [0, -1],
'a': [-1, 0], 'd': [1, 0],
's': [ 0, 0] }
g_twist_pub = None
g_target_twist = None
g_last_twist = None
g_last_send_time = None
g_... | [
"noreply@github.com"
] | noreply@github.com |
0fcb0815b7b1f32727664509a647f553232b6583 | ea603cefec4fe15cf4636715fb7d4e2c3185945b | /tests/test_antennas.py | 7837f8225442bdf0f913287d30b660e662a2b2d4 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | masscreation/antenna-selection | aa5f771402a1bbaaa3941f607bf9f261a1ac6442 | caf522b2ee72a9f23280b5bcf2b53930d50196b3 | refs/heads/master | 2021-02-12T15:58:48.298750 | 2020-02-26T00:41:28 | 2020-02-26T00:41:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 435 | py | import os
import subprocess
import sys
import unittest
# /path/to/demos/antenna-selection/tests/test_antennas.py
project_dir = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
class TestDemo(unittest.TestCase):
def test_smoke(self):
"""run antennas.py and check that nothing crashes"""
... | [
"mwong@dwavesys.com"
] | mwong@dwavesys.com |
28f4a157d4097c727f9f21e898d12265cfd43662 | 11eedcaafb721ecdb8f63d3cadcfd851e15c9ef0 | /oop12/lesson12f.py | f5fe853bf9c2edfe5c96a402369ec5b80ad796ea | [
"MIT"
] | permissive | ay1011/MITx-6.00.1x-Introduction-to-Computer-Science-and-Programming-Using-Python | 590cacccd8bbccfe0dc3e0c6c62ac3625372af9d | 7c55465ac788fde2a9210d3806a6989b8337a005 | refs/heads/master | 2020-12-25T14:38:08.356000 | 2016-07-27T18:08:52 | 2016-07-27T18:08:52 | 63,199,177 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,931 | py | import random
class Hand(object):
def __init__(self, n):
'''
Initialize a Hand.
n: integer, the size of the hand.
'''
assert type(n) == int
self.HAND_SIZE = n
self.VOWELS = 'aeiou'
self.CONSONANTS = 'bcdfghjklmnpqrstvwxyz'
# Deal a new hand... | [
"yongallan@yahoo.com"
] | yongallan@yahoo.com |
bda87bddb2074d724f72769e1702f73a598e71dc | 49094b834bbc8af3b8fd9e5fc01156ab706f0354 | /linear_regression/regression.py | 92f0abe95efcc1db64d8e196df46a0c135aca0a8 | [] | no_license | YR123-123/python_learning | d60bcc05c272322dbe281dca1c86af9ac1c74a8d | 8a81f6b6a6e2aae8af70872da38112a6b19eef0a | refs/heads/master | 2022-12-20T15:59:30.947817 | 2020-09-05T08:18:18 | 2020-09-05T08:18:18 | 272,135,300 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,372 | py | import tensorflow as tf
import os
def linear_regression():
with tf.variable_scope("prepare_data"):
# 1)准备数据
x = tf.random_normal(shape=[100,1],name="features")
y_true = tf.matmul(x, [[0.8]]) + 0.7
with tf.variable_scope("create_model"):
# 2)构造模型
weights = tf.Variable(i... | [
"yangrui99128@163.com"
] | yangrui99128@163.com |
136c2f696912cba318bb9a20d680e25cc81c3422 | 6c69ed07acff2f98ffb60922fd1d57b501caa3de | /CPP_LiaoPython_Exp/oop/use_property.py | 313a7d22a3d4d6ca4157fa787e50e9ffe2ae7591 | [] | no_license | OldJohn86/Python_CPP | 9c7abfc3e03a0ac72cbe77ec31e58690fc0f805a | ae04246869fbc3ca135ab6e37f3f8927371c11af | refs/heads/master | 2021-06-03T19:50:49.553986 | 2021-03-08T08:18:25 | 2021-03-08T08:18:25 | 108,956,912 | 4 | 0 | null | 2019-05-28T08:48:28 | 2017-10-31T06:52:23 | Python | UTF-8 | Python | false | false | 501 | py | class Screen(object):
@property
def width(self):
return self._width
@width.setter
def width(self, value):
self._width = value
@property
def height(self):
return self._height
@height.setter
def height(self, value):
self._height = value
@property
def resolution(self):
return self._width * self._he... | [
"johnchen5372@gmail.com"
] | johnchen5372@gmail.com |
c095f936144341d38f5e5eb83d7fcd87870de1d2 | cd0d3b6ccfc53ad71cdff478e2d9ae93cdddefa0 | /Exercises/dayofweek.py | 3b8ac4b0d0f365ff37c0dd85241e8c496740bccc | [] | no_license | steve-77/Learning_Python | a5fa6a63dfe9185f26ab51bd278a4ac6c6d8b3b7 | 4e4b911614786f5893162420f77439ee65a6ad50 | refs/heads/master | 2023-03-18T11:57:54.993661 | 2019-02-22T15:11:47 | 2019-02-22T15:11:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 414 | py | print "Please enter a numberbe tween 1 and 31 inclusive"
date = raw_input()
daysofweek = 'SMTWtFs'*5
daysofweek = daysofweek*5
#print daysofweek
day = daysofweek[int(date)-1]
print daysofweek
print day
##print "Please enter a numberbe tween 1 and 31 inclusive"
##date = raw_input()
##daysofweek =
##daysofweek = day... | [
"calebkibet88@gmail.com"
] | calebkibet88@gmail.com |
70a530776feddee787d772b1d025a48370e07019 | 952d323f230600419ea703b1dc7164260bdc0673 | /cogs/love.py | b116a18fd9f8280e6d5e198c473634d2d5c1bdb8 | [] | no_license | Kloyc/5435346546456354 | eca277cf342400053757aa1d46e95bf0aa787036 | 936769846b3664c657851b0934150762ba83b9c0 | refs/heads/main | 2023-02-07T19:22:07.031169 | 2020-12-15T12:44:21 | 2020-12-15T12:44:21 | 321,664,250 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,892 | py | import discord
from discord.ext import commands
from discord.utils import get
import random
# Картинки :D
kek = "https://lifeo.ru/wp-content/uploads/gikfi-obnimashki-782.gif"
lol = "https://cdn.humoraf.ru/wp-content/uploads/2017/07/gif-21-10.gif"
rfr = "https://i.pinimg.com/originals/ba/a8/0b/baa80b2c50561bd5d95fe0ae... | [
"noreply@github.com"
] | noreply@github.com |
44cf3e93502c80360c84a5e60a3dd9b51d4df9f6 | ef01dc3fedeb81f0a1739822b92043592cff63b9 | /music/urls.py | fb1d9c4031a9455f706481dd5f1a57170dad47db | [] | no_license | laboyd001/python-django-music | 867cfe70cfccb108721155861003881b8040bc43 | 159a22b6beff93c8d223f5ab1c5655e9e914b920 | refs/heads/master | 2020-04-17T20:39:33.686191 | 2019-01-24T03:39:15 | 2019-01-24T03:39:15 | 166,915,444 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 795 | py | """music URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/2.1/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: path('', views.home, name='home')
Class-based v... | [
"lesley.a.boyd1@gmail.com"
] | lesley.a.boyd1@gmail.com |
9271d5b064cd96ddb9ecc1568fc4c7372e701a0d | 7bb5ed00771dc28670301d1637fa6f8a1d6a8ecc | /deprecated/migrations/versions/1c545fee7484_.py | 2862675bccac88b34aa7fe213b3bb9ad8eac5063 | [
"MIT"
] | permissive | andypoorman/honbot-server | 60bce3d3cf752848039ffec670fca2d130aebc4f | 271594f5ea011a9f2f0762c3bfcca7e33a7b8b3a | refs/heads/master | 2021-01-15T09:32:43.646270 | 2015-07-17T03:50:25 | 2015-07-17T03:50:25 | 39,233,626 | 0 | 0 | null | 2015-07-17T03:46:39 | 2015-07-17T03:46:39 | null | UTF-8 | Python | false | false | 506 | py | """empty message
Revision ID: 1c545fee7484
Revises: 5813c1b9304f
Create Date: 2015-04-15 23:57:22.997160
"""
# revision identifiers, used by Alembic.
revision = '1c545fee7484'
down_revision = '5813c1b9304f'
from alembic import op
import sqlalchemy as sa
def upgrade():
### commands auto generated by Alembic - ... | [
"scttcper@gmail.com"
] | scttcper@gmail.com |
08aa6e176fef1101f9c176d404be481fdc6d79e9 | c9f1af48710b6cbff11222f7fe265ed1fceb7e99 | /BBBDataLoggerMk2.py | 696767375d01a01222446571bdf3c66d47ce7994 | [] | no_license | DUEM/Data_Logger | 76280d9cf6218bef1fb747838313583f3066819e | 0b5cf6e08d2ba755e8c5f7e3bbe79932698cf0a6 | refs/heads/master | 2021-01-19T12:39:01.366757 | 2015-10-06T02:30:07 | 2015-10-06T02:30:07 | 26,801,755 | 0 | 1 | null | 2014-12-24T17:39:57 | 2014-11-18T09:29:41 | Python | UTF-8 | Python | false | false | 1,960 | py | import can
import mysql.connector as sql
import datetime
#################################### SQL FUNCTIONS WE WILL NEED #########################################################
def connect(username,password,database):
connect = sql.connect( user = username, password = password, database = database) # connected t... | [
"awwoof@hotmail.com"
] | awwoof@hotmail.com |
5bd5d8b3fb6a81743d777f2afcf0aa445e97c630 | 8d386b55963726b089e335dc057b62cc5a2861af | /ocdskingfisherprocess/maindatabase/migrations/versions/b2ff4e525bcb_add_indexes_to_foreign_keys.py | 675af1b9d473e62e518747d3f13938ee698697f1 | [
"BSD-3-Clause"
] | permissive | vlasvlasvlas/kingfisher-process | a3e673d4b8083050f2d25f4631a9ac1a2dd68a12 | b96353649c57a96e62e0b028e3978b8c0df2f97b | refs/heads/main | 2023-03-06T07:52:59.285856 | 2021-02-18T21:55:46 | 2021-02-18T21:55:46 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,807 | py | """Add indexes to foreign keys
Revision ID: b2ff4e525bcb
Revises: 53699ddc9872
Create Date: 2019-12-17 13:23:54.335035
"""
from alembic import op
# revision identifiers, used by Alembic.
revision = 'b2ff4e525bcb'
down_revision = '53699ddc9872'
branch_labels = None
depends_on = None
def upgrade():
op.create_ind... | [
"26463+jpmckinney@users.noreply.github.com"
] | 26463+jpmckinney@users.noreply.github.com |
fa2a351a5c06bc563409e7111a5b8756f79920b6 | e7288e8e8eefe00a51112bb4d0c8313b11d3b79e | /learning_logs/urls.py | ac7c5f9445b0df233237eac1d75674330e3f56ec | [] | no_license | Closeressi/learning_log | a8bd4a05bd4fc68a8c21fb043c1046a614d191ec | 23af8f607da1f656a1f7463da08c23416f9f3711 | refs/heads/master | 2023-05-02T22:06:22.141352 | 2021-05-19T07:30:06 | 2021-05-19T07:30:06 | 368,185,056 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 691 | py | """定义learning_logs的URL模式"""
from django.urls import path
from . import views
app_name = 'learning_logs'
urlpatterns = [
#主页
path('', views.index, name='index'),
#显示所有的主题
path('topics/', views.topics, name='topics'),
#特定主题的详细页面
path("topics/(?P<topic_id>\d+)/", views.topic, name='topic'),
... | [
"958044031@qq.com"
] | 958044031@qq.com |
6dbdc8bca55cc3695a10df67b4cbd4bf10e87178 | 8017f814bd418e51924532373a6aa2ab49e18fa5 | /otp_api/migrations/0001_initial.py | de95eb22dd6191bd7946667f18066771fbc9b4e4 | [] | no_license | pravin-yadav/django-otp-api-counter-based | 8fd28cab65ebd93e50273a02a383c7a49686e811 | 85aa75d4c6577e1016a449246dea57ac192f20e0 | refs/heads/main | 2023-01-06T07:28:35.245069 | 2020-11-06T11:26:30 | 2020-11-06T11:26:30 | 310,576,090 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 623 | py | # Generated by Django 3.0.7 on 2020-11-06 10:15
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='PhoneModel',
fields=[
('id', models.AutoFie... | [
"work.coderpravin@gmail.com"
] | work.coderpravin@gmail.com |
afa780e0f4321a1068d25a0a735061aefce29115 | 88cf3aa4eb13cda1790cd930ed2cb8c08964c955 | /chainercv/utils/image/write_image.py | b5610c992a0e0703f3c0c5571fc051b16454d9a8 | [
"MIT"
] | permissive | mingxiaoh/chainercv | 6ae854f445b7a14f55e41b51b5e4226224702b95 | cfb7481907efe93e13c729ae2d9df4706d3975a6 | refs/heads/master | 2022-11-11T20:44:31.875419 | 2018-05-03T04:09:13 | 2018-05-03T04:33:15 | 131,939,645 | 1 | 2 | MIT | 2022-10-26T00:07:37 | 2018-05-03T03:58:59 | Python | UTF-8 | Python | false | false | 517 | py | import numpy as np
from PIL import Image
def write_image(img, path):
"""Save an image to a file.
This function saves an image to given file. The image is in CHW format and
the range of its value is :math:`[0, 255]`.
Args:
image (~numpy.ndarray): An image to be saved.
path (str): The ... | [
"yuyuniitani@gmail.com"
] | yuyuniitani@gmail.com |
894e88c9defffd266e661be418f90bd80700b29a | 07dbbd94b3f6a25a289fcad070f868ba319d2a64 | /color-depth-reduction/Fashion-MNIST/util.py | b67432391e94a86bd0fd3cdbb523fba448a863d9 | [
"Apache-2.0"
] | permissive | jfc43/pixel-discretization | 49a7d52f57b33cbbdf5efd60df020b334cb3df2b | 955da976dbc041f59c09ebcb32715552078fb0c9 | refs/heads/master | 2022-03-16T19:36:02.542507 | 2022-02-17T02:37:08 | 2022-02-17T02:37:08 | 174,421,930 | 6 | 1 | null | null | null | null | UTF-8 | Python | false | false | 373 | py | import numpy as np
from sklearn.neighbors import KDTree
def preprocess(images0, codes):
images = np.copy(images0)
kd = KDTree(codes, metric='infinity')
new_images = []
for img in images:
points = img.reshape(-1,1)
inds = np.squeeze(kd.query(points,return_distance=False))
new_images.append(codes[ind... | [
"jfc43@jfchen666@gmail.com"
] | jfc43@jfchen666@gmail.com |
ffd937ad1355c18b19c876e02d8b14088dfea591 | 8fab47a4eb74cb5614f3e472e8480928e6690153 | /knit/db_knit/__init__.py | 45bd40e58487396af78842820c9eea368afd5fa4 | [] | no_license | mdumbrava/Knitting-Site | 0742f211f6c2a1ea81fd6bac98e32e39965500f7 | 4034bfc2e45dc663ffeba3a558ff3223b3b20cce | refs/heads/main | 2023-06-27T19:54:13.251703 | 2021-08-02T19:35:26 | 2021-08-02T19:35:26 | 365,350,261 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 44 | py | from .users import *
from .products import * | [
"mihaela.dmbrv@gmail.com"
] | mihaela.dmbrv@gmail.com |
eb0161794d91eb86a57183ca40268a732425e6e8 | 1d081cc18c4c5fd6d23a846a5fc843cf1c730bb1 | /elearn/serializers.py | 19f2786c1351291390d546e5e0b5477bc3070562 | [] | no_license | Aarthif-Nawaz/e-learning | 9bed7e722912c61bd8fd0546588662a0d22ef06e | 059ed218bf4c25113bd1726984c6004689662dcc | refs/heads/master | 2023-07-20T15:37:01.313066 | 2021-07-30T21:26:53 | 2021-07-30T21:26:53 | 384,365,284 | 0 | 6 | null | 2021-07-20T13:08:57 | 2021-07-09T08:00:29 | Python | UTF-8 | Python | false | false | 16,056 | py | from rest_framework import serializers
from elearn.models import *
class ShotsCategorySerializer(serializers.ModelSerializer):
class Meta:
model = ShotsCategory
fields = '__all__'
class ShotsSubCategorySerializer(serializers.ModelSerializer):
class Meta:
model = ShotsSubCategory
... | [
"mohammed.2017313@iit.ac.lk"
] | mohammed.2017313@iit.ac.lk |
8df95b4c5afd3d8f93ea1b3be572594251589ad4 | 8b0cd05a9cd2b01db156c21c89f85bb737ca1459 | /AWSrecipe/distance.py | 1d5eb2513d2e9512ab57af4e3459b75ca9029d03 | [] | no_license | ylyhlh/recipe_aws | 518c8df28a1a4aa3e16576af7bf8fc3db8879664 | 9d3ffbce703e137142659adbb3d1174246476bce | refs/heads/master | 2020-05-18T12:13:42.177902 | 2014-05-08T20:42:38 | 2014-05-08T20:42:38 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,668 | py | import os, urllib, urllib2, time, csv
from xml.dom.minidom import parseString
#url = "http://maps.googleapis.com/maps/api/directions/xml?origin=" + "40.63319,-73.99440" + "&destination=" + "42.25446,-92.21648" + "&sensor=false"
#url = "http://maps.googleapis.com/maps/api/distancematrix/xml?origins=" + "40.63319,-73.99... | [
"martinliuhao@gmail.com"
] | martinliuhao@gmail.com |
7d726df5c430491490c8dbb90f409c3dec17e9eb | 50ac7107bf68f5ca3385efe998d221d7239efb50 | /TestServer/djangoServer/mysite/remoteAcademy/static/remoteAcademy/backend/printer.py | 05ac366a78f703df78d3cd723b9622631dcc3a7a | [] | no_license | RoboticsLabURJC/2018-tfm-Carlos-Awadallah | e15f23601b8cd042f58163bfa2378b35148c3af7 | 38626d0689c005850a467707fc7d1144d9de5eaa | refs/heads/master | 2020-03-23T22:40:46.673383 | 2020-03-11T07:59:40 | 2020-03-11T07:59:40 | 142,190,880 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 301 | py |
import matplotlib.pyplot as plt
import numpy as np
import time
def printImage(image):
plt.axis('off')
a = plt.imshow(image)
plt.show()
def printVideo(image):
#plt.close()
plt.axis('off')
v = plt.imshow(image) #, block=False)
plt.show()
time.sleep(2)
plt.close()
| [
"carlosawadallah@gmail.com"
] | carlosawadallah@gmail.com |
d518a6af6e11fbfe48bb06e63440ad59b5fbbf84 | c18015d6189b2c5842ae3adaf401263e6857409d | /main_loop_simulateur.py | 427b4b4a4ac3824ccf047d8ca5f9b770110f8113 | [] | no_license | anthonygi13/Oral_simulateur_RV-JR | 007f9db21e5c6cf2f50c2e28cf75933a89381f9a | 1f537412e58ee718a219a92a5da08d2a04e00302 | refs/heads/master | 2020-03-13T23:40:26.151648 | 2018-04-29T13:09:02 | 2018-04-29T13:09:02 | 131,340,010 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,357 | py | # Authors: Anthony Giraudo, Kari Hichma, Kilian Mac Donald, Louise Marinho
# 23 mars 2018
# main_loop_simulateur.py
import pygame
from pygame.locals import *
pygame.init()
from conversions import *
from classes_simulateur import *
import time
# images
image_roue = "champi.png"
image_capteur = "r2d2.jpg"
dimensions_im... | [
"anthony.giraudo@etu.univ-amu.fr"
] | anthony.giraudo@etu.univ-amu.fr |
eb01ea53d5bd47975ab1ad3f8327eb110318a968 | c0f42b2bc7d8e605cc08bc3c2ea4fedb324d9aaa | /car/car.py | 26c8d9dcabe48aa062a5afd8355f9137668e6424 | [] | no_license | bendhouseart/InClass | ca60a3caeaab1f080303053c7e14fff32070fd4a | 4ccd0f07c444f3beb7fb1c8f6eb5dad7e505aa0a | refs/heads/master | 2021-01-22T02:08:21.355781 | 2017-06-04T02:34:43 | 2017-06-04T02:34:43 | 92,336,065 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 487 | py | class Car:
def __init__(self, model, wheels, color, doors):
self.model = model
self.wheels = wheels
self.color = color
self.doors = doors
def number_of_wheels(self):
self.wheels = 4
def color(self, color):
self.color = color
def number_of_doors(self, doors):
self.doors = doors
def __str__(self... | [
"anthony.e.galassi@gmail.com"
] | anthony.e.galassi@gmail.com |
46e104da6da209507165841429818c5c4c4fc997 | 96a02ab50eb0418c50e887b7ead366b5165e8cae | /polymorphism_06/in_class/image_area_04.py | 0a996278c65f5738824bd60df319196f2cf409af | [] | no_license | AlexNedyalkov/Python-OOP-2020 | c9f47145bc4df1c548c9dcf28316f92365642a3c | 7ee7172bc0f4ba57282558325a02ba4a006f93d9 | refs/heads/master | 2023-03-23T04:40:06.786372 | 2021-03-22T11:14:23 | 2021-03-22T11:14:23 | 350,313,340 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,271 | py | '''
Create a class called ImageArea which will store the width and the height of an image. Create a method called get_area()
which will return the area of the image. We have to also implement all the magic methods for comparison of two image
areas (>, >=, <, <=, ==, !=) which will compare their areas
'''
class Image... | [
"nedyalkov6@gmail.com"
] | nedyalkov6@gmail.com |
bae1ee85529bad01328f91ec316207f6cf065957 | f7110aaab742fc92179302c5874691078ed05158 | /book_author_shell/book_author/views.py | 33d21d80d85a99cfc6465ff8b778e23db2d583fc | [] | no_license | Moha327/python_extra | 0f9252a46a652ffe83d97cd0d6906a1835c2abbf | a3e1b31831578484c651d76bfd01173fe9d6eb10 | refs/heads/master | 2023-05-23T14:03:21.962212 | 2021-06-16T13:50:06 | 2021-06-16T13:50:06 | 377,511,352 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,341 | py | from django.shortcuts import render,HttpResponse,redirect
from .models import *
# Create your views here.
def index(request):
context = {
"books": Book.objects.all(),
"authors": Author.objects.all()
# 'books':models.allBook()
}
return render(request, 'index.html' , context)
def... | [
"m7amad9595@outlook.com"
] | m7amad9595@outlook.com |
e20fb55ee066307eb9118a8c58a7551ff43d93fb | d90d04745c6e65f51b5a06c1cf5d0130d0d9411e | /test.py | 32d3d90ffd490b34e14a74b3259bc861392e0de0 | [] | no_license | seandmurray/missing_letters_python | 5c6026f8466c5c091da0b8fd2b02f11db0f2847e | e7312ee9f45f66f1af75fbca6fc8d6d0e81c4b9d | refs/heads/master | 2020-07-03T06:47:01.321821 | 2019-08-11T23:38:35 | 2019-08-11T23:38:35 | 201,826,661 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 511 | py | import unittest
import missingletters
class TestMissingLetters (unittest.TestCase):
def test_noletters(self):
self.assertEqual('abcdefghijklmnopqrstuvwxyz', missingletters.processLine(''))
def test_allletters(self):
self.assertEqual('', missingletters.processLine('abcdefghijklmnopqrstuvwxyz')... | [
"sean@murray.cc"
] | sean@murray.cc |
4ebc7d9c4b30c4e5cbfa66a6f3a425710f432d0f | 28cc9d64c58b8b891c17a9f313d4c76e1becf0c1 | /lections/binary.py | ef269f551b3f1c641a06a5459f22f77d1e112168 | [] | no_license | h-yaroslav/pysnippets | 795881cd3f1118c0e354a9b05d4d261eaf6c9657 | f4d38796ee7fa7dc6f1de29860f91b3b5dc6f1e0 | refs/heads/master | 2021-09-25T00:56:45.783455 | 2021-09-15T09:44:06 | 2021-09-15T09:44:06 | 13,030,155 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 426 | py | #!/usr/bin/python
# -*- coding: latin-1 -*-
import os, sys
def Denary2Binary(n):
'''convert denary integer n to binary string bStr'''
bStr = ''
if n < 0: raise ValueError, "must be a positive integer"
if n == 0: return '0'
while n > 0:
bStr = str(n % 2) + bStr
n = n >> 1
retu... | [
"h.yaroslav@gmail.com"
] | h.yaroslav@gmail.com |
980505b76a38c4254fc0f3bfc680f77aa46742e0 | 6b41cd9ca8d13c09b20266ed24b8083d32ace91e | /Aula04/Desafio03.py | 2f039d5c1fe5a5bd2933fa8cce47ccb75f9f837e | [] | no_license | sylviocesart/Curso_em_Video | 345e55aacaa77aabaa77315f34e2fc698d63afa3 | c87f708f57ee4b1b11cc71b8cdbd796683a26acb | refs/heads/master | 2021-04-27T00:23:49.883367 | 2019-07-24T20:36:04 | 2019-07-24T20:36:04 | 123,805,747 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 432 | py | """
Crie um script que leia dois números e tente
mostrar a soma entre eles
"""
num1 = input('Primeiro número: ')
num2 = input('Segundo número: ')
print('A soma é',num1 + num2) # O resultado foi a junção dos números.
# Agora, fazendo a soma realmente dos números
print('A soma é', int(num1) + int(num2)) # Aqui o result... | [
"sylvio.cesart@gmail.com"
] | sylvio.cesart@gmail.com |
7ed1c30363e1f08e66f3739c047e711d18b9a751 | 0cd64f3f67c6a3b130a788906da84ffc3d15396a | /Library/lib/python3.9/site-packages/terminado/__init__.py | b719a2732b62668ad85459f6c3593ec181c85a6a | [
"MIT",
"BSD-3-Clause",
"0BSD",
"LicenseRef-scancode-free-unknown",
"GPL-1.0-or-later",
"LicenseRef-scancode-other-copyleft",
"LicenseRef-scancode-python-cwi",
"Python-2.0"
] | permissive | Ryorama/codeapp | 32ef44a3e8058da9858924df211bf82f5f5018f1 | cf7f5753c6c4c3431d8209cbaacf5208c3c664fa | refs/heads/main | 2023-06-26T09:24:13.724462 | 2021-07-27T17:54:25 | 2021-07-27T17:54:25 | 388,520,626 | 0 | 0 | MIT | 2021-07-22T16:01:32 | 2021-07-22T16:01:32 | null | UTF-8 | Python | false | false | 544 | py | """Terminals served to xterm.js using Tornado websockets"""
# Copyright (c) Jupyter Development Team
# Copyright (c) 2014, Ramalingam Saravanan <sarava@sarava.net>
# Distributed under the terms of the Simplified BSD License.
from .websocket import TermSocket
from .management import (TermManagerBase, SingleTermManager... | [
"ken.chung@thebaselab.com"
] | ken.chung@thebaselab.com |
e77023d2e1ce8b3c376a53e0f999132204293667 | 5d29cf45f454327ae4281777d1f4c8a4ceaf8c19 | /Arrays/merge_sorted_arrays.py | 1474d9601e4db1432d5814e16df946d9c1db212d | [] | no_license | jmtzt/data-structures-algorithms | 6eb34c4dfb0d78842b3bc5f40c64b2bb99e5734e | f5a293691a9d007493eb3c0d519d5dc9666f3416 | refs/heads/main | 2023-05-05T00:30:17.476055 | 2021-06-01T21:23:56 | 2021-06-01T21:23:56 | 370,813,239 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 490 | py | def merge_sorted(arr1, arr2):
if len(arr1) == 0 or len(arr2) == 0:
return arr1 + arr2
merged_arr = []
i = 0
j = 0
while i < len(arr1) and j < len(arr2):
if arr1[i] <= arr2[j]:
merged_arr.append(arr1[i])
i += 1
elif arr2[j] < arr1[i]:
mer... | [
"jmttozato@gmail.com"
] | jmttozato@gmail.com |
c7f246eae7e802395dc6f0c86357b7176a75fec7 | 9b69347440396c71858e33bea8fbf2f47bae0cdb | /onmt/Beam.py | 0fe876757b5c26e7c088ac339a939b98d4babaac | [
"MIT"
] | permissive | caleblu/OpenNMT-py | 055fb0b11c2d37508a631bb69918ede08c38ca68 | de52e6605d06a01572574b80c0759a5a88b313dc | refs/heads/master | 2021-05-09T11:39:26.348623 | 2018-01-26T03:59:02 | 2018-01-26T03:59:02 | 118,995,754 | 0 | 0 | null | 2018-01-26T02:38:07 | 2018-01-26T02:38:06 | null | UTF-8 | Python | false | false | 5,556 | py | from __future__ import division
import torch
import onmt
"""
Class for managing the internals of the beam search process.
Takes care of beams, back pointers, and scores.
"""
class Beam(object):
def __init__(self, size, n_best=1, cuda=False, vocab=None,
global_scorer=None):
self.size ... | [
"kaijil@andrew.cmu.edu"
] | kaijil@andrew.cmu.edu |
39f8c2975ea7a973b33151d0ac6e33d8d2fc012f | d6cc875c99ad0edc8976a5188b849a593d4a33e4 | /DateInvalid.py | 643019d2343323025ad69755b6ae2291fa73a371 | [] | no_license | Glink31/GZherebtsov | 6b89bbc462215ead1d56a76b7a8ee978d020cb01 | d54171886cf9b6ecb583e66d05716959f68050e4 | refs/heads/main | 2021-07-03T02:56:11.528375 | 2021-01-28T13:00:11 | 2021-01-28T13:00:11 | 218,539,470 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 47 | py | class InvalidDateException(Exception):
pass | [
"Goshazherebtsov@gmail.com"
] | Goshazherebtsov@gmail.com |
b3a5241c24af553d2a0c526109f3ddbd07ba62d2 | 762bb9215f47b2eaec38fad9e37b40a1dfe71d20 | /kamworld.py | 840f3cc0a0c390f9601121920db64583d416573d | [] | no_license | kremiszewski/kamworld | 9aa78050a52e5f53c3d06511f8525f7ed6a62027 | bac8cc64a394479cd256225e08bd4e9cefb73fe6 | refs/heads/master | 2020-03-25T00:51:58.989778 | 2018-08-01T21:20:42 | 2018-08-01T21:20:42 | 143,209,644 | 0 | 1 | null | 2018-10-16T00:34:32 | 2018-08-01T21:17:39 | Python | UTF-8 | Python | false | false | 1,303 | py | name = input("Enter your name: ")
race = input("State your race! (human - elf - dwarf - orc): ")
if race == "human":
print("You are a human!")
print(" MM ")
print(" /..\ | ")
print(" \--/ | ")
print(" | | ")
print(" *--+---+ ")
print(" | | ")
print(" ^... | [
"kamil.remiszewski@stonybrook.edu"
] | kamil.remiszewski@stonybrook.edu |
f263b576cb1d335942b621ed03298a3ebbc9539d | a336180f32b8b7529469514faae997f7a32b071d | /dags/scrap_videos.py | 0276e35a8fcdc14dbaaee77e5e73221c08dc5edd | [] | no_license | AllanKT/youtube_extraction | e9a6e5453f83cc3ec1d478b1b14623d98295a6bf | 25473e90f0abdcd78d9e3508f4e7805b48ac86db | refs/heads/main | 2023-08-11T07:02:22.405582 | 2021-10-11T12:22:55 | 2021-10-11T12:22:55 | 415,324,864 | 0 | 0 | null | 2021-10-11T12:22:49 | 2021-10-09T14:00:44 | null | UTF-8 | Python | false | false | 675 | py | from airflow import DAG
from airflow.operators.dummy_operator import DummyOperator
from airflow.operators.bash_operator import BashOperator
from airflow.operators.python_operator import PythonOperator
from datetime import datetime, timedelta
from src.tasks import *
from src.settings import *
with DAG(
dag_id='sc... | [
"allankltsn@gmail.com"
] | allankltsn@gmail.com |
73a690eea5351ab4f5447b0084f0e6bade1ab4d0 | 16e1ad2c98ed25fed2f4beaa7b53ffa739f89f0b | /Shortest path.py | 04e6fbd86741ec64de259f90659a086269c31add | [] | no_license | ysachinj99/PythonFile | 85c18135402366cd26f329dc285c7bd15b01138c | c45c88ed2db376529d265afe283a07e840c2a261 | refs/heads/main | 2023-04-29T20:19:11.423064 | 2021-05-23T07:18:00 | 2021-05-23T07:18:00 | 343,701,949 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,613 | py | graph = {'A':['B','C'],
'B':['C','D'],
'C':['D'],
'D':['C'],
'E':['F'],
'F':['C']}
def find_path(graph,start,end,path=[]):
path = path + [start]
if start == end:
return path
if(start not in graph):
return... | [
"noreply@github.com"
] | noreply@github.com |
ff8d0a1e505d29b23839c0a3c44638f35c5fa273 | 395c18db541d20361443c00d0e05a668a120f0d2 | /for문/2439.py | cb065327fc0a06fa585ae01a0685315a78873738 | [] | no_license | 1KimJiHyeon/BaekJoon-Algorithm | 619a25100c801bab4dd4735fd40fcca08315e36c | 2dd2781299ab58194987ab9e4d6f6370907877af | refs/heads/master | 2020-12-20T18:48:29.104479 | 2020-03-10T08:40:46 | 2020-03-10T08:40:46 | 234,717,049 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 75 | py | N = int(input())
for i in range (1,N+1):
N-=1
print((" "*N)+("*"*i)) | [
"noreply@github.com"
] | noreply@github.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.