This paper presents an original machine learning method for extracting diagnostic medical information from heart sound recordings. The method is proposed to be integrated with an intelligent phonocardiography in order to enhance diagnostic value of this technology. The method is tailored to diagnose children with heart septal defects, the pathological condition which can bring irreversible and sometimes fatal consequences to the children. The study includes 115 children referrals to an university hospital, consisting of 6 groups of the individuals: atrial septal defects (10), healthy children with innocent murmur (25), healthy children without any murmur (25), mitral regurgitation (15), tricuspid regurgitation (15), and ventricular septal defect (25). The method is trained to detect the atrial or ventricular septal defects versus the rest of the groups. Accuracy/sensitivity and the structural risk of the method is estimated to be 91.6%/88.4% and 9.89%, using the repeated random sub sampling and the A-Test method, respectively.