Update README.md
Browse files
README.md
CHANGED
@@ -9,16 +9,25 @@ Automatic detection of blast cells in ALL data using transformers.
|
|
9 |
Official implementation of our work: *"Automated Identification of Cell Populations in Flow Cytometry Data with Transformers"*
|
10 |
by Matthias Wödlinger, Michael Reiter, Lisa Weijler, Margarita Maurer-Granofszky, Angela Schumich, Elisa O Sajaroff, Stefanie Groeneveld-Krentz, Jorge G Rossi, Leonid Karawajew, Richard Ratei and Michael Dworzak
|
11 |
|
12 |
-
##
|
13 |
|
14 |
Load the pretrained model from huggingface
|
15 |
|
16 |
-
```
|
17 |
from transformers import AutoModel
|
18 |
flowformer = AutoModel.from_pretrained("matth/flowformer", trust_remote_code=True)
|
19 |
```
|
20 |
|
21 |
-
`trust_remote_code=True` is necessary because the model code uses a custom architecture.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
22 |
|
23 |
## Citation
|
24 |
|
|
|
9 |
Official implementation of our work: *"Automated Identification of Cell Populations in Flow Cytometry Data with Transformers"*
|
10 |
by Matthias Wödlinger, Michael Reiter, Lisa Weijler, Margarita Maurer-Granofszky, Angela Schumich, Elisa O Sajaroff, Stefanie Groeneveld-Krentz, Jorge G Rossi, Leonid Karawajew, Richard Ratei and Michael Dworzak
|
11 |
|
12 |
+
## Load the model
|
13 |
|
14 |
Load the pretrained model from huggingface
|
15 |
|
16 |
+
```python
|
17 |
from transformers import AutoModel
|
18 |
flowformer = AutoModel.from_pretrained("matth/flowformer", trust_remote_code=True)
|
19 |
```
|
20 |
|
21 |
+
`trust_remote_code=True` is necessary because the model code uses a custom architecture.
|
22 |
+
|
23 |
+
## Usage
|
24 |
+
|
25 |
+
The model expects as input a pytorch tensor `x` with shape `batch_size x num_cells x num_markers`.
|
26 |
+
The pretrained model is trained with the the markers: *TIME, FSC-A, FSC-W, SSC-A, CD20, CD10, CD45, CD34, CD19, CD38, SY41*. If you use different markers (or a different ordering of markers), you need to specify this by setting the `markers` kwarg in the model forward pass:
|
27 |
+
|
28 |
+
```python
|
29 |
+
output = flowformer(x, markers=["Marker1", "Marker2", "Marker3"])
|
30 |
+
```
|
31 |
|
32 |
## Citation
|
33 |
|