Due to the use of yapf in the code prettification step, the following are new minor style issues:
d2l.plt.scatter(d2l.numpy(features[:, 1]), d2l.numpy(labels), 1); will become d2l.plt.scatter(features[:, (1)].asnumpy(), labels.asnumpy(), 1), where the trailing semicolon (useful for showing figures only in notebooks) is trimmed and 1 is surrounded with unnecessary parentheses.
yapf may unnecessarily produce two empty lines instead of one empty line (space inefficient for physical books):
yapf may unnecessarily produce empty lines within our import blocks (space inefficient for physical books):
Thanks to https://github.com/d2l-ai/d2l-book/commit/06ce6657f279af162da845dd3d771ae6a61f1700, now D2L replaces fluent alias (e.g., d2l.reshape(a, (1,2)) -> a.reshape((1,2))) correctly!
Due to the use of
yapf
in the code prettification step, the following are new minor style issues:d2l.plt.scatter(d2l.numpy(features[:, 1]), d2l.numpy(labels), 1);
will becomed2l.plt.scatter(features[:, (1)].asnumpy(), labels.asnumpy(), 1)
, where the trailing semicolon (useful for showing figures only in notebooks) is trimmed and1
is surrounded with unnecessary parentheses.yapf
may unnecessarily produce two empty lines instead of one empty line (space inefficient for physical books):yapf
may unnecessarily produce empty lines within our import blocks (space inefficient for physical books):