  We present an algorithm for the computation of the topological type of a real
compact Riemann surface associated to an algebraic curve, i.e., its genus and
the properties of the set of fixed points of the anti-holomorphic involution
$\tau$, namely, the number of its connected components, and whether this set
divides the surface into one or two connected components. This is achieved by
transforming an arbitrary canonical homology basis to a homology basis where
the $\mathcal{A}$-cycles are invariant under the anti-holomorphic involution
$\tau$.
