Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 3 additions & 20 deletions httomo/templates/cor-sweep.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,6 @@ metadata:
{{- .Files.Get "schemas/cor-sweep-ui.json" | nindent 6 }}
spec:
entrypoint: run
volumeClaimTemplates:
- metadata:
name: tmpdir
spec:
accessModes: [ "ReadWriteOnce" ]
resources:
requests:
storage: 1Gi
storageClassName: netapp
arguments:
parameters:
- name: visitdir
Expand Down Expand Up @@ -108,13 +99,11 @@ spec:
- name: httomo-outdir-name
- name: nprocs
- name: memory
- name: tmpdir-path
value: /tmp
container:
image: ghcr.io/diamondlightsource/httomo:latest
env:
- name: CUPY_CACHE_DIR
value: "{{`{{ inputs.parameters.tmpdir-path }}`}}/.cupy/kernel_cache"
value: "/tmp/.cupy/kernel_cache"
- name: MKL_NUM_THREADS
value: "1"
- name: NUMEXPR_NUM_THREADS
Expand All @@ -140,8 +129,6 @@ spec:
volumeMounts:
- name: session
mountPath: "{{`{{ workflow.parameters.visitdir }}`}}"
- name: tmpdir
mountPath: "{{`{{ inputs.parameters.tmpdir-path }}`}}"
volumes:
- name: session
hostPath:
Expand All @@ -163,8 +150,6 @@ spec:
inputs:
parameters:
- name: output-dir-path
- name: tmpdir-path
value: /tmp
- name: output-filename
value: multi-page-tiff.tif
script:
Expand All @@ -178,7 +163,7 @@ spec:
IMAGE_DIR_PATTERN = "images_sweep_recon*"
OUTPUT_DIR = Path("{{`{{ inputs.parameters.output-dir-path }}`}}")
image_dir = list(OUTPUT_DIR.glob(IMAGE_DIR_PATTERN))[0]
OUT_PATH = "{{`{{ inputs.parameters.tmpdir-path }}`}}/{{`{{ inputs.parameters.output-filename }}`}}"
OUT_PATH = OUTPUT_DIR / "{{`{{ inputs.parameters.output-filename }}`}}"
filenames = list(image_dir.glob("*.tif"))
filenames.sort()
single_image = tifffile.tifffile.imread(filenames[0])
Expand All @@ -193,8 +178,6 @@ spec:
volumeMounts:
- name: session
mountPath: "{{`{{ workflow.parameters.visitdir }}`}}"
- name: tmpdir
mountPath: "{{`{{ inputs.parameters.tmpdir-path }}`}}"
volumes:
- name: session
hostPath:
Expand All @@ -203,6 +186,6 @@ spec:
outputs:
artifacts:
- name: sweep-res
path: "{{`{{ inputs.parameters.tmpdir-path }}`}}/{{`{{ inputs.parameters.output-filename }}`}}"
path: "{{`{{ inputs.parameters.output-dir-path }}`}}/{{`{{ inputs.parameters.output-filename }}`}}"
archive:
none: { }