Skip to content

Commit

Permalink
Updated README, minor comment update
Browse files Browse the repository at this point in the history
  • Loading branch information
davidmezzetti committed Aug 18, 2020
1 parent 46d15a1 commit 8672775
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 6 deletions.
22 changes: 18 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,30 @@ You can also install txtai directly from GitHub. Using a Python Virtual Environm

Python 3.6+ is supported

### Notes for Windows
This project has dependencies that require compiling native code. Linux environments usually work without an issue. Windows requires the following extra steps.
### Troubleshooting
This project has dependencies that require compiling native code. Windows and macOS systems require the following additional steps. Most Linux environments will install without any additional steps.

#### Windows

- Install C++ Build Tools - https://visualstudio.microsoft.com/visual-cpp-build-tools/
- If PyTorch errors are encountered, run the following command before installing paperai. See [pytorch.org](https://pytorch.org) for more information.
- PyTorch binaries are not on pip, the following url link must be added when installing

```
pip install txtai -f https://download.pytorch.org/whl/torch_stable.html
```
See [pytorch.org](https://pytorch.org) for more information.
#### macOS
- Run the following before installing
```
pip install torch===1.6.0 torchvision===0.7.0 -f https://download.pytorch.org/whl/torch_stable.html
brew install libomp
```
See [this link](https://github.com/kyamagu/faiss-wheels#prerequisite) for more information.
## Examples
The examples directory has a series of examples and notebooks giving an overview of txtai. See the list of notebooks below.
Expand Down
4 changes: 2 additions & 2 deletions src/python/txtai/embeddings.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,11 @@ def index(self, documents):
# Normalize embeddings
self.normalize(embeddings)

# Save configuration
# Save embeddings metadata
self.config["ids"] = ids
self.config["dimensions"] = dimensions

# Create embeddings index, store backend used
# Create embeddings index
self.embeddings = ANN.create(self.config)

# Build the index
Expand Down

0 comments on commit 8672775

Please sign in to comment.