Faster getPts

Adding a dictionary comprehension and getting rid of the local variable makes the `getPts` function overall faster