graphscope.framework.app.load_app
- graphscope.framework.app.load_app(gar=None, algo=None, context=None, **kwargs)[source]
Load an app from gar. bytes or the resource of the specified path or bytes.
- Parameters
algo – str Algo name inside resource. None will extract name from gar resource if there is only one app in it.
gar – bytes or BytesIO or str str represent the path of resource.
- Returns
Instance of <graphscope.framework.app.AppAssets>
- Raises
FileNotFoundError – File not exist.
PermissionError – Permission denied of path.
TypeError – File is not a zip file.
Examples
>>> sssp = load_app(gar='./resource.gar', algo='sssp') >>> sssp(src=4)
- which will have following .gs_conf.yaml in resource.gar:
- app:
algo: sssp type: cpp_pie class_name: grape:SSSP context_type: vertex_data src: sssp/sssp.h compatible_graph:
gs::ArrowProjectedFragment