diff image_learner.xml @ 9:9e912fce264c draft default tip

planemo upload for repository https://github.com/goeckslab/gleam.git commit eace0d7c2b2939029c052991d238a54947d2e191
author goeckslab
date Wed, 27 Aug 2025 21:02:48 +0000
parents 85e6f4b2ad18
children
line wrap: on
line diff
--- a/image_learner.xml	Thu Aug 14 14:53:10 2025 +0000
+++ b/image_learner.xml	Wed Aug 27 21:02:48 2025 +0000
@@ -1,5 +1,5 @@
-<tool id="image_learner" name="Image Learner for Classification" version="0.1.2" profile="22.05">
-    <description>trains and evaluates a image classification model</description>
+<tool id="image_learner" name="Image Learner" version="0.1.2" profile="22.05">
+    <description>trains and evaluates an image classification/regression model</description>
     <requirements>
         <container type="docker">quay.io/goeckslab/galaxy-ludwig-gpu:latest</container>
     </requirements>
@@ -46,6 +46,9 @@
                         --batch-size "$batch_size"
                     #end if
                     --split-probabilities "$train_split" "$val_split" "$test_split"
+                    #if $threshold
+                        --threshold "$threshold"
+                    #end if
                 #end if
                 #if $augmentation
                     --augmentation "$augmentation"
@@ -144,8 +147,7 @@
         <conditional name="scratch_fine_tune">
             <param name="use_pretrained" type="select"
                 label="Use pretrained weights?"
-                help="If select no, the encoder, combiner, and decoder will all be initialized and trained from scratch.  
-               (e.g. when your images are very different from ImageNet or no suitable pretrained model exists.)">
+                help="If select no, the encoder, combiner, and decoder will all be initialized and trained from scratch. (e.g. when your images are very different from ImageNet or no suitable pretrained model exists.)">
                 <option value="false">No</option>
                 <option value="true" selected="true">Yes</option>
             </param>
@@ -317,16 +319,17 @@
                 </element>
             </output_collection>
         </test>
-        </tests>
+    </tests>
     <help>
         <![CDATA[
 **What it does**
-Image Learner for Classification: trains and evaluates a image classification model. 
+Image Learner for Classification/regression: trains and evaluates a image classification/regression model.
 It uses the metadata csv to find the image paths and labels. 
 The metadata csv should contain a column with the name 'image_path' and a column with the name 'label'.
 Optionally, you can also add a column with the name 'split' to specify which split each row belongs to (train, val, test). 
 If you do not provide a split column, the tool will automatically split the data into train, val, and test sets based on the proportions you specify or [0.7, 0.1, 0.2] by default.
 
+**If the selected label column has more than 10 unique values, the tool will automatically treat the task as a regression problem and apply appropriate metrics (e.g., MSE, RMSE, R²).**
 
 **Outputs**
 The tool will output a trained model in the form of a ludwig_model file,