Sometimes you can make an educated guess by their fins and girth, males having more pointy fins and larger girth and females having more rounded fins and slightly smaller girth but it is hard to determine if you only have one fish.
Another way and the most accurate is by venting them. Just net them and while holding in the net turn them upside down and look at their mommy and daddy parts The females will be larger than the males when they are @ sexual maturity.