import tensorflow as tf

        Calibrate input of shape (-1, w, h, ch) to (-1, w_out, h_out, ch_out), assuming (w, h) / (w_out, h_out) is power of 2
        '''
        # Downsample with factorized reduction
        downsample_no = 0
        while w > w_out or h > h_out:
            downsample_no += 1
            with tf.variable_scope('downsample_{}x'.format(downsample_no)):
                X = tf.nn.relu(X)
                X = self._add_factorized_reduction(X, w, h, ch, ch_out, is_train=is_train)
                ch = ch_out
                w >>= 1
                h >>= 1

        # If channel counts finally don't match, convert channel counts with 1x1 conv
