improve BDS 50 and 60 inference

This commit is contained in:
Junzi Sun
2020-08-05 18:38:12 +02:00
parent 1f15a953e3
commit 93fc536926
5 changed files with 30 additions and 12 deletions

View File

@@ -46,7 +46,7 @@ def bds_info(BDS, m):
)
else:
info = None
info = []
return info
@@ -87,5 +87,5 @@ def commb_decode_all(df, n=None):
if __name__ == "__main__":
commb_decode_all(df=20, n=100)
commb_decode_all(df=21, n=100)
commb_decode_all(df=20, n=500)
commb_decode_all(df=21, n=500)

View File

@@ -17,8 +17,8 @@ def test_bds_infer():
def test_bds_is50or60():
assert bds.is50or60("A0001838201584F23468207CDFA5", 0, 0, 0) == None
assert bds.is50or60("A0000000FFDA9517000464000000", 182, 237, 1250) == "BDS50"
assert bds.is50or60("A0000000919A5927E23444000000", 413, 54, 18700) == "BDS60"
assert bds.is50or60("A8001EBCFFFB23286004A73F6A5B", 320, 250, 14000) == "BDS50"
assert bds.is50or60("A8001EBCFE1B29287FDCA807BCFC", 320, 250, 14000) == "BDS50"
def test_surface_position():