Using machine learning control methods in hydroponics

Properly controlling the hydroponic environment is perhaps one of the most challenging tasks the modern grower must face. Either with a small grow room or a big green house, it is difficult to properly control variables such as temperature, humidity, pH and nutrient concentration, ensuring they are all kept in tight ranges with the proper controlling actions always being applied. Today we’re going to talk about some of the research done into advanced control systems and how using these could help you boost your crop yields.

Control flow algorithm taken from this paper
Crop result comparison taken from this paper

Hydroponic crops are dynamic systems, with plants continuously affecting their environment and demanding control actions in order to keep conditions constant. For example plants will tend to transpire water and absorb carbon dioxide during their light cycle, so in order to keep humidity and carbon dioxide concentrations constant you might need to turn on humidifiers, dehumidifiers, carbon dioxide generators, etc. Knowing what action needs to be taken is not trivial and naive control implementations – like turning on humidifiers, AC systems, etc when some thresholds are reached – can cause problems where sensors fight each other (for example a sensor trying to increase ambient humidity and another trying to raise temperature) or even fail to trigger.

In order to provide better control, researchers have created systems that rely on machine learning – systems that can learn from examples – in order to learn what control actions are needed and execute them in order to provide ideal control to a hydroponic setup. A machine learning system will be able to anticipate things like the lag between turning an AC unit on and the temperature decreasing, so it will be able to be both more efficient and more accurate in the way it controls your environment. This use of automated control guided by machine learning is also known as “smart hydroponics”.

Control flow diagram from this article

For example you can read this paper where growers were able to increase the yield of a crop by 66% just by ensuring they could maintain proper environmental conditions the entire time using machine learning. In this case the researchers use a probabilistic method where the system determines the probability of an action – like triggering a sensor – will cause a desired effect. As data is accumulated the system basically executes whichever action has the highest probability to lead to the desired outcome.

There are other papers on the subject. In this one a deep learning neural network is used to perform a similar control role, although the quantification of improvements in this paper is not sufficient to claim that the control method would have been an improvement over a traditionally managed hydroponic setup, as the comparison is made between a soil control, not a hydroponic control with no automated environmental management.

This paper uses a simple IoT sensor control system and a multivariate regression approach in order to control the environment in a hydroponic greenhouse, this system was created with the aim to be cheap and usable in developing countries.

Although there are now several different demonstrations of this being done in the literature there still does not seem to be a commercially mature technology to carry out this task and the implementations seem to still be tailor made to each particular situation. However the modeling techniques used are not exceedingly complex and even modest commercial growers could – nowadays – afford to setup something of this nature.

With a computer, some arduinos, raspberry pi computers, sensors and time and effort a grower could definitely setup a very nice, machine learning based control system to benefit from the above described technologies.