xdata (time) is not correct
Thanks for this library which helped me to a lot through python.
I noticed an issue when xdata which is time element for when xoffset : '0.005' xdata is subject to rounding errors
print(chns[0]['xdata']) return the following : [0.01, 0.01, 0.03, 0.03, 0.04, 0.06, 0.07, 0.08, 0.09, 0.1, 0.11, 0.12, 0.12, 0.14, 0.15, 0.15, 0.17, 0.18, 0.18, 0.2, 0.21, 0.21, 0.23, 0.24, 0.24.
my time scale is inconsistent due to this and I believe the issue comes from the library as chns = imctm.get_channels(True) and this is directly build from IMCtermite.
I would be very thanksful if you have a fix for it.
Feel free to tell me if you need additional information of if my issue is unclear.
Hi @QuentinGlob ,
thank you for the issue! I'm glad you appreciate the library ;)
I'm going to have a look into the issue. Can you share the file you try to decode (at least the "header" part including the meta data) ?
Best regards
Hi, thanks you for looking into it !
I assume this is what you call the header : {'uuid': '892', 'name': 'Distance_RAD', 'comment': '', 'origin': 'imc STUDIO 5.0 R10 (04/08/2017)@imc DEVICES 2.9R7 (2017-07-25)@imcDev__23146913@PC', 'description': '', 'trigger-time-nt': '1980-01-01T00:00:00', 'trigger-time': '2025-04-17T09:28:39', 'language-code': '0x0', 'codepage': '1252', 'yname': 'Distance_RAD', 'yunit': 'm', 'significantbits': '16', 'addtime': '1429345719', 'xname': '', 'xunit': 's', 'xstepwidth': '0.01', 'xoffset': '0.005', 'group': {'index': '-1', 'name': '', 'comment': ''}, 'ydata':
the file that has caused this is present here: https://github.com/QuentinGlob/imctermite_rounding_issue
I hope this is clear, I have never used much GitHub I'm not sure what is standard practice.
Best regards