-
Notifications
You must be signed in to change notification settings - Fork 76
Description
NDPluginPvxs does not work with ImageJ when the NDArrays are compressed. ImageJ reports the following errors:
31-Dec-2025 12:30:51.982: color mode is not an int
31-Dec-2025 12:30:51.982: handleEvents caught exception java.lang.NullPointerException
and the images do not update.
When sending uncompressed arrays the images do update, but this error message is still present for each image received:
31-Dec-2025 12:30:53.080: color mode is not an int
31-Dec-2025 12:30:53.180: color mode is not an int
31-Dec-2025 12:30:53.282: color mode is not an int
This is the output of pvget, which does have the data and report the correct compression.
(base) [epics@corvette ADSimDetector]$ pvget 13SIM1:Pva1:Image
13SIM1:Pva1:Image epics:nt/NTNDArray:1.0
union value
ubyte[] [0,0,2,164,31,85,1,0,108,31,170,1,0,108,15,255,0,108,31,85,255,0,108,15,0,1,255,239,31,153,1,0,108,31,204,1,0,108,31,102,1,0,108,31,51,
1,0,108,15,255,1,108,31,153,255,1,108,31,204,255,1,108,31,102,255,1,108,47,51,30,1,0,108,31,15,1,0,108,31,135,1,0,108,31,195,1,0,108,31,225,1,0,108,
31,240,1,0,108,31,120,1,0,108,31,60,1,0,108,47,31,224,2,0,107,47,15,240,2,0,107,47,7,248,2,0,107,47,3,252,2,0,107,47,1,254,2,0,107,47,0,255,2,0,107,47,
...
codec_t codec
string name bslz4
any parameters
long 1
long compressedSize 86556
long uncompressedSize 1048576
int uniqueId 4300
time_t dataTimeStamp 2025-12-31 12:35:14.685
long secondsPastEpoch 1767206114
int nanoseconds 685011863
time_t timeStamp 2025-12-31 12:35:14.685
long secondsPastEpoch 1767206114
int nanoseconds 685011894
dimension_t[] dimension
dimension_t
int size 1024
int offset 0
int fullSize 1024
int binning 1
boolean reverse false
dimension_t
int size 1024
int offset 0
int fullSize 1024
int binning 1
boolean reverse false
epics:nt/NTAttribute:1.0[] attribute
epics:nt/NTAttribute:1.0
string name ColorMode
any value
long 0
string[] tags []
string descriptor Color mode
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 0
string source Driver
epics:nt/NTAttribute:1.0
string name Int8
any value
long -8
string[] tags []
string descriptor Int8 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name UInt8
any value
ulong 8
string[] tags []
string descriptor UInt8 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Int16
any value
long -16
string[] tags []
string descriptor Int16 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name UInt16
any value
ulong 16
string[] tags []
string descriptor UInt16 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Int32
any value
long -32
string[] tags []
string descriptor Int32 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name UInt32
any value
ulong 32
string[] tags []
string descriptor UInt32 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Int64
any value
long -64
string[] tags []
string descriptor Int64 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name UInt64
any value
ulong 64
string[] tags []
string descriptor UInt64 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Float32
any value
double 32
string[] tags []
string descriptor Float32 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Float64
any value
double 64
string[] tags []
string descriptor Float64 attribute
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp
long secondsPastEpoch 0
int nanoseconds 0
int userTag 0
int sourceType 3
string source myAttrFunct1
NDPluginPVA does not have these issues. It correctly displays the compressed images in ImageJ with no error messages.
This is the output of pvget when I switch back to using NDPluginPVA.
(base) [epics@corvette ADSimDetector]$ pvget 13SIM1:Pva1:Image
13SIM1:Pva1:Image epics:nt/NTNDArray:1.0
union value
ubyte[] [0,0,2,155,31,85,1,0,108,31,170,1,0,108,15,255,0,108,31,85,255,0,108,15,0,1,255,239,31,102,1,0,108,31,51,1,0,108,31,153,1,0,108,31,204,1,0,108,15,255,
1,108,31,102,255,1,108,31,51,255,1,108,31,153,255,1,108,47,204,135,1,0,108,31,195,1,0,108,31,225,1,0,108,31,240,1,0,108,31,120,1,0,108,31,60,1,0,108,31,30,1,0,108,31,15,1,0,108,47,7,248,2,0,107,47,3,252,2,0,107,47,1,254,2,0,107,47,0,255,2,0,107,47,128,127,2,0,107,47,192,63,2,0,107,47,224,31,2,0,107,4
...
codec_t codec
string name bslz4
any parameters
int 5
long compressedSize 86556
long uncompressedSize 1048576
dimension_t[] dimension
dimension_t
int size 1024
int offset 0
int fullSize 1024
int binning 1
boolean reverse false
dimension_t
int size 1024
int offset 0
int fullSize 1024
int binning 1
boolean reverse false
int uniqueId 270
time_t dataTimeStamp 2025-12-31 12:47:19.827
long secondsPastEpoch 1767206839
int nanoseconds 826854944
int userTag 0
epics:nt/NTAttribute:1.0[] attribute
epics:nt/NTAttribute:1.0
string name ColorMode
any value
int 0
string descriptor Color mode
int sourceType 0
string source Driver
epics:nt/NTAttribute:1.0
string name Int8
any value
byte -8
string descriptor Int8 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name UInt8
any value
ubyte 8
string descriptor UInt8 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Int16
any value
short -16
string descriptor Int16 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name UInt16
any value
ushort 16
string descriptor UInt16 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Int32
any value
int -32
string descriptor Int32 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name UInt32
any value
uint 32
string descriptor UInt32 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Int64
any value
long -64
string descriptor Int64 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name UInt64
any value
ulong 64
string descriptor UInt64 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Float32
any value
float 32
string descriptor Float32 attribute
int sourceType 3
string source myAttrFunct1
epics:nt/NTAttribute:1.0
string name Float64
any value
double 64
string descriptor Float64 attribute
int sourceType 3
string source myAttrFunct1
string descriptor
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp 2025-12-31 12:47:19.827
long secondsPastEpoch 1767206839
int nanoseconds 826855001
int userTag 0
display_t display
double limitLow 0
double limitHigh 0
string description
string format
string units
This shows the reason for the ColorMode error: PVA says the value is "int 0" but PVXS says it is "long 0".
Most of the attributes have the wrong datatype. For example the attribute named UInt8 has the value "ubyte 8" with PVA but "ulong 8" with PVXS.
The reason for the failure to display the compressed images may be that the codec parameters are "int 5" for PVA but "long 1" for PVXS.