keys = ['photo_2560', 'photo_1280', 'width', 'album_id', 'post_id', 'date', 'owner_id', 'photo_807', 'photo_604', 'id', 'photo_130', 'text']
max(map(lambda s: int(s[6:]), filter(lambda s: s[:6]=='photo_', keys)))
'photo_'+str(max(map(lambda s: int(s[6:]), filter(lambda s: s[:6]=='photo_', keys))))
>>> items = [ 'photo_2560', 'photo_1280', 'width', 'album_id', 'post_id', 'date', 'owner_id', 'photo_807', 'photo_604', 'id', 'photo_130', 'text']
>>> max((item for item in items if item.startswith('photo_')), key=lambda x: int(x[6:]))
'photo_2560'