ONE-vscode icon indicating copy to clipboard operation
ONE-vscode copied to clipboard

[Meta Provider] Overview of Meta Provider

Open khlee025 opened this issue 2 years ago • 6 comments

Hello, we are team AndroMETA from SSAFY (Samsung SW Academy For Youth).

What

We suggests adding meta provider to one-vscode extension. Meta provider is a feature to provide information for each files. (https://github.com/Samsung/ONE-vscode/issues/1240) This contains three parts: Metadata viewer, Relation viewer, Metadata management.

Why

ONE Explorer offers limited information about files. The tree view of it depends on the configuration files only.
So that we think we need to store unchanged key information of files and make a method to access them anytime, anywhere.

How

1. Metadata is saved and managed using external hash object files.

File watcher of VScode triggers the managements of Metadata.

image

2. Metadata viewer show the key information of the file as a web view.

image image image

3. Relation viewer show the relationship of files using tree structure.

Child files are derived from parents model/circle files.

image

Our plan

Work List:

  • Metadata Viewer

    • [x] create MetadataViewerProvider
    • [x] create index.html
    • [x] create style.css
    • [x] create index.js for html
    • [x] add Command to open Metadata Viewer
    • [x] call api to get Metadata for Metadata viewer
    • [x] Add a folding function to make the data easier to see.
  • Relation Viewer

    • [x] create RelationViewerProvider
    • [x] create index.html
    • [x] create index.css
    • [x] create index.js for html
    • [x] add Command to open Relation Viewer
    • [x] call api to get Relation Data for Relation Viewer
    • [x] add logic to rerender relation viewer when node clicked
    • [x] create a function to group files of the same content through buttons on nodes
    • [x] create a function to right-click on the node to display the context menu. (Open file, show MetadataViewer)
    • [x] create a function to left-click(or double click) on the node to display relation of the node
    • [x] show toolchain/onecc version on node if it has them
  • Metadata Manager

    • [x] Create dummy files
    • [x] create API for Metadata Viewer
    • [x] create API for Relation Viewer
  • Event Management

    • [x] create file creation event with onDidCreateFiles API
    • [x] create file modification event with onDidChangeFile API
    • [x] create file deletion event with onDidDeletedFiles API
    • [x] add function of file creation event
    • [x] add operation information to metadata of circle
    • [x] add exception cases to file creation event

The project plan will be continuously updated.

khlee025 avatar Sep 15 '22 07:09 khlee025

You can put the plan(https://github.com/SSDC-AndroMETA/ONE-vscode/issues/4) here too :-D

dayo09 avatar Sep 15 '22 07:09 dayo09

just arrived~😊

chshin59 avatar Sep 15 '22 08:09 chshin59

Could you guys check the done-lists here?

dayo09 avatar Oct 06 '22 07:10 dayo09

FYI, when generating multiple quantization models from one tflite file...

디렉토리 캡쳐2

dayo09 avatar Oct 06 '22 07:10 dayo09

Thanks for your guys' hard works :-D.

BTW, I found the draft #1349 has a little bug. It doesn't show the relation properly, only a single node exists even if I generated a circle from the tflite.

If you can, could you revise the draft, and also provides some unit tests?

dayo09 avatar Oct 19 '22 11:10 dayo09

Thank you for your comments of this works.

We already recognize the similar problem. Can you check if the input/output path of config file(.cfg) is relative path? If so, could you test the draft with absolute input/output path?

We think the bug occurs when the input/output path of config file(.cfg) is relative path not absolute path. The bug is related to 'Relation.ts' but need more time to fix it... If you want to discuss more details about it, please talk with @smj53.

khlee025 avatar Oct 19 '22 12:10 khlee025