Module: Omnizip::Algorithms::PPMd7::Constants

Included in:
Omnizip::Algorithms::PPMd7, Context, Model
Defined in:
lib/omnizip/algorithms/ppmd7/constants.rb

Overview

Constants for PPMd7 algorithm

PPMd7 uses context-based statistical compression with maximum context orders typically ranging from 2 to 16.

Constant Summary collapse

MAX_ORDER =

Maximum context order (model order)

16
MIN_ORDER =
2
DEFAULT_ORDER =
6
MIN_MEM_SIZE =

Memory allocation constants

1 << 20
MAX_MEM_SIZE =

1 MB minimum

1 << 30
DEFAULT_MEM_SIZE =

1 GB maximum

1 << 24
PROB_TOTAL =

Probability scaling factors

2048
MAX_FREQ =
124
INIT_ESCAPE_FREQ =
1
ALPHABET_SIZE =

Symbol alphabet size

256
UNIT_SIZE =

Context node structure sizes

12
MAX_STATES =

Maximum number of states per context

256
SEE_CONTEXTS =

Escape symbol handling

25
SUFFIX_CONTEXTS =
32
INT_BITS =

Update intervals for probability models

7
PERIOD_BITS =
7
BIN_SCALE =
1 << 13
INTERVAL =
1 << INT_BITS
UNIT_ALLOC_SIZE =

Memory unit allocation

12
TOP_VALUE =

Range coder constants (inherited from arithmetic coding)

1 << 24
BOT_VALUE =
1 << 15