Fixed constants in randmem script
Made singleton script more portable by fixing path