content stringlengths 1 1.05M | input_ids sequencelengths 1 883k | ratio_char_token float64 1 22.9 | token_count int64 1 883k |
|---|---|---|---|
from rest_framework_gis import serializers
from rest_framework import serializers as s
from .models import (
Artificialisee2015to2018,
Artificielle2018,
CommunesSybarval,
CouvertureSol,
EnveloppeUrbaine2018,
Ocsge,
Renaturee2018to2015,
Sybarval,
Voirie2018,
ZonesBaties2018,
... | [
6738,
1334,
62,
30604,
62,
70,
271,
1330,
11389,
11341,
198,
6738,
1334,
62,
30604,
1330,
11389,
11341,
355,
264,
198,
198,
6738,
764,
27530,
1330,
357,
198,
220,
220,
220,
35941,
786,
68,
4626,
1462,
7908,
11,
198,
220,
220,
220,
3... | 2.422535 | 142 |
from django.contrib import admin
from .models import SearchResult
# Register your models here.
admin.site.register(SearchResult, SearchResultAdmin) | [
6738,
42625,
14208,
13,
3642,
822,
1330,
13169,
198,
6738,
764,
27530,
1330,
11140,
23004,
198,
198,
2,
17296,
534,
4981,
994,
13,
198,
198,
28482,
13,
15654,
13,
30238,
7,
18243,
23004,
11,
11140,
23004,
46787,
8
] | 3.921053 | 38 |
import asyncio
import os
import tempfile
from contextlib import ExitStack
from typing import Text, Optional, List, Union, Dict
from rasa.importers.importer import TrainingDataImporter
from rasa import model
from rasa.model import FingerprintComparisonResult
from rasa.core.domain import Domain
from rasa.utils.common im... | [
11748,
30351,
952,
198,
11748,
28686,
198,
11748,
20218,
7753,
198,
6738,
4732,
8019,
1330,
29739,
25896,
198,
6738,
19720,
1330,
8255,
11,
32233,
11,
7343,
11,
4479,
11,
360,
713,
198,
198,
6738,
374,
15462,
13,
320,
1819,
1010,
13,
... | 2.385246 | 976 |
# ============================================================================
# FILE: default.py
# AUTHOR: Shougo Matsushita <Shougo.Matsu at gmail.com>
# License: MIT license
# ============================================================================
import re
import typing
from denite.util import echo, error, c... | [
2,
38093,
2559,
18604,
198,
2,
45811,
25,
4277,
13,
9078,
198,
2,
44746,
25,
911,
280,
2188,
30107,
1530,
5350,
1279,
2484,
280,
2188,
13,
44,
19231,
379,
308,
4529,
13,
785,
29,
198,
2,
13789,
25,
17168,
5964,
198,
2,
38093,
2559... | 4.460784 | 102 |
# -*- coding: utf-8 -*-
"""Context managers implemented for (mostly) internal use"""
import contextlib
import functools
from io import UnsupportedOperation
import os
import sys
__all__ = ["RedirectStdout", "RedirectStderr"]
RedirectStdout = functools.partial(_stdchannel_redirected, sys.stdout)
RedirectStderr = f... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
37811,
21947,
11663,
9177,
329,
357,
29471,
8,
5387,
779,
37811,
198,
198,
11748,
4732,
8019,
198,
11748,
1257,
310,
10141,
198,
6738,
33245,
1330,
791,
15999,
32180,... | 3.013699 | 146 |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from . import __version__ as app_version
app_name = "pos_kiosk"
app_title = "Pos Kiosk"
app_publisher = "9t9it"
app_description = "Kiosk App"
app_icon = "octicon octicon-file-directory"
app_color = "grey"
app_email = "info@9t9it.com"
app_license = "MIT"
... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
6738,
11593,
37443,
834,
1330,
28000,
1098,
62,
17201,
874,
198,
6738,
764,
1330,
11593,
9641,
834,
355,
598,
62,
9641,
198,
198,
1324,
62,
3672,
796,
366,
1930,
62,
4... | 2.319625 | 1,386 |
from keras import Model, Input
from keras.layers import Dense, concatenate, LSTM, Reshape, Permute, Embedding, Dropout, Convolution1D, Flatten
from keras.optimizers import Adam
from pypagai.models.base import KerasModel
| [
6738,
41927,
292,
1330,
9104,
11,
23412,
198,
6738,
41927,
292,
13,
75,
6962,
1330,
360,
1072,
11,
1673,
36686,
378,
11,
406,
2257,
44,
11,
1874,
71,
1758,
11,
2448,
76,
1133,
11,
13302,
6048,
278,
11,
14258,
448,
11,
34872,
2122,
... | 3.027027 | 74 |
from .fully_connected import FullyConnectedLatentVariable
from .convolutional import ConvolutionalLatentVariable
| [
6738,
764,
2759,
62,
15236,
1330,
40234,
13313,
276,
24220,
298,
43015,
198,
6738,
764,
42946,
2122,
282,
1330,
34872,
2122,
282,
24220,
298,
43015,
198
] | 4.346154 | 26 |
#!/usr/bin/env python
# -*- coding:utf-8 -*-
# Author:
''' PNASNet in PyTorch.
Paper: Progressive Neural Architecture Search
'''
from easyai.base_name.block_name import NormalizationType, ActivationType
from easyai.base_name.backbone_name import BackboneName
from easyai.model.backbone.utility.base_backbone import *
fr... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
2,
532,
9,
12,
19617,
25,
40477,
12,
23,
532,
9,
12,
198,
2,
6434,
25,
198,
7061,
6,
350,
18293,
7934,
287,
9485,
15884,
354,
13,
198,
42950,
25,
25852,
47986,
29778,
11140,
198,
... | 2.891429 | 175 |
# -*- coding: utf-8 -*-
# coding=utf-8
import json
import os
import math
import logging
import requests
import time
from map_download.cmd.BaseDownloader import DownloadEngine, BaseDownloaderThread, latlng2tile_terrain, BoundBox
if __name__ == '__main__':
if 1:
logger = logging.getLogger('down')
... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
220,
19617,
28,
40477,
12,
23,
198,
11748,
33918,
198,
11748,
28686,
198,
11748,
10688,
198,
11748,
18931,
198,
11748,
7007,
198,
11748,
640,
198,
198,
6738,
3975,
62... | 2.001536 | 651 |
# coding: utf-8
"""
Kubernetes
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
OpenAPI spec version: v1.12.4
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
from __future__ import absolute_import
import r... | [
2,
19617,
25,
3384,
69,
12,
23,
198,
198,
37811,
198,
220,
220,
220,
12554,
527,
3262,
274,
628,
220,
220,
220,
1400,
6764,
2810,
357,
27568,
416,
2451,
7928,
6127,
5235,
3740,
1378,
12567,
13,
785,
14,
2032,
7928,
12,
15042,
14,
... | 2.84375 | 160 |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Fri Nov 10 23:28:58 2017
@author: dhingratul
"""
import urllib.request
import os
from selenium import webdriver
from selenium.webdriver.support.ui import Select
from bs4 import BeautifulSoup
import ssl
import requests
import wget
from PyPDF2 import PdfFileR... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
37811,
198,
41972,
319,
19480,
5267,
838,
2242,
25,
2078,
25,
3365,
2177,
198,
198,
31,
9800,
25,
288,
722,
10366... | 2.457627 | 236 |
"""
Experiment summary
------------------
Treat each province/state in a country cases over time
as a vector, do a simple K-Nearest Neighbor between
countries. What country has the most similar trajectory
to a given country?
Plots similar countries
"""
import sys
sys.path.insert(0, '..')
from utils import data
impor... | [
37811,
198,
20468,
3681,
10638,
198,
1783,
438,
198,
51,
630,
1123,
8473,
14,
5219,
287,
257,
1499,
2663,
625,
640,
198,
292,
257,
15879,
11,
466,
257,
2829,
509,
12,
8199,
12423,
28708,
1022,
198,
9127,
1678,
13,
1867,
1499,
468,
2... | 2.580475 | 758 |
"""
Rational Activation Functions for MXNET
=======================================
This module allows you to create Rational Neural Networks using Learnable
Rational activation functions with MXNET networks.
"""
import mxnet as mx
from mxnet import initializer
from mxnet.gluon import HybridBlock
from rational.utils.... | [
37811,
198,
49,
864,
13144,
341,
40480,
329,
26135,
12884,
198,
10052,
1421,
18604,
198,
198,
1212,
8265,
3578,
345,
284,
2251,
46863,
47986,
27862,
1262,
14365,
540,
198,
49,
864,
14916,
5499,
351,
26135,
12884,
7686,
13,
198,
37811,
1... | 3.944 | 125 |
"""Utils for criterion."""
import torch
import torch.nn.functional as F
def normalize(x, axis=-1):
"""Performs L2-Norm."""
num = x
denom = torch.norm(x, 2, axis, keepdim=True).expand_as(x) + 1e-12
return num / denom
# Source : https://github.com/earhian/Humpback-Whale-Identification-1st-/blob/master... | [
37811,
18274,
4487,
329,
34054,
526,
15931,
198,
11748,
28034,
198,
11748,
28034,
13,
20471,
13,
45124,
355,
376,
628,
198,
4299,
3487,
1096,
7,
87,
11,
16488,
10779,
16,
2599,
198,
220,
220,
220,
37227,
5990,
23914,
406,
17,
12,
3539... | 2.197917 | 384 |
"""Tests for the sbahn_munich integration"""
line_dict = {
"name": "S3",
"color": "#333333",
"text_color": "#444444",
}
| [
37811,
51,
3558,
329,
262,
264,
65,
15386,
62,
6199,
488,
11812,
37811,
628,
198,
1370,
62,
11600,
796,
1391,
198,
220,
220,
220,
366,
3672,
1298,
366,
50,
18,
1600,
198,
220,
220,
220,
366,
8043,
1298,
25113,
24840,
2091,
1600,
198... | 2.271186 | 59 |
#! /usr/bin/env python2.7
# -*- coding: latin-1 -*-
from flask import Blueprint
from flask import current_app
from flask import render_template
from flask_login import login_required
homestack = Blueprint("homestack", __name__, url_prefix="/homestack")
| [
2,
0,
1220,
14629,
14,
8800,
14,
24330,
21015,
17,
13,
22,
198,
2,
532,
9,
12,
19617,
25,
3042,
259,
12,
16,
532,
9,
12,
198,
198,
6738,
42903,
1330,
39932,
198,
6738,
42903,
1330,
1459,
62,
1324,
198,
6738,
42903,
1330,
8543,
6... | 3.17284 | 81 |
"""Forms for RTD donations"""
import logging
from django import forms
from django.conf import settings
from django.utils.translation import ugettext_lazy as _
from readthedocs.payments.forms import StripeModelForm, StripeResourceMixin
from readthedocs.payments.utils import stripe
from .models import Supporter
log ... | [
37811,
8479,
82,
329,
11923,
35,
10976,
37811,
198,
198,
11748,
18931,
198,
198,
6738,
42625,
14208,
1330,
5107,
198,
6738,
42625,
14208,
13,
10414,
1330,
6460,
198,
6738,
42625,
14208,
13,
26791,
13,
41519,
1330,
334,
1136,
5239,
62,
7... | 3.320755 | 106 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from .base import DataReaderBase
from ..tools import COL, _get_dates, to_float, to_int
import pandas as pd
#from pandas.tseries.frequencies import to_offset
from six.moves import cStringIO as StringIO
import logging
import traceback
import datetime
import json
import tok... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
6738,
764,
8692,
1330,
6060,
33634,
14881,
198,
6738,
11485,
31391,
1330,
20444,
11,
4808,
1136,
62,
19581,
11,
28... | 2.140267 | 1,048 |
# !/usr/bin/python
# -*- coding: utf-8 -*-
# @time : 2019/11/2 21:08
# @author : Mo
# @function:
from keras_textclassification.data_preprocess.text_preprocess import load_json, save_json
from keras_textclassification.conf.path_config import path_model_dir
path_fast_text_model_vocab2index = path_model_dir + 'vocab... | [
2,
5145,
14,
14629,
14,
8800,
14,
29412,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
2488,
2435,
220,
220,
220,
1058,
13130,
14,
1157,
14,
17,
2310,
25,
2919,
198,
2,
2488,
9800,
220,
1058,
4270,
198,
... | 2.505814 | 172 |
# Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
from gpu_tests.gpu_test_expectations import GpuTestExpectations
# See the GpuTestExpectations class for documentation.
| [
2,
15069,
1946,
383,
18255,
1505,
46665,
13,
1439,
2489,
10395,
13,
198,
2,
5765,
286,
428,
2723,
2438,
318,
21825,
416,
257,
347,
10305,
12,
7635,
5964,
326,
460,
307,
198,
2,
1043,
287,
262,
38559,
24290,
2393,
13,
198,
198,
6738,... | 3.628205 | 78 |
# -*- coding: utf-8 -*-
# Generated by Django 1.11.13 on 2018-06-08 22:54
from __future__ import unicode_literals
from django.conf import settings
import django.contrib.postgres.fields.jsonb
from django.db import migrations, models
import django.db.models.deletion
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
2980,
515,
416,
37770,
352,
13,
1157,
13,
1485,
319,
2864,
12,
3312,
12,
2919,
2534,
25,
4051,
198,
6738,
11593,
37443,
834,
1330,
28000,
1098,
62,
17201,
874,
198,... | 2.902174 | 92 |
import setuptools #enables develop
setuptools.setup(
name='pysvm',
version='0.1',
description='PySVM : A NumPy implementation of SVM based on SMO algorithm',
author_email="191300064@smail.nju.edu.cn",
packages=['pysvm'],
license='MIT License',
long_description=open('README.md', encoding='u... | [
11748,
900,
37623,
10141,
220,
1303,
268,
2977,
1205,
198,
198,
2617,
37623,
10141,
13,
40406,
7,
198,
220,
220,
220,
1438,
11639,
79,
893,
14761,
3256,
198,
220,
220,
220,
2196,
11639,
15,
13,
16,
3256,
198,
220,
220,
220,
6764,
11... | 2.445055 | 182 |
######## Image Object Detection Using Tensorflow-trained Classifier #########
#
# Author: Evan Juras
# Date: 1/15/18
# Description:
# This program uses a TensorFlow-trained classifier to perform object detection.
# It loads the classifier uses it to perform object detection on an image.
# It draws boxes and scores aro... | [
7804,
7412,
9515,
46254,
8554,
309,
22854,
11125,
12,
35311,
5016,
7483,
1303,
7804,
198,
2,
198,
2,
6434,
25,
21523,
449,
17786,
198,
2,
7536,
25,
352,
14,
1314,
14,
1507,
198,
2,
12489,
25,
220,
198,
2,
770,
1430,
3544,
257,
309... | 3.122769 | 1,401 |
from data_collection.management.commands import BaseXpressDemocracyClubCsvImporter
| [
6738,
1366,
62,
43681,
13,
27604,
13,
9503,
1746,
1330,
7308,
55,
8439,
11522,
17818,
42350,
34,
21370,
3546,
26634,
198
] | 3.952381 | 21 |
from django.db.models import Q
from django.shortcuts import render
from django.http import Http404
# Create your views here.
from rest_framework.views import APIView
from rest_framework.response import Response
from rest_framework.decorators import api_view
from .models import Product, Category
from .serializers imp... | [
6738,
42625,
14208,
13,
9945,
13,
27530,
1330,
1195,
198,
198,
6738,
42625,
14208,
13,
19509,
23779,
1330,
8543,
198,
6738,
42625,
14208,
13,
4023,
1330,
367,
29281,
26429,
198,
198,
2,
13610,
534,
5009,
994,
13,
198,
6738,
1334,
62,
... | 3.923913 | 92 |
from sys import maxsize
| [
6738,
25064,
1330,
3509,
7857,
628,
198
] | 3.714286 | 7 |
##########################################################################
#
# Copyright (c) 2010-2012, Image Engine Design Inc. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redis... | [
29113,
29113,
7804,
2235,
198,
2,
198,
2,
220,
15069,
357,
66,
8,
3050,
12,
6999,
11,
7412,
7117,
8495,
3457,
13,
1439,
2489,
10395,
13,
198,
2,
198,
2,
220,
2297,
396,
3890,
290,
779,
287,
2723,
290,
13934,
5107,
11,
351,
393,
... | 3.498195 | 554 |
"""Pacman game domain."""
from rlpy.Tools import __rlpy_location__
from .Domain import Domain
from .PacmanPackage import layout, pacman, game, ghostAgents
from .PacmanPackage import graphicsDisplay
import numpy as np
from copy import deepcopy
import os
import time
__copyright__ = "Copyright 2013, RLPy http://acl.mit.e... | [
37811,
18844,
805,
983,
7386,
526,
15931,
198,
6738,
374,
75,
9078,
13,
33637,
1330,
11593,
45895,
9078,
62,
24886,
834,
198,
6738,
764,
43961,
1330,
20021,
198,
6738,
764,
18844,
805,
27813,
1330,
12461,
11,
23503,
805,
11,
983,
11,
... | 2.942529 | 174 |
from zeit.cms.i18n import MessageFactory as _
import zope.interface
import zope.schema
| [
6738,
41271,
270,
13,
46406,
13,
72,
1507,
77,
1330,
16000,
22810,
355,
4808,
198,
11748,
1976,
3008,
13,
39994,
198,
11748,
1976,
3008,
13,
15952,
2611,
628
] | 3.142857 | 28 |
N, M = map(int, input().split())
for i in range(1, M + 1):
if i % 2 == 1:
j = (i - 1) // 2
print(1 + j, M + 1 - j)
else:
j = (i - 2) // 2
print(M + 2 + j, 2 * M + 1 - j)
| [
45,
11,
337,
796,
3975,
7,
600,
11,
5128,
22446,
35312,
28955,
198,
198,
1640,
1312,
287,
2837,
7,
16,
11,
337,
1343,
352,
2599,
198,
220,
220,
220,
611,
1312,
4064,
362,
6624,
352,
25,
198,
220,
220,
220,
220,
220,
220,
220,
47... | 1.743802 | 121 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
220,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
345,
743,
198,
2,
220,
... | 2.744186 | 645 |
# coding=utf-8
# Copyright (c) Facebook, Inc. and its affiliates.
# Copyright (c) HuggingFace Inc. team.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses... | [
2,
19617,
28,
40477,
12,
23,
198,
2,
15069,
357,
66,
8,
3203,
11,
3457,
13,
290,
663,
29116,
13,
198,
2,
15069,
357,
66,
8,
12905,
2667,
32388,
3457,
13,
1074,
13,
198,
2,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
... | 2.849831 | 2,657 |
from abc import (
ABC,
abstractmethod,
)
import logging
from typing import (
TYPE_CHECKING,
Tuple,
Type,
)
from eth._utils.datatypes import (
Configurable,
)
from eth.db.backends.base import (
BaseAtomicDB,
)
from eth.exceptions import (
BlockNotFound,
)
from eth.validation import (
... | [
6738,
450,
66,
1330,
357,
198,
220,
220,
220,
9738,
11,
198,
220,
220,
220,
12531,
24396,
11,
198,
8,
198,
11748,
18931,
198,
6738,
19720,
1330,
357,
198,
220,
220,
220,
41876,
62,
50084,
2751,
11,
198,
220,
220,
220,
309,
29291,
... | 2.345961 | 2,587 |
#!/usr/local/bin/python3
import paramiko,time
#using as SSH Client
client = paramiko.SSHClient()
# check dir(client) to find available options.
# auto adjust host key verification with yes or no
client.set_missing_host_key_policy(paramiko.AutoAddPolicy())
# time for connecting to remote Cisco IOS
"""
Manually taki... | [
2,
48443,
14629,
14,
12001,
14,
8800,
14,
29412,
18,
198,
198,
11748,
5772,
12125,
11,
2435,
198,
198,
2,
3500,
355,
33825,
20985,
198,
198,
16366,
796,
5772,
12125,
13,
5432,
39,
11792,
3419,
198,
198,
2,
2198,
26672,
7,
16366,
8,
... | 2.658744 | 589 |
# for n in range(400,500):
# i = n // 100
# j = n // 10 % 10
# k = n % 10
# if n == i ** 3 + j ** 3 + k ** 3:
# print(n)
# (16)
# input("():")
# s1 = input("():")
# l1 = s1.split(' ')
# l2 = []
# for i in l1:
# if i.isdigit():
# l2.append(int(i))
# for i in l2:
# if not (i % ... | [
2,
329,
299,
287,
2837,
7,
7029,
11,
4059,
2599,
198,
2,
220,
220,
220,
220,
1312,
796,
299,
3373,
1802,
198,
2,
220,
220,
220,
220,
474,
796,
299,
3373,
838,
4064,
838,
198,
2,
220,
220,
220,
220,
479,
796,
299,
4064,
838,
19... | 1.74902 | 255 |
"""
A query transformer is a function that accepts a program and returns a program, plus a priority level.
Higher priority transformers are placed closer to the front of the list. Were ensuring is a function,
because were going to evaluate it later 31 .
Well assume there wont be an enormous number of transformer additi... | [
37811,
198,
32,
12405,
47385,
318,
257,
2163,
326,
18178,
257,
1430,
290,
5860,
257,
1430,
11,
5556,
257,
8475,
1241,
13,
198,
48708,
8475,
6121,
364,
389,
4624,
5699,
284,
262,
2166,
286,
262,
1351,
13,
15176,
13359,
318,
257,
2163,
... | 2.632979 | 752 |
#!/usr/bin/python3.6.8+
# -*- coding:utf-8 -*-
"""
@auth: cml
@date: 2020-12-2
@desc: ...
"""
| [
2,
48443,
14629,
14,
8800,
14,
29412,
18,
13,
21,
13,
23,
10,
198,
2,
532,
9,
12,
19617,
25,
40477,
12,
23,
532,
9,
12,
198,
37811,
198,
31,
18439,
25,
269,
4029,
198,
31,
4475,
25,
12131,
12,
1065,
12,
17,
198,
31,
20147,
2... | 1.846154 | 52 |
# -*- coding: utf-8 -*-
"""
pyboleto.html
~~~~~~~~~~~~~
Classe Responsvel por fazer o output do boleto em html.
:copyright: 2012 by Artur Felipe de Sousa
:license: BSD, see LICENSE for more details.
"""
import os
import string
import sys
import codecs
import base64
from itertools import chain
i... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
37811,
198,
220,
220,
220,
12972,
45693,
1462,
13,
6494,
198,
220,
220,
220,
220,
15116,
8728,
93,
628,
220,
220,
220,
1012,
21612,
20549,
626,
16964,
277,
19178,
267,
... | 2.09204 | 402 |
summary = 0
i = 0
while i < 5:
summary = summary + i
print(summary)
i = i + 1
| [
49736,
796,
657,
198,
198,
72,
796,
657,
198,
4514,
1312,
1279,
642,
25,
198,
220,
220,
220,
10638,
796,
10638,
1343,
1312,
198,
220,
220,
220,
3601,
7,
49736,
8,
198,
220,
220,
220,
1312,
796,
1312,
1343,
352,
198
] | 2.219512 | 41 |
import imtreat
img = imtreat.imageManagerClass.openImageFunction("../images/soleil.png", 0)
img = imtreat.definedModesClass.detailEnhanceFunction(img)
imtreat.imageManagerClass.saveImageFunction("/Tlchargements/", "image_1", ".png", img)
| [
11748,
545,
83,
630,
198,
198,
9600,
796,
545,
83,
630,
13,
9060,
13511,
9487,
13,
9654,
5159,
22203,
7203,
40720,
17566,
14,
6753,
346,
13,
11134,
1600,
657,
8,
198,
198,
9600,
796,
545,
83,
630,
13,
23211,
44,
4147,
9487,
13,
49... | 2.939024 | 82 |
# Copyright (c) 2016 TUBITAK BILGEM
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless requir... | [
2,
15069,
357,
66,
8,
1584,
309,
10526,
2043,
10206,
347,
4146,
38,
3620,
198,
2,
1439,
6923,
33876,
13,
198,
2,
198,
2,
220,
220,
220,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
345,
743,... | 3.21266 | 3,207 |
import requests
words_list = requests.get("https://raw.githubusercontent.com/atebits/Words/master/Words/fr.txt").text
words_list = filter(lambda x: len(x) > 4, words_list.split('\n'))
path = input("Chemin d'criture ? (words.txt) ")
if path == "":
path = "./words.txt"
with open(path, "w", encoding="utf-8") as f... | [
11748,
7007,
198,
198,
10879,
62,
4868,
796,
7007,
13,
1136,
7203,
5450,
1378,
1831,
13,
12567,
43667,
13,
785,
14,
378,
9895,
14,
37117,
14,
9866,
14,
37117,
14,
8310,
13,
14116,
11074,
5239,
198,
198,
10879,
62,
4868,
796,
8106,
7... | 2.623188 | 138 |
import unittest
from unittest import mock
import os
import subprocess
from testfixtures import TempDirectory
from simplegallery.upload.uploader_factory import get_uploader
if __name__ == '__main__':
unittest.main()
| [
11748,
555,
715,
395,
198,
6738,
555,
715,
395,
1330,
15290,
198,
11748,
28686,
198,
11748,
850,
14681,
198,
6738,
1332,
69,
25506,
1330,
24189,
43055,
198,
6738,
2829,
24460,
13,
25850,
13,
25850,
263,
62,
69,
9548,
1330,
651,
62,
25... | 3.313433 | 67 |
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'add_subject.ui'
#
# Created by: PyQt4 UI code generator 4.11.4
#
# WARNING! All changes made in this file will be lost!
from PyQt4 import QtCore, QtGui
try:
_fromUtf8 = QtCore.QString.fromUtf8
except AttributeError:
try:... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
201,
198,
201,
198,
2,
5178,
7822,
7560,
422,
3555,
334,
72,
2393,
705,
2860,
62,
32796,
13,
9019,
6,
201,
198,
2,
201,
198,
2,
15622,
416,
25,
9485,
48,
83,
19,
12454,... | 2.302817 | 284 |
from django.db.models import signals
from django.test import TestCase
from django.core import management
from django.utils import six
from shared_models import models
PRE_SYNCDB_ARGS = ['app', 'create_models', 'verbosity', 'interactive', 'db']
SYNCDB_DATABASE = 'default'
SYNCDB_VERBOSITY = 1
SYNCDB_INTERACTIVE = Fal... | [
6738,
42625,
14208,
13,
9945,
13,
27530,
1330,
10425,
198,
6738,
42625,
14208,
13,
9288,
1330,
6208,
20448,
198,
6738,
42625,
14208,
13,
7295,
1330,
4542,
198,
6738,
42625,
14208,
13,
26791,
1330,
2237,
198,
198,
6738,
4888,
62,
27530,
... | 3.273109 | 238 |
# Copyright The PyTorch Lightning team.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to i... | [
2,
15069,
383,
9485,
15884,
354,
12469,
1074,
13,
198,
2,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
198,
2,
345,
743,
407,
779,
428,
2393,
2845,
287,
11846,
351,
262,
13789,
13,
1... | 3.782828 | 198 |
#!/usr/bin/env python
import time
import os
import math
from trackball import TrackBall
print("""Trackball: Mouse
Use the trackball as a mouse in Raspbian, with right-click
when the switch is pressed.
Press Ctrl+C to exit!
""")
trackball = TrackBall(interrupt_pin=4)
trackball.set_rgbw(0, 0, 0, 0)
# Check for xte (... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
11748,
640,
198,
11748,
28686,
198,
11748,
10688,
198,
6738,
2610,
1894,
1330,
17762,
23410,
198,
198,
4798,
7203,
15931,
24802,
1894,
25,
21839,
198,
198,
11041,
262,
2610,
1894,
355,
2... | 2.404145 | 386 |
"""GaussianMLPRegressorModel."""
import numpy as np
import tensorflow as tf
import tensorflow_probability as tfp
from garage.experiment import deterministic
from garage.tf.models import GaussianMLPModel
| [
37811,
35389,
31562,
5805,
4805,
1533,
44292,
17633,
526,
15931,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
11192,
273,
11125,
355,
48700,
198,
11748,
11192,
273,
11125,
62,
1676,
65,
1799,
355,
256,
46428,
198,
198,
6738,
15591,
13,... | 3.474576 | 59 |
import torch
import torch.nn as nn
import torch.optim as optim
import torch.nn.functional as F
import torch.backends.cudnn as cudnn
import torchvision
import torchvision.transforms as transforms
import torchvision.datasets as datasets
import os
import argparse
from torch.autograd import Variable
from e... | [
11748,
28034,
201,
198,
11748,
28034,
13,
20471,
355,
299,
77,
201,
198,
11748,
28034,
13,
40085,
355,
6436,
201,
198,
11748,
28034,
13,
20471,
13,
45124,
355,
376,
201,
198,
11748,
28034,
13,
1891,
2412,
13,
66,
463,
20471,
355,
269,... | 2.402585 | 1,083 |
"""Model Parameters Module."""
import torch.optim as optim
from .search import SamplingSearch, GreedySearch, BeamSearch
SEARCH_FACTORY = {
'sampling': SamplingSearch,
'greedy': GreedySearch,
'beam': BeamSearch,
}
OPTIMIZER_FACTORY = {
'adadelta': optim.Adadelta,
'adagrad': optim.Adagrad,
'adam... | [
37811,
17633,
40117,
19937,
526,
15931,
198,
11748,
28034,
13,
40085,
355,
6436,
198,
6738,
764,
12947,
1330,
3409,
11347,
18243,
11,
11955,
4716,
18243,
11,
25855,
18243,
198,
198,
5188,
31315,
62,
37,
10659,
15513,
796,
1391,
198,
220,
... | 2.404624 | 173 |
#
# Copyright (c) 2021 The GPflux Contributors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agr... | [
2,
198,
2,
15069,
357,
66,
8,
33448,
383,
14714,
69,
22564,
25767,
669,
13,
198,
2,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
198,
2,
345,
743,
407,
779,
428,
2393,
2845,
287,
1... | 3.170213 | 564 |
#!/usr/bin/env python
#
from actingweb import actor
from actingweb import config
from actingweb import trust
from actingweb import auth
import webapp2
import os
from google.appengine.ext.webapp import template
import json
import logging
import datetime
import time
# /trust handlers
#
# GET /trust with query paramet... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
2,
198,
6738,
7205,
12384,
1330,
8674,
198,
6738,
7205,
12384,
1330,
4566,
198,
6738,
7205,
12384,
1330,
3774,
198,
6738,
7205,
12384,
1330,
6284,
198,
198,
11748,
3992,
1324,
17,
198,
... | 3.332721 | 544 |
End of preview. Expand in Data Studio
README.md exists but content is empty.
- Downloads last month
- 18