### visit method example Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v1_0.api.S104File.html Example from the visit method documentation. It creates a File object and uses visit with a list append callable to collect all member names in the file. ```python >>> # List the entire contents of the file >>> f = File("foo.hdf5") >>> list_of_names = [] >>> f.visit(list_of_names.append) ``` -------------------------------- ### Get a list of all softlinks in the file Source: https://s100py.readthedocs.io/en/latest/api/s100py.s1xx.S1XXFile.html Shows how to use the visititems_links method on an S1XXFile instance to collect all SoftLink objects by name. Callback receives each link and adds the link name to a list when the link is an instance of SoftLink. The example opens 'foo.hdf5' and visits all links. ```python mylist = [] def func(name, link): if isinstance(link, SoftLink): mylist.append(name) f = File('foo.hdf5') f.visititems_links(func) ``` -------------------------------- ### as_integer_ratio() example Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v1_0.api.WaterLevelTrend.html Shows the output of calling as_integer_ratio() on positive, negative, and zero integers. ```python >>> (10).as_integer_ratio() (10, 1) >>> (-10).as_integer_ratio() (-10, 1) >>> (0).as_integer_ratio() (0, 1) ``` -------------------------------- ### __init__(name, *args, **kwrds) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_0.api.S102File.html Creates a new file object. See the h5py user guide for a detailed explanation of the options. ```APIDOC ## __init__(name, *args, **kwrds) ### Description Creates a new file object. See the h5py user guide for a detailed explanation of the options. ### Parameters - **name** (str or file-like) - Required - Name of the file on disk, or file-like object. Note: for files created with the 'core' driver, HDF5 still requires this be non-empty. - **mode** (str) - Optional - r: Readonly, file must exist (default); r+: Read/write, file must exist; w: Create file, truncate if exists; w- or x: Create file, fail if exists; a: Read/write if exists, create otherwise. - **driver** (str) - Optional - Name of the driver to use. Legal values are None (default, recommended), 'core', 'sec2', 'direct', 'stdio', 'mpio', 'ros3'. - **libver** (str) - Optional - Library version bounds. Supported values: 'earliest', 'v108', 'v110', 'v112', 'v114', 'v200' and 'latest' depending on the version of libhdf5 h5py is built against. - **userblock_size** (int) - Optional - Desired size of user block. Only allowed when creating a new file (mode w, w- or x). - **swmr** (bool) - Optional - Open the file in SWMR read mode. Only used when mode = 'r'. - **rdcc_nslots** (int) - Optional - The number of chunk slots in the raw data chunk cache for this file. Increasing this value reduces the number of cache collisions, but slightly increases the memory used. Due to the hashing strategy, this value should ideally be a prime number. As a rule of thumb, this value should be at least 10 times the number of chunks that can fit in rdcc_nbytes bytes. For maximum performance, this value should be set approximately 100 times that number of chunks. The default value is 521. Applies to all datasets unless individually changed. - **rdcc_nbytes** (int) - Optional - Total size of the dataset chunk cache in bytes. The default size per dataset is 1024**2 (1 MiB) for HDF5 before 2.0 and 8 MiB for HDF5 2.0 and later. Applies to all datasets unless individually changed. - **rdcc_w0** (float) - Optional - The chunk preemption policy for all datasets. This must be between 0 and 1 inclusive and indicates the weighting according to which chunks which have been fully read or written are penalized when determining which chunks to flush from cache. A value of 0 means fully read or written chunks are treated no differently than other chunks (the preemption is strictly LRU) while a value of 1 means fully read or written chunks are always preempted before other chunks. If your application only reads or writes data once, this can be safely set to 1. Otherwise, this should be set lower depending on how often you re-read or re-write the same data. The default value is 0.75. Applies to all datasets unless individually changed. - **track_order** (bool) - Optional - Track dataset/group/attribute creation order under root group if True. If None use global default h5.get_config().track_order. - **track_times** (bool or None) - Optional - If True, store timestamps for this group in the file. If None, fall back to the default value. Default: False. - **fs_strategy** (str) - Optional - The file space handling strategy to be used. Only allowed when creating a new file (mode w, w- or x). Defined as: "fsm" FSM, Aggregators, VFD; "page" Paged FSM, VFD; "aggregate" Aggregators, VFD; "none" VFD. If None use HDF5 defaults. - **fs_page_size** (int) - Optional - File space page size in bytes. Only used when fs_strategy="page". If None use the HDF5 default (4096 bytes). - **fs_persist** (bool) - Optional - A boolean value to indicate whether free space should be persistent or not. Only allowed when creating a new file. The default value is False. - **fs_threshold** (int) - Optional - The smallest free-space section size that the free space manager will track. Only allowed when creating a new file. The default value is 1. - **page_buf_size** (int) - Optional - Page buffer size in bytes. Only allowed for HDF5 files created with fs_strategy="page". Must be a power of two value and greater or equal than the file space page size when creating the file. It is not used by default. - **min_meta_keep** (int) - Optional - Minimum percentage of metadata to keep in the page buffer before allowing pages containing metadata to be evicted. Applicable only if page_buf_size is set. Default value is zero. - **min_raw_keep** (int) - Optional - Minimum percentage of raw data to keep in the page buffer before allowing pages containing raw data to be evicted. Applicable only if page_buf_size is set. Default value is zero. - **locking** (bool, str, or None) - Optional - The file locking behavior. Defined as: False (or "false") – Disable file locking; True (or "true") – Enable file locking; "best-effort" – Enable file locking but ignore some errors; None – Use HDF5 defaults. Warning: The HDF5_USE_FILE_LOCKING environment variable can override this parameter. - **alignment_threshold** (int) - Optional - Together with alignment_interval, this property ensures that any file object greater than or equal in size to the alignment threshold (in bytes) will be aligned on an address which is a multiple of alignment interval. ``` -------------------------------- ### __init__(*args, **kywrds) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v2_0.api.S104File.html Creates a new file object. See the h5py user guide for detailed explanation of options. ```APIDOC ## __init__(*args, **kywrds) ### Description Creates a new file object. See the h5py user guide for detailed explanation of options. ### Parameters - **name** (str or file-like) - Required - Name of the file on disk, or file-like object. Note: for files created with the 'core' driver, HDF5 still requires this be non-empty. - **mode** (str) - Optional - r: Readonly, file must exist (default); r+: Read/write, file must exist; w: Create file, truncate if exists; w- or x: Create file, fail if exists; a: Read/write if exists, create otherwise. - **driver** (str) - Optional - Name of the driver to use. Legal values are None (default, recommended), 'core', 'sec2', 'direct', 'stdio', 'mpio', 'ros3'. - **libver** (str) - Optional - Library version bounds. Supported values: 'earliest', 'v108', 'v110', 'v112', 'v114', 'v200' and 'latest' depending on the version of libhdf5 h5py is built against. - **userblock_size** (int) - Optional - Desired size of user block. Only allowed when creating a new file (mode w, w- or x). - **swmr** (bool) - Optional - Open the file in SWMR read mode. Only used when mode = 'r'. - **rdcc_nslots** (int) - Optional - The number of chunk slots in the raw data chunk cache for this file. Increasing this value reduces the number of cache collisions, but slightly increases the memory used. Due to the hashing strategy, this value should ideally be a prime number. As a rule of thumb, this value should be at least 10 times the number of chunks that can fit in rdcc_nbytes bytes. For maximum performance, this value should be set approximately 100 times that number of chunks. The default value is 521. Applies to all datasets unless individually changed. - **rdcc_nbytes** (int) - Optional - Total size of the dataset chunk cache in bytes. The default size per dataset is 1024**2 (1 MiB) for HDF5 before 2.0 and 8 MiB for HDF5 2.0 and later. Applies to all datasets unless individually changed. - **rdcc_w0** (float) - Optional - The chunk preemption policy for all datasets. This must be between 0 and 1 inclusive and indicates the weighting according to which chunks which have been fully read or written are penalized when determining which chunks to flush from cache. A value of 0 means fully read or written chunks are treated no differently than other chunks (the preemption is strictly LRU) while a value of 1 means fully read or written chunks are always preempted before other chunks. If your application only reads or writes data once, this can be safely set to 1. Otherwise, this should be set lower depending on how often you re-read or re-write the same data. The default value is 0.75. Applies to all datasets unless individually changed. - **track_order** (bool) - Optional - Track dataset/group/attribute creation order under root group if True. If None use global default h5.get_config().track_order. - **track_times** (bool or None) - Optional - If True, store timestamps for this group in the file. If None, fall back to the default value. Default: False. - **fs_strategy** (str) - Optional - The file space handling strategy to be used. Only allowed when creating a new file (mode w, w- or x). Defined as: "fsm" FSM, Aggregators, VFD; "page" Paged FSM, VFD; "aggregate" Aggregators, VFD; "none" VFD. If None use HDF5 defaults. - **fs_page_size** (int) - Optional - File space page size in bytes. Only used when fs_strategy="page". If None use the HDF5 default (4096 bytes). - **fs_persist** (bool) - Optional - A boolean value to indicate whether free space should be persistent or not. Only allowed when creating a new file. The default value is False. - **fs_threshold** (int) - Optional - The smallest free-space section size that the free space manager will track. Only allowed when creating a new file. The default value is 1. - **page_buf_size** (int) - Optional - Page buffer size in bytes. Only allowed for HDF5 files created with fs_strategy="page". Must be a power of two value and greater or equal than the file space page size when creating the file. It is not used by default. - **min_meta_keep** (int) - Optional - Minimum percentage of metadata to keep in the page buffer before allowing pages containing metadata to be evicted. Applicable only if page_buf_size is set. Default value is zero. ``` -------------------------------- ### bit_count() example Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v1_0.api.WaterLevelTrend.html Shows the binary representation of 13 and the result of bit_count(). ```python >>> bin(13) '0b1101' >>> (13).bit_count() 3 ``` -------------------------------- ### bit_length() example Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v1_0.api.WaterLevelTrend.html Shows the binary representation of 37 and the result of bit_length(). ```python >>> bin(37) '0b100101' >>> (37).bit_length() 6 ``` -------------------------------- ### __init__(_*args_, _**opts_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_0.api.S102MetadataListBase.html Initializes the object. ```APIDOC ## __init__(_*args_, _**opts_) ### Description Initializes the object. ### Parameters - **args** - Positional arguments. - **opts** - Keyword arguments. ``` -------------------------------- ### Check dataset class with group.get() Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.S100File.html Uses the get method with getclass=True to check if a dataset is a SoftLink. The example shows a conditional check after retrieval. ```python >>> cls = group.get('foo', getclass=True) >>> if cls == SoftLink: ``` -------------------------------- ### __init__(*args, **opts) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v2_0.api.WaterLevelContainerDCF2.html Initializes the WaterLevelContainerDCF2 instance. ```APIDOC ## __init__(*args, **opts) ### Description Initializes the WaterLevelContainerDCF2 instance. ### Method N/A (class constructor) ### Endpoint N/A ### Parameters - **args** - Optional - Positional arguments. - **opts** - Optional - Keyword arguments. ### Returns None ``` -------------------------------- ### Install s100py with pip Source: https://s100py.readthedocs.io/en/latest Installs the s100py package using pip. Requires GDAL Python bindings to be installed beforehand. ```bash pip install s100py ``` -------------------------------- ### __init__(_* args_, _** kywrds_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.S100File.html Creates a new file object. The constructor accepts various parameters to configure the file, including name, mode, driver, library version, and caching options. ```APIDOC ## __init__(_* args_, _** kywrds_) ### Description Create a new file object. See the h5py user guide for a detailed explanation of the options. ### Method __init__ ### Parameters - **name** (str or file-like) - Required - Name of the file on disk, or file-like object. Note: for files created with the 'core' driver, HDF5 still requires this be non-empty. - **mode** (str) - Optional - Access mode: 'r' (readonly, file must exist, default), 'r+' (read/write, file must exist), 'w' (create file, truncate if exists), 'w-' or 'x' (create file, fail if exists), 'a' (read/write if exists, create otherwise). - **driver** (str) - Optional - Name of the driver to use. Legal values are None (default, recommended), 'core', 'sec2', 'direct', 'stdio', 'mpio', 'ros3'. - **libver** (str) - Optional - Library version bounds. Supported values: 'earliest', 'v108', 'v110', 'v112', 'v114', 'v200' and 'latest' depending on the version of libhdf5 h5py is built against. - **userblock_size** (int) - Optional - Desired size of user block. Only allowed when creating a new file (mode w, w- or x). - **swmr** (bool) - Optional - Open the file in SWMR read mode. Only used when mode = 'r'. - **rdcc_nslots** (int) - Optional - The number of chunk slots in the raw data chunk cache for this file. Increasing this value reduces the number of cache collisions, but slightly increases the memory used. Due to the hashing strategy, this value should ideally be a prime number. As a rule of thumb, this value should be at least 10 times the number of chunks that can fit in rdcc_nbytes bytes. For maximum performance, this value should be set approximately 100 times that number of chunks. The default value is 521. Applies to all datasets unless individually changed. - **rdcc_nbytes** (int) - Optional - Total size of the dataset chunk cache in bytes. The default size per dataset is 1024**2 (1 MiB) for HDF5 before 2.0 and 8 MiB for HDF5 2.0 and later. Applies to all datasets unless individually changed. - **rdcc_w0** (float) - Optional - The chunk preemption policy for all datasets. This must be between 0 and 1 inclusive and indicates the weighting according to which chunks which have been fully read or written are penalized when determining which chunks to flush from cache. A value of 0 means fully read or written chunks are treated no differently than other chunks (the preemption is strictly LRU) while a value of 1 means fully read or written chunks are always preempted before other chunks. If your application only reads or writes data once, this can be safely set to 1. Otherwise, this should be set lower depending on how often you re-read or re-write the same data. The default value is 0.75. Applies to all datasets unless individually changed. - **track_order** (bool or None) - Optional - Track dataset/group/attribute creation order under root group if True. If None use global default h5.get_config().track_order. - **track_times** (bool or None) - Optional - If True, store timestamps for this group in the file. If None, fall back to the default value. Default: False. - **fs_strategy** (str) - Optional - The file space handling strategy to be used. Only allowed when creating a new file (mode w, w- or x). Defined as: "fsm" FSM, Aggregators, VFD; "page" Paged FSM, VFD; "aggregate" Aggregators, VFD; "none" VFD. If None use HDF5 defaults. - **fs_page_size** (int) - Optional - File space page size in bytes. Only used when fs_strategy="page". If None use the HDF5 default (4096 bytes). - **fs_persist** (bool) - Optional - A boolean value to indicate whether free space should be persistent or not. Only allowed when creating a new file. The default value is False. ### Returns A new S100File object. ``` -------------------------------- ### Create S-104 File with Metadata and Data Arrays Source: https://s100py.readthedocs.io/en/latest/s104.html Setup metadata dictionary with optional attributes, create a new S-104 file using s104.utils.create_s104, add metadata and water level instances, add water level data from arrays for two time series, update metadata, and write the file. The example requires definitions for datetime_forecast_issuance, datetime_interval, grid_properties, and water_level_height_001/002 and water_level_trend_001 arrays. ```python # Example metadata # Optional attributes are denoted below and can be removed metadata = { 'horizontalCRS': 4326, # EPSG code 'waterLevelHeightUncertainty': -1.0, # -1.0 (unknown) or positive value (m) 'horizontalPositionUncertainty': -1.0, # -1.0 (unknown) or positive value (m) 'verticalUncertainty': -1.0, # -1.0 (unknown) or positive value (m) 'waterLevelTrendThreshold': 0.2, 'verticalCS': 6499, # Height-Meters–Orientation Up 'verticalDatumReference': 1, # 1:S100_VerticalAndSoundingDatum 'verticalCoordinateBase': 2, # 2:verticalDatum (Only value allowed) 'verticalDatum': 12, # 12:MLLW 'commonPointRule': 4, # 4:all 'interpolationType': 1, # 1:nearestneighbor (Only value allowed) 'dataDynamicity': 5, # 5:Hydrodynamic model forecast (F) 'issueDateTime': datetime_forecast_issuance, # All times are in UTC, DateTime format 'dateTimeOfFirstRecord': '20210901T010000Z', # All times are in UTC, DateTime format 'geographicIdentifier': 'Add Region Name', # Optional 'methodWaterLevelProduct': 'ADCIRC_Hydrodynamic_Model_Forecasts', # Optional 'trendInterval': 60, # Optional (Minutes) 'datasetDeliveryInterval': 'PT6H', #Optional (ISO 8601 duration, format `YnMnDTnHnMnS`) 'epoch': '2005.0', # Optional 'verticalDatumEpoch': 'NOAA_NTDE_1983-2001', # Optional 'timeUncertainty': -1.0 # Optional } data_coding_format = 2 # Only value allowed in S-104 Ed 2.0 data_file = s104.utils.create_s104("test_s104.h5", 2) s104.utils.add_metadata(metadata, data_file) s104.utils.add_water_level_instance(data_file) data_series_time_001 = datetime_forecast_issuance + datetime_interval s104.utils.add_data_from_arrays(water_level_height_001, water_level_trend_001, data_file, grid_properties, data_series_time_001, data_coding_format) data_series_time_002 = data_series_time_001 + datetime_interval water_level_difference = numpy.round((water_level_height_002 - water_level_height_001), decimals=2) water_level_difference = numpy.ma.masked_where((water_level_height_002 == -9999.0) | (water_level_height_001 == -9999.0), water_level_difference) #Trend is determined using S-104 Edition 2.0.0 Annex A-2 Feature Attributes Section 2: Water Level Trend (waterLevelTrend) water_level_trend_002 = numpy.where((-metadata['waterLevelTrendThreshold'] < water_level_difference) & (water_level_difference < metadata['waterLevelTrendThreshold'] ), 3, numpy.where(water_level_difference >= metadata['waterLevelTrendThreshold'] , 2, numpy.where(water_level_difference <= -metadata['waterLevelTrendThreshold'] , 1, 0))) water_level_trend_002 = numpy.ma.filled(water_level_trend_002, 0) s104.utils.add_data_from_arrays(water_level_height_002, water_level_trend_002, data_file, grid_properties, data_series_time_002, data_coding_format) s104.utils.update_metadata(data_file, grid_properties, metadata) s104.utils.write_data_file(data_file) ``` -------------------------------- ### __init__(_* args_, _** kwargs_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s111.v1_0.api.DiscoveryMetadata.html Initializes the DiscoveryMetadata object. ```APIDOC ## __init__(_* args_, _** kwargs_) ### Description Initializes the DiscoveryMetadata object. ``` -------------------------------- ### Install s100py with mamba Source: https://s100py.readthedocs.io/en/latest Install s100py from the conda-forge channel using mamba. ```bash mamba install s100py ``` -------------------------------- ### __init__(recursively_create_children=False, **kywrds) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s1xx.S1xxGridsBase.html Initializes the S1xxGridsBase instance. ```APIDOC ## __init__(recursively_create_children=False, **kywrds) ### Description Initializes the S1xxGridsBase instance. ``` -------------------------------- ### Install s100py with conda Source: https://s100py.readthedocs.io/en/latest Install s100py from the conda-forge channel using conda. ```bash conda install s100py ``` -------------------------------- ### copy group example Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_1.api.S102File.html Example of copying a group within a file. Creates a group, lists keys, copies it, and lists keys again to show the new copy. ```python >>> f = File('myfile.hdf5', 'w') >>> f.create_group("MyGroup") >>> list(f.keys()) ['MyGroup'] >>> f.copy('MyGroup', 'MyCopy') >>> list(f.keys()) ['MyGroup', 'MyCopy'] ``` -------------------------------- ### Create a basic MyObject and add it to the file Source: https://s100py.readthedocs.io/en/latest/using_example_api.html Creates a MyObject instance, sets its data_value attribute, and assigns it to the root of the file. ```python the_first_object = MyObject() the_first_object.data_value = "A sample string" write_to_file.root.my_first_object = the_first_object ``` -------------------------------- ### FeatureInstanceDCF5.start_sequence_create() Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureInstanceDCF5.html Creates a blank, empty or zero value for start_sequence. ```APIDOC ## FeatureInstanceDCF5.start_sequence_create() ### Description Creates a blank, empty or zero value for start_sequence. ### Method start_sequence_create ### Parameters None ### Returns None ``` -------------------------------- ### S100 data spec example Source: https://s100py.readthedocs.io/en/latest/example_api.html Example data specification for the S100 API. It defines a tree structure with compound datasets, multi-occurrence groups, sub groups, and attributes. Use this as a reference when implementing the corresponding Python classes. ```text S999 | + datasetWithNames (type=compound dataset) | | | + attrInt (type=int) | | | + attrFloat (type=float) | | | + attrStr (type=string) | + dataGroup_01, dataGroup_02... (type=multi-occurrence group) | | | + nameOfData (type=enumeration) | | | + dataGrid (type=rectangular grid dataset) | + myLocationGroup (type=sub group but based on a S100 type, GeographicBoundingBox) | | | + utmZone (type=int) | + myFirstObject (type=sub group) | | | + dataValue (type=string) ``` -------------------------------- ### __init__(name, *args, **kywrds) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s1xx.S1XXFile.html Creates a new file object. This constructor initializes an S1XXFile instance with the specified parameters. ```APIDOC ## __init__(name, *args, **kywrds) ### Description Creates a new file object. This constructor initializes an S1XXFile instance with the specified parameters. ### Method N/A (constructor) ### Parameters - **name** (str or file-like) - Required - Name of the file on disk, or file-like object. Note: for files created with the 'core' driver, HDF5 still requires this be non-empty. - **mode** (str) - Optional - Access mode: 'r' (readonly, file must exist, default), 'r+' (read/write, file must exist), 'w' (create file, truncate if exists), 'w-' or 'x' (create file, fail if exists), 'a' (read/write if exists, create otherwise). - **driver** (str) - Optional - Name of the driver to use. Legal values are None (default, recommended), 'core', 'sec2', 'direct', 'stdio', 'mpio', 'ros3'. - **libver** (str) - Optional - Library version bounds. Supported values: 'earliest', 'v108', 'v110', 'v112', 'v114', 'v200' and 'latest' depending on the version of libhdf5 h5py is built against. - **userblock_size** (int) - Optional - Desired size of user block. Only allowed when creating a new file (mode w, w- or x). - **swmr** (bool) - Optional - Open the file in SWMR read mode. Only used when mode = 'r'. - **rdcc_nslots** (int) - Optional - The number of chunk slots in the raw data chunk cache for this file. Increasing this value reduces the number of cache collisions, but slightly increases the memory used. Due to the hashing strategy, this value should ideally be a prime number. As a rule of thumb, this value should be at least 10 times the number of chunks that can fit in rdcc_nbytes bytes. For maximum performance, this value should be set approximately 100 times that number of chunks. The default value is 521. Applies to all datasets unless individually changed. - **rdcc_nbytes** (int) - Optional - Total size of the dataset chunk cache in bytes. The default size per dataset is 1024**2 (1 MiB) for HDF5 before 2.0 and 8 MiB for HDF5 2.0 and later. Applies to all datasets unless individually changed. - **rdcc_w0** (float) - Optional - The chunk preemption policy for all datasets. This must be between 0 and 1 inclusive and indicates the weighting according to which chunks which have been fully read or written are penalized when determining which chunks to flush from cache. A value of 0 means fully read or written chunks are treated no differently than other chunks (the preemption is strictly LRU) while a value of 1 means fully read or written chunks are always preempted before other chunks. If your application only reads or writes data once, this can be safely set to 1. Otherwise, this should be set lower depending on how often you re-read or re-write the same data. The default value is 0.75. Applies to all datasets unless individually changed. - **track_order** (bool) - Optional - Track dataset/group/attribute creation order under root group if True. If None use global default h5.get_config().track_order. - **track_times** (bool or None) - Optional - If True, store timestamps for this group in the file. If None, fall back to the default value. Default: False. - **fs_strategy** (str) - Optional - The file space handling strategy to be used. Only allowed when creating a new file (mode w, w- or x). Defined as: "fsm" FSM, Aggregators, VFD; "page" Paged FSM, VFD; "aggregate" Aggregators, VFD; "none" VFD. If None use HDF5 defaults. - **fs_page_size** (int) - Optional - File space page size in bytes. Only used when fs_strategy="page". If None use the HDF5 default (4096 bytes). - **fs_persist** (bool) - Optional - A boolean value to indicate whether free space should be persistent or not. Only allowed when creating a new file. The default value is False. - **fs_threshold** (int) - Optional - The smallest free-space section size that the free space manager will track. Only allowed when creating a new file. The default value is 1. - **page_buf_size** (int) - Optional - Page buffer size in bytes. Only allowed for HDF5 files created with fs_strategy="page". Must be a power of two value and greater or equal than the file space page size when creating the file. It is not used by default. - **min_meta_keep** (int) - Optional - Minimum percentage of metadata to keep in the page buffer before allowing pages containing metadata to be evicted. Applicable only if page_buf_size is set. Default value is zero. ### Response Returns a new S1XXFile object. ``` -------------------------------- ### S102File.values Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_2.api.S102File.html Get a view object on member objects. ```APIDOC ## S102File.values ### Description Get a view object on member objects. ### Method values ### Returns A view object on member objects. ``` -------------------------------- ### __init__(_*args_, _**opts_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v1_0.api.WaterLevelListDCF3.html Constructor for the WaterLevelListDCF3 class. ```APIDOC ## __init__(_*args_, _**opts_) ### Description Constructor for the WaterLevelListDCF3 class. ### Method Constructor ### Parameters - **args** - Positional arguments. - **opts** - Keyword arguments. ``` -------------------------------- ### __init__(_*args_, _**opts_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureContainerDCF8.html Initializes the FeatureContainerDCF8 instance. ```APIDOC ## __init__(_*args_, _**opts_) ### Description Initializes the FeatureContainerDCF8 instance. ``` -------------------------------- ### values() Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_2.api.S102File.html Get a view object on member objects ```APIDOC ## values() ### Description Get a view object on member objects. ### Parameters None ### Returns Returns a ValuesView object. ``` -------------------------------- ### get Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_1.api.S102File.html Retrieves an item or other information from the HDF5 file. ```APIDOC ## get ### Description Retrieve an item or other information from the HDF5 file. ### Method instance method ### Signature `get(name, default=None, getclass=False, getlink=False)` ### Parameters - **name** - Required - Name of the item to retrieve. - **default** (optional) - Optional - Value to return if item does not exist. - **getclass** (bool) - Optional - If True, return the class of object (Group, Dataset, etc.). - **getlink** (bool) - Optional - If True, return HardLink, SoftLink or ExternalLink instances. ### Returns - **item** - The retrieved item, or default if not found. - **class** - If getclass is True, the class of the object. - **link** - If getlink is True, the link instance. ### Example ``` >>> cls = group.get('foo', getclass=True) >>> if cls == SoftLink: ``` ``` -------------------------------- ### __init__(recursively_create_children=False, **kywrds) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_0.api.S102Root.html Initializes the S102Root object. ```APIDOC ## __init__(recursively_create_children=False, **kywrds) ### Description Initializes the S102Root object. ### Method N/A (SDK method) ### Endpoint N/A (SDK method) ### Parameters #### Path Parameters - **recursively_create_children** (bool) - Optional - Whether to recursively create children. Default is False. - **kywrds** (keyword arguments) - Optional - Additional keyword arguments. ### Request Example N/A ### Response #### Success Response (200) - **None** - This method returns None. #### Response Example N/A ``` -------------------------------- ### get_s1xx_attr(_s1xx_name_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_0.api.BathymetryFeatureInstance.html Gets an S1xx attribute by name. ```APIDOC ## get_s1xx_attr(_s1xx_name_) ### Description Gets an S1xx attribute by name. ### Parameters - **s1xx_name** (unknown) - Required - The S1xx attribute name. ### Returns No return value documented. ``` -------------------------------- ### S100File.keys Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.S100File.html Gets a view object on member names. ```APIDOC ## S100File.keys ### Description Gets a view object on member names. ### Method keys ### Parameters None. ``` -------------------------------- ### __init__(_*args_, _**opts_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s111.v1_0.api.S111MetadataListBase.html Constructor for the S111MetadataListBase class. ```APIDOC ## __init__(_*args_, _**opts_) ### Description Constructor for the S111MetadataListBase class. ### Method POST ### Endpoint S111MetadataListBase.__init__(_*args_, _**opts_) ### Parameters #### Path Parameters - **args** - Required - Positional arguments. - **opts** - Required - Keyword arguments. ### Returns - **None** - None ``` -------------------------------- ### __init__(recursively_create_children=False, **kywrds) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s111.v1_0.api.S111Root.html Initializes the S111Root object. ```APIDOC ## __init__(recursively_create_children=False, **kywrds) ### Description Initializes the S111Root object. ### Method __init__(recursively_create_children=False, **kywrds) ### Parameters - **recursively_create_children** (bool) - Optional - Whether to recursively create children. Default is False. - **kywrds** (dict) - Optional - Additional keyword arguments. ### Return Type None ### Example ```python root = S111Root(recursively_create_children=True) ``` ``` -------------------------------- ### S100File.items Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.S100File.html Gets a view object on member items. ```APIDOC ## S100File.items ### Description Gets a view object on member items. ### Method items ### Parameters None. ``` -------------------------------- ### __init__(_recursively_create_children =False_, _** kywrds_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureInstanceDCF2.html Initializes the object. ```APIDOC ## __init__(_recursively_create_children =False_, _** kywrds_) ### Description Initializes the object. ### Method N/A ### Endpoint N/A ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **recursively_create_children** (bool) - Optional - Whether to recursively create children. - **kywrds** (dict) - Optional - Additional keyword arguments. ### Request Example N/A ### Response #### Success Response (200) None #### Response Example N/A ``` -------------------------------- ### BathymetryContainer.get_data(key) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_0.api.BathymetryContainer.html Gets data for a given key. ```APIDOC ## BathymetryContainer.get_data(key) ### Description Gets the data associated with the specified key. ### Method GET ### Parameters - **key** - Required - The key for which to retrieve data. ### Returns - data - The data associated with the key. ### Example None ``` -------------------------------- ### get_s1xx_attr(_s1xx_name_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureContainerDCF1.html Gets an S100 attribute by name. ```APIDOC ## get_s1xx_attr(_s1xx_name_) ### Description Gets an S100 attribute by name. ### Parameters - **s1xx_name** (unknown) - Required - The S100 name of the attribute. ``` -------------------------------- ### get_data(_key_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureContainerDCF1.html Gets data from the feature container. ```APIDOC ## get_data(_key_) ### Description Gets data from the feature container. ### Parameters - **key** (unknown) - Required - The key for the data. ``` -------------------------------- ### __init__(recursively_create_children=False, **kywrds) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureInstanceBase.html Initializes the FeatureInstanceBase object. ```APIDOC ## __init__(recursively_create_children=False, **kywrds) ### Description Initializes the FeatureInstanceBase object. ### Method __init__(recursively_create_children=False, **kywrds) ### Parameters #### Parameters - **recursively_create_children** (bool) - Optional - Whether to recursively create children. Default is False. - **kywrds** (keyword arguments) - Optional - Additional keyword arguments. ### Return Type None ### Response No response body. ``` -------------------------------- ### S100Root.__init__ Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.S100Root.html Initializes an S100Root instance. Optionally recursively creates child data and overwrites existing data. ```APIDOC ## S100Root.__init__ ### Description Initializes an S100Root instance. Optionally recursively creates child data and overwrites existing data. ### Method Constructor ### Parameters - **recursively_create_children** (bool) - Optional - True = Create children for any child data that would have other children; False = Only create data for immediate children of this instance. - **kywrds** (keyword arguments) - Optional - Additional keyword arguments. ### Return Type None ``` -------------------------------- ### S1xxCollection.get_hdf5_from_file(file_obj) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s1xx.S1xxCollection.html Gets HDF5 data from a file object. ```APIDOC ## S1xxCollection.get_hdf5_from_file(file_obj) ### Description Gets HDF5 data from a file object. ### Method get_hdf5_from_file ### Parameters - **file_obj** - The file object to read from. ``` -------------------------------- ### S1xxCollection.get_data(key) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s1xx.S1xxCollection.html Gets data from the collection using a key. ```APIDOC ## S1xxCollection.get_data(key) ### Description Gets data from the collection using a key. ### Method get_data ### Parameters - **key** - The key for the data. ``` -------------------------------- ### __init__(*args, **opts) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_0.api.BathymetryContainer.html Constructor for the BathymetryContainer class. ```APIDOC ## __init__(*args, **opts) ### Description Constructor for the BathymetryContainer class. ### Method `__init__(*args, **opts)` ``` -------------------------------- ### SurfaceCurrentGroup.get_s1xx_attr(s1xx_name) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s111.v1_0.api.SurfaceCurrentGroup.html Gets an S100 attribute by its S100 name. ```APIDOC ## SurfaceCurrentGroup.get_s1xx_attr(s1xx_name) ### Description Gets an S100 attribute by its S100 name. ### Method get_s1xx_attr ### Parameters - **s1xx_name** (str) - Required - The S100 name of the attribute. ### Returns The attribute value. ``` -------------------------------- ### WaterLevelDomainExtentPolygonInformation.get_s1xx_attr(s1xx_name) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v2_0.api.WaterLevelDomainExtentPolygonInformation.html Method to get an S1xx attribute by name. ```APIDOC ## get_s1xx_attr(s1xx_name) ### Description Retrieves the S1xx attribute with the given name. ### Parameters - **s1xx_name** - The name of the S1xx attribute. ``` -------------------------------- ### __init__(_recursively_create_children=False, **kywrds_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureInstanceDCF9.html Initializes the FeatureInstanceDCF9 instance. ```APIDOC ## __init__(_recursively_create_children=False, **kywrds_) ### Description Initializes the FeatureInstanceDCF9 instance. ### Method Constructor ### Endpoint FeatureInstanceDCF9.__init__() ### Parameters - **recursively_create_children** (bool) - Optional - If True, recursively create children. - **kywrds** - Optional - Additional keyword arguments. ### Return Type None ``` -------------------------------- ### __init__(_recursively_create_children=False_, _**kywrds_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_0.api.FeatureCodesBase.html Initializes the FeatureCodesBase instance. ```APIDOC ## __init__(_recursively_create_children=False_, _**kywrds_) ### Description Initializes the FeatureCodesBase instance. ``` -------------------------------- ### S104Root.get_s1xx_attr(s1xx_name) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v1_0.api.S104Root.html Gets the S100 attribute with the given name. ```APIDOC ## S104Root.get_s1xx_attr(s1xx_name) ### Description Gets the S100 attribute with the given name. ### Method get_s1xx_attr ### Parameters - **s1xx_name** (string) - Required - The S100 attribute name. ### Returns The attribute value. ``` -------------------------------- ### S104Root.get_data(key) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v1_0.api.S104Root.html Gets the value associated with the given key. ```APIDOC ## S104Root.get_data(key) ### Description Gets the value associated with the given key. ### Method get_data ### Parameters - **key** (string) - Required - The key to retrieve. ### Returns The value associated with the key. ``` -------------------------------- ### __init__(_recursively_create_children=False, **kywrds_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v1_0.api.S100Root.html Initializes the S100Root object. ```APIDOC ## __init__(_recursively_create_children=False, **kywrds_) ### Description Initializes the S100Root object. ``` -------------------------------- ### __init__ Source: https://s100py.readthedocs.io/en/latest/api/s100py.s111.v1_0.api.SurfaceCurrentFeatureInstanceDCF3.html Initializes the SurfaceCurrentFeatureInstanceDCF3 object. ```APIDOC ## __init__ ### Description Initializes the SurfaceCurrentFeatureInstanceDCF3 object. ### Method __init__ ### Parameters - **recursively_create_children** (bool) - Optional - Whether to recursively create children. - **kywrds** - Optional - Additional keyword arguments. ### Return Type None ``` -------------------------------- ### VertexPoint.get_s1xx_attr(s1xx_name) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.VertexPoint.html Gets an S100 attribute by its S100 name. ```APIDOC ## VertexPoint.get_s1xx_attr(s1xx_name) ### Description Gets an S100 attribute by its S100 name. ### Method get_s1xx_attr ### Parameters - **s1xx_name** (unknown) - Required - The S100 name of the attribute. ### Returns Unknown ``` -------------------------------- ### VertexPoint.get_data(key) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.VertexPoint.html Gets data associated with the given key. ```APIDOC ## VertexPoint.get_data(key) ### Description Gets data associated with the given key. ### Method get_data ### Parameters - **key** (unknown) - Required - The key for the data. ### Returns Unknown ``` -------------------------------- ### Create a MyLocation object and add it to the file Source: https://s100py.readthedocs.io/en/latest/using_example_api.html Creates a MyLocation object, initializes its properties, sets some attributes, and adds it to the file root. ```python a_location = MyLocation() # create values for all child attributes and by passing in True it would recurse all grandchildren and beyond too a_location.initialize_properties(True) a_location.utm_zone = 18 a_location.east_bound_longitude = 33.5 ``` -------------------------------- ### __init__(_* args_, _** opts_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureInformationDataset.html Initializes a new instance of the FeatureInformationDataset class. ```APIDOC ## __init__(_* args_, _** opts_) ### Description Initializes a new instance of the FeatureInformationDataset class. ### Method __init__ ### Parameters - **args** - Positional arguments. - **opts** - Keyword arguments. ### Returns None ``` -------------------------------- ### get_data(_key_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureContainerDCF4.html Gets data associated with the given key. ```APIDOC ## get_data(_key_) ### Description Gets data associated with the given key. ### Method get_data ### Parameters - **key** (unknown) - Required - The key for the data. ### Returns None ``` -------------------------------- ### __init__(_recursively_create_children=False, **kywrds_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.GroupFBase.html Initializes the GroupFBase instance. ```APIDOC ## __init__(_recursively_create_children=False, **kywrds_) ### Description Initializes the GroupFBase instance. ``` -------------------------------- ### get_hdf5_from_file(_file_obj_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s100.FeatureContainerDCF1.html Gets HDF5 data from a file object. ```APIDOC ## get_hdf5_from_file(_file_obj_) ### Description Gets HDF5 data from a file object. ### Parameters - **file_obj** (unknown) - Required - The file object to read from. ``` -------------------------------- ### __init__(_recursively_create_children=False_, _**kywrds_) Source: https://s100py.readthedocs.io/en/latest/api/s100py.s104.v2_0.api.WaterLevelFeatureInstanceDCF2.html Initializes the WaterLevelFeatureInstanceDCF2 instance. ```APIDOC ## __init__(_recursively_create_children=False_, _**kywrds_) ### Description Initializes the WaterLevelFeatureInstanceDCF2 object. ### Method __init__(recursively_create_children=False, **kywrds) ### Parameters - **recursively_create_children** (bool) - Optional - If True, recursively create child objects - **kywrds** (keyword arguments) - Optional - Additional keyword arguments ### Return Type None ### Example ```python instance = WaterLevelFeatureInstanceDCF2() instance = WaterLevelFeatureInstanceDCF2(recursively_create_children=True) ``` ``` -------------------------------- ### __init__ Source: https://s100py.readthedocs.io/en/latest/api/s100py.s102.v2_2.api.BathymetryCoverage.html Initializes a new instance of the BathymetryCoverage class. ```APIDOC ## __init__ ### Description Constructor for the BathymetryCoverage class. ### Parameters - **recursively_create_children** (bool) - Optional - Whether to recursively create children. - **kywrds** - Optional - Additional keyword arguments. ```