prompt listlengths 1 1 | compression_prompt listlengths 1 1 | target stringlengths 1.03k 828k |
|---|---|---|
[
{
"content": "Return the code unaltered:\n```python\nimport os\nimport sys\nfrom sys import argv, exit\nfrom scipy.sparse.csgraph import dijkstra\n\nimport CPUtimer\n\nfrom data1 import instance_iteratorL, print_solution\n\ndef solve(instance_path):\n timer = CPUtimer.CPUTimer()\n for instance in instance... | [
{
"content": "Return the code unaltered:\n<|memory_start|>```python\nimport os\nimport sys\nfrom sys import argv, exit\nfrom scipy.sparse.csgraph import dijkstra\n\nimport CPUtimer\n\nfrom data1 import instance_iteratorL, print_solution\n\ndef solve(instance_path):\n timer = CPUtimer.CPUTimer()\n for inst... | ```python
import os
import sys
from sys import argv, exit
from scipy.sparse.csgraph import dijkstra
import CPUtimer
from data1 import instance_iteratorL, print_solution
def solve(instance_path):
timer = CPUtimer.CPUTimer()
for instance in instance_iteratorL(instance_path):
verticeInicial = 1
... |
[
{
"content": "```python\n#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\n# Part of the PsychoPy library\n# Copyright (C) 2002-2018 Jonathan Peirce (C) 2019-2020 Open Science Tools Ltd.\n# Distributed under the terms of the GNU General Public License (GPL).\n\n\"\"\"Data useful for calibrations (Smith-Pokorny ... | [
{
"content": "<|memory_start|>```python\n#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\n# Part of the PsychoPy library\n# Copyright (C) 2002-2018 Jonathan Peirce (C) 2019-2020 Open Science Tools Ltd.\n# Distributed under the terms of the GNU General Public License (GPL).\n\n\"\"\"Data useful for calibrations... | ```python
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Part of the PsychoPy library
# Copyright (C) 2002-2018 Jonathan Peirce (C) 2019-2020 Open Science Tools Ltd.
# Distributed under the terms of the GNU General Public License (GPL).
"""Data useful for calibrations (Smith-Pokorny cone fundamentals etc...)
"""
fro... |
[
{
"content": "```python\nfrom datetime import timedelta\n\nimport pytest\nfrom furl import furl\n\nfrom osf_tests.factories import (\n AuthUserFactory,\n PreprintFactory,\n PreprintProviderFactory,\n)\nfrom reviews.permissions import GroupHelper\nfrom reviews_tests.factories import ReviewLogFactory\nfr... | [
{
"content": "<|memory_start|>```python\nfrom datetime import timedelta\n\nimport pytest\nfrom furl import furl\n\nfrom osf_tests.factories import (\n AuthUserFactory,\n PreprintFactory,\n PreprintProviderFactory,\n)\nfrom reviews.permissions import GroupHelper\nfrom reviews_tests.factories import Revi... | ```python
from datetime import timedelta
import pytest
from furl import furl
from osf_tests.factories import (
AuthUserFactory,
PreprintFactory,
PreprintProviderFactory,
)
from reviews.permissions import GroupHelper
from reviews_tests.factories import ReviewLogFactory
from website.util import permissions ... |
[
{
"content": "Here is some code:\n```python\n# Copyright 2015-2017 Cisco Systems, Inc.\n# All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this file except in compliance with the License. You may obtain\n# a copy of the License at\n#\n# ... | [
{
"content": "Here is some code:\n<|memory_start|>```python\n# Copyright 2015-2017 Cisco Systems, Inc.\n# All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this file except in compliance with the License. You may obtain\n# a copy of the License... | ```python
# Copyright 2015-2017 Cisco Systems, 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
#
# ... |
[
{
"content": "Here is the code content:\n```python\nfrom flask import render_template, url_for, Response\n\nfrom common.config import read_config\nfrom common.utils import concat_url_path\nfrom web.content import content\n\n\n@content.route('/jquery', methods=['GET'])\ndef get_jquery():\n \"\"\" Returns the ... | [
{
"content": "Here is the code content:\n<|memory_start|>```python\nfrom flask import render_template, url_for, Response\n\nfrom common.config import read_config\nfrom common.utils import concat_url_path\nfrom web.content import content\n\n\n@content.route('/jquery', methods=['GET'])\ndef get_jquery():\n \"\... | ```python
from flask import render_template, url_for, Response
from common.config import read_config
from common.utils import concat_url_path
from web.content import content
@content.route('/jquery', methods=['GET'])
def get_jquery():
""" Returns the jQuery.js file """
return render_template('javascript/jqu... |
[
{
"content": "```python\nimport os\nfrom gdcdatamodel import models as m\nfrom graphviz import Digraph\n\n\ndef build_visualization():\n print('Building schema documentation...')\n\n # Load directory tree info\n bin_dir = os.path.dirname(os.path.realpath(__file__))\n root_dir = os.path.join(os.path.... | [
{
"content": "<|memory_start|>```python\nimport os\nfrom gdcdatamodel import models as m\nfrom graphviz import Digraph\n\n\ndef build_visualization():\n print('Building schema documentation...')\n\n # Load directory tree info\n bin_dir = os.path.dirname(os.path.realpath(__file__))\n root_dir = os.pa... | ```python
import os
from gdcdatamodel import models as m
from graphviz import Digraph
def build_visualization():
print('Building schema documentation...')
# Load directory tree info
bin_dir = os.path.dirname(os.path.realpath(__file__))
root_dir = os.path.join(os.path.abspath(
os.path.join(bin... |
[
{
"content": "Return the code unaltered:\n```python\n# Copyright (c) 2012, 2013 Rich Porter - see LICENSE for further details\n\nimport re\n\nimport coverage\nimport database\nimport mdb\nimport message\n\n################################################################################\n\n# ids can be given in ... | [
{
"content": "Return the code unaltered:\n<|memory_start|>```python\n# Copyright (c) 2012, 2013 Rich Porter - see LICENSE for further details\n\nimport re\n\nimport coverage\nimport database\nimport mdb\nimport message\n\n################################################################################\n\n# ids ... | ```python
# Copyright (c) 2012, 2013 Rich Porter - see LICENSE for further details
import re
import coverage
import database
import mdb
import message
################################################################################
# ids can be given in the form range-or-id,+
# where range-or-id is [0-9]+(..[0-9]+)... |
[
{
"content": "Here is the source code:\n```python\n# -*- coding: utf-8 -*-\n\"\"\"\n/***************************************************************************\n DemTools\n A QGIS plugin\n A suite of tools for doing neat things with DEMs\n ----------... | [
{
"content": "Here is the source code:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\n\"\"\"\n/***************************************************************************\n DemTools\n A QGIS plugin\n A suite of tools for doing neat things with DEMs\n ... | ```python
# -*- coding: utf-8 -*-
"""
/***************************************************************************
DemTools
A QGIS plugin
A suite of tools for doing neat things with DEMs
-------------------
begin : 2014-05-15
... |
[
{
"content": "Write out the code verbatim, preserving indentation and whitespace:\n```python\n# -*- coding:utf-8 -*-\n#--\n# Copyright (c) 2012-2014 Net-ng.\n# All rights reserved.\n#\n# This software is licensed under the BSD License, as described in\n# the file LICENSE.txt, which you should have received as p... | [
{
"content": "Write out the code verbatim, preserving indentation and whitespace:\n<|memory_start|>```python\n# -*- coding:utf-8 -*-\n#--\n# Copyright (c) 2012-2014 Net-ng.\n# All rights reserved.\n#\n# This software is licensed under the BSD License, as described in\n# the file LICENSE.txt, which you should ha... | ```python
# -*- coding:utf-8 -*-
#--
# Copyright (c) 2012-2014 Net-ng.
# All rights reserved.
#
# This software is licensed under the BSD License, as described in
# the file LICENSE.txt, which you should have received as part of
# this distribution.
#--
from nagare import security
from peak.rules import when
from naga... |
[
{
"content": "Reconstruct the code exactly:\n```python\n# -*- coding: UTF-8 -*-\n\n# Licensed to the Apache Software Foundation (ASF) under one\n# or more contributor license agreements. See the NOTICE file\n# distributed with this work for additional information\n# regarding copyright ownership. The ASF ... | [
{
"content": "Reconstruct the code exactly:\n<|memory_start|>```python\n# -*- coding: UTF-8 -*-\n\n# Licensed to the Apache Software Foundation (ASF) under one\n# or more contributor license agreements. See the NOTICE file\n# distributed with this work for additional information\n# regarding copyright owne... | ```python
# -*- coding: UTF-8 -*-
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Vers... |
[
{
"content": "```python\nfrom dopamine.environments import TestEnvironment\nfrom dopamine.environments import DiscreteCartPoleEnvironment, CartPoleRenderer\n\nfrom dopamine.agents import QAgent, SARSAAgent\nfrom dopamine.experiments import Experiment\nfrom dopamine.adapters import EpsilonGreedyExplorer, VQState... | [
{
"content": "<|memory_start|>```python\nfrom dopamine.environments import TestEnvironment\nfrom dopamine.environments import DiscreteCartPoleEnvironment, CartPoleRenderer\n\nfrom dopamine.agents import QAgent, SARSAAgent\nfrom dopamine.experiments import Experiment\nfrom dopamine.adapters import EpsilonGreedyE... | ```python
from dopamine.environments import TestEnvironment
from dopamine.environments import DiscreteCartPoleEnvironment, CartPoleRenderer
from dopamine.agents import QAgent, SARSAAgent
from dopamine.experiments import Experiment
from dopamine.adapters import EpsilonGreedyExplorer, VQStateDiscretizationAdapter
from ... |
[
{
"content": "Here is the source code:\n```python\n#!python\n\nimport random, time\n\nclass RandomGenerator:\n def __init__(self):\n random.seed(time.clock())\n \n def generate_uniform(self, min_v, max_v):\n return random.uniform(min_v, max_v)\n \n def generate_int(self, min... | [
{
"content": "Here is the source code:\n<|memory_start|>```python\n#!python\n\nimport random, time\n\nclass RandomGenerator:\n def __init__(self):\n random.seed(time.clock())\n \n def generate_uniform(self, min_v, max_v):\n return random.uniform(min_v, max_v)\n \n def genera... | ```python
#!python
import random, time
class RandomGenerator:
def __init__(self):
random.seed(time.clock())
def generate_uniform(self, min_v, max_v):
return random.uniform(min_v, max_v)
def generate_int(self, min_v, max_v):
return random.randint(min_v, max_v)
... |
[
{
"content": "Write out the code verbatim, preserving indentation and whitespace:\n```python\nfrom __future__ import absolute_import\nfrom .nixbase import NixBase\nimport numpy as np\n\n\nclass WeightStack(NixBase):\n\n def __init__(self, nix_object):\n super(WeightStack, self).__init__(nix_object)\n ... | [
{
"content": "Write out the code verbatim, preserving indentation and whitespace:\n<|memory_start|>```python\nfrom __future__ import absolute_import\nfrom .nixbase import NixBase\nimport numpy as np\n\n\nclass WeightStack(NixBase):\n\n def __init__(self, nix_object):\n super(WeightStack, self).__init_... | ```python
from __future__ import absolute_import
from .nixbase import NixBase
import numpy as np
class WeightStack(NixBase):
def __init__(self, nix_object):
super(WeightStack, self).__init__(nix_object)
self._sources = []
self._targets = []
@property
def data(self):
retur... |
[
{
"content": "Reconstruct the code exactly:\n```python\n\"\"\"GPU-based interactive Mandelbrot fractal example.\"\"\"\nfrom galry import *\nimport numpy as np\nimport numpy.random as rdn\n\nFSH = \"\"\"\n// take a position and a number of iterations, and\n// returns the first iteration where the system escapes ... | [
{
"content": "Reconstruct the code exactly:\n<|memory_start|>```python\n\"\"\"GPU-based interactive Mandelbrot fractal example.\"\"\"\nfrom galry import *\nimport numpy as np\nimport numpy.random as rdn\n\nFSH = \"\"\"\n// take a position and a number of iterations, and\n// returns the first iteration where the... | ```python
"""GPU-based interactive Mandelbrot fractal example."""
from galry import *
import numpy as np
import numpy.random as rdn
FSH = """
// take a position and a number of iterations, and
// returns the first iteration where the system escapes a box of size N.
int mandelbrot_escape(vec2 pos, int iterations)
{
vec... |
[
{
"content": "Provide an exact copy of the source code:\n```python\n# Copyright 2015 Google Inc. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# h... | [
{
"content": "Provide an exact copy of the source code:\n<|memory_start|>```python\n# Copyright 2015 Google Inc. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the Licens... | ```python
# Copyright 2015 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
#
# Unless required by applicabl... |
[
{
"content": "```python\n# -*- coding: utf-8 -*-\nfrom django.db import models\n\nfrom sigma_chat.models.chat_member import ChatMember\nfrom sigma_chat.models.chat import Chat\n\n\ndef chat_directory_path(instance, filename):\n # file will be uploaded to MEDIA_ROOT/user_<id>/<filename>\n return 'uploads/c... | [
{
"content": "<|memory_start|>```python\n# -*- coding: utf-8 -*-\nfrom django.db import models\n\nfrom sigma_chat.models.chat_member import ChatMember\nfrom sigma_chat.models.chat import Chat\n\n\ndef chat_directory_path(instance, filename):\n # file will be uploaded to MEDIA_ROOT/user_<id>/<filename>\n r... | ```python
# -*- coding: utf-8 -*-
from django.db import models
from sigma_chat.models.chat_member import ChatMember
from sigma_chat.models.chat import Chat
def chat_directory_path(instance, filename):
# file will be uploaded to MEDIA_ROOT/user_<id>/<filename>
return 'uploads/chats/{0}/{1}'.format(instance.ch... |
[
{
"content": "```python\n\"\"\"\nPlatform-specific code lives here.\n\nThis is its own module to abstract away what would otherwise be distracting\nlogic-flow interruptions.\n\"\"\"\n\nfrom contextlib import contextmanager\nimport select\nimport sys\n\n# TODO: move in here? They're currently platform-agnostic..... | [
{
"content": "<|memory_start|>```python\n\"\"\"\nPlatform-specific code lives here.\n\nThis is its own module to abstract away what would otherwise be distracting\nlogic-flow interruptions.\n\"\"\"\n\nfrom contextlib import contextmanager\nimport select\nimport sys\n\n# TODO: move in here? They're currently pla... | ```python
"""
Platform-specific code lives here.
This is its own module to abstract away what would otherwise be distracting
logic-flow interruptions.
"""
from contextlib import contextmanager
import select
import sys
# TODO: move in here? They're currently platform-agnostic...
from .util import has_fileno, isatty
... |
[
{
"content": "Repeat the code precisely:\n```python\nfrom Tkinter import *\r\n\r\nfrom idlelib import SearchEngine\r\nfrom idlelib.SearchDialogBase import SearchDialogBase\r\nimport re\r\n\r\n\r\ndef replace(text):\r\n root = text._root()\r\n engine = SearchEngine.get(root)\r\n if not hasattr(engine, \... | [
{
"content": "Repeat the code precisely:\n<|memory_start|>```python\nfrom Tkinter import *\r\n\r\nfrom idlelib import SearchEngine\r\nfrom idlelib.SearchDialogBase import SearchDialogBase\r\nimport re\r\n\r\n\r\ndef replace(text):\r\n root = text._root()\r\n engine = SearchEngine.get(root)\r\n if not h... | ```python
from Tkinter import *
from idlelib import SearchEngine
from idlelib.SearchDialogBase import SearchDialogBase
import re
def replace(text):
root = text._root()
engine = SearchEngine.get(root)
if not hasattr(engine, "_replacedialog"):
engine._replacedialog = ReplaceDialog(root, ... |
[
{
"content": "```python\n#!/usr/bin/env python2\n# -*- coding: utf-8 -*-\n\n# Copyright (C) 2012 emijrp\n# Copyright (C) 2015 Matt Hazinski <matt@hazinski.net>\n# This program is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the F... | [
{
"content": "<|memory_start|>```python\n#!/usr/bin/env python2\n# -*- coding: utf-8 -*-\n\n# Copyright (C) 2012 emijrp\n# Copyright (C) 2015 Matt Hazinski <matt@hazinski.net>\n# This program is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as publi... | ```python
#!/usr/bin/env python2
# -*- coding: utf-8 -*-
# Copyright (C) 2012 emijrp
# Copyright (C) 2015 Matt Hazinski <matt@hazinski.net>
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, eithe... |
[
{
"content": "Here is a code snippet:\n```python\nimport unittest\n\n\nclass Solution:\n def restoreIpAddresses(self, s):\n \"\"\"\n :type s: str\n :rtype: List[str]\n \"\"\"\n result = []\n slen = len(s)\n # [0,p1) [p1,p2) [p2,p3) [p3,slen)\n for p1 in... | [
{
"content": "Here is a code snippet:\n<|memory_start|>```python\nimport unittest\n\n\nclass Solution:\n def restoreIpAddresses(self, s):\n \"\"\"\n :type s: str\n :rtype: List[str]\n \"\"\"\n result = []\n slen = len(s)\n # [0,p1) [p1,p2) [p2,p3) [p3,slen)\n ... | ```python
import unittest
class Solution:
def restoreIpAddresses(self, s):
"""
:type s: str
:rtype: List[str]
"""
result = []
slen = len(s)
# [0,p1) [p1,p2) [p2,p3) [p3,slen)
for p1 in range(1, 4):
for p2 in range(p1 + 1, p1 + 4):
... |
[
{
"content": "```python\n\"\"\" smashlib.plugins.env_command\n\"\"\"\nimport os\nfrom smashlib import get_smash\nfrom smashlib.plugins import Plugin\nfrom smashlib.patches.base import PatchMagic\nfrom smashlib.completion import smash_env_complete\n\nenv_completer = lambda himself, event: smash_env_complete(even... | [
{
"content": "<|memory_start|>```python\n\"\"\" smashlib.plugins.env_command\n\"\"\"\nimport os\nfrom smashlib import get_smash\nfrom smashlib.plugins import Plugin\nfrom smashlib.patches.base import PatchMagic\nfrom smashlib.completion import smash_env_complete\n\nenv_completer = lambda himself, event: smash_e... | ```python
""" smashlib.plugins.env_command
"""
import os
from smashlib import get_smash
from smashlib.plugins import Plugin
from smashlib.patches.base import PatchMagic
from smashlib.completion import smash_env_complete
env_completer = lambda himself, event: smash_env_complete(event.symbol)
env_regex = r'env [A-Za-z0-... |
[
{
"content": "Reconstruct the code exactly:\n```python\n\"\"\"\n``fitscheck`` is a command line script based on pyfits for verifying and\nupdating the CHECKSUM and DATASUM keywords of .fits files. ``fitscheck`` can\nalso detect and often fix other FITS standards violations. ``fitscheck``\nfacilitates re-writi... | [
{
"content": "Reconstruct the code exactly:\n<|memory_start|>```python\n\"\"\"\n``fitscheck`` is a command line script based on pyfits for verifying and\nupdating the CHECKSUM and DATASUM keywords of .fits files. ``fitscheck`` can\nalso detect and often fix other FITS standards violations. ``fitscheck``\nfaci... | ```python
"""
``fitscheck`` is a command line script based on pyfits for verifying and
updating the CHECKSUM and DATASUM keywords of .fits files. ``fitscheck`` can
also detect and often fix other FITS standards violations. ``fitscheck``
facilitates re-writing the non-standard checksums originally generated by
pyfits ... |
[
{
"content": "```python\nimport cv2\nimport numpy\n\nimport Tool\n\nclass HueEqualiser(Tool.Tool):\n def on_init(self):\n self.id = \"hueequaliser\"\n self.name = \"Hue Equaliser\"\n self.icon_path = \"ui/PF2_Icons/HueEqualiser.png\"\n self.properties = [\n Tool.Propert... | [
{
"content": "<|memory_start|>```python\nimport cv2\nimport numpy\n\nimport Tool\n\nclass HueEqualiser(Tool.Tool):\n def on_init(self):\n self.id = \"hueequaliser\"\n self.name = \"Hue Equaliser\"\n self.icon_path = \"ui/PF2_Icons/HueEqualiser.png\"\n self.properties = [\n ... | ```python
import cv2
import numpy
import Tool
class HueEqualiser(Tool.Tool):
def on_init(self):
self.id = "hueequaliser"
self.name = "Hue Equaliser"
self.icon_path = "ui/PF2_Icons/HueEqualiser.png"
self.properties = [
Tool.Property("header", "Hue Equaliser", "Header", N... |
[
{
"content": "```python\n#!/usr/bin/python\n# Copyright: (c) 2018, Ondrej Famera <ondrej-xa2iel8u@famera.cz>\n# GNU General Public License v3.0+ (see LICENSE-GPLv3.txt or https://www.gnu.org/licenses/gpl-3.0.txt)\n# Apache License v2.0 (see LICENSE-APACHE2.txt or http://www.apache.org/licenses/LICENSE-2.0)\n\nf... | [
{
"content": "<|memory_start|>```python\n#!/usr/bin/python\n# Copyright: (c) 2018, Ondrej Famera <ondrej-xa2iel8u@famera.cz>\n# GNU General Public License v3.0+ (see LICENSE-GPLv3.txt or https://www.gnu.org/licenses/gpl-3.0.txt)\n# Apache License v2.0 (see LICENSE-APACHE2.txt or http://www.apache.org/licenses/L... | ```python
#!/usr/bin/python
# Copyright: (c) 2018, Ondrej Famera <ondrej-xa2iel8u@famera.cz>
# GNU General Public License v3.0+ (see LICENSE-GPLv3.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# Apache License v2.0 (see LICENSE-APACHE2.txt or http://www.apache.org/licenses/LICENSE-2.0)
from __future__ import absolu... |
[
{
"content": "Repeat the code precisely:\n```python\n#-------------------------------------------------------------------------------\n\n# ServiceManager.py\n#\n# Purpose: Creates, updates, deletes services in ArcGIS Online\n#\n#\n# Prerequisites/Inputs:\n# TokenManager: authentication token for NPS... | [
{
"content": "Repeat the code precisely:\n<|memory_start|>```python\n#-------------------------------------------------------------------------------\n\n# ServiceManager.py\n#\n# Purpose: Creates, updates, deletes services in ArcGIS Online\n#\n#\n# Prerequisites/Inputs:\n# TokenManager: authenticati... | ```python
#-------------------------------------------------------------------------------
# ServiceManager.py
#
# Purpose: Creates, updates, deletes services in ArcGIS Online
#
#
# Prerequisites/Inputs:
# TokenManager: authentication token for NPS ArcGIS Online
# ServiceConfiguration: service config... |
[
{
"content": "Repeat the code exactly as the original, including blank lines:\n```python\n# Copyright(c) 2017, Dimitar Venkov\n# @5devene, dimitar.ven@gmail.com\n# www.badmonkeys.net\n\n#inspired by Troy Gates https://forums.autodesk.com/t5/revit-api/revit-api-selected-element-set-order/td-p/5597203\n\nimport c... | [
{
"content": "Repeat the code exactly as the original, including blank lines:\n<|memory_start|>```python\n# Copyright(c) 2017, Dimitar Venkov\n# @5devene, dimitar.ven@gmail.com\n# www.badmonkeys.net\n\n#inspired by Troy Gates https://forums.autodesk.com/t5/revit-api/revit-api-selected-element-set-order/td-p/559... | ```python
# Copyright(c) 2017, Dimitar Venkov
# @5devene, dimitar.ven@gmail.com
# www.badmonkeys.net
#inspired by Troy Gates https://forums.autodesk.com/t5/revit-api/revit-api-selected-element-set-order/td-p/5597203
import clr
clr.AddReference("RevitAPIUI")
from Autodesk.Revit.UI import *
clr.AddReference("RevitAPI... |
[
{
"content": "Write the code verbatim:\n```python\nfrom itertools import chain\n\nfrom collections import (\n defaultdict,\n Iterable,\n)\n\nfrom django.http import HttpResponseNotAllowed\n\n\n__version__ = '0.1.1'\n\n\nclass Handler(object):\n \"\"\"Container for views.\n\n :param decorators: (opti... | [
{
"content": "Write the code verbatim:\n<|memory_start|>```python\nfrom itertools import chain\n\nfrom collections import (\n defaultdict,\n Iterable,\n)\n\nfrom django.http import HttpResponseNotAllowed\n\n\n__version__ = '0.1.1'\n\n\nclass Handler(object):\n \"\"\"Container for views.\n\n :param d... | ```python
from itertools import chain
from collections import (
defaultdict,
Iterable,
)
from django.http import HttpResponseNotAllowed
__version__ = '0.1.1'
class Handler(object):
"""Container for views.
:param decorators: (optional) list of decorators that will be applied
to each endpoi... |
[
{
"content": "Here is the script:\n```python\n# =============================================================================\n# Copyright (C) 2010 Diego Duclos\n#\n# This file is part of pyfa.\n#\n# pyfa is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public Lic... | [
{
"content": "Here is the script:\n<|memory_start|>```python\n# =============================================================================\n# Copyright (C) 2010 Diego Duclos\n#\n# This file is part of pyfa.\n#\n# pyfa is free software: you can redistribute it and/or modify\n# it under the terms of the GNU Ge... | ```python
# =============================================================================
# Copyright (C) 2010 Diego Duclos
#
# This file is part of pyfa.
#
# pyfa is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundatio... |
[
{
"content": "```python\nimport base64\nimport csv\nimport sys\n\nFIELDS = (\"summary\", \"detail\")\n\n\ndef extract_doc(stream):\n\n targets = dict()\n target = None\n\n for line in stream:\n\n # only comment lines\n if not line.startswith(\"#\"):\n continue\n\n # stri... | [
{
"content": "<|memory_start|>```python\nimport base64\nimport csv\nimport sys\n\nFIELDS = (\"summary\", \"detail\")\n\n\ndef extract_doc(stream):\n\n targets = dict()\n target = None\n\n for line in stream:\n\n # only comment lines\n if not line.startswith(\"#\"):\n continue\n... | ```python
import base64
import csv
import sys
FIELDS = ("summary", "detail")
def extract_doc(stream):
targets = dict()
target = None
for line in stream:
# only comment lines
if not line.startswith("#"):
continue
# strip off the comment, trailing whitespace, and a s... |
[
{
"content": "Return the code exactly, with no changes:\n```python\nimport pygame\n\nBLACK = ( 0, 0, 0)\nWHITE = ( 255, 255, 255)\nBLUE = ( 0, 0, 255)\nRED = ( 255, 0, 0)\nGREEN = ( 0, 255, 0)\n\nsize = (800, 600)\n\nclass Player(pygame.sprite.Sprite):\n\n\tchange_x = 0\n\tchange_y = 0\n\n\tlevel = None\n\t\n\t... | [
{
"content": "Return the code exactly, with no changes:\n<|memory_start|>```python\nimport pygame\n\nBLACK = ( 0, 0, 0)\nWHITE = ( 255, 255, 255)\nBLUE = ( 0, 0, 255)\nRED = ( 255, 0, 0)\nGREEN = ( 0, 255, 0)\n\nsize = (800, 600)\n\nclass Player(pygame.sprite.Sprite):\n\n\tchange_x = 0\n\tchange_y = 0\n\n\tleve... | ```python
import pygame
BLACK = ( 0, 0, 0)
WHITE = ( 255, 255, 255)
BLUE = ( 0, 0, 255)
RED = ( 255, 0, 0)
GREEN = ( 0, 255, 0)
size = (800, 600)
class Player(pygame.sprite.Sprite):
change_x = 0
change_y = 0
level = None
def __init__(self):
pygame.sprite.Sprite.__init__(self)
#The player. take an image,... |
[
{
"content": "Here is the script:\n```python\n# -*- encoding: utf-8 -*-\n# #############################################################################\n#\n# OpenERP, Open Source Management Solution\n# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).\n#\n# This program is free software: you can r... | [
{
"content": "Here is the script:\n<|memory_start|>```python\n# -*- encoding: utf-8 -*-\n# #############################################################################\n#\n# OpenERP, Open Source Management Solution\n# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).\n#\n# This program is free sof... | ```python
# -*- encoding: utf-8 -*-
# #############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the ter... |
[
{
"content": "```python\n# Samba-specific bits for optparse\n# Copyright (C) Jelmer Vernooij <jelmer@samba.org> 2007\n#\n# This program is free software; you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the Free Software Foundation; either version ... | [
{
"content": "<|memory_start|>```python\n# Samba-specific bits for optparse\n# Copyright (C) Jelmer Vernooij <jelmer@samba.org> 2007\n#\n# This program is free software; you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the Free Software Foundation;... | ```python
# Samba-specific bits for optparse
# Copyright (C) Jelmer Vernooij <jelmer@samba.org> 2007
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at y... |
[
{
"content": "Provide an exact copy of the source code:\n```python\n# vim: tabstop=4 shiftwidth=4 softtabstop=4\n\n# Copyright 2010 United States Government as represented by the\n# Administrator of the National Aeronautics and Space Administration.\n# All Rights Reserved.\n# Copyright 2011 - 2012, Red Hat, Inc... | [
{
"content": "Provide an exact copy of the source code:\n<|memory_start|>```python\n# vim: tabstop=4 shiftwidth=4 softtabstop=4\n\n# Copyright 2010 United States Government as represented by the\n# Administrator of the National Aeronautics and Space Administration.\n# All Rights Reserved.\n# Copyright 2011 - 20... | ```python
# vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
# Copyright 2011 - 2012, Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License")... |
[
{
"content": "Here is the script:\n```python\n# char encode:\n# the value can be: utf-8, ascii, windows-1252, ...\nchar_encode = 'ascii'\n\nimport os\nimport os_base\nimport codecs\n\n#\nmat_data = []\nftxt = \"materials_data.txt\"\nm3d_ex = \"_export.m3d\"\n\n#\nname_list = ['sinon']\nname_list += ['pepper']\n... | [
{
"content": "Here is the script:\n<|memory_start|>```python\n# char encode:\n# the value can be: utf-8, ascii, windows-1252, ...\nchar_encode = 'ascii'\n\nimport os\nimport os_base\nimport codecs\n\n#\nmat_data = []\nftxt = \"materials_data.txt\"\nm3d_ex = \"_export.m3d\"\n\n#\nname_list = ['sinon']\nname_list... | ```python
# char encode:
# the value can be: utf-8, ascii, windows-1252, ...
char_encode = 'ascii'
import os
import os_base
import codecs
#
mat_data = []
ftxt = "materials_data.txt"
m3d_ex = "_export.m3d"
#
name_list = ['sinon']
name_list += ['pepper']
name_list += ['nino']
name_list += ['black_warrior']
#
mat_star... |
[
{
"content": "Return the code exactly, with no changes:\n```python\n# Generated by the protocol buffer compiler. DO NOT EDIT!\n# source: pogoprotos/networking/platform/responses/plat_eight_response.proto\n\nimport sys\n_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))\nfrom google.prot... | [
{
"content": "Return the code exactly, with no changes:\n<|memory_start|>```python\n# Generated by the protocol buffer compiler. DO NOT EDIT!\n# source: pogoprotos/networking/platform/responses/plat_eight_response.proto\n\nimport sys\n_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))\n... | ```python
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: pogoprotos/networking/platform/responses/plat_eight_response.proto
import sys
_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))
from google.protobuf import descriptor as _descriptor
from google.protobuf import messa... |
[
{
"content": "Produce an exact reconstruction of the code:\n```python\nimport os\nfrom flask import Flask, request, jsonify\nfrom mongoengine import *\nimport datetime\n\napp = Flask(__name__)\n\nmongodb_uri = os.environ.get('MONGODB_URI', 'localhost:27017')\n\nconnect(\"pokerstats\", host=mongodb_uri)\n\nclass... | [
{
"content": "Produce an exact reconstruction of the code:\n<|memory_start|>```python\nimport os\nfrom flask import Flask, request, jsonify\nfrom mongoengine import *\nimport datetime\n\napp = Flask(__name__)\n\nmongodb_uri = os.environ.get('MONGODB_URI', 'localhost:27017')\n\nconnect(\"pokerstats\", host=mongo... | ```python
import os
from flask import Flask, request, jsonify
from mongoengine import *
import datetime
app = Flask(__name__)
mongodb_uri = os.environ.get('MONGODB_URI', 'localhost:27017')
connect("pokerstats", host=mongodb_uri)
class Player(Document):
name = StringField(required=True, unique=True, max_length=200)... |
[
{
"content": "Here is a code file:\n```python\nfrom elemental_core.util import process_uuids_value\n\nfrom ._resource_type import ResourceType\nfrom ._resource_reference import ResourceReference\nfrom ._property_changed_hook import PropertyChangedHook\n\n\nclass FilterType(ResourceType):\n \"\"\"\n Repres... | [
{
"content": "Here is a code file:\n<|memory_start|>```python\nfrom elemental_core.util import process_uuids_value\n\nfrom ._resource_type import ResourceType\nfrom ._resource_reference import ResourceReference\nfrom ._property_changed_hook import PropertyChangedHook\n\n\nclass FilterType(ResourceType):\n \"... | ```python
from elemental_core.util import process_uuids_value
from ._resource_type import ResourceType
from ._resource_reference import ResourceReference
from ._property_changed_hook import PropertyChangedHook
class FilterType(ResourceType):
"""
Represents a collection of AttributeIds that should be filtered... |
[
{
"content": "```python\nimport itertools\n\nfrom utils.utils import range_union\n\n# adapted from ips-util for python 3.2 (https://pypi.org/project/ips-util/)\nclass IPS_Patch(object):\n def __init__(self, patchDict=None):\n self.records = []\n self.truncate_length = None\n self.max_siz... | [
{
"content": "<|memory_start|>```python\nimport itertools\n\nfrom utils.utils import range_union\n\n# adapted from ips-util for python 3.2 (https://pypi.org/project/ips-util/)\nclass IPS_Patch(object):\n def __init__(self, patchDict=None):\n self.records = []\n self.truncate_length = None\n ... | ```python
import itertools
from utils.utils import range_union
# adapted from ips-util for python 3.2 (https://pypi.org/project/ips-util/)
class IPS_Patch(object):
def __init__(self, patchDict=None):
self.records = []
self.truncate_length = None
self.max_size = 0
if patchDict is no... |
[
{
"content": "Output the full code verbatim (no extra comments):\n```python\n# -*- coding: utf-8 -*-\n\n# Copyright 2013 Mirantis, Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this file except in compliance with the License. You may obtain\n# a copy... | [
{
"content": "Output the full code verbatim (no extra comments):\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\n\n# Copyright 2013 Mirantis, Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this file except in compliance with the License. You may obt... | ```python
# -*- coding: utf-8 -*-
# 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
#
# Un... |
[
{
"content": "```python\n# Copyright 2015-2016 Yelp Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requir... | [
{
"content": "<|memory_start|>```python\n# Copyright 2015-2016 Yelp Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\... | ```python
# Copyright 2015-2016 Yelp 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 agreed to... |
[
{
"content": "Here is the code block:\n```python\n# Copyright 2017 Google LLC\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.... | [
{
"content": "Here is the code block:\n<|memory_start|>```python\n# Copyright 2017 Google LLC\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/lic... | ```python
# Copyright 2017 Google LLC
#
# 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 ... |
[
{
"content": "Here is the snippet:\n```python\n#!/usr/bin/env python\n\nimport unittest\nfrom day22 import Node, make_nodes, viable_nodes\n\n\nclass TestMakingNodes(unittest.TestCase):\n\n def test_makes_nodes_from_input(self):\n df = \"\"\"\n /dev/grid/node-x0-y0 87T 71T 16T 81%\n ... | [
{
"content": "Here is the snippet:\n<|memory_start|>```python\n#!/usr/bin/env python\n\nimport unittest\nfrom day22 import Node, make_nodes, viable_nodes\n\n\nclass TestMakingNodes(unittest.TestCase):\n\n def test_makes_nodes_from_input(self):\n df = \"\"\"\n /dev/grid/node-x0-y0 87T 71T ... | ```python
#!/usr/bin/env python
import unittest
from day22 import Node, make_nodes, viable_nodes
class TestMakingNodes(unittest.TestCase):
def test_makes_nodes_from_input(self):
df = """
/dev/grid/node-x0-y0 87T 71T 16T 81%
/dev/grid/node-x0-y1 93T 72T 21T 77%
... |
[
{
"content": "```python\n\"\"\" Test the API for Gyms \"\"\"\nfrom datetime import datetime, timedelta\nfrom app.models.gym import Gym\nfrom app.models.gym_item import GymItem\nfrom app.models.raid_item import RaidItem\nfrom app.tests.api.personalised.gym_collection.gym_common import \\\n GymAPICommonCase\ni... | [
{
"content": "<|memory_start|>```python\n\"\"\" Test the API for Gyms \"\"\"\nfrom datetime import datetime, timedelta\nfrom app.models.gym import Gym\nfrom app.models.gym_item import GymItem\nfrom app.models.raid_item import RaidItem\nfrom app.tests.api.personalised.gym_collection.gym_common import \\\n Gym... | ```python
""" Test the API for Gyms """
from datetime import datetime, timedelta
from app.models.gym import Gym
from app.models.gym_item import GymItem
from app.models.raid_item import RaidItem
from app.tests.api.personalised.gym_collection.gym_common import \
GymAPICommonCase
import pytz
class TestGymCollectionM... |
[
{
"content": "Here is the source code:\n```python\n# -*- coding: utf-8 -*-\nimport hashlib\nimport libtorrent as lt\nimport logging\nfrom threading import Timer, Event\nimport os\nimport time\nfrom p2c.exceptions import SessionNotBindedException, TorrentHasNotMetadataYet\nimport settings\nfrom torrent.movie imp... | [
{
"content": "Here is the source code:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\nimport hashlib\nimport libtorrent as lt\nimport logging\nfrom threading import Timer, Event\nimport os\nimport time\nfrom p2c.exceptions import SessionNotBindedException, TorrentHasNotMetadataYet\nimport settings\nfrom t... | ```python
# -*- coding: utf-8 -*-
import hashlib
import libtorrent as lt
import logging
from threading import Timer, Event
import os
import time
from p2c.exceptions import SessionNotBindedException, TorrentHasNotMetadataYet
import settings
from torrent.movie import Movie
SOURCE_TYPES = ("MAGNET", "TORRENT")
logger = ... |
[
{
"content": "Repeat the code exactly as the original, including blank lines:\n```python\nimport networkx as nx\nfrom load_data import *\nfrom compute_metrics_multiplex import *\n\ndef numNodes(g):\n return g.number_of_nodes()\n \ndef numEdges(g):\n return g.number_of_edges()\n \ndef avgDeg(g):\n ... | [
{
"content": "Repeat the code exactly as the original, including blank lines:\n<|memory_start|>```python\nimport networkx as nx\nfrom load_data import *\nfrom compute_metrics_multiplex import *\n\ndef numNodes(g):\n return g.number_of_nodes()\n \ndef numEdges(g):\n return g.number_of_edges()\n \ndef... | ```python
import networkx as nx
from load_data import *
from compute_metrics_multiplex import *
def numNodes(g):
return g.number_of_nodes()
def numEdges(g):
return g.number_of_edges()
def avgDeg(g):
return g.number_of_edges()*1.0/g.number_of_nodes()
def getGiantComponent(g):
return g.sub... |
[
{
"content": "Here is a code snippet:\n```python\n# encoding: utf-8\nfrom south.v2 import DataMigration\nfrom django.contrib.gis.maps.google.overlays import GPolygon\n\nclass Migration(DataMigration):\n class NewGPolygon(GPolygon):\n def latlng_from_coords(self, coords):\n \"Generates a Jav... | [
{
"content": "Here is a code snippet:\n<|memory_start|>```python\n# encoding: utf-8\nfrom south.v2 import DataMigration\nfrom django.contrib.gis.maps.google.overlays import GPolygon\n\nclass Migration(DataMigration):\n class NewGPolygon(GPolygon):\n def latlng_from_coords(self, coords):\n \... | ```python
# encoding: utf-8
from south.v2 import DataMigration
from django.contrib.gis.maps.google.overlays import GPolygon
class Migration(DataMigration):
class NewGPolygon(GPolygon):
def latlng_from_coords(self, coords):
"Generates a JavaScript array of GLatLng objects for the given coordinat... |
[
{
"content": "```python\n#!/usr/bin/env python3\n# -*- coding: UTF-8 -*-\n#----------------------------------------------------------------------------\n\"\"\"HTTP content negotiation application.\"\"\"\n__author__ = ('Lance Finn Helsten',)\n__version__ = '0.0'\n__copyright__ = \"\"\"Copyright (C) 2014 Lance Fi... | [
{
"content": "<|memory_start|>```python\n#!/usr/bin/env python3\n# -*- coding: UTF-8 -*-\n#----------------------------------------------------------------------------\n\"\"\"HTTP content negotiation application.\"\"\"\n__author__ = ('Lance Finn Helsten',)\n__version__ = '0.0'\n__copyright__ = \"\"\"Copyright (... | ```python
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
#----------------------------------------------------------------------------
"""HTTP content negotiation application."""
__author__ = ('Lance Finn Helsten',)
__version__ = '0.0'
__copyright__ = """Copyright (C) 2014 Lance Finn Helsten"""
__license__ = """
Li... |
[
{
"content": "Here is the code block:\n```python\n\"\"\"\r\nSTDM Import/Export module\r\n\"\"\"\r\n__author__ = 'John Gitau'\r\n__license__ = 'GNU Lesser General Public License (LGPL)'\r\n__url__ = 'http://www.unhabitat.org'\r\n\r\nfrom stdm.settings import QGISRegistryConfig\r\nfrom .exceptions import Translat... | [
{
"content": "Here is the code block:\n<|memory_start|>```python\n\"\"\"\r\nSTDM Import/Export module\r\n\"\"\"\r\n__author__ = 'John Gitau'\r\n__license__ = 'GNU Lesser General Public License (LGPL)'\r\n__url__ = 'http://www.unhabitat.org'\r\n\r\nfrom stdm.settings import QGISRegistryConfig\r\nfrom .exceptions... | ```python
"""
STDM Import/Export module
"""
__author__ = 'John Gitau'
__license__ = 'GNU Lesser General Public License (LGPL)'
__url__ = 'http://www.unhabitat.org'
from stdm.settings import QGISRegistryConfig
from .exceptions import TranslatorException
from .reader import OGRReader
from .writer import OGRWri... |
[
{
"content": "```python\n# coding=utf-8\n# Copyright 2021 The Google Research Authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/L... | [
{
"content": "<|memory_start|>```python\n# coding=utf-8\n# Copyright 2021 The Google Research Authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apach... | ```python
# coding=utf-8
# Copyright 2021 The Google Research Authors.
#
# 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 b... |
[
{
"content": "Replicate the source code:\n```python\nimport types\nimport platform\n\n_PYTHON_VERSION = platform.python_version()\n_IS_PYTHON_3 = _PYTHON_VERSION >= '3'\n_IS_BELOW_PYTHON_2_7 = _PYTHON_VERSION < '2.7'\n\ndef get_underlying_function(f):\n if _IS_BELOW_PYTHON_2_7 and (isinstance(f, classmethod)... | [
{
"content": "Replicate the source code:\n<|memory_start|>```python\nimport types\nimport platform\n\n_PYTHON_VERSION = platform.python_version()\n_IS_PYTHON_3 = _PYTHON_VERSION >= '3'\n_IS_BELOW_PYTHON_2_7 = _PYTHON_VERSION < '2.7'\n\ndef get_underlying_function(f):\n if _IS_BELOW_PYTHON_2_7 and (isinstance... | ```python
import types
import platform
_PYTHON_VERSION = platform.python_version()
_IS_PYTHON_3 = _PYTHON_VERSION >= '3'
_IS_BELOW_PYTHON_2_7 = _PYTHON_VERSION < '2.7'
def get_underlying_function(f):
if _IS_BELOW_PYTHON_2_7 and (isinstance(f, classmethod) or isinstance(f, staticmethod)):
return _get_under... |
[
{
"content": "```python\nimport datetime\n\nfrom django.core import signing\nfrom django.test import SimpleTestCase\nfrom django.test.utils import freeze_time\nfrom django.utils.crypto import InvalidAlgorithm\n\n\nclass TestSigner(SimpleTestCase):\n\n def test_signature(self):\n \"signature() method s... | [
{
"content": "<|memory_start|>```python\nimport datetime\n\nfrom django.core import signing\nfrom django.test import SimpleTestCase\nfrom django.test.utils import freeze_time\nfrom django.utils.crypto import InvalidAlgorithm\n\n\nclass TestSigner(SimpleTestCase):\n\n def test_signature(self):\n \"sign... | ```python
import datetime
from django.core import signing
from django.test import SimpleTestCase
from django.test.utils import freeze_time
from django.utils.crypto import InvalidAlgorithm
class TestSigner(SimpleTestCase):
def test_signature(self):
"signature() method should generate a signature"
... |
[
{
"content": "```python\n# Copyright 2013 Hewlett-Packard Development Company, L.P.\n# All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this file except in compliance with the License. You may obtain\n# a copy of the License at\n#\n# ... | [
{
"content": "<|memory_start|>```python\n# Copyright 2013 Hewlett-Packard Development Company, L.P.\n# All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this file except in compliance with the License. You may obtain\n# a copy of the License... | ```python
# Copyright 2013 Hewlett-Packard Development Company, L.P.
# 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... |
[
{
"content": "Return the code exactly, with no changes:\n```python\nimport tensorflow as tf #Tensorflow사용을 위한 import\nfrom tensorflow.examples.tutorials.mnist import input_data\n\n# Dataset loading\nmnist = input_data.read_data_sets(\"./samples/MNIST_data/\", one_hot=True)\n\n# Set up model\nx = tf.placeh... | [
{
"content": "Return the code exactly, with no changes:\n<|memory_start|>```python\nimport tensorflow as tf #Tensorflow사용을 위한 import\nfrom tensorflow.examples.tutorials.mnist import input_data\n\n# Dataset loading\nmnist = input_data.read_data_sets(\"./samples/MNIST_data/\", one_hot=True)\n\n# Set up mode... | ```python
import tensorflow as tf #Tensorflow사용을 위한 import
from tensorflow.examples.tutorials.mnist import input_data
# Dataset loading
mnist = input_data.read_data_sets("./samples/MNIST_data/", one_hot=True)
# Set up model
x = tf.placeholder(tf.float32, [None, 784]) #심볼릭 변수들을 사용하여 상호작용하는 작업들을 기술
W = tf.Va... |
[
{
"content": "Repeat the code exactly as the original, including blank lines:\n```python\n# -*- coding: utf-8 -*-\n##############################################################################\n#\n# OpenERP, Open Source Management Solution\n# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).\n# Co... | [
{
"content": "Repeat the code exactly as the original, including blank lines:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\n##############################################################################\n#\n# OpenERP, Open Source Management Solution\n# Copyright (C) 2004-2009 Tiny SPRL (<http://tin... | ```python
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
# Copyright (C) 2011 SYLEAM (<http://syleam.fr/>)
# Copyright (C) 2013 Julius Network Solution... |
[
{
"content": "```python\nimport qrcode\n\nfrom PyQt5.QtGui import QColor, QPen\nimport PyQt5.QtGui as QtGui\nfrom PyQt5.QtCore import Qt\nfrom PyQt5.QtWidgets import (\n QApplication, QVBoxLayout, QTextEdit, QHBoxLayout, QPushButton, QWidget,\n QFileDialog,\n)\n\nfrom electrum_ltc.i18n import _\nfrom elec... | [
{
"content": "<|memory_start|>```python\nimport qrcode\n\nfrom PyQt5.QtGui import QColor, QPen\nimport PyQt5.QtGui as QtGui\nfrom PyQt5.QtCore import Qt\nfrom PyQt5.QtWidgets import (\n QApplication, QVBoxLayout, QTextEdit, QHBoxLayout, QPushButton, QWidget,\n QFileDialog,\n)\n\nfrom electrum_ltc.i18n imp... | ```python
import qrcode
from PyQt5.QtGui import QColor, QPen
import PyQt5.QtGui as QtGui
from PyQt5.QtCore import Qt
from PyQt5.QtWidgets import (
QApplication, QVBoxLayout, QTextEdit, QHBoxLayout, QPushButton, QWidget,
QFileDialog,
)
from electrum_ltc.i18n import _
from electrum_ltc.simple_config import Simp... |
[
{
"content": "Here is the snippet:\n```python\n#\n# Copyright (c) 2015 Red Hat\n# Licensed under The MIT License (MIT)\n# http://opensource.org/licenses/MIT\n#\nimport json\n\nfrom django.contrib.contenttypes.models import ContentType\nfrom django.core.urlresolvers import reverse\nfrom django.shortcuts import g... | [
{
"content": "Here is the snippet:\n<|memory_start|>```python\n#\n# Copyright (c) 2015 Red Hat\n# Licensed under The MIT License (MIT)\n# http://opensource.org/licenses/MIT\n#\nimport json\n\nfrom django.contrib.contenttypes.models import ContentType\nfrom django.core.urlresolvers import reverse\nfrom django.sh... | ```python
#
# Copyright (c) 2015 Red Hat
# Licensed under The MIT License (MIT)
# http://opensource.org/licenses/MIT
#
import json
from django.contrib.contenttypes.models import ContentType
from django.core.urlresolvers import reverse
from django.shortcuts import get_object_or_404
from django.utils import six
from dja... |
[
{
"content": "Repeat the code precisely:\n```python\n# -*- coding: utf-8 -*-\n# Generated by Django 1.11.5 on 2017-10-16 20:06\nfrom __future__ import unicode_literals\n\nfrom django.db import migrations, models\n\n\nclass Migration(migrations.Migration):\n\n dependencies = [\n ('ofahrtbase', '0019_au... | [
{
"content": "Repeat the code precisely:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\n# Generated by Django 1.11.5 on 2017-10-16 20:06\nfrom __future__ import unicode_literals\n\nfrom django.db import migrations, models\n\n\nclass Migration(migrations.Migration):\n\n dependencies = [\n ('ofahr... | ```python
# -*- coding: utf-8 -*-
# Generated by Django 1.11.5 on 2017-10-16 20:06
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('ofahrtbase', '0019_auto_20161020_1750'),
]
operations = [
migrati... |
[
{
"content": "Provide a verbatim copy of the code:\n```python\n# -*- coding: utf-8 -*-\n\n\"\"\"\n***************************************************************************\n edgebundlingProviderPlugin.py\n ---------------------\n Date : January 2018\n Copyright : (C) 201... | [
{
"content": "Provide a verbatim copy of the code:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\n\n\"\"\"\n***************************************************************************\n edgebundlingProviderPlugin.py\n ---------------------\n Date : January 2018\n Copyright ... | ```python
# -*- coding: utf-8 -*-
"""
***************************************************************************
edgebundlingProviderPlugin.py
---------------------
Date : January 2018
Copyright : (C) 2018 by Anita Graser
Email : anitagraser@gmx.at
*******... |
[
{
"content": "Here is the code block:\n```python\n# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\nfrom spack import *\n\n\nclass Precice(CMakePackage):\n ... | [
{
"content": "Here is the code block:\n<|memory_start|>```python\n# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\nfrom spack import *\n\n\nclass Precice(CMak... | ```python
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack import *
class Precice(CMakePackage):
"""preCICE (Precise Code Interaction Coupling Environment... |
[
{
"content": "Replicate the source code:\n```python\nfrom __future__ import absolute_import, print_function\n\nimport os.path\nfrom uuid import uuid4\nfrom functools import wraps\n\nimport warnings\nimport logging\nlogger = logging.getLogger(__file__)\n\nfrom six import add_metaclass, iteritems\nfrom six.moves.... | [
{
"content": "Replicate the source code:\n<|memory_start|>```python\nfrom __future__ import absolute_import, print_function\n\nimport os.path\nfrom uuid import uuid4\nfrom functools import wraps\n\nimport warnings\nimport logging\nlogger = logging.getLogger(__file__)\n\nfrom six import add_metaclass, iteritems\... | ```python
from __future__ import absolute_import, print_function
import os.path
from uuid import uuid4
from functools import wraps
import warnings
import logging
logger = logging.getLogger(__file__)
from six import add_metaclass, iteritems
from six.moves.urllib.parse import urlsplit
from .embed import autoload_stat... |
[
{
"content": "Reconstruct the code exactly:\n```python\n\"\"\"Component is the building block for desmod models.\n\nHierarchy\n---------\n\nA desmod model consists of a directed acyclical graph (DAG) of\n:class:`Component` subclasses. Each Component is composed of zero or more child\nComponents. A single top-le... | [
{
"content": "Reconstruct the code exactly:\n<|memory_start|>```python\n\"\"\"Component is the building block for desmod models.\n\nHierarchy\n---------\n\nA desmod model consists of a directed acyclical graph (DAG) of\n:class:`Component` subclasses. Each Component is composed of zero or more child\nComponents.... | ```python
"""Component is the building block for desmod models.
Hierarchy
---------
A desmod model consists of a directed acyclical graph (DAG) of
:class:`Component` subclasses. Each Component is composed of zero or more child
Components. A single top-level Component class is passed to the
:func:`~desmod.simulation.s... |
[
{
"content": "```python\ndef bivariate_normal(X, Y, sigmax=1.0, sigmay=1.0, mux=0.0, muy=0.0, sigmaxy=0.0):\n Xmu = X-mux\n Ymu = Y-muy\n rho = sigmaxy/(sigmax*sigmay)\n z = Xmu**2/sigmax**2 + Ymu**2/sigmay**2 - 2*rho*Xmu*Ymu/(sigmax*sigmay)\n denom = 2*np.pi*sigmax*sigmay*np.sqrt(1-rho**2)\n ... | [
{
"content": "<|memory_start|>```python\ndef bivariate_normal(X, Y, sigmax=1.0, sigmay=1.0, mux=0.0, muy=0.0, sigmaxy=0.0):\n Xmu = X-mux\n Ymu = Y-muy\n rho = sigmaxy/(sigmax*sigmay)\n z = Xmu**2/sigmax**2 + Ymu**2/sigmay**2 - 2*rho*Xmu*Ymu/(sigmax*sigmay)\n denom = 2*np.pi*sigmax*sigmay*np.sqrt... | ```python
def bivariate_normal(X, Y, sigmax=1.0, sigmay=1.0, mux=0.0, muy=0.0, sigmaxy=0.0):
Xmu = X-mux
Ymu = Y-muy
rho = sigmaxy/(sigmax*sigmay)
z = Xmu**2/sigmax**2 + Ymu**2/sigmay**2 - 2*rho*Xmu*Ymu/(sigmax*sigmay)
denom = 2*np.pi*sigmax*sigmay*np.sqrt(1-rho**2)
return np.exp(-z/(2*(1-rho**2... |
[
{
"content": "Here is a code file:\n```python\nimport shelve\n\n\nclass InvalidationError(Exception):\n pass\n\nclass ShelfProxy(Proxy):\n __slots__ = [\"_key\", \"_shelf\", \"_invalidated\"]\n \n def __init__(self, obj, shelf, key):\n Proxy.__init__(self, obj)\n object.__setattr__(sel... | [
{
"content": "Here is a code file:\n<|memory_start|>```python\nimport shelve\n\n\nclass InvalidationError(Exception):\n pass\n\nclass ShelfProxy(Proxy):\n __slots__ = [\"_key\", \"_shelf\", \"_invalidated\"]\n \n def __init__(self, obj, shelf, key):\n Proxy.__init__(self, obj)\n object... | ```python
import shelve
class InvalidationError(Exception):
pass
class ShelfProxy(Proxy):
__slots__ = ["_key", "_shelf", "_invalidated"]
def __init__(self, obj, shelf, key):
Proxy.__init__(self, obj)
object.__setattr__(self, "_shelf", shelf)
object.__setattr__(self, "_key", k... |
[
{
"content": "Return the code exactly, with no changes:\n```python\n# -----------------\n# normal decorators\n# -----------------\n\ndef decorator(func):\n def wrapper(*args):\n return func(1, *args)\n return wrapper\n\n@decorator\ndef decorated(a,b):\n return a,b\n\nexe = decorated(set, '')\n\n... | [
{
"content": "Return the code exactly, with no changes:\n<|memory_start|>```python\n# -----------------\n# normal decorators\n# -----------------\n\ndef decorator(func):\n def wrapper(*args):\n return func(1, *args)\n return wrapper\n\n@decorator\ndef decorated(a,b):\n return a,b\n\nexe = decora... | ```python
# -----------------
# normal decorators
# -----------------
def decorator(func):
def wrapper(*args):
return func(1, *args)
return wrapper
@decorator
def decorated(a,b):
return a,b
exe = decorated(set, '')
#? set
exe[1]
#? int()
exe[0]
# more complicated with args/kwargs
def dec(func)... |
[
{
"content": "```python\n# coding: utf-8\nfrom __future__ import unicode_literals\n\nimport functools\nimport itertools\nimport operator\nimport re\n\nfrom .common import InfoExtractor\nfrom ..compat import (\n compat_HTTPError,\n compat_str,\n compat_urllib_request,\n)\nfrom .openload import PhantomJS... | [
{
"content": "<|memory_start|>```python\n# coding: utf-8\nfrom __future__ import unicode_literals\n\nimport functools\nimport itertools\nimport operator\nimport re\n\nfrom .common import InfoExtractor\nfrom ..compat import (\n compat_HTTPError,\n compat_str,\n compat_urllib_request,\n)\nfrom .openload ... | ```python
# coding: utf-8
from __future__ import unicode_literals
import functools
import itertools
import operator
import re
from .common import InfoExtractor
from ..compat import (
compat_HTTPError,
compat_str,
compat_urllib_request,
)
from .openload import PhantomJSwrapper
from ..utils import (
det... |
[
{
"content": "```python\n#! /usr/bin/python3\n\n## Hackish example script to compare some results output by process-discogs-chunks.py\n##\n## Licensed under the terms of the General Public License version 3\n##\n## SPDX-License-Identifier: GPL-3.0\n##\n## Copyright 2017-2019 - Armijn Hemel\n\nimport os\nimport ... | [
{
"content": "<|memory_start|>```python\n#! /usr/bin/python3\n\n## Hackish example script to compare some results output by process-discogs-chunks.py\n##\n## Licensed under the terms of the General Public License version 3\n##\n## SPDX-License-Identifier: GPL-3.0\n##\n## Copyright 2017-2019 - Armijn Hemel\n\nim... | ```python
#! /usr/bin/python3
## Hackish example script to compare some results output by process-discogs-chunks.py
##
## Licensed under the terms of the General Public License version 3
##
## SPDX-License-Identifier: GPL-3.0
##
## Copyright 2017-2019 - Armijn Hemel
import os
import sys
import argparse
def main():
... |
[
{
"content": "Here is the code content:\n```python\n###\n### this script assigns most voted class to corems\n###\n\nimport sys\n\n# 0. user defined variables\ngene2ClassFile='/Volumes/omics4tb/alomana/projects/TLR/data/annotation/si.table.1.si.ribosomal.protein.index.information.csv'\ngeneDictionaryFile='/Volum... | [
{
"content": "Here is the code content:\n<|memory_start|>```python\n###\n### this script assigns most voted class to corems\n###\n\nimport sys\n\n# 0. user defined variables\ngene2ClassFile='/Volumes/omics4tb/alomana/projects/TLR/data/annotation/si.table.1.si.ribosomal.protein.index.information.csv'\ngeneDictio... | ```python
###
### this script assigns most voted class to corems
###
import sys
# 0. user defined variables
gene2ClassFile='/Volumes/omics4tb/alomana/projects/TLR/data/annotation/si.table.1.si.ribosomal.protein.index.information.csv'
geneDictionaryFile='/Volumes/omics4tb/alomana/projects/TLR/data/annotation/si.table.... |
[
{
"content": "Reconstruct the code file line-for-line, unmodified:\n```python\n#!/usr/bin/env python\n\nfrom settings import *\nimport os.path, Tkinter, tkFont, tkFileDialog\nimport taxonutils\n\n\nclass TaxonLinker():\n\n def __init__(self,root):\n \n self.taxondict = DICTIONARY_FILE\n self.nameslist =... | [
{
"content": "Reconstruct the code file line-for-line, unmodified:\n<|memory_start|>```python\n#!/usr/bin/env python\n\nfrom settings import *\nimport os.path, Tkinter, tkFont, tkFileDialog\nimport taxonutils\n\n\nclass TaxonLinker():\n\n def __init__(self,root):\n \n self.taxondict = DICTIONARY_FILE\n ... | ```python
#!/usr/bin/env python
from settings import *
import os.path, Tkinter, tkFont, tkFileDialog
import taxonutils
class TaxonLinker():
def __init__(self,root):
self.taxondict = DICTIONARY_FILE
self.nameslist = []
self.results = []
self.dictload = False
self.nmload = False
# op... |
[
{
"content": "Reconstruct the code file line-for-line, unmodified:\n```python\nimport logging\nfrom pyvisdk.exceptions import InvalidArgumentError\n\n########################################\n# Automatically generated, do not edit.\n########################################\n\nlog = logging.getLogger(__name__)\n... | [
{
"content": "Reconstruct the code file line-for-line, unmodified:\n<|memory_start|>```python\nimport logging\nfrom pyvisdk.exceptions import InvalidArgumentError\n\n########################################\n# Automatically generated, do not edit.\n########################################\n\nlog = logging.getLo... | ```python
import logging
from pyvisdk.exceptions import InvalidArgumentError
########################################
# Automatically generated, do not edit.
########################################
log = logging.getLogger(__name__)
def GuestWindowsFileAttributes(vim, *args, **kwargs):
'''Different attributes fo... |
[
{
"content": "Here is a code file:\n```python\n# Copyright (c) 2008-2009 Junior (Frederic) FLEURIAL MONFILS\r\n# \r\n# This file is part of PyAnalyzer.\r\n#\r\n# PyAnalyzer is free software: you can redistribute it and/or modify\r\n# it under the terms of the GNU General Public License as published by\r\n# the ... | [
{
"content": "Here is a code file:\n<|memory_start|>```python\n# Copyright (c) 2008-2009 Junior (Frederic) FLEURIAL MONFILS\r\n# \r\n# This file is part of PyAnalyzer.\r\n#\r\n# PyAnalyzer is free software: you can redistribute it and/or modify\r\n# it under the terms of the GNU General Public License as publis... | ```python
# Copyright (c) 2008-2009 Junior (Frederic) FLEURIAL MONFILS
#
# This file is part of PyAnalyzer.
#
# PyAnalyzer is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License... |
[
{
"content": "Repeat the code exactly:\n```python\n# -*- coding: utf-8 -*-\n\nfrom __future__ import print_function, division, absolute_import\n\n#\n# Copyright (c) 2011 Red Hat, Inc.\n#\n# This software is licensed to you under the GNU General Public\n# License as published by the Free Software Foundation; eit... | [
{
"content": "Repeat the code exactly:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\n\nfrom __future__ import print_function, division, absolute_import\n\n#\n# Copyright (c) 2011 Red Hat, Inc.\n#\n# This software is licensed to you under the GNU General Public\n# License as published by the Free Software... | ```python
# -*- coding: utf-8 -*-
from __future__ import print_function, division, absolute_import
#
# Copyright (c) 2011 Red Hat, Inc.
#
# This software is licensed to you under the GNU General Public
# License as published by the Free Software Foundation; either version
# 2 of the License (GPLv2) or (at your option... |
[
{
"content": "Here is the source code:\n```python\n# -*- coding: UTF-8 -*-\n\n# © Copyright 2009 Wolodja Wentland. All Rights Reserved.\n\n# This file is part of wp-import.\n#\n# wp-import is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as publishe... | [
{
"content": "Here is the source code:\n<|memory_start|>```python\n# -*- coding: UTF-8 -*-\n\n# © Copyright 2009 Wolodja Wentland. All Rights Reserved.\n\n# This file is part of wp-import.\n#\n# wp-import is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public Lic... | ```python
# -*- coding: UTF-8 -*-
# © Copyright 2009 Wolodja Wentland. All Rights Reserved.
# This file is part of wp-import.
#
# wp-import is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of... |
[
{
"content": "Here is the code block:\n```python\nfrom __future__ import print_function\n\nimport os\nimport sys\nimport traceback\n\nimport lxml.etree\n\nfrom django.core.management.base import BaseCommand\nfrom fs.osfs import OSFS\nfrom path import Path as path\nfrom xmodule.modulestore.xml import XMLModuleSt... | [
{
"content": "Here is the code block:\n<|memory_start|>```python\nfrom __future__ import print_function\n\nimport os\nimport sys\nimport traceback\n\nimport lxml.etree\n\nfrom django.core.management.base import BaseCommand\nfrom fs.osfs import OSFS\nfrom path import Path as path\nfrom xmodule.modulestore.xml im... | ```python
from __future__ import print_function
import os
import sys
import traceback
import lxml.etree
from django.core.management.base import BaseCommand
from fs.osfs import OSFS
from path import Path as path
from xmodule.modulestore.xml import XMLModuleStore
def traverse_tree(course):
"""
Load every des... |
[
{
"content": "```python\n#\n# Copyright (c) 2020 SUNET\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or\n# without modification, are permitted provided that the following\n# conditions are met:\n#\n# 1. Redistributions of source code must retain the above copyri... | [
{
"content": "<|memory_start|>```python\n#\n# Copyright (c) 2020 SUNET\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or\n# without modification, are permitted provided that the following\n# conditions are met:\n#\n# 1. Redistributions of source code must retain ... | ```python
#
# Copyright (c) 2020 SUNET
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or
# without modification, are permitted provided that the following
# conditions are met:
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list ... |
[
{
"content": "Repeat the code exactly as the original, including blank lines:\n```python\n\"\"\"\nUtil functions\n\"\"\"\nimport os\nimport shlex\nfrom subprocess import Popen, PIPE\n\nfrom six import string_types\n\nfrom .exceptions import ShellError\nfrom . import report\n\n\nclass ShellOutput(str):\n def ... | [
{
"content": "Repeat the code exactly as the original, including blank lines:\n<|memory_start|>```python\n\"\"\"\nUtil functions\n\"\"\"\nimport os\nimport shlex\nfrom subprocess import Popen, PIPE\n\nfrom six import string_types\n\nfrom .exceptions import ShellError\nfrom . import report\n\n\nclass ShellOutput... | ```python
"""
Util functions
"""
import os
import shlex
from subprocess import Popen, PIPE
from six import string_types
from .exceptions import ShellError
from . import report
class ShellOutput(str):
def __new__(cls, stdout, stderr):
# Store raw
stdout = stdout.strip() if stdout else ''
... |
[
{
"content": "Provide a verbatim copy of the code:\n```python\nfrom django.utils.translation import ugettext as _, ugettext_lazy \nfrom django.db.models.signals import post_syncdb\n\nimport permissions\nfrom permissions.utils import register_role, register_permission\n\n## role-related constants\nNOBODY = 'NOBO... | [
{
"content": "Provide a verbatim copy of the code:\n<|memory_start|>```python\nfrom django.utils.translation import ugettext as _, ugettext_lazy \nfrom django.db.models.signals import post_syncdb\n\nimport permissions\nfrom permissions.utils import register_role, register_permission\n\n## role-related constants... | ```python
from django.utils.translation import ugettext as _, ugettext_lazy
from django.db.models.signals import post_syncdb
import permissions
from permissions.utils import register_role, register_permission
## role-related constants
NOBODY = 'NOBODY'
GAS_MEMBER = 'GAS_MEMBER'
GAS_REFERRER_SUPPLIER = 'GAS_REFERRER_... |
[
{
"content": "Write out the code verbatim, preserving indentation and whitespace:\n```python\nimport simplejson\nimport psycopg2\nfrom types import DictType\n\n\nclass DBMSPostgreSQL:\n\n # User's parameters\n db_name = None\n username = None\n password = None\n host = None\n port = None\n ... | [
{
"content": "Write out the code verbatim, preserving indentation and whitespace:\n<|memory_start|>```python\nimport simplejson\nimport psycopg2\nfrom types import DictType\n\n\nclass DBMSPostgreSQL:\n\n # User's parameters\n db_name = None\n username = None\n password = None\n host = None\n p... | ```python
import simplejson
import psycopg2
from types import DictType
class DBMSPostgreSQL:
# User's parameters
db_name = None
username = None
password = None
host = None
port = None
schema = None
# Computed variables.
connection = None
def __init__(self, db_name, username,... |
[
{
"content": "```python\n# python\n# Steady hands game\n# run with - sudo python SteadyRa.py\n# updated to be Revision Aware, to cope with board revisions 1 & 2 \n\nimport RPi.GPIO as GPIO\nimport time\n\ndef findRevision():\n global boardRevision\n fin = open('/proc/cpuinfo')\n boardRevision = -1\n ... | [
{
"content": "<|memory_start|>```python\n# python\n# Steady hands game\n# run with - sudo python SteadyRa.py\n# updated to be Revision Aware, to cope with board revisions 1 & 2 \n\nimport RPi.GPIO as GPIO\nimport time\n\ndef findRevision():\n global boardRevision\n fin = open('/proc/cpuinfo')\n boardRe... | ```python
# python
# Steady hands game
# run with - sudo python SteadyRa.py
# updated to be Revision Aware, to cope with board revisions 1 & 2
import RPi.GPIO as GPIO
import time
def findRevision():
global boardRevision
fin = open('/proc/cpuinfo')
boardRevision = -1
while True: # go through the file ... |
[
{
"content": "Repeat the code precisely as written (spacing intact):\n```python\nimport sublime\n\nimport os.path\nimport shutil\nimport textwrap\nimport time\nimport uuid\n\nfrom YetAnotherCodeSearch.tests import CommandTestCase\n\n\n_NEEDLE_IN_HAYSTACK = 'cc5b252b-e7fb-5145-bf8a-ed272e3aa7bf'\n\n\nclass Csear... | [
{
"content": "Repeat the code precisely as written (spacing intact):\n<|memory_start|>```python\nimport sublime\n\nimport os.path\nimport shutil\nimport textwrap\nimport time\nimport uuid\n\nfrom YetAnotherCodeSearch.tests import CommandTestCase\n\n\n_NEEDLE_IN_HAYSTACK = 'cc5b252b-e7fb-5145-bf8a-ed272e3aa7bf'\... | ```python
import sublime
import os.path
import shutil
import textwrap
import time
import uuid
from YetAnotherCodeSearch.tests import CommandTestCase
_NEEDLE_IN_HAYSTACK = 'cc5b252b-e7fb-5145-bf8a-ed272e3aa7bf'
class CsearchCommandTest(CommandTestCase):
def setUp(self):
super(CsearchCommandTest, self)... |
[
{
"content": "Here is some code:\n```python\n# /usr/bin/env python\n'''\nWritten by Kong Xiaolu and CBIG under MIT license:\nhttps://github.com/ThomasYeoLab/CBIG/blob/master/LICENSE.md\n'''\n\nimport os\nimport numpy as np\nimport torch\nimport CBIG_pMFM_basic_functions_main as fc\nimport warnings\n\n\ndef CBIG... | [
{
"content": "Here is some code:\n<|memory_start|>```python\n# /usr/bin/env python\n'''\nWritten by Kong Xiaolu and CBIG under MIT license:\nhttps://github.com/ThomasYeoLab/CBIG/blob/master/LICENSE.md\n'''\n\nimport os\nimport numpy as np\nimport torch\nimport CBIG_pMFM_basic_functions_main as fc\nimport warnin... | ```python
# /usr/bin/env python
'''
Written by Kong Xiaolu and CBIG under MIT license:
https://github.com/ThomasYeoLab/CBIG/blob/master/LICENSE.md
'''
import os
import numpy as np
import torch
import CBIG_pMFM_basic_functions_main as fc
import warnings
def CBIG_mfm_test_desikan_main(gpu_index=0):
'''
This fu... |
[
{
"content": "Return the code unaltered:\n```python\n#\n# Copy right YMSys, 2015,2016 Zhaoming Yin\n#\n# @brief This script performs data analytics\n# 1) it can list:\n# name, numV, numE, numCC, avgDiam, varDiam, avgCluCoeff, varCluCoeff\n# 2) it can draw distribution of \n# ... | [
{
"content": "Return the code unaltered:\n<|memory_start|>```python\n#\n# Copy right YMSys, 2015,2016 Zhaoming Yin\n#\n# @brief This script performs data analytics\n# 1) it can list:\n# name, numV, numE, numCC, avgDiam, varDiam, avgCluCoeff, varCluCoeff\n# 2) it can draw dist... | ```python
#
# Copy right YMSys, 2015,2016 Zhaoming Yin
#
# @brief This script performs data analytics
# 1) it can list:
# name, numV, numE, numCC, avgDiam, varDiam, avgCluCoeff, varCluCoeff
# 2) it can draw distribution of
# clique, truss
#
#
# MODIFIED (... |
[
{
"content": "Here is the code content:\n```python\nimport base64\nimport importlib\nimport sys\n\nfrom metamagic.json import dumps, dumpb, loadb\n\nfrom django.core.management.base import BaseCommand\n\n\nclass Command(BaseCommand):\n help = 'Import a model'\n\n def add_arguments(self, parser):\n ... | [
{
"content": "Here is the code content:\n<|memory_start|>```python\nimport base64\nimport importlib\nimport sys\n\nfrom metamagic.json import dumps, dumpb, loadb\n\nfrom django.core.management.base import BaseCommand\n\n\nclass Command(BaseCommand):\n help = 'Import a model'\n\n def add_arguments(self, pa... | ```python
import base64
import importlib
import sys
from metamagic.json import dumps, dumpb, loadb
from django.core.management.base import BaseCommand
class Command(BaseCommand):
help = 'Import a model'
def add_arguments(self, parser):
parser.add_argument('-i,--import', dest='import', help='File to... |
[
{
"content": "Here is the source code:\n```python\n# Protocol Buffers - Google's data interchange format\n# Copyright 2008 Google Inc. All rights reserved.\n# http://code.google.com/p/protobuf/\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that... | [
{
"content": "Here is the source code:\n<|memory_start|>```python\n# Protocol Buffers - Google's data interchange format\n# Copyright 2008 Google Inc. All rights reserved.\n# http://code.google.com/p/protobuf/\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitt... | ```python
# Protocol Buffers - Google's data interchange format
# Copyright 2008 Google Inc. All rights reserved.
# http://code.google.com/p/protobuf/
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistr... |
[
{
"content": "Recreate the original code text:\n```python\n#!/usr/bin/env python\n# Test finding storage pool source of 'netfs' type\n\nfrom xml.dom import minidom\n\nimport libvirt\nfrom libvirt import libvirtError\n\nfrom src import sharedmod\nfrom utils import utils\n\nrequired_params = ('sourcehost',)\nopti... | [
{
"content": "Recreate the original code text:\n<|memory_start|>```python\n#!/usr/bin/env python\n# Test finding storage pool source of 'netfs' type\n\nfrom xml.dom import minidom\n\nimport libvirt\nfrom libvirt import libvirtError\n\nfrom src import sharedmod\nfrom utils import utils\n\nrequired_params = ('sou... | ```python
#!/usr/bin/env python
# Test finding storage pool source of 'netfs' type
from xml.dom import minidom
import libvirt
from libvirt import libvirtError
from src import sharedmod
from utils import utils
required_params = ('sourcehost',)
optional_params = {'xml' : 'xmls/netfs_pool_source.xml',
... |
[
{
"content": "Repeat the full code snippet:\n```python\n# Copyright 2021 The Cirq Developers\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# https://www.apache.org/lic... | [
{
"content": "Repeat the full code snippet:\n<|memory_start|>```python\n# Copyright 2021 The Cirq Developers\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# https://ww... | ```python
# Copyright 2021 The Cirq Developers
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agr... |
[
{
"content": "```python\n#!/usr/bin/env python\nimport messagebird\nimport argparse\n\nparser = argparse.ArgumentParser()\nparser.add_argument('--accessKey', help='access key for MessageBird API', type=str, required=True)\nparser.add_argument('--callID', help='identifier for the call', type=str, required=True)\... | [
{
"content": "<|memory_start|>```python\n#!/usr/bin/env python\nimport messagebird\nimport argparse\n\nparser = argparse.ArgumentParser()\nparser.add_argument('--accessKey', help='access key for MessageBird API', type=str, required=True)\nparser.add_argument('--callID', help='identifier for the call', type=str,... | ```python
#!/usr/bin/env python
import messagebird
import argparse
parser = argparse.ArgumentParser()
parser.add_argument('--accessKey', help='access key for MessageBird API', type=str, required=True)
parser.add_argument('--callID', help='identifier for the call', type=str, required=True)
parser.add_argument('--legID'... |
[
{
"content": "Repeat the code precisely as written (spacing intact):\n```python\nimport logging, os, re\nfrom autotest_lib.client.common_lib import error\nfrom autotest_lib.client.bin import utils, os_dep\nfrom autotest_lib.client.virt import virt_utils\nfrom autotest_lib.client.virt import virt_env_process\n\n... | [
{
"content": "Repeat the code precisely as written (spacing intact):\n<|memory_start|>```python\nimport logging, os, re\nfrom autotest_lib.client.common_lib import error\nfrom autotest_lib.client.bin import utils, os_dep\nfrom autotest_lib.client.virt import virt_utils\nfrom autotest_lib.client.virt import virt... | ```python
import logging, os, re
from autotest_lib.client.common_lib import error
from autotest_lib.client.bin import utils, os_dep
from autotest_lib.client.virt import virt_utils
from autotest_lib.client.virt import virt_env_process
class NFSCorruptConfig(object):
"""
This class sets up nfs_corrupt test envi... |
[
{
"content": "Here is the code content:\n```python\n#!/usr/bin/env python\n\n\"\"\"\nCopyright (c) 2006-2017 sqlmap developers (http://sqlmap.org/)\nSee the file 'doc/COPYING' for copying permission\n\"\"\"\n\nimport time\n\nfrom lib.core.common import clearConsoleLine\nfrom lib.core.common import dataToStdout\... | [
{
"content": "Here is the code content:\n<|memory_start|>```python\n#!/usr/bin/env python\n\n\"\"\"\nCopyright (c) 2006-2017 sqlmap developers (http://sqlmap.org/)\nSee the file 'doc/COPYING' for copying permission\n\"\"\"\n\nimport time\n\nfrom lib.core.common import clearConsoleLine\nfrom lib.core.common impo... | ```python
#!/usr/bin/env python
"""
Copyright (c) 2006-2017 sqlmap developers (http://sqlmap.org/)
See the file 'doc/COPYING' for copying permission
"""
import time
from lib.core.common import clearConsoleLine
from lib.core.common import dataToStdout
from lib.core.common import filterListValue
from lib.core.common i... |
[
{
"content": "```python\n# -*- coding: utf-8 -*-\n\n# Copyright(C) 2012 Romain Bignon\n#\n# This file is part of weboob.\n#\n# weboob is free software: you can redistribute it and/or modify\n# it under the terms of the GNU Affero General Public License as published by\n# the Free Software Foundation, either ver... | [
{
"content": "<|memory_start|>```python\n# -*- coding: utf-8 -*-\n\n# Copyright(C) 2012 Romain Bignon\n#\n# This file is part of weboob.\n#\n# weboob is free software: you can redistribute it and/or modify\n# it under the terms of the GNU Affero General Public License as published by\n# the Free Software Founda... | ```python
# -*- coding: utf-8 -*-
# Copyright(C) 2012 Romain Bignon
#
# This file is part of weboob.
#
# weboob is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at... |
[
{
"content": "Repeat the code precisely as written (spacing intact):\n```python\n# coding=utf-8\n# --------------------------------------------------------------------------\n# Copyright (c) Microsoft Corporation. All rights reserved.\n# Licensed under the MIT License. See License.txt in the project root for li... | [
{
"content": "Repeat the code precisely as written (spacing intact):\n<|memory_start|>```python\n# coding=utf-8\n# --------------------------------------------------------------------------\n# Copyright (c) Microsoft Corporation. All rights reserved.\n# Licensed under the MIT License. See License.txt in the pro... | ```python
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# Code generated by Microsoft (R) AutoRest Code Generator.
# Ch... |
[
{
"content": "Provide a verbatim copy of the code:\n```python\n# -*- coding: utf-8 -*-\n\n\"\"\"\nCommon type definitions and constants for edx-dl\n\nThe classes in this module represent the structure of courses in edX. The\nstructure is:\n\n* A Course contains Sections\n* Each Section contains Subsections\n* ... | [
{
"content": "Provide a verbatim copy of the code:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\n\n\"\"\"\nCommon type definitions and constants for edx-dl\n\nThe classes in this module represent the structure of courses in edX. The\nstructure is:\n\n* A Course contains Sections\n* Each Section contains... | ```python
# -*- coding: utf-8 -*-
"""
Common type definitions and constants for edx-dl
The classes in this module represent the structure of courses in edX. The
structure is:
* A Course contains Sections
* Each Section contains Subsections
* Each Subsection contains Units
Notice that we don't represent the full tr... |
[
{
"content": "Recreate the entire code block with identical formatting:\n```python\n\"\"\"\nHelper functions, OS agnostic\n\n@author: Roy Nielsen\n\"\"\"\n\n#--- Native python libraries\nimport re\nimport os\nimport sys\nimport time\nimport ctypes\nimport traceback\nfrom subprocess import Popen, STDOUT, PIPE\nt... | [
{
"content": "Recreate the entire code block with identical formatting:\n<|memory_start|>```python\n\"\"\"\nHelper functions, OS agnostic\n\n@author: Roy Nielsen\n\"\"\"\n\n#--- Native python libraries\nimport re\nimport os\nimport sys\nimport time\nimport ctypes\nimport traceback\nfrom subprocess import Popen,... | ```python
"""
Helper functions, OS agnostic
@author: Roy Nielsen
"""
#--- Native python libraries
import re
import os
import sys
import time
import ctypes
import traceback
from subprocess import Popen, STDOUT, PIPE
try:
import termios
except:
pass
#--- non-native python libraries in this source tree
from . l... |
[
{
"content": "Write out the code verbatim, preserving indentation and whitespace:\n```python\n# -*- coding: utf-8 -*-\nfrom __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\nfrom __future__ import unicode_literals\n\n\nfrom mock import Mock\nfrom mock imp... | [
{
"content": "Write out the code verbatim, preserving indentation and whitespace:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\nfrom __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\nfrom __future__ import unicode_literals\n\n\nfrom mock import Moc... | ```python
# -*- coding: utf-8 -*-
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
from mock import Mock
from mock import patch
from squirrel.common.unittest import TestCase
from squirrel.launcher.squirrel_dev import ... |
[
{
"content": "Recreate the entire code block with identical formatting:\n```python\n# vim: tabstop=4 shiftwidth=4 softtabstop=4\n\n# Copyright 2011 OpenStack Foundation.\n# All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this file except in c... | [
{
"content": "Recreate the entire code block with identical formatting:\n<|memory_start|>```python\n# vim: tabstop=4 shiftwidth=4 softtabstop=4\n\n# Copyright 2011 OpenStack Foundation.\n# All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this ... | ```python
# vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2011 OpenStack Foundation.
# 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:... |
[
{
"content": "```python\n# -*- coding: utf-8 -*-\n'''\t\nforgetting_curve.py\nThis program aims at generating a plan for memorizing\nvocabularies according to the Forgetting Curve.\n\nCopyright (c) 2015 Libao Jin\nLicence: unknown\n'''\n\nimport math\nimport itertools\n\n__author__ = 'Libao Jin'\n__date__ = 'Ju... | [
{
"content": "<|memory_start|>```python\n# -*- coding: utf-8 -*-\n'''\t\nforgetting_curve.py\nThis program aims at generating a plan for memorizing\nvocabularies according to the Forgetting Curve.\n\nCopyright (c) 2015 Libao Jin\nLicence: unknown\n'''\n\nimport math\nimport itertools\n\n__author__ = 'Libao Jin'... | ```python
# -*- coding: utf-8 -*-
'''
forgetting_curve.py
This program aims at generating a plan for memorizing
vocabularies according to the Forgetting Curve.
Copyright (c) 2015 Libao Jin
Licence: unknown
'''
import math
import itertools
__author__ = 'Libao Jin'
__date__ = 'July 03, 2015'
def listGroup(lists, num... |
[
{
"content": "Repeat the code exactly:\n```python\n#!/usr/bin/env python3.2\n#\n# Copyright (c) Net24 Limited, Christchurch, New Zealand 2011-2012\n# and Voyager Internet Ltd, New Zealand, 2012-2013\n#\n# This file is part of py-magcode-core.\n#\n# Py-magcode-core is free software: you can redis... | [
{
"content": "Repeat the code exactly:\n<|memory_start|>```python\n#!/usr/bin/env python3.2\n#\n# Copyright (c) Net24 Limited, Christchurch, New Zealand 2011-2012\n# and Voyager Internet Ltd, New Zealand, 2012-2013\n#\n# This file is part of py-magcode-core.\n#\n# Py-magcode-core is free softwar... | ```python
#!/usr/bin/env python3.2
#
# Copyright (c) Net24 Limited, Christchurch, New Zealand 2011-2012
# and Voyager Internet Ltd, New Zealand, 2012-2013
#
# This file is part of py-magcode-core.
#
# Py-magcode-core is free software: you can redistribute it and/or modify
# it under the terms of the ... |
[
{
"content": "```python\nfrom collections import Counter\nfrom itertools import chain, combinations\n\nfrom django.conf import settings\nfrom django.core.urlresolvers import reverse\nfrom django.utils.http import urlquote\nfrom django.template.response import TemplateResponse\n\nfrom us_ignite.apps.models impor... | [
{
"content": "<|memory_start|>```python\nfrom collections import Counter\nfrom itertools import chain, combinations\n\nfrom django.conf import settings\nfrom django.core.urlresolvers import reverse\nfrom django.utils.http import urlquote\nfrom django.template.response import TemplateResponse\n\nfrom us_ignite.a... | ```python
from collections import Counter
from itertools import chain, combinations
from django.conf import settings
from django.core.urlresolvers import reverse
from django.utils.http import urlquote
from django.template.response import TemplateResponse
from us_ignite.apps.models import Application, Domain
from us_i... |
[
{
"content": "```python\n#!/usr/bin/env python\nfrom __future__ import division, print_function\nimport os\nfrom math import log\nfrom collections import namedtuple, OrderedDict, deque\nimport time\nimport threading\nimport json\nimport gc\ntry:\n from Queue import Queue\nexcept ImportError:\n from queue ... | [
{
"content": "<|memory_start|>```python\n#!/usr/bin/env python\nfrom __future__ import division, print_function\nimport os\nfrom math import log\nfrom collections import namedtuple, OrderedDict, deque\nimport time\nimport threading\nimport json\nimport gc\ntry:\n from Queue import Queue\nexcept ImportError:\... | ```python
#!/usr/bin/env python
from __future__ import division, print_function
import os
from math import log
from collections import namedtuple, OrderedDict, deque
import time
import threading
import json
import gc
try:
from Queue import Queue
except ImportError:
from queue import Queue
import io
import loggi... |
[
{
"content": "Reconstruct the code exactly:\n```python\n# -*- coding: utf-8 -*-\nfrom freezegun import freeze_time\n\nfrom odoo.addons.account.tests.common import AccountTestInvoicingCommon\nfrom odoo.tests.common import Form\nfrom odoo.tests import tagged\n\n\n@tagged('post_install', '-at_install')\nclass Test... | [
{
"content": "Reconstruct the code exactly:\n<|memory_start|>```python\n# -*- coding: utf-8 -*-\nfrom freezegun import freeze_time\n\nfrom odoo.addons.account.tests.common import AccountTestInvoicingCommon\nfrom odoo.tests.common import Form\nfrom odoo.tests import tagged\n\n\n@tagged('post_install', '-at_insta... | ```python
# -*- coding: utf-8 -*-
from freezegun import freeze_time
from odoo.addons.account.tests.common import AccountTestInvoicingCommon
from odoo.tests.common import Form
from odoo.tests import tagged
@tagged('post_install', '-at_install')
class TestReconciliationMatchingRules(AccountTestInvoicingCommon):
@... |
[
{
"content": "Return the code exactly, with no changes:\n```python\nfrom argparse import ArgumentParser\nimport os\nimport sys\n\nimport django\nfrom django.conf import settings\n\nfrom coverage import Coverage\nfrom termcolor import colored\n\nTESTS_ROOT = os.path.abspath(os.path.dirname(os.path.dirname(__file... | [
{
"content": "Return the code exactly, with no changes:\n<|memory_start|>```python\nfrom argparse import ArgumentParser\nimport os\nimport sys\n\nimport django\nfrom django.conf import settings\n\nfrom coverage import Coverage\nfrom termcolor import colored\n\nTESTS_ROOT = os.path.abspath(os.path.dirname(os.pat... | ```python
from argparse import ArgumentParser
import os
import sys
import django
from django.conf import settings
from coverage import Coverage
from termcolor import colored
TESTS_ROOT = os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
TESTS_THRESHOLD = 100
def main():
parser = ArgumentParser(descri... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.