Closed mkitti closed 1 month ago
xref: HDF5 Path Names and Navigation.
A BNF grammar for path names
PathName ::= AbsolutePathName | RelativePathName
Separator ::= "/" ["/"]*
AbsolutePathName ::= Separator [ RelativePathName ]
RelativePathName ::= Component [ Separator RelativePathName ]*
Component ::= "." | Name
Name ::= Character+ - {"."}
Character ::= {c: c in {{ legal ASCII characters } - {'/'}}
For a dataset with a name of "/X/somelab/RW10557/031021/Pos0/segmentation/RegB/045/E10\",
Base.parent
does not work. It attempts to look for "/X/somelab/RW10557/031021/Pos0/segmentation/RegB/045/E10" since that is the result ofdirname
.Instead we should strictly look for
/
. This is still possibly incorrect since the name of the dataset could contain a/
.