oct-converter


Nameoct-converter JSON
Version 0.6.2 PyPI version JSON
download
home_page
SummaryExtract OCT and fundus data from proprietary file formats.
upload_time2024-01-03 17:47:32
maintainer
docs_urlNone
author
requires_python>=3.7
licenseMIT License Copyright (c) 2021 Mark Graham Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords oct fundus reader fda e2e zeiss heidelberg topcon
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <h1 align="center">OCT Converter</h1>
<p align="center">
 Python-based tools for reading OCT and fundus data.
</p>


<p align="center">
    <img width="320" height="320" src="https://user-images.githubusercontent.com/7947315/202814956-6e7e6702-82f4-4250-8625-ec23c1727e4f.jpg">
    <img width="320" height="320" src="https://user-images.githubusercontent.com/7947315/202814575-9f18b7ca-3028-4d23-9b82-015995c44eab.gif">
</p>

## Description
In ophthalmology, data acquired from the scanner is often exported in the manufacturer's proprietary file format. OCT-Converter provides python-based tools for extracting images (optical coherence tomography and fundus), as well as associated metadata, from these files.

## Supported file formats
* .fds (Topcon)
* .fda (Topcon)
* .e2e (Heidelberg)
* .img (Zeiss)
* .oct (Bioptigen)
* .OCT (Optovue)
* .dcm

## Installation
Requires python 3.7 or higher.

```bash
pip install oct-converter
```


## Usage
A number of example usage scripts are included in `examples/`.

Here is an example of reading a .fds file:

```python
from oct_converter.readers import FDS

# An example .fds file can be downloaded from the Biobank website:
# https://biobank.ndph.ox.ac.uk/showcase/refer.cgi?id=30
filepath = '/home/mark/Downloads/eg_oct_fds.fds'
fds = FDS(filepath)

oct_volume = fds.read_oct_volume()  # returns an OCT volume with additional metadata if available
oct_volume.peek(show_contours=True) # plots a montage of the volume, with layer segmentations is available
oct_volume.save('fds_testing.avi')  # save volume as a movie
oct_volume.save('fds_testing.png')  # save volume as a set of sequential images, fds_testing_[1...N].png
oct_volume.save_projection('projection.png') # save 2D projection

fundus_image = fds.read_fundus_image()  # returns a  Fundus image with additional metadata if available
fundus_image.save('fds_testing_fundus.jpg')

metadata = fds.read_all_metadata(verbose=True) # extracts all other metadata
with open("fds_metadata.json", "w") as outfile:
    outfile.write(json.dumps(metadata, indent=4))

# create and save a DICOM
dcm = create_dicom_from_oct(filepath)
```

## Contributions
Are welcome! Here is a [development roadmap](https://github.com/marksgraham/OCT-Converter/issues/86), including some easy first issues. Please open a [new issue](https://github.com/marksgraham/OCT-Converter/issues/new) to discuss any potential contributions.

## Updates
9 November 2023
- Can now save .e2e, .img, .oct, and .OCT files as DICOMs with correct headers.

22 September 2023
- DICOM support: can now save .fda/.fds files as DICOMs with correct headers.
- Much more complete extraction of .fda/.fds metadata.

28 March 2023
- Metadata extraction for .fds expanded to match that of .fda file.

31 January 2023
- Greatly extended support for extracting metadata from .fda files.

7 August 2022
- Contours (layer segmentations) are now extracted from .e2e files.
- Acquisition date is now extracted from .e2e files.

16 June 2022
- Initial support for reading Optovue OCTs.
- Laterality is now extracted separately for each OCT/fundus image for .e2e files.
- More patient info extracted from .e2e files (name, sex, birthdate, patient ID).

24 Aug 2021
- Reading the Bioptigen .OCT format is now supported.

11 June 2021
- Can now specify whether Zeiss .img data needs to be de-interlaced during reading.

14 May 2021
- Can save 2D projections of OCT volumes.

30 October 2020
- Extract fundus and laterality data from .e2e
- Now attempts to extract additional volumetric data from .e2e files that was previously missed.

22 August 2020
- Experimental support for reading OCT data from .fda files.

14 July 2020
- Can now read fundus data from .fda files.

## Related projects
- [uocte](https://bitbucket.org/uocte/uocte/wiki/Home) inspired and enabled this project
- [LibE2E](https://github.com/neurodial/LibE2E) and [LibOctData](https://github.com/neurodial/LibOctData) provided some additional descriptions of the .e2e file spec
- [eyepy](https://github.com/MedVisBonn/eyepy) for python-based import, visualisation, and analysis of OCT data
- [eyelab](https://github.com/MedVisBonn/eyelab) is a tool for annotating this data

## Clinical use
We can't guarantee images extracted with OCT-Converter will match those extracted or viewed with the manufacturer's software. Any use in clinical settings is at the user's own risk.

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "oct-converter",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": "",
    "keywords": "oct,fundus,reader,fda,e2e,zeiss,heidelberg,topcon",
    "author": "",
    "author_email": "Mark Graham <markgraham539@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/2e/f1/6ac0d9ef70d702c0b57045b8db3237a91f28e9bfb20dd752b1e15eaeaecd/oct_converter-0.6.2.tar.gz",
    "platform": null,
    "description": "<h1 align=\"center\">OCT Converter</h1>\n<p align=\"center\">\n Python-based tools for reading OCT and fundus data.\n</p>\n\n\n<p align=\"center\">\n    <img width=\"320\" height=\"320\" src=\"https://user-images.githubusercontent.com/7947315/202814956-6e7e6702-82f4-4250-8625-ec23c1727e4f.jpg\">\n    <img width=\"320\" height=\"320\" src=\"https://user-images.githubusercontent.com/7947315/202814575-9f18b7ca-3028-4d23-9b82-015995c44eab.gif\">\n</p>\n\n## Description\nIn ophthalmology, data acquired from the scanner is often exported in the manufacturer's proprietary file format. OCT-Converter provides python-based tools for extracting images (optical coherence tomography and fundus), as well as associated metadata, from these files.\n\n## Supported file formats\n* .fds (Topcon)\n* .fda (Topcon)\n* .e2e (Heidelberg)\n* .img (Zeiss)\n* .oct (Bioptigen)\n* .OCT (Optovue)\n* .dcm\n\n## Installation\nRequires python 3.7 or higher.\n\n```bash\npip install oct-converter\n```\n\n\n## Usage\nA number of example usage scripts are included in `examples/`.\n\nHere is an example of reading a .fds file:\n\n```python\nfrom oct_converter.readers import FDS\n\n# An example .fds file can be downloaded from the Biobank website:\n# https://biobank.ndph.ox.ac.uk/showcase/refer.cgi?id=30\nfilepath = '/home/mark/Downloads/eg_oct_fds.fds'\nfds = FDS(filepath)\n\noct_volume = fds.read_oct_volume()  # returns an OCT volume with additional metadata if available\noct_volume.peek(show_contours=True) # plots a montage of the volume, with layer segmentations is available\noct_volume.save('fds_testing.avi')  # save volume as a movie\noct_volume.save('fds_testing.png')  # save volume as a set of sequential images, fds_testing_[1...N].png\noct_volume.save_projection('projection.png') # save 2D projection\n\nfundus_image = fds.read_fundus_image()  # returns a  Fundus image with additional metadata if available\nfundus_image.save('fds_testing_fundus.jpg')\n\nmetadata = fds.read_all_metadata(verbose=True) # extracts all other metadata\nwith open(\"fds_metadata.json\", \"w\") as outfile:\n    outfile.write(json.dumps(metadata, indent=4))\n\n# create and save a DICOM\ndcm = create_dicom_from_oct(filepath)\n```\n\n## Contributions\nAre welcome! Here is a [development roadmap](https://github.com/marksgraham/OCT-Converter/issues/86), including some easy first issues. Please open a [new issue](https://github.com/marksgraham/OCT-Converter/issues/new) to discuss any potential contributions.\n\n## Updates\n9 November 2023\n- Can now save .e2e, .img, .oct, and .OCT files as DICOMs with correct headers.\n\n22 September 2023\n- DICOM support: can now save .fda/.fds files as DICOMs with correct headers.\n- Much more complete extraction of .fda/.fds metadata.\n\n28 March 2023\n- Metadata extraction for .fds expanded to match that of .fda file.\n\n31 January 2023\n- Greatly extended support for extracting metadata from .fda files.\n\n7 August 2022\n- Contours (layer segmentations) are now extracted from .e2e files.\n- Acquisition date is now extracted from .e2e files.\n\n16 June 2022\n- Initial support for reading Optovue OCTs.\n- Laterality is now extracted separately for each OCT/fundus image for .e2e files.\n- More patient info extracted from .e2e files (name, sex, birthdate, patient ID).\n\n24 Aug 2021\n- Reading the Bioptigen .OCT format is now supported.\n\n11 June 2021\n- Can now specify whether Zeiss .img data needs to be de-interlaced during reading.\n\n14 May 2021\n- Can save 2D projections of OCT volumes.\n\n30 October 2020\n- Extract fundus and laterality data from .e2e\n- Now attempts to extract additional volumetric data from .e2e files that was previously missed.\n\n22 August 2020\n- Experimental support for reading OCT data from .fda files.\n\n14 July 2020\n- Can now read fundus data from .fda files.\n\n## Related projects\n- [uocte](https://bitbucket.org/uocte/uocte/wiki/Home) inspired and enabled this project\n- [LibE2E](https://github.com/neurodial/LibE2E) and [LibOctData](https://github.com/neurodial/LibOctData) provided some additional descriptions of the .e2e file spec\n- [eyepy](https://github.com/MedVisBonn/eyepy) for python-based import, visualisation, and analysis of OCT data\n- [eyelab](https://github.com/MedVisBonn/eyelab) is a tool for annotating this data\n\n## Clinical use\nWe can't guarantee images extracted with OCT-Converter will match those extracted or viewed with the manufacturer's software. Any use in clinical settings is at the user's own risk.\n",
    "bugtrack_url": null,
    "license": "MIT License  Copyright (c) 2021  Mark Graham  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
    "summary": "Extract OCT and fundus data from proprietary file formats.",
    "version": "0.6.2",
    "project_urls": {
        "Homepage": "https://github.com/marksgraham/OCT-Converter"
    },
    "split_keywords": [
        "oct",
        "fundus",
        "reader",
        "fda",
        "e2e",
        "zeiss",
        "heidelberg",
        "topcon"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4a5978eb4491f8fc7aedf10b252b30dcfbd09b1522cb4b249df103ae37aca944",
                "md5": "fcc5e68d8d26cf32e8beed22fe9eeba8",
                "sha256": "6e0af928d31948752f416c79d58b9d256a2e7cdfc5acfff5d9d7541fc5e10bad"
            },
            "downloads": -1,
            "filename": "oct_converter-0.6.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "fcc5e68d8d26cf32e8beed22fe9eeba8",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7",
            "size": 52429,
            "upload_time": "2024-01-03T17:47:26",
            "upload_time_iso_8601": "2024-01-03T17:47:26.614620Z",
            "url": "https://files.pythonhosted.org/packages/4a/59/78eb4491f8fc7aedf10b252b30dcfbd09b1522cb4b249df103ae37aca944/oct_converter-0.6.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2ef16ac0d9ef70d702c0b57045b8db3237a91f28e9bfb20dd752b1e15eaeaecd",
                "md5": "243c2f5fae5485f536ddfd9c3bed5fef",
                "sha256": "b8e7c23391142fea6904ff24ece424ead43e111917978b7e36f7e9e0c33e1973"
            },
            "downloads": -1,
            "filename": "oct_converter-0.6.2.tar.gz",
            "has_sig": false,
            "md5_digest": "243c2f5fae5485f536ddfd9c3bed5fef",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7",
            "size": 35646,
            "upload_time": "2024-01-03T17:47:32",
            "upload_time_iso_8601": "2024-01-03T17:47:32.111644Z",
            "url": "https://files.pythonhosted.org/packages/2e/f1/6ac0d9ef70d702c0b57045b8db3237a91f28e9bfb20dd752b1e15eaeaecd/oct_converter-0.6.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-03 17:47:32",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "marksgraham",
    "github_project": "OCT-Converter",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "oct-converter"
}
        
Elapsed time: 0.15950s