Skip to content

Commit 1f81d2a

Browse files
committedOct 1, 2024·
improve javadoc
1 parent e0cc2a8 commit 1f81d2a

File tree

1 file changed

+0
-42
lines changed

1 file changed

+0
-42
lines changed
 

Diff for: ‎src/main/java/io/bioimage/modelrunner/pytorch/tensor/ImgLib2Builder.java

-42
Original file line numberDiff line numberDiff line change
@@ -84,13 +84,6 @@ public static < T extends RealType< T > & NativeType< T > > RandomAccessibleInte
8484
}
8585
}
8686

87-
/**
88-
* Builds a {@link Img} from a unsigned byte-typed {@link NDArray}.
89-
*
90-
* @param tensor
91-
* The {@link NDArray} data is read from.
92-
* @return The {@link Img} built from the tensor of type {@link UnsignedByteType}.
93-
*/
9487
private static RandomAccessibleInterval<UnsignedByteType> buildFromTensorUByte(NDArray tensor) {
9588
long[] arrayShape = tensor.getShape().getShape();
9689
if (CommonUtils.int32Overflows(arrayShape, 1))
@@ -103,13 +96,6 @@ private static RandomAccessibleInterval<UnsignedByteType> buildFromTensorUByte(N
10396
return Utils.transpose(rai);
10497
}
10598

106-
/**
107-
* Builds a {@link Img} from a signed byte-typed {@link NDArray}.
108-
*
109-
* @param tensor
110-
* The {@link NDArray} data is read from.
111-
* @return The {@link Img} built from the tensor of type {@link ByteType}.
112-
*/
11399
private static RandomAccessibleInterval<ByteType> buildFromTensorByte(NDArray tensor) {
114100
long[] arrayShape = tensor.getShape().getShape();
115101
if (CommonUtils.int32Overflows(arrayShape, 1))
@@ -122,13 +108,6 @@ private static RandomAccessibleInterval<ByteType> buildFromTensorByte(NDArray te
122108
return Utils.transpose(rai);
123109
}
124110

125-
/**
126-
* Builds a {@link RandomAccessibleInterval} from a signed integer-typed {@link NDArray}.
127-
*
128-
* @param tensor
129-
* The {@link NDArray} data is read from.
130-
* @return The {@link RandomAccessibleInterval} built from the tensor of type {@link IntType}.
131-
*/
132111
private static RandomAccessibleInterval<IntType> buildFromTensorInt(NDArray tensor) {
133112
long[] arrayShape = tensor.getShape().getShape();
134113
if (CommonUtils.int32Overflows(arrayShape, 1))
@@ -141,13 +120,6 @@ private static RandomAccessibleInterval<IntType> buildFromTensorInt(NDArray tens
141120
return Utils.transpose(rai);
142121
}
143122

144-
/**
145-
* Builds a {@link RandomAccessibleInterval} from a signed float-typed {@link NDArray}.
146-
*
147-
* @param tensor
148-
* The {@link NDArray} data is read from.
149-
* @return The {@link RandomAccessibleInterval} built from the tensor of type {@link FloatType}.
150-
*/
151123
private static RandomAccessibleInterval<FloatType> buildFromTensorFloat(NDArray tensor) {
152124
long[] arrayShape = tensor.getShape().getShape();
153125
if (CommonUtils.int32Overflows(arrayShape, 1))
@@ -160,13 +132,6 @@ private static RandomAccessibleInterval<FloatType> buildFromTensorFloat(NDArray
160132
return Utils.transpose(rai);
161133
}
162134

163-
/**
164-
* Builds a {@link RandomAccessibleInterval} from a signed double-typed {@link NDArray}.
165-
*
166-
* @param tensor
167-
* The {@link NDArray} data is read from.
168-
* @return The {@link RandomAccessibleInterval} built from the tensor of type {@link DoubleType}.
169-
*/
170135
private static RandomAccessibleInterval<DoubleType> buildFromTensorDouble(NDArray tensor) {
171136
long[] arrayShape = tensor.getShape().getShape();
172137
if (CommonUtils.int32Overflows(arrayShape, 1))
@@ -179,13 +144,6 @@ private static RandomAccessibleInterval<DoubleType> buildFromTensorDouble(NDArra
179144
return Utils.transpose(rai);
180145
}
181146

182-
/**
183-
* Builds a {@link RandomAccessibleInterval} from a signed long-typed {@link NDArray}.
184-
*
185-
* @param tensor
186-
* The {@link NDArray} data is read from.
187-
* @return The {@link RandomAccessibleInterval} built from the tensor of type {@link DoubleType}.
188-
*/
189147
private static RandomAccessibleInterval<LongType> buildFromTensorLong(NDArray tensor) {
190148
long[] arrayShape = tensor.getShape().getShape();
191149
if (CommonUtils.int32Overflows(arrayShape, 1))

0 commit comments

Comments
 (0)
Please sign in to comment.