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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
5c9772366bf445c954968e4b507dc52dcb29c60e | 28deae4b6f2ef4c83116d8a7e08061b2ac47bb71 | /Spider/commentbox/spider/encrypt.py | 71a3b95bbdf67d38fd3744475f576aec28cdd9eb | [
"MIT",
"Apache-2.0"
] | permissive | Danceiny/HackGirlfriend | 9cc796c733be7055799efb1c51f1e5ecb3d12d81 | d64f43c5cfb48d30ed812e34fb19bc7b90ba01f8 | refs/heads/master | 2023-01-04T16:09:55.205094 | 2017-07-22T16:48:59 | 2017-07-22T16:48:59 | 93,874,976 | 2 | 1 | Apache-2.0 | 2022-12-26T20:14:57 | 2017-06-09T15:57:34 | HTML | UTF-8 | Python | false | false | 1,611 | py | # coding=utf-8
import os
import base64
import platform
import json
if platform.system() == 'Darwin':
try:
import crypto
import sys
sys.modules['Crypto'] = crypto
except ImportError:
pass
from Crypto.Cipher import AES
# https://github.com/darknessomi/musicbox/wiki/网易云音乐新版WebA... | [
"danceiny@gmail.com"
] | danceiny@gmail.com |
bae8eb019762143945ce74fa7330120d0ad3a8b3 | e7e536df0263ae2a7ac44ef30f19110f891213a9 | /src/tests/api/test_api_reviews.py | 8af79849d889a34659681f05b76196ee11d9e8d8 | [
"Apache-2.0"
] | permissive | pretalx/pretalx | b3b3808266f4810dfc8445dc1ed33ba398e7a9c2 | 269dce90a6fb1ce0064008c40ce5dd4dad61e2e3 | refs/heads/main | 2023-09-05T11:09:23.538325 | 2023-09-04T19:57:47 | 2023-09-04T19:57:47 | 83,081,285 | 563 | 195 | Apache-2.0 | 2023-09-13T19:12:28 | 2017-02-24T20:46:51 | Python | UTF-8 | Python | false | false | 3,279 | py | import json
import pytest
from django_scopes import scope
from pretalx.api.serializers.review import ReviewSerializer
@pytest.mark.django_db
def test_review_serializer(review):
with scope(event=review.event):
data = ReviewSerializer(review).data
assert set(data.keys()) == {
"id",
... | [
"r@rixx.de"
] | r@rixx.de |
ae0818619246b3bb7d794ba9dc5038f83db79eed | f89d70fc8bf370ef4e2aa54c7ee0de3b4a053624 | /scripts/patches/codepipeline.py | 20b98f8526ecd6469e0a36ff5f6078f7b847e0da | [
"BSD-2-Clause",
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | yks0000/troposphere | a7622bff01c31f10dcb296d2ca353144e1d7f793 | 9a94a8fafd8b4da1cd1f4239be0e7aa0681fd8d4 | refs/heads/main | 2022-04-28T03:51:42.770881 | 2022-04-15T15:15:01 | 2022-04-15T15:15:01 | 482,753,190 | 1 | 0 | BSD-2-Clause | 2022-04-18T07:20:42 | 2022-04-18T07:20:42 | null | UTF-8 | Python | false | false | 2,244 | py | patches = [
# backward compatibility
{
"op": "move",
"from": "/PropertyTypes/AWS::CodePipeline::Pipeline.StageTransition",
"path": "/PropertyTypes/AWS::CodePipeline::Pipeline.DisableInboundStageTransitions",
},
{
"op": "replace",
"path": "/ResourceTypes/AWS::CodeP... | [
"mark@peek.org"
] | mark@peek.org |
2f47b872200e92c1dd739ecfba7b29d356bbc5c9 | ae8590dc2dd0dd6530868ccd52702d06e5d96fa1 | /set.py | db1f8968df305dbd882d4f03ee932777ea1fa60b | [] | no_license | abhisek08/Python-Basics-Part-1- | e3bec8e4d7f9e484c4bcade7763842334c93f4b0 | 3687dd6ebb01f2289b3fa226cea28b564894a68f | refs/heads/master | 2022-09-08T11:42:28.871012 | 2020-05-25T07:58:01 | 2020-05-25T07:58:01 | 266,717,854 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 460 | py | '''
Write a Python program to print out a set containing all the colors from color_list_1 which are not present in color_list_2. Go to the editor
Test Data :
color_list_1 = set(["White", "Black", "Red"])
color_list_2 = set(["Red", "Green"])
Expected Output :
{'Black', 'White'}
'''
color_list_1 = set(["White", "Black", ... | [
"abhisek.bhunia08@gmail.com"
] | abhisek.bhunia08@gmail.com |
61795a374265bfd7628a5a4f8567cea6a4871501 | 41de4210af23a8a8a3ca7dd090bb51faecf4a0c8 | /lib/python3.5/site-packages/statsmodels/tsa/statespace/tests/test_pickle.py | e4143eb73bf4dbaa785ecf20c15a8bc067c18aaf | [
"Python-2.0"
] | permissive | randybrown-github/ziplineMacOS | 42a0c2bfca2a54baa03d2803dc41317647811285 | eb5872c0903d653e19f259f0800fb7aecee0ee5c | refs/heads/master | 2022-11-07T15:51:39.808092 | 2020-06-18T20:06:42 | 2020-06-18T20:06:42 | 272,631,387 | 0 | 1 | null | 2022-11-02T03:21:45 | 2020-06-16T06:48:53 | Python | UTF-8 | Python | false | false | 5,445 | py | """
Tests for python wrapper of state space representation and filtering
Author: Chad Fulton
License: Simplified-BSD
References
----------
Kim, Chang-Jin, and Charles R. Nelson. 1999.
"State-Space Models with Regime Switching:
Classical and Gibbs-Sampling Approaches with Applications".
MIT Press Books. T... | [
"randybrown18@me.com"
] | randybrown18@me.com |
62c27b0cf0a5f8a1a68a8aedafbea9941629ddf5 | c50e7eb190802d7849c0d0cea02fb4d2f0021777 | /src/azure-firewall/azext_firewall/vendored_sdks/v2020_07_01/v2020_07_01/operations/_available_resource_group_delegations_operations.py | e40effbf3eedfc272c4a8dabfc86149ff292a448 | [
"LicenseRef-scancode-generic-cla",
"MIT"
] | permissive | Azure/azure-cli-extensions | c1615b19930bba7166c282918f166cd40ff6609c | b8c2cf97e991adf0c0a207d810316b8f4686dc29 | refs/heads/main | 2023-08-24T12:40:15.528432 | 2023-08-24T09:17:25 | 2023-08-24T09:17:25 | 106,580,024 | 336 | 1,226 | MIT | 2023-09-14T10:48:57 | 2017-10-11T16:27:31 | Python | UTF-8 | Python | false | false | 5,696 | 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 may ... | [
"noreply@github.com"
] | Azure.noreply@github.com |
1721d823737b9758f72ff95546378340fdbe225f | b73a66c9593b7aa326c26d4f148606ca100f541e | /corehq/apps/indicators/urls.py | e7409ae140feb38f5a5bb6f54c8f4055d3c30201 | [] | no_license | SEL-Columbia/commcare-hq | c995a921de6d076e777ca2d5d2baed6a8bcd5d7b | 992ee34a679c37f063f86200e6df5a197d5e3ff6 | refs/heads/master | 2021-01-14T14:37:34.391473 | 2014-09-15T21:01:54 | 2014-09-15T21:01:54 | 17,970,223 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 657 | py | from django.conf.urls.defaults import patterns, url
from corehq import IndicatorAdminInterfaceDispatcher
from corehq.apps.indicators.views import IndicatorAdminCRUDFormView, BulkCopyIndicatorsView
urlpatterns = patterns('corehq.apps.indicators.views',
url(r'^$', 'default_admin', name="default_indicator_admin"),
... | [
"biyeun@dimagi.com"
] | biyeun@dimagi.com |
0cbb6f41c16ebe936880049ad757b009d9c9d15c | 54f352a242a8ad6ff5516703e91da61e08d9a9e6 | /Source Codes/AtCoder/agc004/B/4553322.py | 708d9d250a600dde43d899a86623332b0cf0c4bf | [] | no_license | Kawser-nerd/CLCDSA | 5cbd8a4c3f65173e4e8e0d7ed845574c4770c3eb | aee32551795763b54acb26856ab239370cac4e75 | refs/heads/master | 2022-02-09T11:08:56.588303 | 2022-01-26T18:53:40 | 2022-01-26T18:53:40 | 211,783,197 | 23 | 9 | null | null | null | null | UTF-8 | Python | false | false | 247 | py | import numpy as np
N, x = map(int, input().split())
a = np.array(list(map(int, input().split())))
b = np.copy(a)
ans = float('inf')
for i in range(N):
c = np.roll(a,i)
b = np.minimum(b,c)
ans = min(ans, sum(b)+i*x)
print(ans) | [
"kwnafi@yahoo.com"
] | kwnafi@yahoo.com |
0910059b9001607f6889bee415cd0046879e7eba | 57dccf7b8da26753b66a9eecb9eb6cd1ae5584b5 | /yolov5/backup/yolov5_2.py | 0db2a2eb1f6be065758b4c99caec163f748bed1f | [] | no_license | vbvg2008/benchmarks | 4b743d6b19a4d0b41fa78b8db2a3f3a3f4e86018 | 29e2e445e6701529e048e8ffa283b5b071295566 | refs/heads/master | 2022-12-12T21:50:51.082085 | 2022-12-06T22:09:26 | 2022-12-06T22:09:26 | 187,144,413 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 395 | py | import pdb
import numpy as np
import torch
from PIL import Image
# Model
model = torch.hub.load('ultralytics/yolov5', 'yolov5s', pretrained=False)
# Images
# img1 = Image.open('zidane.jpg')
# inputs = np.array(img1)
# inputs = np.transpose(inputs, [2, 0, 1])
# pdb.set_trace()
# # Inference
# result = model([inputs]... | [
"shawnmengdong@gmail.com"
] | shawnmengdong@gmail.com |
321fa041bc8aa7599fc821cd44dae64b4deb545b | 5c883c87f337be7ffd52f49f0a4e6c72bbd58932 | /apps/seguimiento/migrations/0012_auto_20161009_1256.py | 53fe40acab70a7d988dc02796c1d764cf8059d45 | [] | no_license | DARKDEYMON/Tesis-2-Vidaurre-J.C. | f1b0d8e8a593a9d4a585bdd14b21d4809d55ce9f | 4299cea2e990ee798b02724849d747bfd558b97d | refs/heads/master | 2021-06-20T09:25:53.273225 | 2017-05-25T22:20:31 | 2017-05-25T22:20:31 | 65,408,196 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 474 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.10.2 on 2016-10-09 16:56
from __future__ import unicode_literals
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('seguimiento', '0011_requerimiento_maq_he_requerimientopersonal'),
]
operations = [
... | [
"darkdeymon04@gmail.com"
] | darkdeymon04@gmail.com |
8403f2004c7f764c1701a784cd86927f379d97bd | 85373d45a83e4096affafa4f4e5b400787413e57 | /test/programytest/parser/template/node_tests/richmedia_tests/test_list.py | 282b8606c75b00ec4a823c41783ef19aa46ed8ab | [
"MIT"
] | permissive | keiffster/program-y | a02bb9d8278835547cc875f4f9cd668d5b1f44da | fc7b0a3afa4fa6ed683e0c817a9aa89f9543bb20 | refs/heads/master | 2023-08-23T13:55:39.255535 | 2022-12-13T09:51:57 | 2022-12-13T09:51:57 | 74,462,571 | 379 | 173 | NOASSERTION | 2023-05-23T00:51:21 | 2016-11-22T10:43:41 | Python | UTF-8 | Python | false | false | 969 | py | from programy.parser.template.nodes.base import TemplateNode
from programy.parser.template.nodes.richmedia.list import TemplateListNode
from programy.parser.template.nodes.word import TemplateWordNode
from programytest.parser.base import ParserTestsBaseClass
class TemplateListNodeTests(ParserTestsBaseClass):
def... | [
"keith@keithsterling.com"
] | keith@keithsterling.com |
e86764ade6955c0e9d01a19dd792a7783ffab002 | 230ccae62e975f7bfde062edd32e5a54db888a04 | /programmers/[Level-4]/fail/스티커모으기.py | e07a5aef7d58ef6b2d9cbd566e5f8fe54890943f | [] | no_license | seung-woo-ryu/AlgorithmTest | 6f56ec762dc2c863218c529299a3874ad9fd6c53 | 2b735535dbd447f873650bfb649616b78de34343 | refs/heads/master | 2023-02-03T08:00:19.929711 | 2020-12-12T10:04:07 | 2020-12-12T10:04:07 | 285,925,867 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,268 | py | vi = []
li2 = []
answer = 0
def s(n,edges):
global answer
global vi
li2 = [[0 for _ in range(n)] for _ in range(n)]
vi = [0] * n
def re(idx,li2):
global vi
if idx != 0:
for i in range(0,idx):
if li2[idx][i] == 1:
vi[i] += 1
... | [
"tmddn645@naver.com"
] | tmddn645@naver.com |
d1325713c07c1c46518100d38aa60e1e84a7af95 | 9bc17bffce835eb8e27422e39438bf7bd1af2282 | /pnc_cli/swagger_client/models/page.py | 2ba471e49073d2f40d51ae98c7e9566888ed8e25 | [
"Apache-2.0"
] | permissive | pgier/pnc-cli | c3e7d61c3bce4c1a48b29e5f980b6b72cded3e31 | 4d29a8a7ec749c8843c6e32adb7c9c969e6cc24a | refs/heads/master | 2021-01-15T23:59:08.874319 | 2016-05-02T20:59:48 | 2016-05-02T20:59:48 | 57,930,193 | 0 | 0 | null | 2016-05-03T00:36:34 | 2016-05-03T00:36:33 | null | UTF-8 | Python | false | false | 4,465 | py | # coding: utf-8
"""
Copyright 2015 SmartBear Software
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 applica... | [
"thauser@redhat.com"
] | thauser@redhat.com |
39f9ab976f2acb071d2f4cc6d0b3c49a985bcd32 | 2d4af29250dca8c72b74e190e74d92f1467120a0 | /TaobaoSdk/Request/UmpToolsGetRequest.py | 34245bfd22984b2009657c88f859c074ebb7ee59 | [] | no_license | maimiaolmc/TaobaoOpenPythonSDK | 2c671be93c40cf487c0d7d644479ba7e1043004c | d349aa8ed6229ce6d76a09f279a0896a0f8075b3 | refs/heads/master | 2020-04-06T03:52:46.585927 | 2014-06-09T08:58:27 | 2014-06-09T08:58:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,465 | py | #! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim: set ts=4 sts=4 sw=4 et:
## @brief 查询工具列表
# @author wuliang@maimiaotech.com
# @date 2013-09-22 16:52:38
# @version: 0.0.0
import os
import sys
import time
def __getCurrentPath():
return os.path.normpath(os.path.join(os.path.realpath(__file__), os.path.pardi... | [
"chenke@maimiaotech.com"
] | chenke@maimiaotech.com |
cc50b631b320114baf420e8a9698000c87c7eaca | 0b802a3b3572ae4e9be55cb1c116ebcf06cceb4d | /tests/pipupgrade/cli/test_cli__init__.py | 04031a9628d0715815b484f5dbf878b575837d64 | [
"MIT"
] | permissive | todun/pipupgrade | fc8b1315a9b432a75dd78c1783f85cd0147e631b | 2f2e04d77c7e276e4b6172d42b5bdeaae11075fb | refs/heads/master | 2020-06-25T00:43:26.995923 | 2019-06-10T18:46:22 | 2019-06-10T18:46:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 820 | py | # imports - compatibility imports
from pipupgrade._compat import iteritems, iterkeys
# imports - module imports
from pipupgrade import cli
from pipupgrade.cli import get_args
from pipupgrade.util.types import merge_dict
def test_command():
def _assert_command(values, override = dict(), initial = dict()):
... | [
"achillesrasquinha@gmail.com"
] | achillesrasquinha@gmail.com |
378ba1016f60d57bd7f16d42e2c06e05626ec211 | 42b3c0d4691df8cfe60177abe7c33d01575f2d9a | /multiThreads/多进程拷贝代码.py | 507e05be7f3bbfd237f703ce6c7499b1ad3191d0 | [] | no_license | richard-ql/pythonNotes | 68d592bdf9f81ea1569b1a5f9a12f5897b98f922 | 27919b2c95cf9ca7443d218488a6edefdb846129 | refs/heads/master | 2021-07-13T23:00:29.126607 | 2021-06-27T16:16:26 | 2021-06-27T16:16:26 | 227,252,159 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 185 | py | import os
print("hello world")
pid = os.fork()
print("多进程会拷贝os.fork之后的代码")
print(pid)
if pid == 0:
print("son process")
else:
print("father process")
| [
"richard_ql@hotmail.com"
] | richard_ql@hotmail.com |
f135315217f58fe37e1088ccf0c094c7fd1d9606 | 09c18cf1d9dc443e43357383030be9b3ce9e2756 | /QUANTAXIS/QAData/__init__.py | 4a2cfb9ae8dfa14a8a5228a58a67d7843913348e | [
"MIT"
] | permissive | zhouji0212/QUANTAXIS | ed47f78be7d78d2888faf01ba5cfe75dca463e06 | 54b2a0c3445d77c7fcd4858100e8bebe6656e940 | refs/heads/master | 2020-04-07T16:56:56.332211 | 2018-12-23T14:44:30 | 2018-12-23T14:44:30 | 141,289,835 | 0 | 0 | MIT | 2018-11-21T12:19:41 | 2018-07-17T12:56:33 | Python | UTF-8 | Python | false | false | 2,386 | py | # coding:utf-8
#
# The MIT License (MIT)
#
# Copyright (c) 2016-2018 yutiansut/QUANTAXIS
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation th... | [
"yutiansut@qq.com"
] | yutiansut@qq.com |
05fae7a028b9f848821d1fb01887ec4165b34f20 | e2d5b42941f6bd5a5adace442feab1c446f4a997 | /dp-knight-chess-movement.py | 19e4d662b82190f8979d3e4651678f59e7e6ba2b | [] | no_license | yongxuUSTC/challenges | 21601f8f47beed3ef2c733caaf512b39ce00bc69 | 00ece128923511f29c207d42cbf060cae6bafa01 | refs/heads/master | 2021-06-26T01:15:03.436234 | 2020-08-17T19:17:33 | 2020-08-17T19:17:33 | 97,131,133 | 2 | 1 | null | 2017-07-13T14:22:36 | 2017-07-13T14:22:36 | null | UTF-8 | Python | false | false | 2,361 | py | '''
How many different 10-digit numbers can be formed starting from 1?
The constraint is that the movement from 1 digit to the next is similar to the movement of the Knight in a chess game.
Reference: http://stackoverflow.com/questions/2893470/generate-10-digit-number-using-a-phone-keypad
'''
def initialize():
tabl... | [
"harishvc@gmail.com"
] | harishvc@gmail.com |
911c126a0f974f911bf5b66ca8c23e2cfd9747a3 | 1bf9f6b0ef85b6ccad8cb029703f89039f74cedc | /src/spring/azext_spring/vendored_sdks/appplatform/v2021_06_01_preview/aio/_app_platform_management_client.py | 27281616bb20c88913df623e391e6632539d2a69 | [
"MIT",
"LicenseRef-scancode-generic-cla"
] | permissive | VSChina/azure-cli-extensions | a1f4bf2ea4dc1b507618617e299263ad45213add | 10b7bfef62cb080c74b1d59aadc4286bd9406841 | refs/heads/master | 2022-11-14T03:40:26.009692 | 2022-11-09T01:09:53 | 2022-11-09T01:09:53 | 199,810,654 | 4 | 2 | MIT | 2020-07-13T05:51:27 | 2019-07-31T08:10:50 | Python | UTF-8 | Python | false | false | 7,399 | 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 may ... | [
"noreply@github.com"
] | VSChina.noreply@github.com |
68b882f21b82ee98e1f7d0034f05ab3e7456ca93 | 2fc4ccffe5c557602302f087ae296fd31c0c1c2e | /apps/backups/serializers.py | 8dc1c7418ea730901f3e574b5a9e84ba57ccd033 | [] | no_license | Duyshg/syncano-platform | 7cfee3f877f761deaa5fb2e70f89deba4f90cb05 | ea645f998edb80d5e1c6eca5ae9f7beb37d4e711 | refs/heads/master | 2020-04-25T20:47:32.717475 | 2019-02-14T17:49:06 | 2019-02-14T17:49:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,496 | py | # coding=UTF8
from django.conf import settings
from rest_framework.relations import PrimaryKeyRelatedField, SlugRelatedField
from rest_framework.serializers import ModelSerializer, ValidationError
from apps.admins.serializers import AdminFullSerializer
from apps.core.exceptions import PermissionDenied
from apps.core.f... | [
"rk@23doors.com"
] | rk@23doors.com |
7c7705efd2928f8d5566e1d078bd5e130c52912c | 5aad0901bba97bdec3e8ad576abdcb780cc7f99e | /experiment/surprise/prediction_algorithms/item_rel_tags.py | 41ae0831820f49417af314ac8db066d57b73a2c7 | [] | no_license | HelloYym/Cross-TTCF | 544f2322d25855586bf517bb769e94ffd112e847 | d4504af02a7d0dcc1b5c59aba33ba9bc897e381d | refs/heads/master | 2021-06-19T01:04:32.401074 | 2017-06-07T05:53:29 | 2017-06-07T05:53:29 | 86,427,595 | 3 | 4 | null | null | null | null | UTF-8 | Python | false | false | 4,272 | py | from __future__ import (absolute_import, division, print_function,
unicode_literals)
import numpy as np
from six.moves import range
import copy
from .algo_base import AlgoBase
class ItemRelTags(AlgoBase):
def __init__(self, n_factors=100, n_epochs=20, biased=True, lr_all=.005,
... | [
"yangym@zju.edu.cn"
] | yangym@zju.edu.cn |
896785f9a67cae451dd0cc416ffc28e3f1afa9a3 | 456a87fc1d6c6ea29063b542a4ae3d636577a56d | /06_Python_Fonksiyonlar/04_function-demos.py | d9240c2dede075c4739ac482a7520918bb307646 | [] | no_license | dyedefRa/python_bastan_sona_sadik_turan | baca8a8e05321e21bcd9d0c2bd97504d93ae8c33 | a289501b408a26c4036d68968001e2b4a6a57da7 | refs/heads/master | 2021-03-04T12:28:48.481785 | 2020-02-26T12:07:35 | 2020-02-26T12:07:35 | 246,033,399 | 1 | 0 | null | 2020-03-09T12:45:54 | 2020-03-09T12:45:54 | null | UTF-8 | Python | false | false | 2,142 | py | # 1- Gönderilen bir kelimeyi belirtilen kez ekranda gösteren fonksiyonu yazın.
'''
word = input('word : ')
count = int(input('count : '))
def yazdir(word,count):
for n in range(0,count):
print(word)
yazdir(word,count)
def yazdir2(word,count):
print(word*count)
yazdir2(word+'\n',count)
'''
# 2- Kend... | [
"metinoguzhann@gmail.com"
] | metinoguzhann@gmail.com |
3ae8ac2cf1fd31a817682334a42b0a5be16ee6b1 | d267ec32822b24092f617e88da919d1709549394 | /wproject1m/ecommerce2/One_GB_Mobiles/models.py | da5e919880576434f6e016c4f8a762046b6dfaa9 | [] | no_license | sam-student/Evaluation | 42fcccae54358fbb6a8bef8c5f9d80a7bc075864 | 3ba7842a15e431d30618c28819ea9b64c618ef2a | refs/heads/master | 2020-05-17T04:23:08.997952 | 2019-04-25T21:05:46 | 2019-04-25T21:05:46 | 183,507,753 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,768 | py | import random
import os
from django.db import models
from django.urls import reverse
# Create your models here.
from django.db.models.signals import pre_save, post_save
from ecommerce.utils import unique_slug_generator
def get_filename_ext(filename):
base_name=os.path.basename(filename)
name, ext = os.path.sp... | [
"abc@gmail.com"
] | abc@gmail.com |
2469c0eba172dd50239c61a100a2e4db476432c2 | 5733fb1a6746146889ac0941258ef5716ea17e7e | /snippets/migrations/0003_auto_20171127_0352.py | fa74dc12b146cc8cb2888b9c339cc997394a825c | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | teraoka-hiroshi/django-auth-example | b401df8877c3fc9ca61cf1cdb7d7541ef8e19820 | 675492aeb5f42dc04f9ba5de7f8f528120ddceea | refs/heads/master | 2022-01-13T08:23:25.879459 | 2018-05-21T17:06:22 | 2018-05-21T17:06:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 967 | py | # Generated by Django 2.0rc1 on 2017-11-26 18:52
from django.db import migrations, models
import django.utils.timezone
class Migration(migrations.Migration):
dependencies = [
('snippets', '0002_auto_20171127_0329'),
]
operations = [
migrations.RenameField(
model_name='snippe... | [
"contact@c-bata.link"
] | contact@c-bata.link |
680ef4bff1f4d131a6765303e1123e2525fa7bb0 | d7f2df4896898b9c30ce58507ecc72d83c34f07c | /classification.py | a079ad32e31b4e0e1fbb10af9cea8d01280bd65b | [] | no_license | candlewill/Vecamend | a12e6f74f22325cd7993c41661816780d2f3e868 | 7b73678cd4eb4aba926d4cbe752c91c7fa10ebc3 | refs/heads/master | 2021-01-10T13:27:10.847329 | 2016-01-18T16:09:00 | 2016-01-18T16:09:00 | 46,402,087 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,176 | py | import numpy as np
from load_data import load_pickle
from sklearn.cross_validation import ShuffleSplit
from sklearn.linear_model import LogisticRegression
def build_data():
positive_data = load_pickle('./tmp/amended_pos.p')
negative_data = load_pickle('./tmp/amended_neg.p')
X, Y = [], []
for pos in po... | [
"yunchaohe@gmail.com"
] | yunchaohe@gmail.com |
ba451ddd52423d13c07f5377076fc5316f56263b | 48e124e97cc776feb0ad6d17b9ef1dfa24e2e474 | /sdk/python/pulumi_azure_native/web/v20190801/list_static_site_function_app_settings.py | 6388c3e6d80456c0f9b063f72414997bc774ce73 | [
"BSD-3-Clause",
"Apache-2.0"
] | permissive | bpkgoud/pulumi-azure-native | 0817502630062efbc35134410c4a784b61a4736d | a3215fe1b87fba69294f248017b1591767c2b96c | refs/heads/master | 2023-08-29T22:39:49.984212 | 2021-11-15T12:43:41 | 2021-11-15T12:43:41 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,459 | py | # coding=utf-8
# *** WARNING: this file was generated by the Pulumi SDK Generator. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from ... import _utilities
__... | [
"noreply@github.com"
] | bpkgoud.noreply@github.com |
2e7c3ca2251c8b4024a5b4bf215a578d51f2c361 | 847273de4b1d814fab8b19dc651c651c2d342ede | /.history/Sudoku_upgr2_20180607105940.py | e76935186c51e8439262854cc75ecf84734205af | [] | no_license | Los4U/sudoku_in_python | 0ba55850afcffeac4170321651620f3c89448b45 | 7d470604962a43da3fc3e5edce6f718076197d32 | refs/heads/master | 2020-03-22T08:10:13.939424 | 2018-07-04T17:21:13 | 2018-07-04T17:21:13 | 139,749,483 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 4,220 | py | #row1 = [0,0,0,0,0,0,0,0,0]
#row2 = [0,0,0,5,0,6,0,0,0]
#row3 = [0,0,1,0,0,0,0,3,0]
#row4 = [0,9,5,0,0,0,2,0,0]
#row5 = [0,0,0,0,0,1,6,0,7]
#row6 = [1,0,6,0,0,9,0,0,5]
#row7 = [7,0,0,8,0,3,9,0,0]
#row8 = [0,3,8,9,0,0,0,2,0]
#row9 = [0,5,0,0,2,0,7,0,0]
columns = [1,2,3,4,5,6,7,8,9]
row1 = [9,8,7,4,3,2,5,6,1]
... | [
"inz.kamil.wos@gmail.com"
] | inz.kamil.wos@gmail.com |
40f2eac079d40bc274d3a0b07534b141a26c2887 | 6d9ebbee5dd515ff8d1e039b28ebcdbe185f6275 | /info/modules/uic/ex_loaduitype.py | 9d512b9e7c59a341e0e9d153b8620f8823240bcd | [] | no_license | volitilov/PyQt5_learn | 50bc378798609d98db2bd7fabe4b13ad1257e308 | f5270173d62bb61b374593cb22c4f9905a61d404 | refs/heads/master | 2021-09-08T14:12:58.387721 | 2018-03-10T10:03:06 | 2018-03-10T10:03:06 | 115,354,065 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 738 | py | from PyQt5 import QtWidgets, uic
import sys
# :::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# class MyWidget(QtWidgets.QWidget):
# def __init__(self, parent=None):
# QtWidgets.QWidget.__init__(self, parent)
# Form, _ = uic.loadUiType('MyForm.ui')
# self.ui = Form()
# self.ui.setupUi(self)
# sel... | [
"volitilov@gmail.com"
] | volitilov@gmail.com |
5a2acdcac93d580ba844a41f6be3e5618201d90b | a5b8dc5566567a8d23fc061b98ea2aa55e8f6361 | /tests/test_endpoints_sync_methods.py | d2411b2d1594f498fcd609e6a5d0fea369d5b703 | [
"MIT"
] | permissive | vltr/sanic-jwt | 5f512f91e89121c55498c88669c44dce441fdac8 | 19df69f78db121404325417f71d7bef2d1d4738d | refs/heads/master | 2021-05-11T06:31:34.497767 | 2018-02-06T19:00:50 | 2018-02-06T19:01:42 | 117,989,778 | 0 | 0 | null | 2018-01-18T13:57:27 | 2018-01-18T13:57:27 | null | UTF-8 | Python | false | false | 5,020 | py | import binascii
import os
from sanic import Sanic
from sanic.response import json
import pytest
from sanic_jwt import initialize
from sanic_jwt import exceptions
from sanic_jwt.decorators import protected
@pytest.yield_fixture
def app_with_sync_methods(users):
cache = {}
def authenticate(request, *args, *... | [
"rkuesters@gmail.com"
] | rkuesters@gmail.com |
5244256cfaf82bd7735b6e8a555dc572ce428f38 | d8d8fce19c88edc68f295c3ea0756ffe8576f982 | /bin/reportPatches.py | 2e8e58a6693daec37fd9b438f3cc2d819371309a | [] | no_license | mjuric/lsst-pipe_tasks | 4f178efd11b930d4c6bf3ed4ebce896ad8402537 | 585fa1b78ea99306edc9f89f98f0ce6618400240 | refs/heads/master | 2021-01-01T05:31:53.037714 | 2013-02-13T18:05:35 | 2013-02-13T18:05:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,206 | py | #!/usr/bin/env python
#
# LSST Data Management System
# Copyright 2008, 2009, 2010, 2011, 2012 LSST Corporation.
#
# This product includes software developed by the
# LSST Project (http://www.lsst.org/).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Pub... | [
"rowen@uw.edu"
] | rowen@uw.edu |
902e6ddb8c5ff647d175b814fc0a296e4e136f3e | 1315e1c8357f1bae712db6e3ebd3e76902173959 | /src/app/agents/authorize.py | ddd0fa9a459158d404a713525161a2f8c71b4033 | [] | no_license | jldupont/musync | e2e68d85db40c9eb4f0369c25a4b73426b1d54c0 | b52908b263ec7e18d1433dc27fa75e092fa415aa | refs/heads/master | 2021-01-23T21:37:51.762597 | 2010-08-27T01:29:12 | 2010-08-27T01:29:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,442 | py | """
Authorization Agent
Responsible for handling the authorization process
with the user
Messages Processed:
- "start_authorize"
- "start_verify"
- "oauth_error"
- "oauth?"
Messages Generated:
- "error_requesttoken"
- "error_webbrowser"
- "error_accesstoken... | [
"github@jldupont.com"
] | github@jldupont.com |
2c2198547b61fdbeb366057c6b3ffc9759df27f8 | 5963c12367490ffc01c9905c028d1d5480078dec | /tests/components/met/test_init.py | 64323af56ce222c79f5d0d50a696796b676ae555 | [
"Apache-2.0"
] | permissive | BenWoodford/home-assistant | eb03f73165d11935e8d6a9756272014267d7d66a | 2fee32fce03bc49e86cf2e7b741a15621a97cce5 | refs/heads/dev | 2023-03-05T06:13:30.354545 | 2021-07-18T09:51:53 | 2021-07-18T09:51:53 | 117,122,037 | 11 | 6 | Apache-2.0 | 2023-02-22T06:16:51 | 2018-01-11T16:10:19 | Python | UTF-8 | Python | false | false | 1,381 | py | """Test the Met integration init."""
from homeassistant.components.met.const import (
DEFAULT_HOME_LATITUDE,
DEFAULT_HOME_LONGITUDE,
DOMAIN,
)
from homeassistant.config import async_process_ha_core_config
from homeassistant.config_entries import ConfigEntryState
from . import init_integration
async def t... | [
"noreply@github.com"
] | BenWoodford.noreply@github.com |
7a0f7b03eaaf6ee2ded1913f70ceb02941f42851 | ad080bd1612b980490ef2d1b61647cbc6beddf5d | /my_game/diplomacy/send_mail.py | 89f7c3c35034326843b74ea6aeb2f25eeefc6298 | [] | no_license | rokealva83/my_game | 8f915076986144234950aa4443e8bc51ad019664 | 76ecc1dbf60c7f93621ddca66d62d5fea2826d0e | refs/heads/master | 2020-12-24T17:54:59.491881 | 2016-05-10T20:06:53 | 2016-05-10T20:06:53 | 29,264,967 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,021 | py | # -*- coding: utf-8 -*-
from datetime import datetime
from django.shortcuts import render
from my_game.models import MyUser, UserCity, Warehouse
from my_game import function
from my_game.models import Mail
def send_mail(request):
if "live" not in request.session:
return render(request, "index.html", {})
... | [
"tolik20002@bigmir.net"
] | tolik20002@bigmir.net |
a97607aa70412fb502d24b6319285ac72592a6b5 | f662bd04d2f29ef25bbfd7e768b1e57dfbba4d9f | /apps/plmejoras/migrations/0002_plan_mejoras_activo.py | 2d3ce174039be499a21756157156df72a31334f2 | [] | no_license | DARKDEYMON/sisevadoc | f59b193688f7eca7c140a03ee414f5d20ada78c7 | 9fc0943200986824a2aab2134fdba5c9f3315798 | refs/heads/master | 2020-03-19T03:27:07.907125 | 2019-12-11T13:30:43 | 2019-12-11T13:30:43 | 135,729,070 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 383 | py | # Generated by Django 2.0.8 on 2019-02-13 15:46
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('plmejoras', '0001_initial'),
]
operations = [
migrations.AddField(
model_name='plan_mejoras',
name='activo',
... | [
"darkdeymon04@gmail.com"
] | darkdeymon04@gmail.com |
4f2e66526c5ab51faf1f6d381c56f55f00e4bf5d | fa76868608739eb514c7bf9cb3be6ca1a0283409 | /l3-patterns+descriptors+metaclasses/lesson/abstract_classes.py | f4ac7bd0eb21302ca449c521709e5df6c6f295a9 | [] | no_license | k1r91/course2 | efa4b200f19798275251d1b737613cf4560e3f47 | a4b0413030e17d37406feb8f58314356e3ab15e3 | refs/heads/master | 2021-08-16T04:04:26.796036 | 2018-10-23T17:04:54 | 2018-10-23T17:04:54 | 135,111,700 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 303 | py | from abc import ABCMeta, abstractmethod, abstractproperty
class Foo(metaclass=ABCMeta):
@abstractmethod
def spam(self, a, b):
pass
@property
@abstractmethod
def name(self, asd):
pass
class Grok:
pass
Foo.register(Grok)
g = Grok()
print(isinstance(g, Foo)) | [
"cherkasov.kirill@gmail.com"
] | cherkasov.kirill@gmail.com |
a351715c2f009f811b5f12fe749143736ea6a79e | 9269bbcf34563ba16602b693858cae2908c8505c | /Python/racy/plugins/libext/sconsbuilders/mkdir.py | 10013540ef0215f405a79ce0f9b3c4578f6cb368 | [
"BSD-3-Clause"
] | permissive | cfobel/sconspiracy | 4bfe4066731ecbfb781d17d3014c5b4bdb201396 | 478876b2b033d313085a33ac0f7647da18a8439a | refs/heads/master | 2021-01-04T22:32:52.809083 | 2012-02-21T15:11:35 | 2012-02-21T15:11:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 737 | py | # -*- coding: UTF8 -*-
import os
import SCons.Node
import utils
def MkdirArgs(target, source, env):
args = []
args.extend(env.get('ARGS',[]))
args = map(env.subst, args)
return args
@utils.marker_decorator
def Mkdir(target, source, env):
for d in MkdirArgs(target, source, env):
env.Exe... | [
"none@none"
] | none@none |
91da0924f0be6bd28259ad79770de110838e7057 | 8f5aa55a8860a33290692a3455b75bc512a369bb | /controller/report.py | d485cbb30f9896976f82b80d90c8db5039b42b09 | [] | no_license | Trafire/PurchaseReports | c683072712988f50154f6bf301e0e82b8ef92d4e | 71f2ae13b366d186fef9c524cd443b78c46cdb6f | refs/heads/master | 2023-02-20T12:16:32.207351 | 2021-01-17T17:57:32 | 2021-01-17T17:57:32 | 330,453,147 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,294 | py | from autof2.dailytasks import purchaselist
from openpyxl import Workbook
from openpyxl.worksheet.table import Table
from openpyxl.worksheet.table import TableStyleInfo
from openpyxl import load_workbook
import openpyxl
import datetime, time
from datetime import date
from autof2.interface import send_data
from autof2.... | [
"antoinewood@gmail.com"
] | antoinewood@gmail.com |
be877c7774e1bb701cf61046bdf12f27d5bf2d0f | 5b3090dece7d3d276922f53bfba18fdff3a5ba12 | /app/base/config.py | 4fa810801a20b3d033452130877cc6a43e3b5644 | [
"MIT"
] | permissive | HsOjo/PyJSONEditor | 338978b36a545982bec7285ba1de9aa5704f39b0 | c2cf5398fa569ba0575048f3deebbf23028a61a1 | refs/heads/master | 2020-06-30T00:35:40.215143 | 2019-10-15T11:27:01 | 2019-10-15T11:27:01 | 200,668,517 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,775 | py | import base64
import json
import os
import platform
import sys
from app.res.const import Const
from app.util import object_convert
from app.util.log import Log
sys_type = platform.system()
if sys_type == 'Darwin':
CONFIG_NAME = ('com.%s.%s' % (Const.author, Const.app_name)).lower()
CONFIG_PATH = os.path.expa... | [
"1134031392@qq.com"
] | 1134031392@qq.com |
d60f887276a626cc23bd15b52d1b2af930c4090c | badf813b23670f38233a2f66031df33b12d6685c | /tests/test_plotting.py | 28ec689c4c5b8ed7e4ea260c1a73f340c0a70458 | [
"MIT"
] | permissive | healthonrails/annolid | 6ef2de72bc666e247ae51ae1a5df3d75337fc28c | 730f7dff2239ef716841390311b5b9250149acaf | refs/heads/main | 2023-09-01T20:52:14.857248 | 2023-09-01T14:34:34 | 2023-09-01T14:34:34 | 290,017,987 | 25 | 8 | MIT | 2022-05-03T14:36:21 | 2020-08-24T19:14:07 | Jupyter Notebook | UTF-8 | Python | false | false | 843 | py | import os
import numpy as np
import pandas as pd
from annolid.postprocessing.plotting import plot_trajactory
def test_plot_trajactory():
tracking_csv = '/tmp/tracking.csv'
cx = np.random.randint(0, 100, size=100)
cy = np.random.randint(0, 100, size=100)
instance_name = ['mouse'] * 100
df = pd.Data... | [
"healthonrails@gmail.com"
] | healthonrails@gmail.com |
23e636f36c7413ef55ccef2d4ace1aa86d27543e | 55c250525bd7198ac905b1f2f86d16a44f73e03a | /Python/Games/Python wow/models/items/loot_table.py | c59db565ea77b475438d958eda7505fb8b440c3c | [] | no_license | 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:71adc2c7aa6f6a777843ec5491e3b43f745ce5167f6810246ac3946d4ec95a0b
size 6943
| [
"nateweiler84@gmail.com"
] | nateweiler84@gmail.com |
6f94a4b8651fca9e5f6dfe42b57d55cebbf1eaab | 3851a5f2233aa68ae98aa4cd813e0a6dcbda464e | /spider/jiaoben/anjvkexzl (1).py | 62d19c7f400f3ca1116d5840a905ace18a722522 | [] | no_license | scmsqhn/yunying | 976a2c9fff98613361d4b28719080d9e4d8112dc | 3c30b6985ac974bc75d50e8abe0b69174fb46700 | refs/heads/master | 2021-01-19T21:06:21.778902 | 2017-04-25T09:14:00 | 2017-04-25T09:14:00 | 88,607,812 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,631 | py | # -*- coding: utf-8 -*-
import scrapy
import re
import time
from lxml import etree
from scrapy import log
import random
import requests
from myscrapy.items import MyscrapyItemcd
import logging
'''
1. logging.CRITICAL - for critical errors (highest severity) 致命错误
2. logging.ERROR - for regular errors 一般错误
3. logging.W... | [
"haining.qin@changhong.com"
] | haining.qin@changhong.com |
5cf0ddbe1552569d850eeea5f21edb458b930f1b | 7f73b32886f69e34dcef53b6593727effdc2fdf5 | /sentence_transformers/models/WordEmbeddings.py | a235b3af1000f3ad8951d66c310cefcb3f74575c | [
"Apache-2.0"
] | permissive | gabbage/sentence-transformers | bac116f35b5ba61bc64f35149a1963db851e5552 | 4a5308479bbb0bac7c0f60a3b2f6a01ebdfa2aa0 | refs/heads/master | 2020-07-07T01:46:56.442696 | 2019-08-19T16:24:56 | 2019-08-19T16:24:56 | 203,205,790 | 0 | 0 | null | 2019-08-19T16:03:58 | 2019-08-19T16:03:58 | null | UTF-8 | Python | false | false | 5,836 | py | import torch
from torch import nn, Tensor
from typing import Union, Tuple, List, Iterable, Dict
import logging
import gzip
from tqdm import tqdm
import numpy as np
import os
import json
from ..util import import_from_string, fullname, http_get
from .tokenizer import WordTokenizer, WhitespaceTokenizer
class WordEmbedd... | [
"rnils@web.de"
] | rnils@web.de |
882cb593206aad566ecbacb6fa9144344bd399b9 | 4111ca5a73a22174f189361bef654c3f91c3b7ed | /Lintcode/Ladder_11_15_A/134. LRU Cache.py | abb130048a64c5c6df4397b67d81b496d32268fd | [
"MIT"
] | permissive | ctc316/algorithm-python | 58b541b654509ecf4e9eb8deebfcbdf785699cc4 | ac4580d55e05e93e407c6156c9bb801808027d60 | refs/heads/master | 2020-03-16T06:09:50.130146 | 2019-08-02T02:50:49 | 2019-08-02T02:50:49 | 132,548,222 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,788 | py | class Node:
def __init__(self, key="", val=-1, prev=None, next=None):
self.key = key
self.val = val
self.prev = prev
self.next = next
class LRUCache:
"""
@param: capacity: An integer
"""
def __init__(self, capacity):
self.capacity = capacity
self.map... | [
"mike.tc.chen101@gmail.com"
] | mike.tc.chen101@gmail.com |
1743aa0b591c3eb8da10ea9d4d5551356ad61da9 | 4510bbf54e2ca619c3a863f5ca03df6584585402 | /tfx/examples/custom_components/container_components/download_grep_print_pipeline.py | 2ce8d69992f2a165d0a9b87bd887d7450af33c60 | [
"Apache-2.0"
] | permissive | Mdlglobal-atlassian-net/tfx | e55f38336d1989ac970b5069c7128097ed86b422 | 37cbbb95c65e1a891045dd13232a7f2a293a7b70 | refs/heads/master | 2022-10-02T07:44:41.180873 | 2020-06-01T18:49:15 | 2020-06-01T18:49:53 | 268,607,840 | 0 | 1 | Apache-2.0 | 2020-06-01T19:01:51 | 2020-06-01T19:01:50 | null | UTF-8 | Python | false | false | 4,376 | py | # Lint as: python2, python3
# Copyright 2020 Google LLC. 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 req... | [
"tensorflow-extended-nonhuman@googlegroups.com"
] | tensorflow-extended-nonhuman@googlegroups.com |
327e3bd7f32ec9065be455843c7a3ed5b6283fed | 4703856e735a81b43232bf47c8e1b0e7c29cc714 | /charities/serializers.py | 9a4a0bd37d128ac5bcd4edd3d9b128283e9a1c87 | [
"MIT"
] | permissive | salmanAndroidDev/charity-app | 6a367e8e16b55db20f3624559547c33299155285 | f2ea53c91c9cf46a63af6d3bef211c75dd5219bc | refs/heads/main | 2023-03-17T04:31:55.291455 | 2021-03-04T19:45:07 | 2021-03-04T19:45:07 | 344,589,781 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 654 | py | from rest_framework import serializers
from .models import Benefactor
from .models import Charity, Task
class BenefactorSerializer(serializers.ModelSerializer):
"""Serializer class for benefactor object"""
class Meta:
model = Benefactor
fields = ('experience', 'free_time_per_week')
class Ch... | [
"salmanAndB@outlook.com"
] | salmanAndB@outlook.com |
1d324d45ec8ac267e4dac7c06c7c9077ccda5aef | 3861d9f9c68eb0b09c46b9a10b92fca8fa608a23 | /Pygame/Snake/snake.py | e75117e333e90732a4c9f093dbd85a426892d47e | [] | no_license | vuquangtam/Apps | 3bbd8125dda67210862b114e3961f3d78676a06b | 94ba79e87b914595937efc95d60d8531172c87fa | refs/heads/master | 2021-01-22T13:08:22.922382 | 2016-02-01T02:51:49 | 2016-02-01T02:51:49 | 32,475,321 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,763 | py | import pygame, random, os
BLOCK_WIDTH = 40
BLOCK_HEIGHT = 40
WINDOW_WIDTH = 1280
WINDOW_HEIGHT = 600
BLOCK_X_MAX = int(WINDOW_WIDTH / BLOCK_WIDTH)
BLOCK_Y_MAX = int(WINDOW_HEIGHT / BLOCK_HEIGHT)
LENGHT_OF_SNAKE = 5
START_POSITION_X = 10
START_POSITION_Y = 10
SNAKE_SPEED = 1
BLACK = (0, 0, 0)
WHITE =... | [
"vuquangtam1994@gmail.com"
] | vuquangtam1994@gmail.com |
f82270579338afb628549cc0faca8293c5922f33 | 60a831fb3c92a9d2a2b52ff7f5a0f665d4692a24 | /IronPythonStubs/release/stubs.min/Autodesk/Revit/DB/__init___parts/FaceSecondDerivatives.py | a8db8408a607733b344af34107b62ddde5d1bfee | [
"MIT"
] | permissive | shnlmn/Rhino-Grasshopper-Scripts | a9411098c5d1bbc55feb782def565d535b27b709 | 0e43c3c1d09fb12cdbd86a3c4e2ba49982e0f823 | refs/heads/master | 2020-04-10T18:59:43.518140 | 2020-04-08T02:49:07 | 2020-04-08T02:49:07 | 161,219,695 | 11 | 2 | null | null | null | null | UTF-8 | Python | false | false | 1,656 | py | class FaceSecondDerivatives(object,IDisposable):
""" Contains second partial derivatives of a face at a specified point. """
def Dispose(self):
""" Dispose(self: FaceSecondDerivatives) """
pass
def ReleaseUnmanagedResources(self,*args):
""" ReleaseUnmanagedResources(self: FaceSecondDerivatives,disposing: bool)... | [
"magnetscoil@gmail.com"
] | magnetscoil@gmail.com |
f7a2b88e5951ed5c9599d5fa6f35931526001d5d | e84020108a7037d8d4867d95fada1b72cbcbcd25 | /src/chattisgarh/misc/processNregaAssets.py | 00148cbca88667705777386bf35810bf5a749c0f | [] | no_license | rajesh241/libtech | 8384316051a2e8c2d4a925cd43216b855b82e4d9 | 0105e717357a3626106028adae9bf162a7f93fbf | refs/heads/master | 2022-12-10T03:09:00.048841 | 2020-06-14T09:39:04 | 2020-06-14T09:39:04 | 24,629,538 | 1 | 1 | null | 2022-12-08T02:26:11 | 2014-09-30T07:57:45 | Python | UTF-8 | Python | false | false | 4,969 | py | import csv
from bs4 import BeautifulSoup
import requests
import os
import time
import re
import sys
import urllib2
import MySQLdb
import time
import re
import os
import sys
import os.path
fileDir=os.path.dirname(os.path.abspath(__file__))
sys.path.insert(0, fileDir+'/../../includes/')
from settings import dbhost,dbuser... | [
"togoli@gmail.com"
] | togoli@gmail.com |
f9637053b972322b18327b19537200a6e0b6944e | 4027d8dafb6f60568f03357e329c09262161e963 | /machinelearn/neural_network/logistic.py | f68ba50920fdc46698497029c196f4d0f14b714c | [] | no_license | pentiumCM/machinelearn | a2bfa15d6e9f20fd604116f77186da76ebcc4f27 | 329bb9521b5e06e3471aa209fc87ca47f8d5fdcb | refs/heads/master | 2022-12-08T23:43:05.784930 | 2021-05-24T04:02:23 | 2021-05-24T04:02:23 | 216,704,188 | 7 | 1 | null | 2022-12-08T09:30:07 | 2019-10-22T02:13:45 | Python | UTF-8 | Python | false | false | 6,241 | py | #!/usr/bin/env python
# encoding: utf-8
'''
@Author : pentiumCM
@Email : 842679178@qq.com
@Software: PyCharm
@File : logistic.py
@Time : 2019/10/27 21:49
@desc : 基于逻辑回归的单层感知器(神经网络)算法
'''
import numpy as np
import matplotlib.pyplot as plt
# 1. 激活函数
def sigmoid(z):
"""
sigmoid激活函数
:param z: 输入
... | [
"842679178@qq.com"
] | 842679178@qq.com |
73937dbd616aa7fd615db0615064c976542f5ef3 | c9ab605cdd2dbf92c9de05768ade0ecf1718be02 | /algorithm/t3.py | 74cec31f9cfc6fb539cb226f55bf3b5622627dae | [] | no_license | PyeongGang-Kim/TIL | 42d69308cf99d2e07644b51d7636e1b64551a697 | 8711501d131ee7d78fdaac544dda2008adf820a1 | refs/heads/master | 2023-01-12T21:10:38.027946 | 2021-10-23T07:19:48 | 2021-10-23T07:19:48 | 195,937,990 | 10 | 1 | null | 2023-01-07T11:25:30 | 2019-07-09T05:22:45 | HTML | UTF-8 | Python | false | false | 814 | py | # 0번집이 털린 경우의 dp 최대값 - 마지막 빼고 할것
# 0번집이 털리지 않은 경우의 dp 최대값 - 첫번째 빼고 할 것
def solution(money):
D11 = [0] * len(money)
D12 = [0] * len(money)
D21 = [0] * len(money)
D22 = [0] * len(money)
D11[0] = money[0]
D21[1] = money[1]
# 이전 인덱스의 0 번이 털린경우의 최대값
# 1번이 털리지 않은 경우의 최대값
for i in range(... | [
"pyeonggangkim@gmail.com"
] | pyeonggangkim@gmail.com |
84330b145a69b3630554ae4f66c56b7a6e6c2946 | aa42be48004e22faf72e5a2cfcd4714cfba04ee7 | /crafters/image/ImageCropper/__init__.py | 98c16e7eb0bdd54389537e9ab4543e251ef70e54 | [
"Apache-2.0"
] | permissive | YueLiu1415926/jina-hub | e14b426924cb00f8253004271cda7f050ef1c3c4 | e0a7dc95dbd69a55468acbf4194ddaf11fd5aa6c | refs/heads/master | 2022-12-05T15:36:26.665207 | 2020-08-20T03:40:47 | 2020-08-20T03:40:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,701 | py | __copyright__ = "Copyright (c) 2020 Jina AI Limited. All rights reserved."
__license__ = "Apache-2.0"
from typing import Tuple, Dict, Union
import numpy as np
from jina.executors.crafters import BaseCrafter
from .helper import _crop_image, _move_channel_axis, _load_image
class ImageCropper(BaseCrafter):
"""
... | [
"han.xiao@jina.ai"
] | han.xiao@jina.ai |
f13bebe05707028d5ef7c32256afa8695be99970 | 8f6cc0e8bd15067f1d9161a4b178383e62377bc7 | /ppo_baseline_DMB/WORKINGON/easy_ppo_v6/Exp_run_v0001.py | 8fb7ec75b0875fad040abe46af4ef32294900a85 | [] | no_license | humorbeing/python_github | 9c4dfc61a3cefbb266fefff335f6b28d05797e5e | e4b4b49bee7e7e3843c6874717779ce8d619bd02 | refs/heads/master | 2023-01-22T21:51:20.193131 | 2020-01-26T21:47:23 | 2020-01-26T21:47:23 | 163,707,778 | 0 | 0 | null | 2022-12-27T15:37:48 | 2019-01-01T01:58:18 | Python | UTF-8 | Python | false | false | 5,926 | py | from collections import deque
import time
import torch
import numpy as np
try:
from .envs import make_vec_envs
except Exception: #ImportError
from envs import make_vec_envs
try:
from .model import Policy
except Exception:
from model import Policy
try:
from .ppo import PPO
except Exception:
from ... | [
"geemguang@gmail.com"
] | geemguang@gmail.com |
e3ab109cbd7ee8af1a38d19e640309ac777edf33 | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/otherforms/_humidifies.py | eca272ad0fd541f4afc6614cbf8c1e3c03ae63f2 | [
"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 | 232 | py |
#calss header
class _HUMIDIFIES():
def __init__(self,):
self.name = "HUMIDIFIES"
self.definitions = humidify
self.parents = []
self.childen = []
self.properties = []
self.jsondata = {}
self.basic = ['humidify']
| [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
56ad186bf416e7055d7e7210a444f0856051c226 | 25ebf226893b44dd8a6b1b85cf80864579372892 | /divide-two-integers/Wrong Answer/2-28-2021, 1:11:22 AM/Solution.py | 6f112ee1acf15b23f426815b780ac2338de4df1f | [] | no_license | TianrunCheng/LeetcodeSubmissions | db15f5a1a8e1bbecefc45cb0b2b5fbaa036aa6f5 | 00a5403f1950e039ccc370cb266b752faebb8e79 | refs/heads/main | 2023-06-29T21:51:43.029300 | 2021-07-22T03:12:15 | 2021-07-22T03:12:15 | 388,305,775 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 962 | py | // https://leetcode.com/problems/divide-two-integers
class Solution:
def divide(self, dividend: int, divisor: int) -> int:
neg = False
if dividend < 0:
dividend = 0 - dividend
neg = not neg
if divisor < 0:
divisor = 0 - divisor
neg = ... | [
"tc905@georgetown.edu"
] | tc905@georgetown.edu |
9a69b3ede4a9045e9356c9c5067bc0b9f40dac61 | e21599d08d2df9dac2dee21643001c0f7c73b24f | /practice/profile/cProfile/stats.py | 5c1b922d260936e05ac059b23dec1b91f2af3de5 | [] | no_license | herolibra/PyCodeComplete | c7bf2fb4ce395737f8c67749148de98a36a71035 | 4ef7d2c3aec6d28a53eed0e649cdeb74df3d783b | refs/heads/master | 2022-07-17T05:39:03.554760 | 2020-05-03T07:00:14 | 2020-05-03T07:00:14 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 796 | py | #!/usr/bin/env python
# coding=utf-8
# author: zengyuetian
if __name__ == '__main__':
import pstats
# 创建Stats对象
p = pstats.Stats("result.out")
# strip_dirs(): 去掉无关的路径信息
# sort_stats(): 排序,支持的方式和上述的一致
# print_stats(): 打印分析结果,可以指定打印前几行
# 按照函数名排序,只打印前3行函数的信息, 参数还可为小数,表示前百分之几的函数信息
p.str... | [
"ijumper@163.com"
] | ijumper@163.com |
9f5deeabe426194334c63fe23dfd1178c20184ec | 7041c85dffb757c3e7063118730363f32ebb9b8a | /Algorithm/python 파일/20190129/글자수.py | 0740ce2e51a31a4650217cb8239b85c97193425d | [] | no_license | woonji913/til | efae551baff56f3ca16169b93185a65f4d81cd7a | a05efc68f88f535c26cb4d4a396a1e9cd6bf0248 | refs/heads/master | 2021-06-06T23:17:54.504620 | 2019-06-19T04:29:18 | 2019-06-19T04:29:18 | 163,778,844 | 1 | 0 | null | 2021-05-08T16:27:17 | 2019-01-02T01:08:19 | HTML | UTF-8 | Python | false | false | 249 | py | import sys
sys.stdin = open("글자수_input.txt", "r")
T = int(input())
for tc in range(1, T + 1):
str1 = str(input())
str2 = str(input())
ans = []
for i in str1:
ans.append(str2.count(i))
print(f"#{tc} {max(ans)}")
| [
"johnnyboy0913@gmail.com"
] | johnnyboy0913@gmail.com |
f56a97f3a3b19d1678cd8892d3f96a6483ee6e44 | 0d9cd43c4bc56e917135dc329c5cd9c1a4cb2b87 | /idangr/gui.py | 53874d0a7f93456b78e7c1825872f8e07e060f58 | [
"BSD-2-Clause"
] | permissive | budanthara/IDAngr | 8ec10ec9b3736d2419244161830a8bf90f957a63 | 0acbbf9847b728e8d0fccdc06ae63c3b971f5808 | refs/heads/master | 2020-03-22T07:43:05.641342 | 2018-06-27T08:23:29 | 2018-06-27T08:23:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 357 | py | import manage
print "######### IDAngr GUI #########"
def show():
if not manage.is_initialized():
from init_gui import IDAngrConnectDialog
if IDAngrConnectDialog.go():
from main_gui import idangr_panel_show
idangr_panel_show()
else:
from main_gui import idangr_pa... | [
"andreafioraldi@gmail.com"
] | andreafioraldi@gmail.com |
44bd4131bcd523e76930ee093593e6c0c8c07d61 | b9de33c6fb310ef69cba728b9de1a31165c3a031 | /chapter_32/spam_static.py | d461de172a54a1bde7567489c009edee95058f0c | [] | no_license | bimri/learning-python | 2fc8c0be304d360b35020a0dfc16779f78fb6848 | 5f2fcc9a08f14e1d848530f84ce3b523d1f72aad | refs/heads/master | 2023-08-12T20:30:09.754468 | 2021-10-15T20:53:49 | 2021-10-15T20:53:49 | 377,515,946 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,386 | py | "Counting Instances with Static Methods"
class Spam:
numInstances = 0 # Use static method for class data
def __init__(self):
Spam.numInstances += 1
def printNumInstances():
print("Number of instances: %s" % Spam.numInstances)
printNumIns... | [
"bimri@outlook.com"
] | bimri@outlook.com |
9b8c7faa9ecbc4bf81e1ed72473dbe553ffe7c31 | df83f97ed2c6dd199005e96bc7c494cfb3b49f8c | /GeeksForGeeks/Chocolate Distribution Problem.py | 803170c58228d3d30393c9b4bb6f758534761bf3 | [] | no_license | poojan14/Python-Practice | 45f0b68b0ad2f92bbf0b92286602d64f3b1ae992 | ed98acc788ba4a1b53bec3d0757108abb5274c0f | refs/heads/master | 2022-03-27T18:24:18.130598 | 2019-12-25T07:26:09 | 2019-12-25T07:26:09 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,039 | py | '''
//MEMORY ERROR
from itertools import permutations
if __name__=='__main__':
T=int(input())
for _ in range(T):
N=int(input())
A=list(map(int,input().split()))
M=int(input())
A.sort()
if M==1:print('0')
else:
lst=[]
l=list(permutations(A,M... | [
"noreply@github.com"
] | poojan14.noreply@github.com |
14fc8447bbed8c468586a52217f4963fdec8fc15 | e3b42e43555cb34e9a7f44c5e1e42b06c89e2b49 | /envi/tests/msp430/irlc.py | f50db0e4a61b68e1fb1c41a4d5605096c4ae251d | [
"Apache-2.0"
] | permissive | bat-serjo/vivisect-py3 | 77eed20e8e78ff0f5bbde57eb7709c68617aeb1d | 75d58115b09c209a042713736181888fad31482c | refs/heads/master | 2021-01-11T21:54:42.853791 | 2019-01-08T20:15:57 | 2019-01-08T20:15:57 | 78,873,268 | 12 | 2 | null | null | null | null | UTF-8 | Python | false | false | 3,176 | py | checks = [
# RLC
(
'RLC r15 (destination negative + overflow)',
{ 'regs': [(REG_R15, 0x5555)], 'flags': [(SR_N, 0), (SR_Z, 0), (SR_C, 0), (SR_V, 0)], 'code': "0f6f", 'data': "" },
{ 'regs': [(REG_R15, 0xaaaa)], 'flags': [(SR_N, 1), (SR_Z, 0), (SR_C, 0), (SR_V, 1)], 'code': "0f6f", 'data'... | [
"jroi.martin@gmail.com"
] | jroi.martin@gmail.com |
1a59a935ece142b1fba84eebe71dbdb2f3ddd079 | 9161503ddd4d3044a9481cb519a4f30b7f371335 | /venv/bin/pip3 | 3e07a514109385314762d4908a7ff1c67d334d3f | [] | no_license | cuixiaozhao/HelloFlask | 48112e72300549dc06cc5abfe3c0869a902ce9ab | 165c8a69204f9dec9b09de72c4eb0468ec1d41a0 | refs/heads/master | 2020-03-28T13:36:39.983346 | 2018-09-12T03:48:55 | 2018-09-12T03:48:55 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 418 | #!/Users/cuixiaozhao/PycharmProjects/Flask/HelloFlask/venv/bin/python
# EASY-INSTALL-ENTRY-SCRIPT: 'pip==10.0.1','console_scripts','pip3'
__requires__ = 'pip==10.0.1'
import re
import sys
from pkg_resources import load_entry_point
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.... | [
"19930911cXS"
] | 19930911cXS | |
f008b4ce82e6c21360f7bef5df058c46001c8a1f | 17f6881c70401dc63757cc7b5fa4d9dd396689e3 | /src/main/com/libin/yfl/10.py | 606053f9ee34ad635daf307378dc978dcea86602 | [] | no_license | BigDataRoad/Algorithm | 0ab493eeb478125b4beb62d78ce18c73e30b0496 | 2f2fb4f4b84f6c9df8adbada63b327c43ce29ddd | refs/heads/master | 2023-07-02T04:06:51.025648 | 2021-07-28T14:04:55 | 2021-07-28T14:04:55 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 658 | py | '''
203. 移除链表元素
删除链表中等于给定值 val 的所有节点。
示例:
输入: 1->2->6->3->4->5->6, val = 6
输出: 1->2->3->4->5
'''
# Definition for singly-linked list.
# class ListNode:
# def __init__(self, x):
# self.val = x
# self.next = None
class Solution:
def removeElements(self, head: ListNode, val: int) -> ListNode:
... | [
"yangfengling@inttech.cn"
] | yangfengling@inttech.cn |
be9c5ee84e7952ac4d8ffdddcb2eb46f037ed1d2 | 4fcb2e797ba83b310fe05461d48f02931ea5a427 | /2021/day-12/solution.py | d066e599b9ac7a138623fee02b10f61387a92589 | [] | no_license | BrentChesny/AdventOfCode | 5a642d081505563f7518c5244bb814e9e4dfc5de | dad5224961539149bed5757bbae0ccc35a3a293d | refs/heads/master | 2022-12-11T19:51:22.138655 | 2022-12-04T21:46:29 | 2022-12-04T21:46:29 | 47,266,210 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,775 | py | from collections import defaultdict
def parse_input():
caves = defaultdict(list)
for line in open("input.txt"):
fr, to = line.strip().split("-")
caves[fr].append(to)
caves[to].append(fr)
return caves
def is_small(cave):
return cave.islower()
def solve(caves, current, visite... | [
"brent.chesny@gmail.com"
] | brent.chesny@gmail.com |
a547a4cbb4dff01e327264fb4b7c55d089927cc9 | 9a5b81fd11a5e6fcae6ac166fc44a2d80f7c22e1 | /pyflow/demo/helloWorld/helloWorld.py | 0efe70710cb4bd9645ef0cc98de6e89dadd707b2 | [] | no_license | moleculo/pyflow | a636cbed88dc4014394bd8a55660e6e6f57fe977 | 62ecdf32889d099e5b37eac0b4e17ed6612c6443 | refs/heads/master | 2021-01-18T06:05:05.281246 | 2013-05-08T01:13:33 | 2013-05-08T01:13:33 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,286 | py | #!/usr/bin/env python
#
# Copyright (c) 2012-2013 Illumina, Inc.
#
# This software is provided under the terms and conditions of the
# Illumina Open Source Software License 1.
#
# You should have received a copy of the Illumina Open Source
# Software License 1 along with this program. If not, see
# <https://github.com/... | [
"csaunders@illumina.com"
] | csaunders@illumina.com |
5348c082b53d461884706e83f902f1bd079d2e12 | 31fb7c74b94e46a325e6b05501c6972a401cf423 | /PYTHON/BASIC_PYTHON/수업내용/04/04-029.py | 1d0861db9a70b872a9db5c3adf7ecd597cd10dd6 | [] | no_license | superf2t/TIL | f2dacc30d6b89f3717c0190ac449730ef341f6a4 | cadaaf952c44474bed9b8af71e70754f3dbf86fa | refs/heads/master | 2022-04-10T13:55:24.019310 | 2019-12-12T11:15:31 | 2019-12-12T11:15:31 | 268,215,746 | 1 | 0 | null | 2020-05-31T05:32:46 | 2020-05-31T05:32:46 | null | UTF-8 | Python | false | false | 1,098 | py | #04-029.py
nums='1237894673683038478236749192738623234234'
if 1:
cnt = {}
for num in nums:
cnt.setdefault(num, 0)
cnt[num] += 1
else:
# 위에서 for문을 돌려서 만든 cnt를 Counter 메소드를 통해 한 번에 만들 수도 있음!
from collections import Counter
cnt = Counter(nums)
print(cnt)
... | [
"noreply@github.com"
] | superf2t.noreply@github.com |
fbf299007fe1f34f9f48f8ad4ed2ef2bd8f6d4e2 | 1b2d5f0635459a02f82b574e5de632f67679210a | /5/11_sin_gru_tf.py | 9a2132f121e7e66adb7875b7fbb2408c1a4302a2 | [] | no_license | ydocore/deeplearning-keras-tf2-torch | f9b117e693b4a122bfb37fc77ae082de2140afd7 | 19aa983de1b0f55985179549603327281b92fcb2 | refs/heads/master | 2022-12-22T16:26:11.249773 | 2020-09-15T12:54:26 | 2020-09-15T12:54:26 | 276,814,737 | 0 | 1 | null | 2020-07-03T05:24:38 | 2020-07-03T05:24:38 | null | UTF-8 | Python | false | false | 4,399 | py | '''
5.3.2 GRU - TensorFlow (sin波)
'''
import numpy as np
import matplotlib.pyplot as plt
from sklearn.model_selection import train_test_split
from sklearn.utils import shuffle
import tensorflow as tf
from tensorflow.keras import datasets
from tensorflow.keras.models import Model
from tensorflow.keras.layers import Den... | [
"me@yusugomori.com"
] | me@yusugomori.com |
de058075cb519f64d30d752973071422f9008b5b | c27c51f5c33e0431dbe7db6e18c21b249d476cfa | /OpenSource_Python_Code/horizon-master/openstack_dashboard/dashboards/project/images_and_snapshots/snapshots/views.py | 299ec446133658878663a3ffe30cf05d036707cd | [
"Apache-2.0"
] | permissive | bopopescu/Python_Stuff | 9bef74e0db17bb5e3ba2d908ced01ee744820d80 | 9aa94a0fa5e4e802090c7b29ec88b840e304d9e5 | refs/heads/master | 2022-11-20T06:54:36.581623 | 2017-12-04T18:56:02 | 2017-12-04T18:56:02 | 282,171,169 | 0 | 0 | null | 2020-07-24T08:54:37 | 2020-07-24T08:54:36 | null | UTF-8 | Python | false | false | 2,173 | py | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2012 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
#
# Copyright 2012 Nebula, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# no... | [
"thelma1944@gmail.com"
] | thelma1944@gmail.com |
24055a1a6e8b5a0c6a0d50ceec70784bc1200932 | f576f0ea3725d54bd2551883901b25b863fe6688 | /sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/aio/_configuration.py | 8f5a2a189161e3f0b90013118775e86eb5fd19a4 | [
"LicenseRef-scancode-generic-cla",
"MIT",
"LGPL-2.1-or-later"
] | permissive | Azure/azure-sdk-for-python | 02e3838e53a33d8ba27e9bcc22bd84e790e4ca7c | c2ca191e736bb06bfbbbc9493e8325763ba990bb | refs/heads/main | 2023-09-06T09:30:13.135012 | 2023-09-06T01:08:06 | 2023-09-06T01:08:06 | 4,127,088 | 4,046 | 2,755 | MIT | 2023-09-14T21:48:49 | 2012-04-24T16:46:12 | Python | UTF-8 | Python | false | false | 3,791 | 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 may ... | [
"noreply@github.com"
] | Azure.noreply@github.com |
0106a8b00c02f1cf93357f0dbdee964c833a0cad | 9ed385053e7f28bfd0c6f186fc4963faac43eb96 | /store/models.py | 3f05789263ca28aa75c52f50113c0aaacc36d485 | [] | no_license | Pagante/greatkart-django | ffadfb5d4827220f3df588fb1d21dc28f1359ce0 | d4bb679c7fd270435f4ce0cc8854bdb3d2e134dd | refs/heads/main | 2023-05-12T01:07:53.092949 | 2021-05-30T16:34:07 | 2021-05-30T16:34:07 | 365,899,060 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,999 | py | from django.db import models
from django.db.models.aggregates import Count
from django.db.models.deletion import CASCADE
from django.db.models.expressions import Case
from django.urls.base import reverse
from category.models import Category
from accounts.models import Account
from django.db.models import Avg, Count
# ... | [
"55301195+Pagante@users.noreply.github.com"
] | 55301195+Pagante@users.noreply.github.com |
1a7bd63272c5441eea5544e3e4fd0a3dd2a93d9b | 537345f90de44dac4e2a20037d21f858f82e3120 | /concatenateGenbankFiles.py | 08d2e28a0b99eda871a365d7827e7b9b97120c28 | [] | no_license | kaiyaprovost/misc_scripts | f8fc8ca646c5c97ad3495e612bc9656e2b8d238c | 5c460ea608c13ff271fa6772fe548b89aa68c225 | refs/heads/master | 2021-11-11T15:33:34.211463 | 2021-11-10T23:11:56 | 2021-11-10T23:11:56 | 237,049,894 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,176 | py | # -*- coding: utf-8 -*-
"""
Created on Fri Dec 9 18:27:49 2016
@author: kprovost
This script takes multiple genbank .gb files adn turns them into one file
Usage: give path, creates a folder
python concatenateGenbankFiles.py <optional path>
"""
def concatGB(filename,outfile):
with open(filename,"r") as infile,... | [
"17089935+kaiyaprovost@users.noreply.github.com"
] | 17089935+kaiyaprovost@users.noreply.github.com |
9395ac23fad1778148b66efae8bb997bf22d7431 | 18a645c8e543c905528364fad8c429e209903e80 | /acapy-client/acapy_client/api/issue_credential_v_10/post_issue_credential_send_offer.py | 7d95d291316c0d7eac46e78b101473fa2a2c0925 | [] | no_license | cjhowland/acapy-revocation-demo | 854e9aff4236c034ae9cc00206abde87f257bc45 | 01c21eb38d085c5633e505908c26c2e9ebfe3110 | refs/heads/main | 2023-07-16T02:01:05.659695 | 2021-05-12T17:00:44 | 2021-05-12T17:00:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,430 | py | from typing import Any, Dict, Optional
import httpx
from ...client import Client
from ...models.v10_credential_exchange import V10CredentialExchange
from ...models.v10_credential_offer_request import V10CredentialOfferRequest
from ...types import Response
def _get_kwargs(
*,
client: Client,
json_body: V... | [
"dbluhm@pm.me"
] | dbluhm@pm.me |
299bb263f3c5c29e06546b2fafcc922341219476 | 7e516383bd528e79719f04e88e8839671de5f81b | /l10n_ec_talent_growth/__manifest__.py | 7342e79f47b66f49b21ce8565d79023d863d2ae3 | [] | no_license | hc-mic29/primerabase | c96b1bd8ee77d4217b528dd4f9f50274f5711fca | 16fcc33bbf5bfcda236cc1a7a595cccf15aa5b44 | refs/heads/main | 2023-06-14T23:50:46.970941 | 2021-07-06T22:38:40 | 2021-07-06T22:38:40 | 383,600,215 | 0 | 0 | null | 2021-07-06T21:17:38 | 2021-07-06T21:17:38 | null | UTF-8 | Python | false | false | 1,033 | py | # -*- coding: utf-8 -*-
{
'name': "Talent Growth",
'summary': """
Modulo de talent Growth""",
'description': """
En el presente modulo se llevara acabo el control de desarrollo y crecimiento del personal
""",
'author': "Opa Consulting",
'website': "http://www.opa-consulting.co... | [
"glabois@opa-consulting.com"
] | glabois@opa-consulting.com |
7d4ec04cdb2b19f3b0eb63afcab1dce44a9b3f4a | 62def70e2d802375b1ad28b0ac85fee2010ee0a9 | /flask/server/app2.py | 5ba7860c73d4a3a14efbd47ab066e88ac9058194 | [] | no_license | MarkAYoder/BeagleBoard-exercises | c48028b6e919d8c04dedfd2040a133c760f0f567 | 2fab7c7f7aa09bf101168dfb279e690bc43a6514 | refs/heads/master | 2023-07-22T08:06:19.482358 | 2023-07-12T19:24:51 | 2023-07-12T19:24:51 | 5,111,513 | 48 | 41 | null | 2021-07-29T18:02:29 | 2012-07-19T15:07:14 | JavaScript | UTF-8 | Python | false | false | 674 | py | #!/usr/bin/env python3
# From: https://towardsdatascience.com/python-webserver-with-flask-and-raspberry-pi-398423cc6f5d
import gpiod
CHIP = '0' # P9_11
offsets=[30]
from flask import Flask, render_template
app = Flask(__name__)
chip = gpiod.Chip(CHIP)
lines = chip.get_lines(offsets)
# Set button as an input
lines.... | [
"Mark.A.Yoder@Rose-Hulman.edu"
] | Mark.A.Yoder@Rose-Hulman.edu |
5971a56f860c99200f932f59b086d7cf6ebe4b6a | facb8b9155a569b09ba66aefc22564a5bf9cd319 | /wp2/merra_scripts/03_model_fitting/merraRF882/641-tideGauge.py | dac5196ec7ba7de35a7df47a6c6f4edc7937cd21 | [] | no_license | moinabyssinia/modeling-global-storm-surges | 13e69faa8f45a1244a964c5de4e2a5a6c95b2128 | 6e385b2a5f0867df8ceabd155e17ba876779c1bd | refs/heads/master | 2023-06-09T00:40:39.319465 | 2021-06-25T21:00:44 | 2021-06-25T21:00:44 | 229,080,191 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,456 | py | # -*- coding: utf-8 -*-
"""
Created on Mon May 4 15:51:30 2020
This program is designed to validate a Random Forest
model by using the KFOLD method
@author: Michael Tadesse
"""
#import packages
import os
import glob
import numpy as np
import pandas as pd
from sklearn import metrics
from scipy import stats
import se... | [
"michaelg.tadesse@gmail.com"
] | michaelg.tadesse@gmail.com |
d0306b119643795c0a1f9cc58722de910337f986 | 83efa5604be59078372c55998b9c686774e73e89 | /utils/utils.py | 17f3c5461f1aaaaefd48e7dc908a631518ace97a | [
"MIT"
] | permissive | Dawa406/import_to_gee | 5c7a2db656cf6fe8ad3b4d954bcc38e06b4a0d32 | 4d13a261fff371eb6a18076fdd1ea742fddd814b | refs/heads/master | 2023-02-07T14:12:07.878640 | 2020-12-24T08:35:31 | 2020-12-24T08:35:31 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 899 | py | import os
import ee
from utils import message as ms
ee.Initialize()
def display_asset(output, asset):
"""remove the manifest from the asset name and display it to the user"""
asset = asset.replace('projects/earthengine-legacy/assets/', '')
output.add_msg(ms.asset_created.format(asset), 'succes... | [
"pierrick.rambaud49@gmail.com"
] | pierrick.rambaud49@gmail.com |
fab5b4d8041420a521a36b1045fd6be52e330cc1 | e298bf40ae88c2bd8e0a07f3e92f3e08a92edcc6 | /nova/cmd/compute.py | 08389a16f24119b2c164ccd399e82698802ab5ff | [] | no_license | KevinKaiQian/polar-bear | 46a814c746246394f76505846166673a049f12f2 | 61d4e0ccd7328a6aa543af3b75e5f7fedf98bf8e | refs/heads/master | 2022-04-29T02:15:35.536039 | 2021-05-19T12:33:07 | 2021-05-19T12:33:07 | 172,068,536 | 2 | 0 | null | 2022-03-29T21:56:51 | 2019-02-22T13:11:58 | Python | UTF-8 | Python | false | false | 2,444 | py | # Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# 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 ... | [
"root@localhost.localdomain"
] | root@localhost.localdomain |
a3023c4c318b3cbafd0372ec93f51a1666a9e0cf | 090e04cd5c7f020a03eb6f0dfdb7d37cce555288 | /my_navigation_interface/navigation_interface.py | 55904118838f7e447016caec8a17dff0372079da | [] | no_license | imfog/Groove | dbcddbc040dbd4cd30991b20568046d9ac5590d3 | 3bcdc980b798e901eb1e3e87ebdada268c36f1d4 | refs/heads/master | 2022-12-28T21:57:12.125621 | 2020-10-15T03:32:15 | 2020-10-15T03:32:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,491 | py | # coding:utf-8
from ctypes.wintypes import HWND
from PyQt5.QtCore import Qt, pyqtSignal, QPoint, QEvent
from PyQt5.QtWidgets import QWidget
from .navigation_bar import NavigationBar
from .navigation_widget import NavigationWidget
from .navigation_menu import NavigationMenu
from effects import WindowEffect
class Na... | [
"1319158137@qq.com"
] | 1319158137@qq.com |
e792e19c6c071844b8e14e4097606cc35d55f43f | 4f8a363ad77ffa2772d1916673a390719729ff0f | /example/example.py | afc0c571b7435400d8452ab1ee83c2922e2697b0 | [
"MIT"
] | permissive | HannahVMeyer/bgen-reader-py | c9453063a612c2bc7690c97809a1e746f61b8ebc | 2bbdfbec30df98550d53a13d253fb580bc401690 | refs/heads/master | 2020-03-23T07:10:46.479208 | 2018-07-16T12:49:23 | 2018-07-16T12:49:23 | 141,252,940 | 0 | 0 | null | 2018-07-17T07:58:06 | 2018-07-17T07:58:06 | null | UTF-8 | Python | false | false | 288 | py | from bgen_reader import read_bgen
if __name__ == "__main__":
bgen = read_bgen("example.bgen", verbose=False)
print(bgen["variants"].head())
print(bgen["samples"].head())
print(len(bgen["genotype"]))
p = bgen["genotype"][0].compute()
print(p)
print(p.shape)
| [
"danilo.horta@gmail.com"
] | danilo.horta@gmail.com |
051b4d205eb8834085b0c4a3388e32cdf989b777 | 2affcf450f0bab36b74dd7c8b29522ad38955155 | /pyspedas/geotail/load.py | f27b097b0e3fde3d8f21e205f9036251f591478f | [
"MIT"
] | permissive | nargesahmadi/pyspedas | 1148de83641196681ad65b54e43df0d0c185baf2 | 73ebdabcdef0f6e1087a2a5eb18c3e2384c4fb54 | refs/heads/master | 2022-02-16T18:51:35.204137 | 2022-01-10T23:25:20 | 2022-01-10T23:25:20 | 174,030,853 | 0 | 0 | MIT | 2019-03-05T22:34:32 | 2019-03-05T22:34:24 | Python | UTF-8 | Python | false | false | 2,604 | py | from pyspedas.utilities.dailynames import dailynames
from pyspedas.utilities.download import download
from pyspedas.analysis.time_clip import time_clip as tclip
from pytplot import cdf_to_tplot
from .config import CONFIG
def load(trange=['2013-11-5', '2013-11-6'],
instrument='mgf',
datatype='k0',
... | [
"egrimes@igpp.ucla.edu"
] | egrimes@igpp.ucla.edu |
6b396ca0c75e591c9c9ba4624a333c13ce6f7238 | 36cebe3f80c547aa43c8c015484d37cd8e70722b | /dingtalk/callback/__init__.py | bd11949f57e96341f0ec3b7a894c6ea0882f23cc | [
"Apache-2.0"
] | permissive | 007gzs/dingtalk-python | 7e62f4a722484f9a98a22fc1ad21edebb6b7fddc | d9bc5d1294fc000cc7339b4b82c212c63a419cc6 | refs/heads/master | 2020-03-14T22:17:34.191090 | 2018-04-26T02:18:13 | 2018-04-26T02:18:13 | 131,817,956 | 1 | 0 | null | 2018-05-02T08:00:54 | 2018-05-02T08:00:53 | null | UTF-8 | Python | false | false | 6,837 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Time: 2018/3/1 上午11:20
# @Author: BlackMatrix
# @Site: https://github.com/blackmatrix7
# @File: __init__.py
# @Software: PyCharm
from .crypto import *
from .callback import *
from functools import partial
from ..exceptions import DingTalkExceptions
from ..foundation impo... | [
"codecolor@outlook.com"
] | codecolor@outlook.com |
9ae7ef98bcee9e4b2d7db1dc46125c4be3eda2a4 | b1571f4ee376d789b8094777fd81c4fb47a89cf1 | /AtCoder/練習/others/sumitrust2019/D1.py | d4afae0be30a66063c7a97e2992736d77893989d | [] | no_license | hiroyaonoe/Competitive-programming | e49e43f8853602ba73e658cab423bd91ebbe9286 | 2949e10eec3a38498bedb57ea41a2491916bab1c | refs/heads/master | 2021-06-23T21:56:33.232931 | 2021-05-30T15:27:31 | 2021-05-30T15:27:31 | 225,863,783 | 2 | 0 | null | 2020-06-14T17:54:28 | 2019-12-04T12:37:24 | Python | UTF-8 | Python | false | false | 319 | py | n=int(input())
s=list(map(int,list(input())))
ans=0
for i in range(10):
try:
ss=s[s.index(i)+1:]
for j in range(10):
try:
sss=ss[ss.index(j)+1:]
for k in range(10):
if k in sss:ans+=1
except:pass
except:pass
print(ans) | [
"onoehiroya@gmail.com"
] | onoehiroya@gmail.com |
59f8182ce946966628f9ed37706d098e615c12dc | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_048/ch25_2020_03_31_22_53_41_450736.py | 44e131685efa1784e312a6679f408074c7a2fedb | [] | 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 | 211 | py | v=float(input("qual a velocidade"))
o=float(input("qual o angulo"))
g=9.8
import math
d=((v**2)*math.sin(2*o))/g
if d<98:
print('Muito perto')
elif 102<d:
print('Muito longe')
else:
print('Acertou!') | [
"you@example.com"
] | you@example.com |
92c29e1e0f95c6c8c50f1bb43c30c205f4387ff9 | 69d407235771f364277f78aeb3a03896804cb690 | /astrobf/run/run_mask.py | 029b428e4d2404ca033b7017c4f8c8dc2fb933f6 | [] | no_license | Hoseung/astroBF | 1bb16de1c867b943751ff0d73dfabc5ab7e723c6 | e04efff26e99886c8b7eba42a897277318338d61 | refs/heads/main | 2023-07-17T12:27:10.184080 | 2021-09-01T05:42:05 | 2021-09-01T05:42:05 | 313,825,096 | 0 | 0 | null | 2021-07-22T15:16:58 | 2020-11-18T04:44:01 | Jupyter Notebook | UTF-8 | Python | false | false | 3,500 | py | import matplotlib.pyplot as plt
import numpy as np
import pickle
import sys, math
from glob import glob
from astropy.io import fits
import astrobf
from astrobf.utils import mask_utils
from astrobf.utils.mask_utils import *
import re
def extract_gid(g_path):
import re
return int(re.split('(\d+)',g_path.split... | [
"hopung@gmail.com"
] | hopung@gmail.com |
1f18bb4f0f316c64abea5e788982bfbf7ef4a0b5 | 54f63580a298ffa63520771c734f5b6dd15894bc | /edabit/4_Hard/Next_Prime.py | 1db7b12fc4d3d66d64f66a33297fbc19c046eedb | [] | no_license | CKMaxwell/Python_online_challenge | 048d24128b588d1af3db03379fb462cf7ea908a9 | f13444612d93cf98aff760a6ff01d82a18082725 | refs/heads/master | 2023-01-03T20:19:27.001425 | 2020-10-26T18:25:07 | 2020-10-26T18:25:07 | 287,968,703 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 396 | py | # 20201005 - Next Prime
def next_prime(num):
def prime(current):
check = True
for i in range(2, current//2):
if current % i == 0:
check = False
return check
if prime(num) == True:
return num
else:
while True:
num += 1
... | [
"39400519+CKMaxwell@users.noreply.github.com"
] | 39400519+CKMaxwell@users.noreply.github.com |
dc3186d2a2455dc2d0a0a9cff49870a71018fe2c | fb86f0dca6e525b8a8ddb63f10b8d220ddd7f7fe | /test/functional/rpc_users.py | e0e558491976166d2bcf20a7ad60b036f1e5687b | [
"MIT"
] | permissive | ORO-mlm/UNO-Core | 14fcdb3c2db4bde256e48ea661ada61579ccf403 | d6e6769ce57466cfc9e7cab681eab880cdb8e3e8 | refs/heads/main | 2023-06-16T08:21:00.808606 | 2021-07-12T07:08:35 | 2021-07-12T07:08:35 | 383,350,655 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,951 | py | #!/usr/bin/env python3
# Copyright (c) 2015-2017 The Bitcoin Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""Test multiple RPC users."""
from test_framework.test_framework import UnoTestFramework
from test_frame... | [
"brandon2davincci@gmail.com"
] | brandon2davincci@gmail.com |
c0e2d24a1bc7297c88a9beb74ab0133e4e5aac89 | 9556f7e1d81a305d71a66b9768eba199e396d733 | /CloudVerify/hz_topic/plot.py | 447e8168a5f86e890edab291b63a8088f90bc23a | [] | no_license | gitgaoqian/Python | 301a2823b50ec754a2c1a3f47c39ae8b0b8e6890 | 164f5271044b235d256a9bbe0a34caacf1e81fc8 | refs/heads/master | 2023-01-08T21:23:59.640828 | 2020-11-01T13:06:21 | 2020-11-01T13:06:21 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,121 | py | # -*- coding: utf-8 -*-
"""
Created on Wed Jan 17 20:41:36 2018
@author: ros
"""
import matplotlib.pyplot as plt
def load_data(fileName):
inFile = open(fileName, 'r')
t=[]
rate=[]
num=1
for line in inFile:
t.append(num) #第一部分,即文件中的第一列数据逐一添加到list X 中
rate.append(float(line.strip('\n'... | [
"734756851@qq.com"
] | 734756851@qq.com |
ed902afbfae4296e1b7fd7cc37f83453df65e33c | 0937646b6ce9249a8d193987f308ce398dc28bd1 | /statistics.py | 4a51b15c3db32e5303a16077cf08ea2c86d4f3e8 | [] | no_license | barry800414/JobTitleNLP | 98622d02b25b1418f28698f7d772c8de96642032 | b379c2052447e6483d17f5db51fb918b37ac7a52 | refs/heads/master | 2021-06-08T19:36:39.044757 | 2016-10-21T03:11:10 | 2016-10-21T03:11:10 | 66,043,111 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 917 | py |
import sys, json
from collections import defaultdict
from getCat import *
with open('jobs.min.json', 'r') as f:
data = json.load(f)
with open('104RawCategory.json', 'r') as f:
rawCat = json.load(f)
to2 = getL3ToL2(rawCat)
to1 = getL2ToL1(rawCat)
L3Cnt = dict()
L2Cnt = defaultdict(int)
L1Cnt = defaultdict(i... | [
"barry800414@gmail.com"
] | barry800414@gmail.com |
4581ca0ff8deedc11195f9b9e61bd3b02094bc6a | f4dcb14111539e9a22300256fd6f8fefc61f2d50 | /src/flua/Compiler/Output/cpp/CPPNamespace.py | dc0efdf08384a361bdec9fa561fa5145d8bb7ac0 | [] | no_license | GWRon/flua | 276c3ea4ce1cfcf68a1000fb44512460b5161c4e | 1cf051f1d5aec3ba4da48442a0d7257d399e5b36 | refs/heads/master | 2021-01-15T17:37:03.914965 | 2012-10-24T12:57:27 | 2012-10-24T12:57:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,462 | py | ####################################################################
# Header
####################################################################
# File: Namespace class
# Author: Eduard Urbach
####################################################################
# License
##########################################... | [
"e.urbach@gmail.com"
] | e.urbach@gmail.com |
ec65f29f39de790b1e38281d3dde053db6f88073 | 4ed5069638a0e684e8e813e4ef34dcfd1b68cd74 | /boj/python/9012.py | 23dfb7c5b49336d327f0b59ebfdff9939db6a327 | [] | no_license | youngerous/algorithm | 11dafe9c54edf83646c915c59b1d7d4d18569005 | fe599d958fdf51b956d2250088a3d5f1c5b22854 | refs/heads/master | 2022-01-27T02:12:49.237009 | 2022-01-16T12:29:40 | 2022-01-16T12:29:40 | 133,662,997 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 501 | py | from sys import stdin
input = stdin.readline
N = int(input())
for _ in range(N):
ps = input().strip()
if ps.count("(") != ps.count(")"):
print("NO")
continue
# 처음부터 stack을 int 0으로 할당하면 시간을 더 줄일 수 있을 것
stack = []
try:
for each in ps:
stack.append(each) if each ==... | [
"youngerous@gmail.com"
] | youngerous@gmail.com |
692841366fdad59ec8bf6e644ed7a843673fbc53 | 4c61f3bc0620758224bca72d4edec2707b41ecf0 | /tests/test_victorspx.py | a586ffc0109f6fa13675f07e23206ea903e99df4 | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] | permissive | CrispyBacon1999/robotpy-ctre | 6b5ec68606e5b9094669e468fb4f01cd27f05c9d | b57346dda3de46c6f3bf25dddfe166fbf192846f | refs/heads/master | 2020-12-11T11:47:28.578527 | 2020-01-02T00:35:29 | 2020-01-02T00:35:29 | 233,840,408 | 0 | 0 | NOASSERTION | 2020-01-14T12:50:12 | 2020-01-14T12:50:11 | null | UTF-8 | Python | false | false | 424 | py | import pytest
@pytest.fixture(scope="function")
def victor(ctre):
return ctre.WPI_VictorSPX(1)
@pytest.fixture(scope="function")
def cdata(victor, hal_data):
return hal_data["CAN"][1]
def test_victor_init(ctre, hal_data):
assert 1 not in hal_data["CAN"]
ctre.WPI_VictorSPX(1)
assert 1 in hal_da... | [
"dustin@virtualroadside.com"
] | dustin@virtualroadside.com |
e99d44683d10030de32eea47d3b31d3a6ce832c4 | 1ec89e2731d84f4fc4210060212ea80b002db277 | /pysph/examples/ghia_cavity_data.py | 0c9ded4878f9770d5ce8010d28b8f98994555831 | [
"BSD-3-Clause"
] | permissive | fight1314/pysph | 15600a3053f5bac41bf9c862914e870d93454e20 | 9bfa8d65cee39fbd470b8231e38e972df199a4da | refs/heads/master | 2020-07-21T20:44:26.866017 | 2019-09-04T20:16:53 | 2019-09-04T20:16:53 | 206,971,679 | 3 | 0 | NOASSERTION | 2019-09-07T13:24:51 | 2019-09-07T13:24:51 | null | UTF-8 | Python | false | false | 3,655 | py | """This module provides a few convenient functions for
the Lid Driven Cavity solutions in the paper:
"High-Re solutions for incompressible flow using the Navier-Stokes
equations and a multigrid method", U Ghia, K.N Ghia, C.T Shin,
JCP, Volume 48, Issue 3, December 1982, Pages 387-411.
"""
import numpy as np
from io i... | [
"prabhu@aero.iitb.ac.in"
] | prabhu@aero.iitb.ac.in |
a411c7c8ec083f0a3500bac6c9f4fbebb6cbf0d4 | afdf82890966bd3061db0a2478ad600fb8528475 | /Chapter4/garbage.py | 3ae8e92079e19f310faffcd854cd780535b234ba | [] | no_license | humuhimi/wkwk_nlp | 7cd6653d7cdb2b8f171447c2628b8a517dd65d13 | 48a6ef3745bf2c97c5581034bf85450be5783664 | refs/heads/master | 2022-01-11T09:15:06.378166 | 2019-07-03T08:43:49 | 2019-07-03T08:43:49 | 191,727,302 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 962 | py | # ストップワードの除去:使用頻度の高い言葉を処理対象外にする
import MeCab
# mecab-ipadic-NEologd辞書指定してオブジェクト生成
tagger = MeCab.Tagger()
tagger.parse("")
# 形態素解析の結果をリストで取得、単語ごとにリストの要素に入ってる
node = tagger.parseToNode("機械学習をマスターしたい。")
result = []
#助詞や助動詞は拾わない
while node is not None:
# 品詞情報取得
# Node.featureのフォーマット:品詞,品詞細分類1,品詞細分類2,品詞細分類3,活用形,活... | [
"masa19951009@gmail.com"
] | masa19951009@gmail.com |
cdb0d8b6cd08ee4eb88fdc17d0efedfad34bbef7 | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/nouns/_angina.py | a3b48acb4bd4e8c024e14b432ddc21b2b819b361 | [
"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 | 420 | py |
#calss header
class _ANGINA():
def __init__(self,):
self.name = "ANGINA"
self.definitions = [u'a condition that causes strong chest pains because blood containing oxygen is prevented from reaching the heart muscle by blocked arteries: ']
self.parents = []
self.childen = []
self.properties = []
self.jso... | [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
74d6da60d8fb42c6a20f8541c42289571346ac04 | 942b0a9a24efa9dfc49ff4743180d9a412070359 | /LEARNING/IMPORT/3_RemoteLoad/base.py | 1150d0f6700110235ce38cf885994b3e832de242 | [] | no_license | atomicoo/python-tutorials | c48cd0e4b2b6e70ba177e40ea847c7b398139b62 | e630c9bb3bcddda874a4c0a5b02c7e4d47e1eb7e | refs/heads/master | 2023-02-02T09:46:21.147516 | 2020-12-17T03:59:06 | 2020-12-17T03:59:06 | 317,762,439 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,842 | py | import sys
from importlib import abc
from importlib.machinery import ModuleSpec
import imp
from urllib.request import urlopen
# Debugging
import logging
logging.basicConfig(format='%(asctime)s - %(pathname)s[line:%(lineno)d] - %(levelname)s: %(message)s',
level=logging.DEBUG)
logger = logging.getLo... | [
"atomicoo95@gmail.com"
] | atomicoo95@gmail.com |
a5cf496490118bc838a7e7ce72e2a774864993cf | 20aadf6ec9fd64d1d6dffff56b05853e0ab26b1f | /l5/L5_pbm9.py | d4eb630c9efd666ed8dafec822a97ccc812ed104 | [] | no_license | feminas-k/MITx---6.00.1x | 9a8e81630be784e5aaa890d811674962c66d56eb | 1ddf24c25220f8b5f78d36e2a3342b6babb40669 | refs/heads/master | 2021-01-19T00:59:57.434511 | 2016-06-13T18:13:17 | 2016-06-13T18:13:17 | 61,058,244 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 404 | py | def semordnilap(str1, str2):
'''
str1: a string
str2: a string
returns: True if str1 and str2 are semordnilap;
False otherwise.
'''
if len(str1) != len(str2):
return False
if len (str1)==1:
return str1 == str2
if str1[0]== str2[-1]:
return semord... | [
"femi1991@gmail.com"
] | femi1991@gmail.com |
e59e2f20fba580c5a353b118da2c2220bc2a4e2a | 9adc810b07f7172a7d0341f0b38088b4f5829cf4 | /rlkit/torch/dqn/double_dqn.py | 74b2f68bcafd5be7ce67a3fd89c50b4e34968553 | [
"MIT"
] | permissive | Asap7772/railrl_evalsawyer | 7ee9358b5277b9ddf2468f0c6d28beb92a5a0879 | baba8ce634d32a48c7dfe4dc03b123e18e96e0a3 | refs/heads/main | 2023-05-29T10:00:50.126508 | 2021-06-18T03:08:12 | 2021-06-18T03:08:12 | 375,810,557 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,826 | py | import numpy as np
import torch
import rlkit.torch.pytorch_util as ptu
from rlkit.misc.eval_util import create_stats_ordered_dict
from rlkit.torch.dqn.dqn import DQNTrainer
class DoubleDQNTrainer(DQNTrainer):
def train_from_torch(self, batch):
rewards = batch['rewards']
terminals = batch['termina... | [
"alexanderkhazatsky@gmail.com"
] | alexanderkhazatsky@gmail.com |
d213cd9894b49709b6f412912e23fb194187d63a | c4b636a2fffbf8ef3096e4de9de61b30ea3df72a | /hackerrank/find_tortosian_angle.py | d30648b1f4f0359a1f1c8378e6b8211b53386bd0 | [
"MIT"
] | permissive | FelixTheC/hackerrank_exercises | f63fbbc55a783ee4cecfa04302301a0fb66d45fe | 24eedbedebd122c53fd2cb6018cc3535d0d4c6a0 | refs/heads/master | 2021-01-04T22:10:47.538372 | 2020-11-01T15:57:20 | 2020-11-01T15:57:20 | 240,779,506 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,223 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
@created: 07.07.20
@author: felix
"""
import math
class Points:
__slots__ = ['x', 'y', 'z']
def __init__(self, x, y, z):
self.x, self.y, self.z = x, y, z
def __sub__(self, other):
return Points(self.x - other.x,
sel... | [
"felixeisenmenger@gmx.net"
] | felixeisenmenger@gmx.net |
3ac7de780e04dfd3fb4a83d22d22c72c9b191128 | 2e3f09aa3ad09a33cb9133133a2e7aa92578de00 | /GenPIDMatching/test/test_wETL_cfg.py | 5cb68687b035b0a716ba5b46670157d97bb36f40 | [] | no_license | yszhang95/MTDHIAnalysis | 238f470e941d3d5a5a5c91f5e3d496323dc7a1db | de1e76a2a6d9cc43df992bd3e598f82c77aeebc2 | refs/heads/master | 2020-04-19T00:54:11.669859 | 2018-12-03T12:12:37 | 2018-12-03T12:12:37 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,637 | py | import FWCore.ParameterSet.Config as cms
process = cms.Process("mtdhi")
# initialize MessageLogger and output report
process.load("FWCore.MessageLogger.MessageLogger_cfi")
process.MessageLogger.cerr.FwkReport.reportEvery = cms.untracked.int32(1)
process.options = cms.untracked.PSet( wantSummary =
cms.untracked.boo... | [
"liwei810812@gmail.com"
] | liwei810812@gmail.com |
3291bf56514aaf9d24dd01745b5735be76b4a58e | 6b2a8dd202fdce77c971c412717e305e1caaac51 | /solutions_5738606668808192_1/Python/thomasahle/c.py | eef8d580501ceb9469eb0cf84e9016a7098c1326 | [] | 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,164 | py | import sys
read = lambda t=int: list(map(t,sys.stdin.readline().split()))
#def isweakprime(n):
# return all(n%q!=0 for q in [2,3,5,7,11])
#def isprime(n):
# return all(n%q!=0 for q in range(2,int(n**.5)+1))
#def brute(n):
# for i in range(2**(n-2)):
# j = 1<<(n-1) | i<<1 | 1
# bs = [sum(b**i for i in r... | [
"alexandra1.back@gmail.com"
] | alexandra1.back@gmail.com |
2200a43585376dd23f9cbc67bb71411c8aebf3b8 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02272/s422945045.py | 66f42ba322c67f725b33af923bcbd37a20695982 | [] | 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 | 645 | py | def mergeSort(A,left,right,B):
if left + 1 < right:
mid = (left+right)//2
mergeSort(A,left,mid,B)
mergeSort(A,mid,right,B)
merge(A,left,mid,right,B)
def merge(A,left,mid,right,B):
L = A[left:mid]
R = A[mid:right]
L.append(1000000000)
R.append(1000000000)
i = 0
... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.