Codync
免費、開源的 1:1 替代方案,取代 Grok Bot 與 Muse。從 iPhone、Mac 或 Linux 桌面將 Claude Code、Codex、Cursor 與 40+ 程式碼代理人作為持續機器人傳訊。群組聊天、主題串…
AI 翻譯
個人 GitHub 帳號下公開儲存庫的擁有者可以登入並驗證所有權,自行管理介紹,無需管理員核准。
登入並產生驗證檔案,在 30 分鐘內將其提交至此儲存庫的預設分支。其他分支或分叉儲存庫中的檔案無效。然後在下方檢查檔案,即可無需管理員核准直接管理專案。請保留檔案以維持管理權限。
如需登入,將前往登入頁面。登入後請回到此處,再次點擊所選的驗證按鈕。
在專案資料夾中執行 /nomorevibe verify,即可驗證所有權並自行管理介紹。
一分鐘完成驗證製作者的介紹僅有上面的一句話。 更多詳情請閱讀儲存庫 README。 儲存庫 README ↗
正在載入完整 README。
檢視完整 README ↗Write GDAL multidimensional VRT from xarray Datasets and STAC catalogues. Pure Python: no GDAL needed to write.
Documentation: https://hypertidy.github.io/xvrt/
A multidimensional VRT is a small XML file that describes a collection of files as one n-dimensional dataset: which file supplies which slab of which array, plus dimensions, coordinates, CRS, units and packing. It holds no data. Any reader of GDAL's multidimensional API opens the whole collection as a single cube and reads only the files a request touches.
pip install xvrt
pip install "xvrt[stac]" # adds pyarrow and pyproj for from_stac()
Reading the result needs GDAL 3.x with multidimensional support (for example GDAL's Python bindings from conda-forge).
Open files the way you normally would, then describe the result:
import glob
import xarray as xr
from xvrt import write_mdim_vrt
paths = sorted(glob.glob("oisst-avhrr-v02r01.*.nc")) # one day per file
ds = xr.open_mfdataset(paths, combine="nested", concat_dim="time")
write_mdim_vrt(ds, paths, "oisst.vrt", composition="concat", concat_dim="time")
The same works over HTTP. Ten monthly files of one variable from a THREDDS
server (URLs become /vsicurl/ sources):
PREFIX = "https://thredds.nci.org.au/thredds/fileServer/gb6/BRAN/BRAN2020/daily"
months = [f"2010_{m:02d}" for m in range(1, 11)]
paths = [f"{PREFIX}/ocean_temp_{ym}.nc" for ym in months]
ds = xr.open_mfdataset(paths, engine="h5netcdf")
write_mdim_vrt(ds[["temp"]], paths, "bran.vrt",
composition="concat", concat_dim="Time")
from_stac() builds the VRT from catalogue fields alone (grid, CRS, item
datetimes, per-asset band storage) without opening a file:
from xvrt import from_stac
from_stac("https://data.source.coop/ausantarctic/ghrsst-mur-v2/ghrsst-mur-v2.parquet",
"mur.vrt", block_size=[1, 512, 512])
For the GHRSST MUR collection that is five arrays over 8913 days in a few seconds.
concat (files already have the dimension) and stack
(one file per position of a new dimension), with explicit positions and
gaps..encoding, so GDAL decodes the stored bytes exactly as xarray did.<SourceBand> and
<SourceTranspose>.<SourceSlab>), so a read
opens only the files it needs.<SRS> with the data-axis-to-SRS-axis mapping computed from the
WKT axis order.gdal mdim info oisst.vrt
from osgeo import gdal
ds = gdal.OpenEx("oisst.vrt", gdal.OF_MULTIDIM_RASTER)
sst = ds.GetRootGroup().OpenMDArray("sst").GetUnscaled()
or with an xarray backend for GDAL, such as
gdalxarray:
xr.open_dataset("oisst.vrt", engine="gdalxarray").
pip install -e ".[test]"
pytest tests/
tests/test_gdal_roundtrip.py reads every written VRT back through GDAL and
validates it against GDAL's schema (schema/gdalvrt.xsd); it is skipped when
osgeo.gdal is not importable. With conda-forge:
micromamba create -n xvrt -c conda-forge python gdal libgdal-netcdf xarray netcdf4 h5netcdf dask lxml pyarrow pyproj pytest
The design notes are in mdim-vrt-writer-plan.md; the documentation site source is in docs/.
MIT