March 24th, 2022

H2O Wave Snippet Plugin for PyCharm

RSS icon RSS Category: Tutorials, Wave

Note: this blog post by Shamil Dilshan Prematunga was first published on Medium.

What is PyCham?

PyCharm is the most famous IDE among software developers who are working based on python language. It contains more features such as code analysis, graphical debugger, integrated unit tester, integrated version control system, and supports data science with Anaconda. It is also a cross-platform with Windows, macOS, and Linux versions.

Plugins in PyCharm

Plugins in PyCharm extend its core functionalities and give a smooth programming experience to the programmer. As an example, by using these plugins we can add some features such as coding assistance support for various languages and frameworks, shortcut hints, live previews, integration with version control systems, etc. In the plugin market space in PyCharm, we can find various plugins for different purposes.

Figure 1 – PyCharm Plugins Market Place

There are multiple ways to add plugins in PyCharm.

1. Install plugins from Marketplace

  • Open IDE settings and select Plugins.
  • Find plugins in the marketplace and click install.

2. Install plugin from disk

  • Download the plugin in ZIP or JAR format.
  • Open IDE settings and select Plugins.
  • Click on settings and then click “Install Plugin from Disk”.
  • Select the plugin archive file and click OK.
  • Click OK to apply changes and restart IDE.

Same as the install plugins we can remove or disable them in a project. This is also simple as installing plugins. To perform this, open the IDE settings and select plugins to list down installed plugins. Click on the one we need to remove or disable. In the plugin’s description pane click on Uninstall or Disable. Now it is done!

H2O Wave Plugin

We can define H2O wave as an open-source Python development framework used to develop real-time interactive AI apps. Having a plugin for this kind of platform will make it super easier for the developers who are working with wave application developments. With that perspective, H2O has released H2O Snippet as the plugin for PyCharm. It is available in the marketplace to directly install, or we can install it via this link. Once after installation, restart the IDE to effect the changes.

Figure 2 – H2O Wave Plugin in Market Place

Once after successful installation, we can use it super easily in PyCharm. All we need to do is create a Python file and start experiencing the easiness of the plugin. Typing the letter “w” at the very beginning of the python file will suggest us a list of things we can access via the plugin.

Figure 3 – Auto Suggestions

To demonstrate the easiness, I’ll show how we can interact with this plugin. In most of the applications, we have our header component. In the list of example codes suggested by the wave snippet plugin, we can find it there. After one click, the code will be loaded to the file. It is easy and we no need to code it from the scratch.

Figure 4 – Load Example Code

Another super cool thing that we can experience through this plugin is how easy to interact with cards and components. I’ll demonstrate it by extending the above code.

Now just think that you want to add a button in the wave application, but you don’t know how to apply it and what are the required fields. Here is the plugin with you. Just type “w_button” and see the suggestions.

Figure 5 – Element Auto Suggestions

“w_button” is the option with minimal conditions required to a button. If you need to customize the button with more features click on “w_full_button” which gives all supported attributes to edit.

Figure 6 – Suggest Elements with Full Attributes

Another benefit we can achieve by using the wave plugin is, it suggests all the icons we can use within the application. Therefore, we no need to spend our time searching for the availability of these items. It is demonstrated below by extending the same example used in the previous section.

Figure 7 – Auto Icon Suggestions

Another specific feature covered with this plugin is, it reminds us of what we already defined for a client within the code. We no need to remind all of them while we are working with a long codebase. As a demonstration of the above point, the code I used previously can be used as below.

Figure 8 – Auto Suggest Definitions

In this way, they made it easier for a developer to easily interact with features in H2O Wave by providing custom code snippets and advanced autocomplete features along with the PyCharm plugin.

Figure 9 – H2O Wave Plugin Summary

For more information regarding this content, you can refer to the below references.

Try this awesome plugin and witness how cool H2O Wave is.

About the Author

Shamil Prematunga

Shamil is a Software Engineer at H2O mainly working on wave application development to provide a better experience of AI to the users. He is passionate about delivering AI-based solutions to real-life problems and sharing them with the open-source community.

Leave a Reply

10 Consejos para Convertirte en un Científico de Datos Exitoso

En este mundo que no deja de cambiar y sorprendernos, como científicos de datos debemos

January 19, 2023 - by Favio Vázquez
Explaining models built in H2O-3 — Part 1

Machine Learning explainability refers to understanding and interpreting the decisions and predictions made by a

December 22, 2022 - by Parul Pandey
+ at NeurIPS 2022 is proud to participate in the 36th Conference on Neural Information Processing Systems (NeurIPS)

December 6, 2022 - by Marcos V. Conde
A Brief Overview of AI Governance for Responsible Machine Learning Systems

Our paper “A Brief Overview of AI Governance for Responsible Machine Learning Systems” was recently

November 30, 2022 - by Navdeep Gill, Abhishek Mathur and Marcos V. Conde
H2O World Dallas Customer Talks

After three long years of not having an #H2OWorld, we finally held our first one

November 24, 2022 - by Vinod Iyengar
New in Wave 0.24.0

Another Wave release has arrived with quite a few exciting new features. Let's quickly go

November 21, 2022 - by Martin Turoci

Request a Demo

Explore how to Make, Operate and Innovate with the H2O AI Cloud today

Learn More