Relapse in Tuberculosis (TB) patients represents an important challenge to improve treatment. A large number of patients undergo relapse even after what was thought to be a successful treatment. Lipid rich (LR) bacteria, surviving treatment, are thought to play a key role in patient relapse. The presence of bacteria with intracellular lipid bodies in patients sputum was linked to higher risk of poor treatment outcome. LR bacteria can be stained and detected using fluorescence microscopy. However, manual counting of bacteria makes this method too labour intensive and potentially biased to be routinely used in practice or to foster large-scale data sets which would inform and drive future research efforts. In this paper we propose a new algorithm for automatic estimation of the number of bacteria present in images generated with fluorescence microscopy. Our approach comprises elements of image processing, computer vision and machine learning. We demonstrated the effectiveness of the method by testing it on fluorescence microscopy images of in vitro grown M. smegmatis cells stained with Nile red.