Repository navigation
Conversation
|
@thuyen, thanks for your PR! By analyzing the history of the files in this pull request, we identified @danmane, @drpngx and @tensorflower-gardener to be potential reviewers. |
|
Can one of the admins verify this patch? |
|
@danmane knows best. |
|
Is there a need for the "prefix" argument? Why not just have the summary wrapper accept a string tensor as name, and convert it into a string? Adding prefix as another arg seems orthogonal to the main goal of the pr |
|
@danmane Could you tell me the function for |
|
I am still not sure if such function exists since |
|
What would the prefix be used for? Can't you achieve the same by wrapping the call to the summary in a name_scope? |
|
|
|
+1 for implementing some way of using string tensor as summary name. I frequently used the following scenario, where I want to measure accuracy on train/devel/test data (to appear in different graphs in TensorBoard): dataset_name = tf.placeholder(tf.string, [])
summary = tf.scalar_summary(self.dataset_name+"/accuracy", accuracy)That way I could use the same summary = session.run([summary], {dataset_name:"train" / "devel" / "test"})A |
|
+1 for passing an optional string/string tensor (but not prefix) as names. This would also resolve #6150 |
|
@dandelionmane is that the right way to go about this? |
|
@dandelionmane any advice on how to proceed here? |
|
@thuyen Thanks for the pull request, and sorry for the really slow review on my part. I think this is a fine proposal. I would just like more descriptive docstrings that explain why the new argument should be used. |
| tensor: A real numeric Tensor containing a single value. | ||
| collections: Optional list of graph collections keys. The new summary op is | ||
| added to these collections. Defaults to `[GraphKeys.SUMMARIES]`. | ||
| prefix: Optional string tensor |
There was a problem hiding this comment.
Optional string tensor. If provided, it will be a prefix to the summary's tag in TensorBoard.
teamdandelion
left a comment
There was a problem hiding this comment.
I'd like the docstring for "prefix" to explain how the prefix will be used. Otherwise, LGTM
|
Adding @martinwicke for API review triage, if needed. Also, a test is warranted here, probably. |
|
Please update it for the (tensor_summary)[https://github.com/tensorflow/tensorflow/blob/master/tensorflow/python/ops/summary_ops.py#L38] as well. This will be more tricky because the tensor_summary has a different implementation and things are a little inconsistent. In the long run, I think we may want to have all of the summaries set the node_name part of the summary protobuf according to the kernels' node name, and set the tag according to things like the prefix and the original text the user provided to the summary op (as opposed to the deduplicated, name-scope'd name) |
|
Why the solution here is prefix instead of just giving the whole string? Giving the whole string would also fix #6150 together |
|
@dandelionmane, what about @ppwwyyxx's comment? |
|
@dandelionmane any progress? |
|
@dandelionmane |
Old/Deprecated summary ops can accept
string tensorsfortags. The new summary interface only allowsstringsfornames(subsequently used as tags). This pull addsprefixoption, which can be astring tensor.This is important because sometimes we want to define the tags symbolically based on some conditions of input placeholders.