A computer-implemented method for generating a reference line for planning a trajectory to drive an autonomous driving vehicle, ADV, the method comprising: perceiving a driving environment surrounding the ADV, including identifying one or more objects (501, 502, 503) based on sensor data obtained from a plurality of sensors of the ADV; for each of the identified objects (501, 502, 503), generating an arc curve (511, 512, 513) connecting a current location of the ADV and the object (501, 502, 503), and calculating a curvature of the arc curve (511, 512, 513) associated with the object (501, 502, 503); selecting one of the objects (501, 502, 503) associated with an arc curve (511, 512, 513) that satisfies a predetermined condition, wherein the selected object has a smallest curvature amongst the identified objects (501, 502, 503) as the predetermined condition, wherein the arc curve (511, 512, 513) connecting the current location of the ADV and the object (501, 502, 503) is generated, such that an X coordinate of an origin of the arc curve (rx) on an X axis is identical to an X coordinate of the ADV, wherein the X axis represents a current heading direction of the ADV, wherein a Y coordinate of the origin of the arc curve (ry) is determined based on a radius (r) of the arc curve: ry = r, and wherein the radius of the arc curve r = (x^2 + y^2) / 2y, wherein (x, y) represents a coordinate of the corresponding object; and generating a reference line from the current location of the ADV to the selected object, wherein the reference line is utilized for planning the trajectory to drive the ADV. perceiving a driving environment surrounding the ADV, including identifying one or more objects (501, 502, 503) based on sensor data obtained from a plurality of sensors of the ADV; for each of the identified objects (501, 502, 503), generating an arc curve (511, 512, 513) connecting a current location of the ADV and the object (501, 502, 503), and calculating a curvature of the arc curve (511, 512, 513) associated with the object (501, 502, 503); generating an arc curve (511, 512, 513) connecting a current location of the ADV and the object (501, 502, 503), and calculating a curvature of the arc curve (511, 512, 513) associated with the object (501, 502, 503); selecting one of the objects (501, 502, 503) associated with an arc curve (511, 512, 513) that satisfies a predetermined condition, wherein the selected object has a smallest curvature amongst the identified objects (501, 502, 503) as the predetermined condition, wherein the arc curve (511, 512, 513) connecting the current location of the ADV and the object (501, 502, 503) is generated, such that an X coordinate of an origin of the arc curve (rx) on an X axis is identical to an X coordinate of the ADV, wherein the X axis represents a current heading direction of the ADV, wherein a Y coordinate of the origin of the arc curve (ry) is determined based on a radius (r) of the arc curve: ry = r, and wherein the radius of the arc curve r = (x^2 + y^2) / 2y, wherein (x, y) represents a coordinate of the corresponding object; and generating a reference line from the current location of the ADV to the selected object, wherein the reference line is utilized for planning the trajectory to drive the ADV.