Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add concat_tracks utility function #56

Merged
merged 11 commits into from Apr 16, 2021
Merged

Conversation

willgraf
Copy link
Contributor

concat_tracks joins several Track objects and returns the overall feature dict.

@willgraf willgraf merged commit 0280832 into graph_tracking_data Apr 16, 2021
@willgraf willgraf deleted the concat_tracks branch April 16, 2021 19:58
MekWarrior pushed a commit that referenced this pull request Apr 21, 2021
* Split code out into utility functions and use them in Track and est_feats.
* cv2 is no longer required as deepcell_toolbox.resize is used instead.
* Update docstrings
* Add tests for new utils.
* Update test_utils to not be protected
* Fix tests.
* Change dtypes to strings.
* Change coverage limit to 70% to pass tests.
* Need to initialize the shapes in case there are no labels.
* use cache=True in regionprops for MUCH faster perfomance (15min before, 6min after)
* Refactor a couple function names for readability.
* Add concat_tracks utility function (#56)
* Add new concatenate_tracks function.
* initialize shape in the for loop to allow generators to be passed
* Remove _pad_array and rename conacatenate_tracks to concat_tracks.
* Generators have no len
* Make Track attributes plural for consistency.
* Fix array insertion with the help of stackoverflow.
* Update TODO and move into funcitons/classes
* don't index on tracks, index on sum of batches.
* Change name back, get_features is overloaded.
* PEP8
* Fix default distance threshold.
* Fix dtypes in get_frame_features
* Fix indexing for frame features.
* Add optional tracked_data parameter that shortcuts loading if already loaded.
* fix multi-dim indexing
* create adj_matrix outside of get_frame_features.
* Distance should be counted for all cells, not just current track_ids.
* fix track indexing
* Fix adj_matrix calculation.
* missing batch dimension
* remove distance_threshold from get_image_features call
* Fix tests.
* Include batch dimension.
* remove troublesome debugging code
MekWarrior added a commit that referenced this pull request Jun 1, 2021
* create a track data structure to hold info and handle pre-processing
* init changes
* update var names and lint
* merge similar variables
* move helper function related to max label to base util
* move out common funcs to utils and clean up
* clear out old/invalid tests and update as req
* update tests and PEP8
* Explicitly call .predict
* Update encoder predict method
* update dummy encoder
* update model mocks
* add notes to encoder for troubleshooting
* clarify comments, stub out new tests, and fix cell_idx bug
* update cell mapping
* add dummy data gen functions for tests
* tighten up util func and add additional tests for max_cells and clean_up_annotations
* fix correctness test
* explicitly state uid and lint
* improve dummy data funcs
* pare down funcs and tests to find pred bug
* make members of self more obvious in init
* update desc and test for get max cell
* Fix predictions-slicing useing idx_to_id in _get_parent. (#52)
* track_idx and track_id are equal. Use idx_to_id (with frame) to get cell_id.
* change get parent behavior to more closely emulate what happened in old tracking.py
* add match_nodes functions and node_key to fix metrics issue
* Add benchmarking function to isbi util
* switch compute_overlap import and add deepcell toolbox dependency
* remove python 2 support
* Refactor tracking.py to remove unused code and improve readability. (#54)
* Fix _get_parent input name.
* update whitespace for readability
* Remove unused get_feature_shape
* Only store embeddings and centroids in features.
* Use the dict to validate inputs later.
* Put in a debugging line to test the KeyError in _get_parent.
* Pass relevant_tracks through the predictions_dict.
* test getting track_id from list of them by index.
* Be careful about matching track_id with predictions shape.
* Get a random feature and include the keys for current/future in predictions.
* only use track_ids used in the current_feature.
* enumerate over track_ids
* Move _get_annotated_movie into test_utils.py and ignore from coverage.
* Use _get_annotated_movie in tracking tests.
* Remove _get_dummy_tracking_data, buggy.
* Only fill relevant capped tracks, not all tracks.
* Update docstring and remove unused imports.
* make neigh encoder a named argument
* add embedding axis
* Pull code from `Track` object into helper functions with tests. (#55)
* Split code out into utility functions and use them in Track and est_feats.
* cv2 is no longer required as deepcell_toolbox.resize is used instead.
* Need to initialize the shapes in case there are no labels.
* use cache=True in regionprops for MUCH faster perfomance (15min before, 6min after)
* Add concat_tracks utility function (#56)
* Add new concatenate_tracks function.
* initialize shape in the for loop to allow generators to be passed
* Remove _pad_array and rename conacatenate_tracks to concat_tracks.
* don't index on tracks, index on sum of batches.
* Fix default distance threshold.
* Fix dtypes in get_frame_features
* Fix indexing for frame features.
* Add optional tracked_data parameter that shortcuts loading if already loaded.
* fix multi-dim indexing
* create adj_matrix outside of get_frame_features.
* Distance should be counted for all cells, not just current track_ids.
* fix track indexing
* Fix adj_matrix calculation.
* missing batch dimension
* remove distance_threshold from get_image_features call
* add test for match_nodes
* Change shape of feature arrays to use time as the first axis. (#57)
* Update feature arrays to use time as the first axis.
* Fix initialized feature shapes in _get_features.
* Stack the current features along the cell axis as they contain a time axis.
* Fix input shape for temporal adj matrix.
* Fix `normalize_adj_matrix` and add tests.
* Add test for concat_tracks.
* Remove the unused compute_distance function
* Remove commented out test stub.
* Increase frames and labels to get better randomized tests.
* Test Track initializers.

Co-authored-by: willgraf <7930703+willgraf@users.noreply.github.com>
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.

None yet

1 participant