CSX officials and their contractors worked overnight to restore the train cars that were derailed at the Port of Tampa early Thursday morning.
As of noon, crews had removed all but two of the derailed cars, according to Tampa Fire Rescue.
Fire officials said the workers' efforts to get the cars upright and in a safe location were hampered Thursday night by lightning and heavy rain that pushed through the region.
The process should continue well into today, fire officials said.
The 88-car train was delivering ethanol to the port Thursday about 1 a.m. when 14 of the cars left the rails and three toppled, spilling their cargo, said Capt. Lonnie Benniefield with Tampa Fire Rescue.
The spill was cleaned up Thursday morning, fire officials said.
The derailment occurred where tracks cross Maritime Boulevard in the port, and businesses across the port felt the effect of the derailment almost immediately because it happened near the north entrance where several rail lines and truck lanes converge.
The cause of the derailment has yet to be determined.