The method generator.next() in listing 7.17 collapses under Python 3.10 with an error message: AttributeError: 'DataGenerator' object has no attribute 'next'
How to transform the code for it to work?
The code:
from dlgo.data.parallel_processor import GoDataProcessor
The method generator.next() in listing 7.17 collapses under Python 3.10 with an error message: AttributeError: 'DataGenerator' object has no attribute 'next' How to transform the code for it to work?
The code: from dlgo.data.parallel_processor import GoDataProcessor
processor = GoDataProcessor() generator = processor.load_go_data('train', 100, use_generator=True) print(generator.get_num_samples()) generator = generator.generate(batch_size=10) X, y = generator.next()