Compression algorithm about the OpenHistoian
deathfromheaven opened this issue · 2 comments
Dear developer,thanks for your contribution to the GSF.
Recently,some questions about the compression algorithm of OpenHistoian come to me. At present, I have used the OpenHistorian to receive the phasor datas ,which are measured by self-developed device. Therefore,I want to make an improvement on OpenHistorian's own compression algorithm(the TSSC algorithm) to adapt to our team's phasor data.
My question is : where to find the code of TSSC algorithm in the GSF framework and whether or not I can modify this algorithm.
Thanks for your kind attention and look forward your prompt reply!
Here's the C# code used for compression / decompression:
See the Encode / Decode methods.
You can write your own algorithm by giving it its own EncodingDefinition, basically a unique Guid and some type definitions, similar to this:
You are not restricted to the specified HistorianKey / HistorianValue - you can use your own key/value pair definition.
I'm sure if you are willing to invest more CPU cycles, the compression can be improved - however, openHistorian has a design goal to focus on speed, although for synchrophasor data, the compression results are pretty good.
If you have a different kind of data in mind, certainly another algorithm may do better.
OK,thank you very much!