Hermie happens. Sometimes on a micro scale with cannabis. Tons of factors as to what would have led to this. Weak genetics, conditions going off, stress from methods used, etc.
The male flower aspect can be really hidden or buried inside the flower at times when this occurs.
So, yes, they can produce seeds without an actual male in the space.