There is a major difference between birefringence extraction from a weakly polarizing jones matrix and a homogeneous jones matrix. A weakly polarzing element jones matrix can be inhomogeneous and yet meet the condition of weakly polarzing element (which is jxx-1, jxy, jyx, jyy ~ 10^-4) . Its good practice to not confuse both.
Eg:
A homogeneous weakly pol. JM: J = np.array([[1+1E-4, 1E-4], [1E-4, 1+1E-4]]), with eta = 0
A inhomogenous weakly pol. JM: J = np.array([[1+1E-4-7E-5, 1E-4-9E-5], [1E-4, 1+1E-4]]), with eta = 0.69
Both meet the requirement of weakly polarizing element condition. Yet you might go the wrong way in classifying them if you just consider homogeneous and inhomogeneous criteria and get misleading results.
The retardation and diattentuation calculation using homogeneous JM formula and weakly Polarizing JM formula, do match though.