import re str = "{{182,915},{58,70}}" res = re.sub('{|}','',str) print res.split(',') ##输出:182,915,58,70