Skip to content

Commit

Permalink
Update a comment
Browse files Browse the repository at this point in the history
  • Loading branch information
kozlovsky committed Nov 1, 2022
1 parent 52d0e5d commit feb9b04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/tribler/core/utilities/search_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def seeders_rank(seeders: int, leechers: int = 0) -> float:
:return: the torrent rank based on seeders and leechers, normalized to the range [0, 1]
"""
sl = seeders + leechers * LEECHERS_COEFF
return sl / (100 + sl) # inf seeders -> 1; 100 seeders -> 0.5; 10 seeders -> approx 0.1
return sl / (100 + sl) # infinity seeders -> rank 1.0; 100 seeders -> rank 0.5; 10 seeders -> approximately 0.1


def freshness_rank(freshness: Optional[float] = 0) -> float:
Expand Down

0 comments on commit feb9b04

Please sign in to comment.