Datasets:
text stringlengths 232 16.3k | domain stringclasses 1
value | difficulty stringclasses 3
values | meta dict |
|---|---|---|---|
<|fim_suffix|> :param obj: input object
:return: Serializer
"""
# 1-NULL serializer
if obj is None:
return self._null_serializer_adapter
obj_type = type(obj)
serializer = None
# 2-Default serializers, Dataserializable, Portable, primitives, ar... | code_fim | hard | {
"lang": "python",
"repo": "mustafaiman/hazelcast-python-client",
"path": "/hazelcast/serialization/base.py",
"mode": "spm",
"license": "Apache-2.0",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: mustafaiman/hazelcast-python-client path: /hazelcast/serialization/base.py
from threading import RLock
from api import *
from data import *
from hazelcast.core import *
from serializer import *
EMPTY_PARTITIONING_STRATEGY = lambda key: None
def handle_exception(e):
if isinstance(e, Memory... | code_fim | hard | {
"lang": "python",
"repo": "mustafaiman/hazelcast-python-client",
"path": "/hazelcast/serialization/base.py",
"mode": "psm",
"license": "Apache-2.0",
"source": "the-stack-v2"
} |
<|fim_suffix|> serializer_adaptor = create_buffer_serializer_wrapper(serializer)
self.register_constant_serializer_adaptor(obj_type, serializer_adaptor)
def register_constant_serializer_adaptor(self, obj_type, serializer_adaptor):
self._constant_type_dict[obj_type] = serializer_adaptor
... | code_fim | hard | {
"lang": "python",
"repo": "mustafaiman/hazelcast-python-client",
"path": "/hazelcast/serialization/base.py",
"mode": "spm",
"license": "Apache-2.0",
"source": "the-stack-v2"
} |
<|fim_suffix|> """Logs epoch level validation metrics."""
self.log_dict(self.val_metrics.compute())
self.val_metrics.reset()
def test_step(self, *args: Any, **kwargs: Any) -> None:
"""Compute test loss.
Args:
batch: the output of your DataLoader
"""
... | code_fim | hard | {
"lang": "python",
"repo": "microsoft/torchgeo",
"path": "/torchgeo/trainers/segmentation.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|> """Logs epoch level test metrics."""
self.log_dict(self.test_metrics.compute())
self.test_metrics.reset()
def predict_step(self, *args: Any, **kwargs: Any) -> Tensor:
"""Compute and return the predictions.
By default, this will loop over images in a dataloader... | code_fim | hard | {
"lang": "python",
"repo": "microsoft/torchgeo",
"path": "/torchgeo/trainers/segmentation.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: microsoft/torchgeo path: /torchgeo/trainers/segmentation.py
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
"""Segmentation tasks."""
import os
import warnings
from typing import Any, cast
import matplotlib.pyplot as plt
import segmentation_models_... | code_fim | hard | {
"lang": "python",
"repo": "microsoft/torchgeo",
"path": "/torchgeo/trainers/segmentation.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: vmware/network-insight-sdk-generic-datasources path: /network_insight_sdk_generic_datasources/common/import_module_utilities.py
# Copyright 2019 VMware, Inc.
# SPDX-License-Identifier: BSD-2-Clause
import importlib
def load_class(class_path):
module = importlib.import_module(".".join(clas... | code_fim | hard | {
"lang": "python",
"repo": "vmware/network-insight-sdk-generic-datasources",
"path": "/network_insight_sdk_generic_datasources/common/import_module_utilities.py",
"mode": "psm",
"license": "BSD-2-Clause",
"source": "the-stack-v2"
} |
<|fim_suffix|>
def load_class_for_pre_post_parser(device, class_name):
module_path = "{0}.{1}.{1}_{2}".format("network_insight_sdk_generic_datasources.routers_and_switches", device,
"pre_post_processor")
module = importlib.import_module(module_path)
return getattr(... | code_fim | hard | {
"lang": "python",
"repo": "vmware/network-insight-sdk-generic-datasources",
"path": "/network_insight_sdk_generic_datasources/common/import_module_utilities.py",
"mode": "spm",
"license": "BSD-2-Clause",
"source": "the-stack-v2"
} |
<|fim_suffix|>def load_class_for_process_table(device, class_name):
module_path = "{0}.{1}.{1}_{2}".format("network_insight_sdk_generic_datasources.routers_and_switches", device,
"pre_post_processor")
module = importlib.import_module(module_path)
return getattr(mod... | code_fim | hard | {
"lang": "python",
"repo": "vmware/network-insight-sdk-generic-datasources",
"path": "/network_insight_sdk_generic_datasources/common/import_module_utilities.py",
"mode": "spm",
"license": "BSD-2-Clause",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: tnakamura/SilverTask path: /silvertask-web/kay/sessions/middleware.py
# -*- coding: utf-8 -*-
"""
Kay session middleware.
:Copyright: (c) 2009 Accense Technology, Inc. All rights reserved.
:license: BSD, see LICENSE for more details.
"""
import kay.sessions
from kay.conf import settings
from w... | code_fim | medium | {
"lang": "python",
"repo": "tnakamura/SilverTask",
"path": "/silvertask-web/kay/sessions/middleware.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|> if hasattr(request, '_cached_session') and \
request.session.should_save and hasattr(response, 'set_cookie'):
session_store = import_string(settings.SESSION_STORE)()
session_store.save(request.session)
response.set_cookie(settings.COOKIE_NAME,
sess... | code_fim | hard | {
"lang": "python",
"repo": "tnakamura/SilverTask",
"path": "/silvertask-web/kay/sessions/middleware.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: great-expectations/great_expectations path: /great_expectations/core/usage_statistics/schemas.py
"$schema": SCHEMA,
"title": "anonymized-test-yaml-config-payload",
"definitions": {
"anonymized_string": anonymized_string_schema,
"anonymized_class_info": anonymized_class_inf... | code_fim | hard | {
"lang": "python",
"repo": "great-expectations/great_expectations",
"path": "/great_expectations/core/usage_statistics/schemas.py",
"mode": "psm",
"license": "Apache-2.0",
"source": "the-stack-v2"
} |
<|fim_suffix|>anonymized_expectation_configuration_builder_schema = {
"$schema": SCHEMA,
"title": "anonymized-expectation-configuration-builder",
"definitions": {
"anonymized_string": anonymized_string_schema,
},
"type": "object",
"properties": {
"parent_class": {"type": "string"... | code_fim | hard | {
"lang": "python",
"repo": "great-expectations/great_expectations",
"path": "/great_expectations/core/usage_statistics/schemas.py",
"mode": "spm",
"license": "Apache-2.0",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: mpavezb/CarND-Advanced-Lane-Lines path: /main.py
from src.logger import Log
from src.lane_tracker import LaneLinesTracker
from examples import *
<|fim_suffix|> input_file = "project_video.mp4"
output_file = "output_videos/project_video.mp4"
tracker = LaneLinesTracker()
clip = tra... | code_fim | medium | {
"lang": "python",
"repo": "mpavezb/CarND-Advanced-Lane-Lines",
"path": "/main.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|> Log.debug_enabled = False
# RunCalibrationExample()
# RunDistortionCorrectionExample()
# RunEdgeDetectionExample()
# RunPerspectiveTransformExample()
# RunLaneFittingExample()
# RunFullPipelineExample()
ProcessProjectVideo(subclip_seconds=None)
if __name__ == "__main__":... | code_fim | hard | {
"lang": "python",
"repo": "mpavezb/CarND-Advanced-Lane-Lines",
"path": "/main.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|>qs = MyModel.objects
qs = q.filter(field__regex=r'^(An?|The) +')<|fim_prefix|># repo: andrewp-as-is/django-examples path: /Models/querysets/Field lookups/__regex/tests.py
#!/usr/bin/env python
from .models import MyModel
<|fim_middle|>"""
https://docs.djangoproject.com/en/dev/ref/models/querysets/#regex... | code_fim | medium | {
"lang": "python",
"repo": "andrewp-as-is/django-examples",
"path": "/Models/querysets/Field lookups/__regex/tests.py",
"mode": "spm",
"license": "Unlicense",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: andrewp-as-is/django-examples path: /Models/querysets/Field lookups/__regex/tests.py
#!/usr/bin/env python
from .models import MyModel
<|fim_suffix|>qs = MyModel.objects
qs = q.filter(field__regex=r'^(An?|The) +')<|fim_middle|>"""
https://docs.djangoproject.com/en/dev/ref/models/querysets/#regex... | code_fim | medium | {
"lang": "python",
"repo": "andrewp-as-is/django-examples",
"path": "/Models/querysets/Field lookups/__regex/tests.py",
"mode": "psm",
"license": "Unlicense",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: KKowalewski24/MUM path: /Task4/Program/module/k_means.py
from datetime import datetime
from typing import List, Tuple
import matplotlib.pyplot as plt
import numpy as np
from sklearn.cluster import KMeans
from sklearn.metrics import silhouette_score
from module.LatexGenerator import LatexGenerat... | code_fim | hard | {
"lang": "python",
"repo": "KKowalewski24/MUM",
"path": "/Task4/Program/module/k_means.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|> save_latex: bool = False) -> None:
scores_clusters_numbers: List[Tuple[List[float], List[float]]] = []
scores_iter_numbers: List[Tuple[List[float], List[float]]] = []
for cluster_value in CLUSTERS_NUMBER:
k_means = KMeans(
n_clusters=cluster_value
... | code_fim | hard | {
"lang": "python",
"repo": "KKowalewski24/MUM",
"path": "/Task4/Program/module/k_means.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: r3gh/hackathonRioHeatMap path: /server/tweets/src/stream_twitter.py
import tweepy
from tweepy import OAuthHandler
from tweepy.streaming import StreamListener
import numpy as np
import json
import numpy as np
from tweets.src.functions import *
class StreamTwitterGenerator:
def __init__(self):
... | code_fim | medium | {
"lang": "python",
"repo": "r3gh/hackathonRioHeatMap",
"path": "/server/tweets/src/stream_twitter.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|> consumer_key = tokens['consumer_key']
consumer_secret = tokens['consumer_secret']
access_token = tokens['access_token']
access_secret = tokens['access_secret']
auth = OAuthHandler(consumer_key, consumer_secret)
auth.set_access_token(access_token, access_secret)
api = ... | code_fim | medium | {
"lang": "python",
"repo": "r3gh/hackathonRioHeatMap",
"path": "/server/tweets/src/stream_twitter.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|> soup = htmlRequest(url)
genreList = soup.select('.breadcrumb > li')[1].contents[1]
genreName = genreList.contents[0]
return genreName
"""
# Functions which are 3 functions below from here gives exact URL
# however it is little bit slower
"""
def getCatIDLetters(l,url):
i = url.rfind("id")
catID =... | code_fim | hard | {
"lang": "python",
"repo": "ferhatyaman/appStore",
"path": "/appReader.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: ferhatyaman/appStore path: /appReader.py
import urllib.request
from bs4 import BeautifulSoup
import string, sys, sqlite3, time
#if connection lost or server waits the program
#try to catch error and sleep until error is gone
def htmlRequest(url):
success= False
while not success:
tr... | code_fim | hard | {
"lang": "python",
"repo": "ferhatyaman/appStore",
"path": "/appReader.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: 1748276037/Django path: /bookmanager/book/views.py
from django.shortcuts import render
<|fim_suffix|> context = {
'name':'想了解更多吗?点击我哦'
}
# 请求
# 参数2: 模板文件
return render(request,'book/index.html',context=context)<|fim_middle|># Create your views here.
from django.http i... | code_fim | medium | {
"lang": "python",
"repo": "1748276037/Django",
"path": "/bookmanager/book/views.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|> context = {
'name':'想了解更多吗?点击我哦'
}
# 请求
# 参数2: 模板文件
return render(request,'book/index.html',context=context)<|fim_prefix|># repo: 1748276037/Django path: /bookmanager/book/views.py
from django.shortcuts import render
<|fim_middle|># Create your views here.
from django.http i... | code_fim | medium | {
"lang": "python",
"repo": "1748276037/Django",
"path": "/bookmanager/book/views.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_suffix|> # Fourier transform
fft2 = staticmethod(npa.fft.fft2)
backend = NumpyBackend()
def set_backend(name):
"""
Set the backend for the simulations.
This function monkey-patches the backend object by changing its class.
This way, all methods of the backend object will be replace... | code_fim | hard | {
"lang": "python",
"repo": "SiEPIC/legume",
"path": "/legume/backend.py",
"mode": "spm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: SiEPIC/legume path: /legume/backend.py
"""
Backend for the simulations. Available backends:
- numpy [default]
- autograd
A backend can be set with the 'set_backend'
import legume
legume.set_backend("autograd")
Numpy is still used with some functionalities; if autograd backend is set,
... | code_fim | hard | {
"lang": "python",
"repo": "SiEPIC/legume",
"path": "/legume/backend.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: ably/ably-python path: /ably/types/options.py
import random
import logging
from ably.transport.defaults import Defaults
from ably.types.authoptions import AuthOptions
log = logging.getLogger(__name__)
class Options(AuthOptions):
def __init__(self, client_id=None, log_level=0, tls=True, re... | code_fim | hard | {
"lang": "python",
"repo": "ably/ably-python",
"path": "/ably/types/options.py",
"mode": "psm",
"license": "Apache-2.0",
"source": "the-stack-v2"
} |
<|fim_suffix|> @property
def loop(self):
return self.__loop
# RTC1b
@property
def auto_connect(self):
return self.__auto_connect
@property
def connection_state_ttl(self):
return self.__connection_state_ttl
@connection_state_ttl.setter
def connection_state_tt... | code_fim | hard | {
"lang": "python",
"repo": "ably/ably-python",
"path": "/ably/types/options.py",
"mode": "spm",
"license": "Apache-2.0",
"source": "the-stack-v2"
} |
<|fim_prefix|># repo: tiabas/django-forms path: /form_engine/views.py
for_field_type(field_type)
if not template_field_form:
raise HttpResponseNotFound("<p>Invalid field type: </p>" % request.POST.get('qtype'))
form_template = get_object_or_404(Survey, pk=form_id)
item_forms = forms_for_survey_no_prefix(request, ... | code_fim | hard | {
"lang": "python",
"repo": "tiabas/django-forms",
"path": "/form_engine/views.py",
"mode": "psm",
"license": "MIT",
"source": "the-stack-v2"
} |
QuickCoder-Dataset
This dataset repository stores upload-ready JSONL training checkpoints for code completion and fill-in-the-middle training. Checkpoints are appended in approximately 20 GiB units so they can also be copied to Google Drive and loaded from Colab/H100 training jobs. New checkpoints use one JSONL file per 20 GiB checkpoint. The long-term target is 400 GiB total mirrored to Hugging Face and Google Drive.
Current Upload Status
Only validation-passing checkpoints should be uploaded or used for training.
| Checkpoint | Size | JSONL | In-bundle duplicates | Status |
|---|---|---|---|---|
checkpoint_20260611_104104_bundle01_20g |
19.04 GiB | valid, single JSONL | 0 | uploaded to Hugging Face; Google Drive cloud verified by rclone SHA256/size check |
checkpoint_20260611_112534_bundle01_20g |
19.11 GiB | valid, single JSONL | 0 | uploaded to Hugging Face; Google Drive cloud verified by rclone SHA256/size check |
checkpoint_20260611_143422_bundle01_20g |
19.19 GiB | valid, single JSONL | 0 | uploaded to Hugging Face; Google Drive upload pending user confirmation |
Current Hugging Face dataset repo:
aisamdasu/QuickCoder-Dataset
Repository Layout
README.md
dataset_guide/
tokenizer/
dense/
moe/
dataset/
checkpoint_YYYYMMDD_HHMMSS_bundleNN_20g/
dataset/
checkpoint_YYYYMMDD_HHMMSS_bundleNN_20g.jsonl
dataset_guide/
checkpoint_reports/
checkpoint_YYYYMMDD_HHMMSS_bundleNN_20g/
MANIFEST.json
BALANCE_REPORT.md
CHECKSUMS.txt
Record Format
Each line is one UTF-8 JSON object. The main training payload is text.
Metadata can appear in top-level fields and in meta.
Common fields:
text: canonical training string.domain: task family such ascode_fimorcode_gen.difficulty: coarse difficulty bucket.meta.lang: programming language.meta.repo,meta.path,meta.license,meta.source: source metadata when available.meta.mode: FIM ordering such aspsmorspm.
FIM examples use explicit special tokens:
<|fim_prefix|>{prefix}<|fim_suffix|>{suffix}<|fim_middle|>{middle}
Some FIM shards may use suffix-prefix-middle ordering for robustness.
Source And License Notes
This is a mixed code dataset. Bundle 1 contains generated/unknown continuation
records and the-stack-v2 FIM records with per-record source metadata such as
repository, path, and license where available. Consumers should filter by
meta.license, meta.source, and project policy before redistribution or
training.
The dataset card intentionally uses license: other because this repository
contains mixed-source records rather than one uniform license.
Validation Contract
A checkpoint is upload-ready only when:
- JSONL parsing succeeds.
- Empty
textcount is zero. - In-bundle duplicate count is zero.
- The checkpoint folder contains only one file:
dataset/<checkpoint>.jsonl. Legacy checkpoints may contain several JSONL parts only until they are repackaged. MANIFEST.json,BALANCE_REPORT.md, andCHECKSUMS.txtare present underdataset_guide/checkpoint_reports/<checkpoint>/.- Shared
tokenizer/,dense/, andmoe/documentation lives at repository root, outside checkpoint folders.
Do not train on a checkpoint marked Not Upload Ready.
- Downloads last month
- 74