Icon

02. Define U-Net

Option 1: Create a Unet Architecture using No-Code nodes1. Use the Keras Input Layer node to create the input layer of shape (224,224,1)2. Create 5 Encoding Layers using the U-Net 2D Encoding Layer component with the following settings - Filter = 16, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.1, MaxPooling Pool Size = 2,2 - Filter = 32, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.1, MaxPooling Pool Size = 2,2 - Filter = 64, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.2, MaxPooling Pool Size = 2,2 - Filter = 128, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.2, MaxPooling Pool Size = 2,2 - Filter = 256, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.3, MaxPooling Pool Size = 2,23. Create 4 Decoding Layers using the U-Net 2D DEconding Layer component (the settings will be taken automatically from the Encoding Layers)4. Create on final convolutional layer using the Keras Convolution 2D Layer node with Padding = "same" and Activation function = "Sigmoid"5. Use the Keras Network Writer node to write your network to a file named u-net.h5 in the data folder (Hint: use workflow relative path: knime://knime.workflow/../../data/u-net.h5) Create a U-Net Architecture networkFor Option 2: Create a Tensorflow2 environment under Preferences -> KNIME -> Python Deep Learning Option 2: Create a Unet Architecture using DL Python Nodes1. In the Conda Environment propagation use the correct conda environment (using Tensorflow2 environment created in the beginning under Preferences) is selected.2. In the DL Python Network Creator update the Python code to create a U-Net with 5 Encoding Layers and 4 Decoding Layers with the follwoing settings - Filter = 16, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.1, MaxPooling Pool Size = 2,2 - Filter = 32, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.1, MaxPooling Pool Size = 2,2 - Filter = 64, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.2, MaxPooling Pool Size = 2,2 - Filter = 128, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.2, MaxPooling Pool Size = 2,2 - Filter = 256, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.3, MaxPooling Pool Size = 2,23. Use the Tensorflow2 Network Writer node to write your network to a file named u-net-tf2.h5 in the data folder and make sure the conda.enrionment variable is selected in the Executable Tab (Hint: use workflow relative path: ../../data/u-net.h5) UNet DL PythonNetwork Creator Conda EnvironmentPropagation Option 1: Create a Unet Architecture using No-Code nodes1. Use the Keras Input Layer node to create the input layer of shape (224,224,1)2. Create 5 Encoding Layers using the U-Net 2D Encoding Layer component with the following settings - Filter = 16, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.1, MaxPooling Pool Size = 2,2 - Filter = 32, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.1, MaxPooling Pool Size = 2,2 - Filter = 64, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.2, MaxPooling Pool Size = 2,2 - Filter = 128, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.2, MaxPooling Pool Size = 2,2 - Filter = 256, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.3, MaxPooling Pool Size = 2,23. Create 4 Decoding Layers using the U-Net 2D DEconding Layer component (the settings will be taken automatically from the Encoding Layers)4. Create on final convolutional layer using the Keras Convolution 2D Layer node with Padding = "same" and Activation function = "Sigmoid"5. Use the Keras Network Writer node to write your network to a file named u-net.h5 in the data folder (Hint: use workflow relative path: knime://knime.workflow/../../data/u-net.h5) Create a U-Net Architecture networkFor Option 2: Create a Tensorflow2 environment under Preferences -> KNIME -> Python Deep Learning Option 2: Create a Unet Architecture using DL Python Nodes1. In the Conda Environment propagation use the correct conda environment (using Tensorflow2 environment created in the beginning under Preferences) is selected.2. In the DL Python Network Creator update the Python code to create a U-Net with 5 Encoding Layers and 4 Decoding Layers with the follwoing settings - Filter = 16, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.1, MaxPooling Pool Size = 2,2 - Filter = 32, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.1, MaxPooling Pool Size = 2,2 - Filter = 64, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.2, MaxPooling Pool Size = 2,2 - Filter = 128, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.2, MaxPooling Pool Size = 2,2 - Filter = 256, Activation function = "ELU”, Kernel Size = 3,3, Dropout Rate = 0.3, MaxPooling Pool Size = 2,23. Use the Tensorflow2 Network Writer node to write your network to a file named u-net-tf2.h5 in the data folder and make sure the conda.enrionment variable is selected in the Executable Tab (Hint: use workflow relative path: ../../data/u-net.h5) UNetDL PythonNetwork Creator Conda EnvironmentPropagation

Nodes

Extensions

Links