Closed jawad5311 closed 2 years ago
Hi @jawad5311,
Thank you for your submission! I am working on a code update for TFX 1.4 at the moment.
FYI, @tf.function
is not necessary. Bug5 happens due to the comparison in the zipcode
function.
I'll push an update in the next hours.
Hi @jawad5311, Here is the updated code: https://github.com/Building-ML-Pipelines/building-machine-learning-pipelines/releases/tag/examples_based_on_tfx_1.4
Please reopen the issue if you run into issues. Thank you!
tensorflow==2.6.2 tfx==1.3.3
Environment: Google Colab
Bug 1
When importing
external_input
the following error occurs:Fix
ExampleGen
component can now accept the path to data directory as a stringRemove the line
from tfx.utils.dsl_utils import external_input
from the cellBug 2
When creating
CsvExampleGen
component, the following error occurs:Fix
CsvExampleGen
components parameterinput
is now changed toinput_base
Bug 3
When running the transform component using the following line
context.run(transform)
It throws the following error:
Fix
We need to decorate
convert_zip_code()
function with@tf.function
inmodule.py
Bug 4
After the upper fix the transform component throws an other error:
Fix
always_return_num_quantiles
arg oftft.bucketize
is deprecated in version 0.26 of tensorflow-transform.Remove or comment out the this argument from the function
tft.bucketize()
insidepreprocessing_fn()
inmodule.py
.Bug 5
After the upper fix, the transform component throws another error:
This error occurs as tensor returns the shape
None
and python cannot compareNoneType
withint
,float
, orstr
.I have tried to figure out where and why the tensor is returning shape None but it's over my head and can't figure out.