blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 281 | content_id stringlengths 40 40 | detected_licenses listlengths 0 57 | license_type stringclasses 2
values | repo_name stringlengths 6 116 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 313
values | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 18.2k 668M ⌀ | star_events_count int64 0 102k | fork_events_count int64 0 38.2k | gha_license_id stringclasses 17
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 107
values | src_encoding stringclasses 20
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 4 6.02M | extension stringclasses 78
values | content stringlengths 2 6.02M | authors listlengths 1 1 | author stringlengths 0 175 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
421e7cdaf623fa7b8157f576be9ee78581a188c9 | 02bcb7bc8563cbc95ecd00689b58f4195e9329f3 | /nets/cifar_nets.py | 0712af08e7e874aee4328d5242a417cfa2b192c6 | [] | no_license | lovecodestudent/RRSVM_pytorch | 53a8d3503b4d8a31931d69549a2464385ddacd81 | 6c7fcec26fb2e176f6cde749a6de3829c981a019 | refs/heads/master | 2021-09-07T03:50:13.442248 | 2018-02-16T21:32:35 | 2018-02-16T21:32:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,828 | py | import torch.nn as nn
import torch.nn.functional as F
from RRSVM.RRSVM_v1 import RRSVM
from pt_utils.t_sets import getOutputSize
import torch
from torch.autograd import Variable
class BaseNet(nn.Module):
def __init__(self, input_size=None):
super(BaseNet, self).__init__()
if not input_size:
... | [
"zwei@adobe.com"
] | zwei@adobe.com |
5517731694153dd6d0907d6cfb449d2a3888c706 | 4e30749e4ec62929de303f7399915e8863e24c74 | /P148.py | a1f5e211375aad1d96d2553df8e02c24ad81627e | [] | no_license | aditi419/P148h | 8af7780494bb421e0847356b1b3e5403c82b74f5 | fedd92144aec375f5c41826ea75832224578f450 | refs/heads/main | 2023-07-15T16:51:39.427471 | 2021-08-28T16:02:27 | 2021-08-28T16:02:27 | 400,833,877 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 702 | py | from tkinter import *
import random
root = Tk()
root.title('List')
root.geometry('400x400')
ListItems = Label(root)
RandomNum = Label(root)
picnicItems = ['Picnic Blanket','Picnic Basket','Cooler','Chairs']
ListItems['text'] = 'Listed Items: ' + str(picnicItems)
def stuff():
randomNumbers = random.sample(range(... | [
"noreply@github.com"
] | noreply@github.com |
edd843a86dade9def9d2f7c90e31ddddc0266609 | ad0ec4a275f4733208f199d97f7ab4c15db51312 | /lib/django_dbtemplates-0.8.0-py2.6.egg/dbtemplates/admin.py | 1b0924bdf1a9832f5fc38e8bd930e232a879bee2 | [] | no_license | OKTago/Bore | 179f9409ae443a2e4bdff4a402aeca2d07eaaba4 | a5043ca6803a659f5d411e0c7fccee3ab98244aa | refs/heads/master | 2021-01-10T20:26:20.049364 | 2010-11-11T10:11:26 | 2010-11-11T10:11:26 | 1,071,075 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,272 | py | import posixpath
from django import forms
from django.contrib import admin
from django.utils.translation import ungettext, ugettext_lazy as _
from django.utils.safestring import mark_safe
from dbtemplates import settings
from dbtemplates.models import (Template, backend, remove_cached_template,
add_template_to... | [
"marco.ferragina@oktago.com"
] | marco.ferragina@oktago.com |
9e6ce10d1dd0a0d4a8cdb718b8d5834908c38f81 | 1cb496cab9ddf375083bb13dfefb40757d15a5dc | /pyrigate/config.py | a7c15da434008b6c7bf0d486f968c0553e414e35 | [
"MIT"
] | permissive | AmerTm/pyrigate | 201c9d5ae38470c0eda6e14a7b26d958d43c611b | d9002f80a6b17078e99cec892f87bac0e6e0bb59 | refs/heads/master | 2020-08-20T11:41:55.614329 | 2019-08-14T21:30:49 | 2019-08-14T21:30:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,927 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Generic plant configuration class."""
import json
from pyrigate.validation import plant_configuration_schema
class PlantConfiguration(object):
"""Light-weight configuration class for plants.
Its main purpose is to provide sensible defaults when certain sett... | [
"alexander.asp.bock@gmail.com"
] | alexander.asp.bock@gmail.com |
ad6c0f965ce7a6c341d00ced7b1dbf7ac4aa9582 | 091f397adba3eeb36557ff84f6b0845e2952ba48 | /roles/.venv/bin/ansible-test | 8821d1729640795f4b3a7966041cf003409217d9 | [
"MIT",
"BSD-3-Clause"
] | permissive | Alex-Mbulankende/testingshit | 0d6d07d0754704abb8a76cb6fe5e620ff96b47d5 | 6cbe5c8da2c030d1e3c989b86adf7b740ac65418 | refs/heads/master | 2022-03-12T04:11:00.763799 | 2019-12-01T05:31:19 | 2019-12-01T05:31:19 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 851 | #!/Users/tjblogumas/blogumas/development/testingshit/roles/.venv/bin/python3
# PYTHON_ARGCOMPLETE_OK
"""Command line entry point for ansible-test."""
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import os
import sys
def main():
"""Main program entry point."""
ansib... | [
"tj.blogumas@codeblogkc.com"
] | tj.blogumas@codeblogkc.com | |
1be0ca744558dc2bd73eb51acecfb4a29395a6ae | 0cb534f6625b7b1ef2e3779b30fae31777fae2af | /products/migrations/0012_auto_20201019_1008.py | f708662a024ef7e398618e4d80567c207c2d933d | [] | no_license | ducnguyen99/digital_world | 34f2496567ff64f6907f79897c74aeb9c15c87ad | ff5259ed0b4fce961f160567e0a97b3f201726d4 | refs/heads/master | 2022-12-31T21:43:26.415363 | 2020-10-22T11:16:33 | 2020-10-22T11:16:33 | 286,378,086 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 482 | py | # Generated by Django 3.1 on 2020-10-19 10:08
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('products', '0011_auto_20201019_0944'),
]
operations = [
migrations.AlterField(
model_name='order',
name='delivery_pric... | [
"nguyenhuungocduc@gmail.com"
] | nguyenhuungocduc@gmail.com |
53c8084f71dafc506e57810a71b1c84208a39d2e | 5c68846730c473da870176862b08847c289d711c | /I0320014_soal1_tugas6.py | 40f95957dead4be1c46bd0af36699e544acf7abf | [] | no_license | audreyalexandra/Audrey-Alexandra_I0320014_Wildan_Tugas6 | 0a55eb1d77d6574be7fcf9991d05654824c14077 | 56eaab5f1a7d4fee7f59f4f4cfc1b4ac329de08f | refs/heads/main | 2023-04-05T19:48:51.153369 | 2021-04-09T23:58:25 | 2021-04-09T23:58:25 | 355,900,541 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 54 | py | i = 1
while i<=10:
print("Hello World")
i= i+1 | [
"audreyalexandra18@gmail.com"
] | audreyalexandra18@gmail.com |
27b97a688d3bb6fd3ac0f10b1ed784f008c2145f | fa4313083d646eaa0b0e071d6367e6f3feccebef | /replace_except_expr.py | 768036b62d1a9dd231eb56e3ce211ac45401648a | [] | no_license | Rosuav/ExceptExpr | 0be15eb05de52067f556a290a7518ad764379e1b | 09392a7de1dd301e70061d8b9e557f4f14fc3d2b | refs/heads/master | 2016-09-05T14:49:10.306855 | 2014-03-04T14:04:21 | 2014-03-04T14:04:21 | 16,904,403 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,830 | py | import ast
import sys
sys.path.append('pep-463-except-expr/Tools/parser')
sys.path.append('Tools/parser')
import find_except_expr
# If true, comment blocks will be inserted to explain the changes made.
# Otherwise, the translation will be "pure".
explain = True
# If omitted, expression->expression except blocks will ... | [
"rosuav@gmail.com"
] | rosuav@gmail.com |
431bfc1d0f37c81c577f6d7e7ac0080fdb36555c | a71ed9977a7774a6e0fc06e83bd01647de46bdb5 | /apigateway/logic/rpe_predictor.py | ac8cf608a26d381efa87ea8ff557992857f1c9c6 | [] | no_license | biometrixtech/plans | 7ba4df97d84d7bf252a919e88fa9cbaa597fde0a | 4d7efb77baca15e8722c37d2cdc7dc84d878ae90 | refs/heads/master | 2022-12-25T00:11:54.022346 | 2020-08-14T14:23:44 | 2020-08-14T14:23:44 | 138,765,729 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,143 | py | import os
from models.movement_tags import Gender
from fathomapi.utils.xray import xray_recorder
from datastores.ml_model_datastore import MLModelsDatastore
class RPEPredictor(object):
def __init__(self):
self.model = MLModelsDatastore.get_hr_model()
@xray_recorder.capture('logic.RPEPredictor.predict_... | [
"dipesh@biometrixtech.com"
] | dipesh@biometrixtech.com |
ed4e407b9e2ea18bea2534cf9cef0cfcc4442a0e | cbb5694845e59f2ba94f687075364f450150d0ad | /users/migrations/0007_alter_profile_bio.py | 760ebed2d27dea0ed0a2c7489d179f9f11f2b752 | [] | no_license | PhantomManYt/hackingtons_social-master | e1fafa81ec68275728e64d777d60613af071d746 | 4ee7747154aa9cfe5ff3b0fec5ba73821021ceb5 | refs/heads/main | 2023-07-13T08:30:15.930469 | 2021-08-20T04:40:16 | 2021-08-20T04:40:16 | 398,139,074 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 391 | py | # Generated by Django 3.2.6 on 2021-08-20 00:56
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('users', '0006_alter_profile_image'),
]
operations = [
migrations.AlterField(
model_name='profile',
name='bio',
... | [
"64277260+PhantomManYt@users.noreply.github.com"
] | 64277260+PhantomManYt@users.noreply.github.com |
072c176eb09f3f0d1c12137a8e34e31477c5eac4 | a8e152cea157b18703c3dc368079b14db1296e5c | /apf/metrics/pyroscope/__init__.py | c0c090a73e2a9018bc5932ceb8b61bdeb11e2565 | [
"MIT"
] | permissive | alercebroker/APF | f2f148c376c0dd9ae27f573e8c84eadb78e813b0 | b2333f52b81486654a396254ee9f40a687f4b080 | refs/heads/main | 2023-08-08T12:27:19.397352 | 2023-07-21T16:01:03 | 2023-07-21T16:01:03 | 223,983,195 | 3 | 2 | MIT | 2023-07-21T16:01:04 | 2019-11-25T15:38:52 | Python | UTF-8 | Python | false | false | 29 | py | from .profile import profile
| [
"pedrogallardorobinson@gmail.com"
] | pedrogallardorobinson@gmail.com |
29e0124b661379789bc2c4f409a4f7bd2b152893 | 45d0f74916a2f63b6b73937a4210247bd17e295d | /kite_purchase.py | 8960c4fddeb0ab1ad3f26a8df71a97249444d59b | [] | no_license | Pradeep9497/manufacturingerp | 100167dd66f619c2b5dd9b66b8364414ffeb77a4 | 3de338cbf98109fe47aace21fcab0a823239457b | refs/heads/master | 2021-09-10T23:56:50.690416 | 2018-04-04T13:49:33 | 2018-04-04T13:49:33 | 114,199,139 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,787 | py | from openerp import tools
from openerp.osv import osv, fields
from openerp.tools.translate import _
import time
from datetime import date
import openerp.addons.decimal_precision as dp
from datetime import datetime
dt_time = time.strftime('%m/%d/%Y %H:%M:%S')
class kite_purchase(osv.osv):
_name = "kite.p... | [
"noreply@github.com"
] | noreply@github.com |
a44c312b288d21db66156e2ee38ac70257256d20 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02918/s539072224.py | 2dbe24e4788b05696bc3160ba49b9b37d37af922 | [] | no_license | Aasthaengg/IBMdataset | 7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901 | f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8 | refs/heads/main | 2023-04-22T10:22:44.763102 | 2021-05-13T17:27:22 | 2021-05-13T17:27:22 | 367,112,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 810 | py | import sys
import numpy as np
input = lambda: sys.stdin.readline().rstrip()
INF = 10**9 + 1
def solve():
N, K = map(int, input().split())
S = np.array(list(input()), dtype='str')
if N == 1:
print(0)
exit()
ri = INF
kc = 0
fs = S[0]
if fs == 'R':
nfs = 'L'
else... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
b66fee40edbe7f81bdb4c9bc16a49fc66944ec23 | cc6167caf1875d5cbad8cb83018c1ee60d9be665 | /Py07/to_upper.py | df13cc5b32cdb796efff747c16c08b2fae6fcfaa | [] | no_license | rcabezas29/Python-Basics | d1bc51c31f1d279f392b6b91b8b9ba36548b4270 | 00adb96b69b701a1ccb0f0d9b89ea1dd6f57b2a1 | refs/heads/main | 2023-06-16T13:59:25.469943 | 2021-07-06T14:01:33 | 2021-07-06T14:01:33 | 365,013,871 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 148 | py | def to_upper(s):
a = s.lower()
return a.swapcase()
def main():
print(to_upper("Hola"))
if __name__ == "__main__":
main() | [
"noreply@github.com"
] | noreply@github.com |
efd021c0316156776876ce0abeeb3c3283a39a3d | eea3f04dc73d4536083c74cac4478835a31c4a94 | /chinese_song_generation/data_utils.py | 75424c8a5cc4c880bf635faf9ab900953138832f | [] | no_license | yscoder-github/news-generate | 15d5f9acecc92add201fb3c53aa211c0aa474e1f | 6b8a98375db984dea9edb4abff72191477bdb406 | refs/heads/master | 2023-05-26T19:58:00.797573 | 2019-07-18T01:30:36 | 2019-07-18T01:30:36 | 187,489,859 | 4 | 4 | null | 2023-05-22T22:14:54 | 2019-05-19T14:50:32 | Python | UTF-8 | Python | false | false | 5,906 | py | # Copyright 2015 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | [
"yscoder@foxmail.com"
] | yscoder@foxmail.com |
68458c655c1f3d9180eeeb19b34f722715887bfa | 79646b0fb15c2f609798ece7c2068af694447bc4 | /scripts/start1.py | 742d4083ab4888aa8a32d59870d339dd7abbf95f | [] | no_license | ankitsaini2609/Automation | ddc689ee2387bf0c09a067d1615b4ab83d6cbba7 | fd67c39edbfc5bea20ee1e3e8bd2d6b44da2329b | refs/heads/master | 2020-03-11T01:53:44.810857 | 2018-08-06T18:39:20 | 2018-08-06T18:39:20 | 129,704,630 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 422 | py | import os,shutil,subprocess
path = os.getcwd()
dirs = os.listdir(path)
for item in dirs:
if os.path.isdir(path+"/"+item):
shutil.copyfile("/root/dataset/scripts/automate.sh",path+"/"+item+"/automate.sh")
os.chdir(path+"/"+item)
try:
s = subprocess.check_output(["/bin/bash","-c"... | [
"ankitsaini2609@gmail.com"
] | ankitsaini2609@gmail.com |
b5f48eaec9414d0da620433ba933b3f89f318c36 | 98decc08fe01b81af5e790288425a8dde1772a14 | /demo.py | 4d07446ef5f61896a581f5c816fb93949ff70cfa | [] | no_license | bcwingnut/apriori | 6f204ba90083ee3c9c4798bbfa1849aad8046150 | 2d5224478e02c2a1441d0429398c83e45447642e | refs/heads/master | 2020-03-09T05:59:03.319977 | 2018-06-22T12:38:59 | 2018-06-22T12:38:59 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 742 | py | import apriori
# Train model and write to file
# support = minimum number of lines containing a group of items
# needed to consider the group appears frequently
# a line of data is valid only if
# min_set_size <= number of items in the line <= max_sey_size
AP = apriori.APriori(data='./test_datasets/freqout.out',
... | [
"csh199883@gmail.com"
] | csh199883@gmail.com |
64b73e76e9a871dc1c4f0f5b76f1a170080ce545 | 74dfbefd05ff71903bc2d13979100ac9a903de8e | /trajectron/evaluation/evaluation.py | 92c45f2b1a62134dc68ff1e4319a7c872f56ba86 | [
"MIT",
"BSD-2-Clause"
] | permissive | zhuMingXu/social-nce-trajectron-plus-plus | 0de7c256f49d86591ecf56659788fd5da9276f63 | fb36669c52af964a8afa58304b9b407e394a3105 | refs/heads/master | 2023-06-19T23:41:43.608244 | 2021-07-22T21:27:54 | 2021-07-22T21:27:54 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,343 | py | import numpy as np
from scipy.interpolate import RectBivariateSpline
from scipy.ndimage import binary_dilation
from scipy.stats import gaussian_kde
from utils import prediction_output_to_trajectories
import visualization
from matplotlib import pyplot as plt
def compute_ade(predicted_trajs, gt_traj):
error = np.lin... | [
"yuejiang.liu@outlook.com"
] | yuejiang.liu@outlook.com |
696ed35bb22e3e88c3a56f39a9cc885a938a4dda | cf8636929ab18fab2ef2fc79c2b522213f57cea1 | /schedule/schedule3.py | 7c524d27dce04a4b266bca35e050f4ccfcdbe5c9 | [] | no_license | LuckyStrike-zhou/excel_helper | ad4b7a1eb8b13ed677795c2e8c1b07c4b3dd6d71 | c912e2247c4737000125c589c5c664a9fc4dfdc2 | refs/heads/main | 2023-02-23T05:59:57.868146 | 2021-01-11T14:10:02 | 2021-01-11T14:10:02 | 315,235,934 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 444 | py | from tkinter import *
root = Tk()
label1 = Label(root, text="Enter Number")
E1 = Entry(root, bd=5)
def isPrime(lbl):
entry1 = int(E1.get())
for d in range(2, entry1):
if entry1 % d == 0:
lbl.config(text="Not prime")
break
else:
lbl["text"] = "Prime"
submit = But... | [
""
] | |
0276923d8773904d13396821fac157e851fd5120 | 76bf0ddf40494ca10ca96800a61487600ce4edc2 | /clientside/migrations/0002_auto_20210627_0717.py | 2c080727537165859fc1a06eedf811902bc48a7f | [] | no_license | albertbolt1/csrabledimageupload | bef0d4acb988cd4ba1165130dc7b054d0f7787f2 | ba6688ddcd30163fdbdbcad5643f5ac60e2a807f | refs/heads/main | 2023-06-29T06:20:23.308786 | 2021-07-11T15:12:32 | 2021-07-11T15:12:32 | 380,535,126 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 679 | py | # Generated by Django 3.2.4 on 2021-06-27 01:47
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('clientside', '0001_initial'),
]
operations = [
migrations.RenameField(
model_name='plantdiseaseimage',
old_name='plantimage1... | [
"45144020+albertbolt1@users.noreply.github.com"
] | 45144020+albertbolt1@users.noreply.github.com |
fb2dac07af82c220e6e4a2f95942ed4fa435a178 | 6ffa236a008d1cd1dc70f2c8ea0544d20ec350ee | /aries_cloudagent/messaging/issue_credential/v1_0/messages/credential_stored.py | 59973aa3320b3ad20a261d63f724ad3d305ab2b3 | [
"Apache-2.0"
] | permissive | blockpass-identity-lab/aries-fl-demo | 99e849f782dd80e729e3fe24c3af2881c5c49dca | 310b748c1ac2e814ec6f97c46ddbb9985584e0fc | refs/heads/master | 2022-07-06T18:37:16.007582 | 2020-04-23T15:48:33 | 2020-04-23T15:48:33 | 221,698,330 | 5 | 0 | Apache-2.0 | 2021-02-26T02:40:03 | 2019-11-14T12:58:58 | Python | UTF-8 | Python | false | false | 911 | py | """A credential stored message."""
# from marshmallow import fields
from ....agent_message import AgentMessage, AgentMessageSchema
from ..message_types import CREDENTIAL_STORED
HANDLER_CLASS = (
"aries_cloudagent.messaging.issue_credential.v1_0.handlers."
"credential_stored_handler.CredentialStoredHandler"
)... | [
"srklump@hotmail.com"
] | srklump@hotmail.com |
1b3dc5794b8d78ef65f79d30b8852f8c5138c541 | b3d00f85b47f6787461061ac955aba4b544e9976 | /trainset_input.py | 678c07722a99cfe6ed433ae7b58bf167a6c5020a | [
"MIT"
] | permissive | chciw/Adversary-about-RGBD-SOD | 94eb9f3863ac93ae42496fc21339a7fc41e1f906 | 19edc78b3abf45313f63212750aaedefb3b82de0 | refs/heads/main | 2023-07-22T08:11:28.283731 | 2021-08-24T02:17:44 | 2021-08-24T02:17:44 | 390,727,685 | 4 | 1 | null | null | null | null | UTF-8 | Python | false | false | 10,360 | py | """
Utilities for importing the nju2000 and nlpr dataset.
Each image in the dataset is a numpy array of shape (224, 224, 3), with the values
being unsigned integers (i.e., in the range 0,1,...,255).
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_functi... | [
"noreply@github.com"
] | noreply@github.com |
8e003e0f09d1d1e726aac6086a86610b4f1d87c7 | 55df546c36e81bbd8786bb092e3be4cf2b2db065 | /example/python/permissions/can_get_all_acc_txs.py | f787d6ed964c1d4580bd3a52d4b578dbdf5c25cb | [
"CC-BY-4.0",
"Apache-2.0"
] | permissive | NickMavronick/iroha | d9dacb651475ac8e2edb0c8fd7af129e08097ca4 | 4839bae80fbf5184af9df9600552fab12af1c513 | refs/heads/master | 2020-06-16T00:26:30.674709 | 2019-07-05T04:35:33 | 2019-07-05T05:21:30 | 195,431,244 | 1 | 0 | Apache-2.0 | 2019-07-05T15:27:13 | 2019-07-05T15:27:13 | null | UTF-8 | Python | false | false | 812 | py | #
# Copyright Soramitsu Co., Ltd. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0
#
import irohalib
import commons
import primitive_pb2
admin = commons.new_user('admin@first')
alice = commons.new_user('alice@second')
iroha = irohalib.Iroha(admin['id'])
@commons.hex
def genesis_tx():
test_permissions ... | [
"andrei@soramitsu.co.jp"
] | andrei@soramitsu.co.jp |
49239cd741a705842914498b8d8adcf755414d87 | 462e53caefc202f1e48f7a3891b27dad6d4032f1 | /src/networkcloud/azext_networkcloud/aaz/latest/networkcloud/clustermanager/_create.py | 17de61aba3e388ebf787cfed6f192b7718b26b70 | [
"LicenseRef-scancode-generic-cla",
"MIT"
] | permissive | bragi92/azure-cli-extensions | a910f14a0613f5611b08ed34ce8d67c1ad05013e | e9aebbcbd3df15fd874a32babc40ae1a0ba23c1f | refs/heads/k8s-extension/public | 2023-08-04T13:22:05.747918 | 2023-07-28T15:45:27 | 2023-07-28T15:45:27 | 205,455,084 | 0 | 0 | MIT | 2019-08-30T20:50:25 | 2019-08-30T20:50:25 | null | UTF-8 | Python | false | false | 16,035 | py | # --------------------------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
#
# Code generated by aaz-dev-tools
# --------------------------------... | [
"noreply@github.com"
] | noreply@github.com |
22eec8aa33a194f79cc77b65625df03bdd5af45d | 145f1ccf9aba3e01300ae18ec43675ad03ff0e7b | /Lab 3/Lab_3.py | 22bf7e68c50f072dc9973d06b2c5f5f7a114e748 | [] | no_license | IzzatHaikal/OS | 3b5cdc673dc058136f09f3ae6ea40d267aafce9f | 079ddc95026e685d48cac4a8079bc8360db76897 | refs/heads/main | 2023-04-01T16:17:47.380218 | 2021-04-05T08:00:44 | 2021-04-05T08:00:44 | 349,398,446 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,143 | py | def SJN():
jobNum = int(input("Enter the number of job(s): "))
job = [None]*jobNum
for x in range(jobNum):
aUnicode = ord("A")+x
job[x] = int(input("Enter job {} CPU cycle: ".format(chr(aUnicode))))
aUnicode += 1
job.sort()
total = totalSJN(job, jobNum)
print("Average tur... | [
"58548850+IzzatHaikal@users.noreply.github.com"
] | 58548850+IzzatHaikal@users.noreply.github.com |
9e10fab873f443c80734eb13d6241d1f1ec1f36f | 1cc98b96c69e8d722455af46eaead8ca0193d03b | /action/commission.py | 350b6afe44e570ce82eb3a9832127c1b28312435 | [] | no_license | sesametian/commission | ae09ffbd46f36c692e321bbbf3adf4ed6b0bb56a | 6e22fe9be938b30d64f3080f2f4428468a6647e2 | refs/heads/master | 2020-07-05T16:24:26.116750 | 2019-08-16T09:58:40 | 2019-08-16T09:58:40 | 202,698,350 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,009 | py | from public.public_db import *
from public.public_excel import *
def b0_b1_b2_result(DB_zhenxuan_and_type_rate_amount, EX_resdict, DB_orderpaid):
IsPass = True
errorInf = None
for ZTRA in DB_zhenxuan_and_type_rate_amount:
if ZTRA[0] == EX_resdict[1] and ZTRA[1] == 0: # 对比甄选收益
print('EX... | [
"hichcock_tian@hotmail.com"
] | hichcock_tian@hotmail.com |
8b3a97ebe43ae145f472de830429cf5e306e5269 | 5c902cfea2856b5b591a9e4de4ecf7d66d01c3a0 | /백준/기초1/수학1/나머지.py | 36861f45235b2a9988962ca407e259b38e24cc23 | [] | no_license | VIXXPARK/pythonAlgorithm | 9cbedf1e9dc387756bed1793081be90e77daf9e8 | 8675fc0e078d90620ecf9dae95c1ccd6bcd36d37 | refs/heads/main | 2023-05-29T10:41:51.900075 | 2021-06-17T23:28:51 | 2021-06-17T23:28:51 | 316,072,889 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 140 | py | import sys
a,b,c= map(int,sys.stdin.readline().rstrip().split())
print((a+b)%c)
print(((a%c)+(b%c))%c)
print((a*b)%c)
print(((a%c)*(b%c))%c) | [
"vixx170627@gmail.com"
] | vixx170627@gmail.com |
2d7098cb8174e3779d78a54cffcff3d299651034 | 5174346f6bd374cc8873a41ed336b7545756d753 | /examples/prompts/toolbar-prompt.py | ff31c5f2951a01c99352e655915d09e1f94ff7bc | [
"BSD-3-Clause"
] | permissive | calebstewart/python-prompt-toolkit | f06dd911399b75e9d4985b485a3e9897c04bf1d6 | 3f9f9a927b2d1a208e59af73e574825df2901e69 | refs/heads/master | 2022-07-02T16:23:24.682709 | 2020-05-14T22:45:14 | 2020-05-14T22:45:14 | 263,998,820 | 1 | 0 | null | 2020-05-14T18:51:02 | 2020-05-14T18:51:01 | null | UTF-8 | Python | false | false | 260 | py | #!/usr/bin/env python
"""
Prompt for user input as a toolbar which disappears after submission.
"""
from prompt_toolkit import prompt
if __name__ == "__main__":
answer = prompt(message="prompt$ ", prompt_in_toolbar=True)
print(f"You said: {answer}")
| [
"caleb.stewart94@gmail.com"
] | caleb.stewart94@gmail.com |
4c2bdb7c3c1f0ffd2ca09b91c2b25d6b3bd6dc4c | ebd5c4632bb5f85c9e3311fd70f6f1bf92fae53f | /PORMain/pirates/effects/DarkPortal.py | 0cf27ecf8deadbcfe7623641ee7db325b3b0db04 | [] | no_license | BrandonAlex/Pirates-Online-Retribution | 7f881a64ec74e595aaf62e78a39375d2d51f4d2e | 980b7448f798e255eecfb6bd2ebb67b299b27dd7 | refs/heads/master | 2020-04-02T14:22:28.626453 | 2018-10-24T15:33:17 | 2018-10-24T15:33:17 | 154,521,816 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,813 | py | from panda3d.core import TransparencyAttrib
# File: D (Python 2.4)
from direct.interval.IntervalGlobal import *
from PooledEffect import PooledEffect
from EffectController import EffectController
from otp.otpbase import OTPRender
import random
class DarkPortal(PooledEffect, EffectController):
def __init__(self):... | [
"brandoncarden12345@gmail.com"
] | brandoncarden12345@gmail.com |
2cb377c43ca73e2cf72a65ab4b4636613e972e8c | b0038c62b3ac288d2dae54ac73fc7a65b1abaefe | /leetcode/medium/16-3sum-closest.py | 6962ac18e17fef931adb52e79be1ef33c07c0458 | [] | no_license | rebornbd/PROBLEM-SOLVE | a9acb5b4c3ad5a7df45fa515842ffb0bdad04512 | b0f20141748fc0937d9caea19ae5fa13b1f01bc7 | refs/heads/master | 2023-07-15T15:39:00.251292 | 2021-08-31T08:58:47 | 2021-08-31T08:58:47 | 400,992,703 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 852 | py | class Solution:
def threeSumClosest(self, nums, target):
nums.sort()
numsLen = len(nums)
res = float('inf')
for i in range(0, numsLen-2):
if i > 0 and (nums[i] == nums[i-1]): continue
low = i + 1
high = numsLen - 1
... | [
"dipta.dhar.bd@gmail.com"
] | dipta.dhar.bd@gmail.com |
328fb9e4369aa42b565a12b663af3028621e6923 | 579737178a1ca75756c85124cbe97fc1d2bded60 | /pyutil/pub.py | 0b22e21d4c121d0f02500420ab0c73069d032d80 | [] | no_license | jbester/python2-util | b183a7b4e430c691badca8352f2a2d1555deb5a7 | 02c1e14c3eb8dad7509df58c6cd8fca192778897 | refs/heads/master | 2021-12-29T07:20:05.311325 | 2011-12-30T21:29:32 | 2011-12-30T21:29:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,274 | py | ################################################################################
# File : pub.py
# Function : Publish/Subscribe Library
################################################################################
# Newest version can be obtained at http://www.freshlime.org
# Send comments or questions to code a... | [
"jbester@gmail.com"
] | jbester@gmail.com |
06864ac65e787aa808340b9594fcc3a612d1f8c5 | 4e30e4f4a98710b0874593166f7d9caff7eb3320 | /Trabajo Final/Script.py | f690e14e5dfaa386eb5cecbdc4d3d5f62cfa8e33 | [] | no_license | majocubero/PF-3115-Laboratorios | 8e53ac7cbec6dde115c42225d056366f2606bbf3 | 42e6c45456d6c72028a3f338fa633c3be3c9e6d5 | refs/heads/master | 2022-11-17T09:09:17.448543 | 2020-06-30T23:49:45 | 2020-06-30T23:49:45 | 257,762,262 | 0 | 0 | null | 2020-06-16T23:29:59 | 2020-04-22T01:46:58 | Python | UTF-8 | Python | false | false | 2,833 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Wed May 27 18:43:02 2020
@author: osvaldo
"""
import pandas as pd
from sklearn.model_selection import train_test_split
#Todo lo comentado fue lo que se hizo para dividir los datos de manera balanceada
'''
#leyendo los datos
datos=pd.read_csv("/home/osv... | [
"osvaldour@gmail.com"
] | osvaldour@gmail.com |
93048f8876fc96b4c7fd4bda1e6719756d628118 | 222d4f2dfb63a66b5de274b785cb92393a2e0fe9 | /after6pm_191113/04.py | 17381eb6ff56e9032c7c90fbf870c88dae44464e | [] | no_license | GyuReeKim/PycharmProjects | fd2584c3ff1369510a7f246f2089cefb77035d9d | dd4f0e15b4e72c68b054489c54f24fa0ba5b9ed3 | refs/heads/master | 2020-07-03T11:44:54.951147 | 2019-11-21T00:07:43 | 2019-11-21T00:07:43 | 201,894,857 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 217 | py | # 연구소
# 벽세우기
import sys
sys.stdin = open('04.txt', 'r')
def f(i, j, lab):
pass
N, M = map(int, input().split())
lab = [list(map(int, input().split())) for _ in range(N)]
print(lab)
f(0, 0, lab) | [
"starkim96@naver.com"
] | starkim96@naver.com |
b6eb1a9acaec58050efa63ac3b0227a9e160bd5e | e8601b69369d36a18ce2256c5d7e55ca87c8daf1 | /hello/userprofile/tests/test_views.py | bba4ab67c89dc9b6114b9ba727223778218d0c88 | [] | no_license | tdn1234/Django | 6f95be985bb0ef79ca8353c78a60fcfb79327305 | e76bda7972dd9d26600e15ff72a734bce85cea18 | refs/heads/master | 2021-01-10T02:51:48.009666 | 2015-11-13T11:02:26 | 2015-11-13T11:02:26 | 46,097,976 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,165 | py | from django.contrib.auth.models import User
from django.test import TestCase
from django.test.client import Client
from django.test.client import RequestFactory
class ViewUserTestCase(TestCase):
def setUp(self):
self.factory = RequestFactory()
self.client = Client()
self.user = User.object... | [
"tdn1234cntt@gmail.com"
] | tdn1234cntt@gmail.com |
55f0d2481754c912cb2c42f535a00f9435de0ad1 | 2e92d8d84c70636d1ccc45cfd323e87881c9bb97 | /distributed-crawler/bot.py | 0c2b0655115de6c1bb0272c5e9a0944a6791db50 | [] | no_license | cctvkill1/test | 258238ee28a747068a76391c4a99c6d6432fea68 | 622ab91273ba8a7fb20710754631795dc95ed5d8 | refs/heads/master | 2021-01-17T07:34:13.316543 | 2019-01-17T14:48:01 | 2019-01-17T14:48:01 | 23,092,358 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 673 | py | # -*- coding: utf-8 -*-
import Queue
initial_page = "http://www.renminribao.com"
url_queue = Queue.Queue()
seen = set()
seen.insert(initial_page)
url_queue.put(initial_page)
while(True): #一直进行直到海枯石烂
if url_queue.size()>0:
current_url = url_queue.get() #拿出队例中第一个的url
store(current_url) ... | [
"1097422313@qq.com"
] | 1097422313@qq.com |
717c663e7b15e05259d4441cf607714ca2bcc424 | e0cf5c5c98661f39b990a1a871292ba307dfa82a | /VIPclient/python/portal.py | e45acc5ba35615b63b154abd9a2f499f4b1234f0 | [
"CC-BY-4.0"
] | permissive | CISI-INSERM/OpenDose-Computing | 1ad3551d82442047b997c29b22fb65f2ad434ffe | d32f5bdb2a58712ca9f05af6909f055b15cacda1 | refs/heads/master | 2020-03-25T14:36:26.358289 | 2019-12-23T10:51:32 | 2019-12-23T10:51:32 | 143,863,267 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,561 | py | import os
import argparse
import configparser
from gate import Gate
from gate_lab import GateLab
from gate_CL import GateCL
class Portal():
def __init__(self):
pass
def parseParams(self):
print("Portal :: parse params")
parser = argparse.ArgumentParser()
parser.add_argument("--config", "-C", help="path to ... | [
"daniel.salas@inserm.fr"
] | daniel.salas@inserm.fr |
eb3fc67560a4cb8799759fb9f9260b886aa4b1dc | 0d366c90d6f70c6c2252b45c1b581fe3732a7998 | /tkdemo/tkdemo/remember.py | 0af0e66d3e344a3d8483a2faaf6e39b9d229e9e9 | [] | no_license | borisbho/PythonPractice | d67f84b3bc0db8ae2711f4d61a9150fad61db646 | deb320174c4354eb1ba6121df9d1c89a5ccdd463 | refs/heads/master | 2020-06-03T11:49:20.615973 | 2019-06-12T11:53:44 | 2019-06-12T11:53:44 | 191,556,977 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,959 | py | from tkinter import Tk, Label, Frame, Button, Entry, Canvas, PhotoImage
import random
root = Tk()
root.title('Remember The GUI Year')
question_1 = ("the start of the Revolutionary War", 1775)
question_2 = ("the United States Constitution signed", 1783)
question_3 = ("President Lincoln assassinated", 1865)
question_4 =... | [
"noreply@github.com"
] | noreply@github.com |
a1ad55236b217f8b3a31a24a32f154b5d7313462 | 607cdcb7dec0bd14052b78de281c6d3049c32b9b | /scraper/parser.py | c2f2cd306bf4c9d95dc682914b5b2ca5200830d0 | [
"BSD-3-Clause"
] | permissive | ea-sal/scraper | d81027cae8d39e232abd230821b1a1c98c9ed7de | c088dc3dc613fec94e297ac71302d2305b44b14c | refs/heads/master | 2022-09-23T16:35:45.178767 | 2020-05-26T15:36:23 | 2020-05-26T15:36:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,371 | py | from parsel import Selector
def get_features_from_item(item_url_responce) -> dict:
"""
takes item link
and gets item's characteristics from link html
:item_url_responce item's url response
:return: item features as a dictionary
"""
item_response_html = Selector(item_url_responce.text)
... | [
"easaltykova@avito.ru"
] | easaltykova@avito.ru |
e8dbf9e194c596ccb086a0b20048def936cb4f39 | d361ec226065d77a69e5179a5746cc1d76ede8de | /FBTserver/apps/account/urls.py | c7591c434ee49e33cbb22885e02a730e9fee36cc | [] | no_license | zhujinliang/FBTserver | e12c5af945c9f45b55aee1c32bcfcdcb0deda826 | ba739230a659f9e15f744b168ef6bbfd3e49fe2c | refs/heads/master | 2016-08-04T09:45:25.733153 | 2013-07-06T08:50:34 | 2013-07-06T08:50:34 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 490 | py | from django.conf.urls import patterns, include, url
from FBTserver.apps.account.views import RegisterView
from FBTserver.apps.account.views import LoginView
from FBTserver.apps.account.views import LogoutView
from FBTserver.apps.account.views import SetPasswordView
urlpatterns = patterns('',
url(r'^register/$', R... | [
"jzhu@redhat.com"
] | jzhu@redhat.com |
6238fb8273504cdc518dfb9eb499d99cd1154705 | 78ef02f8d148713a8ae6e96120761d5e3887098b | /RF_P/PROPMAT-master/matlab_to_propmat/loop.py | 1175a4ed95e43a536792648e23ba3ef470077668 | [] | no_license | DrikoldLun/RF_yORCA | 99bbd93c84be7182546feb5d5c384f35b41d55c0 | 63008599459bd5c9c4479e159c4e32af7b35067d | refs/heads/master | 2023-06-17T09:07:43.015052 | 2021-07-07T13:02:33 | 2021-07-07T13:02:33 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 821 | py | import os
#stalst = os.listdir('../RF_data/event_data_Pcorrected0.1')
#parafile = 'paraRF.cfg'
#config = configparser.ConfigParser()
#config.read(parafile)
#event_path = config.get('path','event_path')
#stalst = os.listdir(event_path)
#stalst = ['CC06','EE04','CC07']
#stalst = ['CC04','CC05','WC03']
#stalst = ['CC05']
... | [
"zhanglnju2015@gmail.com"
] | zhanglnju2015@gmail.com |
b695d8ad94119bbc9b73c478b2406f4ae32ae1be | 071078a168ab73e8f4fb3e47f5c1096b3e41d0ea | /Orders/views.py | e9a5666f559957776b49d9ea450e0c434eeeac72 | [] | no_license | rashad-farajullayev/drf-example | 8cc4745fd739cda2f8b41d526ba8b755979bf5c5 | 99db8850690dd17422292d27d5b774d5d0432332 | refs/heads/master | 2023-04-14T10:15:29.853733 | 2021-04-25T14:46:04 | 2021-04-25T14:46:04 | 361,368,156 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,275 | py | from rest_framework import permissions
from rest_framework import status
from rest_framework.response import Response
from rest_framework.views import APIView
from .models import Order
from .permissions import IsOwnerOfOrder
from .serializer import OrderSerializer, OrderDetailsSerializer
class OrderListView(APIView)... | [
"rashad.farajullayev@atltech.az"
] | rashad.farajullayev@atltech.az |
9c14ff371ae3c1b5705cf3b2b0e761044559e189 | 16af907b1a93c15a55b1bc711db4750ee4afd07c | /krow_package/Krow/__init__.py | c4e6c4665ce2984c3dd29670c8a466c15fbc2b0a | [] | no_license | KrowNetwork/Krowsearch | 03929e097248b5d8541ba6bab959c987d326e7e9 | 2477ea9b24f8cd8d17ee4a34da7ded903d4467aa | refs/heads/master | 2020-03-17T04:14:40.154484 | 2018-11-20T00:11:23 | 2018-11-20T00:11:23 | 133,267,959 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 152 | py | from Krow.chain import Chain
from Krow.applicant import Applicant
from Krow.employer import Employer
from Krow.job import Job
from Krow.errors import *
| [
"siegel.tucker@gmail.com"
] | siegel.tucker@gmail.com |
45aad19c79479fd3824ea58eb7d7717279b0b008 | 6858cbebface7beec57e60b19621120da5020a48 | /ply/modimport.py | f82d08c44b979f0b39be6a4dfe34acf53fbfc6e1 | [] | no_license | ponyatov/PLAI | a68b712d9ef85a283e35f9688068b392d3d51cb2 | 6bb25422c68c4c7717b6f0d3ceb026a520e7a0a2 | refs/heads/master | 2020-09-17T01:52:52.066085 | 2017-03-28T07:07:30 | 2017-03-28T07:07:30 | 66,084,244 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 233 | py | >>> import tokrules
>>> lexer = lex.lex(module=tokrules)
>>> lexer.input("3 + 4")
>>> lexer.token()
LexToken(NUMBER,3,1,1,0)
>>> lexer.token()
LexToken(PLUS,'+',1,2)
>>> lexer.token()
LexToken(NUMBER,4,1,4)
>>> lexer.token()
None
>>> | [
"dponyatov@gmail.com"
] | dponyatov@gmail.com |
524b26645d22e5350ca96393ae4a8f8c7410257e | 4c76dbfaa8f2ca33945e303be90b579c79bd4008 | /renesola/apps/freight/management/commands/build_angular_js.py | 50d8bdd16a9ceccc64c3c8823bb5058badf95821 | [] | no_license | fogcitymarathoner/renasola | 42c32243df4e4c1246d9a85cfb9251aed2264309 | 9089dcc0ffc57a76799f5e99244df644256e08ea | refs/heads/master | 2021-01-11T00:32:40.358446 | 2016-10-10T18:49:50 | 2016-10-10T18:49:50 | 70,517,907 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 362 | py | __author__ = 'marc'
from django.core.management.base import BaseCommand
from django.conf import settings
import os
from renesola_lib.angular_helpers import build_js
class Command(BaseCommand):
"""
field delimiter ';'
text delmiter '"'
"""
args = ''
help = ''
def handle(self, ... | [
"marc@fogtest.com"
] | marc@fogtest.com |
d54db077ad045ae5605a1a04b178f9fac106b3ab | 30a456e3012c663782d2a07a0ff67c377d63790d | /data/ass2json.py | 08561f2f6f0db1ff52593268932f24b680e40cf8 | [
"MIT"
] | permissive | akx/my-video | 41099725fd96f369a1e8e671667e2e7be3256f42 | b1135809f81a34026536d1a8532390dc5f1c7945 | refs/heads/master | 2021-01-24T10:30:53.608241 | 2016-10-01T18:30:34 | 2016-10-01T18:30:34 | 69,733,122 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,283 | py | import argparse
import re, json
import sys
K_RE = re.compile(r'(\{\\k([0-9]+)\})')
def parse_time(dt):
h, m, s, hs = [float(int(p, 10)) for p in re.split('[:.,]', dt)]
return h * 60 * 60 + m * 60 + s * 1 + hs / 100.0
def parse_ass(infp):
for line in infp:
if not line.startswith('Dialogue:'):
... | [
"akx@iki.fi"
] | akx@iki.fi |
3d9f9ad922536fe8a855676dc1949a8d29cbcb0e | ee149168125c6fe3718f525ccf204e36534dc2e4 | /services/db/posts.py | 54cc68b08bba23b039007126fbdd4269bed16c24 | [
"Apache-2.0"
] | permissive | vadimkorr/scheduled-posts-manager | 063d1bdb75d92f18ad461c652ac12e5f1a570e0d | 89fd5779afbd8cd7efdc7e663a2dfb00510304e6 | refs/heads/master | 2021-08-18T11:10:33.059173 | 2019-03-29T20:27:01 | 2019-03-29T20:27:01 | 157,437,694 | 0 | 0 | Apache-2.0 | 2021-06-10T21:00:23 | 2018-11-13T19:53:27 | Python | UTF-8 | Python | false | false | 965 | py | import boto3
import datetime
dynamodb = boto3.resource(
'dynamodb') # , region_name="us-west-2") # , endpoint_url="http://localhost:8001")
postsTable = dynamodb.Table('posts')
def putPost(post):
postsTable.put_item(Item=post)
def getPost(id):
response = postsTable.get_item(Key={
'id': id
... | [
"korobeinikovv@mail.ru"
] | korobeinikovv@mail.ru |
3ce64f0f7cf14fcc36f5f71986bfe87885493f36 | 2bfd3d0d347bb53c49addb13baeb051e7d15f459 | /medilix/users/migrations/0013_auto_20170430_1051.py | 24f25ee3ac2256acb9d74a21d9c150505692e667 | [] | no_license | faradzh/medilix | ec2a6bd2a491c7de38e3935dbed9892f621f7212 | 6c41464fbc84c6850c7c8c24d4dbac52a938b071 | refs/heads/master | 2021-03-19T11:54:16.677656 | 2017-06-05T00:07:13 | 2017-06-05T00:07:13 | 85,694,619 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 630 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-04-30 10:51
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('health', '0002_auto_20170430_0922'),
('users', '0012_auto_20170430_1050'),
]
... | [
"faradj.musaev@gmail.com"
] | faradj.musaev@gmail.com |
1b3572d5cffbf8f576dfef7358f169283ebc397f | 1735d169e79c3b0d5390b46bfc03be4a225b92aa | /manual_tests/testSimulation.py | 3c796fa3ba4243efc0fd1c16c066b15c146e3e49 | [] | no_license | marcoaaguiar/yaocptool | c5750973ffc924e5ff9228f4f827ff161ecd075a | 820513fbff6d7690dfed807fff005325ccd2f452 | refs/heads/master | 2023-07-15T15:04:01.339000 | 2020-06-08T19:18:03 | 2020-06-08T19:18:03 | 104,109,025 | 14 | 0 | null | 2020-06-08T19:18:04 | 2017-09-19T17:56:42 | Python | UTF-8 | Python | false | false | 1,593 | py | from yaocptool.modelling import SystemModel
# create model
model = SystemModel(name="dae_system")
x = model.create_state("x", 2)
y = model.create_algebraic_variable("y", 2)
u = model.create_control("u")
a = model.create_parameter("a")
b = model.create_theta("b")
model.include_equations(
ode=[-a * x[0] + b * y[0]... | [
"marcoaaguiar@gmail.com"
] | marcoaaguiar@gmail.com |
12421fad05503e978ebc58d3a49c3a9bd1325f54 | 876cf08f89a4ecf1c0479362586e5f78ca92e3a2 | /system-tools.py | 41abac388b09c42a12c2471bdf2f90bbf5b44352 | [] | no_license | TheTheseus/dsk-systemtool95 | 6969b4252a9297fc4ca169d412dbff0b7b438008 | 127baee28f52ad0b2895408f25178d00c206e8be | refs/heads/master | 2021-09-07T10:08:13.013639 | 2018-02-21T12:44:44 | 2018-02-21T12:44:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,875 | py | import sys
import os
import time
import requests
import redis
from flask import Flask, request
from flask_restful import Resource, Api
app = Flask(__name__)
api = Api(app)
redis_db = redis.StrictRedis(host=str(os.environ['REDIS_SERVICE_HOST']), port=str(os.environ['REDIS_SERVICE_PORT']))
class SystemToolTime(Resour... | [
"noreply@github.com"
] | noreply@github.com |
69f41c9bc89099a762ed51e3431a4d30ecbb6e04 | 55582eae17ed06d174b4f2fb6aae77a3fecf7300 | /main.py | 84406cfee178dbea83341e47e34061efa20ed2d7 | [
"MIT"
] | permissive | EMBEDDIA/EMBEDDIA-summarization-service | a4c9c1bda4baf95d2b105192b24d0d4c29d08527 | 01607377082edb0a5169a3aebe04a6aaf9b78c90 | refs/heads/main | 2023-06-10T11:45:48.583738 | 2021-06-29T11:35:15 | 2021-06-29T11:35:15 | 379,161,605 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,181 | py | from sklearn.metrics.pairwise import cosine_similarity
import networkx as nx
from sklearn.preprocessing import MinMaxScaler
from utils.encoders import SentenceBERT
def summarize(comments, n):
sentence_encoder = SentenceBERT()
# Compute the sentence embeddings
embeddings = sentence_encoder.encode_sentence... | [
"ales.zagar@hotmail.com"
] | ales.zagar@hotmail.com |
9b5c0769b5bff8e323791aacf80b06da0c16643b | 7af470bb3343cfbacb58aea800822384425471cc | /DCNN-Pytorch/main_autoencoder.py | 70b74f19a5ca651a2d73eeeffb897f682b4a3da3 | [
"Apache-2.0"
] | permissive | SiChiTong/deepracing | 751551a2a616b38b4786ee810466f8246ac1fb6a | 4272069ac249e910ae19f404e746176e4d630fa2 | refs/heads/main | 2023-06-13T09:08:04.029721 | 2021-01-04T18:36:05 | 2021-01-04T18:36:05 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 11,762 | py | import comet_ml
import torch
import torch.nn as NN
import torch.nn.functional as F
import torch.utils.data as data_utils
import deepracing_models.data_loading.proto_datasets as PD
from tqdm import tqdm as tqdm
import deepracing_models.nn_models.LossFunctions as loss_functions
import deepracing_models.nn_models.Models
i... | [
"ttw2xk@virginia.edu"
] | ttw2xk@virginia.edu |
f4fa2a2f4e94d2575f4e90e294396d09f4467611 | 56d0a689a62c1d3090947816f424a3166799d000 | /app/util/util.py | c8af6460dcf1ceeef380ac9177e551c7a8d7c3cc | [] | no_license | jrnn/sholdr | 0df3a2ae0117d23d1b0f7a73d9eceaab5610ae57 | d2253e275de6654d8542208afde33830393f24c0 | refs/heads/master | 2020-03-18T04:49:27.915457 | 2018-06-26T08:51:36 | 2018-06-26T08:51:36 | 134,308,542 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,659 | py | """
This module contains generic utility functions that are needed here and
there.
The several 'apply'-something functions below seem trivial, but they are
needed for WTForm transformations (passed into a field as 'filters').
"""
import re
import uuid
def apply_lower(s):
"""
Apply .lower() ... | [
"juho.juurinen@gmail.com"
] | juho.juurinen@gmail.com |
fc3cf43a004aa546f7a758790863ae7c54f32330 | 9dd43be6dbb1e528f9799d65b443709da8f6ea5b | /build/gazebo_ros_demos/custom_plugin_tutorial/catkin_generated/pkg.develspace.context.pc.py | 9bff73921acb5e36eb9d81b53614e25888663ffb | [] | no_license | wangdwes/catkin | 03de2986113f9c938e6968052b40c911765980b0 | 918b2d369d9b2861048a57810ec6c7981cabf59a | refs/heads/master | 2021-01-01T17:48:31.308964 | 2014-10-24T16:19:22 | 2014-10-24T16:19:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 394 | py | # generated from catkin/cmake/template/pkg.context.pc.in
CATKIN_PACKAGE_PREFIX = ""
PROJECT_PKG_CONFIG_INCLUDE_DIRS = "".split(';') if "" != "" else []
PROJECT_CATKIN_DEPENDS = "roscpp;gazebo_ros".replace(';', ' ')
PKG_CONFIG_LIBRARIES_WITH_PREFIX = "".split(';') if "" != "" else []
PROJECT_NAME = "gazebo_tutorials"
PR... | [
"wangdwes@gmail.com"
] | wangdwes@gmail.com |
d4b86ce8c2dcf80ee5ce28fd7f9795ce4bfad495 | 6fa7f99d3d3d9b177ef01ebf9a9da4982813b7d4 | /93o6y6WKFpQKoDg4T_18.py | 69dd497b116184ce41ce029c7571c5d85d204ef8 | [] | no_license | daniel-reich/ubiquitous-fiesta | 26e80f0082f8589e51d359ce7953117a3da7d38c | 9af2700dbe59284f5697e612491499841a6c126f | refs/heads/master | 2023-04-05T06:40:37.328213 | 2021-04-06T20:17:44 | 2021-04-06T20:17:44 | 355,318,759 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 57 | py |
def sort_by_length(lst):
return sorted(lst, key=len)
| [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
6064a370749e471e4cefe3193b1717f0000647d6 | af4f7d5522e362c207ddc5a06872923fdb38765a | /weixin/views.py | ea98ae4482d92af55be6ba149ba6387c3c05f91d | [
"CC0-1.0",
"LicenseRef-scancode-public-domain"
] | permissive | jixuduxing/django-ex | 288b823f7f0282675fc3f206ffd1d0a847f741fc | fab0a44045206ccb0038d372c70867d5dedbc0a8 | refs/heads/master | 2021-01-21T19:27:49.899007 | 2017-07-03T02:44:34 | 2017-07-03T02:44:34 | 92,139,106 | 0 | 0 | null | 2017-05-23T06:47:54 | 2017-05-23T06:47:54 | null | UTF-8 | Python | false | false | 5,438 | py | import os
from django.shortcuts import render
from django.conf import settings
from django.views.generic.base import View
from django.http import HttpResponse
from django.views.decorators.csrf import csrf_exempt
from django.template.loader import render_to_string
from django.utils.encoding import smart_str
import hashl... | [
"jixuduxing@gmail.com"
] | jixuduxing@gmail.com |
52d2a549bfa98b389a989407e8f89608d0b6d76c | 72e4271f6f6cbe98ae40807f0f22133de026e3fa | /LightBlog/comment/migrations/0001_initial.py | 5eeea8760b99f57c3cebd408eb87d7ce9f1293c8 | [] | no_license | QGtiger/LightBlog_backend | 7a2aa7e87ec83f44756152a53771cf8b36a93999 | 3be4c23a5cb5377e671031403a73e682df05a494 | refs/heads/master | 2020-08-03T01:27:01.430625 | 2020-05-06T03:58:17 | 2020-05-06T03:58:17 | 211,581,132 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,298 | py | # Generated by Django 2.1.5 on 2019-04-23 12:11
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
migrations.swappable_dependency(settings.AUT... | [
"qg6285@apac.arcsoft.corp"
] | qg6285@apac.arcsoft.corp |
cb7fb08c690282edfd833933070c697f756dcb10 | 0fccee4c738449f5e0a8f52ea5acabf51db0e910 | /genfragments/ThirteenTeV/ADD/ADDmonoPhoton_MD_1_d_8_TuneCUETP8M1_13TeV_pythia8_cfi.py | 302e89726365a986e9049cc298156fb6aa79d2a4 | [] | no_license | cms-sw/genproductions | f308ffaf3586c19b29853db40e6d662e937940ff | dd3d3a3826343d4f75ec36b4662b6e9ff1f270f4 | refs/heads/master | 2023-08-30T17:26:02.581596 | 2023-08-29T14:53:43 | 2023-08-29T14:53:43 | 11,424,867 | 69 | 987 | null | 2023-09-14T12:41:28 | 2013-07-15T14:18:33 | Python | UTF-8 | Python | false | false | 1,425 | py | import FWCore.ParameterSet.Config as cms
from Configuration.Generator.Pythia8CommonSettings_cfi import *
from Configuration.Generator.Pythia8CUEP8M1Settings_cfi import *
generator = cms.EDFilter("Pythia8GeneratorFilter",
maxEventsToPrint = cms.untracked.int32(1),
pyt... | [
"sheffield@physics.rutgers.edu"
] | sheffield@physics.rutgers.edu |
bc332131f0a6a057ee10e5475640eb28f9b9d4e2 | f846ffb38d1e4ec046afa9091363f1b560806a4b | /blog/home/migrations/0003_comment.py | 4e72789654e6e91e09b02177f1d73268b3b8b9ef | [
"MIT"
] | permissive | poemcoding/django_blog | 800990abf939b8f996bc94ee47e535b7a4e1d540 | 2a9746d075ff17cc3ffc62b233fd9f17997f6a9e | refs/heads/main | 2023-06-14T05:59:18.897694 | 2021-07-09T14:10:31 | 2021-07-09T14:10:31 | 376,488,077 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,128 | py | # Generated by Django 2.2 on 2021-06-29 14:06
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
('home', '0002_article'),
... | [
"1270502322@qq.com"
] | 1270502322@qq.com |
85beef64fe4dbf5c85d8171398f3294ae72f2cd2 | d9a577a1e6b04413050f4259b0534cd91e412b86 | /src/blog/migrations/0004_auto_20190501_1639.py | 02ec0f400cb56e81d29e5903da26a67a866ddeed | [] | no_license | thinkcodeforlife/django-blog | fe344767fdd0ff5ddabc6274408b5099826152e1 | 0ea098157466e5d33763ee08a4b81e27af7d668a | refs/heads/master | 2020-05-24T08:20:40.982134 | 2019-05-17T10:38:23 | 2019-05-17T10:38:23 | 187,182,445 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 374 | py | # Generated by Django 2.2 on 2019-05-01 13:39
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('blog', '0003_blogpost_slug'),
]
operations = [
migrations.AlterField(
model_name='blogpost',
name='slug',
... | [
"thinkcodeforlife@users.noreply.github.com"
] | thinkcodeforlife@users.noreply.github.com |
9699d2d730841cae22d82c3afd27e8c48dcedfe4 | 241dab5ef171872d15485809b2616319ed7eec71 | /backend/scripts/data_scrape/eoddata_scrape_daily.py | 5f9c1f499227a581793821130aba27e5ca037a0f | [] | no_license | gitori90/Python_stocks_scrape_analysis | 2dca7d99e8d70e114c517262636b481b1a7abd41 | b9d471f107460626d576364e619358f48230da52 | refs/heads/master | 2022-11-20T10:04:54.607357 | 2020-07-23T10:14:12 | 2020-07-23T10:14:12 | 265,858,889 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,674 | py | import pandas as pd
import threading
import backend.scripts.data_scrape.path_finding_functions as path_functions
from backend.scripts.df_utils.data_frame_utilities import replace_all_nan
def load_sheet_to_dataframe(sheet_name, title):
try:
symbols_file_name = path_functions.get_symbols_file_path(title)
... | [
"orifreedman@gmail.com"
] | orifreedman@gmail.com |
fe5021e04b8f5a928fd508dbb912b1ca292dde6e | 041d13ee537f70b192e28ee2c5e64c0d1ed21e3f | /mutate.py | 11dafb10391d3b62b54f842b39edd6b82b563194 | [] | no_license | rafgro/vanilla_evo | 359694a2630331ef9f3cd159ef5458abed51201d | b7522bf882d08109a20d5ccb744d69601bcb381a | refs/heads/main | 2023-02-25T03:37:41.148399 | 2021-01-04T19:58:57 | 2021-01-04T19:58:57 | 316,687,803 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,312 | py | """
Mutation Module
Main Purpose
------------
Introduce primary source of variability within genomes
"""
from random import randint
from codon import Codon
def mutate(agenome, frequency_table):
""" Change sequence of codons in a random way
Parameters
----------
agenome: Genome class
Diploid... | [
"rafal.grochala@op.pl"
] | rafal.grochala@op.pl |
5588811602468117dcf4c2c815b823cd9c66efd6 | 0bb474290e13814c2498c086780da5096453da05 | /abc151/C/main.py | de4737e84810f2b025becf5752de28655a3a7833 | [] | no_license | ddtkra/atcoder | 49b6205bf1bf6a50106b4ae94d2206a324f278e0 | eb57c144b5c2dbdd4abc432ecd8b1b3386244e30 | refs/heads/master | 2022-01-25T15:38:10.415959 | 2020-03-18T09:22:08 | 2020-03-18T09:22:08 | 208,825,724 | 1 | 0 | null | 2022-01-21T20:10:20 | 2019-09-16T14:51:01 | Python | UTF-8 | Python | false | false | 1,054 | py | #!/usr/bin/env python3
import sys
sys.setrecursionlimit(10000000)
INF = 1<<32
def solve(N: int, M: int, p: "List[int]", S: "List[str]"):
dp = [[0, 0] for i in range(N+1)]
for i in range(M):
if S[i] == 'AC':
dp[p[i]][0] = 1
else:
if dp[p[i]][0] == 0:
... | [
"deritefully@gmail.com"
] | deritefully@gmail.com |
fdb50e78d8f3cd88a933c0267dc004b8cf101a43 | 424f489cb3bdbec53431bbcfbcb63f54ff030e15 | /apps/users/serializers.py | 919e4c3cad1951bfbbd0e7acebee7397bfe0a344 | [] | no_license | overproof9/curs-valutar | 9f93c8c3ba89dd95e54bd98fefe63c610cc089fa | db6019e6247ff54f703c30c7149b0de66e56d7eb | refs/heads/master | 2022-11-06T08:31:39.611894 | 2020-06-24T07:05:58 | 2020-06-24T07:05:58 | 274,331,809 | 0 | 0 | null | 2020-06-23T06:55:27 | 2020-06-23T06:55:26 | null | UTF-8 | Python | false | false | 297 | py | from django.contrib.auth.models import User
from rest_framework import serializers
class UserSerializer(serializers.ModelSerializer):
password = serializers.CharField(write_only=True)
class Meta:
model = User
fields = ("first_name", "last_name", "username", "password",) | [
"ordersone@gmail.com"
] | ordersone@gmail.com |
db3d0d50a7710a487c431dd03dac4101012f8f99 | 3e8be7dd89413314afa0d70cf2933d467e94946d | /solution.py | ad68b77ec4735b3be2c54cdd28774a61e14151e0 | [] | no_license | shubhra-3/Area-of-burnt-forst-prdiction | e4b709c8824c4477f7beb29cb35eacc38c400d8e | 7b31b990f006d4d34b011985e13fe96222f1c7eb | refs/heads/master | 2020-04-22T16:45:35.329814 | 2019-02-13T14:24:48 | 2019-02-13T14:24:48 | 170,519,350 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,289 | py |
import numpy as np
import matplotlib.pyplot as plt
import pandas as pd
dataset = pd.read_csv("train.csv")
#colnames=['Id','X','Y','month','day','5','6','7','8','9','10','11','12','13']
testset = pd.read_csv('test.csv')#, names=colnames, header=None)
from sklearn.preprocessing import LabelEncoder, OneHot... | [
"noreply@github.com"
] | noreply@github.com |
e24d7c430d94b09680a7007fec6b40a7a58a2934 | 192dae6c34e098de419ddac360e2ff33ae7fd0eb | /rubbish/neighours/neighbour_api.py | 41ee4960fa4921a187ab31fe965b48ff1fcafdfd | [] | no_license | whelks-chance/wiserd3 | 33298d1344253e5cca26c984c265f4b15e475d72 | 1df72cc8e01f991dfb017d77df3e864418cd8ed9 | refs/heads/master | 2023-05-05T02:53:33.945769 | 2022-04-20T08:19:56 | 2022-04-20T08:19:56 | 38,719,496 | 3 | 1 | null | 2023-04-21T20:25:23 | 2015-07-07T23:04:36 | JavaScript | UTF-8 | Python | false | false | 10,629 | py | # coding=utf-8
import os
from copy import deepcopy
from openpyxl.reader.excel import load_workbook
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'wiserd3.settings')
import django
django.setup()
from django.db import connections
from dataportal3 import models
import json
import requests
from django.contrib.gis.geos... | [
"i.c.harvey@cs.cf.ac.uk"
] | i.c.harvey@cs.cf.ac.uk |
9eeb6493e7ffc4de7c553d77979a09da3caeaa1e | 8e1668e35a8df9968ab14d16db089b51dbe6dd51 | /python/algorithms/contests/four_divisors.py | 77b0e61ed7442f35a879a90753b56c9b384e7f7b | [] | no_license | Chalmiller/competitive_programming | f1ec0184d1ff247201522ab90ca8e66b3f326afc | b437080d1ba977c023baf08b7dc5c3946784e183 | refs/heads/master | 2021-03-24T05:11:59.383916 | 2020-08-24T22:07:41 | 2020-08-24T22:07:41 | 247,519,998 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 557 | py | from typing import *
class Solution:
def sumFourDivisors(self, nums: List[int]) -> int:
divisors = 0
for i in nums:
num_divisor = []
for j in range(i+1):
if len(num_divisor) > 4:
break
if i%(j+1) == 0:
... | [
"chalmiller1@gmail.com"
] | chalmiller1@gmail.com |
4d620495621fd8734bc2f5085f0814fab0602439 | db6d37fcf5545acd3dd9910674c0f43c90410e0a | /iterminal/controllers.py | 88f3f762f83c05c23a9cf06bbd3546a14f2d520a | [] | no_license | capalmer1013/i | 629bb44b4640fc91be883ca2e47c6a3d81f51a0b | 4e0bc895ad232cad7dfefefec35a67346da6794b | refs/heads/master | 2023-02-23T02:35:44.270400 | 2022-04-27T03:04:21 | 2022-04-27T03:04:21 | 86,883,795 | 0 | 0 | null | 2023-02-16T00:32:58 | 2017-04-01T04:29:44 | Python | UTF-8 | Python | false | false | 519 | py | import curses
from iterminal.constants import UP, DOWN, LEFT, RIGHT
def inputController(stdscr, p):
while True:
key = stdscr.getch()
#stdscr.addstr(0, 0, str(key))
dirDict = {curses.KEY_UP: UP, curses.KEY_DOWN: DOWN, curses.KEY_LEFT: LEFT, curses.KEY_RIGHT: RIGHT}
shootDict = {ord(... | [
"capalmer1013@gmail.com"
] | capalmer1013@gmail.com |
ed8a2c4e242ca9537a384879948138caac9539c7 | 870e0facc200437912f3ac6c79ee6c1b810135a1 | /mdbtoSav.py | 9f5f93c497839c1f6d01414a502565933f4bd040 | [] | no_license | jhovannycanas/mdb_to_spss | 5565893a2decf2614e3503f23b9668b95cda43d9 | 7d7bf1707d61fd185ad81b2e80c7cca887d042bf | refs/heads/master | 2021-06-15T04:03:23.692339 | 2017-03-21T15:25:29 | 2017-03-21T15:25:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 658 | py | __author__ = 'jhovanny'
#!/usr/bin/python
# -*- coding: utf-8 -*-
import sys
#sys.setdefaultencoding("utf-8")
#reload(sys)
import savReaderWriter
import locale
import os
import collections
from obdc import *
varLabels = {'var1': 'This is variable 1',
'v2': 'This is v2!',
'bdate': 'do... | [
"jhovannycanas@gmail.com"
] | jhovannycanas@gmail.com |
854a857b9eedc99be8a2332e23c37f43e09f4bc4 | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /FjiriGn8gc5RE8Xm2_7.py | efeef575fedcd049a250bbc0cfb0345e324e582a | [] | no_license | daniel-reich/turbo-robot | feda6c0523bb83ab8954b6d06302bfec5b16ebdf | a7a25c63097674c0a81675eed7e6b763785f1c41 | refs/heads/main | 2023-03-26T01:55:14.210264 | 2021-03-23T16:08:01 | 2021-03-23T16:08:01 | 350,773,815 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,014 | py | """
Write a function that takes `fuel` (liters), `fuel_usage` (liters/100km),
`passengers`, `air_con` (boolean) and returns maximum distance that car can
travel.
* `fuel` is the number of liters of fuel in the fuel tank.
* `fuel_usage` is basic fuel consumption per 100 km (with the driver inside only).
* Ever... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
f62ec39eec2222c4bc33d3bddf25ea8511ed90fe | e63771573603a6eba9178e15770c427849bb4644 | /django/arzaq/settings.py | 9b2f8bff32e2ed8e61a18f74d06cdc1cfba5db31 | [] | no_license | sohepalslamat/WebApplaction-Arzaq | 44b581725802d0ab9c2ba42b5757ae4cee6a0ea5 | 15504ef3a4f4b5815099b8cd1f9e4489e2a859ec | refs/heads/master | 2023-02-02T11:59:40.123142 | 2019-12-05T20:43:24 | 2019-12-05T20:43:24 | 214,710,377 | 0 | 0 | null | 2019-10-12T20:37:57 | 2019-10-12T20:23:15 | JavaScript | UTF-8 | Python | false | false | 3,641 | py | """
Django settings for arzaq project.
Generated by 'django-admin startproject' using Django 2.2.2.
For more information on this file, see
https://docs.djangoproject.com/en/2.2/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/2.2/ref/settings/
"""
import os
# B... | [
"sohep.alslamat91@gmail.com"
] | sohep.alslamat91@gmail.com |
44dd80d350dc467c7a172ab66eb9a3ecfda16c3f | af83851eabb687a9549dedfe131aa620de9b60d2 | /Leetcode/equal-Domino-rows.py | 4fa5ad984b2a556be8c10c02171d6c6304d471a1 | [] | no_license | LalitGsk/Programming-Exercises | e6a6607d72583f6668839e2325d96fb976e9e44f | f575e662f28ea13984304f2f0639dc1cb392e679 | refs/heads/master | 2020-07-26T18:44:54.516607 | 2020-07-09T04:44:40 | 2020-07-09T04:44:40 | 208,736,087 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 849 | py | # -*- coding: utf-8 -*-
"""
Created on Sun Oct 6 19:11:26 2019
@author: lalit
Minimum Domino Rotations For Equal Row
"""
class Solution:
def minDominoRotations(self, A: list[int], B: list[int]) -> int:
def check(x):
rotations_a = 0
rotations_b = 0
... | [
"noreply@github.com"
] | noreply@github.com |
f17025743fc841a91077662b31a3cb066d361be2 | a5e5d39f42f468d35f18aab3e78c3c090046b0df | /apps/contacts/forms.py | 72c512374bed6f2e74a37ac9c50a2a1151e9ee6e | [] | no_license | WayneLambert/portfolio | 66198dfc18b3f254e6bc726575903c3e8f570dc4 | 7e02165386e4784f81e15bae0325a77cf45f410d | refs/heads/main | 2023-02-04T18:08:13.559223 | 2023-01-29T14:13:59 | 2023-01-29T14:13:59 | 180,239,669 | 5 | 1 | null | 2023-02-04T07:07:10 | 2019-04-08T22:02:22 | JavaScript | UTF-8 | Python | false | false | 568 | py | from django import forms
from captcha.fields import ReCaptchaField
from captcha.widgets import ReCaptchaV3
from apps.contacts.models import Contact
class ContactForm(forms.ModelForm):
class Meta:
model = Contact
fields = ('first_name', 'last_name', 'email', 'message')
captcha = ReCaptchaFi... | [
"wayne.a.lambert@gmail.com"
] | wayne.a.lambert@gmail.com |
537b1e6af4b96fd09dba3bd4344c38fb66b9ca65 | d4e9a392d7465a5c10417364dd91cd5dd3c5d935 | /app/preprocess.py | d0fbfc80e4a532a5803e9d7632c2c1743c42d9e6 | [] | no_license | MaayanLab/harmonizome-ml | 045f866bac4683a23dd8a393e48f9f09bb08c35d | 5cebd194d771b1d7eabeb65a1c81ce0c78bf7a80 | refs/heads/master | 2020-03-21T13:26:26.132737 | 2020-03-05T22:46:38 | 2020-03-05T22:46:38 | 138,605,770 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,905 | py | #!/usr/bin/env python
import os
import nbformat
from flask import render_template
from . import app
from .model import build_fields
from .runtime import ipynb_import_from_file
from .template.nbtemplate_parse import parse_fields
from .util import app_dir, globalContext
@app.template_filter('filter')
def reverse_filter... | [
"u8sand@gmail.com"
] | u8sand@gmail.com |
1fb7519779c1e12faf9d7ed6d7b1edb5f68fa6d2 | d7e9cdf4e92388b897066010c1b8d12d22ada267 | /python/code/sensors/BMP280_read.py | 26250e9d74b2c40170f237c4acc23743b1897c0f | [] | no_license | adavidson32/EOTG | 700c146944c98ea88f4288bed97e7ab7f738996a | 8ad02cfb0e71e972b7a8789ffaba2a60ab2d29ee | refs/heads/master | 2020-05-26T13:55:54.343848 | 2017-04-25T18:43:40 | 2017-04-25T18:43:40 | 85,002,940 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,560 | py | import logging
import Adafruit_GPIO.I2C as I2C
i2c = I2C()
# BMP280 default address.
BMP280_I2CADDR = 0x76
BMP280_CHIPID = 0xD0
# BMP280 Registers
BMP280_DIG_T1 = 0x88 # R Unsigned Calibration data (16 bits)
BMP280_DIG_T2 = 0x8A # R Signed Calibration data (16 bits)
BMP280_DIG_T3 = 0x8C # R Signed Calibratio... | [
"noreply@github.com"
] | noreply@github.com |
fa9ba509291b1804040cd413eb7052b6604d9ee3 | b62c0f6beef30a82170082e5538946e70d1d1c32 | /apps/Image/models.py | 543ef73759f5df826005f35c7bcdcb8e648d51fd | [] | no_license | IOSZYQ/LushuTools | a78153a8ea5321128614d453b6fe305795a650d9 | f05adc60917b47973a3f55b2f52b3b786438dfd0 | refs/heads/master | 2020-04-13T10:54:04.336775 | 2019-01-25T11:27:45 | 2019-01-25T11:27:45 | 163,156,781 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 330 | py | from django.db import models
# Create your models here.
class Image(models.Model):
imageName = models.CharField(verbose_name='图片文件名', max_length=64, unique=True)
class Meta:
verbose_name = "图片"
verbose_name_plural = verbose_name
def __str__(self):
return str(self.imageName)
| [
"hualing_zyq@126.com"
] | hualing_zyq@126.com |
1112cd1cd75612f8e8bcc2c5a3a0903f36c25d3b | 06013cedb6e028397ef8be1798a2d15148ad350d | /lab_3/var_5/flask_server.py | 259936dcdf07ee7d76875c84a1ec7f22814aaff9 | [] | no_license | ShJL/IrfmLabs | 495f7d652380a8235a2291093c320196d1f30a6f | 36fc6b97fb9213ecdeb8851ef48b021d1ca98690 | refs/heads/master | 2020-04-22T23:19:13.414526 | 2019-04-08T20:45:03 | 2019-04-08T20:45:03 | 170,737,753 | 2 | 3 | null | null | null | null | UTF-8 | Python | false | false | 3,472 | py | import flask
import sqlite3
import db.sql_consts as sc
_OK = 200
_BAD_REQUEST = 400
_NOT_FOUND = 404
app = flask.Flask(__name__)
def _get_db():
db = getattr(flask.g, "_db_connection", None)
if db is None:
db = flask.g._db_connection = sqlite3.connect(sc.DATABASE)
db.row_factory = lambda c... | [
"LDDD5@yandex.ru"
] | LDDD5@yandex.ru |
40c7a96a66c6ce84439222e54679cc51149bc0ba | a86293a2033c06410aa8ed19bcbce8ca55ea3c55 | /src/client_libraries/python/dynamics/customerinsights/api/models/cds_org_info.py | e414e4e2f31a4ed4afa9f160f9258d839d0aa435 | [
"LicenseRef-scancode-generic-cla",
"MIT"
] | permissive | ramotheonly/Dynamics365-CustomerInsights-Client-Libraries | a3ca28aa78d2b5509e65d9895ff4a0d42d05f611 | e00632f7972717b03e0fb1a9e2667e8f9444a0fe | refs/heads/main | 2023-08-02T08:09:04.063030 | 2021-09-28T22:42:15 | 2021-09-28T22:42:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,154 | py | # coding=utf-8
# --------------------------------------------------------------------------
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------
from ... | [
"michaelajohnston@mac.com"
] | michaelajohnston@mac.com |
a99dbdf037c0559627072edbf0cd2f7e24983bb2 | 01f77b70dfb8817a913414fd25d9ed44ba3cd1f4 | /oscar_invoices/urls.py | 1bc931c736f24795068621e2e1d47790be762a5e | [] | no_license | luiz158/django-oscar-invoices | ca2cf8b70347000399c5316532aca7e52d0f77a3 | 9cc3425410641a95832bda93155e4d2bfa95ac7e | refs/heads/master | 2023-07-02T22:21:03.318698 | 2020-10-06T16:01:02 | 2020-10-06T16:01:02 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 190 | py | from django.urls import re_path
from . import views
app_name = "oscar_invoices"
urlpatterns = [
re_path(r"invoice/(?P<pk>\d+)/", views.InvoicePreviewView.as_view(), name="invoice"),
]
| [
"sasha@sasha0.ru"
] | sasha@sasha0.ru |
200e9ea914f49811117ea1217accd0bb9a5faa8e | 0845c7a5bcd8426dbaa20d146b75b5bc00c41f3a | /simulation/utils/road/sections/test/zebra_crossing_test.py | 163161ec81fc8648de27cfe904baa755dd9ca084 | [
"MIT"
] | permissive | GeSteine/kitcar-gazebo-simulation | b96b407e34b61b9084846e5fea68f14a9eec78fd | adfdadd83cbdb6d577c665076f831704bde95f1d | refs/heads/master | 2022-11-17T06:04:09.237815 | 2020-06-24T18:32:42 | 2020-06-24T18:32:42 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 933 | py | import unittest
from simulation.utils.geometry import Point, Polygon, Transform
from simulation.utils.road.sections.zebra_crossing import ZebraCrossing
import simulation.utils.road.sections.type as road_section_type
from simulation.utils.road.config import Config
class ModuleTest(unittest.TestCase):
def test_z... | [
"ufzev@student.kit.edu"
] | ufzev@student.kit.edu |
d7b9f75239b7b347072009145160460e4ebf3de9 | ac9bff6f5ae0d52acf3541f0002b69dd5ad8855a | /dataEncode.py | a2146304f52d41472f30d7870eba5c2621658f4d | [] | no_license | Dofolk/BiRen | 610f8daa978a97adacea165fc701532d5f127ed8 | 5fc76c3cdb435bbcde5537e51980c53e105e32b4 | refs/heads/master | 2023-07-08T15:01:31.835696 | 2019-07-05T00:57:54 | 2019-07-05T00:57:54 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,587 | py | import numpy as np
import os
import sys
import commands
fileName = sys.argv[1]
genome = sys.argv[2]
evolutionaryConservation = sys.argv[3]
# Check argv length
if len(sys.argv) != 4:
print "Miss required parameter"
print "Usage :"
print " python example genome.fa EvolutionaryConservation.bw"
os._exit(0)
else:
pa... | [
"noreply@github.com"
] | noreply@github.com |
759453a9942cf164858e0646369370b634ed8630 | 751300a23242cfe393f86ff489339ffc81319efc | /speaker_spotting/speaker_spotting_oracle_cluster2-dev.py | 9ee8cd16ac65ab6ad961b195a92ffb3714d90be2 | [] | no_license | yinruiqing/speaker_spotting | bc349791a59c6caa2a840fb39aa1d4c1221f99e9 | c2fbdcbf2885d9545abe8bf1e19b2c412b0680ee | refs/heads/master | 2021-05-04T14:39:33.213405 | 2018-05-03T10:28:11 | 2018-05-03T10:28:11 | 120,207,231 | 2 | 4 | null | null | null | null | UTF-8 | Python | false | false | 4,962 | py |
# coding: utf-8
# ```bash
# $ pip install pyannote.metrics==1.4.1
# $ pip install pyannote.db.odessa.ami==0.5.1
# ```
import clustering
import numpy as np
from pyannote.audio.features import Precomputed
precomputed = Precomputed('/vol/work1/bredin/speaker_spotting/embeddings')
from pyannote.database import get_pr... | [
"yinruiqing110@gmail.com"
] | yinruiqing110@gmail.com |
b65a0d35db9f6025977c8d15e05fa76d1205eabb | ebfa76d74294fa64648146e6726cc69d3e25e23f | /parlai/mturk/tasks/light/light_chat_eval/worlds.py | 1ecac1421555897bf2765a369fcd6ba4428df1e3 | [
"MIT"
] | permissive | ritvik1512/ContrastiveLearning4Dialogue | 17b770a8c777aca9f5be273ff41f02c4530f8ff3 | 873c20d21ee810750179356c353d2cce244db028 | refs/heads/master | 2023-03-12T15:17:43.635546 | 2021-02-24T07:20:27 | 2021-02-24T07:20:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 15,029 | py | #!/usr/bin/env python3
# Copyright (c) Facebook, Inc. and its affiliates.
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
from parlai.mturk.core.worlds import MTurkOnboardWorld, MTurkTaskWorld
from parlai.mturk.core.agents import (
MTURK_... | [
"caihengyi@ict.ac.cn"
] | caihengyi@ict.ac.cn |
364b52dce6b0b45a45ebc5c83fd807abaf14be33 | f4be48866d7d2181d563939cee82671b893ddbb9 | /kubecd/tests/helm_test.py | 9f7ced88d45076beffcc4b869d72427b85b75dbd | [
"Apache-2.0"
] | permissive | cvega/kubecd | cd893639cf6e683caa6a94eea730cf956be3f0ed | 3e181d29caa4220c19dcd80ed44e5aaec1e6c955 | refs/heads/master | 2020-03-26T22:19:51.775077 | 2018-06-20T06:12:23 | 2018-06-20T06:12:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 582 | py | from .. import helm as sut
def test_lookup_value():
assert 'foo' == sut.lookup_value('a.b', {'a': {'b': 'foo'}})
assert 'foo' == sut.lookup_value(['a', 'b'], {'a': {'b': 'foo'}})
assert sut.lookup_value(['b.a'], {'a': {'b': 'foo'}}) is None
def test_key_is_in_values():
assert sut.key_is_in_values(['... | [
"stig@zedge.net"
] | stig@zedge.net |
03ea1e159edc4c6f2403ada2fec1c9b11f7da13f | 43bf5f016b72ae137e18d72bffaec4a3fb9f2fea | /E_learning/E_learning/settings.py | b38dfd995319549de6f4f97431e889e2f3c14753 | [] | no_license | oyewunmio/Django_works | 374a414543ee91093328993c287bcc7e4d900a5c | 99161bcf5542122cf0703af809e336d5e7888c54 | refs/heads/main | 2023-07-03T09:57:10.534592 | 2021-08-15T17:31:28 | 2021-08-15T17:31:28 | 389,153,021 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,498 | py | """
Django settings for E_learning project.
Generated by 'django-admin startproject' using Django 3.2.4.
For more information on this file, see
https://docs.djangoproject.com/en/3.2/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/3.2/ref/settings/
"""
from path... | [
"42620838+oyewunmio@users.noreply.github.com"
] | 42620838+oyewunmio@users.noreply.github.com |
cd101dd7fed78764bf7b94b637a62e38eca94487 | ad1697f00a25fd249ccd4a175cb29f1cb89fd4d4 | /app/app.py | 90074be9ace0662badc3e0dd8f08509692e67531 | [] | no_license | sarathk-vmw/test18 | 427b0f7efc48d3ede0b7e703003757dcbed5f12d | 0e006d060dcebb65c39d83203b0960d32527e7f5 | refs/heads/master | 2021-01-11T06:58:26.602181 | 2017-08-20T07:00:48 | 2017-08-20T07:00:48 | 71,971,377 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 189 | py | from flask import Flask
app = Flask(__name__)
@app.route("/")
def index():
return "Welcome Docker"
if __name__ == "__main__":
app.run(debug=True, host="0.0.0.0", port=9000)
| [
"srt181@example.com"
] | srt181@example.com |
1ad40da9f025f979beaadbf21c9fdb2e06ead2ac | 03c1325893b502b7855f83287e02e7f14af4f1c7 | /projects/py/chapter14/amazon-dynamodb-part-iv.py | 33eb30bdf82b22ac3da8f477fa5ad77771e646da | [] | no_license | elgeish/Computing-with-Data | 8562a15a74df6f379296b84e393a358eebf3d3fc | 5547dc28c027e023783238be78eab216ec5204f4 | refs/heads/master | 2023-07-29T06:00:26.625191 | 2023-07-16T00:32:38 | 2023-07-16T00:32:38 | 145,339,359 | 15 | 24 | null | 2023-07-16T00:32:40 | 2018-08-19T21:38:09 | Java | UTF-8 | Python | false | false | 558 | py | from pprint import pprint
import boto3
from boto3.dynamodb.conditions import Key
dynamodb = boto3.resource('dynamodb')
response = dynamodb.Table('reminder').query(
KeyConditionExpression=Key('timestamp').eq(1511647270)
)
pprint(response['Items'])
## [{u'text': u'batch write example',
## u'timestamp': Decimal('15... | [
"elgeish@gmail.com"
] | elgeish@gmail.com |
60521fbf55813b5e5554d270c2914a972760e620 | 75c3ce2153613a0ff754f51062beec325aa2bb26 | /xiaoEdaifa/trade/migrations/0004_auto_20190622_2200.py | e390f179f767c9839223e532be6374fe8b090dc2 | [] | no_license | chan3256995/vueproject | a3c600ea2880b694a53b6f346bcb840581a7d1fc | 681d5a943f8699750ced49b40097bb7f24c810aa | refs/heads/master | 2023-02-21T04:21:01.964410 | 2023-02-10T11:14:13 | 2023-02-10T11:14:13 | 198,947,244 | 0 | 0 | null | 2022-12-11T20:30:08 | 2019-07-26T04:39:25 | JavaScript | UTF-8 | Python | false | false | 410 | py | # Generated by Django 2.2.1 on 2019-06-22 14:00
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('trade', '0003_auto_20190622_1042'),
]
operations = [
migrations.AlterField(
model_name='refundapply',
name='add_time... | [
"801314902qq.com"
] | 801314902qq.com |
467121700a3bbae0045b9fa5e7aba2e67e68fe10 | ddab9365317ea104f1a20ebdc35a62e47b12c659 | /tests/test_aragon_d5_gas_analytics.py | dfd50ca9742b12b13bc70040de3ec61bc1c0262b | [] | no_license | d5-ai/aragon_d5_gas_anayltics | 5606957b331efb319455a2985b7e568558f0045a | 59e1db395d551b9d5371cc8ab937b4a6b4c508a9 | refs/heads/master | 2022-12-26T00:58:42.749449 | 2020-10-14T12:26:55 | 2020-10-14T12:26:55 | 303,974,397 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 104 | py | from aragon_d5_gas_analytics import __version__
def test_version():
assert __version__ == '0.1.0'
| [
"araa@connect.ust.hk"
] | araa@connect.ust.hk |
a78e3bfd191120d9e43f6a701cd5118e8c862b15 | c9b41d89848a5e4019b033f7f0585c5eb02c89cc | /variables/amihud.py | 51e21b6f459bfb28c702f0f13fbdf2be5eabaf3a | [] | no_license | gaitkin/insider-predictions | 956a587d6d30df1a795964947521c943ae6c305a | 46e2711fb8b1cafd6865bba8852ca3bfca3060bb | refs/heads/main | 2023-05-26T19:01:07.318354 | 2021-06-07T13:34:22 | 2021-06-07T13:34:22 | 372,782,189 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,463 | py | #!/usr/bin/env python
# coding: utf-8
#Import libraries used
import pandas as pd
import numpy as np
import math
from datetime import datetime, timedelta
#Import closing/daily returns data CSV as dataframe
df_closing = pd.read_csv ("closingdata.csv")
df_daily_returns = pd.read_csv ("dailyreturns.csv")
#Select relev... | [
"noreply@github.com"
] | noreply@github.com |
166c22366b18b72c0e2b554c1b08c41c2df395ea | 3f1c663a877a0947dfb3fde38bb0d0082ecd26b1 | /pdml2arff.py | 69d64f3f75b336428cbeb37c27690df246b6166f | [] | no_license | KyungRul/Graduation-Thesis | 0e9495272d92f19409f989a1bcc1d576ab15c4b0 | 76272955b9d790d804b127d1ba14aa5d379b9bdf | refs/heads/master | 2020-07-28T15:23:36.404490 | 2020-04-30T07:20:30 | 2020-04-30T07:20:30 | 209,450,617 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 10,100 | py | #!/usr/bin/python
# change the path (above) to reflect where you have python installed
#
# this script will take a tshark generated pdml file and turn it
# into an arff formatted file, suitable for ingestment by weka
# here's how to create the pdml file from pcap:
# tshark -T pdml -r <infile> > <outfile>
# (adding -V g... | [
"kyungrulbae@gmail.com"
] | kyungrulbae@gmail.com |
b4d713dbbbe9bdb10d591bc40c6f752200008f97 | a12d2d99d6bbb00bf4dabcab8c3efe5ea4714648 | /DistractedDriverMaskHandsAndFace.py | cb255bd777238c310b8c3e0f2709123ec5589192 | [] | no_license | devyhia/slim-backup | 01a702f65d4d5a2994cd2fac1ee225646e819fd9 | 26471cf66cf8e8ceff136a692ae6ba36fea90952 | refs/heads/master | 2021-01-12T00:14:25.456094 | 2017-10-17T09:54:35 | 2017-10-17T09:54:35 | 78,696,206 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,502 | py | import pickle
from glob import glob
import numpy as np
from PIL import Image
import Shared
from tqdm import tqdm
import os
with open('/home/devyhia/LendingAHand/result.pickle') as f:
hands = pickle.load(f)
with open('/home/devyhia/FaceDetection_CNN/result.pickle') as f:
faces = pickle.load(f)
def mask_image... | [
"devyhia@aucegypt.edu"
] | devyhia@aucegypt.edu |
ad796b01f49b7944d7c81a65fdb929ca1235c040 | 64ec8731553aa08c33373b212bbe431b1a23b97c | /test/util/util_spatial.py | 74e2b2692deec5adc94efe1ca8e6186db7ba6e48 | [
"BSD-3-Clause",
"MIT"
] | permissive | ChetanNathwani/pyrolite | 98947fde265b25beea839f24495d68bbdb726eed | 8de9c67855305115517418e127bf26de84ff062d | refs/heads/master | 2023-07-26T18:57:28.024540 | 2021-07-08T09:19:02 | 2021-07-08T09:19:02 | 367,300,779 | 0 | 0 | NOASSERTION | 2021-05-14T09:23:47 | 2021-05-14T08:35:50 | null | UTF-8 | Python | false | false | 7,785 | py | import unittest
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
try:
import cartopy.crs as ccrs
HAVE_CARTOPY = True
except ImportError:
HAVE_CARTOPY = False
from pyrolite.util.spatial import *
from pyrolite.util.math import isclose # nan-equalling isclose
class TestGreatCircleDis... | [
"morgan.j.williams@hotmail.com"
] | morgan.j.williams@hotmail.com |
7f1f96006e29e9599c5b43b0d55227bd8c5c2601 | 7150cc28822dd224c68356a3e820cd4c5b63e877 | /Leetcode_easy/191. Number of 1 Bits/191_Number of 1 Bits.py | 5bad0096ed6ea6575b6a34b69a87f00aebaa6bb9 | [] | no_license | duxun93/LeetCodeProject | 7db0dfa629dc0b287b783437da76698719b84581 | d089a9ce2d7dd4cebb966e52283b21b4d81253d6 | refs/heads/master | 2020-04-08T04:48:33.851157 | 2019-01-04T12:55:39 | 2019-01-04T12:55:39 | 159,033,093 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 290 | py | #https://leetcode.com/problems/number-of-1-bits/
#python 字符串是个神器,都变成字符串迭代就ok。
def hammingWeight(n):
s = str(n)
j = 0
for i in s :
if i == '1' :
j = j + 1
return j
print(hammingWeight(11111111111111111111111111111101)) | [
"1850175167@qq.com"
] | 1850175167@qq.com |
fb96fd228b595751b23398728c4cc3dcae170fee | 0d8c030beb0cf8d6ebc8b67f86619400f9a8300c | /unpacking_function_argument.py | 418457e19ff951995b7d6862f51b1d27da9e752a | [] | no_license | czach81/python_exercises | b50dd5c55883d2d1d2488340e866fd24ddcebb27 | d8b4a267502310019a4d4d669c02d7e38c8c5de2 | refs/heads/master | 2020-09-15T13:09:29.340334 | 2019-11-26T21:37:25 | 2019-11-26T21:37:25 | 223,454,889 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,570 | py | # you have a function that needs to take in a collection of data (elements unknown)
# one element or many elements
def greeting(*args): # unpacking start with a star(astrix) then name argument list args --unpacked
print('Hi ' + ' '.join(args)) # concatenate the arguments .join then pass in args... | [
"christopherpzach@gmail.com"
] | christopherpzach@gmail.com |
fe9b3528b6a13ece78a8b5bb615828732c4ea9f4 | 0df9864d526e1878a80e61cb03419e0d4361456c | /dodo-flask/app.py | 31250efed87ce2fad63c7ee3e89a2ce272ee6f56 | [] | no_license | Yuhemei/dodo | e7ba586717d5c8778e7242abe25f7a87776bc5bb | 87306e23160a72cb84c87c886c05e163a03bd28c | refs/heads/master | 2023-06-18T02:36:51.753534 | 2020-11-29T12:50:42 | 2020-11-29T12:50:42 | 291,392,200 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 497 | py | from flask import Flask
from flask_cors import CORS
import config
from model import Category
app = Flask(__name__)
CORS(app)
app.config['SECRET_KEY'] = config.flask_secret_key
from views.auth import *
from views.category import *
from views.errors import *
from views.posts import *
from views.upload import *
from ... | [
"yuyongjin@csii.com.cn"
] | yuyongjin@csii.com.cn |
b92defed3b5e8993f941de86c1d080d39aa48810 | c73beb04d101ca8d98c9126b1c47b4f19cc35066 | /week1/calculator.py | f7f372af8b41c269b4a182934923f6716834ac12 | [] | no_license | fywest/python | a5ecf62e1f8cdf59c936da81b478c371f169aec4 | cd97438679d8e129b3cb75d76226b16e7e7850ac | refs/heads/master | 2022-12-13T06:15:04.021492 | 2019-05-28T19:21:18 | 2019-05-28T19:21:18 | 130,403,136 | 0 | 0 | null | 2022-12-08T05:08:55 | 2018-04-20T19:02:57 | Python | UTF-8 | Python | false | false | 929 | py | import sys
if __name__=='__main__':
if len(sys.argv)<2:
print("please input salary amount")
exit(1)
print(sys.argv[1])
try:
amount=int(sys.argv[1])
tax=0.0
amount_fortax=0.0
amount_fortax=amount-0-3500
if amount_fortax<=0:
tax=0;
e... | [
"fywest2109@hotmail.com"
] | fywest2109@hotmail.com |
f1fa874c7bec4593ab87f840c26270883a4e970a | ee170fc4a6fe7180608c0182cbe7e1119fb1cf91 | /src/main/python/merge.py | 8611ff09c8fb1417b820292715286efb6ba9d4e5 | [] | no_license | rimamittal/petFinder | 7085b10e13b85ecd9af45562b263f9dfb9d6c1ae | 384000756b7597ab597fcc447321980a65e40615 | refs/heads/master | 2020-05-04T18:42:47.651880 | 2019-04-03T20:20:01 | 2019-04-03T20:20:01 | 179,363,911 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,470 | py | import pandas as pd
def merge(df, text_df, image_df):
completeData = pd.merge(df, text_df, left_on='PetID', right_on='petid', how='left')
completeData = pd.merge(completeData, image_df, left_on='PetID', right_on='petid', how='left')
completeData.drop(columns=['petid_x', 'petid_y'], inplace=True)
compl... | [
"Rima@NextrowLaptop-Rima.local"
] | Rima@NextrowLaptop-Rima.local |
9ad30ee9734df856d50edf0d943d9924d00ca67a | 1c8bcd2d8e129a92e3328f47d2a452814c033327 | /kaggle/otto-group-product-classification-challenge/script_30.py | 2250ea4fb9cf07c4c72a3fb83dcb6c31ab8ca81f | [
"MIT"
] | permissive | josepablocam/janus-public | 425334706f9a4519534779b7f089262cf5cf0dee | 4713092b27d02386bdb408213d8edc0dc5859eec | refs/heads/main | 2023-03-08T15:21:12.461762 | 2021-02-25T20:53:02 | 2021-02-25T20:53:02 | 314,606,918 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,253 | py | import numpy as np # linear algebra
import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)
from sklearn.model_selection import train_test_split
from sklearn.feature_extraction.text import TfidfTransformer
import lightgbm as lgb
pd.set_option('display.max_columns', 100)
pd.set_option('display.max_rows',... | [
"jcamsan@mit.edu"
] | jcamsan@mit.edu |
50286763bdd321a0902f41cc5fa33b8f3e85b1bd | bcd22d1bb172982b513b5ff0463bd56d920321ef | /project/routes.py | 582f8ad4166148827f02ff04ec70d75e1f367605 | [
"MIT"
] | permissive | wanh23/bulletin-webvr | 49743e92de839a6a51e9c7671dba84c16c97af9d | 5f42b4af996d5d22f306d6a2be410b03b0cdaf9d | refs/heads/master | 2020-08-28T17:14:38.573921 | 2019-10-26T19:38:00 | 2019-10-26T19:38:00 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,755 | py | from flask import jsonify, request, render_template, url_for, flash, redirect
import numpy as np
from project import application, db
from project.db_models import Message
from profanity import profanity
from fuzzywuzzy import fuzz
from fuzzywuzzy import process
import json
from sqlalchemy import asc
MAX_MESSAGES = 5
... | [
"mykytasolonko@gmail.com"
] | mykytasolonko@gmail.com |
e0b2abc6fdc9f4a635de40691e9ad06c3da0a16b | 1525501b7361e36ec126d3c74707705442240cc3 | /main.py | 2d0237e955e154f97a8de4e8d28c28ade3150784 | [] | no_license | aclaughan/create_device_banners | ceccd118767541e3f40c2a1eb34a68e83887ace9 | 150072d13ea07623e0c13a84f802eab9836863d2 | refs/heads/master | 2023-04-09T15:39:46.490140 | 2021-04-25T11:13:24 | 2021-04-25T11:13:24 | 361,405,937 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,993 | py | import logging
logging.basicConfig(level=logging.INFO, filename="app.log")
def create_device_banners(hostname: str, model: str) -> str:
"""
Just give this function a hostname and model type and it will
creates standard exec and login banners for a cisco device.
you can vary the segment sizes, by adj... | [
"git@claughan.com"
] | git@claughan.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.