private static SimpleFloat3 loadFC() { System.out.print("loading ... "); int nx = 256; int ny = 256; // int nz = 1000; int nz = 1000; int kz = 2000; SimpleFloat3 sf3; try { ArrayFile af = new ArrayFile(DATA_DIR + "CS_patient/CS_matrix.imgs", "r"); // ArrayFile af = // new ArrayFile(DATA_DIR+"FC_patient/FC_2000_2999.imgs","r"); af.seek(175 + kz * nx * ny); byte[][][] b = zerobyte(nx, ny, nz); af.readBytes(b); float[][][] f = zerofloat(nz, ny, nx); for (int ix = 0; ix < nx; ++ix) { for (int iy = 0; iy < ny; ++iy) { for (int iz = 0; iz < nz; ++iz) { int i = b[iz][iy][ix]; if (i < 0) i += 256; f[ix][iy][iz] = (float) i; } } } sf3 = new SimpleFloat3(f); } catch (IOException ioe) { throw new RuntimeException(ioe); } System.out.println("done"); return sf3; }