If excess contribution plus earnings shows a loss and the loss is more than $300, ( 6% )
your other option is to leave the money in the SEP pay the penalty and reduce your 2023 contribution by about $5,000.
Custodian should be able to tell you the numbers without actually doing the operation.
@wkeithnix