1. A method for detecting a curve structure in an image, comprising: detecting a plurality of curve segments in the image; generating a graph based on the curve segments, wherein the graph comprises a plurality of nodes, including a respective node corresponding to each of the plurality of curve segments detected in the image, and a plurality of edges connecting the plurality of nodes, wherein each node of the plurality of nodes is connected by respective edges to multiple other nodes of the plurality of nodes and each edge represents a possible connection between the curve segments corresponding to the nodes connected by the edge; and detecting a curve structure in the image by determining a path from a source node to a destination node in the graph.