Better python problem initialization