Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there any plugin to simplify the preview of configuration? #7557

Closed
williamking5 opened this issue Mar 28, 2022 · 4 comments
Closed

Is there any plugin to simplify the preview of configuration? #7557

williamking5 opened this issue Mar 28, 2022 · 4 comments
Assignees

Comments

@williamking5
Copy link

Hi, thank you for great codes! I find the configuration files have really deep hierarchical structures, which is defined by _base_. This kind of design can promote reusing codes but make difficult to change and preview the configurations. For example, if I want to change some arguments, I have to search all _base_ configurations, and it is time-consuming.

For python, plugins such as Pylance have been developed for IDEs to help dive into the codes but mmdet-style configurations are not supported by these plugins. I wonder if there is some plugins that can help preview configurations? Thank you very much!

@Czm369
Copy link
Collaborator

Czm369 commented Mar 29, 2022

Sorry, I do not know whether there exits some plugins that can help preview configurations.
But we are supporting replacing ${key} with the value of cfg.key
#7492

@shinya7y
Copy link
Contributor

VSCode extension Open file is useful, although it is not for preview.
https://marketplace.visualstudio.com/items?itemName=Fr43nk.seito-openfile

This extension enables the user to open a file under the current cursor position. Just right-click on a pathname within a open document and select the open file under cursor option (or just press Alt + P without right-click). If the file is found by vscode then it will open a new tab with this file.

@shinya7y
Copy link
Contributor

print_config.py prints the whole config.
We can run it by F5 or Ctrl+F5 after editing the launch.json of VSCode.

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: mmdet print_config",
            "type": "python",
            "request": "launch",
            "program": "${cwd}/tools/misc/print_config.py",
            "args": ["${file}"],
            "console": "integratedTerminal",
            "justMyCode": true
        }
    ]
}

@williamking5
Copy link
Author

Thank you! I've tried these tools, and they are useful for me:)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants