Return the function applied to the outer product of a and b.
(self, a, b)
| 1136 | return masked_tr |
| 1137 | |
| 1138 | def outer(self, a, b): |
| 1139 | """ |
| 1140 | Return the function applied to the outer product of a and b. |
| 1141 | |
| 1142 | """ |
| 1143 | (da, db) = (getdata(a), getdata(b)) |
| 1144 | d = self.f.outer(da, db) |
| 1145 | ma = getmask(a) |
| 1146 | mb = getmask(b) |
| 1147 | if ma is nomask and mb is nomask: |
| 1148 | m = nomask |
| 1149 | else: |
| 1150 | ma = getmaskarray(a) |
| 1151 | mb = getmaskarray(b) |
| 1152 | m = umath.logical_or.outer(ma, mb) |
| 1153 | if (not m.ndim) and m: |
| 1154 | return masked |
| 1155 | if m is not nomask: |
| 1156 | np.copyto(d, da, where=m) |
| 1157 | if not d.shape: |
| 1158 | return d |
| 1159 | masked_d = d.view(get_masked_subclass(a, b)) |
| 1160 | masked_d._mask = m |
| 1161 | return masked_d |
| 1162 | |
| 1163 | def accumulate(self, target, axis=0): |
| 1164 | """Accumulate `target` along `axis` after filling with y fill |
nothing calls this directly
no test coverage detected