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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
64a65dc8e8eb1d2a4fda1b44992a6c4e8928a5f0 | 15ed27bece0ae11ee0ae19f7d8fbffb1bd6db342 | /tensorforce/environments/socket_environment.py | 20cfde293eb197ba167a9b4a457e7ab276897cdb | [
"Apache-2.0"
] | permissive | marload/tensorforce | 06baea28096d04bbe1f42ee99d0d8e4d815d1e40 | 7101282b2c4a0524361aeeab22d3a2c5a3dd03bc | refs/heads/master | 2021-04-01T09:55:48.154186 | 2020-03-17T23:38:49 | 2020-03-17T23:38:49 | 248,179,865 | 1 | 0 | Apache-2.0 | 2020-03-18T08:46:32 | 2020-03-18T08:46:31 | null | UTF-8 | Python | false | false | 5,808 | py | # Copyright 2020 Tensorforce Team. 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 la... | [
"[email protected]"
] | |
42635fa6693ccd0a767871eb5e8353b606f9eb6d | 0e478f3d8b6c323c093455428c9094c45de13bac | /src/OTLMOW/PostenMapping/Model/Post060261215.py | 1e8401f5696f51dc2d278fa4a273f956133d8b95 | [
"MIT"
] | permissive | davidvlaminck/OTLMOW | c6eae90b2cab8a741271002cde454427ca8b75ba | 48f8c357c475da1d2a1bc7820556843d4b37838d | refs/heads/main | 2023-01-12T05:08:40.442734 | 2023-01-10T15:26:39 | 2023-01-10T15:26:39 | 432,681,113 | 3 | 1 | MIT | 2022-06-20T20:36:00 | 2021-11-28T10:28:24 | Python | UTF-8 | Python | false | false | 4,912 | py | # coding=utf-8
from OTLMOW.PostenMapping.StandaardPost import StandaardPost
from OTLMOW.PostenMapping.StandaardPostMapping import StandaardPostMapping
# Generated with PostenCreator. To modify: extend, do not edit
class Post060261215(StandaardPost):
def __init__(self):
super().__init__(
nummer... | [
"[email protected]"
] | |
51218db60992a0598c11d71f2a2840fd04fe9494 | 4e6caa29a341e8e3964855172af4b89d683ff65f | /orders/models.py | d2030a34d7e0aace750b9adea2fb7d4d6f9d3e26 | [] | no_license | sadakchap/basic-ecommerce-site | 2112e758ac0d9074a18c50f6a0955c0ab82ff01d | b1f9990eaebb260a3c338fda61f8c426953faad8 | refs/heads/master | 2022-12-25T11:04:16.247128 | 2021-06-02T01:47:00 | 2021-06-02T01:47:00 | 212,818,635 | 0 | 0 | null | 2022-12-08T06:40:57 | 2019-10-04T13:14:44 | JavaScript | UTF-8 | Python | false | false | 1,301 | py | from django.db import models
from shop.models import Product
# Create your models here.
class Order(models.Model):
first_name = models.CharField(max_length=255)
last_name = models.CharField(max_length=255)
email = models.EmailField()
address = models.CharField(max_length=255)
postal_c... | [
"[email protected]"
] | |
981bf9717f31d66e32777202e08d7e15847fb7fd | 9b3f578e63a7e17e2b1bab5f38aa8625b8a80251 | /descarteslabs/workflows/models/versionedgraft.py | 5c4b26227aef784da05648dcf5da73da4df46673 | [
"Apache-2.0"
] | permissive | carderne/descarteslabs-python | e6f7000f08cd1569e0ddd0f7fb8e53abb6765183 | 757b480efb8d58474a3bf07f1dbd90652b46ed64 | refs/heads/master | 2022-12-09T23:19:02.361226 | 2020-08-13T11:52:30 | 2020-08-13T11:52:30 | 287,264,851 | 0 | 0 | NOASSERTION | 2020-08-13T11:46:58 | 2020-08-13T11:46:57 | null | UTF-8 | Python | false | false | 5,341 | py | import json
import textwrap
from descarteslabs.common.graft import client as graft_client
from descarteslabs.common.proto.workflow import workflow_pb2
from descarteslabs.workflows import _channel
from descarteslabs.workflows.cereal import deserialize_typespec, serialize_typespec
from descarteslabs.workflows.client imp... | [
"[email protected]"
] | |
c9481cd2dcec110f75b2234f1c65a3c1766da112 | 543286f4fdefe79bd149ff6e103a2ea5049f2cf4 | /Exercicios&cursos/Curso_Py/escrevendo_arquivo.py | b357539a43c5f9dca9aea36886c29d852f520cae | [] | no_license | antonioleitebr1968/Estudos-e-Projetos-Python | fdb0d332cc4f12634b75984bf019ecb314193cc6 | 9c9b20f1c6eabb086b60e3ba1b58132552a84ea6 | refs/heads/master | 2022-04-01T20:03:12.906373 | 2020-02-13T16:20:51 | 2020-02-13T16:20:51 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 170 | py | arq = open("teste_aula.txt", "w")#w para escrever
arq.write("escreviiiiiiii\n")
arq.write("dnvvvvvvvvvvv\n")
arq.write("HAHAHA CHUPA")
arq.write("UHUUUUUU")
arq.close()
| [
"[email protected]"
] | |
72e597de56f9957f4ef37fa1adeabff299cde620 | ebcea394905df8222c257c8c6c469627a6e48095 | /djangoProject/mysite/Profile/admin.py | cba40e206156413afaf37126354b58225ad1a65d | [] | no_license | valiok98/Python-Qt5-Tensorflow | 2773cfc2a0e569ed53cf3d90066885f17abe8c6a | e03ccc2884b687a36fbe47f5ff320837be3e217a | refs/heads/master | 2021-09-17T20:41:01.908602 | 2018-03-31T12:42:25 | 2018-03-31T12:42:25 | 103,644,683 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 301 | py | from django.contrib import admin
# Register your models here.
from .models import PersonalProfile, Item
class PProfile(admin.ModelAdmin):
list_display = ["f_name","l_name"]
class Meta:
model = PersonalProfile
admin.site.register(PersonalProfile,PProfile)
admin.site.register(Item) | [
"[email protected]"
] | |
c5c5338564eb826c01194cf073d4ba304148170e | 39200f6d08ebeac0f147d3b2b6aaed980d2ce555 | /blog/urls.py | ce3882ff9612bb77ff64376fa9dd24a0c8c0a086 | [] | no_license | hemor/my-first-blog | 506a81b6dcda82a39aa24ecda65632b1d92ecbce | 525e002897fd9367ffa6fbfc9458bf2e477efab9 | refs/heads/master | 2020-03-28T02:08:04.116659 | 2016-06-01T17:40:35 | 2016-06-01T17:40:35 | 60,012,037 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 873 | py | from django.conf.urls import url
from . import views
app_name = 'blog'
urlpatterns = [
url(r'^$', views.post_list, name='post_list'),
url(r'^index/$', views.post_list, name='index'),
url(r'^post/(?P<pk>\d+)/$', views.post_detail, name='post_detail'),
url(r'^post/(?P<pk>\d+)/comment/$', views.add_comment_to_post, ... | [
"[email protected]"
] | |
de41530ae7cbc92425d107c3f2e3e33d1b2dfa11 | 4e96f383d4703ad8ee58869ed91a0c8432c8a051 | /Cura/Uranium/UM/Operations/AddSceneNodeOperation.py | 3afab5a287b257c42b56bb5d7554760e5322b2c3 | [
"LGPL-3.0-only",
"GPL-3.0-only"
] | permissive | flight7788/3d-printing-with-moveo-1 | b2dba26010c4fa31815bc1d2d0966161a8600081 | 7fcb9c6b5da9245d54ac917de8c2a7f5148e42b0 | refs/heads/Feature_Marlin_with_AlanBoy | 2022-08-30T18:36:44.785058 | 2020-05-30T07:52:58 | 2020-05-30T07:52:58 | 212,583,912 | 0 | 0 | MIT | 2020-05-16T07:39:47 | 2019-10-03T13:13:01 | C | UTF-8 | Python | false | false | 1,597 | py | # Copyright (c) 2018 Ultimaker B.V.
# Uranium is released under the terms of the LGPLv3 or higher.
from UM.Operations.Operation import Operation
from UM.Scene.Selection import Selection
from UM.Scene.SceneNode import SceneNode
from typing import Optional
## Operation that adds a new node to the scene.
class AddS... | [
"[email protected]"
] | |
6b0447a4f1e8917cc1625bd04e865f86499b4fa2 | 23e1f9af34f2f2c3f32f68a6176c7664cb7f62d7 | /legacy/daily/163/overview.py | f5d54088c3d930ebb955ac5055aba50cd24e7f87 | [] | no_license | jki14/the-cat-of-wall-street | 8bc95d812f0381c7e02bd65777ee9f44e17f73d9 | 5e1265a11bba7f3040c893043d5ac79fe5736b63 | refs/heads/master | 2021-10-11T11:27:18.297584 | 2019-01-25T08:51:22 | 2019-01-25T08:51:22 | 115,118,975 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,088 | py | # -*- coding: utf-8 -*-
import csv
import datetime
import json
import os
import socket
import sys
import time
import urllib2
tracking_list = ['sh000001', 'sz399001', 'sz399300']
foo = {}
try:
with open('./data/dbf/overview.dbf', 'r') as dbf:
foo = json.load(dbf)
except IOError:
foo['layout'] = ['DAT... | [
"[email protected]"
] | |
4661574ed6bcbdbcb9e401e4121736a4c790d8e6 | 0131f6d91da5b063b3d79330b014871c128c67ed | /irc/asparagus/modules/4chan.py | ebb414e01e4aa3612a6cdb9b84448a46a5a2afc9 | [
"Zlib"
] | permissive | moneytech/code-2 | f31602a702cc7e13b24c1ab5817d30d2314dde76 | d970038329f7c4e4f0ee9dcd1b345741dd0fcc51 | refs/heads/master | 2021-10-02T18:24:20.159492 | 2018-11-30T02:14:18 | 2018-11-30T02:14:18 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,174 | py | """
Copyright (c) 2013, Christine Dodrill
All rights reserved.
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.
Permission is granted to anyone to use this software for any purpose,
including ... | [
"[email protected]"
] | |
3b3693eadafb982f2084a294eca435e9ca20ceee | 67bdebd561b19af9bf759b6ed5de8556b93ea91f | /trace_unless.py | f02ba6959a7ce84d5162f521cd3b15b0d53a8b8d | [] | no_license | rlowrance/re-avm | 91371ec79f6b6f48e17643da4dfb7a4894d0a0ca | d4cfa62e9f65d325e8ac98caa61d3fb666b8a6a2 | refs/heads/master | 2021-01-17T07:34:16.876133 | 2017-02-06T21:04:59 | 2017-02-06T21:04:59 | 42,865,972 | 31 | 10 | null | null | null | null | UTF-8 | Python | false | false | 316 | py | import pdb
def trace_unless(condition, message, **kwds):
'like assert condition, message; but enters debugger if condition fails'
if condition:
return
print '+++++++++++++++'
for k, v in kwds.iteritems():
print k, v
print message
print '+++++++++++++++'
pdb.set_trace()
| [
"[email protected]"
] | |
01f9a0bdf77391ac938617afd13a6195299dafb5 | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /Wpbb6x9nHax55zKLX_14.py | 8e96679b72e16f74a7456684857920bfe30cdea7 | [] | 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 | 1,103 | py | """
In many cases, **SQL** is used to select more than just columns in a table.
For example, you can filter your search by specifying conditions as seen
below:
SELECT * FROM Table
WHERE Name = "Bob";
* Again, we can use the asterisks to select all the data in a table.
* However, with the use of the WHE... | [
"[email protected]"
] | |
52d6fc860067cda559eaca821a47486d2e8644ac | c4af67db4c523d20f2d55aef90ba77db1fb53c38 | /CMFDefault/Extensions/update_catalogIndexes.py | c86903bdb2a56bf53134126924f3d2287a8708e7 | [] | no_license | dtgit/dtedu | e59b16612d7d9ea064026bf80a44657082ef45a3 | d787885fe7ed0de6f9e40e9b05d852a0e9d60677 | refs/heads/master | 2020-04-06T05:22:50.025074 | 2009-04-08T20:13:20 | 2009-04-08T20:13:20 | 171,351 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 639 | py | from Products.CMFCore.utils import getToolByName
def update_catalogIndexes(self, REQUEST):
'''
External method to drop, re-add, and rebuild catalog Indexes for migrated
CMF sites from Zope 2.3 to 2.4+.
'''
rIndexes = {'allowedRolesAndUsers': 'KeywordIndex'
, 'effective': 'FieldIndex'... | [
"[email protected]"
] | |
00c5c1b70eb024b63457ed9b09528d8528502b80 | cf05dc6b31bb83b0b71cd357d7d19dfea7ad40a0 | /office_system/apps/users/forms.py | 2f956301bb4f9be16de57da66f79a02283317f08 | [] | no_license | peng-python/oa | 5df69a935b20b8200808133bf92d6757016cb9fa | bfc600a9c439866e1617f297007dc10fd8b86090 | refs/heads/master | 2020-03-17T20:21:54.927871 | 2018-05-18T05:15:28 | 2018-05-18T05:15:28 | 133,905,915 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 161 | py | from django import forms
class LoginFrom(forms.Form):
username = forms.CharField(required=True)
password = forms.CharField(required=True, min_length=8) | [
"[email protected]"
] | |
e52e408df819be554e75d2ac286768fecdfd6097 | 060e82b46016744deb7da7c940f97d0dea39d1b3 | /excel/定向分配/赵土良100445/ztl_python_script/To_mongo/ztl.py | 1fa3c0c96bb707e8b2bfcc393884c9065dcf378b | [] | no_license | yangwen1997/- | eb8c609d8af3f4493adf70d10df8cc5f561bcf60 | 197ae391ff1be36189ba003b025fd4802d703e00 | refs/heads/master | 2022-12-08T17:11:57.910664 | 2019-11-12T01:32:17 | 2019-11-12T01:32:17 | 160,466,240 | 0 | 1 | null | 2022-12-08T05:24:52 | 2018-12-05T05:34:19 | Python | UTF-8 | Python | false | false | 1,872 | py | '''
@author : yangwenlong
@file : ztl
@intro : 4320条-赵土良存入monmgo
@creatime : 2019/9/25
'''
import xlrd
import hashlib
from ztl_python_script.common import Enterprise_db,get_log
log = get_log()
#使用xlrd打开工作本(excel文件)
book = xlrd.open_workbook(r'D:\白名单\定向分配资源整理\excel\定向分配\赵土良100445\2016年8月4320条-... | [
"[email protected]"
] | |
e9b1a299486c6a98727862c462c3b949bf92b416 | 94c8dd4126da6e9fe9acb2d1769e1c24abe195d3 | /qiskit/circuit/library/__init__.py | 775bf9fdf67fe41e674f190ff83ba2983724d6da | [
"Apache-2.0"
] | permissive | levbishop/qiskit-terra | a75c2f96586768c12b51a117f9ccb7398b52843d | 98130dd6158d1f1474e44dd5aeacbc619174ad63 | refs/heads/master | 2023-07-19T19:00:53.483204 | 2021-04-20T16:30:16 | 2021-04-20T16:30:16 | 181,052,828 | 1 | 0 | Apache-2.0 | 2019-06-05T15:32:13 | 2019-04-12T17:20:54 | Python | UTF-8 | Python | false | false | 7,078 | py | # This code is part of Qiskit.
#
# (C) Copyright IBM 2017, 2020.
#
# This code is licensed under the Apache License, Version 2.0. You may
# obtain a copy of this license in the LICENSE.txt file in the root directory
# of this source tree or at http://www.apache.org/licenses/LICENSE-2.0.
#
# Any modifications or derivat... | [
"[email protected]"
] | |
10f403c415e3258aa195e50df38424e21966e650 | c67831f476cb530fc0c26e0bf4258ce18e986749 | /module_intent/migrations/0001_initial.py | f9fde504260720388d163863648d863149e5b7ff | [
"MIT"
] | permissive | cz-qq/bk-chatbot | a3ce4b86452b3de0ff35430c1c85b91d6b23a3e6 | da37fb2197142eae32158cdb5c2b658100133fff | refs/heads/master | 2023-06-05T05:48:22.083008 | 2021-06-15T10:21:30 | 2021-06-15T10:21:30 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,294 | py | """
TencentBlueKing is pleased to support the open source community by making
蓝鲸智云PaaS平台社区版 (BlueKing PaaSCommunity Edition) available.
Copyright (C) 2017-2018 THL A29 Limited,
a Tencent company. All rights reserved.
Licensed under the MIT License (the "License");
you may not use this file except in compliance with the... | [
"[email protected]"
] | |
1778e80f2fab17a4495abc3b59d9289f191e26ed | bb71e927dc2429abf551b44874ee990cb3a93f7a | /python/python_tricks/train.py | b7b940b5716ec1c81a6ebdd74a7e822126801790 | [] | no_license | khuyentran1401/Data-science | c37021349bb407ed50d891dab780463e0b243de5 | be59f5959be9f5944e12260fbb4548c85ef6aabe | refs/heads/master | 2023-08-31T13:46:58.212459 | 2023-08-09T15:46:11 | 2023-08-09T15:46:11 | 280,508,180 | 3,809 | 943 | null | 2023-05-23T02:38:37 | 2020-07-17T19:25:27 | Jupyter Notebook | UTF-8 | Python | false | false | 281 | py | import sys
model_type = sys.argv[1]
model_version = sys.argv[2]
model_path = f'''model/model1/{model_type}/version_{model_version}'''
print('Loading model from', model_path, 'for training')
# On the terminal type
# for version in 1 2 3 4
# do
# python train.py $version
# done | [
"[email protected]"
] | |
9593144727e4f55f8bc92271de4d519cd3632302 | 8e07b5b7a8dd38e0ef2c7ffc97d0392d886f32e6 | /venv/Lib/site-packages/mypy/typeshed/stdlib/3/winreg.pyi | 23482b55cac99932caabc054d47d219409f6ba40 | [] | no_license | RodrigoNeto/cursopythonyt | fc064a2e6106324e22a23c54bdb9c31040ac9eb6 | 279dad531e21a9c7121b73d84fcbdd714f435e7e | refs/heads/master | 2023-07-03T00:54:09.795054 | 2021-08-13T12:42:24 | 2021-08-13T12:42:24 | 395,646,798 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,827 | pyi | from types import TracebackType
from typing import Any, Optional, Tuple, Type, Union
_KeyType = Union[HKEYType, int]
def CloseKey(__hkey: _KeyType) -> None: ...
def ConnectRegistry(__computer_name: Optional[str], __key: _KeyType) -> HKEYType: ...
def CreateKey(__key: _KeyType, __sub_key: Optional[str]) -> HKEY... | [
"[email protected]"
] | |
9848fd410ddb1d313b711e656fde9ae27d2261fd | 732d750ce7b96090bc1b252fbefdadfe167990a1 | /networker/io/__init__.py | 3ac84486d4ee66edda8e7eb94ebf4c159a76b37a | [] | no_license | carbz/networker | 4008174200db1865635f524646ad550187a4d289 | cab14026118db42603bd1a5757ec460c6cb4984d | refs/heads/master | 2021-01-15T10:24:59.858048 | 2015-04-22T17:11:49 | 2015-04-22T17:11:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,465 | py | # -*- coding: utf-8 -*-
import ogr
import osr
import networkx as nx
import networker.geomath as gm
from networker.classes.geograph import GeoGraph
import warnings
import os
"""
Package for reading/writing networkx based GeoGraphs
Note: these wrap existing networkx functions for custom behavior
"""
def load_shp(shp... | [
"[email protected]"
] | |
43b694369a93e5b2fca5c24a9a3ea7ae339c90e4 | 604bd9370a5b4e61a5f9e533c6612bc94aef0c6c | /django/helpdesk_deploy_old/helpdesk/base/migrations/0005_auto_20201210_0554.py | ac187c287afd3fa9fa8cede7bf91012b73480f43 | [
"Apache-2.0"
] | permissive | Netromnik/python | 2ba2f15b56e635b53c12ef39ed776b9577c08dff | 630a9df63b1cade9af38de07bb9cd0c3b8694c93 | refs/heads/main | 2023-06-16T04:58:35.634371 | 2021-07-18T16:20:13 | 2021-07-18T16:20:13 | 355,891,948 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 756 | py | # Generated by Django 3.1.2 on 2020-12-10 05:54
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('base', '0004_auto_20201114_1445'),
]
operations = [
migrations.AddField(
model_name='collectmedia',
name='groups',
... | [
"[email protected]"
] | |
e261f4ac64cfeda090c8d41631cb690d60dd4505 | 964f2882117ff656d7a2757c233c6dd88226d975 | /services/autoscaling/setup.py | e3e711abf8319d6d068bac1c11a37bd4253ee6bd | [
"MIT"
] | permissive | ignapas/osparc-simcore | a002dd47d7689af9c1c650eea33e31add2b182c1 | cb62e56b194265a907f260f3071c55a65f569823 | refs/heads/master | 2023-01-22T08:55:32.580775 | 2022-12-09T15:57:36 | 2022-12-09T15:57:36 | 170,852,656 | 0 | 0 | MIT | 2023-01-09T05:03:04 | 2019-02-15T11:12:34 | Python | UTF-8 | Python | false | false | 1,726 | py | #!/usr/bin/env python3
import re
import sys
from pathlib import Path
from setuptools import find_packages, setup
def read_reqs(reqs_path: Path) -> set[str]:
return {
r
for r in re.findall(
r"(^[^#\n-][\w\[,\]]+[-~>=<.\w]*)",
reqs_path.read_text(),
re.MULTILINE... | [
"[email protected]"
] | |
480f230a8f4d7f2d2cb4b1c639c05909e1bd21f2 | e90bf4b372da78ceec15282d060b48d18ba8d4e9 | /supervisor/docker/const.py | f8e3edbeb75efcfbbb06b5df64772e6a083b2986 | [
"Apache-2.0"
] | permissive | home-assistant/supervisor | 67f2e1755ff5fbf7cf2084351e1c32c6995274e0 | 4838b280adafed0997f32e021274b531178386cd | refs/heads/main | 2023-08-31T22:51:25.949277 | 2023-08-31T08:01:42 | 2023-08-31T08:01:42 | 84,926,758 | 928 | 477 | Apache-2.0 | 2023-09-14T17:11:27 | 2017-03-14T08:54:15 | Python | UTF-8 | Python | false | false | 2,030 | py | """Docker constants."""
from enum import Enum
from docker.types import Mount
from ..const import MACHINE_ID
class Capabilities(str, Enum):
"""Linux Capabilities."""
BPF = "BPF"
DAC_READ_SEARCH = "DAC_READ_SEARCH"
IPC_LOCK = "IPC_LOCK"
NET_ADMIN = "NET_ADMIN"
NET_RAW = "NET_RAW"
PERFMON ... | [
"[email protected]"
] | |
a90e9370b12a22d95dfd74afb1de671b312d4041 | 6471f95e6a193b0c018d81a2c4e8a518f7ec35d7 | /tests/test_wrappers.py | 04a0837a4d619f644b026ee4c60fc82aa4fe1eee | [
"BSD-3-Clause"
] | permissive | Billingegroup/bluesky_scanplans | 5b297e4874b2e57d44a5cc091a2a87be87856503 | f865da9712bb91dceee73d4aea61f9b6c4b2c9ef | refs/heads/master | 2021-06-30T18:08:37.553268 | 2021-05-20T18:25:31 | 2021-05-20T18:25:31 | 234,350,238 | 0 | 3 | BSD-3-Clause | 2021-05-20T17:11:51 | 2020-01-16T15:27:35 | Jupyter Notebook | UTF-8 | Python | false | false | 755 | py | import bluesky.plan_stubs as bps
import bluesky.plans as bp
import bluesky.simulators as sim
import xpdsim.movers as movers
import scanplans.wrapper as helper
def test_wrapper_count():
trigger_and_read = helper.shutter_wrapper(bps.trigger_and_read, movers.shctl1, 0, 100, 0)
one_shot = helper.take_reading_wra... | [
"[email protected]"
] | |
527f3f6b2e59ae487d07bc1f27334d5ba63a8ff6 | eb2867c8ef92810fb0a76aa5fa9933cfba42d3de | /DL_HomeWork/DL_midterm_codings/u_toronto_csc321_winter2018.py | a2e3d6675c9eead5a172b8b76a40dbf99aa66367 | [] | no_license | thomas-liao/python_prac | 76bbaf988a21cdac8e932a272db8f5eddfc66a7f | 05c68f14c5d7b8bb202ab6dde22e0214b1cd4ee1 | refs/heads/master | 2020-04-23T00:48:33.306497 | 2019-02-27T03:46:40 | 2019-02-27T03:46:40 | 170,792,637 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 421 | py | import numpy as np
X = np.arange(15).reshape(5,3)
w = np.zeros((3, 1))
t = np.array([1,2,3,4,5])
t = np.reshape(t, (5, 1))
y_bar = np.dot(X, w) - t
# single: dL/ dw.T = (yi - ti) * xi - > dl / dw = (yi - ti) * xi.T
# multiple - > = y_bar = (np.dot(X, w) - t)
# res = np.dot(X.T, y_bar) / N
w_bar = np.dot(X.T, y_bar... | [
"[email protected]"
] | |
1fb0eac2c32fdf739ca1c6178dcee78561e16153 | 8cba955ce23f98e0a24dc8f8be04e305c4ba59ef | /model.py | 8f523915da7766efb21deaa5bbaee095b8367a84 | [] | no_license | amit20-meet/Y2L-Flask-Routing | 5ba3ae8c9631f18897faf6d7a794355ac9dd907a | 8ddac918a788bd68c065c9976487eb7f589b701a | refs/heads/master | 2020-09-14T17:58:14.881190 | 2019-12-12T14:59:42 | 2019-12-12T14:59:42 | 223,207,600 | 0 | 0 | null | 2019-11-21T15:41:05 | 2019-11-21T15:41:04 | null | UTF-8 | Python | false | false | 512 | py | from sqlalchemy import Column, Integer, String, Date, ForeignKey, Float, Boolean, DateTime
from sqlalchemy.ext.declarative import declarative_base
Base = declarative_base()
class Product(Base):
__tablename__ = 'products'
id = Column(Integer, primary_key=True)
name = Column(String)
price = Column(Float)
picture_l... | [
"[email protected]"
] | |
2c5e1e78f81d3c4f9a9b47f685b834307e66f8aa | 7a9f6e01c0450173a0a45bd70816a4be38021eda | /cliente/migrations/0009_auto_20151117_2109.py | a5f6d71b2be3d0455b483d4a777ab7235a44b6d6 | [] | no_license | ryujiin/lovizdigital | 6137726349e6bd1de866054ce37de90f783a3b38 | 9f14c83b976e1e47a2558b508396139145b67bf2 | refs/heads/master | 2021-01-10T03:54:41.460708 | 2016-10-14T02:10:32 | 2016-10-14T02:10:32 | 45,559,176 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 441 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('cliente', '0008_auto_20151117_2054'),
]
operations = [
migrations.AlterField(
model_name='comentario',
... | [
"[email protected]"
] | |
b682efa36350fb281b200657223293f02c8be285 | d6ca0b326f1bd0ce381c6db611f6331096bf4187 | /examples/example_18_many_runs.py | e04e292092de98147577f3188ad7b98029be7b6e | [
"BSD-3-Clause"
] | permissive | SmokinCaterpillar/pypet | aa35355d70e8f44be015313494376d993f645d80 | 3d454ac65f89e7833baaf89510f73c546e90d8f6 | refs/heads/develop | 2023-08-08T16:01:54.087819 | 2023-02-14T14:59:32 | 2023-02-14T14:59:32 | 12,901,526 | 89 | 22 | BSD-3-Clause | 2023-07-24T00:46:12 | 2013-09-17T17:06:00 | Python | UTF-8 | Python | false | false | 2,415 | py | """Exploring more than 20000 runs may slow down *pypet*.
HDF5 has problems handling nodes with more than 10000 children.
To overcome this problem, simply group your runs into buckets or sets
using the `$set` wildcard.
"""
__author__ = 'Robert Meyer'
import os # To allow file paths working under Windows and Linux
... | [
"[email protected]"
] | |
1eda218ffa2e3edd8b517b2eb124e9f95f1996c4 | c67831f476cb530fc0c26e0bf4258ce18e986749 | /backend/opsbot/command/argfilter/__init__.py | f929fa7ce2f64581dcd0d1bd5e2a4709dad4ffb0 | [
"MIT"
] | permissive | cz-qq/bk-chatbot | a3ce4b86452b3de0ff35430c1c85b91d6b23a3e6 | da37fb2197142eae32158cdb5c2b658100133fff | refs/heads/master | 2023-06-05T05:48:22.083008 | 2021-06-15T10:21:30 | 2021-06-15T10:21:30 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 931 | py | """
TencentBlueKing is pleased to support the open source community by making
蓝鲸智云PaaS平台社区版 (BlueKing PaaSCommunity Edition) available.
Copyright (C) 2017-2018 THL A29 Limited,
a Tencent company. All rights reserved.
Licensed under the MIT License (the "License");
you may not use this file except in compliance with the... | [
"[email protected]"
] | |
fc124f8b4453ed0ea2d82b9e548da280ea7e856d | 0cd09f64f7d42f60167c688a959ab1b4eec62caf | /sources/t06/t06ej03.py | 6e6fa34ed09a94cfe12c5ef1749df95a040a47e9 | [
"MIT"
] | permissive | workready/pythonbasic | 3d438250b2fce6b6d243f2a8a1f8c5ccc9734d8c | 59bd82caf99244f5e711124e1f6f4dec8de22141 | refs/heads/master | 2022-10-14T09:20:30.160865 | 2020-06-10T09:22:51 | 2020-06-10T09:22:51 | 270,270,853 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 287 | py | # Implementamos un constructor para nuestra clase, y dentro del constructor asignamos variables.
class MiClase:
def __init__(self, x, y):
# self.x y self.y son propias de la instancia, no compartidas
self.x = x
self.y = y
c = MiClase(7, 12)
print(c.x, c.y) | [
"[email protected]"
] | |
7a1a3bafcd8974fdc513d298fc7f66943334e152 | 974d04d2ea27b1bba1c01015a98112d2afb78fe5 | /test/legacy_test/test_mv_op.py | 14a4ada5727e896eb87ca2a3359b5f9f4e760a81 | [
"Apache-2.0"
] | permissive | PaddlePaddle/Paddle | b3d2583119082c8e4b74331dacc4d39ed4d7cff0 | 22a11a60e0e3d10a3cf610077a3d9942a6f964cb | refs/heads/develop | 2023-08-17T21:27:30.568889 | 2023-08-17T12:38:22 | 2023-08-17T12:38:22 | 65,711,522 | 20,414 | 5,891 | Apache-2.0 | 2023-09-14T19:20:51 | 2016-08-15T06:59:08 | C++ | UTF-8 | Python | false | false | 3,850 | py | # Copyright (c) 2020 PaddlePaddle 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 appli... | [
"[email protected]"
] | |
a80e5a089f37600ba430f6f29761a5e3e3bc6a52 | 4d4c197c49172549514af7845f2429772d0158c7 | /message/migrations/0003_delete_user_account.py | 6a1e9ea6b0bb8c49d85c29853a9aa0745e36b8ee | [] | no_license | vigneshhari/djangolife | 787147ca4195a9a066bf7fdf2f389435afc6cc0b | 1e3b7a6516e1b4fbb98117abec4fa166e6747250 | refs/heads/master | 2021-01-10T02:00:44.300142 | 2017-06-29T02:21:19 | 2017-06-29T02:21:19 | 48,617,422 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 325 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('message', '0002_auto_20151206_1835'),
]
operations = [
migrations.DeleteModel(
name='User_Account',
),
... | [
"[email protected]"
] | |
32ded32756b1b4f4f83fa1014ca01a88bfcc0928 | 1131198c6d53eed5aeacb8af7cfd5e4664f924e5 | /suggestion_baselines/HRED-qs/multi_bleu.py | bc4f5c96ca8b749f2fd68872137f47f4ad8213ed | [
"MIT"
] | permissive | polaris79/mnsrf_ranking_suggestion | d9f2a889e1ccd7f9993594ac212b3a2853f1b7eb | 5bd241fb49f08fa4937539991e12e5a502d5a072 | refs/heads/master | 2020-03-11T23:15:24.019548 | 2018-04-14T16:41:07 | 2018-04-14T16:41:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,302 | py | from functools import reduce
from math import exp, log
from collections import Counter
def ngram_count(words, n):
if n <= len(words):
return Counter(zip(*[words[i:] for i in range(n)]))
return Counter()
def max_count(c1, c2):
return Counter({k: max(c1[k], c2[k]) for k in c1})
de... | [
"[email protected]"
] | |
bf846570cdfda344627ed0134bc3cfe19b69e3b6 | 531be8455556ce2b1e171f71eb040fddd7eb7522 | /Chapter_4_5/gifts_calc.py | 15433eb8c94439a333675850b421dfd031bb4e4f | [] | no_license | tanc7/ACC_410_Tax_Calculator_Project | 8a8f206268b0fb69872d0cc7191e3e69a299dee6 | b6684f8a307f948dee653b7a81457d144866ba11 | refs/heads/master | 2021-01-23T16:19:55.737386 | 2017-07-11T00:32:28 | 2017-07-11T00:32:28 | 93,293,406 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,517 | py | from termcolor import colored
import os
import sys
import socket
import StringIO
import time
import operator
# os.chdir('/root/Documents/ACC_410_Exam_Calculator_Project')
os.chdir('/root/Documents/ACC_410_Exam_Calculator_Project/Chapter_4_5')
def red(string):
string = colored(string,'red',attrs=['bold'])
print ... | [
"[email protected]"
] | |
e774524468621c8b62228ad9b5e4bf70b776f035 | 2c872fedcdc12c89742d10c2f1c821eed0470726 | /pbase/day06/jiangyi/day06/day05_exercise/narcissistic.py | cbe324dd1bb5e88bff78735f37f05917d091fbdb | [] | no_license | zuigehulu/AID1811 | 581c3c7a37df9fa928bc632e4891fc9bafe69201 | 10cab0869875290646a9e5d815ff159d0116990e | refs/heads/master | 2020-04-19T16:33:04.174841 | 2019-01-30T07:58:24 | 2019-01-30T07:58:24 | 168,307,918 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 946 | py | # 4. 算出 100 ~ 999 范围内的水仙花数(Narcissistic Number)
# 水仙花数是指百位的3次方 + 十位的3次方 + 个位的3次方 等于原
# 数的整数
# 如:
# 153 = 1**3 + 5**3 + 3**3
# 答案:
# 153, 370, ....
# 方法1
# for x in range(100, 1000):
# bai = x // 100 # 百位
# shi = x % 100 // 10 # 十位
# ge = x % 10 # 个数
# if x == bai ** 3 +... | [
"[email protected]"
] | |
54857f8ce1335c730dd6913435514bdd95f0ec4d | 6c1a3dc849b1d84271caad0133387c7001a9704f | /Sep05/client01.py | 9c05f4d7af4e730c40cfc31f06a6225b9e242ab8 | [] | no_license | tnaswin/PythonPractice | f6207a4cf560b45c09af2f82d7365d4f0d16afaf | 8c20fa35bdf65aaf8ec899c217c10ffc7d4d3d64 | refs/heads/master | 2020-06-11T08:53:35.190582 | 2019-06-26T13:41:18 | 2019-06-26T13:41:18 | 193,908,616 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,149 | py | from __future__ import print_function
from twisted.internet import task
from twisted.internet.defer import Deferred
from twisted.internet.protocol import ClientFactory
from twisted.protocols.basic import LineReceiver
class EchoClient(LineReceiver):
end = "End!"
def connectionMade(self):
self.sendLi... | [
"[email protected]"
] | |
af6a652fa0f874ec7d1a8c91a4a5b77365f67462 | b8085ef607da70023214f105eb27bdbc713e596f | /Day2/Async3.py | 7774674800fd4e6e93ddc3f94d67f879c4b88f34 | [] | no_license | artheadsweden/python_adv_april19 | 893c9ec76e8505a580439b7a2fd7aa2776503c77 | 04eecd25d4a291dddd608d94968b217fed7b88d8 | refs/heads/master | 2020-05-07T13:41:15.545033 | 2019-04-11T18:47:22 | 2019-04-11T18:47:22 | 180,559,955 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 579 | py | import asyncio
import random
async def my_other(id):
process_time = random.randint(1, 5)
await asyncio.sleep(process_time)
print(f"Coroutine {id}, has successfully completed after {process_time} seconds")
async def my_coroutine():
tasks = []
for i in range(10):
tasks.append(asyncio.ensur... | [
"[email protected]"
] | |
b5dd0646b1b2c4b271da16df28f9fa635ae98a8c | 6162b166a93c60677b97b91c1f07be1511fd05e2 | /catkin_ws/src/jackal_hunt_rabbit/scripts/output.py | ae97f3dd5df85b938f61ff6c608095446704d1bb | [] | no_license | SiChiTong/fuzzy-eureka | d7c540e4349621097ee861e7337488ba46a2c718 | 61e2075cfd99520e0fb689e47aa73b3d43481f18 | refs/heads/master | 2021-08-24T09:04:28.384368 | 2017-12-08T23:30:23 | 2017-12-08T23:30:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 912 | py | #!/usr/bin/env python
import cv2
import numpy as np
font = cv2.FONT_HERSHEY_SIMPLEX
cv2.namedWindow("ouput", flags = cv2.WINDOW_NORMAL)
img = np.zeros((512, 2400, 3), np.uint8)
def draw_egg(color, count, x, y):
cv2.ellipse(img, (x, y), (140, 200), 0, 0, 360, color, -1)
cv2.putText(img, count, (x - 80, y + 1... | [
"[email protected]"
] | |
a149725c1bd9437f884bb652f73407173011b1b8 | 8e3a27091d51c3fd9681f5caf0534a0d3a36c3ff | /setup.py | d6e064fc1b06aca13b6baa6cd70dd4d6360354cb | [
"MIT"
] | permissive | DES-SL/EasyLens | c5c5d9dc5af7d6495027f7cfe51cdf48c0a098de | 97673d65abc00b945e7c6332e465c1d08fcb09a9 | refs/heads/master | 2020-04-06T07:09:07.342981 | 2016-11-08T10:47:20 | 2016-11-08T10:47:20 | 58,768,462 | 1 | 0 | null | 2016-05-20T06:19:18 | 2016-05-13T19:51:37 | Jupyter Notebook | UTF-8 | Python | false | false | 2,058 | py | #!/usr/bin/env python
import os
import sys
from setuptools.command.test import test as TestCommand
from setuptools import find_packages
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.e... | [
"[email protected]"
] | |
2b3018fd53876b1bd94dc8c35c89202502fb585b | 13131e0e4805aa48bf64647f5da666e2e72dab9a | /misc/aggregate_logs_and_stats.py | 1b29c5437f03387cef5aede4d88bb57b7142ffbc | [] | no_license | m-bain/collaborative-experts | 4ae6632f0ec36b612b768048b2daa623d8b4c385 | 3a224ecad6fe36722112181c3ac48f918a799081 | refs/heads/master | 2021-01-08T19:43:14.689074 | 2020-02-16T06:05:06 | 2020-02-16T06:05:06 | 242,124,924 | 1 | 0 | null | 2020-02-21T11:35:41 | 2020-02-21T11:35:40 | null | UTF-8 | Python | false | false | 2,161 | py | """Aggregate logs across multiple seeded runs and summarise their statistics.
"""
import argparse
import logging
from pathlib import Path
from collections import OrderedDict
from utils.util import read_json
from logger.log_parser import log_summary
def summarise(group_id, log_dir="data/saved/log", model_dir="data/sa... | [
"[email protected]"
] | |
6b39dee81dd9f2c3d18cd4ad5ec017627ab539e7 | 8fcc27160f8700be46296568260fa0017a0b3004 | /client/spacecomponents/server/eventLogger.py | fb49f52c4e8741c49e6cc178d8184b066a6f509d | [] | no_license | connoryang/dec-eve-serenity | 5d867f4eedfa896a4ef60f92556356cafd632c96 | b670aec7c8b4514fc47cd52e186d7ccf3aabb69e | refs/heads/master | 2021-01-22T06:33:16.303760 | 2016-03-16T15:15:32 | 2016-03-16T15:15:32 | 56,389,750 | 1 | 0 | null | 2016-04-16T15:05:24 | 2016-04-16T15:05:24 | null | UTF-8 | Python | false | false | 1,022 | py | #Embedded file name: e:\jenkins\workspace\client_SERENITY\branches\release\SERENITY\packages\spacecomponents\server\eventLogger.py
from eveexceptions.exceptionEater import ExceptionEater
EVENT_DECAYED = 'spacecomponent::decay_Decayed'
EVENT_BECOMEACTIVE = 'spacecomponent::activate_BecomeActive'
class EventLogger(... | [
"[email protected]"
] | |
ad194816a6379fa3222c48a90e327ef99945ece2 | a8b17b17f9b2a640013064c50e1cebc27a7a68de | /16-statistical-thinking-in-python-pt2/01-parameter-estimation-by-optimization/01-how-often-do-we-get-no-hitters.py | 8e07aef449d1b4f71f6836c43205c929a66754b4 | [] | no_license | JohnnyFang/datacamp | 20eae09752521f14006cb3fda600b10bd7b12398 | 0fa8fa7682c23b0eb07bd03e4b75f5b77aeafa75 | refs/heads/master | 2020-04-18T00:27:37.358176 | 2020-02-04T20:54:19 | 2020-02-04T20:54:19 | 167,078,316 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,031 | py | '''
How often do we get no-hitters?
The number of games played between each no-hitter in the modern era (1901-2015) of Major League Baseball is stored in the array nohitter_times.
If you assume that no-hitters are described as a Poisson process, then the time between no-hitters is Exponentially distributed. As you ha... | [
"[email protected]"
] | |
6bf01c4d7cdaa26a436edc642c3871f8a1df6b49 | 9be5b6259e4db9a9386d5e6eea59bfb4ed4ccdbd | /liberapay/notifications/web.py | d3677868d705e6ac8647ec0f6c6f06ec7f41dc0b | [
"CC0-1.0",
"LicenseRef-scancode-public-domain"
] | permissive | Changaco/liberapay.com | b3e040ed24d47a6ebccdd0b2285526f02b4103cc | 4d134508c911f23478e80b8d8ff62223b866bb5e | refs/heads/master | 2021-01-16T21:47:57.475734 | 2015-09-02T15:41:50 | 2015-09-02T15:41:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,371 | py | from __future__ import division, print_function, unicode_literals
def withdrawal_failed(_, user, exchange):
href = '/%s/receiving/payout?exchange_id=%s' % (user.username, exchange.id)
return ('danger',
['a',
{'href': href}, _("The transfer to your bank account has failed!"),
]
... | [
"[email protected]"
] | |
5186b10cd80cab8f8320b0162dfd8881526c443f | 93a613f09d564a1d45ecc01b54b73745ce2850b7 | /majora2/management/commands/load_counties.py | 7e60d9acd4fc67489980ad313b871f818eb9608d | [] | no_license | pythseq/majora | fa17c77fa8a916c688fd2b40744d768dd851b99b | 40b918d32b4061cddee5f7279f97e70eb894623d | refs/heads/master | 2022-12-23T20:09:41.233844 | 2020-09-28T18:18:42 | 2020-09-28T18:18:42 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 574 | py | from django.core.management.base import BaseCommand, CommandError
from majora2 import models
class Command(BaseCommand):
help = "Load a list of counties"
def add_arguments(self, parser):
parser.add_argument('filename')
def handle(self, *args, **options):
fh = open(options["filename"])
... | [
"[email protected]"
] | |
ca32ac6e38b9a3d4b55c6c625ef3bc8c727a7bb3 | 3c17e189622018329bc0ebd8523eae8db9f3112a | /ykdl/util/wrap.py | de6d61b463f96d1bc0bb8f01bef4d73c3470f3b0 | [
"MIT"
] | permissive | YU-zreo/ykdl | 167c9b8715a1cecf57c18bf60c7da3b22437ad06 | b59dacd78bcec79d208d7cb86b86fa65428e386a | refs/heads/master | 2020-12-02T12:47:01.113309 | 2017-07-07T12:39:20 | 2017-07-07T12:39:20 | 96,594,712 | 1 | 0 | null | 2017-07-08T03:57:22 | 2017-07-08T03:57:21 | null | UTF-8 | Python | false | false | 1,580 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import subprocess
import shlex
from logging import getLogger
logger = getLogger("wrap")
from ykdl.compact import compact_tempfile
def launch_player(player, urls, **args):
if 'mpv' in player:
cmd = shlex.split(player) + ['--demuxer-lavf-o=protocol_whitelist=... | [
"[email protected]"
] | |
5a4d7837248354b88c88b465c3cbd58a4b15c328 | 0b1e404a165c960677d07015bc26aac0569cf84a | /src/combustion/nn/activations/swish.py | de70fb4f298b010d397300b048a83d7107bb6a6f | [
"Apache-2.0"
] | permissive | johndpope/combustion | d3ec349cd7be086f55b4e3deebd571c97842e1ed | c3f91e62a10a873cfeeae8c675b0683bc5158818 | refs/heads/master | 2023-03-01T14:34:42.149415 | 2021-02-07T17:55:58 | 2021-02-13T17:17:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,077 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import torch
import torch.nn as nn
import torch.nn.functional as F
from torch import Tensor
# implementation inspired by
# https://github.com/lukemelas/EfficientNet-PyTorch/blob/master/efficientnet_pytorch/utils.py
class _SwishFunction(torch.autograd.Function):
@st... | [
"[email protected]"
] | |
f784b3a01ba171e37e1998ab9f4997ed520f1cbe | 22622d1899ac2a37c66d776e317a7c752b2fb10e | /rio/_compat.py | 3e05ed7366dbb45a1f3df523a9be3de33fa28f95 | [
"MIT"
] | permissive | soasme/rio | 64bb3e24580c18951d5eaf84809216785ae35020 | e6b89634db8d3ad75ac7f7b25ddec5b19d4f66e2 | refs/heads/master | 2022-01-23T01:48:17.445050 | 2019-12-30T02:36:50 | 2019-12-30T02:36:50 | 55,581,621 | 0 | 1 | MIT | 2019-12-30T02:39:58 | 2016-04-06T06:34:59 | Python | UTF-8 | Python | false | false | 315 | py | # -*- coding: utf-8 -*-
"""
rio._compact
~~~~~~~~~~~~~
"""
try:
import cPickle as pickle
except ImportError:
import pickle # noqa
try:
from cStringIO import StringIO
except ImportError:
from StringIO import StringIO # noqa
try:
import simplejson as json
except ImportError:
import json
| [
"[email protected]"
] | |
c07b1b463ef553ac6896b1ab101ae7c439731385 | c56ffb7215547b658e6698bc4bbe78fbd0e3330b | /3.1 Conditional Statements Advanced - Exercise/02-summerOutfit.py | 9fe22dd121ed0949664396b2184c89cbc50fc5bd | [] | no_license | byAbaddon/Basics-Course-Python-November-2020 | 344646bbb33740d15bec94fd5b5d7cd257df9220 | c6c17a5cdc29121d706bc7677a61637a9bcefbb1 | refs/heads/main | 2023-04-16T01:00:10.000371 | 2023-04-10T20:46:11 | 2023-04-10T20:46:11 | 316,531,468 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 810 | py | degrees = int(input())
day_time = input()
result = 0
data_dict = {
'm': {'Morning':'Sweatshirt and Sneakers', 'Afternoon': 'Shirt and Moccasins', 'Evening': 'Shirt and Moccasins'},
'a': {'Morning':'Shirt and Moccasins', 'Afternoon': 'T-Shirt and Sandals', 'Evening': 'Shirt and Moccasins'},... | [
"[email protected]"
] | |
6684bd853d6ef7bafa5052fab25a9722778e5c79 | a193a941a9f70dd0aa46e7a402265bfff27bb075 | /tests/codecs/formats/test_wav.py | ea60a4ef2fba103e2ff55f42f4466be82d316a33 | [
"0BSD"
] | permissive | hile/oodi | f3c606b5209c2b05e077d9039104df7187ba0b1c | f3a758238033c0a511e1ecffbb4b5bfde70efbda | refs/heads/main | 2023-04-13T07:07:03.535176 | 2023-04-10T07:17:44 | 2023-04-10T07:17:44 | 196,691,234 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 983 | py | """
Unit tests for oodi.codecs.formats.wav module
"""
from pathlib import Path
from oodi.codecs.constants import CodecFormat
from oodi.codecs.formats.wav import Wav
from .validators import validate_codec_properties, TEST_FILENAME_NO_MATCH
TEST_FILENAME_MATCH = f'test case.{CodecFormat.WAV.value}'
def test_codecs_f... | [
"[email protected]"
] | |
e5071c6b16895e33b46c923d938f1b8ff8361ee1 | b5a9d42f7ea5e26cd82b3be2b26c324d5da79ba1 | /tensorflow/tools/test/check_futures_test.py | f0c4d0d47930e2ca716933f9f677440922daf5ca | [
"Apache-2.0"
] | permissive | uve/tensorflow | e48cb29f39ed24ee27e81afd1687960682e1fbef | e08079463bf43e5963acc41da1f57e95603f8080 | refs/heads/master | 2020-11-29T11:30:40.391232 | 2020-01-11T13:43:10 | 2020-01-11T13:43:10 | 230,088,347 | 0 | 0 | Apache-2.0 | 2019-12-25T10:49:15 | 2019-12-25T10:49:14 | null | UTF-8 | Python | false | false | 4,053 | py | # Copyright 2015 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... | [
"[email protected]"
] | |
0fb2282d3b84448e01b5dcc2f4bd64681db1bbb0 | fabc3b3286df0fa98a35ea90d4693d9f38db50a2 | /sendJsonRequest.py | a84652870f3a942e8fd181669bc76831b3cc1e21 | [] | no_license | yangtou45du/openpyxl | 750b5ee23ce8e5cb6826b8cc137012fbf2a5d9cb | 87eef380391e60eab81f93c7742d1c21b1d029de | refs/heads/master | 2020-03-16T21:59:35.078761 | 2018-05-31T03:42:03 | 2018-05-31T03:42:03 | 133,022,587 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 466 | py | import requests
import json
class sendRequest():
def POST(self,url,dict):
re=requests.post(url,json=dict)
return re.text
if __name__ == '__main__':
url="http://221.236.20.217:8093/pcl/services/loanCenter/account/queryPaymentHistory"
dict={
"params": {
"loanNo": "00000... | [
"[email protected]"
] | |
59773eb3cc899c7e48f6283380f46e6b5d8902c3 | 55c250525bd7198ac905b1f2f86d16a44f73e03a | /Python/Projects/pyinstaller/tests/old_suite/interactive/test_pygame.py | bc4b2ab4e66186771f7e4675c2622bd8225cad3d | [
"LicenseRef-scancode-other-permissive"
] | permissive | NateWeiler/Resources | 213d18ba86f7cc9d845741b8571b9e2c2c6be916 | bd4a8a82a3e83a381c97d19e5df42cbababfc66c | refs/heads/master | 2023-09-03T17:50:31.937137 | 2023-08-28T23:50:57 | 2023-08-28T23:50:57 | 267,368,545 | 2 | 1 | null | 2022-09-08T15:20:18 | 2020-05-27T16:18:17 | null | UTF-8 | Python | false | false | 129 | py | version https://git-lfs.github.com/spec/v1
oid sha256:82d416a54f2704d7f86702c9d4fca758c3922aabd54f55bd79bc5d55d8cb8592
size 8156
| [
"[email protected]"
] | |
8a43127609e4f347391453d0dab8d410e2ee6d3d | dc456b315dc6988fbc37a92e8c1af8987205c9fa | /holiday/countries/poland.py | 5d59cee331e259533d6991ba00d5467cc7251f70 | [
"MIT"
] | permissive | Lionbridge-Technologies/holiday | 83bf8e0d665828e75429b519e3b85294475ecb64 | e8fa1628efdc81ed2f3452cf7009de605968cb76 | refs/heads/master | 2021-01-13T08:58:09.830066 | 2013-11-10T21:50:58 | 2013-11-10T21:50:58 | 69,601,979 | 0 | 1 | null | 2016-09-29T19:46:17 | 2016-09-29T19:46:16 | null | UTF-8 | Python | false | false | 1,582 | py | # -*- coding: utf-8 -*-
'''Holiday information for Poland. Adapted from
https://gist.github.com/sebzur/1810707
'''
from __future__ import (absolute_import, division, print_function,
unicode_literals)
from datetime import date, timedelta
from dateutil import easter
from dateutil.relativedelta i... | [
"[email protected]"
] | |
2d40f0bfb1b559ceab1fa73202905567d7c26083 | 24c5c46f1d281fc15de7f6b72a5148ae85f89fb4 | /SRC/demo/imooc/imooc_advanced/对象迭代与反迭代/part5.py | 3baf32b97753c3d1764be42a9bf4906e61683e3c | [] | no_license | enterpriseih/easyTest | 22d87c7ffe40fb10a07f7c5cdd505f63dd45adc0 | 43b8d294e898f25055c78313cfece2753352c250 | refs/heads/master | 2023-08-23T22:55:14.798341 | 2020-02-11T09:13:43 | 2020-02-11T09:13:43 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 753 | py | # 如何对迭代器做切片操作
# 实际案例:有某个文本文件,我们想读取其中某范围的内容如100~300行之间的内容,
# python中文本文件是可迭代对象,我们是否可以使用类似列表切片的方式得到一个
# 100~300行文件内容的生成器?
# f=open('')
# f[100:300] 可以吗
# 使用标准库中的itertools.islice,它能返回一个迭代对象切片的生成器
from itertools import islice
f=open('part1.py',encoding='utf-8')
# for x in f:
# print(f.readline())
for line in islice(f... | [
"yaolihui0506"
] | yaolihui0506 |
21f5c6a34e88da9ea700f99dfdcc7834a7aefe05 | 6ead0d3997aa3470fc6f49c6ccc0ac8f808ae5d7 | /problems/python/findPeakElement.py | 54ddbd13b948a36ca234c81c0125b7d55d9dc703 | [] | no_license | ikedaosushi/leetcode | d405455bfffda3057259da78783901feb56d9f76 | d378f2dc5f0b2df1f00208e304979ac0f53ab385 | refs/heads/master | 2021-06-24T04:31:56.586685 | 2020-12-08T13:51:18 | 2020-12-08T13:51:18 | 178,659,078 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 474 | py | from typing import List
class Solution:
def findPeakElement(self, nums: List[int]) -> int:
if len(nums) <= 1:
return 0
if nums[0] > nums[1]:
return 0
if nums[-2] < nums[-1]:
return len(nums) - 1
i = 1
while i < len(nums) - 1:
... | [
"[email protected]"
] | |
251e492a5dd723d7807866355d7f4487306bc38d | 0a7711063b30b1566ade3cc07f105292e32fe6d6 | /scrapy_test/aggregates/apartment/tests/integration/test_apartment_behavior.py | 2c4e1054d5b46d3ecaff69fa4cd40a24006fb188 | [] | no_license | huokedu/dynamic-scrapy | e150a1fc6894e39d6bae37c602a592d57cd22c51 | 31a47e9810f2039cfe33653e09d7d03242764723 | refs/heads/master | 2021-01-17T21:33:17.810250 | 2013-10-05T17:28:19 | 2013-10-05T17:28:19 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 774 | py | import pytest
from scrapy_test.aggregates.apartment.services import apartment_service
from scrapy_test.aggregates.listing.models import Listing
from scrapy_test.aggregates.listing.services import listing_service
from scrapy_test.aggregates.listing.tests import listing_test_data
@pytest.mark.django_db_with_migrations
... | [
"[email protected]"
] | |
12808eccde179a2a86faac55bccb1419289b162f | cc20c7658fdf4fa7506625c9efdae792dfd857ce | /src/visionlouisville/utils.py | 8f17dc56324ff01681c7cff2368133b2fa2a242e | [] | no_license | openplans/visionlouisville | 4a9972adc97af0048c4f7c0cd8f642bef59e69cf | e4dc182d061866e80ae140a887bba1b0e967753c | refs/heads/master | 2020-05-20T13:25:47.273430 | 2013-10-24T16:27:47 | 2013-10-24T16:27:47 | 10,971,764 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 809 | py | from django.conf import settings
from itertools import combinations, islice
from random import randint
def uniquify_tweet_ids(queryset):
"""Ensure that the tweet_ids of all items in the queryset are unique"""
all_different = False
while not all_different:
all_different = True
for referrenc... | [
"[email protected]"
] | |
19e37018d09be7a049a1eb9e51bdf5f7e821a01a | 46c38a849a96ca868b1efaa8280be7416e15f952 | /goslinks/blueprints/auth.py | 3fc63ffc1366208b6bd7351e53fdf2521ccce5a9 | [
"ISC"
] | permissive | RevolutionTech/goslinks | 066b7f08a05bb68b6440bab4e670e537d0f1960f | fedb91a0d4ab227ba926f4588c7feeb3af284d2b | refs/heads/main | 2023-02-20T17:25:50.052529 | 2021-10-16T23:19:28 | 2021-10-16T23:19:28 | 184,518,945 | 1 | 0 | ISC | 2023-02-08T00:51:24 | 2019-05-02T04:07:12 | Python | UTF-8 | Python | false | false | 500 | py | from flask import Blueprint, redirect, session
from goslinks.auth.constants import AUTH_EMAIL_KEY, AUTH_NEXT_URL_KEY
from goslinks.auth.decorators import no_cache
bp = Blueprint("auth", __name__)
@bp.route("/logout/")
@no_cache
def logout():
# Deprecated session variables, to be removed after 2020/10/13
ses... | [
"[email protected]"
] | |
269883af7e8c26cec4f9f1501eb31440733b33e5 | 2534803a09f5a6676ccece4519a2b8faaea9329d | /zeno/test/propagate/helper.py | dc33a738b861d6a9fd3e317a8adb5d9b0f2649da | [
"Apache-2.0"
] | permissive | SmithSamuelM/plenum | c41ccb849cd1113ba8496fa8bd9b0c5336ee9878 | 2675523f8718d6f240027582bc90c76b4f80c105 | refs/heads/master | 2021-01-15T23:35:53.640499 | 2016-02-16T05:01:22 | 2016-02-16T05:01:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 580 | py | from zeno.common.request_types import Propagate
from zeno.test.helper import TestNode, getAllArgs
def sentPropagate(node: TestNode):
params = getAllArgs(node, TestNode.send)
return [p for p in params if isinstance(p['msg'], Propagate)]
def recvdPropagate(node: TestNode):
return getAllArgs(node,
... | [
"[email protected]"
] | |
7d3f4e0a5031f9ce618c568b440c7425489060a1 | 16631cf7cd4a70f2cd2750851649d3eff5e17724 | /2019/day06/part1.py | d5325cb19e7543fcf23dde0b345f5a8f5535efa1 | [] | no_license | kynax/AdventOfCode | 1dd609a3308d733f2dd7d4ea00508d2da73180b9 | 36a339241dd7a31ebe08a73e5efa599e5faeea1a | refs/heads/master | 2022-12-21T13:32:52.591068 | 2022-12-16T22:41:30 | 2022-12-16T22:41:30 | 48,439,585 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,048 | py | import sys
class Obj:
def __init__(self, name):
self.name = name
self.down = []
def add_child(self, obj):
self.down.append(obj)
def prnt(self, prev):
if not self.down:
print(prev + '=' + self.name)
else:
for d in self.down:
... | [
"[email protected]"
] | |
dc099d384ffc6b9326adbfb10628a62857513c67 | cbc829f5787b770c9184b91ee470d058cc4cbe65 | /backtrack/46_全排列.py | b21c5927665b36a64df5503725fa3d085639de52 | [] | no_license | SilvesSun/learn-algorithm-in-python | 58815e7e85e767cbc4a9c21e36e7bdede4f32bef | 5ba3465ba9c85955eac188e1e3793a981de712e7 | refs/heads/master | 2022-09-19T05:10:26.783943 | 2022-09-10T04:56:43 | 2022-09-10T04:56:43 | 115,470,779 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 613 | py | class Solution(object):
def permute(self, nums):
"""
:type nums: List[int]
:rtype: List[List[int]]
"""
if not nums:
return
res = []
def backtrack(_nums, track):
if not _nums:
res.append(track[:])
return... | [
"[email protected]"
] | |
01c6a82363241a9064bcdc20ba495dec968eb0ca | 9461195cac30788855359753ac2856d746e81cd6 | /apps/estado_flujo/forms.py | 4e5747b61b4e54b2f824df8dd33ccf4402278ed3 | [] | no_license | ChristianSmith18/python-project | e15460b29e29a6bb841c82a762618f7ff86ab724 | 76d876f3fded93643af58e65f183bb6403beb755 | refs/heads/master | 2023-04-30T15:30:48.472909 | 2021-05-24T17:33:46 | 2021-05-24T17:33:46 | 370,433,052 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 484 | py | from django import forms
from apps.estado_flujo.models import Glo_EstadoFlujo
class estadoFlujoForm(forms.ModelForm):
class Meta:
model = Glo_EstadoFlujo
fields = [
'descripcion_estado',
'estado',
]
widgets = {
'descripcion_... | [
"[email protected]"
] | |
6d2e0a26d4c7ad4f0faf749760e2e908565be54d | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/nouns/_splotches.py | ed0d1adf3f190745463d7e746b1ad80895ac0e75 | [
"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 | 247 | py |
from xai.brain.wordbase.nouns._splotch import _SPLOTCH
#calss header
class _SPLOTCHES(_SPLOTCH, ):
def __init__(self,):
_SPLOTCH.__init__(self)
self.name = "SPLOTCHES"
self.specie = 'nouns'
self.basic = "splotch"
self.jsondata = {}
| [
"[email protected]"
] | |
88dfa41087978b540b432a730f6068e9e609f5bc | 2edfa18568b02e63757da73254c09e195b9f4efa | /evaluation/nejm/evaluate.py | 7e2fcaf57a3bb27d779b4998aa9d3e4d76e406dd | [] | no_license | boxiangliu/ParaMed | 65e67977c88c1ce2166d08d6d40a33f6961a3486 | 08484488f4829bf144303a2e348c79e4e2ae5f71 | refs/heads/master | 2023-05-02T22:14:31.911384 | 2021-05-15T21:44:51 | 2021-05-15T21:44:51 | 217,118,327 | 19 | 1 | null | null | null | null | UTF-8 | Python | false | false | 4,436 | py | import argparse
import os
import pandas as pd
pd.options.display.max_columns = 99
import numpy as np
from collections import defaultdict
parser = argparse.ArgumentParser(description="Generate precision-recall "\
"table for sentence alignments.")
parser.add_argument("--align_fn", type=str, help="Path to ground-truth ... | [
"[email protected]"
] | |
eed94a71c7239fbdd541de9a4417a48de3d95475 | ab670d6e59ebd4a0c23fa867fb77866d223163da | /Python/Problem029.py | 7fedb1207b0e2cc07512acac43d00c69115028a9 | [] | no_license | JeromeLefebvre/ProjectEuler | 18799e85947e378e18839704c349ba770af4a128 | 3f16e5f231e341a471ffde8b0529407090920b56 | refs/heads/master | 2020-07-05T02:42:44.844607 | 2014-07-26T01:04:38 | 2014-07-26T01:04:38 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 760 | py |
'''
Distinct powers
Problem 29
Consider all integer combinations of ab for 2 ≤ a ≤ 5 and 2 ≤ b ≤ 5:
22=4, 23=8, 24=16, 25=32
32=9, 33=27, 34=81, 35=243
42=16, 43=64, 44=256, 45=1024
52=25, 53=125, 54=625, 55=3125
If they are then placed in numerical order, with any repeats removed, we get the following sequence of 15... | [
"[email protected]"
] | |
3bf61bbfa5ba4d78c42105bc36280e5ed2f3f3b2 | 34c01d4bf7ae13b15bfbcfd90ff39f5353971820 | /examples/reactive.py | cb3d656e3187fae427834a62122f2958b8199bf1 | [] | no_license | nvbn/microasync | c78d8684119fe6cbcd1ece762a15d64940ff9eb6 | 9e4975ed5077f133051bc80c1d54042dac5b78c7 | refs/heads/master | 2021-01-23T08:56:52.382753 | 2014-10-23T20:13:49 | 2014-10-23T20:13:49 | 23,565,211 | 5 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,559 | py | from microasync.async import coroutine, as_chan, Channel, do_all, select
from microasync.device import get_switch, get_output_pin
@as_chan(Channel)
def get_bicolor_led(chan, left, right):
left_pin = get_output_pin(left)
right_pin = get_output_pin(right)
while True:
msg = yield chan.get()
p... | [
"[email protected]"
] | |
0f7b6291b1f5cf75ec7597313122777012517352 | f875b0d80254c8f6eee4e5887869442a8abf60e4 | /Official_OpenCV_Docs/Image_Processing_In_OpenCV/changing_color_spaces.py | 2065a51ee24f675278df82863552b3ccb6733902 | [] | no_license | AmitKulkarni23/OpenCV | 6d9320fa9e4fd41af4806cda6df0fb2c641d7884 | 449468f4c9c84ffb5b66ab352086e5b23f342b45 | refs/heads/master | 2020-03-19T12:36:23.305898 | 2018-09-16T00:53:51 | 2018-09-16T00:53:51 | 136,528,669 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,703 | py | # Python file which captures video from teh camera and displays only the red color
# Everything else is blacked out
# OpenCV has >150 color spaces
# But 2 of teh important ones are BGR -> HSV and BGR -> Gray
# Changing Colorspaces - used API cv2.cvtColor
# Why HSV for color detection?
# Will help in pinpointing a mor... | [
"[email protected]"
] | |
eab66c8739d2f800e313c946eeac35d82206b0f6 | 2b832e5d3d88b25998f44d21fdb3fa40c2072a9e | /testcase/api/__init__.py | fb1bdccf22a848238c4b584cbd9bcd23639dd0a1 | [
"MIT"
] | permissive | lijunzhe123/Automation | 387536505e0b77fd9cc1d7dc9d017dc1268925eb | 18122ce2c5debe485fab7dac5f8007f4b7b2d51f | refs/heads/main | 2023-06-17T10:04:51.296922 | 2021-07-10T17:58:56 | 2021-07-10T17:58:56 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 170 | py | #!/usr/bin/env python3
# -*- encoding: utf-8 -*-
'''
@author: yuejl
@application:
@contact: [email protected]
@file: __init__.py.py
@time: 2021/7/8 0008 20:59
@desc:
''' | [
"[email protected]"
] | |
134ea0ae19f609e515c711126a5c421c4f2b288a | 850c6fd59110bbdd89a28a2ebd117be04ce3917a | /nengo_normal_form/hosted.py | 4cbcbcb5084393bea9907aeb717900c91f30748e | [
"MIT"
] | permissive | tcstewar/nengo_normal_form | e56b35b5cb36a0ed659528ab83e1116bda3dfb32 | 37ca02b20c4cc143a7bf9c27912ead36d23a04d7 | refs/heads/master | 2021-01-01T19:44:39.556970 | 2018-05-15T22:08:06 | 2018-05-15T22:08:06 | 98,668,081 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,597 | py | import nengo_normal_form
import nengo
import numpy as np
from .generic import GenericSimulator
class Host2Client(nengo.Node):
def __init__(self, conn):
self.latest_time = 0
self.latest_x = np.zeros(conn.size_out)
super(Host2Client, self).__init__(self.update,
... | [
"[email protected]"
] | |
00104352c1370d91932fa8d8269ab961641f0546 | 5201e237c0d58cdfdbc2fdf8103f9141161eb9f8 | /ITKFastMarchingPython.pyi | 29ae0da83b4f80330b389cd611cb717d8648dacb | [] | no_license | hjmjohnson/itk-stubs | 704f5b92a755e55b81d02fcad62a366143e125f3 | 771951d007ae425b758e088eae6f9e4ca0e4afb1 | refs/heads/main | 2023-01-22T05:50:33.649088 | 2020-12-04T01:31:09 | 2020-12-04T01:35:06 | 318,368,028 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 788 | pyi | from itk.itkLevelSetNodePython import *
from itk.itkNodePairPython import *
from itk.itkFastMarchingStoppingCriterionBasePython import *
from itk.ITKFastMarchingBasePython import *
from itk.itkFastMarchingImageFilterBasePython import *
from itk.itkFastMarchingExtensionImageFilterPython import *
from itk.itkFastMarching... | [
"[email protected]"
] | |
0a32b3ef2fb132f35bbac420ae65c23c9a600a2d | 4dc0b92ae40c4bb90e4549732cab8b1f2d4305c6 | /platforms/windows/dos/8232.py | c9204be6911fdfac7062141a0fd3580830f5263a | [] | no_license | xiaohen/exploit-database | be462a39978d6309ae98677e662dc8b228f936a8 | d02449c714d2df225eba6f55b65d9840e6d19a5f | refs/heads/master | 2021-01-17T10:00:13.535969 | 2014-03-02T04:29:43 | 2014-03-02T04:29:43 | 17,334,511 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 799 | py | #!/usr/bin/python
# Chasys Media Player 1.1 (.pls) Local Buffer Overflow (SEH) PoC
# SEH And NEXT_SEH are Overwritten but shellcode doesn't executed !!!
# I have tried a lot of Addresses .
# Waitting for the Exploit from someone .
# Download : http://www.jpcha2.com/setup/chasys_media_player.zip
print " Chasys Media Pl... | [
"[email protected]"
] | |
704c318e614ef0ed1ac677b6e615272c162d3661 | 09e57dd1374713f06b70d7b37a580130d9bbab0d | /benchmark/startQiskit_Class36.py | e0acf1a88e1f96250e4f122e4227bc4cdb34de6e | [
"BSD-3-Clause"
] | permissive | UCLA-SEAL/QDiff | ad53650034897abb5941e74539e3aee8edb600ab | d968cbc47fe926b7f88b4adf10490f1edd6f8819 | refs/heads/main | 2023-08-05T04:52:24.961998 | 2021-09-19T02:56:16 | 2021-09-19T02:56:16 | 405,159,939 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,427 | py | # qubit number=3
# total number=9
import numpy as np
from qiskit import QuantumCircuit, execute, Aer, QuantumRegister, ClassicalRegister, transpile, BasicAer, IBMQ
import networkx as nx
from qiskit.visualization import plot_histogram
from typing import *
from pprint import pprint
from math import log2
from collection... | [
"[email protected]"
] | |
5cbb883ea1c04efe8a7a2cef7957a2a2273cf727 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03946/s811408190.py | 1dcbe0bb3e40ad9cf5592528edaf02ff138bc42a | [] | 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 | 589 | py | N,T = map(int,input().split())
A = list(map(int,input().split()))
data = [0]*(N-1)
M = [0]*N
M[N-1] = A[N-1]
M_index = [N-1]*N
for i in range(2,N+1):
if A[N-i] > M[N-i+1]:
M[N-i] = A[N-i]
M_index[N-i] = N-i
else:
M[N-i] = M[N-i+1]
M_index[N-i] = M_index[N-i+1]
data[N-i] = M... | [
"[email protected]"
] | |
534d7a8d361d7a451f2b98d94d9b4539fe824687 | de24f83a5e3768a2638ebcf13cbe717e75740168 | /moodledata/vpl_data/137/usersdata/218/47092/submittedfiles/Maratona.py | 6d8876f8f1158c2fd5d5be7ed13195de53f89d34 | [] | no_license | rafaelperazzo/programacao-web | 95643423a35c44613b0f64bed05bd34780fe2436 | 170dd5440afb9ee68a973f3de13a99aa4c735d79 | refs/heads/master | 2021-01-12T14:06:25.773146 | 2017-12-22T16:05:45 | 2017-12-22T16:05:45 | 69,566,344 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 412 | py | # -*- coding: utf-8 -*-
N=int(input('digite o numero de postos da prova:'))
M=int(input('digite a distancia de alcance maxima entre os postos:'))
maxima=42195
minima=0
cont=0
for i in range (0,N,1):
p=int(input('digite a posição do posto:'))
if p<minima:
minima=p
if p>maxima:
maxima=p
if... | [
"[email protected]"
] | |
90183842ee994ee4c500c4ac32e0e8ac30df18d8 | 15f321878face2af9317363c5f6de1e5ddd9b749 | /solutions_python/Problem_118/2306.py | 480ae3036f9ad1679c427e947506870bf81d64db | [] | no_license | dr-dos-ok/Code_Jam_Webscraper | c06fd59870842664cd79c41eb460a09553e1c80a | 26a35bf114a3aa30fc4c677ef069d95f41665cc0 | refs/heads/master | 2020-04-06T08:17:40.938460 | 2018-10-14T10:12:47 | 2018-10-14T10:12:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 717 | py | import sys
import math
def is_palindrom(number):
return str(number) == str(number)[::-1]
def make_work(input='input.txt', output='output.txt'):
file_in = open(input)
cases_number = int(file_in.readline().strip())
for n in xrange(cases_number):
case_number = n + 1
a, b = map(int, file_in.readlin... | [
"[email protected]"
] | |
5cbd9ab1e7cbca8d9043ca2d795fd3e2e95dce6d | e63ab09f227459380c317aa1694cffd04255c807 | /cheshire3/lucene/indexStore.py | d8219db0cb88d5d868bd9d0e3bef35b30995337d | [
"ICU",
"X11"
] | permissive | bitwhite/cheshire3 | 91a0d2f8d2e79ac277ac4f7a3bea9efa911ce3d6 | ca27bc2600d217e36a429ccfe064f11d9b200193 | refs/heads/master | 2021-05-27T03:50:09.456813 | 2013-10-10T13:47:16 | 2013-10-10T13:47:16 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,186 | py |
from cheshire3.baseObjects import IndexStore
from cheshire3.lucene.utils import NullC3Analyzer, C3TokenStream, cqlToLucene
from cheshire3.resultSet import SimpleResultSet, SimpleResultSetItem
import lucene
class LuceneIndexStore(IndexStore):
def __init__(self, session, config, parent):
IndexStore.__ini... | [
"[email protected]"
] | |
97373bd89810120c5216516ef09d1046ca0c6302 | 509c3eb9d205be19426c01f222a6e5870cca256f | /runs/sim-study/configs/test-sim-6-8-6/tsne/viz.py | b608dfa400b45c5118d89e6526b248dbdb47ad82 | [
"MIT"
] | permissive | luiarthur/CytofRepFAM.jl | b4d23cd32cc89493015b72777f1016b41862aaf7 | 1f997d1620d74861c5bde5559ebdd1e6c449b9e7 | refs/heads/master | 2021-07-07T16:07:23.489103 | 2021-04-30T02:43:42 | 2021-04-30T02:43:42 | 238,282,263 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,998 | py | import numpy as np
import pandas as pd
import seaborn as sns
import matplotlib.pyplot as plt
import os
import sys
sys.path.append('../../../../PlotUtils')
import plot_yz
def graph_tsne(tsne_df, clust, i, method, outpath, method_suffix=''):
if clust is None:
tsne_df[method] = tsne_df[method].astype(int)
... | [
"[email protected]"
] | |
4f1a9db5a85cb6b5683c2bd6e86cbc75cb4ce5ed | 06737979a3d4924dc6a3d926d1b3c1c144891fb8 | /yq/operators/subsequence.py | ac83dc051cc727e3080488e6edb463a6a9c0e07a | [] | no_license | abesto/yq | 630fc2377adfb5198b5b0068a1505af01744a339 | daf0c0d8f4da2ce2eace0c21ce4d8c2d7055ba54 | refs/heads/master | 2020-05-16T22:29:59.196970 | 2017-01-19T12:43:07 | 2017-01-19T12:43:07 | 16,524,927 | 83 | 10 | null | 2016-02-28T18:24:32 | 2014-02-04T20:41:24 | Python | UTF-8 | Python | false | false | 507 | py | from yq.operators.base import Operator
class Subsequence(Operator):
def __init__(self, low, hi):
if low is None:
self.low = low
else:
self.low = int(low)
if hi is None:
self.hi = None
else:
self.hi = int(hi)
def _apply_item(self,... | [
"[email protected]"
] | |
0a5b64d704824ce71bb59cd4c8f347f2cc8e081b | 0001e8b4a35ea0530cb0f6f803b896da96d06ce3 | /sommashampoosales.py | be0a16dd95394ca00a7b52f08f417ddef8f97b50 | [] | no_license | elisagiacomini/programming.lab | 7374340ed875b17702566f2e760b184a4abbb70d | 03cef1f1befa3aeb0ccc74c89f5663bdc3e50712 | refs/heads/main | 2023-01-27T17:46:24.651148 | 2020-12-01T16:03:04 | 2020-12-01T16:03:04 | 311,688,417 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 609 | py | # Inizializzo una lista vuota per salvare i valori
values = []
# Apro e leggo il file, linea per linea
my_file = open('shampoo_sales.csv', 'r')
for line in my_file:
# Faccio lo split di ogni riga sulla virgola
elements = line.split(',')
# Se NON sto processando l’intestazione...
if elements[0] != ... | [
"[email protected]"
] | |
4e9a8679f6d3e1a43540bb78022b35d6cb07679d | a74b980fd95d5d810315f181449fc9d1710e6923 | /savecode/threeyears/idownclient/scan/plugin/zgrab2/zgrab2scanner/zgrab2scannerpop3.py | b822e7e9071e3ecd8759508da388a167c5059ce4 | [
"Apache-2.0"
] | permissive | cbbbbbbbb/sspywork | b70f5539203b47b21eec2f0514ddca155affc2b8 | 8f05a6b91fc205960edd57f9076facec04f49a1a | refs/heads/master | 2023-03-22T19:45:13.024076 | 2021-03-08T01:24:21 | 2021-03-08T01:24:21 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,680 | py | """
zgrab2去扫pop3
create by judy 2019/11/19
"""
import os
import signal
import traceback
import uuid
from datacontract.iscandataset.iscantask import IscanTask
from .zgrab2scannerbase import Zgrab2ScannerBase
from ..zgrab2parser import Zgrab2ParserPop3
class Zgrab2ScannerPop3(Zgrab2ScannerBase):
"""zgrab2 http sc... | [
"[email protected]"
] | |
33a2d5d740644f1f35166c70f71a5928b409bcb6 | 072f8bffbfef6e149ad1934ea9183a79864c1acd | /venv/Lib/site-packages/watcherclient/tests/unit/v1/test_strategy_shell.py | 7a1568714e2603e647f5b0d99f8bceeb0ede953e | [] | no_license | numvc/LuxoftBot | 77d9bf8f5f63aee63350f1ec82f4b940afe203d2 | 29d7ca8868ab86bc076509d103f7596039333417 | refs/heads/master | 2020-09-21T21:37:12.527546 | 2019-12-04T23:24:35 | 2019-12-04T23:24:35 | 224,939,956 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,741 | py | # Copyright (c) 2016 b<>com
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, softw... | [
"[email protected]"
] | |
688a3352badf0b2f3f6ee521627b783d65c0d14a | d18ed72d6f8d27dd8a13eab5c6366f9dca48aa6b | /espresso/lab/hydra/usecases/cassandra/cassandra/time/Scheduler.py | 29bbabb9f1513382a67171657fec3a84c5a2406f | [] | no_license | danse-inelastic/AbInitio | 6f1dcdd26a8163fa3026883fb3c40f63d1105b0c | 401e8d5fa16b9d5ce42852b002bc2e4274afab84 | refs/heads/master | 2021-01-10T19:16:35.770411 | 2011-04-12T11:04:52 | 2011-04-12T11:04:52 | 34,972,670 | 1 | 2 | null | null | null | null | UTF-8 | Python | false | false | 2,527 | py |
class Scheduler(object):
def __init__(self):
self.now = self.getCurrentTime()
self.alarmIndex = []
self.alarms = {}
return
def alarm(self, interval, callback):
"""Call the given callback after the specified time interval
elapses."""
from ... | [
"[email protected]"
] | |
2c492ea4b85b3ed7315977442b45bb309b1f88a1 | 3c59b7bde01cfbc1fbd170883393e8ebf7a0a92f | /HackerRank/Binary Search Tree-Lowest Common Ancestor.py | 50b0ac929272da74203ba36f002280fdd857dc6f | [] | no_license | gf234/python_problem_solving | 93ae00d940091131d8f8b06e478e385e4c2a4503 | 4c95751f5a687215c14bf61c37e6dc2e7e752342 | refs/heads/main | 2023-05-10T07:28:12.351006 | 2021-06-14T04:59:33 | 2021-06-14T04:59:33 | 314,479,583 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 202 | py | def lca(root, v1, v2):
if root.info < v1 and root.info < v2:
return lca(root.right, v1, v2)
elif root.info > v1 and root.info > v2:
return lca(root.left, v1, v2)
return root
| [
"[email protected]"
] | |
94403f1b21bd73a763eaa34c5f40bef0076041d1 | f3b233e5053e28fa95c549017bd75a30456eb50c | /jnk1_input/24/24-36_MD_NVT_rerun/set_2.py | 3ad7ebd55a5bdc277eef71cc5e0ea648a32b10d0 | [] | no_license | AnguseZhang/Input_TI | ddf2ed40ff1c0aa24eea3275b83d4d405b50b820 | 50ada0833890be9e261c967d00948f998313cb60 | refs/heads/master | 2021-05-25T15:02:38.858785 | 2020-02-18T16:57:04 | 2020-02-18T16:57:04 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 741 | py | import os
dir = '/mnt/scratch/songlin3/run/jnkl/L624/MD_NVT_rerun/ti_one-step/24_36/'
filesdir = dir + 'files/'
temp_prodin = filesdir + 'temp_prod_2.in'
temp_pbs = filesdir + 'temp_2.pbs'
lambd = [ 0.00922, 0.04794, 0.11505, 0.20634, 0.31608, 0.43738, 0.56262, 0.68392, 0.79366, 0.88495, 0.95206, 0.99078]
for j in la... | [
"[email protected]"
] | |
53d454a183cbff0e567046f5fd4165f5a6a8bd6d | 41d96fec63aff02b9eb0152002f45b1b867bfafe | /experiments/tools/noise.py | b725ec234fe89a9a7e61b4a4de3dd5803acf4c04 | [] | no_license | jon--lee/dart_dev | fef7b18e0c05ac64b3a1b1c42c1e0ac071504619 | 2539f1d918c07c15dea8d72865bb2faf1a49d22c | refs/heads/master | 2020-03-14T04:29:23.200345 | 2018-06-21T07:03:38 | 2018-06-21T07:03:38 | 131,442,979 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,239 | py | import numpy as np
import statistics
import IPython
def sample_covariance_lnr(env, lnr, sup, samples, T):
cov = np.zeros(env.action_space.shape[0])
for s in range(samples):
states, tmp_actions, _, _ = statistics.collect_traj(env, lnr, T)
sup_actions = np.array([sup.intended_action(s) for s in ... | [
"[email protected]"
] | |
17c41d0c9e81aa5d9e9f1da1181bc65e32417ecb | d2a0c5b7f9977720eb588a664b6ad40486691baa | /sports/tasks.py | 30dd137c0455fd2cbc90eb28af09f7dac89ebf4a | [] | no_license | cjredmond/final_project | 37df2ab88ff6e1aa06af12a196d5d7bc4cda71e0 | ae9bbabae8f611d88d12e045ffedf87a077b0580 | refs/heads/master | 2020-07-26T22:25:44.357141 | 2016-12-15T19:24:25 | 2016-12-15T19:24:25 | 73,711,954 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,221 | py | import time
from celery import Celery
import random
import datetime
import requests
from celery import shared_task
from sports.scraper import usable_data, fix_names, nba_scores
from sports.nhl_scraper import nhl_scores, nhl_usable_data
from sports.nfl_scraper import nfl_scores, nfl_usable_data
from sports.models import... | [
"[email protected]"
] | |
fa474f19b5c1d31fb875338677ede2815df5a871 | ae9bd6f9a8fc4133a03db60910c25617b65732f1 | /pyro_models/bcm/bernoulli.py | 9f6e2ccf839bc0c52db09b353c0c27383d26dbc1 | [
"MIT"
] | permissive | afcarl/pyro-models | 0af1a239af81436b1980752c132f288ea59bcbc3 | 1fc3f4b27fe946a99b2ddd6b57cca16f8c7da181 | refs/heads/master | 2022-01-27T13:15:33.641771 | 2019-07-09T18:55:39 | 2019-07-09T18:55:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 750 | py | # model file: example-models/basic_estimators/bernoulli.stan
import torch
import pyro
import pyro.distributions as dist
def init_vector(name, dims=None):
return pyro.sample(name, dist.Normal(torch.zeros(dims), 0.2 * torch.ones(dims)).to_event(1))
def validate_data_def(data):
assert 'N' in data, 'variable no... | [
"[email protected]"
] | |
d5b69845bfc9fdf1ab9d7e507f7523442b3dc405 | def27d5864764b877b6786835ec97f2bd74c6ba8 | /medium/RotateImage.py | 4c0c646667bb3773d3d30ad5ef12082eb7604994 | [] | no_license | bolan2014/leetcode | f6cf38a49a9250abeb36543ea2498062c58e811d | 1c35fde3a65c4f216218f459736d4c39a29980d5 | refs/heads/master | 2021-04-09T16:59:41.494568 | 2017-05-10T03:47:14 | 2017-05-10T03:47:14 | 46,648,353 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 500 | py | class Solution(object):
def rotate(self, matrix):
"""
:type matrix: List[List[int]]
:rtype: void Do not return anything, modify matrix in-place instead.
"""
n = len(matrix)
for i in range(n):
for j in range(i, n):
matrix[i][j], matrix[j][i]... | [
"[email protected]"
] | |
cccb144b3b818fd1c34f78878597e6c7566e5ae1 | 18239524612cf572bfeaa3e001a3f5d1b872690c | /clients/keto/python/ory_keto_client/models/list_ory_access_control_policy_roles.py | 012f3b490b2695312354cb16433a47b77482f36d | [
"Apache-2.0"
] | permissive | simoneromano96/sdk | 2d7af9425dabc30df830a09b26841fb2e8781bf8 | a6113d0daefbbb803790297e4b242d4c7cbbcb22 | refs/heads/master | 2023-05-09T13:50:45.485951 | 2021-05-28T12:18:27 | 2021-05-28T12:18:27 | 371,689,133 | 0 | 0 | Apache-2.0 | 2021-05-28T12:11:41 | 2021-05-28T12:11:40 | null | UTF-8 | Python | false | false | 5,559 | py | # coding: utf-8
"""
ORY Keto
A cloud native access control server providing best-practice patterns (RBAC, ABAC, ACL, AWS IAM Policies, Kubernetes Roles, ...) via REST APIs. # noqa: E501
The version of the OpenAPI document: v0.0.0-alpha.37
Contact: [email protected]
Generated by: https://openapi-generato... | [
"[email protected]"
] | |
d99415ddf223c396bd34c3886c0908198511a6c6 | de6fb3a55196b6bd36a4fda0e08ad658679fb7a1 | /modules/resource/orchestrator/src/delegate/geni/v3/utils/ro.py | 5e877ef9e520129ca30707d53a4bf5b7ffbcc9fc | [
"BSD-3-Clause",
"Apache-2.0"
] | permissive | dana-i2cat/felix | 4a87af639e4c7db686bfa03f1ae4ce62711615e3 | 059ed2b3308bda2af5e1942dc9967e6573dd6a53 | refs/heads/master | 2021-01-02T23:12:43.840754 | 2016-02-04T10:04:24 | 2016-02-04T10:04:24 | 17,132,912 | 4 | 4 | null | null | null | null | UTF-8 | Python | false | false | 6,153 | py | from db.db_manager import db_sync_manager
from delegate.geni.v3.rm_adaptor import AdaptorFactory
from rspecs.ro.manifest_parser import ROManifestParser
from commons import CommonUtils
from tn import TNUtils
from vl import VLUtils
import core
logger = core.log.getLogger("ro-utils")
class ROUtils(CommonUtils):
def... | [
"[email protected]"
] | |
9746c655fff4a9fe413aa78411dd64741596373b | 9e988c0dfbea15cd23a3de860cb0c88c3dcdbd97 | /sdBs/AllRun/sdssj_233734.00+434646.2/sdB_SDSSJ_233734.00+434646.2_lc.py | db14c23c567efeaa0cbc6954ff394fa00c9bcd68 | [] | no_license | tboudreaux/SummerSTScICode | 73b2e5839b10c0bf733808f4316d34be91c5a3bd | 4dd1ffbb09e0a599257d21872f9d62b5420028b0 | refs/heads/master | 2021-01-20T18:07:44.723496 | 2016-08-08T16:49:53 | 2016-08-08T16:49:53 | 65,221,159 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 370 | py | from gPhoton.gAperture import gAperture
def main():
gAperture(band="NUV", skypos=[354.391667,43.7795], stepsz=30., csvfile="/data2/fleming/GPHOTON_OUTPU/LIGHTCURVES/sdBs/sdB_SDSSJ_233734.00+434646.2 /sdB_SDSSJ_233734.00+434646.2_lc.csv", maxgap=1000., overwrite=True, radius=0.00555556, annulus=[0.005972227,0.010388897... | [
"[email protected]"
] | |
98fcf5fcfca6641dd017597b7d01b3e14688866e | f99f30752e9bb9e023b37c731f64fb2155ac3daf | /05/for.py | 7557743e98836a3021a0668b8696a0f0828f700a | [] | no_license | chu83/python-basics | 148ff6977f5ca04775951d90ed1f5f763c51a9ff | 19fe0937842c668f604876be0aeb0962a2630dd2 | refs/heads/master | 2023-01-19T01:29:25.203738 | 2020-11-29T18:34:33 | 2020-11-29T18:34:33 | 311,258,549 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,331 | py | #for loop
print('========== for loop 기본 ===========')
a=['cat', 'cow', 'tiger']
for animal in a:
print(animal, end=' ')
else:
print('')
print('========== 복합 자료형의 for loop ===========')
l1 = [('둘리', 10), ('마이콜', 20), ('또치', 10)]
for t in l1:
#print(f'이름 : {t[0]}, 나이 : {t[1]}')
print('이름 : %s, 나이 : %d'... | [
"[email protected]"
] | |
e031a15e54ff318ebc704179b54cb081cd8a680f | 7ad19e854135977ee5b789d7c9bdd39d67ec9ea4 | /mapping_models/setup.py | b83d962eff3cd62e6d0205c3795371958ee84111 | [
"MIT"
] | permissive | Leofltt/rg_sound_generation | 1b4d522507bf06247247f3ef929c8d0b93015e61 | 8e79b4d9dce028def43284f80521a2ec61d0066c | refs/heads/main | 2023-05-02T19:53:23.645982 | 2021-05-22T16:09:54 | 2021-05-22T16:09:54 | 369,842,561 | 0 | 0 | MIT | 2021-05-22T15:27:28 | 2021-05-22T15:27:27 | null | UTF-8 | Python | false | false | 780 | py | import setuptools
with open("README.md", "r", encoding="utf-8") as fh:
long_description = fh.read()
setuptools.setup(
name="mapping_models",
version="0.0.1",
author="Sound Generation OSR",
author_email="[email protected]",
description="mapping models module",
long_description=long_... | [
"[email protected]"
] | |
5ddb60ad27fa77fedbf2551bbab1bb2e95fa771c | 6b2a8dd202fdce77c971c412717e305e1caaac51 | /solutions_2692487_0/Python/kangz/skel.py | d65aa33398c04c3302fbb0196b83fee415960cd0 | [] | 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,174 | py | import sys
def concat_str(args):
s = ""
for arg in args:
s += str(arg)
return s
def debug(*args):
sys.stderr.write(concat_str(args) + "\n")
def printf(*args):
debug(*args)
print concat_str(args)
def int_input():
return map(int, raw_input().split(' '))
##########################... | [
"[email protected]"
] | |
316a5d32e5f75abc519788e2b798965ebd1d55c5 | 15f321878face2af9317363c5f6de1e5ddd9b749 | /solutions_python/Problem_136/2973.py | a8200601b088f6309637d43fb933939df7d0a51b | [] | no_license | dr-dos-ok/Code_Jam_Webscraper | c06fd59870842664cd79c41eb460a09553e1c80a | 26a35bf114a3aa30fc4c677ef069d95f41665cc0 | refs/heads/master | 2020-04-06T08:17:40.938460 | 2018-10-14T10:12:47 | 2018-10-14T10:12:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 366 | py | tests = int(raw_input(''))
for t in xrange(tests):
r = raw_input('').split()
C = float(r[0])
F = float(r[1])
X = float(r[2])
time = 0.0
increase = 2.0
result = 100000000000000.0
bound = int( (F*X - 2.0*C)/(F*C) )
for i in xrange(bound+10):
result = min(result, time + X/increase)
time += C/increase
incr... | [
"[email protected]"
] | |
eba134ac77216aec2247bf99d6822f1a554a1e1e | 28431c6bdfd15b346741f62b06410d815c1a1482 | /jupytex/tools.py | 5142309970c92b973730541273841ea8f6bb80b3 | [
"MIT"
] | permissive | agoose77/jupytex | e3740c367f3fd87bc32819e0a91ef9674a14ff66 | 0906c35e29c6f4b6030ae7f86565d667fb30c1da | refs/heads/master | 2021-06-09T22:31:58.200217 | 2021-05-21T13:55:40 | 2021-05-21T13:55:40 | 123,421,594 | 1 | 0 | null | 2019-01-30T09:12:09 | 2018-03-01T10:45:25 | Python | UTF-8 | Python | false | false | 1,287 | py | import logging
import pathlib
import subprocess
import typing
import importlib_resources as resources
from . import data
logger = logging.getLogger(__name__)
def get_resource_names(package: resources.Package) -> typing.Iterator[str]:
for name in resources.contents(package):
if name == "__init__.py":
... | [
"[email protected]"
] | |
05857782727dc8cbb0cce52c998e642c1192f449 | 1049d75b4d94564e54fbd0f2d8c36f774832bbf3 | /career/migrations/0001_initial.py | 2c6bf0213e1deef916116f664196fc4205095f74 | [] | no_license | wahid999/Alumni-Studen-Portal-FYP--master | b7597b4fd7f9e9e7966b09229b887bc156238c6b | 1c9719f33fc338786220cbceb8e91789aa0161ab | refs/heads/master | 2023-07-16T10:43:41.431096 | 2021-08-31T07:06:44 | 2021-08-31T07:06:44 | 401,582,254 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,083 | py | # Generated by Django 3.0.5 on 2020-04-17 19:46
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
ope... | [
"[email protected]"
] | |
5d61287b4f126287b3558dee2293d4b9935db595 | 43362c036fa9c4dd61ead35a38ede10f3e72c222 | /setup.py | 27bd1aebc9af315fd4e7a748e43a283f8c40ed78 | [
"MIT"
] | permissive | lowks/esios | acea4d86c1362641ab022d30f885dea980384473 | 2d0b00807d3e5900dfae7b89d3aacc4bc123066b | refs/heads/master | 2021-01-15T09:47:59.190672 | 2016-03-18T13:17:39 | 2016-03-18T13:17:39 | 54,208,454 | 0 | 1 | null | 2016-03-18T14:43:14 | 2016-03-18T14:43:14 | null | UTF-8 | Python | false | false | 303 | py | from setuptools import setup, find_packages
setup(
name='esios',
version='0.1.7',
packages=find_packages(),
url='https://github.com/gisce/esios',
license='MIT',
install_requires=['libsaas'],
author='GISCE-TI, S.L.',
author_email='[email protected]',
description=''
)
| [
"[email protected]"
] | |
33fd60f33c6e12e205067a4078dfebf1066dbc9c | 7d76d00142cd5c3b8d4aaeb917829ddf46871fb5 | /mlir/lib/Bindings/Python/mlir/dialects/linalg/opdsl/ops/core_named_ops.py | 229458855939a794af5b3415dc548a23455b0cde | [
"LLVM-exception",
"Apache-2.0"
] | permissive | pauljoo28/llvm-project | 8ff49f620f6ae2e9bacaad83991cd0c2bc8b36bd | 4bf8985f4fb1411831505a4b38265eb517783dc7 | refs/heads/main | 2023-04-23T07:14:36.877563 | 2021-04-06T20:23:58 | 2021-04-06T20:23:58 | 320,934,047 | 4 | 2 | null | 2020-12-12T22:09:36 | 2020-12-12T22:09:36 | null | UTF-8 | Python | false | false | 2,315 | py | from ..lang import *
T1 = TV.T1
T2 = TV.T2
Batch = S.Batch
@linalg_structured_op
def matmul(A=TensorDef(T1, S.M, S.K),
B=TensorDef(T2, S.K, S.N),
C=TensorDef(U, S.M, S.N, output=True)):
"""Performs a matrix multiplacation of two 2D inputs.
Numeric casting is performed on the operands to t... | [
"[email protected]"
] | |
8bdc625bce37546dcff8911293c12f4f99a0b92a | ff81a9d7880f1b85a1dc19d5eba5ac72d7179c86 | /pychron/loading/tasks/loading_plugin.py | ab3f96269cb4288e7d554f9723dd6eaa10080d38 | [
"Apache-2.0"
] | permissive | UManPychron/pychron | 2fb7e479a9f492423c0f458c70102c499e1062c4 | b84c9fd70072f9cbda30abe2c471e64fe3dd75d8 | refs/heads/develop | 2022-12-03T23:32:45.579326 | 2020-01-29T19:02:20 | 2020-01-29T19:02:20 | 36,100,637 | 0 | 0 | null | 2015-05-23T00:10:06 | 2015-05-23T00:10:05 | null | UTF-8 | Python | false | false | 3,651 | py | # ===============================================================================
# Copyright 2013 Jake Ross
#
# 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... | [
"[email protected]"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.