1 public class TrackDemo {
13 /* input data and the counter to record the input to be processed next */
17 /* current processing image related */
18 float[] m_image; // Icur/Jpyr1
21 float[] m_image_resized; // Jpyr2
42 /* benchmark constants */
45 int SUPPRESION_RADIUS;
51 public TrackDemo(int nump) {
52 this.m_inputs = new int[2][];
54 int rows = 10 * 60; // * 2;
57 this.m_inputs[0] = this.makeImage(rows, cols, offset);
59 this.m_inputs[1] = this.makeImage(rows, cols, offset);
66 this.N_FEA = 16; //00;
67 this.SUPPRESION_RADIUS = 10;
69 this.accuracy = (float)0.03;
76 this.accuracy = (float)0.1;
90 this.m_3f = new float[3][this.N_FEA];
91 this.m_rows_3f = this.N_FEA;
92 this.m_cols_3f = 1; //this.N_FEA;
93 this.m_counter_3f = 3;
99 this.m_image_resized = null;
103 this.m_features = null;
108 public int getNumP() {
112 public boolean isFinish() {
113 return (this.m_count == this.m_counter);
116 public int getRows() {
120 public int getCols() {
124 public float[] getImage() {
128 public int getRowsR() {
129 return this.m_rows_r;
132 public int getColsR() {
133 return this.m_cols_r;
136 public float[] getImageR() {
137 return this.m_image_resized;
140 public int[] getInput(boolean isadvance) {
141 int[] input = this.m_inputs[this.m_count];
149 public void setBPNum(int num) {
153 public void setBPLNum(int num) {
154 this.m_num_bpl = num;
157 public int[] makeImage(int rows,
163 out = new int[rows * cols + 4];
166 out[2] = rows * cols;
170 for(i=0; i<rows; i++) {
171 for(j=0; j<cols; j++) {
172 out[i*cols+j+4] = ((k++)*rows)%255;
179 public boolean addBP(BlurPiece bp) {
180 int startRow = bp.getRowsRS();
181 int endRow = bp.getRowsRE();
183 float[] image, input;
185 if(this.m_image == null) {
186 this.m_rows = bp.getRows();
187 this.m_cols = bp.getCols();
188 this.m_image = new float[this.m_rows * this.m_cols];
190 image = this.m_image;
193 input = bp.getResult();
195 for(i = startRow; i < endRow; i++) {
196 for(j = 0; j < cols; j++) {
197 image[i * cols + j] = input[k * cols + j];
203 return (0 == this.m_num_bp);
206 public boolean addBPL(BlurPieceL bpl) {
207 int startRow = bpl.getRowsRS();
208 int endRow = bpl.getRowsRE();
210 float[] image, input;
212 if(this.m_image == null) {
213 this.m_rows = bpl.getRows();
214 this.m_cols = bpl.getCols();
215 this.m_image = new float[this.m_rows * this.m_cols];
217 image = this.m_image;
220 input = bpl.getResult();
222 for(i = startRow; i < endRow; i++) {
223 for(j = 0; j < cols; j++) {
224 image[i * cols + j] = input[k * cols + j];
230 return (0 == this.m_num_bpl);
233 public void postBlur() {
239 int kernelSize, startCol, endCol, halfKernel, startRow, endRow, kernelSum;
244 image = this.m_image;
259 startCol = 2; //((kernelSize)/2);
260 endCol = cols - 2; //round(cols - (kernelSize/2));
261 halfKernel = 2; //(kernelSize-1)/2;
263 startRow = 2; //(kernelSize)/2;
264 endRow = rows-2; //(rows - (kernelSize)/2);
266 for(i=startRow; i<endRow; i++) {
267 for(j=startCol; j<endCol; j++) {
269 for(k=-halfKernel; k<=halfKernel; k++) {
270 temp += (float)((image[(i+k) * cols + j]
271 * (float)(kernel[k+halfKernel])));
273 image[i * cols + j] = (float)(temp/kernelSum);
278 public void resize() {
283 int kernelSize, startCol, endCol, halfKernel, startRow, endRow, kernelSum;
284 int outputRows, outputCols;
288 float[] image, resized;
289 int rows = this.m_rows;
290 int cols = this.m_cols;
292 // level 1 is the base image.
294 outputRows = (int)(Math.floor((rows+1)/2));
295 outputCols = (int)(Math.floor((cols+1)/2));
299 temp = new float[rows_t * cols_t];
301 this.m_rows_r = outputRows;
302 this.m_cols_r = outputCols;
303 resized = this.m_image_resized = new float[this.m_rows_r * this.m_cols_r];
304 image = this.m_image;
308 kernel = new int[rows_k * cols_k];
319 startCol = 2; //(kernelSize/2);
320 endCol = cols - 2; //(int)(cols - (kernelSize/2));
321 halfKernel = 2; //(kernelSize-1)/2;
323 startRow = 2; //kernelSize/2;
324 endRow = rows - 2; //(rows - (kernelSize)/2);
326 for(i=startRow; i<endRow; i++) {
328 for(j=startCol; j<endCol; j+=2) {
330 for(k=-halfKernel; k<=halfKernel; k++) {
331 tempVal += (float)(image[i * cols + (j+k)]
332 * (float)(kernel[k+halfKernel]));
334 temp[i * outputCols + m] = (float)(tempVal/kernelSum);
340 for(i=startRow; i<endRow; i+=2) {
341 for(j=0; j<outputCols; j++) {
343 for(k=-halfKernel; k<=halfKernel; k++) {
344 tempVal += (float)(temp[(i+k) * outputCols + j]*kernel[k+halfKernel]);
346 resized[m * outputCols + j] = (float)(tempVal/kernelSum);
352 public boolean addIDX(IDX idx) {
353 float[][] m3f = this.m_3f;
354 int rows = idx.getRowsRS();
355 int rowe = idx.getRowsRE();
356 int threshold = this.N_FEA;
357 int[] ind = idx.getInd();
358 float[] image = idx.getImage();
360 int nfea = this.N_FEA;
361 int length = this.m_rows * this.m_cols;
362 int[] h_ind = new int[this.N_FEA];
363 boolean[] f_ind = new boolean[this.N_FEA];
364 for(int i = 0; i < this.N_FEA; i++) {
371 for(int i = rows; i < rowe; i++) {
372 rindex = length - ind[j];
374 localindex = j + rows;
377 m3f[2][rindex] = image[localindex];
378 h_ind[rindex] = localindex;
380 m3f[0][rindex] = Math.ceilf((float)(localindex / (float)r));
381 m3f[1][rindex] = (float)localindex
382 -(m3f[0][rindex]-1)*(float)r*(float)1.0;
383 f_ind[rindex] = true;
385 // previously held by some others with the same value
386 int k = rindex; // the place to insert
387 int k1 = rindex; // the first one which is not set
388 for(; k1 < nfea; k1++) {
389 if(h_ind[k1] > localindex) {
397 //System.printI(77777777);
399 } else if(k == rindex) {
402 if(f_ind[k] && (m3f[2][k] != image[localindex])) {
403 //System.printI(88888888);
406 // move all things after k behind
409 m3f[2][p] = m3f[2][p-1];
410 h_ind[p] = h_ind[p-1];
411 m3f[0][p] = m3f[0][p-1];
412 m3f[1][p] = m3f[1][p-1];
416 m3f[2][p] = image[localindex];
417 h_ind[p] = localindex;
419 m3f[0][p] = Math.ceilf((float)(localindex / (float)r));
420 m3f[1][p] = (float)localindex
421 -(m3f[0][p]-1)*(float)r*(float)1.0;
430 return (0 == this.m_num_p);
433 public void calcFeatures() {
435 int rows_f1, cols_f1, rows_f2, cols_f2, rows_f3, cols_f3;
436 float[] interestPnts;
437 int[] rows_ip, cols_ip;
438 int rows_ipt, cols_ipt;
439 rows_ip = new int[1];
440 cols_ip = new int[1];
445 rows_f1 = this.m_rows_3f;
446 rows_f2 = this.m_rows_3f;
447 rows_f3 = this.m_rows_3f;
448 cols_f1 = this.m_cols_3f;
449 cols_f2 = this.m_cols_3f;
450 cols_f3 = this.m_cols_3f;
452 interestPnts = this.getANMs(f1,
463 rows_ipt = rows_ip[0];
464 cols_ipt = cols_ip[0];
465 rows_ip = cols_ip = null;
467 // fTranspose(interestPnts)
469 int i, j, k, rows_trans, cols_trans;
471 rows_trans = cols_ipt;
472 cols_trans = rows_ipt;
473 trans = new float[rows_trans * cols_trans];
476 for(i=0; i<cols_ipt; i++) {
477 for(j=0; j<rows_ipt; j++) {
478 trans[k++] = interestPnts[j * cols_ipt + i];
482 // fDeepCopyRange(interestPnt, 0, 2, 0, cols_ip[0])
486 int numberCols = cols_trans;
489 rows = numberRows + startRow;
490 cols = numberCols + startCol;
492 rows_ipt = numberRows;
493 cols_ipt = numberCols;
494 interestPnts = new float[rows_ipt * cols_ipt];
497 for(i=startRow; i<rows; i++) {
498 for(j=startCol; j<cols; j++) {
499 interestPnts[k++] = trans[i*cols_trans+j];
505 this.m_cols_f = cols_ipt;
506 features = this.m_features = new float[this.m_rows_f * this.m_cols_f];
508 for(j=0; j<cols_ipt; j++) {
509 features[i * cols_ipt + j] = interestPnts[i * cols_ipt + j];
514 public float[] horzcat(float[] f1,
524 int rows=0, cols=0, i, j, k, c_1, c_2, r_3, c_3;
538 out = new float[rows * cols];
540 for(i=0; i<rows; i++) {
542 for(j=0; j<c_1; j++) {
543 out[i*cols+k] = f1[i*c_1+j];
546 for(j=0; j<c_2; j++) {
547 out[i*cols+k] = f2[i*c_2+j];
550 for(j=0; j<c_3; j++) {
551 out[i*cols+k] = f3[i*c_3+j];
559 public int[] fSortIndices(float[] input,
567 in = new float[input.length];
568 for(i=0; i<input.length; i++) {
572 ind = new int[rows * cols];
574 for(k=0; k<cols; k++) {
575 for(i=0; i<rows; i++) {
576 float localMax = in[i * cols + k];
578 ind[i * cols + k] = i;
579 for(j=0; j<rows; j++) {
580 if(localMax < in[j*cols+k]) {
581 ind[i * cols + k] = j;
582 localMax = in[j * cols + k];
586 in[localIndex * cols + k] = 0;
593 public float[] ffVertcat(float[] matrix1,
600 int rows_o, cols_o, i, j, k;
602 rows_o = rows_m1 + rows_m2;
604 outMatrix = new float[rows_o * cols_o];
606 for( i=0; i<cols_m1; i++) {
607 for (j=0; j<rows_m1; j++) {
608 outMatrix[j * cols_m1 + i] = matrix1[j * cols_m1 + i];
610 for( k=0; k<rows_m2; k++) {
611 outMatrix[(k+rows_m1) * cols_m1 + i] = matrix2[ k * cols_m2 + i];
619 public float[] getANMs(float[] f1,
630 float MAX_LIMIT = (float)100000000;
631 float C_ROBUST = (float)1.0;
632 float[] suppressR, points, srtdPnts, tempF, srtdV, interestPnts, temp;
633 int rows_sr, cols_sr, rows_p, cols_p, rows_sp, cols_sp, rows_tf, cols_tf;
634 int rows_sv, cols_sv, rows_tmp, cols_tmp;
635 int[] srtdVIdx, supId;
636 int rows_svi, cols_svi, rows_si, cols_si;
638 int n, i, j, k, validCount, cnt, end, iter, rows, cols;
641 r_sq = (float)(this.SUPPRESION_RADIUS ^ 2);
642 points = this.horzcat (f1,
652 cols_p = cols_f1 + cols_f2 + cols_f3;
655 /** sort() arg 2 is for descend = 1, arg3 = indices. Returns sorted values **/
657 srtdVIdx = this.fSortIndices (f3, rows_f3, cols_f3);
663 srtdPnts = new float[rows_sp * cols_sp];
665 for (i = 0; i < rows_sp; i++) {
666 for(j=0; j<cols_sp; j++) {
667 srtdPnts[i*cols_sp+j] = points[srtdVIdx[i]*cols_sp+j];
673 temp = new float[rows_tmp * cols_tmp];
676 suppressR = new float[rows_sr * cols_sr];
677 for(i = 0; i < rows_sr; i++) {
678 for(j = 0; j < cols_sr; j++) {
679 suppressR[i*cols_sr+j] = MAX_LIMIT;
685 for (i = 0; i < rows_sr; i++) {
686 if (suppressR[i] > r_sq) {
692 rows_si = validCount;
694 supId = new int[rows_si * cols_si];
695 for (i = 0; i < (rows_sr*cols_sr); i++) {
696 if (suppressR[i] > r_sq) {
701 while (validCount > 0) {
702 float[] tempp, temps;
703 int rows_tpp, cols_tpp, rows_tps, cols_tps;
704 temp[0] = srtdPnts[supId[0] * cols_sp + 0];
705 temp[1] = srtdPnts[supId[0] * cols_sp + 1];
706 temp[2] = srtdPnts[supId[0] * cols_sp + 2];
710 rows_ip[0] = rows_tmp;
711 cols_ip[0] = cols_tmp;
713 interestPnts = this.ffVertcat(interestPnts,
719 rows_ip[0] = rows_ip[0] + rows_tmp;
720 cols_ip[0] = cols_ip[0];
728 tempp = new float[rows_tpp * cols_tpp];
729 for(i=0; i<rows_tpp * cols_tpp; i++) {
730 tempp[i] = srtdPnts[i];
735 temps = new float[rows_tps * cols_tps];
736 for(i=0; i<rows_tps * cols_tps; i++) {
737 temps[i] = suppressR[i];
740 rows_sp = validCount - 1;
742 srtdPnts = new float[rows_sp * cols_sp];
743 rows_sr = validCount - 1;
745 suppressR = new float[rows_sr * cols_sr];
748 for(i=0; i<(validCount-1); i++) {
749 srtdPnts[i * cols_sp + 0] = tempp[supId[i+1] * cols_sp + 0];
750 srtdPnts[i * cols_sp + 1] = tempp[supId[i+1] * cols_sp + 1];
751 srtdPnts[i * cols_sp + 2] = tempp[supId[i+1] * cols_sp + 2];
752 suppressR[i * cols_sr + 0] = temps[supId[i+1] * cols_sr + 0];
755 int rows1 = rows_ip[0]-1;
756 int cols1 = cols_ip[0];
757 for (i = 0; i < rows_sp; i++) {
761 if ((C_ROBUST * interestPnts[rows1 * cols1 + 2])
762 >= srtdPnts[i * cols_sp + 2]) {
763 t = srtdPnts[i * cols_sp + 0] - interestPnts[rows1 * cols1 + 0];
764 t1 = srtdPnts[i * cols_sp + 1] - interestPnts[rows1 * cols1 + 1];
769 if ((C_ROBUST * interestPnts[rows1 * cols1 + 2])
770 < srtdPnts[i * cols_sp + 2]) {
771 t1 = (float)1 * (float)MAX_LIMIT;
774 if (suppressR[i] > (t + t1)) {
775 suppressR[i] = t + t1;
780 for (i = 0; i < rows_sr; i++) {
781 if (suppressR[i] > r_sq) {
787 rows_si = validCount;
789 supId = new int[rows_si * cols_si];
791 for (i = 0; i < rows_sr*cols_sr; i++) {
792 if (suppressR[i] > r_sq) {
801 public void startTrackingLoop() {
803 this.m_image_resized = null;
806 public float[] getInterpolatePatch(float[] src,
813 float a, b, a11, a12, a21, a22;
814 int i, j, srcIdxX, dstIdxX, srcIdy, dstIdy, dstIndex;
816 a = centerX - (float)(Math.floor(centerX));
817 b = centerY - (float)(Math.floor(centerY));
825 cols_d = 2*this.WINSZ*2*this.WINSZ;
826 dst = new float[rows_d * cols_d];
828 for(i=-this.WINSZ; i<=(this.WINSZ-1); i++) {
829 srcIdxX = (int)(Math.floor(centerX)) + i;
830 dstIdxX = i+this.WINSZ;
832 for(j=-this.WINSZ; j<=(this.WINSZ-1); j++) {
833 srcIdy = (int)(Math.floor(centerY)) + j;
834 dstIdy = j+this.WINSZ;
835 dstIndex = dstIdy * 2 * this.WINSZ + dstIdxX;
836 // printf("%f\t%f\t%d\t%d\n", centerX, centerY, srcIdxX, srcIdy);
837 dst[dstIndex] = src[srcIdy * cols + srcIdxX]*a11
838 + src[(srcIdy+1)* cols + srcIdxX]*a12
839 + src[srcIdy * cols + (srcIdxX+1)]*a21
840 + src[(srcIdy+1) * cols+ (srcIdxX+1)]*a22;
847 public int[] calcPyrLKTrack(float[][] Ipyrs,
851 float[] ip1, ip2, idxp1, idxp2, idyp1, idyp2, jp1, jp2, fPnt;
861 jp2 = this.m_image_resized;
862 fPnt = this.m_features;
864 int idx, level, pLevel, i, winSizeSq;
865 int[] valid, imgDims;
866 int rows_v, cols_v, rows_id, cols_id;
867 float[] rate, iPatch, jPatch, iDxPatch, iDyPatch;
868 int rows_r, cols_r, rows_ip, cols_ip, rows_jp, cols_jp;
869 int rows_idxp, cols_idxp, rows_idyp, cols_idyp;
870 float x, y, dX, dY, c_xx, c_yy, c_xy, tr;
871 int imgSize_1, /*max_iter, */imgSize_2;
872 float mX, mY, dIt, eX, eY, c_det;
873 int nFeatures = this.m_cols_f;
877 imgDims = new int[rows_id * cols_id];
879 imgDims[0] = rows[0];
880 imgDims[1] = cols[0];
881 imgDims[2] = rows[1];
882 imgDims[3] = cols[1];
887 rate = new float[rows_r * cols_r];
890 rate[1] = (float)0.5;
891 rate[2] = (float)0.25;
892 rate[3] = (float)0.125;
893 rate[4] = (float)0.0625;
894 rate[5] = (float)0.03125;
896 winSizeSq = 4*this.WINSZ*this.WINSZ;
899 iPatch = new float[rows_ip * cols_ip];
902 jPatch = new float[rows_jp * cols_jp];
904 cols_idxp = winSizeSq;
905 iDxPatch = new float[rows_idxp * cols_idxp];
907 cols_idyp = winSizeSq;
908 iDyPatch = new float[rows_idyp * cols_idyp];
912 valid = new int[rows_v * cols_v];
913 for(int valid_idx=0;valid_idx<valid.length;valid_idx++){
917 for(i=0; i<nFeatures; i++) {
920 x = fPnt[i*2+0] * rate[pLevel];
921 y = fPnt[i*2+1] * rate[pLevel];
924 for(level = pLevel-1; level>=0; level--) {
929 imgSize_1 = imgDims[level*2];
930 imgSize_2 = imgDims[level*2+1];
936 if( (x-(float)this.WINSZ)<(float)0 || (y-(float)this.WINSZ)<(float)0
937 || (y+(float)this.WINSZ)>=(float)imgSize_1
938 || (x+(float)this.WINSZ)>=(float)imgSize_2 ) {
944 iPatch = getInterpolatePatch(ip1, rows[0], cols[0], x, y);
945 iDxPatch = getInterpolatePatch(idxp1, rows[2], cols[2], x, y);
946 iDyPatch = getInterpolatePatch(idyp1, rows[3], cols[3], x, y);
949 iPatch = getInterpolatePatch(ip2, rows[1], cols[1], x, y);
950 iDxPatch = getInterpolatePatch(idxp2, rows[4], cols[4], x, y);
951 iDyPatch = getInterpolatePatch(idyp2, rows[5], cols[5], x, y);
953 rows_ip = rows_idxp = rows_idyp = 1;
954 cols_ip = cols_idxp = cols_idyp = 2*this.WINSZ*2*this.WINSZ;
956 for(idx=0; idx<this.WINSZ; idx++) {
957 c_xx += iDxPatch[idx] * iDxPatch[idx];
958 c_xy += iDxPatch[idx] * iDyPatch[idx];
959 c_yy += iDyPatch[idx] * iDyPatch[idx];
962 c_det = (c_xx * c_yy -c_xy * c_xy);
965 if(c_det == (float)0) {
969 if((float)(c_det/(tr+(float)0.00001)) < (float)this.accuracy) {
974 c_det = (float)(1/c_det);
975 for(k=0; k<this.LK_ITER;/*max_iter; */k++) {
976 if( (x+dX-(float)this.WINSZ)<(float)0 || (y+dY-(float)this.WINSZ)<(float)0
977 || (y+dY+(float)this.WINSZ)>=(float)imgSize_1
978 || (x+dX+(float)this.WINSZ)>=(float)imgSize_2) {
983 // printf("x and dx = %d\t%d\t%f\t%f\t%f\t%f\n", i, level, x, dX, y, dY);
985 jPatch = getInterpolatePatch(jp1,
992 jPatch = getInterpolatePatch(jp2,
999 cols_jp = 2*this.WINSZ*2*this.WINSZ;
1003 for(idx=0; idx<winSizeSq; idx++) {
1004 dIt = iPatch[idx] - jPatch[idx];
1005 eX += dIt * iDxPatch[idx];
1006 eY += dIt * iDyPatch[idx];
1009 mX = c_det * (eX * c_yy - eY * c_xy);
1010 mY = c_det * (-eX * c_xy + eY * c_xx);
1011 // printf("mx = %d\t%d\t%f\t%f\t%f\t%f\t%f\n", i, level, mX, mY, c_det, eX, eY);
1015 if( (mX*mX+mY+mY) < this.accuracy) {
1021 newPnt[i] = fPnt[i*2] + dX;
1022 newPnt[1*nFeatures+i] = fPnt[i*2+1] + dY;
1029 public void calcTrack(IXLM ixlm,
1033 float[][] Ipyrs = new float[6][];
1034 int[] rows = new int[6];
1035 int[] cols = new int[6];
1036 float[] newpoints, features, np_temp;
1037 int rows_n, cols_n, rows_np, cols_np, i, j, k, m, n, numFind;
1041 Ipyrs[0] = ixlm.getImage();
1042 rows[0] = ixlm.getRows();
1043 cols[0] = ixlm.getCols();
1044 Ipyrs[2] = ixlm.getResult();
1045 rows[2] = ixlm.getRowsR();
1046 cols[2] = ixlm.getColsR();
1047 Ipyrs[3] = iylm.getResult();
1048 rows[3] = iylm.getRowsR();
1049 cols[3] = iylm.getColsR();
1051 Ipyrs[1] = ixlmr.getImage();
1052 rows[1] = ixlmr.getRows();
1053 cols[1] = ixlmr.getCols();
1054 Ipyrs[4] = ixlmr.getResult();
1055 rows[4] = ixlmr.getRowsR();
1056 cols[4] = ixlmr.getColsR();
1057 Ipyrs[5] = iylmr.getResult();
1058 rows[5] = iylmr.getRowsR();
1059 cols[5] = iylmr.getColsR();
1061 features = this.m_features;
1063 cols_n = this.m_cols_f;
1064 newpoints = new float[rows_n * cols_n];
1066 // status_ = calcPyrLKTrack(...)
1067 status = this.calcPyrLKTrack(Ipyrs, rows, cols, newpoints);
1069 cols_s = this.m_cols_f;
1072 np_temp = new float[newpoints.length];
1075 for(i = 0; i < newpoints.length; i++) {
1076 np_temp[i] = newpoints[i];
1079 if(rows_s*cols_s > 0 ) {
1082 rows_f = rows_s * cols_s;
1084 findInd = new int[rows_f * cols_f];
1089 for(i=0; i<cols_s; i++) {
1090 for(j=0; j<rows_s; j++) {
1091 if(status[j*cols_s+i] != 0) {
1105 newpoints = new float[rows_n * cols_n];
1109 for(i=0; i<rows_np; i++) {
1110 for(j=0; j<cols_np; j++) {
1113 newpoints[k++] = np_temp[i*cols_np+m];
1119 // features_ = fDeepCopy(newpoints_);
1120 this.m_rows_f = rows_n;
1121 this.m_cols_f = cols_n;
1122 features = this.m_features = new float[newpoints.length];
1123 for(k = 0; k < newpoints.length; k++) {
1124 features[k] = newpoints[k];
1128 public void printImage() {
1129 // result validation
1130 for(int i=0; i<this.m_rows; i++) {
1131 for(int j=0; j<this.m_cols; j++) {
1132 System.printI((int)(this.m_image[i * this.m_cols + j]*10));
1137 public void print3f() {
1138 // result validation
1139 System.printI(11111111);
1140 for(int j=0; j<this.N_FEA; j++) {
1141 System.printI((int)(this.m_3f[0][j]*10));
1143 System.printI(22222222);
1144 for(int j=0; j<this.N_FEA; j++) {
1145 System.printI((int)(this.m_3f[1][j]*10));
1147 System.printI(33333333);
1148 for(int j=0; j<this.N_FEA; j++) {
1149 System.printI((int)(this.m_3f[2][j]*10));
1153 public void printFeatures() {
1154 // result validation
1155 for(int i=0; i<this.m_rows_f; i++) {
1156 for(int j=0; j<this.m_cols_f; j++) {
1157 System.printI((int)(this.m_features[i * this.m_cols_f + j]*10));