(self, left, right)
| 157 | raise NotImplementedError() |
| 158 | |
| 159 | def preprocess(self, left, right): |
| 160 | x = tf.concat([left, right], axis=0) # 2CHW |
| 161 | rgb_mean = tf.reduce_mean(x, axis=[0, 2, 3], keep_dims=True) |
| 162 | return (x - rgb_mean) / 255. |
| 163 | |
| 164 | def postprocess(self, prediction): |
| 165 | return resize(prediction * DISP_SCALE, mode='bilinear') |