blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 2 616 | content_id stringlengths 40 40 | detected_licenses listlengths 0 69 | license_type stringclasses 2
values | repo_name stringlengths 5 118 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 63 | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 2.91k 686M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 23
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 213
values | src_encoding stringclasses 30
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 2 10.3M | extension stringclasses 246
values | content stringlengths 2 10.3M | authors listlengths 1 1 | author_id stringlengths 0 212 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
c47526f0d790a2ed2821b182298c5174a9f702cc | b62f1ed18ba20c79f7c0163bdecce776fa91c4ce | /GAN_embedding/discriminator.py | 65781a01d2c8cebc8eb8ccc6921f93536416f6d0 | [] | no_license | xymeng16/CanetGAN | 0e26f06094c1494fb5f35e5b802560f9d28dd66e | 1dba84f93414e53610f6d24695857d3d4343fd46 | refs/heads/master | 2020-03-06T22:16:44.396231 | 2018-07-19T16:37:46 | 2018-07-19T16:37:46 | 127,099,303 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,724 | py | # the discriminator class
import tensorflow as tf
import config
class Discriminator():
def __init__(self, n_node, node_emd_init):
self.n_node = n_node
self.node_emd_init = node_emd_init
with tf.variable_scope('discriminator'):
self.node_embed = tf.get_variable(name="node_embed... | [
"xymeng16@gmail.com"
] | xymeng16@gmail.com |
1195760a35ce3a9c14f793d3c538dc657c321ab7 | 12c0d1826453412581534dc5ed7d3bda583b8b13 | /zip_scheduler.py | 291dfc5ba2cdd5c3b58dc9cd06b84cc38197d976 | [] | no_license | bfolks2/zipline | b1d51e3601bef40202216608322764ab753c9398 | bb2a9bc6872f300128a53cf18dac855833d74ee8 | refs/heads/master | 2020-03-31T15:35:39.574524 | 2018-10-11T14:58:39 | 2018-10-11T15:00:24 | 152,342,658 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 13,388 | py | from itertools import permutations
from math import sqrt
import csv
import os
PROJECT_ROOT = os.path.abspath(os.path.join(os.path.dirname(__file__), os.pardir))
# Data arrays
hospital_database = []
all_orders_list = []
class Order(object):
order_priorities = ('Resupply', 'Emergency')
def __init__(self, rec... | [
"ben.folks@redshelf.com"
] | ben.folks@redshelf.com |
fef3f4b53f772e17c6f18018ef896aa30cabb937 | 4f17180695203db25fe84e13234af31a518264f7 | /blog/migrations/0001_initial.py | c8bc924c8ef94da501f9aecca788045ae71b7940 | [] | no_license | VS69/wagtail | aa829e646cb7cf51523eb39d3fec0a97cc8aacdc | c7d5e50e13f7fffc8f2588ef063a81a9aab62951 | refs/heads/master | 2020-06-14T15:26:20.392478 | 2017-02-19T12:11:08 | 2017-02-19T12:11:08 | 75,177,772 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,250 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.10.3 on 2016-11-30 15:20
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
import wagtail.wagtailcore.fields
class Migration(migrations.Migration):
initial = True
dependencies = [
('wagta... | [
"vladimir.salitrinsky@gmail.com"
] | vladimir.salitrinsky@gmail.com |
1ab900d7222571937f860b89e1f9ac4071e79175 | 3f2fe42412701e6395b518a0f1f26338c39fb12d | /neop.py | 0b0fff4aca6880ebc19d93f02b085b6923fbe9fd | [] | no_license | owly/wc2021nolight | 9d893da4db4aa19b4aed17a29fd801580c9373ce | f110aa049e457d55da39fc180af51991baf068f5 | refs/heads/main | 2023-05-19T00:26:52.320607 | 2021-06-05T16:24:29 | 2021-06-05T16:24:29 | 374,159,991 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,778 | py | # SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries
# SPDX-License-Identifier: MIT
# Simple test for NeoPixels on Raspberry Pi
import time
import board
import neopixel
# Choose an open pin connected to the Data In of the NeoPixel strip, i.e. board.D18
# NeoPixels must be connected to D10, D12, D18 or D21 ... | [
"github@haham.net"
] | github@haham.net |
1d56cb579b4790f733317d1a79f0a8d3c8cd7f52 | 1fdc846f4e5b7bda56e8740b859c8340d9b5141a | /tests/test_input_biot_npbc_lagrange.py | cc685e4db4201cb225b7adde4304c90956861222 | [
"BSD-3-Clause"
] | permissive | olivierverdier/sfepy | b824fdab7d91e137a371c277901fbb807b316b02 | 83aefb7b33ea17f4acb83388ba8bc7314c77616c | refs/heads/master | 2021-01-18T05:39:13.127137 | 2010-10-25T13:13:18 | 2010-10-25T17:31:37 | 1,022,869 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 164 | py | input_name = '../examples/biot/biot_npbc_lagrange.py'
output_name = 'test_biot_npbc_lagrange.vtk'
from testsBasic import TestInput
class Test(TestInput):
pass
| [
"cimrman3@ntc.zcu.cz"
] | cimrman3@ntc.zcu.cz |
3a557d315f18d0baf66b76f127915f68f305201f | 772a9f52f73100fc8bb764f841519242db5c310f | /hp_hyphenation.py | cc5f8f8394de9ad22b9924d78ed20953973a12a4 | [] | no_license | LifeShouldBeAMusical/epub-soup-to-latex | e9f664e0a0609bbc0109a13fcb41176bb62e91c3 | 485bdf2842b113bf0b7e9bc151a74834d1ae05f3 | refs/heads/master | 2021-05-23T15:47:25.707860 | 2020-04-06T01:31:15 | 2020-04-06T01:31:15 | 253,367,118 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,462 | py | hp_hyphenation = """
\hyphenation{
A-bra-xas
A-va-da
Accio
Adal-bert
Agrip-pa
Agua-men-ti
Al-be-r-ic
Al-bus
Al-ec-to
Alas-tor
Alo-ho-mora
Amor-ten-tia
Amy-cus
An-dro-me-da
An-glia
Anap-neo
Ani-ma-gi
Ani-ma-gus
Ap-pa-ra-ted
Ap-pa-ra-tes
Ap-pa-ra-ting
Ap-pa-ra-tion
Ap-pa-rat... | [
"rickipettinato@gmail.com"
] | rickipettinato@gmail.com |
02fb72c39313d3cf3fa118b02b5ee4482843631b | b6918aacbaa197c15cbcc39281006e1034342661 | /bryansWebsite/wsgi.py | f78e9cfbd3c469dc51eb89a8c39579b952bc8647 | [
"MIT"
] | permissive | bhhaskin/bryans.website | f519e4a5a58b5371fc25452b05330a9387d52b0e | d8ce350745f6f2fa1f630f0abb712f7846a5986e | refs/heads/master | 2021-01-10T14:09:19.708188 | 2015-12-27T08:34:49 | 2015-12-27T08:34:49 | 44,498,066 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 401 | py | """
WSGI config for bryansWebsite 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/1.7/howto/deployment/wsgi/
"""
import os
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "bryansWebsite.settings")
from d... | [
"bryan@ocgcreative.com"
] | bryan@ocgcreative.com |
2b76192c2bef7db5b34fe1f9dbf931220a18b0c8 | b7935934c77a236e1afa4b51163ab83b62c78f09 | /property/property1/myproject/mysite/migrations/0007_auto_20180218_0515.py | b8f2283e836786b47b6589bed8e6aafa8dccdeb2 | [] | no_license | RahulReddyBaddam/property-19-march | 9ee3fa290ea146311a7137ecb8429d9e6df3ecdc | ad2379ca3d8b552b2c43e0afbc1a0e262a6af270 | refs/heads/master | 2021-04-09T16:18:51.858520 | 2018-03-19T05:05:21 | 2018-03-19T05:05:21 | 125,803,817 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 359 | py | # Generated by Django 2.0.2 on 2018-02-17 23:45
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('mysite', '0006_auto_20180218_0510'),
]
operations = [
migrations.RenameField(
model_name='site',
old_name='cat',
... | [
"noreply@github.com"
] | RahulReddyBaddam.noreply@github.com |
0df1697632882f6375fe245ad6647dbc6937cffe | 275b09ecff10a1896cef814006210fed98693c93 | /command.py | cd28df2e17cbf117edbc0eb9e2080bd98b7e58c8 | [] | no_license | xiaohaoliang/lstm_attention | c7e446223effa1025b53a559801c98a79f0d38f3 | f1b9d97173ec864defe965940e07866b89989d15 | refs/heads/master | 2020-04-26T03:19:01.266638 | 2018-09-09T15:27:07 | 2018-09-09T15:27:07 | 173,262,985 | 0 | 1 | null | 2019-03-01T08:19:23 | 2019-03-01T08:19:22 | null | UTF-8 | Python | false | false | 4,380 | py | def prepare_arguments(parser):
add_data_arguments(parser)
add_audio_arguments(parser)
add_lstm_arguments(parser)
add_training_arguments(parser)
def add_data_arguments(parser):
parser.add_argument(
'--data_dir',
type=str,
default='data/yes',
help='Where to download t... | [
"waitingcheung@users.noreply.github.com"
] | waitingcheung@users.noreply.github.com |
e83344bc5686876da9d4a28fdd9a32c2540bccf5 | a7b5adc5f72b9ef71c0c71691492f8af8a32c868 | /Minseo-Kim/leetcode/206_Reverse_linked_list.py | 73148fa6b52f9be00ce91fc881e9ae477ff1fd88 | [] | no_license | mintheon/Practice-Algorithm | 535ff607e36d1bfa9f800a28091a52c48748221c | 3a653a1d8cc6e1438cab47a427ccd0b421a10010 | refs/heads/master | 2023-04-10T17:43:10.434210 | 2021-04-10T18:46:26 | 2021-04-10T18:46:26 | 347,719,297 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 610 | py | # Definition for singly-linked list.
# class ListNode:
# def __init__(self, val=0, next=None):
# self.val = val
# self.next = next
# Time complexity: O(n), ** Space complexity: O(1)**
# Runtime: 32 ms, faster than 87.13% of Python3
# Memory Usage: 15.5 MB, less than 93.25% of Python3
class Soluti... | [
"noreply@github.com"
] | mintheon.noreply@github.com |
55cfaeab09e1c56425b6b10cc584e7562f88c62b | c52a955010f0ea35424c917af87b03ca6120b230 | /chat/migrations/0004_auto_20201229_1616.py | a59fcc80b72191770f9aebac7af433aedbba9436 | [] | no_license | lepestos/chat | 2db2701851b2f2d1ace2c7587ab708ae0eee4c6d | efcd04f52c63f96b3f21bf3aabcbdb18968d62ab | refs/heads/main | 2023-03-19T11:44:31.525621 | 2021-03-16T11:19:50 | 2021-03-16T11:19:50 | 348,318,174 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 366 | py | # Generated by Django 3.1.4 on 2020-12-29 16:16
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('chat', '0003_auto_20201229_1557'),
]
operations = [
migrations.RenameField(
model_name='message',
old_name='chatroom',
... | [
"kirill-nazarov1928@yandex.ru"
] | kirill-nazarov1928@yandex.ru |
e1eca558e5cbce67053dce1a670a4aa3069896cd | ff6248be9573caec94bea0fa2b1e4b6bf0aa682b | /StudentProblem/10.21.12.28/5/1569571946.py | af429088f6ad955c7b65295f7f9a893d0bbe5fc1 | [] | no_license | LennartElbe/codeEvo | 0e41b1a7705204e934ef71a5a28c047366c10f71 | e89b329bc9edd37d5d9986f07ca8a63d50686882 | refs/heads/master | 2020-12-21T17:28:25.150352 | 2020-03-26T10:22:35 | 2020-03-26T10:22:35 | 236,498,032 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 288 | py | import functools
import typing
import string
import random
import pytest
## Lösung Teil 1.
def mysum(xs: list) -> int:
return sum(xs)
## Lösung Teil 2. (Tests)
def test_mysum():
assert mysum([1,2,3]) == 6
######################################################################
| [
"lenni.elbe@gmail.com"
] | lenni.elbe@gmail.com |
6ef1ee991e0efa811b2815eddfd338b124f7053b | 5f843c8a59dd366b3bd687bcc5351a6d7caba6ef | /salabim_test.py | 05daa3b216d67f53d9cefb9146bf42e9e3a2a3d2 | [
"MIT"
] | permissive | Xiong7777777/salabim | f66167fd60b9d001fb4060e077bc99092e986aee | e2e59120f46266363c292f7aa513fe32740aefa5 | refs/heads/master | 2020-03-17T07:03:29.845110 | 2018-05-04T13:45:22 | 2018-05-04T13:45:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 45,294 | py | import salabim as sim
import math
import random
import string
import time
import logging
import inspect
import platform
Pythonista=(platform.system()=='Darwin')
def test():
test62()
def test62():
class X1(sim.Component):
def process(self):
yield self.hold(100)
class X... | [
"noreply@github.com"
] | Xiong7777777.noreply@github.com |
6ea8c664d8363b0e68c43722576fb087038d2c4c | 0ab1b0b7290681942181b60846f50df916c6d922 | /dj_celery/celery.py | 635ebce519a67c47a6a3767287ce8e417cb6d432 | [] | no_license | FazlulAyanKoushik/Django_celery | 17f65c927da62566fcc86ff82faa23648fd45e08 | 5a49026e828a610b2bba721a799213ea8f5bb9ef | refs/heads/master | 2023-06-25T07:53:40.087178 | 2021-07-26T15:21:34 | 2021-07-26T15:21:34 | 389,678,440 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 486 | py | from __future__ import absolute_import, unicode_literals
import os
from celery import Celery
from django.conf import settings
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'dj_celery.settings')
app = Celery('dj_celery')
app.conf.enable_utc = False
app.conf.update(timezone = 'Asia/Dhaka')
app.config_from_object(s... | [
"ak.fazlulayan117@gmail.com"
] | ak.fazlulayan117@gmail.com |
31f0c9b8606299f25247b4d6a5709b3949bbd1f9 | 773e10ba2b621f08c55219a118557549964e002c | /integration_test/GkPos_test.py | e3b592202ac555b51396747039e3ed0463eaa185 | [] | no_license | tepotepon/taka2 | ae5e9348e8cda8092b07d3b37bd473a239c9bf1d | 6d69f07ef009d15b9fe19ca31d7a3d6f28467975 | refs/heads/master | 2021-07-21T13:10:35.276947 | 2020-06-24T10:38:51 | 2020-06-24T10:38:51 | 186,963,001 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 95 | py | import LibTaca.GkPos as gkp
gkPos = gkp.GkPos(5)
gkPos.push((0,0))
print(gkPos.get_estimate()) | [
"javier.torresb@gmail.com"
] | javier.torresb@gmail.com |
809865b08ec1a4e3b4e45e92660e7eb685d4401c | 1e94439a8db204d703cfeaae3ab69aa005ea059d | /cameras/image_converter.py | d3a781b4335e0e55783295881a5d8070cc462346 | [
"MIT"
] | permissive | steelhawks/1050-105 | c12836de243404cf632a7d1b17d70f0bfaff9ad9 | 778d085b52fa1d55df027982642f4078daa333b6 | refs/heads/master | 2023-02-16T17:56:19.859534 | 2021-01-20T00:59:35 | 2021-01-20T00:59:35 | 327,494,581 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 242 | py | from PIL import Image
from io import BytesIO
def convert_to_jpg(image):
"""TBW."""
# assumes image is RGB provided
im = Image.fromarray(image)
mem_file = BytesIO()
im.save(mem_file, 'JPEG')
return mem_file.getvalue()
| [
"haliwhang4444@gmail.com"
] | haliwhang4444@gmail.com |
6433009879ec60f413d1e8dc840c7aaa7f3dfb02 | df30c6a9c0ebc84acfc94d03fc28b5420c4d88ff | /apps/drama/drama/spiders/__init__.py | ffd5c23f0991e312c068d7a28e84405481d5a29d | [] | no_license | aitjcize/bb8 | e347d145323a9530d083548ac858380405c5ca54 | dc8d9fb76bf583386e173f3abcbf33008d08afd9 | refs/heads/master | 2021-03-27T20:11:48.166184 | 2016-11-09T08:22:15 | 2016-11-09T08:22:15 | 59,660,680 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 135 | py | # -*- coding: utf-8 -*-
"""
Spiders module
~~~~~~~~~~~~~~
Copyright 2016 bb8 Authors
"""
from spiders import DramaSpider
| [
"kevin@compose.ai"
] | kevin@compose.ai |
7f5c194b447ceb774feca8837cfa0126ad8f8b14 | 45726c5611b26b35a4f059baa46cedd41c31d447 | /SAAS/main/urls.py | 1c413976ab9fdde227b87b99e4d845a0be906e14 | [] | no_license | hhy12138/Ipsos_SAAS_translation | 746bfc1673fbaf8a9529000db49f0af9773a20f5 | 884b9d94eb0a6672286a6a026aa57941747e3a51 | refs/heads/master | 2020-09-08T01:18:37.262405 | 2019-11-20T08:04:26 | 2019-11-20T08:04:26 | 220,968,643 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 328 | py | from django.conf.urls import url
from main import views
urlpatterns = [
url(r'shutdown',views.shutdown),
url(r'^test/',views.test),
url(r'^change_time/',views.change_time),
url(r'^upload/',views.upload),
url(r'^translate/',views.translate),
url(r'^download/',views.download),
url(r'',views.... | [
"37316896+briiiskiiiday@users.noreply.github.com"
] | 37316896+briiiskiiiday@users.noreply.github.com |
721b363586299f2a3880d59a8d08d7268a47a523 | 47f5830ca57ed1ac91f52c8a0b239f321eb3da7e | /train_RNN.py | a3fe395a39fb92c5dc15c5e1020e5fefb4038e97 | [] | no_license | achyuta26/MusicalFace | 98ff51c32dd3c2e0ba7307074f01dc2dd118b843 | 58ecc435da421b99f5daa78689c7a5719a6e57e9 | refs/heads/master | 2020-04-12T00:23:34.071336 | 2018-12-18T18:18:23 | 2018-12-18T18:18:23 | 162,198,374 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,175 | py |
# coding: utf-8
import numpy as np
import matplotlib.pyplot as plt
import keras
import pandas as pd
import csv
from sklearn.model_selection import train_test_split
from sklearn.preprocessing import LabelEncoder
from keras.models import Model, Sequential
from keras.layers import LSTM, Activation, Dense, Dropout, Inpu... | [
"noreply@github.com"
] | achyuta26.noreply@github.com |
f31830753d4ff210bc95a5c5ade96ed335226bc1 | 9999a45225358bca3fdc18a5c1982827b8a7fbcb | /appointment/models.py | 6fe5a424166d83c9cb36f2dab266df4271d449ea | [] | no_license | Starinfosol/Starinfosol-live | e67d6713a3b979d13f47a14dd147079f9c58cf12 | f374444e37b0964a0679ac42198ad3546dd9cc7d | refs/heads/main | 2023-06-12T06:31:39.626318 | 2021-07-09T12:50:29 | 2021-07-09T12:50:29 | 368,502,086 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 958 | py | from django.db import models
from django.utils import timezone
# Create your models here.
TAGS = (('Dr. Bhuvneshwer', 'Dr. Bhuvneshwer'), ('Dr. Ishwari', 'Dr. Ishwari'), ('Dr. Shriwastav', 'Dr. Shriwastav'))
class Appointment(models.Model):
sno= models.AutoField(primary_key=True)
name= models.CharField(max_... | [
"starinfosol954@gmail.com"
] | starinfosol954@gmail.com |
a6b85a3f6e2b8d0f1e3cf58986db2e2c22612ed7 | 6d16362a8d7d9bb56a06613f3a720178fc69f834 | /backend/models.py | acd4a5ec1cca8fc1d1044b0ed9c8048d108f86d8 | [
"MIT"
] | permissive | marlonxteban/trivia_api | 8d3638e8fe1e48e5a514073a1e706b16cc7f6445 | 83df5ba322aaaf7f2f5e2caa0da635f5fcf134ae | refs/heads/main | 2023-02-17T16:13:25.028428 | 2021-01-13T03:30:31 | 2021-01-13T03:30:31 | 326,855,527 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,228 | py | import os
from sqlalchemy import Column, String, Integer, create_engine
from flask_sqlalchemy import SQLAlchemy
from flask_migrate import Migrate
import json
database_name = "trivia"
database_path = "postgres://{}/{}".format('localhost:5432', database_name)
# change database_path with the following to use the docker e... | [
"marlonxteban@gmail.com"
] | marlonxteban@gmail.com |
c97fb1324900addb6349889f1cc8dcf15e86c005 | ef5f166653d5c945b41bc28e164dc7ee2c4cf64b | /tests/conftest.py | cc74138852ad74b1738c60b4bd28277c5d783796 | [
"Apache-2.0"
] | permissive | aliceUnhinged613/trains-agent | fdde3c6d62c8161b9b4b72c369f6ab80f25e098c | 28f47419b06a9b67a92dbee16a145a4a42c30015 | refs/heads/master | 2022-12-19T03:43:20.925165 | 2020-09-15T17:26:02 | 2020-09-15T17:26:02 | 296,956,668 | 1 | 0 | Apache-2.0 | 2020-09-19T21:46:26 | 2020-09-19T21:46:24 | null | UTF-8 | Python | false | false | 1,909 | py | from argparse import Namespace
from contextlib import contextmanager
import pytest
import yaml
from pathlib2 import Path
PROJECT_ROOT = Path(__file__).resolve().parents[1]
@pytest.fixture(scope='function')
def run_trains_agent(script_runner):
""" Execute trains_agent agent app in subprocess and return stdout as... | [
""
] | |
446eb5aba336d453446a65b1cb40675f2b609055 | 98581c6f418fcc25061b7ee416f45dc24c6fd2ec | /AT_2021/DrawFunctions.py | 84d97481a960a777b33e83d698615c8982338ac7 | [
"MIT"
] | permissive | kishorejsn/VideoAnnotationTool_MastersThesis | 067a69522ffe62249cc069b0e95c04c6f384dd31 | 6754a29d1ce06f27acfbf58f58d730b4f0937b96 | refs/heads/main | 2023-04-21T04:25:01.374582 | 2021-05-11T07:04:18 | 2021-05-11T07:04:18 | 366,287,041 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 21,143 | py | from typing import List, Any, Union, Tuple
import cv2
import numpy as np
from lane_detection import *
# from MousTrackingTest import MyDefineRoi
# from canny_avg import *
Green = (0, 255, 0)
Yellow = (0, 255, 255)
Blue = (255, 0, 0)
BlueGreen = (255, 255, 0)
Red = (0, 0, 255)
DarkRed = (0, 50, 180)
Blac... | [
"noreply@github.com"
] | kishorejsn.noreply@github.com |
c6ef67a918889ffda52983461233393b208d2851 | be37c53d458221d32d226a5e3fc3cbf4711819e4 | /api/models.py | bfc70996f94dad05c15b8ceb305671fba3ce8c11 | [
"MIT"
] | permissive | omegaorchid/EVE_api_old | 8bbd19145a291b2706419c951e65c49201429115 | ec4f1c83cb51c107e78e2559878531037e68b790 | refs/heads/master | 2021-06-13T02:33:56.772779 | 2017-02-09T18:16:10 | 2017-02-09T18:16:10 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 610 | py | from django.db import models
class Join(models.Model):
first_name = models.CharField(max_length=128, blank=True)
email = models.EmailField(max_length=128, unique=True, help_text="eg: 123@esp.ext")
ref_id = models.CharField(max_length=32, default="default", unique=True)
ip_address = models.GenericIPAdd... | [
"omegaorchid@gmail.com"
] | omegaorchid@gmail.com |
a03b3dde8cc57f05b2c21ac0c2d56dedbd8456f0 | 7c3a6339bcb221e6f9e6277248b2da3464569293 | /main.py | 703e237f0f204c691db893ed147a726591880987 | [] | no_license | Introduction-to-Programming-OSOWSKI/1-1-echo-Alexmidnightmiller2024 | 539e7fa2f4a50292c337846afecec6fedde0aff9 | c1c9fc6e13596b0e8ff0c4f3346674c8dabf57f5 | refs/heads/master | 2023-08-02T14:25:20.691088 | 2021-09-21T14:27:30 | 2021-09-21T14:27:30 | 408,478,295 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 60 | py | def echo(a,b):
return a*b
print(echo("yo", 8))
| [
"826784@mystma.org"
] | 826784@mystma.org |
07a6fa897cc722ed76ffe326de8f940d5b3d0e6e | 544086b3e4c580dbb39d1a8373a4903696d51db0 | /careforall/careforall/urls.py | 055beec5fc0b88a934ebb3a01b8dd4b8b89d99e0 | [] | no_license | careall249/Care-For-All | dc3a798fb47d10134f50d5a20b2b2eede52e623e | 0c74ba245e1758b10133cbfdc7345cdf4f4a8c5c | refs/heads/master | 2023-02-13T16:54:11.535341 | 2021-01-05T18:25:00 | 2021-01-05T18:25:00 | 316,262,763 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,113 | py | """careforall URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/3.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-ba... | [
"careal249@gmail.com"
] | careal249@gmail.com |
ff1e3577b40464dba3cd00a72f00e43fb9fbe2a8 | debf465c270c83d46f6f02daf81ef1f57fc9ec53 | /gtkbasket/wsgi.py | 37422d1df22399dc20fcd59d818901772781d210 | [] | no_license | MANOJGURUNG25/gtkbasket-master | e5918b642fd7bcebd2c1774fb81a5184770643b3 | 4d49e3a4539a14c4e99c58054e917df007c8c9d3 | refs/heads/master | 2022-06-01T03:36:58.013540 | 2020-05-05T08:30:04 | 2020-05-05T08:30:04 | 261,400,278 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 395 | py | """
WSGI config for gtkbasket 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/3.0/howto/deployment/wsgi/
"""
import os
from django.core.wsgi import get_wsgi_application
os.environ.setdefault('DJANGO_SET... | [
"47414036+MANOJGURUNG25@users.noreply.github.com"
] | 47414036+MANOJGURUNG25@users.noreply.github.com |
1371802502bdcec5314c8eeac5d4c4467ff4accd | deb1ef7385f13b6bcd2b9b052b348a079bba5516 | /Gaurav1/hack3.py | 705eed6c94692f90cafd2c971397f958cd9bad7b | [] | no_license | gauravkumarusit/test | 8426f97cf7859501f8e73cb4365cf45239b31c47 | 7c45fefcdfe1a4ef2247155702c0c720e6d4b4df | refs/heads/master | 2020-03-19T17:46:14.146630 | 2018-06-10T12:50:28 | 2018-06-10T12:50:28 | 136,776,687 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,009 | py | n=input("enter value of n \n")
eot=list()
m=list()
z=list()
comat=list()
lent=raw_input("enter length of %d salmons"%(n)).split()
sot=raw_input("enter time of %d salmon"%(n)).split()
lent = map(int, lent)
sot = map(int, sot)
print lent[0]
print lent[1]
print lent[2]
print sot
for i in range(0,n) :
... | [
"gauravkumar.usit@gmail.com"
] | gauravkumar.usit@gmail.com |
9c1be8f38214a7ef81656728eb586cf39be24807 | 6beb400670e95229e6a286ec9caf5b951ac25acc | /users/migrations/0039_auto_20210323_1226.py | eede0adc6e5e9d184c9da67284bd01c230ae6c38 | [] | no_license | AlphBeta/MiniProject | dc9d4bc3983787fb49a034b87262fa88577c2b1d | 0bf4383cebd453c4404c6c7a6007ad9ba9831f1f | refs/heads/master | 2023-04-09T17:42:44.005625 | 2021-04-16T16:35:20 | 2021-04-16T16:35:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,212 | py | # Generated by Django 2.2 on 2021-03-23 06:56
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('users', '0038_auto_20210323_1217'),
]
operations = [
migrations.AddField(
model_name='medinfo',
name='sex',
... | [
"antonybush95@gmail.com"
] | antonybush95@gmail.com |
0a736af76c3ce46abe0ba0398ba9cda27cdd1809 | a15586922c27ed9175a61d1f18de223311483618 | /pca reconstruction.py | f7b8ea2d50465e9cd45dfd4a1a68c4ea9420f2ad | [] | no_license | 11ayush11/Image-Processing-tool | 31393989fa52946cbf1660f61db674599e58b7a7 | b72dbfdfb709154394ef39d9ccca6c17d14a2280 | refs/heads/master | 2021-04-28T16:52:52.437154 | 2018-03-17T11:10:36 | 2018-03-17T11:10:36 | 121,842,806 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,386 | py | import scipy
import scipy.ndimage
import matplotlib.pyplot as plt
import numpy as np
from PIL import Image
# IMPORTING IMAGE USING SCIPY AND TAKING R,G,B COMPONENTS
a = scipy.ndimage.imread("C:/Users/DELL-pc/Desktop/ayush/c98b4234-48a8-11e7-93ee-bf101afa7e33.jpg")
a_np = np.array(a)
a_r = a_np[:,:,0]
a_g = a_np[:,:... | [
"noreply@github.com"
] | 11ayush11.noreply@github.com |
4765e2372a9c23e3e7efac558e378ceee6d3caef | bd12128da5e5d52151be22c3bc7fdaef7acd4b3b | /src/strategie/migrations/0004_auto_20210315_2154.py | 125fdbe3a941a8af26b295de9d522c2fe6e30dcf | [] | no_license | RBHSMA/TechTrader | a6ed9da0875a902fa26dc51eddc63955485e03e5 | 65465c5ceb6d95f9d333b3399ccd988034b475ba | refs/heads/main | 2023-04-14T21:12:02.970836 | 2021-03-30T23:27:04 | 2021-03-30T23:27:04 | 334,465,076 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 896 | py | # Generated by Django 3.1.6 on 2021-03-15 21:54
import django.core.validators
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('strategie', '0003_auto_20210223_1923'),
]
operations = [
migrations.RemoveField(
model_name='strat... | [
"1710317@stud.hs-mannheim.de"
] | 1710317@stud.hs-mannheim.de |
3f53f5573681c9ce0fc51b144d84850bc70bcfb1 | 7a87b2701dedeab6ad0c237feebdb3434d28231e | /ui_framework/page/index_page.py | 623efd36b370587149fe71e05467bb3cc8843856 | [] | no_license | tingyu-ui/test_dwpytest | 002a81f897b61c1e593d0f07f973b8380a725f9c | 4765ed74b64582453ddce6e318aa626049b133e8 | refs/heads/master | 2023-08-28T02:25:25.814423 | 2021-10-06T17:58:00 | 2021-10-06T17:59:02 | 375,302,284 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 655 | py | #!/usr/bin/env python
# -*- coding:utf-8 -*-
#雪球首页page
#可以直接继承basepage,调用已经封装好的UI操作
import yaml
from ui_framework.base_page import BasePage
class IndexPage(BasePage):
def goto_market(self):
#xpath等同于By.xpath
# self.find("xpath", "//*[@text='行情']").click()
# print(data)
#data格式 {'... | [
"you@example.com"
] | you@example.com |
213f0d85ace059f47ca513f3aa10e494654ff300 | cd927fa7ceb53d9008530577aff7f954a6f0fcb3 | /pre_processing/template_credit_data.py | 186fbe84151e4ce4265f20bce390482e3556b2bb | [] | no_license | brenomacedo/ML-and-DS | e5040c8e99337a166ba08b94ba71c55ba16259c0 | 2117bb56fedb80b0ede10ff07e14ed0c574d1cae | refs/heads/master | 2022-12-07T00:43:44.424032 | 2020-08-29T23:33:45 | 2020-08-29T23:33:45 | 275,128,165 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,126 | py | import pandas as pd
import numpy as np
base = pd.read_csv('credit_data.csv')
base.loc[base.age < 0, 'age'] = 40.92
previsores = base.iloc[:, 1:4].values
classe = base.iloc[:, 4].values
from sklearn.impute import SimpleImputer
imputer = SimpleImputer(missing_values = np.nan, strategy = 'mean')
imputer ... | [
"b88660501@gmail.com"
] | b88660501@gmail.com |
a5983f189787026b176806371a7c4b895764c0dd | bbf3d86b716feadbd40c96dd80e58b226ce60262 | /Zajecia6/test.py | ee7ebf16fc933e3b0d03000d90b5ec7e0b785db0 | [] | no_license | pstorozenko/YP2018-PythonPodstawy | 82baa2b49bf9682e690cf8e7010e9f8ad18e0845 | 12c0fa30a78be901fa69712f1b96d443bd2e6847 | refs/heads/master | 2020-04-04T12:39:59.943332 | 2019-01-28T00:37:13 | 2019-01-28T00:37:13 | 155,933,806 | 5 | 0 | null | null | null | null | UTF-8 | Python | false | false | 432 | py | class Pracownik:
def __init__(self, id, imie, nazwisko):
self.id = id
self.imie = imie
self.nazwisko = nazwisko
def __repr__(self):
s = "Pracownik " + str(self.id) + ": " + str(self.imie) + " " + str(self.nazwisko)
return s
l = []
l.append(Pracownik(1, "Jan", "... | [
"pitrosk@gmail.com"
] | pitrosk@gmail.com |
1a800a6c3b555fd8655951cb30da18dda8477a41 | a2e17c5cf56775bb02f55e1ade32e065af0e9f83 | /caluma/core/apps.py | 2550bb1b8c773ff5e379e8b7d9fee4b6acb223a3 | [
"MIT"
] | permissive | czosel/caluma | b671a4702344a55ebe0f57ec4c74735bb0e5a9e9 | 4a3e81b2000961ab934bfc1c6840ec00f0ba2c19 | refs/heads/master | 2022-03-16T08:37:46.662054 | 2019-01-22T11:43:20 | 2019-01-22T11:43:20 | 166,988,321 | 0 | 0 | MIT | 2019-01-22T12:13:05 | 2019-01-22T12:13:05 | null | UTF-8 | Python | false | false | 613 | py | from django.apps import AppConfig
from django.conf import settings
from django.utils.module_loading import import_string
class DefaultConfig(AppConfig):
name = "caluma.core"
def ready(self):
from .mutation import Mutation
from .types import Node
# to avoid recursive import error, loa... | [
"oliver.sauder@adfinis-sygroup.ch"
] | oliver.sauder@adfinis-sygroup.ch |
95bf26f4044777d86f65896e21463659f25d5c59 | 70b13a381a6c4b245feeb1227f2ef274fce8dec8 | /hw1/behavioural_cloning.py | 0ecb6b3f4d339bbe5e14a5dc4c8d300bb0b3bf6a | [
"MIT"
] | permissive | constant-c/homework | 9e2edd8abf400dd015bbe96ec7faf8871b801b65 | 07347f047d26b02fe560d63d910e115bd44a44bf | refs/heads/master | 2020-03-21T19:44:07.210212 | 2018-07-04T07:57:15 | 2018-07-04T07:57:15 | 138,966,843 | 0 | 0 | MIT | 2018-06-28T04:41:35 | 2018-06-28T04:41:35 | null | UTF-8 | Python | false | false | 4,956 | py | import os
import pickle
import gym
# os.chdir(os.path.join(os.path.abspath(os.path.curdir), "hw1/"))
import load_policy
import numpy as np
import tensorflow as tf
import tf_util
from keras import Sequential
from keras.layers import Dense
def generate_expert_data(expert_policy_file, env_name, max_timesteps=None, num_... | [
"cronrath@chalmers.se"
] | cronrath@chalmers.se |
7808b767d59251d668304489971025bb095ee8da | b207f16445f98cdf18ce4eb06ca8c1b292f7a096 | /mysite/urls.py | 149018110f85268095b7a27c3ed9a664fd15aeec | [] | no_license | Hugekyung/rest-board | 653adac144244eddab65edf9754061b1046df182 | 038fb71b8cccc91e828b29025b40a15d249bb41a | refs/heads/main | 2023-02-24T16:45:48.320337 | 2021-01-27T14:08:27 | 2021-01-27T14:08:27 | 331,324,674 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 801 | py | """mysite URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/3.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 ... | [
"kiki9510@gmail.com"
] | kiki9510@gmail.com |
3f50f46b762d28c768d543e4f72a69732b1ccaa3 | 7299134a93f0a5ed98873b316f74007d3af1a6c4 | /API/ML_model/views.py | baf2a66a2f0e85b13ef7399523aa43e9729fd5ad | [] | no_license | naqashgerard7897/unsw_data_analysis | 334d4904390aaf435fe2b9e54177e4945e9ade8a | 81a615ef81481372fe3d85feaa02c712eec213f3 | refs/heads/master | 2023-07-02T02:26:40.812604 | 2021-08-08T20:55:07 | 2021-08-08T20:55:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,010 | py | from django.shortcuts import render
from rest_framework.views import APIView
# Create your views here.
from . apps import MLModelConfig
from django.http import JsonResponse
import joblib
import pandas as pd
from . models import inputs
from rest_framework import serializers
# validate the input request
class validate... | [
"talha.yousuf@stech.ai"
] | talha.yousuf@stech.ai |
a696358764bbe718e42ec0818c28aaa4bdd7c151 | a4a2856c6082325bf5f314fb7a3f81d07dc061b9 | /venv/Lib/site-packages/otree/api.pyi | 46c481fbe19158587426e511bf84ed190ac95697 | [] | no_license | giuly090399/BEErtualLab | ea7e4bf8647d71677fdef8e600417df4f839ec6e | 7b0fa50cd090943b49159944074c0da6bbd8c6d7 | refs/heads/master | 2023-07-14T17:03:43.362152 | 2021-08-23T07:12:44 | 2021-08-23T07:12:44 | 398,954,714 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,930 | pyi | from typing import Union, List, Any, Optional, TypeVar, Type
from otree.currency import RealWorldCurrency, Currency
class Currency(Currency):
"""
PyCharm autocomplete seems to require that I explicitly define the class in this file
(if I import, it says the reference to Currency is not found)
"""
cu =... | [
"A01339472@itesm.mx"
] | A01339472@itesm.mx |
86a8652f184bd719381276eb60b29ef3b88a77f7 | e5bd7e733fbaf97532e47b6fd79ab2a1370a95c1 | /scripts/oops/constructor_class.py | dede6b098f9c40c945cef5afb414c51193b322b8 | [] | no_license | priyaydwtt/scripts | 3d3e95fee8eb797e3a785e66629a2e8499abe6eb | d81e1e5c974b18131daa890f939f7d60b00b22e0 | refs/heads/master | 2020-03-19T15:47:46.780282 | 2018-07-22T04:09:51 | 2018-07-22T04:09:51 | 136,686,247 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 848 | py | # OOPS Learnings
"""
1. simple class
"""
class Account_Details:
# default variable, accessable in all the function of this class
# constructor
# init - global intialization for this class
def __init__(self):
self.name = "csk"
self.age =27
# self is keyword to access
def perso... | [
"priya.s147@gmail.com"
] | priya.s147@gmail.com |
3fc70f03e9b4426bcce2c40963f3bd5138a648d3 | 67817340c5e06c0e66c3307c7f5b7f0c3c7bb658 | /235680/src/model/single/baseline.py | dd35654631d649c1b07525a0fd8efa4514f70615 | [] | no_license | parkjuida/dacon | 110f836dd407e5eb704ca6c412afc6a1eb7c5c9e | 5730871a7a89676d0ce95a784fbd287591e149b6 | refs/heads/master | 2023-03-25T21:23:25.033117 | 2021-03-14T12:27:20 | 2021-03-14T12:27:20 | 324,297,048 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 315 | py | import tensorflow as tf
class Baseline(tf.keras.Model):
def __init__(self, label_index=None):
super().__init__()
self.label_index = label_index
def call(self, inputs):
if self.label_index is None:
return inputs
result = inputs[:, :, self.label_index]
return result[:, :, tf.newaxis] | [
"bees1114@naver.com"
] | bees1114@naver.com |
d6b4388855a0884a32f7d4a5d924a2e063dda428 | 03e4e75a00044df181adbebf5f44b5076d97a15f | /example/0_Basic_usage_of_the_library/python_motor/3_delete.py | 944d7f2e83b32bde74bae3324bcb045b7ab6c39c | [
"MIT"
] | permissive | RecluseXU/learning_spider | 3820b15654bb5824b1f92c53389d24799ff2bb88 | 43831e2fbbd5de0cf729ce8c12c84d043b56e855 | refs/heads/master | 2023-06-08T09:36:26.307395 | 2023-05-19T02:48:08 | 2023-05-19T02:48:08 | 234,718,806 | 64 | 14 | null | 2020-01-20T11:54:29 | 2020-01-18T10:38:06 | null | UTF-8 | Python | false | false | 820 | py | # -*- encoding: utf-8 -*-
'''
@Time : 2021-06-09
@Author : EvilRecluse
@Contact : https://github.com/RecluseXU
@Desc : 删除
'''
# here put the import lib
from motor.motor_asyncio import AsyncIOMotorClient
import asyncio
async def do_delete(client: AsyncIOMotorClient):
""" 删除一条记录
"""
collecti... | [
"444640050@qq.com"
] | 444640050@qq.com |
5e77a95372dbe4d4b2dcabbf8704c9263a3e44fb | df48df0621ec77578561cab7a5b624b0d1be80bf | /bk1051/adventure/game.py | 9f0d387811af246feb47ddce49abc909c46e5aaa | [] | no_license | Y0000Y/assignment5 | ed0cf64f68ae8c5ffbf1a57cd6887008a525161a | 0f627fcff8d7da8291b032ed00f9740c151a5a49 | refs/heads/master | 2021-05-31T05:00:47.313505 | 2015-12-13T01:43:26 | 2015-12-13T01:43:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 60,682 | py | """How we keep track of the state of the game."""
# Numeric comments scattered through this file refer to FORTRAN line
# numbers, for those comparing this file and `advent.for`; so "#2012"
# refers to FORTRAN line number 2012 (which you can find easily in the
# FORTRAN using Emacs with an interactive search for newlin... | [
"bk1051@nyu.edu"
] | bk1051@nyu.edu |
78d111077b4b2c6d31fe8b876e9a79fbc0c21856 | 64bdbfdfa014020d7bd4f13c05cc837eff5258f8 | /Quiz3.py | bbc3cdfa184ff12f890532265dd13b9d847a93a9 | [] | no_license | kipfletcher/Quiz3 | 719b54a16142c972d940ad95c29e2128aec80c1f | d08140318bdfadd429ba48a3c014463e80acdc98 | refs/heads/master | 2020-03-21T06:23:35.078419 | 2018-06-22T21:12:37 | 2018-06-22T21:12:37 | 138,216,451 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,868 | py | # Kip Fletcher Math 4330 6/18/2018
# Quiz 3
# dot returns the dot product of two vectors.
def dot(vector01, vector02):
'''
This function takes two compatible vectors as its arguments and returns
their dot product. It first uses an if-else statement to verify that both
vectors are vectors. It utiliz... | [
"noreply@github.com"
] | kipfletcher.noreply@github.com |
80699938953a724bf730aa4721fcb66da36d6e0d | 25c4b837fb0f4a25c6271150208560f058500740 | /simplesocial/accounts/forms.py | 95d221786099871670eff9a55105a40a81857d40 | [] | no_license | KalashMaskey/social-clone-project | 1dac99d1a888e7f63a62e6c2ec8139d032e354af | 6dd899c3609adb93b390c6d0437521c7dac11c4a | refs/heads/master | 2022-08-14T09:13:08.512686 | 2020-05-15T05:48:41 | 2020-05-15T05:48:41 | 264,107,355 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 561 | py | from django.contrib.auth import get_user_model
from django.contrib.auth.forms import UserCreationForm
class UserCreateForm(UserCreationForm):
class Meta:
fields = ('username','email','password1','password2')
model = get_user_model()
def __init__(self,*args,**kwargs):
super().__init__... | [
"kalashm24@gmail.com"
] | kalashm24@gmail.com |
cc6235a3bc1a7e6fbd38b073bc939afc294370fa | 946818722ecdd086f3d829f95c3b7d3b390f0a34 | /lambda/lambda_function.py | 12a385f59295a8fa51c68ba1ad05804968c62f98 | [] | no_license | anjanragh/sagemakerdemo | 0b844cb9abe81dd132058cb773094d48a3a7da38 | 70a005d7a55421e0c05ae460652973c8689c9ddb | refs/heads/master | 2022-07-28T16:01:43.710400 | 2020-05-15T03:58:47 | 2020-05-15T03:58:47 | 264,084,108 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,902 | py | import json
import os
import boto3
import email
import re
from botocore.exceptions import ClientError
from email.parser import BytesParser
from email import policy
from sms_spam_classifier_utilities import one_hot_encode
from sms_spam_classifier_utilities import vectorize_sequences
vocabulary_length = 9013
def quer... | [
"anjanragh@gmail.com"
] | anjanragh@gmail.com |
2b8c7cbbaa838cdb8cb0871185611fb9237ec0d2 | 91ee3afd21767341b1af1c7945c1ac44d357b925 | /2.py | 7a6d7df49a29cd90d5836fa1ac1e640154e150ad | [] | no_license | alexryndin/algrorithms_and_data_structures_stepik | 5e1e3c18f3c746c862a0285f83d77812c3160b7f | abf157c998ba16eb4e897c807d9302530ea70f93 | refs/heads/master | 2022-06-16T18:50:24.944252 | 2020-05-11T19:04:58 | 2020-05-11T19:04:58 | 262,311,948 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 650 | py | #!/bin/python
def depth(tree, root):
q = tree[root]
q_tmp = []
d = 0
while q:
d+=1
while q:
n = q.pop()
if n in tree:
q_tmp.extend(tree[n])
q, q_tmp = q_tmp, q
return d+1
def main():
n = int(input())
tree = list(map(int, i... | [
"alexnryndin@gmail.com"
] | alexnryndin@gmail.com |
ca371895a38d5b2128545dcb4c8090e865160163 | d4c9b12f6b74858322bfac82886fef684fa58e3a | /DjangoDemo/blog/models.py | 0e6db3f89b8bcc515caf6639922cd544f7469f08 | [] | no_license | zai-jian/django_test | 3b19af34ef49a23fd47199131a204ca3f0004008 | dbf3a5e61c887c535186eb1a56e792cb9032a66a | refs/heads/master | 2022-12-13T19:15:49.116149 | 2019-11-04T12:06:23 | 2019-11-04T12:06:23 | 214,969,498 | 0 | 0 | null | 2022-12-04T18:48:23 | 2019-10-14T06:54:10 | CSS | UTF-8 | Python | false | false | 2,415 | py | from django.contrib.auth.models import User
from django.db import models
class Category(models.Model):
STATUS_NORMAL = 1
STATUS_DELETE = 0
STATUS_ITEMS = (
(STATUS_NORMAL, '正常'),
(STATUS_DELETE, '删除'),
)
name = models.CharField(max_length=50, verbose_name='名称')
status = models.... | [
"zaijianwzj@163.com"
] | zaijianwzj@163.com |
ff4fcc7c10a1508f589576a41d36785af57f322b | 5d4302420957012c3e48290957255a3981f7bffd | /misc/python/cap_problem.py | 33b17f95d4eb83b68adf3b9654db0cce94bc24fa | [] | no_license | fluffycat/Notes | 43affe8c254eeb83dd278e38fd6916546869d275 | 6db648a5d8881db5abc82601bddbc99030508dcc | refs/heads/master | 2020-12-11T07:46:23.107851 | 2014-01-23T13:03:43 | 2014-01-23T13:03:43 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 190 | py | #coding=utf-8
def cal(m):
return sum([(1.0*m)/(m-i) for i in range(0,m)])
s = 0.0
x = 0.1
for i in range(1,10000):
s += i*((1-x)**(i-1))*x
print s
for i in range(20):
print i,cal(i) | [
"darrenhp@gmail.com"
] | darrenhp@gmail.com |
dff0844843348d6cea53872404ce8867c500790d | bd755c98543160ab6bbd932c8f3b4a56356a9609 | /src/Python/pyDotNet/src/pydotnet/clr/data/CLRFloat64Array.py | 572434f17e7f8d3eedf823066bfc098fee441901 | [
"Apache-2.0"
] | permissive | jar1karp/.Net-Bridge | aa89fdd90149c36410d163ff93b7f5aec6d0ab9b | dabbd95ab564e2546fbd87732dcf72ea2418f84c | refs/heads/master | 2021-01-21T09:14:40.074332 | 2017-08-30T19:59:53 | 2017-08-30T19:59:53 | 101,968,004 | 0 | 0 | null | 2017-08-31T06:37:05 | 2017-08-31T06:37:05 | null | UTF-8 | Python | false | false | 1,394 | py | #
# General:
# This file is pary of .NET Bridge
#
# Copyright:
# 2010 Jonathan Shore
# 2017 Jonathan Shore and Contributors
#
# License:
# 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 c... | [
"jonathan.shore@gmail.com"
] | jonathan.shore@gmail.com |
11f67c0308b87d360a68ff26de26d4697538d0de | 0b842bcb3bf20e1ce628d39bf7e11abd7699baf9 | /sql/register_sql.py | 9fac3d26fe0e079d1338a20b332cb6855862c0c9 | [] | no_license | afeset/miner2-tools | 75cc8cdee06222e0d81e39a34f621399e1ceadee | 81bcc74fe7c0ca036ec483f634d7be0bab19a6d0 | refs/heads/master | 2016-09-05T12:50:58.228698 | 2013-08-27T21:09:56 | 2013-08-27T21:09:56 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 279 | py | '''
Created on Aug 14, 2013
@author: asaf
'''
import sys
sys.path.append("/home/asaf/miner2.0")
import miner_globals
sys.path.append("/home/asaf/miner2-tools")
from sql import sql_target
miner_globals.addTargetToClassMapping("sql",None,"sql_target.sqlDump","Write To SQL DB")
| [
"afeset@gmail.com"
] | afeset@gmail.com |
841815712a69ec53210e65b2409387ca65d4c2ba | 50a00c194afddf2298504605f8a3dc1e1f854721 | /sqlparse1/engine/grouping.py | e4f0cbf794843a12f84c397700779cc511b450d1 | [] | no_license | CudaText-addons/cuda_fmt_sql_uroboro | ee57f8d600f4f838458519eb6a89a0690b6687c7 | bbebcfee9ecfe3c317f62a1c8259b58f1da5b9c2 | refs/heads/master | 2020-06-18T21:38:40.678645 | 2019-07-11T21:25:46 | 2019-07-11T21:25:46 | 196,459,066 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 18,236 | py | # -*- coding: utf-8 -*-
import itertools
from sqlparse1 import sql
from sqlparse1 import tokens as T
import sys
try:
next
except NameError: # Python < 2.6
next = lambda i: i.__next__()
def _group_left_right(tlist, ttype, value, cls,
check_right=lambda t: True,
c... | [
"support@uvviewsoft.com"
] | support@uvviewsoft.com |
ed96719717fd7ac441f1be6e923d772a205c721f | 71f1b0bf1bd4db06e824aa581f0a8ac66ec64600 | /lecture10/commlib.py | dc894e287bf9195167c8cfb83261323900156687 | [
"MIT"
] | permissive | thomaskamalakis/telecomsystems | 5b36a08f4db0d3856eecbd816f6c5bcfc5de27f7 | 08eb8db7102a43894b539d5f95d917bf09ed109e | refs/heads/master | 2023-01-23T20:31:15.281260 | 2023-01-18T09:45:21 | 2023-01-18T09:45:21 | 214,350,536 | 4 | 11 | null | 2019-10-11T05:31:02 | 2019-10-11T05:27:18 | null | UTF-8 | Python | false | false | 26,301 | py | import numpy as np
import matplotlib.pyplot as plt
from copy import deepcopy
from scipy.special import erfc
DEFAULT_PLOT_SETTINGS = {
'plot_type' : '-',
'xlabelt' : 't',
'ylabelt' : 'x(t)',
'xlabelf' : 'f',
'ylabelf' : 'X(f)',
'xlimt' : None,
'ylimt' : None,
'xlimf' : None,
'... | [
"thkam@hua.gr"
] | thkam@hua.gr |
0e9a79e66d3489ffeeff1e43b6ee8976830f9f07 | ccf08d85b8362044c59246b285b75167cd5d91ba | /tiktok.shortest2.py | bd86cb46c3f597e92232729bac9be6049e06896a | [] | no_license | SofiiaK22/tictactoeSK22 | d59bf76c0b46150e423d19e1899979ccdc7c5286 | 11b88c3a0939e933f27b71b4a5a7af4b81a12657 | refs/heads/master | 2021-01-07T10:02:21.260834 | 2020-02-17T10:40:01 | 2020-02-17T10:40:01 | 241,657,518 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,408 | py | dictionary = {'x': [], 'o': []}
a = dictionary['x']
b = dictionary['o']
k = 0
comb = [[0, 1, 2],[0, 4, 8],[0, 3, 6],[1, 4, 7],[2, 4, 6],[2, 5, 8],[3, 4, 5],[6, 7, 8]]
def wonlost():
for m in dictionary:
s = dictionary[m]
for f in comb:
if f[0] in s and f[1] in s and f[2] in s:
... | [
"Sofiia.kozoriz22@gmail.com"
] | Sofiia.kozoriz22@gmail.com |
ae442edb83bc59a0a8a48043445817b22e5c8dad | 72c65ab014d5589eeb034568f855ac159fc552aa | /tests/client.py | c75ea5ee5e5c55d2834b7317cac296433eba8334 | [
"MIT"
] | permissive | bixuehujin/dockerman | 9f5dd2c71a00ccd3ebb5021ec7150d0e0ba7bdf2 | fe94021297d6ee5eb837a1fd05a2cf02e39c7653 | refs/heads/master | 2016-09-10T20:26:53.610129 | 2015-01-07T17:33:49 | 2015-01-07T17:33:49 | 28,772,057 | 5 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,132 | py | __author__ = 'hujin'
import time
from dockerman.docker import Client
from twisted.internet import reactor
client = Client('127.0.0.1', 4243)
d = client.create_container('bixuehujin/blink-db-server:1.0.0', name='test')
def inspect_container(response):
print(response)
print("container created\n")
dd =... | [
"bixuehujin@gmail.com"
] | bixuehujin@gmail.com |
92b90393445cf2665ca28a844bbe3257e14aa609 | 1e5b7d65b7163cfa4be939a632206b00df98487d | /models/fundamental_diagrams/fundamental_diagram_definitions.py | 01607a415cb95e7776c2b69d7a3d16a0e42dcd50 | [] | no_license | YannisZa/probabilistic_traffic_flow_modelling | 04f2c16f39507f3e142157c16fb5ab4a2be97e86 | 44fd58501f2946e7b835264607d30e1891bf9626 | refs/heads/main | 2023-08-05T11:48:27.492559 | 2021-09-15T15:19:57 | 2021-09-15T15:19:57 | 339,135,948 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 14,283 | py | import numpy as np
from fundamental_diagrams import FundamentalDiagram
class ExponentialFD(FundamentalDiagram):
pass
def __init__(self,data_id):
super().__init__(data_id)
FundamentalDiagram.name.fset(self, 'exponential')
FundamentalDiagram.num_learning_parameters.fset(self, 3)
... | [
"yzachos@gmail.com"
] | yzachos@gmail.com |
2ae95574f310aa8df7b035537d7208bc72e1225f | 5e381364c2ab31ff3618369085afffba6caa8edb | /recipes/squirrel/all/test_package/conanfile.py | 5789855d52cb28e63a00eaa87670af8ce596836e | [
"MIT"
] | permissive | CAMOBAP/conan-center-index | 16aea68a6d22da22831ba985773125e8eda08f00 | 67d57532bdad549fef3fa6cb8fcdfa86bc55e4f1 | refs/heads/master | 2023-07-30T08:58:57.285571 | 2021-10-02T14:57:54 | 2021-10-02T14:57:54 | 323,262,699 | 1 | 0 | MIT | 2021-05-29T13:37:04 | 2020-12-21T07:30:02 | Python | UTF-8 | Python | false | false | 559 | py | from conans import ConanFile, CMake, tools
import os
class TestPackageConan(ConanFile):
settings = "os", "compiler", "build_type", "arch"
generators = "cmake", "cmake_find_package_multi"
def build(self):
cmake = CMake(self)
cmake.definitions["SQUIRREL_SHARED"] = self.options["squirrel"].s... | [
"noreply@github.com"
] | CAMOBAP.noreply@github.com |
5cc0691f2e7969455fd5bb8879f0ac67e68f528b | dc81baa3bd5ca2a4b5ba7c1bb6246358e4f5d4ed | /0x06-python-classes/2-square.py | 01498b74dec0c0ca76828e93c7740798fb1d92cc | [] | no_license | MarcosPimienta/holbertonschool-higher_level_programming | cd902349291f1320a3d627369e5f7f540b27e058 | 44528514d9764685ef747ec95407e250493edbc8 | refs/heads/master | 2023-03-03T18:44:53.125118 | 2021-02-12T04:05:50 | 2021-02-12T04:05:50 | 291,888,773 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 332 | py | #!/usr/bin/python3
"""Square class with private size"""
class Square:
"""Square class with private size"""
def __init__(self, size=0):
self.__size = size
if not type(size) is int:
raise TypeError("size must be an integer")
if size < 0:
raise ValueError("size mus... | [
"1676@holbertonschool.com"
] | 1676@holbertonschool.com |
ba5b46a31f4fb683772f0bbe00da6ac8986514ce | b03878679b1e07e0ec962083dd4d058d1503180f | /pyoxford/translator_api.py | 50ec01c31e66fc1aef9305b12d2977aaffa05fc1 | [
"MIT"
] | permissive | jhoelzl/pyoxford | d3a8abfb822706fbba17792e8519ac3d2d05e36d | 9e3f2e0130951e0ccb3c3f7fd8798219e1c36ee2 | refs/heads/master | 2020-12-28T12:07:27.963018 | 2015-11-28T14:33:44 | 2015-11-28T14:33:44 | 58,353,003 | 0 | 0 | null | 2016-05-09T06:17:24 | 2016-05-09T06:17:23 | null | UTF-8 | Python | false | false | 2,222 | py | import urllib.parse
from xml.etree import ElementTree
import requests
class Translator(object):
AUTH_URL = "https://datamarket.accesscontrol.windows.net/v2/OAuth2-13"
API_ROOT = "http://api.microsofttranslator.com/v2/Http.svc"
TRANSLATE_URL = "http://api.microsofttranslator.com/v2/Http.svc/Translates"
... | [
"icoxfog417@yahoo.co.jp"
] | icoxfog417@yahoo.co.jp |
279fdd848d5ad7ecd4ae09134425e0328924f9ba | 40d95c36ff59271caf8282aa644a9505cd4c310f | /Regression/mlp.py | a78652206a2ef111da13bc1b7dd37471d19b5a39 | [] | no_license | hockey-for-NOI/NeuronNetworkFinalProject | 95d8ddfc2352d13f24a8cdf3fe2f5154dfc8b58c | d92f22d3526e43c6ec438410e9336023e9ca689e | refs/heads/master | 2021-09-04T17:32:45.967749 | 2018-01-19T17:46:46 | 2018-01-19T17:46:46 | 111,172,918 | 0 | 0 | null | 2017-12-02T02:48:34 | 2017-11-18T03:23:30 | TeX | UTF-8 | Python | false | false | 2,325 | py | import numpy as np
import tensorflow as tf
import csv
import random
DATA_FILE_NAME = 't_price_cut.csv'
LABEL_FILE_NAME = 't_label.csv'
data = []
label = []
data_reader = csv.reader(open(DATA_FILE_NAME))
label_reader = csv.reader(open(LABEL_FILE_NAME))
for row in data_reader:
data.append(row)
for row in label_read... | [
"809642754@qq.com"
] | 809642754@qq.com |
cc5fa549674d5f7f51c7555601bb75a5d2f426f5 | 9b0bdebe81e558d3851609687e4ccd70ad026c7f | /数据结构/链表/10.链表相交.py | f407d7d61aadf869f8133d2993fdec96d025f9a8 | [] | no_license | lizenghui1121/DS_algorithms | 645cdad007ccbbfa82cc5ca9e3fc7f543644ab21 | 9690efcfe70663670691de02962fb534161bfc8d | refs/heads/master | 2022-12-13T22:45:23.108838 | 2020-09-07T13:40:17 | 2020-09-07T13:40:17 | 275,062,257 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 977 | py | """
@Author: Li Zenghui
@Date: 2020-07-17 14:47
"""
class ListNode:
def __init__(self, val):
self.val = val
self.next = None
def getIntersectionNode(headA, headB):
def getLength(head):
count = 0
while head:
count += 1
head = head.next
return ... | [
"954267393@qq.com"
] | 954267393@qq.com |
d665df43152a171e231c0793371cf072aca4f3a1 | 31bd9276e74446a05cb41644dc8baf55d8662f93 | /xnr_0429/xnr/weibo_xnr_knowledge_base_management/utils.py | f3093366cccee8bd07fb22b3e81de8f8d384c4a2 | [] | no_license | SDsonghuiui/xnr2 | 4938a73adcafdc5881a81ffc9eaa93b08fb770e3 | 30d1d41566c58ee7925da6c2c6d741e229cda852 | refs/heads/master | 2020-04-06T08:25:42.176438 | 2018-11-12T14:10:32 | 2018-11-12T14:10:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 41,301 | py | #!/usr/bin/python
#-*- coding:utf-8 -*-
import time
import json
import pinyin
import numpy as np
from xnr.global_config import S_TYPE,S_DATE
from xnr.global_utils import es_xnr as es
from xnr.global_utils import es_user_portrait,es_user_profile,es_flow_text,flow_text_index_name_pre,flow_text_index_type
from xn... | [
"bingqulee@gmail.com"
] | bingqulee@gmail.com |
95036f88c5a8088641777f174f9a7371d400967c | 4171d2423e04e57ae6d51ffcf159d292de08854d | /5.Django/first_project/first_app/migrations/0001_initial.py | e5dd6bcaf39a72c65559699b874d925fc4c0de88 | [] | no_license | harshit-jaiswal/Python-and-Django-fullstack | db21ebca835b7b9e1be426c5b625abe0015551ca | 2e8ccea734a9013a4ac979a182f5323c053d9052 | refs/heads/master | 2022-07-30T10:46:35.121499 | 2020-05-23T10:26:31 | 2020-05-23T10:26:31 | 260,271,509 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,385 | py | # Generated by Django 3.0.6 on 2020-05-08 16:26
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Topic',
fields=[
... | [
"Hjaiswal02@gmail.com"
] | Hjaiswal02@gmail.com |
93751656fda3d971cc190873ece55248d3a8d757 | 58a87e847f8c6cd5b83cbe5758e779679563cc66 | /Exercícios complementares/ExercícioG.py | cceba6383e0aa814ccbfd132a91df968d153333a | [] | no_license | suzanamfp/Atividades-complementares-Python | 9444dec6cd952db3cdeaf26648f0eb60a89a0862 | d1a04f3f4d70298aa8448a37ba3e4b5313ced472 | refs/heads/master | 2022-12-02T21:23:55.261903 | 2020-08-18T19:28:34 | 2020-08-18T19:28:34 | 288,545,350 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 129 | py | def main():
cores = ['azul', 'vermelho', 'cinza', 'amarelo']
cores.remove('vermelho')
print(cores)
main() | [
"noreply@github.com"
] | suzanamfp.noreply@github.com |
23b3665560b2105af94061d1dfb27c99ee78e8e3 | 709c35fded3567512c1eec3bb7facb63e4891903 | /mark2cure/task/ner/models.py | 5c8d298d572b68cf492693848e88e40401c9c0fc | [
"MIT"
] | permissive | SuLab/mark2cure | da8ddca9d35cc10116417451d8a4caea29f279c5 | 63d20e75b8817ad75c6766b4d8a7a8ee8207d512 | refs/heads/master | 2023-02-04T08:51:22.372167 | 2018-02-28T02:50:25 | 2018-02-28T02:50:25 | 54,926,527 | 17 | 14 | null | 2023-01-11T22:31:16 | 2016-03-28T21:58:29 | Python | UTF-8 | Python | false | false | 790 | py | from django.db import models
from .managers import EntityRecognitionAnnotationManager
from django.forms.models import model_to_dict
class EntityRecognitionAnnotation(models.Model):
# Only access through Document.Annotation.metadata.RelationAnnotation
DISEASE = 0
GENE = 1
TREATMENT = 2
TYPE_CHOICES... | [
"max@maxnanis.com"
] | max@maxnanis.com |
b7559dc7812e5200464d1e7279d70aedf5f87fb3 | d73b14bd20cfc1320e1911247b28c5109c51b5d1 | /training/train_openpose.py | 75a4569e1b897416ebc493dee676ee8e17f683fe | [] | no_license | rainyucool/openpose-pytorch | 9c7e32bdab53417fef30d81a2dc53019dc3dbd84 | 4bc9cf4c927fdb507d89198724a237800cad9b3e | refs/heads/master | 2020-04-01T13:25:04.702843 | 2018-05-07T13:12:11 | 2018-05-07T13:12:11 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,292 | py | import torch
from torch.utils.data import DataLoader
from config import cfg
from datasets.coco_dataset import CocoDataset
from models import model_openpose
from skeletons.gt_generators.gt_generator_openpose import GroundTruthGeneratorOpenPose
from skeletons.skeleton_config_openpose import SkeletonConfigOpenPose
from t... | [
"Dennis.Ludl@reutlingen-university.de"
] | Dennis.Ludl@reutlingen-university.de |
1a6e7eb51c70cb8fd43657c64d233264aef82988 | d70a4ec35ac91c914c42611e8b0ee05525371f7a | /src/lwc/settings_old.py | 392a0df76f497a6832088dac3f360cb7bffbefc8 | [] | no_license | jwilsontt/lwc | b662de74e47f350a732cc5e1e52a80bd4da46524 | 975a45aab16019f03880dafcd1b1ee7931613613 | refs/heads/master | 2021-01-21T07:53:44.348760 | 2015-08-21T04:05:36 | 2015-08-21T04:05:36 | 33,587,522 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,454 | py | """
Django settings for lwc project.
For more information on this file, see
https://docs.djangoproject.com/en/1.6/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.6/ref/settings/
"""
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
import... | [
"jwilsontt@gmail.com"
] | jwilsontt@gmail.com |
4b6f8df3be6b4381ec458f9097531d47618b8bd9 | 73054d4c78ed06e43460d098af5840ed9d5c2ae1 | /numpy/deepgp_approxep/__init__.py | 7d07b4506d005cb79479857e990f03c896c3d019 | [
"MIT"
] | permissive | 2476F/deepGP_approxEP | 856ba0f70047eecaafba647f887e3db6dc9c546a | c540225094ef44fecd66bdd58efe4d9d21f60d8b | refs/heads/master | 2023-04-20T13:20:08.346829 | 2021-05-25T14:12:15 | 2021-05-25T14:12:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 58 | py | from . import AEPDGP_net, AEPDGP, EQ_kernel, FITC_network
| [
"dks28@cam.ac.uk"
] | dks28@cam.ac.uk |
bb98b8c8376205d9e19f6311a891a0930cfba762 | bb7823efe85b6afc2e3f6cf97e0b25ce9a8cf2df | /slackbot_settings.py | fc78415ec3f09982796c10d0d49aa19ed78fde8d | [] | no_license | nagi-lc3/slackbot | 0ac95b4521c34a882f0eaf7db7c04d3a50ba2030 | 36b828fb674ccf2e57c2222f7cf2ee86f130f3a2 | refs/heads/master | 2022-11-11T22:59:11.252473 | 2020-06-29T11:03:06 | 2020-06-29T11:03:06 | 275,787,175 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 339 | py | import os
from dotenv import load_dotenv
load_dotenv()
# API TOKEN
API_TOKEN = os.environ['API_TOKEN']
# 対応するメッセージがなかった場合に反応するメッセージ
DEFAULT_REPLY = "I dont't understand you."
# Botが実行するスクリプトを配置するディレクトリパスのリスト
PLUGINS = ['plugins']
| [
"ymxlinkinparkxlc@gmail.com"
] | ymxlinkinparkxlc@gmail.com |
46ab94c8a8e2a2f0c3ac17d32ed98651ad8589fb | 0849923ebcde8f56a6e8550ae4f3c5ee3e2e0846 | /desktop/core/ext-py/MySQL-python-1.2.3c1/setup_posix.py | 5895984e6cb9da83ebb46ef3be36f4b55e2e0b0d | [
"GPL-2.0-only",
"GPL-1.0-or-later",
"Apache-2.0"
] | permissive | thinker0/hue | 511a5796cdfe45e0b27f1d3309557ca60ce8b13b | ee5aecc3db442e962584d3151c0f2eab397d6707 | refs/heads/master | 2022-07-10T02:37:23.591348 | 2014-03-27T20:05:00 | 2014-03-27T20:05:00 | 12,731,435 | 0 | 0 | Apache-2.0 | 2022-07-01T17:44:37 | 2013-09-10T14:13:42 | Python | UTF-8 | Python | false | false | 2,947 | py | from ConfigParser import SafeConfigParser
# This dequote() business is required for some older versions
# of mysql_config
def dequote(s):
if s[0] in "\"'" and s[0] == s[-1]:
s = s[1:-1]
return s
def compiler_flag(f):
return "-%s" % f
def mysql_config(what):
from os import popen
f = pope... | [
"bcwalrus@cloudera.com"
] | bcwalrus@cloudera.com |
3e00a977c51f8050c62863cc8bf3f8aea1eee6fb | cb9b35568ff470df6b210558750f4f43319587b6 | /game_logo_scene.py | 2c1462ff4ca987a4fc10eddf82169b49ab0b2ee6 | [] | no_license | MotherTeresaHS/ICS3U-2016-Group7 | cdc73f90bd2ab33e81e74ba1779d84c949293bde | 659589c03478cd460c681a5b2d427589e0d58843 | refs/heads/master | 2020-06-26T02:04:22.523455 | 2017-01-21T03:59:06 | 2017-01-21T03:59:06 | 74,606,228 | 0 | 1 | null | 2017-01-21T03:59:07 | 2016-11-23T19:08:12 | Python | UTF-8 | Python | false | false | 2,594 | py | # Created by: Mr.Coxall
#Modified by: Sheldon H.
# Created on: Sep 2016
# Created for: ICS3U
# This scene shows a game logo screen for 2 seconds,
# then transitions to the main menu.
from scene import *
import ui
import time
from main_menu_scene import *
class GameLogoScene(Scene):
def setup(self):
# ... | [
"noreply@github.com"
] | MotherTeresaHS.noreply@github.com |
1d82d008ec888f22b422e2485f067fc9d1106e52 | cda54a77875d95fb0a60f3655263b2e3d68984bf | /prorgam26_class.py | 237a670f8cac202b293eff45c51c2b58a49a6df1 | [] | no_license | bilashProshad/Python-code | 87ef96d62bc262648427980b357e1cb7de56194d | 4d84238f3c57d6877d23629fd10c9d0bee6fb35e | refs/heads/master | 2023-05-04T10:54:48.481436 | 2021-05-26T19:50:36 | 2021-05-26T19:50:36 | 371,153,034 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 325 | py | class Student:
def __init__(self, roll, name, gpa):
self.roll = roll
self.name = name
self.gpa = gpa
def display(self):
print(f"Roll: {self.roll}, Name: {self.name}, GPA: {self.gpa}")
student1 = Student(101, "John", 3.75)
student1.display()
print(isinstance(student1, Student)... | [
"pbilash64@gmail.com"
] | pbilash64@gmail.com |
1b4da8a1f594f8fb6b066d22090a1dc4f03c05cf | 18488a8d9f06c3dd092089f015c32202ef118b24 | /tennis_ball_death_arena_scoring.py | dfd809caaeb8fd10d8f8e0af60a44a3265ec2071 | [] | no_license | Maxwell-Banks/TBDA-Scoring-System | b3191771f33971643f090b4f4cdd5c0bbde236b5 | 38d26b94484cf279309e9cc59f287ee642c2fdb5 | refs/heads/main | 2023-03-15T22:11:15.864372 | 2021-03-04T02:11:40 | 2021-03-04T02:11:40 | 344,306,549 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,685 | py | """By Maxwell M. Banks
Wednesday 6/19/19
Scoring system for the game "Tennis Ball Death Arena"
"""
import sys
import os
import math
class Player:
"""A class that holds the player's name and throws for the
game
Attributes:
name(str): The name of the player holding the class
throws(li... | [
"maxwellmbanks@gmail.com"
] | maxwellmbanks@gmail.com |
ecfb81ea993353444f0d49cd8cc8cd399d6b883b | a036ec1009168e0632e247525244db359359df2c | /I0320097_exercise6.13.py | 1626fc865f4fdeb42ba6f7ec127acbcf8abb816a | [] | no_license | alqodriano/syahrifai-al-qodriano_I0320097_aditya-mahendra_tugas6 | c6233b1c3407054fafff4d64f7e448414da18ec2 | b42ae03578f5980a23d600d83346fa9e0d139a87 | refs/heads/main | 2023-04-13T16:39:07.315355 | 2021-04-09T18:19:45 | 2021-04-09T18:19:45 | 355,499,529 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 213 | py | #exercise6.13
def tambah(a, b):
c = a + b
return c
x = int(input("masukkan bilangan ke 1: "))
y = int(input("masukkan bilangan ke 2: "))
hasil = tambah(x,y)
print("%d + %d = %d" % (x, y, hasil))
| [
"noreply@github.com"
] | alqodriano.noreply@github.com |
8876284a7a38ed4b8daedc0a42e8722bf52cf232 | d3efc82dfa61fb82e47c82d52c838b38b076084c | /Autocase_Result/AbnormalRecovery-bak/bak/XOGW_RESTART_PGJK_IPO.py | 4445242cb1451a5c0c23ad77987bf2e8101fe124 | [] | no_license | nantongzyg/xtp_test | 58ce9f328f62a3ea5904e6ed907a169ef2df9258 | ca9ab5cee03d7a2f457a95fb0f4762013caa5f9f | refs/heads/master | 2022-11-30T08:57:45.345460 | 2020-07-30T01:43:30 | 2020-07-30T01:43:30 | 280,388,441 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,296 | py | #!/usr/bin/python
# -*- encoding: utf-8 -*-
import sys
sys.path.append("/home/yhl2/workspace/xtp_test")
from Autocase_Result.AbnormalRecovery.ARservice.ARmainservice import *
from utils.env_restart import *
from service.ServiceConfig import *
from xtp.api.xtp_test_case import *
from xtp.api.config import ALL_USER
# 执... | [
"418033945@qq.com"
] | 418033945@qq.com |
315aad6b034c11627f71ff2689bea84cf59bba2b | 4a48593a04284ef997f377abee8db61d6332c322 | /python/pyqt/pyqt5/widget_QTableWidget.py | ac6b9f412cde6986dc866f49d1e4a4e191922386 | [
"MIT"
] | permissive | jeremiedecock/snippets | 8feaed5a8d873d67932ef798e16cb6d2c47609f0 | b90a444041c42d176d096fed14852d20d19adaa7 | refs/heads/master | 2023-08-31T04:28:09.302968 | 2023-08-21T07:22:38 | 2023-08-21T07:22:38 | 36,926,494 | 26 | 9 | MIT | 2023-06-06T02:17:44 | 2015-06-05T10:19:09 | Python | UTF-8 | Python | false | false | 2,001 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
# See https://pythonspot.com/en/pyqt5-table/
import sys
from PyQt5.QtWidgets import QApplication, QWidget, QTableWidget, QTableWidgetItem, QVBoxLayout
from PyQt5.QtCore import pyqtSlot
class MyTableWidget(QWidget):
def __init__(self):
super().__init__()
... | [
"jd.jdhp@gmail.com"
] | jd.jdhp@gmail.com |
a59f28c45522064b1d335c76ec154d66b5ffeb42 | 5d0054c979d04f063cd78249a06118716dba89ce | /reasonable.py | fccff74056a1784ac549ce6204b63e9820c22d53 | [] | no_license | latos/love-letter | c0b48e050b9aa44287b22198808057e4f9b261d6 | 2502cafbf824762d2bc95692ea0cb44a31d94d56 | refs/heads/master | 2021-01-02T08:51:01.451130 | 2013-07-27T06:19:46 | 2013-07-27T06:23:08 | 11,699,732 | 0 | 2 | null | 2019-12-12T02:40:40 | 2013-07-27T04:11:02 | Python | UTF-8 | Python | false | false | 3,715 | py | from game import Player, Move, targetting_cards, full_deck
def flatten(l):
return [item for sublist in l for item in sublist]
class Reasonable(Player):
"""
Plays reasonably
"""
def get_brain_name(self):
return 'reasonable'
def new_game(self, initial_card, other_players):
self.current_card = init... | [
"daniel@helixta.com.au"
] | daniel@helixta.com.au |
210ca1a7edd0af971540a7809fe69223ac700a81 | 2f164ba5d0d67fadb88b85bc1fa0961f659cf721 | /venv/Scripts/easy_install-script.py | 449afc6dea1b4b7f97d8c38d0150b145581e2bcd | [] | no_license | shiguliya/myproject | bee086b69e9251c0fe671a9d91258f5fc7bacc5b | 59288b90e3dbc741c5020bf0bcc1b64746ed9be1 | refs/heads/master | 2021-05-23T01:25:00.364437 | 2020-04-19T03:23:39 | 2020-04-19T03:23:39 | 253,172,223 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 434 | py | #!E:\project\cloud\Study\venv\Scripts\python.exe
# EASY-INSTALL-ENTRY-SCRIPT: 'setuptools==40.8.0','console_scripts','easy_install'
__requires__ = 'setuptools==40.8.0'
import re
import sys
from pkg_resources import load_entry_point
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys... | [
"1953491515@qq.com"
] | 1953491515@qq.com |
13d50e6c1e440cd5218c80dbd7403c3103006452 | ca53da088f3ac41cf916a7fa1973e13dbe5f2720 | /Python/ex3.py | 0bcc968b7c57e7eb6bb820fdea4442c9231a13ff | [] | no_license | jackson-/alex-lessons | 77a8cb3976605feb6947f99cefd469a824687634 | 8eea464d6f2aeb63edf645ace94f1fbae2e1534a | refs/heads/master | 2021-05-13T21:02:05.374946 | 2018-01-06T21:36:15 | 2018-01-06T21:36:15 | 116,452,193 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 188 | py | a = [1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89]
less = []
more = []
for i in range (0, len(a)):
if a[i] < 5:
less.append(a[i])
else:
more.append(a[i])
print(less, more) | [
"jackson.t.devin@gmail.com"
] | jackson.t.devin@gmail.com |
26e5acf735b001f7a3fc4430ad39a0090e189b81 | 59138b7f7bb84dec518383202a563271a27cd859 | /async_v20/definitions/primitives.py | fb88b5454b1b9c17110db318dce543fc55ac567c | [
"MIT"
] | permissive | luca-heltai/async_v20 | d5b006c83e522281cf617559f38941a9926391ef | 9a1f944edabeac2d45b1fb847c4108fc957f6b05 | refs/heads/master | 2021-08-24T17:53:46.322409 | 2017-11-21T09:10:20 | 2017-11-21T09:10:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 54,917 | py | from .helpers import domain_check
__all__ = ['AcceptDatetimeFormat', 'AccountFinancingMode', 'AccountID', 'AccountUnits', 'CancellableOrderType',
'CandlestickGranularity', 'ClientComment', 'ClientID', 'ClientTag', 'Currency', 'DateTime', 'DecimalNumber',
'Direction', 'FundingReason', 'InstrumentN... | [
"james.peter.schinner@gmail.com"
] | james.peter.schinner@gmail.com |
3faf8dad36e57a5c0ad8aad5132adc9208b0bf5e | 6c1d75591aeece9902b201ae1a902eee2de93725 | /CS 1064/functions.py | a7c873c663d1f9189637f892cd0dba6174d91416 | [] | no_license | pahuja-gor/Python-Lectures | 85a8630bb1a707daf98b621dd105c5163155efc0 | 2d16dba4b39703c255a4059318da6866028595bb | refs/heads/master | 2022-11-27T03:45:42.254849 | 2020-08-01T23:59:09 | 2020-08-01T23:59:09 | 256,677,210 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 330 | py | output = print("input")
#user_response = input("prompt: ")
integer_542 = int(float("542.0"))
print(abs(int(input("Give me some input (hey, it should be an integer) ")))) # Example 1 of Nesting Functions
print(input("Give me some input (make it a string)").lower().replace("b", "a").count("a")) # Example 2 of Nesting... | [
"36912136+pahuja-gor@users.noreply.github.com"
] | 36912136+pahuja-gor@users.noreply.github.com |
c12d8db8b77d18d3b21a06766010ed2261cde7ba | ceb66ad2b944f38930367f96ea610956f3dc1905 | /NNmodels_and_Docs/diabetes.py | 3248d7b23d4aa8d8c7687d9227229b5bb0dec3aa | [] | no_license | programoworm/DeepNetEI | c635cad82aa9f14ee7ce7ce955607966f3e19b80 | 07eedbf3bb9831ef9ee02b594d36a8e7c925c140 | refs/heads/master | 2023-05-30T00:44:10.236914 | 2021-06-14T10:29:19 | 2021-06-14T10:29:19 | 343,476,497 | 4 | 0 | null | 2021-05-05T15:48:12 | 2021-03-01T16:08:59 | HTML | UTF-8 | Python | false | false | 885 | py | #Diabetes Dataset
import numpy as np
import matplotlib.pyplot as plt
import DeepNet as dn
from time import time
def diabetes():
#Training data modelling
dataset=np.loadtxt("./Datasets/diabetes.data",delimiter=",",comments='#')
X=dataset[1:,:-1]
Y=dataset[1:,-1]
#split into input (X) and output (y) variables
X_tr... | [
"rbkumar712@gmail.com"
] | rbkumar712@gmail.com |
8bc8d819a3a7bc9ec885a9da485a151f60a0a370 | 4246722db02c4fd7ff2500af2d0a208d2fe4dc9d | /fibonacci_ultimo_digito.py | 10860a2a3e8f961ddb0fe8d5b6422a8d1a8845ed | [] | no_license | albertoiur/Algoritmos | 3691aea1d776188b170cb7caa804521e9e1477f8 | 2af41f27b9e1cf3b7de6cd093f840922ab23ccda | refs/heads/master | 2021-10-24T23:11:25.909624 | 2019-03-29T15:19:58 | 2019-03-29T15:19:58 | 120,036,951 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 215 | py | # Uses python3
n = int(input())
if n==0:
print(n)
exit()
if n==1:
print(n)
exit()
a,b = 0,1
for i in range(1,n):
a,b = b, (a+b) % 10
#print(i,a,b)
print(b)
| [
"ruialduol@gmail.com"
] | ruialduol@gmail.com |
4772ae7f4c98b37d92c93a2f74f8148c75426459 | 24a96b67fae227e6be502aa10c87c1ac12b123bc | /BooksApp/urls/authorUrls.py | fe695b430b2cbe3d04a59f326e5c047cf46e657e | [] | no_license | omid-ebrahimi/Django-Sample-Skeleton | eea6ea3328d987d515570a6923dcdc9613d43d3c | 80aa92877e009d4dc7bc97a6258fb26b4aeacffc | refs/heads/master | 2021-05-27T12:29:19.913026 | 2013-07-06T11:09:17 | 2013-07-06T11:09:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 128 | py | __author__ = 'OMID EBRAHIMI'
from django.conf.urls import url, patterns
urlpatterns = patterns('BooksApp.views.authorViews',
) | [
"ebrahimi.omid69@gmail.com"
] | ebrahimi.omid69@gmail.com |
76eba15048d0b423af69d4b807fdbb06c86718cf | 2b425e9e57c778f15d41279ccadf339a7f1ab494 | /catalogue/admin.py | b472d7354710c5fcc280c138f70d69caa27556dc | [] | no_license | Marymuriithi/Greenskiosk | c8935cfed35be4d7611d821aec3c0f17791134eb | b73b2bdc14759fc0766ce26c3ac670a4eaee6639 | refs/heads/master | 2023-01-02T09:41:34.789239 | 2020-10-22T06:23:17 | 2020-10-22T06:23:17 | 286,051,737 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 232 | py | from django.contrib import admin
from .models import ProductSupplier, ProductCategory, Product
# Register your models here.
admin.site.register(ProductSupplier)
admin.site.register(ProductCategory)
admin.site.register(Product)
| [
"mariemuriithi771@gmail.com"
] | mariemuriithi771@gmail.com |
79a88dd625cba7e407e80ccb400fbd3a623f64b0 | 83129b26063ddbf0fd0bbabd929659499ad59eb9 | /prep_data.py | eaf30e478a7861df2f75e5f69cf4f225bb418986 | [] | no_license | baxton-sg/test | ae5d09412c3d4f62b36cd616541ad0c0c09622e0 | ae09b1858c468a0d81c91da0c69028a5ced89d3d | refs/heads/master | 2021-01-01T16:30:22.464937 | 2016-02-04T09:01:08 | 2016-02-04T09:01:08 | 38,250,505 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,221 | py |
import sys
import numpy as np
from array import array
def save_array(src, file_name):
with open(file_name, "wb+") as fout:
print len(src), len(src[1])
R = len(src)
for r in range(R):
a = array('f', src[r])
a.tofile(fout)
def process(subj_no):
for ... | [
"baxton-sg@users.noreply.github.com"
] | baxton-sg@users.noreply.github.com |
e8fbe4bd5e122c8ef6cb17b695b700b76663a1f4 | 1b55d4bba0503856632eb3b8a7295eb94759b2ea | /utils/train_utils.py | 637d40501fc25e10702d3a32e15eab605de9f402 | [] | no_license | qianguzi/competition_cls | d14751ef1000ff708fdaa934a8fee5647fb3e9e0 | 6d035f5d579e4aceef2ce51997ef492953365223 | refs/heads/master | 2020-04-08T08:26:19.402802 | 2019-02-25T09:08:58 | 2019-02-25T09:08:58 | 159,178,721 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,602 | py | # Copyright 2018 The TensorFlow Authors All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | [
"454099185@qq.com"
] | 454099185@qq.com |
7c8ca79e14d099a436e0546c70c1769db217b091 | 34a7bf487666f350c27706a663029555f81a8e01 | /main.py | 01ebd41175fb62dae28cf6af04c3399602b56096 | [] | no_license | Giulero/deep_deterministic_policy_gradient | a676c62457f9487fdf0db8746368655f918d0cdc | 6b607542fea1e2f8c7cd90f6410f9f849cb05899 | refs/heads/master | 2020-04-24T08:55:10.573252 | 2019-03-03T11:35:56 | 2019-03-03T11:35:56 | 171,845,946 | 4 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,646 | py | import argparse
import numpy as np
import mujoco_py
import gym
import tensorflow as tf
from Actor import *
from Critic import *
from OU_Noise import *
from tqdm import tqdm
from collections import deque
import random
import os
import shutil
# function to organize the selected elements from the batch
def batch_selecto... | [
"gl.giuseppelerario@gmail.com"
] | gl.giuseppelerario@gmail.com |
175dac1813e30dfc38d2330b3134a90625c9dacc | 3d192f5ebe208a9603460d7bc248a5e983bd49e1 | /main_list.py | dc59cc6d0f399323fb087d8c5a02697e1a5038f5 | [] | no_license | 535521469/list_shc | 43e83705127b601fdfa3f1688f450d9ddae96bb9 | 0d93baec3a64a532ab95498805247784262dd684 | refs/heads/master | 2021-01-15T21:10:03.980779 | 2013-11-28T05:44:17 | 2013-11-28T05:44:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,202 | py | # encoding=utf8
'''
Created on 2013-3-20
@author: corleone
'''
from crawler.shc.fe.const import FEConstant as const
from multiprocessing import Process
from sched import scheduler
from scrapy.cmdline import execute
from scrapy.settings import CrawlerSettings
import collections
import datetime
import time
from bot.confi... | [
"535521469@qq.com"
] | 535521469@qq.com |
a2c06d42d13a74881d8ce2770a42a240f90ffa8b | acb8e84e3b9c987fcab341f799f41d5a5ec4d587 | /langs/5/nxr.py | 78b3d4076a27f4f810c52838a61eaa9ef5ab7d72 | [] | no_license | G4te-Keep3r/HowdyHackers | 46bfad63eafe5ac515da363e1c75fa6f4b9bca32 | fb6d391aaecb60ab5c4650d4ae2ddd599fd85db2 | refs/heads/master | 2020-08-01T12:08:10.782018 | 2016-11-13T20:45:50 | 2016-11-13T20:45:50 | 73,624,224 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 486 | py | import sys
def printFunction(lineRemaining):
if lineRemaining[0] == '"' and lineRemaining[-1] == '"':
if len(lineRemaining) > 2:
#data to print
lineRemaining = lineRemaining[1:-1]
print ' '.join(lineRemaining)
else:
print
def main(fileName):
with open(fileName) as f:
for line in f:
... | [
"juliettaylorswift@gmail.com"
] | juliettaylorswift@gmail.com |
d10ea8cdadf1085bc2df8736b0a85db0a99283ba | a6a616bd4cdbdacfd820687ba49217ea0fe55b4f | /env/Scripts/django-admin.py | 1ad8a2d33bf8906618e59a3da503c5781efc6185 | [] | no_license | CNPATADIYA/CoronaHack--Chest-X-Ray | 6ae5d45df53e637299c328b829afd570364a2165 | 525d7e9fb9095cdf0c767b1ffd4aaefddce9a202 | refs/heads/master | 2023-07-27T03:33:30.002206 | 2021-09-08T03:43:31 | 2021-09-08T03:43:31 | 345,550,507 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 702 | py | #!C:\Users\Chirag\Desktop\corona-chest-x-ray\env\Scripts\python.exe
# When the django-admin.py deprecation ends, remove this script.
import warnings
from django.core import management
try:
from django.utils.deprecation import RemovedInDjango40Warning
except ImportError:
raise ImportError(
'django-admi... | [
"chiragpatadiya20@gmail.com"
] | chiragpatadiya20@gmail.com |
0e10540f473f672f0bf338bc72c450920cda8694 | 24d808fb40082fbbf66013f1d921fb2d9e4a4846 | /V-REP simulation/AckermannCar/NeatEngine/utils.py | 26db1176ac2fb54c08998e1d1cbf00912bfe4f4c | [] | no_license | DaryaLari/ControlTheoryProject | eb7abc74a45ac44f0d1a3362330b4fa534cedcfc | 64cd0d044110702fe199b509cc3b7f861e3748ce | refs/heads/master | 2023-01-21T13:12:32.359246 | 2018-07-04T13:03:31 | 2018-07-04T13:03:31 | 127,004,555 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 876 | py | import neat
import os
def import_best_genome(restore_file_name, config_file_name):
p = neat.Checkpointer.restore_checkpoint(restore_file_name)
if p.best_genome is not None:
best_gen = p.best_genome
else:
best_gen = max(filter(lambda g: g.fitness is not None, p.population.values()), key=la... | [
"daryalari1@gmail.com"
] | daryalari1@gmail.com |
9e90bb8d779df640147384a893d77b07f2666499 | e44d00ffcea03f8656c40b3d4d993d51a38af3b0 | /leetcode/June/J30_WordSearch.py | b5d00f420d9170ce3aba83d26afc9c78c2c1d6ed | [] | no_license | Ayushmanglani/competitive_coding | d6beec4f2b24aef34ea44c3a4a72074985b4a766 | 12325b09ae2bc6b169578b6a0a091069e14c9227 | refs/heads/master | 2023-06-12T04:43:41.130774 | 2021-07-03T13:01:37 | 2021-07-03T13:01:37 | 262,079,363 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,032 | py | WORD_KEY = '$'
trie = {}
for word in words:
node = trie
for letter in word:
# retrieve the next node; If not found, create a empty node.
node = node.setdefault(letter, {})
# mark the existence of a word in trie node
... | [
"ayush.manglani@gmail.com"
] | ayush.manglani@gmail.com |
4b6869addf1b07d38c2cfc116b7b4396b942bd18 | cdb47e1f6eb6511cbf4e1814e5388f23e322343e | /examples/train_HPF_spectrum.py | bfda96393770c19ae9d7d6e7d8be50ce6362ea74 | [
"MIT"
] | permissive | erwanp/blase | 7b89dd2b315d53ccd54577b47ea48d18ddce8c9f | b8effa1176d9c5c77f9afe20c4e2fbc3bb9f6031 | refs/heads/main | 2023-01-24T01:49:18.655198 | 2020-12-06T23:58:22 | 2020-12-06T23:58:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,945 | py | from os import initgroups
# from astropy.io.fits import column
# from numpy.lib.shape_base import column_stack
import torch
import time
from blase.datasets import HPFDataset
from blase.multiorder import MultiOrder
from torch.utils.data import DataLoader
import torch.optim as optim
import torch.nn as nn
from tqdm impor... | [
"igully@gmail.com"
] | igully@gmail.com |
bcf362efa27bf9b944a7809c71d7d948778c7f5b | 6351221d588668804e2df01936732eede4d96ed0 | /leetcode-cn/Python/75.颜色分类.py | 4313aa9c973f61f6ebfa98ea1f9aed7a874433b6 | [] | no_license | LogicJake/code-for-interview | 8e4ec9e24ec661a443ad42aa2496d78a1fbc8a3f | 5990b09866696c2f3e845047c755fa72553dd421 | refs/heads/master | 2021-09-20T20:19:17.118333 | 2021-09-14T13:46:30 | 2021-09-14T13:46:30 | 102,202,212 | 3 | 2 | null | null | null | null | UTF-8 | Python | false | false | 611 | py | #
# @lc app=leetcode.cn id=75 lang=python3
#
# [75] 颜色分类
#
# @lc code=start
from typing import List
class Solution:
def sortColors(self, nums: List[int]) -> None:
"""
Do not return anything, modify nums in-place instead.
"""
p0 = 0
p2 = len(nums) - 1
i = 0
... | [
"835410808@qq.com"
] | 835410808@qq.com |
a6fc513962549acb9bc142960e1fd8db3a850b34 | dbfead054f92e33fffe6d30b831bef2d434eec80 | /scripts/model/asset_times_series.py | e6cc78e39cfabc8324626c7e5854f07f42cdc2bb | [
"MIT"
] | permissive | aGiant/options_trading_data_example | f9334945c003007bf3ce47636e0c593095cd294f | 1a27a26d328a89349c336811a1d657711513ca70 | refs/heads/master | 2022-06-04T11:01:34.625433 | 2020-03-12T19:47:14 | 2020-03-12T19:47:14 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,568 | py | import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import tensorflow as tf
import sys
import os.path
from pathlib import Path
import argparse
from sklearn.preprocessing import MinMaxScaler
from sklearn.metrics import r2_score
from keras.models import Sequential
from keras.layers import Dense
impor... | [
"pmrai@sandia.gov"
] | pmrai@sandia.gov |
88d4fa2d0076946d04bbd1b4a6f4885cde020362 | f82757475ea13965581c2147ff57123b361c5d62 | /gi-stubs/repository/Gdk/EventTouchpadSwipe.py | d2868a48bee0f1424400e2bd2a7e6dbbb90e218c | [] | no_license | ttys3/pygobject-stubs | 9b15d1b473db06f47e5ffba5ad0a31d6d1becb57 | d0e6e93399212aada4386d2ce80344eb9a31db48 | refs/heads/master | 2022-09-23T12:58:44.526554 | 2020-06-06T04:15:00 | 2020-06-06T04:15:00 | 269,693,287 | 8 | 2 | null | 2020-06-05T15:57:54 | 2020-06-05T15:57:54 | null | UTF-8 | Python | false | false | 5,968 | py | # encoding: utf-8
# module gi.repository.Gdk
# from /usr/lib64/girepository-1.0/Gdk-2.0.typelib
# by generator 1.147
# no doc
# imports
import gi as __gi
import gi.overrides as __gi_overrides
import gi.overrides.GObject as __gi_overrides_GObject
import gi.repository.Gio as __gi_repository_Gio
import gobject as __gobje... | [
"ttys3@outlook.com"
] | ttys3@outlook.com |
1cfeabe2c335f3dd9eeeba0cce481ec2d3938588 | b46b1cac5e318241fcb268aacf536b8efe6568ea | /bin/tensorboard | e217fa73f3fb31e3163356b3025234259249d903 | [] | no_license | kerow1004/tensorflow_imageprocessing | 1cc0e5ef8f95ad30c8ccc4254d055f03e67302c4 | cc883695fdb0cf04dc630bcea7692171e4ec3ce5 | refs/heads/master | 2022-12-22T00:57:46.620124 | 2020-09-08T04:11:29 | 2020-09-08T04:11:29 | 293,470,047 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 274 | #!/Users/jinseongkim/PycharmProjects/tensorflow-mobile/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from tensorboard.main import run_main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.argv[0])
sys.exit(run_main())
| [
"noreply@github.com"
] | kerow1004.noreply@github.com | |
fbd5216afb522f655d0010b399ceaaefc24ab5ea | e96d6fa89c89bc8240076c94e522e928e71981f4 | /train_metric.py | da8aeaab951d869e5189fcc5ecd910fc6788a1f1 | [] | no_license | dongzeus/metric_learning | 6bc1465ad08c456895aaeb37de5bdae9e27a1e09 | de5ea312510a0ac093962ea3e15a920a0c845f1f | refs/heads/master | 2021-09-02T08:55:58.724731 | 2018-01-01T06:15:42 | 2018-01-01T06:15:42 | 113,464,443 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,348 | py | #!/usr/bin/env python
from __future__ import print_function
import argparse
import random
import time
import os
import numpy as np
from optparse import OptionParser
import torch
import torch.backends.cudnn as cudnn
import torch.optim as optim
from torch.autograd import Variable
from torch.optim.lr_scheduler import La... | [
"dongzeus@163.com"
] | dongzeus@163.com |
9e6a5c28deb6319b17382841b4bf8f3c8eb12329 | a0bc7e910303484c34ea7cd7b066e3c3dbbfa3ff | /Try_Them_All!.py | 22848d356db531c01106976cffdf7ea9fb05574f | [
"MIT"
] | permissive | eddyvdaker/PicoCTF-2013 | 1534d147a9cebdfdc8ff0a1595d18f325ae33c12 | 6dd29bfad4b5c85cfa44fd847511452546b9b1ac | refs/heads/master | 2021-01-12T16:42:33.872171 | 2016-11-01T08:35:30 | 2016-11-01T08:35:30 | 71,434,876 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 774 | py | #!/usr/bin/env python
import md5, time, csv
counter = 0
print('### MD5 Dictonary Attack Tool ###')
passHash = str(raw_input('Input the password hash to crack: '))
salt = str(raw_input('Input salt (leave empty for no salt): '))
wordfile = open('wordlist.csv', 'rb')
reader = csv.reader(wordfile)
startTi... | [
"noreply@github.com"
] | eddyvdaker.noreply@github.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.