Made memory allocation dynamic in region setting to allow for the size of genomes and larger numbers