content stringlengths 1 1.04M | input_ids listlengths 1 774k | ratio_char_token float64 0.38 22.9 | token_count int64 1 774k |
|---|---|---|---|
import os
import logging
from gamechangerml.api.fastapi.model_config import Config
logger = logging.getLogger()
| [
11748,
28686,
198,
11748,
18931,
198,
6738,
983,
354,
2564,
4029,
13,
15042,
13,
7217,
15042,
13,
19849,
62,
11250,
1330,
17056,
198,
198,
6404,
1362,
796,
18931,
13,
1136,
11187,
1362,
3419,
628
] | 3.352941 | 34 |
# Licensed under a 3-clause BSD style license - see PYFITS.rst
import warnings
from ...extern import six
from ...utils.compat.numpycompat import NUMPY_LT_1_10
from ...utils.exceptions import AstropyUserWarning
if not six.PY2:
# Stuff to do if Python 3
# Make the decode_ascii utility function actually work
... | [
2,
49962,
739,
257,
513,
12,
565,
682,
347,
10305,
3918,
5964,
532,
766,
350,
56,
37,
29722,
13,
81,
301,
198,
198,
11748,
14601,
198,
6738,
2644,
1069,
759,
1330,
2237,
198,
6738,
2644,
26791,
13,
5589,
265,
13,
77,
32152,
5589,
... | 2.567708 | 384 |
# -*- coding: utf-8 -*-
"""
Script Name: GraphicPathItem.py
Author: Do Trinh/Jimmy - 3D artist.
Description:
"""
# -------------------------------------------------------------------------------------------------------------
""" Import """
from PySide2.QtWidgets import QGraphicsPathItem
from py... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
37811,
198,
198,
7391,
6530,
25,
43029,
15235,
7449,
13,
9078,
198,
13838,
25,
2141,
33822,
71,
14,
40335,
532,
513,
35,
6802,
13,
198,
198,
11828,
25,
198,
198,
37811... | 3.913907 | 151 |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# @trojanzhex
from pyrogram import filters
from pyrogram import Client as trojanz
from pyrogram.types import InlineKeyboardMarkup, InlineKeyboardButton
from config import Config
from script import Script
@trojanz.on_message(filters.private & (filters.docu... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
201,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
201,
198,
2,
2488,
23528,
13881,
89,
33095,
201,
198,
201,
198,
201,
198,
6738,
12972,
39529,
1330,
16628,
201,
1... | 2.866667 | 120 |
from paraview.simple import *
# Load the distributed plugin.
LoadDistributedPlugin("VTKmFilters" , remote=False, ns=globals())
assert VTKmContour
| [
6738,
1582,
615,
769,
13,
36439,
1330,
1635,
198,
198,
2,
8778,
262,
9387,
13877,
13,
198,
8912,
20344,
6169,
37233,
7203,
36392,
42,
76,
11928,
1010,
1,
837,
6569,
28,
25101,
11,
36545,
28,
4743,
672,
874,
28955,
198,
198,
30493,
3... | 3.083333 | 48 |
from __future__ import print_function
import os
import time
import sys
sys.path.append("..")
import tensorflow as tf
import keras.backend.tensorflow_backend as KTF
gpu_frac = 0.7
def get_session(gpu_fraction=gpu_frac):
'''Assume that you have 6GB of GPU memory and want to allocate ~2GB then gpu_frac=0.3 '''
... | [
6738,
11593,
37443,
834,
1330,
3601,
62,
8818,
198,
198,
11748,
28686,
198,
11748,
640,
198,
198,
11748,
25064,
198,
17597,
13,
6978,
13,
33295,
7203,
492,
4943,
198,
198,
11748,
11192,
273,
11125,
355,
48700,
198,
11748,
41927,
292,
13... | 2.769231 | 494 |
#!/usr/bin/env python
import argparse
import subprocess
import sqlite3 as sql
from LLC_Membranes.llclib import topology, file_rw
from LLC_Membranes.analysis import solute_partitioning
from LLC_Membranes.setup import lc_class, equil, solvate_tails
import mdtraj as md
import numpy as np
import os
if __name__ == "__m... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
198,
11748,
1822,
29572,
198,
11748,
850,
14681,
198,
11748,
44161,
578,
18,
355,
44161,
198,
6738,
11419,
62,
13579,
1671,
7305,
13,
297,
565,
571,
1330,
1353,
1435,
11,
2393,
62,
316... | 2.252618 | 764 |
from anarcho import app
from flask import jsonify
from flask_swagger import swagger
@app.route('/swagger/spec.json', methods=['GET'])
def spec():
"""
Returns the swagger spec.
Read more by this link https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md
:return:
"""
swag = swa... | [
6738,
14061,
78,
1330,
598,
198,
6738,
42903,
1330,
33918,
1958,
198,
6738,
42903,
62,
2032,
7928,
1330,
1509,
7928,
628,
198,
31,
1324,
13,
38629,
10786,
14,
2032,
7928,
14,
16684,
13,
17752,
3256,
5050,
28,
17816,
18851,
6,
12962,
1... | 2.637363 | 182 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
'''
Copyright 2020, Yutong Xie, UIUC.
Using Two Pointers to find the interval intersection.
'''
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
7061,
6,
198,
220,
220,
220,
15069,
12131,
11,
575,
315,
506,
48989,
11,
12454,
9598,
13,
198,
220,
220,
220,
8554,
... | 2.62069 | 58 |
import asyncio
import json
import os
import sys
import multiprocessing
import webbrowser
import requests
import requests.cookies
import logging as log
import subprocess
import time
from galaxy.api.consts import LocalGameState, Platform
from galaxy.api.plugin import Plugin, create_and_run_plugin
from galaxy.api.types ... | [
11748,
30351,
952,
198,
11748,
33918,
198,
11748,
28686,
198,
11748,
25064,
198,
11748,
18540,
305,
919,
278,
198,
11748,
3992,
40259,
198,
11748,
7007,
198,
11748,
7007,
13,
27916,
444,
198,
11748,
18931,
355,
2604,
198,
11748,
850,
1468... | 2.874564 | 574 |
# Copyright (C) 2017 Beijing Didi Infinity Technology and Development Co.,Ltd.
# 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/LI... | [
2,
15069,
357,
34,
8,
2177,
11618,
7731,
72,
22385,
8987,
290,
7712,
1766,
1539,
43,
8671,
13,
198,
2,
1439,
2489,
10395,
13,
198,
2,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
198... | 2.700394 | 761 |
from django.urls import path
from rest_framework.authtoken import views as drf_views
from . import views
from . import api_views
urlpatterns = [
path('users/', api_views.UserList.as_view()),
path('users/<int:id>/', api_views.UserRetrieveUpdate.as_view()),
]
| [
6738,
42625,
14208,
13,
6371,
82,
1330,
3108,
198,
6738,
1334,
62,
30604,
13,
18439,
30001,
1330,
5009,
355,
1553,
69,
62,
33571,
198,
6738,
764,
1330,
5009,
198,
6738,
764,
1330,
40391,
62,
33571,
198,
198,
6371,
33279,
82,
796,
685,... | 2.810526 | 95 |
import numpy as np
import pandas as pd
class Cake:
"""example"""
x=2
class Datacleaner:
""""class for cleaning our data"""
def replace_values(self, value=np.nan, new=0):
"""replace values in a dataframe"""
self.df = self.df.replace(value, new)
| [
11748,
299,
32152,
355,
45941,
198,
11748,
19798,
292,
355,
279,
67,
198,
198,
4871,
30799,
25,
220,
198,
220,
220,
220,
37227,
20688,
37811,
198,
220,
220,
220,
2124,
28,
17,
198,
198,
4871,
16092,
6008,
272,
263,
25,
220,
198,
220... | 2.46087 | 115 |
# -*- coding: utf-8 -*-
import unittest
from unittest import mock
from pastepwn.analyzers.googleapikeyanalyzer import GoogleApiKeyAnalyzer
if __name__ == '__main__':
unittest.main()
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
11748,
555,
715,
395,
198,
6738,
555,
715,
395,
1330,
15290,
198,
198,
6738,
1613,
538,
675,
13,
38200,
47031,
13,
13297,
499,
522,
4121,
3400,
9107,
1330,
3012,
32,
1... | 2.661972 | 71 |
from django.contrib import admin
from .models import Entry, Topic
admin.site.register(Topic)
admin.site.register(Entry)
| [
6738,
42625,
14208,
13,
3642,
822,
1330,
13169,
198,
198,
6738,
764,
27530,
1330,
21617,
11,
47373,
198,
198,
28482,
13,
15654,
13,
30238,
7,
33221,
8,
198,
28482,
13,
15654,
13,
30238,
7,
30150,
8,
198
] | 3.297297 | 37 |
# uploads.py - Discourse only sends the real addresses of some embedded
# images in the 'cooked' HTML. This module helps to extract them from
# there and turn them into real links in the Markdown.
import html.parser
import io
import commonmark
import commonmark_extensions.plaintext
| [
2,
9516,
82,
13,
9078,
532,
8444,
9047,
691,
12800,
262,
1103,
9405,
286,
617,
14553,
198,
2,
4263,
287,
262,
705,
46591,
6,
11532,
13,
220,
770,
8265,
5419,
284,
7925,
606,
422,
198,
2,
612,
290,
1210,
606,
656,
1103,
6117,
287,
... | 3.931507 | 73 |
#!/bin/env python
import profile
from pstats import Stats
from Main import main
s = profile.run('main()', 'pksampler.profile')
Stats('pksampler.profile').sort_stats('calls').print_stats()
| [
2,
48443,
8800,
14,
24330,
21015,
198,
198,
11748,
7034,
198,
6738,
279,
34242,
1330,
20595,
198,
6738,
8774,
1330,
1388,
198,
198,
82,
796,
7034,
13,
5143,
10786,
12417,
3419,
3256,
705,
79,
591,
321,
20053,
13,
13317,
11537,
198,
29... | 3.064516 | 62 |
from piece import piece
| [
6738,
3704,
1330,
3704,
628
] | 5 | 5 |
#!/usr/bin/env python3
from nlptools.text.tokenizer import Tokenizer_BERT
from nlptools.utils import zload
import sys
s = Tokenizer_BERT(bert_model_name='/home/pzhu/.pytorch_pretrained_bert/bert-base-uncased')
txt = 'Who was Jim Henson ? Jim Henson was a puppeteer'
print(s.seg(txt))
print(s.vocab)
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
198,
6738,
299,
75,
457,
10141,
13,
5239,
13,
30001,
7509,
1330,
29130,
7509,
62,
13246,
51,
198,
6738,
299,
75,
457,
10141,
13,
26791,
1330,
1976,
2220,
198,
11748,
25064,
198,
198,
... | 2.525 | 120 |
from __future__ import unicode_literals, print_function, division
import requests
from datetime import datetime
from bs4 import BeautifulSoup
import re
| [
6738,
11593,
37443,
834,
1330,
28000,
1098,
62,
17201,
874,
11,
3601,
62,
8818,
11,
7297,
198,
11748,
7007,
198,
6738,
4818,
8079,
1330,
4818,
8079,
198,
6738,
275,
82,
19,
1330,
23762,
50,
10486,
198,
11748,
302,
628
] | 3.923077 | 39 |
# -*- coding: utf-8 -*-
"""
Stack Floating Buttons
======================
Copyright © 2010-2018 HeaTTheatR
For suggestions and questions:
<kivydevelopment@gmail.com>
This file is distributed under the terms of the same license,
as the Kivy framework.
Example
-------
from kivy.app import App
from kivy.lang import ... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
37811,
198,
25896,
49768,
887,
27288,
198,
4770,
50155,
198,
198,
15269,
10673,
3050,
12,
7908,
679,
64,
51,
464,
265,
49,
198,
198,
1890,
11776,
290,
2683,
25,
1... | 2.25353 | 1,629 |
#
# 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 in writing, software
# distributed under ... | [
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,
198,
2,
921,
743,
7330,
257,
4866,
286,
262,
13789,
379,... | 3.802956 | 203 |
"""
Hydrus helper is module containing various functions for working with Hydrus
output files and processing them in Jupyter Notebooks
For now the functions are:
- copy_output():
It will copy the selected files from temporary working directory of a
Hydrus project to a Hydrus/project_name subdirectory.... | [
37811,
201,
198,
40436,
14932,
31904,
318,
8265,
7268,
2972,
5499,
329,
1762,
351,
15084,
14932,
201,
198,
22915,
3696,
290,
7587,
606,
287,
449,
929,
88,
353,
5740,
12106,
201,
198,
201,
198,
1890,
783,
262,
5499,
389,
25,
201,
198,
... | 1.968655 | 4,594 |
from telethon import events
from iahr.reg import TextSender, VoidSender, MultiArgs, any_send
from iahr.config import IahrConfig
from iahr.utils import AccessList, EventService
from .utils import mention, local, CHAT_TAG
##################################################
# Routines themselves
########################... | [
6738,
5735,
400,
261,
1330,
2995,
198,
198,
6738,
220,
9520,
81,
13,
2301,
1330,
8255,
50,
2194,
11,
18331,
50,
2194,
11,
15237,
42035,
11,
597,
62,
21280,
198,
6738,
220,
9520,
81,
13,
11250,
1330,
314,
993,
81,
16934,
198,
6738,
... | 3.761468 | 109 |
# -*- coding: UTF-8 -*-
# Copyright (c) 2008 - 2014, Pascal Volk
# See COPYING for distribution information.
"""
vmm.ext.postconf
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Wrapper class for Postfix's postconf.
Postconf instances can be used to read actual values of configuration
parameters or edit the value ... | [
2,
532,
9,
12,
19617,
25,
41002,
12,
23,
532,
9,
12,
198,
2,
15069,
357,
66,
8,
3648,
532,
1946,
11,
35163,
4709,
74,
198,
2,
4091,
27975,
45761,
329,
6082,
1321,
13,
198,
37811,
198,
220,
220,
220,
410,
3020,
13,
2302,
13,
73... | 2.238579 | 1,970 |
""" Sixth version, make the code easier and more modifiable """
# Define the main programme
from funcs import store_namespace
from funcs import load_namespace
from funcs import emulate_jmod
import os
import datetime
import time
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
#from multiprocessin... | [
37811,
28980,
2196,
11,
787,
262,
2438,
4577,
290,
517,
953,
16823,
37227,
198,
2,
2896,
500,
262,
1388,
11383,
198,
198,
6738,
1257,
6359,
1330,
3650,
62,
14933,
10223,
198,
6738,
1257,
6359,
1330,
3440,
62,
14933,
10223,
198,
6738,
... | 1.811902 | 6,167 |
# Generated by Django 3.2.3 on 2021-06-02 14:44
from typing import List, Tuple
from django.db import migrations, models
| [
2,
2980,
515,
416,
37770,
513,
13,
17,
13,
18,
319,
33448,
12,
3312,
12,
2999,
1478,
25,
2598,
198,
6738,
19720,
1330,
7343,
11,
309,
29291,
198,
198,
6738,
42625,
14208,
13,
9945,
1330,
15720,
602,
11,
4981,
628
] | 3.05 | 40 |
# coding: utf-8
#
# Copyright 2019 Amazon.com, Inc. or its affiliates. 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. A copy of the License is located at
#
# http://aws.amazon.com/apache2.0/
#
# or in the "lice... | [
2,
19617,
25,
3384,
69,
12,
23,
198,
198,
2,
198,
2,
15069,
13130,
6186,
13,
785,
11,
3457,
13,
393,
663,
29116,
13,
1439,
6923,
33876,
13,
198,
2,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
... | 2.85396 | 3,232 |
import xquantum as xq
import math
from qiskit.circuit.library.standard_gates import RYGate
from qiskit import QuantumCircuit, execute, Aer, IBMQ
# https://algassert.com/quirk#circuit={%22cols%22:[[1,{%22id%22:%22Ryft%22,%22arg%22:%221.982313%22}],[],[{%22id%22:%22Ryft%22,%22arg%22:%221.714144%22},%22%E2%80%A2%22],[],[... | [
11748,
2124,
40972,
388,
355,
2124,
80,
198,
11748,
10688,
198,
6738,
10662,
1984,
270,
13,
21170,
5013,
13,
32016,
13,
20307,
62,
70,
689,
1330,
371,
56,
22628,
198,
6738,
10662,
1984,
270,
1330,
29082,
31560,
5013,
11,
12260,
11,
15... | 1.577601 | 1,134 |
from bot.Bot import Bot
from bot.api_ai import find_respond
import json
# change = Change()
# jso = {
#
# "respond": "Bye"
# }
# result = change.respond(jso)
# print(result)
| [
6738,
10214,
13,
20630,
1330,
18579,
198,
6738,
10214,
13,
15042,
62,
1872,
1330,
1064,
62,
5546,
198,
11748,
33918,
628,
198,
198,
2,
1487,
796,
9794,
3419,
198,
2,
474,
568,
796,
1391,
198,
2,
198,
2,
220,
220,
366,
5546,
1298,
... | 2.623188 | 69 |
import data_w
from data_w import widedata
from data_w import*
import model_w
from model_w import*
from model_w import WideCNN
#datset=widedata(ligand_path, protein_path,keys,motif_path,affinity_path)
dataset = widedata(ligand_path, protein_path,keys,motif_path,affinity_path)
train_loader, test_loader = load... | [
11748,
1366,
62,
86,
201,
198,
6738,
1366,
62,
86,
1330,
266,
1384,
1045,
201,
198,
6738,
1366,
62,
86,
1330,
9,
201,
198,
11748,
2746,
62,
86,
201,
198,
6738,
2746,
62,
86,
1330,
9,
201,
198,
6738,
2746,
62,
86,
1330,
23399,
18... | 2.317181 | 227 |
import math | [
11748,
10688
] | 5.5 | 2 |
from itertools import cycle
import sys
# from qtpy import QtWidgets, QtCore
from PyQt5 import QtWidgets, QtCore
if __name__ == "__main__":
app = QtWidgets.QApplication(sys.argv)
ex = ExampleWindow()
ex.show()
sys.exit(app.exec_())
| [
6738,
340,
861,
10141,
1330,
6772,
198,
11748,
25064,
198,
198,
2,
422,
10662,
83,
9078,
1330,
33734,
54,
312,
11407,
11,
33734,
14055,
198,
6738,
9485,
48,
83,
20,
1330,
33734,
54,
312,
11407,
11,
33734,
14055,
628,
198,
198,
361,
... | 2.428571 | 105 |
from os import system
| [
6738,
28686,
1330,
1080,
201,
198,
201,
198
] | 3.125 | 8 |
"""
Module with tests for Highlight
"""
#-----------------------------------------------------------------------------
# Copyright (c) 2013, the IPython Development Team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file COPYING.txt, distributed with this software.
#-----... | [
37811,
198,
26796,
351,
5254,
329,
3334,
2971,
198,
37811,
198,
198,
2,
10097,
32501,
198,
2,
15069,
357,
66,
8,
2211,
11,
262,
6101,
7535,
7712,
4816,
13,
198,
2,
198,
2,
4307,
6169,
739,
262,
2846,
286,
262,
40499,
347,
10305,
1... | 3.076923 | 689 |
"""Here, I'd like to gather utility function / classes related to `pywin32com`.
Notice that this library is not library, but recipes for reading codes of `pywin32com`.
"""
from win32com.client import DispatchEx, CDispatch
from win32com.client.selecttlb import EnumTlbs
from win32com.client.makepy import GenerateFro... | [
37811,
4342,
11,
314,
1549,
588,
284,
6431,
10361,
2163,
1220,
6097,
3519,
284,
4600,
9078,
5404,
2624,
785,
44646,
220,
198,
26396,
326,
428,
5888,
318,
407,
5888,
11,
475,
14296,
329,
3555,
12416,
286,
4600,
9078,
5404,
2624,
785,
4... | 3.223404 | 188 |
from selenium import webdriver
from time import sleep
import os
options = webdriver.ChromeOptions()
options.add_experimental_option("excludeSwitches", ['enable-automation'])
# プラウザ起動(Chrome)
driver = webdriver.Chrome(r'chromedriver.exe', chrome_options=options) # chromedriver.exeを使う
# リストからURLをひとつづつ処理
pri... | [
6738,
384,
11925,
1505,
1330,
3992,
26230,
201,
198,
6738,
640,
1330,
3993,
201,
198,
11748,
28686,
201,
198,
201,
198,
25811,
796,
3992,
26230,
13,
1925,
5998,
29046,
3419,
201,
198,
25811,
13,
2860,
62,
23100,
9134,
62,
18076,
7203,
... | 2.244019 | 209 |
# gcode runner
import io, sys
import socket
import time
import re
import argparse
ADDR="192.168.1.18"
PORT=23
LAST_SENT=""
# Should be ok, error, etc.
LAST_RESPONSE=""
# Optional [Caution: Unlocked] in response to $X
LAST_RESPONSE_MSG=""
# Global values set by get_status()
STATUS=""
MPOS=[0.0, 0.0, 0.0]
WPOS=[0.0, 0.... | [
2,
308,
8189,
17490,
198,
11748,
33245,
11,
25064,
198,
11748,
17802,
198,
11748,
640,
198,
11748,
302,
198,
11748,
1822,
29572,
198,
198,
2885,
7707,
2625,
17477,
13,
14656,
13,
16,
13,
1507,
1,
198,
15490,
28,
1954,
198,
43,
11262,
... | 2.130258 | 2,948 |
#4. 定义一个函数,完成以下功能:
# 1) 输入两个整型数,例如输入的是3, 5
# 2) 此函数要计算的是3 + 33 + 333 + 3333 + 33333(到5个为止)
a, b = eval(input("请输入两个整型数"))
print(sum1(a, b))
| [
2,
19,
13,
10263,
106,
248,
20046,
231,
31660,
10310,
103,
49035,
121,
46763,
108,
171,
120,
234,
22522,
234,
22755,
238,
20015,
98,
10310,
233,
27950,
253,
47797,
121,
25,
198,
2,
220,
220,
352,
8,
5525,
122,
241,
17739,
98,
10310,... | 0.99375 | 160 |
# test plugin
from bot.pluginDespatch import Plugin
import re
import datetime
import logging
from models import CapturedUrls
from logos.settings import LOGGING
logger = logging.getLogger(__name__)
logging.config.dictConfig(LOGGING)
| [
2,
1332,
13877,
198,
6738,
10214,
13,
33803,
5960,
17147,
1330,
42636,
198,
11748,
302,
198,
11748,
4818,
8079,
198,
11748,
18931,
198,
6738,
4981,
1330,
6790,
1522,
16692,
7278,
198,
198,
6738,
29645,
13,
33692,
1330,
41605,
38,
2751,
... | 2.435897 | 117 |
from django.contrib.auth.models import User
from rest_framework import serializers
from odata.models import Product, Customer, Category, Shipper, Order, OrderDetail | [
6738,
42625,
14208,
13,
3642,
822,
13,
18439,
13,
27530,
1330,
11787,
198,
6738,
1334,
62,
30604,
1330,
11389,
11341,
198,
6738,
267,
7890,
13,
27530,
1330,
8721,
11,
22092,
11,
21743,
11,
911,
14710,
11,
8284,
11,
8284,
11242,
603
] | 4 | 41 |
#! /usr/bin/env python2
'''
This script converts the Ensembl.dat file to the GO reference file used in the topGO R program.
#Example input:
ID 1 standard; DNA; HTG; 122678785 BP.
XX
AC chromosome:CanFam3.1:1:1:122678785:1
XX
SV 1.CanFam3.1
XX
DT 4-SEP-2018
XX
DE Canis lupus familiaris chromosome 1 CanFam... | [
2,
0,
1220,
14629,
14,
8800,
14,
24330,
21015,
17,
198,
198,
7061,
6,
198,
1212,
4226,
26161,
262,
2039,
4428,
75,
13,
19608,
2393,
284,
262,
10351,
4941,
2393,
973,
287,
262,
1353,
11230,
371,
1430,
13,
198,
198,
2,
16281,
5128,
... | 1.818611 | 5,083 |
import os
import numpy as np
import scipy.spatial as scsp
import scipy.linalg as scli
| [
11748,
28686,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
629,
541,
88,
13,
2777,
34961,
355,
629,
2777,
198,
11748,
629,
541,
88,
13,
75,
1292,
70,
355,
264,
44506,
628,
628,
628,
628,
628
] | 2.638889 | 36 |
import json
| [
11748,
33918,
198
] | 4 | 3 |
# Copyright 2013 Mirantis, Inc.
#
# 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 ... | [
2,
220,
220,
220,
15069,
2211,
7381,
20836,
11,
3457,
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,
198,
2,
220,
220,
220,
407,
779,
428,
2393,
... | 3.300654 | 306 |
from CHECLabPy.core.io import TIOReader
from TargetCalibSB.pedestal import PedestalTargetCalib
import fitsio
from tqdm import tqdm
from matplotlib import pyplot as plt
import numpy as np
if __name__ == '__main__':
main()
| [
6738,
5870,
2943,
17822,
20519,
13,
7295,
13,
952,
1330,
31598,
1581,
1329,
263,
198,
6738,
12744,
9771,
571,
16811,
13,
9124,
395,
282,
1330,
13457,
395,
282,
21745,
9771,
571,
198,
11748,
11414,
952,
198,
6738,
256,
80,
36020,
1330,
... | 2.814815 | 81 |
import pandas as pd
import numpy as np
import xgboost as xgb
import lightgbm as lgb
import pyarrow as pa
import pyarrow.parquet as pq
from sklearn.model_selection import train_test_split
import argparse
from scipy.special import erfinv
from scipy.sparse import csr_matrix
from sklearn.preprocessing import StandardScaler... | [
11748,
19798,
292,
355,
279,
67,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
2124,
70,
39521,
355,
2124,
22296,
198,
11748,
1657,
70,
20475,
355,
300,
22296,
198,
11748,
12972,
6018,
355,
14187,
198,
11748,
12972,
6018,
13,
1845,
21... | 2.324891 | 1,382 |
argo["salinity"].sel(level=10).plot.line() | [
9448,
14692,
21680,
6269,
1,
4083,
741,
7,
5715,
28,
940,
737,
29487,
13,
1370,
3419
] | 2.625 | 16 |
import numpy as np
import matplotlib.pyplot as plt
from skimage import io
import cv2
# 参考記事:https://qiita.com/haru1843/items/00de955790d3a22a217b
img = io.imread("./dataset/images/imori_256x256.png")
gray_img = cv2.cvtColor(img, cv2.COLOR_RGB2GRAY)
th = getThreshold(gray_img)
binary_img = gray2binary(gray_img, th)... | [
11748,
299,
32152,
355,
45941,
198,
11748,
2603,
29487,
8019,
13,
9078,
29487,
355,
458,
83,
198,
6738,
1341,
9060,
1330,
33245,
198,
11748,
269,
85,
17,
628,
198,
2,
10263,
237,
224,
32003,
225,
164,
101,
246,
12859,
233,
171,
120,
... | 2.076923 | 273 |
from sqlite3 import Row
from pydantic import BaseModel
| [
6738,
44161,
578,
18,
1330,
11314,
198,
198,
6738,
279,
5173,
5109,
1330,
7308,
17633,
628,
198
] | 3.411765 | 17 |
from .boxloss import *
from .focalloss import *
from .multitaskloss import *
| [
6738,
764,
3524,
22462,
1330,
1635,
198,
6738,
764,
69,
420,
439,
793,
1330,
1635,
198,
6738,
764,
16680,
270,
2093,
22462,
1330,
1635,
198
] | 3.08 | 25 |
import os
import time
import numpy as np
import pandas as pd
from sklearn.linear_model import LinearRegression
from sklearn.model_selection import cross_val_score
import sys
sys.path.append('..')
from utils import calHarDist
DATA_DIR = '../datasets'
for filename in ['modified_train.csv']:
print('readin... | [
11748,
28686,
198,
11748,
640,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
19798,
292,
355,
279,
67,
198,
6738,
1341,
35720,
13,
29127,
62,
19849,
1330,
44800,
8081,
2234,
198,
6738,
1341,
35720,
13,
19849,
62,
49283,
1330,
3272,
62... | 2.213235 | 816 |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Tue Jun 15 14:01:24 2021
@author: liang
"""
'''
AWS personalize model
'''
import boto3
import json
import os
class PersonalizePredictHandler():
"""
""" | [
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,
30030,
7653,
1315,
1478,
25,
486,
25,
1731,
33448,
198,
198,
31,
9800,
25,
7649,
648,
198... | 2.516854 | 89 |
# Copyright 2016 Bridgewater Associates
#
# 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 appli... | [
2,
220,
220,
220,
220,
15069,
1584,
48218,
29306,
198,
2,
198,
2,
220,
220,
220,
220,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
198,
2,
220,
220,
220,
220,
345,
743,
407,
779,
428,
2393,
... | 3.290698 | 258 |
import cloudmesh
cloudmesh.shell("help")
print cloudmesh.version()
| [
11748,
6279,
76,
5069,
198,
17721,
76,
5069,
13,
29149,
7203,
16794,
4943,
198,
4798,
6279,
76,
5069,
13,
9641,
3419,
628
] | 3.090909 | 22 |
import json
import numpy as np
import torch
from torch import nn
| [
11748,
33918,
198,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
28034,
198,
6738,
28034,
1330,
299,
77,
198
] | 3.473684 | 19 |
#
# PySNMP MIB module Juniper-IKE-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/Juniper-IKE-MIB
# Produced by pysmi-0.3.4 at Mon Apr 29 19:52:12 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Mar 27... | [
2,
198,
2,
9485,
15571,
7378,
337,
9865,
8265,
7653,
9346,
12,
40,
7336,
12,
8895,
33,
357,
4023,
1378,
16184,
76,
489,
8937,
13,
785,
14,
79,
893,
11632,
8,
198,
2,
7054,
45,
13,
16,
2723,
2393,
1378,
14,
14490,
14,
67,
615,
... | 2.381318 | 9,774 |
# Based on CreateQuadGeometry example
import simpl
import simplpy as d3d
import simpl_helpers as sh
import simpl_test_dirs as sd
if __name__ == '__main__':
CreateQuadGeometryTest()
| [
2,
13403,
319,
13610,
4507,
324,
10082,
15748,
1672,
198,
198,
11748,
7106,
198,
11748,
7106,
9078,
355,
288,
18,
67,
198,
11748,
7106,
62,
16794,
364,
355,
427,
198,
11748,
7106,
62,
9288,
62,
15908,
82,
355,
45647,
198,
198,
361,
... | 3.032787 | 61 |
"""
PDF Enlarge
===========
Scale the contents of a PDF document 2x.
- Split each page into two parts along the perpendicular axis (e.g. one
A4 page into two A5 pages).
- Scale each split part 2 times (e.g. A5 -> A4)
- Merge scaled parts into a new PDF document.
"""
import sys
def main() -> int:
"""Console s... | [
37811,
198,
20456,
2039,
11664,
198,
2559,
18604,
198,
198,
29990,
262,
10154,
286,
257,
12960,
3188,
362,
87,
13,
198,
198,
12,
27758,
1123,
2443,
656,
734,
3354,
1863,
262,
47190,
16488,
357,
68,
13,
70,
13,
530,
198,
220,
317,
19... | 3.027586 | 145 |
# Copyright (C) 2011-2012 Canonical Services Ltd
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, ... | [
2,
15069,
357,
34,
8,
2813,
12,
6999,
19507,
605,
6168,
12052,
198,
2,
198,
2,
2448,
3411,
318,
29376,
7520,
11,
1479,
286,
3877,
11,
284,
597,
1048,
16727,
198,
2,
257,
4866,
286,
428,
3788,
290,
3917,
10314,
3696,
357,
1169,
198... | 3.159178 | 779 |
from __future__ import print_function
# -*- coding: utf-8 -*-
from six.moves import range
from acq4.util import Qt
import acq4.pyqtgraph as pg
#import acq4.pyqtgraph.TreeWidget as TreeWidget
import acq4.util.flowchart.EventDetection as FCEventDetection
import acq4.util.debug as debug
| [
6738,
11593,
37443,
834,
1330,
3601,
62,
8818,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
6738,
2237,
13,
76,
5241,
1330,
2837,
198,
198,
6738,
936,
80,
19,
13,
22602,
1330,
33734,
198,
11748,
936,
80... | 2.813725 | 102 |
from shakenfist.client import apiclient
from shakenfist_ci import base
| [
6738,
27821,
69,
396,
13,
16366,
1330,
2471,
291,
75,
1153,
198,
198,
6738,
27821,
69,
396,
62,
979,
1330,
2779,
628
] | 3.318182 | 22 |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
| [
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,
198,
6738,
42625,
14208,
13,
9945,
1330,
4981,
11,
15720,
602,
628
] | 2.891892 | 37 |
# -*- coding: utf-8 -*- # Lint as: python3
# Copyright 2020 Google Inc. 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
... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
1303,
406,
600,
355,
25,
21015,
18,
198,
2,
15069,
12131,
3012,
3457,
13,
1439,
6923,
33876,
13,
198,
2,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
35... | 3.133087 | 541 |
import math
def code(radius: int = 15, num_sides: int = 7) -> str:
"""
Example G-code module, regular polygon.
Please simulate first, before milling.
"""
result = ["G90"]
for i in range(num_sides):
x = radius - radius * math.cos(2 * math.pi * i / num_sides)
y = radius * math.... | [
11748,
10688,
628,
198,
4299,
2438,
7,
42172,
25,
493,
796,
1315,
11,
997,
62,
82,
1460,
25,
493,
796,
767,
8,
4613,
965,
25,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
17934,
402,
12,
8189,
8265,
11,
3218,
7514,
14520,
13,
... | 2.083682 | 239 |
import numpy as np
from scipy.io import loadmat
from scipy.fft import fft
def make_point_clouds(vertices, temperature):
"""[summary]
Parameters
----------
vertices : ndarray of shape (n_vertices, 3)
Vertices of the mesh as 3D points.
temperature : ndarray of shape (n_vertices, n_functio... | [
11748,
299,
32152,
355,
45941,
198,
198,
6738,
629,
541,
88,
13,
952,
1330,
3440,
6759,
198,
6738,
629,
541,
88,
13,
487,
83,
1330,
277,
701,
628,
198,
198,
4299,
787,
62,
4122,
62,
17721,
82,
7,
1851,
1063,
11,
5951,
2599,
198,
... | 2.803279 | 427 |
from argparse import (
Action,
Namespace,
HelpFormatter,
OPTIONAL,
REMAINDER,
SUPPRESS,
PARSER,
ONE_OR_MORE,
ZERO_OR_MORE,
)
from .actions import *
from .cli import *
from .core import *
from .deprecated import *
from .formatters import *
from .jsonnet import *
from .jsonschema impor... | [
6738,
1822,
29572,
1330,
357,
198,
220,
220,
220,
7561,
11,
198,
220,
220,
220,
28531,
10223,
11,
198,
220,
220,
220,
10478,
8479,
1436,
11,
198,
220,
220,
220,
39852,
2849,
1847,
11,
198,
220,
220,
220,
22657,
32,
12115,
1137,
11,
... | 2.602339 | 171 |
#!@PYTHON_EXECUTABLE@
#ckwg +28
# Copyright 2011-2013 by Kitware, 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:
#
# * Redistributions of source code must retain the above copyright notice,... | [
2,
0,
31,
47,
56,
4221,
1340,
62,
6369,
2943,
3843,
17534,
31,
198,
2,
694,
86,
70,
1343,
2078,
198,
2,
15069,
2813,
12,
6390,
416,
10897,
1574,
11,
3457,
13,
198,
2,
1439,
2489,
10395,
13,
198,
2,
198,
2,
2297,
396,
3890,
290... | 3.124386 | 611 |
import hashlib
from corehq.apps.integration.models import (
DialerSettings,
GaenOtpServerSettings,
HmacCalloutSettings,
)
| [
11748,
12234,
8019,
198,
198,
6738,
4755,
71,
80,
13,
18211,
13,
18908,
1358,
13,
27530,
1330,
357,
198,
220,
220,
220,
21269,
263,
26232,
11,
198,
220,
220,
220,
12822,
268,
46,
34788,
10697,
26232,
11,
198,
220,
220,
220,
367,
202... | 2.679245 | 53 |
#!/usr/bin/env python
import os, sys, warnings, logging
logger = logging.getLogger(__name__)
if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "dashboard.settings")
from django.core.management import execute_from_command_line
# Regex for which modules to ignore warnings from
... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
11748,
28686,
11,
25064,
11,
14601,
11,
18931,
198,
198,
6404,
1362,
796,
18931,
13,
1136,
11187,
1362,
7,
834,
3672,
834,
8,
198,
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
... | 2.847059 | 170 |
import torch
from torch import autograd, nn
import torch.nn.functional as functional
import utils
| [
11748,
28034,
198,
6738,
28034,
1330,
1960,
519,
6335,
11,
299,
77,
198,
11748,
28034,
13,
20471,
13,
45124,
355,
10345,
198,
198,
11748,
3384,
4487,
628,
198,
220,
220,
220,
220,
220,
220,
220,
220,
628
] | 3 | 37 |
import os
basedir = os.path.abspath(os.path.dirname(__file__)) | [
11748,
28686,
198,
3106,
343,
796,
28686,
13,
6978,
13,
397,
2777,
776,
7,
418,
13,
6978,
13,
15908,
3672,
7,
834,
7753,
834,
4008
] | 2.48 | 25 |
import re
import yaml
def split_markup(markup):
"""
Given some markup, return a tuple containing the decoded data and the
template code.
"""
match = re.search(r'\n={3,}\n', markup)
if match:
start, end = match.span()
ctx = yaml.load(markup[:start])
template_code = mark... | [
11748,
302,
198,
198,
11748,
331,
43695,
628,
198,
4299,
6626,
62,
4102,
929,
7,
4102,
929,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
11259,
617,
41485,
11,
1441,
257,
46545,
7268,
262,
875,
9043,
1366,
290,
262,
198,
220... | 2.335196 | 179 |
# CÓDIGO DE PRUEBA
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pymongo import MongoClient
from bson.objectid import ObjectId
from nltk.tokenize import TweetTokenizer
from datetime import datetime as dt
try:
client = MongoClient()
print("Connected to MongoDB\n")
except pymongo.errors.ConnectionFailure as e:
... | [
2,
327,
127,
241,
35,
3528,
46,
5550,
4810,
8924,
4339,
198,
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,
279,
4948,
25162,
1330,
42591,
11792,
198,
67... | 2.131579 | 532 |
__all__ = ["PairedNote"]
class PairedNote:
"""This class holds a DebitNote together with its matching
CreditNote(s)
"""
def __init__(self, debit_note, credit_note):
"""Construct from the matching pair of notes"""
from Acquire.Accounting import CreditNote as _CreditNote
from Ac... | [
834,
439,
834,
796,
14631,
47,
9820,
6425,
8973,
628,
198,
4871,
350,
9820,
6425,
25,
198,
220,
220,
220,
37227,
1212,
1398,
6622,
257,
1024,
2545,
6425,
1978,
351,
663,
12336,
198,
220,
220,
220,
10504,
6425,
7,
82,
8,
198,
220,
... | 2.200366 | 1,093 |
from nltk import *
from nltk.corpus import *
ans = 'Y'
while((ans=='y')|(ans=='Y')):
input1 = input("Write a scentence")
lang = detect_language(input1)
print(input1+"\t Langauge: "+ lang)
ans = input("to do this again enter (y/Y)")
| [
6738,
299,
2528,
74,
1330,
1635,
201,
198,
6738,
299,
2528,
74,
13,
10215,
79,
385,
1330,
1635,
201,
198,
504,
796,
705,
56,
6,
201,
198,
4514,
19510,
504,
855,
6,
88,
11537,
91,
7,
504,
855,
6,
56,
11537,
2599,
201,
198,
220,
... | 2.265487 | 113 |
import os
import sys
sys.path.append(os.path.join(os.path.dirname(__file__), "../test/integration/pyxl/"))
from pyxl.codec.register import pyxl_transform_string
for i in xrange(100):
# pyxl/tests/test_if_1.py
pyxl_transform_string(
'''
from pyxl import html
def test():
assert str(<frag><if cond="{True}"... | [
11748,
28686,
198,
11748,
25064,
198,
198,
17597,
13,
6978,
13,
33295,
7,
418,
13,
6978,
13,
22179,
7,
418,
13,
6978,
13,
15908,
3672,
7,
834,
7753,
834,
828,
366,
40720,
9288,
14,
18908,
1358,
14,
9078,
87,
75,
30487,
4008,
198,
... | 1.878815 | 4,423 |
from __future__ import unicode_literals
from __future__ import print_function
from __future__ import division
from __future__ import absolute_import
from future import standard_library
from future.utils import with_metaclass
standard_library.install_aliases()
from abc import ABCMeta
from abc import abstractmethod
cl... | [
6738,
11593,
37443,
834,
1330,
28000,
1098,
62,
17201,
874,
198,
6738,
11593,
37443,
834,
1330,
3601,
62,
8818,
198,
6738,
11593,
37443,
834,
1330,
7297,
198,
6738,
11593,
37443,
834,
1330,
4112,
62,
11748,
198,
6738,
2003,
1330,
3210,
... | 3.493243 | 148 |
#!/usr/bin/env python3
import os
import sys
import argparse
import logging
from typing import List, Optional, Union, Dict, Tuple
from datetime import datetime, timedelta
from sqlalchemy import create_engine
import rx
import rx.operators as ops
from rx.subject import AsyncSubject, Subject, BehaviorSubject, ReplaySubje... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
198,
198,
11748,
28686,
198,
11748,
25064,
198,
11748,
1822,
29572,
198,
11748,
18931,
198,
6738,
19720,
1330,
7343,
11,
32233,
11,
4479,
11,
360,
713,
11,
309,
29291,
198,
6738,
4818,
... | 2.970954 | 482 |
# Line Ghanem 27280076
# Anthony Iatropoulos 40028246
# Mikael Samvelian 40003178
import re
# V = 0
# V = 1
# V = 2
# helper function
| [
2,
6910,
402,
7637,
368,
2681,
2078,
405,
4304,
198,
2,
9953,
314,
265,
1773,
19537,
7337,
2078,
26912,
198,
2,
17722,
3010,
3409,
626,
666,
30123,
18,
23188,
198,
198,
11748,
302,
628,
220,
220,
220,
1303,
569,
796,
657,
628,
220,
... | 2.384615 | 65 |
from time import time
from threading import Lock
class PaceMaker(object):
'''
Implementation of https://en.wikipedia.org/wiki/Token_bucket#Algorithm
Args:
no_token_sleep_in_seconds: Seconds to nap when there are no tokens to spend.
Defaults to... | [
6738,
640,
1330,
640,
198,
6738,
4704,
278,
1330,
13656,
628,
198,
4871,
44111,
48890,
7,
15252,
2599,
198,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
220,
220,
220,
220,
46333,
286,
3740,
1378,
268,
13,
31266,
13,
2398,
14,
1546... | 2.038813 | 876 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import warnings
import pandas as pd
import pytest
from covsirphy import PolicyMeasures
from covsirphy import SIRF, Scenario
# Skip this test at this time
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
11748,
14601,
198,
11748,
19798,
292,
355,
279,
67,
198,
11748,
12972,
9288,
198,
6738,
39849,
82,
343,
6883,
1330... | 2.861111 | 72 |
from django.contrib import admin
from .models import Animal, Raca, NomeCientifico, Origem, NomePopular
admin.site.register(Animal)
admin.site.register(Raca)
admin.site.register(Origem)
admin.site.register(NomeCientifico)
admin.site.register(NomePopular)
| [
6738,
42625,
14208,
13,
3642,
822,
1330,
13169,
201,
198,
6738,
764,
27530,
1330,
13792,
11,
371,
22260,
11,
399,
462,
34,
1153,
811,
78,
11,
6913,
368,
11,
399,
462,
16979,
934,
201,
198,
201,
198,
28482,
13,
15654,
13,
30238,
7,
... | 2.71134 | 97 |
password="pbkdf2(1000,20,sha512)$a4e3c0f67fc691f5$70638e315cc3ad9d7aed2f01edba2f36a5cbe486"
| [
28712,
2625,
40842,
74,
7568,
17,
7,
12825,
11,
1238,
11,
26270,
25836,
8,
3,
64,
19,
68,
18,
66,
15,
69,
3134,
16072,
49541,
69,
20,
3,
35402,
2548,
68,
27936,
535,
18,
324,
24,
67,
22,
8432,
17,
69,
486,
276,
7012,
17,
69,
... | 1.703704 | 54 |
#
# PySNMP MIB module Wellfleet-GRE-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/Wellfleet-GRE-MIB
# Produced by pysmi-0.3.4 at Wed May 1 15:40:19 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Ma... | [
2,
198,
2,
9485,
15571,
7378,
337,
9865,
8265,
3894,
33559,
12,
28934,
12,
8895,
33,
357,
4023,
1378,
16184,
76,
489,
8937,
13,
785,
14,
79,
893,
11632,
8,
198,
2,
7054,
45,
13,
16,
2723,
2393,
1378,
14,
14490,
14,
67,
615,
4756... | 2.617186 | 4,783 |
nFeatures = {
"EE": 182, #22,
"SD": 126, #24,
"SR": 330, #23,
"OF": 0,
"CR": 97, #22, #91
}
params = {
'SD': {
'MoveThroughDoorway_Method2':
{'r2': {'nOutputs': 4, 'nInputs': 150, 'pos': -1, 'decoder': DecodeRobot_SD}},
'Recover_Method1':
{'r2': {'nO... | [
198,
77,
23595,
796,
1391,
198,
220,
220,
220,
366,
6500,
1298,
28581,
11,
1303,
1828,
11,
198,
220,
220,
220,
366,
10305,
1298,
19710,
11,
1303,
1731,
11,
198,
220,
220,
220,
366,
12562,
1298,
25508,
11,
1303,
1954,
11,
198,
220,
... | 1.811066 | 741 |
#!/usr/bin/python3
import pandas
| [
2,
48443,
14629,
14,
8800,
14,
29412,
18,
198,
198,
11748,
19798,
292,
628
] | 2.5 | 14 |
import sys
print("----------------------- pythonsv project init -----------------------")
sys.path.append(".")
sys.path.append(r'C:\PythonSV\icelakex')
from icelakex.starticx import *
from icelakex.toolext import pysv_config
from svtools.common.pysv_config import CFG
if __name__ == '__main__':
itp, sv = pythons... | [
11748,
25064,
198,
198,
4798,
7203,
19351,
6329,
279,
5272,
684,
85,
1628,
2315,
41436,
6329,
4943,
198,
17597,
13,
6978,
13,
33295,
7203,
19570,
198,
17597,
13,
6978,
13,
33295,
7,
81,
6,
34,
7479,
37906,
50,
53,
59,
291,
417,
539,... | 2.037528 | 453 |
import sys
import threading
import code
import socket
import code
import debugthread
import io
foo="xxx"
s = socket.socket(socket.AF_INET)
s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
s.bind(('127.0.0.1', 4711))
s.listen(0)
while True:
ss, addr = s.accept()
stdin =io.TextIOWrapper(ss.makefile('rb',... | [
11748,
25064,
198,
11748,
4704,
278,
198,
11748,
2438,
198,
11748,
17802,
198,
11748,
2438,
198,
11748,
14257,
16663,
198,
11748,
33245,
198,
198,
21943,
2625,
31811,
1,
198,
198,
82,
796,
17802,
13,
44971,
7,
44971,
13,
8579,
62,
1268,... | 2.452632 | 190 |
import pytest
from tartiflette.language.ast import InterfaceTypeDefinitionNode
@pytest.mark.parametrize(
"interface_type_definition_node,other,expected",
[
(
InterfaceTypeDefinitionNode(
name="interfaceTypeDefinitionName",
description="interfaceTypeDefinit... | [
11748,
12972,
9288,
198,
198,
6738,
35842,
361,
21348,
13,
16129,
13,
459,
1330,
26491,
6030,
36621,
19667,
628,
198,
198,
31,
9078,
9288,
13,
4102,
13,
17143,
316,
380,
2736,
7,
198,
220,
220,
220,
366,
39994,
62,
4906,
62,
46758,
... | 2.308144 | 2,554 |
"""
Main Gofra programming language source code.
"""
__author__ = "Kirill Zhosul @kirillzhosul"
__license__ = "MIT"
from typing import Generator
from os.path import basename
from sys import argv
import gofra
from gofra.core.danger import *
from gofra.core.stack import Stack
# MAJOR WARNING FOR ALL READERS.
# ... | [
37811,
198,
220,
220,
220,
8774,
1514,
69,
430,
8300,
3303,
2723,
2438,
13,
198,
198,
37811,
198,
198,
834,
9800,
834,
796,
366,
42,
343,
359,
10511,
418,
377,
2488,
74,
343,
359,
23548,
418,
377,
1,
198,
834,
43085,
834,
796,
366... | 1.961445 | 70,238 |
# Global settings for photologue example project.
import os
DEBUG = TEMPLATE_DEBUG = True
# Top level folder - the one created by the startproject command.
TOP_FOLDER = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
ADMINS = ()
MANAGERS = ADMINS
# Default dev database is Sqlite. In production I us... | [
2,
8060,
6460,
329,
2825,
39795,
1672,
1628,
13,
198,
198,
11748,
28686,
198,
198,
30531,
796,
309,
3620,
6489,
6158,
62,
30531,
796,
6407,
198,
198,
2,
5849,
1241,
9483,
532,
262,
530,
2727,
416,
262,
923,
16302,
3141,
13,
198,
352... | 2.514706 | 1,156 |
# Learning rate scheduler
| [
2,
18252,
2494,
6038,
18173,
201,
198,
201,
198
] | 3.222222 | 9 |
import asyncio
import dataclasses
import itertools
import logging
import pathlib
import sys
import traceback
import typing
from typing import Any, Callable, Dict, FrozenSet, Iterable, Set, Text, Tuple, Type
import gamla
import immutables
import toposort
import typeguard
from gamla.optimized import async_functions as o... | [
11748,
30351,
952,
198,
11748,
4818,
330,
28958,
198,
11748,
340,
861,
10141,
198,
11748,
18931,
198,
11748,
3108,
8019,
198,
11748,
25064,
198,
11748,
12854,
1891,
198,
11748,
19720,
198,
6738,
19720,
1330,
4377,
11,
4889,
540,
11,
360,
... | 2.300254 | 1,965 |
from django.db import models
from django.contrib.auth.models import User
from django.utils import timezone
# Create your models here. | [
6738,
42625,
14208,
13,
9945,
1330,
4981,
198,
6738,
42625,
14208,
13,
3642,
822,
13,
18439,
13,
27530,
1330,
11787,
198,
6738,
42625,
14208,
13,
26791,
1330,
640,
11340,
628,
198,
2,
13610,
534,
4981,
994,
13
] | 3.648649 | 37 |
import torch
import numpy as np
import matplotlib.pyplot as plt
import pandas as pd
import seaborn as sns
import sys
import matplotlib
font = {"size": 30}
matplotlib.rc("font", **font)
matplotlib.rcParams["text.usetex"] = True
n_gene_sets_to_name = 2
results_df = pd.read_csv("./out/st_avg_gene_variance_gsea_result... | [
11748,
28034,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
2603,
29487,
8019,
13,
9078,
29487,
355,
458,
83,
198,
11748,
19798,
292,
355,
279,
67,
198,
198,
11748,
384,
397,
1211,
355,
3013,
82,
198,
11748,
25064,
198,
198,
11748,
... | 2.164211 | 475 |
if __name__ == "__main__":
parser = OptionParser()
Runtime.add_options(parser)
options, args = parser.parse_args()
pid, players = load_config("{{VIFF_CONFIG_LOC}}")
Zp = GF(find_prime(2**65, blum=True))
runtime_class = make_runtime_class(
mixins=[ProbabilisticEqualityMixin, Compari... | [
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
834,
1298,
198,
220,
220,
220,
30751,
796,
16018,
46677,
3419,
198,
220,
220,
220,
43160,
13,
2860,
62,
25811,
7,
48610,
8,
198,
220,
220,
220,
3689,
11,
26498,
796,
30751,
13,
2957... | 2.447964 | 221 |
"""project urls."""
from django.urls import path, re_path
from project.views import ProjectListView, ProjectDetailView
app_name = 'project'
urlpatterns = [
path('', ProjectListView.as_view(), name='index'),
re_path(r'(?P<uid>\w+)/', ProjectDetailView.as_view(), name='detail'),
]
| [
37811,
16302,
2956,
7278,
526,
15931,
198,
6738,
42625,
14208,
13,
6371,
82,
1330,
3108,
11,
302,
62,
6978,
198,
198,
6738,
1628,
13,
33571,
1330,
4935,
8053,
7680,
11,
4935,
11242,
603,
7680,
198,
198,
1324,
62,
3672,
796,
705,
16302... | 2.745283 | 106 |
from flask import Flask, render_template, redirect, url_for, request, session
from flask_restful import Api
from connect import config
from routes.routes import initialize_routes
from my_code.Process import RecommendMovie
from read_file import get_user_id
from read_file import get_rating
app = Flask(__name__)
api =... | [
6738,
42903,
1330,
46947,
11,
8543,
62,
28243,
11,
18941,
11,
19016,
62,
1640,
11,
2581,
11,
6246,
198,
6738,
42903,
62,
2118,
913,
1330,
5949,
72,
198,
6738,
2018,
1330,
4566,
198,
6738,
11926,
13,
81,
448,
274,
1330,
41216,
62,
81... | 2.648402 | 219 |
from PIL import Image, ImageDraw, ImageFont
FONT = ImageFont.load_default() | [
6738,
350,
4146,
1330,
7412,
11,
7412,
25302,
11,
7412,
23252,
198,
198,
37,
35830,
796,
7412,
23252,
13,
2220,
62,
12286,
3419
] | 3.304348 | 23 |