storescu
Sends DICOM files to a peer with C-STORE, all on one association, and reports each file's result. It can send images in another transfer syntax when the peer accepts it.
When to use it
Use storescu to push files to a PACS, a router, a viewer or a test
server: a study after anonymize, files made with
create, or a backlog after an outage. It proposes a
presentation context for each SOP class among the files and sends every
file in turn.
It sends the files you name: it does not walk directories (use
study/*.dcm, or find … -exec), and it does not query or retrieve. To
send over HTTP instead, use stow.
The closest tools are dcmtk's storescu and dcmsend, and pynetdicom's
python -m pynetdicom storescu.
Examples
Send a study
go-dicom storescu -aec STORESCP pacs:11112 study/*.dcmRequesting Association with pacs:11112 (AE: STORESCP)
Association accepted
Sending: study/ct.dcm
Stored successfully
Sending: study/mr.dcm
Stored successfully
Results: 2 sent, 0 failed-aec is the peer's AE title, -aet yours (default STORESCU). The
peer often admits only calling titles it knows.
When the peer refuses your calling title
go-dicom storescu -aec STORESCP pacs:11112 ct.dcmRequesting Association with pacs:11112 (AE: STORESCP)
Association failed: association error [ASSOCIATION_REJECTED]: association rejected: result=1, source=1, reason=3
Results: 0 sent, 1 failed
Error: 1 file(s) failed to sendReason 3 is "calling AE title not recognized": give the title the peer
knows you by, -aet CT01.
Send compressed, losslessly
go-dicom storescu -aec STORESCP -syntax jpeg-ls pacs:11112 ct.dcm…
Sending: ct.dcm
As JPEG-LS Lossless
Stored successfully-syntax takes any name compress takes (rle, jpeg-ls,
jpeg2000, htj2k, …), an uncompressed one (explicit, implicit,
deflated, big-endian) or a UID. The file is re-encoded in memory; it is
not changed on disk. A file the peer does not accept in that syntax goes as
it is.
Send 8-bit images as JPEG
go-dicom storescu -aec STORESCP -syntax jpeg -quality 90 pacs:11112 rgb.dcm
go-dicom storescu -aec STORESCP -jpeg-quality 85 pacs:11112 rgb.dcmSending: rgb.dcm
As JPEG Baseline, lossy; the SOP Instance UID is kept
Stored successfully
…
Sending: rgb.dcm
As JPEG Baseline, quality 85
Stored successfully-jpeg-quality sends uncompressed 8-bit images as JPEG Baseline when the
peer accepts it, and the rest as they are. -chroma 422 halves the color
resolution.
Warning
-syntax jpeg, jpeg-extended, jpeg-ls-near, jpeg2000-lossy,
htj2k-lossy and -jpeg-quality lose detail. Unlike
compress, which gives a lossy copy a new SOP Instance UID,
storescu keeps the UID, so the peer holds a lossy instance under the
original's UID.
Notes
- Exit status is 0 when every file was stored, 1 when any failed
(
Error: 1 file(s) failed to send). A file that cannot be read counts as failed; a directory given as an argument is one of them. -timeoutis in seconds (default 60).-eventsrecords the association as JSON lines (Events). The-tls…options are those of echoscu.- See CONFORMANCE.md, Transfer syntaxes negotiated by default.
See also
- storescp, qrscp, echoscu, compress, stow
- Networking with an SCU
- Pixel data
- TLS and security
- Examples
Options