blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 2 616 | content_id stringlengths 40 40 | detected_licenses listlengths 0 69 | license_type stringclasses 2
values | repo_name stringlengths 5 118 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 63 | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 2.91k 686M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 23
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 220
values | src_encoding stringclasses 30
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 2 10.3M | extension stringclasses 257
values | content stringlengths 2 10.3M | authors listlengths 1 1 | author_id stringlengths 0 212 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
d706cbc2c581af29582c417ee42d30c6d487eef0 | ad715f9713dc5c6c570a5ac51a18b11932edf548 | /tensorflow/lite/testing/op_tests/scatter_nd.py | 8a365ae5b96365937c5c2c28468aa81e1870ed84 | [
"LicenseRef-scancode-generic-cla",
"Apache-2.0",
"BSD-2-Clause"
] | permissive | rockzhuang/tensorflow | f1f31bc8edfa402b748c500efb97473c001bac95 | cb40c060b36c6a75edfefbc4e5fc7ee720273e13 | refs/heads/master | 2022-11-08T20:41:36.735747 | 2022-10-21T01:45:52 | 2022-10-21T01:45:52 | 161,580,587 | 27 | 11 | Apache-2.0 | 2019-01-23T11:00:44 | 2018-12-13T03:47:28 | C++ | UTF-8 | Python | false | false | 2,856 | py | # Copyright 2019 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... | [
"gardener@tensorflow.org"
] | gardener@tensorflow.org |
b347b4988d4ba504e2cb28606864befe47bcb34d | 7ba6fc111bdbce41a640e17c3ed1d0b2cbd0f433 | /app/views/main.py | c430018c84a6375912a86244b89a9444558ad344 | [] | no_license | arush15june/circl-cve | 9a2a1680bdf353241afdf278a690a89c9cbec06b | 49b354d0a0a0d4d259f7458ea7c0e56e48301552 | refs/heads/master | 2020-07-28T19:12:22.189142 | 2019-08-07T11:50:21 | 2019-08-07T11:50:21 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,556 | py | # -*- coding: utf-8 -*-
import syslog
from flask import Blueprint, render_template, flash, redirect, url_for, request, jsonify, escape
from flask_login import login_required, current_user
from sqlalchemy import desc
import os
import form_class
import models
from utils import admin_required, gpg
main_blueprint = Blue... | [
"swapnilansh182@gmail.com"
] | swapnilansh182@gmail.com |
ee1b7226a561379a914fa3fd752b3bd10cec0b11 | 4b5ef8e75387ffdc2e3e310938aa1ccad5fb3a45 | /drop_and_grab_algorithm.py | 759b12c43e99e2fe571faf383ef7ee68155a14f3 | [] | no_license | JeDeveloper/qscout | baa35c884a69880ffbcea93a14d22e382f4c6bc7 | 93fa90d82eec22fde09940dccfd2a1ab93b7f825 | refs/heads/master | 2023-02-21T18:34:51.542873 | 2021-01-11T21:34:41 | 2021-01-11T21:34:41 | 320,684,236 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 20,693 | py | from qgis.core import (QgsProcessingParameterFile)
from qgis import processing
from .qscout_pin_algorithm import *
from .pin_dropper_algorithm import *
from .grid_aggregator_algorithm import *
from .value_grabber_algorithm import QScoutValueGrabberAlgorithm, band_field
class DropAndGrabAlgoithm(QgsProcessingAlgorithm... | [
"joshuaevanslowell@gmail.com"
] | joshuaevanslowell@gmail.com |
36f0c2503555c6c05554aba80e07ccabf726f6b2 | 7337c58669cba9e87adeb195a7bfe689eb75ff58 | /src/edinet/app/eagle/migrations/0001_initial.py | 4db83e60a3d07f24a6e1a2767ae8ab1f7ca2d554 | [
"Apache-2.0"
] | permissive | ryuichi1208/air-pipeline | 71d6542f6cced966d5877f1f56baa42639b4f4c2 | c98382ea95cbef6a7dc529281a474ee33bede7cb | refs/heads/master | 2023-05-28T15:00:35.312378 | 2022-11-16T17:00:21 | 2022-11-16T17:00:21 | 229,581,131 | 0 | 0 | Apache-2.0 | 2023-05-08T20:29:24 | 2019-12-22T14:33:50 | Python | UTF-8 | Python | false | false | 5,017 | py | # Generated by Django 2.2.2 on 2019-07-03 04:01
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Company',
fields=[
... | [
"ryucrosskey@gmail.com"
] | ryucrosskey@gmail.com |
56e863d35664bee987c60e191072ea3ecebfd4c6 | 0ab0403303090c3ebaa6b55635c1247576eb1dbb | /models/quantize_affine.py | 8fea43ff96fb14aaacb4c3cf72634ca5ae07aaf4 | [] | no_license | silvrwolfboy/learning-compressible-subspaces | c8bc0d89c45f8894a318b2a74601a819deeb84a4 | 308f5216c7b0c15a0ebc88c7cec3e7d28c82b6c1 | refs/heads/master | 2023-08-28T06:32:33.669751 | 2021-10-27T16:22:28 | 2021-10-27T16:22:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 14,297 | py | #
# For licensing see accompanying LICENSE file.
# Copyright (C) 2021 Apple Inc. All Rights Reserved.
#
import collections
import numbers
from typing import Any
from typing import Optional
import numpy as np
import torch
from torch import autograd
from torch import nn
from .special_tensors import RepresentibleByQuant... | [
"mchorton@apple.com"
] | mchorton@apple.com |
6c708d71414961bfd27dd63946aaa70d181350d5 | 6dc463ce97fc275787cfdef563317f3f7e4f5fcf | /radio_table_widget_app/widgets.py | 557a613116b686330885748746143cf0bdc904d1 | [] | no_license | chapkovski/table_radio_widget | 7ea7506d801213cb24a832096fbf88ab7eb89c92 | 320a2b2f5462c6abe8bd0a355b1b4ac8defe3adf | refs/heads/master | 2020-03-22T09:29:23.298900 | 2018-07-06T17:24:23 | 2018-07-06T17:24:23 | 139,840,943 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 647 | py | from django.forms import RadioSelect
class TableRadio(RadioSelect):
template_name = 'widgets/multiple_input.html'
option_template_name = 'widgets/input_option.html'
def __init__(self, top_row=None, bottom_row=None, attrs=None, choices=(), ):
self.top_row = top_row
self.bottom_row = bottom... | [
"chapkovski@gmail.com"
] | chapkovski@gmail.com |
4afd37c750cfc496c579ea48617490c7e9cfc5cf | 4f428027c235d4567d436efae6861200d8ae661c | /easypadel/templatetags/mathtools.py | 39d19eb72dabf777fe2cc6b47ad0676bdc21c50f | [] | no_license | jorgeron/mytfg | 058008225f73cfb72c4af307162f7d14e913e2f1 | 879571674d7845c46520a554ac27efe2f10fbedc | refs/heads/master | 2021-01-20T14:54:18.755250 | 2017-06-01T14:21:39 | 2017-06-01T14:21:39 | 82,786,071 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 157 | py | from django import template
register = template.Library()
@register.simple_tag()
def porcentaje(parte, total, *args, **kwargs):
return (parte*100)/total | [
"jorgeron1993@hotmail.com"
] | jorgeron1993@hotmail.com |
e3bf9ce6464b09b76421075ddc04b704216d9611 | 2625c81908b8ba4f9acd7287f19aa43897a01490 | /1. MNIST and softmax/1.MNIST_softmax.py | 3873f53606711e1f5c00128a4bde4ab1d42c5a78 | [] | no_license | George-wu509/Deep-learning-team-tutorial | 534c0a5662303e758351e768255a00b311bedd00 | b44a66301dd218e8743c4389c167304e4a75132a | refs/heads/master | 2020-12-24T21:45:13.265592 | 2016-05-05T03:18:34 | 2016-05-05T03:18:34 | 57,171,565 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,732 | py |
# ------ This is Deep learning team tutorial example1: MNIST and softmax regression -----
# Download MNIST data from server using input_data.py
# You can use the following link to get input_data.py code:
# https://github.com/tensorflow/tensorflow/blob/r0.8/tensorflow/examples/tutorials/mnist/input_data.py
# Use inp... | [
"wu509@purdue.edu"
] | wu509@purdue.edu |
29a18faaa50dc981225e58ae908f3d2125f8b8f8 | 0e65bf60d9ffc64bbb8e300b90fa87b27316eb9b | /app/view/dialog.py | 9697a0346dae4342898309a67634342b626f254a | [] | no_license | artu-hnrq/Ine5420 | ee2996f7c096982f375b658beb90bab7aa3bc786 | b32c8841dcfc02be4c2c7517a7f810899ae11a85 | refs/heads/master | 2022-09-07T20:30:34.349925 | 2020-03-09T02:52:41 | 2020-03-09T02:52:41 | 202,533,109 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 298 | py | from app.view import UserInterface
class Dialog(UserInterface):
def __init__(self, title, text):
super().__init__()
self.window.set_title(title)
self.builder.get_object("text").set_text(text)
self.builder.get_object("ok_button").connect("clicked", self.quit)
| [
"Arthur.Henrique.Della.Fraga@gmail.com"
] | Arthur.Henrique.Della.Fraga@gmail.com |
8e22d1ea23f7ca524327b2070d521659d9c3922e | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /3gziWsCxqGwGGZmr5_11.py | 6392e84ea4d1c88aaa1154379e9f4d945b640bab | [] | 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 | 763 | py | """
Given two integers as arguments, create a function that finds the largest
prime within the range of the two integers.
### Examples
fat_prime(2, 10) ➞ 7
# range [2, 3, 4, 5, 6, 7, 8, 9, 10] and the largest prime is 7.
fat_prime(10, 2) ➞ 7
# [10, 9, 8, 7, 6, 5, 4, 3, 2] and the largest prime... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
218480d8de1b32721fa9093e05f3940ed09e8600 | bf9a1254cfb4af85c62b86eba21b9ad0495dd0a7 | /cal_SaD_SaM/read_NA_NV.py | c9706b0f494f82fa33e5bd5eabe03dece36611ba | [] | no_license | garyhsieh15/cal_eq_force | 2554aa51f475298241434bc9225cc9e41e26c2cf | 4f12fde4c6903484f98f999248f1e1ad83e83d0e | refs/heads/master | 2021-08-10T12:35:37.594490 | 2017-11-12T15:05:15 | 2017-11-12T15:05:15 | 110,441,743 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,196 | py | #!/usr/bin/env python3
import sys
''' ----------------------------------------------------------------------------
1. 輸入斷層的位置以及距離即可以得到NA and NV
2. NA and NV包含了, dNA, dNV, mNA and mNV.
3. 程式的想法是用if來先行判斷距離的多少, 再用斷層區域來做進一步的判定其因子為多少.
---------------------------------------------------------------------------- '''
print("... | [
"garyhsieh15@yahoo.com"
] | garyhsieh15@yahoo.com |
c94f3a57cfa500b7fe0a09ea6af43fa08b118a3b | ba11824525c7e41da98f343517e3c47f98bc81cf | /SpectralClusteringAndKMeans.py | 89979be1f7d7655fbbf9563ae4bb8a7032db4491 | [] | no_license | mani447/PCAImplementation_Kmeans_SpectralClustering | 4320fe56377a09f521b3fd3f78f3453a5e51bf9a | 580fec27bfb19def7149f232984488ca103cd484 | refs/heads/main | 2023-07-17T06:44:56.113871 | 2021-09-01T16:52:29 | 2021-09-01T16:52:29 | 402,136,454 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,223 | py | import numpy as np
from numpy import matlib
import pandas as pd
import math
from sklearn.cluster import KMeans
from matplotlib import pyplot as plt
import cv2
def LP_Matrix_Evaluate(similarity_matrix):
diagonal_matrix = np.zeros(similarity_matrix.shape)
sum_vec = np.sum(similarity_matrix, axis=1)
np.fill_... | [
"manideepreddy580@gmail.com"
] | manideepreddy580@gmail.com |
2a87843282159e9c6443e44c4633d6c6cd1d6e17 | e192f4a4a829d6f58daf04782de0ba7ba87958d3 | /pytorch implementation/pytorch/data.py | 4a7e822b28708546ca34d88af53fe4c8c8d613cf | [] | no_license | Carachias/DGCNN_VoxML_Classifier | 40d4bd4d5b70ae022d0678e90bb355cd17149d63 | 24d79174942c1158fd3a3554081b92e2e185cd95 | refs/heads/master | 2023-04-16T18:48:45.081413 | 2021-05-07T13:42:17 | 2021-05-07T13:42:17 | 361,211,004 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,004 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
@Author: Yue Wang
@Contact: yuewangx@mit.edu
@File: data.py
@Time: 2018/10/13 6:21 PM
"""
import os
import sys
import glob
import h5py
import numpy as np
import torch
from torch.utils.data import Dataset
def download():
BASE_DIR = os.path.dirname(os.path.abspath... | [
"carachias@gmail.com"
] | carachias@gmail.com |
20a405147dc239db1af8b180b78f4310c43f38b0 | ae66ad38a7b19c01f1099d671dd127716a5d4c34 | /accounts/migrations/0025_auto_20180511_1233.py | e1d9e06c37affbd3e572a0f042dd681de84ec054 | [] | no_license | selbieh/django-freelacer-website | 6fd1eb009e9b30738bfa59fa78f530144b273231 | 0971a7fc3dc7e63a1909bb6adf3a84d7d9083324 | refs/heads/master | 2022-11-22T19:07:48.470928 | 2019-11-24T12:24:26 | 2019-11-24T12:24:26 | 172,359,908 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 579 | py | # Generated by Django 2.0.4 on 2018-05-11 10:33
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('accounts', '0024_auto_20180511_1229'),
]
operations = [
migrations.AlterField(
model_name='userprofile',
name='pic',... | [
"selbieh@gmail.com"
] | selbieh@gmail.com |
02572ac0d7a899647d2e88f1a95a0f55337c7e01 | fc1c1e88a191b47f745625688d33555901fd8e9a | /meraki/models/protocol_4_enum.py | a5a84ca844f12ecbee618d6942e1886545423e86 | [
"MIT",
"Python-2.0"
] | permissive | RaulCatalano/meraki-python-sdk | 9161673cfd715d147e0a6ddb556d9c9913e06580 | 9894089eb013318243ae48869cc5130eb37f80c0 | refs/heads/master | 2022-04-02T08:36:03.907147 | 2020-02-03T19:24:04 | 2020-02-03T19:24:04 | 416,889,849 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 556 | py | # -*- coding: utf-8 -*-
"""
meraki
This file was automatically generated for meraki by APIMATIC v2.0 ( https://apimatic.io ).
"""
class Protocol4Enum(object):
"""Implementation of the 'Protocol4' enum.
The protocol of the incoming packet. Can be one of "ANY", "TCP" or "UDP".
Defaul... | [
"api-pm@meraki.com"
] | api-pm@meraki.com |
dbe6152c90a1d121fb9efa404084e4479ccfa844 | d245d44d742aee4a08c45263eda6ec42bb552dbd | /prac_1/sales_bonus.py | 65643e63980b21058ced7d680f128bb1c4b20996 | [] | no_license | mpearce19/CP1404practicals | d3b6afeddabd7193ed08ce17d40460aee8173126 | 270aed43ba7a8051cab83b13ba7b888ba222fbaa | refs/heads/master | 2023-01-05T11:41:28.147753 | 2020-11-05T00:58:14 | 2020-11-05T00:58:14 | 289,182,956 | 0 | 0 | null | 2020-09-09T01:07:47 | 2020-08-21T05:11:57 | Python | UTF-8 | Python | false | false | 403 | py | # 1.
"""
Program to calculate and display a user's bonus based on sales.
If sales are under $1,000, the user gets a 10% bonus.
If sales are $1,000 or over, the bonus is 15%.
"""
sales = float(input("Enter sales: $"))
while sales >= 0:
if sales < 1000:
bonus = sales * 0.10
else:
bonus = sales * ... | [
"mitchell.pearce@my.jcu.edu.au"
] | mitchell.pearce@my.jcu.edu.au |
6bb617f65ce38c6264839410620930fdf5f56e11 | 677734a1b188fc28d2af7848cd17923cd5a45871 | /PopulateCredential.py | f16b1da8f2f654883c331c204d8a97ffebe17b93 | [] | no_license | cyrexin/simplechatroom | dae66c3547dbef1cac2a12cd0eb219db2430d72c | 59797624df8ec780dbb3fa5e98aea05cdacc5736 | refs/heads/master | 2020-12-01T13:05:12.418441 | 2016-03-23T00:10:22 | 2016-03-23T00:10:22 | 54,007,192 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 558 | py | from Encrypt import *
user_password = {
'columbia': '116bway',
'seas': 'winterisover',
'csee4119': 'lotsofassignments',
'foobar': 'passpass',
'windows': 'withglass',
'google': 'partofalphabet',
'facebook': 'wastetime',
'wikipedia': 'donation',
'network': 'seemsez'
}
f = open('user_... | [
"cyrexin@gmail.com"
] | cyrexin@gmail.com |
41520052906753d133afd2569d27beb0bd764902 | f2dc83ffed7f5f8fffc83ef66b78d0b64274f803 | /main_codes/main.py | fde287072ff2e8e239fa1c5b990bfb575ac42055 | [] | no_license | TarunGandotra/flask_ui | 42805a29f3b5b34e200311a9e76a30ce4f135dff | 22bb891f470409878a1b5a408f3741caef8bf418 | refs/heads/main | 2023-01-18T20:29:25.208084 | 2020-11-20T13:53:01 | 2020-11-20T13:53:01 | 314,558,144 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 33,224 | py | # -*- coding: utf-8 -*-
"""
Created on Fri May 17 14:49:58 2019
@author: Digiscape
# """
from fund_ref import fund
#from afn003 import AFN003
from Article_History import article_history
from BRX012 import Brx012
from rule_109 import Rule_109
from Che015 import CHE015_11
from rule_17 import Rule_17
from RU... | [
"noreply@github.com"
] | TarunGandotra.noreply@github.com |
5c8dd67ca45da6502659d71d6cc1ed997f15c654 | 81672127c3d85d90ad724788a8bfb83ba3a92bfc | /problem/lintcode/lint1216.py | 2f56fbf57f4701f337064f99329257f7fcbb47cd | [] | no_license | qdian88/pylearn | 01f8ac8db554740a7f119d5df116c8816bd094ef | 47abd49462c58765b5029699f5675f635353dc1d | refs/heads/master | 2020-05-29T21:00:05.141278 | 2019-05-30T07:27:44 | 2019-05-30T07:27:44 | 188,647,604 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 284 | py | # -*- coding: utf-8 -*-
"""
Created on Wed Apr 24 11:04:43 2019
@author: Administrator
"""
m=10**3
s_max=0
for i in range(m-1,m//10,-1):
for j in range(m-1,i-1,-1):
s=i*j
if str(s)==str(s)[::-1] and s > s_max:
s_max=s
print(s)
print(s_max) | [
"19463739@qq.com"
] | 19463739@qq.com |
651b60b515fe7843967505febf81ecf3864711a5 | a7f39db24ce26ab0f02650ffd97007222aa536c5 | /so.guishiwen.org_shiwen.py | 1c43a5299d50000c95b371c9ff9420f1d01ebc75 | [] | no_license | hpifu/py-ancient | 6f51067c4c6ef1adb8241994e03dccb29e35b501 | a845e86057432a39f8239263aa7bf0e97c3f4c76 | refs/heads/master | 2022-12-13T00:40:09.735917 | 2019-10-27T05:21:52 | 2019-10-27T05:21:52 | 204,660,319 | 0 | 0 | null | 2022-07-06T20:16:22 | 2019-08-27T08:48:26 | Python | UTF-8 | Python | false | false | 1,333 | py | #!/usr/bin/env python3
import requests
from pyquery import PyQuery as pq
www = "https://so.gushiwen.org/shiwen"
def getPage(url):
res = requests.get(
url,
headers={
"accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-ex... | [
"hatlonely@gmail.com"
] | hatlonely@gmail.com |
72886476b0c8673d4ab8017cbda9bd78e3b3caf1 | cf0eb4dd2929cf6cde79b5357ff3d793a51425ce | /src/mongowave/configuration.py | 6006c444fa7862fad3c17a4231a4ea1dd5b03c72 | [] | no_license | igor-petruk/mongo-wave | 5911182942dbe8870c5bd02f81deaa9837ca4f43 | 5a63a1f303c7a31c17d4d5a5d4f5fe644ac6a7fc | refs/heads/master | 2016-09-06T14:24:03.083573 | 2012-12-13T23:59:37 | 2012-12-13T23:59:37 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,264 | py | from configparser import *
import os
import json
import uuid
class ConfigLocation:
@staticmethod
def CONFIG_FILE():
return os.path.expanduser("~/.mongowave")
class ClientConnection:
def __init__(self):
self.id = uuid.uuid4()
self.name=""
self.host="localhost"
self.p... | [
"igor.petrouk@gmail.com"
] | igor.petrouk@gmail.com |
b0005938274e2ee8f47d15f16514ef24a1c06540 | eeb04894d014a7bdd5501b4901e5d9818a29bd89 | /ex63.py | dead2d0dd94ebd07dbc94cc8a45553f97b113d7e | [
"MIT"
] | permissive | amarelopiupiu/python-exercicios | c9952828154abc42befffbea1b4a5a25e4c7ca62 | 4c1c535bf09854c7ce43405a4b55a2302c0edcda | refs/heads/main | 2023-05-25T08:11:34.294453 | 2021-06-09T20:32:35 | 2021-06-09T20:32:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 339 | py | # Desenvolva um programa que leia o primeiro termo e a razão de uma PA. No final, mostre os 10 primeiros termos dessa progressão.
pt = int(input('Diga qual é o primeiro termo: '))
razão = int(input('Diga a razão: '))
décimo = pt + (10 - 1) * razão
for a in range(pt, razão + décimo, razão):
print(a, end=' ')
print(... | [
"femahi2020@gmail.com"
] | femahi2020@gmail.com |
dc0a16d8c69607e0d52b47fbd9e0231d4266ac7f | 30ea7b9b9a88d542e9ea3c5b8def38e1b1d778e5 | /hw2/semantic_segmentation/dataset.py | 84f026529c7fbe3a2e50bf399cf78f0a53b05a9b | [] | no_license | kai860115/DLCV2020-FALL | 96ee63cc73969f4efe872870a0e6f8b0dfff08fd | cd07b9ac131b3bc5c22f92d57c80960dfc071ea3 | refs/heads/main | 2023-02-26T00:19:59.325488 | 2021-02-04T05:38:36 | 2021-02-04T05:38:36 | 335,480,530 | 5 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,944 | py | import re
import glob
import os
import random
import torch
from torch.utils.data import Dataset
import torchvision.transforms as transforms
import torchvision.transforms.functional as TF
from PIL import Image
def mask_target(im):
im = transforms.ToTensor()(im)
im = 4 * im[0] + 2 * im[1] + 1 * im[2]
target ... | [
"kai860115@gmail.com"
] | kai860115@gmail.com |
f2141c2a5ca33051d3a1f0f6e37b4171bbbfe7e4 | 8d19a7ce4deaa5f59acb8048e886ba7f05d87180 | /plotting/swa.py | 6451e09d0b9cbea33b85a7da12614eb00140cb38 | [
"MIT"
] | permissive | dejac001/MCFlow | bbc66529716e92de8b9507cc74b3de37da3d7143 | 19d1ee21318b49102842d75493a2fb830ec116f0 | refs/heads/master | 2022-12-17T15:08:46.648626 | 2020-07-26T18:24:53 | 2020-07-26T18:24:53 | 202,601,205 | 1 | 1 | MIT | 2022-12-08T10:45:35 | 2019-08-15T19:39:25 | Python | UTF-8 | Python | false | false | 2,637 | py | def make_grace(my_ax):
my_ax.tick_params(axis='y',direction='in',which='both',labelsize=10,left=True,right=True)
for dirn in ['top','bottom','left','right']:
my_ax.spines[dirn].set_color('black')
my_ax.spines[dirn].set_linewidth(1)
my_ax.tick_params(colors='black',size=5.,width=1.)
def plo... | [
"dejac001@umn.edu"
] | dejac001@umn.edu |
c5f63fefce90ea7f2fb12d5a4269401e45a5c574 | 2af3c577ec934c0d36ba40fbb55d1b67a99069fb | /account/migrations/0001_initial.py | f1344a6eb4f2fba47558b0d637c0a0762408b2f2 | [] | no_license | sathish-ku-mar/fynd-assignment | a3b7e16863d3db48a484aa0afde57c2d7d250899 | 93dc963d9ec441fd8a892e0d22be3af7df4aa960 | refs/heads/master | 2022-12-01T21:05:52.190085 | 2020-08-16T04:41:41 | 2020-08-16T04:41:41 | 287,740,164 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,497 | py | # Generated by Django 3.1 on 2020-08-15 11:31
import django.core.validators
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='User',
fields=[
... | [
"sathishkumar1954@gmail.com"
] | sathishkumar1954@gmail.com |
11022183e4676e6e9f90235da6453034baea344b | 319ee59669806935266cadd5c97bb30fca906412 | /actualapp.py | 34254941b75429343706ae35e5eab7174def3b9d | [
"MIT"
] | permissive | zenador/sporebusbot | 0cd505d03db975fca53dbe0c9759d34d66cc50b0 | 2ccc214cd8da4f8d3931db7cabfc4fb8e5183a78 | refs/heads/master | 2021-01-01T03:44:53.483042 | 2020-12-23T18:57:28 | 2020-12-23T18:57:28 | 59,570,064 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 297 | py | #!/usr/bin/env python
from flask import Flask#, send_from_directory
app = Flask(__name__)
app.config.from_pyfile('flaskapp.cfg')
@app.route('/')
def index():
return '.'
'''
@app.route('/ATriggerVerify.txt')
def show_atrigger_verify():
return send_from_directory("", 'ATriggerVerify.txt')
'''
| [
"zenador9@gmail.com"
] | zenador9@gmail.com |
90a66989e2c6b11e2cbe3b5a40014ec1d1beba97 | 36aea5790cc01c652326f6f5a5722f13ee9d498b | /m-hackathon/review10.py | e2ac404b28fb62f31280b7fb25534873fad595d3 | [] | no_license | kev158/NguyenTrongDuc-c4t | 2d9162a69dfa87e8ee24b93e4a72dc8811031cff | e1fba30f06c77bb7ab3271475d7ba6da9771ae09 | refs/heads/master | 2020-04-18T22:04:00.041524 | 2019-04-20T14:59:10 | 2019-04-20T14:59:10 | 167,783,372 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 179 | py | dangnhap = input("tên đăng nhập:")
matkhau = input("Nhập mật khẩu:")
e = input("Nhập email:")
print(dangnhap)
print(matkhau)
print(e)
print("đăng ký thành công") | [
"trongduc811@gmail.com"
] | trongduc811@gmail.com |
90176d92ce58020a5923f9b84ebb560a8b0c83db | 3d9a2964d25cf7f3bdd03be8019e176d743e793b | /cyberAttackSimulation.py | 471c87fd70869587dd090430e7fc0573d7efb8e2 | [] | no_license | connoryin/cyber-attack-simulation | cd68e1d47be22adab7673541d795d4c44f783ad1 | 36df25102ebef807fb492c174063decc4b7b9a00 | refs/heads/master | 2020-12-22T02:57:21.518303 | 2020-02-17T22:38:10 | 2020-02-17T22:38:10 | 236,650,194 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 17,869 | py | from graph_tool.all import *
from numpy.random import *
import numpy as np
from random import sample, gauss
import matplotlib.pyplot as plt
from matplotlib.figure import Figure
from matplotlib.backends.backend_gtk3cairo import FigureCanvasGTK3Cairo as FigureCanvas
import sys, os, os.path
import time, math
import statsm... | [
"connor@sjtu.edu.cn"
] | connor@sjtu.edu.cn |
e5a7b23422f40b51cdbaf54d658a81c03f5c2e6a | 5d21443ec6f858f6d5e5d260a670c94a2bc176e7 | /spider_jiandan2.py | 1c6c56a96049301dda4fa304fee23a332061ef14 | [
"MIT"
] | permissive | Sablier/SpiderBoy | 0f7a16571ea2148508eabfe3b074ec4e63b58f3c | 53b007d0b1b6e2375e5ee71d4b4e5e7deeeacafc | refs/heads/master | 2020-05-07T18:23:43.717739 | 2019-06-12T17:09:48 | 2019-06-12T17:09:48 | 180,764,734 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,588 | py | """使用面向对象思想编程。使用selenium包获取html内容,使用lxml解析网页"""
import os
import requests
from lxml import etree
from selenium import webdriver
class GetJandan(object):
def __init__(self,path,page=10):
self.start_url = 'http://jandan.net/ooxx'
self.url = ""
self.save_path = path
self.page = page
... | [
"albertpeng1991@gmail.com"
] | albertpeng1991@gmail.com |
ba5f4cd07918520b871fedc8ce034363db2a0906 | 5ca893fc4b0f65774260fd8909b12706bcf1a9fa | /tests/test_is_pangram.py | 11f0a6064dcfbf21cf6c3cbecf0859e4bd203e95 | [
"MIT"
] | permissive | daveoncode/python-string-utils | 27fe323292860e78bac954177c2556aa8f3f25b5 | 78929d88d90b1f90cb4837528ed955166bf0f559 | refs/heads/master | 2022-12-11T20:14:30.087257 | 2020-03-31T11:23:35 | 2020-03-31T11:23:35 | 39,955,389 | 55 | 12 | MIT | 2022-12-08T03:44:22 | 2015-07-30T14:39:06 | Python | UTF-8 | Python | false | false | 900 | py | from unittest import TestCase
from string_utils import is_pangram
class IsPangramTestCase(TestCase):
def test_non_string_objects_return_false(self):
# noinspection PyTypeChecker
self.assertFalse(is_pangram(1))
# noinspection PyTypeChecker
self.assertFalse(is_pangram(['xx']))
... | [
"davidezanotti@gmail.com"
] | davidezanotti@gmail.com |
148c8cc9b4af58e8cbf0df51d9ddf6cd1016874d | abda045e5516fb64f6e52031aced1da8e18e5bf7 | /tests/test_tokens.py | 7a801230e6afd238ef17921bc3cd9e9223ab3003 | [] | no_license | omar212/pascal.py | a99d92fdc7a23ca8cad4ddbd7df8f473523c6c3e | d51745bb85198c99a918e68289703a822648d3ad | refs/heads/master | 2020-05-26T05:51:37.827324 | 2014-06-19T06:51:39 | 2014-06-19T06:51:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,587 | py | import unittest
from modules.token_creator import TokenCreator
from modules.pascal_token import Token
class TestTokenAttributes(unittest.TestCase):
"""test that attribute methods return correct boolean values"""
def setUp(self):
self.tokenCreator = TokenCreator()
# paramters to creat... | [
"brianwu02@gmail.com"
] | brianwu02@gmail.com |
db32253902147d6de63a312faa4dc7a41e150337 | c016088a3bdb255d4f5253185d27b5a4c75feb1b | /11_testing_your_code/11_3/employee.py | 919260baf759a0a8360fcd951f4ce7399a8e2888 | [
"MIT"
] | permissive | simonhoch/python_basics | b0b7c37ff647b653bb4c16a116e5521fc6b438b6 | 4ecf12c074e641e3cdeb0a6690846eb9133f96af | refs/heads/master | 2021-04-03T10:11:10.660454 | 2018-03-13T20:04:46 | 2018-03-13T20:26:25 | 125,107,388 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 628 | py | class Employee ():
"""Simple attempt to describe an employee"""
def __init__(self, first_name, last_name, annual_salary):
"""Initialization of the employee class"""
self.first_name = first_name.title()
self.last_name = last_name.title()
self.annual_salary = annual_salary
de... | [
"simonhoch1@gmail.com"
] | simonhoch1@gmail.com |
dd5173273d0d804b36621c3206594029a67b98df | 1d1e1ff4614e085ad5187fbc6aa68a003a5f1ac2 | /setup.py | 837db8adddf7a2f91b2082c288d1e68a96f52b8d | [
"MIT"
] | permissive | malisal/streampie | 9e83cf9ba51a7c241935d88f3821ed256de20133 | 7b1b24b01b234cd093a350f04ffaf1a4974282ad | refs/heads/master | 2021-01-10T07:51:44.333259 | 2016-04-20T17:11:07 | 2016-04-20T17:11:07 | 53,448,331 | 5 | 0 | null | null | null | null | UTF-8 | Python | false | false | 888 | py | from setuptools import setup
with open("requirements.txt") as f:
required = f.read().splitlines()
setup(
name = "streampie",
version = "0.2.4",
description = "A simple, parallel stream processing library",
author = "Luka Malisa",
author_email = "luka.malisha@gmail.com",
license = "MIT",
url = ... | [
"luka.malisha@gmail.com"
] | luka.malisha@gmail.com |
84c6464c17e376eb7e83ffc85264a665216ccf37 | c70457843b82b4ea0212feb81153be1b7cbe8240 | /lab_04/orderedset.py | fe251a155503050e7097144084a7941caccbc93b | [] | no_license | alexbardas/krr | 65b4443a784d952d0a07a0dbf7b801ef54b00bb8 | e88c40b61b9b09612f83e0cd1c488291cc0446f0 | refs/heads/master | 2016-09-01T21:07:27.774450 | 2013-01-15T23:47:01 | 2013-01-15T23:47:01 | 6,520,495 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,807 | py | import collections
KEY, PREV, NEXT = range(3)
class OrderedSet(collections.MutableSet):
def __init__(self, iterable=None):
self.end = end = []
end += [None, end, end] # sentinel node for doubly linked list
self.map = {} # key --> [key, prev, next]
if iter... | [
"alexbardas@gmail.com"
] | alexbardas@gmail.com |
278789d4b6a9951c0f6d6bf55614b7139a62b95b | 4e208d8d4f34c9f0f946d5c762dc7dc94a2593db | /apps/my_app/migrations/0001_initial.py | 47ea576627ec29e03f3dfd3eeeac42ff671a913b | [] | no_license | tarrdog/python_black_belt | 0231c71752c72c02729ad1e8627a99ce07e64c36 | fa53d48a0d42a26a5174c102c13ec33f83e79421 | refs/heads/master | 2020-12-03T00:43:00.206731 | 2017-07-03T04:05:08 | 2017-07-03T04:05:08 | 96,069,494 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,545 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.1 on 2017-07-03 00:07
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.Crea... | [
"tarrdog@gmail.com"
] | tarrdog@gmail.com |
627162d6e931f6e673884ff3d7894f226d49c18b | 613057da52adee14bd24c7570aa54291413f0792 | /身份证校验系统.py | f4bdfa40818d62aa7d5108cd30cf17b28e323754 | [] | no_license | han925981034/python | 565d3ee95bc73017e3658b4c8af5a455664c7e8b | 8b48b5f3481477252d66a917943f67599a8e6ea1 | refs/heads/master | 2020-08-16T14:54:17.745165 | 2019-10-16T11:26:26 | 2019-10-16T11:26:26 | 215,514,430 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,513 | py | from tkinter import *
import time,datetime
class IDCCheck():
def __init__(self):
self.win=Tk()
self.win.geometry('700x400')
self.win.title('身份验证系统')
self.win['bg'] = 'lightblue'
self.image = PhotoImage(file='11.png')
self.lable_image=Label(self.win,image=... | [
"noreply@github.com"
] | han925981034.noreply@github.com |
fc0ba945af6ee21809c0c81d4d2d1d2a8b103254 | 79a3cc6868730fd5fb748dfc2c4430e6ac52b26c | /Weblogic-Deployment/roles/Application-2/templates/start-managed-servers.py | c8b0cc2118d2516e2f2ab9e670ed6b611d2b87bd | [
"BSD-3-Clause"
] | permissive | rgaddam/Weblogic-Deployement-Using-Ansible | 6b431e9238f68ba82da5d03ac3f1460ac617c891 | 0e16d4dd4263da6fd604d231b190a5fd21bc36a1 | refs/heads/master | 2022-04-06T03:38:18.851761 | 2020-02-28T21:58:23 | 2020-02-28T21:58:23 | 70,837,199 | 2 | 3 | null | null | null | null | UTF-8 | Python | false | false | 492 | py | # Set AdminServer connection URL
ADMIN_SERVER_URL = 't3://' + '{{ admin_server_hostname }}' + ':' + '{{ admin_server_port }}';
# Connect to the AdminServer
connect('{{ weblogic_admin }}', '{{ weblogic_admin_pass }}', ADMIN_SERVER_URL);
# Start editing mode
edit();
startEdit();
# Start Managed Server-1
start('{{ man... | [
"noreply@github.com"
] | rgaddam.noreply@github.com |
de0872015a00bf7aa5c3e151ddeecb83fe00d452 | 86e25f7afc5e5ca1194512b79b1e581c1a682946 | /container.py | 18bb431ac148799c895e0f70580133153fa02f99 | [] | no_license | Vlad-Iliescu/kinetic-python | 85b7442326d4814175acdf333453c0f65d85ef61 | 4b8d1b0680e410d0533e76a6edcd3fd44934a25d | refs/heads/master | 2016-09-05T23:19:25.324952 | 2012-09-07T12:07:13 | 2012-09-07T12:07:13 | 32,134,186 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,854 | py | __author__ = 'Vlad'
from node import Node
from util.global_options import Kinetic, write_output
class Container(Node):
def __init__(self, var_name=None, **kwargs):
super(Container, self).__init__(**kwargs)
self._parse_container_config(kwargs)
self.name = var_name
self.c... | [
"Vlad.Iliescu.88@gmail.com@42f960a1-aad4-b08e-6b72-5efd33d37d32"
] | Vlad.Iliescu.88@gmail.com@42f960a1-aad4-b08e-6b72-5efd33d37d32 |
81ca8e11005c1feb11cd0cbc18f5ea33860d493a | 8e6d78920b4d5ed60616d69cfba1824afeff611b | /backend/backend/urls.py | c0a2bb028b4fe8a80c5860a450aa2c4cfc99f5f3 | [] | no_license | shiowwj/django-react | 1c711b9bc879f13e99d1e6bc2c1e56d85a12729b | b381d48e6574eb134b8b530a758b6f7ea0719914 | refs/heads/master | 2023-01-06T07:29:36.168514 | 2019-06-19T10:04:26 | 2019-06-19T10:04:26 | 192,477,199 | 0 | 0 | null | 2023-01-04T00:45:44 | 2019-06-18T06:14:31 | JavaScript | UTF-8 | Python | false | false | 1,406 | py | """backend URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/2.2/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: path('', views.home, name='home')
Class-based... | [
"shiowweijun@gmail.com"
] | shiowweijun@gmail.com |
01ed533f6c9a4859a87371bd27fea296ed647fc0 | e58b0929819446d737a3cf78ea39893036c7be38 | /subcmds/diff.py | 9045edc7e7a370bc23b714fbe73ff0900548f491 | [
"Apache-2.0"
] | permissive | bgabrhelik/git-repo | d732820854a7816860a5ccb968ecbfe08cf2b5d1 | c326834397ca0afe0b0a66728a18881005858f66 | refs/heads/master | 2020-12-26T00:07:57.899455 | 2015-03-26T17:00:40 | 2015-03-26T17:00:40 | 33,419,452 | 1 | 1 | null | 2015-04-04T20:34:41 | 2015-04-04T20:34:41 | null | UTF-8 | Python | false | false | 1,472 | py | #
# Copyright (C) 2008 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... | [
"matthias.putz@esrlabs.com"
] | matthias.putz@esrlabs.com |
3a19ba528e7e6cf2e1c340ffc2f61d93a9766961 | 306dc56bdbe12120541ec0ad80cf6e428ded2d0c | /LastQue!/connect5.py | 429c692dd7908cb47a186cbe5fe6768e615c2ecd | [] | no_license | DevTotti/Challenges | bf286b11a5405c0ae8853e00b6c4024149a77be8 | 448521de19d48ad7d061ae33c87838d661c67868 | refs/heads/master | 2020-06-21T00:37:15.330204 | 2019-07-17T02:39:14 | 2019-07-17T02:39:14 | 197,300,585 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,511 | py | """
Name: Osuntolu Paul
email: neptunecody@gmail.com
Intermediate test question 5 & 6
"""
import mechanicalsoup
import re
import json
import requests
from statistics import mean
import scipy
import scipy.stats as st
from scipy.spatial.distance import cdist
from scipy.interpolate import *
import numpy as np
s=reques... | [
"paul.bIncoM@gmail.com"
] | paul.bIncoM@gmail.com |
c08a06098466014eebcd6ca0f27fc1259e9c1c1a | 91d1a6968b90d9d461e9a2ece12b465486e3ccc2 | /directconnect_write_f/virtual-interface_delete.py | 80e3a4f24ad845af820b46f860e9d930d4b0b178 | [] | no_license | lxtxl/aws_cli | c31fc994c9a4296d6bac851e680d5adbf7e93481 | aaf35df1b7509abf5601d3f09ff1fece482facda | refs/heads/master | 2023-02-06T09:00:33.088379 | 2020-12-27T13:38:45 | 2020-12-27T13:38:45 | 318,686,394 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 694 | py | #!/usr/bin/python
# -*- codding: utf-8 -*-
import os
import sys
sys.path.append(os.path.dirname(os.path.abspath(os.path.dirname(__file__))))
from common.execute_command import write_parameter
# url : https://awscli.amazonaws.com/v2/documentation/api/latest/reference/ec2/describe-instances.html
if __name__ == '__main__... | [
"hcseo77@gmail.com"
] | hcseo77@gmail.com |
07493ee2b882c3363f6d52bd9562f1c312196c56 | 99493b50c8be7e88090c2c5d9a9070cf33f15f3a | /小姐姐带你学自动化测试/01python/02 条件语句.py | fa9110454d699d20c423f1dc3b9116ce5e7566ed | [] | no_license | Saber1342/python | 42d2585c4e39f5b1ddca781881e76733b7d21918 | d714e6c273009bf3b9a6013ae788d8145f083f1b | refs/heads/master | 2020-12-19T11:54:55.776850 | 2020-01-23T04:59:08 | 2020-01-23T04:59:08 | 235,724,690 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 367 | py | #该实例演示数字猜谜游戏
guess = 0
number = 5
print("猜数字游戏")
while guess != number:
guess = int(input("请输入你猜的数字:"))
if guess == number:
print("恭喜,你猜对了!")
elif guess < number:
print("在猜哦,猜的数字小了")
elif guess > number:
print("在猜哦,猜的数字大了") | [
"549755670@qq.com"
] | 549755670@qq.com |
6a72e0a4d419c5ee1caa5dbd06bbe9167e2bf1dd | 341662c6723e379d37eac840e3d58c2c2b8e303c | /solutions/euler6.py | 253ae8671bd2fd7116a37c0b7437bb32171d1b07 | [] | no_license | jimmyhmiller/project-euler | 571ae047b2ce66324bc407724cffefe788649c06 | 124b7b4aa3d022c3072a92f1cec76011ced866a5 | refs/heads/master | 2020-05-22T01:09:21.139071 | 2017-03-28T05:24:38 | 2017-03-28T05:24:38 | 15,573,029 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 217 | py | #!/usr/bin/env python
def main():
sum_of_squares = sum(x**2 for x in range(1,101))
square_of_sums = sum(range(1,101))**2
print abs(sum_of_squares - square_of_sums)
if __name__ == '__main__':
main() | [
"nomicness@gmail.com"
] | nomicness@gmail.com |
92d4201ea1b976e5fadadf15d8d197cdf4270b45 | 13c03c269c3ed7a82e7771c5eafcaf8d4d46fa46 | /weather_DL.py | c4670b23961f46ee4ad77d0c641f80340ebfb6ff | [] | no_license | ncsa/CPRHD_SES | 533d1f1177368ccbd67588d21913863cafd7442c | 3168044825d74f776b4828cc43936eacf6859f18 | refs/heads/master | 2021-06-28T15:43:33.373380 | 2020-12-18T20:38:44 | 2020-12-18T20:38:44 | 191,447,999 | 1 | 1 | null | 2019-10-16T19:58:27 | 2019-06-11T20:56:00 | Jupyter Notebook | UTF-8 | Python | false | false | 972 | py | import urllib.request
import json
from datetime import datetime
from datetime import date
def download_weather_climate_division(date_to_start: str):
base_url = "http://data.rcc-acis.org/GridData"
start_date = datetime.strptime(date_to_start, '%Y%m%d').strftime("%Y%m%d")
end_date = datetime.today().strftim... | [
"jallen17@illinois.edu"
] | jallen17@illinois.edu |
08fed6bd9d3495b53532ebd0d362e54a2feacc00 | 68d0775ff5ec73901838137725642f83252c6130 | /src/python_tools/Spacecraft.py | c53b7e49e61625bca9125d014a670e3be4bd9800 | [] | no_license | bryanwweber/AWP | 3506aefc655288a6ab35b0f7e88a2fc0360eb78d | 0a316fe82cd61751a0acf5e58c966f54367b6970 | refs/heads/main | 2023-06-09T09:50:02.970273 | 2021-07-03T01:27:56 | 2021-07-03T01:27:56 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,744 | py | '''
AWP | Astrodynamics with Python by Alfonso Gonzalez
https://github.com/alfonsogonzalez/AWP
https://www.youtube.com/c/AlfonsoGonzalezSpaceEngineering
Spacecraft class definition
'''
# Python standard libraries
import os
import math as m
# 3rd party libraries
import numpy as np
import matplotlib.pypl... | [
"alfonso8gonzalez@gmail.com"
] | alfonso8gonzalez@gmail.com |
d34d9478e0a08733cd8446aad7f2470cd93da574 | eb267b933b04739f05c9aff83698e70f1d5e3dce | /telegram.py | 0313ffc7a8f75e64754e0ac8bd785065e30e91e3 | [] | no_license | Tabaktom/StockTips | 3f9284910d9c0b5829aa91e93855d47ceb0f1ee3 | 95d4697eb05a55977bc4a69a69f6da8842daf3d7 | refs/heads/master | 2022-12-02T20:47:04.230078 | 2020-08-22T16:48:59 | 2020-08-22T16:48:59 | 289,527,391 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 471 | py |
def share_telegram(message):
import telepot
from secrets import telegram_chat_token
token = telegram_chat_token
botname = 'BOT_NAME'
TelegramBot = telepot.Bot(token)
#bot_id = TelegramBot.getMe()['id']
#print(bot_id)
bot_id='BOT_ID'
updates = TelegramBot.getUpdates()
send_id='C... | [
"noreply@github.com"
] | Tabaktom.noreply@github.com |
bb9ab0f73f6c25d085278975445f6e1ad3916472 | 6675cc79f2bad3cf8d4bbb4517c4660a14dcd425 | /Spotify/extractdata.py | 2c9c46d60ae38f4e6a01ee72b839fbe0123b7c9a | [] | no_license | minh-le1994/MinhLe | 8390a85c014421922cc0374475ce72a634e269a8 | b9392b1cffe41486a9f296d83f11123c5bded8cb | refs/heads/master | 2022-12-11T23:10:14.188875 | 2020-07-12T16:00:43 | 2020-07-12T16:00:43 | 250,595,997 | 0 | 0 | null | 2022-09-23T22:39:29 | 2020-03-27T17:11:56 | HTML | UTF-8 | Python | false | false | 3,290 | py | import requests
import pandas as pd
import json
from authorisation import SpotifyAuthorisation
class DataExtracter():
"""
Class to extract the data from the Spotify Web Api regarding the last 50 songs played and the audio features of this songs. The
class is initiated with the token needed to access ... | [
"khac.minh.le@outlook.de"
] | khac.minh.le@outlook.de |
5466f06013d91cbc89027ba74e9665d8a1e56a94 | 4726d52edb8a5f091d2bd52acec561d77fb5f73d | /backend/rest/invoiceDetails/migrations/0002_auto_20201117_1158.py | a18e699d67ce0291aeb9af72f0817e012437d818 | [] | no_license | ChristianTaborda/Hyperfoods | 5d34252c1c3f91a7d899cb842007427007d3ddc3 | 47ac16b6adca28f02ba0f227acae431daeda1304 | refs/heads/master | 2023-02-06T12:00:53.884171 | 2020-12-30T23:11:41 | 2020-12-30T23:11:41 | 325,666,350 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 826 | py | # Generated by Django 3.1 on 2020-11-17 16:58
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('combos', '0002_combo_imagecombo'),
('products', '0003_auto_20201116_2124'),
('invoiceDetails', '0001_initial')... | [
"christian.taborda@correounivalle.edu.co"
] | christian.taborda@correounivalle.edu.co |
4aa6bd7f048cdaa6fcb9c0294eb8ec82785ce637 | a3e1bf40dc7b24e559ab69fbb50fa9724b4c3e20 | /scorecenter/scorecenter/settings.py | 0ddcd1102022047bfb894c3b518de21b090cfc8f | [] | no_license | andresmacha/Quiniela | e260067f80db94f023168e6073d847b52c371afe | a5e947cca473b57ff757fc677995ab2b3f03f306 | refs/heads/master | 2016-09-05T14:38:44.542513 | 2013-02-12T14:58:51 | 2013-02-12T14:58:51 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,646 | py | # Django settings for scorecenter project.
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ADMINS = (
# ('Your Name', 'your_email@example.com'),
)
MANAGERS = ADMINS
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
'NAME': 'cham... | [
"andresalejandro13@hotmail.com"
] | andresalejandro13@hotmail.com |
6e2d152884470b76fab1e4f8be0c8476ae6e0fb1 | f29e8c30b9f7b66cb66bfb634608adec74a4aee0 | /012desafio - ler preco, retorna desconto.py | f26b56ea286e0bc9a308999fc0202fc8be53aad4 | [] | no_license | brunoparodi/Curso-GUANABARA | acafe1390ccd2ba5648ca30f73f54b95a6c57201 | 16b7a293a54f1a471fa07830bc66709a88fceb79 | refs/heads/master | 2020-04-24T09:16:12.095977 | 2019-02-21T11:17:01 | 2019-02-21T11:17:01 | 171,857,603 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 155 | py | preco = float(input('Informe o preço do produto: R$'))
desconto = preco * (5 / 100)
print('O preço com desconto é: R${:.2f}.'.format(preco - desconto))
| [
"bruno@parodi.com.br"
] | bruno@parodi.com.br |
de8a2eb24ef3c4273c3735cc6a55be8ff4758247 | 347ba5b3b5c171be17bc201d87d580b1b0a8e59c | /templates/test.py | fddb06cd2dcafdbe7f13ed21118d41b0d10c5567 | [] | no_license | hf618/Task2 | 589be10b66325ed538ed98542d618149682477f3 | e4597bc4ee4998cfa2e9abcf32c327dd8a75619a | refs/heads/master | 2023-09-01T22:27:41.845475 | 2021-10-08T17:00:12 | 2021-10-08T17:00:12 | 415,053,667 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 375 | py | from database import * # 自己写的数据库函数的包
import random
import copy
import numpy as np
a=['kim','hwang','lee','ye','wu']
#a = gain_namelist() # 名字列表
ori = a #原始数据
random.shuffle(a) # 随机排序后名字列表
print(a)
baocun = copy.deepcopy(a)
a.pop(1)
print(a)
print(baocun)
samples = random.sample(a, 3)
print(samples)
| [
"1208927463@qq.com"
] | 1208927463@qq.com |
faaabc87d530eda66341796909e94a28dc6d25c5 | b306aab9dcea2dd83dda700bc9f7b9f1a32cff3a | /CAIL2020/cocr/det_infer.py | a89f3a16932ef293bd9a8018db8f313597098ffd | [
"Apache-2.0"
] | permissive | Tulpen/CAIL | d6ca9981c7ea2603ae61675ba330a9614cd9398d | c4cfa98ab4ecedbce34a7a5a186830486047540c | refs/heads/master | 2023-04-23T20:07:56.774530 | 2021-04-16T13:18:36 | 2021-04-16T13:18:36 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,839 | py | import argparse
import os
import sys
import pathlib
import torch
from torch import nn
from torchvision import transforms
from torchocr.networks import build_model
from torchocr.datasets.det_modules import ResizeShortSize
from torchocr.postprocess import build_post_process
import cv2
from matplotlib import pyplot as pl... | [
"bangtech@sina.com"
] | bangtech@sina.com |
1508d1b59f6898158e81fe6c5d740f5229815180 | 242f7b0ffeec430d67b262b724165fad343fda68 | /combinatory_analysis/comb-rep.py | 361f318f4be39a2236f0b7c25a0966d40a8e629b | [] | no_license | lnbe10/Math-Thinking-for-Comp-Sci | ea12dc212ea654b11e5499b317db37b1287bdea4 | c12f3b84c6831ef5a6bb02c04390223f17167e14 | refs/heads/main | 2023-02-26T13:50:13.755274 | 2021-02-05T07:10:27 | 2021-02-05T07:10:27 | 332,588,364 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,395 | py |
from itertools import combinations_with_replacement
# Question 1
# Twenty people are voting for one of 5 candidates.
# They have secret ballot, each voter votes for one of 5 candidates.
# The result of an election is the number of votes for each of the candidate.
# How many possible results can this vote have (the r... | [
"luankevinfmb@hotmail.com"
] | luankevinfmb@hotmail.com |
4293b3acde9fd16c7d98f4e36d670978acca31a3 | f73f5f5d0770f731b5e76da39131ff36c9fde11e | /django_libs/tests/models_tests.py | 7c46c414daad0a285198d5f569b7e8cfa6ef2ad1 | [
"MIT"
] | permissive | SurferTank/django-libs | fcede8d7dff4ea58c728d05ff0030a3ce892a08e | 6ad3f7cf5f9a7a4848557d73af4a93054b34e27f | refs/heads/master | 2021-02-09T01:28:32.153104 | 2020-10-26T03:11:23 | 2020-10-26T03:11:23 | 244,222,230 | 0 | 0 | MIT | 2020-03-01T20:55:22 | 2020-03-01T20:55:21 | null | UTF-8 | Python | false | false | 519 | py | """Tests for the models of the ``django_libs`` app."""
from django.test import TestCase
from ..models import ColorField
from ..widgets import ColorPickerWidget
class ColorFieldTestCase(TestCase):
"""Tests for the ``ColorField`` model."""
longMessage = True
def test_functions(self):
color_field =... | [
"tobias.lorenz@bitmazk.com"
] | tobias.lorenz@bitmazk.com |
f3ffceb64896a81db9b59622fbfb0a1798476e5b | ccc412c09af06cd2f55c74702436378f97ef460f | /examples/Texas_mapping_objects.py | 87bbab0b721ce3ea7b135807a6dc0fe825de4dbf | [
"MIT"
] | permissive | rasquith/choroshape | bde5237418d3e43c4321906c99732a285dfd8394 | 0e88465173fed56f0edb31b73a0a1962f3180464 | refs/heads/master | 2020-07-07T23:35:43.863863 | 2018-09-25T01:14:11 | 2018-09-25T01:14:11 | 67,946,286 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,744 | py | '''This file has objects used for making maps of Texas. Objects here are
intended for maps of Texas made with specific style guidelines'''
import pandas as pd
Texas_city_label_dict = {'city_names': ['El Paso', 'Odessa', 'Amarillo',
'Lubbock', 'Fort Worth', 'Dallas',
... | [
"rachel.asquith@gmail.com"
] | rachel.asquith@gmail.com |
4467952bc3588edaf21b854d2cb536eb9a03be12 | 03034837c5f10d19fcc4dc51388f056ec43fd1d2 | /pro21.py | a5fa31a3792fe95d280dc9afd594c679ff30987a | [] | no_license | shaukhk01/project01 | e95c19844757c631f7ffbdd910b20316f49a945b | 79cfe784612fdbb4816c9fc3fc7222c845a3268f | refs/heads/master | 2020-06-26T07:20:49.844532 | 2019-08-20T06:06:40 | 2019-08-20T06:06:40 | 199,569,813 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 140 | py | import re
def main():
matched = re.finditer('a{2}','abcdeaakkkaa')
for m in matched:
print(m.start(),'--',m.group())
main()
| [
"shaukhk01@gmail.com"
] | shaukhk01@gmail.com |
574d7ca56487ba0eab4dd0ce88086455d0675b1a | bf330ac532c742b06393d170104da3995308dbf9 | /fitlife/migrations/0002_products.py | faf0eb847e3f6d99b7f253eaadf95ac35316ab75 | [] | no_license | kml95/DjangroProject | 375c3ce292e35817c3af566ffcfbf20831dc96c0 | a8f33bbab7e5ffd2a666118d1d5d32c0b0655aba | refs/heads/master | 2021-04-06T19:37:36.296828 | 2017-06-01T19:28:08 | 2017-06-01T19:28:08 | 125,425,390 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 650 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.1 on 2017-05-31 16:49
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('fitlife', '0001_initial'),
]
operations = [
migrations.CreateModel(
... | [
"adrian.kalinowski95@gmail.com"
] | adrian.kalinowski95@gmail.com |
a6a8f3e31af3d7f8c62c42ef83ed0d10121c2482 | 3a3b1b35bb1db050aecb7cfe1828516f1ce40aec | /assignment7/main.py | e34c5f1dd9bc150913bf150a9a62aee5f458acbd | [] | no_license | Shadesfear/SIP | 5249f51ec93dc92751944b3513e8214234f7af60 | e9081c6b87189bd16b074a161824b3743ca7b632 | refs/heads/master | 2021-01-06T16:23:15.379319 | 2020-03-23T22:53:52 | 2020-03-23T22:53:52 | 241,395,445 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 164 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Mon Mar 23 23:52:16 2020
"""
import exer1, exer2
if __name__ == "__main__":
exer1()
exer2() | [
"Blaedelblaedel@gmail.com"
] | Blaedelblaedel@gmail.com |
45a009dba2770c9039de56e2489370042d17c258 | 1ad42b8f706287b9c830590a7da8e83fbea57bb6 | /typeDensity.py | 5a7c17285f66e4cde588afe7ebfa9b7fa380bba8 | [] | no_license | ntBre/CNTResearch | 7e54d2dbc11bddd05cda6e998358c0dd9d74fb16 | 41a32423966cf09da5580339dfa933c45dc595bf | refs/heads/master | 2021-04-27T01:55:39.466045 | 2018-04-01T01:07:09 | 2018-04-01T01:07:09 | 122,684,605 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 3,858 | py | #Sectional distribution
def innertube(sections):
"""Takes the lampstrj file produced by the CHILL Algorithm and calculates the percent of each type of
water, printing these to files for each type of water for plotting"""
file_name = ""
tube_radius = 0
tube_length = 80
types = [[0] * sections for i in range(5)... | [
"bwestbro@stedwards.edu"
] | bwestbro@stedwards.edu |
d46615282317fbeef2fe89137c6aeb7e9cd8cbc0 | 3f99a5be32a57c59fbf3a0dfcc74594215fb3001 | /bi_account_invoice_layout/models/account_invoice_inherit.py | 45af6190f2ffd01511cba56dae3a6a9002c8e417 | [] | no_license | Brahim820/dulexlab | b8e6891df22a4acd3d52775e61b2e9ad122a583d | 7f8f7519acb08b0b2704aeac61878f2c459d53e1 | refs/heads/master | 2020-08-01T02:52:35.343291 | 2019-09-02T09:08:52 | 2019-09-02T09:08:52 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,487 | py | # -*- coding: utf-8 -*-
from odoo import fields, models, api, _
class AccountInvoiceLineInherit(models.Model):
_inherit = 'account.invoice.line'
public_price_lst = fields.Monetary(string='Public Price', compute='get_public_price_lst', store=True)
phd_disc = fields.Float(string='PHD %')
dd_disc = fie... | [
"mkhairy@iskydev.com"
] | mkhairy@iskydev.com |
6d858a6f7e8b2f12d4ec8b67ef93d19370d79f0f | 8398dcf8b46493c1487f23ba259d9140cc7fe556 | /visionMiniProject/kakao/face_input.py | d6bdb51f93c4d346f83121bf55e2472a8c479aa5 | [] | no_license | JU-RI/visionMiniProject | 8ac5dee87a48deafb80c0d66c9127d9368dcb4ad | b55e01a2512f976524e7d5b8c41327f234eb840f | refs/heads/master | 2020-05-23T23:59:08.187333 | 2019-05-18T07:50:05 | 2019-05-18T07:50:05 | 187,006,579 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,293 | py | import requests
import argparse
import sys
import math
import random
from collections import Counter
import searchdb
from PIL import Image, ImageTk
import tkinter as tk
from tkinter import filedialog
import tkinter.messagebox
photolabel, photolabel2, info_label = None, None, None
gender, age, corner = None, None, None... | [
"48680930+JU-RI@users.noreply.github.com"
] | 48680930+JU-RI@users.noreply.github.com |
41c56a7c5c0c9ce2bc578dda633139c181636491 | 3e21239d7b0537b038d32bda632a7137c3ce2fb0 | /coverage.py | 889b8210e523f1cdccb9a2008fea3e321059958d | [
"MIT"
] | permissive | rlopez93/seq-assembly-2 | 966cc2d80b7043fd5a76b43eff6424f5441b46c5 | d78a7ee8321dba8d025b5bf72b77454d1b6ffc36 | refs/heads/master | 2021-01-21T13:41:43.597041 | 2015-05-25T22:09:35 | 2015-05-25T22:09:35 | 35,104,802 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,780 | py | #! /usr/bin/env python2
from __future__ import print_function
import fileinput
"""
Usage: cat <map file> | python coverage.py
Note: this script assumes that all reads in
the map file are of the same gene
"""
# coverage[i] -> coverage for gene at position i
coverage = []
for line in fileinput.input():
fields... | [
"ricardolopez93@gmail.com"
] | ricardolopez93@gmail.com |
88e50a08bbca948a79e849d9561cf42f78aca8d4 | 34ffaabea6d4ca25edd893e0429d846fdea78856 | /effidavit/urls.py | e6f8a71f1af46b1cbb462abc376b8f98714285b4 | [] | no_license | bkanuka/efidavit | 730e80f48dd875a77e2ea4979f0d110248c2d519 | 0ec341452ce9486ee0582c6402ebdcc325800939 | refs/heads/master | 2020-03-28T18:41:51.068012 | 2014-09-21T02:17:42 | 2014-09-21T02:17:42 | 24,279,599 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 516 | py | from django.conf.urls import patterns, include, url
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'jumpingintodjango.views.home', name='home'),
# url(r'^blog/', include('blog.url... | [
"bkanuka@gmail.com"
] | bkanuka@gmail.com |
175b16aa461473aa8fbeb39f96459c4ddc826859 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02937/s405333986.py | 77f923e46db0a03de4ebb7d4023a7c9648601069 | [] | 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 | 694 | py | s=list(input())
t=list(input())
ns=len(s)
nt=len(t)
t_set=list(set(t))
s_set=list(set(s))
for i in range(len(t_set)):
if t_set[i] not in s_set:
print(-1)
exit()
from collections import defaultdict, deque
from bisect import bisect_right
ds=defaultdict(list)
for i in range(ns):
ds[s[i]].append(i)... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
ffa7a37033c9eee4858e1ff0293d62b027d27f1c | d3942686f0b3d5c3bb077607bdd04af082363520 | /{{cookiecutter.project_slug}}/tests/__init__.py | 79b42da3269c9b900df483f37457663f1a4bbba6 | [
"BSD-3-Clause",
"GPL-3.0-only",
"GPL-1.0-or-later",
"GPL-3.0-or-later",
"LGPL-2.0-or-later",
"LGPL-2.1-or-later",
"LicenseRef-scancode-free-unknown",
"MIT",
"ISC",
"Apache-2.0"
] | permissive | audreyfeldroy/cookiecutter-pypackage | aaa3a26c314e990f3a4867c0722fa9d06f72755c | a3bfdf11b42fcfa2d3c721270ae7a112be551eb5 | refs/heads/master | 2023-08-25T16:22:23.781780 | 2023-08-16T03:23:40 | 2023-08-16T03:23:40 | 11,407,567 | 1,427 | 661 | BSD-3-Clause | 2023-08-16T03:23:42 | 2013-07-14T18:52:05 | Python | UTF-8 | Python | false | false | 61 | py | """Unit test package for {{ cookiecutter.project_slug }}."""
| [
"eugene.kim@ntti3.com"
] | eugene.kim@ntti3.com |
66710b834ba910ae871e35434ff06cc236671078 | 88a6bee119310e508bd04e87532a363eaafabc38 | /mattermostgithub/payload.py | e99404fef011930a7b6da540bed9729136c80ea1 | [
"MIT"
] | permissive | Y-Ge/mattermost-github-integration | efcd0be77649d47c22ecc2390b9210da48dde673 | 1124a0ff233b50ed6070cb84cfffd128ad219831 | refs/heads/master | 2020-05-03T06:46:05.224619 | 2019-01-16T10:17:18 | 2019-01-16T10:17:18 | 178,481,570 | 0 | 0 | NOASSERTION | 2019-03-29T22:09:52 | 2019-03-29T22:09:52 | null | UTF-8 | Python | false | false | 9,155 | py | from io import BytesIO
import requests
try:
from PIL import Image
from mattermostgithub.config import SHOW_AVATARS
except ImportError:
SHOW_AVATARS = False
class Payload(object):
def __init__(self, data):
self.data = data
def user_link(self):
name = self.data['sender']['login']
... | [
"lukas.diekmann@gmail.com"
] | lukas.diekmann@gmail.com |
d91c472494a14944078b8c134a26b081bd7333e7 | 525c3a824a5bab4d72a355bfe9d504a170793cf6 | /AltScraper/AltScraper/pipelines.py | 8b422c45455b7e0db592e7b7c96c344800ee181e | [] | no_license | khuhroproeza/AltApi | b5dce386119d49b829c4ad19306692d2a32b6b7c | 0c869c34a084e95775e0694d627098552870bd59 | refs/heads/master | 2023-03-14T03:16:30.742540 | 2021-02-21T01:04:18 | 2021-02-21T01:04:18 | 340,785,831 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 364 | py | # Define your item pipelines here
#
# Don't forget to add your pipeline to the ITEM_PIPELINES setting
# See: https://docs.scrapy.org/en/latest/topics/item-pipeline.html
# useful for handling different item types with a single interface
from itemadapter import ItemAdapter
class AltscraperPipeline:
def process_it... | [
"s.khuhro@appose.com"
] | s.khuhro@appose.com |
997c692b5f8aa3a1df50e49dd5f625b4b2a76106 | 636a45b40f0a31a0f01487ebd0270a01c350a7e8 | /my_functions.py | 635661302dedc84d7478dc67c755a48733c0de5b | [] | no_license | Marley-C-Robinson-99/Windows-Test | 4afad46810f08c5b0bd0d0303310fb6eb02954f8 | 3fc1240126c07de01836032ab2e9241b6bbf25a8 | refs/heads/main | 2023-06-16T21:23:48.591193 | 2021-07-14T17:26:27 | 2021-07-14T17:26:27 | 380,139,065 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,198 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
def is_two(num):
return num == 2 or num == '2'
def is_vowel(strng):
return strng in ('aeiouAEIOU')
def is_consonant(l):
return is_vowel(l) == False
def cap(word):
if word[0] != ('aeiouAEIOU'):
return word.title() #Used ttitlecase to capitalize ... | [
"marleycrobinson99@gmail.com"
] | marleycrobinson99@gmail.com |
eea01f46700e145a52ea864f42942e182a2b4072 | 3eb781bc3669496b0de3dbe637f2ebcba5cb7fca | /blog/urls.py | 068f5a975335045a737555faa3e6e0165ae7acca | [] | no_license | kitano333/my-first-blog | 8f3508391e6d48a932fa2d5e9d1a20441dae5e15 | df94d9a1cabf0479b21f29b6bb7ad4fad60aab45 | refs/heads/master | 2020-08-02T21:41:16.166154 | 2019-10-10T16:14:04 | 2019-10-10T16:14:04 | 199,885,243 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 862 | py | from django.urls import path
from . import views
#これはDjangoの path 関数と、blog アプリの全ての ビュー(といっても、今は一つもありません。すぐに作りますけど!)をインポートするという意味です。
urlpatterns = [
path('', views.post_list, name='post_list'),
]
#見てのとおり、post_list という名前の ビュー をルートURLに割り当てています。 このURLパターンは空の文字列に一致し、Django URLリゾルバーはURLのフルパスの前半にくっつくドメイン名(つまり、http://127.... | [
"poao333@yahoo.co.jp"
] | poao333@yahoo.co.jp |
e50f135364772e42c6edaf110f4b2dd0b7d1d55c | 1fcbe1f4ec9f55b1c576e848e793228323ed2d61 | /order/migrations/0001_initial.py | 0e0281f1158c2d262d9b2bf6b5f4e14119c06c29 | [] | no_license | jzhang0228/coin_registeration | 48db7f697c0eedcaba6cbf2824f39334687a40d0 | fd6482c6390f6afac5b84a185f6fbb35a66e348e | refs/heads/master | 2021-01-10T09:30:57.131499 | 2016-04-19T06:37:43 | 2016-04-19T06:37:43 | 50,980,920 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,842 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.9 on 2016-02-03 07:06
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations =... | [
"jzhang0228@gmail.com"
] | jzhang0228@gmail.com |
3585d6a65316de2774692932e0998c9bca0ae3af | ac53ed07a534db727e57714f5fdd07950d22c170 | /Python学习/day04/匿名函数.py | b55019111525f8b8a8cb09de9d5e4c6a19f97327 | [
"MIT"
] | permissive | taoyan/python | b8847911068083481e34567716710abaf5bbe4be | 3fbb1e534ec91b33cd2ac690966d7253c2f5d757 | refs/heads/master | 2022-12-11T17:15:59.411554 | 2019-10-28T03:50:31 | 2019-10-28T03:50:31 | 147,048,609 | 1 | 0 | MIT | 2022-12-10T14:53:29 | 2018-09-02T02:39:40 | Python | UTF-8 | Python | false | false | 839 | py | #匿名函数
#lambda修饰
result = (lambda x,y:x+y)(1,2)
print(result)
#使用场景:简化代码
#匿名函数的调用
func = lambda x,y:x*y
result = func(1,2)
print(result)
#判断是否是偶数
def is_os(num):
if num % 2 == 0:
return True
else:
return False
print(is_os(1))
#使用匿名函数判断
new_func = lambda num:True if num % 2 == 0 else False
pri... | [
"1136523628@qq.com"
] | 1136523628@qq.com |
0fcbfd1b29cd78bfc26627d84f1dc484ef4cd791 | 1dbb922246b549d2721fb0bde46b49ee94d65789 | /tests/base.py | 5cbf76b6b7e17e1ed4243858d3e555b46362405d | [] | no_license | easyNav/easyNav-sensors-wifi | a9ae91cc5ab9ffb3113d081f8b43b9761942abe0 | 00acfd48473efb52b838379a25de516d52a222d4 | refs/heads/master | 2021-01-01T15:24:36.112766 | 2014-10-16T15:58:09 | 2014-10-16T15:58:09 | 25,121,604 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 360 | py | #!/usr/bin/python
# -*- coding: utf-8 -*-
# This file is part of easyNav-sensors-wifi.
# https://github.com/easyNav/easyNav-sensors-wifi
# Licensed under the MIT license:
# http://www.opensource.org/licenses/MIT-license
# Copyright (c) 2014 Joel Tong me@joeltong.org
from unittest import TestCase as PythonTestCase
c... | [
"me@joeltong.org"
] | me@joeltong.org |
9517457d7e8d2371a55f8d478f0d120d0d465c5c | c92035d0192a9cc65d0319c454beca8974808f42 | /app/map/urls.py | 6a59b642c1e4fc612b5998ecf62122d1d139ae33 | [] | no_license | ueue511/django-celery | 0fd710e1326e0ac636a843d742b961971724b562 | 3422ba995adcba5561f14350c7dc3fcd4d9a6e1c | refs/heads/master | 2023-07-04T08:39:28.993106 | 2021-08-12T11:56:57 | 2021-08-12T11:56:57 | 395,297,670 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 196 | py | from django.urls import path
from . import views
urlpatterns = [
path('map/', views.Make_Map.as_view(), name='make_map'),
path('make_map/', views.make_map_post, name='make_map_post'),
]
| [
"nexnex07@yahoo.co.jp"
] | nexnex07@yahoo.co.jp |
6ad2e977a128e69b0bb0e99f23b1c334efee2083 | a1107969d677024c15edd4808b7006f8421d64c2 | /venv/bin/pyqt5qmlscene | 4dfe09476a0e70d19b8e96594754030ba7e767d2 | [] | no_license | vlamik19/Server-Client-learn-socked | cafe6d6faff5b76b220b48a3d06bd24ee227c763 | 6bb1b31b3f85b1fbf29c7cb5438cbf449b2aaa93 | refs/heads/master | 2022-11-28T03:43:38.760346 | 2020-07-21T15:07:06 | 2020-07-21T15:07:06 | 278,643,809 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 279 | #!/home/vladmik19/PycharmProjects/server2/venv/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from pyqt5_tools.entrypoints import pyqt5qmlscene
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(pyqt5qmlscene())
| [
"madara020498@mail.ru"
] | madara020498@mail.ru | |
72873dffd27f14fc20be6c3a6a335451b79762f1 | 960cf810b9544128bc7eb32f25adafb7d668499e | /dd_using_vgg16.py | 5b1465fd407d653301d98efc80cdeb1aeb2cb39b | [] | no_license | janvi08/Distracted-driver-detection-system | 324c76296cdd584435144fe3a68afd23df3702c4 | 027a63b4d86efbd1efdf4b878b4f206694d1d9e3 | refs/heads/master | 2023-08-15T05:38:31.763741 | 2021-10-04T12:18:48 | 2021-10-04T12:18:48 | 413,400,961 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,398 | py | # -*- coding: utf-8 -*-
"""DD using VGG16.ipynb
Automatically generated by Colaboratory.
Original file is located at
https://colab.research.google.com/drive/1Elg597sYw5uSq8rGiDeoDOkORsZrbLVy
"""
from google.colab import drive
drive.mount('/content/gdrive')
import pandas as pd
df=pd.read_csv('gdrive/My Drive/i... | [
"janviphadtare9@gmail.com"
] | janviphadtare9@gmail.com |
9b1ea4f67a3f044fbccede3769ea8b82e6e0b05a | 5534b6f65381357d60c1c8277e27e99a98def5f8 | /2022/LeetCode/2022-11/prefix_sum.py | be837dc1b64a8e1f6cf68cd1b1216d623d82fbb5 | [] | no_license | ootz0rz/tinkering-and-hacking | 61bc326f87bca57b2c2bc660885a75b21a7b0f55 | 874ee305e53998a89ced77111aaae45b60b418e1 | refs/heads/master | 2023-01-28T05:27:02.812394 | 2023-01-24T20:05:02 | 2023-01-24T20:05:02 | 8,169,514 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,023 | py | from typing import List, Optional, Dict
# stupid...but works
import sys, os
SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__))
sys.path.append(os.path.dirname(SCRIPT_DIR))
from TestHarness import *
'''
Prefix sums allow us to find the sum of any subarray in O(1)O(1).
If we want the sum of the subarray from i ... | [
"ootz0rz@gmail.com"
] | ootz0rz@gmail.com |
2f7161e1462efe4a1f7d4281499acae7de884531 | b7e9c505f3634f1ab0a28d4468fd7adb1d6cbf92 | /simple_linear_regression.py | 5a19f7618038446a71e18bd10034f3bc7fa36577 | [] | no_license | devarajnadiger/LinearRegression | a9cac70f606c27adc4e5a4f4a5baef1b8b6fd340 | b9a6c033e84b2ac4435f5e861db6b0f57f26a7b6 | refs/heads/master | 2020-04-23T06:49:31.640253 | 2019-02-23T04:52:05 | 2019-02-23T04:52:05 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,618 | py | '''
----------------------------------------------------------------------------------
simple linear regression python code without using pandas and scikit library
with only one feature that is x
output is y
hypothesis function(predicted/model function) is h
parameters/coefficients theta0 and theta1
------------... | [
"noreply@github.com"
] | devarajnadiger.noreply@github.com |
4ad57e5623a534930577b2344a2f132f793c8bb5 | 7dc295d045982180f89e2bca204148c715dcdd8c | /using_context/using_redirection.py | b3b04bf12790a109758b99bd39c6bd769572946a | [] | no_license | onionmccabbage/AdvancedPythonMay2021 | 0c582e2502672c5d0974a46da1f689ac44c41728 | 5194fb191f8d01521d54d6867084ae6845a3726c | refs/heads/main | 2023-04-20T07:32:29.119310 | 2021-05-13T14:53:01 | 2021-05-13T14:53:01 | 366,090,231 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,117 | py | # we can write a class to redirect the context (simple solution)
import sys # sys is in control of inputs and outputs
class Redirect:
'''
Provide an easy way to redirect the standard output
(which defaults to printing to the console)
'''
def __init__(self, new_stdout):
self.new_std... | [
"noreply@github.com"
] | onionmccabbage.noreply@github.com |
ba5bf4df83c1a5e401c6ac4d470108fae419940f | 25bb4e760769cc483a20f27b6312698891dce034 | /python/Closures and Decorators/decorators-2-name-directory-English.py | 529c7f5310dd4be88cfeca5669d97fbd3c92bd2b | [] | no_license | rangaeeeee/codes-hackerrank | e13d22adff1ef74974e34251d9bfac6cfd36f2b0 | ce7fdf7f336c10164fd2f779d4ed3713849d7c2b | refs/heads/master | 2021-01-19T17:07:28.451983 | 2017-09-01T18:05:33 | 2017-09-01T18:05:33 | 101,049,197 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 190 | py | from operator import itemgetter
def person_lister(f):
def inner(people):
people=sorted(people,key=lambda x: int(x[2]))
return [f(p) for p in people]
return inner | [
"rrangarajan.85@gmail.com"
] | rrangarajan.85@gmail.com |
014b7ef0141fa10bec4ed60ff73f77ca036a6182 | b354c139723db370b69083071a7799052408fc24 | /lab4/mlutils.py | 45db00d5d60efdd882ef5d571fafa434b465448c | [] | no_license | kristijanbartol/Machine-Learning | b985ac070f0da7323931597c9bec8fc4d549cfb6 | da4df84b969900de7439a373e1962882cd9b44bf | refs/heads/master | 2021-09-23T20:22:04.572582 | 2018-09-27T11:52:07 | 2018-09-27T11:52:07 | 108,148,447 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,994 | py | import numpy as np
import matplotlib.pyplot as plt
from sklearn.model_selection import train_test_split
from sklearn.datasets import make_classification
from sklearn.neighbors import KNeighborsClassifier
def plot_2d_clf_problem(X, y, h=None):
'''
Plots a two-dimensional labeled dataset (X,y) and, if function ... | [
"kristijan.bartol@gmail.com"
] | kristijan.bartol@gmail.com |
90a27c3b480f0cc80ed8ee801bdadd35c64a12c3 | 1a356165035504853ea8c6b721c547d2cea0c18d | /Player/greatest.py | c3d077633cbd75d104f4ac68e6d4f83944d47d7c | [] | no_license | Anjali1409/Python-Programming | 93f128c7b724486505a47e55bc71bdd9872b4a3e | 7af4bb946f17cb7f0ef1bb1c21fc149dc3af8285 | refs/heads/master | 2021-04-28T04:05:36.276091 | 2018-06-10T09:46:20 | 2018-06-10T09:46:20 | 122,153,429 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 117 | py | i=int(input())
j=int(input())
k=int(input())
if(i>j and i>k):
print(i)
elif(j>i and j>k):
print(j)
else:
print(k)
| [
"noreply@github.com"
] | Anjali1409.noreply@github.com |
7a65e54865e002c36b16fb0dc338699d283732c9 | 80b489a53f7f211a09920affa5998a0724d83e71 | /webapp/venv/lib/python2.7/site-packages/alembic/ddl/mysql.py | 96f42f382d97e602f22fcb1113185859ced6fda1 | [
"MIT"
] | permissive | mustafatasdemir/apkinspector | d9ec9d85da5e0014edaf0d98119561bf3f87dffc | 1bd0d044b7daef4efda21c985393f8d73722a074 | refs/heads/master | 2016-09-06T03:25:49.212735 | 2014-12-12T03:52:56 | 2014-12-12T03:52:56 | 24,392,752 | 3 | 0 | null | 2014-10-28T03:57:43 | 2014-09-23T23:10:55 | Java | UTF-8 | Python | false | false | 8,123 | py | from sqlalchemy.ext.compiler import compiles
from sqlalchemy import types as sqltypes
from sqlalchemy import schema
from ..compat import string_types
from .. import util
from .impl import DefaultImpl
from .base import ColumnNullable, ColumnName, ColumnDefault, \
ColumnType, AlterColumn, format_column_name,... | [
"mustafa.tasdemir@hotmail.com.tr"
] | mustafa.tasdemir@hotmail.com.tr |
b6a695509f4c932fce5594d2924313a6581f08bd | 8afb5afd38548c631f6f9536846039ef6cb297b9 | /_ORGS/NPM/node/deps/v8/tools/release/test_scripts.py | 7cf5d141301c575c3186e2488597b510374b586d | [
"MIT",
"LicenseRef-scancode-unknown-license-reference",
"BSD-3-Clause",
"SunPro"
] | permissive | bgoonz/UsefulResourceRepo2.0 | d87588ffd668bb498f7787b896cc7b20d83ce0ad | 2cb4b45dd14a230aa0e800042e893f8dfb23beda | refs/heads/master | 2023-03-17T01:22:05.254751 | 2022-08-11T03:18:22 | 2022-08-11T03:18:22 | 382,628,698 | 10 | 12 | MIT | 2022-10-10T14:13:54 | 2021-07-03T13:58:52 | null | UTF-8 | Python | false | false | 34,860 | py | #!/usr/bin/env python
# Copyright 2013 the V8 project authors. 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... | [
"bryan.guner@gmail.com"
] | bryan.guner@gmail.com |
97b645a76edb21baf3e7d7f565b58fdb42d9e961 | 48cbfd4c3634a45da8cd4616013d775ff00a39e5 | /20201001_1/task1.py | f27c17eeda5565a43f27ef096abd00126d5520e9 | [] | no_license | hakenlaken/pythonprac | c3393f0eb1d8a569c6ee853cf6da9fe959bbedf8 | 2b5fe81b728ac10e3fd25b7223f9df25b0155752 | refs/heads/master | 2023-06-05T22:32:36.248486 | 2021-06-25T08:16:10 | 2021-06-25T08:16:10 | 297,048,545 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 400 | py | # Задача_1: написать функцию вычитания двух объектов
def fun(a, b):
if type(a) is str:
res = ""
for d in [c for c in a if c not in b]:
res += d
return res
elif hasattr(a, "__sub__"):
return a - b
else:
return type(a)(c for c in a if c not in b)
inp = eva... | [
"lav@MacBook-LAV.local"
] | lav@MacBook-LAV.local |
26b18e37eff8d9418bc37752e4f8fe2f947df0b1 | 07ec5a0b3ba5e70a9e0fb65172ea6b13ef4115b8 | /lib/python3.6/site-packages/tensorflow/contrib/predictor/contrib_estimator_predictor.py | afeb0cc8d0fc8739a534d1ebdf77758c20ae8948 | [] | no_license | cronos91/ML-exercise | 39c5cd7f94bb90c57450f9a85d40c2f014900ea4 | 3b7afeeb6a7c87384049a9b87cac1fe4c294e415 | refs/heads/master | 2021-05-09T22:02:55.131977 | 2017-12-14T13:50:44 | 2017-12-14T13:50:44 | 118,736,043 | 0 | 0 | null | 2018-01-24T08:30:23 | 2018-01-24T08:30:22 | null | UTF-8 | Python | false | false | 129 | py | version https://git-lfs.github.com/spec/v1
oid sha256:f616a461aa1df558fae47ff2bc5c7d16ceb00620172d2724deccf893b3da6f46
size 3152
| [
"seokinj@jangseog-in-ui-MacBook-Pro.local"
] | seokinj@jangseog-in-ui-MacBook-Pro.local |
ca1b7ba1ced0801086175a3a04c5cadc63f7bb52 | c190336a28dc3a2a20e0448551ffcb3a24ebd08b | /app1.py | fb7ba06b7592d75084c4b15736d944ecdc8a5a84 | [] | no_license | ThomsonRen/flying-dog-beers | bf3af72f7e70f09b23a73ccb7fc18e6eb5048621 | dce2d96fb9fe8ffe8aec319fb8a37a146fb86685 | refs/heads/master | 2021-05-18T16:05:26.204152 | 2020-04-17T12:18:36 | 2020-04-17T12:18:36 | 251,309,362 | 0 | 0 | null | 2020-03-30T13:14:11 | 2020-03-30T13:14:11 | null | UTF-8 | Python | false | false | 2,620 | py | # -*- coding: utf-8 -*-
import dash
import dash_core_components as dcc
import dash_html_components as html
from dash.dependencies import Input, Output
import pandas as pd
import plotly.express as px
# df = px.data.gapminder()
external_stylesheets = ['https://codepen.io/chriddyp/pen/bWLwgP.css']
# df = df[df['cont... | [
"rentongxin@sjtu.edu.cn"
] | rentongxin@sjtu.edu.cn |
b327b6904a68a6fac9133923566f52491e3e7255 | 96db160b6075e49101686eb4947fefb2e0909985 | /Store/views.py | 3cba59847230429be847c64618fcdb291698a251 | [] | no_license | hdforoozan/Restaurant | 7c43b1c89e8edc504a27dac2515313b979069c88 | d9420dc5dcd42bcb6c5952474ef996845ec4381c | refs/heads/master | 2022-12-09T13:38:57.970747 | 2019-09-29T20:45:10 | 2019-09-29T20:45:10 | 208,814,583 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,784 | py | from datetime import datetime
from django.shortcuts import render
from .models import Store, Employee, Manager
from Food.models import Food
from django.urls import reverse_lazy
from django.views.generic import TemplateView,DetailView,ListView, CreateView,DeleteView,UpdateView
from django.contrib.auth.mixins import Logi... | [
"hdforoozan@gmail.com"
] | hdforoozan@gmail.com |
5654cf482eb177451e9980b172ae3959c3598848 | c4249ce9e7cb26ae006bc9951ea676ae2250777b | /gamslib/tsp42/tsp42-scalar.py | 42958fd8ad72080b79cab8da32eb1cf7165217d6 | [] | no_license | vaidasj/alg-mod-rev | 79de3ef1e110f4bd07cbdef6951de2e4216f47f1 | a3ec6b5c21700a2f28ac6bf7db6aa22540748c6e | refs/heads/master | 2021-06-27T14:06:39.997411 | 2020-10-19T15:47:54 | 2020-10-19T15:47:54 | 180,074,989 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 80,771 | py | # MIP written by GAMS Convert at 12/13/18 10:32:27
#
# Equation counts
# Total E G L N X C B
# 43 43 0 0 0 0 0 0
#
# Variable counts
# x b i s1s s2s sc ... | [
"v.jusevicius@gmail.com"
] | v.jusevicius@gmail.com |
6786a568c54a17e0b7e59fcb7c9bc5425a1874be | 1eccb884bb72a07b7d5417c523fa082c13933984 | /backend/backend/settings.py | cd9d385829fbfeb6b9aa667d5a22266fca66aeff | [] | no_license | sajal09/rainbow- | 5c3bc744c406f30a6516ce3c5449579f4ca3a1aa | 963ccaa446c642cd9fde5ccc262d4a54a9b80561 | refs/heads/master | 2023-01-24T02:14:58.470392 | 2020-07-15T13:10:57 | 2020-07-15T13:10:57 | 124,750,812 | 0 | 0 | null | 2023-01-05T22:27:00 | 2018-03-11T11:44:50 | JavaScript | UTF-8 | Python | false | false | 3,222 | py | """
Django settings for backend project.
Generated by 'django-admin startproject' using Django 3.0.7.
For more information on this file, see
https://docs.djangoproject.com/en/3.0/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/3.0/ref/settings/
"""
import os
#... | [
"sajalchaurasia09@gmail.com"
] | sajalchaurasia09@gmail.com |
f8880d12b3954bf1f29a84e2fa0adf8ba9e779d6 | 52a4d869976a97498bdf56a8d0ff92cac138a136 | /Bioinformatics Textbook Track/Chapter 2/rosalind_ba2d.py | 238db719734990db59ec3be92ca629ff672af9ea | [] | no_license | aakibinesar/Rosalind | d726369a787d848cc378976b886189978a60a3a5 | 375bbdbfb16bf11b2f980701bbd0ba74a1605cdb | refs/heads/master | 2022-08-18T09:36:00.941080 | 2020-05-24T18:49:38 | 2020-05-24T18:49:38 | 264,722,651 | 0 | 0 | null | 2020-05-17T17:51:03 | 2020-05-17T17:40:59 | null | UTF-8 | Python | false | false | 1,561 | py | def greedymotifsearch(dna,k,t):
best = [s[:k] for s in dna]
for i in range(len(dna[0])-k+1):
tempbest = [dna[0][i:i+k]]
for m in range(1,t):
matrix = motifsToProfile(tempbest)
tempbest.append(profileMostProbablekmer(dna[m],k,matrix))
if score(tempbest) < score(bes... | [
"noreply@github.com"
] | aakibinesar.noreply@github.com |
3fa74ef1b8d7691e99faafe2a76a31346ce5aa33 | 35747e9ab6b1b70720ec90efcfce3e72e792b28c | /DQNAgent.py | 48dbd05199dcdda8e32e0a2152f104462b4ac961 | [] | no_license | nayansinghal/Deep-Q-Learning | aa568ff2f0400247f10ed4acd9732e693092b6d1 | 95b706500fd9539b5818ca7b147f79a44472c210 | refs/heads/master | 2021-08-27T19:54:52.692100 | 2017-11-04T21:03:45 | 2017-11-04T21:03:45 | 108,695,108 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,911 | py | import numpy as np
from collections import deque
import random
from ModelBuilder import ModelBuilder
from AtariModel import AtariModel
from Processor import AtariProcessor
from Memory import Memory
class DQNAgent:
def __init__(self, processor, state_size, action_size, lr=0.001, epsilon=1.0, model_path=None):
self.p... | [
"singhalnayan91@gmail.com"
] | singhalnayan91@gmail.com |
007455755e4df954816604e5b84ea3665446662f | bc900ac54e870c5150f1cf64a1196037c54835ce | /Main.py | 9d440ad2e8b1d45884e8a288feb45b10fddf7d26 | [] | no_license | ZeCanelha/AED_PROJECTO1 | 2065c12beb5047e80025f710c05e58b5dac53985 | 051991e4b2779d816139f520d4798d34ca94ff27 | refs/heads/master | 2021-01-19T21:15:05.700968 | 2017-03-26T22:14:48 | 2017-03-26T22:14:48 | 82,474,935 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,443 | py | import csv
import DoubleNode as DoubleNode
import DoubleLinkedList as DLList
import Functions as F
import re as split
#TODO Criar um dicionario com os pares de Pais / Sigla
_par_sigla_pais = {};
def create_ddlist(data):
DList = DLList.DoubleLinkedList()
Function = F.Functions(1,DList,_par_sigla_pais)
""... | [
"josemc@student.dei.uc.pt"
] | josemc@student.dei.uc.pt |
7c9e10c88fe57e659271b8670b20e26f8d2ecefe | 911e7c7ba3ff999eb58275595d934dee968d8f80 | /trunk/agent/src/main/python/ambari_agent/ZooKeeperCommunicator.py | 576a4a4b458c22c4da1e845e50d351cc59c69c8a | [
"Apache-2.0"
] | permissive | sreev/ambari | 1bce266ed0d318af3ebe50a7bd6b378083612330 | 48b92a5aa58debe7824f4337a97dfa8a8bb07f71 | refs/heads/master | 2021-01-10T21:44:10.844859 | 2012-04-19T19:20:28 | 2012-04-19T19:20:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,890 | py | #!/usr/bin/env python2.6
'''
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"Licens... | [
"sree_at_chess@yahoo.com"
] | sree_at_chess@yahoo.com |
077b5d30d14d285cab485c2c132910e626e14fc2 | dac8ec1bca7b390dac4aaedf94be0445cec03b66 | /lab04/run_NB.py | 53834b60d91845a6d924d88d71b14cd56d826d5d | [] | no_license | ldakir/Machine-Learning | 49333f641f745bcc523d6842fdc5e1c5db449d16 | 033a38459cac0d0c212f88a84ddcc6b772ec13dc | refs/heads/master | 2020-09-02T12:10:02.310934 | 2019-11-02T21:50:19 | 2019-11-02T21:50:19 | 219,218,176 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 906 | py | """
Top level comment: be sure to include the purpose/contents of this file
as well as the author(s)
"""
import util
from Partition import *
from NaiveBayes import *
import numpy as np
def main():
opts = util.parse_args()
train_partition = util.read_arff(opts.train_filename)
test_partition = util.read_ar... | [
"39743074+ldakir@users.noreply.github.com"
] | 39743074+ldakir@users.noreply.github.com |
8d1dcda3139a9d6e5d1dcd75a2e85017e18a0a4a | 78c3082e9082b5b50435805723ae00a58ca88e30 | /03.AI알고리즘 소스코드/venv/Lib/site-packages/caffe2/python/operator_test/flatten_op_test.py | ba5fce81296a516900f9cabf049c0c697338ce54 | [] | no_license | jinStar-kimmy/algorithm | 26c1bc456d5319578110f3d56f8bd19122356603 | 59ae8afd8d133f59a6b8d8cee76790fd9dfe1ff7 | refs/heads/master | 2023-08-28T13:16:45.690232 | 2021-10-20T08:23:46 | 2021-10-20T08:23:46 | 419,217,105 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 960 | py |
from hypothesis import given
import numpy as np
from caffe2.python import core
import caffe2.python.hypothesis_test_util as hu
class TestFlatten(hu.HypothesisTestCase):
@given(X=hu.tensor(min_dim=2, max_dim=4),
**hu.gcs)
def test_flatten(self, X, gc, dc):
for axis in r... | [
"gudwls3126@gmail.com"
] | gudwls3126@gmail.com |
a4d9cd67be8d8087ca60582c8e2dacbdbc3aac6e | 54e0c677471942aa35386e810e7fa54753bbecce | /Assignment 3 submission/preprocess.py | 23b0a97ab08a87dcc6522ff1fa19a31f8c302d1f | [] | no_license | itsuncheng/COMP4901I_Assignments | b27dd86d4e5a438c54c1298478bcc07efe2ea879 | 3bbe115056900515a4fa8fee1973219f9efdf334 | refs/heads/master | 2021-05-16T21:39:59.170470 | 2020-03-27T08:43:26 | 2020-03-27T08:43:26 | 250,479,705 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,657 | py | import pandas as pd
import re
import numpy as np
import pickle
from collections import Counter
import torch
import torch.utils.data as data
PAD_INDEX = 0
UNK_INDEX = 1
def clean(sent):
# clean the data
############################################################
# TO DO
###############################... | [
"itsuncheng2000@gmail.com"
] | itsuncheng2000@gmail.com |
08e27a11dfdd901859ea13372fe5cc91ccfe4f91 | 19a55c290de75ef32f790b96091eeb7a96703ec7 | /tasks/urls.py | 288e95106c5a36f4b38c17b300077d10576d3c58 | [] | no_license | vyshak-sukumaran/ToDo_Project | 49e7603d938d0401fc2d6c6caff8bd6bcf1f4ac1 | 7d368322d59793e42bcf5c00484d36fbf12240d0 | refs/heads/master | 2023-06-28T23:07:13.783844 | 2021-07-31T07:43:58 | 2021-07-31T07:43:58 | 391,287,194 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 237 | py | from django.urls import path, include
from . import views
urlpatterns = [
path('', views.index, name="index"),
path('update/<str:pk>/', views.update, name='update'),
path('delete/<str:pk>/', views.delete, name='delete'),
]
| [
"vyshakvyshu791@gmail.com"
] | vyshakvyshu791@gmail.com |
86438607b68f0230a38d395d4d3e9ad3da451323 | d68c6fd11a0a034348b5ec4cfd3304048a01e0a8 | /python/docop-hello-world/main.py | c44270d657fe9c00768af56e3c9630cd0e9279c6 | [] | no_license | wfelipe3/KnowBag | 043570ea1fad101d416b49bca04f621661ed159b | 0cf10e8a57076b68dc3ce9327869496027285c96 | refs/heads/master | 2021-01-24T08:15:30.437703 | 2018-02-12T03:32:49 | 2018-02-12T03:32:49 | 26,071,840 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,088 | py | """Naval Fate.
Usage:
naval_fate.py ship new <name>...
naval_fate.py ship <name> move <x> <y> [--speed=<kn>]
naval_fate.py ship shoot <x> <y>
naval_fate.py mine (set|remove) <x> <y> [--moored | --drifting]
naval_fate.py (-h | --help)
naval_fate.py --version
Options:
-h --help Show this screen.
--v... | [
"feliperojas@iMac-de-Felipe.local"
] | feliperojas@iMac-de-Felipe.local |
2432a572bd371ad31357a644beb118c7a6652907 | 9c3584757cda097128e6916a5490056263d038a1 | /cv/urls.py | b4a4aa8a59791c0d56489205762ada1f5cf5f7b1 | [] | no_license | jackcorsi/bridging-coursework | 0921a5e2b7dbba304895022e95707475d176fb36 | a1e5e2e42b3cdcc241356fefc2a53d47320c7e04 | refs/heads/master | 2022-12-12T11:35:28.713567 | 2020-08-31T22:06:28 | 2020-08-31T22:06:28 | 290,881,071 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 102 | py | from django.urls import path
from . import views
urlpatterns = [
path('', views.cv, name='cv'),
] | [
"jackcorsiwarren@gmail.com"
] | jackcorsiwarren@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.