Automation, Artificial Intelligence and Cannabis: A Tale of Three Friends?

Columns - Guest Column

Motorleaf’s CEO outlines how AI, combined with machine learning, can help cultivators operate in the most efficient and effective way.

October 30, 2017

©Erikona |

Artificial intelligence (AI) and machine learning are buzzwords around the tech community, prompting many to ask, “Are they real, and are they here yet?”

I had to ask the same question over a year ago to someone who was leading an AI team at Google. This is the explanation I received that I like to use:

Think of artificial intelligence as a technology that can do what a human can do already, like a robot vacuum. The difference is the robot can go all day and night, week after week.

Machine learning, however, is making that vacuum perform its task in a way that a human can’t do. Imagine the vacuum learns each day the layout of an enormous office building, and every second is making thousands of calculations to figure out the most time- and energy-efficient way to perform its task—that is AI plus machine learning.

Right now, you may already (even if unknowingly) be using a basic form of AI in your business. Perhaps you’re automatically taking pH readings every minute and having that data recorded in your computer’s hard drive. Maybe you have a system that will automatically dose pH up or down based on those readings. That’s AI right there, and a ‘better-than-just-a-timer-setting’ method of automation. It’s not a very integrated system, but it does one thing well.

Automated Applications

What I believe very strongly is that the word ‘automation’ as it applies to indoor agriculture is at a tipping point where technology companies are reinventing its meaning. Automation is starting to mean data collection, analysis, discovery, suggestion(s), action, producing better crops and then doing it all over again—so you get predictability.

An example would be monitoring the light (PAR) level and spectrum used in a grow room. A human won’t go in the room each hour to take a measurement, making sure the right amount of power and correct light spectrum is reaching the plants. However hard you try, simply looking at your HPS lights won’t alert you when they are performing below the optimum range your business needs to maximize production.

Our team at Motorleaf is working to make that possible by automating this data collection, and automating the alerts that will reach the head grower if any of those lights are underperforming.

So that is AI at work. Now how does that become machine learning?

Imagine that you have a day-by-day record of how your plants are reacting to all the different inputs (environmental conditions, nutrient feed, pH, CO2, light spectrum, etc.) and your software is now making millions of calculations to draw insights on what is making a difference to your output. The output may be yield, energy consumption, labor cost, etc., but it may also be modeling what will happen if you change your way of growing.

All of this is now possible with a potent mix of sensor data, and machine vision via HD webcams.

Yield Prediction Algorithm

Another example of AI and machine learning that will transform the industry is yield prediction.

There are many reasons why accurate yield forecasting matters.

Knowing ahead of time if your production costs are rising per square foot, based upon projected yield, is critical for proper financial planning.

Being able to negotiate better rates from buyers, based upon consistent quality and quantity, can only happen if you maintain a deep understanding of how to deliver both.

Yield prediction is a complex problem to solve. At Motorleaf, we have started by using machine vision and algorithms (defined by Merriam-Webster as “step-by-step procedure[s] for solving a problem or accomplishing some end especially by a computer") to first track the precise growth rate of plants in their vegetative stage.

The human eye can make a ballpark guess of how fast a crop has grown one day to the next; however, AI will take thousands of measurements each day and plot a growth index to precisely show how fast plants are growing, and also compare those to the benchmarks that growers are always trying to achieve for more predictable outcomes.

The next step is to create custom algorithms for each producer (as every environment and grow style is different in many ways), using as much data as we can obtain via existing sensor-based data (from equipment the producer may already have in place), as well as deploying more hardware to collect even more data.

Then we look to feature engineering, which is the identification of which unique features we are trying to focus on (in this instance, that would be yield prediction). We then define the parameters needed for the algorithm via data and plant scientists.

This next step is expensive and takes time. We use data scientists and plant scientists to look at the problem we’re trying to solve, and between, “I know how plants grow/react,” and, “Tell me what’s important and I’ll figure out how to find the data you need,” we start to build the process to find the most valuable data. Then comes the most important part—filtering out data. Bad or duplicate data can damage the algorithm’s ability to work. So knowing which data to include is critical, but likewise, knowing what to ignore is just as important. For example, some sensors may give zero readings for a few hours and go live again, or there can be typos in manual human entry (such as 2.5 kg/m² of yield instead of 1.5 kg/m² of yield).

Then the actual creation of the algorithm can begin. Think of it as a big pot of soup. The basic ingredients can be “bought off the shelf”—there are many standard algorithms that may address some of the needs you have, so these are tested and chosen based on their merits. Then we add in the engineered features we worked on prior (telling us what is the most relevant data to focus on and why), and finally we tweak the settings. When a chef makes soup, sometimes the final subtle flavors he adds make all the difference—a standard broth becomes a work of art. The same is true of building an algorithm. After you make the algorithm soup, you need people to test it. In our case, we can test on data sets. Testing the data sets can help us understand how a specific type of data improves/degrades the algorithm’s performance. Using the same analogy, testing the data set is like testing how an ingredient affects the flavor of the soup before serving the final version and putting it on the menu.

AI and cannabis is a new partnership. In the future, with marijuana legalization, we imagine a comprehensive use of AI in marijuana: yield prediction, environmental controls, image recognition and associating visual cues to known marijuana diseases, and even with operations like cost-benefit analyses of purchasing new equipment or introducing new recipes into the grow process, such as new nutrients, increased indoor temperature/CO2 level and more.

Alastair Monk is the co-founder of Motorleaf, a hardware and software developer that enables growers to connect equipment they already own, and turn their grow space into a smart grow space.