Access auto tracking feature detection with python script
I know this is years late but I will answer this incase anyone stumbles across this. 

In this case you need to force context since the operators require a certain context to execute. To do this for the detect_features method you can do:

ctx = bpy.context.copy()
for area in bpy.context.screen.areas:
    if area.type == 'CLIP_EDITOR':
        ctx['area'] = area
bpy.ops.clip.detect_features(ctx)