File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ * text =auto eol =lf
Original file line number Diff line number Diff line change @@ -364,6 +364,36 @@ def scale(
364364
365365 return target
366366
367+ def scale_tech_node (self , target : float , default : float ) -> float :
368+ """
369+ Scales the tech node of the component to the given target.
370+
371+ Parameters
372+ ----------
373+ target: float
374+ The target tech node.
375+ default: float
376+ The default tech node.
377+
378+ Returns
379+ -------
380+ The scaled tech node.
381+ """
382+ from hwcomponents .scaling import (
383+ tech_node_area ,
384+ tech_node_energy ,
385+ tech_node_latency ,
386+ tech_node_leak ,
387+ )
388+ return self .scale (
389+ "tech_node" ,
390+ target , default ,
391+ tech_node_area ,
392+ tech_node_energy ,
393+ tech_node_latency ,
394+ tech_node_leak ,
395+ )
396+
367397 @classmethod
368398 def get_action_names (cls ) -> List [str ]:
369399 """
You can’t perform that action at this time.
0 commit comments