(p)
| 140 | |
| 141 | |
| 142 | def is_model_parallel_parameter(p) -> bool: |
| 143 | if hasattr(p, 'model_parallel') and p.model_parallel: |
| 144 | return True |
| 145 | |
| 146 | if hasattr(p, 'tensor_model_parallel') and p.tensor_model_parallel: |
| 147 | return True |
| 148 | |
| 149 | return False |
| 150 | |
| 151 | |
| 152 | def copy_to_device(item, device, criterion_func): |
no outgoing calls