Gravar-mail: An automated lung segmentation approach using bidirectional chain codes to improve nodule detection accuracy