Detection and diagnosis of lung phenotypes in severe pneumonia