blob_id stringlengths 40 40 | formatted stringlengths 15 1.74M | input_ids listlengths 7 1.19M | tokens listlengths 7 1.19M | rows listlengths 7 1.19M | cols listlengths 7 1.19M |
|---|---|---|---|---|---|
aff1a9263e183610f403a4d6a7f27b45eacb7ff2 | name = "valentina "
print(name * 1000)
| [
444,
299,
332,
718,
323,
5245,
332,
222,
1243,
45,
444,
338,
244,
54,
53,
53,
53,
46,
222
] | [
"name",
"Ġ=",
"Ġ\"",
"val",
"ent",
"ina",
"Ġ\"",
"Ċ",
"print",
"(",
"name",
"Ġ*",
"Ġ",
"1",
"0",
"0",
"0",
")",
"Ċ"
] | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2
] | [
1,
5,
7,
9,
12,
15,
18,
20,
1,
6,
7,
11,
13,
14,
15,
16,
17,
18,
19
] |
eabf06481509962652812af67ad59da5cfe30fae | """mupub module."""
__all__ = (
"__title__",
"__summary__",
"__version__",
"__author__",
"__license__",
"__copyright__",
)
__title__ = "mupub"
__summary__ = "Musical score publishing utility for the Mutopia Project"
"""Versioning:
This utility follows a MAJOR . MINOR . EDIT format. Upon a ma... | [
3012,
114,
436,
375,
2313,
7128,
222,
222,
523,
483,
523,
299,
327,
303,
9609,
1333,
41451,
303,
9609,
1386,
41451,
303,
9609,
1687,
41451,
303,
9609,
2133,
41451,
303,
9609,
2094,
41451,
303,
9609,
11793,
41451,
222,
46,
499,
222,
52... | [
"\"\"\"",
"m",
"up",
"ub",
"Ġmodule",
".\"\"\"",
"Ċ",
"Ċ",
"__",
"all",
"__",
"Ġ=",
"Ġ(",
"ĊĠĠĠ",
"Ġ\"__",
"title",
"__\",",
"ĊĠĠĠ",
"Ġ\"__",
"summary",
"__\",",
"ĊĠĠĠ",
"Ġ\"__",
"version",
"__\",",
"ĊĠĠĠ",
"Ġ\"__",
"author",
"__\",",
"ĊĠĠĠ",
"Ġ\"__",
"l... | [
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
5,
5,
5,
5,
6,
6,
6,
6,
7,
7,
7,
7,
8,
8,
8,
8,
9,
9,
9,
9,
10,
10,
12,
13,
13,
13,
13,
13,
13,
13,
13,
13,
13,
14,
14,
14,
14,
14,
14,
14,
14,
... | [
1,
4,
5,
7,
9,
16,
20,
1,
1,
3,
6,
8,
10,
12,
4,
8,
13,
17,
4,
8,
15,
19,
4,
8,
15,
19,
4,
8,
14,
18,
4,
8,
15,
19,
4,
8,
17,
21,
1,
2,
1,
1,
3,
8,
10,
12,
14,
15,
17,
19,
20,
1,
3,
10,
12,
14,
16,
17,
... |
54f0ed5f705d5ada28721301f297b2b0058773ad | """Module for the bot"""
from copy import deepcopy
from time import sleep
import mcpi.minecraft as minecraft
from mcpi.vec3 import Vec3
import mcpi.block as block
from search import SearchProblem, astar, bfs
from singleton import singleton
_AIR = block.AIR.id
_WATER = block.WATER.id
_LAVA = block.LAVA.id
_BEDROCK =... | [
3012,
2478,
456,
341,
7369,
3012,
222,
222,
1097,
1948,
1220,
29281,
222,
1097,
1153,
1220,
9375,
222,
222,
485,
16544,
1314,
51,
8654,
641,
364,
19469,
222,
1097,
16544,
1314,
51,
3160,
56,
1220,
7485,
56,
222,
485,
16544,
1314,
51,
... | [
"\"\"\"",
"Module",
"Ġfor",
"Ġthe",
"Ġbot",
"\"\"\"",
"Ċ",
"Ċ",
"from",
"Ġcopy",
"Ġimport",
"Ġdeepcopy",
"Ċ",
"from",
"Ġtime",
"Ġimport",
"Ġsleep",
"Ċ",
"Ċ",
"import",
"Ġmc",
"pi",
".",
"minecraft",
"Ġas",
"Ġm",
"inecraft",
"Ċ",
"from",
"Ġmc",
"pi",
".",... | [
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
11,
11,... | [
1,
4,
10,
14,
18,
22,
25,
1,
1,
5,
10,
17,
26,
1,
5,
10,
17,
23,
1,
1,
7,
10,
12,
13,
22,
25,
27,
35,
1,
5,
8,
10,
11,
14,
15,
22,
26,
27,
1,
7,
10,
12,
13,
18,
21,
27,
1,
1,
5,
12,
19,
26,
33,
34,
36,
40,
... |
45969b346d6d5cbdef2f5d2f74270cf12024072d | # Generated by Django 4.1.9 on 2023-06-29 16:11
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("search", "0003_auto_20230209_1441"),
]
operations = [
migrations.CreateModel(
name="SearchSettings",
fields=[
... | [
40,
13046,
829,
18288,
244,
57,
51,
54,
51,
62,
563,
244,
55,
53,
55,
56,
50,
53,
59,
50,
55,
62,
244,
54,
59,
63,
54,
54,
222,
222,
1097,
8532,
51,
1219,
1220,
12520,
49,
4590,
499,
222,
842,
18572,
45,
19772,
51,
12071,
73... | [
"#",
"ĠGenerated",
"Ġby",
"ĠDjango",
"Ġ",
"4",
".",
"1",
".",
"9",
"Ġon",
"Ġ",
"2",
"0",
"2",
"3",
"-",
"0",
"6",
"-",
"2",
"9",
"Ġ",
"1",
"6",
":",
"1",
"1",
"Ċ",
"Ċ",
"from",
"Ġdjango",
".",
"db",
"Ġimport",
"Ġmigrations",
",",
"Ġmodels",
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
5,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8... | [
1,
2,
12,
15,
22,
23,
24,
25,
26,
27,
28,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
1,
1,
5,
12,
13,
15,
22,
33,
34,
41,
1,
1,
6,
16,
17,
27,
28,
37,
39,
4,
17,
19,
21,
8,
11,
17... |
67b967b688aeac1270eee836e0f6e6b3555b933e | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
This program is run at regular intervals to check the battery charge status of the uninterruptible power supply.
In our case, it is a LiPo battery with a nominal voltage of 3.7 volts. By setting the voltage for the
Raspberry PI shutdown procedure at 3.7 V,we ensure th... | [
8758,
3392,
52,
1793,
52,
2141,
4406,
56,
222,
40,
8571,
10633,
63,
6471,
50,
61,
8571,
222,
222,
3012,
222,
2287,
3477,
458,
1441,
840,
10639,
26438,
391,
1524,
341,
29942,
10117,
2302,
451,
341,
725,
15334,
1497,
7183,
19456,
51,
... | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"3",
"Ċ",
"#",
"Ġ-*-",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ġ-*-",
"Ċ",
"Ċ",
"\"\"\"",
"Ċ",
"This",
"Ġprogram",
"Ġis",
"Ġrun",
"Ġat",
"Ġregular",
"Ġintervals",
"Ġto",
"Ġcheck",
"Ġthe",
"Ġbattery",
"Ġcharge... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6... | [
1,
4,
7,
8,
11,
12,
15,
22,
23,
1,
2,
6,
13,
14,
18,
19,
20,
24,
1,
1,
4,
1,
5,
13,
16,
20,
23,
31,
41,
44,
50,
54,
62,
69,
76,
79,
83,
86,
95,
99,
105,
112,
113,
1,
3,
7,
12,
13,
16,
19,
21,
24,
26,
34,
39,
... |
c59707ba07c1659d94684c54cdd7bb2658cba935 | from __future__ import division, print_function, absolute_import
import numbers
import warnings
from abc import ABCMeta, abstractmethod
import numpy as np
from .base import check_frame
from skutil.base import overrides
from sklearn.externals import six
from sklearn.base import _pprint
from sklearn.utils.fixes import si... | [
1097,
1176,
9689,
523,
1220,
20707,
49,
1489,
100,
1144,
49,
7984,
100,
485,
222,
485,
7560,
222,
485,
11740,
222,
1097,
20701,
1220,
20660,
3123,
2303,
49,
5560,
1978,
222,
485,
6610,
641,
2115,
222,
1097,
657,
1460,
1220,
1524,
100,... | [
"from",
"Ġ__",
"future",
"__",
"Ġimport",
"Ġdivision",
",",
"Ġprint",
"_",
"function",
",",
"Ġabsolute",
"_",
"import",
"Ċ",
"import",
"Ġnumbers",
"Ċ",
"import",
"Ġwarnings",
"Ċ",
"from",
"Ġabc",
"Ġimport",
"ĠAB",
"CM",
"eta",
",",
"Ġabstract",
"method",
"... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9... | [
1,
5,
8,
14,
16,
23,
32,
33,
39,
40,
48,
49,
58,
59,
65,
1,
7,
15,
1,
7,
16,
1,
5,
9,
16,
19,
21,
24,
25,
34,
40,
1,
7,
13,
16,
19,
1,
5,
7,
11,
18,
24,
25,
30,
1,
5,
8,
12,
13,
17,
24,
34,
1,
5,
13,
14,
... |
41cfd558824b6561114a48a694b1e6e6a7cb8c05 | import streamlit as st
from streamlit.components.v1 import components
from streamlit.report_thread import get_report_ctx
from util.session import *
from multipage import MultiPage
from pages import register
def app(page):
if not login_status():
title_container = st.empty()
remail_input_container =... | [
485,
3458,
2543,
641,
395,
222,
1097,
3458,
2543,
51,
3545,
51,
123,
54,
1220,
6361,
222,
1097,
3458,
2543,
51,
3755,
100,
3442,
1220,
640,
100,
3755,
100,
2112,
222,
1097,
4548,
51,
2867,
1220,
338,
222,
1097,
12099,
400,
1220,
104... | [
"import",
"Ġstream",
"lit",
"Ġas",
"Ġst",
"Ċ",
"from",
"Ġstream",
"lit",
".",
"components",
".",
"v",
"1",
"Ġimport",
"Ġcomponents",
"Ċ",
"from",
"Ġstream",
"lit",
".",
"report",
"_",
"thread",
"Ġimport",
"Ġget",
"_",
"report",
"_",
"ctx",
"Ċ",
"from",
... | [
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
8,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
1... | [
1,
7,
14,
17,
20,
23,
1,
5,
12,
15,
16,
26,
27,
28,
29,
36,
47,
1,
5,
12,
15,
16,
22,
23,
29,
36,
40,
41,
47,
48,
51,
1,
5,
10,
11,
18,
25,
27,
1,
5,
12,
15,
22,
28,
32,
1,
5,
11,
18,
27,
1,
1,
4,
8,
9,
13,... |
f2bb44600f011a205c71985ad94c18f7e058634f | import os
import requests
from PIL import Image
from io import BytesIO
import csv
from typing import Iterable, List, Tuple, Dict, Callable, Union, Collection
# pull the image from the api endpoint and save it if we don't have it, else load it from disk
def get_img_from_file_or_url(img_format: str = "JPEG") -> Callabl... | [
485,
2355,
222,
485,
5188,
222,
1097,
35991,
1220,
4393,
222,
1097,
3377,
1220,
18401,
2354,
222,
485,
11490,
222,
1097,
12018,
1220,
19208,
49,
1701,
49,
11724,
49,
14609,
49,
27052,
49,
16546,
49,
7380,
499,
222,
40,
5093,
341,
1802... | [
"import",
"Ġos",
"Ċ",
"import",
"Ġrequests",
"Ċ",
"from",
"ĠPIL",
"Ġimport",
"ĠImage",
"Ċ",
"from",
"Ġio",
"Ġimport",
"ĠBytes",
"IO",
"Ċ",
"import",
"Ġcsv",
"Ċ",
"from",
"Ġtyping",
"Ġimport",
"ĠIterable",
",",
"ĠList",
",",
"ĠTuple",
",",
"ĠDict",
",",
"... | [
1,
1,
1,
2,
2,
2,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
... | [
1,
7,
10,
1,
7,
16,
1,
5,
9,
16,
22,
1,
5,
8,
15,
21,
23,
1,
7,
11,
1,
5,
12,
19,
28,
29,
34,
35,
41,
42,
47,
48,
57,
58,
64,
65,
76,
1,
1,
2,
7,
11,
17,
22,
26,
30,
39,
43,
48,
51,
54,
57,
61,
63,
68,
71,
... |
302605d8bb45b1529742bf9441d476f0276085b9 | import sys
from PyQt5.QtWidgets import (
QMainWindow,
QWidget,
QHBoxLayout,
QVBoxLayout,
QFrame,
QSplitter,
QStyleFactory,
QApplication,
QPushButton,
QTextEdit,
QLabel,
QFileDialog,
QMessageBox,
)
from PyQt5.QtCore import Qt
from PyQt5.QtGui import QFont, QColor
impor... | [
485,
5263,
222,
1097,
48886,
58,
51,
47881,
1220,
327,
303,
1931,
21495,
49,
303,
39917,
49,
303,
1931,
77,
30400,
49,
303,
1931,
91,
30400,
49,
303,
1931,
2163,
49,
303,
1931,
34841,
49,
303,
1931,
2291,
2232,
49,
303,
1931,
2743,
... | [
"import",
"Ġsys",
"Ċ",
"from",
"ĠPyQt",
"5",
".",
"QtWidgets",
"Ġimport",
"Ġ(",
"ĊĠĠĠ",
"ĠQ",
"MainWindow",
",",
"ĊĠĠĠ",
"ĠQWidget",
",",
"ĊĠĠĠ",
"ĠQ",
"H",
"BoxLayout",
",",
"ĊĠĠĠ",
"ĠQ",
"V",
"BoxLayout",
",",
"ĊĠĠĠ",
"ĠQ",
"Frame",
",",
"ĊĠĠĠ",
"ĠQ"... | [
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
4,
4,
4,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
7,
7,
7,
7,
8,
8,
8,
8,
9,
9,
9,
9,
9,
10,
10,
10,
10,
11,
11,
11,
11,
12,
12,
12,
12,
12,
13,
13,
13,
14,
14,
14,... | [
1,
7,
11,
1,
5,
10,
11,
12,
21,
28,
30,
4,
6,
16,
17,
4,
12,
13,
4,
6,
7,
16,
17,
4,
6,
7,
16,
17,
4,
6,
11,
12,
4,
6,
14,
15,
4,
6,
11,
18,
19,
4,
6,
17,
18,
4,
6,
16,
17,
4,
6,
10,
14,
15,
4,
11,
12,
... |
5d9c8e235385ff53c7510994826ff3a04e4a5888 | """
@file : 001-rnn+lstm+crf.py
@author: xiaolu
@time : 2019-09-06
"""
import re
import numpy as np
import tensorflow as tf
from sklearn.metrics import classification_report
class Model:
def __init__(self, dim_word, dim_char, dropout, learning_rate, hidden_size_char, hidden_size_word, num_layers):
... | [
3012,
222,
222,
69,
781,
244,
518,
244,
53,
53,
54,
50,
28394,
48,
35833,
48,
2465,
107,
51,
997,
222,
222,
69,
2133,
63,
837,
923,
381,
122,
222,
222,
69,
1021,
244,
518,
244,
55,
53,
54,
62,
50,
53,
62,
50,
53,
59,
222,
... | [
"\"\"\"",
"Ċ",
"Ċ",
"@",
"file",
"Ġ",
"Ġ:",
"Ġ",
"0",
"0",
"1",
"-",
"rnn",
"+",
"lstm",
"+",
"cr",
"f",
".",
"py",
"Ċ",
"Ċ",
"@",
"author",
":",
"Ġx",
"ia",
"ol",
"u",
"Ċ",
"Ċ",
"@",
"time",
"Ġ",
"Ġ:",
"Ġ",
"2",
"0",
"1",
"9",
"-",
"... | [
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
9,
9,
10,
11,
11,
11,
12,
12,
12,
12,
12,
13,
13,
... | [
1,
4,
1,
1,
2,
6,
7,
9,
10,
11,
12,
13,
14,
17,
18,
22,
23,
25,
26,
27,
29,
1,
1,
2,
8,
9,
11,
13,
15,
16,
1,
1,
2,
6,
7,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
19,
20,
1,
1,
4,
1,
1,
7,
10,
1,
7,
13,
1... |
54e04d740ef46fca04cf4169d2e7c05083414bd8 | import random
import math
import time
import pygame
pygame.init()
scr = pygame.display.set_mode((700, 700))
enemies = []
# music = pygame.mixer.music.load('ENERGETIC CHIPTUNE Thermal - Evan King.mp3')
# pygame.mixer.music.play(-1)
hit = []
class Player:
def __init__(self):
self.x = 275
self.y = 2... | [
485,
4051,
222,
485,
7820,
222,
485,
1153,
222,
485,
23967,
222,
222,
997,
3642,
51,
1683,
365,
222,
10340,
299,
23967,
51,
2784,
51,
489,
100,
2832,
1181,
60,
53,
53,
49,
244,
60,
53,
53,
509,
222,
291,
27074,
299,
1627,
222,
4... | [
"import",
"Ġrandom",
"Ċ",
"import",
"Ġmath",
"Ċ",
"import",
"Ġtime",
"Ċ",
"import",
"Ġpygame",
"Ċ",
"Ċ",
"py",
"game",
".",
"init",
"()",
"Ċ",
"scr",
"Ġ=",
"Ġpygame",
".",
"display",
".",
"set",
"_",
"mode",
"((",
"7",
"0",
"0",
",",
"Ġ",
"7",
"0... | [
1,
1,
1,
2,
2,
2,
3,
3,
3,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9... | [
1,
7,
14,
1,
7,
12,
1,
7,
12,
1,
7,
14,
1,
1,
3,
7,
8,
12,
14,
1,
4,
6,
13,
14,
21,
22,
25,
26,
30,
32,
33,
34,
35,
36,
37,
38,
39,
40,
42,
1,
3,
8,
10,
13,
1,
2,
8,
10,
17,
18,
23,
24,
29,
30,
34,
36,
40... |
2cbce618d1ec617d1c7dc0e9792b6a49361ec5a4 | def mais_populoso(dic):
p = 0
sp = 0
for t, i in dic.items():
for m in dic[t].values():
p += m
if p > sp:
sp = p
x = t
return x
| [
610,
15338,
100,
3254,
7293,
780,
45,
2957,
731,
303,
317,
299,
244,
53,
303,
1887,
299,
244,
53,
303,
456,
292,
49,
613,
347,
27477,
51,
3053,
2284,
310,
456,
364,
347,
27477,
96,
121,
1015,
2857,
2284,
343,
317,
1475,
364,
310,
... | [
"def",
"Ġmais",
"_",
"pop",
"ulo",
"so",
"(",
"dic",
"):",
"ĊĠĠĠ",
"Ġp",
"Ġ=",
"Ġ",
"0",
"ĊĠĠĠ",
"Ġsp",
"Ġ=",
"Ġ",
"0",
"ĊĠĠĠ",
"Ġfor",
"Ġt",
",",
"Ġi",
"Ġin",
"Ġdic",
".",
"items",
"():",
"ĊĠĠĠĠĠĠĠ",
"Ġfor",
"Ġm",
"Ġin",
"Ġdic",
"[",
"t",
"]."... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
9,
9,
9,
9,
10,
10,
10
] | [
1,
4,
9,
10,
13,
16,
18,
19,
22,
24,
4,
6,
8,
9,
10,
4,
7,
9,
10,
11,
4,
8,
10,
11,
13,
16,
20,
21,
26,
29,
8,
12,
14,
17,
21,
22,
23,
25,
31,
34,
12,
14,
17,
19,
8,
11,
13,
15,
18,
19,
12,
15,
17,
19,
12,
... |
2092ead8b8f268a22711b8af8052241c1ac00c15 | wage = 5
print("%d시간에 %d%s 벌었습니다." % (1, wage * 1, "달러"))
print("%d시간에 %d%s 벌었습니다." % (5, wage * 5, "달러"))
print("%d시간에 %.1f%s 벌었습니다" % (1, 5710.8, "원"))
print("%d시간에 %.1f%s 벌었습니다" % (5, 28554.0, "원"))
| [
124,
400,
299,
244,
58,
222,
222,
1243,
4923,
105,
11835,
22988,
5032,
925,
105,
42,
120,
21590,
258,
35509,
13865,
3128,
925,
327,
54,
49,
360,
400,
338,
244,
54,
49,
332,
2825,
143,
19156,
2152,
222,
1243,
4923,
105,
11835,
22988,... | [
"w",
"age",
"Ġ=",
"Ġ",
"5",
"Ċ",
"Ċ",
"print",
"(\"%",
"d",
"ìĭľ",
"ê°Ħ",
"ìĹIJ",
"Ġ%",
"d",
"%",
"s",
"Ġë²",
"Į",
"ìĹĪ",
"ìĬµëĭĪëĭ¤",
".\"",
"Ġ%",
"Ġ(",
"1",
",",
"Ġw",
"age",
"Ġ*",
"Ġ",
"1",
",",
"Ġ\"",
"ëĭ",
"¬",
"룬",
"\"))",
"Ċ",
"prin... | [
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4... | [
1,
2,
5,
7,
8,
9,
1,
1,
6,
9,
10,
11,
12,
13,
15,
16,
17,
18,
19,
20,
21,
24,
26,
28,
30,
31,
32,
34,
37,
39,
40,
41,
42,
44,
44,
45,
46,
49,
1,
6,
9,
10,
11,
12,
13,
15,
16,
17,
18,
19,
20,
21,
24,
26,
28,
... |
805fc9a26650f85227d14da972311ffbd9dbd555 | class Date:
def __init__(self, strDate):
strDate = strDate.split(".")
self.day = strDate[0]
self.month = strDate[1]
self.year = strDate[2]
| [
842,
2833,
63,
303,
684,
1176,
1683,
3232,
803,
49,
615,
1563,
731,
310,
615,
1563,
299,
615,
1563,
51,
3045,
46854,
310,
649,
51,
3386,
299,
615,
1563,
96,
53,
98,
310,
649,
51,
5926,
299,
615,
1563,
96,
54,
98,
310,
649,
51,
... | [
"class",
"ĠDate",
":",
"ĊĠĠĠ",
"Ġdef",
"Ġ__",
"init",
"__(",
"self",
",",
"Ġstr",
"Date",
"):",
"ĊĠĠĠĠĠĠĠ",
"Ġstr",
"Date",
"Ġ=",
"Ġstr",
"Date",
".",
"split",
"(\".\")",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
".",
"day",
"Ġ=",
"Ġstr",
"Date",
"[",
"0",
"]",
"ĊĠĠĠĠĠĠĠ",... | [
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6
] | [
1,
6,
11,
12,
4,
8,
11,
15,
18,
22,
23,
27,
31,
33,
8,
12,
16,
18,
22,
26,
27,
32,
37,
8,
13,
14,
17,
19,
23,
27,
28,
29,
30,
8,
13,
14,
19,
21,
25,
29,
30,
31,
32,
8,
13,
14,
18,
20,
24,
28,
29,
30,
31
] |
038ccba05113fb7f2f589eaa7345df53cb59a5af | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys
import torch
from torch import nn, autograd
import config
import time
import copy
import progressbar as pb
from dataset import TrainDataSet
from model import BiAffineSrlModel
from fscore import FScore
config.add_option("-m", "--mode", dest="mode", default="train... | [
8758,
3392,
52,
1793,
52,
2141,
4406,
222,
40,
8571,
10633,
63,
6471,
50,
61,
8571,
222,
485,
5263,
222,
485,
5665,
222,
1097,
5665,
1220,
8507,
49,
2283,
4985,
222,
485,
1377,
222,
485,
1153,
222,
485,
1948,
222,
485,
6551,
1652,
... | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"Ċ",
"#",
"Ġ-*-",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ġ-*-",
"Ċ",
"import",
"Ġsys",
"Ċ",
"import",
"Ġtorch",
"Ċ",
"from",
"Ġtorch",
"Ġimport",
"Ġnn",
",",
"Ġauto",
"grad",
"Ċ",
"import",
"Ġconfig",
"Ċ",... | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
7,
7,
7,
8,
8,
8,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
11,
11,
11,
11,
11,
11,
11,
11,
11... | [
1,
4,
7,
8,
11,
12,
15,
22,
1,
2,
6,
13,
14,
18,
19,
20,
24,
1,
7,
11,
1,
7,
13,
1,
5,
11,
18,
21,
22,
27,
31,
1,
7,
14,
1,
7,
12,
1,
7,
12,
1,
7,
16,
19,
22,
25,
1,
5,
13,
20,
26,
33,
1,
5,
11,
18,
21,
... |
b5180a2dbe1f12e1bbc92874c67ea99c9a84a9ed | # print all cards with even numbers.
cards = ["2", "3", "4", "5", "6", "7", "8", "9", "10", "J", "Q", "K", "A"]
for card in cards:
try:
number = int(card)
if number % 2 == 0: # modulo operator
print(card, "is an even card.")
except ValueError:
print(card, "can not be divid... | [
40,
1489,
1187,
16278,
642,
4462,
7560,
51,
222,
222,
12266,
299,
3059,
55,
411,
332,
56,
411,
332,
57,
411,
332,
58,
411,
332,
59,
411,
332,
60,
411,
332,
61,
411,
332,
62,
411,
332,
54,
53,
411,
332,
79,
411,
332,
86,
411,
... | [
"#",
"Ġprint",
"Ġall",
"Ġcards",
"Ġwith",
"Ġeven",
"Ġnumbers",
".",
"Ċ",
"Ċ",
"cards",
"Ġ=",
"Ġ[\"",
"2",
"\",",
"Ġ\"",
"3",
"\",",
"Ġ\"",
"4",
"\",",
"Ġ\"",
"5",
"\",",
"Ġ\"",
"6",
"\",",
"Ġ\"",
"7",
"\",",
"Ġ\"",
"8",
"\",",
"Ġ\"",
"9",
"\",",
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
6,
6,
6,
7... | [
1,
2,
8,
12,
18,
23,
28,
36,
37,
1,
1,
6,
8,
11,
12,
14,
16,
17,
19,
21,
22,
24,
26,
27,
29,
31,
32,
34,
36,
37,
39,
41,
42,
44,
46,
47,
49,
51,
52,
53,
55,
57,
58,
60,
62,
63,
65,
67,
68,
70,
72,
73,
75,
1,
... |
13c9f0f58ec6da317c3802f594bb0db7c275dee9 | """
!pip install wget
from zipfile import ZipFile
import wget
print('Beginning file downlaod with wget module')
url = 'https://download.microsoft.com/download/3/E/1/3E1C3F21-ECDB-4869-8368-6DEBA77B919F/kagglecatsanddogs_3367a.zip'
wget.download(url, 'sample_data/')
print('2. Extract all files in ZIP to different dir... | [
3012,
222,
38,
9144,
2462,
25399,
222,
1097,
8617,
781,
1220,
23049,
991,
222,
485,
25399,
222,
1243,
482,
46284,
822,
2850,
3104,
450,
642,
25399,
2313,
704,
222,
222,
983,
299,
349,
662,
574,
5000,
51,
3800,
51,
527,
52,
5000,
52,... | [
"\"\"\"",
"Ċ",
"!",
"pip",
"Ġinstall",
"Ġwget",
"Ċ",
"from",
"Ġzip",
"file",
"Ġimport",
"ĠZip",
"File",
"Ċ",
"import",
"Ġwget",
"Ċ",
"print",
"('",
"Beginning",
"Ġfile",
"Ġdown",
"la",
"od",
"Ġwith",
"Ġwget",
"Ġmodule",
"')",
"Ċ",
"Ċ",
"url",
"Ġ=",
"Ġ'... | [
1,
1,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
4,
1,
2,
5,
13,
18,
1,
5,
9,
13,
20,
24,
28,
1,
7,
12,
1,
6,
8,
17,
22,
27,
29,
31,
36,
41,
48,
50,
1,
1,
4,
6,
8,
13,
16,
24,
25,
34,
35,
38,
39,
47,
48,
49,
50,
51,
52,
53,
54,
55,
56,
57,
58,
59,
60,
... |
95c5971a102fb2ed84ab0de0471278d0167d8359 | #!/usr/bin/python3
"""1. Divide a matrix"""
def matrix_divided(matrix, div):
"""Divides a Matrix
Args:
matrix: A list of lists of ints or floats
div: a non zero int or float
Exceptions:
TypeError: if the matrix and/or div is not as stated or the matrix elements
are not of the ... | [
8758,
3392,
52,
1793,
52,
2980,
56,
222,
3012,
54,
51,
17555,
824,
331,
5083,
3012,
499,
222,
610,
5083,
100,
526,
12190,
45,
4948,
49,
4469,
731,
303,
1547,
6792,
13014,
331,
9351,
465,
10485,
63,
303,
5083,
63,
418,
1168,
451,
1... | [
"#!/",
"usr",
"/",
"bin",
"/",
"python",
"3",
"Ċ",
"\"\"\"",
"1",
".",
"ĠDiv",
"ide",
"Ġa",
"Ġmatrix",
"\"\"\"",
"ĊĊ",
"Ċ",
"def",
"Ġmatrix",
"_",
"div",
"ided",
"(",
"matrix",
",",
"Ġdiv",
"):",
"ĊĠĠĠ",
"Ġ\"\"\"",
"Div",
"ides",
"Ġa",
"ĠMatrix",
"... | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
12,
12,
12,
... | [
1,
4,
7,
8,
11,
12,
18,
19,
1,
4,
5,
6,
10,
13,
15,
22,
25,
1,
1,
4,
11,
12,
15,
19,
20,
26,
27,
31,
33,
4,
8,
11,
15,
17,
24,
4,
9,
10,
4,
11,
12,
14,
19,
22,
28,
31,
36,
39,
46,
4,
8,
9,
11,
15,
20,
24,
... |
5fb998fa761b989c6dd423634824197bade4f8a5 | """
You can perform the following operations on the string, :
Capitalize zero or more of 's lowercase letters.
Delete all of the remaining lowercase letters in .
Given two strings, and , determine if it's possible to make equal to as described. If so, print YES on a new line. Otherwise, print NO.
For example, give... | [
3012,
222,
4296,
902,
4464,
341,
2434,
7392,
563,
341,
821,
49,
518,
222,
222,
39568,
537,
5953,
575,
1851,
451,
349,
120,
27104,
19429,
51,
222,
3422,
1187,
451,
341,
11479,
27104,
19429,
347,
657,
222,
16634,
3161,
5872,
49,
244,
... | [
"\"\"\"",
"Ċ",
"You",
"Ġcan",
"Ġperform",
"Ġthe",
"Ġfollowing",
"Ġoperations",
"Ġon",
"Ġthe",
"Ġstring",
",",
"Ġ:",
"Ċ",
"Ċ",
"Capital",
"ize",
"Ġzero",
"Ġor",
"Ġmore",
"Ġof",
"Ġ'",
"s",
"Ġlowercase",
"Ġletters",
".",
"Ċ",
"Delete",
"Ġall",
"Ġof",
"Ġthe",
... | [
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6... | [
1,
4,
1,
4,
8,
16,
20,
30,
41,
44,
48,
55,
56,
58,
1,
1,
8,
11,
16,
19,
24,
27,
29,
30,
40,
48,
49,
1,
7,
11,
14,
18,
28,
38,
46,
49,
51,
1,
6,
10,
18,
19,
20,
24,
26,
36,
39,
42,
44,
53,
56,
61,
62,
68,
71,
... |
5ed439a2a7cfb9c941c40ea0c5eba2851a0f2855 | #!/bin/python3
# Implement a stack with push, pop, inc(e, k) operations
# inc (e,k) - Add k to each of bottom e elements
import sys
class Stack(object):
def __init__(self):
self.arr = []
def push(self, val):
self.arr.append(val)
def pop(self):
if len(self.arr):
retur... | [
8758,
1793,
52,
2980,
56,
222,
222,
40,
10135,
331,
4154,
642,
5849,
49,
4742,
49,
6985,
45,
106,
49,
851,
46,
7392,
222,
40,
6985,
327,
106,
49,
112,
46,
449,
2242,
851,
391,
2531,
451,
6838,
503,
4725,
222,
485,
5263,
499,
222... | [
"#!/",
"bin",
"/",
"python",
"3",
"Ċ",
"Ċ",
"#",
"ĠImplement",
"Ġa",
"Ġstack",
"Ġwith",
"Ġpush",
",",
"Ġpop",
",",
"Ġinc",
"(",
"e",
",",
"Ġk",
")",
"Ġoperations",
"Ċ",
"#",
"Ġinc",
"Ġ(",
"e",
",",
"k",
")",
"Ġ-",
"ĠAdd",
"Ġk",
"Ġto",
"Ġeach",
... | [
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
7,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10... | [
1,
4,
7,
8,
14,
15,
1,
1,
2,
12,
14,
20,
25,
30,
31,
35,
36,
40,
41,
42,
43,
45,
46,
57,
1,
2,
6,
8,
9,
10,
11,
12,
14,
18,
20,
23,
28,
31,
38,
40,
49,
1,
7,
11,
1,
1,
6,
12,
13,
19,
21,
4,
8,
11,
15,
18,
... |
39f9341313e29a22ec5e05ce9371bf65e89c91bd | """
리스트에 있는 숫자들의 최빈값을 구하는 프로그램을 만들어라.
[12, 17, 19, 17, 23] = 17
[26, 37, 26, 37, 91] = 26, 37
[28, 30, 32, 34, 144] = 없다
최빈값 : 자료의 값 중에서 가장 많이 나타난 값
① 자료의 값이 모두 같거나 모두 다르면 최빈값은 없다.
② 자료의 값이 모두 다를 때, 도수가 가장 큰 값이 1개 이상 있으면 그 값은 모두 최빈값이다.
"""
n_list = [[12, 17, 19, 17, 23], [26, 37, 26, 37, 91], [28, 30, 32, 34, 144], ... | [
3012,
222,
8691,
25172,
5032,
22527,
37330,
142,
10764,
14397,
5996,
31553,
203,
155,
254,
36102,
5197,
17475,
11739,
40460,
46886,
5197,
31875,
41937,
11775,
51,
222,
222,
96,
54,
55,
49,
244,
54,
60,
49,
244,
54,
62,
49,
244,
54,
... | [
"\"\"\"",
"Ċ",
"리",
"ìĬ¤íĬ¸",
"ìĹIJ",
"ĠìŀĪëĬĶ",
"ĠìĪ",
"«",
"ìŀIJ",
"ëĵ¤",
"ìĿĺ",
"Ġìµľ",
"ë",
"¹",
"Ī",
"ê°Ĵ",
"ìĿĦ",
"Ġ구",
"íķĺëĬĶ",
"ĠíĶĦë¡ľê·¸",
"ëŀ¨",
"ìĿĦ",
"Ġë§Įëĵ¤",
"ìĸ´ë",
"Ŀ¼",
".",
"Ċ",
"Ċ",
"[",
"1",
"2",
",",
"Ġ",
"1",
"7",
",",
... | [
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5... | [
1,
4,
1,
2,
4,
5,
8,
9,
10,
11,
12,
13,
15,
15,
15,
16,
17,
18,
20,
22,
26,
27,
28,
31,
32,
33,
34,
1,
1,
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
19,
20,
21,
23,
24,
25,
26,
1,
2,
3,
4... |
312cc666c88fcd22882c49598db8c5e18bd3dae1 | from setuptools import setup, find_packages
from setuptools.extension import Extension
from sys import platform
cython = True
try:
from Cython.Build import cythonize
cython = True
except ImportError:
cython = False
# Define the C++ extension
if platform == "darwin":
extra_compile_args = ["-O3", "-pt... | [
1097,
29910,
1220,
4721,
49,
2309,
100,
5051,
222,
1097,
29910,
51,
6749,
1220,
15354,
222,
1097,
5263,
1220,
5637,
222,
222,
104,
2457,
299,
2969,
222,
222,
1287,
63,
303,
664,
409,
2457,
51,
3328,
1220,
300,
2457,
537,
465,
300,
2... | [
"from",
"Ġsetuptools",
"Ġimport",
"Ġsetup",
",",
"Ġfind",
"_",
"packages",
"Ċ",
"from",
"Ġsetuptools",
".",
"extension",
"Ġimport",
"ĠExtension",
"Ċ",
"from",
"Ġsys",
"Ġimport",
"Ġplatform",
"Ċ",
"Ċ",
"c",
"ython",
"Ġ=",
"ĠTrue",
"Ċ",
"Ċ",
"try",
":",
"ĊĠĠ... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
6,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
10,
10,
10,
10,
10,
11,
11,
11,
11,
12,
12,
12,
12,
12,
13,
14,
14,
14,
14,... | [
1,
5,
16,
23,
29,
30,
35,
36,
44,
1,
5,
16,
17,
26,
33,
43,
1,
5,
9,
16,
25,
1,
1,
2,
7,
9,
14,
1,
1,
4,
5,
4,
9,
11,
16,
17,
22,
29,
31,
36,
39,
4,
6,
11,
13,
18,
1,
7,
19,
20,
4,
6,
11,
13,
19,
1,
1,
... |
2aec0581413d4fb0ffb4090231fde0fed974bf18 | import numpy as np
import random
with open("./roc.txt", "r") as fin:
with open("./roc_shuffle.txt", "w") as fout:
tmp = []
for k, line in enumerate(fin):
i = k + 1
if i % 6 == 0:
idx = [0] + np.random.permutation(range(1, 5)).tolist()
for sen ... | [
485,
6610,
641,
2115,
222,
485,
4051,
222,
222,
1814,
2177,
12031,
24051,
51,
2787,
411,
332,
119,
678,
641,
3770,
63,
303,
642,
2177,
12031,
24051,
100,
18047,
51,
2787,
411,
332,
124,
678,
641,
39862,
63,
310,
3709,
299,
1627,
310... | [
"import",
"Ġnumpy",
"Ġas",
"Ġnp",
"Ċ",
"import",
"Ġrandom",
"Ċ",
"Ċ",
"with",
"Ġopen",
"(\"./",
"roc",
".",
"txt",
"\",",
"Ġ\"",
"r",
"\")",
"Ġas",
"Ġfin",
":",
"ĊĠĠĠ",
"Ġwith",
"Ġopen",
"(\"./",
"roc",
"_",
"shuffle",
".",
"txt",
"\",",
"Ġ\"",
"w",
... | [
1,
1,
1,
1,
1,
2,
2,
2,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9... | [
1,
7,
13,
16,
19,
1,
7,
14,
1,
1,
5,
10,
14,
17,
18,
21,
23,
25,
26,
28,
31,
35,
36,
4,
9,
14,
18,
21,
22,
29,
30,
33,
35,
37,
38,
40,
43,
48,
49,
8,
12,
14,
17,
8,
12,
14,
15,
20,
23,
33,
34,
37,
39,
12,
14,... |
4f13e2858d9cf469f14026808142886e5c3fcc85 | class Solution:
def merge(self, nums1, m, nums2, n):
"""
Do not return anything, modify nums1 in-place instead.
"""
if n == 0:
nums1 = nums1
if nums1[m - 1] <= nums2[0]:
for i in range(n):
nums1[m + i] = nums2[i]
elif nums1[0]... | [
842,
12219,
63,
303,
684,
4009,
45,
803,
49,
12988,
54,
49,
364,
49,
12988,
55,
49,
329,
731,
310,
1547,
310,
3291,
666,
461,
8003,
49,
5370,
12988,
54,
347,
50,
1878,
4203,
51,
310,
1547,
603,
434,
329,
630,
244,
53,
63,
343,
... | [
"class",
"ĠSolution",
":",
"ĊĠĠĠ",
"Ġdef",
"Ġmerge",
"(",
"self",
",",
"Ġnums",
"1",
",",
"Ġm",
",",
"Ġnums",
"2",
",",
"Ġn",
"):",
"ĊĠĠĠĠĠĠĠ",
"Ġ\"\"\"",
"ĊĠĠĠĠĠĠĠ",
"ĠDo",
"Ġnot",
"Ġreturn",
"Ġanything",
",",
"Ġmodify",
"Ġnums",
"1",
"Ġin",
"-",
"pla... | [
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9... | [
1,
6,
15,
16,
4,
8,
14,
15,
19,
20,
25,
26,
27,
29,
30,
35,
36,
37,
39,
41,
8,
12,
8,
11,
15,
22,
31,
32,
39,
44,
45,
48,
49,
54,
62,
63,
8,
12,
8,
11,
13,
16,
17,
18,
19,
12,
17,
18,
20,
25,
26,
8,
11,
16,
1... |
57967f36a45bb3ea62708bbbb5b2f4ddb0f4bb16 | # -*- coding:ascii -*-
from mako import runtime, filters, cache
UNDEFINED = runtime.UNDEFINED
__M_dict_builtin = dict
__M_locals_builtin = locals
_magic_number = 10
_modified_time = 1428612037.145222
_enable_loop = True
_template_filename = "C:\\Users\\Cody\\Desktop\\Heritage\\chf\\templates/account.rentalcart.html"
_... | [
40,
8571,
10633,
63,
14528,
8571,
222,
1097,
364,
17560,
1220,
6098,
49,
10637,
49,
3337,
222,
222,
41597,
299,
6098,
51,
41597,
222,
523,
82,
100,
2734,
100,
14838,
299,
5473,
222,
523,
82,
100,
22427,
100,
14838,
299,
28333,
222,
... | [
"#",
"Ġ-*-",
"Ġcoding",
":",
"ascii",
"Ġ-*-",
"Ċ",
"from",
"Ġm",
"ako",
"Ġimport",
"Ġruntime",
",",
"Ġfilters",
",",
"Ġcache",
"Ċ",
"Ċ",
"UNDEFINED",
"Ġ=",
"Ġruntime",
".",
"UNDEFINED",
"Ċ",
"__",
"M",
"_",
"dict",
"_",
"builtin",
"Ġ=",
"Ġdict",
"Ċ",
... | [
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8... | [
1,
2,
6,
13,
14,
19,
23,
1,
5,
7,
10,
17,
25,
26,
34,
35,
41,
1,
1,
10,
12,
20,
21,
30,
1,
3,
4,
5,
9,
10,
17,
19,
24,
1,
3,
4,
5,
11,
12,
19,
21,
28,
1,
2,
7,
8,
14,
16,
17,
18,
19,
1,
2,
10,
11,
15,
17,... |
44d87f112ab60a202e4c8d64d7aec6f4f0d10578 | # coding: utf-8
import os
import factory
import datetime
from journalmanager import models
from django.contrib.auth.models import Group
from django.core.files.base import File
_HERE = os.path.dirname(os.path.abspath(__file__))
with open(os.path.join(_HERE, "xml_samples", "0034-8910-rsp-48-2-0216.xml")) as xml_fil... | [
40,
10633,
63,
6471,
50,
61,
222,
485,
2355,
222,
222,
485,
7769,
222,
485,
7181,
222,
222,
1097,
16364,
4031,
1220,
4590,
222,
1097,
8532,
51,
12060,
51,
2408,
51,
3404,
1220,
7072,
222,
1097,
8532,
51,
1284,
51,
2558,
51,
1460,
... | [
"#",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ċ",
"import",
"Ġos",
"Ċ",
"Ċ",
"import",
"Ġfactory",
"Ċ",
"import",
"Ġdatetime",
"Ċ",
"Ċ",
"from",
"Ġjournal",
"manager",
"Ġimport",
"Ġmodels",
"Ċ",
"from",
"Ġdjango",
".",
"contrib",
".",
"auth",
".",
"models",
... | [
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
3,
4,
4,
4,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
11,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12... | [
1,
2,
9,
10,
14,
15,
16,
1,
7,
10,
1,
1,
7,
15,
1,
7,
16,
1,
1,
5,
13,
20,
27,
34,
1,
5,
12,
13,
20,
21,
25,
26,
32,
39,
45,
1,
5,
12,
13,
17,
18,
23,
24,
28,
35,
40,
1,
1,
2,
6,
8,
11,
12,
16,
17,
24,
25... |
81dfdf0479fc1f136fa5153840d8c7015f9db676 | # required !!!
# pip install selenium
# pip install webdriver-manager
from theMachine import loops
# fill the number and message
# you can fill the number with array
phoneNumber = "fill the number"
message = "fill with ur message"
loop = 1 # this how many u want to loop
loops(loop, phoneNumber, message) # input ho... | [
40,
2147,
33017,
222,
40,
10815,
2462,
35822,
222,
40,
10815,
2462,
48594,
50,
4031,
222,
222,
1097,
341,
7105,
1220,
23847,
222,
222,
40,
5342,
341,
1470,
480,
1492,
222,
40,
863,
902,
5342,
341,
1470,
642,
1437,
222,
29860,
299,
3... | [
"#",
"Ġrequired",
"Ġ!!!",
"Ċ",
"#",
"Ġpip",
"Ġinstall",
"Ġselenium",
"Ċ",
"#",
"Ġpip",
"Ġinstall",
"Ġwebdriver",
"-",
"manager",
"Ċ",
"Ċ",
"from",
"Ġthe",
"Machine",
"Ġimport",
"Ġloops",
"Ċ",
"Ċ",
"#",
"Ġfill",
"Ġthe",
"Ġnumber",
"Ġand",
"Ġmessage",
"Ċ",
... | [
1,
1,
1,
1,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
11,
11,
11,
11,
... | [
1,
2,
11,
15,
1,
2,
6,
14,
23,
1,
2,
6,
14,
24,
25,
32,
1,
1,
5,
9,
16,
23,
29,
1,
1,
2,
7,
11,
18,
22,
30,
1,
2,
6,
10,
15,
19,
26,
31,
37,
1,
12,
14,
16,
20,
24,
31,
32,
1,
8,
10,
12,
16,
21,
24,
32,
33... |
24de4f486d4e976850e94a003f8d9cbe3e518402 | a = input("Enter number")
a = a.split()
b = []
for x in a:
b.append(int(x))
print(b)
l = len(b)
c = 0
s = 0
for i in range(l):
s = len(b[:i])
for j in range(s):
if b[s] < b[j]:
c = b[s]
b.pop(s)
b.insert(b.index(b[j]), c)
print(b, b[:i], b[s])
| [
102,
299,
1533,
459,
6559,
1470,
678,
222,
102,
299,
331,
51,
3045,
365,
222,
103,
299,
1627,
222,
999,
837,
347,
331,
63,
303,
342,
51,
1713,
45,
429,
45,
125,
509,
222,
222,
1243,
45,
103,
46,
222,
113,
299,
2095,
45,
103,
4... | [
"a",
"Ġ=",
"Ġinput",
"(\"",
"Enter",
"Ġnumber",
"\")",
"Ċ",
"a",
"Ġ=",
"Ġa",
".",
"split",
"()",
"Ċ",
"b",
"Ġ=",
"Ġ[]",
"Ċ",
"for",
"Ġx",
"Ġin",
"Ġa",
":",
"ĊĠĠĠ",
"Ġb",
".",
"append",
"(",
"int",
"(",
"x",
"))",
"Ċ",
"Ċ",
"print",
"(",
"b",
... | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
11,
11,
11,
11,
11... | [
1,
2,
4,
10,
12,
17,
24,
26,
1,
2,
4,
6,
7,
12,
14,
1,
2,
4,
7,
1,
4,
6,
9,
11,
12,
4,
6,
7,
13,
14,
17,
18,
19,
21,
1,
1,
6,
7,
8,
9,
1,
2,
4,
8,
9,
10,
11,
1,
2,
4,
5,
6,
1,
2,
4,
5,
6,
1,
4,
6,
... |
a98be930058269a6adbc9a28d1c0ad5d9abba136 | import sys
import time
import pymorphy2
import pyglet
import pyttsx3
import threading
import warnings
import pytils
warnings.filterwarnings("ignore")
""" Количество раундов, вдохов в раунде, задержка дыхания на вдохе"""
rounds, breaths, hold = 4, 30, 13
def play_wav(src):
wav = pyglet.media.load(sys.path[0] + "... | [
485,
5263,
222,
485,
1153,
222,
485,
317,
2225,
9239,
126,
55,
222,
485,
3643,
108,
749,
222,
485,
3643,
121,
26883,
56,
222,
485,
26311,
222,
485,
11740,
222,
485,
3643,
1574,
120,
222,
222,
20340,
51,
2049,
20340,
459,
3634,
678,
... | [
"import",
"Ġsys",
"Ċ",
"import",
"Ġtime",
"Ċ",
"import",
"Ġp",
"ym",
"orph",
"y",
"2",
"Ċ",
"import",
"Ġpy",
"g",
"let",
"Ċ",
"import",
"Ġpy",
"t",
"tsx",
"3",
"Ċ",
"import",
"Ġthreading",
"Ċ",
"import",
"Ġwarnings",
"Ċ",
"import",
"Ġpy",
"til",
"s",... | [
1,
1,
1,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
6,
6,
6,
7,
7,
7,
8,
8,
8,
8,
8,
9,
10,
10,
10,
10,
10,
10,
10,
10,
11,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
... | [
1,
7,
11,
1,
7,
12,
1,
7,
9,
11,
15,
16,
17,
1,
7,
10,
11,
14,
1,
7,
10,
11,
14,
15,
1,
7,
17,
1,
7,
16,
1,
7,
10,
13,
14,
1,
1,
9,
10,
16,
24,
26,
32,
34,
1,
1,
4,
6,
8,
10,
15,
17,
18,
20,
21,
23,
24,
... |
4f0933c58aa1d41faf4f949d9684c04f9e01b473 | from os.path import exists
from_file = input("form_file")
to_file = input("to_file")
print(f"copying from {from_file} to {to_file}")
indata = open(from_file).read() # 这种方式读取文件后无需close
print(f"the input file is {len(indata)} bytes long")
print(f"does the output file exist? {exists(to_file)}")
print("return to contin... | [
1097,
2355,
51,
1005,
1220,
5394,
222,
222,
1097,
100,
781,
299,
1533,
459,
618,
100,
781,
678,
222,
471,
100,
781,
299,
1533,
459,
471,
100,
781,
678,
222,
222,
1243,
45,
107,
39,
47496,
664,
320,
1097,
100,
781,
130,
391,
320,
... | [
"from",
"Ġos",
".",
"path",
"Ġimport",
"Ġexists",
"Ċ",
"Ċ",
"from",
"_",
"file",
"Ġ=",
"Ġinput",
"(\"",
"form",
"_",
"file",
"\")",
"Ċ",
"to",
"_",
"file",
"Ġ=",
"Ġinput",
"(\"",
"to",
"_",
"file",
"\")",
"Ċ",
"Ċ",
"print",
"(",
"f",
"\"",
"copyi... | [
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
5,
8,
9,
13,
20,
27,
1,
1,
5,
6,
10,
12,
18,
20,
24,
25,
29,
31,
1,
3,
4,
8,
10,
16,
18,
20,
21,
25,
27,
1,
1,
6,
7,
8,
9,
16,
21,
23,
27,
28,
32,
33,
36,
38,
40,
41,
45,
48,
1,
4,
7,
9,
14,
15,
19,
20... |
5c81ddbc8f5a162949a100dbef1c69551d9e267a | # -*- coding: utf-8 -*-
from django.test import TestCase
from django.contrib.auth.models import User
from ..models import Todo
class MyTestCase(TestCase):
def test_mark_done(self):
user = User.objects.create_user(email="user@…", username="user", password="somepasswd")
todo = Todo(title="SomeTitle... | [
40,
8571,
10633,
63,
6471,
50,
61,
8571,
222,
222,
1097,
8532,
51,
881,
1220,
19189,
222,
1097,
8532,
51,
12060,
51,
2408,
51,
3404,
1220,
2694,
222,
1097,
4390,
3404,
1220,
24160,
499,
222,
842,
4318,
7246,
45,
7246,
731,
303,
684,... | [
"#",
"Ġ-*-",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ġ-*-",
"Ċ",
"Ċ",
"from",
"Ġdjango",
".",
"test",
"Ġimport",
"ĠTestCase",
"Ċ",
"from",
"Ġdjango",
".",
"contrib",
".",
"auth",
".",
"models",
"Ġimport",
"ĠUser",
"Ċ",
"from",
"Ġ..",
"models",
"Ġimport",
"Ġ... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
7,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10... | [
1,
2,
6,
13,
14,
18,
19,
20,
24,
1,
1,
5,
12,
13,
17,
24,
33,
1,
5,
12,
13,
20,
21,
25,
26,
32,
39,
44,
1,
5,
8,
14,
21,
26,
1,
1,
6,
9,
17,
18,
26,
28,
4,
8,
13,
14,
18,
19,
23,
24,
28,
30,
8,
13,
15,
20,
... |
509129052f97bb32b4ba0e71ecd7b1061d5f8da2 | print(180 / 4)
| [
1243,
45,
54,
61,
53,
536,
244,
57,
46,
222
] | [
"print",
"(",
"1",
"8",
"0",
"Ġ/",
"Ġ",
"4",
")",
"Ċ"
] | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | [
1,
6,
7,
8,
9,
10,
12,
13,
14,
15
] |
2c90c4e0b42a75d6d387b9b2d0118d8e991b5a08 | import math
import decimal
from typing import Union, List, Set
from sqlalchemy import text
from .model import BaseMixin
from ..core.db import db
Orders = List[Set(str, Union(str, int, decimal.Decimal))]
class BaseDBMgr:
def get_page(
self, cls_: BaseMixin, filters: set, orders: Orders = list(), field:... | [
485,
7820,
222,
485,
10262,
222,
1097,
12018,
1220,
16546,
49,
1701,
49,
1776,
222,
222,
1097,
30936,
1220,
1367,
222,
222,
1097,
657,
1184,
1220,
3787,
13983,
222,
1097,
4390,
1284,
51,
1219,
1220,
3100,
499,
222,
15939,
299,
1701,
9... | [
"import",
"Ġmath",
"Ċ",
"import",
"Ġdecimal",
"Ċ",
"from",
"Ġtyping",
"Ġimport",
"ĠUnion",
",",
"ĠList",
",",
"ĠSet",
"Ċ",
"Ċ",
"from",
"Ġsqlalchemy",
"Ġimport",
"Ġtext",
"Ċ",
"Ċ",
"from",
"Ġ.",
"model",
"Ġimport",
"ĠBase",
"Mixin",
"Ċ",
"from",
"Ġ..",
"... | [
1,
1,
1,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
10,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
13,
14,
... | [
1,
7,
12,
1,
7,
15,
1,
5,
12,
19,
25,
26,
31,
32,
36,
1,
1,
5,
16,
23,
28,
1,
1,
5,
7,
12,
19,
24,
29,
1,
5,
8,
12,
13,
15,
22,
25,
1,
1,
7,
9,
14,
15,
18,
19,
22,
23,
29,
30,
33,
34,
38,
39,
47,
48,
55,
... |
cb2e800cc2802031847b170a462778e5c0b3c6f9 | from math import *
from numpy import *
from random import *
import numpy as np
import matplotlib.pyplot as plt
from colorama import Fore, Back, Style
from gridworld import q_to_arrow
N_ROWS = 6
N_COLUMNS = 10
class State(object):
def __init__(self, i, j, is_cliff=False, is_goal=False):
self.i = i
... | [
1097,
7820,
1220,
338,
222,
1097,
6610,
1220,
338,
222,
1097,
4051,
1220,
338,
222,
485,
6610,
641,
2115,
222,
485,
13168,
51,
18553,
641,
6020,
222,
1097,
1989,
4497,
1220,
16829,
49,
7607,
49,
11643,
222,
1097,
5145,
5879,
1220,
270... | [
"from",
"Ġmath",
"Ġimport",
"Ġ*",
"Ċ",
"from",
"Ġnumpy",
"Ġimport",
"Ġ*",
"Ċ",
"from",
"Ġrandom",
"Ġimport",
"Ġ*",
"Ċ",
"import",
"Ġnumpy",
"Ġas",
"Ġnp",
"Ċ",
"import",
"Ġmatplotlib",
".",
"pyplot",
"Ġas",
"Ġplt",
"Ċ",
"from",
"Ġcolor",
"ama",
"Ġimport",
... | [
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
9,
10,
10,
10,
10,
10,
10,
10,
11,
11,
11,
11,
11,
11,
... | [
1,
5,
10,
17,
19,
1,
5,
11,
18,
20,
1,
5,
12,
19,
21,
1,
7,
13,
16,
19,
1,
7,
18,
19,
25,
28,
32,
1,
5,
11,
14,
21,
26,
27,
32,
33,
39,
1,
5,
10,
15,
22,
24,
25,
27,
28,
33,
1,
1,
2,
3,
7,
9,
10,
11,
1,
2... |
52da8608e43b2d8dfe00f0956a1187fcf2e7b1ff | # Generated by Django 2.2.6 on 2020-05-21 09:44
import datetime
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("DHOPD", "0015_auto_20200515_0126"),
]
operations = [
migrations.CreateModel(
name="Patient_c",
fields... | [
40,
13046,
829,
18288,
244,
55,
51,
55,
51,
59,
563,
244,
55,
53,
55,
53,
50,
53,
58,
50,
55,
54,
244,
53,
62,
63,
57,
57,
222,
222,
485,
7181,
222,
1097,
8532,
51,
1219,
1220,
12520,
49,
4590,
499,
222,
842,
18572,
45,
1977... | [
"#",
"ĠGenerated",
"Ġby",
"ĠDjango",
"Ġ",
"2",
".",
"2",
".",
"6",
"Ġon",
"Ġ",
"2",
"0",
"2",
"0",
"-",
"0",
"5",
"-",
"2",
"1",
"Ġ",
"0",
"9",
":",
"4",
"4",
"Ċ",
"Ċ",
"import",
"Ġdatetime",
"Ċ",
"from",
"Ġdjango",
".",
"db",
"Ġimport",
"Ġ... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
6,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9... | [
1,
2,
12,
15,
22,
23,
24,
25,
26,
27,
28,
31,
32,
33,
34,
35,
36,
37,
38,
39,
40,
41,
42,
43,
44,
45,
46,
47,
48,
1,
1,
7,
16,
1,
5,
12,
13,
15,
22,
33,
34,
41,
1,
1,
6,
16,
17,
27,
28,
37,
39,
4,
17,
19,
21,... |
1084478226777b9259274e053984ac34d461198d | from .ast import *
# noinspection PyPep8Naming
def addToClass(cls):
def decorator(func):
setattr(cls, func.__name__, func)
return func
return decorator
def print_intended(to_print, intend):
print(intend * "| " + to_print)
# noinspection PyPep8Naming,PyUnresolvedReferences
class TreeP... | [
1097,
657,
652,
1220,
338,
499,
222,
40,
1307,
28924,
4374,
40613,
61,
29450,
222,
610,
33625,
1359,
45,
6943,
731,
303,
684,
26643,
45,
1316,
731,
310,
39561,
45,
6943,
49,
3439,
3688,
444,
7652,
3439,
46,
310,
461,
3439,
465,
461,... | [
"from",
"Ġ.",
"ast",
"Ġimport",
"Ġ*",
"ĊĊ",
"Ċ",
"#",
"Ġno",
"inspection",
"ĠPy",
"Pep",
"8",
"Naming",
"Ċ",
"def",
"ĠaddTo",
"Class",
"(",
"cls",
"):",
"ĊĠĠĠ",
"Ġdef",
"Ġdecorator",
"(",
"func",
"):",
"ĊĠĠĠĠĠĠĠ",
"Ġsetattr",
"(",
"cls",
",",
"Ġfunc",
... | [
1,
1,
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
10,
10,
10,
12,
13,
13,
13,
13,
13,
13,
13,
13,
13,
13,
13,
13,
13,
14,
... | [
1,
5,
7,
10,
17,
19,
1,
1,
2,
5,
15,
18,
21,
22,
28,
1,
4,
10,
15,
16,
19,
21,
4,
8,
18,
19,
23,
25,
8,
16,
17,
20,
21,
26,
29,
33,
36,
41,
42,
8,
15,
20,
4,
11,
21,
1,
1,
4,
10,
11,
14,
19,
20,
22,
23,
28,... |
999de0965efa3c1fe021142a105dcf28184cd5ba | import dnf_converter
def parse(query):
print("parsing the query...")
query = dnf_converter.convert(query)
cp_clause_list = []
clause_list = []
for cp in query["$or"]:
clauses = []
if "$and" in cp:
for clause in cp["$and"]:
clauses.append(clause)
... | [
485,
362,
10843,
100,
13967,
499,
222,
610,
3203,
45,
1234,
731,
303,
1489,
459,
26778,
341,
2487,
21948,
303,
2487,
299,
362,
10843,
100,
13967,
51,
5975,
45,
1234,
46,
303,
9210,
100,
15161,
100,
687,
299,
1627,
303,
15309,
100,
6... | [
"import",
"Ġd",
"nf",
"_",
"converter",
"ĊĊ",
"Ċ",
"def",
"Ġparse",
"(",
"query",
"):",
"ĊĠĠĠ",
"Ġprint",
"(\"",
"parsing",
"Ġthe",
"Ġquery",
"...\")",
"ĊĠĠĠ",
"Ġquery",
"Ġ=",
"Ġd",
"nf",
"_",
"converter",
".",
"convert",
"(",
"query",
")",
"ĊĠĠĠ",
"Ġc... | [
1,
1,
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
11,
11,
11,
... | [
1,
7,
9,
11,
12,
21,
1,
1,
4,
10,
11,
16,
18,
4,
10,
12,
19,
23,
29,
34,
4,
10,
12,
14,
16,
17,
26,
27,
34,
35,
40,
41,
4,
7,
8,
14,
15,
19,
21,
24,
4,
11,
12,
16,
18,
21,
4,
8,
11,
14,
20,
22,
23,
25,
28,
... |
cb08f64d1ad7e53f1041684d4ca4ef65036c138d | import json
import re
from bs4 import BeautifulSoup
from bs4.element import NavigableString, Tag
from common import dir_path
def is_element(el, tag):
return isinstance(el, Tag) and el.name == tag
class ElemIterator:
def __init__(self, els):
self.els = els
self.i = 0
def peek(self):
... | [
485,
2379,
222,
485,
334,
222,
1097,
14270,
57,
1220,
39693,
222,
1097,
14270,
57,
51,
2559,
1220,
20568,
463,
671,
49,
9147,
222,
222,
1097,
4959,
1220,
4937,
100,
1005,
499,
222,
610,
458,
100,
2559,
45,
361,
49,
2621,
731,
303,
... | [
"import",
"Ġjson",
"Ċ",
"import",
"Ġre",
"Ċ",
"from",
"Ġbs",
"4",
"Ġimport",
"ĠBeautifulSoup",
"Ċ",
"from",
"Ġbs",
"4",
".",
"element",
"Ġimport",
"ĠNavig",
"able",
"String",
",",
"ĠTag",
"Ċ",
"Ċ",
"from",
"Ġcommon",
"Ġimport",
"Ġdir",
"_",
"path",
"ĊĊ",... | [
1,
1,
1,
2,
2,
2,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
12,
13,
13,
... | [
1,
7,
12,
1,
7,
10,
1,
5,
8,
9,
16,
30,
1,
5,
8,
9,
10,
17,
24,
30,
34,
40,
41,
45,
1,
1,
5,
12,
19,
23,
24,
28,
1,
1,
4,
7,
8,
15,
16,
18,
19,
23,
25,
4,
11,
22,
23,
25,
26,
30,
31,
35,
38,
39,
43,
46,
5... |
5082182af5a08970568dc1ab7a53ee5337260687 | #
# romaO
# www.fabiocrameri.ch/colourmaps
from matplotlib.colors import LinearSegmentedColormap
cm_data = [
[0.45137, 0.22346, 0.34187],
[0.45418, 0.22244, 0.3361],
[0.45696, 0.22158, 0.33043],
[0.45975, 0.2209, 0.32483],
[0.46251, 0.22035, 0.31935],
[0.46527, 0.21994... | [
40,
222,
40,
282,
26027,
102,
84,
222,
40,
6031,
19955,
51,
107,
14564,
561,
4344,
19465,
51,
399,
52,
21740,
8222,
222,
1097,
13168,
51,
8803,
1220,
14138,
7719,
337,
889,
29311,
222,
222,
4112,
100,
624,
299,
447,
303,
447,
53,
... | [
"#",
"Ċ",
"#",
"ĠĠĠĠĠĠĠĠ",
"Ġrom",
"a",
"O",
"Ċ",
"#",
"ĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ",
"Ġwww",
".",
"f",
"abi",
"oc",
"ram",
"eri",
".",
"ch",
"/",
"colour",
"maps",
"Ċ",
"from",
"Ġmatplotlib",
".",
"colors",
"Ġimport",
"ĠLinear",
"Segment",
"ed",
"Col",
"ormap"... | [
1,
1,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
2,
1,
2,
10,
14,
15,
16,
1,
2,
20,
24,
25,
26,
29,
31,
34,
37,
38,
40,
41,
47,
51,
1,
5,
16,
17,
23,
30,
37,
44,
46,
49,
54,
1,
1,
3,
4,
8,
10,
12,
4,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
19,
... |
3dd4b4d4241e588cf44230891f496bafb30c6153 | import requests
import json
import pandas as pd
n1 = "ADS"
api_url = "https://www.quandl.com/api/v3/datasets/WIKI/%s.csv" % n1
df = pd.read_csv(api_url)
df = df.head(100)
print(df.head())
# print(list(data))
| [
485,
5188,
222,
485,
2379,
222,
485,
13247,
641,
6451,
222,
222,
115,
54,
299,
332,
21856,
39,
222,
1256,
100,
983,
299,
332,
662,
574,
1516,
51,
467,
382,
113,
51,
527,
52,
1256,
52,
123,
56,
52,
15461,
52,
6620,
27716,
9731,
1... | [
"import",
"Ġrequests",
"Ċ",
"import",
"Ġjson",
"Ċ",
"import",
"Ġpandas",
"Ġas",
"Ġpd",
"Ċ",
"Ċ",
"n",
"1",
"Ġ=",
"Ġ\"",
"ADS",
"\"",
"Ċ",
"api",
"_",
"url",
"Ġ=",
"Ġ\"",
"https",
"://",
"www",
".",
"qu",
"and",
"l",
".",
"com",
"/",
"api",
"/",
... | [
1,
1,
1,
2,
2,
2,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
7,
16,
1,
7,
12,
1,
7,
14,
17,
20,
1,
1,
2,
3,
5,
7,
10,
11,
1,
4,
5,
8,
10,
12,
17,
20,
23,
24,
26,
29,
30,
31,
34,
35,
38,
39,
40,
41,
42,
50,
51,
53,
55,
57,
58,
59,
62,
63,
65,
67,
68,
1,
3,
5,
8,
... |
a558b42106b036719fe38ee6efd1c5b933290f52 | #!/usr/local/bin/python
# -*- coding: utf-8 -*-
from sqlalchemy import select, update
from sqlalchemy import Table, Column, String, Integer, Float, Boolean, Date, BigInteger
from sqlalchemy import create_engine, MetaData
import API_and_Database_function as func
import pandas as pd
import re
connection, Twitter_Senti... | [
8758,
3392,
52,
1717,
52,
1793,
52,
2980,
222,
40,
8571,
10633,
63,
6471,
50,
61,
8571,
222,
222,
1097,
30936,
1220,
2209,
49,
1991,
222,
1097,
30936,
1220,
5565,
49,
7747,
49,
910,
49,
4418,
49,
8182,
49,
5080,
49,
2833,
49,
2172... | [
"#!/",
"usr",
"/",
"local",
"/",
"bin",
"/",
"python",
"Ċ",
"#",
"Ġ-*-",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ġ-*-",
"Ċ",
"Ċ",
"from",
"Ġsqlalchemy",
"Ġimport",
"Ġselect",
",",
"Ġupdate",
"Ċ",
"from",
"Ġsqlalchemy",
"Ġimport",
"ĠTable",
",",
"ĠColumn",
"... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
4,
7,
8,
13,
14,
17,
18,
24,
1,
2,
6,
13,
14,
18,
19,
20,
24,
1,
1,
5,
16,
23,
30,
31,
38,
1,
5,
16,
23,
29,
30,
37,
38,
45,
46,
54,
55,
61,
62,
70,
71,
76,
77,
88,
1,
5,
16,
23,
30,
31,
37,
38,
43,
47,
... |
10d35ba3c04d9cd09e152c575e74b0382ff60572 | from pydispatch import dispatcher
import time
import serial
import threading
from queue import Queue
PORT = "/dev/ttys005"
# PORT='/dev/tty.usbmodem1461'
SPEED = 4800.0
class GcodeSender(object):
PEN_LIFT_PULSE = 1500
PEN_DROP_PULSE = 800
def __init__(self, **kwargs):
super(GcodeSender, self).__... | [
1097,
3643,
7154,
1220,
26598,
222,
485,
1153,
222,
485,
4569,
222,
485,
26311,
222,
1097,
5535,
1220,
14317,
222,
222,
3640,
299,
2450,
1920,
52,
8384,
120,
53,
53,
58,
39,
222,
40,
15869,
20190,
1920,
52,
8384,
51,
13092,
2832,
11... | [
"from",
"Ġpy",
"dispatch",
"Ġimport",
"Ġdispatcher",
"Ċ",
"import",
"Ġtime",
"Ċ",
"import",
"Ġserial",
"Ċ",
"import",
"Ġthreading",
"Ċ",
"from",
"Ġqueue",
"Ġimport",
"ĠQueue",
"Ċ",
"Ċ",
"PORT",
"Ġ=",
"Ġ\"/",
"dev",
"/",
"tty",
"s",
"0",
"0",
"5",
"\"",
... | [
1,
1,
1,
1,
1,
1,
2,
2,
2,
3,
3,
3,
4,
4,
4,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
11,
12,
12,
12,... | [
1,
5,
8,
16,
23,
34,
1,
7,
12,
1,
7,
14,
1,
7,
17,
1,
5,
11,
18,
24,
1,
1,
5,
7,
10,
13,
14,
17,
18,
19,
20,
21,
22,
1,
2,
7,
10,
13,
14,
17,
18,
21,
25,
26,
27,
28,
29,
30,
31,
1,
6,
8,
9,
10,
11,
12,
13... |
e1d0648825695584d3ea518db961a9178ea0c66a | import requests
import sxtwl
import datetime
from datetime import date
import lxml
from lxml import etree
# 日历中文索引
ymc = ["十一", "十二", "正", "二", "三", "四", "五", "六", "七", "八", "九", "十"]
rmc = [
"初一",
"初二",
"初三",
"初四",
"初五",
"初六",
"初七",
"初八",
"初九",
"初十",
"十一",
"十二",
"十三... | [
485,
5188,
222,
485,
23516,
4176,
113,
222,
485,
7181,
222,
1097,
7181,
1220,
2361,
222,
485,
475,
2608,
222,
1097,
475,
2608,
1220,
2990,
993,
222,
222,
40,
244,
6640,
18861,
35977,
21653,
222,
2225,
104,
299,
3059,
14190,
2288,
411,... | [
"import",
"Ġrequests",
"Ċ",
"import",
"Ġsx",
"tw",
"l",
"Ċ",
"import",
"Ġdatetime",
"Ċ",
"from",
"Ġdatetime",
"Ġimport",
"Ġdate",
"Ċ",
"import",
"Ġl",
"xml",
"Ċ",
"from",
"Ġl",
"xml",
"Ġimport",
"Ġet",
"ree",
"Ċ",
"Ċ",
"#",
"Ġ",
"æĹ¥",
"åİĨ",
"ä¸Ńæĸĩ",... | [
1,
1,
1,
2,
2,
2,
2,
2,
3,
3,
3,
4,
4,
4,
4,
4,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
7,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9... | [
1,
7,
16,
1,
7,
10,
12,
13,
1,
7,
16,
1,
5,
14,
21,
26,
1,
7,
9,
12,
1,
5,
7,
10,
17,
20,
23,
1,
1,
2,
3,
4,
5,
7,
9,
1,
3,
4,
6,
9,
10,
11,
13,
15,
16,
17,
19,
21,
22,
24,
26,
27,
29,
31,
32,
34,
36,
3... |
2c39660da8fe839c4634cd73ce069acc7b1b29b4 | import time
# Decorator
def measure_time_of_func(func):
def wrapper_func(n):
start_time = time.time()
fib_seq = func(n)
end_time = time.time()
return (fib_seq, end_time - start_time)
return wrapper_func
# Returns a list with first n numbers of fibonacci sequence.
@measure_ti... | [
485,
1153,
499,
222,
40,
35910,
738,
222,
610,
9483,
100,
1021,
100,
1048,
100,
1316,
45,
1316,
731,
303,
684,
7780,
100,
1316,
45,
115,
731,
310,
1496,
100,
1021,
299,
1153,
51,
1021,
365,
310,
28319,
100,
4974,
299,
3439,
45,
11... | [
"import",
"Ġtime",
"ĊĊ",
"Ċ",
"#",
"ĠDecor",
"ator",
"Ċ",
"def",
"Ġmeasure",
"_",
"time",
"_",
"of",
"_",
"func",
"(",
"func",
"):",
"ĊĠĠĠ",
"Ġdef",
"Ġwrapper",
"_",
"func",
"(",
"n",
"):",
"ĊĠĠĠĠĠĠĠ",
"Ġstart",
"_",
"time",
"Ġ=",
"Ġtime",
".",
"ti... | [
1,
1,
1,
3,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
... | [
1,
7,
12,
1,
1,
2,
8,
12,
1,
4,
12,
13,
17,
18,
20,
21,
25,
26,
30,
32,
4,
8,
16,
17,
21,
22,
23,
25,
8,
14,
15,
19,
21,
26,
27,
31,
33,
8,
12,
13,
16,
18,
23,
24,
25,
26,
8,
12,
13,
17,
19,
24,
25,
29,
31,
... |
c87e6f8780bf8d9097f200c7f2f0faf55beb480c | # 1
def transform_data(fn):
print(fn(10))
# 2
transform_data(lambda data: data / 5)
# 3
def transform_data2(fn, *args):
for arg in args:
print(fn(arg))
transform_data2(lambda data: data / 5, 10, 15, 22, 30)
# 4
def transform_data2(fn, *args):
for arg in args:
print("Result: {:^20.2f}... | [
40,
244,
54,
222,
610,
4549,
100,
624,
45,
3379,
731,
303,
1489,
45,
3379,
45,
54,
53,
509,
499,
222,
40,
244,
55,
222,
3824,
100,
624,
45,
6034,
727,
63,
727,
536,
244,
58,
46,
499,
222,
40,
244,
56,
222,
610,
4549,
100,
62... | [
"#",
"Ġ",
"1",
"Ċ",
"def",
"Ġtransform",
"_",
"data",
"(",
"fn",
"):",
"ĊĠĠĠ",
"Ġprint",
"(",
"fn",
"(",
"1",
"0",
"))",
"ĊĊ",
"Ċ",
"#",
"Ġ",
"2",
"Ċ",
"transform",
"_",
"data",
"(",
"lambda",
"Ġdata",
":",
"Ġdata",
"Ġ/",
"Ġ",
"5",
")",
"ĊĊ",... | [
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
5,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
9,
10,
10,
10,
10,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
12,
12,
12,
12,
1... | [
1,
2,
3,
4,
1,
4,
14,
15,
19,
20,
22,
24,
4,
10,
11,
13,
14,
15,
16,
18,
1,
1,
2,
3,
4,
1,
10,
11,
15,
16,
22,
27,
28,
33,
35,
36,
37,
38,
1,
1,
2,
3,
4,
1,
4,
14,
15,
19,
20,
21,
23,
24,
26,
30,
32,
4,
8... |
f4f08015b7638f4d6ea793350d5d19a3485978cd | """Plot the output data."""
# Standard library
import os
import json
import math
import matplotlib as maplot
import matplotlib.pyplot as pyplot
from datetime import datetime
# User library
from sub.inputprocess import CONSTANTS as CONS
# **json.loads(json_data)
def get_data():
"""Read output file to get data.""... | [
3012,
11756,
341,
1716,
727,
7128,
222,
222,
40,
9312,
4277,
222,
485,
2355,
222,
485,
2379,
222,
485,
7820,
222,
485,
13168,
641,
2010,
2537,
222,
485,
13168,
51,
18553,
641,
3643,
3570,
222,
1097,
7181,
1220,
7181,
222,
222,
40,
2... | [
"\"\"\"",
"Plot",
"Ġthe",
"Ġoutput",
"Ġdata",
".\"\"\"",
"Ċ",
"Ċ",
"#",
"ĠStandard",
"Ġlibrary",
"Ċ",
"import",
"Ġos",
"Ċ",
"import",
"Ġjson",
"Ċ",
"import",
"Ġmath",
"Ċ",
"import",
"Ġmatplotlib",
"Ġas",
"Ġmap",
"lot",
"Ċ",
"import",
"Ġmatplotlib",
".",
"p... | [
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
4,
4,
4,
5,
5,
5,
6,
6,
6,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
10,
11,
11,
11,
11,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
14,
15,
15,
15... | [
1,
4,
8,
12,
19,
24,
28,
1,
1,
2,
11,
19,
1,
7,
10,
1,
7,
12,
1,
7,
12,
1,
7,
18,
21,
25,
28,
1,
7,
18,
19,
25,
28,
31,
35,
1,
5,
14,
21,
30,
1,
1,
2,
7,
15,
1,
5,
9,
10,
15,
22,
29,
38,
39,
42,
47,
1,
... |
d2a153fffccd4b681eebce823e641e195197cde7 | """
Created on 02.09.2013
@author: Paul Schweizer
@email: paulschweizer@gmx.net
@brief: Holds all the namingconventions for pandora's box
"""
import os
import json
class NamingConvention:
"""Imports naming conventions from the respective .json file and puts them
into class variables.
"""
def __init_... | [
3012,
222,
6880,
563,
244,
53,
55,
51,
53,
62,
51,
55,
53,
54,
56,
222,
69,
2133,
63,
30498,
10469,
1399,
2292,
222,
69,
1951,
63,
9236,
357,
6387,
1399,
2292,
69,
108,
7796,
51,
1317,
222,
69,
5313,
63,
27005,
120,
1187,
341,
... | [
"\"\"\"",
"Ċ",
"Created",
"Ġon",
"Ġ",
"0",
"2",
".",
"0",
"9",
".",
"2",
"0",
"1",
"3",
"Ċ",
"@",
"author",
":",
"ĠPaul",
"ĠSch",
"we",
"izer",
"Ċ",
"@",
"email",
":",
"Ġpa",
"ul",
"sch",
"we",
"izer",
"@",
"g",
"mx",
".",
"net",
"Ċ",
"@",
... | [
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
7,
8,
8,
8,
9,
9,
9... | [
1,
4,
1,
8,
11,
12,
13,
14,
15,
16,
17,
18,
19,
20,
21,
22,
1,
2,
8,
9,
14,
18,
20,
24,
1,
2,
7,
8,
11,
13,
16,
18,
22,
23,
24,
26,
27,
30,
1,
2,
7,
8,
13,
14,
18,
22,
29,
32,
40,
44,
46,
49,
52,
54,
58,
1,... |
aff1d702e591efcfc0fc93150a3fbec532408137 | from rest_framework import serializers, viewsets, routers
from lamp_control.models import Lamp
class LampSerializer(serializers.HyperlinkedModelSerializer):
class Meta:
model = Lamp
fields = "__all__"
class LampViewSet(viewsets.ModelViewSet):
serializer_class = LampSerializer
queryset =... | [
1097,
6125,
100,
2863,
1220,
34229,
49,
2221,
2047,
49,
18669,
502,
222,
222,
1097,
475,
778,
100,
2452,
51,
3404,
1220,
517,
778,
499,
222,
842,
517,
778,
7271,
45,
34191,
51,
20576,
11137,
1262,
7271,
731,
303,
462,
11990,
63,
310... | [
"from",
"Ġrest",
"_",
"framework",
"Ġimport",
"Ġserializers",
",",
"Ġview",
"sets",
",",
"Ġrout",
"ers",
"Ċ",
"Ċ",
"from",
"Ġl",
"amp",
"_",
"control",
".",
"models",
"Ġimport",
"ĠL",
"amp",
"ĊĊ",
"Ċ",
"class",
"ĠL",
"amp",
"Serializer",
"(",
"serializer... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
11,
12,
12,
12,
12,
12,
12,
... | [
1,
5,
10,
11,
20,
27,
39,
40,
45,
49,
50,
55,
58,
1,
1,
5,
7,
10,
11,
18,
19,
25,
32,
34,
37,
1,
1,
6,
8,
11,
21,
22,
33,
34,
39,
45,
50,
60,
62,
4,
10,
15,
16,
8,
14,
16,
18,
21,
8,
15,
17,
21,
24,
26,
27,
... |
c6502ea2b32ad90c76b6dfaf3ee3218d029eba15 | class NlpUtility:
"""
Utility methods to get particular parts of speech from a token set
"""
def get_nouns(self, tokens):
nouns = []
for word, pos in tokens:
if pos == "NN":
nouns.push(word)
def get_verbs(self, tokens):
verbs = []
for wor... | [
842,
508,
1935,
11328,
63,
303,
1547,
303,
23194,
4457,
391,
640,
8445,
8740,
451,
24962,
664,
331,
2421,
758,
303,
1547,
465,
684,
640,
100,
1365,
16349,
45,
803,
49,
7960,
731,
310,
1307,
16349,
299,
1627,
310,
456,
3619,
49,
3423... | [
"class",
"ĠN",
"lp",
"Utility",
":",
"ĊĠĠĠ",
"Ġ\"\"\"",
"ĊĠĠĠ",
"ĠUtility",
"Ġmethods",
"Ġto",
"Ġget",
"Ġparticular",
"Ġparts",
"Ġof",
"Ġspeech",
"Ġfrom",
"Ġa",
"Ġtoken",
"Ġset",
"ĊĠĠĠ",
"Ġ\"\"\"",
"ĊĊĠĠĠ",
"Ġdef",
"Ġget",
"_",
"no",
"uns",
"(",
"self",
",... | [
1,
1,
1,
1,
1,
1,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
10,
... | [
1,
6,
8,
10,
17,
18,
4,
8,
4,
12,
20,
23,
27,
38,
44,
47,
54,
59,
61,
67,
71,
4,
8,
4,
8,
12,
13,
15,
18,
19,
23,
24,
31,
33,
8,
11,
14,
16,
19,
8,
12,
17,
18,
22,
25,
32,
33,
12,
15,
19,
22,
24,
26,
28,
16,
... |
675fbdfd519d00ab10bf613e8abb7338e484fe65 | import logging
formatter = logging.Formatter("%(asctime)s [%(levelname)s] : %(message)s")
log = logging.getLogger("othello")
log.setLevel(logging.DEBUG)
stream_hander = logging.StreamHandler()
stream_hander.setFormatter(formatter)
log.addHandler(stream_hander)
| [
485,
5751,
499,
222,
14565,
299,
5751,
51,
8748,
4923,
45,
321,
27760,
46,
120,
244,
18010,
45,
2675,
444,
46,
120,
98,
518,
18207,
1454,
46,
120,
678,
222,
222,
769,
299,
5751,
51,
10588,
459,
385,
7670,
678,
222,
769,
51,
34360,... | [
"import",
"Ġlogging",
"ĊĊ",
"Ċ",
"formatter",
"Ġ=",
"Ġlogging",
".",
"Formatter",
"(\"%",
"(",
"as",
"ctime",
")",
"s",
"Ġ",
"Ġ[%",
"(",
"level",
"name",
")",
"s",
"]",
"Ġ:",
"Ġ%(",
"message",
")",
"s",
"\")",
"Ċ",
"Ċ",
"log",
"Ġ=",
"Ġlogging",
"."... | [
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
... | [
1,
7,
15,
1,
1,
10,
12,
20,
21,
30,
33,
34,
36,
41,
42,
43,
44,
47,
48,
53,
57,
58,
59,
60,
62,
65,
72,
73,
74,
76,
1,
1,
4,
6,
14,
15,
24,
26,
28,
33,
35,
1,
4,
5,
13,
14,
21,
22,
27,
28,
1,
1,
7,
8,
12,
1... |
d7b45e76f150107cd62be160e8938f17dad90623 | import pandas as pd
from sqlalchemy import create_engine
# file = 'testfile.csv'
# print(pd.read_csv(file, nrows=5))
with open("testfile_short1.csv", "r") as original:
data = original.read()
for i in range(2):
with open("testfile_short3.csv", "a") as modified:
modified.write(data)
| [
485,
13247,
641,
6451,
222,
1097,
30936,
1220,
1506,
100,
3502,
222,
40,
822,
299,
349,
881,
781,
51,
4849,
44,
222,
222,
40,
1489,
45,
7221,
51,
870,
100,
4849,
45,
781,
49,
329,
2158,
66,
58,
509,
222,
222,
1814,
2177,
459,
88... | [
"import",
"Ġpandas",
"Ġas",
"Ġpd",
"Ċ",
"from",
"Ġsqlalchemy",
"Ġimport",
"Ġcreate",
"_",
"engine",
"Ċ",
"#",
"Ġfile",
"Ġ=",
"Ġ'",
"test",
"file",
".",
"csv",
"'",
"Ċ",
"Ċ",
"#",
"Ġprint",
"(",
"pd",
".",
"read",
"_",
"csv",
"(",
"file",
",",
"Ġn",... | [
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8... | [
1,
7,
14,
17,
20,
1,
5,
16,
23,
30,
31,
37,
1,
2,
7,
9,
11,
15,
19,
20,
23,
24,
1,
1,
2,
8,
9,
11,
12,
16,
17,
20,
21,
25,
26,
28,
32,
33,
34,
36,
1,
1,
5,
10,
12,
16,
20,
21,
26,
27,
28,
31,
33,
35,
36,
38... |
61454a3d6b5b17bff871ededc6ddfe8384043884 | from pythongame.core.buff_effects import get_buff_effect, register_buff_effect, StatModifyingBuffEffect
from pythongame.core.common import ItemType, Sprite, BuffType, Millis, HeroStat
from pythongame.core.game_data import UiIconSprite, register_buff_text
from pythongame.core.game_state import Event, PlayerDamagedEnemy,... | [
1097,
3643,
368,
805,
340,
51,
1284,
51,
12811,
100,
16413,
1220,
640,
100,
12811,
100,
7483,
49,
3923,
100,
12811,
100,
7483,
49,
15207,
14498,
318,
20334,
5572,
222,
1097,
3643,
368,
805,
340,
51,
1284,
51,
2297,
1220,
6337,
638,
... | [
"from",
"Ġpy",
"th",
"ong",
"ame",
".",
"core",
".",
"buff",
"_",
"effects",
"Ġimport",
"Ġget",
"_",
"buff",
"_",
"effect",
",",
"Ġregister",
"_",
"buff",
"_",
"effect",
",",
"ĠStat",
"Modify",
"ing",
"Buff",
"Effect",
"Ċ",
"from",
"Ġpy",
"th",
"ong"... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3... | [
1,
5,
8,
10,
13,
16,
17,
21,
22,
26,
27,
34,
41,
45,
46,
50,
51,
57,
58,
67,
68,
72,
73,
79,
80,
85,
91,
94,
98,
104,
1,
5,
8,
10,
13,
16,
17,
21,
22,
28,
35,
40,
44,
45,
52,
53,
56,
58,
62,
63,
65,
70,
71,
76,... |
4c60fd123f591bf2a88ca0affe14a3c3ec0d3cf6 | from pyspark import SparkContext
from pyspark.sql import SQLContext
from pyspark.sql.types import *
sc = SparkContext("local", "weblog app")
effective_care = (
sc.textFile("file:///data/exercise1/effective_care").map(lambda l: l.encode().split(",")).map(lambda x: (x[0], x[1:]))
)
procedure_care = effective_care.m... | [
1097,
3643,
10256,
1220,
17311,
1237,
222,
1097,
3643,
10256,
51,
2622,
1220,
4447,
1237,
222,
1097,
3643,
10256,
51,
2622,
51,
2529,
1220,
338,
222,
222,
564,
299,
17311,
1237,
459,
1717,
411,
332,
1857,
769,
1142,
678,
222,
222,
271... | [
"from",
"Ġpy",
"spark",
"Ġimport",
"ĠSpark",
"Context",
"Ċ",
"from",
"Ġpy",
"spark",
".",
"sql",
"Ġimport",
"ĠSQL",
"Context",
"Ċ",
"from",
"Ġpy",
"spark",
".",
"sql",
".",
"types",
"Ġimport",
"Ġ*",
"Ċ",
"Ċ",
"sc",
"Ġ=",
"ĠSpark",
"Context",
"(\"",
"lo... | [
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8... | [
1,
5,
8,
13,
20,
26,
33,
1,
5,
8,
13,
14,
17,
24,
28,
35,
1,
5,
8,
13,
14,
17,
18,
23,
30,
32,
1,
1,
3,
5,
11,
18,
20,
25,
27,
29,
32,
35,
39,
41,
1,
1,
10,
11,
15,
17,
19,
4,
7,
8,
12,
16,
18,
22,
26,
30,
... |
5c30b0e952ddf2e05a7ad5f8d9bbd4f5e22f887d | # strspn(str1,str2)
str1 = "12345678"
str2 = "456"
# str1 and chars both in str1 and str2
print(str1 and str2)
str1 = "cekjgdklab"
str2 = "gka"
nPos = -1
for c in str1:
if c in str2:
nPos = str1.index(c)
break
print(nPos)
| [
40,
615,
40547,
45,
484,
54,
49,
484,
55,
46,
222,
484,
54,
299,
332,
54,
55,
56,
57,
58,
59,
60,
61,
39,
222,
484,
55,
299,
332,
57,
58,
59,
39,
222,
40,
615,
54,
480,
16668,
4354,
347,
615,
54,
480,
615,
55,
222,
1243,
... | [
"#",
"Ġstr",
"spn",
"(",
"str",
"1",
",",
"str",
"2",
")",
"Ċ",
"str",
"1",
"Ġ=",
"Ġ\"",
"1",
"2",
"3",
"4",
"5",
"6",
"7",
"8",
"\"",
"Ċ",
"str",
"2",
"Ġ=",
"Ġ\"",
"4",
"5",
"6",
"\"",
"Ċ",
"#",
"Ġstr",
"1",
"Ġand",
"Ġchars",
"Ġboth",
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
7... | [
1,
2,
6,
9,
10,
13,
14,
15,
18,
19,
20,
1,
4,
5,
7,
9,
10,
11,
12,
13,
14,
15,
16,
17,
18,
1,
4,
5,
7,
9,
10,
11,
12,
13,
1,
2,
6,
7,
11,
17,
22,
25,
29,
30,
34,
38,
39,
1,
6,
7,
10,
11,
15,
19,
20,
21,
1... |
a86b64ccd0dab4ab70ca9c2b7625fb34afec3794 | from django.contrib import admin
from django_summernote.admin import SummernoteModelAdmin
from .models import ArticlePost
# Register your models here.
class SomeModelAdmin(SummernoteModelAdmin): # instead of ModelAdmin
summernote_fields = "__all__"
admin.site.register(ArticlePost, SummernoteModelAdmin)
| [
1097,
8532,
51,
12060,
1220,
5611,
222,
1097,
8532,
100,
36540,
5774,
51,
2317,
1220,
10755,
2322,
5774,
1262,
4208,
222,
1097,
657,
3404,
1220,
20657,
3176,
222,
40,
7017,
1390,
4590,
2464,
51,
499,
222,
842,
4202,
1262,
4208,
45,
49... | [
"from",
"Ġdjango",
".",
"contrib",
"Ġimport",
"Ġadmin",
"Ċ",
"from",
"Ġdjango",
"_",
"summer",
"note",
".",
"admin",
"Ġimport",
"ĠSum",
"mer",
"note",
"Model",
"Admin",
"Ċ",
"from",
"Ġ.",
"models",
"Ġimport",
"ĠArticle",
"Post",
"Ċ",
"#",
"ĠRegister",
"Ġyo... | [
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8... | [
1,
5,
12,
13,
20,
27,
33,
1,
5,
12,
13,
19,
23,
24,
29,
36,
40,
43,
47,
52,
57,
1,
5,
7,
13,
20,
28,
32,
1,
2,
11,
16,
23,
28,
29,
1,
1,
6,
11,
16,
21,
22,
25,
28,
32,
37,
42,
44,
45,
47,
55,
58,
64,
69,
4,
... |
f17d33f1d035da42dc9a2b4c0c60beefc6a48dea | import functools
import shutil
import tempfile
import unittest
import unittest.mock
from pathlib import Path
import numpy as np
import pandas as pd
import one.alf.io as alfio
from ibllib.io.extractors import training_trials, biased_trials, camera
from ibllib.io import raw_data_loaders as raw
from ibllib.io.extractors... | [
485,
35383,
222,
485,
23074,
222,
485,
29651,
222,
485,
15790,
222,
485,
15790,
51,
3628,
222,
1097,
30293,
1220,
5404,
222,
222,
485,
6610,
641,
2115,
222,
485,
13247,
641,
6451,
222,
222,
485,
1611,
51,
5691,
51,
735,
641,
763,
10... | [
"import",
"Ġfunctools",
"Ċ",
"import",
"Ġshutil",
"Ċ",
"import",
"Ġtempfile",
"Ċ",
"import",
"Ġunittest",
"Ċ",
"import",
"Ġunittest",
".",
"mock",
"Ċ",
"from",
"Ġpathlib",
"Ġimport",
"ĠPath",
"Ċ",
"Ċ",
"import",
"Ġnumpy",
"Ġas",
"Ġnp",
"Ċ",
"import",
"Ġpanda... | [
1,
1,
1,
2,
2,
2,
3,
3,
3,
4,
4,
4,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
7,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
10,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
1... | [
1,
7,
17,
1,
7,
14,
1,
7,
16,
1,
7,
16,
1,
7,
16,
17,
21,
1,
5,
13,
20,
25,
1,
1,
7,
13,
16,
19,
1,
7,
14,
17,
20,
1,
1,
7,
11,
12,
15,
16,
18,
21,
24,
25,
27,
1,
5,
7,
9,
12,
13,
15,
16,
23,
26,
33,
42,
... |
767c0e6d956701fcedddb153b6c47f404dec535a | import boto3
class NetworkLookup:
def __init__(self):
self.loaded = 0
self.subnets = {}
self.vpcs = {}
def load(self):
if self.loaded:
return
client = boto3.client("ec2")
# load subnets
subnets_r = client.describe_subnets()
subnets_... | [
485,
36600,
56,
499,
222,
842,
8187,
10138,
63,
303,
684,
1176,
1683,
3232,
803,
731,
310,
649,
51,
5907,
299,
244,
53,
310,
649,
51,
19823,
120,
299,
2172,
310,
649,
51,
10743,
1766,
299,
2172,
465,
684,
2480,
45,
803,
731,
310,
... | [
"import",
"Ġboto",
"3",
"ĊĊ",
"Ċ",
"class",
"ĠNetwork",
"Lookup",
":",
"ĊĠĠĠ",
"Ġdef",
"Ġ__",
"init",
"__(",
"self",
"):",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
".",
"loaded",
"Ġ=",
"Ġ",
"0",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
".",
"subnet",
"s",
"Ġ=",
"Ġ{}",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
".... | [
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
10,
10,
10,
10,
10,
10,
11,
11,
11,
11,
11,
11,
12,
12,
14,
14,
14,
14,
14,
14,
14,
... | [
1,
7,
12,
13,
1,
1,
6,
14,
20,
21,
4,
8,
11,
15,
18,
22,
24,
8,
13,
14,
20,
22,
23,
24,
8,
13,
14,
20,
21,
23,
26,
8,
13,
14,
16,
18,
20,
23,
4,
8,
13,
14,
18,
20,
8,
11,
16,
17,
23,
24,
12,
19,
8,
15,
17,
... |
efcbe296ea72a94be967124a8ba8c84a524e2eb1 | __author__ = "AChen"
from rec_linked_list import *
def filter_pos_rec(lst):
"""
@type lst: LinkedListRec
>>> lst = LinkedListRec([3, -10, 4, 0])
>>> pos = filter_pos_rec(lst)
>>> str(pos)
'3 -> 4'
"""
if lst.is_empty():
return lst
else:
pos_rec = LinkedListRec([])... | [
523,
2133,
523,
299,
332,
70,
846,
291,
39,
222,
222,
1097,
8835,
100,
11137,
100,
687,
1220,
338,
499,
222,
610,
2785,
100,
985,
100,
4898,
45,
10015,
731,
303,
1547,
303,
496,
700,
20408,
63,
21057,
8347,
303,
8257,
20408,
299,
... | [
"__",
"author",
"__",
"Ġ=",
"Ġ\"",
"A",
"Ch",
"en",
"\"",
"Ċ",
"Ċ",
"from",
"Ġrec",
"_",
"linked",
"_",
"list",
"Ġimport",
"Ġ*",
"ĊĊ",
"Ċ",
"def",
"Ġfilter",
"_",
"pos",
"_",
"rec",
"(",
"lst",
"):",
"ĊĠĠĠ",
"Ġ\"\"\"",
"ĊĠĠĠ",
"Ġ@",
"type",
"Ġlst... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,... | [
1,
3,
9,
11,
13,
15,
16,
18,
20,
21,
1,
1,
5,
9,
10,
16,
17,
21,
28,
30,
1,
1,
4,
11,
12,
15,
16,
19,
20,
23,
25,
4,
8,
4,
6,
10,
14,
15,
26,
29,
4,
8,
12,
14,
25,
28,
30,
31,
32,
34,
35,
36,
37,
38,
39,
40... |
4789546128263bd298f8f5827734f8402747b9ac | from enum import Enum
from roll.input import Input
from roll.network import Server, Client
from assets.game_projects.fighter.src.game_properties import GameProperties
from assets.game_projects.fighter.src.network_message import NetworkMessage
class InputBuffer:
"""
Responsible for collecting game input from... | [
1097,
3858,
1220,
7827,
222,
222,
1097,
12356,
51,
1151,
1220,
4257,
222,
1097,
12356,
51,
4599,
1220,
4242,
49,
5680,
222,
222,
1097,
13638,
51,
3642,
100,
7327,
51,
36472,
284,
51,
1634,
51,
3642,
100,
4659,
1220,
6067,
3303,
222,
... | [
"from",
"Ġenum",
"Ġimport",
"ĠEnum",
"Ċ",
"Ċ",
"from",
"Ġroll",
".",
"input",
"Ġimport",
"ĠInput",
"Ċ",
"from",
"Ġroll",
".",
"network",
"Ġimport",
"ĠServer",
",",
"ĠClient",
"Ċ",
"Ċ",
"from",
"Ġassets",
".",
"game",
"_",
"projects",
".",
"fight",
"er",
... | [
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
9,
10,
... | [
1,
5,
10,
17,
22,
1,
1,
5,
10,
11,
16,
23,
29,
1,
5,
10,
11,
18,
25,
32,
33,
40,
1,
1,
5,
12,
13,
17,
18,
26,
27,
32,
34,
35,
38,
39,
43,
44,
54,
61,
66,
76,
1,
5,
12,
13,
17,
18,
26,
27,
32,
34,
35,
38,
39,
... |
b693cc63e2ee4c994ef7b5e44faea99f15a021f6 | import torch
import torch.multiprocessing as mp
import random
class QManeger(object):
def __init__(self, opt, q_trace, q_batch):
self.traces_s = []
self.traces_a = []
self.traces_r = []
self.lock = mp.Lock()
self.q_trace = q_trace
self.q_batch = q_batch
sel... | [
485,
5665,
222,
485,
5665,
51,
6870,
9608,
641,
7714,
222,
485,
4051,
499,
222,
842,
1931,
1272,
106,
892,
45,
1491,
731,
303,
684,
1176,
1683,
3232,
803,
49,
2948,
49,
2706,
100,
5736,
49,
2706,
100,
4476,
731,
310,
649,
51,
3694... | [
"import",
"Ġtorch",
"Ċ",
"import",
"Ġtorch",
".",
"multi",
"processing",
"Ġas",
"Ġmp",
"Ċ",
"import",
"Ġrandom",
"ĊĊ",
"Ċ",
"class",
"ĠQ",
"Man",
"e",
"ger",
"(",
"object",
"):",
"ĊĠĠĠ",
"Ġdef",
"Ġ__",
"init",
"__(",
"self",
",",
"Ġopt",
",",
"Ġq",
"... | [
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
1... | [
1,
7,
13,
1,
7,
13,
14,
19,
29,
32,
35,
1,
7,
14,
1,
1,
6,
8,
11,
12,
15,
16,
22,
24,
4,
8,
11,
15,
18,
22,
23,
27,
28,
30,
31,
36,
37,
39,
40,
45,
47,
8,
13,
14,
20,
21,
22,
24,
27,
8,
13,
14,
20,
21,
22,
... |
3c0beb7be29953ca2d7b390627305f4541b56efa | import sys
sys.path.append("../circos_report/cnv_anno2conf")
from cnv_anno2conf import main_cnv
tarfile = {"yaml": "data/test_app.yaml"}
def test_main_cnv():
main_cnv(tarfile)
if __name__ == "__main__":
test_main_cnv()
| [
485,
5263,
222,
222,
3750,
51,
1005,
51,
1713,
15471,
28883,
4984,
100,
3755,
52,
4999,
123,
100,
13241,
55,
2982,
678,
222,
1097,
300,
9709,
100,
13241,
55,
2982,
1220,
2594,
100,
4999,
123,
499,
222,
5384,
781,
299,
3479,
6057,
58... | [
"import",
"Ġsys",
"Ċ",
"Ċ",
"sys",
".",
"path",
".",
"append",
"(\"../",
"cir",
"cos",
"_",
"report",
"/",
"cn",
"v",
"_",
"anno",
"2",
"conf",
"\")",
"Ċ",
"from",
"Ġc",
"nv",
"_",
"anno",
"2",
"conf",
"Ġimport",
"Ġmain",
"_",
"cn",
"v",
"ĊĊ",
... | [
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
9,
10,
10,
10,
10,
10,
10,
10,
10,
... | [
1,
7,
11,
1,
1,
4,
5,
9,
10,
16,
21,
24,
27,
28,
34,
35,
37,
38,
39,
43,
44,
48,
50,
1,
5,
7,
9,
10,
14,
15,
19,
26,
31,
32,
34,
35,
1,
1,
4,
8,
10,
13,
17,
19,
21,
25,
26,
30,
31,
34,
35,
39,
41,
1,
1,
4,
... |
8d0fcf0bf5effec9aa04e7cd56b4b7098c6713cb | for i in range(-10, 0):
print(i, end=" ")
| [
999,
613,
347,
2189,
3766,
54,
53,
49,
244,
53,
731,
303,
1489,
45,
110,
49,
962,
366,
7816,
222
] | [
"for",
"Ġi",
"Ġin",
"Ġrange",
"(-",
"1",
"0",
",",
"Ġ",
"0",
"):",
"ĊĠĠĠ",
"Ġprint",
"(",
"i",
",",
"Ġend",
"=\"",
"Ġ\")",
"Ċ"
] | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2
] | [
1,
4,
6,
9,
15,
17,
18,
19,
20,
21,
22,
24,
4,
10,
11,
12,
13,
17,
19,
22
] |
a14114f9bb677601e6d75a72b84ec128fc9bbe61 | from django.contrib import admin
from django.urls import path, include, re_path
from django.conf.urls import include
# from rest_framework import routers
from rest_framework.authtoken import views
# from adventure.api import PlayerViewSet, RoomViewSet
# from adventure.api import move
# router = routers.DefaultRoute... | [
1097,
8532,
51,
12060,
1220,
5611,
222,
1097,
8532,
51,
11420,
1220,
1536,
49,
2323,
49,
334,
100,
1005,
222,
1097,
8532,
51,
2982,
51,
11420,
1220,
2323,
222,
222,
40,
664,
6125,
100,
2863,
1220,
18669,
502,
222,
1097,
6125,
100,
2... | [
"from",
"Ġdjango",
".",
"contrib",
"Ġimport",
"Ġadmin",
"Ċ",
"from",
"Ġdjango",
".",
"urls",
"Ġimport",
"Ġpath",
",",
"Ġinclude",
",",
"Ġre",
"_",
"path",
"Ċ",
"from",
"Ġdjango",
".",
"conf",
".",
"urls",
"Ġimport",
"Ġinclude",
"Ċ",
"Ċ",
"#",
"Ġfrom",
... | [
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
5,
12,
13,
20,
27,
33,
1,
5,
12,
13,
17,
24,
29,
30,
38,
39,
42,
43,
47,
1,
5,
12,
13,
17,
18,
22,
29,
37,
1,
1,
2,
7,
12,
13,
22,
29,
34,
37,
1,
5,
10,
11,
20,
21,
24,
26,
27,
30,
37,
43,
1,
2,
7,
10,
1... |
36991c3191ba48b1b9dbd843e279f8fe124f1339 | __author__ = "Jager"
from char import Character
class Rouge(Character):
def special_attack1(self, opponent, hitdamage_callback, specatt_callback):
pass # hook method
def special_attack2(self, opponent, hitdamage_callback, specatt_callback):
pass # hook method
def heal(self, target):
... | [
523,
2133,
523,
299,
332,
79,
1227,
39,
222,
1097,
1370,
1220,
15045,
499,
222,
842,
578,
663,
319,
45,
6891,
731,
303,
684,
7472,
100,
15605,
54,
45,
803,
49,
35639,
49,
8990,
23937,
100,
4399,
49,
1394,
3150,
100,
4399,
731,
310... | [
"__",
"author",
"__",
"Ġ=",
"Ġ\"",
"J",
"ager",
"\"",
"Ċ",
"from",
"Ġchar",
"Ġimport",
"ĠCharacter",
"ĊĊ",
"Ċ",
"class",
"ĠR",
"ou",
"ge",
"(",
"Character",
"):",
"ĊĠĠĠ",
"Ġdef",
"Ġspecial",
"_",
"attack",
"1",
"(",
"self",
",",
"Ġopponent",
",",
"Ġh... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
4,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9... | [
1,
3,
9,
11,
13,
15,
16,
20,
21,
1,
5,
10,
17,
27,
1,
1,
6,
8,
10,
12,
13,
22,
24,
4,
8,
16,
17,
23,
24,
25,
29,
30,
39,
40,
44,
50,
51,
59,
60,
65,
68,
69,
77,
79,
8,
13,
14,
16,
21,
28,
4,
8,
16,
17,
23,
... |
0de657ee173b606ad61d614a6168c00fcd571a70 | import os
from .common import cached_outputs, data_files, test_outputs
import nappy.nc_interface.na_to_nc
import nappy.nc_interface.nc_to_na
def test_convert_nc_2010_to_na_2310():
ffi_in, ffi_out = (2010, 2310)
infile = os.path.join(cached_outputs, f"{ffi_in}.nc")
outfile = os.path.join(test_outputs, f... | [
485,
2355,
222,
222,
1097,
657,
2297,
1220,
10812,
100,
11017,
49,
727,
100,
2558,
49,
913,
100,
11017,
222,
222,
485,
329,
17582,
51,
6667,
100,
3352,
51,
3288,
100,
471,
100,
6667,
222,
485,
329,
17582,
51,
6667,
100,
3352,
51,
... | [
"import",
"Ġos",
"Ċ",
"Ċ",
"from",
"Ġ.",
"common",
"Ġimport",
"Ġcached",
"_",
"outputs",
",",
"Ġdata",
"_",
"files",
",",
"Ġtest",
"_",
"outputs",
"Ċ",
"Ċ",
"import",
"Ġn",
"appy",
".",
"nc",
"_",
"interface",
".",
"na",
"_",
"to",
"_",
"nc",
"Ċ",
... | [
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9... | [
1,
7,
10,
1,
1,
5,
7,
13,
20,
27,
28,
35,
36,
41,
42,
47,
48,
53,
54,
61,
1,
1,
7,
9,
13,
14,
16,
17,
26,
27,
29,
30,
32,
33,
35,
1,
7,
9,
13,
14,
16,
17,
26,
27,
29,
30,
32,
33,
35,
1,
1,
4,
9,
10,
17,
18,... |
06638b361c1cbe92660d242969590dfa45b63a4d | #!/usr/bin/env python3
from utils import mathfont
import fontforge
v1 = 5 * mathfont.em
v2 = 1 * mathfont.em
f = mathfont.create("stack-bottomdisplaystyleshiftdown%d-axisheight%d" % (v1, v2), "Copyright (c) 2016 MathML Association")
f.math.AxisHeight = v2
f.math.StackBottomDisplayStyleShiftDown = v1
f.math.StackBotto... | [
8758,
3392,
52,
1793,
52,
2141,
4406,
56,
222,
222,
1097,
8767,
1220,
7820,
2204,
222,
485,
2377,
9499,
222,
222,
123,
54,
299,
244,
58,
338,
7820,
2204,
51,
423,
222,
123,
55,
299,
244,
54,
338,
7820,
2204,
51,
423,
222,
107,
2... | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"3",
"Ċ",
"Ċ",
"from",
"Ġutils",
"Ġimport",
"Ġmath",
"font",
"Ċ",
"import",
"Ġfont",
"forge",
"Ċ",
"Ċ",
"v",
"1",
"Ġ=",
"Ġ",
"5",
"Ġ*",
"Ġmath",
"font",
".",
"em",
"Ċ",
"v",
"2",
"Ġ=",
"Ġ",
"1",
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8... | [
1,
4,
7,
8,
11,
12,
15,
22,
23,
1,
1,
5,
11,
18,
23,
27,
1,
7,
12,
17,
1,
1,
2,
3,
5,
6,
7,
9,
14,
18,
19,
21,
1,
2,
3,
5,
6,
7,
9,
14,
18,
19,
21,
1,
2,
4,
9,
13,
14,
20,
22,
27,
28,
34,
41,
46,
48,
50... |
2dd59681a0dcb5d3f1143385100c09c7783babf4 | #!/usr/bin/env python
# script :: creating a datamodel that fits mahout from ratings.dat
ratings_dat = open("../data/movielens-1m/users.dat", "r")
ratings_csv = open("../data/movielens-1m/users.txt", "w")
for line in ratings_dat:
arr = line.split("::")
new_line = "\t".join(arr)
ratings_csv.write(new_lin... | [
8758,
3392,
52,
1793,
52,
2141,
4406,
222,
40,
3273,
2053,
6913,
331,
45444,
708,
30871,
364,
2389,
560,
664,
42117,
51,
2923,
499,
222,
37031,
100,
2923,
299,
2177,
15471,
624,
52,
3492,
691,
1249,
50,
54,
114,
52,
3724,
51,
2923,
... | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"Ċ",
"#",
"Ġscript",
"Ġ::",
"Ġcreating",
"Ġa",
"Ġdatamodel",
"Ġthat",
"Ġfits",
"Ġm",
"ah",
"out",
"Ġfrom",
"Ġratings",
".",
"dat",
"ĊĊ",
"Ċ",
"ratings",
"_",
"dat",
"Ġ=",
"Ġopen",
"(\"../",
"data",
"/",
... | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6... | [
1,
4,
7,
8,
11,
12,
15,
22,
1,
2,
9,
12,
21,
23,
33,
38,
43,
45,
47,
50,
55,
63,
64,
67,
1,
1,
8,
9,
12,
14,
19,
24,
28,
29,
32,
35,
38,
39,
40,
41,
42,
47,
48,
51,
53,
55,
56,
58,
1,
8,
9,
12,
14,
19,
24,
... |
5ce98ae241c0982eeb1027ffcff5b770f94ff1a3 | import csv
import os
events = {}
eventTypes = set()
eventIndices = {}
i = 0
with open("Civ VI Modding Companion - Events.csv", newline="") as csvfile:
reader = csv.reader(csvfile, delimiter=",", quotechar="|")
for row in reader:
if i < 4:
i += 1
continue
eventName = r... | [
485,
11490,
222,
485,
2355,
222,
222,
5070,
299,
2172,
222,
1585,
2439,
299,
758,
365,
222,
1585,
13386,
299,
2172,
222,
222,
110,
299,
244,
53,
222,
222,
1814,
2177,
459,
72,
407,
35075,
5516,
2438,
2270,
18843,
449,
17874,
51,
484... | [
"import",
"Ġcsv",
"Ċ",
"import",
"Ġos",
"Ċ",
"Ċ",
"events",
"Ġ=",
"Ġ{}",
"Ċ",
"event",
"Types",
"Ġ=",
"Ġset",
"()",
"Ċ",
"event",
"Indices",
"Ġ=",
"Ġ{}",
"Ċ",
"Ċ",
"i",
"Ġ=",
"Ġ",
"0",
"Ċ",
"Ċ",
"with",
"Ġopen",
"(\"",
"C",
"iv",
"ĠVI",
"ĠMod",
... | [
1,
1,
1,
2,
2,
2,
3,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
7,
8,
8,
8,
8,
8,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
11,
11,
11,
11,
11,
11,
11,... | [
1,
7,
11,
1,
7,
10,
1,
1,
7,
9,
12,
1,
6,
11,
13,
17,
19,
1,
6,
13,
15,
18,
1,
1,
2,
4,
5,
6,
1,
1,
5,
10,
12,
13,
15,
18,
22,
26,
31,
36,
38,
45,
46,
49,
51,
59,
63,
66,
70,
74,
75,
4,
11,
13,
17,
18,
24... |
79c043fc862e77bea5adc3f1c6bb9a6272f19c75 | #!/usr/bin/env python
import socket
name = socket.gethostname()
| [
8758,
3392,
52,
1793,
52,
2141,
4406,
222,
222,
485,
6241,
222,
222,
444,
299,
6241,
51,
44187,
667,
444,
365,
222
] | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"Ċ",
"Ċ",
"import",
"Ġsocket",
"Ċ",
"Ċ",
"name",
"Ġ=",
"Ġsocket",
".",
"geth",
"ost",
"name",
"()",
"Ċ"
] | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5
] | [
1,
4,
7,
8,
11,
12,
15,
22,
1,
1,
7,
14,
1,
1,
5,
7,
14,
15,
19,
22,
26,
28
] |
22c498d84f40455d89ed32ccf3bf8778cb159579 | import os
import pandas as pd
from tabulate import tabulate
if __name__ == "__main__":
bestPrecision = [0, 0, 0, 0, 0, 0]
bestPrecisionFile = ["", "", "", "", "", ""]
bestRecall = [0, 0, 0, 0, 0, 0]
bestRecallFile = ["", "", "", "", "", ""]
bestSupport = [0, 0, 0, 0, 0, 0]
bestSupportFile = [""... | [
485,
2355,
222,
485,
13247,
641,
6451,
222,
1097,
4890,
6710,
1220,
4890,
6710,
222,
222,
344,
1176,
444,
523,
630,
9609,
1850,
18021,
303,
5318,
20475,
299,
447,
53,
49,
244,
53,
49,
244,
53,
49,
244,
53,
49,
244,
53,
49,
244,
... | [
"import",
"Ġos",
"Ċ",
"import",
"Ġpandas",
"Ġas",
"Ġpd",
"Ċ",
"from",
"Ġtab",
"ulate",
"Ġimport",
"Ġtab",
"ulate",
"Ċ",
"Ċ",
"if",
"Ġ__",
"name",
"__",
"Ġ==",
"Ġ\"__",
"main",
"__\":",
"ĊĠĠĠ",
"Ġbest",
"Precision",
"Ġ=",
"Ġ[",
"0",
",",
"Ġ",
"0",
","... | [
1,
1,
1,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8... | [
1,
7,
10,
1,
7,
14,
17,
20,
1,
5,
9,
14,
21,
25,
30,
1,
1,
3,
6,
10,
12,
15,
19,
23,
27,
4,
9,
18,
20,
22,
23,
24,
25,
26,
27,
28,
29,
30,
31,
32,
33,
34,
35,
36,
37,
38,
39,
4,
9,
18,
22,
24,
27,
29,
33,
3... |
5b8c95354f8b27eff8226ace52ab9e97f98ae217 | from dai_imports import *
from obj_utils import *
import utils
class my_image_csv_dataset(Dataset):
def __init__(self, data_dir, data, transforms_=None, obj=False, minorities=None, diffs=None, bal_tfms=None):
self.data_dir = data_dir
self.data = data
self.transforms_ = transforms_
... | [
1097,
362,
3063,
100,
22451,
1220,
338,
222,
1097,
2847,
100,
2324,
1220,
338,
222,
485,
8767,
499,
222,
842,
1690,
100,
915,
100,
4849,
100,
5709,
45,
9440,
731,
303,
684,
1176,
1683,
3232,
803,
49,
727,
100,
1537,
49,
727,
49,
1... | [
"from",
"Ġd",
"ai",
"_",
"imports",
"Ġimport",
"Ġ*",
"Ċ",
"from",
"Ġobj",
"_",
"utils",
"Ġimport",
"Ġ*",
"Ċ",
"import",
"Ġutils",
"ĊĊ",
"Ċ",
"class",
"Ġmy",
"_",
"image",
"_",
"csv",
"_",
"dataset",
"(",
"Dataset",
"):",
"ĊĠĠĠ",
"Ġdef",
"Ġ__",
"init"... | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
5,
7,
9,
10,
17,
24,
26,
1,
5,
9,
10,
15,
22,
24,
1,
7,
13,
1,
1,
6,
9,
10,
15,
16,
19,
20,
27,
28,
35,
37,
4,
8,
11,
15,
18,
22,
23,
28,
29,
32,
33,
38,
39,
50,
52,
56,
57,
61,
62,
67,
68,
74,
79,
80,
8... |
64c32b3ada7fff51a7c4b07872b7688e100897d8 | class Node(object):
def __init__(self, data):
self.data = data
self.left = None
self.right = None
self.parent = None
class tree(object):
def __init__(self):
self.root = None
def insert(self, root, value):
if self.root == None:
self.root = Node(v... | [
842,
4021,
45,
1491,
731,
303,
684,
1176,
1683,
3232,
803,
49,
727,
731,
310,
649,
51,
624,
299,
727,
310,
649,
51,
1892,
299,
1686,
310,
649,
51,
1009,
299,
1686,
310,
649,
51,
2562,
299,
1686,
499,
222,
842,
4369,
45,
1491,
73... | [
"class",
"ĠNode",
"(",
"object",
"):",
"ĊĠĠĠ",
"Ġdef",
"Ġ__",
"init",
"__(",
"self",
",",
"Ġdata",
"):",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
".",
"data",
"Ġ=",
"Ġdata",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
".",
"left",
"Ġ=",
"ĠNone",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
".",
"right",
"Ġ=",
"ĠNone",
... | [
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
8,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
11,
11,
11,
11,
11,
11,
13,
13... | [
1,
6,
11,
12,
18,
20,
4,
8,
11,
15,
18,
22,
23,
28,
30,
8,
13,
14,
18,
20,
25,
8,
13,
14,
18,
20,
25,
8,
13,
14,
19,
21,
26,
8,
13,
14,
20,
22,
27,
1,
1,
6,
11,
12,
18,
20,
4,
8,
11,
15,
18,
22,
24,
8,
13,
... |
88ec9484e934ce27b13734ca26f79df71b7677e6 | import requests
from bs4 import BeautifulSoup
import sys
import re
if len(sys.argv) < 2:
print("Syntax : python %s <port>") % (str(sys.argv[0]))
else:
print("-" * 55)
print("HTB WEB-CHALLENGE coded by ZyperX [Freelance]")
print("-" * 55)
r = requests.session()
port = str(sys.argv[1])
url = ... | [
485,
5188,
222,
1097,
14270,
57,
1220,
39693,
222,
485,
5263,
222,
485,
334,
222,
222,
344,
2095,
45,
3750,
51,
6129,
46,
350,
244,
55,
63,
303,
1489,
459,
6651,
518,
4406,
925,
120,
350,
644,
19824,
925,
327,
484,
45,
3750,
51,
... | [
"import",
"Ġrequests",
"Ċ",
"from",
"Ġbs",
"4",
"Ġimport",
"ĠBeautifulSoup",
"Ċ",
"import",
"Ġsys",
"Ċ",
"import",
"Ġre",
"Ċ",
"Ċ",
"if",
"Ġlen",
"(",
"sys",
".",
"argv",
")",
"Ġ<",
"Ġ",
"2",
":",
"ĊĠĠĠ",
"Ġprint",
"(\"",
"Syntax",
"Ġ:",
"Ġpython",
"... | [
1,
1,
1,
2,
2,
2,
2,
2,
2,
3,
3,
3,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
... | [
1,
7,
16,
1,
5,
8,
9,
16,
30,
1,
7,
11,
1,
7,
10,
1,
1,
3,
7,
8,
11,
12,
16,
17,
19,
20,
21,
22,
4,
10,
12,
18,
20,
27,
29,
30,
32,
36,
39,
41,
43,
46,
47,
50,
51,
55,
56,
57,
60,
1,
5,
6,
4,
10,
13,
14,
... |
cd2e03666a890d6e9ea0fcb45fe28510d684916d | import requests
def squeezed(client_name):
return client_name.replace("Индивидуальный предприниматель", "ИП")
def get_kkm_filled_fn(max_fill=80):
## возвращает список ККМ с заполнением ФН больше max_fill в %
LOGIN_URL = "https://pk.platformaofd.ru/auth/login"
API_URL = "https://pk.platformaofd.ru/ap... | [
485,
5188,
499,
222,
610,
328,
554,
11743,
337,
45,
1598,
100,
444,
731,
303,
461,
2060,
100,
444,
51,
3249,
459,
19048,
1439,
4382,
13869,
27631,
2574,
19047,
18513,
25814,
47358,
12062,
9256,
39874,
411,
332,
19048,
13169,
678,
499,
... | [
"import",
"Ġrequests",
"ĊĊ",
"Ċ",
"def",
"Ġs",
"que",
"ez",
"ed",
"(",
"client",
"_",
"name",
"):",
"ĊĠĠĠ",
"Ġreturn",
"Ġclient",
"_",
"name",
".",
"replace",
"(\"",
"Ðĺ",
"н",
"д",
"ив",
"ид",
"Ñĥ",
"алÑĮ",
"нÑĭй",
"ĠпÑĢед",
"пÑĢ",
"ин... | [
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9... | [
1,
7,
16,
1,
1,
4,
6,
9,
11,
13,
14,
20,
21,
25,
27,
4,
11,
18,
19,
23,
24,
31,
33,
34,
35,
36,
38,
40,
41,
44,
47,
52,
54,
56,
58,
63,
65,
67,
68,
69,
71,
1,
1,
4,
8,
9,
11,
12,
13,
19,
20,
22,
23,
26,
27,
... |
709f2425bc6e0b0b650fd6c657df6d85cfbd05fe | from django.shortcuts import render
# Create your views here.
def test_petite_vue(request):
return render(request, "petite_vue_app/test-form.html")
| [
1097,
8532,
51,
36264,
1220,
2922,
499,
222,
40,
2673,
1390,
11887,
2464,
51,
222,
610,
913,
100,
6093,
676,
100,
7098,
45,
1375,
731,
303,
461,
2922,
45,
1375,
49,
332,
6093,
676,
100,
7098,
100,
745,
52,
881,
50,
618,
51,
935,
... | [
"from",
"Ġdjango",
".",
"shortcuts",
"Ġimport",
"Ġrender",
"ĊĊ",
"Ċ",
"#",
"ĠCreate",
"Ġyour",
"Ġviews",
"Ġhere",
".",
"Ċ",
"def",
"Ġtest",
"_",
"pet",
"ite",
"_",
"vue",
"(",
"request",
"):",
"ĊĠĠĠ",
"Ġreturn",
"Ġrender",
"(",
"request",
",",
"Ġ\"",
"... | [
1,
1,
1,
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6
] | [
1,
5,
12,
13,
22,
29,
36,
1,
1,
2,
9,
14,
20,
25,
26,
1,
4,
9,
10,
13,
16,
17,
20,
21,
28,
30,
4,
11,
18,
19,
26,
27,
29,
32,
35,
36,
39,
40,
43,
44,
48,
49,
53,
54,
58,
60
] |
a4deb67d277538e61c32381da0fe4886016dae33 | import torch
import torch.nn as nn
import torch.nn.functional as F
import torch.optim as optim
import cv2
import imageio
import pandas as pd
import glob, os
import numpy as np
fileDir = os.getcwd()
# os.chdir("./train-jpg")
# there are 40480 training examples
# we will allocate 39000 for training
# and the remaining ... | [
485,
5665,
222,
485,
5665,
51,
4042,
641,
8507,
222,
485,
5665,
51,
4042,
51,
18678,
641,
525,
222,
485,
5665,
51,
8411,
641,
6630,
222,
485,
6781,
55,
222,
485,
1802,
735,
222,
485,
13247,
641,
6451,
222,
485,
12542,
49,
2355,
22... | [
"import",
"Ġtorch",
"Ċ",
"import",
"Ġtorch",
".",
"nn",
"Ġas",
"Ġnn",
"Ċ",
"import",
"Ġtorch",
".",
"nn",
".",
"functional",
"Ġas",
"ĠF",
"Ċ",
"import",
"Ġtorch",
".",
"optim",
"Ġas",
"Ġoptim",
"Ċ",
"import",
"Ġcv",
"2",
"Ċ",
"import",
"Ġimage",
"io",
... | [
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
6,
6,
6,
6,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
10,
11,
11,
11,
11,
11,
11,
11,
11,
12,
12,
12,
... | [
1,
7,
13,
1,
7,
13,
14,
16,
19,
22,
1,
7,
13,
14,
16,
17,
27,
30,
32,
1,
7,
13,
14,
19,
22,
28,
1,
7,
10,
11,
1,
7,
13,
15,
1,
7,
14,
17,
20,
1,
7,
12,
13,
16,
1,
7,
13,
16,
19,
1,
1,
5,
8,
10,
13,
14,
20... |
914f477518918619e0e42184bd03c2a7ed16bb01 | from django.db import models
class Location(models.Model):
id_location = models.AutoField(primary_key=True)
city = models.CharField(max_length=100, null=True)
street_name = models.CharField(max_length=100, null=True)
street_number = models.IntegerField(null=True)
zip = models.IntegerField(null=Tru... | [
1097,
8532,
51,
1219,
1220,
4590,
499,
222,
842,
10642,
45,
3404,
51,
1262,
731,
303,
828,
100,
2665,
299,
4590,
51,
4754,
1195,
45,
4472,
100,
697,
66,
1844,
46,
303,
11353,
299,
4590,
51,
16347,
45,
1472,
100,
1340,
66,
54,
53,
... | [
"from",
"Ġdjango",
".",
"db",
"Ġimport",
"Ġmodels",
"ĊĊ",
"Ċ",
"class",
"ĠLocation",
"(",
"models",
".",
"Model",
"):",
"ĊĠĠĠ",
"Ġid",
"_",
"location",
"Ġ=",
"Ġmodels",
".",
"Auto",
"Field",
"(",
"primary",
"_",
"key",
"=",
"True",
")",
"ĊĠĠĠ",
"Ġcity"... | [
1,
1,
1,
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
5,
12,
13,
15,
22,
29,
1,
1,
6,
15,
16,
22,
23,
28,
30,
4,
7,
8,
16,
18,
25,
26,
30,
35,
36,
43,
44,
47,
48,
52,
53,
4,
9,
11,
18,
19,
28,
29,
32,
33,
39,
40,
41,
42,
43,
44,
49,
50,
54,
55,
4,
11,
12,
16,... |
cdbf9427d48f0a5c53b6efe0de7dfea65a8afd83 | # -*- coding: utf-8 -*-
# Copyright (c) 2018-2020 Christiaan Frans Rademan <chris@fwiw.co.za>.
# 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 ... | [
40,
8571,
10633,
63,
6471,
50,
61,
8571,
222,
40,
2657,
327,
104,
46,
244,
55,
53,
54,
61,
50,
55,
53,
55,
53,
24677,
923,
297,
10766,
711,
578,
1546,
1607,
350,
9924,
316,
69,
8953,
12374,
51,
352,
51,
6224,
4513,
222,
40,
33... | [
"#",
"Ġ-*-",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ġ-*-",
"Ċ",
"#",
"ĠCopyright",
"Ġ(",
"c",
")",
"Ġ",
"2",
"0",
"1",
"8",
"-",
"2",
"0",
"2",
"0",
"ĠChrist",
"ia",
"an",
"ĠFr",
"ans",
"ĠR",
"ade",
"man",
"Ġ<",
"chr",
"is",
"@",
"fw",
"iw",
".... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5... | [
1,
2,
6,
13,
14,
18,
19,
20,
24,
1,
2,
12,
14,
15,
16,
17,
18,
19,
20,
21,
22,
23,
24,
25,
26,
33,
35,
37,
40,
43,
45,
48,
51,
53,
56,
58,
59,
61,
63,
64,
66,
67,
69,
71,
1,
2,
6,
13,
22,
23,
1,
2,
1,
2,
17,
... |
c4624425f57211e583b5fbaec3943539ce6fea6f | from django import forms
from .models import BlogPost
class BlogPostForm(forms.ModelForm):
class Meta:
model = BlogPost
fields = "__all__"
| [
1097,
8532,
1220,
10556,
222,
1097,
657,
3404,
1220,
20007,
3176,
499,
222,
842,
20007,
3176,
1260,
45,
8543,
51,
1262,
1260,
731,
303,
462,
11990,
63,
310,
1573,
299,
20007,
3176,
310,
3844,
299,
9609,
483,
523,
39,
222
] | [
"from",
"Ġdjango",
"Ġimport",
"Ġforms",
"Ċ",
"from",
"Ġ.",
"models",
"Ġimport",
"ĠBlog",
"Post",
"ĊĊ",
"Ċ",
"class",
"ĠBlog",
"Post",
"Form",
"(",
"forms",
".",
"Model",
"Form",
"):",
"ĊĠĠĠ",
"Ġclass",
"ĠMeta",
":",
"ĊĠĠĠĠĠĠĠ",
"Ġmodel",
"Ġ=",
"ĠBlog",
"... | [
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8
] | [
1,
5,
12,
19,
25,
1,
5,
7,
13,
20,
25,
29,
1,
1,
6,
11,
15,
19,
20,
25,
26,
31,
35,
37,
4,
10,
15,
16,
8,
14,
16,
21,
25,
8,
15,
17,
21,
24,
26,
27
] |
a42f36fca2f65d0c5c9b65055af1814d8b4b3d42 | #!/usr/bin/env python3
# --------------------( LICENSE )--------------------
# Copyright (c) 2014-2023 Beartype authors.
# See "LICENSE" for further details.
"""
Project-wide **standard Python module globals** (i.e., global constants
describing modules and packages bundled with CPython's sta... | [
8758,
3392,
52,
1793,
52,
2141,
4406,
56,
222,
40,
42734,
45,
7621,
9326,
848,
35541,
222,
40,
2657,
327,
104,
46,
244,
55,
53,
54,
57,
50,
55,
53,
55,
56,
4284,
521,
430,
14656,
51,
222,
40,
2819,
332,
4106,
39,
456,
9710,
42... | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"3",
"Ċ",
"#",
"Ġ--------------------",
"(",
"ĠLICENSE",
"ĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ",
"Ġ)",
"--------------------",
"Ċ",
"#",
"ĠCopyright",
"Ġ(",
"c",
")",
"Ġ",
"2",
"0",
"1",
"4",
"-",
"2",
"0",
"2",
"3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7... | [
1,
4,
7,
8,
11,
12,
15,
22,
23,
1,
2,
23,
24,
32,
59,
61,
81,
1,
2,
12,
14,
15,
16,
17,
18,
19,
20,
21,
22,
23,
24,
25,
26,
29,
32,
35,
43,
44,
1,
2,
6,
8,
15,
16,
20,
28,
36,
37,
1,
1,
4,
1,
8,
9,
13,
16,
... |
c23125018a77508dad6fd2cb86ec6d556fbd1019 | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Thu May 21 11:40:26 2020
@author: jlee
"""
import time
start_time = time.time()
import numpy as np
import glob, os
from astropy.io import fits
import init_cfg as ic
# ----- Making scripts for PSFEx ----- #
os.system("psfex -dd > config.psfex")
if ic.... | [
8758,
3392,
52,
1793,
52,
2141,
4406,
56,
222,
40,
8571,
10633,
63,
6471,
50,
61,
8571,
222,
3012,
222,
6880,
563,
17024,
10712,
244,
55,
54,
244,
54,
54,
63,
57,
53,
63,
55,
59,
244,
55,
53,
55,
53,
222,
222,
69,
2133,
63,
... | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"3",
"Ċ",
"#",
"Ġ-*-",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ġ-*-",
"Ċ",
"\"\"\"",
"Ċ",
"Created",
"Ġon",
"ĠThu",
"ĠMay",
"Ġ",
"2",
"1",
"Ġ",
"1",
"1",
":",
"4",
"0",
":",
"2",
"6",
"Ġ",
"2",
"0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
7,
7,
8,
9,
9,
9,
10,
11,
11,
11,
11,
11,
11,
... | [
1,
4,
7,
8,
11,
12,
15,
22,
23,
1,
2,
6,
13,
14,
18,
19,
20,
24,
1,
4,
1,
8,
11,
15,
19,
20,
21,
22,
23,
24,
25,
26,
27,
28,
29,
30,
31,
32,
33,
34,
35,
36,
1,
1,
2,
8,
9,
11,
14,
1,
4,
1,
1,
7,
12,
1,
1,... |
81688d51696156905736b5de7a4929387fd385ab | import argparse
import datetime
import importlib
import pprint
import time
import random
import numpy as np
import torch
from torch.utils.tensorboard import SummaryWriter
from utils import get_git_state, time_print, AverageMeter, ProgressMeter, save_checkpoint
def train(cfg, epoch, data_loader, model):
data_tim... | [
485,
16693,
222,
485,
7181,
222,
485,
46233,
222,
485,
25852,
222,
485,
1153,
222,
485,
4051,
222,
222,
485,
6610,
641,
2115,
222,
485,
5665,
222,
1097,
5665,
51,
2324,
51,
6878,
2207,
1220,
15615,
3989,
222,
222,
1097,
8767,
1220,
... | [
"import",
"Ġargparse",
"Ċ",
"import",
"Ġdatetime",
"Ċ",
"import",
"Ġimportlib",
"Ċ",
"import",
"Ġpprint",
"Ċ",
"import",
"Ġtime",
"Ċ",
"import",
"Ġrandom",
"Ċ",
"Ċ",
"import",
"Ġnumpy",
"Ġas",
"Ġnp",
"Ċ",
"import",
"Ġtorch",
"Ċ",
"from",
"Ġtorch",
".",
"ut... | [
1,
1,
1,
2,
2,
2,
3,
3,
3,
4,
4,
4,
5,
5,
5,
6,
6,
6,
7,
8,
8,
8,
8,
8,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
11,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
12,
1... | [
1,
7,
16,
1,
7,
16,
1,
7,
17,
1,
7,
14,
1,
7,
12,
1,
7,
14,
1,
1,
7,
13,
16,
19,
1,
7,
13,
1,
5,
11,
12,
17,
18,
24,
29,
36,
44,
50,
1,
1,
5,
11,
18,
22,
23,
26,
27,
32,
33,
38,
39,
44,
45,
53,
58,
59,
68... |
d90942f22cbbd9cfc3a431b7857cd909a7690966 | OK = 200
CREATED = 201
NOT_MODIFIED = 304
UNAUTHORIZED = 401
FORBIDDEN = 403
BAD_REQUEST = 400
NOT_FOUND = 404
CONFLICT = 409
UNPROCESSABLE = 422
INTERNAL_SERVER_ERROR = 500
NOT_IMPLEMENTED = 501
SERVICE_UNAVAILABLE = 503
ADMIN = "admin"
ELITE = "elite"
NOOB = "noob"
WITHDRAW = "withdraw"
FUND = "fund"
| [
2966,
299,
244,
55,
53,
53,
222,
28035,
299,
244,
55,
53,
54,
222,
3922,
100,
34321,
25025,
299,
244,
56,
53,
57,
222,
1430,
30717,
1363,
299,
244,
57,
53,
54,
222,
7331,
35236,
16031,
299,
244,
57,
53,
56,
222,
13721,
100,
7921... | [
"OK",
"Ġ=",
"Ġ",
"2",
"0",
"0",
"Ċ",
"CREATED",
"Ġ=",
"Ġ",
"2",
"0",
"1",
"Ċ",
"NOT",
"_",
"MODI",
"FIED",
"Ġ=",
"Ġ",
"3",
"0",
"4",
"Ċ",
"UN",
"AUTHORIZ",
"ED",
"Ġ=",
"Ġ",
"4",
"0",
"1",
"Ċ",
"FOR",
"BID",
"DEN",
"Ġ=",
"Ġ",
"4",
"0",
"... | [
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8... | [
1,
3,
5,
6,
7,
8,
9,
1,
8,
10,
11,
12,
13,
14,
1,
4,
5,
9,
13,
15,
16,
17,
18,
19,
1,
3,
11,
13,
15,
16,
17,
18,
19,
1,
4,
7,
10,
12,
13,
14,
15,
16,
1,
4,
5,
12,
14,
15,
16,
17,
18,
1,
4,
5,
10,
12,
13,
... |
54ec1961f4835f575e7129bd0b2fcdeb97be2f03 | import configparser
import sqlite3
import time
import uuid
from duoquest.tsq import TableSketchQuery
def input_db_name(conn):
while True:
db_name = input("Database name (default: concert_singer) > ")
if not db_name:
db_name = "concert_singer"
cur = conn.cursor()
cur.e... | [
485,
1377,
3936,
222,
485,
17743,
56,
222,
485,
1153,
222,
485,
11168,
222,
222,
1097,
6305,
116,
622,
51,
1448,
118,
1220,
5565,
44347,
1643,
499,
222,
610,
1533,
100,
1219,
100,
444,
45,
3795,
731,
303,
2236,
2969,
63,
310,
3100,
... | [
"import",
"Ġconfig",
"parser",
"Ċ",
"import",
"Ġsqlite",
"3",
"Ċ",
"import",
"Ġtime",
"Ċ",
"import",
"Ġuuid",
"Ċ",
"Ċ",
"from",
"Ġdu",
"o",
"quest",
".",
"ts",
"q",
"Ġimport",
"ĠTable",
"Sketch",
"Query",
"ĊĊ",
"Ċ",
"def",
"Ġinput",
"_",
"db",
"_",
"... | [
1,
1,
1,
1,
2,
2,
2,
2,
3,
3,
3,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
11,
... | [
1,
7,
14,
20,
1,
7,
14,
15,
1,
7,
12,
1,
7,
12,
1,
1,
5,
8,
9,
14,
15,
17,
18,
25,
31,
37,
42,
1,
1,
4,
10,
11,
13,
14,
18,
19,
23,
25,
4,
10,
15,
16,
8,
11,
12,
16,
18,
24,
26,
34,
39,
41,
48,
49,
53,
57,
... |
2fe20f28fc7bba6b8188f5068e2b3c8b87c15edc | from util import AutomataError
from automata import NFA
from base import Node
from copy import copy, deepcopy
from os.path import commonprefix
DEBUG = False
LAMBDA = "\u03bb"
PHI = "\u00d8"
def copyDeltas(src):
out = dict()
for k in src:
out[k] = dict()
for k2 in src[k]:
out[k][k... | [
1097,
4548,
1220,
13515,
420,
943,
222,
1097,
4351,
420,
1220,
508,
1867,
222,
1097,
1712,
1220,
4021,
222,
1097,
1948,
1220,
1948,
49,
29281,
222,
1097,
2355,
51,
1005,
1220,
4959,
4271,
222,
222,
2913,
299,
3208,
222,
222,
81,
44853... | [
"from",
"Ġutil",
"Ġimport",
"ĠAutom",
"ata",
"Error",
"Ċ",
"from",
"Ġautom",
"ata",
"Ġimport",
"ĠN",
"FA",
"Ċ",
"from",
"Ġbase",
"Ġimport",
"ĠNode",
"Ċ",
"from",
"Ġcopy",
"Ġimport",
"Ġcopy",
",",
"Ġdeepcopy",
"Ċ",
"from",
"Ġos",
".",
"path",
"Ġimport",
"... | [
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
8,
9,
9,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
... | [
1,
5,
10,
17,
23,
26,
31,
1,
5,
11,
14,
21,
23,
25,
1,
5,
10,
17,
22,
1,
5,
10,
17,
22,
23,
32,
1,
5,
8,
9,
13,
20,
27,
33,
1,
1,
6,
8,
14,
1,
1,
2,
7,
9,
12,
13,
14,
15,
17,
18,
1,
3,
4,
6,
9,
10,
11,
... |
aa579025cacd11486a101b2dc51b5ba4997bf84a | class UrlPath:
@staticmethod
def combine(*args):
result = ""
for path in args:
result += path if path.endswith("/") else "{}/".format(path)
# result = result[:-1]
return result
| [
842,
15795,
1233,
63,
303,
496,
16130,
303,
684,
16878,
2761,
1150,
731,
310,
1074,
299,
3347,
310,
456,
1536,
347,
2194,
63,
343,
1074,
1475,
1536,
434,
1536,
51,
20677,
32153,
832,
19457,
52,
2316,
1664,
45,
1005,
46,
310,
607,
10... | [
"class",
"ĠUrl",
"Path",
":",
"ĊĠĠĠ",
"Ġ@",
"staticmethod",
"ĊĠĠĠ",
"Ġdef",
"Ġcombine",
"(*",
"args",
"):",
"ĊĠĠĠĠĠĠĠ",
"Ġresult",
"Ġ=",
"Ġ\"\"",
"ĊĠĠĠĠĠĠĠ",
"Ġfor",
"Ġpath",
"Ġin",
"Ġargs",
":",
"ĊĠĠĠĠĠĠĠĠĠĠĠ",
"Ġresult",
"Ġ+=",
"Ġpath",
"Ġif",
"Ġpath",
"."... | [
1,
1,
1,
1,
1,
2,
2,
2,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8
] | [
1,
6,
10,
14,
15,
4,
6,
18,
4,
8,
16,
18,
22,
24,
8,
15,
17,
20,
8,
12,
17,
20,
25,
26,
12,
19,
22,
27,
30,
35,
36,
44,
49,
54,
58,
59,
61,
67,
68,
72,
73,
8,
10,
17,
19,
26,
29,
30,
31,
8,
15,
22
] |
a1304f290e0346e7aa2e22d9c2d3e7f735b1e8e7 | # We don't need no stinking models but django likes this file to be there if you are an app
| [
40,
2726,
2818,
1348,
1868,
1307,
395,
783,
318,
4590,
1294,
8532,
39848,
477,
822,
391,
545,
2038,
434,
863,
904,
619,
1142,
222
] | [
"#",
"ĠWe",
"Ġdon",
"'t",
"Ġneed",
"Ġno",
"Ġst",
"ink",
"ing",
"Ġmodels",
"Ġbut",
"Ġdjango",
"Ġlikes",
"Ġthis",
"Ġfile",
"Ġto",
"Ġbe",
"Ġthere",
"Ġif",
"Ġyou",
"Ġare",
"Ġan",
"Ġapp",
"Ċ"
] | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] | [
1,
2,
5,
9,
11,
16,
19,
22,
25,
28,
35,
39,
46,
52,
57,
62,
65,
68,
74,
77,
81,
85,
88,
92
] |
368e209f83cc0cade81791c8357e01e7e3f940c8 | #!/usr/bin/python3
import requests
import urllib3
urllib3.disable_warnings()
response = requests.get("https://freeaeskey.xyz", verify=False)
data = response.text.encode("utf-8")
key = data[data.index(b"<b>") + 3 : data.index(b"</b>")]
print(key.decode("ascii"))
| [
8758,
3392,
52,
1793,
52,
2980,
56,
222,
222,
485,
5188,
222,
485,
22296,
56,
222,
222,
39599,
56,
51,
5826,
100,
20340,
365,
222,
2003,
299,
5188,
51,
390,
459,
662,
574,
4010,
16477,
697,
51,
11482,
411,
6152,
66,
2737,
46,
222,... | [
"#!/",
"usr",
"/",
"bin",
"/",
"python",
"3",
"Ċ",
"Ċ",
"import",
"Ġrequests",
"Ċ",
"import",
"Ġurllib",
"3",
"Ċ",
"Ċ",
"urllib",
"3",
".",
"disable",
"_",
"warnings",
"()",
"Ċ",
"response",
"Ġ=",
"Ġrequests",
".",
"get",
"(\"",
"https",
"://",
"free... | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
4,
4,
4,
4,
5,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9... | [
1,
4,
7,
8,
11,
12,
18,
19,
1,
1,
7,
16,
1,
7,
14,
15,
1,
1,
7,
8,
9,
16,
17,
25,
27,
1,
9,
11,
20,
21,
24,
26,
31,
34,
38,
41,
44,
45,
48,
50,
57,
58,
63,
64,
1,
5,
7,
16,
17,
21,
22,
28,
30,
33,
34,
35,
... |
174f744b641ee20272713fa2fe1991cb2c76830a | from django.db import models
class Brokerage(models.Model):
BrokerageName = models.CharField(max_length=500)
# To-Do Fix additional settings for ImagesFields/FileFields
# BrokerageLogo = ImageField
ReviewLink = models.CharField(max_length=1000)
ContactLink = models.CharField(max_length=1000)
T... | [
1097,
8532,
51,
1219,
1220,
4590,
499,
222,
842,
41088,
400,
45,
3404,
51,
1262,
731,
303,
41088,
400,
577,
299,
4590,
51,
16347,
45,
1472,
100,
1340,
66,
58,
53,
53,
46,
303,
607,
2634,
50,
2573,
7097,
5408,
4086,
456,
27648,
415... | [
"from",
"Ġdjango",
".",
"db",
"Ġimport",
"Ġmodels",
"ĊĊ",
"Ċ",
"class",
"ĠBroker",
"age",
"(",
"models",
".",
"Model",
"):",
"ĊĠĠĠ",
"ĠBroker",
"age",
"Name",
"Ġ=",
"Ġmodels",
".",
"CharField",
"(",
"max",
"_",
"length",
"=",
"5",
"0",
"0",
")",
"ĊĠĠ... | [
1,
1,
1,
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8... | [
1,
5,
12,
13,
15,
22,
29,
1,
1,
6,
13,
16,
17,
23,
24,
29,
31,
4,
11,
14,
18,
20,
27,
28,
37,
38,
41,
42,
48,
49,
50,
51,
52,
53,
4,
6,
9,
10,
12,
16,
27,
36,
40,
47,
53,
54,
58,
64,
4,
6,
13,
16,
20,
22,
28,... |
d815c6e233d81dfb144442a83e6006aa4e29bfce | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# ==================================================
# @Author : Copyright@Ryuchen
# ==================================================
from .version import VERSION
__all__ = ["VERSION"]
| [
8758,
3392,
52,
1793,
52,
2141,
4406,
222,
40,
8571,
10633,
63,
6471,
50,
61,
8571,
222,
40,
21422,
66,
222,
40,
496,
4372,
518,
2657,
69,
35014,
2032,
291,
222,
40,
21422,
66,
222,
222,
1097,
657,
1687,
1220,
20411,
222,
222,
523... | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"Ċ",
"#",
"Ġ-*-",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ġ-*-",
"Ċ",
"#",
"Ġ=================================================",
"=",
"Ċ",
"#",
"Ġ@",
"Author",
"Ġ:",
"ĠCopyright",
"@",
"Ry",
"uch",
"en",
"Ċ",
"... | [
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
8,
9,
9,
9,
9,
9,
9,
9,
9
] | [
1,
4,
7,
8,
11,
12,
15,
22,
1,
2,
6,
13,
14,
18,
19,
20,
24,
1,
2,
52,
53,
1,
2,
4,
10,
12,
22,
23,
25,
28,
30,
1,
2,
52,
53,
1,
1,
5,
7,
14,
21,
29,
1,
1,
3,
6,
8,
10,
13,
20,
22
] |
eec52695e5afcc21e5fed6453e96cc3a58e7c1df | import micropython
# viper function taking and returning ints
@micropython.viper
def viper_int(x: int, y: int) -> int:
return x + y + 3
print(viper_int(1, 2))
# viper function taking and returning objects
@micropython.viper
def viper_object(x: object, y: object) -> object:
return x + y
print(viper_objec... | [
485,
10314,
2980,
499,
222,
40,
8955,
481,
686,
15170,
480,
14122,
34669,
222,
69,
9465,
2980,
51,
46152,
222,
610,
8955,
481,
100,
429,
45,
125,
63,
648,
49,
553,
63,
648,
46,
984,
648,
63,
303,
461,
837,
494,
553,
494,
244,
56... | [
"import",
"Ġmicro",
"python",
"ĊĊ",
"Ċ",
"#",
"Ġvi",
"per",
"Ġfunction",
"Ġtaking",
"Ġand",
"Ġreturning",
"Ġints",
"Ċ",
"@",
"micro",
"python",
".",
"viper",
"Ċ",
"def",
"Ġvi",
"per",
"_",
"int",
"(",
"x",
":",
"Ġint",
",",
"Ġy",
":",
"Ġint",
")",
... | [
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
12,
13,... | [
1,
7,
13,
19,
1,
1,
2,
5,
8,
17,
24,
28,
38,
43,
1,
2,
7,
13,
14,
19,
1,
4,
7,
10,
11,
14,
15,
16,
17,
21,
22,
24,
25,
29,
30,
33,
37,
38,
4,
11,
13,
15,
17,
19,
20,
21,
1,
1,
6,
7,
12,
13,
16,
17,
18,
19,
... |
9119fc1c75de980bbcf74f1e06a36ba587fc490b | import backtrader as bt
class RSIStrategy(bt.Strategy):
def __init__(self):
self.order = None
self.position.size = 0
self.sellAlert1 = False
self.sellAlert2 = False
self.buyAlert = False
self.failureNum = 0
self.successNum = 0
self.rsi_1 = bt.ind.RSI... | [
485,
1769,
378,
839,
641,
18389,
499,
222,
842,
28774,
1309,
378,
5143,
45,
8057,
51,
8095,
731,
303,
684,
1176,
1683,
3232,
803,
731,
310,
649,
51,
1191,
299,
1686,
310,
649,
51,
2719,
51,
911,
299,
244,
53,
310,
649,
51,
10607,
... | [
"import",
"Ġback",
"tr",
"ader",
"Ġas",
"Ġbt",
"ĊĊ",
"Ċ",
"class",
"ĠRS",
"IS",
"tr",
"ategy",
"(",
"bt",
".",
"Strategy",
"):",
"ĊĠĠĠ",
"Ġdef",
"Ġ__",
"init",
"__(",
"self",
"):",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
".",
"order",
"Ġ=",
"ĠNone",
"ĊĠĠĠĠĠĠĠ",
"Ġself",
... | [
1,
1,
1,
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9,
10,
10,
10,
10,
10,
1... | [
1,
7,
12,
14,
18,
21,
24,
1,
1,
6,
9,
11,
13,
18,
19,
21,
22,
30,
32,
4,
8,
11,
15,
18,
22,
24,
8,
13,
14,
19,
21,
26,
8,
13,
14,
22,
23,
27,
29,
30,
31,
8,
13,
14,
18,
23,
24,
26,
32,
8,
13,
14,
18,
23,
24,
... |
99785ffb4b594db1fac05ca3d3f5764151b2b7b6 | import django
from rest_framework import serializers
from django.shortcuts import render
from .models import Student
from .serializiers import StudentSerializer
from rest_framework.renderers import JSONRenderer
from django.http import HttpResponse, JsonResponse
import io
from rest_framework.parsers import JSONParser
f... | [
485,
8532,
222,
1097,
6125,
100,
2863,
1220,
34229,
222,
1097,
8532,
51,
36264,
1220,
2922,
222,
1097,
657,
3404,
1220,
16660,
222,
1097,
657,
3557,
32059,
502,
1220,
16660,
7271,
222,
1097,
6125,
100,
2863,
51,
3183,
502,
1220,
3411,
... | [
"import",
"Ġdjango",
"Ċ",
"from",
"Ġrest",
"_",
"framework",
"Ġimport",
"Ġserializers",
"Ċ",
"from",
"Ġdjango",
".",
"shortcuts",
"Ġimport",
"Ġrender",
"Ċ",
"from",
"Ġ.",
"models",
"Ġimport",
"ĠStudent",
"Ċ",
"from",
"Ġ.",
"serial",
"izi",
"ers",
"Ġimport",
... | [
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
7,
7,
7,
7,
8,
9,
9,
9,
10,
10,
10,
10,
10,
10,
... | [
1,
7,
14,
1,
5,
10,
11,
20,
27,
39,
1,
5,
12,
13,
22,
29,
36,
1,
5,
7,
13,
20,
28,
1,
5,
7,
13,
16,
19,
26,
34,
44,
1,
5,
10,
11,
20,
21,
27,
30,
37,
42,
50,
1,
5,
12,
13,
17,
24,
37,
38,
51,
1,
1,
7,
10,
... |
cf0eb9685cdfc412871d3b36270ddab3e520bb8f | # -*- coding: utf-8 -*-
# Define here the models for your scraped items
#
# See documentation in:
# http://doc.scrapy.org/en/latest/topics/items.html
import scrapy
class CnnArticleItem(scrapy.Item):
title = scrapy.Field()
developments = scrapy.Field()
body = scrapy.Field()
date = scrapy.Field()
cl... | [
40,
8571,
10633,
63,
6471,
50,
61,
8571,
222,
222,
40,
14181,
2464,
341,
4590,
456,
1390,
33057,
337,
3966,
222,
40,
222,
40,
2819,
4349,
347,
63,
222,
40,
1930,
574,
1446,
51,
37903,
126,
51,
1107,
52,
291,
52,
5341,
52,
16982,
... | [
"#",
"Ġ-*-",
"Ġcoding",
":",
"Ġutf",
"-",
"8",
"Ġ-*-",
"Ċ",
"Ċ",
"#",
"ĠDefine",
"Ġhere",
"Ġthe",
"Ġmodels",
"Ġfor",
"Ġyour",
"Ġscrap",
"ed",
"Ġitems",
"Ċ",
"#",
"Ċ",
"#",
"ĠSee",
"Ġdocumentation",
"Ġin",
":",
"Ċ",
"#",
"Ġhttp",
"://",
"doc",
".",
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
8,
8,
8,
8,
10,
11,
11,
11,
11,
11,
11,
11,
... | [
1,
2,
6,
13,
14,
18,
19,
20,
24,
1,
1,
2,
9,
14,
18,
25,
29,
34,
40,
42,
48,
1,
2,
1,
2,
6,
20,
23,
24,
1,
2,
7,
10,
13,
14,
19,
20,
21,
24,
25,
27,
28,
34,
35,
41,
42,
47,
48,
52,
1,
1,
7,
13,
14,
1,
1,
... |
a42a94798d176e20646d41cf0f4b7e4f99e0790b | import requests
from SPARQLWrapper import SPARQLWrapper, JSON
from rdflib import Graph
from plenum.server.plugin.graphchain.graph_store import GraphStore
from plenum.server.plugin.graphchain.logger import get_debug_logger
logger = get_debug_logger()
class StardogGraphStore(GraphStore):
def __init__(self, ts_db_... | [
485,
5188,
222,
1097,
377,
4200,
2166,
4687,
1220,
377,
4200,
2166,
4687,
49,
3411,
222,
1097,
34526,
1379,
1220,
6478,
222,
222,
1097,
1302,
3880,
51,
1805,
51,
2809,
51,
2275,
5089,
51,
2275,
100,
2173,
1220,
6478,
2796,
222,
1097,
... | [
"import",
"Ġrequests",
"Ċ",
"from",
"ĠS",
"PAR",
"QL",
"Wrapper",
"Ġimport",
"ĠS",
"PAR",
"QL",
"Wrapper",
",",
"ĠJSON",
"Ċ",
"from",
"Ġrdf",
"lib",
"Ġimport",
"ĠGraph",
"Ċ",
"Ċ",
"from",
"Ġpl",
"enum",
".",
"server",
".",
"plugin",
".",
"graph",
"chai... | [
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
8,
8,
8... | [
1,
7,
16,
1,
5,
7,
10,
12,
19,
26,
28,
31,
33,
40,
41,
46,
1,
5,
9,
12,
19,
25,
1,
1,
5,
8,
12,
13,
19,
20,
26,
27,
32,
37,
38,
43,
44,
49,
56,
62,
67,
1,
5,
8,
12,
13,
19,
20,
26,
27,
32,
37,
38,
44,
51,
5... |
7affd79fb0bb47283bbd9a7fbcaa0ba43aa8e6a6 | # Write a program to accept a no & count number of zeros in it.(int=32bits)
def countOfZeros(num):
cnt = 0
while num != 0:
cnt += 1
num = num & (num - 1)
return 32 - cnt
def main():
num = eval(input("Enter number to count zeros in it's binary: "))
print("Assumung int is of 32 bit... | [
40,
5968,
331,
3477,
391,
5531,
331,
1307,
568,
2409,
1470,
451,
22738,
347,
580,
10702,
429,
66,
56,
55,
5966,
46,
499,
222,
610,
2409,
1436,
95,
14731,
45,
1538,
731,
303,
14091,
299,
244,
53,
303,
2236,
1952,
882,
244,
53,
63,
... | [
"#",
"ĠWrite",
"Ġa",
"Ġprogram",
"Ġto",
"Ġaccept",
"Ġa",
"Ġno",
"Ġ&",
"Ġcount",
"Ġnumber",
"Ġof",
"Ġzeros",
"Ġin",
"Ġit",
".(",
"int",
"=",
"3",
"2",
"bits",
")",
"ĊĊ",
"Ċ",
"def",
"Ġcount",
"Of",
"Z",
"eros",
"(",
"num",
"):",
"ĊĠĠĠ",
"Ġcnt",
"Ġ="... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9... | [
1,
2,
8,
10,
18,
21,
28,
30,
33,
35,
41,
48,
51,
57,
60,
63,
65,
68,
69,
70,
71,
75,
76,
1,
1,
4,
10,
12,
13,
17,
18,
21,
23,
4,
8,
10,
11,
12,
4,
10,
14,
17,
18,
19,
20,
8,
12,
15,
16,
17,
8,
12,
14,
18,
20,... |
62a7958ba5ebb6da866d6ef156e52136df22f235 | # =============>This is a Normal mathematical tasks<==========
x = 7
x = 7 // 3 # rounds the number = 2 ans class int
# x = 7 / 3 # gives the floating number = 2.33333335 ans class float
# x = 7 % 3 # gives the reminder = 1 ans class int
# print("x is {}" .format(x))
# print(type(x))
# ================>This is how ... | [
40,
299,
7567,
67,
2287,
458,
331,
13616,
47738,
8285,
65,
18420,
222,
125,
299,
244,
60,
222,
125,
299,
244,
60,
453,
244,
56,
244,
607,
41562,
341,
1470,
299,
244,
55,
12187,
462,
648,
222,
40,
837,
299,
244,
60,
536,
244,
56,... | [
"#",
"Ġ=",
"============",
">",
"This",
"Ġis",
"Ġa",
"ĠNormal",
"Ġmathematical",
"Ġtasks",
"<",
"==========",
"Ċ",
"x",
"Ġ=",
"Ġ",
"7",
"Ċ",
"x",
"Ġ=",
"Ġ",
"7",
"Ġ//",
"Ġ",
"3",
"Ġ",
"Ġ#",
"Ġrounds",
"Ġthe",
"Ġnumber",
"Ġ=",
"Ġ",
"2",
"Ġans",
"Ġcl... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4,
4... | [
1,
2,
4,
16,
17,
21,
24,
26,
33,
46,
52,
53,
63,
1,
2,
4,
5,
6,
1,
2,
4,
5,
6,
9,
10,
11,
12,
14,
21,
25,
32,
34,
35,
36,
40,
46,
50,
1,
2,
4,
6,
7,
8,
10,
11,
12,
13,
15,
21,
25,
34,
41,
43,
44,
45,
46,
... |
0744ec646e7b9303c67c25dff2997568c6171b91 | #!/usr/bin/env python3
#
# nextskeleton - An assembler skeleton for the ZX Spectrum Next
#
# Copyright (C) 2020 Richard "Shred" Körber
# https://github.com/shred/nextskeleton
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You ma... | [
8758,
3392,
52,
1793,
52,
2141,
4406,
56,
222,
40,
222,
40,
2371,
33639,
449,
2262,
31194,
37208,
456,
341,
42813,
32615,
10538,
11006,
222,
40,
222,
40,
2657,
327,
72,
46,
244,
55,
53,
55,
53,
39018,
332,
1207,
1116,
39,
1242,
72... | [
"#!/",
"usr",
"/",
"bin",
"/",
"env",
"Ġpython",
"3",
"Ċ",
"#",
"Ċ",
"#",
"Ġnext",
"skeleton",
"Ġ-",
"ĠAn",
"Ġassembler",
"Ġskeleton",
"Ġfor",
"Ġthe",
"ĠZX",
"ĠSpect",
"rum",
"ĠNext",
"Ċ",
"#",
"Ċ",
"#",
"ĠCopyright",
"Ġ(",
"C",
")",
"Ġ",
"2",
"0",... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
2,
2,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
3,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
5,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
6,
7,
7,
8,
8... | [
1,
4,
7,
8,
11,
12,
15,
22,
23,
1,
2,
1,
2,
7,
15,
17,
20,
30,
39,
43,
47,
50,
56,
59,
64,
1,
2,
1,
2,
12,
14,
15,
16,
17,
18,
19,
20,
21,
29,
31,
33,
36,
37,
39,
41,
44,
1,
2,
4,
10,
13,
19,
20,
23,
24,
26... |
8abfb6a9ca3a7a909a1e8125e8c03e29b2bacda8 | from StockDatabase import StockDatabase
from RNNinner import RecurrentAnalyzer
import torch
import matplotlib.pyplot as plt
import numpy as np
database = StockDatabase()
database.read_data()
prices = torch.tensor(database.normalize(database.get_stock_prices("AAPL", length=2000)))
print(prices.shape)
model = Recurrent... | [
1097,
22460,
3969,
1220,
22460,
3969,
222,
1097,
578,
5863,
3384,
1220,
922,
1719,
17430,
222,
485,
5665,
222,
485,
13168,
51,
18553,
641,
6020,
222,
485,
6610,
641,
2115,
222,
222,
4617,
299,
22460,
3969,
365,
222,
4617,
51,
870,
100... | [
"from",
"ĠStock",
"Database",
"Ġimport",
"ĠStock",
"Database",
"Ċ",
"from",
"ĠR",
"NN",
"inner",
"Ġimport",
"ĠRe",
"current",
"Analyzer",
"Ċ",
"import",
"Ġtorch",
"Ċ",
"import",
"Ġmatplotlib",
".",
"pyplot",
"Ġas",
"Ġplt",
"Ċ",
"import",
"Ġnumpy",
"Ġas",
"Ġn... | [
1,
1,
1,
1,
1,
1,
1,
2,
2,
2,
2,
2,
2,
2,
2,
2,
3,
3,
3,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
6,
7,
7,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
9,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10,
10... | [
1,
5,
11,
19,
26,
32,
40,
1,
5,
7,
9,
14,
21,
24,
31,
39,
1,
7,
13,
1,
7,
18,
19,
25,
28,
32,
1,
7,
13,
16,
19,
1,
1,
9,
11,
17,
25,
27,
1,
9,
10,
14,
15,
19,
21,
1,
1,
7,
9,
15,
16,
22,
23,
31,
32,
41,
4... |
14f309d478de6de5a0b493503176941fdfa8b702 | import cv2
import numpy as np
if __name__ == "__main__":
cap = cv2.VideoCapture()
while True:
ret, frame = cap.read()
cv2.imshow(frame)
| [
485,
6781,
55,
222,
485,
6610,
641,
2115,
222,
222,
344,
1176,
444,
523,
630,
9609,
1850,
18021,
303,
5228,
299,
6781,
55,
51,
6086,
11882,
365,
465,
2236,
2969,
63,
310,
2170,
49,
3145,
299,
5228,
51,
870,
365,
310,
6781,
55,
51,... | [
"import",
"Ġcv",
"2",
"Ċ",
"import",
"Ġnumpy",
"Ġas",
"Ġnp",
"Ċ",
"Ċ",
"if",
"Ġ__",
"name",
"__",
"Ġ==",
"Ġ\"__",
"main",
"__\":",
"ĊĠĠĠ",
"Ġcap",
"Ġ=",
"Ġcv",
"2",
".",
"Video",
"Capture",
"()",
"ĊĊĠĠĠ",
"Ġwhile",
"ĠTrue",
":",
"ĊĠĠĠĠĠĠĠ",
"Ġret",
"... | [
1,
1,
1,
1,
2,
2,
2,
2,
2,
3,
4,
4,
4,
4,
4,
4,
4,
4,
4,
5,
5,
5,
5,
5,
5,
5,
5,
5,
7,
7,
7,
7,
8,
8,
8,
8,
8,
8,
8,
8,
8,
9,
9,
9,
9,
9,
9,
9,
9
] | [
1,
7,
10,
11,
1,
7,
13,
16,
19,
1,
1,
3,
6,
10,
12,
15,
19,
23,
27,
4,
8,
10,
13,
14,
15,
20,
27,
29,
4,
10,
15,
16,
8,
12,
13,
19,
21,
25,
26,
30,
32,
8,
11,
12,
13,
19,
20,
25,
26
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.