Closed kmorel closed 3 years ago
@ben-e-whitney the fPIC related issue still persists. Maybe you can look into this?
I believe that the cached version of MOAB, compiled without -fPIC
, is still being used. The workflows last ran six days ago. If no one activates them for another day or two, the cache should be cleared. If that doesn't happen, or if people keep on pushing changes, I will figure out how to clear the cache manually.
The previous versions of
huffman_encoding
andhuffman_decoding
assumed that the length of every code is greater than 0. If it was not, then either function would crash (primarily from a failedassert
).Zero length huffman codes do happen when there is only 1 code. (If there is only 1 code, then that code contains no information and thus uses 0 bits.) This can when the buffer contains all the same value (for example, calling it with an array of all zeros). It can also happen when the buffer contains only values outside the range of encodable values (which I've seen in small test arrays with a sufficiently small quantum).
Are either of these cases practical? Not really. But they can happen, and the MGARD library shouldn't crash in those cases.