My bicinctus do this behavior frequently, usually for three noticeable purposes:
1) to kick up infauna prey into the water column, which the fish then consumes
2) to clear all sand and moveable structure away from their spawning location
3) to protect their territory from scavengers (such as hermit crabs) that will prey on the nest - even if they are between spawns
In your case, it seems to be an aggressive action towards the crabs...