Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tf/contrastive prediction #594

Merged
merged 29 commits into from
Aug 4, 2022
Merged

Tf/contrastive prediction #594

merged 29 commits into from
Aug 4, 2022

Conversation

marcromeyn
Copy link
Contributor

@marcromeyn marcromeyn commented Jul 20, 2022

Blocked by:

Goals ⚽

Implementation Details 🚧

  • Register metrics and makes sure TopKMetricsAggregator is serializable
  • Wrap the top-k metrics provided to the model in a TopKMetricsAggregator instance to make sure top-k extraction and label relevant counts are computed once for all metrics.
  • Add a base-class ContrastivePredictionBlock .
  • Add ContrastiveDotProduct that replaces the ItemRetrievalScorer. This new implementation does not rely on the context layer and has direct access to the query embeddings.
  • Add a newDotProductCategoricalPrediction for prediction tasks including negative sampling (will replace the ItemRetrievalTask)
    ---> (Note: This new implementation does not support the TopkIndex evaluation).
    ---> The motivation is to decouple the contrastive learning task of the RetrievalModel from the evaluation of the top-k recommender.
    ---> So the supported evaluation strategy is to use negative sampling, similar to training.

Testing Details 🔍

  • Add unit test of saving/loading RetrievalModel with the new DotProductCategoricalPrediction block.
  • Add unit tests for ContrastivePredictionBlock.
  • Add a unit test for specifying the negative sampling strategy in the compile method.

@marcromeyn marcromeyn self-assigned this Jul 20, 2022
@marcromeyn marcromeyn added the enhancement New feature or request label Jul 20, 2022
@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit 17c59963df9b62d68757ccec515884942d69c785, no merge conflicts.
Running as SYSTEM
Setting status of 17c59963df9b62d68757ccec515884942d69c785 to PENDING with url https://10.20.13.93:8080/job/merlin_models/752/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse 17c59963df9b62d68757ccec515884942d69c785^{commit} # timeout=10
Checking out Revision 17c59963df9b62d68757ccec515884942d69c785 (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f 17c59963df9b62d68757ccec515884942d69c785 # timeout=10
Commit message: "Making test_dot_product_prediction pass"
 > git rev-list --no-walk d0a6ef64213431bb2552d624fe62b457c04d6868 # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins14498452105031826995.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 500 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 2%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 4%]
tests/unit/datasets/test_synthetic.py ..... [ 5%]
tests/unit/tf/test_core.py ...... [ 6%]
tests/unit/tf/test_dataset.py ................ [ 9%]
tests/unit/tf/test_public_api.py . [ 9%]
tests/unit/tf/blocks/test_cross.py ........... [ 11%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 13%]
tests/unit/tf/blocks/test_interactions.py . [ 13%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 20%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 20%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 22%]
tests/unit/tf/core/test_aggregation.py ......... [ 24%]
tests/unit/tf/core/test_base.py .. [ 25%]
tests/unit/tf/core/test_combinators.py ............... [ 28%]
tests/unit/tf/core/test_index.py ... [ 28%]
tests/unit/tf/core/test_prediction.py .. [ 29%]
tests/unit/tf/core/test_tabular.py .... [ 29%]
tests/unit/tf/core/test_transformations.py s.................... [ 34%]
tests/unit/tf/data_augmentation/test_misc.py . [ 34%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 36%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 37%]
tests/unit/tf/examples/test_01_getting_started.py . [ 37%]
tests/unit/tf/examples/test_02_dataschema.py . [ 37%]
tests/unit/tf/examples/test_03_exploring_different_models.py . [ 37%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 38%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 38%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py . [ 38%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py . [ 38%]
tests/unit/tf/inputs/test_continuous.py ..... [ 39%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 44%]
tests/unit/tf/inputs/test_tabular.py ....... [ 46%]
tests/unit/tf/layers/test_queue.py .............. [ 49%]
tests/unit/tf/losses/test_losses.py ....................... [ 53%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 54%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 58%]
tests/unit/tf/models/test_base.py ........... [ 60%]
tests/unit/tf/models/test_benchmark.py .. [ 60%]
tests/unit/tf/models/test_ranking.py ................ [ 64%]
tests/unit/tf/models/test_retrieval.py ............................... [ 70%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 70%]
tests/unit/tf/prediction_tasks/test_multi_task.py ....... [ 72%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 73%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 73%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 74%]
tests/unit/tf/predictions/test_base.py .... [ 75%]
tests/unit/tf/predictions/test_dot_product.py . [ 75%]
tests/unit/tf/utils/test_batch.py .... [ 76%]
tests/unit/tf/utils/test_tf_utils.py .. [ 76%]
tests/unit/torch/test_dataset.py ......... [ 78%]
tests/unit/torch/test_public_api.py . [ 78%]
tests/unit/torch/block/test_base.py .... [ 79%]
tests/unit/torch/block/test_mlp.py . [ 79%]
tests/unit/torch/features/test_continuous.py .. [ 80%]
tests/unit/torch/features/test_embedding.py .............. [ 83%]
tests/unit/torch/features/test_tabular.py .... [ 83%]
tests/unit/torch/model/test_head.py ............ [ 86%]
tests/unit/torch/model/test_model.py .. [ 86%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 88%]
tests/unit/torch/tabular/test_tabular.py ... [ 88%]
tests/unit/torch/tabular/test_transformations.py ....... [ 90%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................. [100%]

=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:566: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/predictions/test_dot_product.py: 5 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_fileoi54wsv5.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py: 4 warnings
tests/unit/tf/models/test_base.py: 8 warnings
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/tf/models/test_ranking.py::test_dlrm_model_multi_task[True]
tests/unit/tf/models/test_ranking.py::test_dlrm_model_multi_task[True]
tests/unit/tf/models/test_ranking.py::test_dlrm_model_multi_task[False]
tests/unit/tf/models/test_ranking.py::test_dlrm_model_multi_task[False]
tests/unit/tf/predictions/test_base.py::test_parallel_prediction_blocks[True]
tests/unit/tf/predictions/test_base.py::test_parallel_prediction_blocks[True]
tests/unit/tf/predictions/test_base.py::test_parallel_prediction_blocks[False]
tests/unit/tf/predictions/test_base.py::test_parallel_prediction_blocks[False]
/usr/local/lib/python3.8/dist-packages/numpy/core/numeric.py:2446: DeprecationWarning: elementwise comparison failed; this will raise an error in the future.
return bool(asarray(a1 == a2).all())

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:266: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
========== 492 passed, 10 skipped, 116 warnings in 1858.51s (0:30:58) ==========
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins4074493560798103697.sh

@github-actions
Copy link

Documentation preview

https://nvidia-merlin.github.io/models/review/pr-594

@viswa-nvidia viswa-nvidia added this to the Merlin 22.08 milestone Jul 20, 2022
@marcromeyn marcromeyn force-pushed the tf/contrastive-prediction branch from 17c5996 to e65d1d4 Compare July 21, 2022 12:36
@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit e65d1d4acd3b26d4fc66db7adbf67d82b5c1a169, no merge conflicts.
Running as SYSTEM
Setting status of e65d1d4acd3b26d4fc66db7adbf67d82b5c1a169 to PENDING with url https://10.20.13.93:8080/job/merlin_models/775/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse e65d1d4acd3b26d4fc66db7adbf67d82b5c1a169^{commit} # timeout=10
Checking out Revision e65d1d4acd3b26d4fc66db7adbf67d82b5c1a169 (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f e65d1d4acd3b26d4fc66db7adbf67d82b5c1a169 # timeout=10
Commit message: "Making test_dot_product_prediction pass"
 > git rev-list --no-walk 4a5f05ec055f27673e3d332ae3cc232a44db6b7e # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins3942879835829008709.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 506 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 2%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 3%]
tests/unit/datasets/test_synthetic.py ..... [ 4%]
tests/unit/tf/test_core.py ...... [ 6%]
tests/unit/tf/test_dataset.py ................ [ 9%]
tests/unit/tf/test_public_api.py . [ 9%]
tests/unit/tf/blocks/test_cross.py ........... [ 11%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 13%]
tests/unit/tf/blocks/test_interactions.py . [ 13%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 19%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 20%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 22%]
tests/unit/tf/core/test_aggregation.py ......... [ 24%]
tests/unit/tf/core/test_base.py .. [ 24%]
tests/unit/tf/core/test_combinators.py ............... [ 27%]
tests/unit/tf/core/test_index.py ... [ 28%]
tests/unit/tf/core/test_prediction.py .. [ 28%]
tests/unit/tf/core/test_tabular.py .... [ 29%]
tests/unit/tf/core/test_transformations.py s.................... [ 33%]
tests/unit/tf/data_augmentation/test_misc.py . [ 33%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 35%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 36%]
tests/unit/tf/examples/test_01_getting_started.py F [ 36%]
tests/unit/tf/examples/test_02_dataschema.py F [ 37%]
tests/unit/tf/examples/test_03_exploring_different_models.py F [ 37%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 37%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 37%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py F [ 37%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py F [ 38%]
tests/unit/tf/inputs/test_continuous.py ..... [ 39%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 44%]
tests/unit/tf/inputs/test_tabular.py ........... [ 46%]
tests/unit/tf/layers/test_queue.py .............. [ 49%]
tests/unit/tf/losses/test_losses.py ....................... [ 53%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 54%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 58%]
tests/unit/tf/models/test_base.py ........... [ 60%]
tests/unit/tf/models/test_benchmark.py .. [ 60%]
tests/unit/tf/models/test_ranking.py .............. [ 63%]
tests/unit/tf/models/test_retrieval.py ............................... [ 69%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 70%]
tests/unit/tf/prediction_tasks/test_multi_task.py ....... [ 71%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 72%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 72%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 74%]
tests/unit/tf/predictions/test_base.py .... [ 74%]
tests/unit/tf/predictions/test_classification.py FF [ 75%]
tests/unit/tf/predictions/test_dot_product.py . [ 75%]
tests/unit/tf/predictions/test_regression.py FF [ 75%]
tests/unit/tf/utils/test_batch.py .... [ 76%]
tests/unit/tf/utils/test_tf_utils.py .. [ 77%]
tests/unit/torch/test_dataset.py ......... [ 78%]
tests/unit/torch/test_public_api.py . [ 79%]
tests/unit/torch/block/test_base.py .... [ 79%]
tests/unit/torch/block/test_mlp.py . [ 80%]
tests/unit/torch/features/test_continuous.py .. [ 80%]
tests/unit/torch/features/test_embedding.py .............. [ 83%]
tests/unit/torch/features/test_tabular.py .... [ 83%]
tests/unit/torch/model/test_head.py ............ [ 86%]
tests/unit/torch/model/test_model.py .. [ 86%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 88%]
tests/unit/torch/tabular/test_tabular.py ... [ 88%]
tests/unit/torch/tabular/test_transformations.py ....... [ 90%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................. [100%]

=================================== FAILURES ===================================
_______________________ test_example_01_getting_started ________________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fdf40182370>

@testbook(REPO_ROOT / "examples/01-Getting-started.ipynb", execute=False)
def test_example_01_getting_started(tb):
    tb.inject(
        """
        from unittest.mock import patch
        from merlin.datasets.synthetic import generate_data
        mock_train, mock_valid = generate_data(
            input="movielens-1m",
            num_rows=1000,
            set_sizes=(0.8, 0.2)
        )
        p1 = patch(
            "merlin.datasets.entertainment.get_movielens",
            return_value=[mock_train, mock_valid]
        )
        p1.start()
        """
    )
    tb.execute()
    metrics = tb.ref("metrics")
  assert set(metrics.keys()) == set(
        [
            "auc",
            "binary_accuracy",
            "loss",
            "regularization_loss",
            "precision",
            "recall",
        ]
    )

E AssertionError: assert {'auc_1', 'bi...ization_loss'} == {'auc', 'bina...ization_loss'}
E Extra items in the left set:
E 'recall_1'
E 'auc_1'
E 'precision_1'
E Extra items in the right set:
E 'recall'
E 'auc'
E 'precision'
E Full diff:
E {
E - 'auc',
E + 'auc_1',
E ? ++
E 'binary_accuracy',
E 'loss',
E - 'precision',
E + 'precision_1',
E ? ++
E - 'recall',
E + 'recall_1',
E ? ++
E 'regularization_loss',
E }

tests/unit/tf/examples/test_01_getting_started.py:42: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-21 12:57:10.217272: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-21 12:57:11.556395: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-21 12:57:11.556557: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-21 12:57:11.557318: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-21 12:57:11.557376: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
_______________________ test_example_02_nvt_integration ________________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fdf3057eee0>

@testbook(REPO_ROOT / "examples/02-Merlin-Models-and-NVTabular-integration.ipynb", execute=False)
def test_example_02_nvt_integration(tb):
    tb.inject(
        """
        import os
        os.environ["INPUT_DATA_DIR"] = "/tmp/data/"
        from unittest.mock import patch
        from merlin.datasets.synthetic import generate_data
        mock_train, mock_valid = generate_data(
            input="movielens-1m",
            num_rows=1000,
            set_sizes=(0.8, 0.2)
        )
        p1 = patch(
            "merlin.datasets.entertainment.get_movielens",
            return_value=[mock_train, mock_valid]
        )
        p1.start()
        p2 = patch(
            "merlin.core.utils.download_file",
            return_value=[]
        )
        p2.start()
        import numpy as np
        import pandas
        from pathlib import Path
        from merlin.datasets.synthetic import generate_data
        mock_data = generate_data(
            input="movielens-1m-raw-ratings",
            num_rows=1000
        )
        mock_data = mock_data.to_ddf().compute()
        if not isinstance(mock_data, pandas.core.frame.DataFrame):
            mock_data = mock_data.to_pandas()
        input_path = os.environ.get(
            "INPUT_DATA_DIR",
            os.path.expanduser("~/merlin-models-data/movielens/")
        )
        path = Path(input_path + "ml-1m/")
        path.mkdir(parents=True, exist_ok=True)
        np.savetxt(
            input_path + 'ml-1m/ratings.dat',
            mock_data.values,
            delimiter='::',
            fmt='%s',
            encoding='utf-8'
        )
        """
    )
    tb.execute()
    assert tb.cell_output_text(15)[-19:] == "'TE_userId_rating']"
    metrics = tb.ref("metrics")
  assert set(metrics.keys()) == set(
        [
            "auc",
            "binary_accuracy",
            "loss",
            "regularization_loss",
            "precision",
            "recall",
        ]
    )

E AssertionError: assert {'auc_1', 'bi...ization_loss'} == {'auc', 'bina...ization_loss'}
E Extra items in the left set:
E 'recall_1'
E 'auc_1'
E 'precision_1'
E Extra items in the right set:
E 'recall'
E 'auc'
E 'precision'
E Full diff:
E {
E - 'auc',
E + 'auc_1',
E ? ++
E 'binary_accuracy',
E 'loss',
E - 'precision',
E + 'precision_1',
E ? ++
E - 'recall',
E + 'recall_1',
E ? ++
E 'regularization_loss',
E }

tests/unit/tf/examples/test_02_dataschema.py:58: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-21 12:57:26.119180: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-21 12:57:27.494748: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-21 12:57:27.494907: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-21 12:57:27.496178: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-21 12:57:27.496321: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
__________________ test_example_03_exploring_different_models __________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fdf0fed3fa0>

@testbook(REPO_ROOT / "examples/03-Exploring-different-models.ipynb", execute=False)
def test_example_03_exploring_different_models(tb):
    tb.inject(
        """
        import os
        os.environ["DATA_FOLDER"] = "/tmp/data/"
        os.environ["NUM_ROWS"] = "999"
        """
    )
    NUM_OF_CELLS = len(tb.cells)
    tb.execute_cell(list(range(0, NUM_OF_CELLS - 5)))
    metrics_ncf = tb.ref("metrics_ncf")
  assert set(metrics_ncf.keys()) == set(
        [
            "auc",
            "loss",
            "regularization_loss",
        ]
    )

E AssertionError: assert {'auc_1', 'lo...ization_loss'} == {'auc', 'loss...ization_loss'}
E Extra items in the left set:
E 'auc_1'
E Extra items in the right set:
E 'auc'
E Full diff:
E - {'regularization_loss', 'auc', 'loss'}
E + {'regularization_loss', 'auc_1', 'loss'}
E ? ++

tests/unit/tf/examples/test_03_exploring_different_models.py:20: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-21 12:57:39.089726: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-21 12:57:41.065162: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-21 12:57:41.065328: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-21 12:57:41.066130: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-21 12:57:41.066187: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
__________________ test_example_06_defining_own_architecture ___________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fdf0febadf0>

@testbook(
    REPO_ROOT / "examples/06-Define-your-own-architecture-with-Merlin-Models.ipynb", execute=False
)
def test_example_06_defining_own_architecture(tb):
    tb.inject(
        """
        from unittest.mock import patch
        from merlin.datasets.synthetic import generate_data
        mock_train, mock_valid = generate_data(
            input="movielens-1m",
            num_rows=1000,
            set_sizes=(0.8, 0.2)
        )
        p1 = patch(
            "merlin.datasets.entertainment.get_movielens",
            return_value=[mock_train, mock_valid]
        )
        p1.start()
        """
    )
    tb.execute()
    metrics = tb.ref("metrics")
  assert set(metrics.keys()) == set(["auc", "loss", "regularization_loss"])

E AssertionError: assert {'auc_1', 'lo...ization_loss'} == {'auc', 'loss...ization_loss'}
E Extra items in the left set:
E 'auc_1'
E Extra items in the right set:
E 'auc'
E Full diff:
E - {'regularization_loss', 'auc', 'loss'}
E + {'regularization_loss', 'auc_1', 'loss'}
E ? ++

tests/unit/tf/examples/test_06_advanced_own_architecture.py:30: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-21 12:59:03.221281: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-21 12:59:04.576265: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-21 12:59:04.576421: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-21 12:59:04.577299: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-21 12:59:04.577357: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
______________________ test_usecase_pretrained_embeddings ______________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fdf30563be0>

@testbook(
    REPO_ROOT / "examples/usecases/entertainment-with-pretrained-embeddings.ipynb", execute=False
)
def test_usecase_pretrained_embeddings(tb):
    tb.execute()
    model = tb.ref("model")
  assert set(model.history.history.keys()) == set(["auc", "loss", "regularization_loss"])

E AssertionError: assert {'auc_1', 'lo...ization_loss'} == {'auc', 'loss...ization_loss'}
E Extra items in the left set:
E 'auc_1'
E Extra items in the right set:
E 'auc'
E Full diff:
E - {'regularization_loss', 'auc', 'loss'}
E + {'regularization_loss', 'auc_1', 'loss'}
E ? ++

tests/unit/tf/examples/test_usecase_pretrained_embeddings.py:12: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-21 12:59:24.671281: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-21 12:59:26.683769: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-21 12:59:26.683921: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-21 12:59:26.684752: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-21 12:59:26.684818: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
______________________ test_binary_prediction_block[True] ______________________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fe0e231ca30>
run_eagerly = True

@pytest.mark.parametrize("run_eagerly", [True, False])
def test_binary_prediction_block(ecommerce_data: Dataset, run_eagerly):
    model = mm.Model(
        mm.InputBlock(ecommerce_data.schema),
        mm.MLPBlock([8]),
        mm.BinaryPrediction("click"),
    )
  _, history = testing_utils.model_test(model, ecommerce_data, run_eagerly=run_eagerly)

tests/unit/tf/predictions/test_classification.py:31:


merlin/models/tf/utils/testing_utils.py:110: in model_test
assert isinstance(model.from_config(model.get_config()), type(model))
merlin/models/tf/models/base.py:908: in from_config
layers = [
merlin/models/tf/models/base.py:909: in
tf.keras.layers.deserialize(conf, custom_objects=custom_objects)
/usr/local/lib/python3.8/dist-packages/keras/layers/serialization.py:205: in deserialize
return generic_utils.deserialize_keras_object(
/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:664: in deserialize_keras_object
(cls, cls_config) = class_and_config_for_serialized_keras_object(


config = {'class_name': 'BinaryPrediction', 'config': {'default_loss': 'binary_crossentropy', 'default_metrics': List(
(0): D...lti_label): False
(label_weights): None
)
)
), 'dtype': 'float32', 'name': 'click/binary_prediction', ...}}
module_objects = {'AbstractRNNCell': <class 'keras.layers.rnn.abstract_rnn_cell.AbstractRNNCell'>, 'Activation': <class 'keras.layers.c...rs.regularization.activity_regularization.ActivityRegularization'>, 'Add': <class 'keras.layers.merging.add.Add'>, ...}
custom_objects = None, printable_module_name = 'layer'

def class_and_config_for_serialized_keras_object(
    config,
    module_objects=None,
    custom_objects=None,
    printable_module_name='object'):
  """Returns the class name and config for a serialized keras object."""
  if (not isinstance(config, dict)
      or 'class_name' not in config
      or 'config' not in config):
    raise ValueError(
        f'Improper config format for {config}. '
        'Expecting python dict contains `class_name` and `config` as keys')

  class_name = config['class_name']
  cls = get_registered_object(class_name, custom_objects, module_objects)
  if cls is None:
  raise ValueError(
        f'Unknown {printable_module_name}: {class_name}. Please ensure this '
        'object is passed to the `custom_objects` argument. See '
        'https://www.tensorflow.org/guide/keras/save_and_serialize'
        '#registering_the_custom_object for details.')

E ValueError: Unknown layer: BinaryPrediction. Please ensure this object is passed to the custom_objects argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details.

/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:562: ValueError
----------------------------- Captured stdout call -----------------------------

1/1 [==============================] - ETA: 0s - loss: 0.6866 - click/binary_prediction/precision: 0.6429 - click/binary_prediction/recall: 0.8438 - click/binary_prediction/binary_accuracy: 0.6000 - click/binary_prediction/auc: 0.6484 - regularization_loss: 0.0000e+00����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������
1/1 [==============================] - 1s 606ms/step - loss: 0.6866 - click/binary_prediction/precision: 0.6429 - click/binary_prediction/recall: 0.8438 - click/binary_prediction/binary_accuracy: 0.6000 - click/binary_prediction/auc: 0.6484 - regularization_loss: 0.0000e+00
_____________________ test_binary_prediction_block[False] ______________________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fe0e1dce430>
run_eagerly = False

@pytest.mark.parametrize("run_eagerly", [True, False])
def test_binary_prediction_block(ecommerce_data: Dataset, run_eagerly):
    model = mm.Model(
        mm.InputBlock(ecommerce_data.schema),
        mm.MLPBlock([8]),
        mm.BinaryPrediction("click"),
    )
  _, history = testing_utils.model_test(model, ecommerce_data, run_eagerly=run_eagerly)

tests/unit/tf/predictions/test_classification.py:31:


merlin/models/tf/utils/testing_utils.py:110: in model_test
assert isinstance(model.from_config(model.get_config()), type(model))
merlin/models/tf/models/base.py:908: in from_config
layers = [
merlin/models/tf/models/base.py:909: in
tf.keras.layers.deserialize(conf, custom_objects=custom_objects)
/usr/local/lib/python3.8/dist-packages/keras/layers/serialization.py:205: in deserialize
return generic_utils.deserialize_keras_object(
/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:664: in deserialize_keras_object
(cls, cls_config) = class_and_config_for_serialized_keras_object(


config = {'class_name': 'BinaryPrediction', 'config': {'default_loss': 'binary_crossentropy', 'default_metrics': List(
(0): D...lti_label): False
(label_weights): None
)
)
), 'dtype': 'float32', 'name': 'click/binary_prediction', ...}}
module_objects = {'AbstractRNNCell': <class 'keras.layers.rnn.abstract_rnn_cell.AbstractRNNCell'>, 'Activation': <class 'keras.layers.c...rs.regularization.activity_regularization.ActivityRegularization'>, 'Add': <class 'keras.layers.merging.add.Add'>, ...}
custom_objects = None, printable_module_name = 'layer'

def class_and_config_for_serialized_keras_object(
    config,
    module_objects=None,
    custom_objects=None,
    printable_module_name='object'):
  """Returns the class name and config for a serialized keras object."""
  if (not isinstance(config, dict)
      or 'class_name' not in config
      or 'config' not in config):
    raise ValueError(
        f'Improper config format for {config}. '
        'Expecting python dict contains `class_name` and `config` as keys')

  class_name = config['class_name']
  cls = get_registered_object(class_name, custom_objects, module_objects)
  if cls is None:
  raise ValueError(
        f'Unknown {printable_module_name}: {class_name}. Please ensure this '
        'object is passed to the `custom_objects` argument. See '
        'https://www.tensorflow.org/guide/keras/save_and_serialize'
        '#registering_the_custom_object for details.')

E ValueError: Unknown layer: BinaryPrediction. Please ensure this object is passed to the custom_objects argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details.

/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:562: ValueError
----------------------------- Captured stdout call -----------------------------

1/1 [==============================] - ETA: 0s - loss: 0.6890 - click/binary_prediction/precision: 0.6500 - click/binary_prediction/recall: 0.8667 - click/binary_prediction/binary_accuracy: 0.6400 - click/binary_prediction/auc: 0.5658 - regularization_loss: 0.0000e+00����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������
1/1 [==============================] - 3s 3s/step - loss: 0.6890 - click/binary_prediction/precision: 0.6500 - click/binary_prediction/recall: 0.8667 - click/binary_prediction/binary_accuracy: 0.6400 - click/binary_prediction/auc: 0.5658 - regularization_loss: 0.0000e+00
______________________ test_binary_prediction_block[True] ______________________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fe179a97760>
run_eagerly = True

@pytest.mark.parametrize("run_eagerly", [True, False])
def test_binary_prediction_block(ecommerce_data: Dataset, run_eagerly):
    model = mm.Model(
        mm.InputBlock(ecommerce_data.schema),
        mm.MLPBlock([8]),
        mm.RegressionPrediction("click"),
    )
  _, history = testing_utils.model_test(model, ecommerce_data, run_eagerly=run_eagerly)

tests/unit/tf/predictions/test_regression.py:31:


merlin/models/tf/utils/testing_utils.py:110: in model_test
assert isinstance(model.from_config(model.get_config()), type(model))
merlin/models/tf/models/base.py:908: in from_config
layers = [
merlin/models/tf/models/base.py:909: in
tf.keras.layers.deserialize(conf, custom_objects=custom_objects)
/usr/local/lib/python3.8/dist-packages/keras/layers/serialization.py:205: in deserialize
return generic_utils.deserialize_keras_object(
/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:664: in deserialize_keras_object
(cls, cls_config) = class_and_config_for_serialized_keras_object(


config = {'class_name': 'RegressionPrediction', 'config': {'default_loss': 'mse', 'default_metrics': List(
(0): Dict(
(cl...n_squared_error'
(dtype): 'float32'
)
)
), 'dtype': 'float32', 'name': 'click/regression_prediction', ...}}
module_objects = {'AbstractRNNCell': <class 'keras.layers.rnn.abstract_rnn_cell.AbstractRNNCell'>, 'Activation': <class 'keras.layers.c...rs.regularization.activity_regularization.ActivityRegularization'>, 'Add': <class 'keras.layers.merging.add.Add'>, ...}
custom_objects = None, printable_module_name = 'layer'

def class_and_config_for_serialized_keras_object(
    config,
    module_objects=None,
    custom_objects=None,
    printable_module_name='object'):
  """Returns the class name and config for a serialized keras object."""
  if (not isinstance(config, dict)
      or 'class_name' not in config
      or 'config' not in config):
    raise ValueError(
        f'Improper config format for {config}. '
        'Expecting python dict contains `class_name` and `config` as keys')

  class_name = config['class_name']
  cls = get_registered_object(class_name, custom_objects, module_objects)
  if cls is None:
  raise ValueError(
        f'Unknown {printable_module_name}: {class_name}. Please ensure this '
        'object is passed to the `custom_objects` argument. See '
        'https://www.tensorflow.org/guide/keras/save_and_serialize'
        '#registering_the_custom_object for details.')

E ValueError: Unknown layer: RegressionPrediction. Please ensure this object is passed to the custom_objects argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details.

/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:562: ValueError
----------------------------- Captured stdout call -----------------------------

1/1 [==============================] - ETA: 0s - loss: 0.6301 - click/regression_prediction/root_mean_squared_error: 0.7938 - regularization_loss: 0.0000e+00�������������������������������������������������������������������������������������������������������������������������������������������������������������
1/1 [==============================] - 0s 259ms/step - loss: 0.6301 - click/regression_prediction/root_mean_squared_error: 0.7938 - regularization_loss: 0.0000e+00
_____________________ test_binary_prediction_block[False] ______________________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fe0d83bdfa0>
run_eagerly = False

@pytest.mark.parametrize("run_eagerly", [True, False])
def test_binary_prediction_block(ecommerce_data: Dataset, run_eagerly):
    model = mm.Model(
        mm.InputBlock(ecommerce_data.schema),
        mm.MLPBlock([8]),
        mm.RegressionPrediction("click"),
    )
  _, history = testing_utils.model_test(model, ecommerce_data, run_eagerly=run_eagerly)

tests/unit/tf/predictions/test_regression.py:31:


merlin/models/tf/utils/testing_utils.py:110: in model_test
assert isinstance(model.from_config(model.get_config()), type(model))
merlin/models/tf/models/base.py:908: in from_config
layers = [
merlin/models/tf/models/base.py:909: in
tf.keras.layers.deserialize(conf, custom_objects=custom_objects)
/usr/local/lib/python3.8/dist-packages/keras/layers/serialization.py:205: in deserialize
return generic_utils.deserialize_keras_object(
/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:664: in deserialize_keras_object
(cls, cls_config) = class_and_config_for_serialized_keras_object(


config = {'class_name': 'RegressionPrediction', 'config': {'default_loss': 'mse', 'default_metrics': List(
(0): Dict(
(cl...n_squared_error'
(dtype): 'float32'
)
)
), 'dtype': 'float32', 'name': 'click/regression_prediction', ...}}
module_objects = {'AbstractRNNCell': <class 'keras.layers.rnn.abstract_rnn_cell.AbstractRNNCell'>, 'Activation': <class 'keras.layers.c...rs.regularization.activity_regularization.ActivityRegularization'>, 'Add': <class 'keras.layers.merging.add.Add'>, ...}
custom_objects = None, printable_module_name = 'layer'

def class_and_config_for_serialized_keras_object(
    config,
    module_objects=None,
    custom_objects=None,
    printable_module_name='object'):
  """Returns the class name and config for a serialized keras object."""
  if (not isinstance(config, dict)
      or 'class_name' not in config
      or 'config' not in config):
    raise ValueError(
        f'Improper config format for {config}. '
        'Expecting python dict contains `class_name` and `config` as keys')

  class_name = config['class_name']
  cls = get_registered_object(class_name, custom_objects, module_objects)
  if cls is None:
  raise ValueError(
        f'Unknown {printable_module_name}: {class_name}. Please ensure this '
        'object is passed to the `custom_objects` argument. See '
        'https://www.tensorflow.org/guide/keras/save_and_serialize'
        '#registering_the_custom_object for details.')

E ValueError: Unknown layer: RegressionPrediction. Please ensure this object is passed to the custom_objects argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details.

/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:562: ValueError
----------------------------- Captured stdout call -----------------------------

1/1 [==============================] - ETA: 0s - loss: 0.5994 - click/regression_prediction/root_mean_squared_error: 0.7742 - regularization_loss: 0.0000e+00�������������������������������������������������������������������������������������������������������������������������������������������������������������
1/1 [==============================] - 3s 3s/step - loss: 0.5994 - click/regression_prediction/root_mean_squared_error: 0.7742 - regularization_loss: 0.0000e+00
=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:752: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_files8b7059p.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.1]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.3]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.5]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.7]
tests/unit/tf/models/test_base.py::test_model_pre_post[True]
tests/unit/tf/models/test_base.py::test_model_pre_post[False]
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:266: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
====== 9 failed, 489 passed, 10 skipped, 97 warnings in 700.39s (0:11:40) ======
Build step 'Execute shell' marked build as failure
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins1002104713105901232.sh

@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit 475008f4bd89f5122f9e107d6ccdb8a3d79439f3, no merge conflicts.
Running as SYSTEM
Setting status of 475008f4bd89f5122f9e107d6ccdb8a3d79439f3 to PENDING with url https://10.20.13.93:8080/job/merlin_models/777/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse 475008f4bd89f5122f9e107d6ccdb8a3d79439f3^{commit} # timeout=10
Checking out Revision 475008f4bd89f5122f9e107d6ccdb8a3d79439f3 (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f 475008f4bd89f5122f9e107d6ccdb8a3d79439f3 # timeout=10
Commit message: "Adding TODO"
 > git rev-list --no-walk 23ba7d295f4f6a03704188a83cde21a285208a69 # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins7586695647337365818.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 506 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 2%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 3%]
tests/unit/datasets/test_synthetic.py ..... [ 4%]
tests/unit/tf/test_core.py ...... [ 6%]
tests/unit/tf/test_dataset.py ................ [ 9%]
tests/unit/tf/test_public_api.py . [ 9%]
tests/unit/tf/blocks/test_cross.py ........... [ 11%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 13%]
tests/unit/tf/blocks/test_interactions.py . [ 13%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 19%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 20%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 22%]
tests/unit/tf/core/test_aggregation.py ......... [ 24%]
tests/unit/tf/core/test_base.py .. [ 24%]
tests/unit/tf/core/test_combinators.py ............... [ 27%]
tests/unit/tf/core/test_index.py ... [ 28%]
tests/unit/tf/core/test_prediction.py .. [ 28%]
tests/unit/tf/core/test_tabular.py .... [ 29%]
tests/unit/tf/core/test_transformations.py s.................... [ 33%]
tests/unit/tf/data_augmentation/test_misc.py . [ 33%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 35%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 36%]
tests/unit/tf/examples/test_01_getting_started.py F [ 36%]
tests/unit/tf/examples/test_02_dataschema.py F [ 37%]
tests/unit/tf/examples/test_03_exploring_different_models.py F [ 37%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 37%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 37%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py F [ 37%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py F [ 38%]
tests/unit/tf/inputs/test_continuous.py ..... [ 39%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 44%]
tests/unit/tf/inputs/test_tabular.py ........... [ 46%]
tests/unit/tf/layers/test_queue.py .............. [ 49%]
tests/unit/tf/losses/test_losses.py ....................... [ 53%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 54%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 58%]
tests/unit/tf/models/test_base.py ........... [ 60%]
tests/unit/tf/models/test_benchmark.py .. [ 60%]
tests/unit/tf/models/test_ranking.py .............. [ 63%]
tests/unit/tf/models/test_retrieval.py ............................... [ 69%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 70%]
tests/unit/tf/prediction_tasks/test_multi_task.py ....... [ 71%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 72%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 72%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 74%]
tests/unit/tf/predictions/test_base.py .... [ 74%]
tests/unit/tf/predictions/test_classification.py FF [ 75%]
tests/unit/tf/predictions/test_dot_product.py . [ 75%]
tests/unit/tf/predictions/test_regression.py FF [ 75%]
tests/unit/tf/utils/test_batch.py .... [ 76%]
tests/unit/tf/utils/test_tf_utils.py .. [ 77%]
tests/unit/torch/test_dataset.py ......... [ 78%]
tests/unit/torch/test_public_api.py . [ 79%]
tests/unit/torch/block/test_base.py .... [ 79%]
tests/unit/torch/block/test_mlp.py . [ 80%]
tests/unit/torch/features/test_continuous.py .. [ 80%]
tests/unit/torch/features/test_embedding.py .............. [ 83%]
tests/unit/torch/features/test_tabular.py .... [ 83%]
tests/unit/torch/model/test_head.py ............ [ 86%]
tests/unit/torch/model/test_model.py .. [ 86%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 88%]
tests/unit/torch/tabular/test_tabular.py ... [ 88%]
tests/unit/torch/tabular/test_transformations.py ....... [ 90%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................. [100%]

=================================== FAILURES ===================================
_______________________ test_example_01_getting_started ________________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fb1802ccd00>

@testbook(REPO_ROOT / "examples/01-Getting-started.ipynb", execute=False)
def test_example_01_getting_started(tb):
    tb.inject(
        """
        from unittest.mock import patch
        from merlin.datasets.synthetic import generate_data
        mock_train, mock_valid = generate_data(
            input="movielens-1m",
            num_rows=1000,
            set_sizes=(0.8, 0.2)
        )
        p1 = patch(
            "merlin.datasets.entertainment.get_movielens",
            return_value=[mock_train, mock_valid]
        )
        p1.start()
        """
    )
    tb.execute()
    metrics = tb.ref("metrics")
  assert set(metrics.keys()) == set(
        [
            "auc",
            "binary_accuracy",
            "loss",
            "regularization_loss",
            "precision",
            "recall",
        ]
    )

E AssertionError: assert {'auc_1', 'bi...ization_loss'} == {'auc', 'bina...ization_loss'}
E Extra items in the left set:
E 'recall_1'
E 'precision_1'
E 'auc_1'
E Extra items in the right set:
E 'auc'
E 'precision'
E 'recall'
E Full diff:
E {
E - 'auc',
E + 'auc_1',
E ? ++
E 'binary_accuracy',
E 'loss',
E - 'precision',
E + 'precision_1',
E ? ++
E - 'recall',
E + 'recall_1',
E ? ++
E 'regularization_loss',
E }

tests/unit/tf/examples/test_01_getting_started.py:42: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-22 08:47:47.999734: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-22 08:47:49.336117: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-22 08:47:49.336277: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-22 08:47:49.337027: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-22 08:47:49.337084: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
_______________________ test_example_02_nvt_integration ________________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fb15d705d30>

@testbook(REPO_ROOT / "examples/02-Merlin-Models-and-NVTabular-integration.ipynb", execute=False)
def test_example_02_nvt_integration(tb):
    tb.inject(
        """
        import os
        os.environ["INPUT_DATA_DIR"] = "/tmp/data/"
        from unittest.mock import patch
        from merlin.datasets.synthetic import generate_data
        mock_train, mock_valid = generate_data(
            input="movielens-1m",
            num_rows=1000,
            set_sizes=(0.8, 0.2)
        )
        p1 = patch(
            "merlin.datasets.entertainment.get_movielens",
            return_value=[mock_train, mock_valid]
        )
        p1.start()
        p2 = patch(
            "merlin.core.utils.download_file",
            return_value=[]
        )
        p2.start()
        import numpy as np
        import pandas
        from pathlib import Path
        from merlin.datasets.synthetic import generate_data
        mock_data = generate_data(
            input="movielens-1m-raw-ratings",
            num_rows=1000
        )
        mock_data = mock_data.to_ddf().compute()
        if not isinstance(mock_data, pandas.core.frame.DataFrame):
            mock_data = mock_data.to_pandas()
        input_path = os.environ.get(
            "INPUT_DATA_DIR",
            os.path.expanduser("~/merlin-models-data/movielens/")
        )
        path = Path(input_path + "ml-1m/")
        path.mkdir(parents=True, exist_ok=True)
        np.savetxt(
            input_path + 'ml-1m/ratings.dat',
            mock_data.values,
            delimiter='::',
            fmt='%s',
            encoding='utf-8'
        )
        """
    )
    tb.execute()
    assert tb.cell_output_text(15)[-19:] == "'TE_userId_rating']"
    metrics = tb.ref("metrics")
  assert set(metrics.keys()) == set(
        [
            "auc",
            "binary_accuracy",
            "loss",
            "regularization_loss",
            "precision",
            "recall",
        ]
    )

E AssertionError: assert {'auc_1', 'bi...ization_loss'} == {'auc', 'bina...ization_loss'}
E Extra items in the left set:
E 'recall_1'
E 'precision_1'
E 'auc_1'
E Extra items in the right set:
E 'auc'
E 'precision'
E 'recall'
E Full diff:
E {
E - 'auc',
E + 'auc_1',
E ? ++
E 'binary_accuracy',
E 'loss',
E - 'precision',
E + 'precision_1',
E ? ++
E - 'recall',
E + 'recall_1',
E ? ++
E 'regularization_loss',
E }

tests/unit/tf/examples/test_02_dataschema.py:58: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-22 08:48:03.752688: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-22 08:48:05.108258: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-22 08:48:05.108416: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-22 08:48:05.109252: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-22 08:48:05.109307: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
__________________ test_example_03_exploring_different_models __________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fb15d06fe80>

@testbook(REPO_ROOT / "examples/03-Exploring-different-models.ipynb", execute=False)
def test_example_03_exploring_different_models(tb):
    tb.inject(
        """
        import os
        os.environ["DATA_FOLDER"] = "/tmp/data/"
        os.environ["NUM_ROWS"] = "999"
        """
    )
    NUM_OF_CELLS = len(tb.cells)
    tb.execute_cell(list(range(0, NUM_OF_CELLS - 5)))
    metrics_ncf = tb.ref("metrics_ncf")
  assert set(metrics_ncf.keys()) == set(
        [
            "auc",
            "loss",
            "regularization_loss",
        ]
    )

E AssertionError: assert {'auc_1', 'lo...ization_loss'} == {'auc', 'loss...ization_loss'}
E Extra items in the left set:
E 'auc_1'
E Extra items in the right set:
E 'auc'
E Full diff:
E - {'loss', 'regularization_loss', 'auc'}
E ? -------
E + {'loss', 'auc_1', 'regularization_loss'}
E ? +++++++++

tests/unit/tf/examples/test_03_exploring_different_models.py:20: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-22 08:48:16.542061: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-22 08:48:18.531692: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-22 08:48:18.531854: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-22 08:48:18.532656: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-22 08:48:18.532711: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
__________________ test_example_06_defining_own_architecture ___________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fb15d09dca0>

@testbook(
    REPO_ROOT / "examples/06-Define-your-own-architecture-with-Merlin-Models.ipynb", execute=False
)
def test_example_06_defining_own_architecture(tb):
    tb.inject(
        """
        from unittest.mock import patch
        from merlin.datasets.synthetic import generate_data
        mock_train, mock_valid = generate_data(
            input="movielens-1m",
            num_rows=1000,
            set_sizes=(0.8, 0.2)
        )
        p1 = patch(
            "merlin.datasets.entertainment.get_movielens",
            return_value=[mock_train, mock_valid]
        )
        p1.start()
        """
    )
    tb.execute()
    metrics = tb.ref("metrics")
  assert set(metrics.keys()) == set(["auc", "loss", "regularization_loss"])

E AssertionError: assert {'auc_1', 'lo...ization_loss'} == {'auc', 'loss...ization_loss'}
E Extra items in the left set:
E 'auc_1'
E Extra items in the right set:
E 'auc'
E Full diff:
E - {'loss', 'regularization_loss', 'auc'}
E ? -------
E + {'loss', 'auc_1', 'regularization_loss'}
E ? +++++++++

tests/unit/tf/examples/test_06_advanced_own_architecture.py:30: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-22 08:49:40.353406: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-22 08:49:41.719575: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-22 08:49:41.719734: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-22 08:49:41.720534: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-22 08:49:41.720586: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
______________________ test_usecase_pretrained_embeddings ______________________

tb = <testbook.client.TestbookNotebookClient object at 0x7fb15d532a90>

@testbook(
    REPO_ROOT / "examples/usecases/entertainment-with-pretrained-embeddings.ipynb", execute=False
)
def test_usecase_pretrained_embeddings(tb):
    tb.execute()
    model = tb.ref("model")
  assert set(model.history.history.keys()) == set(["auc", "loss", "regularization_loss"])

E AssertionError: assert {'auc_1', 'lo...ization_loss'} == {'auc', 'loss...ization_loss'}
E Extra items in the left set:
E 'auc_1'
E Extra items in the right set:
E 'auc'
E Full diff:
E - {'loss', 'regularization_loss', 'auc'}
E ? -------
E + {'loss', 'auc_1', 'regularization_loss'}
E ? +++++++++

tests/unit/tf/examples/test_usecase_pretrained_embeddings.py:12: AssertionError
----------------------------- Captured stderr call -----------------------------
2022-07-22 08:50:01.913765: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2022-07-22 08:50:03.923433: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 0
2022-07-22 08:50:03.923581: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 1627 MB memory: -> device: 0, name: Tesla P100-DGXS-16GB, pci bus id: 0000:07:00.0, compute capability: 6.0
2022-07-22 08:50:03.924378: I tensorflow/core/common_runtime/gpu/gpu_process_state.cc:222] Using CUDA malloc Async allocator for GPU: 1
2022-07-22 08:50:03.924432: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1532] Created device /job:localhost/replica:0/task:0/device:GPU:1 with 14532 MB memory: -> device: 1, name: Tesla P100-DGXS-16GB, pci bus id: 0000:08:00.0, compute capability: 6.0
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.8/logging/init.py", line 2127, in shutdown
h.close()
File "/usr/local/lib/python3.8/dist-packages/absl/logging/init.py", line 934, in close
self.stream.close()
File "/usr/local/lib/python3.8/dist-packages/ipykernel/iostream.py", line 438, in close
self.watch_fd_thread.join()
AttributeError: 'OutStream' object has no attribute 'watch_fd_thread'
______________________ test_binary_prediction_block[True] ______________________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fb139974c70>
run_eagerly = True

@pytest.mark.parametrize("run_eagerly", [True, False])
def test_binary_prediction_block(ecommerce_data: Dataset, run_eagerly):
    model = mm.Model(
        mm.InputBlock(ecommerce_data.schema),
        mm.MLPBlock([8]),
        mm.BinaryPrediction("click"),
    )
  _, history = testing_utils.model_test(model, ecommerce_data, run_eagerly=run_eagerly)

tests/unit/tf/predictions/test_classification.py:31:


merlin/models/tf/utils/testing_utils.py:110: in model_test
assert isinstance(model.from_config(model.get_config()), type(model))
merlin/models/tf/models/base.py:910: in from_config
layers = [
merlin/models/tf/models/base.py:911: in
tf.keras.layers.deserialize(conf, custom_objects=custom_objects)
/usr/local/lib/python3.8/dist-packages/keras/layers/serialization.py:205: in deserialize
return generic_utils.deserialize_keras_object(
/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:664: in deserialize_keras_object
(cls, cls_config) = class_and_config_for_serialized_keras_object(


config = {'class_name': 'BinaryPrediction', 'config': {'default_loss': 'binary_crossentropy', 'default_metrics': List(
(0): D...lti_label): False
(label_weights): None
)
)
), 'dtype': 'float32', 'name': 'click/binary_prediction', ...}}
module_objects = {'AbstractRNNCell': <class 'keras.layers.rnn.abstract_rnn_cell.AbstractRNNCell'>, 'Activation': <class 'keras.layers.c...rs.regularization.activity_regularization.ActivityRegularization'>, 'Add': <class 'keras.layers.merging.add.Add'>, ...}
custom_objects = None, printable_module_name = 'layer'

def class_and_config_for_serialized_keras_object(
    config,
    module_objects=None,
    custom_objects=None,
    printable_module_name='object'):
  """Returns the class name and config for a serialized keras object."""
  if (not isinstance(config, dict)
      or 'class_name' not in config
      or 'config' not in config):
    raise ValueError(
        f'Improper config format for {config}. '
        'Expecting python dict contains `class_name` and `config` as keys')

  class_name = config['class_name']
  cls = get_registered_object(class_name, custom_objects, module_objects)
  if cls is None:
  raise ValueError(
        f'Unknown {printable_module_name}: {class_name}. Please ensure this '
        'object is passed to the `custom_objects` argument. See '
        'https://www.tensorflow.org/guide/keras/save_and_serialize'
        '#registering_the_custom_object for details.')

E ValueError: Unknown layer: BinaryPrediction. Please ensure this object is passed to the custom_objects argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details.

/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:562: ValueError
----------------------------- Captured stdout call -----------------------------

1/1 [==============================] - ETA: 0s - loss: 0.6926 - click/binary_prediction/precision: 0.5111 - click/binary_prediction/recall: 0.9200 - click/binary_prediction/binary_accuracy: 0.5200 - click/binary_prediction/auc: 0.5688 - regularization_loss: 0.0000e+00����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������
1/1 [==============================] - 1s 616ms/step - loss: 0.6926 - click/binary_prediction/precision: 0.5111 - click/binary_prediction/recall: 0.9200 - click/binary_prediction/binary_accuracy: 0.5200 - click/binary_prediction/auc: 0.5688 - regularization_loss: 0.0000e+00
_____________________ test_binary_prediction_block[False] ______________________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fb3cd402b20>
run_eagerly = False

@pytest.mark.parametrize("run_eagerly", [True, False])
def test_binary_prediction_block(ecommerce_data: Dataset, run_eagerly):
    model = mm.Model(
        mm.InputBlock(ecommerce_data.schema),
        mm.MLPBlock([8]),
        mm.BinaryPrediction("click"),
    )
  _, history = testing_utils.model_test(model, ecommerce_data, run_eagerly=run_eagerly)

tests/unit/tf/predictions/test_classification.py:31:


merlin/models/tf/utils/testing_utils.py:110: in model_test
assert isinstance(model.from_config(model.get_config()), type(model))
merlin/models/tf/models/base.py:910: in from_config
layers = [
merlin/models/tf/models/base.py:911: in
tf.keras.layers.deserialize(conf, custom_objects=custom_objects)
/usr/local/lib/python3.8/dist-packages/keras/layers/serialization.py:205: in deserialize
return generic_utils.deserialize_keras_object(
/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:664: in deserialize_keras_object
(cls, cls_config) = class_and_config_for_serialized_keras_object(


config = {'class_name': 'BinaryPrediction', 'config': {'default_loss': 'binary_crossentropy', 'default_metrics': List(
(0): D...lti_label): False
(label_weights): None
)
)
), 'dtype': 'float32', 'name': 'click/binary_prediction', ...}}
module_objects = {'AbstractRNNCell': <class 'keras.layers.rnn.abstract_rnn_cell.AbstractRNNCell'>, 'Activation': <class 'keras.layers.c...rs.regularization.activity_regularization.ActivityRegularization'>, 'Add': <class 'keras.layers.merging.add.Add'>, ...}
custom_objects = None, printable_module_name = 'layer'

def class_and_config_for_serialized_keras_object(
    config,
    module_objects=None,
    custom_objects=None,
    printable_module_name='object'):
  """Returns the class name and config for a serialized keras object."""
  if (not isinstance(config, dict)
      or 'class_name' not in config
      or 'config' not in config):
    raise ValueError(
        f'Improper config format for {config}. '
        'Expecting python dict contains `class_name` and `config` as keys')

  class_name = config['class_name']
  cls = get_registered_object(class_name, custom_objects, module_objects)
  if cls is None:
  raise ValueError(
        f'Unknown {printable_module_name}: {class_name}. Please ensure this '
        'object is passed to the `custom_objects` argument. See '
        'https://www.tensorflow.org/guide/keras/save_and_serialize'
        '#registering_the_custom_object for details.')

E ValueError: Unknown layer: BinaryPrediction. Please ensure this object is passed to the custom_objects argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details.

/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:562: ValueError
----------------------------- Captured stdout call -----------------------------

1/1 [==============================] - ETA: 0s - loss: 0.6930 - click/binary_prediction/precision: 0.5366 - click/binary_prediction/recall: 0.8462 - click/binary_prediction/binary_accuracy: 0.5400 - click/binary_prediction/auc: 0.4936 - regularization_loss: 0.0000e+00����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������
1/1 [==============================] - 4s 4s/step - loss: 0.6930 - click/binary_prediction/precision: 0.5366 - click/binary_prediction/recall: 0.8462 - click/binary_prediction/binary_accuracy: 0.5400 - click/binary_prediction/auc: 0.4936 - regularization_loss: 0.0000e+00
______________________ test_binary_prediction_block[True] ______________________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fb313452400>
run_eagerly = True

@pytest.mark.parametrize("run_eagerly", [True, False])
def test_binary_prediction_block(ecommerce_data: Dataset, run_eagerly):
    model = mm.Model(
        mm.InputBlock(ecommerce_data.schema),
        mm.MLPBlock([8]),
        mm.RegressionPrediction("click"),
    )
  _, history = testing_utils.model_test(model, ecommerce_data, run_eagerly=run_eagerly)

tests/unit/tf/predictions/test_regression.py:31:


merlin/models/tf/utils/testing_utils.py:110: in model_test
assert isinstance(model.from_config(model.get_config()), type(model))
merlin/models/tf/models/base.py:910: in from_config
layers = [
merlin/models/tf/models/base.py:911: in
tf.keras.layers.deserialize(conf, custom_objects=custom_objects)
/usr/local/lib/python3.8/dist-packages/keras/layers/serialization.py:205: in deserialize
return generic_utils.deserialize_keras_object(
/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:664: in deserialize_keras_object
(cls, cls_config) = class_and_config_for_serialized_keras_object(


config = {'class_name': 'RegressionPrediction', 'config': {'default_loss': 'mse', 'default_metrics': List(
(0): Dict(
(cl...n_squared_error'
(dtype): 'float32'
)
)
), 'dtype': 'float32', 'name': 'click/regression_prediction', ...}}
module_objects = {'AbstractRNNCell': <class 'keras.layers.rnn.abstract_rnn_cell.AbstractRNNCell'>, 'Activation': <class 'keras.layers.c...rs.regularization.activity_regularization.ActivityRegularization'>, 'Add': <class 'keras.layers.merging.add.Add'>, ...}
custom_objects = None, printable_module_name = 'layer'

def class_and_config_for_serialized_keras_object(
    config,
    module_objects=None,
    custom_objects=None,
    printable_module_name='object'):
  """Returns the class name and config for a serialized keras object."""
  if (not isinstance(config, dict)
      or 'class_name' not in config
      or 'config' not in config):
    raise ValueError(
        f'Improper config format for {config}. '
        'Expecting python dict contains `class_name` and `config` as keys')

  class_name = config['class_name']
  cls = get_registered_object(class_name, custom_objects, module_objects)
  if cls is None:
  raise ValueError(
        f'Unknown {printable_module_name}: {class_name}. Please ensure this '
        'object is passed to the `custom_objects` argument. See '
        'https://www.tensorflow.org/guide/keras/save_and_serialize'
        '#registering_the_custom_object for details.')

E ValueError: Unknown layer: RegressionPrediction. Please ensure this object is passed to the custom_objects argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details.

/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:562: ValueError
----------------------------- Captured stdout call -----------------------------

1/1 [==============================] - ETA: 0s - loss: 0.5744 - click/regression_prediction/root_mean_squared_error: 0.7579 - regularization_loss: 0.0000e+00�������������������������������������������������������������������������������������������������������������������������������������������������������������
1/1 [==============================] - 0s 272ms/step - loss: 0.5744 - click/regression_prediction/root_mean_squared_error: 0.7579 - regularization_loss: 0.0000e+00
_____________________ test_binary_prediction_block[False] ______________________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fb0e3d64940>
run_eagerly = False

@pytest.mark.parametrize("run_eagerly", [True, False])
def test_binary_prediction_block(ecommerce_data: Dataset, run_eagerly):
    model = mm.Model(
        mm.InputBlock(ecommerce_data.schema),
        mm.MLPBlock([8]),
        mm.RegressionPrediction("click"),
    )
  _, history = testing_utils.model_test(model, ecommerce_data, run_eagerly=run_eagerly)

tests/unit/tf/predictions/test_regression.py:31:


merlin/models/tf/utils/testing_utils.py:110: in model_test
assert isinstance(model.from_config(model.get_config()), type(model))
merlin/models/tf/models/base.py:910: in from_config
layers = [
merlin/models/tf/models/base.py:911: in
tf.keras.layers.deserialize(conf, custom_objects=custom_objects)
/usr/local/lib/python3.8/dist-packages/keras/layers/serialization.py:205: in deserialize
return generic_utils.deserialize_keras_object(
/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:664: in deserialize_keras_object
(cls, cls_config) = class_and_config_for_serialized_keras_object(


config = {'class_name': 'RegressionPrediction', 'config': {'default_loss': 'mse', 'default_metrics': List(
(0): Dict(
(cl...n_squared_error'
(dtype): 'float32'
)
)
), 'dtype': 'float32', 'name': 'click/regression_prediction', ...}}
module_objects = {'AbstractRNNCell': <class 'keras.layers.rnn.abstract_rnn_cell.AbstractRNNCell'>, 'Activation': <class 'keras.layers.c...rs.regularization.activity_regularization.ActivityRegularization'>, 'Add': <class 'keras.layers.merging.add.Add'>, ...}
custom_objects = None, printable_module_name = 'layer'

def class_and_config_for_serialized_keras_object(
    config,
    module_objects=None,
    custom_objects=None,
    printable_module_name='object'):
  """Returns the class name and config for a serialized keras object."""
  if (not isinstance(config, dict)
      or 'class_name' not in config
      or 'config' not in config):
    raise ValueError(
        f'Improper config format for {config}. '
        'Expecting python dict contains `class_name` and `config` as keys')

  class_name = config['class_name']
  cls = get_registered_object(class_name, custom_objects, module_objects)
  if cls is None:
  raise ValueError(
        f'Unknown {printable_module_name}: {class_name}. Please ensure this '
        'object is passed to the `custom_objects` argument. See '
        'https://www.tensorflow.org/guide/keras/save_and_serialize'
        '#registering_the_custom_object for details.')

E ValueError: Unknown layer: RegressionPrediction. Please ensure this object is passed to the custom_objects argument. See https://www.tensorflow.org/guide/keras/save_and_serialize#registering_the_custom_object for details.

/usr/local/lib/python3.8/dist-packages/keras/utils/generic_utils.py:562: ValueError
----------------------------- Captured stdout call -----------------------------

1/1 [==============================] - ETA: 0s - loss: 0.6198 - click/regression_prediction/root_mean_squared_error: 0.7873 - regularization_loss: 0.0000e+00�������������������������������������������������������������������������������������������������������������������������������������������������������������
1/1 [==============================] - 3s 3s/step - loss: 0.6198 - click/regression_prediction/root_mean_squared_error: 0.7873 - regularization_loss: 0.0000e+00
=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:752: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_filee2pc3qeh.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.1]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.3]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.5]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.7]
tests/unit/tf/models/test_base.py::test_model_pre_post[True]
tests/unit/tf/models/test_base.py::test_model_pre_post[False]
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:266: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
====== 9 failed, 489 passed, 10 skipped, 97 warnings in 699.55s (0:11:39) ======
Build step 'Execute shell' marked build as failure
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins9826944685599890706.sh

@viswa-nvidia
Copy link

Moved to arbitration. Not clear how this maps to the roadmap . @marcromeyn , please clarify.

@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit e350b1811a8c93594d25a0348cd928121a61117f, no merge conflicts.
Running as SYSTEM
Setting status of e350b1811a8c93594d25a0348cd928121a61117f to PENDING with url https://10.20.13.93:8080/job/merlin_models/818/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse e350b1811a8c93594d25a0348cd928121a61117f^{commit} # timeout=10
Checking out Revision e350b1811a8c93594d25a0348cd928121a61117f (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f e350b1811a8c93594d25a0348cd928121a61117f # timeout=10
Commit message: "fix missing imports"
 > git rev-list --no-walk b064fd3c2164003f1c36e8984a6b0327d39d9561 # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins6746806471457472513.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 569 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 1%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 3%]
tests/unit/datasets/test_synthetic.py ..... [ 4%]
tests/unit/tf/test_core.py ...... [ 5%]
tests/unit/tf/test_dataset.py ................ [ 8%]
tests/unit/tf/test_public_api.py . [ 8%]
tests/unit/tf/blocks/test_cross.py ........... [ 10%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 11%]
tests/unit/tf/blocks/test_interactions.py . [ 11%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 17%]
tests/unit/tf/blocks/test_multi_optimizers.py s.................... [ 21%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 21%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 23%]
tests/unit/tf/core/test_aggregation.py ......... [ 25%]
tests/unit/tf/core/test_base.py .. [ 25%]
tests/unit/tf/core/test_combinators.py .................. [ 28%]
tests/unit/tf/core/test_index.py ... [ 29%]
tests/unit/tf/core/test_prediction.py .. [ 29%]
tests/unit/tf/core/test_tabular.py .... [ 30%]
tests/unit/tf/core/test_transformations.py s............................ [ 35%]
... [ 36%]
tests/unit/tf/data_augmentation/test_misc.py . [ 36%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 37%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 38%]
tests/unit/tf/examples/test_01_getting_started.py . [ 39%]
tests/unit/tf/examples/test_02_dataschema.py . [ 39%]
tests/unit/tf/examples/test_03_exploring_different_models.py . [ 39%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 39%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 39%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py . [ 39%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py . [ 40%]
tests/unit/tf/inputs/test_continuous.py ..... [ 40%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 45%]
tests/unit/tf/inputs/test_tabular.py .................. [ 48%]
tests/unit/tf/layers/test_queue.py .............. [ 51%]
tests/unit/tf/losses/test_losses.py ....................... [ 55%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 56%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 59%]
tests/unit/tf/models/test_base.py ........... [ 61%]
tests/unit/tf/models/test_benchmark.py .. [ 61%]
tests/unit/tf/models/test_ranking.py ................ [ 64%]
tests/unit/tf/models/test_retrieval.py ............................... [ 69%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 70%]
tests/unit/tf/prediction_tasks/test_multi_task.py ................ [ 72%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 73%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 74%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 75%]
tests/unit/tf/predictions/test_base.py ..... [ 76%]
tests/unit/tf/predictions/test_classification.py .. [ 76%]
tests/unit/tf/predictions/test_dot_product.py ......F. [ 77%]
tests/unit/tf/predictions/test_regression.py .. [ 78%]
tests/unit/tf/utils/test_batch.py .... [ 78%]
tests/unit/tf/utils/test_tf_utils.py .. [ 79%]
tests/unit/torch/test_dataset.py ......... [ 80%]
tests/unit/torch/test_public_api.py . [ 81%]
tests/unit/torch/block/test_base.py .... [ 81%]
tests/unit/torch/block/test_mlp.py . [ 81%]
tests/unit/torch/features/test_continuous.py .. [ 82%]
tests/unit/torch/features/test_embedding.py .............. [ 84%]
tests/unit/torch/features/test_tabular.py .... [ 85%]
tests/unit/torch/model/test_head.py ............ [ 87%]
tests/unit/torch/model/test_model.py .. [ 87%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 89%]
tests/unit/torch/tabular/test_tabular.py ... [ 89%]
tests/unit/torch/tabular/test_transformations.py ....... [ 91%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................... [100%]

=================================== FAILURES ===================================
_____________ test_item_retrieval_scorer_downscore_false_negatives _____________

ecommerce_data = <merlin.io.dataset.Dataset object at 0x7fad149cba30>

def test_item_retrieval_scorer_downscore_false_negatives(ecommerce_data: Dataset):
    batch_size = 10

    inbatch_sampler = InBatchSampler()
    inputs, features = _retrieval_inputs_(batch_size=batch_size)

    FALSE_NEGATIVE_SCORE = -100_000_000.0
    item_retrieval_scorer = ContrastiveDotProduct(
        schema=ecommerce_data.schema,
        negative_samplers=[inbatch_sampler],
        downscore_false_negatives=True,
        false_negative_score=FALSE_NEGATIVE_SCORE,
    )

    outputs = item_retrieval_scorer(
        inputs,
        training=True,
        features=features,
    )
    output_scores = outputs.predictions

    output_neg_scores = output_scores[:, 1:]

    diag_mask = tf.eye(tf.shape(output_neg_scores)[0], dtype=tf.bool)
    tf.assert_equal(output_neg_scores[diag_mask], FALSE_NEGATIVE_SCORE)
  tf.assert_equal(
        tf.reduce_all(
            tf.not_equal(
                output_neg_scores[tf.math.logical_not(diag_mask)],
                tf.constant(FALSE_NEGATIVE_SCORE, dtype=output_neg_scores.dtype),
            )
        ),
        True,
    )

tests/unit/tf/predictions/test_dot_product.py:98:


/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/traceback_utils.py:141: in error_handler
return fn(*args, **kwargs)
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: in op_dispatch_handler
return dispatch_target(*args, **kwargs)
/usr/local/lib/python3.8/dist-packages/tensorflow/python/ops/check_ops.py:713: in assert_equal_v2
return assert_equal(x=x, y=y, summarize=summarize, message=message, name=name)
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/traceback_utils.py:141: in error_handler
return fn(*args, **kwargs)
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: in op_dispatch_handler
return dispatch_target(*args, **kwargs)
/usr/local/lib/python3.8/dist-packages/tensorflow/python/ops/check_ops.py:724: in assert_equal
return _binary_assert('==', 'assert_equal', math_ops.equal, np.equal, x, y,


sym = '==', opname = 'assert_equal'
op_func = <function equal at 0x7fae2ba6eb80>, static_func = <ufunc 'equal'>
x = <tf.Tensor: shape=(), dtype=bool, numpy=False>
y = <tf.Tensor: shape=(), dtype=bool, numpy=True>
data = ['Condition x == y did not hold.', 'First 1 elements of x:', array([False]), 'First 1 elements of y:', array([ True])]
summarize = 3, message = None, name = None

def _binary_assert(sym, opname, op_func, static_func, x, y, data, summarize,
                   message, name):
  """Generic binary elementwise assertion.

  Implements the behavior described in _binary_assert_doc() above.
  Args:
    sym: Mathematical symbol for the test to apply to pairs of tensor elements,
      i.e. "=="
    opname: Name of the assert op in the public API, i.e. "assert_equal"
    op_func: Function that, if passed the two Tensor inputs to the assertion (x
      and y), will return the test to be passed to reduce_all() i.e.
    static_func: Function that, if passed numpy ndarray versions of the two
      inputs to the assertion, will return a Boolean ndarray with containing
      True in all positions where the assertion PASSES.
      i.e. np.equal for assert_equal()
    x:  Numeric `Tensor`.
    y:  Numeric `Tensor`, same dtype as and broadcastable to `x`.
    data:  The tensors to print out if the condition is False.  Defaults to
      error message and first few entries of `x`, `y`.
    summarize: Print this many entries of each tensor.
    message: A string to prefix to the default message.
    name: A name for this operation (optional).  Defaults to the value of
      `opname`.

  Returns:
    See docstring template in _binary_assert_doc().
  """
  with ops.name_scope(name, opname, [x, y, data]):
    x = ops.convert_to_tensor(x, name='x')
    y = ops.convert_to_tensor(y, name='y')

    if context.executing_eagerly():
      test_op = op_func(x, y)
      condition = math_ops.reduce_all(test_op)
      if condition:
        return

      # If we get here, the assertion has failed.
      # Default to printing 3 elements like control_flow_ops.Assert (used
      # by graph mode) does. Also treat negative values as "print
      # everything" for consistency with Tensor::SummarizeValue().
      if summarize is None:
        summarize = 3
      elif summarize < 0:
        summarize = 1e9  # Code below will find exact size of x and y.

      if data is None:
        data = _make_assert_msg_data(sym, x, y, summarize, test_op)

      if message is not None:
        data = [message] + list(data)
    raise errors.InvalidArgumentError(
          node_def=None,
          op=None,
          message=('\n'.join(_pretty_print(d, summarize) for d in data)))

E tensorflow.python.framework.errors_impl.InvalidArgumentError: Condition x == y did not hold.
E First 1 elements of x:
E [False]
E First 1 elements of y:
E [ True]

/usr/local/lib/python3.8/dist-packages/tensorflow/python/ops/check_ops.py:407: InvalidArgumentError
=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:768: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/predictions/test_dot_product.py: 2 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_file0vhle194.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.1]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.3]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.5]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.7]
tests/unit/tf/models/test_base.py::test_model_pre_post[True]
tests/unit/tf/models/test_base.py::test_model_pre_post[False]
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:264: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [2] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
====== 1 failed, 559 passed, 11 skipped, 99 warnings in 774.06s (0:12:54) ======
Build step 'Execute shell' marked build as failure
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins2792491566800598731.sh

@sararb sararb marked this pull request as ready for review August 3, 2022 17:37
@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit e5c58bcb2826a00d86c04bfa97c8f976c182e534, no merge conflicts.
Running as SYSTEM
Setting status of e5c58bcb2826a00d86c04bfa97c8f976c182e534 to PENDING with url https://10.20.13.93:8080/job/merlin_models/821/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse e5c58bcb2826a00d86c04bfa97c8f976c182e534^{commit} # timeout=10
Checking out Revision e5c58bcb2826a00d86c04bfa97c8f976c182e534 (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f e5c58bcb2826a00d86c04bfa97c8f976c182e534 # timeout=10
Commit message: "fix failing test"
 > git rev-list --no-walk c17f8bc5be6f85e83b3e956d14e871f37d96934d # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins4969210954974086974.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 569 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 1%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 3%]
tests/unit/datasets/test_synthetic.py ..... [ 4%]
tests/unit/tf/test_core.py ...... [ 5%]
tests/unit/tf/test_dataset.py ................ [ 8%]
tests/unit/tf/test_public_api.py . [ 8%]
tests/unit/tf/blocks/test_cross.py ........... [ 10%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 11%]
tests/unit/tf/blocks/test_interactions.py . [ 11%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 17%]
tests/unit/tf/blocks/test_multi_optimizers.py s.................... [ 21%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 21%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 23%]
tests/unit/tf/core/test_aggregation.py ......... [ 25%]
tests/unit/tf/core/test_base.py .. [ 25%]
tests/unit/tf/core/test_combinators.py .................. [ 28%]
tests/unit/tf/core/test_index.py ... [ 29%]
tests/unit/tf/core/test_prediction.py .. [ 29%]
tests/unit/tf/core/test_tabular.py .... [ 30%]
tests/unit/tf/core/test_transformations.py s............................ [ 35%]
... [ 36%]
tests/unit/tf/data_augmentation/test_misc.py . [ 36%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 37%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 38%]
tests/unit/tf/examples/test_01_getting_started.py . [ 39%]
tests/unit/tf/examples/test_02_dataschema.py . [ 39%]
tests/unit/tf/examples/test_03_exploring_different_models.py . [ 39%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 39%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 39%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py . [ 39%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py . [ 40%]
tests/unit/tf/inputs/test_continuous.py ..... [ 40%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 45%]
tests/unit/tf/inputs/test_tabular.py .................. [ 48%]
tests/unit/tf/layers/test_queue.py .............. [ 51%]
tests/unit/tf/losses/test_losses.py ....................... [ 55%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 56%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 59%]
tests/unit/tf/models/test_base.py ........... [ 61%]
tests/unit/tf/models/test_benchmark.py .. [ 61%]
tests/unit/tf/models/test_ranking.py ................ [ 64%]
tests/unit/tf/models/test_retrieval.py ............................... [ 69%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 70%]
tests/unit/tf/prediction_tasks/test_multi_task.py ................ [ 72%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 73%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 74%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 75%]
tests/unit/tf/predictions/test_base.py ..... [ 76%]
tests/unit/tf/predictions/test_classification.py .. [ 76%]
tests/unit/tf/predictions/test_dot_product.py ........ [ 77%]
tests/unit/tf/predictions/test_regression.py .. [ 78%]
tests/unit/tf/utils/test_batch.py .... [ 78%]
tests/unit/tf/utils/test_tf_utils.py .. [ 79%]
tests/unit/torch/test_dataset.py ......... [ 80%]
tests/unit/torch/test_public_api.py . [ 81%]
tests/unit/torch/block/test_base.py .... [ 81%]
tests/unit/torch/block/test_mlp.py . [ 81%]
tests/unit/torch/features/test_continuous.py .. [ 82%]
tests/unit/torch/features/test_embedding.py .............. [ 84%]
tests/unit/torch/features/test_tabular.py .... [ 85%]
tests/unit/torch/model/test_head.py ............ [ 87%]
tests/unit/torch/model/test_model.py .. [ 87%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 89%]
tests/unit/torch/tabular/test_tabular.py ... [ 89%]
tests/unit/torch/tabular/test_transformations.py ....... [ 91%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................... [100%]

=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:768: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/predictions/test_dot_product.py: 2 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_filedr0qfery.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.1]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.3]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.5]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.7]
tests/unit/tf/models/test_base.py::test_model_pre_post[True]
tests/unit/tf/models/test_base.py::test_model_pre_post[False]
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:264: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [2] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
=========== 560 passed, 11 skipped, 99 warnings in 783.62s (0:13:03) ===========
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins11943369698402773399.sh


@ItemSampler.registry.register("in-batch")
@tf.keras.utils.register_keras_serializable(package="merlin.models")
class InBatchSampler(ItemSampler):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is different about this compared to the InBatchSampler that exists in tf.blocks.sampling.in_batch ?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The objective is to move the sampling under the predictions folder as this is used by the new refactored prediction blocks. There are also some enhancements of the sampling blocks (base and InBatchSampler) to improve the API, which are:

  • Add a registry for sampling strategies
  • The class arguments are _last_batch_items_embeddings and _last_batch_items_metadata are wrapped in a new NamedTuple class Items. This new class will replace replace EmbeddingWithMetadata class.
  • Add get_config method to InBatchSampler for serialization.

I think we could keep the old sampling strategies until we update the High-level API with the new prediction blocks and the old ItemRetrievalTask / ItemRetrievalScorer gets dropped.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can follow-up on this in another PR. I'm wondering if the behavior of this class is the same from an interface/api perspective - will we be able to replace uses of the old one without any changes to the surrounding code.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, that's a good point! Once all tasks defined in this ticket are done, the next step is to do the benchmarking of the retrieval/ranking models and then we change the high-level API. The main constraint when implementing these tasks is to keep the user-facing API the same.

But in order to simplify things, the item retrieval model will be converted into a Top-k recommender and Top-k evaluation will be implemented differently. The overall objective is to build a ItemRecommenderModel class that supports the base methods predict() for evaluation and .save() for serialization. Here is a draft code that summarizes what Marc and I discussed.

@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit afbcf163ecf4ca900b0a13c1b331d960576849a4, no merge conflicts.
Running as SYSTEM
Setting status of afbcf163ecf4ca900b0a13c1b331d960576849a4 to PENDING with url https://10.20.13.93:8080/job/merlin_models/829/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse afbcf163ecf4ca900b0a13c1b331d960576849a4^{commit} # timeout=10
Checking out Revision afbcf163ecf4ca900b0a13c1b331d960576849a4 (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f afbcf163ecf4ca900b0a13c1b331d960576849a4 # timeout=10
Commit message: "Merge branch 'main' into tf/contrastive-prediction"
 > git rev-list --no-walk a5b60a29fd10c3075c14292553754b1c800e93e5 # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins10867746741512874101.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 569 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 1%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 3%]
tests/unit/datasets/test_synthetic.py ..... [ 4%]
tests/unit/tf/test_core.py ...... [ 5%]
tests/unit/tf/test_dataset.py ................ [ 8%]
tests/unit/tf/test_public_api.py . [ 8%]
tests/unit/tf/blocks/test_cross.py ........... [ 10%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 11%]
tests/unit/tf/blocks/test_interactions.py . [ 11%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 17%]
tests/unit/tf/blocks/test_multi_optimizers.py s.................... [ 21%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 21%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 23%]
tests/unit/tf/core/test_aggregation.py ......... [ 25%]
tests/unit/tf/core/test_base.py .. [ 25%]
tests/unit/tf/core/test_combinators.py .................. [ 28%]
tests/unit/tf/core/test_index.py ... [ 29%]
tests/unit/tf/core/test_prediction.py .. [ 29%]
tests/unit/tf/core/test_tabular.py .... [ 30%]
tests/unit/tf/core/test_transformations.py s............................ [ 35%]
... [ 36%]
tests/unit/tf/data_augmentation/test_misc.py . [ 36%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 37%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 38%]
tests/unit/tf/examples/test_01_getting_started.py . [ 39%]
tests/unit/tf/examples/test_02_dataschema.py . [ 39%]
tests/unit/tf/examples/test_03_exploring_different_models.py . [ 39%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 39%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 39%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py . [ 39%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py . [ 40%]
tests/unit/tf/inputs/test_continuous.py ..... [ 40%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 45%]
tests/unit/tf/inputs/test_tabular.py .................. [ 48%]
tests/unit/tf/layers/test_queue.py .............. [ 51%]
tests/unit/tf/losses/test_losses.py ....................... [ 55%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 56%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 59%]
tests/unit/tf/models/test_base.py ........... [ 61%]
tests/unit/tf/models/test_benchmark.py .. [ 61%]
tests/unit/tf/models/test_ranking.py ................ [ 64%]
tests/unit/tf/models/test_retrieval.py ............................... [ 69%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 70%]
tests/unit/tf/prediction_tasks/test_multi_task.py ................ [ 72%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 73%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 74%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 75%]
tests/unit/tf/predictions/test_base.py ..... [ 76%]
tests/unit/tf/predictions/test_classification.py .. [ 76%]
tests/unit/tf/predictions/test_dot_product.py ........ [ 77%]
tests/unit/tf/predictions/test_regression.py .. [ 78%]
tests/unit/tf/utils/test_batch.py .... [ 78%]
tests/unit/tf/utils/test_tf_utils.py .. [ 79%]
tests/unit/torch/test_dataset.py ......... [ 80%]
tests/unit/torch/test_public_api.py . [ 81%]
tests/unit/torch/block/test_base.py .... [ 81%]
tests/unit/torch/block/test_mlp.py . [ 81%]
tests/unit/torch/features/test_continuous.py .. [ 82%]
tests/unit/torch/features/test_embedding.py .............. [ 84%]
tests/unit/torch/features/test_tabular.py .... [ 85%]
tests/unit/torch/model/test_head.py ............ [ 87%]
tests/unit/torch/model/test_model.py .. [ 87%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 89%]
tests/unit/torch/tabular/test_tabular.py ... [ 89%]
tests/unit/torch/tabular/test_transformations.py ....... [ 91%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................... [100%]

=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:768: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/predictions/test_dot_product.py: 2 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_filerj6kqm1o.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.1]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.3]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.5]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.7]
tests/unit/tf/models/test_base.py::test_model_pre_post[True]
tests/unit/tf/models/test_base.py::test_model_pre_post[False]
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:264: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [2] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
=========== 560 passed, 11 skipped, 99 warnings in 774.09s (0:12:54) ===========
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins11943330234452110088.sh

config = super().get_config()
config["batch_size"] = self._batch_size

# TODO: This is a side-effect, could this lead to problems?
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you explain why is this line necessary? something to do with resetting the state?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@marcromeyn added this code line, so I kept it until he returned to find out why it is needed.

@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit 1befb657c5bbaff3fb44746916ada15fa6c20af4, no merge conflicts.
Running as SYSTEM
Setting status of 1befb657c5bbaff3fb44746916ada15fa6c20af4 to PENDING with url https://10.20.13.93:8080/job/merlin_models/830/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse 1befb657c5bbaff3fb44746916ada15fa6c20af4^{commit} # timeout=10
Checking out Revision 1befb657c5bbaff3fb44746916ada15fa6c20af4 (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f 1befb657c5bbaff3fb44746916ada15fa6c20af4 # timeout=10
Commit message: "add missing license from PR review"
 > git rev-list --no-walk afbcf163ecf4ca900b0a13c1b331d960576849a4 # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins4654256145322803847.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 571 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 1%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 3%]
tests/unit/datasets/test_synthetic.py ..... [ 4%]
tests/unit/tf/test_core.py ...... [ 5%]
tests/unit/tf/test_dataset.py ................ [ 8%]
tests/unit/tf/test_public_api.py . [ 8%]
tests/unit/tf/blocks/test_cross.py ........... [ 10%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 11%]
tests/unit/tf/blocks/test_interactions.py . [ 11%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 17%]
tests/unit/tf/blocks/test_multi_optimizers.py s.................... [ 21%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 21%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 23%]
tests/unit/tf/core/test_aggregation.py ......... [ 25%]
tests/unit/tf/core/test_base.py .. [ 25%]
tests/unit/tf/core/test_combinators.py .................. [ 28%]
tests/unit/tf/core/test_index.py ... [ 29%]
tests/unit/tf/core/test_prediction.py .. [ 29%]
tests/unit/tf/core/test_tabular.py .... [ 30%]
tests/unit/tf/core/test_transformations.py s............................ [ 35%]
... [ 35%]
tests/unit/tf/data_augmentation/test_misc.py . [ 36%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 37%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 38%]
tests/unit/tf/examples/test_01_getting_started.py . [ 38%]
tests/unit/tf/examples/test_02_dataschema.py . [ 39%]
tests/unit/tf/examples/test_03_exploring_different_models.py . [ 39%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 39%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 39%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py . [ 39%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py . [ 39%]
tests/unit/tf/inputs/test_continuous.py ..... [ 40%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 45%]
tests/unit/tf/inputs/test_tabular.py .................. [ 48%]
tests/unit/tf/layers/test_queue.py .............. [ 50%]
tests/unit/tf/losses/test_losses.py ....................... [ 54%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 55%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 59%]
tests/unit/tf/models/test_base.py ........... [ 60%]
tests/unit/tf/models/test_benchmark.py .. [ 61%]
tests/unit/tf/models/test_ranking.py ................ [ 64%]
tests/unit/tf/models/test_retrieval.py ............................... [ 69%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 69%]
tests/unit/tf/prediction_tasks/test_multi_task.py ................ [ 72%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 73%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 73%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 74%]
tests/unit/tf/predictions/test_base.py ..... [ 75%]
tests/unit/tf/predictions/test_classification.py .. [ 76%]
tests/unit/tf/predictions/test_dot_product.py ........ [ 77%]
tests/unit/tf/predictions/test_regression.py .. [ 77%]
tests/unit/tf/predictions/test_sampling.py .. [ 78%]
tests/unit/tf/utils/test_batch.py .... [ 78%]
tests/unit/tf/utils/test_tf_utils.py .. [ 79%]
tests/unit/torch/test_dataset.py ......... [ 80%]
tests/unit/torch/test_public_api.py . [ 81%]
tests/unit/torch/block/test_base.py .... [ 81%]
tests/unit/torch/block/test_mlp.py . [ 81%]
tests/unit/torch/features/test_continuous.py .. [ 82%]
tests/unit/torch/features/test_embedding.py .............. [ 84%]
tests/unit/torch/features/test_tabular.py .... [ 85%]
tests/unit/torch/model/test_head.py ............ [ 87%]
tests/unit/torch/model/test_model.py .. [ 87%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 89%]
tests/unit/torch/tabular/test_tabular.py ... [ 89%]
tests/unit/torch/tabular/test_transformations.py ....... [ 91%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................... [100%]

=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:768: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/predictions/test_dot_product.py: 2 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_fileu09ew1ep.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.1]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.3]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.5]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.7]
tests/unit/tf/models/test_base.py::test_model_pre_post[True]
tests/unit/tf/models/test_base.py::test_model_pre_post[False]
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:264: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [2] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
=========== 562 passed, 11 skipped, 99 warnings in 773.73s (0:12:53) ===========
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins15748465210790736329.sh

@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit a17e430b2b42ca9594d7d653a0326f853ea043d5, no merge conflicts.
Running as SYSTEM
Setting status of a17e430b2b42ca9594d7d653a0326f853ea043d5 to PENDING with url https://10.20.13.93:8080/job/merlin_models/831/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse a17e430b2b42ca9594d7d653a0326f853ea043d5^{commit} # timeout=10
Checking out Revision a17e430b2b42ca9594d7d653a0326f853ea043d5 (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f a17e430b2b42ca9594d7d653a0326f853ea043d5 # timeout=10
Commit message: "remove unnecessary TODO"
 > git rev-list --no-walk 1befb657c5bbaff3fb44746916ada15fa6c20af4 # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins15917967713176174238.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 571 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 1%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 3%]
tests/unit/datasets/test_synthetic.py ..... [ 4%]
tests/unit/tf/test_core.py ...... [ 5%]
tests/unit/tf/test_dataset.py ................ [ 8%]
tests/unit/tf/test_public_api.py . [ 8%]
tests/unit/tf/blocks/test_cross.py ........... [ 10%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 11%]
tests/unit/tf/blocks/test_interactions.py . [ 11%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 17%]
tests/unit/tf/blocks/test_multi_optimizers.py s.................... [ 21%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 21%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 23%]
tests/unit/tf/core/test_aggregation.py ......... [ 25%]
tests/unit/tf/core/test_base.py .. [ 25%]
tests/unit/tf/core/test_combinators.py .................. [ 28%]
tests/unit/tf/core/test_index.py ... [ 29%]
tests/unit/tf/core/test_prediction.py .. [ 29%]
tests/unit/tf/core/test_tabular.py .... [ 30%]
tests/unit/tf/core/test_transformations.py s............................ [ 35%]
... [ 35%]
tests/unit/tf/data_augmentation/test_misc.py . [ 36%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 37%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 38%]
tests/unit/tf/examples/test_01_getting_started.py . [ 38%]
tests/unit/tf/examples/test_02_dataschema.py . [ 39%]
tests/unit/tf/examples/test_03_exploring_different_models.py . [ 39%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 39%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 39%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py . [ 39%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py . [ 39%]
tests/unit/tf/inputs/test_continuous.py ..... [ 40%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 45%]
tests/unit/tf/inputs/test_tabular.py .................. [ 48%]
tests/unit/tf/layers/test_queue.py .............. [ 50%]
tests/unit/tf/losses/test_losses.py ....................... [ 54%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 55%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 59%]
tests/unit/tf/models/test_base.py ........... [ 60%]
tests/unit/tf/models/test_benchmark.py .. [ 61%]
tests/unit/tf/models/test_ranking.py ................ [ 64%]
tests/unit/tf/models/test_retrieval.py ............................... [ 69%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 69%]
tests/unit/tf/prediction_tasks/test_multi_task.py ................ [ 72%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 73%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 73%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 74%]
tests/unit/tf/predictions/test_base.py ..... [ 75%]
tests/unit/tf/predictions/test_classification.py .. [ 76%]
tests/unit/tf/predictions/test_dot_product.py ........ [ 77%]
tests/unit/tf/predictions/test_regression.py .. [ 77%]
tests/unit/tf/predictions/test_sampling.py .. [ 78%]
tests/unit/tf/utils/test_batch.py .... [ 78%]
tests/unit/tf/utils/test_tf_utils.py .. [ 79%]
tests/unit/torch/test_dataset.py ......... [ 80%]
tests/unit/torch/test_public_api.py . [ 81%]
tests/unit/torch/block/test_base.py .... [ 81%]
tests/unit/torch/block/test_mlp.py . [ 81%]
tests/unit/torch/features/test_continuous.py .. [ 82%]
tests/unit/torch/features/test_embedding.py .............. [ 84%]
tests/unit/torch/features/test_tabular.py .... [ 85%]
tests/unit/torch/model/test_head.py ............ [ 87%]
tests/unit/torch/model/test_model.py .. [ 87%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 89%]
tests/unit/torch/tabular/test_tabular.py ... [ 89%]
tests/unit/torch/tabular/test_transformations.py ....... [ 91%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................... [100%]

=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:768: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/predictions/test_dot_product.py: 2 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_filent4xnq05.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.1]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.3]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.5]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.7]
tests/unit/tf/models/test_base.py::test_model_pre_post[True]
tests/unit/tf/models/test_base.py::test_model_pre_post[False]
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:264: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [2] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
=========== 562 passed, 11 skipped, 99 warnings in 772.19s (0:12:52) ===========
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins16558080880181125340.sh

@nvidia-merlin-bot
Copy link

Click to view CI Results
GitHub pull request #594 of commit e74b63abdf17e5bf35fd56624684d8a34304b53c, no merge conflicts.
Running as SYSTEM
Setting status of e74b63abdf17e5bf35fd56624684d8a34304b53c to PENDING with url https://10.20.13.93:8080/job/merlin_models/832/console and message: 'Pending'
Using context: Jenkins
Building on master in workspace /var/jenkins_home/workspace/merlin_models
using credential nvidia-merlin-bot
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url https://github.com/NVIDIA-Merlin/models/ # timeout=10
Fetching upstream changes from https://github.com/NVIDIA-Merlin/models/
 > git --version # timeout=10
using GIT_ASKPASS to set credentials This is the bot credentials for our CI/CD
 > git fetch --tags --force --progress -- https://github.com/NVIDIA-Merlin/models/ +refs/pull/594/*:refs/remotes/origin/pr/594/* # timeout=10
 > git rev-parse e74b63abdf17e5bf35fd56624684d8a34304b53c^{commit} # timeout=10
Checking out Revision e74b63abdf17e5bf35fd56624684d8a34304b53c (detached)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f e74b63abdf17e5bf35fd56624684d8a34304b53c # timeout=10
Commit message: "Merge branch 'main' into tf/contrastive-prediction"
 > git rev-list --no-walk a17e430b2b42ca9594d7d653a0326f853ea043d5 # timeout=10
[merlin_models] $ /bin/bash /tmp/jenkins12123897127620891862.sh
Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com
Requirement already satisfied: testbook in /usr/local/lib/python3.8/dist-packages (0.4.2)
Requirement already satisfied: nbformat>=5.0.4 in /usr/local/lib/python3.8/dist-packages (from testbook) (5.4.0)
Requirement already satisfied: nbclient>=0.4.0 in /usr/local/lib/python3.8/dist-packages (from testbook) (0.6.5)
Requirement already satisfied: traitlets>=5.1 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (5.3.0)
Requirement already satisfied: jsonschema>=2.6 in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.6.1)
Requirement already satisfied: jupyter-core in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (4.10.0)
Requirement already satisfied: fastjsonschema in /usr/local/lib/python3.8/dist-packages (from nbformat>=5.0.4->testbook) (2.15.3)
Requirement already satisfied: jupyter-client>=6.1.5 in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (7.3.4)
Requirement already satisfied: nest-asyncio in /usr/local/lib/python3.8/dist-packages (from nbclient>=0.4.0->testbook) (1.5.5)
Requirement already satisfied: attrs>=17.4.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (21.4.0)
Requirement already satisfied: importlib-resources>=1.4.0; python_version < "3.9" in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (5.8.0)
Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /usr/local/lib/python3.8/dist-packages (from jsonschema>=2.6->nbformat>=5.0.4->testbook) (0.18.1)
Requirement already satisfied: entrypoints in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (0.4)
Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (2.8.2)
Requirement already satisfied: pyzmq>=23.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (23.2.0)
Requirement already satisfied: tornado>=6.0 in /usr/local/lib/python3.8/dist-packages (from jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (6.1)
Requirement already satisfied: zipp>=3.1.0; python_version < "3.10" in /usr/local/lib/python3.8/dist-packages (from importlib-resources>=1.4.0; python_version < "3.9"->jsonschema>=2.6->nbformat>=5.0.4->testbook) (3.8.0)
Requirement already satisfied: six>=1.5 in /var/jenkins_home/.local/lib/python3.8/site-packages (from python-dateutil>=2.8.2->jupyter-client>=6.1.5->nbclient>=0.4.0->testbook) (1.15.0)
============================= test session starts ==============================
platform linux -- Python 3.8.10, pytest-7.1.2, pluggy-1.0.0
rootdir: /var/jenkins_home/workspace/merlin_models/models, configfile: pyproject.toml
plugins: anyio-3.6.1, xdist-2.5.0, forked-1.4.0, cov-3.0.0
collected 571 items / 2 skipped

tests/unit/config/test_schema.py .... [ 0%]
tests/unit/datasets/test_advertising.py .s [ 1%]
tests/unit/datasets/test_ecommerce.py ..sss [ 1%]
tests/unit/datasets/test_entertainment.py ....sss. [ 3%]
tests/unit/datasets/test_social.py . [ 3%]
tests/unit/datasets/test_synthetic.py ..... [ 4%]
tests/unit/tf/test_core.py ...... [ 5%]
tests/unit/tf/test_dataset.py ................ [ 8%]
tests/unit/tf/test_public_api.py . [ 8%]
tests/unit/tf/blocks/test_cross.py ........... [ 10%]
tests/unit/tf/blocks/test_dlrm.py ........ [ 11%]
tests/unit/tf/blocks/test_interactions.py . [ 11%]
tests/unit/tf/blocks/test_mlp.py ................................. [ 17%]
tests/unit/tf/blocks/test_multi_optimizers.py s.................... [ 21%]
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py .. [ 21%]
tests/unit/tf/blocks/retrieval/test_two_tower.py ........... [ 23%]
tests/unit/tf/core/test_aggregation.py ......... [ 25%]
tests/unit/tf/core/test_base.py .. [ 25%]
tests/unit/tf/core/test_combinators.py .................. [ 28%]
tests/unit/tf/core/test_index.py ... [ 29%]
tests/unit/tf/core/test_prediction.py .. [ 29%]
tests/unit/tf/core/test_tabular.py .... [ 30%]
tests/unit/tf/core/test_transformations.py s............................ [ 35%]
... [ 35%]
tests/unit/tf/data_augmentation/test_misc.py . [ 36%]
tests/unit/tf/data_augmentation/test_negative_sampling.py .......... [ 37%]
tests/unit/tf/data_augmentation/test_noise.py ..... [ 38%]
tests/unit/tf/examples/test_01_getting_started.py . [ 38%]
tests/unit/tf/examples/test_02_dataschema.py . [ 39%]
tests/unit/tf/examples/test_03_exploring_different_models.py . [ 39%]
tests/unit/tf/examples/test_04_export_ranking_models.py . [ 39%]
tests/unit/tf/examples/test_05_export_retrieval_model.py . [ 39%]
tests/unit/tf/examples/test_06_advanced_own_architecture.py . [ 39%]
tests/unit/tf/examples/test_usecase_pretrained_embeddings.py . [ 39%]
tests/unit/tf/inputs/test_continuous.py ..... [ 40%]
tests/unit/tf/inputs/test_embedding.py .......................... [ 45%]
tests/unit/tf/inputs/test_tabular.py .................. [ 48%]
tests/unit/tf/layers/test_queue.py .............. [ 50%]
tests/unit/tf/losses/test_losses.py ....................... [ 54%]
tests/unit/tf/metrics/test_metrics_popularity.py ..... [ 55%]
tests/unit/tf/metrics/test_metrics_topk.py .................. [ 59%]
tests/unit/tf/models/test_base.py ........... [ 60%]
tests/unit/tf/models/test_benchmark.py .. [ 61%]
tests/unit/tf/models/test_ranking.py ................ [ 64%]
tests/unit/tf/models/test_retrieval.py ............................... [ 69%]
tests/unit/tf/prediction_tasks/test_classification.py .. [ 69%]
tests/unit/tf/prediction_tasks/test_multi_task.py ................ [ 72%]
tests/unit/tf/prediction_tasks/test_next_item.py ..... [ 73%]
tests/unit/tf/prediction_tasks/test_regression.py .. [ 73%]
tests/unit/tf/prediction_tasks/test_sampling.py ...... [ 74%]
tests/unit/tf/predictions/test_base.py ..... [ 75%]
tests/unit/tf/predictions/test_classification.py .. [ 76%]
tests/unit/tf/predictions/test_dot_product.py ........ [ 77%]
tests/unit/tf/predictions/test_regression.py .. [ 77%]
tests/unit/tf/predictions/test_sampling.py .. [ 78%]
tests/unit/tf/utils/test_batch.py .... [ 78%]
tests/unit/tf/utils/test_tf_utils.py .. [ 79%]
tests/unit/torch/test_dataset.py ......... [ 80%]
tests/unit/torch/test_public_api.py . [ 81%]
tests/unit/torch/block/test_base.py .... [ 81%]
tests/unit/torch/block/test_mlp.py . [ 81%]
tests/unit/torch/features/test_continuous.py .. [ 82%]
tests/unit/torch/features/test_embedding.py .............. [ 84%]
tests/unit/torch/features/test_tabular.py .... [ 85%]
tests/unit/torch/model/test_head.py ............ [ 87%]
tests/unit/torch/model/test_model.py .. [ 87%]
tests/unit/torch/tabular/test_aggregation.py ........ [ 89%]
tests/unit/torch/tabular/test_tabular.py ... [ 89%]
tests/unit/torch/tabular/test_transformations.py ....... [ 91%]
tests/unit/utils/test_schema_utils.py ................................ [ 96%]
tests/unit/xgb/test_xgboost.py ................... [100%]

=============================== warnings summary ===============================
../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:36: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
'nearest': pil_image.NEAREST,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:37: DeprecationWarning: BILINEAR is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BILINEAR instead.
'bilinear': pil_image.BILINEAR,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:38: DeprecationWarning: BICUBIC is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BICUBIC instead.
'bicubic': pil_image.BICUBIC,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:39: DeprecationWarning: HAMMING is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.HAMMING instead.
'hamming': pil_image.HAMMING,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:40: DeprecationWarning: BOX is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.BOX instead.
'box': pil_image.BOX,

../../../../../usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41
/usr/local/lib/python3.8/dist-packages/keras/utils/image_utils.py:41: DeprecationWarning: LANCZOS is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.LANCZOS instead.
'lanczos': pil_image.LANCZOS,

tests/unit/datasets/test_ecommerce.py::test_synthetic_aliccp_raw_data
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-True-8]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-10]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-9]
tests/unit/tf/test_dataset.py::test_tf_drp_reset[100-False-8]
tests/unit/tf/test_dataset.py::test_tf_catname_ordering
tests/unit/tf/test_dataset.py::test_tf_map
/usr/local/lib/python3.8/dist-packages/cudf/core/frame.py:384: UserWarning: The deep parameter is ignored and is only included for pandas compatibility.
warnings.warn(

tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_matrix_factorization.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/blocks/retrieval/test_two_tower.py::test_matrix_factorization_embedding_export
tests/unit/tf/inputs/test_embedding.py::test_embedding_features_exporting_and_loading_pretrained_initializer
/var/jenkins_home/workspace/merlin_models/models/merlin/models/tf/inputs/embedding.py:768: DeprecationWarning: This function is deprecated in favor of cupy.from_dlpack
embeddings_cupy = cupy.fromDlpack(to_dlpack(tf.convert_to_tensor(embeddings)))

tests/unit/tf/core/test_index.py: 4 warnings
tests/unit/tf/models/test_retrieval.py: 53 warnings
tests/unit/tf/prediction_tasks/test_next_item.py: 3 warnings
tests/unit/tf/predictions/test_dot_product.py: 2 warnings
tests/unit/tf/utils/test_batch.py: 2 warnings
/tmp/autograph_generated_file9ef4l3st.py:8: DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead
ag
.converted_call(ag__.ld(warnings).warn, ("The 'warn' method is deprecated, use 'warning' instead", ag__.ld(DeprecationWarning), 2), None, fscope)

tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.1]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.3]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.5]
tests/unit/tf/data_augmentation/test_noise.py::test_stochastic_swap_noise[0.7]
tests/unit/tf/models/test_base.py::test_model_pre_post[True]
tests/unit/tf/models/test_base.py::test_model_pre_post[False]
/usr/local/lib/python3.8/dist-packages/tensorflow/python/util/dispatch.py:1082: UserWarning: tf.keras.backend.random_binomial is deprecated, and will be removed in a future version.Please use tf.keras.backend.random_bernoulli instead.
return dispatch_target(*args, **kwargs)

tests/unit/torch/block/test_mlp.py::test_mlp_block
/var/jenkins_home/workspace/merlin_models/models/tests/unit/torch/_conftest.py:151: UserWarning: Creating a tensor from a list of numpy.ndarrays is extremely slow. Please consider converting the list to a single numpy.ndarray with numpy.array() before converting to a tensor. (Triggered internally at ../torch/csrc/utils/tensor_new.cpp:201.)
return {key: torch.tensor(value) for key, value in data.items()}

tests/unit/xgb/test_xgboost.py::test_without_dask_client
tests/unit/xgb/test_xgboost.py::TestXGBoost::test_music_regression
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs0-DaskDeviceQuantileDMatrix]
tests/unit/xgb/test_xgboost.py::test_gpu_hist_dmatrix[fit_kwargs1-DaskDMatrix]
tests/unit/xgb/test_xgboost.py::TestEvals::test_multiple
tests/unit/xgb/test_xgboost.py::TestEvals::test_default
tests/unit/xgb/test_xgboost.py::TestEvals::test_train_and_valid
tests/unit/xgb/test_xgboost.py::TestEvals::test_invalid_data
/var/jenkins_home/workspace/merlin_models/models/merlin/models/xgb/init.py:264: UserWarning: Ignoring list columns as inputs to XGBoost model: ['item_genres', 'user_genres'].
warnings.warn(f"Ignoring list columns as inputs to XGBoost model: {list_column_names}.")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
SKIPPED [1] tests/unit/implicit/init.py:18: could not import 'implicit': No module named 'implicit'
SKIPPED [1] tests/unit/lightfm/init.py:18: could not import 'lightfm': No module named 'lightfm'
SKIPPED [1] tests/unit/datasets/test_advertising.py:20: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:62: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:78: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [1] tests/unit/datasets/test_ecommerce.py:92: ALI-CCP data is not available, pass it through env variable $DATA_PATH_ALICCP
SKIPPED [3] tests/unit/datasets/test_entertainment.py:44: No data-dir available, pass it through env variable $INPUT_DATA_DIR
SKIPPED [2] ../../../../../usr/local/lib/python3.8/dist-packages/tensorflow/python/framework/test_util.py:2746: Not a test.
=========== 562 passed, 11 skipped, 99 warnings in 777.10s (0:12:57) ===========
Performing Post build task...
Match found for : : True
Logical operation result is TRUE
Running script : #!/bin/bash
cd /var/jenkins_home/
CUDA_VISIBLE_DEVICES=1 python test_res_push.py "https://api.GitHub.com/repos/NVIDIA-Merlin/models/issues/$ghprbPullId/comments" "/var/jenkins_home/jobs/$JOB_NAME/builds/$BUILD_NUMBER/log"
[merlin_models] $ /bin/bash /tmp/jenkins4006269899221654371.sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants