1. A method for populating a database with a set of image sequences of an object the database being used to detect localization of a guidewire in the object, the method comprising the steps of: receiving a set of images of anatomical structures, each image being annotated to show a guidewire, catheter, wire tip and stent; for each given image: using a Probabilistic Boosting Tree (PBT) to detect short line segments of constant length in the image; constructing two segment curves from the short line segments; using a discriminative joint shape and appearance model to classify each two segment curve; constructing a shape of an n-segment curve by concatenating all the two segment curves; identifying a guidewire curve model that comprises a start point, end point and the n-segment curve; and storing the guidewire curve model in the database.