File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
main/scala/com/intel/analytics/bigdl/nn
test/scala/com/intel/analytics/bigdl/nn/tf Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -319,7 +319,8 @@ object SpatialBatchNormalization {
319
319
val offsetOffset = offset.storageOffset() - 1
320
320
var isIdenticalScale = false
321
321
var identicalScale = 0.0f
322
- if (scale.stride().length == 1 && scale.stride()(0 ) == 0 && scaleData.length == 1 ) {
322
+
323
+ if (scaleData.length == 1 ) {
323
324
isIdenticalScale = true
324
325
identicalScale = scaleData(0 )
325
326
}
Original file line number Diff line number Diff line change @@ -27,6 +27,9 @@ import org.tensorflow.example.Example
27
27
class DecodeBmpSerialTest extends ModuleSerializationTest {
28
28
private def getInputs (name : String ): Tensor [ByteString ] = {
29
29
import com .intel .analytics .bigdl .utils .tf .TFTensorNumeric .NumericByteString
30
+ /* since the tfrecord file is loaded into byteArrays regardless of the
31
+ original image type, we can map "bmp" to 0 as well
32
+ */
30
33
val index = name match {
31
34
case " png" => 0
32
35
case " jpeg" => 1
You can’t perform that action at this time.
0 commit comments