Postgresql Text To Array Python Memory