0
|
1 <tool id="yolo" name="YOLO" version="1.0">
|
|
2 <description>real-time object detection</description>
|
|
3 <requirements>
|
|
4 <requirement type="package" version="1.0">darknet</requirement>
|
|
5 </requirements>
|
|
6 <command detect_errors="exit_code"><![CDATA[
|
19
|
7 mkdir output_shape_confidence_dir &&
|
9
|
8 mkdir input_dir &&
|
19
|
9 mkdir output_png_dir &&
|
18
|
10 cp -R /home/greg/_conda/envs/__darknet@1.0/bin/* .
|
13
|
11 #for $i in $input:
|
14
|
12 #set input_filename = $i.file_name
|
15
|
13 #set full_name = $i.name
|
|
14 #set head = $full_name.split('.')[0]
|
21
|
15 #set output_filename_image = '%s_predictions.png' % $head
|
19
|
16 #set output_filename_shape_confidence = '%s_shape_detection_confidence.tabular' % $head
|
18
|
17 && ln -s $input_filename input_dir/$full_name
|
21
|
18 && darknet detect cfg/yolo.cfg yolo.weights 'input_dir/$full_name' -thresh $thresh -f jpg > output_shape_confidence_dir/$output_filename_shape_confidence
|
|
19 && mv ./predictions.jpg output_png_dir/$output_filename_image
|
9
|
20 #end for
|
0
|
21 ]]></command>
|
|
22 <inputs>
|
8
|
23 <param name="input" format="jpg" type="data_collection" collection_type="list" label="Collection of image files" />
|
6
|
24 <param name="thresh" type="float" value="0.25" label="Object detection threshold" />
|
19
|
25 <param name="output_shape_confidence" type="select" display="radio" label="Output shape detection confidence levels?">
|
|
26 <option value="yes" selected="true">Yes</option>
|
|
27 <option value="no">No</option>
|
|
28 </param>
|
0
|
29 </inputs>
|
|
30 <outputs>
|
19
|
31 <collection name="output_shape_confidence" type="list" label="${tool.name} (shape detection confidence) on ${on_string}">
|
|
32 <discover_datasets pattern="__name__" directory="output_shape_confidence_dir" format="tabular" />
|
|
33 <filter>output_shape_confidence == 'yes'</filter>
|
8
|
34 </collection>
|
21
|
35 <collection name="output_shape" type="list" label="${tool.name} (shapes) on ${on_string}">
|
|
36 <discover_datasets pattern="__name__" directory="output_png_dir" format="png" />
|
|
37 </collection>
|
0
|
38 </outputs>
|
|
39 <tests>
|
|
40 <test>
|
|
41 </test>
|
|
42 </tests>
|
|
43 <help>
|
|
44 **What it does**
|
|
45
|
|
46 You only look once (YOLO) is a state-of-the-art, real-time object detection system.
|
|
47
|
|
48 -----
|
|
49
|
|
50 **Options**
|
|
51
|
|
52 </help>
|
|
53 <citations>
|
|
54 <citation type="bibtex">
|
|
55 @misc{darknet13,
|
|
56 author = {Joseph Redmon},
|
|
57 title = {Darknet: Open Source Neural Networks in C},
|
|
58 url = {http://pjreddie.com/darknet/},
|
|
59 year = {2013--2016}}
|
|
60 </citation>
|
|
61 <citation type="bibtex">
|
|
62 @article{redmon2016yolo9000,
|
|
63 title={YOLO9000: Better, Faster, Stronger},
|
|
64 author={Redmon, Joseph and Farhadi, Ali},
|
|
65 journal={arXiv preprint arXiv:1612.08242},
|
|
66 year={2016}}
|
|
67 </citation>
|
|
68 </citations>
|
|
69 </tool>
|