encode_barcode1d — SYMBOL barcode1d op

• Data kinds: कोई नहीं → table (केवल arguments से तय होने वाला op — यह कोई image या data input नहीं लेता)

• Call: import fullseye as fs; fs.ledger.encode_barcode1d(text, symbology='code128', *, wide_ratio=2.5, check_digit=False, gs1=False) (implementation को सीधे call करना हो तो import barcode1d; barcode1d.encode_barcode1d(text, symbology='code128', *, wide_ratio=2.5, check_digit=False, gs1=False), registry से लेना हो तो opssymbol.get("encode_barcode1d"))

• GPU: नहीं (केवल CPU reference implementation)

उपयोग

string को 1-D bar code की element widths (modules में) में encode करता है (table)।

> नीचे का विस्तृत विवरण मूल text में है — सारांश और headings का अनुवाद हो चुका है।

Encode text as a 1-D symbol. Returns a table: symbology, text (the human-readable data, e.g. EAN-13 with its check digit), widths (element widths in modules, first element a bar, quiet zones excluded), quiet (left, right) in modules, n_modules (symbol length without quiet zones), edges (cumulative element boundaries starting at the left quiet-zone edge = 0), values (symbol character values, Code 128 only) and wide_ratio (two-width symbologies).

symbology: "ean13" (12 or 13 digits; the 13th must be the check digit), "upca" (11 or 12 digits), "code128" (ASCII 32..126, automatic code sets B / C; gs1=True puts FNC1 first and maps '\x1d' to FNC1 — GS1-128), "code39" (0-9 A-Z - . space $ / + %, start/stop * added, optional mod-43 check with check_digit=True), "itf" (an even number of digits; check_digit=True appends the GS1 mod-10 check to make the count even). wide_ratio (two-width symbologies) must lie in [2.0, 3.0].

空の入力(text == "")は ValueError(理由: 符号化する中身が無い)。拒否(ValueError): 文字列でない、未知のシンボル体系、字種の外の文字、桁数違い、検査数字の不一致、wide_ratio が [2.0, 3.0] の外。

उपयोग की विस्तृत guide

• symbol_reading family guide

संदर्भ (sample data, साहित्य)

• Sample data catalog (DL URL / license) — 2-D के लिए skimage.data (BSD/public) + synthetic, 3-D के लिए real data sources (Stanford/PDS आदि) के DL URL।

• Operators का स्रोत और संदर्भ — इस op family के मूल research/methods के स्रोत।

• Algorithm का मानक स्रोत (लेखक, वर्ष) और उपयोग ऊपर की family usage guide में दिए गए हैं।

चलाए जा सकने वाले उदाहरण (verified samples जो सच में यह op call करते हैं)

• poc_symbol_package_1d — py -3.11 examples/poc_symbol_package_1d.py

वे अगले ops जिनसे type जुड़ता है (table को input के रूप में लेते हैं)

render_symbol · symbol_read_trials · symbol_read_pod · ocr_classify · ocr_read_line · ocr_read_trials

इसी category के (barcode1d)

ean_check_digit · barcode_scan_profiles · decode_barcode_profile · read_barcode1d


*Provenance: barcode1d.py — SYMBOL operator registry. यह per-op note tools/opdocs.py md से अपने-आप generate होता है (हाथ से edit न करें)।*

© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.