MCPcopy Index your code
hub / github.com/pyfa-org/Pyfa / getPoint

Method getPoint

graphs/data/base/graph.py:107–114  ·  view source on GitHub ↗
(self, x, miscInputs, xSpec, ySpec, src, tgt=None)

Source from the content-addressed store, hash-verified

105 return plotData
106
107 def getPoint(self, x, miscInputs, xSpec, ySpec, src, tgt=None):
108 cacheKey = self._makeCacheKey(src=src, tgt=tgt)
109 try:
110 y = self._pointCache[cacheKey][(ySpec, xSpec)][x]
111 except KeyError:
112 y = self._calcPoint(x=x, miscInputs=miscInputs, xSpec=xSpec, ySpec=ySpec, src=src, tgt=tgt)
113 self._pointCache.setdefault(cacheKey, {}).setdefault((ySpec, xSpec), {})[x] = y
114 return y
115
116 def clearCache(self, reason, extraData=None):
117 caches = (self._plotCache, self._pointCache)

Callers 2

_getPointMethod · 0.45
drawMethod · 0.45

Calls 2

_makeCacheKeyMethod · 0.95
_calcPointMethod · 0.95

Tested by

no test coverage detected