(string)
| 230 | |
| 231 | |
| 232 | def remove_right_units(string): |
| 233 | # "\\text{ " only ever occurs (at least in the val set) |
| 234 | if '\\text{ ' in string: |
| 235 | splits = string.split('\\text{ ') |
| 236 | assert len(splits) == 2 |
| 237 | return splits[0] |
| 238 | else: |
| 239 | return string |
| 240 | |
| 241 | |
| 242 | def fix_sqrt(string): |