blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 288 | content_id stringlengths 40 40 | detected_licenses listlengths 0 112 | license_type stringclasses 2
values | repo_name stringlengths 5 115 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 684
values | visit_date timestamp[us]date 2015-08-06 10:31:46 2023-09-06 10:44:38 | revision_date timestamp[us]date 1970-01-01 02:38:32 2037-05-03 13:00:00 | committer_date timestamp[us]date 1970-01-01 02:38:32 2023-09-06 01:08:06 | github_id int64 4.92k 681M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 22
values | gha_event_created_at timestamp[us]date 2012-06-04 01:52:49 2023-09-14 21:59:50 ⌀ | gha_created_at timestamp[us]date 2008-05-22 07:58:19 2023-08-21 12:35:19 ⌀ | gha_language stringclasses 147
values | src_encoding stringclasses 25
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 128 12.7k | extension stringclasses 142
values | content stringlengths 128 8.19k | authors listlengths 1 1 | author_id stringlengths 1 132 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
e446b4b4c3699733ad5922d435466930f6cfb35b | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02573/s534378621.py | 53efd867886d93f3b9f58471c95fd08487dbc066 | [] | 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 | 976 | py | # import sys
# input = sys.stdin.readline()
n,m = map(int, input().split())
ab = []
for i in range(m):
a,b = map(int, input().split())
ab.append([a,b])
class UnionFind:
def __init__(self,N):
self.parent = [i for i in range(N)]
self._size = [1] * N
self.count = 0
def root(self,a):
if self.parent... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
2fe6904da2931f0c0af9091b946ef4de9424f574 | 377ec156e459f70ad32e625de2dde2672736dd06 | /Exercises/CorePythonExercises/ForMathModel.py | 527020f502bff6dbe72d50c9e9bb9988e7b05e69 | [] | no_license | tsonglew/learn-python | b657cc34d3e27993ec0dcce152796bea43224d4f | edbf0b5d24bf0e2d9ad7aa5811c7d3aa0a66b57c | refs/heads/master | 2021-06-13T13:46:35.199562 | 2017-04-14T16:57:38 | 2017-04-14T16:57:38 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,273 | py | # -*- coding: utf-8 -*-
"""
例1 混合泳接力队的选拔
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
5名候选人的百米成绩
甲 乙 丙 丁 戊
蝶泳 1'06"8 57"2 1'18" 1'10" 1'07"4
仰泳 1'15"6 1'06" 1'07"8 1'14"2 1'11"
蛙泳 1'27" 1'06"4 1'24"6 1'09"6 1'23"8
自由泳 5... | [
"417879751@qq.com"
] | 417879751@qq.com |
fc07e28592592465f34667c2510771d8580a76b1 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_167/ch19_2019_08_30_17_33_49_991320.py | 255123fd942fa40a66a7196baefba809573f081f | [] | no_license | gabriellaec/desoft-analise-exercicios | b77c6999424c5ce7e44086a12589a0ad43d6adca | 01940ab0897aa6005764fc220b900e4d6161d36b | refs/heads/main | 2023-01-31T17:19:42.050628 | 2020-12-16T05:21:31 | 2020-12-16T05:21:31 | 306,735,108 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 142 | py | import math
g=9.8
def calcula_distancia_do_projetil (v,θ,y0):
d==(v**2/2*g)*1+(1 +2*g*y0/(v)**2*(math.sin(θ)**2))**1/2
return d
| [
"you@example.com"
] | you@example.com |
8ca3f112dba2ddf412dc8ed04db02bafdb9be374 | 78b42a602bdabbf28321b267714f0b29e89a669e | /3-2.队列.py | 1d5c1807ba1b3d50d86169ad3decc5bb6aaa2c1c | [] | no_license | michelleweii/DataStructure-Algorithms | 3c95240b8ed48237f23ff97754d6cc15cadc94dd | 84f5d6e2811f5e6c4578a5e0d381a86cbc414ce9 | refs/heads/master | 2020-03-29T13:07:06.910799 | 2018-11-29T12:57:57 | 2018-11-29T12:57:57 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,858 | py | # 取元素的端叫做队头,添加元素的端叫做队尾
class Queue(object):
"""队列"""
def __init__(self):
self.__list = []
def enqueue(self,item):
"""往队列中添加一个item元素"""
self.__list.append(item)
def dequeue(self):
"""从队列头部删除一个元素"""
return self.__list.pop(0) # 先进先出
def is_empty(self)... | [
"641052383@qq.com"
] | 641052383@qq.com |
44803dedada3fec966306568b761e601637bccc8 | 2e682fd72e3feaa70e3f7bf2a3b83c50d783ec02 | /PyTorch/contrib/cv/detection/NasFPN/mmdet/models/detectors/cascade_rcnn.py | 47cc7cef984123804c4f99900d496807cde3c0e6 | [
"GPL-1.0-or-later",
"Apache-2.0",
"BSD-2-Clause",
"MIT",
"BSD-3-Clause",
"LicenseRef-scancode-generic-cla",
"LicenseRef-scancode-unknown-license-reference",
"LicenseRef-scancode-warranty-disclaimer"
] | permissive | Ascend/ModelZoo-PyTorch | 4c89414b9e2582cef9926d4670108a090c839d2d | 92acc188d3a0f634de58463b6676e70df83ef808 | refs/heads/master | 2023-07-19T12:40:00.512853 | 2023-07-17T02:48:18 | 2023-07-17T02:48:18 | 483,502,469 | 23 | 6 | Apache-2.0 | 2022-10-15T09:29:12 | 2022-04-20T04:11:18 | Python | UTF-8 | Python | false | false | 1,288 | py | from ..builder import DETECTORS
from .two_stage import TwoStageDetector
@DETECTORS.register_module()
class CascadeRCNN(TwoStageDetector):
r"""Implementation of `Cascade R-CNN: Delving into High Quality Object
Detection <https://arxiv.org/abs/1906.09756>`_"""
def __init__(self,
backbone,
... | [
"wangjiangben@huawei.com"
] | wangjiangben@huawei.com |
6ff102d1cea23a24786b8d1335ce9d535b54fdb3 | 045cb1a5638c3575296f83471758dc09a8065725 | /addons/base_gengo/models/res_company.py | 82bdf8e87666085dc1a354e8cba4071dc6357e27 | [] | no_license | marionumza/saas | 7236842b0db98d1a0d0c3c88df32d268509629cb | 148dd95d991a348ebbaff9396759a7dd1fe6e101 | refs/heads/main | 2023-03-27T14:08:57.121601 | 2021-03-20T07:59:08 | 2021-03-20T07:59:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 920 | py | # -*- coding: utf-8 -*-
# Part of Harpiya. See LICENSE file for full copyright and licensing details.
from harpiya import fields, models
class res_company(models.Model):
_inherit = "res.company"
gengo_private_key = fields.Char(string="Gengo Private Key", copy=False, groups="base.group_system")
gengo_pub... | [
"yasir@harpiya.com"
] | yasir@harpiya.com |
66e2c5329e9521e3252d6ead99b95654d8cdaed4 | b7c51f5e564d1f0e622fbe6e144f996d693af8cf | /Bins/MakeSparseMatrixSVD.py | c24629f3f51015d698bb93ed7c430d0c9260a6cd | [] | no_license | GINK03/job-recommender-api | a223fb225a1231eaf1b56abd92d9aa8f20ff241b | 6afdfa915918184debe96f5ac6932dfa30f7d4a5 | refs/heads/master | 2022-11-19T16:48:38.776963 | 2020-07-24T15:49:23 | 2020-07-24T15:49:23 | 263,545,893 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,429 | py | import pickle
import gzip
import glob
from scipy.sparse import lil_matrix
from sklearn.decomposition import TruncatedSVD
# import faiss
import numpy as np
from pathlib import Path
from tqdm import tqdm
import sys
from concurrent.futures import ProcessPoolExecutor
import joblib
import pandas as pd
from os import environ... | [
"gim.kobayashi@gmail.com"
] | gim.kobayashi@gmail.com |
5c2128c48f6cca29296f7fb6db51371bf51bddfe | e9e083aa75398a015e55ec5de655c262eb1496c6 | /mod5-adv/threads/simple-non-daemon.py | c84fa8b3f9455600fa262c7ffd6e93d45bccacc2 | [] | no_license | michaelconst/csuf-pythonprog | 54d98a878b34038a067c07c649a6025b8380b971 | 017ec2004482bbd20ce24d6c5ec8f0ae2a6cdb78 | refs/heads/master | 2021-01-21T10:00:30.268732 | 2017-03-14T01:29:44 | 2017-03-14T01:29:44 | 83,357,234 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 312 | py | import threading
import time
import random
def do_work(t):
print('[{}] sleeping {}s'.format(threading.current_thread().name, t))
time.sleep(t)
print('[{}] exiting'.format(threading.current_thread().name))
for i in range(5):
threading.Thread(target=do_work, args=(random.randint(1, 5),)).start() | [
"constantinm@sharplabs.com"
] | constantinm@sharplabs.com |
3d8e087c32269d3024415ff947d05fb54bc4b5ae | 826085daea311de883ad1e8dfcc8ef5569f087bf | /broca/similarity/term/wikipedia.py | 33c38f57abeaea4f2b39766fd32b32d37969b214 | [
"MIT"
] | permissive | parksebastien/broca | f2d10cfd6a7dcc6c069ee2e69d5faeb2e1004b67 | 7236dcf54edc0a4a54a55eb93be30800910667e7 | refs/heads/master | 2020-05-22T09:48:19.417396 | 2015-09-10T12:35:56 | 2015-09-10T12:35:56 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,242 | py | from scipy.spatial.distance import pdist, squareform
from broca.similarity.term import TermSimilarity
from broca.knowledge.wikipedia import Wikipedia
from broca.vectorize.bow import BoWVectorizer
class WikipediaSimilarity(Wikipedia, TermSimilarity):
def __init__(self, terms, wiki_conn=None):
"""
I... | [
"f+accounts@frnsys.com"
] | f+accounts@frnsys.com |
52fc0a314b8c7900c41339efe131dd5f2bc66806 | 8c69736d7ac2541be761d728284d315cefa90d28 | /nodes/1.x/python/Element.Category+.py | 1d9538abcbb641afdd57cccc319aef7a91d65b65 | [
"MIT"
] | permissive | ptrklk/ClockworkForDynamo | 21ae4ab4ab70d02b6d706f16f312865cd73c4ace | 90293d8fb74e6b3339acd6ca4ff69f695b6a02ac | refs/heads/master | 2020-03-26T07:50:47.053264 | 2018-07-28T07:55:10 | 2018-07-28T07:55:10 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 987 | py | import clr
clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
clr.AddReference("RevitNodes")
import Revit
clr.ImportExtensions(Revit.Elements)
def GetCategory(item):
objtype = item.GetType().ToString()
if objtype == "Autodesk.Revit.DB.ViewSchedule": return Revit.Elements.Category.ById(item.Definition.Cate... | [
"dieckmann@caad.arch.rwth-aachen.de"
] | dieckmann@caad.arch.rwth-aachen.de |
f63cba311274c50550ab3646cb08e9203bacea0f | 9d961bd6a590cc96db0c1f9c72d84e3a66636edf | /심심풀이땅콩/[백준]2920.py | 66cc611eced9e2f94957f850a848db3dff36e886 | [] | no_license | 0equal2/Python_Programming | bae65338929e8e1a88247b8d23de805caa026702 | 2ac1d0262320220f49cbdb45e787e55e994d0b0f | refs/heads/master | 2023-05-14T22:13:41.583214 | 2021-06-09T03:04:51 | 2021-06-09T03:04:51 | 304,628,012 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 192 | py | ###[백준]2920
info=list(map(str,input().split()))
info="".join(info)
if info=="12345678":
print("ascending")
elif info=="87654321":
print("descending")
else:
print("mixed")
| [
"duddms0115@gmail.com"
] | duddms0115@gmail.com |
6a726761b329c956b3768f904b22bebfcb704b34 | 2359121ebcebba9db2cee20b4e8f8261c5b5116b | /configs_pytorch/f30_pt.py | ab367f0af0238b8e8079026ca000938067363cfa | [] | no_license | EliasVansteenkiste/plnt | 79840bbc9f1518c6831705d5a363dcb3e2d2e5c2 | e15ea384fd0f798aabef04d036103fe7af3654e0 | refs/heads/master | 2021-01-20T00:34:37.275041 | 2017-07-20T18:03:08 | 2017-07-20T18:03:08 | 89,153,531 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 6,549 | py |
#copy of j25
import numpy as np
from collections import namedtuple
from functools import partial
from PIL import Image
import data_transforms
import data_iterators
import pathfinder
import utils
import app
import torch
import torchvision
import torch.optim as optim
import torch.nn as nn
import torch.nn.functional... | [
"frederic.godin@ugent.be"
] | frederic.godin@ugent.be |
4e3dbf1d5e5f1322b18d30e741a4ecefa93b1978 | e7795082c0131682803a09e929a86b2deddeab74 | /common/PackageRequest.py | 55551a9dd599fd01e2d21b48e965acf577cdcab7 | [
"MIT"
] | permissive | liwanlei/FXTest | 01de3ad55849b16c49d93b58d1aae21fd0fdafa0 | aeda58d01c14194290ca149d411c3a8596cca82d | refs/heads/master | 2023-04-01T15:45:26.668688 | 2023-03-19T05:19:54 | 2023-03-19T05:19:54 | 97,098,845 | 807 | 419 | MIT | 2022-04-23T06:52:16 | 2017-07-13T08:27:48 | Python | UTF-8 | Python | false | false | 5,324 | py | # -*- coding: utf-8 -*-
# @Date : 2017-07-20 15:13:25
# @Author : lileilei
'''
requets模块的简单的封装
'''
import requests, json
from config import Interface_Time_Out
from requests import exceptions
from common.systemlog import logger
class reques():
def get(self, url, headers, parms): # get消息
try:
... | [
"leileili126@163.com"
] | leileili126@163.com |
bc02bd5d06610caebebf2ffa034ff85777eb4b1d | d51e67abc7709b17664ee08eb9d68ecb938f00a9 | /utils/farmbot.py | 1ace2bcc577c12cf3db231e381d3c13f6f25e1c8 | [] | no_license | averdier/farmware_watering_farmdesign | bb6d3d2615c8ac5294e3bbd61cea97cf0950e05c | d474d78629504907971c7f7b2ee6b88954f6f4cf | refs/heads/master | 2020-03-30T09:26:40.012409 | 2018-10-02T09:16:04 | 2018-10-02T09:16:04 | 151,075,628 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,367 | py | # -*- coding: utf-8 -*-
import uuid
from time import time, sleep
from .api import send_celery_script, log, get_resource
from .geometry import Point3D
def prepare_move_absolute_script(position, speed):
return {
'kind': 'rpc_request',
'args': {
'label': 'farmware_circle_' + str(uuid.uui... | [
"a.verdier@outlook.fr"
] | a.verdier@outlook.fr |
2b9bacb7050fe1eb24ece4e8eb572e2926d53cb4 | 4f340ed313a67bddf077a9d8da2205b9c2feb29a | /emv/util.py | dd9f8ac0b99ed0b904b87cec4e819cd092561dd2 | [
"MIT"
] | permissive | russss/python-emv | 49b645be9ec60acc8cd23e95e5423a1b2c90a175 | ce316ba05165e9b82026f72b55329b9bc287c0b8 | refs/heads/main | 2023-06-21T19:09:10.124472 | 2023-06-01T18:44:34 | 2023-06-11T15:26:11 | 76,971,486 | 105 | 30 | MIT | 2023-06-11T15:26:12 | 2016-12-20T16:10:14 | Python | UTF-8 | Python | false | false | 1,096 | py | import re
def hex_int(val):
"""Convert an integer into a decimal-encoded hex integer as bytes,
which the EMV spec seems awfully keen on.
>>> hex_int(123456)
[0x12, 0x34, 0x56]
>>> hex_int(65432)
[0x06, 0x54, 0x32]
"""
s = str(val)
if len(s) % 2 != 0:
s = "0" + s
return... | [
"russ@garrett.co.uk"
] | russ@garrett.co.uk |
1b392e96dea3bc4c7baebfd90006596440762416 | 30ba09b0a746b1cef4c817fd87f1f310904a6d88 | /test/test_dialogs/test_title_screen.py | 770f143c244c1bfcf20b45cf482ac9f12c0d5667 | [
"MIT",
"Artistic-1.0-Perl"
] | permissive | krother/tilegamelib | 69e610959294ed950f49fefd8e7d50ceb1ba09ed | a8165f27b166acca37f81e8432a70e0b2e028338 | refs/heads/master | 2022-07-21T20:07:35.031330 | 2022-07-10T20:18:19 | 2022-07-10T20:18:19 | 1,045,043 | 5 | 2 | null | null | null | null | UTF-8 | Python | false | false | 1,172 | py |
from unittest import TestCase, main
from conftest import MENU_RECT, TITLE_IMAGE, TITLE_RECT
from tilegamelib.dialogs.title_screen import TitleScreen
from tilegamelib.events import QUIT_EVENT, EventGenerator
from tilegamelib.menu import VERTICAL_MOVES
class TitleScreenTests(TestCase):
def setUp(self):
se... | [
"krother@academis.eu"
] | krother@academis.eu |
3742ff611dc02b777b4f83d39a8aade1e7dc7cfc | a2cd609a52eb5be16a248c054fb014394f12d344 | /build/globalplanner/catkin_generated/pkg.installspace.context.pc.py | a04cf5b45702ff3cf2cd28d70712504d7506b0de | [] | no_license | rfzeg/simon_thesis_ws | c5e6d6b20ee63010ffede91d17ba144527e5f6c5 | dc79635f628dade14cab1a631cc4eb24aee1762c | refs/heads/master | 2021-09-16T12:43:41.270235 | 2018-06-20T12:40:57 | 2018-06-20T12:40:57 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 550 | py | # generated from catkin/cmake/template/pkg.context.pc.in
CATKIN_PACKAGE_PREFIX = ""
PROJECT_PKG_CONFIG_INCLUDE_DIRS = "/home/simoneforno/simon_ws/install/include".split(';') if "/home/simoneforno/simon_ws/install/include" != "" else []
PROJECT_CATKIN_DEPENDS = "roscpp;pluginlib;costmap_2d;base_local_planner;nav_core".r... | [
"s.forno@student.tue.nl"
] | s.forno@student.tue.nl |
6ba857f45be0a377186287819331c0f00d600dc2 | 411eff94020c192d5e5f657fa6012232ab1d051c | /game/src/coginvasion/attack/LinearProjectile.py | f5e3003258b6aada6e2dd3d56c10f9ceea59b384 | [] | no_license | xMakerx/cio-src | 48c9efe7f9a1bbf619a4c95a4198aaace78b8491 | 60b2bdf2c4a24d506101fdab1f51752d0d1861f8 | refs/heads/master | 2023-02-14T03:12:51.042106 | 2021-01-15T14:02:10 | 2021-01-15T14:02:10 | 328,268,776 | 1 | 0 | null | 2021-01-15T15:15:35 | 2021-01-09T23:51:37 | Python | UTF-8 | Python | false | false | 484 | py | from src.coginvasion.attack.BaseProjectile import BaseProjectile
from src.coginvasion.attack.LinearProjectileShared import LinearProjectileShared
class LinearProjectile(BaseProjectile, LinearProjectileShared):
def __init__(self, cr):
BaseProjectile.__init__(self, cr)
LinearProjectileShared.__init_... | [
"maverick.liberty29@gmail.com"
] | maverick.liberty29@gmail.com |
a6cac7d77145dd89deb708f5be1407ffe096d320 | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/verbs/_suffocated.py | 8b356fe7d1d8ac09890ee20e1e5dc5a7719a80ba | [
"MIT"
] | permissive | cash2one/xai | de7adad1758f50dd6786bf0111e71a903f039b64 | e76f12c9f4dcf3ac1c7c08b0cc8844c0b0a104b6 | refs/heads/master | 2021-01-19T12:33:54.964379 | 2017-01-28T02:00:50 | 2017-01-28T02:00:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 259 | py |
from xai.brain.wordbase.verbs._suffocate import _SUFFOCATE
#calss header
class _SUFFOCATED(_SUFFOCATE, ):
def __init__(self,):
_SUFFOCATE.__init__(self)
self.name = "SUFFOCATED"
self.specie = 'verbs'
self.basic = "suffocate"
self.jsondata = {}
| [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
280b60d0e3b097e45c49ec6db0db8f323a43d3c5 | 9568dee77459304ad0f7e01c9dea9432c11377d0 | /maxlike_sim_filehandler.py | c91d4799c888691d93117cefde6a1784acc6f66d | [
"MIT"
] | permissive | lbaumo/wtgpipeline | c101c7e7ec1491a1c40cbe14102662770641bb9a | 73de01736e33769c09c4467e3c040545d7070407 | refs/heads/master | 2021-06-20T14:40:38.263891 | 2017-08-14T21:08:24 | 2017-08-14T21:08:24 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,688 | py | #############################
# Handles loading files for a simulation run
#############################
import ldac, cPickle, numpy as np
import astropy.io.fits as pyfits
import pdzfile_utils, nfwutils, varcontainer
#############################
__cvs_id__ = "$Id$"
#############################
class SimFilehandl... | [
"dapple@xoc7.stanford.edu"
] | dapple@xoc7.stanford.edu |
adeb59d010bdfae9169f837cf998303af2c9df2e | 463c053bcf3f4a7337b634890720ea9467f14c87 | /rllib/models/jax/misc.py | 02ebd98fd261b684769013ef6b2f7fd3ba31bc62 | [
"BSD-3-Clause",
"MIT",
"Apache-2.0"
] | permissive | pdames/ray | e8faddc4440976211a6bcead8f8b6e62c1dcda01 | 918d3601c6519d333f10910dc75eb549cbb82afa | refs/heads/master | 2023-01-23T06:11:11.723212 | 2022-05-06T22:55:59 | 2022-05-06T22:55:59 | 245,515,407 | 1 | 1 | Apache-2.0 | 2023-01-14T08:02:21 | 2020-03-06T20:59:04 | Python | UTF-8 | Python | false | false | 2,287 | py | import time
from typing import Callable, Optional
from ray.rllib.utils.framework import get_activation_fn, try_import_jax
jax, flax = try_import_jax()
nn = np = None
if flax:
import flax.linen as nn
import jax.numpy as np
class SlimFC:
"""Simple JAX version of a fully connected layer."""
def __init... | [
"noreply@github.com"
] | pdames.noreply@github.com |
08b869e8d8559db4d477d360515bc7c627507ca5 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03129/s302066927.py | 0887597072b00c7f90e5a7d87138c543cb18fc6f | [] | 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 | 156 | py | import sys
N, K = map(int, input().split())
ans = 0
for i in range(1,N+1,2):
ans = ans + 1
if ans >= K:
print("YES")
sys.exit()
print("NO")
| [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
77ec1a307afebd5162f2ea1d4eaaece759d3fd15 | 6b2a8dd202fdce77c971c412717e305e1caaac51 | /solutions_5753053697277952_0/Python/BIPUL/a.py | 3b8209e6b92d12243001a0707948776e81fe2d81 | [] | no_license | alexandraback/datacollection | 0bc67a9ace00abbc843f4912562f3a064992e0e9 | 076a7bc7693f3abf07bfdbdac838cb4ef65ccfcf | refs/heads/master | 2021-01-24T18:27:24.417992 | 2017-05-23T09:23:38 | 2017-05-23T09:23:38 | 84,313,442 | 2 | 4 | null | null | null | null | UTF-8 | Python | false | false | 1,955 | py | ############### Author: Bipul Ranjan @ranjanbipul ###############
import sys
import time
import os
import math
import operator
import random
from functools import lru_cache
from decimal import Decimal as D
from fractions import Fraction as F
#sys.setrecursionlimit(10000)
#@lru_cache(maxsize=None)
MOD = 1000... | [
"alexandra1.back@gmail.com"
] | alexandra1.back@gmail.com |
ac6d4db8c9c186c23b51f9690ba1d838c76936cc | b9662213e143acea87e9af6f41143c50f23bec95 | /main.py | 3bcc258a67bac8bb863e85ccfce47cd210cce045 | [] | no_license | elprofedotti/python-mvc | 3442680dc20d7cb0ec9c3bf09442daecda4c8e4e | 9beee06de2e7a04ad872e037157a08dd2bb3dcc6 | refs/heads/main | 2023-08-04T08:17:03.886448 | 2021-04-20T12:57:17 | 2021-04-20T12:58:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 199 | py | """Entry point."""
from app.app import Application
from app.views import MainPage
from app.models import Book
if __name__ == "__main__":
app = Application(MainPage(Book.list()))
app.run()
| [
"mbriolet.ma@gmail.com"
] | mbriolet.ma@gmail.com |
235c672831f5d93373e32f38e38f5655cf5ab225 | fd48fba90bb227017ac2da9786d59f9b9130aaf0 | /digsby/src/contacts/BuddyListElement.py | f33b3380035eee14ea46a75e7f98d16ccdad3ccf | [
"Python-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | niterain/digsby | bb05b959c66b957237be68cd8576e3a7c0f7c693 | 16a62c7df1018a49eaa8151c0f8b881c7e252949 | refs/heads/master | 2021-01-18T10:07:10.244382 | 2013-11-03T02:48:25 | 2013-11-03T02:48:25 | 5,991,568 | 1 | 0 | null | 2013-11-03T02:48:26 | 2012-09-28T02:24:50 | Python | UTF-8 | Python | false | false | 630 | py | from util.primitives.funcs import isiterable
from common.actions import ActionMeta
class BuddyListElement(object):
__metaclass__ = ActionMeta
@property
def num_online(self):
from Contact import Contact
if isiterable(self) and not isinstance(self, Contact):
return su... | [
"mdougherty@tagged.com"
] | mdougherty@tagged.com |
0a67f283ef42dca44daf76bbc4a66abe4d8c48dd | 951a84f6fafa763ba74dc0ad6847aaf90f76023c | /Solu86.py | e7e90402710c612a3e2d5f06db28be58e7c62afc | [] | no_license | SakuraGo/leetcodepython3 | 37258531f1994336151f8b5c8aec5139f1ba79f8 | 8cedddb997f4fb6048b53384ac014d933b6967ac | refs/heads/master | 2020-09-27T15:55:28.353433 | 2020-02-15T12:00:02 | 2020-02-15T12:00:02 | 226,550,406 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,225 | py | # # 86. 分隔链表
# 给定一个链表和一个特定值 x,对链表进行分隔,使得所有小于 x 的节点都在大于或等于 x 的节点之前。
#
# 你应当保留两个分区中每个节点的初始相对位置。
#
# 输入: head = 1->4->3->2->5->2, x = 3
# 输出: 1->2->2->4->3->5
# Definition for singly-linked list.
class ListNode:
def __init__(self, x):
self.val = x
self.next = None
class Solution:
def partition(s... | [
"452681917@qq.com"
] | 452681917@qq.com |
782ce93a0a256fec41cbd6777146f5c3cd2c5695 | b3586235dc1e1acbd49fab996f581269a808480b | /sistema/planeamento/migrations/0013_ordemproducao_num_paletes_stock_in.py | 1fcbb090362b7154911b2ca6ccc20eb7e102cd64 | [] | no_license | gonfersilva/Sistema | 37ad1cd03dfbb7889fa0b0367c6ebd9044712ae3 | 4c6d9ade22040972efbe892eae0130939d7b5c46 | refs/heads/master | 2021-10-23T23:21:51.262723 | 2021-10-13T19:45:49 | 2021-10-13T19:45:49 | 155,545,680 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 458 | py | # Generated by Django 2.2.7 on 2020-08-06 14:53
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('planeamento', '0012_auto_20200805_1401'),
]
operations = [
migrations.AddField(
model_name='ordemproducao',
name='nu... | [
"goncalo.silva@elastictek.com"
] | goncalo.silva@elastictek.com |
095c6844b796a1aa2773a69bc20447cb7d6c0cd5 | efe67da7ca1092e033fba7b0a251a43d9a165022 | /get_city_from_id/views.py | 5d69da18fd281507a348b06021c952f6c6f4bd2e | [] | no_license | poojapauskar/savmytime-api | 0a019077720ab9ec9bd113379e77f0f4c83ef887 | 2bb48d60fce24888c2d4e4ba3b1da8947242a1fd | refs/heads/master | 2021-01-21T13:29:41.086409 | 2016-05-09T06:38:54 | 2016-05-09T06:38:54 | 54,106,625 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,573 | py | from services.models import Services
from category.models import Category
from sub_category.models import Sub_category
from cities.models import Cities
from get_details.serializers import Get_detailsSerializer
from rest_framework import generics
# from ticket.permissions import IsOwnerOrReadOnly
# from rest_framework i... | [
"git.poojapauskar@gmail.com"
] | git.poojapauskar@gmail.com |
1b6e511387f944e0ce53157aa60363c6551647e9 | 2a4290c36832e7080faa4104d58083c29ed1ea09 | /prepro.py | 244c70dc13f9e7ef94ec033204e0662e264afae7 | [] | no_license | jerryli27/my_dtn | 0380e22fb7892f5d46084339a5edb24c8ed5b8c8 | 54b16f403a480c35d5ae331dbbfd0efed53880b9 | refs/heads/master | 2021-01-19T17:17:19.787195 | 2017-03-05T21:48:06 | 2017-03-05T21:48:06 | 82,433,878 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,292 | py | """
The cat face data comes from https://sites.google.com/site/catdatacollection/data
"""
import numpy as np
import pickle
from PIL import Image
from tensorflow.examples.tutorials.mnist import input_data
def resize_images(image_arrays, size=[32, 32]):
# convert float type to integer
image_arrays = (image_ar... | [
"jerrylijiaming@gmail.com"
] | jerrylijiaming@gmail.com |
d0ecd64d2fe16d6c50d3a51d49b2fca1bdfdb0cd | e70b6032024b290e2ba11fa5266ef912d9ac14a2 | /crits/comments/urls.py | bdb50ae5c327a6f98d12bcca1f9b041ce9ffffc0 | [
"MIT"
] | permissive | ckane/crits | 105b45c00b6ad85064b8e33ecd12e7474fc84fd6 | e2f2b71927d08e6432a0e540a0f4634da675ce53 | refs/heads/master | 2021-01-17T07:57:01.495393 | 2016-04-11T04:29:35 | 2016-04-11T04:29:35 | 20,622,493 | 2 | 0 | null | 2016-04-11T04:29:36 | 2014-06-08T17:45:07 | JavaScript | UTF-8 | Python | false | false | 558 | py | from django.conf.urls import patterns
urlpatterns = patterns('crits.comments.views',
(r'^remove/(?P<obj_id>\S+)/$', 'remove_comment'),
(r'^(?P<method>\S+)/(?P<obj_type>\S+)/(?P<obj_id>\S+)/$', 'add_update_comment'),
(r'^activity/$', 'activity'),
(r'^activity/(?P<atype>\S+)/(?P<value>\S+)/$', 'activity'... | [
"mgoffin@mitre.org"
] | mgoffin@mitre.org |
03d3d6b6062452e771dd0f53277a1ff0b3f6c1e9 | 1df7ba55c4b61772c1a31c503e6b8881f1456dc5 | /untitled9/apps/courses/migrations/0010_auto_20170209_1147.py | dfa9d9ea221e6a9ea9b645c7a86fa3dfcace7f37 | [] | no_license | fzk466569/python-django-pro | 35918756060fcae375d3c99ea1a6934949b6d605 | 9add086b7a910f255df5b192268f1e117057e053 | refs/heads/master | 2021-01-19T13:18:14.141880 | 2017-02-19T12:16:29 | 2017-02-19T12:16:29 | 82,374,668 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 545 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.9.8 on 2017-02-09 11:47
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('courses', '0009_auto_20170209_1146'),
]
operations = [
migrations.AlterField... | [
"fzk466569"
] | fzk466569 |
637c9052ec6cfa09517634c6b68099e9a6470ff8 | 7a8fcae483d18e87481443f4476d56b5180459e6 | /statemachine/registry.py | c1632ebc937664e2f22b410a9f4334a197abc83f | [
"MIT"
] | permissive | Gariagi/python-statemachine | 63c67696f57eeda75054df399999bfe7fb21c783 | 7dddc714752ef56dd9e54fe246c0050f40c0ad2d | refs/heads/develop | 2020-03-09T01:04:15.124145 | 2018-04-29T17:53:36 | 2018-04-29T17:53:36 | 128,504,334 | 0 | 0 | MIT | 2018-04-29T17:53:37 | 2018-04-07T06:56:05 | Python | UTF-8 | Python | false | false | 1,206 | py | # coding: utf-8
_REGISTRY = {}
_initialized = False
def register(cls):
_REGISTRY[cls.__name__] = cls
return cls
def get_machine_cls(name):
init_registry()
return _REGISTRY[name]
def init_registry():
global _initialized
if not _initialized:
load_modules(['statemachine', 'statemachi... | [
"fgmacedo@gmail.com"
] | fgmacedo@gmail.com |
14f178cebd12871b2e29d5b54a2c6d71d47622a4 | 3a1bae5b4a49c8f3050f37c3875a5a1dfd6f8316 | /bookzen_flask/bookzen.py | 7c91da763601eb07dd5749b3d1277ba732dc04ae | [] | no_license | meomap/bookzen | 9e86f5d3e63bfbd1e87fae41465115d27ebdd321 | e764dea45c7a5174b728d225ef2aaef3ed09bc9b | refs/heads/master | 2021-01-19T13:25:23.704102 | 2017-02-17T01:52:26 | 2017-02-17T01:52:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,555 | py | # -*- coding: iso-8859-15 -*-
import json
from email.header import Header
from email.mime.multipart import MIMEMultipart
from email.mime.text import MIMEText
from email.utils import formataddr
import smtplib
from flask import Flask, render_template, redirect, url_for
from flask_mongoengine import MongoEngine
from fla... | [
"tu0703@gmail.com"
] | tu0703@gmail.com |
0f260f1dbdd72e3b8c0677de922da98c7967e15b | bb7ebdd990d3265a585700e1083b3e916842aec6 | /scrapper/article.py | c5d9ffb192e8310d3615e63aaf29c76355f4090d | [] | no_license | c24b/clean_crawtext | 2c2a6d6292f5bb00afa45ebb28ba16bf2f0a229e | f1dc20298da418680b1b96dd0468846cbf09a112 | refs/heads/master | 2020-05-18T00:58:55.308025 | 2014-08-19T11:50:52 | 2014-08-19T11:50:52 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,889 | py | #!/usr/bin/env python
# -*- coding: UTF-8 -*-
from copy import deepcopy
from parsers import Parser
from cleaners import StandardDocumentCleaner
from formatters import StandardOutputFormatter
from extractors import StandardContentExtractor
import datetime
from BeautifulSoup import BeautifulSoup as bs
class Extractor(o... | [
"4barbes@gmail.com"
] | 4barbes@gmail.com |
61b4081b28ae6a8a0b66826389ed5b2bf8f6a8bd | 82b728e805d887102c0b8c415731b353877690cd | /samples/generated_samples/aiplatform_generated_aiplatform_v1_job_service_list_data_labeling_jobs_async.py | ff63ecabec79d5b44b37a6226ced8498752c4070 | [
"Apache-2.0"
] | permissive | geraint0923/python-aiplatform | 90c7742c9bdbde05b9688b117e8e59c0406d6f85 | 7ab05d5e127636d96365b7ea408974ccd6c2f0fe | refs/heads/main | 2023-08-24T05:30:38.519239 | 2021-10-27T20:38:25 | 2021-10-27T20:38:25 | 370,803,114 | 0 | 0 | Apache-2.0 | 2021-05-25T19:15:47 | 2021-05-25T19:15:46 | null | UTF-8 | Python | false | false | 1,627 | py | # -*- coding: utf-8 -*-
# Copyright 2020 Google LLC
#
# 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... | [
"noreply@github.com"
] | geraint0923.noreply@github.com |
90229bbbe4785a5b999ee5d8722e20f28827c56f | c05ed32f1ef7e1eb7d73efd674e7d1fd710ad171 | /daily-coding-problems/problem395.py | bf3a13cf875b08ed3da6182d02891d6d297eafa6 | [] | no_license | carlhinderer/python-exercises | c8367517fdf835fa1117f96dbfee3dccc596afa6 | 4e09bbb4c4e2bd5644ed50e997db9f3c289a18f7 | refs/heads/master | 2021-06-01T16:17:00.389134 | 2021-02-09T18:21:01 | 2021-02-09T18:21:01 | 150,902,917 | 0 | 0 | null | 2021-04-20T20:33:11 | 2018-09-29T21:03:36 | Python | UTF-8 | Python | false | false | 275 | py | # Problem 395
# Medium
# Asked by Robinhood
#
# Given an array of strings, group anagrams together.
#
# For example, given the following array:
#
# ['eat', 'ate', 'apt', 'pat', 'tea', 'now']
#
# Return:
#
# [['eat', 'ate', 'tea'],
# ['apt', 'pat'],
# ['now']]
# | [
"carl.hinderer4@gmail.com"
] | carl.hinderer4@gmail.com |
efec59e8370e4f56814a2820c890bc9dc2fff0bd | 659836ef3a9ac558538b016dbf4e128aa975ae7c | /backend/ingredient/migrations/0001_initial.py | 4f51e388822ee86c8a34ae068419dd993474fd70 | [] | no_license | zzerii/save_your_ingredients | fda1c769d158bca9dfd3c28ac9ff34ed7ae4e6a3 | 5ebde82255c1a6edf0c19d9032015d05c9d0abc9 | refs/heads/master | 2023-02-21T22:19:28.954594 | 2021-01-22T11:39:16 | 2021-01-22T11:39:16 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 610 | py | # Generated by Django 3.1.3 on 2020-11-13 05:52
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Ingredient',
fields=[
('id', models.AutoFie... | [
"jinsoo941010@naver.com"
] | jinsoo941010@naver.com |
c97da6f4cbe2fab9d85310007193f7f9c0e31396 | add74ecbd87c711f1e10898f87ffd31bb39cc5d6 | /xcp2k/classes/_guess_vectors1.py | dc797ddfb00b810b4621cc8d73f069c7cf32de02 | [] | no_license | superstar54/xcp2k | 82071e29613ccf58fc14e684154bb9392d00458b | e8afae2ccb4b777ddd3731fe99f451b56d416a83 | refs/heads/master | 2021-11-11T21:17:30.292500 | 2021-11-06T06:31:20 | 2021-11-06T06:31:20 | 62,589,715 | 8 | 2 | null | null | null | null | UTF-8 | Python | false | false | 688 | py | from xcp2k.inputsection import InputSection
from xcp2k.classes._each591 import _each591
class _guess_vectors1(InputSection):
def __init__(self):
InputSection.__init__(self)
self.Section_parameters = None
self.Add_last = None
self.Common_iteration_levels = None
self.Filename... | [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
65b28ee3513376fdfc19b0ce3e8b4f8543856013 | d737fa49e2a7af29bdbe5a892bce2bc7807a567c | /software/qt_examples/src/pyqt-official/webkit/formextractor/ui_formextractor.py | 518bb9cef3ef753de6499455d980501f40903ab0 | [
"GPL-3.0-only",
"MIT",
"CC-BY-NC-SA-4.0",
"GPL-1.0-or-later"
] | permissive | TG-Techie/CASPER | ec47dfbfd6c3a668739ff4d707572e0b853518b4 | 2575d3d35e7dbbd7f78110864e659e582c6f3c2e | refs/heads/master | 2020-12-19T12:43:53.825964 | 2020-01-23T17:24:04 | 2020-01-23T17:24:04 | 235,736,872 | 0 | 1 | MIT | 2020-01-23T17:09:19 | 2020-01-23T06:29:10 | Python | UTF-8 | Python | false | false | 4,813 | py | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'formextractor.ui'
#
# Created: Tue May 14 17:59:08 2013
# by: PyQt5 UI code generator 5.0-snapshot-b0831183bf83
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_Form(object):... | [
"TGTechie01@gmail.com"
] | TGTechie01@gmail.com |
a151f15578260c6246fa532d91a39e1ae25d102d | f7bc9ff51518d11d0d21249e57cdbd7277091e18 | /0x02-python-import_modules/2-args.py | 7ed9bebdf1babd5e74b51714354869b8faf4b092 | [] | no_license | veeteeran/holbertonschool-low_level_programming | 578fd521de625e47406b9141920a531c0483f042 | ff2f79942eb282ae485deda7d9598eda50723c3f | refs/heads/master | 2020-12-29T04:41:46.509414 | 2020-12-27T14:49:57 | 2020-12-27T14:49:57 | 238,458,078 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 379 | py | #!/usr/bin/python3
if __name__ == "__main__":
from sys import argv
length = len(argv)
if length == 1:
print("{:d} arguments.".format(length - 1))
elif length == 2:
print("{:d} argument:".format(length - 1))
else:
print("{:d} arguments:".format(length - 1))
for i in rang... | [
"vietnamtran@gmail.com"
] | vietnamtran@gmail.com |
6dd98b7831f5feee90d9df6b5301c0257eb2e665 | b972faf032590c9722dc240c45fc60157d5a1bee | /(구현)주사위네개.py | a7b250ef8517e21ed6b5335a12dac1288a5381af | [] | no_license | kih1024/codingStudy | 3a91b628bc301d1777d954595e93bf1f9246aca3 | 3e8a6fe86d3861613a85d3e75991f4bc7cd1e716 | refs/heads/master | 2022-12-09T04:58:55.264433 | 2020-09-22T07:29:44 | 2020-09-22T07:29:44 | 269,874,529 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 711 | py | # https://www.acmicpc.net/problem/2484
def dice():
li = sorted(list(map(int, input().split())))
temp = set(li)
if len(temp) == 1:
return li[0] * 5000 + 50000
elif len(temp) == 2 and li[1] == li[2]:
return li[1] * 1000 + 10000
elif len(temp) == 2 and li[1] != li[2]:
return (li... | [
"rladlsgh654@naver.com"
] | rladlsgh654@naver.com |
a8140ac64131df0e94f7c4b4e3daa8d4fbc87dbf | 6d60ac89ee9c14bfc62342f7b33da3932f4eb564 | /mini_build.py | 8b0881434026fcc7a4ba9e7ec6986b0b8a269d1d | [
"MIT"
] | permissive | samuelcolvin/donkey-simple-old | dda5b3c41387231b755965fa982bbb4c845e24c1 | 765810076c01d3677819e4f5a03aefd05300fbda | refs/heads/master | 2021-05-28T19:49:45.269978 | 2014-05-30T17:04:33 | 2014-05-30T17:04:33 | 14,808,774 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,039 | py | from DonkeySimple.DS.download import download_libraries
import os, re
lib_static_dir = os.path.join('DonkeySimple', 'WebInterface', 'static', 'libs')
libs_json_path = 'static_libraries.json'
try:
download_libraries(libs_json_path, lib_static_dir)
except Exception, e:
print 'ERROR: %s' % str(e)
print 'Probl... | [
"s@muelcolvin.com"
] | s@muelcolvin.com |
3b1d6dec03293efd9bdbed97ea34210432f2cbb3 | 228ebc9fb20f25dd3ed2a6959aac41fd31314e64 | /schema/predict/instance/google/cloud/aiplatform/v1beta1/schema/predict/instance_v1beta1/types/image_classification.py | aac9e2bc91fc75d16de26dfd01bb98512f260f25 | [
"Apache-2.0"
] | permissive | orionnye/python-aiplatform | 746e3df0c75025582af38223829faeb2656dc653 | e3ea683bf754832340853a15bdb0a0662500a70f | refs/heads/main | 2023-08-03T06:14:50.689185 | 2021-09-24T03:24:14 | 2021-09-24T03:24:14 | 410,091,957 | 1 | 0 | Apache-2.0 | 2021-09-24T20:21:01 | 2021-09-24T20:21:00 | null | UTF-8 | Python | false | false | 1,593 | py | # -*- coding: utf-8 -*-
# Copyright 2020 Google LLC
#
# 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... | [
"noreply@github.com"
] | orionnye.noreply@github.com |
93576199922965b76e6aae451eccce45bfffccf8 | 47175228ce25812549eb5203fc8b86b76fec6eb9 | /API_scripts/dfp/dfp_python3/v201408/custom_targeting_service/update_custom_targeting_values.py | ff879dd7d5d7d8f3c1653d851a0c2fe2b2a727d5 | [] | no_license | noelleli/documentation | c1efe9c2bdb169baa771e9c23d8f4e2683c2fe20 | a375698b4cf0776d52d3a9d3c17d20143bd252e1 | refs/heads/master | 2021-01-10T05:41:30.648343 | 2016-02-13T05:46:31 | 2016-02-13T05:46:31 | 51,477,460 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,604 | py | #!/usr/bin/python
#
# Copyright 2014 Google Inc. 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 b... | [
"noelle@makermedia.com"
] | noelle@makermedia.com |
4e68d6993b53a2ddd25f70df5669610a0df20cf0 | 952762035d7ffa7c46a2c7dc85063f08b1c4a975 | /2019/23/intcode.py | be46113b6662b2f5f65c6203efea2182ca7f225a | [] | no_license | pjot/advent-of-code | c8a59df25b3c1afa0e14fd22139b9ac3b789ff4d | 4b8b5c55c44dc8325caa2aeea7aa064a98738fd7 | refs/heads/master | 2023-03-10T20:22:44.724300 | 2023-03-04T21:01:02 | 2023-03-04T21:01:02 | 225,183,593 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,708 | py | def parse_file(filename):
with open(filename) as f:
code = f.readline()
ints = code.split(',')
program = [int(i) for i in ints]
return program
def parse_instruction(instruction):
full_instruction = '{:05d}'.format(instruction)
return (
instruction % 100,
int... | [
"peter.bergstrom@trioptima.com"
] | peter.bergstrom@trioptima.com |
3f263a2f1abc45d83649b00dfc604ebb900b4cbd | fa7deca280e1443d5ca79e9910f295a668be14b0 | /compile.py | bc770262d10363c06f9b6fdd5e15420b7d681620 | [
"Apache-2.0"
] | permissive | tomas-cliqz/ichnaea | e210ba419eb2a69553594e3dd4dba2c56c88753a | 1e49cc694b1e9c850417ac093e81849b1886b19e | refs/heads/master | 2021-01-12T20:00:27.455686 | 2016-01-27T14:00:22 | 2016-01-27T14:00:22 | 49,965,385 | 0 | 0 | null | 2016-01-19T16:17:23 | 2016-01-19T16:17:22 | null | UTF-8 | Python | false | false | 1,686 | py | """
This script is used as part of the "make release" command used as part of
building an rpm of this entire virtualenv.
The rpm building process compiles all *.py files found anywhere in the
source tree, independent of whether or not these would actually be used.
It finds some Python files which aren't meant for the ... | [
"hanno@hannosch.eu"
] | hanno@hannosch.eu |
f745deca3f8bab4ea141b85d67a953beab121496 | 025fa245d4cbffdaa422287ed2f31c4d0442ee28 | /orders/api/serializers.py | 15a4a1cf958d28696d037af645fde921fd646007 | [
"MIT"
] | permissive | elcolie/zero-to-deploy | 01f346ca50b8ccb271faef23934abe6a487baca6 | 6191a33ef55af7c550c0e529a4e373bfe40bc014 | refs/heads/master | 2022-02-08T23:22:17.008555 | 2018-06-15T19:39:06 | 2018-06-15T19:39:06 | 137,083,690 | 0 | 0 | MIT | 2022-01-21T19:35:33 | 2018-06-12T14:28:01 | Python | UTF-8 | Python | false | false | 1,228 | py | from rest_framework import serializers
from menus.models import Menu
from order_items.api.serializers import ShortItemSerializer
from order_items.models import OrderItem
from orders.models import Order
class OrderSerializer(serializers.ModelSerializer):
url = serializers.HyperlinkedIdentityField(view_name='api:o... | [
"sarit@elcolie.com"
] | sarit@elcolie.com |
33d9a5f14e08e91b0a36cea7796270daf9f6d3fc | 71f19c14de97846193972830fbc9a4ec972d0ca9 | /website/management/commands/tweet_something.py | 9c69a942adf0593825c1b90f2c1043deb803ba42 | [] | no_license | wbt/govtrack.us-web | 87790050aaba83ca6cca16e26ec796603317e7da | c94c0dfdc809ad506a54108802a2328cc26ca97d | refs/heads/master | 2021-01-25T06:25:24.943845 | 2017-07-26T13:55:01 | 2017-07-26T13:55:01 | 93,572,164 | 0 | 0 | null | 2017-09-24T03:54:30 | 2017-06-06T23:15:59 | Python | UTF-8 | Python | false | false | 7,400 | py | #;encoding=utf8
from django.db.models import F
from django.core.management.base import BaseCommand, CommandError
from django.conf import settings
from django.utils import timezone
from django.template.defaultfilters import truncatechars
from collections import defaultdict
import json, os, sys
from datetime import time... | [
"jt@occams.info"
] | jt@occams.info |
4a34314cf3ab3799f0e9db22f7bf9934c45a1f33 | d0ff9af885dc01de43ae7bdd2d26d6370c7b7ab5 | /unsup_vvs/neural_fit/brainscore_mask/compute_rdms_from_activations.py | 6d62b4160899f47a41da16e2251033e1f396d3d0 | [] | no_license | augix/unsup_vvs | a09f89c7d002006f59ffbe223c9469e959949e04 | 168ed0d068d27b7a7ca1dd5c1ebc28fbe84f8c7c | refs/heads/master | 2023-07-17T05:55:27.630844 | 2021-06-24T01:27:28 | 2021-06-24T01:27:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,860 | py | import pickle
import argparse
import os
import sys
import pdb
from tqdm import tqdm
import numpy as np
RESULT_CACHING_DIR = '/mnt/fs4/chengxuz/v4it_temp_results/.result_caching'
DEFAULT_SAVE_DIR = os.path.join(RESULT_CACHING_DIR, 'computed_rdms')
ACTIVATION_DIR = os.path.join(
RESULT_CACHING_DIR,
'model... | [
"chengxuz@node07-ccncluster.stanford.edu"
] | chengxuz@node07-ccncluster.stanford.edu |
8a31fb2658e068c346166523f70684bc6035c3fc | 410f0d66049ca881dfdeb9b7f784bd70b1c3f6e7 | /bootea/bootea/pipelines.py | 1bcd7524443c973b2ed7217b2a7ddcccda6d3f42 | [] | no_license | ans2human/Scrappers | 1bdf5a1a4a34752c58fb18d45ac01e3cb54b5fe1 | cb2183d25a8af08284f2a6c1311b8da24c720b96 | refs/heads/master | 2020-03-19T20:41:01.244911 | 2018-06-11T11:27:17 | 2018-06-11T11:27:17 | 136,911,832 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,934 | py | from scrapy import log
from twisted.enterprise import adbapi
import time
import sys; sys.path.append("/users/user/appdata/local/programs/python/python36-32/lib/site-packages")
import MySQLdb.cursors
from bootea.items import test
class MySQLStorePipeline(object):
def __init__(self):
print ('init')
s... | [
"ans2human@gmail.com"
] | ans2human@gmail.com |
ecbbe380ee06e59502cd568e0d8911e8ee387e8b | ef72a7df3c39c215dd90ac5e72b164eb9d7da892 | /rpg/heroes/exp.py | 8580678d1bd1cda8e1e24f9779c8fce251493dcc | [] | no_license | thebmo/messing_around | d49a87fc1ff722428ea67bc710ca99ad287098bd | 4cb12e0b224cf7d1f93cb4ae6ff7603619fb7aa9 | refs/heads/master | 2021-01-13T02:18:50.799898 | 2015-04-08T01:12:41 | 2015-04-08T01:12:41 | 28,570,375 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,220 | py | exp_to_next_level = [
0,
29,
87,
174,
304,
499,
792,
1232,
1891,
2880,
4364,
6218,
8534,
11428,
15045,
19114,
23690,
28837,
34627,
41141,
48468,
56711,
65983,
76413,
88147,
101347,
116196,
132901,
151694,... | [
"bmosier@gmail.com"
] | bmosier@gmail.com |
3c415b6254a6a1dfd67e5c564bbeeab602bbbac5 | c3432a248c8a7a43425c0fe1691557c0936ab380 | /Greedy/1744_수묶기*.py | cb76fdcd5d14a3364ec30819632212850e7c8292 | [] | no_license | Parkyunhwan/BaekJoon | 13cb3af1f45212d7c418ecc4b927f42615b14a74 | 9a882c568f991c9fed3df45277f091626fcc2c94 | refs/heads/master | 2022-12-24T21:47:47.052967 | 2022-12-20T16:16:59 | 2022-12-20T16:16:59 | 232,264,447 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 670 | py | import heapq
n = int(input())
sm = 0
plus = []
minus = []
zero = 0
one = 0
for _ in range(n):
val = int(input())
if val == 1:
one += 1
elif val > 0:
heapq.heappush(plus, -val)
elif val == 0:
zero += 1
else:
heapq.heappush(minus, val)
if len(plus) % 2:
heapq.hea... | [
"pyh8618@gmail.com"
] | pyh8618@gmail.com |
3042f2d03444d4ec8ed65c9bcad199f8c3f11f73 | 163bbb4e0920dedd5941e3edfb2d8706ba75627d | /Code/CodeRecords/2536/60761/235389.py | 3dece7a79508610db4ccd9b65cff8208cc2b29f7 | [] | no_license | AdamZhouSE/pythonHomework | a25c120b03a158d60aaa9fdc5fb203b1bb377a19 | ffc5606817a666aa6241cfab27364326f5c066ff | refs/heads/master | 2022-11-24T08:05:22.122011 | 2020-07-28T16:21:24 | 2020-07-28T16:21:24 | 259,576,640 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 412 | py | airlines=input("")
airlines=list(map(str,airlines[2:-2].split("],[")))
result=[]
result.append("JFK")
i=0
while(0<len(airlines)):
destination=[]
for airline in airlines:
if(airline.startswith('"'+result[i])):
destination.append(airline[7:-1])
destination.sort()
airlines.remove('"'+re... | [
"1069583789@qq.com"
] | 1069583789@qq.com |
047f80690a5099e9f1505b2dd7da347d7bd2adc1 | 04ae1836b9bc9d73d244f91b8f7fbf1bbc58ff29 | /378/Solution.py | 2933a83513c07b54670ecbf4838330642d1675d9 | [] | no_license | zhangruochi/leetcode | 6f739fde222c298bae1c68236d980bd29c33b1c6 | cefa2f08667de4d2973274de3ff29a31a7d25eda | refs/heads/master | 2022-07-16T23:40:20.458105 | 2022-06-02T18:25:35 | 2022-06-02T18:25:35 | 78,989,941 | 14 | 6 | null | null | null | null | UTF-8 | Python | false | false | 2,165 | py | """
Given a n x n matrix where each of the rows and columns are sorted in ascending order, find the kth smallest element in the matrix.
Note that it is the kth smallest element in the sorted order, not the kth distinct element.
Example:
matrix = [
[ 1, 5, 9],
[10, 11, 13],
[12, 13, 15]
],
k = 8,
return 1... | [
"zrc720@gmail.com"
] | zrc720@gmail.com |
cabf56396409a2b8bbe2bba525dd0a4347f411d5 | 4af8e73d47535494a25e06d5ac693fdc60fc95f5 | /NLP_pytorch/04_pytorch_ignite/main.py | 3c143464dd83f6b08e51033562e87b446747ba97 | [] | no_license | woosa7/nbcc_projects | 4de2f846068bacdc73a6877d26dba93c483b1be3 | 0e7a30f58e554125d02451ab407f2a19c8c7b5f4 | refs/heads/main | 2023-06-16T16:19:51.975216 | 2021-07-16T05:18:53 | 2021-07-16T05:18:53 | 306,594,548 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,390 | py | import argparse
import torch
import torch.nn as nn
import torch.optim as optim
from model import ImageClassifier
from trainer import Trainer
from data_loader import get_loaders
def define_argparser():
p = argparse.ArgumentParser()
p.add_argument('--model_fn', required=True)
p.add_argument('--gpu_id', ty... | [
"woosa7@gmail.com"
] | woosa7@gmail.com |
71a26a87ecee866c893700324d40a1a2572e4a99 | 6eb58e32b469c37428185ab4456184905a5b4fb5 | /analysis_code/parse_ICD.py | c9e4102115862dbdf62d0a5bc4cdcd1bf75b3e03 | [] | no_license | rchenmit/mht_analysis | 0b8bfff7730df835975c7c41d65f007ad269e3a9 | 678d4419bdaed9ed9d0041df3a2cd8638074590f | refs/heads/master | 2020-04-06T03:40:41.577209 | 2015-01-12T00:14:48 | 2015-01-12T00:14:48 | 19,548,658 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,113 | py | ## Robert Chen
## Monday 5/12/2014
##
## read and process BMI file
##
##
import datetime as dt
import scipy as s
## options
input_folder = '../../data/new_data_20140416/Data_20140409/'
output_dir = '../../data/new_data_20140416/Data_curated_RC/'
pickle_dir = '../analysis_output/pickle/'
bool_make_count_matrix_ALL = 0... | [
"robchen401@gmail.com"
] | robchen401@gmail.com |
581ff3c3ff8eac75bf2c32be001fe3da752ff030 | 87bbeac699af7fa4dc76592acecef52dead1f436 | /Adelphi Academic Calendar/skill/skill_env/Lib/site-packages/docutils/parsers/rst/languages/it.py | ad6085c6d6d78353bca04e8d50786cae5b9e5628 | [
"MIT",
"OpenSSL",
"bzip2-1.0.6",
"LicenseRef-scancode-warranty-disclaimer",
"LicenseRef-scancode-proprietary-license",
"Python-2.0",
"TCL",
"LicenseRef-scancode-newlib-historical"
] | permissive | EnriqueGambra/Amazon-Alexa-Skill | 79ec8848605a0e1e13092a1f6163dd63573322ec | 198ed51bef555eee006041fef0bcbf5c955142d5 | refs/heads/master | 2022-12-02T01:01:48.419524 | 2019-10-23T21:45:49 | 2019-10-23T21:45:49 | 214,226,014 | 0 | 2 | MIT | 2022-11-27T06:15:00 | 2019-10-10T15:58:16 | Python | UTF-8 | Python | false | false | 3,267 | py | # $Id: it.py 7119 2011-09-02 13:00:23Z milde $
# Authors: Nicola Larosa <docutils@tekNico.net>;
# Lele Gaifax <lele@seldati.it>
# Copyright: This module has been placed in the public domain.
# Beware: the italian translation of the reStructuredText documentation
# at http://docit.bice.dyndns.org/static/ReST, ... | [
"gambra7@gmail.com"
] | gambra7@gmail.com |
3ec541908b733c963a38d71f7f5949c8f8a7327d | 465efab6e7b419d4493d09786a4b2d7a976f7a31 | /src/Universe/LevelProps/Decorator.py | d036547a63ad9d0c74b8c3f991b1315b75e5aedb | [] | no_license | dzz/kthuune | aa2cadcdfaed9a06b6384516be429575640a7896 | 2a8be25ec5303586e5a7e067c024d6e6ca171efa | refs/heads/master | 2021-01-24T07:42:41.426973 | 2018-07-29T06:21:34 | 2018-07-29T06:21:34 | 93,354,629 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,089 | py | from Newfoundland.Object import Object
from Beagle import API as BGL
class Decorator(Object):
textures = BGL.assets.get('KT-forest/animation/decorators')
def parse(od,df):
x1 = float(od["x"])
y1 = float(od["y"])
x2 = float(od["w"])
y2 = float(od["h"])
cx = (x1+x2) / ... | [
"devon.zachary@gmail.com"
] | devon.zachary@gmail.com |
c618214707b9fb6a6ca9236d529434d841c267c9 | 50afc0db7ccfc6c80e1d3877fc61fb67a2ba6eb7 | /challenge17(backOnTime)/solutions/FelipeAg.py | 87790a5c157315c30659f1835cb2ca4e79b5036b | [
"MIT"
] | permissive | banana-galaxy/challenges | 792caa05e7b8aa10aad8e04369fc06aaf05ff398 | 8655c14828607535a677e2bb18689681ee6312fa | refs/heads/master | 2022-12-26T23:58:12.660152 | 2020-10-06T13:38:04 | 2020-10-06T13:38:04 | 268,851,516 | 11 | 8 | MIT | 2020-09-22T21:21:30 | 2020-06-02T16:24:41 | Python | UTF-8 | Python | false | false | 190 | py | def solution(steps):
if len(steps) > 10:
return False
elif steps.count('n') == steps.count('s') and steps.count('e') == steps.count('w'):
return True
return False | [
"cawasp@gmail.com"
] | cawasp@gmail.com |
5b2207888d5917f774beaa8e83fa97856d693717 | f6c69a7f7f1bbae5fd5473dfaac5ef5fad840d58 | /lib/datatools/dataclass/datacatalog.py | 61a0c4aa163e163193588df29a4266dfac7aa5a3 | [
"Apache-2.0"
] | permissive | JokerWDL/PyAnomaly | 8c5ca4ca705a1251c70ff1f36c908c8f6f75e7d8 | cf93437e5d7ae87fa916141cf4b5cc2e929b8199 | refs/heads/master | 2022-11-05T11:31:42.345422 | 2020-06-22T17:21:20 | 2020-06-22T17:21:20 | 274,295,638 | 1 | 0 | Apache-2.0 | 2020-06-23T03:04:32 | 2020-06-23T03:04:31 | null | UTF-8 | Python | false | false | 2,336 | py | '''
Refer to the detectron2's DatasetCatalog
'''
from typing import List
class DatasetCatalog(object):
"""
A catalog that stores information about the datasets and how to obtain them.
It contains a mapping from strings
(which are names that identify a dataset, e.g. "coco_2014_train")
to a f... | [
"446358161@qq.com"
] | 446358161@qq.com |
b5ead447cfefeb3618026a45f0fd21cea7995513 | 73a0f661f1423d63e86489d4b2673f0103698aab | /python/oneflow/test/expensive/_internally_replaced_utils.py | 8276fa0ab10c37bd4effe408fa3f5694ab102d26 | [
"Apache-2.0"
] | permissive | Oneflow-Inc/oneflow | 4fc3e081e45db0242a465c4330d8bcc8b21ee924 | 0aab78ea24d4b1c784c30c57d33ec69fe5605e4a | refs/heads/master | 2023-08-25T16:58:30.576596 | 2023-08-22T14:15:46 | 2023-08-22T14:15:46 | 81,634,683 | 5,495 | 786 | Apache-2.0 | 2023-09-14T09:44:31 | 2017-02-11T06:09:53 | C++ | UTF-8 | Python | false | false | 2,197 | py | """
Copyright 2020 The OneFlow 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 applicable law or agr... | [
"noreply@github.com"
] | Oneflow-Inc.noreply@github.com |
f9f83f196d52a47793819cfbd6af460d5fdce595 | 90c6262664d013d47e9a3a9194aa7a366d1cabc4 | /tests/storage/cases/test_KT1UCoFzRwpQhRg9BWz2QMNwzTud56fCdjSP_babylon.py | f8d8b822bf224b7b14e0e62f9d3dfc07c4a33180 | [
"MIT"
] | permissive | tqtezos/pytezos | 3942fdab7aa7851e9ea81350fa360180229ec082 | a4ac0b022d35d4c9f3062609d8ce09d584b5faa8 | refs/heads/master | 2021-07-10T12:24:24.069256 | 2020-04-04T12:46:24 | 2020-04-04T12:46:24 | 227,664,211 | 1 | 0 | MIT | 2020-12-30T16:44:56 | 2019-12-12T17:47:53 | Python | UTF-8 | Python | false | false | 1,170 | py | from unittest import TestCase
from tests import get_data
from pytezos.michelson.converter import build_schema, decode_micheline, encode_micheline, micheline_to_michelson
class StorageTestKT1UCoFzRwpQhRg9BWz2QMNwzTud56fCdjSP_babylon(TestCase):
@classmethod
def setUpClass(cls):
cls.maxDiff = None
... | [
"mz@baking-bad.org"
] | mz@baking-bad.org |
c5ff1437f0d351d49af69153cb81a3ca68b48a2c | f4475acdf01fa80ae3a638c19df30773cfd379dc | /listenclosely/admin.py | b7740fd874d120412af39807149d22c7247f7d97 | [
"BSD-3-Clause"
] | permissive | jlmadurga/listenclosely | ea48e7ea05f971ca4fc979f5f52d5a07ec74dcbb | d6df9110c3ed6fd337e0236cccbe4d931bf217b0 | refs/heads/master | 2023-01-07T13:27:30.024214 | 2016-03-12T12:40:29 | 2016-03-12T12:40:29 | 49,677,476 | 7 | 3 | BSD-3-Clause | 2022-12-26T20:23:37 | 2016-01-14T21:49:08 | Python | UTF-8 | Python | false | false | 203 | py | from django.contrib import admin
from listenclosely.models import Message, Chat, Agent, Asker
admin.site.register(Message)
admin.site.register(Chat)
admin.site.register(Agent)
admin.site.register(Asker) | [
"jlmadurga@gmail.com"
] | jlmadurga@gmail.com |
c383989311b6a33537436038b4dedd0a24e43d79 | 658773cf775fd97c3cec3aca5f559500dec021bc | /controllers/asset.py | c93abf8e08e4c373f5688d022a96348e5dd4d844 | [
"MIT"
] | permissive | smeissner/ifrc | f3795474219d20fba5c68192f5d9b90006288e3e | 505eb6ffbb8fc32fdbbe63fdab4c19d87e53ca86 | refs/heads/master | 2021-01-18T10:43:55.847965 | 2012-10-07T22:43:15 | 2012-10-07T22:43:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,079 | py | # -*- coding: utf-8 -*-
"""
Asset Management Functionality
http://eden.sahanafoundation.org/wiki/BluePrint/Assets
"""
module = request.controller
resourcename = request.function
if not settings.has_module(module):
raise HTTP(404, body="Module disabled: %s" % module)
# ----------------------------------... | [
"fran@aidiq.com"
] | fran@aidiq.com |
f7cb7a5de948cd36e56b54eee4c79406be49b77a | dffd7156da8b71f4a743ec77d05c8ba031988508 | /ac/abc109/abc109_b/11416688.py | a108bbb8ac35b9102f2c74dfe3e7b4513b27c333 | [] | no_license | e1810/kyopro | a3a9a2ee63bc178dfa110788745a208dead37da6 | 15cf27d9ecc70cf6d82212ca0c788e327371b2dd | refs/heads/master | 2021-11-10T16:53:23.246374 | 2021-02-06T16:29:09 | 2021-10-31T06:20:50 | 252,388,049 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 211 | py |
st = set()
cant = False
prev = "-"
for i in range(int(input())):
s = input()
if (prev!="-" and prev!=s[0]) or s in st: cant = True
prev = s[-1]
st.add(s)
print("YNeos"[cant::2])
| [
"v.iceele1810@gmail.com"
] | v.iceele1810@gmail.com |
72a7cb385ba562e3c44eeb5951a6ad27b05b8072 | 992f6a7436a9755d13bfbf0e3e0d98daa7541f1a | /coresite/views.py | 3956a3f993453816a94d377858f59f39293cc9de | [
"MIT"
] | permissive | Klim314/argent_app | 838c3f6b2d15666670ea1e90ac0c23bdc0df50aa | 767a0a11646fc08fb7197a191348466c913fe360 | refs/heads/master | 2021-01-22T05:32:44.626421 | 2017-09-17T15:23:54 | 2017-09-17T15:23:54 | 102,282,161 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,300 | py | from django.shortcuts import render, reverse, HttpResponseRedirect, HttpResponse
from django.views import View
from argent_app.models import Room, InRoom
from django.contrib.auth import authenticate, login
from django.contrib.auth.decorators import login_required
from django.contrib.auth.models import User
from django.... | [
"klim314@gmail.com"
] | klim314@gmail.com |
4fe09e4033ab5248274e1eb4eca7d375acc4598d | b1ba5707a5cbe918d33bc2082b3eb4ff1378c060 | /SDPython/tests/test_sd/test_package.py | 21b1b208b6690f20449ad6c4d37e68781b3b36f3 | [] | no_license | qq781217732/SubstanceDev | 2eb1d9ed48d477cf70c7bfdac2103bb884e9204c | b9ffab0a1b8f3c01783259074940b2712a8142b8 | refs/heads/master | 2023-03-26T00:43:35.047305 | 2021-03-01T04:12:28 | 2021-03-01T04:12:28 | 342,539,111 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,105 | py | # ADOBE CONFIDENTIAL
#
# Copyright 2019 Adobe
# All Rights Reserved.
#
# NOTICE: Adobe permits you to use, modify, and distribute this file in
# accordance with the terms of the Adobe license agreement accompanying it.
# If you have received this file from a source other than Adobe,
# then your use, modification, or d... | [
"gaoyuyang@senseinn.com"
] | gaoyuyang@senseinn.com |
cc25b49cba139ab957706257cc9e9cdd5119b7a6 | 382c8cfb29f420297462d122c571995b62e10a6b | /temp.py | ab5d445e6bd49d2df01744e32851e61b3e05f170 | [] | no_license | innovation-labs/Vader | c1a9592cc02f85cc5a28b3116fc41b35df5baf04 | aa9091f90c41fe2b1ae6e488670bf89bcbbde5c9 | refs/heads/master | 2021-08-23T21:18:46.609875 | 2017-12-06T15:50:56 | 2017-12-06T15:50:56 | 103,031,449 | 0 | 0 | null | 2017-09-10T13:28:51 | 2017-09-10T13:28:50 | null | UTF-8 | Python | false | false | 1,914 | py | #
from django.conf import settings
from geoip2 import database
from geoip2.errors import AddressNotFoundError
from apps.warehouse.models import IPStore
reader = database.Reader(settings.MAXMIND_CITY_DB)
ips = ['99.248.9.54',
'173.34.75.225',
'70.54.130.204',
'67.58.222.87',
'70.55.50.230'... | [
"yousuf.jawwad@gmail.com"
] | yousuf.jawwad@gmail.com |
1bff2ac0967e16eaba266de1b1749c487521c995 | 08778088da558a8bc79326754bb86f61c4cf082b | /eisitirio/database/waiting.py | 5d06fb161572f0a5a5f73faf4ed6d38b4a5a6dad | [] | no_license | toastwaffle/Eisitirio | b5a7c48fc015857bfccdbe3f702e4c12c2e8277c | 64ff15704b6b62d6ed385f7add59e7face88a95c | refs/heads/master | 2020-05-24T15:51:12.023834 | 2019-09-12T19:09:23 | 2019-09-12T19:09:23 | 187,341,863 | 0 | 0 | null | 2019-05-18T09:59:35 | 2019-05-18T09:59:35 | null | UTF-8 | Python | false | false | 954 | py | # coding: utf-8
"""Database model for entries on the waiting list."""
from __future__ import unicode_literals
import datetime
from eisitirio.database import db
DB = db.DB
class Waiting(DB.Model):
"""Model for entries on the waiting list."""
__tablename__ = "waiting"
waiting_since = DB.Column(DB.Date... | [
"samuel.littley@toastwaffle.com"
] | samuel.littley@toastwaffle.com |
7aba7f32ed96c5e577fdeed1ddb2f5bf167c0d91 | 0d32e3819606c3fb6820d0cd5f5097db3b0d3dd4 | /HW3/q_learning_no_epsilon_decay_mountain_car.py | 6afd1f1d11cfe24eb60909d28e8ea03a2aa4b912 | [] | no_license | IanCBrown/COMP5600 | e8e06b2a8e3bde0acc6897adb2396a57a2811f0a | ef454c009d6fd5eec50ceec5a8283a7c6d81d097 | refs/heads/master | 2020-08-02T13:20:41.024681 | 2019-12-09T03:53:37 | 2019-12-09T03:53:37 | 211,366,293 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 6,059 | py | import math
import numpy as np
import matplotlib
matplotlib.use("TkAgg")
from matplotlib import pyplot as plt
import gym
from gym import spaces
from gym.utils import seeding
# Resources:
# https://en.wikipedia.org/wiki/Mountain_car_problem
# https://towardsdatascience.com/getting-started-with-reinforcement-learning-... | [
"icb0004@auburn.edu"
] | icb0004@auburn.edu |
04495c8e1849b8df9b7b60f749e3172809966b93 | 7e419f7046386c20b9a6ed121c377fbcc8ff6885 | /mobject/region.py | d5ba70ff04615c627dc85bf3d0a85a9d4bddec0d | [] | no_license | ralusek/manim | 47ebabb4d42accdda42a0da32ccdef6b129205b8 | d53412d738e3b9d306b7d7d2ad39cac702ff3d18 | refs/heads/master | 2021-04-29T00:47:40.990006 | 2018-02-16T20:16:59 | 2018-02-16T20:16:59 | 121,837,012 | 1 | 0 | null | 2018-02-17T07:44:48 | 2018-02-17T07:44:47 | null | UTF-8 | Python | false | false | 3,206 | py | import numpy as np
import itertools as it
from PIL import Image
from copy import deepcopy
from mobject import Mobject
from helpers import *
#TODO, this whole class should be something vectorized.
class Region(Mobject):
CONFIG = {
"display_mode" : "region"
}
def __init__(self, condition = (lambda ... | [
"grantsanderson7@gmail.com"
] | grantsanderson7@gmail.com |
3d44285b7f4667f8c29bbb1bf7a019e76508ecb4 | 61673ab9a42f7151de7337608c442fa6247f13bb | /pillow/change-pixels-numpy-array-PixelAccess/main-PixelAccess.py | 753aed3b65ccfc089b9e2661eb5527fc4b576b6e | [
"MIT"
] | permissive | furas/python-examples | 22d101670ecd667a29376d7c7d7d86f8ec71f6cf | 95cb53b664f312e0830f010c0c96be94d4a4db90 | refs/heads/master | 2022-08-23T23:55:08.313936 | 2022-08-01T14:48:33 | 2022-08-01T14:48:33 | 45,575,296 | 176 | 91 | MIT | 2021-02-17T23:33:37 | 2015-11-04T23:54:32 | Python | UTF-8 | Python | false | false | 449 | py | #!/usr/bin/env python3
# date: 2019.09.29
# `PixelAccess` changes pixels in original `img`
# so there is no need to convert it back to `Image`
# BTW: Image uses [col,row] (array uses [row,col])
from PIL import Image
img = Image.open('image.jpg')
pixels = img.load()
width, height = img.size
for col in range(widt... | [
"furas@tlen.pl"
] | furas@tlen.pl |
8af072ca10d2818422727df5fbd11c71012690ef | 5da80918ac50156f351966f96e2131123222d483 | /hack/coalesce.py | ddb07665af6933731c1eef0253ccadbd9605a08e | [
"Apache-2.0"
] | permissive | dinomiteX/cluster-api-provider-aws | 43045e2c2d1836f1722795e5d4afeef2a3b407ea | bc4496ff9235a64f81dd9e6f2c97e368b6099431 | refs/heads/master | 2020-07-07T14:50:26.244166 | 2019-08-20T13:37:01 | 2019-08-20T13:37:01 | 203,380,287 | 0 | 0 | Apache-2.0 | 2019-08-20T13:18:24 | 2019-08-20T13:18:23 | null | UTF-8 | Python | false | false | 3,191 | py | #!/usr/bin/env python
# Copyright 2016 The Kubernetes Authors.
#
# 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 appli... | [
"k8s-ci-robot@users.noreply.github.com"
] | k8s-ci-robot@users.noreply.github.com |
92785644c971f51c1aff7d47c833a14c473328a3 | dea5dfdc661309fa26fc93d4884fbcbb75e4d8a0 | /Back_ground/control/classcontrol.py | be904879e1ec0441ee72a9fc24b89447004fa001 | [
"Apache-2.0"
] | permissive | sherwel/Behavior_culture | 0583ba061d7a2feba8f45c2b574005fcc76e4cfd | 43b68e50aed369aacefc5435ec4f9b70960d2344 | refs/heads/master | 2021-01-10T03:47:20.328109 | 2016-02-29T04:42:49 | 2016-02-29T04:42:49 | 50,472,281 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 7,199 | py | #!/usr/bin/python
#coding:utf-8
from tool import SQLTool ,config
from Back_ground.model import takeclass,Class
limitpage=15
localconfig=config.Config()
def haveclassshow(schoolid='',classid='',teacherid='',page='0'):
validresult=False
request_params=[]
values_params=[]
if schoolid!='':
reque... | [
"nanshihui@qq.com"
] | nanshihui@qq.com |
56922e0d19840031cf2fd989884a3f68c517958f | 28c0bcb13917a277cc6c8f0a34e3bb40e992d9d4 | /koku/api/resource_types/azure_regions/view.py | 903367bda356e2193783aa57648a5dc9d0784689 | [
"Apache-2.0"
] | permissive | luisfdez/koku | 43a765f6ba96c2d3b2deda345573e1d97992e22f | 2979f03fbdd1c20c3abc365a963a1282b426f321 | refs/heads/main | 2023-06-22T13:19:34.119984 | 2021-07-20T12:01:35 | 2021-07-20T12:01:35 | 387,807,027 | 0 | 1 | Apache-2.0 | 2021-07-20T13:50:15 | 2021-07-20T13:50:14 | null | UTF-8 | Python | false | false | 2,126 | py | #
# Copyright 2021 Red Hat Inc.
# SPDX-License-Identifier: Apache-2.0
#
"""View for Azure Region locations."""
from django.db.models import F
from django.utils.decorators import method_decorator
from django.views.decorators.vary import vary_on_headers
from rest_framework import filters
from rest_framework import generi... | [
"noreply@github.com"
] | luisfdez.noreply@github.com |
ef24ba60db7198ba0b519cb7a3e69990ba8cea61 | 87bb2b9258c887e8fbcaca08d18e5d95ae96462d | /Codewars/Python/6kyu/6kyu_Sort the odd.py | 8cedc8b089fe3134f4a5c46a38957c62ca3278d3 | [] | no_license | KonradMarzec1991/Codewars-LeetCode | a9e4d09f4271fecb3a7fc1ee436358ac1bbec5e4 | 442113532158f5a3ee7051a42e911afa5373bb5f | refs/heads/master | 2023-04-21T17:04:37.434876 | 2021-05-11T21:47:14 | 2021-05-11T21:47:14 | 166,555,499 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 298 | py | def sort_array(source_array):
sorted_odds = sorted([d for d in source_array if d % 2 == 1])
startpoint = 0
for d in range(len(source_array)):
if source_array[d] % 2 == 1:
source_array[d] = sorted_odds[startpoint]
startpoint += 1
return source_array
| [
"konrimarzec@gmail.com"
] | konrimarzec@gmail.com |
82519a5e2771413edc95e5dee8e2e066d793d518 | e838076bc1c8aedbb8c77710b1a1a32efc3a4da1 | /pc1/models.py | 1e61f611c4a5dbf401dcd01d926e4bc857bb4b2f | [] | no_license | abbasgis/ferrp | 5f2f7768f0e38e299498c2e74379311698b6321f | 77736c33e7ec82b6adf247a1bf30ccbc4897f02e | refs/heads/master | 2023-05-25T09:59:45.185025 | 2021-06-12T09:15:07 | 2021-06-12T09:15:07 | 376,236,936 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,549 | py | from django.db import models
# Create your models here.
class AdpDraft201718Vw(models.Model):
gs_no = models.TextField(primary_key=True) # This field type is a guess.
s_name = models.TextField(blank=True, null=True) # This field type is a guess.
district = models.TextField(blank=True, null=True) # Thi... | [
"abbas123@abc"
] | abbas123@abc |
ef1c013cd55b95725b787557e86769b4fd758760 | e3c8f786d09e311d6ea1cab50edde040bf1ea988 | /Incident-Response/Tools/cyphon/cyphon/alerts/migrations/0011_auto_20170815_1432.py | 83a21b67e06bc5f594c3731289b36f09f4baa58f | [
"LicenseRef-scancode-proprietary-license",
"GPL-3.0-only",
"LicenseRef-scancode-unknown-license-reference",
"GPL-1.0-or-later",
"LicenseRef-scancode-warranty-disclaimer",
"LicenseRef-scancode-other-copyleft",
"MIT"
] | permissive | foss2cyber/Incident-Playbook | d1add8aec6e28a19e515754c6ce2e524d67f368e | a379a134c0c5af14df4ed2afa066c1626506b754 | refs/heads/main | 2023-06-07T09:16:27.876561 | 2021-07-07T03:48:54 | 2021-07-07T03:48:54 | 384,988,036 | 1 | 0 | MIT | 2021-07-11T15:45:31 | 2021-07-11T15:45:31 | null | UTF-8 | Python | false | false | 621 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.2 on 2017-08-15 18:32
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('alerts', '0010_remove_alert_tags'),
]
operations =... | [
"a.songer@protonmail.com"
] | a.songer@protonmail.com |
1d9066b6f8c175153341870908a2697e4398d8bf | e0df2bc703d0d02423ea68cf0b8c8f8d22d5c163 | /ScientificComputing/ch14/filter_equalizer.py | 8d3830bd050cd0f33b823f8ec982a021af94ccdc | [] | no_license | socrates77-sh/learn | a5d459cb9847ba3b1bc4f9284ce35d4207d8aa8b | ae50978023f6b098b168b8cca82fba263af444aa | refs/heads/master | 2022-12-16T16:53:50.231577 | 2019-07-13T13:52:42 | 2019-07-13T13:52:42 | 168,442,963 | 0 | 0 | null | 2022-12-08T05:18:37 | 2019-01-31T01:30:06 | HTML | UTF-8 | Python | false | false | 860 | py | # -*- coding: utf-8 -*-
import scipy.signal as signal
import pylab as pl
import math
import numpy as np
def design_equalizer(freq, Q, gain, Fs):
'''设计二次均衡滤波器的系数'''
A = 10**(gain/40.0)
w0 = 2*math.pi*freq/Fs
alpha = math.sin(w0) / 2 / Q
b0 = 1 + alpha * A
b1 = -2*math.cos(w0)
b2 = 1 - alp... | [
"zhwenrong@sina.com"
] | zhwenrong@sina.com |
04dafde3bc7f94f93d9f00a64036a3aba00ae0e4 | caf0ba85f1c7a2b7208e7f0acebb3c047b17b0ba | /4_py_libro_1_pydroid/venv/4_py_libro_1_pydroid/COLECCIONES/py_1_collecciones.py | f5b5a8874953870d8fbe5e698201b48134170b5f | [] | no_license | JAreina/python | 12ca9bd5467420a813ac3f33b0adba6cd492f855 | 3b9ac8d37ab2abe70e34043857f96a76c19468c8 | refs/heads/master | 2020-03-22T07:57:31.675271 | 2018-09-12T06:38:49 | 2018-09-12T06:38:49 | 139,735,465 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 350 | py | import collections
c = collections
# JAreina
a = c.Counter([2,2,8,5,1,2,3,4,5,8])
print(a)
b = 'en un lugar de la mancha'
print( c.Counter(b))
d = ['a',"b",'c',"c",'z']
print(c.Counter(d))
print("\n ::::::::: update counter::::::::::::\n")
e = c.Counter()
print(e)
e.update("hola hola")
print(e)
#JAreina
e.... | [
"jareinafdez@gmail.com"
] | jareinafdez@gmail.com |
2f44a2a3e2304fa716d563c22a881c2c0fbf5ef7 | 257bd63361aa846ffdacdc15edaecf84c6364e78 | /psou/pro1/pack3/class_ex9.py | b5fb7d6e7b2028d16e4b7c2b560541e4fb51073b | [] | no_license | gom4851/hcjeon | 86dcfd05ce47a13d066f13fe187d6a63142fb9fe | 59a00ca9499f30e50127bb16eb510553e88ace43 | refs/heads/master | 2020-06-04T23:16:08.632278 | 2019-01-15T09:54:08 | 2019-01-15T09:54:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,152 | py | '''
Created on 2018. 11. 8.
상속
'''
class Person:
say = "난 사람이야~"
nai = '20'
__kor = 59 # 앞에 __ 해주면 private가 됨.
def __init__(self, nai):
print('Person 생성자')
self.nai = nai
def printInfo(self):
print('나이:{}, 이야기:{}'.format(self.nai, self.say))
def h... | [
"wer104@naver.com"
] | wer104@naver.com |
c4efff0966532f4a7d4d8ee3839194c7e641bf5c | 91668f2d4404dd3d85b598b15b852d5a2eeeec6a | /setup.py | 27912b3549aa77181a86318e03cafa84b6cf5e87 | [
"BSD-2-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | r-swilderd/mi-instrument | b4fd841f05e7c0522580b73f145c2a826ccf21d6 | 34b60925a01d6cf89db254fdc75566c59ccba144 | refs/heads/master | 2021-01-17T21:56:34.298829 | 2015-08-29T23:02:31 | 2015-08-29T23:02:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,607 | py | #!/usr/bin/env python
try:
from setuptools import setup, find_packages
except ImportError:
from distutils.core import setup
import os
import sys
# Add /usr/local/include to the path for macs, fixes easy_install for several packages (like gevent and pyyaml)
if sys.platform == 'darwin':
os.environ['C_INCLU... | [
"petercable@gmail.com"
] | petercable@gmail.com |
92f42f9f2b8c96f0d8e83bcaa79b8813312fbb2e | ba7c4862dfbc9d0469f389c0cdb3fed01f99ebe3 | /controls/Control_Toolbox/steady_state_error.py | 25f782973e80f3f0f6a329e2308fc7e37a7425c8 | [] | no_license | cmontalvo251/Python | 293cbdf8832d7637d5c0b31eadd02d3ccf2f2c05 | 2b12ce043ee41e08537cfb62301c6a55d4661e04 | refs/heads/master | 2023-06-22T21:50:21.225067 | 2023-06-14T13:42:16 | 2023-06-14T13:42:16 | 229,313,158 | 8 | 3 | null | 2021-07-31T16:01:54 | 2019-12-20T18:03:52 | Python | UTF-8 | Python | false | false | 1,015 | py | ###Integrate an ordinary differential equation
#in MATLAB that's using the function ode45.
#in Python we're going to use the Scipy toolbox and odeint
import numpy as np
import matplotlib.pyplot as plt
import scipy.integrate as I
import control as ctl
import scipy.signal as S
import scipy.linalg as slin
plt.close("all"... | [
"cmontalvo251@gmail.com"
] | cmontalvo251@gmail.com |
fdc34a5acdc9df05688e643c6e3939d0f1cfc1a2 | ca7162adc548c5937ebedd6234b40de7294e2da1 | /11-dababase/sqlite/createTable.py | b5b8058f153badef698c5a031aec4709f76832e6 | [] | no_license | meloLeeAnthony/PythonLearn | 03c259d745b1ccdc039e9999889ab54be14ae020 | 9915ec5bb7048712a97539a9c5bce8743567b22a | refs/heads/master | 2023-07-10T21:12:54.027143 | 2021-08-19T12:43:19 | 2021-08-19T12:43:19 | 289,487,502 | 1 | 2 | null | null | null | null | UTF-8 | Python | false | false | 908 | py | # coding=utf-8
'''
1.导入sqlite3模块
2.创建连接 sqlite3.connect()
3.创建游标对象
4.编写创建表的sql语句
5.执行sql
6.关闭连接
'''
import sqlite3
conn = None
# 创建连接
try:
conn = sqlite3.connect('e:/sqlite3Demo/demo.db')
print('连接sqlite库成功')
except Exception as e:
print('连接sqlite库失败:', e)
if conn is not None:
# 创建游标对象
cur = conn... | [
"li.chun158@gmail.com"
] | li.chun158@gmail.com |
1eb5b10cb25082008a50ed8a90198526794f3f9b | 531c47c15b97cbcb263ec86821d7f258c81c0aaf | /sdk/containerinstance/azure-mgmt-containerinstance/azure/mgmt/containerinstance/models/container_http_get_py3.py | d9ca73f638183794cf20b5a1d7c59793e37d8b7d | [
"LicenseRef-scancode-generic-cla",
"LGPL-2.1-or-later",
"MIT"
] | permissive | YijunXieMS/azure-sdk-for-python | be364d3b88204fd3c7d223df23756386ff7a3361 | f779de8e53dbec033f98f976284e6d9491fd60b3 | refs/heads/master | 2021-07-15T18:06:28.748507 | 2020-09-04T15:48:52 | 2020-09-04T15:48:52 | 205,457,088 | 1 | 2 | MIT | 2020-06-16T16:38:15 | 2019-08-30T21:08:55 | Python | UTF-8 | Python | false | false | 1,433 | py | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes ... | [
"lmazuel@microsoft.com"
] | lmazuel@microsoft.com |
06d91053430128ffbd2e417b7711666eb0bcf41a | 5dd47abf7061201d9378e73e51f08fbb314ba2fd | /envdsys/envdaq/migrations_old/0008_auto_20190215_2305.py | aaa12d1357f80fc2772ac6d5b38aa0b5464dee40 | [
"Unlicense"
] | permissive | NOAA-PMEL/envDataSystem | 4d264ae5209015e4faee648f37608d68a4461d0a | 4db4a3569d2329658799a3eef06ce36dd5c0597d | refs/heads/master | 2023-02-23T22:33:14.334737 | 2021-07-22T01:09:16 | 2021-07-22T01:09:16 | 191,809,007 | 1 | 0 | Unlicense | 2023-02-08T00:45:54 | 2019-06-13T17:50:03 | Python | UTF-8 | Python | false | false | 448 | py | # Generated by Django 2.1.5 on 2019-02-15 23:05
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('envdaq', '0007_auto_20190215_2300'),
]
operations = [
migrations.RemoveField(
model_name='devicedef',
name='contacts',
... | [
"derek.coffman@noaa.gov"
] | derek.coffman@noaa.gov |
7e94fa976fa69e30a6a8fecb112d0151ab64e36a | 14d66cef63d9e540f4a7dd76e8810b7f39c9e536 | /viewer.py | 81b3111c4649653ed33f54c8cbfa293e9a3acd44 | [
"MIT"
] | permissive | YarinAVI/GraphLayout | 5327daebdb45f8273cf75c53341bc02f42d293c7 | 187ea93b06730186ec25dd71a28dd2ccdfaa4a7c | refs/heads/master | 2021-06-17T04:21:02.746604 | 2017-05-31T16:23:20 | 2017-05-31T16:23:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,692 | py | import layout
import render
import wx
TESTS = [
[('t', 'te'), ('t', 'ti'), ('t', 'to'), ('te', 'tea'), ('te', 'ten'), ('tea', 'team'), ('ti', 'tin'), ('tin', 'tine'), ('to', 'ton'), ('ton', 'tone')],
[(5, 11), (11, 10), (11, 2), (3, 10), (3, 8), (8, 9), (11, 9), (7, 8), (7, 11)],
[(1, 2), (1, 5), (2, 5), (... | [
"fogleman@gmail.com"
] | fogleman@gmail.com |
ef5b018a2b5ea2a4f02c3054530d9c410298db2c | bc5d0c3e950ebd9a7fbd33fbbcad94979cbe344f | /src/scratch.py | 1e0bc9d7ea1f286057ac7e65ffcc5322727de2fe | [
"Apache-2.0",
"LicenseRef-scancode-public-domain"
] | permissive | bgshin/bert | 44e7b23016087e7fda6396bd4432188918d2af28 | 5d13d62909f120ec097c606a0366b49887ea1baf | refs/heads/master | 2020-04-06T11:41:44.788854 | 2018-12-03T04:48:56 | 2018-12-03T04:48:56 | 157,426,269 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,344 | py | import os
import numpy as np
import tensorflow as tf
import collections
import tokenization
from run_classifier import SstProcessor, file_based_input_fn_builder, model_fn_builder, file_based_convert_examples_to_features
import modeling
import cPickle
def get_model_size(ckpt_fpath):
# Open TensorFlow ckpt
read... | [
"nomolos79@gmail.com"
] | nomolos79@gmail.com |
3a9cb5d26818969cfb8af7ed4edd0f0d30c3c771 | 2fd0c65aa0f72133f773dac5d9a5c48fe9e26fac | /Python/Core/Lib/encodings/utf_32_be.py | f84e9045e1470bfbee6b819f251ac345d9b60040 | [] | no_license | FingerLeakers/DanderSpritz_docs | f5d2430e0b86b1b2f0684f02ddd4fa973a5a7364 | d96b6a71c039b329f9f81544f645857c75360e7f | refs/heads/master | 2021-01-25T13:05:51.732149 | 2018-03-08T01:22:49 | 2018-03-08T01:22:49 | 123,527,268 | 2 | 0 | null | 2018-03-02T03:48:31 | 2018-03-02T03:48:30 | null | UTF-8 | Python | false | false | 1,048 | py | # uncompyle6 version 2.9.10
# Python bytecode 2.7 (62211)
# Decompiled from: Python 2.7.10 (default, Feb 6 2017, 23:53:20)
# [GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)]
# Embedded file name: utf_32_be.py
"""
Python 'utf-32-be' Codec
"""
import codecs
encode = codecs.utf_32_be_encode
def decode(input, er... | [
"francisck@protonmail.ch"
] | francisck@protonmail.ch |
0e3e32f77124f0e14236d74d16a1a23002091b70 | ae10b60cb92a69146bfb05ef5dde735a0aa45d4b | /examples/Extended Application/matplotlib/examples/userdemo/annotate_simple_coord02.py | c8424d6389371288876249d81040115991437882 | [
"MIT"
] | permissive | kantel/nodebox-pyobjc | 471cea4c5d7f1c239c490323186458a74edcc214 | 068ba64c87d607522a240ab60c3ba14f869f6222 | refs/heads/master | 2021-08-14T18:32:57.995445 | 2017-11-16T13:42:23 | 2017-11-16T13:42:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,429 | py | """
=======================
Annotate Simple Coord02
=======================
"""
import matplotlib.pyplot as plt
# nodebox section
if __name__ == '__builtin__':
# were in nodebox
import os
import tempfile
W = 800
inset = 20
size(W, 600)
plt.cla()
plt.clf()
plt.close('all')
def ... | [
"karstenwo@web.de"
] | karstenwo@web.de |
0a8bd7608db9b29c07d9adbc6e136ba7c4662200 | 35e28d7705773eed54345af4440700522c9d1863 | /deps/libgdal/gyp-formats/tsx.gyp | b8f05037aec95a26a96a811114431a86f6467c1c | [
"Apache-2.0"
] | permissive | naturalatlas/node-gdal | 0ee3447861bf2d1abc48d4fbdbcf15aba5473a27 | c83e7858a9ec566cc91d65db74fd07b99789c0f0 | refs/heads/master | 2023-09-03T00:11:41.576937 | 2022-03-12T20:41:59 | 2022-03-12T20:41:59 | 19,504,824 | 522 | 122 | Apache-2.0 | 2022-06-04T20:03:43 | 2014-05-06T18:02:34 | C++ | UTF-8 | Python | false | false | 245 | gyp | {
"includes": [
"../common.gypi"
],
"targets": [
{
"target_name": "libgdal_tsx_frmt",
"type": "static_library",
"sources": [
"../gdal/frmts/tsx/tsxdataset.cpp"
],
"include_dirs": [
"../gdal/frmts/tsx"
]
}
]
}
| [
"brian@thirdroute.com"
] | brian@thirdroute.com |
ffabd2487c7b9698475b0ebf663f97afebe11c6a | 0f7666900a3d203481b1009fe3d9dd2186938c30 | /gpu-example.py | e89103c48573461470473750392cc1d8d4e2ed0b | [] | no_license | MZ195/Cupy-GPU-Example | 4a7d99c25e9d26213c3f27b6618b6f8c8cbc4393 | 108b920848e60b3e2706749ca97404572433e130 | refs/heads/master | 2022-10-29T23:45:48.093569 | 2020-06-13T21:09:04 | 2020-06-13T21:09:04 | 272,086,332 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,070 | py | import numpy as np
from timeit import default_timer as timer
from numba import vectorize
NUM_ELEMENTS = 100000000
# This is the CPU version.
def vector_add_cpu(a, b):
c = np.zeros(NUM_ELEMENTS, dtype=np.float32)
for i in range(NUM_ELEMENTS):
c[i] = a[i] + b[i]
return c
# This is the GPU version. Note th... | [
"40984264+MZ195@users.noreply.github.com"
] | 40984264+MZ195@users.noreply.github.com |
31e36abf085c1f9a230b668343ec294935b1c1da | 91fe8f479fa921fa84111d19222a5c6aa6eff030 | /apps/django-web/learning_log/ll_env/Scripts/django-admin.py | 8785f03fb524b48fbb8c6393ffc1f4c9ea3ed203 | [] | no_license | romanticair/python | 2055c9cdaa46894c9788d5797643283786ed46dd | 6f91fe5e7cbedcdf4b8f7baa7641fd615b4d6141 | refs/heads/master | 2022-11-03T17:17:17.608786 | 2019-07-05T07:07:29 | 2019-07-05T07:07:29 | 195,356,190 | 0 | 1 | null | 2022-10-14T20:51:14 | 2019-07-05T07:00:33 | Python | UTF-8 | Python | false | false | 183 | py | #!l:\mypythonprogr\somepythonprojects\learning_log\ll_env\scripts\python.exe
from django.core import management
if __name__ == "__main__":
management.execute_from_command_line()
| [
"1024519570@qq.com"
] | 1024519570@qq.com |
f32ae2236fb684777b438596d850abf6885dc83b | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /qLMZ2hEvrhRSSSnQw_20.py | dba82c5c1e6082f3f6e2d972820ab53ab7f449e3 | [] | no_license | daniel-reich/turbo-robot | feda6c0523bb83ab8954b6d06302bfec5b16ebdf | a7a25c63097674c0a81675eed7e6b763785f1c41 | refs/heads/main | 2023-03-26T01:55:14.210264 | 2021-03-23T16:08:01 | 2021-03-23T16:08:01 | 350,773,815 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 813 | py | """
Graded lexicographic order (grlex order for short) is a way of ordering words
that:
1. First orders words by length.
2. Then orders words of the same size by their dictionary order.
For example, in grlex order:
* "tray" < "trapped" since "tray" has length 4 while "trapped" has length 7.
* "trap" < "tr... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
1c54e78c3a9fa11c3884d713d206b69fd669a135 | a08d885cb9150d7e84f5ffbf0c9734893105a898 | /2021/Day 04/giant_squid.py | 113e0335b32c0ec58d8789010615a252f8d92b66 | [] | no_license | vhsw/Advent-of-Code | ab422c389340a1caf2ec17c5db4981add6433fbe | 3c1dac27667472202ab15098c48efaac19348edf | refs/heads/master | 2022-12-29T03:56:59.648395 | 2022-12-26T11:01:45 | 2022-12-26T11:01:45 | 162,491,163 | 0 | 0 | null | 2022-05-10T08:43:32 | 2018-12-19T21:10:26 | Python | UTF-8 | Python | false | false | 1,821 | py | """Day 4: Giant Squid"""
from typing import Iterable
with open("2021/Day 04/input.txt", encoding="utf-8") as fp:
DATA = fp.read().strip()
def part1(data: str):
"""Part 1 solution"""
nums, boards = parse(data)
for num in nums:
for board in boards:
for line in board:
... | [
"nevermind1025@gmail.com"
] | nevermind1025@gmail.com |
861709efdf3acd7f6154b69f466c98536af3d22c | 98e1716c1c3d071b2fedef0ac029eb410f55762c | /part13-introduction-data-visualization/No33-Multiple-time-series-on-common-axes.py | d1207e9079b0d4e197a6b8b3812ed67aab364a3e | [] | no_license | iamashu/Data-Camp-exercise-PythonTrack | 564531bcf1dff119949cbb75e1fd63d89cb2779f | c72a4e806494f0e263ced9594597dc8882c2131c | refs/heads/master | 2020-07-22T00:23:12.024386 | 2019-04-12T09:24:42 | 2019-04-12T09:24:42 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,261 | py | #Multiple time series on common axes
'''
For this exercise, you will construct a plot showing four time series stocks on the same axes. The time series in question are represented in the session using the identifiers aapl, ibm, csco, and msft. You'll generate a single plot showing all the time series on common axes wit... | [
"beiran@hotmail.com"
] | beiran@hotmail.com |
8718fb18f40bed47885972a98c7d3c06d6a3ca6c | 9db8e7bbd09eb07126a7f0c14e2f3af86bf6e8d9 | /datasets/centralia/convert.py | 51efa94fe2198d2ccf0de3656af8e6b03e2c11b4 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | jayschauer/TCPD | ddeb193eca2fa9ea04b791025fe529dfd3ee4686 | f99ab1decc165707115fd60e991ac1c12091f334 | refs/heads/master | 2022-12-05T02:21:16.517774 | 2020-09-02T18:56:49 | 2020-09-02T18:56:49 | 292,368,325 | 0 | 0 | MIT | 2020-09-02T18:52:00 | 2020-09-02T18:52:00 | null | UTF-8 | Python | false | false | 1,365 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
Dataset conversion script
Author: Gertjan van den Burg
"""
import json
import argparse
def parse_args():
parser = argparse.ArgumentParser()
parser.add_argument(
"-s",
"--subsample",
help="Number of observations to skip during subsam... | [
"gertjanvandenburg@gmail.com"
] | gertjanvandenburg@gmail.com |
ac415525282185598f7818ce48ba05afe6778b4c | 78efa54b2b253f99ea7e073f783e6121c20cdb52 | /Codechef/Substraction Game 1.py | 70eba9c0690d035feb1d0ea1b9eec2fb43d7f3d6 | [] | no_license | NishchaySharma/Competitve-Programming | 32a93581ab17f05d20129471f7450f34ec68cc53 | 1ec44324d64c116098eb0beb74baac7f1c3395bb | refs/heads/master | 2020-04-08T04:02:46.599398 | 2020-01-01T15:51:39 | 2020-01-01T15:51:39 | 159,000,529 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 275 | py | def gcd(a:int,b:int)->int:
if a==0 or b==0: return a+b
else: return gcd(b%a,a)
for _ in range(int(input())):
n=int(input())
arr=list(map(int,input().split()))
res=arr[0]
for i in arr[1:]:
res=gcd(res,i)
if res==1: break
print(res)
| [
"noreply@github.com"
] | NishchaySharma.noreply@github.com |
20906ab3c18a8740b0c15f21a626b89b87f75c8d | 10fbe5526e5f0b8588b65f70f088cd86b6e9afbe | /qqpppzas/migrations/0015_auto_20150218_1630.py | 8c6435040612046c9d19f24e8b395845cbb10c31 | [] | no_license | MarkusH/django-migrations-benchmark | eb4b2312bb30a5a5d2abf25e95eca8f714162056 | e2bd24755389668b34b87d254ec8ac63725dc56e | refs/heads/master | 2016-09-05T15:36:45.250134 | 2015-03-31T23:44:28 | 2015-03-31T23:44:28 | 31,168,231 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,078 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('cohutfvb', '0014_auto_20150218_1630'),
('qqpppzas', '0014_auto_20150218_1628'),
]
run_before = [
('ysgxuyu', '0012_d... | [
"info@markusholtermann.eu"
] | info@markusholtermann.eu |
339fbbf64e0beffc337a085e31729f800c8127dd | d03582a9f9a853a07eeb36f746530dee29f7a258 | /build/catkin_generated/generate_cached_setup.py | b68e8b3be2e20e0a06efc00fe0407cd24717e837 | [] | no_license | tanmayshankar/decision_making | 6df835c6c26e9cb2f0fdfbec509f5a46bf3c98ae | fdd3b1ea127a89fb03181cb8f766e86e6d933eed | refs/heads/master | 2021-01-21T04:48:16.259813 | 2016-07-15T17:43:06 | 2016-07-15T17:43:06 | 44,739,541 | 4 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,339 | py | # -*- coding: utf-8 -*-
from __future__ import print_function
import argparse
import os
import stat
import sys
# find the import for catkin's python package - either from source space or from an installed underlay
if os.path.exists(os.path.join('/opt/ros/indigo/share/catkin/cmake', 'catkinConfig.cmake.in')):
sys.p... | [
"tanmay.shankar@gmail.com"
] | tanmay.shankar@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.