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

Feat/support learn & review limit #609

Merged
merged 1 commit into from
Feb 8, 2024

Conversation

L-M-Sherlock
Copy link
Member

@L-M-Sherlock L-M-Sherlock added the enhancement New feature or request label Feb 8, 2024
@L-M-Sherlock L-M-Sherlock merged commit be753b2 into main Feb 8, 2024
@L-M-Sherlock L-M-Sherlock deleted the Feat/support-learn-&-review-limit branch February 8, 2024 03:41
@aleksejrs
Copy link

figs = optimizer.find_optimal_retention(
    deck_size=557,  # number of cards to learn
    learn_span=365,  # days to learn
    max_cost_perday=1800,  # seconds to review and learn per day
    learn_limit_perday=float("inf"),  # number of cards to learn per day
    review_limit_perday=float("inf"),  # number of cards to review per day
    max_ivl=36500,  # days
    loss_aversion=2.5,  # forget cost is multiplied by this factor to simulate loss aversion
)

Learn Count per Day is 31-32? Is that a floating average?

Untitled 1
Untitled 2
Untitled 3
Untitled 4
Untitled 5

learn_limit_perday=1.0
  0%|          | 0/365 [00:00<?, ?it/s]
 52%|█████▏    | 191/365 [00:00<00:00, 1899.90it/s]
                                                   /usr/local/lib/python3.10/dist-packages/fsrs_optimizer/fsrs_simulator.py:444: RuntimeWarning: invalid value encountered in double_scalars
  if abs(cost_per_memorization[i] - target2) < abs(
/usr/local/lib/python3.10/dist-packages/fsrs_optimizer/fsrs_simulator.py:445: RuntimeWarning: invalid value encountered in double_scalars
  cost_per_memorization[i + 1] - target2
/usr/local/lib/python3.10/dist-packages/fsrs_optimizer/fsrs_simulator.py:455: RuntimeWarning: invalid value encountered in double_scalars
  if abs(cost_per_memorization[i] - target3) < abs(
/usr/local/lib/python3.10/dist-packages/fsrs_optimizer/fsrs_simulator.py:456: RuntimeWarning: invalid value encountered in double_scalars
  cost_per_memorization[i + 1] - target3

---------------------------------------------------------------------------

ValueError                                Traceback (most recent call last)

<ipython-input-16-c93e450f7804> in <cell line: 1>()
----> 1 figs = optimizer.find_optimal_retention(
      2     deck_size=557,  # number of cards to learn
      3     learn_span=365,  # days to learn
      4     max_cost_perday=1800,  # seconds to review and learn per day
      5     learn_limit_perday=1.0,  # number of cards to learn per day

5 frames

/usr/local/lib/python3.10/dist-packages/matplotlib/axes/_base.py in _validate_converted_limits(self, limit, convert)
   3568             if (isinstance(converted_limit, Real)
   3569                     and not np.isfinite(converted_limit)):
-> 3570                 raise ValueError("Axis limits cannot be NaN or Inf")
   3571             return converted_limit
   3572 

ValueError: Axis limits cannot be NaN or Inf

@L-M-Sherlock
Copy link
Member Author

Please open a new issue to report the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants