A cleanroom process is evidence that you reimplemented without copying, but that's not enough to avoid infringing a patent. You need to redesign to avoid doing anything they claimed, convince the patent office that they made a mistake in granting some or all of the claims, hold a war chest of patents you could counter-sue with, or YOLO: https://paulgraham.com/softwarepatents.html