This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
> Ahhh - that makes sense. Does make using the ncid as a subscript for various > purposes a bit tricky, though. Yup, but you can get the fileid and groupid out of the ncid (which is called the "locid in much of the documentation) by just dividing by 65536 or taking remainder of dividing by 65536, respectively. --Russ > >> Unrelated, but a quick question - why are the ncid values I get from > >> nf_open so large and in units of 65,536? > > > > Good question, it's an artifact of how netCDF-4 combines both the file > > ID and the group ID into one 32-bit integer for netCDF-4. So with > > 2^16 open files each of which has 2^16 groups, you would use up all the > > 2^32 integers with group IDs of open netCDF files. > > > > --Russ Russ Rew UCAR Unidata Program address@hidden http://www.unidata.ucar.edu Ticket Details =================== Ticket ID: ESK-579185 Department: Support netCDF Priority: Normal Status: Closed