As of tensorflowjs 14.1, it appears that the BN does not work with data in
'channelsFirst' (NCHW). It treats all as 'channelsLast' (NHWC).
As a work-around, the network can now be built in either in channelsFirst or
channelsLast format. The 'webgl' backend gets a 'channelsLast' network and
the 'cpu' backend gets a 'channelsFirst' one.
Strangely, it appears that 'channelsFirst' is faster for both backends.
As of tensorflowjs 14.1, it appears that the BN does not work with data in 'channelsFirst' (NCHW). It treats all as 'channelsLast' (NHWC). As a work-around, the network can now be built in either in channelsFirst or channelsLast format. The 'webgl' backend gets a 'channelsLast' network and the 'cpu' backend gets a 'channelsFirst' one.
Strangely, it appears that 'channelsFirst' is faster for both backends.