BackgroundRecent studies use machine-learning techniques to detect parasites in microscopy images automatically. However, these tools are trained and tested in specific datasets. Indeed, even if over-fitting is avoided during the improvements of computer vision applications, large differences are expected. Differences might be related to settings of camera (exposure, white balance settings, etc) and different blood film slides preparation. Moreover, generative adversial networks offer new opportunities in microscopy: data homogenization, and increase of images in case of imbalanced or small sample size.MethodsTaking into consideration all those aspects, in this paper, we describe a more complete view including both detection and generating synthetic images: i) an automated detection used to detect malaria parasites on stained blood smear images using machine learning techniques testing several datasets. ii) investigate transfer learning and further testing in different unseen datasets having different staining, microscope, resolution, etc. iii) a generative approach to create synthetic images which can deceive experts.ResultsThe tested architecture achieved 0.98 and 0.95 area under the ROC curve in classifying images with respectively thin and thick smear. Moreover, the generated images proved to be very similar to the original and difficult to be distinguished by an expert microscopist, which identified correcly the real data for one dataset but had 50% misclassification for another dataset of images.ConclusionThe proposed deep-learning architecture performed well on a classification task for malaria parasites classification. The automated detection for malaria can help the technician to reduce their work and do not need any presence of experts. Moreover, generative networks can also be applied to blood smear images to generate useful images for microscopists. Opening new ways to data augmentation, translation and homogenization.