Skip to content

Conversation

@Jim-Salmons
Copy link
Contributor

The current version of the Deep Learning Parsing example Notebook lacks the inplace=True parameter on the sort method call to the Layout instance in the left Interval. The master version's large block of image data shows these TextBlock's ids in top-down sequential order. Running the Notebook as written, however, will refresh the Notebook page image with out of sequence ids due to the default of the inplace parameter being False. The current master Notebook will produce the following image post-refresh:
actual-dlp-example-img
For instructional clarity, this version also casts the right_blocks variable as a Layout instance initialized with the TextBlock instances not in the left Interval and with inplace=True to ensure the intended sort sequencing of block ids.

A few non-essential additions to the source comments are added relative to the changes described.

Please note: At 70 years of age, this is my first PR to a public repository. I started my career with no CompSci or engineering experience as a Control Data PLATO developer. I then spent the bulk of my career in Programmer Nirvana as a Smalltalk developer on small teams with brilliant engineers who did all the necessary heavy lifting of integration and testing while I got to explore the nether regions of proof-of-concept ideas. So this is truly a learning experience for me. Any pointers or advice to make this PR useful and acceptable will be greatly appreciated.

The current version of the Deep Learning Parsing example Notebook lacks the 'inplace=True' parameter on the sort method call to the Layout instance in the left Interval. This version's large block of image data shows these TextBlock's ids in top-down sequential order. Running the Notebook as written, however, will refresh the Notebook page image with out of sequence ids due to the default of the inplace parameter being False.

For instructional clarity, this version casts the right_blocks variable as a Layout instance initialized with the TextBlocks not in the left Interval and with inplace=True.

A few non-essential additions to the source comments are added relative to the changes described.
The current version of the Deep Learning Parsing example Notebook lacks the 'inplace=True' parameter on the sort method call to the Layout instance in the left Interval. This version's large block of image data shows these TextBlock's ids in top-down sequential order. Running the Notebook as written, however, will refresh the Notebook page image with out of sequence ids due to the default of the inplace parameter being False.

For instructional clarity, this version casts the right_blocks variable as a Layout instance initialized with the TextBlocks not in the left Interval and with inplace=True.

A few non-essential additions to the source comments are added relative to the changes described.
@lolipopshock
Copy link
Member

lolipopshock commented Jan 12, 2022

Thank you for the updates, @Jim-Salmons ! I added some minor tweaks to your updates to minimize the unnecessary/hidden Jupyter Notebook changes. But other than that all looks great!

@lolipopshock lolipopshock merged commit 6651da5 into Layout-Parser:master Jan 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants