Tools and Infrastructure: What You Need to Know
A non-technical overview of the computational landscape: GPUs and cloud computing, Python and common frameworks (PyTorch, TensorFlow), experiment tracking, and what these cost.
At some point in an AI project somebody will ask you to approve a purchase, sign a cloud agreement or put a compute line in a grant budget. This article is a tour of what the engineers use and roughly what it costs, so that those requests make sense. It is deliberately non-technical. You don't need to be able to use any of this, just to know what it is for.
The prices here are rough figures for late 2026 and they change quickly, so check current numbers before putting anything in a budget.
Why GPUs
Training a neural network consists of an enormous number of small multiplications that can be done at the same time. A graphics processing unit, or GPU, was designed to do exactly that kind of arithmetic for video games, and it turned out to suit neural networks very well. A job that takes a day on a GPU might take weeks on an ordinary processor.
Nearly all deep learning runs on GPUs made by Nvidia, largely because the standard software was built around Nvidia's programming system, CUDA. Alternatives exist and your engineers may have views about them.
For medical imaging the specification to look at first is the memory on the GPU. The model and the images it is working on have to fit in that memory together. A 2D classifier on small images fits almost anywhere. A 3D segmentation network working on CT volumes can fill the memory of a large card with a batch of two scans. When your engineers say a model "doesn't fit," this is what they mean, and it's why they shrink images or cut volumes into patches (see 2.5 Data Preprocessing and Augmentation).
Running a finished model on a new case, which engineers call inference, needs much less than training. Many models run acceptably on a modest GPU or even an ordinary processor.
Where the GPUs live
There are three places to get compute, and most groups end up using a mixture.
A workstation
A desktop machine with one or two good GPUs sits in your lab. A capable deep learning workstation costs somewhere between about $5,000 and $15,000 depending on the GPUs, and it will be useful for three or four years.
The attraction for clinical research is that the data never leaves the building, which makes privacy and ethics approval simpler. Once bought, it costs only electricity. The drawbacks are that somebody has to look after it, it can run only a few experiments at a time, and when a deadline arrives everyone wants it at once.
The institutional cluster
Most universities and many research hospitals run a shared computing cluster, and some countries have national research computing services (in Canada, the Digital Research Alliance). Access is often free or cheap for researchers.
Check two things before relying on it. One is whether the cluster is approved for patient data, since many general-purpose research clusters aren't, even for de-identified data. The other is the queue: on a busy shared system a job may wait hours or days to start, which is tolerable for long training runs and frustrating for quick experiments.
The cloud
Amazon, Google, Microsoft and a number of smaller specialist companies rent GPUs by the hour. A single mid-range GPU costs very roughly $0.50 to $4 an hour, and the largest multi-GPU machines cost tens of dollars an hour.
The cloud's strength is flexibility. You can rent twenty GPUs for a week to run a hyperparameter search and then give them back. Its weaknesses are that costs accumulate without anyone noticing (a machine left running over a holiday is a classic), that you also pay for storing data and for moving it out, and that patient data on someone else's computers needs proper agreements. In the United States that means a business associate agreement with the provider. In Europe it raises the question of where the data is physically held (see 2.7 De-Identification, Privacy, and Regulatory Compliance for Research Data). Your institution may already have a contract with one provider that covers this, and it's worth asking before the engineers open an account on a credit card.
As a rough rule, a workstation is the better buy for a group that trains models steadily, and the cloud suits occasional or bursty use.
How much compute a project needs
Less than the headlines about AI suggest. The eye-watering figures you read about are for training very large foundation models from scratch, which takes thousands of GPUs for weeks and is not something a clinical research group does.
A typical clinical project fine-tunes an existing model on a few thousand images or a few hundred volumes (see 3.3 Transfer Learning). A single training run of that kind takes somewhere from under an hour to a day or two on one GPU. The catch is that a project isn't one run. With hyperparameter tuning, repeated seeds, cross-validation and the many trips round the development loop, a project amounts to a few hundred runs (see 3.4 Hyperparameter Tuning and Model Selection). Even so, for most projects the total is hundreds to a few thousand GPU-hours: one workstation working for some months, or a few thousand dollars of cloud time.
Storage
Medical images are large, and storage is easy to forget in a budget. A CT study runs to hundreds of megabytes. A dataset of a few thousand studies is around a terabyte. Digital pathology is in another league: a single whole-slide image is often more than a gigabyte, so a few thousand slides is several terabytes.
You'll need room for the original data, the preprocessed copies, backups and the saved models. Storage has to meet the same privacy requirements as compute, and it has to be fast enough that reading the images doesn't become the slowest part of training.
The software
Almost all of it is free and open source, which is one of the pleasant surprises of the field.
Python
Python is the working language of machine learning. It isn't especially fast, but it is easy to read and nearly every tool in the field is built for it. If you want to learn one thing in order to look at your own data, Python is the one.
Frameworks
A deep learning framework is the software library that defines networks and runs the training arithmetic on the GPU. There are two that you'll hear named. PyTorch, which came out of Facebook's AI research group and had its first public releases in 2016 and early 2017, is what most research is done in now. TensorFlow, released by Google in 2015, was dominant earlier and is still found in many deployed systems and older codebases. They do the same job, and which one your team uses makes no difference to you, apart from the fact that a published model written in one takes some work to use in the other.
For classical machine learning on tabular data, the standard library is scikit-learn, with XGBoost and similar libraries for gradient-boosted trees.
Medical imaging tools
A layer of specialist software sits on top of the frameworks:
- MONAI is an open-source framework for medical imaging built on PyTorch, launched in 2020 by Nvidia and King's College London. It supplies medical-specific network designs, data loading, augmentations and metrics.
- nnU-Net is the self-configuring segmentation system mentioned in 2.1. It is a common first thing to try on any segmentation task.
- pydicom and SimpleITK read and manipulate DICOM and other medical image formats.
- 3D Slicer and ITK-SNAP are viewers and annotation tools (see 2.3 Data Annotation and Labeling for Clinical AI).
Notebooks
A Jupyter notebook is a document that mixes code, results and plots, and it is how a lot of exploratory work is done. Notebooks are handy for looking at data and showing results in a meeting. They are a poor place to keep the code that produces a paper's final numbers, because cells can be run out of order and it becomes hard to say exactly what was executed.
Keeping track
The remaining tools are about being able to say, later, exactly what was done. For a clinical researcher these are probably the most important ones on the list, since reproducibility is what a reviewer or regulator will ask about.
Version control, almost always Git, records every change to the code, so that any past version can be recovered. Code usually lives on a hosting service such as GitHub or an institutional equivalent.
Experiment tracking records, for every training run, the code version, the hyperparameters, the data version and the resulting metrics and curves. MLflow is a widely used open-source tracker and Weights & Biases a widely used commercial one. Without a tracker, this record lives in file names and somebody's memory, and questions like "which run produced Figure 3?" become archaeology.
Data versioning does the same for datasets: which cases and which labels made up the dataset at each point. Datasets change during a project as cases are added and labels corrected, and a result is only reproducible if you can recover the exact data behind it.
Containers, usually Docker, package the code together with the exact versions of all the software it depends on, so that it runs the same way on another machine or in three years' time.
If a model may become a product, this record-keeping stops being optional. The quality system and software lifecycle standards that regulators apply expect traceability from data to model to result (see 6.9 Software Lifecycle Requirements: IEC 62304 and 6.10 Design History File and Quality Management System Essentials).
What it all costs
Putting the pieces together for a single research project, in rough terms:
| Item | Rough cost |
|---|---|
| Compute | A workstation at $5,000 to $15,000, or a few thousand dollars of cloud time |
| Storage | Hundreds to a few thousand dollars, more for pathology |
| Software | Mostly free. Commercial annotation or tracking tools vary |
| Annotation | Specialist hours. Often the largest non-salary cost |
| People | An engineer or trainee for a year or more |
The people are by far the biggest item, and annotation is usually second. Compute is rarely more than a small fraction of the total, so it's generally a false economy to save on GPUs if it means an engineer spends days waiting for results.
What to ask about your own setup
- Where will the data be stored and processed, and is that location covered by the ethics approval and institutional policy?
- Who administers the machine or the cloud account, and who gets the bill?
- Is the code under version control, and are experiments being tracked?
- Can we identify the exact data and code behind any result we've reported?
- Is everything backed up somewhere other than one person's laptop?
Key takeaways
- Deep learning runs on GPUs. GPU memory limits how large the images and models can be, and 3D data runs into that limit first.
- Compute can come from a lab workstation, an institutional cluster or the cloud. Where patient data is allowed to go often decides between them.
- A typical clinical project fine-tunes an existing model and needs hundreds to a few thousand GPU-hours in total.
- Medical images need a lot of storage, and pathology slides need far more.
- The core software is free: Python, PyTorch or TensorFlow, and medical imaging libraries such as MONAI and nnU-Net.
- Version control, experiment tracking, data versioning and containers are what make results reproducible.
- People and annotation cost much more than compute.
What to read next
- 3.6 Working with an Engineering Team: The Clinician's Role: working with the people who use these tools
- 3.4 Hyperparameter Tuning and Model Selection: where most of the compute goes
- 2.7 De-Identification, Privacy, and Regulatory Compliance for Research Data: what has to be true before data goes on any of this hardware
- 7.5 Transparency and Reproducibility: what the record-keeping tools are for
- 8.3 Interoperability: DICOM, HL7 FHIR, and Integration Standards: connecting a finished model to clinical systems
This article is part of the AI in Clinical Research Knowledge Base.