Skip to content

Commit

Permalink
Fix/<= review limit & learn limit (#80)
Browse files Browse the repository at this point in the history
  • Loading branch information
L-M-Sherlock authored Feb 8, 2024
1 parent e1fc9f6 commit 0168029
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "FSRS-Optimizer"
version = "4.24.0"
version = "4.24.1"
readme = "README.md"
dependencies = [
"matplotlib>=3.7.0",
Expand Down
2 changes: 2 additions & 0 deletions src/fsrs_optimizer/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,8 @@ def remembered_fallback_prompt(key: str, pretty: str = None):

if graphs_input.lower() != "y":
remembered_fallbacks["preview"] = "n"
else:
remembered_fallbacks["preview"] = "y"

with open(
config_save, "w+"
Expand Down
4 changes: 2 additions & 2 deletions src/fsrs_optimizer/fsrs_simulator.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ def stability_after_failure(s, r, d):
true_review = (
need_review
& (np.cumsum(card_table[col["cost"]]) <= max_cost_perday)
& (np.cumsum(need_review) < review_limit_perday)
& (np.cumsum(need_review) <= review_limit_perday)
)
card_table[col["last_date"]][true_review] = today

Expand Down Expand Up @@ -150,7 +150,7 @@ def stability_after_failure(s, r, d):
true_learn = (
need_learn
& (np.cumsum(card_table[col["cost"]]) <= max_cost_perday)
& (np.cumsum(need_learn) < learn_limit_perday)
& (np.cumsum(need_learn) <= learn_limit_perday)
)
card_table[col["last_date"]][true_learn] = today
first_ratings = np.random.choice(
Expand Down

0 comments on commit 0168029

Please sign in to comment.