@@ -735,7 +735,6 @@ def compute_entropy_limits( compute_entropy, bits, overlap, stride, threshold, s
735735 rejects .append ( reject )
736736 rejected = sum ( avg (list (rejects )[- n :]) for n in avg_over ) / len ( avg_over )
737737 if reject or i % checks == 0 :
738- #log.warning(
739738 ( log .info if i % checks == 0 else log .debug )(
740739 f" - { i :6} { threshold = :7.5f} : { 100 * rejected :7.3f} %; "
741740 + ', ' .join ( f"{ 100 * avg (list (rejects )[- n :]):7.3f} %/{ n } " for n in avg_over )
@@ -754,7 +753,7 @@ def test_shannon_limits( detailed=False ):
754753
755754 """
756755 shannon_limits = {}
757- strengths = (128 , 256 , 512 )
756+ strengths = (128 , 256 , 512 ) + ( 160 , 192 , 224 ) # SLIP-39 + BIP-39
758757 strides = (3 , 4 , 5 , 6 , 7 , 8 )
759758 overlapping = (False , True )
760759 cycles = 100001
@@ -798,7 +797,7 @@ def test_signal_limits( detailed=False ):
798797
799798 """
800799 signal_limits = {}
801- strengths = (128 , 256 , 512 )
800+ strengths = (128 , 256 , 512 ) + ( 160 , 192 , 224 ) # SLIP-39 + BIP-39
802801 strides = (3 , 4 , 5 , 6 , 7 , 8 )
803802 overlapping = (False , True )
804803 cycles = 100001
@@ -886,7 +885,7 @@ def test_poor_entropy():
886885
887886 analysis = analyze_entropy ( entropy )
888887 print ( f"Analysis of base-64 phrase: { analysis } " )
889- assert "Shannon entropy reduced at offset 5 in 41x 6-bit symbols" in analysis
888+ assert analysis and "Shannon entropy reduced at offset 5 in 41x 6-bit symbols" in analysis
890889
891890
892891def test_good_entropy ():
0 commit comments