New project? Water sensors

I was chatting to the frome river group on Facebook…

Of course we’d need more peeps but interesting to see interest

So I emailed the UK environmental protection agency… They have a map of swimming spots see - http://environment.data.gov.uk/bwq/profiles/

but they don’t include data sets on rivers…

I’ve asked for sample dataset to see if we could play with it

2 Likes

A possible slight hitch… Looking at the sample data http://environment.data.gov.uk/bwq/profiles/help-understanding-data.html

To know if water is good to ‘swim in’ you need to know if it has bacteria… (e.g. E. coli )

And there aren’t any sensors for that! The environmental agency appears to send off samples of analysis in a lab. I wonder if there is a way to take an image sample at a microscopic level in situ then send it to environmental agency for analysis… hmmm

a portable and automated version

Looks like someone has almost thought same thing… Cloud anaylsis of water quaility

hmm or has someone actually done it… ?

A very relevant discussion on arduino forum about this very topic
https://forum.arduino.cc/index.php?topic=93497.0

I think this is a great idea, but as you’ve highlighted pathogen data would be very difficult (impossible?) to measure on-line. The problem is, samples are taken and cultivated over a few days to establish pathogen count, so you’d have real difficulty in measuring this directly.

Surfers Aginst Sewage have built an App highlighting water quality problems at beaches:

This is based on publicly available APIs with information on point source pollution sources, rather than measuring pollution themselves. It would be interesting to do something similar for rivers, which could be run in conjunction with direct monitoring of more easily measured parameters (e.g. ammonia, dissolved oxygen, temperature).

2 Likes

Interesting and thanks for sharing… A few peeps have also had a punt at this.

See all sensors available

I think you could get AI to look for patterns in a petri dish swabed every few days but starts to get pretty technical…

I also managed to get some sample data of what Eviornmental agency measure in river Frome
https://environment.data.gov.uk/water-quality/view/sampling-point/SW-63119999

They just don’t API it or test in real time like SAS

I think you could get AI to look for patterns in a petri dish ...

Ha! It’s only since joining this forum that I see how similar Artificial Intelligence and Alison look in print. For a moment there I thought it was me that had to study the petri dishes!
:woman_scientist: :microbe: :microscope:

1 Like

Oooh, that’s interesting thought on machine learning/AI (or Al if she wants to!) for classifying microbes in samples “live” in water (rather than culturing them).

I’ve started looking for relevant image data sets and existing research as on the face of it, it seems like (with decent magnification) there should be something to look at… (I’ll add any links on Trello)

Even if we couldn’t classify what’s living in there (*) we could possibly baseline it, then try out anomaly detection to flag up changes that need chemical analysis (catching changes quicker and flagging up short term pollution/changes which may escape the periodic sampling).

Counting/classifying fish (working around seasonal change) might be another angle for signals of pollution as well.

(*) which we might be able to, but needs data and time - what’s living in there might highlight what chemicals are present too…

Is there such a thing as ‘open source AI’ that’s can get access to apply such pattern matching?

Essentially yes - there are:

  • Free & opensource Frameworks for training and classifying data (e.g. keras/tensorflow, pytorch, fastAI, openCV [computer vision] & others)
  • Loads of opensource examples (likely not many covering what we need directly, but for sure image classification, anomaly detection, etc.) on Github, Kaggle, Google Colab etc.
  • Some open/public datasets to work with

On the Trello board, I’ve linked to an interesting project on Kaggle that includes things like PH and conductivity that might be usable to predict harmful contaminants.

[edit: some assembly required

  • unless there’s some existing research to base directly off, it needs designing etc.]

Some reasonably accessible examples:

https://www.tensorflow.org/js/tutorials/transfer/image_classification

So I wrote to the professor in video…

Water quality sensory

|Paul Kay
Hi Danny

Thanks for getting in touch and it sounds great what you are doing. The only way I know of producing real time water quality data at the moment is to install a sonde with telemetry - this works well but costs several £k per sonde so doesn’t sound like what you are after. I know some people at Hull who are developing next generation dip sticks to measure phosphorus and other pollutants in water and these have been used in citizen science but, again, I guess not what you are after. Happy to chat if I can be of any help.

Best wishes

Paul

From: Danny Hearn
Sent: 24 January 2020 13:47
To: Paul Kay
Subject: Water quality sensory

Hi Paul,

I wanted to write to you as i’m part of a local community citizen technology group in Frome (www.techshedfrome.org). We are exploring ways we can using open source technology come up with innovative solutions to problems that benefit the community. We are in the process of creating an air quality sensor network in our local town. We were interested to see if we can expand that to the local rivers. I understand that water quality sensors is a more complicated game, but was curious to see if there was a way to create a water quality sensor station, that replicates some of the Environmental Agency tests in realtime to immediately determine the quality and safety of the water. Would you be able open to having a conversation or point me towards some relevant reading material that helps me understand the subject more deeply and exact process that EA use to analyse the water quality. I did see water https://www.watercanary.com/ which seems to have gone quiet and not moved forward.

Thank you and appreciate any time you can give

Kind regards

Danny|

1 Like

Oh and I wrote to another one that is linked to the water pressure group

Hi Danny,

Sounds interesting – there’s lots of work going on amongst various freshwater groups. Suggest you contact Michelle Walker of the Rivers Trust michelle@theriverstrust.org in the first instance. You could also contact Earthwatchhttps://earthwatch.org.uk/component/k2/fww-study-sdgs .

Some things can be measured reasonably accurately (e.g. conductivity, temperature, pH) but the most important things for water quality such as orthophosphate are mainly unreliable.

I’d be interested to know more about your air quality sensors.

Kind regards

Someone’s had a run at it here

well done - interesting to get these inputs.

Ok a big part of water quaility is measuring the phosphorus This link alludes how it is done https://archive.epa.gov/water/archive/web/html/vms56.html

  1. The EPA-approved method for measuring total orthophosphate is known as the ascorbic acid method. Briefly, a reagent (either liquid or powder) containing ascorbic acid and ammonium molybdate reacts with orthophosphate in the sample to form a blue compound. The intensity of the blue color is directly proportional to the amount of orthophosphate in the water.

This could be done by dropping a sache of reagent and then detecting the colour of the blue with https://www.digikey.co.uk/en/product-highlight/a/ams/tcs3200-rgb-color-sensor-breakout-board?utm_adgroup=Sensors%20%26%20Transducers&utm_source=google&utm_medium=cpc&utm_campaign=Dynamic%20Search&utm_term=&productid=&gclid=CjwKCAiA98TxBRBtEiwAVRLqu4dWl3bvPzIGDMFvIEoR3BRbxoHMvPz-L1nWef0MuYREWYHZsSJG5hoCH1QQAvD_BwE

  1. The total phosphorus test measures all the forms of phosphorus in the sample (orthophosphate, condensed phosphate, and organic phosphate). This is accomplished by first “digesting” (heating and acidifying) the sample to convert all the other forms to orthophosphate. Then the orthophosphate is measured by the ascorbic acid method. Because the sample is not filtered, the procedure measures both dissolved and suspended orthophosphate.
  2. The dissolved phosphorus test measures that fraction of the total phosphorus which is in solution in the water (as opposed to being attached to suspended particles). It is determined by first filtering the sample, then analyzing the filtered sample for total phosphorus.
  3. Insoluble phosphorus is calculated by subtracting the dissolved phosphorus result from the total phosphorus result.

https://archive.epa.gov/water/archive/web/html/vms56.html

I’ve created a document to help frame the problem - https://docs.google.com/presentation/d/1xFNb179Jmnf8LqGU4Cm-M8rjU9iIgsVU3ZiRi_gekbc/edit?usp=sharing

Welcome feedback or edits…

Email from Prof at leeds
Also…

" So, in terms of my thoughts on determinands to measure I would suggest:

  • General water quality variables (pH, electrical conductivity, dissolved oxygen and temperature): these form the basis of most water quality monitoring programmes and would allow the data collected to be put in the context of other monitoring and water quality standards).
  • Nutrients (could just go with phosphorus although nitrate and ammonia would also be useful): excessive levels of phosphorus are a key problem in UK rivers and derive from agricultural runoff and and sewage effluent. Even very low levels drive eutrophication (algal blooms and associated problems). Again, phosphorus is usually monitored and can easily be compared to other datasets and water quality standards (e.g. those stated in the Water Framework Directive). Elevated phosphorus levels are a clear indicator of pollution.
  • E. coli: if bathing water quality is the driver of the work then this is the key variable to measure, as per routine coastal bathing water monitoring. Looking at the literature it seems that the use of a fluorescence detector would be the way to go.

If needed, I’m sure there are people at Leeds who could help with the development of a sensor. More widely, grants do exist for citizen science work and it would be great to spin this out across the country to do some work on bathing waters in rivers."

1 Like