conversation
listlengths
2
2
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom torch import nn\nfrom TestingCode.modules import Attention, FeedForward, PreNorm\n\n# Code from current file (TestingCode/transformer.py):\n\n\nclass Transformer(nn.Module):\n def __init__(\n self,\n ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport glob\nimport os\nimport random\nimport shutil\nimport time\nimport cv2\nimport math\nimport numpy as np\nimport torch\nfrom pathlib import Path\nfrom threading import Thread\nfrom PIL import Image, ExifTags\nfr...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport json\nimport argparse\nimport os\nimport os.path as osp\nimport time\nimport open3d as o3d\nimport numpy as np\nimport copy\nimport matplotlib.pyplot as plt\nfrom utils import o3dobj\nfrom utils import io\nfrom...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport math\nimport torch\nimport torch.nn.functional as F\n import fairscale.nn.model_parallel.initialize as fs_init\nfrom typing import Optional, Tuple\nfrom torch import nn\nfrom .utils import ModelArgs, rep...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport logging\nfrom homeassistant.const import CONF_LATITUDE, CONF_LONGITUDE, CONF_RADIUS, CONF_NAME\nfrom homeassistant.components.device_tracker.config_entry import (\n BaseTrackerEntity,\n SourceType,\n A...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nimport json\nimport sys\nimport math\nimport torch\nimport argparse\nimport transformers\nfrom peft import PeftModel\nfrom transformers import GenerationConfig\nfrom llama_attn_replace import replace_llama_...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom homeassistant.components.sensor import (\n SensorStateClass,\n SensorDeviceClass,\n)\nfrom homeassistant.const import UnitOfPower, UnitOfEnergy, UnitOfTemperature, PERCENTAGE, CONF_NAME\nfrom custom_compone...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport numpy as np\nimport scipy.linalg as la\nfrom polar.utils.misc import (mdot, kdot, get_spin_dim, add_spin_dim)\n\n# Code from current file (polar/basis/trans_1e.py):\n#!/usr/bin/env python\n\n\"\"\"\nTransform 1...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport json\nimport os\nimport time\nfrom stravalib.util.limiter import RateLimiter, XRateLimitRule\nfrom stravalib.client import Client, exc\nfrom utils.exceptions import RateLimitException, NoInternetException\n\n# ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport yaml\nimport os\nimport sys\nimport subprocess\nimport signal\nfrom pprint import pprint\nfrom multiprocessing import Process\nfrom gpt_server.utils import get_free_tcp_port, start_server, run_cmd, stop_server,...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport logging\nfrom typing import List\nfrom tonic_validate.classes.llm_response import LLMResponse\nfrom tonic_validate.metrics.augmentation_accuracy_metric import (\n AugmentationAccuracyMetric\n)\nfrom tonic_va...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom collections.abc import Mapping\nfrom typing import Any\nfrom h3ronpy.arrow.vector import cells_to_coordinates, coordinates_to_cells\nfrom xarray.indexes import PandasIndex\nfrom xdggs.index import DGGSIndex\nfrom...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport numpy as np\nfrom civrealm.envs import FreecivBaseEnv\nfrom civrealm.envs.freeciv_wrapper.config import default_tensor_config\nfrom .core import Wrapper\nfrom .utils import onehotifier_maker\n\n# Code from curr...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nfrom functools import partial, wraps\nfrom typing import Any, Generic, Hashable\nfrom pecapiku.base_cache import BaseCache, DecoratedCallable, Decorator, omnimethod\nfrom pecapiku.cache_access import CacheA...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom threading import Thread\nfrom queue import Queue\nfrom openai import OpenAI\nfrom .parsers import extract_json, extract_list, rectangle_corners\nfrom .wrappers import (\n job_easy_ocr,\n job_easy_ocr_boxes,...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport datetime\nimport pytest\nfrom typing import Any\nfrom freezegun.api import FrozenDateTimeFactory\nfrom homeassistant.const import CONF_NAME, Platform, STATE_OFF, STATE_ON\nfrom homeassistant.core import HomeAss...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport concurrent.futures\nimport json\nfrom pathlib import Path\nfrom time import sleep\nfrom urllib.parse import urlparse\nfrom loguru import logger\nfrom rich.prompt import Confirm\nfrom selenium.webdriver.chrome.w...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport torch\nfrom com_hom_emg.data import get_datasets, get_per_subj_data\n\n# Code from current file (tests/test_data.py):\n\n\n\ndef test_get_datasets_disjoint_val_test():\n # The subject used for val should be ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport torch\nimport torch.nn.functional as F\nimport torchao.quantization.quant_api as quant_api\nfrom .quant_primitives import (\n dynamically_quantize_per_channel,\n quant_int8_dynamic_per_token_linear,\n)\n\...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport numpy as np\nimport torch\nimport torch.nn.functional as F\nfrom torch import nn\nfrom .torch_nn import BasicConv, batched_index_select, act_layer\nfrom .torch_edge import DenseDilatedKnnGraph\nfrom .pos_embed ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport pytest\nfrom requests_mock import Mocker\nfrom ..utils import group_by_url, MockSet\n\n# Code from current file (multi_api_mocker/contrib/pytest_plugin.py):\n\n\n\n@pytest.fixture(scope=\"function\")\ndef setup...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom continuous_eval.llm_factory import DefaultLLM, LLMInterface\nfrom continuous_eval.metrics.base import LLMBasedMetric\nfrom continuous_eval.metrics.retrieval_LLM_based_metrics import LLMBasedContextCoverage\n\n# C...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport pandas as pd\nimport torch\nimport numpy as np\nimport json\nfrom objaverse_utils.utils import text_to_uid_dict\nfrom gpt_4.verification import check_text_similarity\nfrom gpt_4.bard_verify import verify_objave...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom collections import OrderedDict\nfrom icecream import ic # pylint: disable=E0401\nfrom .elem import Edge, Node, NodeEnum, RelEnum\nimport json\nimport typing\nimport networkx as nx # pylint: disable=E0401\nimpor...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom jinja2 import Environment, FileSystemLoader\nfrom epg import utils\nfrom epg.generator import xmltv\nfrom epg.generator import diyp\nfrom epg.scraper import __xmltv\nfrom lxml import etree\nfrom datetime import d...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nimport urllib\nimport chess\nfrom typing import Iterator\nfrom fastapi import WebSocket, WebSocketDisconnect\nfrom langserve import RemoteRunnable\nfrom chesster.app.utils import (\n display_board,\n ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport base64\nimport os\nimport shutil\nimport logging\nfrom pathlib import Path\nfrom typing import Any, Dict, List\nfrom fastapi import FastAPI, File, UploadFile\nfrom fastapi.responses import JSONResponse, Streami...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport argparse\nimport datetime\nimport json\nimport os\nimport time\nfrom pytz import timezone\nfrom tqdm import tqdm\nfrom chat.server.monitor.basic_stats import NUM_SERVERS\nfrom chat.server.monitor.clean_battle_d...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport requests\nimport re\nimport json\nimport time\nimport os\nimport logging\nfrom pathlib import Path\nfrom datetime import datetime, timedelta\nfrom json.decoder import JSONDecodeError\nfrom finary_uapi.user_real...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport paho.mqtt.client as mqtt\nimport json\nimport logging\nfrom datetime import datetime\nfrom rtl_433_discoverandsubmit import config\nfrom rtl_433_discoverandsubmit.modules.device_manager import save_devices_to_f...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom re import T\nfrom sys import implementation\nfrom neuroglia.dependency_injection.service_provider import IServiceProvider, ServiceCollection, ServiceProvider\nfrom tests.services import FileLogger, LoggerBase, Nu...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport re\nimport datetime\nfrom monzo_utils.lib.config import Config\nfrom monzo_utils.model.transaction import Transaction\nfrom monzo_utils.lib.transactions import Transactions\n\n# Code from current file (monzo_ut...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom tqdm import tqdm\nfrom torch_mgdcf.metrics.ranking import ndcg_score, precision_score, recall_score\nfrom torch_mgdcf.vector_search.vector_search import VectorSearchEngine\nimport numpy as np\nimport torch\n\n# C...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport argparse\nimport joblib\nimport pandas as pd\nfrom src.utils.common import read_yaml\nfrom src.utils.sys_logging import get_logger\nfrom sklearn.preprocessing import LabelEncoder\nfrom src.utils.common import w...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport multiprocessing as mp\n import time\n import traceback\n import traceback\nfrom dynapipe.pipe.data_loader import (\n _get_from_shared_kv_store,\n _init_kv_store,\n _put_to_shared_k...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom stable_diffusion.config import PathConfig\nfrom stable_diffusion.model_io import preload_models_from_safetensor_weights\nfrom utils import _state_dict\nfrom utils import get_state_dict_from_safetensor\n\n# Code f...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom pydantic import Field, validator\nfrom ark_sdk_python.models.common import ArkProtocolType\nfrom ark_sdk_python.models.common.ark_workspace_type import ArkWorkspaceType\nfrom ark_sdk_python.models.services.dpa.po...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom pytorch_grad_cam import GradCAM\nfrom PIL import Image\nfrom tqdm import tqdm\nfrom pytorch_grad_cam.utils.image import scale_cam_image\nfrom utils import scoremap2bbox\nfrom clip_text import class_names, new_cla...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom os.path import join\nfrom easyvolcap.utils.console_utils import *\nfrom easyvolcap.utils.data_utils import to_numpy\nfrom easyvolcap.utils.net_utils import save_npz\n from easyvolcap.scripts.main import test #...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport logging\nfrom typing import Any\nfrom homeassistant.components.climate import (\n ClimateEntity,\n ClimateEntityFeature,\n HVACAction,\n HVACMode,\n)\nfrom homeassistant.config_entries import Config...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport logging\nimport os\nimport pathspec\nfrom .models import File, Project\nfrom .settings import Settings\nfrom .output_builder import OutputBuilder\n\n# Code from current file (gptize/gptizer.py):\n\n\nclass GPTi...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom .._ffi import register_func\nfrom .codegen import target_has_features\n\n# Code from current file (python/tvm/target/x86.py):\n# Licensed to the Apache Software Foundation (ASF) under one\n# or more contributor l...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom pond.conventions import (\n METADATA_DIRNAME,\n MANIFEST_FILENAME,\n version_data_location,\n version_manifest_location,\n version_uri,\n urijoinpath,\n)\nfrom pond.version_name import SimpleVer...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport argparse\nimport datetime\nimport glob\nimport os\nimport urllib.parse\nfrom charset_normalizer import from_bytes\nfrom licensed_pile.licenses import PermissiveLicenses\nfrom licensed_pile.write import to_dolma...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom google_colab_selenium.colab_selenium_manager import ColabSeleniumManager\nfrom google_colab_selenium.spinner import Spinner\nfrom google_colab_selenium.exceptions import StartingChromeDriverError\nfrom selenium.w...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom functools import partial\nfrom flax import linen as nn\nfrom .rec_init import matrix_init, truncated_normal_matrix_init, theta_init, nu_init, gamma_log_init\nfrom flax.core.frozen_dict import unfreeze\nimport jax...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nimport sys\nimport argparse\nimport numpy as np\nimport torch\nimport torch.distributed as dist\nimport torch.backends.cudnn as cudnn\nimport timm.models as timm_models\nimport util.misc as misc\nfrom torch...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport fire\nimport sys\nfrom .data import HUMAN_EVAL\nfrom .evaluation import evaluate_functional_correctness\n\n# Code from current file (Evaluation/MBPP/human_eval/evaluate_functional_correctness.py):\n\n\n\ndef en...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nimport cv2\nimport typing\nfrom loguru import logger\nfrom nexaflow import toolbox\nfrom nexaflow.video import VideoFrame\n\n# Code from current file (nexaflow/hook.py):\n\n\nclass BaseHook(object):\n\n ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom uhc.khrylib.utils.torch import *\nfrom torch import nn\nfrom uhc.khrylib.models.rnn import RNN\nfrom uhc.khrylib.models.mlp import MLP\n\n# Code from current file (uhc/khrylib/models/erd_net.py):\n\n\nclass ERDNe...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport numpy as np\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom collections import OrderedDict\nfrom .layers import ConvBlock, Conv3x3, upsample, disp_to_depth, coords_to_normals\nfrom t...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom django.contrib.auth.mixins import LoginRequiredMixin, UserPassesTestMixin\nfrom django.http import HttpRequest, HttpResponse\nfrom django.shortcuts import get_object_or_404, redirect, render\nfrom django.views im...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport pytest\nimport torch\nfrom torch.nn import functional as F\nfrom bitnet.bitlinear import BitLinear, absmax_quantize\nfrom bitnet.transformer import BitNetTransformer, ParallelTransformerBlock, Transformer\n\n# ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom dataclasses import is_dataclass, fields\nfrom typing import Tuple, Callable, Any, Coroutine\nfrom pathlib import Path\nfrom aiodesa.utils.table import make_schema, TableSchema\nimport aiosqlite\n\n# Code from cur...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport math\nimport torch\nimport torch.nn as nn\nfrom models.eg3d.volumetric_rendering.ray_marcher import MipRayMarcher2\nfrom models.eg3d.volumetric_rendering import math_utils\n\n# Code from current file (models/eg...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom torch import nn\nfrom swap_face_fine.face_vid2vid.modules.util import AntiAliasInterpolation2d, make_coordinate_grid_2d\nfrom torchvision import models\nfrom torch.autograd import grad\nfrom torchvision import tr...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport logging\nimport shutil\nimport pytest\nfrom pathlib import Path\nfrom cleo.application import Application\nfrom cleo.testers.command_tester import CommandTester\nfrom deb_pkg_tools.package import ArchiveEntry\n...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom dataclasses import dataclass\nfrom typing import Callable, Protocol\nfrom .api import Array\nfrom .interpreter import forward_laplacian\nimport jax\nimport jax.numpy as jnp\n\n# Code from current file (folx/opera...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nimport argparse\nimport pinecone\nfrom dotenv import load_dotenv\nfrom context import download_embeddings\nfrom utils.utils import batch\nfrom constants import (\n INDEX_NAME,\n INDEX_ENVIRONMENT,\n ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom typing import Optional\nfrom einops import repeat\nfrom jaxtyping import Float\nfrom torch import Tensor\nfrom .coordinate_conversion import generate_conversions\nfrom .rendering import render_over_image\nfrom .t...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom abc import ABC, abstractmethod\nfrom .multimodal_encoder.builder import build_vision_tower\nfrom .multimodal_projector.builder import build_vision_projector\nfrom llava.constants import IGNORE_INDEX, IMAGE_TOKEN_...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom os import getenv\nfrom time import sleep\nfrom tqdm import tqdm\nfrom .LLM_task import LLM_task\nfrom src.srt_util.srt import split_script\nimport logging\n\n# Code from current file (src/translators/translation....
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport torch\nimport torch_scatter\nfrom drugood.models.algorithms.base import BaseAlgorithm\nfrom ..builder import MODELS, build_tasker\n\n# Code from current file (drugood/models/algorithms/groupdro.py):\n# Copyrigh...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport csv\nimport json\nimport logging\nimport os\nimport numpy as np\nimport psycopg2\n import psycopg2\nfrom typing import List\nfrom qdrant_client import QdrantClient\nfrom transformers import AutoModel...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nimport re\nimport time\nimport interpreter\nfrom random import randint\nfrom interpreter.utils.count_tokens import count_messages_tokens, count_tokens\n\n# Code from current file (tests/test_interpreter.py)...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport torch\nimport torch.nn.functional as F\nimport math\nfrom torch.nn import Dropout\nfrom torch import nn\nfrom functools import reduce\nfrom operator import mul\nfrom .Encoder_utils import LayerNorm, Transformer...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport copy\nimport datetime\nimport logging\nimport os\nimport matplotlib as mpl\nimport torch\nfrom torch.nn.functional import softmax\nfrom tqdm import tqdm\nfrom utils.misc import load_model_transform\nfrom .evalu...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport unittest\nimport pytest\nfrom pydantic import ValidationError\nfrom ray_vllm_inference.prompt_format import Message, Prompt, PromptFormat\n\n# Code from current file (tests/prompt_format_test.py):\n# Adapted fr...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom ...__Import import *\nfrom ...Variable import Listener, Poll, Variable\n\n# Code from current file (PotatoWidgets/Widget/_Common/_BasicProps.py):\n\n\nclass BasicProps(Gtk.Widget):\n def __init__(\n sel...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nimport shutil\nfrom music21 import converter as converterm21\nfrom pyMV2H.utils.mv2h import MV2H\nfrom pyMV2H.metrics.mv2h import mv2h\nfrom pyMV2H.utils.music import Music\nfrom pyMV2H.converter.midi_conve...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom collections import OrderedDict\nfrom copy import deepcopy\nfrom functools import partial\nfrom ml_collections import ConfigDict\nfrom flax.training.train_state import TrainState\nfrom .jax_utils import (\n nex...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom aiogram import Router, Bot, F\nfrom aiogram.types import Message\nfrom app.db.functions import User\nfrom app.db.functions import Card\nfrom app.keyboards.inline import get_approve_keyboard\nfrom app.config impor...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport json\nimport os\nimport random\nimport torch\nimport torch\nimport numpy as np\nimport decord\nimport os,glob\nfrom pandas import Categorical\nfrom torch.utils.data import Dataset\nfrom PIL import Image\nfrom P...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport math\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nimport torch.nn.init as init\nfrom .kb_utils import KBAFunction, LayerNorm2d, SimpleGate\n\n# Code from current file (src/spandrel/arc...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport math\nimport torch\nimport torch.nn.functional as F\n import xformers\n import xformers.ops\nfrom functools import partial\nfrom inspect import isfunction\nfrom einops import rearrange, repeat\nfrom torch...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport numpy as np\nimport torch\nfrom .base import LazyMultiStepMemory\nfrom .segment_tree import SumTree, MinTree\n\n# Code from current file (sacd/memory/per.py):\n\n\nclass LazyPrioritizedMultiStepMemory(LazyMulti...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport logging\nimport torch\nimport torch.nn.functional as F\nfrom torch import Tensor, nn\nfrom ..melspec import MelSpectrogram\nfrom .hparams import HParams\nfrom .unet import UNet\n\n# Code from current file (rese...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport sys\nimport logging\nfrom eviloauth.idp import IDP\nfrom eviloauth.exceptions import EviloauthCommandException\n\n# Code from current file (eviloauth/dispatcher.py):\n\n\nclass Dispatcher:\n def __init__(sel...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom .ipynb.ipynb_analyse import parse_ipynb, get_ipynb_content, get_model_list, model_list2python\nfrom .py.py_analyse import extract_function_defs, get_function_defs, get_intro_of_fun\n from ..llm.Ernie i...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom django.shortcuts import render\nfrom .models import *\nfrom django.http import JsonResponse\nfrom datetime import datetime\nfrom .utiles import commandeAnonyme, data_cookie, panier_cookie\nimport json\n\n# Code f...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport torch.optim as optim\r\nfrom utils.lr_scheduler import WarmupMultiStepLR, WarmupCosineAnnealingLR\r\n\n# Code from current file (utils/solver.py):\n\r\n\r\n\r\ndef _optimizer(config, model):\r\n if config.so...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport random\nimport uuid\nfrom faker import Faker\nfrom CE2OCF.ocf.mocks.company import fake_phone_number\nfrom CE2OCF.types.enums import (\n DoubleTriggerTypesEnum,\n PaidWithOptionsEnum,\n SingleTriggerTy...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom utils.utils import oneline_wrapper\nfrom utils import error\nfrom multiprocessing import Process\nimport os\nimport time\nimport argparse\n\n# Code from current file (run_advanced_maxpressure.py):\n\n\ndef parse_...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom datetime import datetime, timedelta, timezone\nfrom pathlib import Path\nfrom unittest.mock import MagicMock\nfrom pandas import DataFrame, DateOffset, Timestamp, to_datetime\nfrom freqtrade.configuration import ...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport json\nfrom typing import List\nfrom obsidian_to_bookstack.bookstack.artifacts import Book, Shelf\nfrom obsidian_to_bookstack.bookstack.client import RemoteClient\nfrom obsidian_to_bookstack.bookstack.collectors...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom rest_framework.views import APIView\nfrom .serializers import RegisterUserSerializer, ResetPasswordSerializer\nfrom rest_framework.response import Response\nfrom rest_framework.exceptions import AuthenticationFai...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport io\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom collections import defaultdict\nfrom PIL import Image\nfrom .util import box_ops\nfrom .util.misc import NestedTensor, interpolate,...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport logging\nfrom ...utils import get_mase_op, get_mase_type\nfrom .software_metadata_layers import SOFTWARE_PARAM_ANALYSIS_LAYERS\n\n# Code from current file (machop/chop/passes/graph/analysis/add_metadata/add_sof...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom torch.nn import Linear, Conv2d, BatchNorm1d, BatchNorm2d, PReLU, Dropout, Sequential, Module\nfrom ldm.thirdp.psp.helpers import get_blocks, Flatten, bottleneck_IR, bottleneck_IR_SE, l2_norm\n\n# Code from curren...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom copy import deepcopy\nfrom typing import Callable, Dict, List, Optional, Protocol, Sequence, Tuple, TypeVar\nfrom compiler.element.logger import ELEMENT_LOG as LOG\nfrom compiler.element.node import *\nfrom compi...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom unittest import TestCase\nfrom econml.sklearn_extensions.linear_model import WeightedLassoCVWrapper\nfrom sklearn.linear_model import LassoCV\nfrom openasce.inference.learner.dml import DML\nfrom tests.datasets.i...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport time\nimport torch\nfrom torch import nn\nfrom learning.op.decoding import decode\nfrom utils.misc import do_lr_decay, EpochMetrics\n\n# Code from current file (learning/op/traj_learner.py):\n\"\"\"\nBQ-NCO\nCo...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport json\r\nfrom py_process_hooker import Hook\r\nfrom py_process_hooker.winapi import *\r\nfrom .ctypes_json import CDataJSONEncoder\r\nfrom .offset import CALL_OFFSET\r\n\n# Code from current file (src/wechat_pyr...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport git\nfrom .io_utils import get_default_config, get_raw_cmdline\n\n# Code from current file (megraph/args_utils.py):\n#! /usr/bin/env python3\n# -*- coding: utf-8 -*-\n# File : args.py\n# Author : Honghua Dong...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom warnings import warn\nfrom .exceptions import NotRegistered\nfrom .modelling.get_convertor import get_convertor\nfrom .registered_predictors import registered_predictors\n\n# Code from current file (src/pyscipopt...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom Configs.frame_config import FRAME_DIR\nfrom Configs.config import FlagRegular\nfrom func.CmdColors import printX\nfrom modules.ReplaceStr import *\nfrom urllib.parse import urlparse as URL\nimport requests, pymys...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nimport numpy as np\nimport math\nfrom einops import rearrange, repeat\nfrom math import sqrt\nfrom utils.sparse_max import Sparsemax\nfrom utils.en...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport json\nimport torch.multiprocessing as mp\nfrom functools import partial\nfrom tqdm import tqdm\nfrom tree_sitter import Language, Parser\nfrom eval_utils import (\n postprocess_code_lines,\n extract_ident...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nfrom collections import OrderedDict, namedtuple\nfrom typing import Tuple\nfrom rlkit.core.loss import LossFunction, LossStatistics\nfrom torch import nn as nn\nfrom rlkit.core.eval_util import create_stats_ordered_di...
[ { "from": "human", "value": "Complete the next line of code: # Imports from current file:\nimport os\nimport warnings\nfrom e2e_ppg_pipeline import e2e_hrv_extraction\nfrom utils import get_data\n\n# Code from current file (example.py):\n# -*- coding: utf-8 -*-\n\nwarnings.filterwarnings(\"ignore\")\n\n\n# ...