1. A computer-implemented process for locating an object to which a device is rigidly attached, comprising: receiving, device motion features expressed in terms of device velocities or device accelerations from sensors on the device; capturing images of the device and the object to which it is rigidly attached; finding image motion features expressed in terms of image velocities or image accelerations in the captured images, wherein image motion features are found by using a flow at a point in an image to measure the velocity of the object under that point and wherein patches of the image are tracked to estimate the acceleration of a given patch of the object as it moves in the image; in a common coordinate system, matching the device velocities with the image velocities or matching the device accelerations with image accelerations, depending on which type of motion features are used, by: computing on a per pixel basis the difference between the image motion features and the device motion features at a number of pixel locations in one or more of the captured images; and determining the location of the device and any rigidly attached object in an image as the location of the smallest difference between the device motion features and image motion features in the coordinates of the common coordinate system.