diff json2yolosegment.xml @ 4:f6990d85161c draft default tip

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools commit c6c9d43a4ecdc88ebdeaf3451453a550f159c506
author bgruening
date Mon, 21 Jul 2025 15:51:13 +0000
parents dfda27273ead
children
line wrap: on
line diff
--- a/json2yolosegment.xml	Mon Jul 14 18:28:46 2025 +0000
+++ b/json2yolosegment.xml	Mon Jul 21 15:51:13 2025 +0000
@@ -8,17 +8,17 @@
     <expand macro="requirements" />
     <command detect_errors="aggressive">
     <![CDATA[
-      mkdir ./input ./output &&
+    mkdir ./input ./output &&
 
-      #for $filename in $in_json:
-          #if $filename.element_identifier.endswith($filename.ext)
-              ln -s '$filename' './input/${filename.element_identifier}' &&
-	  #else:
-	      ln -s '$filename' './input/${filename.element_identifier}.${filename.ext}' &&
-          #end if
-      #end for
+    #for $filename in $in_json:
+        #if $filename.element_identifier.endswith($filename.ext)
+            ln -s '$filename' './input/${filename.element_identifier}' &&
+        #else:
+            ln -s '$filename' './input/${filename.element_identifier}.${filename.ext}' &&
+        #end if
+    #end for
 
-      python '$__tool_directory__/json2yolosegment.py'
+    python '$__tool_directory__/json2yolosegment.py'
 	-i ./input/
 	-o ./output
 	-c '$class_name'
@@ -26,12 +26,12 @@
     ]]>
     </command>
     <inputs>
-	 <param name="in_json" type="data" format="json" multiple="true" label="Input label files" help="The label file is the output of AnyLabeling in JSON format."/>
-         <param name="class_name" type="data" format="txt" label="Class file" help="Class names text file, contains the names of classes, one class per row."/>
+        <param name="in_json" type="data" format="json" multiple="true" label="Input label files" help="The label file is the output of AnyLabeling in JSON format."/>
+        <param name="class_name" type="data" format="txt" label="Class file" help="Class names text file, contains the names of classes, one class per row."/>
     </inputs>
     <outputs>
         <collection name="output_yolo" type="list" label="YOLO text files">
-		<discover_datasets pattern="(?P&lt;name&gt;.+)\.txt" visible="true" directory="./output" format="txt"/>
+            <discover_datasets pattern="(?P&lt;designation&gt;.+)\.txt" directory="./output" format="txt"/>
         </collection>
     </outputs>
     <tests>
@@ -42,21 +42,21 @@
                 <element name="in_json">
                     <assert_contents>
                         <has_n_lines n="1" />
-			<has_text text="0.8532289628180039" />
-		    </assert_contents>
+                        <has_text text="0.8532289628180039" />
+                    </assert_contents>
                 </element>
-	        <element name="in_json1">
+                <element name="in_json1">
                     <assert_contents>
-		        <has_n_lines n="1" />
+                        <has_n_lines n="1" />
                         <has_text text="0.7710371819960861" />
-		    </assert_contents>
+                    </assert_contents>
                 </element>
             </output_collection>
         </test>
         <test>
             <param name="in_json" value="in_json_noext,in_json1_noext" />
             <param name="class_name" value="class_names.txt" />
-	    <output_collection name="output_yolo">
+            <output_collection name="output_yolo">
                 <element name="in_json1_noext">
                     <assert_contents>
                         <has_n_lines n="1" />