<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def from_v_theta(cls, v, theta):
 """ Create a quaternion from unit vector v and rotation angle theta. Returns ------- q : :class:`gala.coordinates.Quaternion` A ``Quaternion`` instance. """

        theta = np.asarray(theta)
        v = np.asarray(v)

        s = np.sin(0.5 * theta)
        c = np.cos(0.5 * theta)
        vnrm = np.sqrt(np.sum(v * v))

        q = np.concatenate([[c], s * v / vnrm])
        return cls(q)