Skip to content

Commit a73cddd

Browse files
authored
minor syntax fixes in integration tests (#351)
1 parent 239cdad commit a73cddd

File tree

3 files changed

+4
-7
lines changed

3 files changed

+4
-7
lines changed

examples/Serving-Ranking-Models-With-Merlin-Systems.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1026,8 +1026,8 @@
10261026
"\n",
10271027
"# read in data for request\n",
10281028
"batch = df_lib.read_parquet(\n",
1029-
" os.path.join(original_data_path,\"valid\", \"part.0.parquet\"), num_rows=3, columns=workflow.input_schema.column_names\n",
1030-
")\n",
1029+
" os.path.join(original_data_path,\"valid\", \"part.0.parquet\"), columns=workflow.input_schema.column_names\n",
1030+
").head(3)\n",
10311031
"batch"
10321032
]
10331033
},

tests/integration/examples/test_serving_ranking_models_with_merlin_systems.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import os
22

33
import pytest
4-
54
from testbook import testbook
65

76
from tests.conftest import REPO_ROOT
@@ -97,9 +96,8 @@ def test_example_04_exporting_ranking_models(tb):
9796
# read in data for request
9897
batch = df_lib.read_parquet(
9998
os.path.join("/tmp/data/", "valid", "part.0.parquet"),
100-
num_rows=3,
10199
columns=workflow.input_schema.column_names,
102-
)
100+
).head(3)
103101
batch = batch.drop(columns="click")
104102
outputs = tb.ref("output_cols")
105103
from merlin.dataloader.tf_utils import configure_tensorflow

tests/integration/t4r/test_pytorch_backend.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@
3434

3535

3636
def test_serve_t4r_with_torchscript(tmpdir):
37-
3837
# ===========================================
3938
# Generate training data
4039
# ===========================================
@@ -107,7 +106,7 @@ def test_serve_t4r_with_torchscript(tmpdir):
107106
if name in input_schema.column_names:
108107
dtype = input_schema[name].dtype
109108

110-
df_cols[name] = tensor.cpu().numpy().astype(dtype)
109+
df_cols[name] = tensor.cpu().numpy().astype(dtype.name)
111110
if len(tensor.shape) > 1:
112111
df_cols[name] = list(df_cols[name])
113112

0 commit comments

Comments
 (0)