MCPcopy Index your code
hub / github.com/plotly/plotly.py / _process_pHYs

Method _process_pHYs

_plotly_utils/png.py:1778–1785  ·  view source on GitHub ↗
(self, data)

Source from the content-addressed store, hash-verified

1776 raise FormatError("sBIT chunk has incorrect length.")
1777
1778 def _process_pHYs(self, data):
1779 # http://www.w3.org/TR/PNG/#11pHYs
1780 self.phys = data
1781 fmt = "!LLB"
1782 if len(data) != struct.calcsize(fmt):
1783 raise FormatError("pHYs chunk has incorrect length.")
1784 self.x_pixels_per_unit, self.y_pixels_per_unit, unit = struct.unpack(fmt, data)
1785 self.unit_is_meter = bool(unit)
1786
1787 def read(self, lenient=False):
1788 """

Callers

nothing calls this directly

Calls 2

FormatErrorClass · 0.85
unpackMethod · 0.45

Tested by

no test coverage detected