Metero NetCDF Viewer
Explore NetCDF data in the main VS Code editor area, with a persistent NC status-bar launcher.
- Click NC in the status bar to open the viewer. Click it again, close its editor tab, or use 收起到状态栏 to collapse it. Reopen to restore the session's open files and preview.
- Open multiple
.nc, .nc4, or .cdf files, including NetCDF-3 and NetCDF-4/HDF5 containers readable by netCDF4.
- Browse data variables, dimensions and original file/variable attributes. Coordinate variables are excluded from the data-variable list.
- Select multidimensional slices and spatial index/coordinate ranges. Time controls show the source values and units.
- Zoom around the mouse pointer with the wheel, drag to pan, and fit/reset the preview. NoData is transparent.
- Time-range averaging uses the bundled Klimapy.
Bundled Python / 开箱即用
Version 0.2.0 ships platform-specific packages with Python 3.12.16, NumPy, netCDF4, cftime and Klimapy 1.2.1. No system Python, pip install or network connection is required for single-time reading. Time averaging is bundled on Linux x64, Windows x64 and Apple Silicon. Marketplace selects the package for the extension host automatically.
| Extension host |
Package |
Minimum system |
| Linux x64 |
linux-x64 |
glibc 2.28+ (not Alpine/musl) |
| Windows x64 |
win32-x64 |
Windows 10/11 |
| macOS Intel |
darwin-x64 |
macOS 14+ |
| macOS Apple Silicon |
darwin-arm64 |
macOS 14+ |
Linux ARM, Windows ARM and browser-based VS Code are not supported by these packages. For Remote SSH, the remote host determines the package and accesses the files. The Metero desktop application is not required.
Intel Mac limitation: the upstream Klimapy 1.2.1 wheel is labelled universal2 but contains an ARM64 native library. Single-time visualization works with bundled Python/netCDF4; time averaging requires an Intel-compatible Klimapy interpreter selected via meteroNc.pythonPath. The Intel package detects this and explains the limitation instead of loading the wrong binary.
The Linux bundle is tested in an isolated Python process and the official VS Code extension host. Windows and macOS packages contain their native CPython distributions and compatible binary wheels; native execution on those systems has not yet been verified here.
读取环境 provides advanced interpreter selection or manual environment setup. meteroNc.pythonPath overrides the bundled interpreter. Leave it empty for the bundled reader. Setup actions download packages only when explicitly selected.
Built-in color maps
Ten local 256-color maps: Viridis, Plasma, Inferno, Magma, Cividis, Turbo, Coolwarm, RdBu_r, Spectral_r and Gray. Change the color-map selector above the preview; the legend updates immediately without rereading the file. No online palette service or Matplotlib installation is needed.
Usage / 使用
点击状态栏 NC,在主编辑区打开查看器。点击“打开 NC 文件”,选择左侧变量,再设置时间和空间范围,点击“预览切片”。右键文件或变量查看属性。支持多个文件,不占用侧栏或底部终端面板。
关闭编辑标签、再次点击状态栏 NC 或点击“收起到状态栏”可收起;在同一个 VS Code 会话内再次打开会恢复文件与已生成的预览。重载 VS Code 后不会自动重新读取先前的文件。
Explorer also provides Metero NetCDF: Open NetCDF File… on NC files. Commands are available in the Command Palette.
Limits and privacy
- This is a sampled numerical grid preview (up to 160 × 160), not a geographic map or full-resolution raster editor. Zoom enlarges the preview, not the on-disk data.
- Time means weight finite timesteps equally using Klimapy, not equal-weight annual means.
- This first release browses root-level variables; nested NetCDF groups, map reprojection, WRF management and the Metero desktop terminal are not included.
- Read-only: source data is never modified. No file contents are uploaded, no telemetry, and no network is needed for the bundled reader.
- Requires a trusted workspace because a Python subprocess is used. No arbitrary filesystem paths are accepted from webview messages; files are authorized through the native file picker/Explorer command.
- Native verification status and supported architectures are listed above.
Settings
| Setting |
Purpose |
meteroNc.showStatusBar |
Show/hide the NC status-bar entry (default: true). |
meteroNc.pythonPath |
Optional Python override; empty uses the bundled interpreter. |
Development
npm ci
npm run check
python -m unittest discover -s test -p 'test_*.py' -v
python tools/bundle-runtime.py
node tools/package-platforms.cjs
The extension bundles its JavaScript UI, a Python reader and the target platform’s Python environment. Runtime archives are SHA256-verified; each package includes runtime/target/manifest.json with provenance and wheel hashes. It contains no embedded account credentials, scientific data or unrelated Metero modules.