Modular nvmsgbroker pipeline#95
Merged
Merged
Conversation
added 3 commits
November 2, 2025 14:32
- Refactored buffer_probe into process_tensor_operations and create_message_metadata - Fixed Consumer Dockerfile path: database/consumer.py - End-to-end testing successful: Pipeline → nvmsgbroker → MQTT → Consumer → MongoDB - Ready for code reuse in future pipelines
lyuzinmaxim
reviewed
Nov 3, 2025
| l_user = l_user.next | ||
| return classification_results | ||
|
|
||
| def create_message_metadata(batch_meta, frame_meta, frame_number, classification_results): |
Collaborator
There was a problem hiding this comment.
this function isn't just creating - it also adds new info in-place. Please change the name to represent this
lyuzinmaxim
reviewed
Nov 3, 2025
Comment on lines
+34
to
+37
| probs = np.ctypeslib.as_array(ptr, shape=(83,)) | ||
| exp_probs = np.exp(probs - np.max(probs)) | ||
| normalized_probs = exp_probs / np.sum(exp_probs) | ||
| top_indices = np.argsort(normalized_probs)[-5:][::-1] |
Collaborator
There was a problem hiding this comment.
this seems to me also as a standalone function
lyuzinmaxim
reviewed
Nov 3, 2025
- Added type hints to all functions - Renamed create_message_metadata to create_and_add_message_metadata - Extracted apply_softmax_normalization as separate function - Added docstrings for better code documentation - Updated documentation with simplified script paths
lyuzinmaxim
approved these changes
Nov 4, 2025
This was referenced Nov 12, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Task #91: Make nvmsgbroker_pipeline modular for future use
Changes Made:
buffer_probefunction into two separate modular functions:process_tensor_operations()- handles tensor processing, softmax normalization, and classificationcreate_message_metadata()- creates nvmsgbroker metadata for MQTT transmissionconsumer.pytodatabase/consumer.pyTesting:
✅ End-to-end testing completed successfully:
Benefits:
DoD Completed:
✅ Modular probe function working in the same way as before
Closes #91