Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## 0.2.1-dev1
## 0.2.1

* Refactor to facilitate local inference
* Removes BasicConfig from logger configuration
Expand Down
20 changes: 17 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,26 @@ These models are invoked via API as part of the partitioning bricks in the `unst

### Package

Requires [`torch>=1.8`](https://pytorch.org/get-started/locally/). Once this is satisfied, run
`pip install unstructured-inference`.
Run `pip install unstructured-inference`.

### Detectron2

[Detectron2](https://github.com/facebookresearch/detectron2) is required for most inference tasks
but is not automatically installed with this package.
For MacOS and Linux, build from source with:
```shell
pip install 'git+https://github.com/facebookresearch/detectron2.git@v0.4#egg=detectron2'
```
Other install options can be found in the
[Detectron2 installation guide](https://detectron2.readthedocs.io/en/latest/tutorials/install.html).

Windows is not officially supported by Detectron2, but some users are able to install it anyway.
See discussion [here](https://layout-parser.github.io/tutorials/installation#for-windows-users) for
tips on installing Detectron2 on Windows.

### Repository

Clone the repo and run `make install` to install dependencies.
To install the repository for development, clone the repo and run `make install` to install dependencies.
Run `make help` for a full list of install options.

## Getting Started
Expand Down
9 changes: 0 additions & 9 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,6 @@

from unstructured_inference.__version__ import __version__

try:
import torch

torch_ver = [int(x) for x in torch.__version__.split(".")[:2]]
assert torch_ver >= [1, 8]
except (ImportError, AssertionError) as e:
raise Exception("Requires PyTorch >= 1.8") from e

setup(
name="unstructured_inference",
description="A library for performing inference using trained models.",
Expand Down Expand Up @@ -57,7 +49,6 @@
entry_points={},
install_requires=[
"fastapi",
"detectron2@git+https://github.com/facebookresearch/detectron2.git@v0.6#egg=detectron2",
"layoutparser[layoutmodels,tesseract]",
"python-multipart",
"uvicorn",
Expand Down
2 changes: 1 addition & 1 deletion unstructured_inference/__version__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.2.1-dev1" # pragma: no cover
__version__ = "0.2.1" # pragma: no cover