given split proportions checks if should split Examples: >>> should_split([10,0,0]) False >>> should_split([1,.1,.2]) True
(split)
| 27 | TEST_DATA = 2 |
| 28 | |
| 29 | def should_split(split): |
| 30 | """ |
| 31 | given split proportions checks if should split |
| 32 | Examples: |
| 33 | >>> should_split([10,0,0]) |
| 34 | False |
| 35 | >>> should_split([1,.1,.2]) |
| 36 | True |
| 37 | """ |
| 38 | return max(split)/sum(split) != 1. |
| 39 | |
| 40 | def get_ext(path): |
| 41 | """gets path extension""" |