Real and simulated data for testing image analysis software
Project description
# pythologist-test-images
Images for use in unit tests etc.
List available datasets:
```python
from pythologist_test_images import TestImages
print(TestImages().datasets)
```
> ['IrisSpatialFeatures', 'Small', 'Tiny']
get a path pointing to the dataset
```python
path = TestImages().raw('IrisSpatialFeatures')
print(path)
```
> '/Source/pythologist-test-images/data/IrisSpatialFeatures/Example'
get a CellDataFrame pythologist object (requires pythologistreader and pythologist `pip install pythologist-test-images[h5]`)
```python
cdf = TestImages().celldataframe('Tiny')
tdf = cdf.threshold('T-CELL','PD1').threshold('OTHER','PDL1').threshold('TUMOR','PDL1')
tdf.loc[tdf['sample_name'].str.contains('I'),'project_name'] = 'SlideModelInfiltrated'
tdf.loc[tdf['sample_name'].str.contains('E'),'project_name'] = 'SlideModelExcluded'
tdf.loc[tdf['sample_name'].str.contains('U'),'project_name'] = 'SlideModelUniform'
tdf['project_id'] = tdf['project_name']
(ggplot(cnts,aes(x='sample_name',y='mean_density_mm2',
ymin='mean_density_mm2+stderr_density_mm2',
ymax='mean_density_mm2-stderr_density_mm2',fill='project_name'))
+ geom_bar(stat='identity')
+ geom_errorbar()
+ facet_wrap('phenotype_label',scales='free_y')
+ theme_bw()
+ theme(panel_spacing_x=0.5)
+ theme(figure_size=(6,6))
)
```
![Image of counts](https://github.com/jason-weirather/pythologist-test-images/raw/master/images/counts.png?raw=true)
Images for use in unit tests etc.
List available datasets:
```python
from pythologist_test_images import TestImages
print(TestImages().datasets)
```
> ['IrisSpatialFeatures', 'Small', 'Tiny']
get a path pointing to the dataset
```python
path = TestImages().raw('IrisSpatialFeatures')
print(path)
```
> '/Source/pythologist-test-images/data/IrisSpatialFeatures/Example'
get a CellDataFrame pythologist object (requires pythologistreader and pythologist `pip install pythologist-test-images[h5]`)
```python
cdf = TestImages().celldataframe('Tiny')
tdf = cdf.threshold('T-CELL','PD1').threshold('OTHER','PDL1').threshold('TUMOR','PDL1')
tdf.loc[tdf['sample_name'].str.contains('I'),'project_name'] = 'SlideModelInfiltrated'
tdf.loc[tdf['sample_name'].str.contains('E'),'project_name'] = 'SlideModelExcluded'
tdf.loc[tdf['sample_name'].str.contains('U'),'project_name'] = 'SlideModelUniform'
tdf['project_id'] = tdf['project_name']
(ggplot(cnts,aes(x='sample_name',y='mean_density_mm2',
ymin='mean_density_mm2+stderr_density_mm2',
ymax='mean_density_mm2-stderr_density_mm2',fill='project_name'))
+ geom_bar(stat='identity')
+ geom_errorbar()
+ facet_wrap('phenotype_label',scales='free_y')
+ theme_bw()
+ theme(panel_spacing_x=0.5)
+ theme(figure_size=(6,6))
)
```
![Image of counts](https://github.com/jason-weirather/pythologist-test-images/raw/master/images/counts.png?raw=true)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
File details
Details for the file pythologist_test_images-1.0.0-py3-none-any.whl
.
File metadata
- Download URL: pythologist_test_images-1.0.0-py3-none-any.whl
- Upload date:
- Size: 7.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e3c7dc3f7addd73b538a9394c318c0f6c7636e617958422a570f02f3de0205bf |
|
MD5 | e57570d2cd3a275149c0ed5d6fc1afe3 |
|
BLAKE2b-256 | 6603ee1a7617468ac5bbbda785cc7afd729606837f1bc97161b6bbe83ee71422 |