HDFStudio Help / 使用帮助

0.16.02 · NetCDF / HDF5 / GRIB1 / GRIB2 · Windows

Unleash the Power of Your NetCDF and GRIB Data

🌐 0.16.02 Icosahedral Analysis / 二十面体分析

变量右键选择 Visual Analysis / 可视分析 → Icosahedral 5 slices,默认显示五条展开带,可切换五张矩形卡和 OpenGL 3D。支持全球或局地真实经纬轴,局地范围外为NaN;复用同变量Image的当前层/Mask,未打开Image时直接读取。L0–L6生成单位球节点、面、边与面积;Run应用Mask或源修改。层工具栏支持切层、Play/Pause和间隔,等待源、分析和显示帧完成,换帧保留上一图但禁用旧值导出/拾取,末帧停止;单时次禁用Play。五卡张量为[5,n,2n],两个Apex顶点另存,当前方向下不是地理南北极;滚轮缩放、拖动平移、双击/Fit复位,PNG输出完整五卡及色标。3D复用原工程GL 3.3 Core画布,支持球面/多面体连续变形、旋转、平移缩放、主棱/细网格/五卡接缝/参考线、转台和地理预设,PNG导出实际帧缓冲。面积、还原、误差和S2S色标共用同一结果;默认Unlit保留亮度。点插值不声称守恒,GL不可用时仍可运行2D/数值分析。

要求已验证的纬度/全球周期经度轴,纬度可非等距/降序;不推断未知坐标。精确等距经度使用现成C核双线性点采样,可信周期的编码舍入或非等距经度使用保留实际中心的适配;再作重心还原。纬度范围外、缺测与Mask传播为NaN。面值为顶点均值,不声明单元平均或质量守恒。面积为steradian,不是平方米。改变源层、Mask或级别后须重新Run。

Export mesh + fields NetCDF导出0基节点/面/边拓扑、邻接、单位球xyz、原单位点值、正向CSR权重、源坐标、还原及残差,供全球图模型数据试验;PNG导出当前图和色标。仅创建新文件并保护源数据。

Level / 精度: 调整L0–L6即自动重算,连续调整采用最后精度,无需再点Run。计算期间保留上一图,可切换2D/3D;旧值探针与导出暂时禁用。Level changes automatically recompute the last selected resolution while keeping the previous frame visible; stale probes and exports remain disabled until the new result is current.

English: Right-click a variable → Visual Analysis → Icosahedral 5 slices. Start with five unfolded strips or switch to five rectangular node cards and the OpenGL 3D sphere/polyhedron. Reuse the same variable's open Image layer/Mask or read it directly; regional exterior stays NaN. Layer playback waits for source, analysis and rendering, and stops at the last layer. Run applies source/Mask changes. Inspect unit-sphere areas, reconstructed source grids and errors; export full-layout/framebuffer PNG or graph topology, chart tensors, node/edge/face point fields, CSR weights and diagnostics in NetCDF. Five slices are a layout of one layer, not five vertical levels. Point interpolation is not conservative cell averaging. New palettes are original sRGB controls without physical thresholds or a perceptual-uniformity claim.

hdf_cli ico-demo new_mesh.nc 3
hdf_cli ico input.nc /temperature new_analysis.nc 3 0

常用功能

从程序的 Help → Help(About 前)或 F1 打开本页。也可以直接双击 doc/help.html;全部内容可离线阅读。

1. 打开文件与查看属性

选择 File → Open,或把文件拖到窗口中。可同时打开 NetCDF-3、NetCDF-4、HDF5、GRIB1 和 GRIB2;程序按文件内容识别格式。展开左侧树,右键文件或变量选择 Properties... 查看属性,可用 Copy All 复制报告。

用 File → Close File 关闭当前文件及关联视图;Close All Files 关闭所有文件。Window → Tile 可平铺视图,Hide Infobar 勾选时隐藏底部信息栏,再点一次恢复。

0.14.08 文件查找:File → Find files... 在指定目录按文件名查找;C7F 按包含匹配,*C7F*、*.grib2 使用通配符,不区分大小写,包含无扩展名文件,默认包含子目录。结果可打开、复制路径或定位目录。扫描不读取科学内容;停止、访问错误及10000条匹配/1000000条目录项限制会明确提示结果不完整。

Find variables... 在当前已打开文件按变量名、路径、long_name/standard_name/描述或GRIB参数ID查找;可见顶部当前文件。勾选 Exact name / path / ID 后,t 不会混入 ta。选结果定位原树节点,Image / Table / Properties 沿用原功能限制。变量目录包含折叠组,GRIB显示各变量真实场数量;层次和成员继续由原控件选择。

🌍 0.14.08 Map projection: Image顶部浅蓝投影栏只占一行,可选经纬度、北/南极极射赤面、东亚Lambert和Mercator,选择即重绘并保存,无需点击OK;状态长文可悬停查看。Options…详细设置立即更新图像,OK只确认详细选项并关闭,Cancel/Esc/右上角关闭撤销本次预览。已确认偏好保存到HDFStudio.exe同目录HDFStudio.ini,下次自动恢复。接收已验证的一维NC经纬轴、可分离GRIB regular_ll和完整矩形高斯网格regular_gg,保留实际非等距高斯纬度和经验证的全球周期。已有有效球体/椭球时使用当前源模型,未声明时明确标记单位球面显示,不提供物理距离/面积,非法或冲突模型仍拒绝。默认叠加可开关的Basemap低精度参考岸线。地图文字采用按背景明暗选色的实心字,无底框、无描边并避让相邻标签。Fit、缩放和平移作用于独立地图视口;探针报告同一像素的源行列和值、Mask或缺测。Play等待新投影完成后切帧,期间保留上一完整地图及色标并禁用旧探针。地图期间Flip禁用;Profile保持可点,点击自动返回Source grid,按原格点选线、拖动和显示曲线。原统计、CSV和PNG继续使用原格点;岸线仅作角度对齐参考,不进行datum转换或海陆Mask。运行离线,不依赖Python/Basemap。

2. 浏览 GRIB1 / GRIB2

打开后等待索引完成。Variables 将兼容场组织为可逐层浏览的虚拟变量;Messages 分页保留原始消息与子场。双击支持矩形图像的变量或场,优先打开 Image View;结构节点或不支持图像的项目仍显示 Properties。右键变量或场,可打开表格、图像、直方图或纹理熵图;Properties 保留参数、层次、时间相关原始键与来源信息。

矩形网格支持图像及相关分析。GRIB 表格提供解码值、Quantized X 及并排模式;Quantized X 是支持的打包方式下重建的量化整数,并非原始字节,不可用时明确显示。缺场会清空旧结果,未知名称/单位保留 unknown。

GRIB 保留源格点数值,符合条件的 regular_ll/regular_gg 可切换地图显示。比较与播放按整数索引推进,不自动匹配物理时间、转换单位或科学重采样。GRIB 任意两轴剖面已接入 GUI 和 CLI/worker;剖面地理坐标及 U/V 矢量入口尚未接通。CF 检查不适用于 GRIB。

3. 数值表格

右键变量选择 Data Grid。NetCDF/HDF5 可选解码值、存储值或并排表格;GRIB 使用上面的解码/量化模式。用顶部维度和层号控件切换高维数据。Auto-fit columns 自动调整列宽,关闭后可手动拖动。

单击或拖动选择单元格,Ctrl/Shift 调整选区,Ctrl+C 复制到电子表格。复制有大小上限,大表请分块选择或使用相应导出功能。

4. 图像、色表与 Mask

新图像、时空剖面和纹理熵图缺省使用 Jet 光谱配色;CMaps 中也可选择 Rainbow、Viridis 等原有色表。残差图保留以零为中心的发散色表。

右键变量选择 Image View,用 CMaps 切换科学色表。滚轮或放大/缩小按钮调整视图;Fit 显示完整图像,Reset 恢复初始方向和适配大小。色表和显示范围的变化复用当前解码数据。

Mask Range 按解码后的数值排除闭区间:起点或终点留空代表无下限或无上限。Mask 影响图像及跟随它的分析。未声明的特殊数字不会自动当作缺测,使用前请确认数据含义。

5. 直方图、曲线、熵与比较

功能常用操作
Histogram...右键变量打开。Sample 1 in N 缺省为 20;设为 1 使用全部有限值。调整分箱或重新抽样复用已读平面。
曲线剖面在 Image View 中使用曲线工具选择折线/样条路径,查看沿线采样并导出 CSV。GRIB 使用网格索引空间。
Texture Entropy Image查看局部 4×4 灰度分布复杂度,色标为 0–4 bits。可独立打开,或从图像打开并跟随其层号和 Mask。
Compare & Metrics打开两个图像,在工具栏或 Window 菜单打开比较面板。选择 Anchor/Target 和整数 lag,查看 Pearson r、RMSE、MAE、Bias。
Residual map在比较面板打开 Target − Anchor 残差图,用以定位差异,可导出 PNG。

比较要求平面形状相同,仅统计两图都有效的像元;请自行确认时间、网格和单位可比较。高熵也可能来自噪声,不能单凭熵判断预报信号。

6. 逐层与联动播放

激活图像或表格,选择有多层的维度,点击绿色 Play / Pause。Frame interval 为显示间隔,缺省 500 ms;播放等待当前读取/渲染完成,到末层停止。少于两帧时禁用播放。

联动播放先在 Compare & Metrics 选择 Anchor/Target 并启用 Sync layer indices,再设各 Target 的 lag。目标索引为 Anchor 索引加 lag;缺场或越界时清空结果,恢复有效索引后重新计算。

7. NetCDF / HDF5 / GRIB 时空剖面

选择数值变量后用 View → Space-Time Section (Hovmöller),选两条显示轴并固定其他维度。支持交换轴、翻转、Mask、PNG/CSV 导出;剩余固定轴有多层时可播放。可信一维坐标存在时提供 Lat–Time/Lon–Time 预设;通用 HDF5 保持索引含义。

GRIB 通过相同菜单或变量右键入口打开。Grid Y–Time index / Time index–Grid X 预设保留源网格索引与原始起报/时效标签,不推断经纬度或经过时长;可选择任意有序两轴,缺场保留缺测。

Fit 将两条显示轴独立拉伸并平滑插值,短剖面也铺满绘图区。探针、CSV 与原分辨率 PNG 保留原采样;不重采样不均匀物理坐标。请保留同目录的 hdf_cli.exe,它承担独立进程读取。

8. 导出与常见提示

  • 导出:使用对应视图的 PNG、CSV 或文本导出。图像 PNG 按数据分辨率输出当前色表、Mask 与翻转结果,不是窗口截图;不要选择源文件作为输出。
  • Python:基本浏览与原生分析无需 Python。By NetCDF4、CF Check 和可选日期标签需配置 Python 及相应的 netCDF4 / numpy / compliance-checker 模块;可用 HDFSTUDIO_PYTHON 指定解释器。
  • 读不出数据:查看 Properties 与错误信息,区分不支持的网格/打包、缺场、文件变化和内存限制。CF 诊断仅供参考,不是完整合规认证。
  • 帮助页打不开:确认 doc/help.html 位于程序旁的 doc 文件夹中,并设置可用的默认浏览器。

9. 为 LLM 和 AI Agent 提取数据上下文

HDFStudio 是对现代 LLM 和 AI Agent 友好的数据检查工具:把 NetCDF、HDF5、GRIB 中的结构、属性和选定数值转成模型可参考的文本,帮助其快速了解数据特点,并据此辅助编写读取、绘图或分析代码。以下流程通过复制报告或调用 CLI 交接信息。

  1. 先给结构:打开文件,右键文件或变量选择 Properties → Copy All。报告可提供对象路径、维度、shape、类型、属性及格式相关信息。
  2. 再给语义:重点保留单位、坐标和时间原文、calendar、填充值与打包参数。对 GRIB 保留场/对象 ID、参数与中心来源、层次、参考时间、step 及网格相关键;缺少或 unknown 的项目明确标出。
  3. 按问题补数值:复制少量有代表性的表格单元格,或导出指定层 CSV。说明选了哪些零基索引、数值是 decoded / stored / Quantized X、是否使用 Mask,并提供最小值、最大值或缺测统计。
  4. 让 Agent 调用 CLI:使用明确的文件路径和对象 ID,读取 stdout、stderr 与退出码。先运行 probe / info,再用 props 查看目标,必要时导出单个平面。核对实际输出后再生成后续分析代码。
hdf_cli probe "data.grib2"
hdf_cli info "data.grib2"
hdf_cli props "data.grib2" /field/0
hdf_cli csv "data.grib2" /field/0 "plane.csv"
hdf_cli props "data.nc" /temperature

文件名与对象 ID 请替换为实际值。高维变量导出需追加对应的前导维度索引;GRIB 多轴虚拟变量可先查看 info,再查看具体 /field/N 的 Properties。需要剖面时使用 hdf_cli slice FILE OBJECT ROW_AXIS COL_AXIS OUTPUT.csv FIXED_IDX_0 ... FIXED_IDX_N-1,为每一维提供索引,两条显示轴位置填 0。

可复制的提问模板:

任务:请依据下面的实际报告,说明如何读取并绘制这个变量。
数据:文件格式、对象路径/ID、shape、维度顺序。
元信息:[粘贴 Properties / CLI 输出,保留原始单位与时间键]
数值样例:[附少量 CSV 行,说明层索引、解码模式与 Mask]
请先总结已确认的数据特点,再列出报告中缺少的信息。
坐标、时间或单位无法确认时请明确说明;GRIB Quantized X 不是物理值。
给出代码时遵循报告中的维度与缺测语义,并提供可核对的 shape、极值和缺测数。

报告为模型提供依据,结论仍需与实际文件和导出值核对。源索引不自动等于地理坐标,GRIB 时间键不自动等于已验证的有效时间,unknown 单位不应猜测。向外部模型分享报告前,可按需要去除本地路径等非必要信息。

返回顶部 · English guide

Everyday tasks

Open this page with Help → Help (before About) or F1. You can also open doc/help.html directly. All content is available offline.

1. Open files and inspect metadata

Choose File → Open or drop files onto the window. Open NetCDF-3, NetCDF-4, HDF5, GRIB1 and GRIB2 together; format detection uses file content. Expand the tree and right-click a file or variable for Properties.... Copy All copies the report.

File → Close File closes a source and its views; Close All Files closes all sources. Use Window → Tile for side-by-side views. Hide Infobar hides the bottom information panel when checked; click again to restore it.

File search in 0.14.08: File → Find files... searches names in a directory. C7F uses substring matching; *C7F* and *.grib2 use wildcards. Matching ignores case, includes extensionless files and searches subdirectories by default. Open a result, copy its path or show it in the file manager. Search does not read scientific contents; cancellation, access errors and limits of 10,000 matches / 1,000,000 directory entries are reported as incomplete.

Find variables... searches names, paths, long_name/standard_name/descriptions and GRIB parameter IDs in the current open file shown above the results. With Exact name / path / ID, t excludes ta. Select a row to locate the existing tree node; Image / Table / Properties retain their original restrictions. Collapsed groups are included and GRIB results show actual source-field counts. Layers and members use existing controls.

🌍 Map projection in 0.14.08: The single-row blue bar above Image redraws and saves longitude/latitude, North/South Polar Stereographic, East Asia Lambert or Mercator as soon as it is selected; no OK click is needed. Hover over shortened status text for details. Options… updates the image live; OK only confirms detailed options and closes, while Cancel/Esc/window close undoes that preview. Confirmed preferences are stored beside HDFStudio.exe in HDFStudio.ini and restored next time. Verified one-dimensional NetCDF axes, separable GRIB regular_ll and rectangular Gaussian regular_gg grids are supported, preserving actual nonuniform Gaussian latitudes and verified global wrapping. Declared valid Earth models are retained; missing models use explicitly labelled unit-sphere display without physical distances or areas. Invalid or conflicting models still reject. Optional offline Basemap low-resolution reference coastlines are enabled by default. Solid map labels adapt to background brightness, without boxes or outlines; neighbouring labels avoid overlap. Fit, zoom and pan control a separate map viewport; probes report the same pixel's source row/column and value, Mask or missing state. Play waits for each projected frame, retaining the previous complete map and colour scale with old probes disabled until replacement. Flip is disabled in map mode; Profile remains available and returns to Source grid for source-index point selection, dragging and curve display. Statistics, CSV and PNG retain the original grid. Coastlines are an angular reference without datum transformation or land/sea masking. Runtime needs no Python/Basemap.

2. Browse GRIB1 / GRIB2

Wait for indexing to finish. Variables groups compatible fields into virtual arrays with layer navigation. Messages preserves paged physical messages and sub-fields. Double-click a variable or field supporting rectangular images to open Image View first; structural or unsupported entries still show Properties. Right-click a variable or field for tables, images, histograms or texture entropy. Properties retains parameter, level, raw time-related keys and provenance.

Rectangular grids support images and related analyses. GRIB tables offer decoded values, Quantized X and paired modes. Quantized X is a reconstructed integer for supported packing, not a raw-byte dump; unsupported reconstruction is marked unavailable. Missing fields clear old results; unknown names/units stay unknown.

GRIB retains source-grid values; eligible regular_ll/regular_gg grids can use map display. Comparison and playback use integer indices without automatic physical-time matching, unit conversion or scientific resampling. Arbitrary-axis GRIB sections are available through the GUI and CLI/worker; section geographic coordinates and U/V vector integration remain pending. CF checks do not apply to GRIB.

3. Read and copy table values

Right-click a variable for Data Grid. NetCDF/HDF5 offers decoded, stored or paired tables; GRIB uses the decoded/quantized modes above. Choose a dimension and layer in the main toolbar. Auto-fit columns sizes columns automatically; disable it for manual widths.

Click or drag to select cells, refine with Ctrl/Shift, then use Ctrl+C to paste into a spreadsheet. Copying has size limits; select smaller blocks or use the view's export action for larger data.

4. Images, colors and Mask

New images, Space-Time Sections and texture entropy images default to the Jet spectrum palette. CMaps also offers Rainbow and the existing scientific palettes. Residuals retain a zero-centered diverging palette.

Right-click a variable for Image View. Choose a scientific palette in CMaps. Zoom with the wheel or zoom buttons; Fit shows the full image and Reset restores orientation and fit. Color and range changes reuse the decoded plane.

Mask Range excludes an inclusive interval of decoded values. A blank start or end means no lower or upper bound. Mask affects the image and analyses following it. Undeclared special values are not inferred as missing; confirm their meaning first.

5. Histograms, curves, entropy and comparison

ToolTypical use
Histogram...Right-click a variable. Sample 1 in N defaults to 20; use 1 for all finite values. Bins and resampling reuse the cached plane.
Curve profileUse the Image View curve tools to draw a polyline/spline, inspect samples and export CSV. GRIB curves use grid-index space.
Texture Entropy ImageInspect local 4×4 gray-distribution complexity on a 0–4 bits scale. Open independently or from an image to follow its layer and Mask.
Compare & MetricsOpen two images and use the toolbar or Window menu. Choose Anchor/Target and an integer lag to inspect Pearson r, RMSE, MAE and Bias.
Residual mapOpen the Target − Anchor map from the comparison panel to locate differences; export PNG when needed.

Comparison requires identical plane shapes and uses pixels valid in both images. Confirm compatible times, grids and units yourself. High entropy can also be noise; it is not evidence of forecast skill.

6. Layer and linked playback

Activate an image or table, choose a multi-layer axis, then press the green Play / Pause button. Frame interval is a display delay (default 500 ms). Playback waits for each read/render and stops at the last layer. Fewer than two frames disables Play.

For linked playback, select Anchor/Target in Compare & Metrics, enable Sync layer indices and set each Target's lag. Target index equals Anchor index plus lag. Missing or out-of-range fields clear results; valid indices restore calculations.

7. NetCDF / HDF5 / GRIB space-time sections

Select a numeric variable and choose View → Space-Time Section (Hovmöller). Select two display axes and fix the others. Swap axes, flip, Mask and export PNG/CSV; play a remaining fixed axis with multiple layers. Trusted 1D coordinates enable Lat–Time/Lon–Time presets; generic HDF5 retains index semantics.

For GRIB, use the same menu or right-click entry. Grid Y–Time index and Time index–Grid X retain source-grid spacing and original reference/step labels, without inferring latitude, longitude or elapsed time. Any ordered pair of axes is available; missing fields remain missing.

Fit stretches each display axis independently to fill the plot with smooth interpolation, including short sections. Probes, CSV and native-resolution PNG retain the original samples. Nonuniform physical coordinates are not resampled. Keep the matching hdf_cli.exe beside the application for separate-process reads.

8. Export and common tips

  • Export: use the view's PNG, CSV or text actions. Image PNGs contain data-resolution pixels with current colors, Mask and flips, rather than a window screenshot. Choose a destination distinct from the source.
  • Python: basic browsing and native analysis need no Python. By NetCDF4, CF Check and optional date labels need Python and the corresponding netCDF4 / numpy / compliance-checker modules. Set HDFSTUDIO_PYTHON to choose an interpreter.
  • Read errors: inspect Properties and the error text for unsupported grids/packing, missing fields, changed sources or memory limits. CF diagnostics are advisory, not full certification.
  • Help will not open: keep doc/help.html in the doc folder beside the executable and configure an available default browser.

9. Extract context for LLMs and AI agents

HDFStudio is friendly to modern LLMs and AI agents: it turns NetCDF, HDF5 and GRIB structure, attributes and selected values into reference text. This helps a model understand the data quickly and assist with reading, plotting or analysis code. Share information by copying reports or invoking the CLI.

  1. Start with structure: open a file, right-click a file or variable, then use Properties → Copy All. Reports provide object paths, dimensions, shape, types, attributes and format-specific information.
  2. Keep semantics: retain original units, coordinate/time metadata, calendar, missing-value and packing attributes. For GRIB include field/object IDs, parameter and centre provenance, levels, reference time, step and grid keys. Mark missing or unknown items explicitly.
  3. Add relevant values: copy representative table cells or export a selected plane to CSV. Identify zero-based indices, decoded / stored / Quantized X mode, Mask settings and available range or missing-value statistics.
  4. Let an agent use the CLI: pass explicit file paths and object IDs; capture stdout, stderr and the exit code. Start with probe / info, inspect the target with props, then export a plane if needed. Check actual output before generating further analysis code.
hdf_cli probe "data.grib2"
hdf_cli info "data.grib2"
hdf_cli props "data.grib2" /field/0
hdf_cli csv "data.grib2" /field/0 "plane.csv"
hdf_cli props "data.nc" /temperature

Replace the example paths/IDs with actual ones. Higher-dimensional plane exports require the corresponding leading-axis indices. For multi-axis GRIB virtual arrays, inspect info first, then use a concrete /field/N for Properties. Section syntax is hdf_cli slice FILE OBJECT ROW_AXIS COL_AXIS OUTPUT.csv FIXED_IDX_0 ... FIXED_IDX_N-1; supply an index for every dimension, with 0 in the two display-axis positions.

Example prompt:

Task: explain how to read and plot this variable using the actual reports below.
Data: file format, object path/ID, shape and dimension order.
Metadata: [paste Properties / CLI output; retain original units and time keys]
Values: [include a few CSV rows, layer indices, decode mode and Mask settings]
First summarize confirmed data characteristics, then identify missing information.
State when coordinates, time or units cannot be verified. GRIB Quantized X is not a physical value.
Use the reported dimension and missing-value semantics in code, with checks for shape, extrema and missing counts.

Reports ground a model's answer; verify conclusions against the file and exported values. Source indices do not establish geographic coordinates, raw GRIB time keys do not establish verified valid times, and unknown units should stay unknown. Remove unnecessary local-path information when sharing externally if appropriate.

Back to top · 简体中文