# How to rename objects with python?

I want to rename the number 1->picture (32) with python not the number 2->picture with the (3745), can someone help me with that ?

bpy.data.objects['3745'].data.name = 'newName'

bpy.context.object.data.name = 'newName'