blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 2 283 | content_id stringlengths 40 40 | detected_licenses listlengths 0 91 | license_type stringclasses 2
values | repo_name stringlengths 3 135 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 68 | visit_date timestamp[ns]date 2015-07-25 20:53:29 2023-09-06 10:46:05 | revision_date timestamp[ns]date 1970-01-01 00:00:00 2037-05-03 13:00:00 | committer_date timestamp[ns]date 1970-01-01 00:00:00 2036-02-09 17:40:36 | github_id int64 1.61k 691M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 24
values | gha_event_created_at timestamp[ns]date 2012-06-03 10:21:33 2023-09-14 21:59:50 ⌀ | gha_created_at timestamp[ns]date 2008-03-27 23:40:48 2023-09-13 22:40:33 ⌀ | gha_language stringclasses 250
values | src_encoding stringclasses 27
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 6 10M | extension stringclasses 289
values | filename stringlengths 1 218 | content stringlengths 6 10M |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
94055f3eb86b025db335f2dfb2c75cb07e18c7d6 | 95e0839e0f77c441c77cbe239158e5934fa01bdc | /Statrec_Toolbox_Object.py | c4315fe6d816652baa3f2981e70bedb88dcd023c | [] | no_license | hgazali/AutoBuffett | 924bfaffe73eeee4aa02efa41c13f2f79c707927 | 8481ff751ed53441c7151efa15e476adcc1f288c | refs/heads/master | 2020-12-01T12:07:41.989930 | 2016-06-27T08:36:46 | 2016-06-27T08:36:46 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,423 | py | Statrec_Toolbox_Object.py | # -*- coding: utf-8 -*-
"""
Created on Fri Mar 18 22:55:58 2016
Algorithm:
1. call init by main
2. call update every iteration, updating the list
3. call eof_shutdown() to calculate the computational intensive stuff
and print everything of interest
@author: Mats Richter
"""
import n... |
573f0a9eba77bccdc796d6331241a75932a32e9e | 7af161332a67d905b33e6517a89c723f1725a378 | /unidade2/media_aluno/media_aluno.py | 9cc6d7057fbace515cf453358627e1dee95c0351 | [] | no_license | Itamar-Farias/TST_P1_UFCG | f4839a18d18d3c5cecdf329a8fc576349c1bc2f9 | c02a0f3911f5cada6aa1d38d211e364ac0527075 | refs/heads/master | 2023-04-06T10:27:06.281918 | 2021-04-08T12:48:45 | 2021-04-08T12:48:45 | 355,337,389 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 221 | py | media_aluno.py | # coding: utf-8
# Itamar da Silva Farias 115210021
# Programação I
nota1 = float(raw_input())
nota2 = float(raw_input())
nota3 = float(raw_input())
media = nota1 * 0.2 + nota2 * 0.3 + nota3 * 0.5
print "%.1f" % media
|
e244cc5a5d67790e98cd467c33601a5528e5175c | a7c1f19a95982de2c0bb7de571cbc4dd161122f1 | /snuba/query/snql/parser.py | e7baa737e99a5525d7162bae73847f211a08536b | [
"BUSL-1.1",
"Apache-2.0"
] | permissive | fpacifici/snuba | ad9d438849a41e143d8ecc587ea39fde1d9dde34 | cf732b71383c948f9387fbe64e9404ca71f8e9c5 | refs/heads/master | 2021-07-16T14:07:36.728642 | 2020-10-29T17:12:07 | 2020-10-29T17:12:07 | 219,029,996 | 0 | 0 | Apache-2.0 | 2019-11-01T19:07:57 | 2019-11-01T17:15:34 | null | UTF-8 | Python | false | false | 14,948 | py | parser.py | from typing import Any, Iterable, NamedTuple, List, Sequence, Tuple, Union
from parsimonious.grammar import Grammar
from parsimonious.nodes import Node, NodeVisitor
from snuba.datasets.dataset import Dataset
from snuba.query.conditions import (
OPERATOR_TO_FUNCTION,
binary_condition,
combine_and_conditions... |
310de2b80efe3699f4bae2b7957285382022492f | 2f1c9bba6ba14a46f04a861e70dbf6d50d96535b | /nand2Tetris/projects/11/CompilationEngine.py | 1f48e02c852313e2c3bb5cb48f5cfb2e0bae1f40 | [] | no_license | leovcunha/CS_learning_projects | 8a3ed5ba76ad81a22c7162835b39734726028953 | 4cbd45192738c2850b308b35ee9b0c95de798748 | refs/heads/master | 2021-01-20T01:23:02.738739 | 2019-07-02T02:11:07 | 2019-07-02T02:11:07 | 89,267,880 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,910 | py | CompilationEngine.py | import os
from KeyValueIndex import *
from Constants import *
class CompilationEngine(object):
'''creates xml files for later parsing into VM commands'''
def __init__(self, infile, outfile):
self.__m_infile = infile
self.__m_outfile = outfile
self.__m_translated = []
self.__m_c... |
3057d358b4804fb8074024f5cc1f303e87ff3b2f | 29861766a887b6ed060d25eebd18b408954e0fd9 | /tools/directory_tree.py | 0d0e76e70c1ffe1024431a499c2e972bcf8bbc53 | [] | no_license | alecordev/cli-tools | cca19a0767ed1130ae5939e1846edff649672a32 | 28ffb8842d1089c746bb9c3a8b500c3f093fc850 | refs/heads/master | 2023-03-16T07:21:49.073146 | 2023-03-06T19:56:16 | 2023-03-06T19:56:16 | 85,628,388 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,766 | py | directory_tree.py | """ Print a directory tree """
import os
import sys
def directory_tree(path, show_files=True, indentation=4, file_output=False):
"""
Shows the contents of a directory in a tree structure.
Arguments
---------
path (string): path of the root folder we want to show.
show_files (boolean): Whethe... |
82fb15ddb529dfb627670c8f04f17a2d33d2ae92 | c7daa48c1b0b5d58ed3f894180a7b90978ec6313 | /Challenges/RGB_Colors.py | 572ef790f8f5473038eca7f4b73d7f46d1143b01 | [] | no_license | ariellewaller/Python-Crash-Course | 7775fc4079273ac5204d2427c88b028e5a1000a2 | dd51d7df9411ba449f5fab913876bb632393881b | refs/heads/master | 2022-11-15T17:17:18.711771 | 2020-07-15T03:22:39 | 2020-07-15T03:22:39 | 270,038,979 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 12,872 | py | RGB_Colors.py | # Photo Filter 3-1: RGB Colors
# In one of the most common formats, a color is represented as a set of three
# values from 0-255. Each value represents how much red, green, and blue light
# to mix when displaying a pixel. The color [255, 0, 0] represents the
# brightest possible red, [0, 255, 0] represents b... |
f121a6fcab9e9af716e3cfc94bb652deefe9451b | 80320c3db8ce33fb9a19e8a3950974d494c4b7e2 | /Brute-Force/14501 - 퇴사.py | 9f70a2459f0aaead9b55e82281dc190d459eb351 | [] | no_license | Yoo-an/Algorithm | 2397f91f24272fb51cd73ffb1695fce913ff28f2 | 43bad3befe1636c5fc32f0d3e8371b62de46a108 | refs/heads/master | 2023-03-29T22:26:38.385436 | 2021-04-23T07:43:42 | 2021-04-23T07:43:42 | 356,234,751 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,367 | py | 14501 - 퇴사.py | # 문제
# 상담원으로 일하고 있는 백준이는 퇴사를 하려고 한다.
#
# 오늘부터 N+1일째 되는 날 퇴사를 하기 위해서, 남은 N일 동안 최대한 많은 상담을 하려고 한다.
#
# 백준이는 비서에게 최대한 많은 상담을 잡으라고 부탁을 했고, 비서는 하루에 하나씩 서로 다른 사람의 상담을 잡아놓았다.
#
# 각각의 상담은 상담을 완료하는데 걸리는 기간 Ti와 상담을 했을 때 받을 수 있는 금액 Pi로 이루어져 있다.
#
# N = 7인 경우에 다음과 같은 상담 일정표를 보자.
#
# 1일 2일 3일 4일 5일 6일 7일
# Ti 3 5 1 1 2 4 2
# Pi 1... |
e0d813318885fcdb5547f0163b96fa3c89b28515 | 071217bad96a548b181cd832a35350763e526662 | /marauder/locate_me_api.py | f3e8dc3f05fd0faf6dc80466a8634655f762aa29 | [
"Apache-2.0"
] | permissive | TeamSirius/MultiUser | e3167fe08915b0a33f59da00d364d4f9a4284748 | 036cdc008b013a4c4f9befbd904b1f40fe6297c9 | refs/heads/master | 2016-09-06T18:28:41.517098 | 2015-07-08T01:40:54 | 2015-07-08T01:40:54 | 30,277,260 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 11,943 | py | locate_me_api.py | from django.conf.urls import url
from django.db import connection
from tastypie.resources import Resource
from tastypie.authentication import ApiKeyAuthentication
from tastypie.exceptions import ImmediateHttpResponse
from tastypie.http import (HttpAccepted, HttpForbidden,
HttpBadRequest, Http... |
d79f9aa3bdd8b48285d1d3e8cddebf2fcb918f25 | 9d3e046554f3f91d9b95d2843c5e3ed8390dcc1c | /park_it/src/filters.py | f134451fe0df261e3313ed8d59c7ef612c4a1bfd | [] | no_license | kenish26/Car-Booking-System-Django | e8bd30ad4f8bff7e04fc0002649ded73b2f53f50 | 0d291c0fbf6dbccfb422386dcc56dda478ec5892 | refs/heads/main | 2023-08-31T00:17:44.161380 | 2021-02-27T00:17:58 | 2021-02-27T00:17:58 | 342,733,907 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 990 | py | filters.py | import django_filters
from django_filters import DateFilter,CharFilter
from django import forms
from .models import *
class BookingFilter(django_filters.FilterSet):
# start_date = DateFilter(field_name = "date_created", lookup_expr='gte')
# end_date = DateFilter(field_name = "date_created", lookup_expr='lte')... |
17ff929bafa0edaffb31fb9fbee4345bfac700a9 | 405a0ea1d991c5abdc99daea51f1efecc83c51f3 | /Praktikum 06/Latihan/Latihan 3(faktorial).py | ebcbacabfad6466729bdd72f6bcc286f6a7a8e19 | [] | no_license | wiratmo/Python-Projects-Protek | e09abd038e10224fac0ce16d128245b9dfe7b815 | 67bcfed7ce8f1ce90716d9e839097cb90b8dc76d | refs/heads/master | 2023-04-12T06:47:03.282306 | 2021-05-11T15:07:47 | 2021-05-11T15:07:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 617 | py | Latihan 3(faktorial).py | def faktorialnya(n):
"""Faktorial buat per angka"""
fkt={}
if n in fkt:
return fkt[n]
elif n == 0 or n == 1 :
return 1
fkt[n] = 1
else:
faktorial = n * faktorialnya(n-1)
fkt[n] = faktorial
return faktorial
def kombin(c,d):
proses = faktori... |
cd1cf7a9188c26cc87fa13dbacf279fcf141dcd6 | 15f321878face2af9317363c5f6de1e5ddd9b749 | /solutions_python/Problem_199/1218.py | 03776d094fa0bb89e971a583f41553d52d4aefc0 | [] | no_license | dr-dos-ok/Code_Jam_Webscraper | c06fd59870842664cd79c41eb460a09553e1c80a | 26a35bf114a3aa30fc4c677ef069d95f41665cc0 | refs/heads/master | 2020-04-06T08:17:40.938460 | 2018-10-14T10:12:47 | 2018-10-14T10:12:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,043 | py | 1218.py | from sys import *
import math
def readints():
return list(map(int, stdin.readline().split()))
def solve(S, K):
# print(S)
k = 0
while k < len(S) and S[k] == "+":
k += 1
S = S[k:]
if len(S) == 0:
return 0
if len(S) < K:
return float('-inf')
else:
S = l... |
ec60bb435e7e78e74b3dfcdd87291d83f1d82c47 | 4592d7a83df7c7baeff91e5ef046cde59cf11dd3 | /Python/Python_OOP/Email_Validation/apps/Email/models.py | 21d48fd5fc9a97b80fedf48ad3178df113c612e7 | [] | no_license | gxnews8/CodingDojo | 8136870b2653c6337d418dc03a4754fc66fd8a9e | b81faab167aabd0abad1aecdbf3594d6b43d740d | refs/heads/master | 2021-01-11T08:17:27.539115 | 2017-06-24T20:04:05 | 2017-06-24T20:04:05 | 76,394,057 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 287 | py | models.py | from __future__ import unicode_literals
from django.db import models
# Create your models here.
class Email(models.Model):
email = models.CharField(max_length = 255)
created_at = models.DateTimeField(auto_now_add = True)
updated = models.DateTimeField(auto_now_add = True)
|
58d9830d3ced943b753bcfa946a60fe4cb66eef5 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02817/s870881790.py | f4536f6cc65a8ba2cce3816cc0a69caa83201580 | [] | no_license | Aasthaengg/IBMdataset | 7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901 | f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8 | refs/heads/main | 2023-04-22T10:22:44.763102 | 2021-05-13T17:27:22 | 2021-05-13T17:27:22 | 367,112,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 56 | py | s870881790.py | S, T = map(str, input().split())
print('%s%s' % (T,S))
|
f9dc9dd43d51922a590d7a00cc0e171854cc183e | e14f7957195af2cadbf9b5102b9dfc7b62251cf5 | /peakAnalyzer/basespace/urls.py | 805e6f631e48378878e8d4020096757fd5017515 | [] | no_license | zzz2010/basespace-ui | f8fcfe830de93f5ce31bf3d774a8c881a0048e80 | 663bb7607354465960fc8d1335275b5c7002a04d | refs/heads/master | 2021-01-10T20:26:26.757006 | 2014-03-18T02:50:12 | 2014-03-18T02:50:12 | 32,113,315 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 961 | py | urls.py | #from django.conf.urls import patterns, include, url
from django.conf.urls import *
#from django_consultants.views import *
# Uncomment the next two lines to enable the admin:
# from django.contrib import admin
# admin.autodiscover()
urlpatterns = patterns('basespace.views',
url(r'^login/$', 'loginUser'),
url(r'^$... |
41ca92cc3e3850e3e24d28a55e594ae386bab853 | dba1a54ffa438e31765f9f4547856a1079e6d3fc | /Problem(2.5).py | 94092f9d6c77614d760d43bd9c4d75da5df1f47a | [] | no_license | Bhumiika16/Python_Assignment | c8ae17897e42cbafa5eac387a21c03984fb666ec | 3b089ddf29eb83d033845a5d1a08fbc7db0066a5 | refs/heads/main | 2023-03-12T05:12:06.997090 | 2021-03-02T13:54:51 | 2021-03-02T13:54:51 | 343,503,413 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 520 | py | Problem(2.5).py | #Length, Breadth and Heigth of both the cuboid is taken as an input from user.
dimensions_x = list(map(int, input().split(",")))
dimensions_y = list(map(int, input().split(",")))
#Initialized volume of both the cuboid as One.
volume_of_x, volume_of_y = 1, 1
#Loop is run 3 times to multiply all the 3 dimesnions of the... |
fbc17574b9bbbf0a904d35eea2da63af7c9c3643 | c4cc3af7dd48687cb1e34ae7a89e51f5e11fbe2f | /hogar/almacen/migrations/0017_auto_20210104_1845.py | 362c2dc70048ed3b06fcdd45558cc313c7012893 | [] | no_license | BadiaValdes/DjangoCodeFarm | 2e5dad53043f0accc6eaaedf385297e710f2ceaa | a00857e98d35f781a6b2561c2e491f2f563b97e5 | refs/heads/main | 2023-06-12T00:30:25.613238 | 2021-06-21T16:11:06 | 2021-06-21T16:11:06 | 341,701,200 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,303 | py | 0017_auto_20210104_1845.py | # Generated by Django 3.1.4 on 2021-01-04 18:45
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),
('almacen', '0016_auto_202... |
fc2cd3e6d2045fd2925714beb3f05cc88b873a33 | 309d17b81cea038713ba67bee72a41d2df4d6869 | /Python/Python_basic/Python_Database/sqlite_tutor.py | 4b525b2913f648ac440eaa662bf59afeb130b401 | [] | no_license | Bongkot-Kladklaen/Programming_tutorial_code | ac07e39da2bce396e670611884436b360536cdc5 | cda7508c15c3e3d179c64b9aac163b6173ef3519 | refs/heads/master | 2023-06-20T13:14:17.077809 | 2021-07-18T04:41:04 | 2021-07-18T04:41:04 | 387,081,622 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 608 | py | sqlite_tutor.py | import _sqlite3
def demo_select():
try:
with _sqlite3.connect("db.sqlite") as con:
con.row_factory = _sqlite3.Row
sql_cmd = """
select gender,height,weight,weight / ((height/100) * (height/100)) as bmi from person
where gender == 'F'
"""
... |
1e1a583657759f6e2f94ce166d52a5483e457de6 | 528a1722fa14b9e053049e71f9f86575b6eabbe8 | /socials/migrations/0002_delete_social.py | de267a3b9f5279ba7d53cb937f791583de972ab6 | [] | no_license | taka-data/mintama | 552d7a1993280085a5963060fedecaf7d77d4117 | 1fe434150b93f39886c356592d8ac78320d023ef | refs/heads/master | 2023-03-28T05:44:12.577154 | 2019-11-22T13:26:17 | 2019-11-22T13:26:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 284 | py | 0002_delete_social.py | # Generated by Django 2.2.4 on 2019-11-10 19:28
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('socials', '0001_initial'),
]
operations = [
migrations.DeleteModel(
name='Social',
),
]
|
b787b4db6034460860a09cbb09751097881a86ef | 2e816dc7654fc8e124fd9adfe26a6c9adcf92542 | /container_constantes.py | 98d8696df3a59da60c05b269859b2df6e2229db0 | [] | no_license | carlosmcastro/PlanetAPP-BACKEND- | 9db8d458a5d388dcd3e7b66737ed98675ebbe57d | 583511fe3d5f7295f2120a22c3d208b84b21bd0a | refs/heads/master | 2021-02-11T09:02:11.033396 | 2020-03-11T17:45:57 | 2020-03-11T17:45:57 | 244,475,414 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,352 | py | container_constantes.py | #encoding: utf-8
#Constantes de las variables.
from decimal import Decimal as D
from math import pi
API_EXOPLANETAS="https://exoplanetarchive.ipac.caltech.edu/cgi-bin/nstedAPI/nph-nstedAPI?" #Parametro obligatorio.
ASTRO_DATA = "astronomical_data.csv"
TABLAS_REF = "data.pickle"
LIMITES_PL_REALISTA = "limit_rea... |
8a4bb89dc5caf9228d6a12fe468d80f0ba3fce5c | d077ddc362142e07abdfa5c02f0505ff21cc7e03 | /matrix4.py | c20f4f4e10cee8ec1b58549548030643b8bc3607 | [] | no_license | dev2404/Babber_List | 7295dad999c3fefeb68d8df1df9a19af93200a35 | cb7687afbeabf94972c6876cb2e7f35931e5e7e6 | refs/heads/main | 2023-01-27T23:25:59.597046 | 2020-12-05T14:07:07 | 2020-12-05T14:07:07 | 318,770,151 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 311 | py | matrix4.py | def matrix(arr):
mat = []
for i in range(len(arr)):
count = 0
for j in range(len(arr[0])):
if arr[i][j] == 1:
count += 1
mat.insert(i, count)
return mat.index(max(mat))
print(matrix([[0, 1, 1, 1],[0, 0, 1, 1],[1, 1, 1, 1],[0, 0, 0, 0]])) |
2a19c2d6e51e9c123236c58f82de1a39e5db40f4 | 84a03b1a62d8f0f0fa1e46f89c19d682a37bca64 | /wurzel/linestructure.py | 8e11f5f35e1d78e4b28a4ff97f17ae0b458d5db2 | [] | no_license | temporaer/wurzel | 34128933cb9bbac6ef8cc062b6b53662c35f5b34 | 76cad3879c5405af891578f061cee5167709fc35 | refs/heads/master | 2021-01-01T20:40:57.145355 | 2012-06-14T23:03:48 | 2012-06-14T23:03:48 | 1,743,601 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,319 | py | linestructure.py | import numpy as np
# Copyright 2011 University of Bonn
# Author: Hannes Schulz
def cnan(x):
""" check for not-a-number in parameter x """
if np.isnan(x).sum()>0:
import pdb
pdb.set_trace()
def get_curve_3D(eig, alpha=0.25,g23=0.5,g12=0.5): # renumerated according to sato et al: l3 is smallest... |
550f5ad4fef77d5795db0393ae0701f679143e72 | 56b615f06ebd9a9cc653a14f35b4aab130f61f3b | /tribits/python_utils/mockprogram.py | 1b38cbc18804f5f67781e997425b0d42535c2aad | [
"BSD-2-Clause"
] | permissive | TriBITSPub/TriBITS | 33b6da32e83b42443f9172b4b14bf244299b807f | 8c1874ca69280c9c9e8346fc96b2f068971e54d4 | refs/heads/master | 2023-08-17T18:43:16.414786 | 2023-07-26T23:19:52 | 2023-07-26T23:19:52 | 23,677,146 | 34 | 48 | NOASSERTION | 2023-07-26T23:19:54 | 2014-09-04T19:55:20 | CMake | UTF-8 | Python | false | false | 5,733 | py | mockprogram.py | #!/usr/bin/env python
# @HEADER
# ************************************************************************
#
# TriBITS: Tribal Build, Integrate, and Test System
# Copyright 2013 Sandia Corporation
#
# Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
# the U.S. Govern... |
4fa9d16f979acf3edce05a209e1c6636e50fc315 | 24d1331a07f79365b8d68293e6768b164e54e1cb | /api/jox_api/Menu.py | a749788b3e1b86701b55475a902a87a783196b3b | [] | no_license | pdkyll/aipu | 88956728f6934e135d5903e411548e122659d319 | 616ead82be8f1753d5ab574879d1765d7279611e | refs/heads/master | 2022-01-06T13:47:35.197582 | 2019-05-13T07:46:28 | 2019-05-13T07:46:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,656 | py | Menu.py | from jox_api import label_image,Mysql,Utils
from jox_config import api_base_url
import json
class Menu():
def __init__(self):
self.mysqlClass = Mysql.MySQL()
self.timeClass = Utils.Time()
def get_menu(self,type,openid):
try:
if type == 'mine':
self.sql = "SEL... |
e5e012e40a71dee9f4dbd9913590aef125b758df | 913fdc45425879242498050d4fbcbec60882f380 | /classes/Visualiser.py | 0526ba8efdf3e991b8099b45ce6b734910b8d038 | [
"MIT"
] | permissive | christianceb/cheesepy | 234e309a9dc4658d01d5a4ebc3037d3011443805 | b131c4200989905bff0a347c10c8c3677a4810d4 | refs/heads/main | 2023-01-11T09:16:51.017864 | 2020-11-14T10:07:21 | 2020-11-14T10:07:21 | 311,029,882 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,741 | py | Visualiser.py | from classes.Board import Board
class Visualiser:
coordinate_map = ("a", "b", "c", "d", "e", "f", "g", "h")
__dimensions = 8
def __init__(self):
self.map = []
self.__build_map()
def __build_map(self):
"""
Creates the array of the battlefield. Should never be used for ... |
c4e4e54ac93c2acdbd3a1cd22b200341a6e45688 | 84a62d00598c1fcb21f3c090bfa281caecc99700 | /engine.py | 54aa45ca2c681f7143cb6f3d63a7b2691d42e418 | [] | no_license | gabrielhuang/twinkle-synth | 316bc9e7a7155139d91c6e912d37b3501e4afc5b | d54e384208761a34242473d57cac03c352de859e | refs/heads/master | 2020-04-03T00:37:30.917088 | 2018-10-26T23:16:06 | 2018-10-26T23:16:06 | 154,904,047 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,092 | py | engine.py | import pyaudio
import numpy as np
from collections import OrderedDict
import utils
class MasterPlayer(object):
def __init__(self, volume=1., samplesPerSecond=44100):
self.p = pyaudio.PyAudio()
self.volume = volume
self.samplesPerSecond = samplesPerSecond
self.individual_callbacks =... |
27e9e63338d422b5fca6f7a67fa3d255602a3358 | b3594ad33b35c9fa60acb4f4977327a1af98bcef | /explain_hmc/hs_plus_cp.py | 66249b064c8851d5e2cc05cb61d571c924b5b6a1 | [] | no_license | yiulau/thesis_code | b30a8da7517a2fef6442e5e12518306fc046300c | c148fcc47cccb18f9f8cbb44e4147f226f52b72d | refs/heads/master | 2021-01-19T09:32:53.685907 | 2018-05-21T06:43:29 | 2018-05-21T06:43:29 | 87,764,950 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,018 | py | hs_plus_cp.py | from abstract_class_V import V
import torch
import torch.nn as nn
class V_test_abstract(V):
def __init__(self):
super(V_test_abstract, self).__init__()
def V_setup(self,y,X,nu):
self.explicit_gradient = False
self.need_higherorderderiv = True
self.dim = X.shape[1]
self... |
ec4348c61cd1c9130543bb20f9ca199399e1caff | 4ec2fdfba5addd6d7233f565063df97355ac30f5 | /Restore_IP_Addresses.py | 9250b69a4dad610c5f1b91b451c84ccbf6a8749e | [] | no_license | mc422/leetcode | e707094d7974316746be9b331f0ab56ca5972a54 | 17cda70d6395325283c9cb3fa24c2e344735831c | refs/heads/master | 2020-04-05T13:31:24.158908 | 2017-08-03T05:03:00 | 2017-08-03T05:03:00 | 94,852,007 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 910 | py | Restore_IP_Addresses.py | class Solution(object):
def restoreIpAddresses(self, s):
"""
:type s: str
:rtype: List[str]
"""
def helper(sb, string, level):
if len(string) == 0:
if level == 4:
ans.append(sb[:-1])
return
if level ... |
d0a3f332e04627eb275168972bd92cd1ea9b9447 | 8d80f72527df21d9d6ba865fd0bb9ed043e76185 | /mctsai/test_mcts_ttt.py | 7c2c9104d8836f5c84ccb19a013e13b88bb2c292 | [] | no_license | ajax88/chessai | 0eac8d6863f515169272dbe41880a309078a0901 | 17d2bafafe119494911409f73da3201e45a08936 | refs/heads/master | 2020-03-19T03:45:32.172985 | 2018-08-17T19:51:44 | 2018-08-17T19:51:44 | 135,759,192 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,021 | py | test_mcts_ttt.py | from board.ttt import TTT
from mctsai.mcts import MCTS
import unittest
# skip = [0, 1]
skip = [0]
class TestTTT(unittest.TestCase):
def test_mcts(self):
if 0 in skip:
print("Skipping ai self-play")
return
ttt = TTT()
for i in range(1000):
mcts = MCTS(tt... |
e95bda8be2294c295d89f1c035bc209128fa29c8 | f20911e113b11f812633bb268e64c592afd890c0 | /Hackerrank/Submission codes/Merge_the_Tools_.py | fe3deba4f0ee2491e171bd89c71dc1b5d69ce063 | [] | no_license | Krishna219/online-courses-and-programming | 9c9c341ee04a397591604a82243097434babb102 | fc755dc6aad88ee047291af3f4093f5a6f23ebc5 | refs/heads/master | 2022-11-24T11:00:51.956644 | 2020-07-26T17:39:16 | 2020-07-26T17:39:16 | 279,117,986 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 228 | py | Merge_the_Tools_.py | def merge_the_tools(string, k):
# your code goes here
num_sub_strings = len(string)/k
#print num_sub_strings
for idx in range(num_sub_strings):
print "".join(set(list(string[idx * k : (idx + 1) * k])))
|
f85a703b47d981397ed6048e941030a3fbee7b6d | 16f161af49b1fddaa0b7b2c349e08bee7a4c7910 | /devday/talk/migrations/0024_talkmedia_codelink.py | 950469fb8644c646328a45d38143e0b24039e1b2 | [
"CC-BY-4.0",
"BSD-3-Clause"
] | permissive | devdaydresden/devday_website | d64fa62e4ac0e66dcc5a737631eff965761410d6 | 1fc28f4e9983b88f45381e807446cef4b8665bb9 | refs/heads/development | 2023-03-31T07:26:18.976047 | 2023-03-31T06:16:11 | 2023-03-31T06:16:11 | 150,890,889 | 11 | 10 | BSD-3-Clause | 2023-03-31T06:16:12 | 2018-09-29T18:13:20 | Python | UTF-8 | Python | false | false | 491 | py | 0024_talkmedia_codelink.py | # -*- coding: utf-8 -*-
# Generated by Django 1.9.8 on 2018-04-27 08:05
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('talk', '0023_auto_20180207_1121'),
]
operations = [
migrations.AddField(
... |
a9aa6ae19dab581c4e0f3bf7b2a413e3e298c12c | 0992ac0a50bd46cbcdf7ef592c29dd637f724533 | /python/LocationChangePredictor/Models/Vocabulary.py | 166dc0b4e86633f293399e3b8743303f1e1f3a50 | [] | no_license | obuzek/geotag | fafe5f7c703b4e4a638749f718e317592a4bd179 | 062fff86d23d08fd681e875d7264f2844070e124 | refs/heads/master | 2016-09-06T17:05:59.579839 | 2013-04-18T19:22:06 | 2013-04-18T19:22:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 341 | py | Vocabulary.py |
class Vocabulary:
def __init__(self):
self.vocab = {}
self.max_index = 0
def get_vocab_num(self,feature):
if feature in self.vocab:
return self.vocab[feature]
else:
self.vocab[feature] = self.max_index
self.max_index += 1
return... |
5aa21461d0c5024ba50661d9ab8cb76cf276c268 | 70ba31523f43d0c80d058a7688a6fc712b46a679 | /etc/41.annomaly/hampel_identifier.py | 7fd770890b29207d1dc13bee2fb10681c8543b56 | [] | no_license | keni-chi/Machine-Learning | 11831a4131ad6618c423e795895789235dbcb192 | 435fd5553dcf6f8272aeb40fd71bd5bcd33f30d6 | refs/heads/master | 2023-06-08T17:27:39.595819 | 2023-06-07T14:18:13 | 2023-06-07T14:18:13 | 165,393,768 | 0 | 0 | null | 2023-03-24T22:45:59 | 2019-01-12T13:56:49 | Jupyter Notebook | UTF-8 | Python | false | false | 1,938 | py | hampel_identifier.py | import numpy as np
import matplotlib.pyplot as plt
def Hampel(x, k, thr=3):
'''
* Input
* x input data
* k half window size (full 2*k+1)
* thr threshold (defaut 3), optional
* Output
* output_x filtered data
* output_Idx indices of... |
83e7da65543f95386fa64f066d4a23cda14c652a | 91a0a63c8908bcab67d20facb8b124fd5bb7df46 | /lib/modules/abstract_simulator.py | 7ede7f63da01456d1a433ec2ea3490b71aae82c8 | [
"MIT"
] | permissive | uvavision/Text2Scene | eb51e7a301f539e32f6e5a975dd89b54480432ca | 2ee5bb6490359459cb3b5812021a32e35e1f8309 | refs/heads/master | 2022-05-26T22:29:56.732535 | 2022-04-15T12:12:33 | 2022-04-15T12:12:33 | 179,596,514 | 129 | 29 | null | null | null | null | UTF-8 | Python | false | false | 7,955 | py | abstract_simulator.py | #!/usr/bin/env python
import numpy as np
import cv2, math
import PIL, cairo
from copy import deepcopy
from abstract_utils import *
from modules.abstract_evaluator import *
import torch
class simulator(object):
def __init__(self, imdb, batch_size=None):
self.db = imdb
self.cfg = imdb.cfg
... |
4acb58e3fd3df86411e96eb58fae8552065f3227 | b3fd3408213698d40b9a249e294d44c962979f9c | /Rotten_Tomato_crawler/spiders/stringfunctions.py | 14a8ed4294fbefdb3ade8cd7f7d78de7992c906e | [] | no_license | mushahid6666/Data_Science_Movie_Matching | 17ede71f4bf2f3e82a2b94f87011edcac0e4326a | 36cfd8548edf27687f86c36c645c5ec6f163d9fd | refs/heads/master | 2022-08-30T16:45:16.421554 | 2022-08-29T05:02:37 | 2022-08-29T05:02:37 | 45,747,363 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,835 | py | stringfunctions.py |
class stringfix():
def findslashes(self,str):
fslash = '/'
bslash = "\\"
result = str.find(fslash)
if (result == -1):
result = str.find(bslash)
if (result == -1):
return str
else:
bslashindex = str.index(bslash)
... |
2ce17d8706348a0e7a161ba9924d5c76500bbf35 | 0b4b9b46f9825da4ef141e8a05b4b0e148038bb8 | /database/reminders.py | 3ad01793a39a1a2f9c471ddbf8a675ac5775d076 | [
"MIT"
] | permissive | Tominous/casper-1 | 3a82cbae47899b824c96a92bb3ce51807b56d8cb | 0a2971c8de886fedfaf6f28e8759a4d66d8e4692 | refs/heads/master | 2020-06-02T04:53:07.181181 | 2019-02-12T13:29:13 | 2019-02-12T13:29:13 | 191,043,662 | 1 | 0 | null | 2019-06-09T18:55:45 | 2019-06-09T18:55:45 | null | UTF-8 | Python | false | false | 1,267 | py | reminders.py | from datetime import datetime
from database.database_models import Reminders
from database.engine_session_initialization import Session
class RemindersDatabaseMethods:
@classmethod
async def add_reminder(cls, guild_id, user, reminder_msg, channel, reminder_time):
session = Session()
reminder ... |
93e6b735e7d8518332c9aa1dec33f8551324f002 | 0433bdb22283bdebd419ccf13ded5c008e83584c | /DealWithFile.py | b1664f2106131a2dd27f44d0ab83f2ffe666a708 | [] | no_license | JaireYu/Dictation | 3b120e50e51757b8881118ef8d2d39c0b636c61e | d6dd37aa9e702479fdea046ea38ad3e1f7313af6 | refs/heads/master | 2020-07-01T18:47:34.957017 | 2019-08-09T12:39:39 | 2019-08-09T12:39:39 | 201,261,109 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 573 | py | DealWithFile.py | from docx import Document
import os
file = Document("D:\\GithubLocalRepo\\dictation\\WordLists.docx")
curentnum = 0
for line in file.paragraphs:
list = line.text.split(' ')
if(list[0] == "Word"):
curentnum = list[2]
else:
if not line == "":
fr = open("List{}.txt".format(str(curen... |
3987c1008d71682a361fa394e2ed38ab335ddcb8 | 4ebbc695513f12a432781b0821693c6a0800d328 | /helipad/cpanelTkinter.py | 3b3a870d18e92e2dcf863255f2301bfd21dd9cb1 | [
"MIT"
] | permissive | charwick/helipad | 1f19cbbbdf620dc25dd642b5095f0b008b95ad0d | c9819e1207c1b295e83683b829884bc3c1586630 | refs/heads/master | 2023-08-22T18:12:26.098932 | 2023-08-03T06:24:55 | 2023-08-03T06:24:55 | 119,096,081 | 30 | 4 | null | null | null | null | UTF-8 | Python | false | false | 27,019 | py | cpanelTkinter.py | """
The Tkinter-based control panel class for use in standalone models. This module should not be imported directly; use `model.launchCpanel()` instead.
"""
import tkinter as tk
import os, sys
from math import ceil
from tkinter.ttk import Progressbar
from helipad.helpers import Color, ï
from helipad.param import Param... |
102521c226bd9038d7f6907349cca98ae99d3ff0 | 44c0f4735c323fa498d004996c91bb83966005b1 | /eisbaer/models/conference.py | 271d26418f06c9838eb01e7a3481bf839d94006d | [] | no_license | JoeyFaulkner/eisbaer | 08a1a4bb64c2dbc595700f183c0ed00fdcca53a7 | 635196f7efa08caf8bd4434eb4fb9f8aaffa1d96 | refs/heads/master | 2022-12-10T10:09:05.409621 | 2021-04-07T11:34:54 | 2021-04-07T11:34:54 | 234,902,905 | 1 | 0 | null | 2022-12-08T03:27:55 | 2020-01-19T13:14:30 | Python | UTF-8 | Python | false | false | 313 | py | conference.py | from models import db
class Conference(db.Model):
__tablename__ = 'conference'
id = db.Column(db.Integer(), unique=True, nullable=False, primary_key=True) # same as nhl.com
nhl_link = db.Column(db.String(), unique=True, nullable=False)
name = db.Column(db.String(), unique=True, nullable=False) |
bac66eda6b0b7e3145152e212c52b0491411db8d | 90250154bc7000845784f545f3d1c33231c5281b | /döviz-kuru/döviz_kuru_göster.py | 082583f7c1950494fbd2102a5bb128af48fdad77 | [] | no_license | ferhat-kaplan/Python | 67dc409cf461f707f0b94340bfc0ed5f2f9428ff | 5c4e12a5c76f62a95b2ca235e8be453923f1f5ba | refs/heads/master | 2022-12-15T03:25:55.612216 | 2020-09-09T18:16:54 | 2020-09-09T18:16:54 | 284,113,351 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 391 | py | döviz_kuru_göster.py | from bs4 import BeautifulSoup
import requests
url = 'https://www.doviz.com/'
r = requests.get(url)
soup = BeautifulSoup(r.content, 'lxml')
veriler = soup.find('div', {'class': 'market-data'}).find_all('div', {'class', 'item'})
for i in veriler:
birim = i.a.find('span', {'class': 'name'}).text
degeri =i.a.f... |
5281f5bda4e55f3ab6d7e88f4105ac2d366a426c | 9dd05fab001c97ed7a6d9835a2adb6cb30a9d680 | /ej1/libro.py | c4e796d375ee819f3874d5b003576afb79f43173 | [] | no_license | emilianospinoso/herencia-clase21 | bf2c4dfbab3517447a31983a60456e003579696b | 8afa8df3abe5331d0bd29a48869260b80b2602bf | refs/heads/main | 2023-06-18T08:58:56.761963 | 2021-07-06T12:44:55 | 2021-07-06T12:44:55 | 383,465,903 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 405 | py | libro.py | from producto import Producto
class Libro(Producto):
def __init__(self,referencia,nombre,descripcion,precio,isbn,autor):
super().__init__(referencia, nombre, descripcion,precio)
self.isbn = isbn
self.autor = autor
def __str__(self):
return "Libro: {} - {} - {} - {} - {} - {}".... |
d0a5f86f67dd23073dbc18295178cd6cc0188240 | e09e3dbe8bf1a028eb3a065162e842a7e3d95ce3 | /utils.py | f7070ddd6ca6013c1586eb2edd4eb63c95f4a1a8 | [] | no_license | gpalsingh/SmScout | 924e0fc2b06b01c85200934d13f65b3c6ba2c0ee | 8fa805428646a69de6a9a6925ff500ef8ba0c6dd | HEAD | 2016-09-15T17:12:21.504548 | 2016-03-27T22:28:11 | 2016-03-27T22:28:11 | 40,920,629 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 10,975 | py | utils.py | # -*- coding: utf-8 -*-
import re
try:
import BeautifulSoup as bs
except:
import bs4 as bs
import os
import time
import variables
import sqlite3 as sql
import sys
import platform
# =========================================================================
#
# GLOBAL VARIABLES
#
# =======... |
041ca1152bc8a3ab9f957604889c063159e4299a | cf67c343dd7f4d1ad4ce35d98340a10101acc174 | /plateau.py | c1f5a03dc504f23ef4c816a394849500d96ceeac | [] | no_license | MinKapout/Clobber | 04e8ee48bce4cbc50da08237f8646c3b1a2db33f | a7e4b62d7c9da45167e211dc930e217fcfa7dc5c | refs/heads/master | 2021-08-19T10:21:09.121240 | 2017-11-25T21:24:26 | 2017-11-25T21:24:26 | 112,024,462 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,539 | py | plateau.py | from pion import Pion
class Plateau :
def __init__(self):
self.plateau = []
for plateauXY in range(3):
self.plateau.append([0] and [0]*4)
def ajoutPion(self, pion, posX, posY):
if self.plateau[posX][posY] == 0:
self.plateau[posX][posY] = pion
return... |
94b1eaacd752875b3cc0e2ff91b285e57fb4e540 | a325101eb84ccd5df277b96a58913818be28726b | /models/depth_and_egomotion.py | 758e8e89e25b12df0773704997bcb7d0ee81295f | [] | no_license | utiasSTARS/learned_scale_recovery | 9b1d2d3fc9a492609aafd7b3521cdf51b5bc09dc | b22c833ceb9a7c0321c6b2e5ee3dcc30f08af7c0 | refs/heads/master | 2023-06-26T05:48:44.238497 | 2021-07-15T16:24:43 | 2021-07-15T16:24:43 | 283,306,765 | 39 | 10 | null | null | null | null | UTF-8 | Python | false | false | 13,888 | py | depth_and_egomotion.py |
from __future__ import absolute_import, division, print_function
import torch
import torch.nn.functional as F
import torch.nn as nn
from collections import OrderedDict
from torch.nn import init
import numpy as np
import torchvision.models as models
import torch.utils.model_zoo as model_zoo
'''
General Functions
Many... |
b6cd9eea5fb15aecdf2d6c94816f4b07cf3e752b | ac9aebe3ddda95f3057b4f9bb2ba6d5718aad039 | /dell_lulu_i3/amixer_toggle.py | d184d2cd0462b72ffee2a515445c61d38263d1c8 | [] | no_license | yoyoliyang/linux_i3_wm_config | db90da9494085393486a24e9e095916d130e903f | 7c6b5f0edd9789c9ee2f1e4dfbf89619e0567f18 | refs/heads/master | 2023-01-12T20:59:23.230858 | 2020-11-12T10:47:59 | 2020-11-12T10:47:59 | 292,426,165 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,101 | py | amixer_toggle.py | #!/usr/bin/python3
import os
# 控制音量腳本
status = {}
# 声卡控制器编号,不同的机器未必相同
c = 0
amixer_list = lambda c: os.popen(f'amixer -c {c}').read()
amixer_list = amixer_list(c).split("\n")
n = 0
status_index = -1
for index, i in enumerate(amixer_list):
if i.startswith('Simple'):
status_result = []
n = 0
... |
ae60cb332f47497b2263d7937c875d7e587c0e94 | 28d02c15fadef8014ebad6aee3e98ece3cd2c81b | /fabric_ubuntu_extras/utils.py | 61f1eb60f2f5dca8235723ab28504cbc03269ca3 | [] | no_license | josephmisiti/fabric-ubuntu-extras | 753b84e3f894d1bc517e81d89efbaea0d04f5d64 | 1c8720c46552dcb6981f2fef8b9d5ecb8928e44b | refs/heads/master | 2016-09-06T12:43:32.290878 | 2011-02-24T16:30:49 | 2011-02-24T16:30:49 | 2,604,276 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 497 | py | utils.py | from os import path
from fabric.api import sudo as _sudo
from fabric.api import put
from fabric.context_managers import *
def sudo(cmd, verbose=False):
if verbose:
with settings(warn_only=True):
return _sudo(cmd)
else:
# Otherwise, be quiet
with settings(hide('everything'), warn_only=True):
return _sudo(... |
90833e82ff81f5ce20911152b554096faa42a4bf | 6312ae52fb81f68ca80ad5c607148d011052850d | /hr_payroll_ext/wizard/dokkan_staff_salary_sheet.py | 8b4ec0c0a6a51aead85ce2af4e64aa908f01cbd5 | [] | no_license | cokotracy/sos_guards | e88b95026185aaf1d622b223d39afd5e60a60ee9 | 84242b484cbd9a4296d3083747b4e31f2ebb3e73 | refs/heads/master | 2022-06-14T05:36:27.971635 | 2019-10-07T07:01:58 | 2019-10-07T07:01:58 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,105 | py | dokkan_staff_salary_sheet.py | import pdb
import time
from datetime import date
from datetime import datetime
from datetime import timedelta
from dateutil import relativedelta
from openerp import tools
from openerp import models, fields, api, _
class dokkan_staff_salary_sheet_wizard(models.TransientModel):
_name = 'dokkan.staff.salary.sheet.wizard... |
312e7451968fb2753f2a7e8ec64b73746f6ced07 | ebf2ccdb9f7ce4fb9b25dd55670de67a17e73c57 | /web/models.py | 624281e0e89d91a42a57f2389899e7029a2624a6 | [] | no_license | OYLshuai/Django | 4628411f4f051a30e069e2c7b910e77800643867 | c804757ee12f4ef4711d0b891151bb2bc8689ffa | refs/heads/master | 2021-10-09T01:38:19.610588 | 2018-12-20T01:52:25 | 2018-12-20T01:52:25 | 152,392,230 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,467 | py | models.py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models
# Create your models here.
class text(models.Model):
id = models.BigIntegerField
name = models.CharField(max_length=20, default='a')
age = models.IntegerField(null=True)
class Book(models.Model):
book_n... |
adf760b9e9b528499ed4540968382773e9519a58 | d49ca13b5543c37005ccdbed3088c9704b2e7e9c | /graphgallery/gallery/sklearn_model/sklearn_model.py | 1f443a1168b20139147edd7e87e347b2cbb75173 | [
"MIT"
] | permissive | future1111/GraphGallery | 21d7675b624906cf4ef9ee0928e6fc083173b7b3 | 240c2b13841a45689e676e85cfb9ad6d67a4f610 | refs/heads/master | 2023-02-04T22:23:09.741952 | 2020-12-16T02:24:02 | 2020-12-16T02:24:02 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,634 | py | sklearn_model.py | from sklearn.preprocessing import normalize
from sklearn.linear_model import LogisticRegression
from sklearn.metrics import accuracy_score
from graphgallery.gallery import GraphModel
from graphgallery import functional as gf
class SklearnModel(GraphModel):
"""Sklean based model for unsupervised learning."""
... |
f4d9f040f586c4db80ea5ef8177ac882d88af0ca | ad8a49c56e2bae8ba5c4a92ccfb287f8869b2dd9 | /setup.py | 243f8ee68f8387bbf9d375ef4b854d7e928e5839 | [
"MIT"
] | permissive | navaz-alani/selenium-testing-module | 9fc63662247ab4272dcacd6209a3cefccc144395 | 652b375456fbdafa0bafd7839668414cde0c619b | refs/heads/master | 2020-06-28T02:12:56.594966 | 2020-03-05T19:09:15 | 2020-03-05T19:09:15 | 200,115,873 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,146 | py | setup.py | from distutils.core import setup
setup(
name='selenium_testing_module',
packages=['selenium_testing_module'],
version='1.0',
license='MIT',
description='TYPE YOUR DESCRIPTION HERE',
author='Navaz Alani',
author_email='nalani@uwaterloo.ca',
url='https://github.com/navaz-alani/selenium-tes... |
5484abbd3158b0a314136830072d7a3d88dc1d27 | ab90c0d1f42e93915a70b0a043dd5d1323ed7642 | /datasets.py | 1aa88d5390dac05b9f058bca331a8ca49a3bc83e | [
"MIT"
] | permissive | BrunoSauvalle/BB-SGD | c4ed3eaf5d6e5a453b3f3760570197a7d7c0a971 | 3bb784ddfb4bc8261dcfca32fc3dd80d2c4df98f | refs/heads/main | 2023-08-03T18:38:22.952196 | 2021-09-27T11:10:53 | 2021-09-27T11:10:53 | 410,848,940 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,874 | py | datasets.py |
import os
import torch
import torch.utils.data as data
import natsort
import cv2
import numpy as np
from tqdm import tqdm
class Image_dataset_with_optical_flow(data.Dataset):
def load_image(self,idx):
image_path = os.path.join(self.dir, self.sorted_image_names[idx])
image = cv2.imread(image_path,... |
d0725908a1165a8142ea332264cd86bc11157a5d | a815e18da664c403794021103b6e2ba8f1531d14 | /moto/dynamodb2/comparisons.py | 1dc723df0e51f238b46b6b5cd7e9eb74dd7c8d8c | [
"Apache-2.0"
] | permissive | zenefits/moto | 1d45bc79eba58396f971d050c46f93c2fa5cca89 | 8341c722a8e06decf23fd4b5e67de612accebb80 | refs/heads/master | 2021-01-22T14:11:01.742715 | 2020-01-03T00:27:54 | 2020-01-03T00:27:54 | 58,078,704 | 0 | 0 | Apache-2.0 | 2019-08-01T00:57:38 | 2016-05-04T19:30:04 | Python | UTF-8 | Python | false | false | 1,432 | py | comparisons.py | from __future__ import unicode_literals
# TODO add tests for all of these
EQ_FUNCTION = lambda item_value, test_value: item_value == test_value
NE_FUNCTION = lambda item_value, test_value: item_value != test_value
LE_FUNCTION = lambda item_value, test_value: item_value <= test_value
LT_FUNCTION = lambda item_value, te... |
ed69b1f6810af5e8c396b37cd191e4e5b9ee4b75 | 9f443bde3f151733deb4455947a6238189db8ba3 | /globalcache/globalcache.py | c171b03a88efdd9181ef67a60e5c36dff1f7870b | [
"MIT"
] | permissive | johnh865/election_sim | 482d040ebe908b3ddaff29e757f0c4239418be93 | 44ee7c276973fa89113606eaf8ba9dd9b3db5cf3 | refs/heads/master | 2022-05-31T12:26:48.374967 | 2022-05-08T23:51:30 | 2022-05-08T23:51:30 | 216,422,491 | 12 | 1 | null | null | null | null | UTF-8 | Python | false | false | 8,158 | py | globalcache.py | # -*- coding: utf-8 -*-
"""
Globalcache constructs a memoization/caching decorator you can use to store
results in IPython or Spyder globals(). This lets you re-run a script and
skip the heavy computing if the result has already been processed, when you
make small changes to your script.
Requirements
-----------
Gl... |
059e43170bbd935a452d811a2e62b10e85f5911c | fc16557e80dcb8e0608c736f7e193a4d2326faae | /yandex.ru/test_login_mail_yandex_ru.py | b1dd9f3b1c78143e7bdb7f37660ceafc8a1cf1ea | [] | no_license | BondarenkoAleksey/PyTest | 742f2398a01803a1b904ce2f7c0e1877f9288dd5 | 2f33e934dd0433fae5a0f460409b60f89cec4ffd | refs/heads/main | 2023-07-18T11:36:44.058849 | 2021-09-01T18:42:58 | 2021-09-01T18:42:58 | 391,991,437 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,801 | py | test_login_mail_yandex_ru.py | import time
from random import randint
from selenium.webdriver.common.by import By
import requests
link = "https://passport.yandex.ru/auth"
link1 = "https://www.google.com/search?q=купить+кофемашину+bork+c804"
# тест входа в почту Яндекс
def test_login_to_mail_yandex_ru(browser):
browser.get(link) # пер... |
b9ecf927cf5ecac8fa3492cd4152b231a4851d62 | 07014084a4777662d980bd900b28b5d8ee0f259c | /janela.py | 24fce1c42638a2611bba8a1d7c643bdd62bd68c0 | [] | no_license | WatanukiRasadar/JogoPrimeiroSemestre | 7774c7c8a3655d7a4844b41b945ee5050b87717f | 61239fb6917a78baa2b576a1429f76e2378a278a | refs/heads/master | 2020-04-05T23:15:47.009644 | 2016-05-30T19:30:25 | 2016-05-30T19:30:25 | 60,032,738 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 675 | py | janela.py | import wx
def janela(Pergunta,Respostas,certa):
class Perguntas(wx.Frame):
def __init__(self,parent,id):
wx.Frame.__init__(self,parent,id,"Perguntas",size=(500,300),style=wx.CAPTION|wx.MINIMIZE_BOX)
self.panel=wx.Panel(self)
wx.StaticText(self.panel,1,Pergunta,(30,3... |
6042a207e1fcf6a2cee2ab0ff1e7e2a01fe92032 | 240ff4c82e5f3738b33699d69fe4d81abfdd7d1a | /introduction_and_environment/data_types_and_control_flow/1_string_length/Solution/solution.py | abd48643d593a9365997c459a8e7a36b8b57e4ab | [] | no_license | FiodorGrecu/Exercises | f816549a3153d25ce2e7906789bfd0fac17d8d4a | 21121a0ca385883953b2f5a9886add40efa21e6f | refs/heads/master | 2023-04-18T15:11:04.023546 | 2021-04-22T00:39:41 | 2021-04-22T00:39:41 | 283,240,812 | 0 | 0 | null | 2020-08-20T18:43:57 | 2020-07-28T14:42:49 | Python | UTF-8 | Python | false | false | 144 | py | solution.py | # Code your solution here
string_1 = "Hello"
# string_1 = input("Enter a string: ")
string_value = len(string_1)
data = string_value
print(data) |
77699e1f500554116c80af9cf544c997f8a38f71 | 35426b3b48e29e368de2bb190b305fd4636f3901 | /pg/ball.py | 5c80b3b2b3bf00c5601b03e427eeeab7c0da6ef0 | [] | no_license | meshko/pintro | 3ac05ffe1471599a89e2aab83e44816b6571cfa0 | 510f8ffcb70de99c44859c74582697035d8ac659 | refs/heads/master | 2020-12-24T07:01:38.157617 | 2016-06-02T01:44:43 | 2016-06-02T01:44:43 | 42,372,112 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 896 | py | ball.py | import pygame
import random
from random import randrange
screen = pygame.display.set_mode((800, 600))
running = True
clock = pygame.time.Clock()
ball = [[randrange(800), randrange(600)], [randrange(255), randrange(255), randrange(255)], randrange(10,20), [randrange(-10, 10), randrange(-10, 10)]]
while running:
ev... |
f41417127801b987d5756e0abe361164741525bf | a73277d9f7af92156d31c12a9e1b4406fa93f5f2 | /algorithms_1_num/leap_year.py | 6b5e631bd86e3608e05646fcc5032900cf2fbad1 | [] | no_license | Alena-Ryzhko/python_algorithms | e2c5eabfc4e00175d891a32d64836443a785b432 | e34ab768fd33c0612b6ea375f446eb8c627ed82f | refs/heads/master | 2022-12-30T08:40:29.032200 | 2020-10-10T20:43:23 | 2020-10-10T20:43:23 | 297,995,652 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 359 | py | leap_year.py | """
Leap year.
A program to check whether a year is leap year or not:
"""
year = int(input('Enter year '))
if year % 4 != 0:
print('Not Leap year')
else:
if year % 100 == 0:
if year % 400 == 0:
if year > 0:
print("Leap year")
else:
print('Not Leap year... |
988bb71e70b048aace659f7e7a4201e6f5b30108 | 44a30eed90e72c51bdd661bcf75599aeec44fd71 | /maskrcnn_benchmark/modeling/roi_heads/box_head/box_head.py | 09f6bb20beceb285af32d6a3eaa17132f8b05cbe | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | yolunghiu/mask_rcnn_code | 045f3559b7ce77c1f63fc37dc6fb1fa2fef8d5fb | a8878f81f6bbfa63b5a4b7ca2bfb80673e4febfd | refs/heads/master | 2022-01-21T07:20:24.658678 | 2019-07-27T14:38:45 | 2019-07-27T14:38:45 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,026 | py | box_head.py | import torch
from torch import nn
from .inference import make_roi_box_post_processor
from .loss import make_roi_box_loss_evaluator
from .roi_box_feature_extractors import make_roi_box_feature_extractor
from .roi_box_predictors import make_roi_box_predictor
class ROIBoxHead(torch.nn.Module):
def __init__(self, cf... |
327305740d2b060c9a423a72a3275268cac795ef | 2716f5c6d4513d5ca13b79cc55c42ab56625a1ac | /B_HACKS/testUI.py | 97643da1efdbc7f8f6521bd50b7875eaa4c811a9 | [] | no_license | deepakDOTexe/hello-world | 0842e00c854abbb123be7c25f44a99175827ba24 | c384ba8b5c61c72c19f3ac0e04a0a01aa173747f | refs/heads/master | 2021-06-29T01:56:01.907164 | 2020-10-03T05:57:59 | 2020-10-03T05:57:59 | 165,545,865 | 0 | 0 | null | 2020-10-03T05:58:00 | 2019-01-13T19:34:18 | Python | UTF-8 | Python | false | false | 650 | py | testUI.py | from tkinter import *
# import tkinter.messagebox
root=Tk()
# root.title('Name')
num_que=Button(root,text="Number of Questions")
num_que.pack(side=TOP)
#*********************
# def enterNumQ():
# tkinter.messagebox.showinfo("Enter Data","Enter number of Questions to be checked")
# answer=tkinter.messagebox.as... |
87b673f9dadd717f7a23e86c76c8b2457d6e48a1 | 180a4fde0decfee7dc27f478f387af21c163a215 | /Hector/HecBaryons/HecPsiCascade/test/hecpsicascade_cfg.py | 8f947d169536fdbadee4c338526bdd70711103fc | [] | no_license | jeramirez/usercode | c6091f2b93470d598c855f46a1b5f4115fb1728e | 91e02f229f97eab4d895ccdfc487ca8a46e996e9 | refs/heads/master | 2016-09-10T11:26:15.120173 | 2013-06-24T21:37:49 | 2013-06-24T21:37:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,994 | py | hecpsicascade_cfg.py | import FWCore.ParameterSet.Config as cms
process = cms.Process("HecPpsiCascade")
process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) )
process.load("FWCore.MessageService.MessageLogger_cfi")
process.load("Configuration.StandardSequences.MagneticField_cff")
#process.load("RecoEgamma.PhotonIdentif... |
ee28720df36a6f2bb971f273a27aae25b785ba4a | 94ea88a0e1bc662443a37d6e6c71fdbdc258131a | /Game/FlyPlane/UI/Label.py | 1306cd756897982c7ec87ae89ab176ec8ffe58ed | [] | no_license | 1549469775/Blog | 0c291aa6b7d9dc6182ed046b37ed47ec290b758b | fdaf99cafb13b737dfc570ae34193b3a2a361445 | refs/heads/master | 2021-04-12T08:00:46.184419 | 2018-04-24T00:01:11 | 2018-04-24T00:01:11 | 125,953,013 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,082 | py | Label.py | import pygame as pg
class Label(pg.sprite.Sprite):
text=""
color=(255, 255, 255)
rect=(0,0)
def __init__(self,text,size=30,color=(255, 255, 255),position=(0,0)):
pg.sprite.Sprite.__init__(self)
# myfont = pg.font.Font("china.ttf", size)
self.myfont = pg.font.SysFont("SimHei", si... |
a5b5ab4426560b9f6db6b8328b3d6f505b5e27a3 | 490c3fd7ccfaf1f640d0da559a1a1b7f5bc52564 | /buddy_pages/views.py | c4bb12471f952424f4833007ee0c228c376472a6 | [] | no_license | Pfhorrest/Django-Buddy | 28d1946bcc9599288b39cfa552375a1473aa1bfe | f2740ccb5cf20b274011e347d632a8f87f55bf5e | refs/heads/main | 2023-02-28T05:58:09.972090 | 2021-01-28T09:56:56 | 2021-01-28T09:56:56 | 331,574,082 | 0 | 0 | null | 2021-01-25T09:58:13 | 2021-01-21T09:13:28 | HTML | UTF-8 | Python | false | false | 293 | py | views.py | from django.shortcuts import render, redirect
# Home screen view
def home_screen_view(request, *args, **kwargs):
context = {}
context['page_title'] = "Home"
user = request.user
if user.is_authenticated:
context['user'] = user
return render(request, "buddy_pages/home.html", context) |
4b94ae26b0ec4618642346b4f20d4822efb4bff0 | c640fe1a5d2db7947394613b272bf16a1f09ea64 | /fabfile.py | 63cb454342a907d97983f183b62d65f65aa34f20 | [] | no_license | WeiChengLiou/setAWS | 558903ec00c7960a1ce9defb6cc841e6d4026205 | 4f36b1f81e52719dbb1424c12476094d776187ca | refs/heads/master | 2021-01-20T11:48:17.061313 | 2015-07-09T10:08:14 | 2015-07-09T10:08:14 | 37,668,681 | 1 | 0 | null | null | null | null | UTF-8 | Python | true | false | 3,521 | py | fabfile.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from os.path import join, basename, realpath, expanduser
from fabric.api import task, run, sudo, execute
from fabric.contrib.files import append, exists
from fabric.contrib.project import rsync_project
from fabric.context_managers import *
from fabric.operations import put... |
533966671382b7dd3de66359c2eb7c699fe02927 | a87b3176272b11112e1e2fe776e16c577dc7fd7b | /Marriage/ppoupas.py | 4027846763b68379b54de5cd510e73fb7022c3d2 | [] | no_license | fleandrei/Projet-reLAX | bd651916209b128c41995958c1cb2b0c0f48e938 | 037b24517aeda52fc050736de77bf490afc2da6e | refs/heads/master | 2021-04-30T05:10:45.940425 | 2018-05-23T22:48:15 | 2018-05-23T22:48:15 | 121,410,102 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 590 | py | ppoupas.py | #!/usr/bin/python
#-*- coding: utf-8 -*-
from test import *
def ppoupas(Vf) :
"""Renvoie True s'il existe un pp, ie un sous ensemble contenant autant de filles que de garçons, et false sinon"""
S=[]
i=0
if test(Vf)==0: #Il y a autant de de filles que de garçons => pp
return(True)
else : #On parc... |
89349f3add2dbec007a80475320a8db33827b1ee | 6ad04487f46a11b1715baa192960e06c481d4f7e | /latex/listings/C2/boundary_generator.py | c0221874a991bbf1275574d3544f3822e0f23c10 | [] | permissive | mick96/bambi-thesis | cc31627019500e47100a93406c2bbef36012562e | 42052f3ea98d22bfdc849bcf8affcc81d04539e9 | refs/heads/master | 2020-03-26T15:08:15.018093 | 2018-10-09T16:20:49 | 2018-10-09T16:20:49 | 145,024,380 | 0 | 0 | Apache-2.0 | 2018-08-16T18:20:03 | 2018-08-16T18:20:03 | null | UTF-8 | Python | false | false | 1,654 | py | boundary_generator.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import roslib
roslib.load_manifest('bambi_msgs')
import rospy
from bambi_msgs.msg import OrthoPhoto, Field, GeoPosition2D
import sys
# parse kml files
from pykml import parser
class BoundaryGeneratorNode():
def __init__(self):
self.m_boundaryPublisher = rospy.... |
96da6d71e6cb94b8347c3528c3d5dbca476fdaaa | 290beb1dc1beef034b2bce38cfe18cad0db13964 | /main_lazy_val_iter.py | 76674c55b1ec9bd1a830f1dd361927cac91ff1d6 | [] | no_license | i-kiran/MarkovDeciaionProcess_MDP_XMEN_Game | 0b9ca6634961c209661d048388cc4297d1a8949f | 3ce7a503176fa2a292d63cf5cb0eddc48801be87 | refs/heads/main | 2023-05-27T18:28:13.843419 | 2021-06-17T04:56:47 | 2021-06-17T04:56:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,639 | py | main_lazy_val_iter.py | import time
import random
import visualize
import difference
import position_generator
from visualize import create
from difference import diff
from visualize import recreate
from position_generator import generate_valid_pos_for_Magneto
freward = 0
reward1 = -15
reward2 = -20
reward3 = 20
delta = 0.05
de... |
f848d4f059c9653f7402b27acff70b481511b5cb | aef4e6a3be051768f665b2e82fa752f9c85b355c | /excel.py | efdc3454a44c64050f94eee84893cc979d8c1e28 | [] | no_license | yljtsgw/MiExpAccount | c23538211ae834a1c2fced7170a9e054713dcd37 | 6560edf1360b0d197bc058281539721489f0c15b | refs/heads/master | 2021-01-25T04:14:14.031498 | 2017-06-11T03:17:03 | 2017-06-11T03:17:03 | 93,409,633 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,769 | py | excel.py | # -*- coding: utf-8 -*-
import xlrd,xlwt,time
########################################################################
class excel:
"""
读写excel的封装 针对03版本
"""
#----------------------------------------------------------------------
def __init__(self):
"""Constructor"""
def set_s... |
85aa46e5f63531140382a25a50f0afe58be5ebd8 | acdd523db076c56d351e2b7085d284692d5891b5 | /amazing_semantic_segmentation/__init__.py | ba2554797747c2ce10f6e5f804a149ef49fbfa7d | [
"Apache-2.0"
] | permissive | jarodhanko/Amazing-Semantic-Segmentation | 25d7935f3a2455e1e7bb206cb37c662e155091ea | b92596d4c17a72492e848af9e8d7152386f035b2 | refs/heads/master | 2023-07-09T12:19:53.974005 | 2021-08-18T13:36:24 | 2021-08-18T13:36:24 | 293,857,767 | 0 | 0 | Apache-2.0 | 2020-09-08T15:52:09 | 2020-09-08T15:52:08 | null | UTF-8 | Python | false | false | 210 | py | __init__.py | __import__('pkg_resources').declare_namespace(__name__) # noqa
from . import utils
from . import base_models
from . import models
from . import builders
from . import version
from .version import __version__ |
40f6ab05192e580cbebdd7fd83b2e3475fece44e | 0931ad00a78912df5fc4f670928f948b203bdf12 | /geoKL/KLfenics.py | adf22e0c065a9e485241d0010ce0fe1bedc07fb7 | [] | no_license | pezzus/fimh2019 | 71c160e9e19cee1658e09d5dfc5f6c0dd8ed6662 | 869b8768d2f338709334c3cd97f4ec7791eccf9b | refs/heads/master | 2020-05-09T22:47:15.494927 | 2020-01-13T06:57:28 | 2020-01-13T06:57:28 | 181,482,403 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,115 | py | KLfenics.py | from fenics import *
from rndfield import *
class SqExpFEniCS:
def __init__(self):
mesh = UnitSquareMesh(100,100)
P1 = FiniteElement("P",mesh.ufl_cell(),1)
V = FunctionSpace(mesh,P1)
u,v = TrialFunction(V),TestFunction(V)
m = u*v*dx
self.Ml = assemble(action(m,Con... |
d62ead3fe53e7080ca8e42275b25efb79d4c05f6 | cc152485f59e7bdf55e4d96970f50589181931df | /menu.py | 3d3cf6052fbf8a07a3b7118a971e520aa4cc9220 | [] | no_license | Rica320/FPRO-Space_Invaders-Clone | 10629d3d41b727021363521a94dd31cdfafd545f | 01fc60c2a6f0d3d88ea90d3a72bb773505f2d664 | refs/heads/main | 2023-02-24T13:12:22.619568 | 2021-01-25T22:34:49 | 2021-01-25T22:34:49 | 322,355,721 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,088 | py | menu.py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Sat Dec 19 13:19:05 2020
@author: ricardo
"""
import pygame
class Menu():
''' A class that defines a menu and it's atributes'''
def __init__(self, game):
pygame.mouse.set_visible(False)
self.game = game
self.running_displa... |
6153bc4e66c837a9ec0c44b64f4c8e14f7518ca6 | 432b7f598eb4ac20504df68351507f5c32a442bc | /mystudy/py_test/chtomp4.py | 666c755d767f2460ce74b564d60925d010568379 | [] | no_license | mykine/pythondata | ed42cf9eb462244502b27c491e4d4c20309ede83 | 88f3cdf239df687dd4131b955995e858852e26d0 | refs/heads/master | 2020-05-18T15:55:18.933100 | 2019-06-22T15:37:16 | 2019-06-22T15:37:16 | 184,513,147 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,667 | py | chtomp4.py | #视频页面vedioSRC = 'https://www.finger66.com/mobile/post/5109165?channel=wechatSession&from=singlemessage&isappinstalled=0'
#放置ts文件所在目录
tsPath = "mp4/"
#获取ts文件参数
hostname = 'https://media.finger66.com'
tsParamUrl = hostname + '/posts/84222300000/MTU1NjEwNDU0ODI2Nw==.mp4.m3u8'
import urllib.request
tsParamData = urllib.req... |
cefb64cd02afe7fa7f4539ef37adac886b5e9b5e | 3fd62d2d2087b208861e07a691d9ffd99c494435 | /models/organization.py | 86729387513741f1d0087da2c06a4e3d69c6a96a | [] | no_license | mj-ux/Hands-on-SQLAlchemy | 39c337f884be6be53e1805e78ae550b52bca251c | 39116fc40067dcbadae12a695ae1f25e6bb78f25 | refs/heads/master | 2021-03-14T12:37:32.139740 | 2020-03-12T18:34:39 | 2020-03-12T18:34:39 | 246,766,425 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 428 | py | organization.py | from sqlalchemy import Column, Integer, String, ForeignKey
from sqlalchemy.orm import sessionmaker, backref, relationship
from base import Base
class Organization(Base):
__tablename__ = 'organizations'
id = Column(
Integer,
primary_key = True,
)
org_name = Column(
String,
... |
008962acab5d9eeb22872042c027e4ed46e206c1 | f07900334326d809a80f3619197769ea63b84c17 | /Programming-Basic-Python/Exams/Exam_9_10_March_2019/04. Darts.py | b35a9509f35d3e8025f8bc0abccaa21d3a2581b9 | [] | no_license | SJeliazkova/SoftUni | 394a0da0041bcf2d2be6c5ac18264d52df0f8ad1 | 5f2c7a9641495e75297d642346dd881de6bfc424 | refs/heads/main | 2023-02-27T19:11:35.637028 | 2021-02-06T18:55:58 | 2021-02-06T18:55:58 | 332,763,499 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 731 | py | 04. Darts.py | player_name = input()
start_score = 301
win_score = 0
shots = 0
unsuccessful_shots = 0
while start_score > 0:
command = input()
if command == "Retire":
print(f"{player_name} retired after {unsuccessful_shots} unsuccessful shots.")
break
else:
score = int(input())
if command... |
9147e6f2fbdf7ccce3e21a0e14883e203f86cb40 | 2f3be02ae7aabbec751392df769f88f17220f7d5 | /cheeseboys/level/__init__.py | 81d7908fd5d55bdcac4b6c773d28f030b6df9687 | [] | no_license | keul/Cheese-Boys | 730a3dc45f23390e31e802f7524eb1fbde73967f | 6a017bb3124415b67b55979c36edd24c865bda4d | refs/heads/master | 2021-06-01T16:47:37.728144 | 2016-10-22T15:45:38 | 2016-10-22T15:45:38 | 16,045,166 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 134 | py | __init__.py | # -*- coding: utf-8 -
from level import GameLevel
from cheeseboys.utils.level import loadLevelByName
from level_text import LevelText |
a49ab41893b4b7dcde6da39783b76583febe5aa5 | 3f5b1d0268443a8fd90f7173af19c749a5ad7b01 | /Old/servo2.py | 61e6ac1b8621ffa7b76771e46bab6829d9a891cf | [] | no_license | Darth-Carrotpie/HitScan | 998cfc8c35339f6b2d75f65be01af0b1aa0c3acd | 98d609d8ff7b51de686f03f28cfc504387235bea | refs/heads/master | 2021-09-03T22:24:18.869444 | 2018-01-12T13:46:41 | 2018-01-12T13:46:41 | 114,267,138 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,255 | py | servo2.py | from Tkinter import *
import RPi.GPIO as GPIO
import time
GPIO.setmode(GPIO.BCM)
GPIO.setup(18, GPIO.OUT)
pwm = GPIO.PWM(18, 666)
pwm.start(20)
#rotation speeds in ms:
lowPeriod = 1.3
midPeriod = 1.5
highPeriod = 1.7
intervalTime = 20.0
#speeds in freq:
lowFreq = 1/ (lowPeriod / 1000)
midFreq = 1/ (midPeriod / 1000)
h... |
0e58c4a65f82741a7b77fd7ee04318039d51afad | 10dbd9fd5db4bf77905ca5c13414bfc0d9b8cb07 | /4.c.py | f87bcce6452d0396af6661f43963ebf479c45df1 | [] | no_license | DVDHANUSH/lab_programs | 7d1f6857508944daca7815718b2baa16245b3e1d | 306db060e47e4a047ef11960fe89e7bf44567c7c | refs/heads/main | 2023-03-09T18:01:24.096895 | 2021-02-28T05:36:23 | 2021-02-28T05:36:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 260 | py | 4.c.py | a = input()
b = input()
print("string is present in it") if b in a else print("string is not present in it")
#(using regular expressions)
import re
a = input()
b = input()
c= re.search(b,a)
if(c):
print('present')
else:
print('not present')
|
bca035946f4624a3f3a5a67029c2957e6e790faa | 40fc602d3bfb49f6be72a31e1eb7af2dfd65af8d | /certifications/apps.py | 9497ca8fd5f20f4a8fa6168bc9f3730426f7e66d | [] | no_license | gourab-sinha/dynamicportfolio | 28220015eb4cc6e9b27496cce4267621faf0400f | 5de19a3a3b468e253cc65081c8c52b673c3a6ea5 | refs/heads/master | 2023-01-20T13:40:14.987715 | 2020-12-01T11:34:22 | 2020-12-01T11:34:22 | 308,969,993 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 103 | py | apps.py | from django.apps import AppConfig
class CertificationsConfig(AppConfig):
name = 'certifications'
|
916a6f97c962c60100858b66d45b8db6f6a8b0d1 | 717743ada4113dca1863d21db0c0459e6a3390ba | /DP_medium.py | 9e1bd2e9af759c65e35cc76c3007ce4baa31ba15 | [] | no_license | suixin233/OJ | 21ebb890bcc3035fd41b0ba41251c169dd4fbb3d | 80ace11518c5212591ffed839652e30d423effa1 | refs/heads/master | 2020-03-27T01:26:29.064052 | 2018-08-22T13:11:54 | 2018-08-22T13:11:54 | 145,710,991 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 404 | py | DP_medium.py |
A = [[1, 2, 1, 0, 2],
[0, 0, 3, 1, 2],
[1, 4, 5, 2, 3]]
S = [[0 for row in range(5)] for col in range(3)]
S[0][0] = A[0][0]
for i in range(3):
for j in range(5):
if i == 0 and j != 0:
S[i][j] = A[i][j] + S[i][j-1]
elif i!= 0 and j==0:
S[i][j] = A[i][j] + S[i-1][j]... |
c374bf13fa1ec52fd8d865a622c642b00e47f99f | 056f46ace547de7e656054407c2663532ebe9a3a | /anacreonlib/utils.py | 4c70ac472b93b1f23e0a780904bea0b128bded12 | [
"MIT"
] | permissive | ritikmishra/anacreonlib | 7c21cf0c2e561a3763b403ecafd7972bfe2da3e9 | 93ea2ec725e0bf19ffb5a026f4adb20164fd2184 | refs/heads/master | 2022-03-06T12:34:27.140979 | 2022-02-26T06:44:20 | 2022-02-26T06:44:20 | 138,549,895 | 5 | 1 | MIT | 2021-08-02T00:33:50 | 2018-06-25T06:00:41 | Python | UTF-8 | Python | false | false | 10,657 | py | utils.py | """Utility function to help with decode information from the Anacreon API
Where possible, function signatures have been ordered with partial application
(see :py:func:`functools.partial`) in mind.
"""
import math
from typing import (
List,
Dict,
Optional,
Sequence,
TypeVar,
Union,
Tuple,
... |
6fe099401d354dcba4d017730cd269361e286cd3 | b41473e6f87fa62525b3adf8c18c0f7e9dd3e3c1 | /tests/data/events.py | ae26631c31496e74f2c59155bd47269dae05f66a | [
"MIT"
] | permissive | Adeola-Adesoba/operationcode-pybot | 64b524c5b9018c4471ed79b1a0096910302a7833 | 0d0ac939c1249a0fbd5e468f99c7a956e1a6dbd8 | refs/heads/staging | 2022-11-20T05:33:14.847918 | 2020-05-30T19:43:35 | 2020-05-30T19:43:35 | 277,414,719 | 0 | 0 | NOASSERTION | 2020-07-06T01:43:36 | 2020-07-06T01:28:51 | null | UTF-8 | Python | false | false | 4,664 | py | events.py | TEAM_JOIN = {
"token": "supersecuretoken",
"team_id": "T000AAA0A",
"api_app_id": "A0AAAAAAA",
"event": {
"type": "team_join",
"channel": "C00000A00",
"user": {
"id": "U0AAAA",
"team_id": "T000AAA0A",
"name": "test",
"real_name": "te... |
23375760c0943ca177b7009031d9d17a91165c5c | 6df0d7a677129e9b325d4fdb4bbf72d512dd08b2 | /PycharmProjects/my_practice/python_practice/prac_75.py | 6f58e178a4597c274a8f393b0cfd58bb55ae6745 | [] | no_license | yingxingtianxia/python | 01265a37136f2ad73fdd142f72d70f7c962e0241 | 3e1a7617a4b6552bce4a7e15a182f30e1bae221e | refs/heads/master | 2021-06-14T15:48:00.939472 | 2019-12-13T05:57:36 | 2019-12-13T05:57:36 | 152,200,507 | 0 | 0 | null | 2021-06-10T20:54:26 | 2018-10-09T06:40:10 | Python | UTF-8 | Python | false | false | 285 | py | prac_75.py | #!/usr/bin/env python
#--coding: utf8--
import time
if __name__ == '__main__':
date = time.strftime('%m-%d')
if date == '03-08':
print '女神节'
elif date == '02-14':
print '情人节'
else:
print '发红包'
print '这是一个测试题' |
f8d815bcdc74452b66a1b3b33bf0fbe976e728c8 | 0f54c35ba27d6a40d09a43907871c67ee5f579bc | /CNN_tf2.py | 8d9694f7ec6332271d9464e13b8a9dddfa0702de | [] | no_license | boaz30333/Road-Signs-Classification | f941bcaca7c236467c356a0cd01c969002c043a8 | e1a40a6dcecab93c2ca822f3b14db0644152eb30 | refs/heads/master | 2023-03-26T18:26:47.358693 | 2021-03-22T22:13:39 | 2021-03-22T22:13:39 | 343,422,854 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,832 | py | CNN_tf2.py | # This is a sample Python script.
# Press Shift+F10 to execute it or replace it with your code.
# Press Double Shift to search everywhere for classes, files, tool windows, actions, and settings.
import tensorflow as tf
from tensorflow.keras import datasets, layers, models
import matplotlib.pyplot as plt
import numpy ... |
ef85f94282bfd7c9491c4e28bab61aaab5c792a5 | 34cba367646ef3d830680d05b9659233b0619ea9 | /widgets/ui_LibraryTab.py | a927c3ac0b52b60e7b4bf8d966999a974085dab5 | [
"MIT"
] | permissive | JaySon-Huang/SecertPhotos | c98be29b998e9e7c2cde3acc54eacc7d39c24922 | e741cc26c19a5b249d45cc70959ac6817196cb8a | refs/heads/master | 2020-04-08T06:57:11.284193 | 2015-06-12T13:30:31 | 2015-06-12T13:30:31 | 35,772,221 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,921 | py | ui_LibraryTab.py | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'src/ui_LibraryTab.ui'
#
# Created: Tue Jun 9 21:46:41 2015
# by: PyQt5 UI code generator 5.4
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_Tab(object):
def setupUi(se... |
8c8bbbc682889c8d79c893f27def76ad70e8bf8d | af62fab57160604a3e5a8980759f78f6b73ec5f7 | /app/settings.py | bbff81867b5520c935aede078ab101438a805abf | [
"Apache-2.0"
] | permissive | TeamFavr/user-service | 1d89e89653206b7d398934ada9255648f3712b3c | bb50fd03158c15b8c0ef2bff87bbe9a2924a2308 | refs/heads/master | 2021-01-20T18:01:16.778109 | 2016-08-11T16:13:09 | 2016-08-11T16:13:09 | 65,148,361 | 0 | 0 | null | 2016-08-10T18:57:09 | 2016-08-07T18:37:49 | Python | UTF-8 | Python | false | false | 25 | py | settings.py | DATABASE_NAME = "user_db" |
9d904225afd4f4d0cf338ae16f031f8ab41639ad | f36cd54c6b66bcd373b8074bb9738649877f3438 | /xblock_ifmo/fragment.py | 6f0ef88ef47078bed1d04879fb758234bb008182 | [] | no_license | npoed/ifmo-xblock-framework | 2f635dfb848f968927122cd36b60fcd74b44ba33 | d3eece00402eb69ffbdcb95e99c99d0b1c965106 | refs/heads/master | 2023-01-01T22:48:22.301231 | 2020-09-30T16:22:15 | 2020-09-30T16:22:15 | 299,882,622 | 0 | 0 | null | 2020-09-30T10:20:28 | 2020-09-30T10:20:27 | null | UTF-8 | Python | false | false | 4,624 | py | fragment.py | # -*- coding=utf-8 -*-
from mako.template import Template
from xblock.fragment import Fragment
from .lookup import TemplateLookup # xblock_ifmo.lookup
from .utils import deep_update
class FragmentMakoChain(Fragment):
"""
Класс, позволяющий последовательно оборачивать экземпляры Fragment друг в
друга.
... |
8cc0393082448bb8f61068b5c96e89ef3aee77ed | a4bd2b028f9327ba82351fefe7f68fd5c6c2ae17 | /python/seafevents/ldap_syncer/ldap_sync.py | 0bad40e15217216f2c7c0e9b16c52aaad075bc94 | [] | no_license | panSdu2/pro-set | 2b8e3d317600c4c1b5461e12ea98c6416d9b27e2 | 4cf350cad435c19cb63333a9641228247f7b606e | refs/heads/master | 2023-06-01T01:33:58.059737 | 2021-06-24T07:46:37 | 2021-06-24T07:46:37 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,951 | py | ldap_sync.py | #coding: utf-8
import logging
from threading import Thread
from ldap import SCOPE_BASE
from seafevents.ldap_syncer.ldap_conn import LdapConn
from seafevents.ldap_syncer.utils import bytes2str, add_group_uuid_pair
from seaserv import get_group_dn_pairs
logger = logging.getLogger(__name__)
def migrate_dn_pairs(set... |
21af630bf383ee1bdd0f644283f0ddadde71620a | c208954de92470c0144fad2e07a92ed1822edd59 | /Hurt/heart/fileupch/_.py | 844dd954c709543b966510bac175a59fdc47e71a | [
"MIT"
] | permissive | rendy026/reverse-enginnering | 4217f3b723569fb792bac0f22a56a305199db1dc | f04cec0bf518a2617fc4fd7155f755fafc2af799 | refs/heads/master | 2023-01-07T15:49:15.791052 | 2020-10-13T09:22:02 | 2020-10-13T09:22:02 | 303,575,571 | 0 | 0 | MIT | 2020-10-13T09:41:59 | 2020-10-13T03:17:42 | Python | UTF-8 | Python | false | false | 854 | py | _.py | #!/bin/usr/python2.7.x
import os, re, urllib2
def main():
ip = raw_input(" Target IP : ")
check(ip)
def check(ip):
try:
print "Loading Check File Uploader...."
print 58*"-"
page = 1
while page <= 21:
bing = "http://www.bing.com/search?q=ip%3A" + \
ip + "+upload&count=50&first=" + str(... |
eb853e430b996a81dc2ef20c320979a3e04d956a | 607696b9a97c560097931db7db09f820219e7a8a | /www.beautyleg7.com/beautyleg7/spiders/beautyleg7_spider.py | 20ee7ea5b1d7c9a170e7b7dd36f8e43985769e81 | [] | no_license | yidasanqian/Beautyleg7Spider | cb2fa1a8acc4221892d15a10057e2f63013cee39 | eb1412b7785f95045fa3c48a73f2c12582b74d17 | refs/heads/master | 2020-07-04T15:12:45.029351 | 2018-06-27T16:10:44 | 2018-06-27T16:10:44 | 202,321,824 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 12,078 | py | beautyleg7_spider.py | #!/usr/bin/env python3
# -*- coding: UTF-8 -*-
import hashlib
import re
from datetime import datetime
import gevent
import requests
import scrapy
from gevent.pool import Pool
from lxml import etree
from scrapy.http import HtmlResponse
from sqlalchemy import create_engine, func
from sqlalchemy.orm import sessionmaker
... |
bc4684d255a46427f708d8ce8bda2e12fb8c8ffe | a57ba073b6c827063d0a26bf14506c8c52796b6b | /examples/routes/resequence_route.py | 2b05c5438e0159af666dd7ed725165799fddfa1c | [
"ISC"
] | permissive | waffledunker/route4me-python-sdk | 95f7c203106e564dbde16197442564fab92c5cfe | b68c5d9209ee0146104177e59676245625a6882c | refs/heads/master | 2022-03-11T23:12:46.265895 | 2019-11-11T15:15:22 | 2019-11-11T15:15:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,969 | py | resequence_route.py | # -*- coding: utf-8 -*-
from route4me import Route4Me
API_KEY = "11111111111111111111111111111111"
def main():
r4m = Route4Me(API_KEY)
route = r4m.route
response = route.get_routes(limit=1, offset=0)
if isinstance(response, dict) and 'errors' in response.keys():
print('. '.join(response['err... |
d015a1b27a3a9e7f5e6614da752137064000b905 | d452e34253561a47b974e260dabd8dcda6e750a2 | /unsupervised_learning/0x03-hyperparameter_tuning/6-bayes_opt.py | 3ec45695bfe3946e07cf0ad5cdbf10d5b5e9e242 | [] | no_license | JohnCook17/holbertonschool-machine_learning | 57fcb5b9d351826c3e3d5478b3b4fbe16cdfac9f | 4200798bdbbe828db94e5585b62a595e3a96c3e6 | refs/heads/master | 2021-07-07T10:16:21.583107 | 2021-04-11T20:38:33 | 2021-04-11T20:38:33 | 255,424,823 | 3 | 2 | null | null | null | null | UTF-8 | Python | false | false | 9,354 | py | 6-bayes_opt.py | #!/usr/bin/env python3
"""Transfer learning with xception"""
import tensorflow.keras as K
from GPyOpt.methods import BayesianOptimization
import pickle
import os
import numpy as np
class my_model():
"""A model bassed on xception"""
def make_model(self, param):
"""makes the model"""
self.lr = ... |
73dcc104f34a587b63e384ed19b039856e92dc7e | dcd15b7ca3a32825f499ce24fa4a772064a87387 | /LWYapi/asgi.py | dce09529ad0ed9f03a788258a82343bc3cc554b9 | [] | no_license | iampeterkr/LWYapi | f8b034616c6c3d1b92f887041d18e1d4b4c25969 | 09815c245cd279b851c239535d802b333cead5ee | refs/heads/master | 2021-01-19T21:41:28.342372 | 2017-09-19T00:51:57 | 2017-09-19T00:51:57 | 88,689,317 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 363 | py | asgi.py | """
ASGI entrypoint file for default channel layer.
Points to the channel layer configured as "default" so you can point
ASGI applications at "askdjango.asgi:channel_layer" as their channel layer.
"""
import os
from channels.asgi import get_channel_layer
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'LWYapi.setting... |
317d04c1e91476aa0b4a947f4b17307895ebd6d4 | 20870db33c382d268d33dddb6a3ea8a75e76db17 | /appengine_example/main.py | 2a946637b0a89de4b7a0b69af53f4e051e3b1ece | [] | no_license | Syldragoon/web-projects | 60b18d177b2f8fcd795c9460f7e9dba6b384b9b0 | efecc540e910b43c4fba3486a776f53255304ab6 | refs/heads/master | 2022-03-06T14:03:30.906410 | 2019-11-22T13:18:36 | 2019-11-22T13:19:57 | 15,585,912 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,808 | py | main.py | # Copyright 2016 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... |
0077d82e2bf65fcb26394c1ffac9ae013e5e33e8 | d7cfe98faeb0fe1b4ce02d54d8bbedaca82764f7 | /1030_문제풀이/swea_1865_동철이의일분배.py | 82beb50e04065a37459b8829e85db855b0fa9e71 | [] | no_license | Anseik/algorithm | 27cb5c8ec9692cf705a8cea1d60e079a7d78ef72 | 925404006b84178682206fbbb3b989dcf4c3dee9 | refs/heads/master | 2023-02-26T00:02:01.696624 | 2021-02-03T14:10:28 | 2021-02-03T14:10:28 | 301,753,927 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 717 | py | swea_1865_동철이의일분배.py | import sys
sys.stdin = open('swea_1865_동철이의일분배.txt')
def distribution(p, curper):
global max_per
if curper < max_per:
return
if p == N:
max_per = max(max_per, curper)
return
for j in range(N):
if not jobs[j] and per[p][j]:
jobs[j] = 1
distributi... |
161744a509749c410b534ac4d0625e64b0226751 | 710f1e1eefde21255c6d05b3d55ef95a1236db83 | /kingfisher_scrapy/spiders/belgium_digiwhist.py | 5889a415c985b255aa165aca19bc0b7183f44ac2 | [
"BSD-3-Clause"
] | permissive | open-contracting/kingfisher-collect | 7320a67c29ef56a426d1671236b09baff817767b | 83c445879189ef3c52c9e9e89e024aa8e303f5f7 | refs/heads/main | 2023-08-13T12:36:27.200328 | 2023-08-09T20:37:27 | 2023-08-09T20:37:27 | 162,262,509 | 11 | 8 | BSD-3-Clause | 2023-09-04T19:16:40 | 2018-12-18T09:21:59 | Python | UTF-8 | Python | false | false | 218 | py | belgium_digiwhist.py | from kingfisher_scrapy.spiders.digiwhist_base import DigiwhistBase
class BelgiumDigiwhist(DigiwhistBase):
name = 'belgium_digiwhist'
start_urls = ['https://opentender.eu/data/files/BE_ocds_data.json.tar.gz']
|
84a0d1a1e2670d2066797bd759896409512d05ce | fe197015c1c55ad214a8954c6d66a0a13a889477 | /src/asterixdb/shopalot/datagen.py | fc04ed2377782f87844edf03c6e9de068b6a4ee8 | [] | no_license | glennga/ilima | 1580a75ad90d00167a35161257da02b318bd0524 | 13f4e89b4f5a84a74334735e2a849147ab40a90d | refs/heads/master | 2023-05-26T22:50:39.446945 | 2021-06-09T16:24:15 | 2021-06-09T16:24:15 | 283,677,568 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 11,975 | py | datagen.py | import datetime
import decimal
import random
import faker
import json
import argparse
import abc
class PrimaryKeyGeneratorFactory:
@staticmethod
def provide_range_generator(start_id, end_id):
def _range_based_pk_generator():
working_primary_key = start_id
while working_primary_... |
bb0cf9dd384ef39404ae8255b9a2392ef918c5bb | 491f29501fa7d484a5860f64aef3fa89fb18ca3d | /examples/mechanics/JointsTestsWithContactDetection/Joint_friction.py | e55d5ef273b83522bfd20a25a59fcd7559a6917d | [
"Apache-2.0"
] | permissive | siconos/siconos-tutorials | e7e6ffbaaea49add49eddd317c46760393e3ef9a | 0472c74e27090c76361d0b59283625ea88f80f4b | refs/heads/master | 2023-06-10T16:43:13.060120 | 2023-06-01T07:21:25 | 2023-06-01T07:21:25 | 152,255,663 | 7 | 2 | Apache-2.0 | 2021-04-08T12:00:39 | 2018-10-09T13:26:39 | Jupyter Notebook | UTF-8 | Python | false | false | 1,657 | py | Joint_friction.py | #!/usr/bin/env python
from siconos.mechanics.collision.tools import Contactor
from siconos.io.mechanics_run import MechanicsHdf5Runner
import siconos.numerics as sn
import siconos.kernel as sk
with MechanicsHdf5Runner() as io:
io.add_primitive_shape('BigBox', 'Box', (1, 1, 1))
io.add_primitive_shape('SmallBo... |
62e67f50720ddeb065d815a385fbb8bc005bdc1b | 2af595cf31760c57e6a691e18ac2a23c5ef784d5 | /TaskManager/tasks/migrations/0006_auto_20190314_1648.py | ad087895c3b6e317de50e8669f07e965b25f872d | [] | no_license | yogesh1905/fsf_2019_screening_task1 | 2aecee153b465cef9012d8c7f1967a78b1fc7b8b | 1ad0b26ca0d0ce0588010242b5a855484910be47 | refs/heads/master | 2021-06-16T06:43:45.455679 | 2019-07-25T20:38:14 | 2019-07-25T20:38:14 | 175,465,565 | 0 | 0 | null | 2021-06-10T21:44:32 | 2019-03-13T17:10:50 | JavaScript | UTF-8 | Python | false | false | 452 | py | 0006_auto_20190314_1648.py | # Generated by Django 2.1.7 on 2019-03-14 16:48
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('tasks', '0005_group'),
]
operations = [
migrations.AlterField(
model_name='task',
name='status',
field=m... |
def5ebfd32a0ba3c6fb43d8437b5f205aa3c1b64 | 1321ba8201f27d9950105f678864ee5f7dd27031 | /send_text.py | 0f8f850d7a450e86993ddd49a4b4c76430e4a854 | [] | no_license | osandrolucas/PythonUdacity | 874ad7df2e2bfee683c0aa6a2bfa07a51d23e750 | f963d097cb4a307733d4abba533bdbf247dea14a | refs/heads/master | 2020-04-03T12:19:25.832573 | 2018-11-11T18:16:23 | 2018-11-11T18:16:23 | 155,248,755 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 371 | py | send_text.py | from twilio.rest import Client
# SID da sua conta, encontre em twilio.com/console
account_sid = "input"
# Seu Auth Token, encontre em twilio.com/console
auth_token = "input"
client = Client(account_sid, auth_token)
message = client.messages.create(
to="+5551984373078",
from_="+17122275825",
body="Olhe q... |
c0a4c60a9afaf2ab92442e9b06e1e79ae538a993 | d8498ca05daa83f108a231c024b4efa2f4b71747 | /ex15_2.py | a44f263937ec590f395cf7ed732689fac2d05929 | [
"CC-BY-4.0",
"CC-BY-3.0"
] | permissive | antoalv19/TP_solutions | ca9baf22ca1d16bac1f1bbabdefe473bb1b0ac0a | 7c1d3b35c11cfbd9c66be9878aafa1dbe8802581 | refs/heads/master | 2020-07-03T14:31:44.626360 | 2020-01-04T20:01:27 | 2020-01-04T20:01:27 | 201,936,524 | 0 | 0 | null | 2019-08-12T13:32:04 | 2019-08-12T13:32:03 | null | UTF-8 | Python | false | false | 1,457 | py | ex15_2.py | #!/usr/bin/env python2
class Rectangle:
'''Represents a rectangle
Attributes: width, height, corner.
'''
class Point:
'''Represents a point in 2-D space.'''
class Circle:
'''Represents a circle.
Attributes: center, radius
'''
import math
# for turtle reference, see: https://docs.python.org/2/library/tu... |
01cf932ace7bee87d1d3f83a6730cec6fa981a47 | f02c3d775de1d9c92f3d4d1f1686d33e198ab824 | /segmentation/segmentation.py | d3cb07db46c6fff4bb1b091954a370ccc4a25210 | [] | no_license | mmatl/segmentation | 8917e0fc0e447fa1cddcbe0fe2ca841aca1462f5 | 7a9b4f0a1a24236a331e71c6bba522318262e5ea | refs/heads/master | 2021-03-27T19:04:42.149605 | 2016-12-08T21:59:07 | 2016-12-08T21:59:07 | 73,516,729 | 6 | 2 | null | null | null | null | UTF-8 | Python | false | false | 29,156 | py | segmentation.py | """
File for processing mesh segmentations.
Author: Matthew Matl
"""
import numpy as np
import networkx as nx
from visualization import Visualizer3D
from meshpy import Mesh3D
from d2_descriptor import D2Descriptor
from color_picker import indexed_color
class FaceNode(object):
"""A single triangle in a 3D mesh. ... |