#NEWLINE# def _is_mri_subject( subject , subjects_dir = None ) : #NEWLINE# #INDENT# 'Check whether a directory in subjects_dir is an mri subject directory\n\n    Parameters\n    ----------\n    subject : str\n        Name of the potential subject/directory.\n    subjects_dir : None | str\n        Override the SUBJECTS_DIR environment variable.\n\n    Returns\n    -------\n    is_mri_subject : bool\n        Whether ``subject`` is an mri subject.\n    ' #NEWLINE# subjects_dir = get_subjects_dir ( subjects_dir , raise_error = True ) #NEWLINE# fname = head_bem_fname . format ( subjects_dir = subjects_dir , subject = subject ) #NEWLINE# if ( not os . path . exists ( fname ) ) : #NEWLINE# #INDENT# return False #NEWLINE# #UNINDENT# return True