Skip to content

Commit

Permalink
allow running process_data function when loading from cachedata
Browse files Browse the repository at this point in the history
  • Loading branch information
kervias committed Dec 4, 2023
1 parent 4368f53 commit ba3cbb6
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions edustudio/datatpl/common/general_datatpl.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ def __init__(
if self.datatpl_cfg['load_data_from'] == 'cachedata':
self.load_cache()
self.check_cache()
self.process_data()
self.logger.info(f"Load from cache successfully: {self.datatpl_cfg['cache_id']}")
self.logger.info(self.datatpl_cfg['dt_info'])
else:
Expand Down Expand Up @@ -141,8 +142,6 @@ def process_data(self):
load_data_from = self.datatpl_cfg['load_data_from']
if load_data_from != 'cachedata':
self.process_load_data_from_middata()
else:
raise ValueError(f"load_data_from={load_data_from} is not expected to appear here")

@classmethod
def load_data(cls, cfg): # 只在middata存在时调用
Expand Down

0 comments on commit ba3cbb6

Please sign in to comment.