Fix data compression ratio and add a new test method for dictionary