Ticket number:
Please, don't forget to add it (this will make your life MUCH easier)
- Monday's ticket number referenced
- Brief description of changes
import os | |
import pydicom # pydicom is using the gdcm package for decompression | |
def clean_text(string): | |
# clean and standardize text descriptions, which makes searching files easier | |
forbidden_symbols = ["*", ".", ",", "\"", "\\", "/", "|", "[", "]", ":", ";", " "] | |
for symbol in forbidden_symbols: | |
string = string.replace(symbol, "-") # replace everything with an dash (safer) or underscore | |
return string.lower() |
{ | |
"studies": [ | |
{ | |
"StudyInstanceUID": "1.2.840.113704.1.111.6364.1415112213.5", | |
"StudyDescription": "RT 6TH RIB", | |
"StudyDate": "20141104", | |
"StudyTime": "135936", | |
"PatientName": "TEST, TEST", | |
"PatientID": "123456789", | |
"AccessionNumber": "", |
import dcmjs from 'dcmjs'; | |
const { data } = dcmjs; | |
const { DicomMessage, DicomMetaDictionary } = data; | |
const arrayBufferOfDICOM = /** Your DICOM file binary */ | |
const dicomDataInTheCorrectResponseFormat = DicomMessage.readFile(arrayBufferOfDICOM).dict; | |
const dicomDataInANaturalizedFormat = DicomMetaDictionary.naturalizeDataset(dicomDataInTheCorrectResponseFormat); |
[ | |
{ | |
"00080005": { | |
"vr": "CS", | |
"Value": ["ISO_IR 100"] | |
}, | |
"00080008": { | |
"vr": "CS", | |
"Value": ["ORIGINAL", "PRIMARY", "LOCALIZER"] | |
}, |
[ | |
{ | |
"00080005": { | |
"vr": "CS", | |
"Value": ["ISO_IR 100"] | |
}, | |
"00080054": { | |
"vr": "AE", | |
"Value": ["DCM4CHEE"] | |
}, |
let something = (() => { | |
// so called "encapsulation" here | |
// ... | |
// and then... | |
return { | |
firstPublic: ..., | |
second public: ... | |
}; | |
}) (); |
{ | |
1: ..., | |
2:[ | |
function (require, module, exports) { | |
const XHR = require ('../ lib / xhr.js'); | |
const DOM = require ('../ lib / domUtils.js'); | |
function loader {container} { | |
const output = DOM.printTo (container); | |
// myShirt.js now have dependencies, the shopping cart and the inventory | |
// module in the same directory as myShirt.js | |
define (["./ cart", "./inventory"], (cart, inventory) => { | |
// returns an object to define the module "myShirt". | |
return { | |
color: "blue", | |
size: "large", | |
addToCart: () => { | |
inventory.remove(this); | |
cart.add(this); |
// request dependency: | |
let a = require ('a.js'); // Node.js modules | |
import a from 'a.js'; // ES modules | |
// ... your code here ... | |
// a way to turn the things visible outside the module: | |
module.exports = something; // Node.js | |
export something; |