Skip to content

simplify copy attr speed up metatensor#4714

Merged
wyli merged 17 commits intoProject-MONAI:devfrom
wyli:simple-copy
Jul 18, 2022
Merged

simplify copy attr speed up metatensor#4714
wyli merged 17 commits intoProject-MONAI:devfrom
wyli:simple-copy

Conversation

@wyli
Copy link
Copy Markdown
Contributor

@wyli wyli commented Jul 16, 2022

Description

remove the recursive deepcopy to speed up operations

this PR:
Screenshot 2022-07-16 at 13 27 09

dev branch:
Screenshot 2022-07-16 at 06 57 36

0.9.0:
Screenshot 2022-07-16 at 07 08 34

Status

Ready

Types of changes

  • Non-breaking change (fix or new feature that would not break existing functionality).
  • Breaking change (fix or new feature that would cause existing functionality to change).
  • New tests added to cover the changes.
  • Integration tests passed locally by running ./runtests.sh -f -u --net --coverage.
  • Quick tests passed locally by running ./runtests.sh --quick --unittests --disttests.
  • In-line docstrings updated.
  • Documentation updated, tested make html command in the docs/ folder.

wyli added 4 commits July 16, 2022 05:36
Signed-off-by: Wenqi Li <[email protected]>
Signed-off-by: Wenqi Li <[email protected]>
Signed-off-by: Wenqi Li <[email protected]>
Signed-off-by: Wenqi Li <[email protected]>
@wyli wyli requested review from Nic-Ma, ericspod and rijobro July 16, 2022 12:32
Signed-off-by: Wenqi Li <[email protected]>
@wyli wyli marked this pull request as ready for review July 16, 2022 12:45
Signed-off-by: Wenqi Li <[email protected]>
@wyli
Copy link
Copy Markdown
Contributor Author

wyli commented Jul 16, 2022

/black

wyli added 4 commits July 16, 2022 16:43
Signed-off-by: Wenqi Li <[email protected]>
Signed-off-by: Wenqi Li <[email protected]>
Signed-off-by: Wenqi Li <[email protected]>
@wyli wyli mentioned this pull request Jul 18, 2022
7 tasks
@wyli wyli requested a review from Nic-Ma July 18, 2022 07:44
wyli added 3 commits July 18, 2022 09:20
Signed-off-by: Wenqi Li <[email protected]>
Signed-off-by: Wenqi Li <[email protected]>
Signed-off-by: Wenqi Li <[email protected]>
@wyli
Copy link
Copy Markdown
Contributor Author

wyli commented Jul 18, 2022

/build

@wyli wyli enabled auto-merge (squash) July 18, 2022 21:46
@wyli
Copy link
Copy Markdown
Contributor Author

wyli commented Jul 18, 2022

/build

@wyli wyli merged commit 225fda4 into Project-MONAI:dev Jul 18, 2022
@wyli wyli deleted the simple-copy branch July 19, 2022 21:28
@rijobro
Copy link
Copy Markdown
Contributor

rijobro commented Jul 25, 2022

Hi, it seems like the difference in your screenshot is around 0.1s between slowest and fastest (1.93s vs 2.04s). Are we sure this isn't random fluctuations?

@wyli
Copy link
Copy Markdown
Contributor Author

wyli commented Jul 25, 2022

Yes @rijobro, I run python tests/test_integration_fast_train.py the total time is 30s vs 20s with my workstations, it's also the case for the relevant demos: Project-MONAI/tutorials#786 (comment).

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.

3 participants