* Mirror pandas' to_csv lineterminator instead of line_terminator
(even though it looks a little weird perhaps)
* Remove squeeze argument
* Revert "Merge branch 'remove-squeeze-argument' into patch-2"
This reverts commit 8b9ab5647e244d78ec3471b80ee7c42e019cf347.
* Don't remove the parameter yet since people might use it
* Add pending deprecation warning
---------
Co-authored-by: David Kyle <david.kyle@elastic.co>
* Ensure the feature logger is using NaN for non matching query feature extractors (consistent with ES).
* Default score is None instead of 0.
* LTR model import API improvements.
* Fix feature logger tests.
* Fix export in eland.ml.ltr
* Apply suggestions from code review
Co-authored-by: Adam Demjen <demjened@gmail.com>
* Fix supported models for LTR
---------
Co-authored-by: Adam Demjen <demjened@gmail.com>
* Add XGBRanker and transformer
* Map XGBoostRegressorTransformer to XGBRanker
* Add unit tests
* Remove unused import
* Revert addition of type
* Update function comment
* Distinguish objective based on model class
* Support for supplying inference_config
* Fix linting errors
* Add unit test
* Add LTR type, throw exception on predict, refine test
* Add search step to LTR test
* Fix linter errors
* Update rescoring assertion in test + type defs
* Fix linting error
* Remove failing assertion
Fixes an error uploading the sentence-transformers/all-distilroberta-v1 model
which failed with "missing 2 required positional arguments: 'token_type_ids'
and 'position_ids'". The cause was that the tokenizer type was not recognised
due to a typo
This PR adds an ability to estimate per deployment and per allocation memory usage of NLP transformer models. It uses torch.profiler and performs logs the peak memory usage during the inference.
This information is then used in Elasticsearch to provision models with sufficient memory (elastic/elasticsearch#98874).
Co-authored-by: David Olaru <dolaru@elastic.co>
* Reduce Docker image size from 4.8GB to 2.2GB
* Use torch+cpu variant if target platform is linux/amd64
Avoids downloading large & unnecessary NVIDIA deps defined in the package on PyPI
* Build linux/arm64 image using buildx and QEMU
* Recommend using pre-built Docker image
* Update README.md
Co-authored-by: István Zoltán Szabó <istvan.szabo@elastic.co>
---------
Co-authored-by: István Zoltán Szabó <istvan.szabo@elastic.co>