diff --git a/utils/polus-csv-collection-merger/Dockerfile b/utils/polus-csv-collection-merger/Dockerfile deleted file mode 100644 index 9137b8539..000000000 --- a/utils/polus-csv-collection-merger/Dockerfile +++ /dev/null @@ -1,4 +0,0 @@ -FROM alpine -COPY VERSION / -COPY script.sh script.sh -ENTRYPOINT ["sh", "script.sh"] \ No newline at end of file diff --git a/utils/polus-csv-collection-merger/README.md b/utils/polus-csv-collection-merger/README.md deleted file mode 100644 index ea885e526..000000000 --- a/utils/polus-csv-collection-merger/README.md +++ /dev/null @@ -1,45 +0,0 @@ -# Polus CSV Collection Merger Plugin - -This plugin helps to merge multiple CSV Collections in WIPP into one collection for later analysis. - -For more information on WIPP, visit the [official WIPP page](https://isg.nist.gov/deepzoomweb/software/wipp). - -**This plugin is in development and is subject for change** - -## Options - -This plugin takes four input parameters and one output parameter: - -| Name | Description | I/O | WIPP Type | -|----------------------|------------------------------------------------|--------|---------------| -| `input-collection-a` | Input CSV collection A | Input | csvCollection | -| `input-collection-b` | Input CSV collection B | Input | csvCollection | -| `append-a` | Option to append collection ID to files from A | Input | boolean | -| `append-b` | Option to append collection ID to files from B | Input | boolean | -| `output` | Output CSV collection | Output | csvCollection | - -## Build the plugin - -```bash -docker build . -t labshare/polus-csv-collection-merger:0.1.1 -``` - - -## Run the plugin - -### Manually - -To test, create 3 folders: `` and `` should contain csv collections you would like to merge. `` is the target folder which will contain the merged files. - -Run the docker container -```bash -docker run -v :/a \ - -v :/b \ - -v :/c \ - labshare/polus-csv-collection-merger:0.1.1 \ - --input-collection-a /a \ - --input-collection-b /b \ - --append-a 'true' \ - --append-b 'true' \ - --output /c -``` \ No newline at end of file diff --git a/utils/polus-csv-collection-merger/VERSION b/utils/polus-csv-collection-merger/VERSION deleted file mode 100644 index 6da28dde7..000000000 --- a/utils/polus-csv-collection-merger/VERSION +++ /dev/null @@ -1 +0,0 @@ -0.1.1 \ No newline at end of file diff --git a/utils/polus-csv-collection-merger/csvcollectionsmerger.cwl b/utils/polus-csv-collection-merger/csvcollectionsmerger.cwl deleted file mode 100644 index fb0684d11..000000000 --- a/utils/polus-csv-collection-merger/csvcollectionsmerger.cwl +++ /dev/null @@ -1,28 +0,0 @@ -class: CommandLineTool -cwlVersion: v1.2 -inputs: - append-a: - inputBinding: - prefix: --append-a - type: boolean? - append-b: - inputBinding: - prefix: --append-b - type: boolean? - input-collection-a: - inputBinding: - prefix: --input-collection-a - type: Directory - input-collection-b: - inputBinding: - prefix: --input-collection-b - type: Directory - output: - inputBinding: - prefix: --output - type: Directory -outputs: - output: !!python/name:builtins.NotImplementedError '' -requirements: - DockerRequirement: - dockerPull: polusai/csv-collection-merger:0.1.2 diff --git a/utils/polus-csv-collection-merger/ict.yaml b/utils/polus-csv-collection-merger/ict.yaml deleted file mode 100644 index 308334ce3..000000000 --- a/utils/polus-csv-collection-merger/ict.yaml +++ /dev/null @@ -1,61 +0,0 @@ -author: -- Konstantin taletskiy -contact: konstantin.taletskiy@labshare.org -container: polusai/csv-collection-merger:0.1.2 -description: Merge two csv collections. You have an option to prepend collection name - to avoid name conflicts. -entrypoint: '[python3, main.py]' -inputs: -- description: Input csv collection A. - format: - - csvCollection - name: input-collection-a - required: true - type: path -- description: Append collection name to collection A. - format: - - boolean - name: append-a - required: false - type: boolean -- description: Input csv collection B. - format: - - csvCollection - name: input-collection-b - required: true - type: path -- description: Append collection name to collection B. - format: - - boolean - name: append-b - required: false - type: boolean -name: polusai/CSVcollectionsmerger -outputs: -- description: Output csv collection for the plugin - format: - - csvCollection - name: output - required: true - type: path -repository: https://github.com/polusai/image-tools -specVersion: 1.0.0 -title: CSV collections merger -ui: -- description: Pick a collection... - key: inputs.input-collection-a - title: 'CSV Collection A: ' - type: path -- description: Pick an option... - key: inputs.append-a - title: 'Append collection name to filenames in A: ' - type: checkbox -- description: Pick a collection... - key: inputs.input-collection-b - title: 'CSV Collection B: ' - type: path -- description: Pick an option... - key: inputs.append-b - title: 'Append collection name to filenames in B: ' - type: checkbox -version: 0.1.2 diff --git a/utils/polus-csv-collection-merger/plugin.json b/utils/polus-csv-collection-merger/plugin.json deleted file mode 100644 index d777c0c06..000000000 --- a/utils/polus-csv-collection-merger/plugin.json +++ /dev/null @@ -1,61 +0,0 @@ -{ - "name": "CSV collections merger", - "version": "0.1.2", - "title": "CSV collections merger", - "description": "Merge two csv collections. You have an option to prepend collection name to avoid name conflicts.", - "author": "Konstantin taletskiy (konstantin.taletskiy@labshare.org)", - "containerId": "polusai/csv-collection-merger:0.1.2", - "inputs": [ - { - "name": "input-collection-a", - "type": "csvCollection", - "description": "Input csv collection A." - }, - { - "name": "append-a", - "type": "boolean", - "required": "false", - "description": "Append collection name to collection A." - }, - { - "name": "input-collection-b", - "type": "csvCollection", - "description": "Input csv collection B." - }, - { - "name": "append-b", - "type": "boolean", - "required": "false", - "description": "Append collection name to collection B." - } - ], - "outputs": [ - { - "name": "output", - "type": "csvCollection", - "description": "Output csv collection for the plugin" - } - ], - "ui": [ - { - "key": "inputs.input-collection-a", - "title": "CSV Collection A: ", - "description": "Pick a collection..." - }, - { - "key": "inputs.append-a", - "title": "Append collection name to filenames in A: ", - "description": "Pick an option..." - }, - { - "key": "inputs.input-collection-b", - "title": "CSV Collection B: ", - "description": "Pick a collection..." - }, - { - "key": "inputs.append-b", - "title": "Append collection name to filenames in B: ", - "description": "Pick an option..." - } - ] -} \ No newline at end of file diff --git a/utils/polus-csv-collection-merger/script.sh b/utils/polus-csv-collection-merger/script.sh deleted file mode 100644 index 646306ddd..000000000 --- a/utils/polus-csv-collection-merger/script.sh +++ /dev/null @@ -1,61 +0,0 @@ -#!/bin/sh - -while [[ $# -gt 0 ]] -do -key="$1" - -case $key in - --input-collection-a) - INPUT_A="$2" - shift # past argument - shift # past value - ;; - --input-collection-b) - INPUT_B="$2" - shift # past argument - shift # past value - ;; - --append-a) - APPEND_A="$2" - shift # past argument - shift # past value - ;; - --append-b) - APPEND_B="$2" - shift # past argument - shift # past value - ;; - --output) - OUTPUT="$2" - shift # past argument - shift # past value - ;; -esac -done - -echo "INPUT COLLECTION A = ${INPUT_A}" -echo "INPUT COLLECTION B = ${INPUT_B}" -echo "APPEND A = ${APPEND_A}" -echo "APPEND B = ${APPEND_B}" -echo "OUTPUT = ${OUTPUT}" - -COLLECTION_A="$(basename $INPUT_A)" -COLLECTION_B="$(basename $INPUT_B)" -echo " " - -echo "Copying files from collection A ($COLLECTION_A):" -for f in $INPUT_A/*; do echo "$(basename $f)"; done -if [ "$APPEND_A" = "true" ]; then - for f in $INPUT_A/*; do cp "$f" "$OUTPUT"/"$COLLECTION_A"_"$(basename $f)"; done -else - for f in $INPUT_A/*; do cp "$f" "$OUTPUT"/"$(basename $f)"; done -fi -echo " " - -echo "Copying files from collection B ($COLLECTION_B):" -for f in $INPUT_B/*; do echo "$(basename $f)"; done -if [ "$APPEND_B" = "true" ]; then - for f in $INPUT_B/*; do cp "$f" "$OUTPUT"/"$COLLECTION_B"_"$(basename $f)"; done -else - for f in $INPUT_B/*; do cp "$f" "$OUTPUT"/"$(basename $f)"; done -fi \ No newline at end of file