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

Update tf_records.pynb tutorial #767

Merged
merged 3 commits into from Jul 9, 2019

Conversation

Projects
None yet
6 participants
@8bitmp3
Copy link
Contributor

commented Jul 9, 2019

While studying how TensorFlow Datasets work and the TFRecord file format, I went through the Using TFRecords and tf.Example tutorial (r2, TF2 Beta1) and made a few changes in line with the Google Docs guide.

Suggestions include: fix minor typos in a file name (test.tfrecord without an "s" versus images.tfrecords with an "s" in the end), fix bullet point representation in markdown (replace "-" with "*"), fix the tense of a few verbs to be in a passive voice ("..es" -> "..ed"), capitalize a few letters (e.g. "TensorFlow"), use second person (change from "we" and "our" to "you" and "your"), add backticks/colons/commas where needed, change the copyright year to 2019, fix the "tensors" spelling, change a few paragraph structures to make them flow

Let me know if it's alright. Cheers

Update tf_records.pynb tutorial
Fix minor typos in a file name (`test.tfrecord` without an "s" versus `images.tfrecords`), fix bullet point representation in markdown (replace "-" with "*"), fix the tense of a few verbs to be in a passive voice, capitalize a few letters (e.g. "TensorFlow"), use second person (change from "we" and "our" to "you" and "your"), add backticks/colons/commas where needed, change copyright year to 2019

@8bitmp3 8bitmp3 requested review from brilee, lamberta and MarkDaoust as code owners Jul 9, 2019

@tfdocsbot

This comment has been minimized.

Copy link
Collaborator

commented Jul 9, 2019

Preview and run these notebook edits with Google Colab:

Notebook diffs available on ReviewNB.com.
Update tf_records.ipynb #2
More minor changes in addition to the previous commit: fix a closed parentheses in a tuple, add colons, change a few paragraph structures to make them flow, change "now" to "next, fix the "tensors" spelling

@googlebot googlebot added the cla: yes label Jul 9, 2019

@lamberta
Copy link
Member

left a comment

Great! Thank you. One quick note but looks good

@@ -1067,7 +1053,7 @@
"id": "Azx83ryQEU6T"
},
"source": [
"As we did earlier, we can now encode the features as types compatible with `tf.Example`. In this case, we will not only store the raw image string as a feature, but we will store the height, width, depth, and an arbitrary `label` feature, which is used when we write the file to distinguish between the cat image and the bridge image. We will use `0` for the cat image, and `1` for the bridge image."
"As you did earlier, you can now encode the features as types compatible with `tf.Example`. In this case, you will store the raw image string feature, as well as the height, width, depth, and arbitrary `label` feature. The latter is used when you write the file to distinguish between the cat image and the bridge image. Use `0` for the cat image, and `1` for the bridge image:"

This comment has been minimized.

Copy link
@lamberta

lamberta Jul 9, 2019

Member

Not your fault, but I'd remove you/we where possible and tell the reader what to do as simply as possible (there's kind of an implied "you" once established earlier in the page). Something like:
"As before, encode the features ..."
"This stores the raw ..."

This comment has been minimized.

Copy link
@8bitmp3

8bitmp3 Jul 9, 2019

Author Contributor

Thanks @lamberta , appreciate it. I went through the notebook once more and replaced the "you + [take action]" with instruction-like "[Take action]" where I thought it was more applicable. The Google docs style guide also helped. Cheers 👍

Update tf_records.ipynb #3
Remove second person where it is implied anyway as per @lamberta's suggestion
@lamberta
Copy link
Member

left a comment

Thank you!

@TensorFlow-Docs-Copybara TensorFlow-Docs-Copybara merged commit f13b903 into tensorflow:master Jul 9, 2019

2 of 3 checks passed

Ubuntu Sanity Check Internal CI build failed
Details
cla/google All necessary CLAs are signed
import/copybara Change imported to the internal review system
Details

TensorFlow-Docs-Copybara pushed a commit that referenced this pull request Jul 9, 2019

Copybara-Service
Merge pull request #767 from 8bitmp3:patch-3
PiperOrigin-RevId: 257276067

@8bitmp3 8bitmp3 deleted the 8bitmp3:patch-3 branch Jul 13, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.