def validate(self, path: str, strictness: str = "<STR_LIT>") -> bool:
valid1 = True<EOL>with h5py.File(path, mode="<STR_LIT:r>") as f:<EOL><INDENT>valid1 = self.validate_spec(f)<EOL>if not valid1:<EOL><INDENT>self.errors.append("<STR_LIT>")<EOL><DEDENT><DEDENT>valid2 = True<EOL>if strictness == "<STR_LIT>":<EOL><INDENT>with loompy.connect(path, mode="<STR_LIT:r>") as ds:<EOL><INDENT>valid2 = self.validate_conventions(ds)<EOL>if not valid2:<EOL><INDENT>self.errors.append("<STR_LIT>")<EOL><DEDENT><DEDENT><DEDENT>return valid1 and valid2<EOL>
Validate a file for conformance to the Loom specification

Args:
        path: 			Full path to the file to be validated
        strictness:		"speconly" or "conventions"

Remarks:
        In "speconly" mode, conformance is assessed relative to the file format specification
        at http://linnarssonlab.org/loompy/format/. In "conventions" mode, conformance is additionally
        assessed relative to attribute name and data type conventions given at http://linnarssonlab.org/loompy/conventions/.