def run_as_package_path(self):
        """Runs program as package specified with file path."""
        import runpy
        pkg_code = base_profile.get_package_code(
            self._run_object, name_is_path=True)
        with CodeHeatmapCalculator() as prof:
            for _, compiled_code in pkg_code.values():
                prof.add_code(compiled_code)
            try:
                runpy.run_path(self._run_object)
            except ImportError:
                raise CodeHeatmapRunError(
                    'Unable to run package %s' % self._run_object)
            except __HOLE__:
                pass
        return self._consodalidate_stats(pkg_code, prof)
dataset/ETHPy150Open nvdv/vprof/vprof/code_heatmap.py/CodeHeatmapProfile.run_as_package_path