Skip to content

Commit 5a71493

Browse files
committed
enh: improve comments
1 parent a85f4a0 commit 5a71493

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

nibabel/streamlines/tck.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -270,10 +270,11 @@ def _write_header(fileobj, header):
270270
out = header[Field.MAGIC_NUMBER] + b"\n" + out.encode('utf-8')
271271

272272
# Compute data offset considering the offset string representation
273-
hdr_offset = len(out) + 8 + 3 + 3 # "file" header, END, and \n's
273+
# headers + "file" header + END + \n's
274+
hdr_offset = len(out) + 8 + 3 + 3
274275
offset_repr = f'{hdr_offset}'
275276

276-
# Adding the offset increases one char to the offset repr
277+
# Adding the offset may increase one char to the offset repr
277278
hdr_offset += len(f'{hdr_offset + len(offset_repr)}')
278279

279280
# Write header to file.

0 commit comments

Comments
 (0)