diff --git a/pysegcnn/core/graphics.py b/pysegcnn/core/graphics.py index a1b64a9b847d952db6771f2a43bbfffe11e793f4..0b76ac3754719a5a67da60d95b72c0363abc672b 100644 --- a/pysegcnn/core/graphics.py +++ b/pysegcnn/core/graphics.py @@ -304,7 +304,7 @@ def plot_sample(x, use_bands, labels, # check whether the ground truth is specified and calculate accuracy if y is not None and accuracy: acc = accuracy_function(v, y) - k += ' ({:.2f}%)'.format(acc * 100) + k = '{:.2f}%'.format(acc * 100) # plot model prediction ax.imshow(v, cmap=cmap, interpolation='nearest', norm=norm) diff --git a/pysegcnn/core/trainer.py b/pysegcnn/core/trainer.py index 689f9c5306929721bf3e2c59f582ee5de4c0694b..206e780c149c9a19a0875b746091d5700dc4db6b 100644 --- a/pysegcnn/core/trainer.py +++ b/pysegcnn/core/trainer.py @@ -2591,19 +2591,12 @@ class NetworkInference(BaseConfig): # plot current scene if self.plot: - - # title for prediction - title = ''.join([ - (v[0] + str(k)) for k, v in - self.src_ds.dataset.sensor.band_dict().items() - if v in self.bands]) - # plot inputs, ground truth and model predictions fig = plot_sample(inputs.clip(0, 1), self.bands, self.use_labels, y=labels, - y_pred={title: prdctn}, + y_pred={'Prediction': prdctn}, accuracy=True, **self.plot_kwargs)