Skip to content

Commit 7e81b82

Browse files
committed
Update README
1 parent ba062c5 commit 7e81b82

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

README.md

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ Simple CLI tool to read `TensorFlow` `TFRecords`.
55
## Install
66

77
### MacOs
8+
89
```bash
910
brew tap spotify/public
1011
brew install tfreader
@@ -16,7 +17,7 @@ Right now we only have binaries available under [releases](https://github.com/sp
1617

1718
## Usage
1819

19-
```
20+
```bash
2021
tfr
2122
Usage: tfr [options] <files? | STDIN>
2223
--usage <bool>
@@ -29,12 +30,28 @@ Usage: tfr [options] <files? | STDIN>
2930
Number of records to output
3031
```
3132

32-
### Example
33+
## Examples
34+
35+
#### Google Cloud Storage
36+
37+
```bash
38+
tfr -n 1 gs://<bucket>/<path>/part-00000-of-00004.tfrecords | jq .
39+
```
40+
41+
#### Local Filesystem
3342

3443
```bash
3544
tfr -n 1 core/src/test/resources/part-00000-of-00004.tfrecords | jq .
3645
```
3746

47+
#### `stdin`
48+
49+
```bash
50+
cat core/src/test/resources/part-00000-of-00004.tfrecords | tfr -n 1 | jq .
51+
```
52+
53+
### Output Example
54+
3855
```json
3956
{
4057
"features": {

0 commit comments

Comments
 (0)