Check Raster Tile Data
CHECK_RASTER_TILE_DATA
See the source code.
This test verifies that raster tile data values at different layers and compression types are correctly delivered by the backend.
Frontend sends: OPEN_FILE (
OpenFile)directory = "set_QA" file = "cluster_04096.fits" hdu = "0" file_id = 0 render_mode = RASTER
Backend returns: OPEN_FILE_ACK (
OpenFileAck)
Check 1: the OPEN_FILE_ACK should satisfy:
OPEN_FILE_ACK.success = True
Frontend sends: ADD_REQUIRED_TILES (
AddRequiredTiles) with NONE compressionfile_id = 0 compression_quality = 11 compression_type = NONE tiles = [0]
Backend returns: RASTER_TILE_DATA (
RasterTileData)
Check 2: the RASTER_TILE_DATA should satisfy:
RASTER_TILE_DATA.file_id = 0
RASTER_TILE_DATA.channel = 0
RASTER_TILE_DATA.stokes = 0
RASTER_TILE_DATA.compression_type = NONE
RASTER_TILE_DATA.tiles.length = 1
RASTER_TILE_DATA.tiles[0].x = 0, y = 0, layer = 0
RASTER_TILE_DATA.tiles[0].height = 256, width = 256
RASTER_TILE_DATA.tiles[0].image_data at pixel (256,256) = 2.72519
ZFP compression at multiple layers (layers 1-4)
Frontend sends: ADD_REQUIRED_TILES (
AddRequiredTiles) for each of 4 layers with ZFP compressionfile_id = 0 compression_type = ZFP compression_quality = 11
Check 3: for each layer, the RASTER_TILE_DATA should satisfy:
RASTER_TILE_DATA.file_id = 0
RASTER_TILE_DATA.channel = 0
RASTER_TILE_DATA.stokes = 0
RASTER_TILE_DATA.compression_type = ZFP
Each tile has correct x, y, layer, height (256), and width (256)
Image data length and spot-check byte values at indices [0, 50000, 100000, 150000, 200000] match expected values