May I ask what your roll values actually means? Each 3D curve has a well defined local frame but that's clearly not the frame you are trying to compute. The usual Frenet or parallel transport methods are thus not directly applicable here.
It looks like you are using a fixed up vector which is then rotated around the tangent by some amount. But in the case you have displayed, the up vector is parallel to the tangent vector and that may cause problems.