xlnstorch.csrc.load_backend#
- xlnstorch.csrc.load_backend(build_dir=None, verbose=False, enable_cpp=True)#
Try to compile and load the C++ extension if it is not already built and loaded. If the extension is already loaded, this function exits and returns True.
- Parameters:
build_dir (Optional[str], optional) – Directory to use for building the extension. If None, a temporary directory is used.
verbose (bool, optional) – If True, enables verbose output during the build process.
enable_cpp (bool, optional) – If True, sets the C++ operators as the default implementations for LNS operations.
- Returns:
True if the C++ extension is successfully loaded, False otherwise.
- Return type: