MCPcopy
hub / github.com/CadQuery/cadquery / fromSP

Method fromSP

cadquery/occ_impl/nurbs.py:128–135  ·  view source on GitHub ↗

Helper for converting from any SciPy sparse array or matrix.

(cls, sparr: sp.sparray | sp.spmatrix)

Source from the content-addressed store, hash-verified

126
127 @classmethod
128 def fromSP(cls, sparr: sp.sparray | sp.spmatrix):
129 """
130 Helper for converting from any SciPy sparse array or matrix.
131 """
132
133 tmp = sparr.tocoo()
134
135 return cls(tmp.row, tmp.col, tmp.data, tmp.shape)
136
137
138class Curve(NamedTuple):

Callers 1

Calls

no outgoing calls

Tested by 1