Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upAllow one to forward features to predictions #114
Comments
|
@jankrynauw Thank you for the feature request. This looks like it could be implemented in a way similar to Unfortunately, we don't have much time to add this ourselves, but if anyone has cycles to a PR, they are very welcome. |
|
@jankrynauw Can you send me the code you were working on so that I can test it and work on it. |
|
See the
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment


We would like to forward a particular 'key' column which is part of the features to appear alongside the predictions - this is to be able to identify to which set of features a particular prediction belongs to. Here is an example of predictions output using the tensorflow.contrib.estimator.multi_class_head:
We would therefore like to add a key attribute to this prediction.
estimator = tf.contrib.estimator.forward_features(estimator, ['key'])gives the following error:
The adanet.Estimator's model_fn should not be called directly in TRAIN mode, because its behavior is undefined outside the context of its train method.The current workaround is to subclass the
head