[NDS] Fix computation of ratio