|
| 1 | +--- |
| 2 | +title: Command line flags on Windows |
| 3 | +tagline: |
| 4 | +category: "Documentation" |
| 5 | +group: "" |
| 6 | +weight: 1 |
| 7 | +--- |
| 8 | + |
| 9 | +# Command-line flags on windows |
| 10 | + |
| 11 | +The behavior of ilastik can be influenced by supplying options upon start-up. |
| 12 | +You have to supply these options as command-line arguments when ilastik is started. |
| 13 | + |
| 14 | +We'll go through two methods of starting ilastik with additional options: |
| 15 | + |
| 16 | +1) Starting ilastik form the _Command Prompt_: Especially useful for running ilastik in [headless mode]({{site.baseurl}}/documentation/headless.html). |
| 17 | +2) Creating a link on the desktop with command line options: This is a more permanent way for options you always want to supply. |
| 18 | + |
| 19 | +## Start ilastik via the terminal/command-line |
| 20 | + |
| 21 | +The command line is just another interface to interact with your computer (as, e.g. opposed to using the mouse). |
| 22 | +It is a special window, where you type in commands that are executed when you press "Enter". |
| 23 | +Using the command line interface is especially useful for running ilastik in [headless mode]({{site.baseurl}}/documentation/headless.html), where you often supply changing options, depending on what project/data you wish to process. |
| 24 | + |
| 25 | +1) __Start the command prompt (`cmd.exe`)__: type `cmd` into the search field, click on "Command Prompt" to start a terminal window. (A new window should pop up): |
| 26 | + |
| 27 | +<!-- TODO: insert image --> |
| 28 | + |
| 29 | +Note that there is a blinking indicator (the cursor) where text commands will appear whe you type. |
| 30 | +To the left of the cursor, the current location is shown (here: `C:\Users\kutra`). |
| 31 | +Per default the command prompt starts in your user home folder. |
| 32 | + |
| 33 | +2) __Navigate to your ilastik installation__: in this terminal window you have to navigate to the ilastik installation folder in order to start ilastik. |
| 34 | +If you didn't change ilastik install location this should be "C:\Program Files\ilastik-1.X.Y" (where `X.Y` are placeholders that you should replace with your installed version - we'll stick with `1.3.3post2` for this example). |
| 35 | +So in the command prompt, type (including the quote marks) and press enter: |
| 36 | + ```cmd |
| 37 | +cd "C:\Program Files\ilastik-1.3.3post2" |
| 38 | +``` |
| 39 | +you should now see `C:\Program Files\ilastik-1.3.3post2>` left of the cursor. |
| 40 | + |
| 41 | +3) __start ilastik__: here you can start ilastik and supply the `--headless` flag by typing |
| 42 | +```cmd |
| 43 | +ilastik.exe --headless |
| 44 | +``` |
| 45 | +You will get a message back that you have to supply at least the `--project` argument as an additional option. |
| 46 | +Read more in the [headles mode documentation]({{site.baseurl}}/documentation/headless.html)! |
| 47 | + |
| 48 | + |
| 49 | +## Create a shortcut with the command line flag |
| 50 | + |
| 51 | +The second method is for a more permanent setup. |
| 52 | +You will create a shortcut to ilastik on your desktop that will always supply the `--hbp` flag, that you can then simply double-click. |
| 53 | +This currently (ilastik `1.4.0b3`) enables the [Voxel Segmentation Workflow]({{site.baseurl}}/documentation/VoxelSegmentation/VoxelSegmentation.html), which is hidden, otherwise. |
| 54 | + |
| 55 | +1) __locate ilastik in your start menu__: |
| 56 | + |
| 57 | +<!-- TODO: insert image --> |
| 58 | + |
| 59 | +2) __create a link on the desktop__: click on it with the left mouse button and hold the button while dragging it to the desktop. |
| 60 | +You have created a link (visible by the little curved arrow in the lower-left corner): |
| 61 | + |
| 62 | +<!-- TODO: add image --> |
| 63 | + |
| 64 | +* __Add the command line option__: edit the properties (right click - Properties) of the link to include the command line flag (highlighted in yellow in the following screenshot): |
| 65 | + |
| 66 | +<!-- TODO: Add image --> |
0 commit comments