are you using `resource_check` below? (otherwise i'd write `if check_model_structure(model):`