Shortcuts

data.buffer.middleware.use_time_check

use_time_check

use_time_check

ding.data.buffer.middleware.use_time_check.use_time_check(buffer_: Buffer, max_use: int = inf) Callable[source]
Overview:

This middleware aims to check the usage times of data in buffer. If the usage times of a data is greater than or equal to max_use, this data will be removed from buffer as soon as possible.

Arguments:
  • max_use (int): The max reused (resampled) count for any individual object.