Let G be a topological group and let µ be the Lebesgue measure on the interval [0, 1]. We let L 0 (G) to be the topological group of all µ-equivalence classes of µ-measurable functions defined on [0,1] with values in G, taken with the pointwise multiplication and the topology of convergence in measure. We show that for a Polish group G, if L 0 (G) has ample generics, then G has ample generics, thus the converse to a result of Kaïchouh and Le Maître.We further study topological similarity classes and conjugacy classes for many groups Aut(M ) and L 0 (Aut(M )), where M is a countable structure. We make a connection between the structure of groups generated by tuples, the Hrushovski property, and the structure of their topological similarity classes. In particular, we prove the trichotomy that for every tuplef of Aut(M ), where M is a countable structure such that algebraic closures of finite sets are finite, either the countable group f is precompact, or it is discrete, or the similarity class off is meager, in particular the conjugacy class off is meager. We prove an analogous trichotomy for groups L 0 (Aut(M )).2010 Mathematics Subject Classification. 03E15, 54H11.