diff --git a/pyrelacs/dataio/nix_writer.py b/pyrelacs/dataio/nix_writer.py index be84a79..6b437f0 100644 --- a/pyrelacs/dataio/nix_writer.py +++ b/pyrelacs/dataio/nix_writer.py @@ -18,20 +18,19 @@ class NixWriter: chunk = 1000 log.debug("Starting the writing") self.write = True - - total_count = self.buffer.totalcount() while self.write: + total_count = self.buffer.totalcount() if total_count - items >= chunk: - log.debug(items) + # log.debug(items) try: data, _ = self.buffer.read(items, extend=chunk) self.data_array.append(data) except IndexError as e: - time.sleep(0.01) + time.sleep(0.001) log.debug(f"{e}") items += chunk else: - time.sleep(0.01) + time.sleep(0.001) continue log.debug("Stoppint the writing") log.debug(f"Samples written {items}")