omni-viewer-core 0.15.0 → 0.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -16,7 +16,7 @@ models, viewers mount into a DOM element, and everything host-specific
16
16
  legacy PPT), Markdown, LaTeX (structure and math preview, not typesetting)
17
17
  - **Data & spreadsheets** — Excel, CSV/TSV, JSON, JSONL/NDJSON, YAML, TOML,
18
18
  Parquet, Avro, HDF5, MATLAB MAT, NumPy (NPY/NPZ), Safetensors, GGUF, ONNX, TFLite/LiteRT,
19
- Protocol Buffers, ReqIF, SQLite
19
+ Keras (.keras and legacy .h5), Protocol Buffers, ReqIF, SQLite
20
20
  - **Media & graphics** — audio (waveform/spectrogram), video, images,
21
21
  Photoshop PSD
22
22
  - **Engineering & automotive** — CAN DBC, AUTOSAR ARXML, ASAM A2L, Vector
@@ -145,6 +145,33 @@ and searchable operator, tensor, input/output, buffer, and model-information
145
145
  panels. Custom operators, Select TensorFlow fallbacks, and buffers stored
146
146
  outside the FlatBuffer are surfaced as warnings.
147
147
 
148
+ ### Keras models
149
+
150
+ Both Keras save formats open through one viewer. A `.keras` file is a ZIP whose
151
+ members Keras stores uncompressed, so `config.json`, `metadata.json`, and the
152
+ `model.weights.h5` store are read in place — JSZip is only consulted for an
153
+ archive that was re-zipped with compression. A legacy `.h5` model is read as
154
+ HDF5, taking `model_config` and `training_config` from the root attributes and
155
+ the parameters from `/model_weights`:
156
+
157
+ ```ts
158
+ import { mountKerasViewer } from 'omni-viewer-core/viewers/keras';
159
+
160
+ await mountKerasViewer({ fileName: file.name, data: bytes }, container, ctx);
161
+ ```
162
+
163
+ Weight payloads are never read: only dataset shapes and datatypes are walked, so
164
+ parameter counts stay cheap on multi-gigabyte models. The viewer lists layers
165
+ (nested sub-models flattened by depth) with per-layer configuration, inbound
166
+ connections, and weights, plus searchable weight, configuration, training,
167
+ archive, and model-information panels.
168
+
169
+ `.keras` routes by extension, and an extensionless archive is resolved by
170
+ `probeContainer`. A `.h5` file routes to the HDF5 viewer, since only its
171
+ contents distinguish a Keras model from any other HDF5 file; hosts that read the
172
+ whole file can refine that with `looksLikeKerasHdf5` from
173
+ `omni-viewer-core/parsers/keras` and mount the Keras viewer instead.
174
+
148
175
  ### Archive host integration
149
176
 
150
177
  Archive decompression remains adapter-owned: pass an `ArchiveDecoder` to
@@ -71,7 +71,51 @@ export const CATALOG_EN = {
71
71
  'numpy.title': 'NumPy arrays', 'numpy.selectArray': 'Select array', 'numpy.data': 'Data',
72
72
  'numpy.arrays': 'Arrays', 'numpy.copyJson': 'Copy JSON', 'numpy.noData': 'No arrays available.',
73
73
  'numpy.previewUnavailable': 'A value preview is not available for this dtype.', 'numpy.slice': 'Slice',
74
+ 'numpy.previewLimited': 'The document preview budget was exhausted before this array.',
75
+ 'numpy.emptyArray': 'This array has no elements.',
74
76
  'numpy.gridShown': '{rows} / {totalRows} rows · {columns} / {totalColumns} columns shown',
77
+ 'numpy.document.npy': 'NumPy array', 'numpy.document.npz': 'NumPy array archive',
78
+ 'numpy.summary.arrays': 'Arrays', 'numpy.summary.elements': 'Elements', 'numpy.summary.dtypes': 'Data types',
79
+ 'numpy.summary.status': 'Status', 'numpy.invalid': 'Invalid', 'numpy.scalar': 'scalar',
80
+ 'numpy.column.name': 'Name', 'numpy.column.dtype': 'Dtype', 'numpy.column.shape': 'Shape',
81
+ 'numpy.column.order': 'Order', 'numpy.column.elements': 'Elements', 'numpy.column.dataSize': 'Data size',
82
+ 'numpy.detail.dtype': 'dtype', 'numpy.detail.shape': 'shape', 'numpy.detail.order': 'order',
83
+ 'numpy.detail.elements': 'elements', 'numpy.detail.bytes': 'bytes', 'numpy.detail.kind': 'kind',
84
+ 'numpy.axis': 'axis {axis}', 'numpy.value': 'value',
85
+ 'numpy.kind.boolean': 'boolean', 'numpy.kind.signedInteger': 'signed integer', 'numpy.kind.unsignedInteger': 'unsigned integer',
86
+ 'numpy.kind.floatingPoint': 'floating point', 'numpy.kind.complex': 'complex', 'numpy.kind.byteString': 'byte string',
87
+ 'numpy.kind.unicodeString': 'Unicode string', 'numpy.kind.timedelta': 'timedelta', 'numpy.kind.datetime': 'datetime',
88
+ 'numpy.kind.void': 'void', 'numpy.kind.object': 'object', 'numpy.kind.unknown': 'unknown',
89
+ 'numpy.warning.notNumpy': 'The file is not a NumPy .npy or .npz file.',
90
+ 'numpy.warning.npyMagic': 'The NPY magic signature is missing.', 'numpy.warning.npzMagic': 'The NPZ ZIP signature is missing.',
91
+ 'numpy.warning.npzDeclaredSize': 'The NPZ declared uncompressed size exceeds {limit}.',
92
+ 'numpy.warning.npzEntryCount': 'The NPZ archive exceeds the {limit} entry safety limit.',
93
+ 'numpy.warning.npzArrayCount': 'Only the first {limit} arrays are shown.',
94
+ 'numpy.warning.npzArraySize': 'The uncompressed array exceeds the {limit} safety limit.',
95
+ 'numpy.warning.npzCrc': 'CRC validation failed; the array was skipped.',
96
+ 'numpy.warning.npzEntryRead': 'The array member could not be decompressed and was skipped: {reason}',
97
+ 'numpy.warning.npzTotalSize': 'Stopped expanding arrays at the {limit} total safety limit.',
98
+ 'numpy.warning.npzNoArrays': 'The NPZ archive does not contain any .npy arrays.',
99
+ 'numpy.warning.npzRead': 'The NPZ archive could not be read: {reason}',
100
+ 'numpy.warning.npyHeader': 'Invalid or truncated NPY header.',
101
+ 'numpy.warning.npyVersion': 'Unsupported NPY format version {version}.',
102
+ 'numpy.warning.npyHeaderBounds': 'The declared NPY header extends beyond the file.',
103
+ 'numpy.warning.npyHeaderSize': 'The NPY header exceeds the {limit} safety limit.',
104
+ 'numpy.warning.npyHeaderDecode': 'The NPY header text could not be decoded.',
105
+ 'numpy.warning.npyHeaderFields': 'The NPY header is missing a simple dtype, shape, or storage-order declaration. Structured dtypes are not yet decoded.',
106
+ 'numpy.warning.npyHeaderGrammar': 'The NPY header contains duplicate fields or unsupported trailing syntax.',
107
+ 'numpy.warning.npyShape': 'The NPY shape contains an invalid dimension.',
108
+ 'numpy.warning.npyElementCount': 'The NPY element count is outside the safe integer range.',
109
+ 'numpy.warning.npyRank': 'The NPY array rank exceeds the {limit}-axis safety limit.',
110
+ 'numpy.warning.payloadShort': 'The array payload is shorter than its dtype and shape require.',
111
+ 'numpy.warning.payloadTrailing': 'The array payload contains trailing bytes.',
112
+ 'numpy.warning.objectUnsafe': 'Object arrays are not loaded because doing so would require unsafe pickle deserialization.',
113
+ 'numpy.warning.dtypeUnsupported': 'Values with dtype {dtype} are not decoded; metadata is still available.',
114
+ 'numpy.warning.nativeEndian': 'Native-endian dtype was interpreted as little-endian.',
115
+ 'numpy.warning.previewDecode': 'Some preview values could not be decoded.',
116
+ 'numpy.warning.previewLimit': 'The document value preview is limited to {limit} elements.',
117
+ 'numpy.warning.textPreviewLimit': 'String previews are limited to {perValue} characters per value and {total} characters per document.',
118
+ 'numpy.warning.stringItemSize': 'String values wider than {limit} are not decoded.',
75
119
  'gguf.title': 'GGUF', 'gguf.search': 'Search metadata and tensors…', 'gguf.copyJson': 'Copy JSON',
76
120
  'gguf.structure': 'Structure', 'gguf.noData': 'No data available.',
77
121
  'gguf.matchingRows': '{count} matching rows',
@@ -166,6 +210,51 @@ export const CATALOG_EN = {
166
210
  'tflite.inspector.inputs': 'Inputs', 'tflite.inspector.outputs': 'Outputs',
167
211
  'tflite.inspector.intermediates': 'Intermediates', 'tflite.inspector.options': 'Options',
168
212
  'tflite.inspector.customOptions': 'Custom options', 'tflite.inspector.subgraphs': 'Referenced subgraphs',
213
+ 'keras.title': 'Keras model', 'keras.document.v3': 'Keras v3 archive', 'keras.document.hdf5': 'Keras HDF5 model',
214
+ 'keras.version': 'Keras {version}', 'keras.search': 'Search layers, weights, and configuration…',
215
+ 'keras.copyJson': 'Copy JSON', 'keras.invalid': 'invalid',
216
+ 'keras.tab.layers': 'Layers', 'keras.tab.weights': 'Weights', 'keras.tab.config': 'Configuration',
217
+ 'keras.tab.training': 'Training', 'keras.tab.files': 'Archive', 'keras.tab.model': 'Model Info',
218
+ 'keras.rows': '{count} rows', 'keras.rowsLimited': '{shown} / {total} rows shown',
219
+ 'keras.summary.layers': 'Layers', 'keras.summary.parameters': 'Parameters',
220
+ 'keras.summary.weightBytes': 'Weight size', 'keras.summary.kerasVersion': 'Keras version',
221
+ 'keras.summary.status': 'Status',
222
+ 'keras.column.name': 'Name', 'keras.column.type': 'Type', 'keras.column.inputShape': 'Input shape',
223
+ 'keras.column.activation': 'Activation', 'keras.column.parameters': 'Parameters',
224
+ 'keras.column.weights': 'Weights', 'keras.column.trainable': 'Trainable', 'keras.column.layer': 'Layer',
225
+ 'keras.column.shape': 'Shape', 'keras.column.dtype': 'Data type', 'keras.column.bytes': 'Size',
226
+ 'keras.column.path': 'Path', 'keras.column.field': 'Field', 'keras.column.value': 'Value',
227
+ 'keras.column.size': 'Size', 'keras.column.compressed': 'Compressed', 'keras.column.method': 'Method',
228
+ 'keras.detail.identity': 'Identity', 'keras.detail.inbound': 'Inputs from',
229
+ 'keras.detail.weights': 'Weights', 'keras.detail.config': 'Configuration',
230
+ 'keras.model.format': 'Format', 'keras.model.class': 'Model class', 'keras.model.name': 'Model name',
231
+ 'keras.model.kerasVersion': 'Keras version', 'keras.model.backend': 'Backend',
232
+ 'keras.model.dateSaved': 'Saved', 'keras.model.fileSize': 'File size',
233
+ 'keras.model.parameters': 'Parameters', 'keras.model.inputs': 'Inputs', 'keras.model.outputs': 'Outputs',
234
+ 'keras.noData': 'No data to show.', 'keras.noLayers': 'No layers were found in this model.',
235
+ 'keras.noWeights': 'This file stores no weights.',
236
+ 'keras.noConfig': 'This file does not carry a readable model configuration.',
237
+ 'keras.noTraining': 'This model was saved without a training configuration.',
238
+ 'keras.warning.notKeras': 'The file is neither a .keras archive nor an HDF5 model.',
239
+ 'keras.warning.archiveUnreadable': 'The .keras archive directory could not be read.',
240
+ 'keras.warning.archiveEntryLimit': 'Only the first {limit} archive entries were inspected.',
241
+ 'keras.warning.memberTooLarge': '{name} exceeds the {limit} safety limit and was skipped.',
242
+ 'keras.warning.memberUnreadable': '{name} could not be read from the archive.',
243
+ 'keras.warning.memberMethod': '{name} uses unsupported compression method {method}.',
244
+ 'keras.warning.inflateUnavailable': '{name} is compressed, and no inflater is available on this platform.',
245
+ 'keras.warning.jsonInvalid': '{name} is not valid JSON.',
246
+ 'keras.warning.configMissing': 'The archive has no config.json, so the layer list is unavailable.',
247
+ 'keras.warning.configMissingHdf5': 'The file has no model_config attribute; it may be a weights-only checkpoint.',
248
+ 'keras.warning.configUnreadable': 'The model_config attribute could not be decoded.',
249
+ 'keras.warning.configTruncated': 'The configuration preview was truncated to {limit} characters.',
250
+ 'keras.warning.weightsMissing': 'No weight store was found, so parameter counts are unavailable.',
251
+ 'keras.warning.weightsUnreadable': 'The weight store is not a readable HDF5 file.',
252
+ 'keras.warning.weightLimit': 'Only the first {limit} weights were read.',
253
+ 'keras.warning.layerLimit': 'Only the first {limit} layers were read.',
254
+ 'keras.warning.noLayers': 'The configuration declares no layers.',
255
+ 'keras.warning.unmatchedWeights': 'Weights for "{layer}" have no matching layer in the configuration.',
256
+ 'keras.warning.unmatchedWeightsMore': '{count} further weight group(s) have no matching layer.',
257
+ 'keras.warning.structureTruncated': 'The HDF5 structure exceeded the inspection limits and was read partially.',
169
258
  'proto.title': 'Protocol Buffer', 'proto.summary': '{syntax} · {package} · {messages} messages · {services} services',
170
259
  'proto.noPackage': 'no package', 'proto.search': 'Search message, field, enum, RPC', 'proto.copyPanel': 'Copy panel',
171
260
  'proto.panel.tree': 'Message Tree', 'proto.panel.types': 'Types', 'proto.panel.relationships': 'Relationships',
@@ -67,7 +67,51 @@ export const CATALOG_JA = {
67
67
  'numpy.title': 'NumPy配列', 'numpy.selectArray': '配列を選択', 'numpy.data': 'データ',
68
68
  'numpy.arrays': '配列一覧', 'numpy.copyJson': 'JSONをコピー', 'numpy.noData': '表示できる配列がありません。',
69
69
  'numpy.previewUnavailable': 'このデータ型の値プレビューは利用できません。', 'numpy.slice': 'スライス',
70
+ 'numpy.previewLimited': 'この配列に達する前にドキュメントのプレビュー予算を使い切りました。',
71
+ 'numpy.emptyArray': 'この配列には要素がありません。',
70
72
  'numpy.gridShown': '{totalRows}行中{rows}行・{totalColumns}列中{columns}列を表示',
73
+ 'numpy.document.npy': 'NumPy配列', 'numpy.document.npz': 'NumPy配列アーカイブ',
74
+ 'numpy.summary.arrays': '配列', 'numpy.summary.elements': '要素', 'numpy.summary.dtypes': 'データ型',
75
+ 'numpy.summary.status': '状態', 'numpy.invalid': '無効', 'numpy.scalar': 'スカラー',
76
+ 'numpy.column.name': '名前', 'numpy.column.dtype': 'データ型', 'numpy.column.shape': '形状',
77
+ 'numpy.column.order': '順序', 'numpy.column.elements': '要素', 'numpy.column.dataSize': 'データサイズ',
78
+ 'numpy.detail.dtype': 'データ型', 'numpy.detail.shape': '形状', 'numpy.detail.order': '順序',
79
+ 'numpy.detail.elements': '要素', 'numpy.detail.bytes': 'バイト', 'numpy.detail.kind': '種類',
80
+ 'numpy.axis': '軸 {axis}', 'numpy.value': '値',
81
+ 'numpy.kind.boolean': 'ブール値', 'numpy.kind.signedInteger': '符号付き整数', 'numpy.kind.unsignedInteger': '符号なし整数',
82
+ 'numpy.kind.floatingPoint': '浮動小数点', 'numpy.kind.complex': '複素数', 'numpy.kind.byteString': 'バイト文字列',
83
+ 'numpy.kind.unicodeString': 'Unicode文字列', 'numpy.kind.timedelta': '時間差', 'numpy.kind.datetime': '日時',
84
+ 'numpy.kind.void': 'void', 'numpy.kind.object': 'オブジェクト', 'numpy.kind.unknown': '不明',
85
+ 'numpy.warning.notNumpy': 'NumPy .npyまたは.npzファイルではありません。',
86
+ 'numpy.warning.npyMagic': 'NPYマジックシグネチャがありません。', 'numpy.warning.npzMagic': 'NPZ ZIPシグネチャがありません。',
87
+ 'numpy.warning.npzDeclaredSize': 'NPZの宣言済み展開サイズが{limit}を超えています。',
88
+ 'numpy.warning.npzEntryCount': 'NPZアーカイブがエントリ数の安全上限{limit}を超えています。',
89
+ 'numpy.warning.npzArrayCount': '先頭{limit}個の配列のみ表示します。',
90
+ 'numpy.warning.npzArraySize': '展開された配列が安全上限{limit}を超えています。',
91
+ 'numpy.warning.npzCrc': 'CRC検証に失敗したため、配列をスキップしました。',
92
+ 'numpy.warning.npzEntryRead': '配列メンバーを展開できないためスキップしました: {reason}',
93
+ 'numpy.warning.npzTotalSize': '合計安全上限{limit}で配列の展開を停止しました。',
94
+ 'numpy.warning.npzNoArrays': 'NPZアーカイブに.npy配列がありません。',
95
+ 'numpy.warning.npzRead': 'NPZアーカイブを読み込めませんでした: {reason}',
96
+ 'numpy.warning.npyHeader': 'NPYヘッダーが無効または途中で切れています。',
97
+ 'numpy.warning.npyVersion': 'NPY形式バージョン{version}は未対応です。',
98
+ 'numpy.warning.npyHeaderBounds': '宣言されたNPYヘッダーがファイルの範囲を超えています。',
99
+ 'numpy.warning.npyHeaderSize': 'NPYヘッダーが安全上限{limit}を超えています。',
100
+ 'numpy.warning.npyHeaderDecode': 'NPYヘッダーテキストをデコードできませんでした。',
101
+ 'numpy.warning.npyHeaderFields': 'NPYヘッダーに単純なdtype、shape、または保存順序の宣言がありません。構造化dtypeはまだデコードされません。',
102
+ 'numpy.warning.npyHeaderGrammar': 'NPYヘッダーに重複フィールドまたは未対応の後続構文があります。',
103
+ 'numpy.warning.npyShape': 'NPY形状に無効な次元があります。',
104
+ 'numpy.warning.npyElementCount': 'NPY要素数が安全な整数範囲外です。',
105
+ 'numpy.warning.npyRank': 'NPY配列の次元数が安全上限{limit}軸を超えています。',
106
+ 'numpy.warning.payloadShort': '配列payloadがdtypeとshapeに必要な長さより短くなっています。',
107
+ 'numpy.warning.payloadTrailing': '配列payloadに余分なバイトがあります。',
108
+ 'numpy.warning.objectUnsafe': '安全でないpickleの逆シリアル化が必要なため、オブジェクト配列は読み込みません。',
109
+ 'numpy.warning.dtypeUnsupported': 'dtype {dtype}の値はデコードされませんが、メタデータは表示できます。',
110
+ 'numpy.warning.nativeEndian': 'ネイティブエンディアンdtypeをリトルエンディアンとして解釈しました。',
111
+ 'numpy.warning.previewDecode': '一部のプレビュー値をデコードできませんでした。',
112
+ 'numpy.warning.previewLimit': 'ドキュメントの値プレビューは{limit}要素に制限されています。',
113
+ 'numpy.warning.textPreviewLimit': '文字列プレビューは1値あたり{perValue}文字、1ドキュメントあたり{total}文字に制限されています。',
114
+ 'numpy.warning.stringItemSize': '幅が{limit}を超える文字列値はデコードされません。',
71
115
  'gguf.title': 'GGUF', 'gguf.search': 'メタデータとテンソルを検索…', 'gguf.copyJson': 'JSONをコピー',
72
116
  'gguf.structure': '構造', 'gguf.noData': '表示できるデータがありません。',
73
117
  'gguf.matchingRows': '一致する行: {count}件',
@@ -162,6 +206,51 @@ export const CATALOG_JA = {
162
206
  'tflite.inspector.inputs': '入力', 'tflite.inspector.outputs': '出力',
163
207
  'tflite.inspector.intermediates': '中間テンソル', 'tflite.inspector.options': 'オプション',
164
208
  'tflite.inspector.customOptions': 'カスタムオプション', 'tflite.inspector.subgraphs': '参照サブグラフ',
209
+ 'keras.title': 'Kerasモデル', 'keras.document.v3': 'Keras v3アーカイブ', 'keras.document.hdf5': 'Keras HDF5モデル',
210
+ 'keras.version': 'Keras {version}', 'keras.search': 'レイヤー、重み、設定を検索…',
211
+ 'keras.copyJson': 'JSONをコピー', 'keras.invalid': '無効',
212
+ 'keras.tab.layers': 'レイヤー', 'keras.tab.weights': '重み', 'keras.tab.config': '設定',
213
+ 'keras.tab.training': '学習設定', 'keras.tab.files': 'アーカイブ', 'keras.tab.model': 'モデル情報',
214
+ 'keras.rows': '{count}行', 'keras.rowsLimited': '{shown} / {total}行を表示',
215
+ 'keras.summary.layers': 'レイヤー', 'keras.summary.parameters': 'パラメーター',
216
+ 'keras.summary.weightBytes': '重みサイズ', 'keras.summary.kerasVersion': 'Kerasバージョン',
217
+ 'keras.summary.status': '状態',
218
+ 'keras.column.name': '名前', 'keras.column.type': '種類', 'keras.column.inputShape': '入力形状',
219
+ 'keras.column.activation': '活性化', 'keras.column.parameters': 'パラメーター',
220
+ 'keras.column.weights': '重み', 'keras.column.trainable': '学習可能', 'keras.column.layer': 'レイヤー',
221
+ 'keras.column.shape': '形状', 'keras.column.dtype': 'データ型', 'keras.column.bytes': 'サイズ',
222
+ 'keras.column.path': 'パス', 'keras.column.field': '項目', 'keras.column.value': '値',
223
+ 'keras.column.size': 'サイズ', 'keras.column.compressed': '圧縮後', 'keras.column.method': '圧縮方式',
224
+ 'keras.detail.identity': '識別情報', 'keras.detail.inbound': '入力元',
225
+ 'keras.detail.weights': '重み', 'keras.detail.config': '設定',
226
+ 'keras.model.format': '形式', 'keras.model.class': 'モデルクラス', 'keras.model.name': 'モデル名',
227
+ 'keras.model.kerasVersion': 'Kerasバージョン', 'keras.model.backend': 'バックエンド',
228
+ 'keras.model.dateSaved': '保存日時', 'keras.model.fileSize': 'ファイルサイズ',
229
+ 'keras.model.parameters': 'パラメーター', 'keras.model.inputs': '入力', 'keras.model.outputs': '出力',
230
+ 'keras.noData': '表示できるデータがありません。', 'keras.noLayers': 'このモデルにレイヤーは見つかりませんでした。',
231
+ 'keras.noWeights': 'このファイルには重みが保存されていません。',
232
+ 'keras.noConfig': 'このファイルには読み取り可能なモデル設定が含まれていません。',
233
+ 'keras.noTraining': 'このモデルは学習設定なしで保存されています。',
234
+ 'keras.warning.notKeras': 'このファイルは.kerasアーカイブでもHDF5モデルでもありません。',
235
+ 'keras.warning.archiveUnreadable': '.kerasアーカイブのディレクトリを読み取れませんでした。',
236
+ 'keras.warning.archiveEntryLimit': 'アーカイブの先頭{limit}件のみを検査しました。',
237
+ 'keras.warning.memberTooLarge': '{name}は安全上限の{limit}を超えるためスキップしました。',
238
+ 'keras.warning.memberUnreadable': '{name}をアーカイブから読み取れませんでした。',
239
+ 'keras.warning.memberMethod': '{name}は未対応の圧縮方式{method}を使用しています。',
240
+ 'keras.warning.inflateUnavailable': '{name}は圧縮されていますが、この環境では展開機能を利用できません。',
241
+ 'keras.warning.jsonInvalid': '{name}は有効なJSONではありません。',
242
+ 'keras.warning.configMissing': 'アーカイブにconfig.jsonがないため、レイヤー一覧を表示できません。',
243
+ 'keras.warning.configMissingHdf5': 'model_config属性がありません。重みのみのチェックポイントの可能性があります。',
244
+ 'keras.warning.configUnreadable': 'model_config属性をデコードできませんでした。',
245
+ 'keras.warning.configTruncated': '設定のプレビューを{limit}文字で打ち切りました。',
246
+ 'keras.warning.weightsMissing': '重みストアが見つからないため、パラメーター数を表示できません。',
247
+ 'keras.warning.weightsUnreadable': '重みストアは読み取り可能なHDF5ファイルではありません。',
248
+ 'keras.warning.weightLimit': '先頭{limit}件の重みのみを読み取りました。',
249
+ 'keras.warning.layerLimit': '先頭{limit}件のレイヤーのみを読み取りました。',
250
+ 'keras.warning.noLayers': '設定にレイヤーが宣言されていません。',
251
+ 'keras.warning.unmatchedWeights': '「{layer}」の重みに対応するレイヤーが設定に見つかりません。',
252
+ 'keras.warning.unmatchedWeightsMore': '対応するレイヤーがない重みグループがさらに{count}件あります。',
253
+ 'keras.warning.structureTruncated': 'HDF5構造が検査上限を超えたため、一部のみ読み取りました。',
165
254
  'proto.title': 'Protocol Buffer', 'proto.summary': '{syntax} · {package} · メッセージ{messages}件 · サービス{services}件',
166
255
  'proto.noPackage': 'パッケージなし', 'proto.search': 'メッセージ、フィールド、列挙型、RPCを検索', 'proto.copyPanel': 'パネルをコピー',
167
256
  'proto.panel.tree': 'メッセージツリー', 'proto.panel.types': '型', 'proto.panel.relationships': '関係',
@@ -69,7 +69,51 @@ export const CATALOG_KO = {
69
69
  'numpy.title': 'NumPy 배열', 'numpy.selectArray': '배열 선택', 'numpy.data': '데이터',
70
70
  'numpy.arrays': '배열 목록', 'numpy.copyJson': 'JSON 복사', 'numpy.noData': '표시할 배열이 없습니다.',
71
71
  'numpy.previewUnavailable': '이 데이터 타입은 값 미리보기를 제공하지 않습니다.', 'numpy.slice': '슬라이스',
72
+ 'numpy.previewLimited': '이 배열에 도달하기 전에 문서 미리보기 예산이 소진되었습니다.',
73
+ 'numpy.emptyArray': '이 배열에는 요소가 없습니다.',
72
74
  'numpy.gridShown': '전체 {totalRows}행 중 {rows}행 · 전체 {totalColumns}열 중 {columns}열 표시',
75
+ 'numpy.document.npy': 'NumPy 배열', 'numpy.document.npz': 'NumPy 배열 아카이브',
76
+ 'numpy.summary.arrays': '배열', 'numpy.summary.elements': '요소', 'numpy.summary.dtypes': '데이터 타입',
77
+ 'numpy.summary.status': '상태', 'numpy.invalid': '유효하지 않음', 'numpy.scalar': '스칼라',
78
+ 'numpy.column.name': '이름', 'numpy.column.dtype': '데이터 타입', 'numpy.column.shape': '형상',
79
+ 'numpy.column.order': '순서', 'numpy.column.elements': '요소', 'numpy.column.dataSize': '데이터 크기',
80
+ 'numpy.detail.dtype': '데이터 타입', 'numpy.detail.shape': '형상', 'numpy.detail.order': '순서',
81
+ 'numpy.detail.elements': '요소', 'numpy.detail.bytes': '바이트', 'numpy.detail.kind': '종류',
82
+ 'numpy.axis': '축 {axis}', 'numpy.value': '값',
83
+ 'numpy.kind.boolean': '불리언', 'numpy.kind.signedInteger': '부호 있는 정수', 'numpy.kind.unsignedInteger': '부호 없는 정수',
84
+ 'numpy.kind.floatingPoint': '부동소수점', 'numpy.kind.complex': '복소수', 'numpy.kind.byteString': '바이트 문자열',
85
+ 'numpy.kind.unicodeString': '유니코드 문자열', 'numpy.kind.timedelta': '시간 간격', 'numpy.kind.datetime': '날짜와 시간',
86
+ 'numpy.kind.void': 'void', 'numpy.kind.object': '객체', 'numpy.kind.unknown': '알 수 없음',
87
+ 'numpy.warning.notNumpy': 'NumPy .npy 또는 .npz 파일이 아닙니다.',
88
+ 'numpy.warning.npyMagic': 'NPY 매직 시그니처가 없습니다.', 'numpy.warning.npzMagic': 'NPZ ZIP 시그니처가 없습니다.',
89
+ 'numpy.warning.npzDeclaredSize': 'NPZ의 선언된 압축 해제 크기가 {limit}를 초과합니다.',
90
+ 'numpy.warning.npzEntryCount': 'NPZ 아카이브가 항목 안전 제한 {limit}개를 초과합니다.',
91
+ 'numpy.warning.npzArrayCount': '처음 {limit}개 배열만 표시합니다.',
92
+ 'numpy.warning.npzArraySize': '압축 해제된 배열이 안전 제한 {limit}를 초과합니다.',
93
+ 'numpy.warning.npzCrc': 'CRC 검증에 실패하여 배열을 건너뛰었습니다.',
94
+ 'numpy.warning.npzEntryRead': '배열 멤버의 압축을 해제할 수 없어 건너뛰었습니다: {reason}',
95
+ 'numpy.warning.npzTotalSize': '전체 안전 제한 {limit}에서 배열 압축 해제를 중단했습니다.',
96
+ 'numpy.warning.npzNoArrays': 'NPZ 아카이브에 .npy 배열이 없습니다.',
97
+ 'numpy.warning.npzRead': 'NPZ 아카이브를 읽을 수 없습니다: {reason}',
98
+ 'numpy.warning.npyHeader': 'NPY 헤더가 유효하지 않거나 잘렸습니다.',
99
+ 'numpy.warning.npyVersion': '지원하지 않는 NPY 형식 버전 {version}입니다.',
100
+ 'numpy.warning.npyHeaderBounds': '선언된 NPY 헤더가 파일 범위를 벗어납니다.',
101
+ 'numpy.warning.npyHeaderSize': 'NPY 헤더가 안전 제한 {limit}를 초과합니다.',
102
+ 'numpy.warning.npyHeaderDecode': 'NPY 헤더 텍스트를 디코딩할 수 없습니다.',
103
+ 'numpy.warning.npyHeaderFields': 'NPY 헤더에 단순 dtype, shape 또는 저장 순서 선언이 없습니다. 구조화 dtype은 아직 디코딩하지 않습니다.',
104
+ 'numpy.warning.npyHeaderGrammar': 'NPY 헤더에 중복 필드 또는 지원하지 않는 후행 구문이 있습니다.',
105
+ 'numpy.warning.npyShape': 'NPY 형상에 유효하지 않은 차원이 있습니다.',
106
+ 'numpy.warning.npyElementCount': 'NPY 요소 수가 안전한 정수 범위를 벗어납니다.',
107
+ 'numpy.warning.npyRank': 'NPY 배열 차원 수가 축 안전 제한 {limit}개를 초과합니다.',
108
+ 'numpy.warning.payloadShort': '배열 payload가 dtype과 shape에 필요한 크기보다 짧습니다.',
109
+ 'numpy.warning.payloadTrailing': '배열 payload에 후행 바이트가 있습니다.',
110
+ 'numpy.warning.objectUnsafe': '안전하지 않은 pickle 역직렬화가 필요하므로 객체 배열을 불러오지 않습니다.',
111
+ 'numpy.warning.dtypeUnsupported': 'dtype {dtype} 값은 디코딩하지 않지만 메타데이터는 표시합니다.',
112
+ 'numpy.warning.nativeEndian': '네이티브 endian dtype을 little-endian으로 해석했습니다.',
113
+ 'numpy.warning.previewDecode': '일부 미리보기 값을 디코딩할 수 없습니다.',
114
+ 'numpy.warning.previewLimit': '문서 값 미리보기는 {limit}개 요소로 제한됩니다.',
115
+ 'numpy.warning.textPreviewLimit': '문자열 미리보기는 값당 {perValue}자, 문서당 {total}자로 제한됩니다.',
116
+ 'numpy.warning.stringItemSize': '폭이 {limit}보다 큰 문자열 값은 디코딩하지 않습니다.',
73
117
  'gguf.title': 'GGUF', 'gguf.search': '메타데이터와 텐서 검색…', 'gguf.copyJson': 'JSON 복사',
74
118
  'gguf.structure': '구조', 'gguf.noData': '표시할 데이터가 없습니다.',
75
119
  'gguf.matchingRows': '일치하는 행 {count}개',
@@ -164,6 +208,51 @@ export const CATALOG_KO = {
164
208
  'tflite.inspector.inputs': '입력', 'tflite.inspector.outputs': '출력',
165
209
  'tflite.inspector.intermediates': '중간 텐서', 'tflite.inspector.options': '옵션',
166
210
  'tflite.inspector.customOptions': '커스텀 옵션', 'tflite.inspector.subgraphs': '참조 서브그래프',
211
+ 'keras.title': 'Keras 모델', 'keras.document.v3': 'Keras v3 아카이브', 'keras.document.hdf5': 'Keras HDF5 모델',
212
+ 'keras.version': 'Keras {version}', 'keras.search': '레이어, 가중치, 설정 검색…',
213
+ 'keras.copyJson': 'JSON 복사', 'keras.invalid': '유효하지 않음',
214
+ 'keras.tab.layers': '레이어', 'keras.tab.weights': '가중치', 'keras.tab.config': '설정',
215
+ 'keras.tab.training': '학습 설정', 'keras.tab.files': '아카이브', 'keras.tab.model': '모델 정보',
216
+ 'keras.rows': '{count}행', 'keras.rowsLimited': '{shown} / {total}행 표시',
217
+ 'keras.summary.layers': '레이어', 'keras.summary.parameters': '파라미터',
218
+ 'keras.summary.weightBytes': '가중치 크기', 'keras.summary.kerasVersion': 'Keras 버전',
219
+ 'keras.summary.status': '상태',
220
+ 'keras.column.name': '이름', 'keras.column.type': '종류', 'keras.column.inputShape': '입력 형태',
221
+ 'keras.column.activation': '활성화', 'keras.column.parameters': '파라미터',
222
+ 'keras.column.weights': '가중치', 'keras.column.trainable': '학습 가능', 'keras.column.layer': '레이어',
223
+ 'keras.column.shape': '형태', 'keras.column.dtype': '데이터 타입', 'keras.column.bytes': '크기',
224
+ 'keras.column.path': '경로', 'keras.column.field': '항목', 'keras.column.value': '값',
225
+ 'keras.column.size': '크기', 'keras.column.compressed': '압축 후', 'keras.column.method': '압축 방식',
226
+ 'keras.detail.identity': '식별 정보', 'keras.detail.inbound': '입력 출처',
227
+ 'keras.detail.weights': '가중치', 'keras.detail.config': '설정',
228
+ 'keras.model.format': '형식', 'keras.model.class': '모델 클래스', 'keras.model.name': '모델 이름',
229
+ 'keras.model.kerasVersion': 'Keras 버전', 'keras.model.backend': '백엔드',
230
+ 'keras.model.dateSaved': '저장 시각', 'keras.model.fileSize': '파일 크기',
231
+ 'keras.model.parameters': '파라미터', 'keras.model.inputs': '입력', 'keras.model.outputs': '출력',
232
+ 'keras.noData': '표시할 데이터가 없습니다.', 'keras.noLayers': '이 모델에서 레이어를 찾지 못했습니다.',
233
+ 'keras.noWeights': '이 파일에는 가중치가 저장되어 있지 않습니다.',
234
+ 'keras.noConfig': '이 파일에는 읽을 수 있는 모델 설정이 없습니다.',
235
+ 'keras.noTraining': '이 모델은 학습 설정 없이 저장되었습니다.',
236
+ 'keras.warning.notKeras': '이 파일은 .keras 아카이브도, HDF5 모델도 아닙니다.',
237
+ 'keras.warning.archiveUnreadable': '.keras 아카이브의 디렉터리를 읽지 못했습니다.',
238
+ 'keras.warning.archiveEntryLimit': '아카이브의 처음 {limit}개 항목만 검사했습니다.',
239
+ 'keras.warning.memberTooLarge': '{name}이(가) 안전 한도 {limit}을(를) 초과하여 건너뛰었습니다.',
240
+ 'keras.warning.memberUnreadable': '아카이브에서 {name}을(를) 읽지 못했습니다.',
241
+ 'keras.warning.memberMethod': '{name}이(가) 지원하지 않는 압축 방식 {method}을(를) 사용합니다.',
242
+ 'keras.warning.inflateUnavailable': '{name}이(가) 압축되어 있지만 이 환경에서는 압축 해제를 사용할 수 없습니다.',
243
+ 'keras.warning.jsonInvalid': '{name}이(가) 올바른 JSON이 아닙니다.',
244
+ 'keras.warning.configMissing': '아카이브에 config.json이 없어 레이어 목록을 표시할 수 없습니다.',
245
+ 'keras.warning.configMissingHdf5': 'model_config 속성이 없습니다. 가중치만 저장된 체크포인트일 수 있습니다.',
246
+ 'keras.warning.configUnreadable': 'model_config 속성을 디코딩하지 못했습니다.',
247
+ 'keras.warning.configTruncated': '설정 미리보기를 {limit}자에서 잘랐습니다.',
248
+ 'keras.warning.weightsMissing': '가중치 저장소를 찾지 못해 파라미터 수를 표시할 수 없습니다.',
249
+ 'keras.warning.weightsUnreadable': '가중치 저장소가 읽을 수 있는 HDF5 파일이 아닙니다.',
250
+ 'keras.warning.weightLimit': '처음 {limit}개의 가중치만 읽었습니다.',
251
+ 'keras.warning.layerLimit': '처음 {limit}개의 레이어만 읽었습니다.',
252
+ 'keras.warning.noLayers': '설정에 선언된 레이어가 없습니다.',
253
+ 'keras.warning.unmatchedWeights': '"{layer}"의 가중치에 해당하는 레이어가 설정에 없습니다.',
254
+ 'keras.warning.unmatchedWeightsMore': '대응하는 레이어가 없는 가중치 그룹이 {count}개 더 있습니다.',
255
+ 'keras.warning.structureTruncated': 'HDF5 구조가 검사 한도를 초과하여 일부만 읽었습니다.',
167
256
  'proto.title': 'Protocol Buffer', 'proto.summary': '{syntax} · {package} · 메시지 {messages}개 · 서비스 {services}개',
168
257
  'proto.noPackage': '패키지 없음', 'proto.search': '메시지, 필드, enum, RPC 검색', 'proto.copyPanel': '패널 복사',
169
258
  'proto.panel.tree': '메시지 트리', 'proto.panel.types': '타입', 'proto.panel.relationships': '관계',
@@ -60,7 +60,51 @@ export const CATALOG_ZH_CN = {
60
60
  'numpy.title': 'NumPy 数组', 'numpy.selectArray': '选择数组', 'numpy.data': '数据',
61
61
  'numpy.arrays': '数组列表', 'numpy.copyJson': '复制 JSON', 'numpy.noData': '没有可显示的数组。',
62
62
  'numpy.previewUnavailable': '此数据类型无法预览值。', 'numpy.slice': '切片',
63
+ 'numpy.previewLimited': '在到达此数组之前,文档预览预算已用尽。',
64
+ 'numpy.emptyArray': '此数组不包含元素。',
63
65
  'numpy.gridShown': '显示 {rows} / {totalRows} 行 · {columns} / {totalColumns} 列',
66
+ 'numpy.document.npy': 'NumPy 数组', 'numpy.document.npz': 'NumPy 数组归档',
67
+ 'numpy.summary.arrays': '数组', 'numpy.summary.elements': '元素', 'numpy.summary.dtypes': '数据类型',
68
+ 'numpy.summary.status': '状态', 'numpy.invalid': '无效', 'numpy.scalar': '标量',
69
+ 'numpy.column.name': '名称', 'numpy.column.dtype': '数据类型', 'numpy.column.shape': '形状',
70
+ 'numpy.column.order': '顺序', 'numpy.column.elements': '元素', 'numpy.column.dataSize': '数据大小',
71
+ 'numpy.detail.dtype': '数据类型', 'numpy.detail.shape': '形状', 'numpy.detail.order': '顺序',
72
+ 'numpy.detail.elements': '元素', 'numpy.detail.bytes': '字节', 'numpy.detail.kind': '种类',
73
+ 'numpy.axis': '轴 {axis}', 'numpy.value': '值',
74
+ 'numpy.kind.boolean': '布尔值', 'numpy.kind.signedInteger': '有符号整数', 'numpy.kind.unsignedInteger': '无符号整数',
75
+ 'numpy.kind.floatingPoint': '浮点数', 'numpy.kind.complex': '复数', 'numpy.kind.byteString': '字节字符串',
76
+ 'numpy.kind.unicodeString': 'Unicode 字符串', 'numpy.kind.timedelta': '时间差', 'numpy.kind.datetime': '日期时间',
77
+ 'numpy.kind.void': 'void', 'numpy.kind.object': '对象', 'numpy.kind.unknown': '未知',
78
+ 'numpy.warning.notNumpy': '此文件不是 NumPy .npy 或 .npz 文件。',
79
+ 'numpy.warning.npyMagic': '缺少 NPY 魔数。', 'numpy.warning.npzMagic': '缺少 NPZ ZIP 签名。',
80
+ 'numpy.warning.npzDeclaredSize': 'NPZ 声明的解压缩大小超过 {limit}。',
81
+ 'numpy.warning.npzEntryCount': 'NPZ 归档超过 {limit} 个条目的安全限制。',
82
+ 'numpy.warning.npzArrayCount': '仅显示前 {limit} 个数组。',
83
+ 'numpy.warning.npzArraySize': '解压后的数组超过 {limit} 的安全限制。',
84
+ 'numpy.warning.npzCrc': 'CRC 验证失败,已跳过该数组。',
85
+ 'numpy.warning.npzEntryRead': '无法解压数组成员,已跳过:{reason}',
86
+ 'numpy.warning.npzTotalSize': '在总安全限制 {limit} 处停止解压数组。',
87
+ 'numpy.warning.npzNoArrays': 'NPZ 归档不包含 .npy 数组。',
88
+ 'numpy.warning.npzRead': '无法读取 NPZ 归档:{reason}',
89
+ 'numpy.warning.npyHeader': 'NPY 标头无效或已截断。',
90
+ 'numpy.warning.npyVersion': '不支持 NPY 格式版本 {version}。',
91
+ 'numpy.warning.npyHeaderBounds': '声明的 NPY 标头超出文件范围。',
92
+ 'numpy.warning.npyHeaderSize': 'NPY 标头超过 {limit} 的安全限制。',
93
+ 'numpy.warning.npyHeaderDecode': '无法解码 NPY 标头文本。',
94
+ 'numpy.warning.npyHeaderFields': 'NPY 标头缺少简单 dtype、shape 或存储顺序声明。暂不解码结构化 dtype。',
95
+ 'numpy.warning.npyHeaderGrammar': 'NPY 标头包含重复字段或不支持的尾随语法。',
96
+ 'numpy.warning.npyShape': 'NPY 形状包含无效维度。',
97
+ 'numpy.warning.npyElementCount': 'NPY 元素数超出安全整数范围。',
98
+ 'numpy.warning.npyRank': 'NPY 数组维数超过 {limit} 个轴的安全限制。',
99
+ 'numpy.warning.payloadShort': '数组 payload 短于其 dtype 和 shape 所需的长度。',
100
+ 'numpy.warning.payloadTrailing': '数组 payload 包含多余字节。',
101
+ 'numpy.warning.objectUnsafe': '对象数组需要不安全的 pickle 反序列化,因此不会加载。',
102
+ 'numpy.warning.dtypeUnsupported': '不会解码 dtype {dtype} 的值,但仍可查看元数据。',
103
+ 'numpy.warning.nativeEndian': '原生端序 dtype 已按小端序解释。',
104
+ 'numpy.warning.previewDecode': '部分预览值无法解码。',
105
+ 'numpy.warning.previewLimit': '文档值预览限制为 {limit} 个元素。',
106
+ 'numpy.warning.textPreviewLimit': '字符串预览限制为每个值 {perValue} 个字符、每个文档 {total} 个字符。',
107
+ 'numpy.warning.stringItemSize': '宽度超过 {limit} 的字符串值不会被解码。',
64
108
  'gguf.title': 'GGUF', 'gguf.search': '搜索元数据和张量…', 'gguf.copyJson': '复制 JSON',
65
109
  'gguf.structure': '结构', 'gguf.noData': '没有可用数据。',
66
110
  'gguf.matchingRows': '{count} 个匹配行', 'gguf.matchingRowsLimited': '显示 {visible} / {total} 个匹配行',
@@ -153,6 +197,51 @@ export const CATALOG_ZH_CN = {
153
197
  'tflite.inspector.inputs': '输入', 'tflite.inspector.outputs': '输出',
154
198
  'tflite.inspector.intermediates': '中间张量', 'tflite.inspector.options': '选项',
155
199
  'tflite.inspector.customOptions': '自定义选项', 'tflite.inspector.subgraphs': '引用的子图',
200
+ 'keras.title': 'Keras 模型', 'keras.document.v3': 'Keras v3 压缩包', 'keras.document.hdf5': 'Keras HDF5 模型',
201
+ 'keras.version': 'Keras {version}', 'keras.search': '搜索层、权重和配置…',
202
+ 'keras.copyJson': '复制 JSON', 'keras.invalid': '无效',
203
+ 'keras.tab.layers': '层', 'keras.tab.weights': '权重', 'keras.tab.config': '配置',
204
+ 'keras.tab.training': '训练配置', 'keras.tab.files': '压缩包', 'keras.tab.model': '模型信息',
205
+ 'keras.rows': '{count} 行', 'keras.rowsLimited': '显示 {shown} / {total} 行',
206
+ 'keras.summary.layers': '层', 'keras.summary.parameters': '参数量',
207
+ 'keras.summary.weightBytes': '权重大小', 'keras.summary.kerasVersion': 'Keras 版本',
208
+ 'keras.summary.status': '状态',
209
+ 'keras.column.name': '名称', 'keras.column.type': '类型', 'keras.column.inputShape': '输入形状',
210
+ 'keras.column.activation': '激活函数', 'keras.column.parameters': '参数量',
211
+ 'keras.column.weights': '权重数', 'keras.column.trainable': '可训练', 'keras.column.layer': '层',
212
+ 'keras.column.shape': '形状', 'keras.column.dtype': '数据类型', 'keras.column.bytes': '大小',
213
+ 'keras.column.path': '路径', 'keras.column.field': '字段', 'keras.column.value': '值',
214
+ 'keras.column.size': '大小', 'keras.column.compressed': '压缩后', 'keras.column.method': '压缩方式',
215
+ 'keras.detail.identity': '标识', 'keras.detail.inbound': '输入来源',
216
+ 'keras.detail.weights': '权重', 'keras.detail.config': '配置',
217
+ 'keras.model.format': '格式', 'keras.model.class': '模型类', 'keras.model.name': '模型名称',
218
+ 'keras.model.kerasVersion': 'Keras 版本', 'keras.model.backend': '后端',
219
+ 'keras.model.dateSaved': '保存时间', 'keras.model.fileSize': '文件大小',
220
+ 'keras.model.parameters': '参数量', 'keras.model.inputs': '输入', 'keras.model.outputs': '输出',
221
+ 'keras.noData': '没有可显示的数据。', 'keras.noLayers': '未在该模型中找到层。',
222
+ 'keras.noWeights': '该文件未保存权重。',
223
+ 'keras.noConfig': '该文件不包含可读取的模型配置。',
224
+ 'keras.noTraining': '该模型保存时未包含训练配置。',
225
+ 'keras.warning.notKeras': '该文件既不是 .keras 压缩包,也不是 HDF5 模型。',
226
+ 'keras.warning.archiveUnreadable': '无法读取 .keras 压缩包的目录。',
227
+ 'keras.warning.archiveEntryLimit': '仅检查了压缩包的前 {limit} 个条目。',
228
+ 'keras.warning.memberTooLarge': '{name} 超过 {limit} 的安全上限,已跳过。',
229
+ 'keras.warning.memberUnreadable': '无法从压缩包中读取 {name}。',
230
+ 'keras.warning.memberMethod': '{name} 使用了不受支持的压缩方式 {method}。',
231
+ 'keras.warning.inflateUnavailable': '{name} 已压缩,但当前平台没有可用的解压器。',
232
+ 'keras.warning.jsonInvalid': '{name} 不是有效的 JSON。',
233
+ 'keras.warning.configMissing': '压缩包中没有 config.json,因此无法显示层列表。',
234
+ 'keras.warning.configMissingHdf5': '文件没有 model_config 属性,可能是仅包含权重的检查点。',
235
+ 'keras.warning.configUnreadable': '无法解码 model_config 属性。',
236
+ 'keras.warning.configTruncated': '配置预览已截断至 {limit} 个字符。',
237
+ 'keras.warning.weightsMissing': '未找到权重存储,因此无法统计参数量。',
238
+ 'keras.warning.weightsUnreadable': '权重存储不是可读取的 HDF5 文件。',
239
+ 'keras.warning.weightLimit': '仅读取了前 {limit} 个权重。',
240
+ 'keras.warning.layerLimit': '仅读取了前 {limit} 个层。',
241
+ 'keras.warning.noLayers': '配置中未声明任何层。',
242
+ 'keras.warning.unmatchedWeights': '“{layer}”的权重在配置中没有对应的层。',
243
+ 'keras.warning.unmatchedWeightsMore': '另有 {count} 个权重组没有对应的层。',
244
+ 'keras.warning.structureTruncated': 'HDF5 结构超出检查上限,仅读取了一部分。',
156
245
  'proto.title': 'Protocol Buffer', 'proto.summary': '{syntax} · {package} · {messages} 条消息 · {services} 个服务',
157
246
  'proto.noPackage': '无软件包', 'proto.search': '搜索消息、字段、枚举或 RPC', 'proto.copyPanel': '复制面板',
158
247
  'proto.panel.tree': '消息树', 'proto.panel.types': '类型', 'proto.panel.relationships': '关系',
@@ -16,6 +16,42 @@ export interface Hdf5Document {
16
16
  rawPreview?: string | undefined;
17
17
  warnings: string[];
18
18
  }
19
+ /**
20
+ * One decoded attribute of a group or dataset.
21
+ *
22
+ * Attributes are where format-specific metadata lives (Keras keeps its model
23
+ * config and layer names there), so string and fixed-width numeric values are
24
+ * decoded; anything else is reported by datatype only, with `values` empty.
25
+ */
26
+ export interface Hdf5Attribute {
27
+ name: string;
28
+ /** Datatype class name — 'String', 'Integer', 'Float', … */
29
+ type: string;
30
+ /** Dataspace dimensions; empty for a scalar attribute. */
31
+ shape: number[];
32
+ values: Array<string | number>;
33
+ /** true when the datatype is not decoded, or a budget stopped decoding. */
34
+ truncated: boolean;
35
+ }
36
+ /** A group or dataset with its attributes, for format-specific readers. */
37
+ export interface Hdf5Object {
38
+ path: string;
39
+ kind: EntryKind;
40
+ /** Human-readable dimensions ('3 × 4', 'scalar'). */
41
+ shape: string;
42
+ /** Numeric dimensions when the dataspace was decoded. */
43
+ dimensions: number[];
44
+ type: string;
45
+ elementSize: number;
46
+ attributes: Hdf5Attribute[];
47
+ }
48
+ export interface Hdf5ObjectTree {
49
+ objects: Hdf5Object[];
50
+ warnings: string[];
51
+ /** true when an inspection limit stopped the traversal early. */
52
+ truncated: boolean;
53
+ }
54
+ export type EntryKind = 'Group' | 'Dataset' | 'Unknown';
19
55
  /** Random-access view over the bytes of an HDF5 file. */
20
56
  export interface Hdf5Reader {
21
57
  readonly size: number;
@@ -37,13 +73,30 @@ export declare class Hdf5Parser {
37
73
  private readonly warnings;
38
74
  private superblock;
39
75
  private nodeBudget;
76
+ private entryLimit;
40
77
  private truncated;
78
+ /** Attribute decoding is opt-in: the document view never shows attributes,
79
+ * and skipping them keeps the common traversal free of global-heap reads. */
80
+ private readAttributes;
81
+ private attributeByteBudget;
82
+ private readonly globalHeaps;
83
+ private denseAttributesReported;
84
+ private readonly attributesByHeader;
85
+ private attributeCount;
41
86
  private constructor();
42
87
  /** Parses HDF5 metadata through a random-access reader without reading dataset payloads. */
43
88
  static parseReader(reader: Hdf5Reader, fileSize?: string): Hdf5Document;
44
89
  /** Parses an in-memory HDF5 byte array. */
45
90
  static parse(buffer: Uint8Array, fileSize?: string): Hdf5Document;
91
+ /**
92
+ * Walks the object hierarchy and returns every group and dataset together
93
+ * with its decoded attributes, for readers of formats that store their
94
+ * metadata in HDF5 attributes (Keras). Dataset payloads are still not read.
95
+ */
96
+ static readObjects(reader: Hdf5Reader): Hdf5ObjectTree;
46
97
  private build;
98
+ /** Locates the superblock and traverses the object hierarchy from the root. */
99
+ private walk;
47
100
  private toModel;
48
101
  private headerPreviewTable;
49
102
  private buildTreePreview;
@@ -62,8 +115,48 @@ export declare class Hdf5Parser {
62
115
  private readLocalHeapDataStart;
63
116
  private decodeLinkMessage;
64
117
  private describeDataspace;
118
+ /** Numeric dimensions of a dataspace message; empty for a scalar. */
119
+ private dataspaceDimensions;
120
+ /** Decoded attributes of an object header, shared across links to it. */
121
+ private attributesFor;
122
+ private decodeAttributes;
123
+ /**
124
+ * An Attribute Info message points at the fractal heap holding an object's
125
+ * attributes once they no longer fit in the object header: version(1),
126
+ * flags(1), [maximum creation index(2) when flags bit 0 is set], then the
127
+ * heap address. An undefined heap address means the attributes are still
128
+ * stored compactly in the header.
129
+ */
130
+ private hasDenseAttributes;
131
+ /**
132
+ * Attribute message layout (versions 1-3). Version 1 pads the name,
133
+ * datatype, and dataspace sections to 8-byte boundaries; versions 2 and 3
134
+ * store them back to back, and version 3 adds a name character set byte.
135
+ * Shared datatype/dataspace messages (version 2+ flags) are not followed.
136
+ */
137
+ private decodeAttribute;
138
+ private decodeAttributeValues;
139
+ /**
140
+ * Reads one object out of a global heap collection ('GCOL'), where
141
+ * variable-length values keep their payload.
142
+ *
143
+ * A collection packs thousands of objects, and every value of an attribute
144
+ * usually lands in the same one, so the object offsets are indexed on first
145
+ * use. Rescanning per lookup would make reading n values cost O(n²) — a few
146
+ * hundred thousand strings took tens of seconds before this cache.
147
+ */
148
+ private readGlobalHeapObject;
149
+ /** Object offsets of one global heap collection, built once per address. */
150
+ private globalHeapIndex;
151
+ private readGlobalHeapIndex;
65
152
  private describeDatatype;
66
153
  private datatypeSize;
154
+ /**
155
+ * Reads a null-terminated name out of a local heap. Names are usually short,
156
+ * so the heap is read a window at a time and only grows for the rare long
157
+ * one — a fixed window would silently truncate the name, and a truncated
158
+ * name becomes a wrong object path rather than a visible failure.
159
+ */
67
160
  private readHeapString;
68
161
  private matchesAscii;
69
162
  private resolve;
@@ -73,3 +166,8 @@ export declare class Hdf5Parser {
73
166
  export declare function formatFileSize(bytes: number): string;
74
167
  /** Convenience function for adapters and the built-in viewer. */
75
168
  export declare function parseHdf5(input: Uint8Array, fileSize?: string): Hdf5Document;
169
+ /**
170
+ * Groups, datasets, and attributes of an in-memory HDF5 file — the entry point
171
+ * for parsers of formats layered on HDF5 (Keras `.h5`, `.keras` weights).
172
+ */
173
+ export declare function readHdf5Objects(input: Uint8Array | Hdf5Reader): Hdf5ObjectTree;