first working metric kernel w/o bitpacking
Code Cleanup