def __init__(
        self, target: str, path: str = None, uri: str = None, port: str = None
    ):
        r"""=

        Parameters
        ----------
        target : str
            target device name. CUDA or ROCM
        path : str, optional
            path to the database file. If not specified, a temporary file is created.
        uri : str, optional
            uri to the RESFul API (Not implemented yet)
        port : str, optional
            port to the RESFul API (Not implemented yet)

        """
        self._target = target
        self._mode = CacheMode.LOCAL
        self._db_commit_flag = False
        # Some design rationales:
        #   * All tables share the version number, because we are exposing the
        #     the cache version. Using a single version number seems to make it
        #     more clean. One caveat is that we are going to re-create all tables
        #     even if some of them are not involved with the breaking changes.
        #     It seems to be fine as we expect the frequency of cache version
        #     updated to be quite low.
        #   * We only keep a single table (i.e. version) for each category (
        #     gemm, conv and norm) to simplify how we handle breaking changes
        #     and rollbacks caused by failures in the updated version.
        #     For example, if we keep multiple versions (i.e. tables) for gemm,
        #     we would have to consider how we were going to maintain those versions.
        #     We could choose the old working version upon rollback, but we might
        #     leave some content from the failing version in the db. How are we
        #     going to update the db if we update the version again, and so on.
        # TODO: add similar version control for norm
        self._gemm_cache_version = ait_cache_version()
        self._conv_cache_version = ait_cache_version()
        self._conv3d_cache_version = ait_cache_version()
        if uri is not None:
            self._mode = CacheMode.REMOTE
        if self._mode == CacheMode.LOCAL:
            assert path is not None
            self._con = sqlite3.connect(path)
            self._cur = self._con.cursor()
            self._init_db()
        else:
            raise NotImplementedError
=

        Parameters
        ----------
        target : str
            target device name. CUDA or ROCM
        path : str, optional
            path to the database file. If not specified, a temporary file is created.
        uri : str, optional
            uri to the RESFul API (Not implemented yet)
        port : str, optional
            port to the RESFul API (Not implemented yet)

        
python/aitemplate/backend/profiler_cache.py