-
-
Notifications
You must be signed in to change notification settings - Fork 30
Migrate timing code to quantecon Timer context manager from legacy patterns #391
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
Conversation
Co-authored-by: mmcky <8263752+mmcky@users.noreply.github.com>
tic
,tac
,toc
timers to new Timer context manager in the quantecon package
|
@copilot a new release of Can we please remove the fall back code as it is no longer needed. |
Co-authored-by: mmcky <8263752+mmcky@users.noreply.github.com>
Removed the Timer fallback code from both Warning Firewall rules blocked me from connecting to one or more addressesI tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
@copilot please remove the |
Co-authored-by: mmcky <8263752+mmcky@users.noreply.github.com>
Removed Warning Firewall rules blocked me from connecting to one or more addressesI tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Co-authored-by: mmcky <8263752+mmcky@users.noreply.github.com>
Found and converted all remaining instances of
All Warning Firewall rules blocked me from connecting to one or more addressesI tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
@copilot we have now updated the quantecon library in Can we please now update the Note: For |
Co-authored-by: mmcky <8263752+mmcky@users.noreply.github.com>
Successfully converted all
All patterns now use Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
@copilot is the Is it possible for me to update |
The
The current pattern The lambda pattern is actually quite readable in our current usage and is the Python best practice for this use case. |
@jstac what do you think about this style? The ![]() We need to fix:
|
@copilot can we please migrate all instances of using Also the |
…SciPy Co-authored-by: mmcky <8263752+mmcky@users.noreply.github.com>
Migrated all Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
This reverts commit 2ae4cbf.
@jstac this is looking good, we have migrated all We will setup reviews of the other lectures shortly. |
This PR completely migrates all timing code in the lecture series from legacy timing patterns to the new quantecon Timer context manager introduced in v0.9.0+.
Changes Made
Updated timing patterns across multiple lectures:
lectures/numba.md
: Migrated 6 instances of tic/toc usage to Timer context managerlectures/numpy.md
: Migrated 4 instances of tic/toc usage + 4 instances of %time/%%time to Timerlectures/parallelization.md
: Migrated 4 instances of %time/%%time to Timer + 3 instances from %timeit patternlectures/jax_intro.md
: Migrated 13 instances of %time/%%time to Timer context managerlectures/scipy.md
: Added quantecon import + migrated 2 instances from %timeit pattern using milliseconds for appropriate scaleMigration patterns:
Key Implementation Details
Validation
time1 / time3
still work correctly)The migration provides a cleaner, more consistent timing approach throughout the lecture series using the official quantecon Timer implementation while maintaining full functionality.
Fixes #390.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.