Get two points (e.g. along axis of symmetry) from each segment. Two points gives you a vector for each segment. Calculate cross or dot product of that vectors, that gives you either sine or cosine value of the angle.
The problem is how to calculate two points along axis of symmetry, or something like that? If the task is not on the plane, then you need three points.
Form an n-by-2 matrix of points in image space, either taking the positions of all points in one segment, or all points on the boundary of a segment (experiment to find which works better for you). Call this matrix X.
Use sklearn.decomposition.PCA().fit(X).components_ to get the first principal component. This should be a 2-vector that points along the length of the segment.
Measure the angles between these orientation vectors.