I think public flogging would be better/cheaper and even more humane. The number of lashes could be determined by the crime and increased with each conviction.
To save money. They could all be put on an uninhabited island with food parachuted in once a week. Same gang. They’ll get along. Put some sheep on the island.