exasol / transformers-extension

An Exasol extension for using state-of-the-art pretrained machine learning models via the Hugging Face Transformers API.
MIT License
2 stars 2 forks source link

IndexError: tuple index out of range for model downloader #187

Open exa-eswar opened 5 months ago

exa-eswar commented 5 months ago

SELECT TRANSFORMERS.TE_MODEL_DOWNLOADER_UDF( 'd4data/bias-detection-model', 'translate', 'TRANSFORMERS_BUCKET', '' )

Code: 0, SQL State: 22002]  VM error: F-UDF-CL-LIB-1127: F-UDF-CL-SL-PYTHON-1002: F-UDF-CL-SL-PYTHON-1026: ExaUDFError: F-UDF-CL-SL-PYTHON-1114: Exception during run 
TE_MODEL_DOWNLOADER_UDF:8 run
  File "/usr/local/lib/python3.8/dist-packages/exasol_transformers_extension/udfs/models/model_downloader_udf.py", line 27, in run
    model_path = self._download_model(ctx)
  File "/usr/local/lib/python3.8/dist-packages/exasol_transformers_extension/udfs/models/model_downloader_udf.py", line 52, in _download_model
    bucketfs_location = self._bucketfs_factory.create_bucketfs_location(
  File "/usr/local/lib/python3.8/dist-packages/exasol_bucketfs_utils_python/bucketfs_factory.py", line 46, in create_bucketfs_location
    url_path.parts[2]).joinpath(*url_path.parts[3:])
IndexError: tuple index out of range
(Session: 1790709593734184960)
tkilias commented 5 months ago

The bucketfs connection currently expects a path in the bucket. This relates to the following issue: https://github.com/exasol/bucketfs-python/issues/77

tkilias commented 5 months ago

also related to https://github.com/exasol/transformers-extension/issues/188

tkilias commented 2 months ago

This bug will be obsolete as soon, we replace the BucketFSLocation with the PathLike Interface and PathBuilder in newer versions of BucketFS-Python. This should happen in Q3. Until then we mentioned this case in the documentation, see #188.