Guys.....OP is not disputing whether he's at fault...rather whether his driving merited the "careless" driving charge.
IMO, your witness should testify that the driver in front of you should be the one receiving the careless charge, cause his unexpected slam on the brakes was completely unwarranted.
If he managed to stop in time, before entering the intersection, then your argument wouldn't hold ground, but from your description of his location, it seems that he's the one that was out of control.
If one can't stop in time at an orange light, one has to proceed through, to clear the intersection.
Instead.....this guy slams the brake...slides into the intersection...comes to a complete stop in the middle of the intersection...blocks traffic...probably with plans to throw it into reverse...to get back behind the line...which is a big

.
Your witness should state that there was ample of time for the
both of you to clear the intersection during the orange light, but that didn't happen because the dude in front of you panicked and slammed the brake like a maniac, in wet conditions.
That cop wasn't present during the incident, so I believe that an eye witness' testimony would be more reliable to determine whether you drove carelessly.
I would hammer that point, indicating that what's careless is the cop not taking a statement from an eye witness, while charging you with such a serious charge.