Calculating encoding of targets almost done