<s> import os <EOL> import warnings <EOL> import numpy as np <EOL> import orca <EOL> import pandas as pd <EOL> import yaml <EOL> warnings . filterwarnings ( '<STR_LIT:ignore>' , category = pd . io . pytables . PerformanceWarning ) <EOL> pd . options . mode . chained_assignment = None <EOL> @ orca . injectable ( ) <EOL> def set_random_seed ( ) : <EOL> pass <EOL> @ orca . injectable ( ) <EOL> def configs_dir ( ) : <EOL> return '<STR_LIT:.>' <EOL> @ orca . injectable ( ) <EOL> def data_dir ( ) : <EOL> return '<STR_LIT:.>' <EOL> @ orca . injectable ( ) <EOL> def settings ( configs_dir ) : <EOL> with open ( os . path . join ( configs_dir , "<STR_LIT>" , "<STR_LIT>" ) ) as f : <EOL> return yaml . load ( f ) <EOL> @ orca . injectable ( cache = True ) <EOL> def store ( data_dir , settings ) : <EOL> return pd . HDFStore ( os . path . join ( data_dir , "<STR_LIT:data>" , settings [ "<STR_LIT:store>" ] ) , <EOL> mode = '<STR_LIT:r>' ) <EOL> @ orca . injectable ( cache = True ) <EOL> def preload_3d_skims ( settings ) : <EOL> return bool ( settings . get ( '<STR_LIT>' , False ) ) <EOL> @ orca . injectable ( cache = True ) <EOL> def cache_lazy_loaded_skims ( settings ) : <EOL> return bool ( settings . get ( '<STR_LIT>' , False ) ) <EOL> @ orca . injectable ( cache = True ) <EOL> def cache_skim_key_values ( settings , preload_3d_skims , cache_lazy_loaded_skims ) : <EOL> if preload_3d_skims or cache_lazy_loaded_skims : <EOL> return settings [ '<STR_LIT>' ] [ '<STR_LIT>' ] <EOL> else : <EOL> return None </s>
