目标检测迁移学习_使用迁移学习检测疟疾

该博客探讨了如何运用目标检测的迁移学习技术来检测疟疾。通过深度学习和机器学习算法,特别是利用预训练模型,可以提高疟疾细胞识别的准确性。
摘要由CSDN通过智能技术生成

目标检测迁移学习

Written by Francesco Palma and Isaac Rosat

由Francesco Palma和Isaac Rosat撰写

In this article, we will first describe how malaria works and how to diagnose this disease, as well as the problems inherent to it. Then we will talk about the ML model used to detect malaria with the help of blood samples and the results of its performance.

在本文中,我们将首先描述疟疾的工作原理以及如何诊断这种疾病以及其固有的问题。 然后,我们将讨论用于借助血液样本检测疟疾的ML模型及其性能结果。

Malaria is one of the deadliest parasite-related diseases humankind has ever known. It has been around ever since humans have been on the face of the earth and it is certainly here for the long term.

疟疾是人类已知的最致命的与寄生虫相关的疾病之一。 自人类出现在地球上以来,它就已经存在了,而且从长远来看,它肯定在这里。

In 2018, 228 million were infected and 405'000 people died, making it a significant health concern and problem. Africa is home to 94% of all malaria cases (2018), but it is also prevalent in southern China and present on nearly all continents. As malaria mainly hits African countries, it is even harder to contain and effectively fight this parasite. Indeed, the developing countries in which it prospers do not always have the appropriate resources to reduce their vulnerability to malaria. There are an estimated 12 billion US Dollars lost by malaria-hit countries per year, due to the inability of many citizens to work during big malaria outbreaks, high healthcare costs and adverse effects on tourism. Add to the pot around 2.7 billion Dollars of humanitarian aid and there is no doubt that malaria has a tremendous negative impact on the economy of affected countries.

2018年,有2.28亿人被感染,有405,000人死亡,这是一个严重的健康问题。 非洲占所有疟疾病例的94%(2018),但在中国南部也很普遍,几乎遍布所有大洲。 由于疟疾主要侵袭非洲国家,因此遏制和有效对抗这种寄生虫变得更加困难。 确实,繁荣的发展中国家并不总是拥有适当的资源来减少其对疟疾的脆弱性。 由于许多公民在疟疾大爆发期间无力工作,高昂的医疗保健费用以及对旅游业的不利影响,受疟疾影响的国家每年估计损失120亿美元。 加上约27亿美元的人道主义援助,毫无疑问,疟疾对受灾国家的经济产生了巨大的负面影响。

Image for post

疟疾,这是什么? (Malaria, what is it?)

Malaria is actually only the name given to the disease. It is caused by a unicellular protozoan parasite known by its genus name, Plasmodium.

疟疾实际上只是该疾病的名字。 它是由单细胞原生动物寄生虫引起的,该寄生虫的属名是疟原虫。

Plasmodium comprises a wide variety of parasites, around 200, but only a handful can contaminate humans. As they are parasites, they use several hosts to feed and reproduce.

疟原虫包含各种各样的寄生虫,大约200种,但是只有极少数会污染人类。 由于它们是寄生虫,因此它们使用多个宿主来繁殖和繁殖。

5 species of plasmodium parasites can successfully parasite humans and be harmful to them, P. flaciparum, P. vivax, P. ovale, P.malariae, and P.knowlesi (P. stands for Plasmodium). While all of the 5 species cited can cause malaria, it is p.flaciparum that is usually lethal and causes severe malaria.

5种疟原虫的可以成功寄生虫人类和有害于健康,P. flaciparum,间日疟原虫,卵形疟原虫,三日疟原虫和 P.knowlesi(P.代表疟原虫)。 虽然所有的5种引可引起疟疾,它是p.flaciparum这通常是致命的,并导致严重的疟疾。

Image for post
two different types of malaria causing plasmodiums, source: https://microbenotes.com/differences-between-plasmodium-vivax-and-plasmodium-falciparum/
两种导致疟原虫的疟疾,来源: https : //microbenotes.com/differences-between-plasmodium-vivax-and-plasmodium-falciparum/

These parasites have a rather simple life cycle compared to other types of parasites, as they only have two hosts, mosquitoes and humans.

与其他类型的寄生虫相比,这些寄生虫的生命周期相当简单,因为它们只有两个宿主,蚊子和人类。

The parasite’s life starts in the mosquito’s gut, and after a multiplication stage, they move to the insect’s salivary gland. When the mosquito feeds on humans for blood, the plasmodium goes into the human’s blood flow. Following the infection, they first go in the liver and go through a multiplication phase. Once mature and in more significant numbers, they leave the liver and go in the red blood cells (erythrocytes).

寄生虫的生活始于蚊子的肠道,在繁殖阶段之后,它们移到了昆虫的唾液腺上。 当蚊子以人类为食时,疟原虫进入了人类的血液。 感染后,它们首先进入肝脏并经历繁殖期。 一旦成熟并且数量更多,它们就会离开肝脏,进入红细胞(红细胞)。

At this point, the parasite will keep multiplying until the body can effectively fight the infection. Some of the plasmodium will differentiate into sexual egg-like cells and will freely flow in the humans’ blood until a mosquito feeds again and uptakes them. Once in the mosquitoes gut again, the male egg-like cell will fertilize the female, and the cycle can start again.

在这一点上,寄生虫将继续繁殖,直到身体可以有效抵抗感染。 某些疟原虫会分化为有性的卵样细胞,并在人的血液中自由流动,直到蚊子再次觅食并吸收它们为止。 再次进入蚊子肠,雄性卵状细胞将使雌性受精,并且周期可再次开始。

Image for post
life cycle of the plasmodium, source: https://sk.pinterest.com/pin/706220785288117948/
疟原虫的生命周期,来源: https : //sk.pinterest.com/pin/706220785288117948/

Malaria fevers usually occur when the plasmodium burst out of the erythrocytes in big numbers and provoke an immune response such as high fever, vomiting, nausea, and headaches. As many red blood cells are being lysed, it can also result in anemia in some instances and this anemia can lead to several organ failures and metabolic acidosis.

疟疾通常在疟原虫大量从红细胞中爆发并引起免疫React(如高烧,呕吐,恶心和头痛)时发生。 随着许多红细胞的溶解,在某些情况下它也可能导致贫血,这种贫血可以导致多种器官衰竭和代谢性酸中毒。

The best way to effectively fight the parasite lies more in prevention above all else. This includes using mosquito repellent as well as insecticide-treated mosquito nets when sleeping at night. Some high-risk areas are also smoked with insecticide in order to avoid having too many mosquitoes.

有效对抗寄生虫的最佳方法更多地在于预防。 这包括在晚上睡觉时使用驱蚊剂和经过杀虫剂处理的蚊帐。 为了避免蚊子过多,一些高危地区也被杀虫剂熏制。

Once infected, several medications exist, but this medication must be given very rapidly to avoid severe harm or even death of the individual.

一旦被感染,存在几种药物,但是必须非常Swift地给予这种药物以避免严重的伤害甚至个体死亡。

One big problem with this parasite and probably one of the main reasons it is still around is its ability to rapidly evolve and develop resistance to the medication it encounters. As the mosquitoes develop resistance to insecticides, it makes it even harder to fight malaria. Additionally, the unhygienic conditions in developing countries, particularly sub-Saharan Africa, are an ideal mosquito breeding ground, especially in the rainy seasons when the insects have many puddles to lay their eggs in.

这种寄生虫的一个大问题,也可能是它仍然存在的主要原因之一,是其Swift进化并发展出对所遇到药物的抵抗力的能力。 由于蚊子对杀虫剂产生抗药性,因此与疟疾作斗争变得更加困难。 此外,发展中国家,特别是撒哈拉以南非洲地区的不卫生条件是理想的蚊子繁殖地,尤其是在雨季,因为昆虫有很多水坑来产卵。

The most effective way to avoid severe complications from malaria is to give a rapid diagnosis. This will avoid death as well as contain the parasite, so as not to infect more people.

避免疟疾造成严重并发症的最有效方法是进行快速诊断。 这将避免死亡以及包含寄生虫,以免感染更多的人。

The most common way to detect a malaria infection is to carry out microscopic blood analysis. This does not require a complex set of skills, however, basic medical knowledge is essential. The problem is that in developing countries the appropriate medical material and personnel are not always readily available, making this diagnosis slower than desirable if not non-existent.

检测疟疾感染的最常见方法是进行显微血液分析。 这不需要复杂的技能,但是,基本的医学知识是必不可少的。 问题在于,在发展中国家,并非总是能随时获得适当的医疗材料和人员,如果不存在这种诊断,其诊断速度将比期望的慢。

Another major issue is that when the resources are available, there is a trend to overestimate the number of infected individuals. Many studies suggest that there is a huge problem of overdiagnosis (as high as 98% wrong diagnosis in some certain rural health centers (Angola, 2012). This results in a massive misuse of malaria treatment and therefore, could end in a shortage of malaria drugs. Plus, this misuse of medication lowers the patients’ response to the drugs when really sick as well as strengthening the plasmodium’s resistance. Finally, this entrenches the lack of appropriate knowledge necessary to do the microscopic blood analysis.

另一个主要问题是,当资源可用时,有一种趋势是高估受感染个体的数量。 许多研究表明,存在一个过度诊断的巨大问题(在某些农村卫生中心,高达98%的错误诊断(安哥拉,2012年),这导致大规模滥用疟疾治疗,因此可能导致疟疾短缺此外,这种滥用药物的行为会降低患者真正生病时对药物的React,并增强疟原虫的抵抗力,最后,这会导致缺乏进行显微血液分析所需的适当知识。

Despite many efforts trying to fight malaria, misuse of resources is still a major problem
尽管为抗击疟疾付出了许多努力,但滥用资源仍然是一个主要问题

AI如何帮助疟疾? (How could A.I help with malaria?)

We have seen that misuse of resources is a major problem, but how could money be better invested in order to help with malaria?

我们已经看到,滥用资源是一个主要问题,但是如何更好地投资以帮助疟疾呢?

A. I could be the answer and on many sides. First and foremost, rapidly detecting this disease using A.I and ML programs could save countless lives by quickly giving a diagnosis. Not only would it be faster than a human, but it could potentially be much more accurate, given the numbers seen earlier. This accuracy would lead to better management of the medication, leading to enormous money savings. Those savings could then be reinjected and be of better use.

答:从很多方面来说,我都是答案。 首先,使用AI和ML程序快速检测出这种疾病可以通过快速做出诊断来挽救无数生命。 考虑到之前看到的数字,它不仅会比人类快,而且可能会更准确。 这种准确性将导致更好地管理药物,从而节省大量资金。 然后可以将这些节省的资金重新注入并得到更好的利用。

Taking photos of red blood cells is very easy and one would only need a microscope and an adaptor ring to take pictures of the erythrocytes. Once the photo is taken, it would be possible to simply run it through an ML program, trained to recognize infected cells.

拍摄红血球非常容易,只需显微镜和转接环即可拍摄红血球。 拍照后,就可以通过训练有素的ML程序简单地运行它,该程序经过训练可以识别受感染的细胞。

Given the rather simple way to detect an infection, we thought we could try to develop a malaria detection program using Giotto, no code involved. The point would be to input unclassified images of red blood cells and let the program do the classification, with satisfactory accuracy.

鉴于检测感染的方法非常简单,我们认为我们可以尝试使用Giotto开发疟疾检测程序,而无需编写任何代码。 关键是输入未分类的红细胞图像,然后让程序以令人满意的精度进行分类。

Giotto is a machine learning platform that can develop an ML program in image classification, without having to code. For a more detailed, step-by-step description of Giotto, you can read one of our previous blog-posts.

Giotto是一个机器学习平台,可以开发图像分类中的ML程序,而无需编写代码。 有关Giotto的更详细的分步说明,您可以阅读我们以前的博客文章之一

No-code platforms are straightforward to use, and this could really democratize A.I. Not only can anyone use it, but the possibility to deploy a docker means with only a computer and no wifi, you can use A.I in the simplest way. This is a critical point as many of the high-risk malaria zones are very remote and, therefore, don’t have access to decent internet connexion. If this worked, rural communities would not have to travel to the closest health center (keeping in mind that this is very far sometimes). The point would not be to replace human expertise, but when there are no other choices, this could be an answer.

无代码平台易于使用,这确实可以使AI民主化,不仅任何人都可以使用它,而且部署Docker的可能性意味着只需要一台计算机而没有wifi,则可以以最简单的方式使用AI。 这是一个关键点,因为许多高风险疟疾地区非常偏远,因此无法获得良好的互联网连接。 如果这样做有效,则农村社区将不必去最近的保健中心(请记住,有时候这很遥远)。 关键不是要取代人类的专业知识,但是当没有其他选择时,这可能就是答案。

The key to properly train a program is to have the appropriate data. This means that you need to have adequately labeled folders of each class to analyze as well as more less same number of images in each folder (when talking about image classification, of course). We used a data set composed of 27'558 images of erythrocytes, half parasited, and half normal.

正确训练程序的关键是拥有适当的数据。 这意味着您需要在每个类别中有足够标签的文件夹来进行分析,并且每个文件夹中的图像数量要少得多(当然,在谈论图像分类时)。 我们使用的数据集由27'558张红细胞图像组成,一半为寄生虫,一半为正常人。

Image for post
Having properly labeled images is primary
具有正确标签的图像是主要的

In order to work with this data set, we first had to upload it to Giotto. We then had to choose the data augmentation techniques that had to be applied to our images. In this case, all of the methods were applied, as none of them would alter the images’ integrity. By doing this augmentation process, we boosted our model’s performance by feeding it more data than the initial set.

为了使用该数据集,我们首先必须将其上传到Giotto。 然后,我们必须选择必须应用于图像的数据增强技术。 在这种情况下,将应用所有方法,因为它们都不会改变图像的完整性。 通过执行这种扩充过程,我们通过向模型提供比初始集合更多的数据来提高模型的性能。

Image for post
All of the data augmentation processes were applied to our data.
所有的数据扩充过程都应用于我们的数据。

Once this was done, we had to choose all of the specificities of our model, such as the resNet number and the number of epochs. Our model performed best with a resNet 34 and 30 epochs.

完成此操作后,我们必须选择模型的所有特殊性,例如resNet数量和时期数。 我们的模型在resNet 34和30个纪元时表现最佳。

Training time was rather long on this project as the data set was massive; it took around 3 hours to complete the training.

该项目的培训时间很长,因为数据集非常庞大。 完成培训大约花了3个小时。

With a 20% validation split, our model achieved 97.88% accuracy, without a single line of code.

通过20%的验证拆分,我们的模型无需一行代码即可达到97.88%的准确性。

This accuracy is satisfying as the setting chosen for the program are not too high (resNet 34 and 30 epochs). Very similar results were achieved with 10 epochs already (~96%).

由于为程序选择的设置不太高(resNet 34和30个纪元),因此此精度令人满意。 已经有10个时期(〜96%)取得了非常相似的结果。

结论 (Conclusion)

Despite medicine’s impressive innovations, this parasite still thrives in many parts of the world, taking hundreds of thousands of lives every year. Finding new ways to fight malaria is crucial. This could help millions as well as promote economic development in high-risk areas.

尽管医学取得了令人瞩目的创新,但这种寄生虫仍在世界许多地方蓬勃发展,每年夺去数十万人的生命。 寻找与疟疾作斗争的新方法至关重要。 这可以帮助数百万人,并促进高风险地区的经济发展。

97.88% accuracy is satisfactory, especially as this was achieved after training of only 3 hours, using absolutely no code. In low resource locations, this could easily achieve better results than someone who has little if no training to run an appropriate analysis. Such an easy application would be straightforward to deploy in rural places, allowing populations to self- medicate if there is no other choice.

97.88%的准确性是令人满意的,特别是因为仅用3个小时的培训就完全没有使用任何代码,就可以达到这一精度。 在资源匮乏的地区,这比那些没有受过足够的培训(如果没有进行适当的分析的培训)的人而言,很容易获得更好的结果。 这样简单的应用程序将很容易部署在农村地区,如果没有其他选择,则可以使人们自疗。

Image for post
Summary of our model.
我们的模型摘要。

You can try the program yourself : https://cloud.giotto.ai/ic/malaria password: malaria123

您可以自己尝试该程序: https ://cloud.giotto.ai/ic/malaria密码:malaria123

来源和链接 (sources and links)

翻译自: https://towardsdatascience.com/detecting-malaria-using-transfer-learning-fab5e1810a88

目标检测迁移学习

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值