• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

Can machine learning be used to predict that when will corona virus end?

 
Ranch Hand
Posts: 1463
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Machine meaning can provide predictions based on dataset.Can machine learning be used to predict that when would corona virus end using the training dataset.
Thanks

 
lowercase baba
Posts: 12855
52
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What dataset would you use?
 
Marshal
Posts: 69411
276
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tell us how you think machine learning could use such a dataset. Also, what would you put into such a dataset?
 
Monica Shiralkar
Ranch Hand
Posts: 1463
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

fred rosenberger wrote:What dataset would you use?



I am thinking that number of deaths per day over the last few months can form the dataset and this dataset would be used by TimeSeries algorithm. The time series ML algorithm would predict the number of deaths for the next day based on the dataset (sequence of number of deaths for each day over the past few months).

 
Saloon Keeper
Posts: 22112
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you're looking for "herd immunity", current wisdom is that we'll never reach it. Sweden tried and failed - the hard way. They're only about 15% and I think the critical number for COVID-19 is well above the 80% point.

Predicting development of a vaccine is little better. Historically, 12-24 months has been considered good, but I think Ebola required something like 6 years and some diseases have never had a vaccine successfully produced. However, COVID is such a menace that all the stops have been pulled. There are about 10 vaccines under trial and I wouldn't be surprised to see something available in about 6 months, but probably little less than that. However, I've donated 3 of my computers to running simulations for the folding@home project and 2 of them have been busy 24x7 for the past month. So hopefully I've managed to help speed things up just a tiny bit myself.

The problem with using machine learning here is that you can only learn by experience and we have no experience that directly corresponds. In the absence of experience, we can only approximate based on similar experiences and in a case like this, it's going to be very approximate indeed.
 
Campbell Ritchie
Marshal
Posts: 69411
276
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Tim Holloway wrote:. . . we'll never reach it. . . . I think the critical number for COVID-19 is well above the 80% point. . . .

Probably higher than 80%, a lot higher. I can't remember the figures, but for something like a Herpes infection (e.g. chickenpox/varicella), you might need > 99% immunity to prevent its spread. Since Herpes viruses remain alive in people for life, that will probably never be feasible.
For something like measles, it would still be well over 90%, which we had before Andrew Wakefield. A small reduction in immune proportion produced measles outbreaks and the first death in this country for ages. I suspect Covid19 will be more like measles, and will only be controllable by immunisation, as was smallpox 45 years ago. Since there is much international travel, and about 10⁸ non‑immune people mysteriously appear on earth every year (most of them at a very small size), I think any immunisation campaign will have to be perpetual to control the bug. As it was with measles.
 
Monica Shiralkar
Ranch Hand
Posts: 1463
8
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Tim Holloway wrote:

The problem with using machine learning here is that you can only learn by experience and we have no experience that directly corresponds..



But we have experience of count of deaths per day (due to corona).

We have few months of data for this .
 
Master Rancher
Posts: 3537
39
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But that tells us nothing about, for example, what vaccine / treatments might be discovered.  Or what abysmally stupid steps might be taken by certain politicians, or their idiot followers.  Those have high impact and little past data to learn from.
 
Tim Holloway
Saloon Keeper
Posts: 22112
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Monica Shiralkar wrote:

Tim Holloway wrote:

The problem with using machine learning here is that you can only learn by experience and we have no experience that directly corresponds..



But we have experience of count of deaths per day (due to corona).

We have few months of data for this .



Yes, but it's like the Stock Market: Past Performance is no indicator of possible Future Results.

Growth rates are predictable and they don't even require machine learning, just basic mathematics. What's not predictable is the perversity with which people react. For example, who, thinking logically could believe that standard health measures dating back a century would be disdained, ridiculed and ignored simply because of the vanity of a popular leader? Machine learning could not predict the massive public emergence last weekend unless it also had samples about how long people could tolerate confinement, and that's even before integrating that knowledge into pandemic growth models.
 
Mike Simmons
Master Rancher
Posts: 3537
39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you had a dataset containing the full lifecycle of numerous past epidemics and pandemics, worldwide, that might help. But there would still be massive unreliability of the results, I think.
 
Tim Holloway
Saloon Keeper
Posts: 22112
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Don't forget that we have had varying levels of preparedness over the years. Or that mask-wearing was actively discouraged initially (allegedly to ensure supplies for medical personel, not for health reasons).

As I said, human perversity has had and will continue to have a massive effect on things and neither man nor machine can make anything like an accurate guess.
 
Mike Simmons
Master Rancher
Posts: 3537
39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yeah, you'd need a dataset that showed many examples of that sort of stupidity reacting to past pandemics.  Hard to find that, and most will not combine it with the modern level of interconnectedness, plus modern medicine.  Many vastly important variables are without precedent, especially together.
 
Tim Holloway
Saloon Keeper
Posts: 22112
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Conversely, there are unpredictable moments of genius as well. Around 1914 there was an outbreak of Pneumonic Plague in Manchuria. The local counterpart to Dr. Fauci recommended that the public wear masks (probably the first mass-masking in history) and is credited with keeping the plague contained and eventually suppressed when it was otherwise headed for the seaport and thence around the globe. COVID-19 is nasty compared to influenza, but it has nothing on the Black Death.

And while there has definitely been some silliness in how many have reacted to the current situation, the ways that people tried to deal with the Black Death were often downright surreal.

Even the current pandemic has different facets. The outbreak in Italy was different both in demographics and in response. The reason why you can buy a house in many Italian towns for a single Euro is that Italy is one of the nations that is literally expiring from old age - low birth rate. So the overall age of the population in the affected area was notably higher than in most places and thus the mortality rate has been higher there as well. And don't even start on Brazil. Or the Russian doctors who can't stay away from windows.
 
Campbell Ritchie
Marshal
Posts: 69411
276
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Mike Simmons wrote:. . . modern level of interconnectedness, plus modern medicine. . . .

And modern capacity for stupidity.
 
Tim Holloway
Saloon Keeper
Posts: 22112
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And then on top of that, the shadow groups that manipulate the exposure of the general population for reasons of financial or ideological selfishness. Or the "patriotic" influencers who are in fact not even citizens of the country which they claim to represent, and in fact are on the payrolls of that country's enemies. Or the people who got the wrong idea to start with and would literally rather die than change. Or. Or. Or.

I cannot even begin to come up with all the variables known or suspected to be in play.
 
Mike Simmons
Master Rancher
Posts: 3537
39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Campbell Ritchie wrote:

Mike Simmons wrote:. . . modern level of interconnectedness, plus modern medicine. . . .

And modern capacity for stupidity.


That was in my first sentence, no?  Not verbatim, but stupidity was what I had just talked about, and then finding that in conjunction with other things, in the second sentence which was quoted.

Ultimately as Tim says, there are just way too many important variables, and nowhere near enough data to use as a learning set for machine learning.  Now, if you had access to quantum multiverses...
 
Campbell Ritchie
Marshal
Posts: 69411
276
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, you did mention stupidity first.
A quantum system would be quite unpredictable, but when you average it out into a larger system, it would be easier to predict. Just as the movement of an atom isn't predictable , but 10²⁶ atoms would form a visible lump of matter which you can pick up by hand (if solid) and the average behaviour of all the atoms would follow Newton's Laws. It might therefore be possible to predict how many people will suffer the bug, but not who they are.
 
Tim Holloway
Saloon Keeper
Posts: 22112
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Campbell Ritchie wrote:Yes, you did mention stupidity first.
A quantum system would be quite unpredictable, but when you average it out into a larger system, it would be easier to predict. Just as the movement of an atom isn't predictable , but 10²⁶ atoms would form a visible lump of matter which you can pick up by hand (if solid) and the average behaviour of all the atoms would follow Newton's Laws. It might therefore be possible to predict how many people will suffer the bug, but not who they are.



The operative word here being "average". If you're going to go Einstein on us, I'll have to point out that stupidity is one of the only two things that Einstein considered might be infinite. It's hard to average that.

And that unlike, say, hydrogen atoms, stupidity doesn't condense to a set of common properties. Other than that they're all stupid, anyway.
 
Campbell Ritchie
Marshal
Posts: 69411
276
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Tim Holloway wrote:. . . stupidity is one of the only two things that Einstein considered might be infinite. . . .

Didn't know that. What was the other?
 
Mike Simmons
Master Rancher
Posts: 3537
39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The probably-apocryphal Einstein quote is:

Two things are infinite: the universe and human stupidity.

And I'm not sure about the universe.



A related quote, variously from either Harlan Ellison or Frank Zappa in one form or another is:

The two most common elements in the universe are hydrogen and stupidity.

 
Greenhorn
Posts: 23
1
Redhat Notepad Fedora Linux
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You cannot predict outbreaks like this due to so many unknowns, but there are for example machine learning models to predict mortality in COVID-19 positive patients:
https://www.medrxiv.org/content/10.1101/2020.04.26.20073411v1
 
Monica Shiralkar
Ranch Hand
Posts: 1463
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Mike Simmons wrote:But that tells us nothing about, for example, what vaccine / treatments might be discovered.  Or what abysmally stupid steps might be taken by certain politicians, or their idiot followers.  Those have high impact and little past data to learn from.



Thanks .I understand that. If we ignore these factors ,can we get a low accuracy model based only on the number of deaths per day since past many days ?
 
Monica Shiralkar
Ranch Hand
Posts: 1463
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Tim Holloway wrote:

Yes, but it's like the Stock Market: Past Performance is no indicator of possible Future Results.

Growth rates are predictable and they don't even require machine learning, just basic mathematics. What's not predictable is the perversity with which people react.



Given any machine learning use case ,how do we know whether or not past results are indicator of possible future results ?

For this use case growth rates are predictable using maths.But would creating a model and training it not be better than mathematics. (ignoring the difficult factors you mentioned while creating the model) ?

 
Mike Simmons
Master Rancher
Posts: 3537
39
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Monica Shiralkar wrote:If we ignore these factors ,can we get a low accuracy model based only on the number of deaths per day since past many days ?


Sure - where "low accuracy" may mean just about anything I suppose.  But you've got a collection of numbers over time; it's certainly possible to generate some sort of predictive model, whose predictions may or may not have anything to do with reality.  I suspect this would be much like weather prediction, where you can get pretty good accuracy for the next few hours, okay accuracy for a few days, marginal accuracy over a week, and meaningless accuracy over months.  Since you originally asked about predicting and end to the virus (which frankly may never happen) we all reacted with extreme skepticism.  That's like predicting where a hurricane will hit next month.  But  you can certainly generate a model, and you may find there's a time range in which the predictions are potentially useful.  It may be a very short time range, or very limited usefulness, but it's hard to say exactly.

Monica Shiralkar wrote:Given any machine learning use case ,how do we know whether or not past results are indicator of possible future results ?


Well, the classic technique would be to take all the past data you have available, take roughly half of it and use it for training, and take the other half to use for validating the accuracy of your results.  That is, use the second half to test whether your predictive algorithm can predict what will happen in that second set of data.  However, for this to work, the two set of data must be independent, which I don't see a clear way to do here.  E.g. if you train using the COVID mortality statistics for 100 different cities, and then validate using mortality statistics for 100 different cities... they're not really independent; both sets of data will be responding to many of the same shared circumstances.  It's an interesting problem; there may be some clever way to isolate the testing and validation data sets.
 
Monica Shiralkar
Ranch Hand
Posts: 1463
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Mike Simmons wrote:

Monica Shiralkar wrote:If we ignore these factors ,can we get a low accuracy model based only on the number of deaths per day since past many days ?


Sure - where "low accuracy" may mean just about anything I suppose.  But you've got a collection of numbers over time; it's certainly possible to generate some sort of predictive model, whose predictions may or may not have anything to do with reality.  


Thanks

I implemented a timeseris ML program using Keras.
I fed it with raw data for training based on data for 10 continous days for the number of deaths in India due to corona.
[156,142,142,150,132,146,131,154,118,104]

Next, I passed it data for 3 days and asked to predict for the next day.

Data passed for the 3 days [190,172,148]

The prediction value it gave as result was 162.27.
where the actual count(next day in news) ,was 177


I understand that model is of low accuracy.

At one point of time this count will start decreasing .
Whereas ,it looks like my program will continue to always give me an increased value for the next day.
Is timeseries a totally wrong choice for this use case .If so ,how to determine whether timeseris can be used for a case or not .
 
Tim Holloway
Saloon Keeper
Posts: 22112
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In an open-ended environment with no alterations, you can do this sort of prediction - it's basically a curve-fitting operation. But using machine learning for that is overkill, since it's just as easy to use straight mathematics.

What machine learning cannot do is realize ahead of time when saturation occurs and what effect that will have on future growth. Because for most of us, learning is something based on the past, not on the unseen future.

The other thing that machine learning cannot do is anticipate changes in growth rate do to people adapting or to government policies. Or reactions to government policies.

A more practical approach would be to use ML to correlate the presence or absence (and severity) of lockdown orders against the natural growth rate. That, in fact is the sort of tool that can be used effectively to guide policies. At least in places where knowledge is valued more than reflex political response.
 
Monica Shiralkar
Ranch Hand
Posts: 1463
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Tim Holloway wrote:In an open-ended environment with no alterations, you can do this sort of prediction - it's basically a curve-fitting operation. But using machine learning for that is overkill.



But even in that case how would that actually be possible because ML/mathematics will give you an higher (increased ) number each time for the number of deaths whereas  in reality one day the count will decrease (and start decreasing ).?
 
Tim Holloway
Saloon Keeper
Posts: 22112
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Likes 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is essentially a problem in graph theory. Each person is a node and the infections from person to person form a graph. The extent of the graph at a given point in time is a function of the number of connections (on average) between persons and the contagion rate (R0), which for COVID-19 is estimated at about 2 to 2.5.

In the early stages of spread, everyone is non-immune and so the maximum rate is seen. As the contagion spreads, some people will have already been exposed, so they won't count - you can only count them once (this is assuming that people get immune).

Eventually, virtually everyone who's exposed has already been exposed and the virus cannot expand further. This is the "herd immunity" effect that Sweden was hoping for. They didn't get, it, incidentally. So you have a geometric expansion at first, with a damping effect and the disease becomes widespread. This can be represented with a relatively simple formula. It won't be strictly accurate day-to-day because the spread is a statistical process, but it will be fairly accurate overall, given the right data.

Machine Learning, on the other hand, depends only on what it has seen. As I said, it cannot look ahead except as conditioned by past experience. So to an untutored machine, the infection plot would increase infinitely and not damp or show herd immunity. And unless you're training for overall timelines (multiple plagues) instead of a specific plague's future trends, the later data from when damping kicks in will distort the earlier projections.
 
Monica Shiralkar
Ranch Hand
Posts: 1463
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Tim Holloway wrote:
Machine Learning, on the other hand, depends only on what it has seen. As I said, it cannot look ahead except as conditioned by past experience. So to an untutored machine, the infection plot would increase infinitely and not damp or show herd immunity.



Thanks .That accurately tells why machine learning is not suitable for this case as this cannot be done merely based on past results.
 
Monica Shiralkar
Ranch Hand
Posts: 1463
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was thinking of using this use case as a small hobby project to learn machine learning. However ,the use case itself is suitable for machine learning but one of the misunderstanding regarding machine learning got cleared through this thread . I will search some other use case for hobby project.
 
Campbell Ritchie
Marshal
Posts: 69411
276
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Monica Shiralkar wrote:. . . Thanks

That's a pleasure

. . . . merely based on past results.

There are lots of past results available, but not for Coronaviruses. There is lots of experience for Sars, Ebola, Marburg disease, the 1919 flu pandemic, which killed more people than the Great War, cholera, the plague, which killed about ⅓ of the whole world's population in the 14th century, etc. You can consider ML to see how Coronavirus compares to those older epidemics/pandemics. You would also consider ML to wok out how incomplete the records are for some of the older outbreaks.
 
They gave me pumpkin ice cream. It was not pumpkin pie ice cream. Wiping my tongue on this tiny ad:
Devious Experiments for a Truly Passive Greenhouse!
https://www.kickstarter.com/projects/paulwheaton/greenhouse-1
    Bookmark Topic Watch Topic
  • New Topic