def plot_memory(self):

        """
        This function ...
        :return:
        """

        # Determine the path to the plot file
        plot_path = fs.join(self.output_path, "memory.pdf")

        # Initialize figure
        plt.figure()
        plt.clf()

        # Loop over the different processes
        for rank in range(len(self.data)):

            # Name of the current process
            process = "P" + str(rank)

            # Plot the memory usage
            plt.plot(self.data[rank].times, self.data[rank].memory, label=process)

        # Set the axis labels
        plt.xlabel("Time (s)", fontsize='large')
        plt.ylabel("Memory usage (GB)", fontsize='large')

        # Set the plot title
        plt.title("Memory consumption")

        # Set the legend
        if len(self.data) > 16: plt.legend(loc='upper center', ncol=8, bbox_to_anchor=(0.5, -0.1), prop={'size': 8})
        else: plt.legend(loc='lower right', ncol=4, prop={'size': 8})

        # Save the figure
        plt.savefig(plot_path, bbox_inches='tight', pad_inches=0.25)
        plt.close()