A system for detecting a trachea of a patient, the system comprising: an imaging device configured to obtain image data of the patient; and a computing device including a processor and a memory storing instructions which, when executed by the processor, cause the computing device to: generate a three-dimensional model of the airway tree of the patient based on the image data; generate binarised slice images of the 3D model along an axial direction showing (i) high density areas and (ii) low density areas likely to be either trachea or lung; identify one or more connected components in each axial slice image of the generated slice images; label a first slice image as a top slice image of the generated slice images; label any connected components in the top slice image as an active object; for each of the further slice images, associate each connected component in a current slice image of the further slice images with a corresponding connected component in the preceding slice image of the current slice image based on a connectivity criterion; for each of the further slice images, label each connected component in the current slice image associated with a connected component of the preceding slice image as the same active object as the connected component of the preceding slice image; and identify one of the active objects as the trachea, based on a length of the active objects. an imaging device configured to obtain image data of the patient; and a computing device including a processor and a memory storing instructions which, when executed by the processor, cause the computing device to: generate a three-dimensional model of the airway tree of the patient based on the image data; generate binarised slice images of the 3D model along an axial direction showing (i) high density areas and (ii) low density areas likely to be either trachea or lung; identify one or more connected components in each axial slice image of the generated slice images; label a first slice image as a top slice image of the generated slice images; label any connected components in the top slice image as an active object; for each of the further slice images, associate each connected component in a current slice image of the further slice images with a corresponding connected component in the preceding slice image of the current slice image based on a connectivity criterion; for each of the further slice images, label each connected component in the current slice image associated with a connected component of the preceding slice image as the same active object as the connected component of the preceding slice image; and identify one of the active objects as the trachea, based on a length of the active objects. generate a three-dimensional model of the airway tree of the patient based on the image data; generate binarised slice images of the 3D model along an axial direction showing (i) high density areas and (ii) low density areas likely to be either trachea or lung; identify one or more connected components in each axial slice image of the generated slice images; label a first slice image as a top slice image of the generated slice images; label any connected components in the top slice image as an active object; for each of the further slice images, associate each connected component in a current slice image of the further slice images with a corresponding connected component in the preceding slice image of the current slice image based on a connectivity criterion; for each of the further slice images, label each connected component in the current slice image associated with a connected component of the preceding slice image as the same active object as the connected component of the preceding slice image; and identify one of the active objects as the trachea, based on a length of the active objects. <EOS>