Getting Started: Building your Own PlantCV Pipeline

Introduction

This document provides general instructions for building an image analysis pipeline in PlantCV, an imaging processing package that is built upon open-source software platforms.

 

Getting started with your image analysis pipeline

Step 1

Download Anaconda (aka “conda”) from https://www.anaconda.com/products/individual .

Step 2

Open “Anaconda Navigator” from download location on computer. (The location should be a folder titled “opt” under the user profile.)

Requirement: The “opt” folder and documents within must be stored at a high-level location on your computer (directly within your user profile) as it will need to be able to access all folders at lower-level hierarchies in your directory.

Step 3

Once Anaconda Navigator is opened, select “Environments” on left side of window

Step 4

Create a new environment titled “plantCV” with the “create” button at the bottom of the screen.

Figure 1. Select ‘Create” to make a new environment called ’Plant CV’.

 

Step 5

Assign your new environment a name (“plantCV” for example).

Figure 2. Name the new environment.

 

Step 6

Now you should be able to see your new Environment.

 

Step 7

Hit the “play” button (green triangle) next to your new environment and select “open terminal”.

 

Step 8

In the terminal, run the following command: pip install plantCV .

 

Step 9

Once installed, at top of the screen in Anaconda Navigator, select “update index” to update the packages associated with your new environment. You should see plantCV located there now.

 

Step 10

With the new “plantCV” environment highlighted, select “Home” in the upper left corner of Anaconda Navigator, find “Jupyter Notebook”, and select “install”.

 

Step 11

Once Jupyter Notebook is installed for the plantCV environment, under “Environment” tab on the left, select the “play” button (green triangle) next to the plantCV environment and select the option to “open with Jupyter Notebook”.

Step 12

You will be automatically directed to an external web application (Jupyter) showing all the folders on your computer – navigate to a folder where you would like to start building and saving your image analysis pipeline.

 

Step 13

Once you have navigated to a desired location in your directory, in the upper right corner of Jupyter, select “New” and then “Python 3”.  A new workspace (Jupyter notebook saved as an ipynb file) will automatically open.

 

Step 14

In this Jupyter notebook, you can begin building your image analysis pipeline. The advantage of building your PlantCV pipeline in a Jupyter notebook is that Jupyter allows for in-notebook plotting of results as you assemble the pipeline in pieces. This allows you to see the results of your parameterizations for each step of the pipeline as you construct it. For example, you can test how well thresholding parameters segment out your object of interest by running one step of the pipeline rather than the pipeline in its entirety.

 

plantCV Tips

Step 15

If at any point you wish to convert you Jupyter notebook into a pdf file for sharing with others or presentations, you can download as a .tex file (Latex).

 

Step 16

This will result in a folder containing the .tex file and the series of images that were generated with your Jupyter notebook. You can compile this tex file into pdf by opening with “TexShop” (Latex software). If you don’t have some version of LaTex installed on your local machine, you can download it for free here:

 https://www.latex-project.org/get/

 

Step 17

In the top menu, make sure “LaTeX” is selected, then click on “Typeset” and it should automatically compile the pdf.

 

Step 18

If you have issues, make sure privacy settings on your computer allow TeXShop to access your entire disk (on a mac go to “Security & Privacy”>”Privacy”>”Full Disk Access”> + > make sure TeXShop is selected).

Related articles

Filter by label

There are no items with the selected labels at this time.