And much more. All these key points are focused toward the development of a software engineer, as he gets to understand how to develop a vital piece of software. For the time being, I have just started out with Python development. Before you start asking me, why I did that:

Long story short, Python is a great language to learn and sometime fun when your C# or C++ code is no longer building. However, if you want to upgrade your skills to a professional Python developer, because Python developers also earn, the developer for Visual Studio Code Python extension was hired by Microsoft. Read the full story at Python Engineers team blog post on MSDN. And,

PyCharm and Visual Studio Code



Figure 1: PyCharm vs Visual Studio Code; sorry for small VS Code icon, didn't mean any harm.

Performance Extensions Virtual Environment support Resource consumption Problems

Performance

In the performance part, I can straight away suggest that Visual Studio Code is a winner, but that won't work out quite well. Visual Studio Code is an extremely lightweight IDE, whereas PyCharm has somewhat backend services and modules that are needed to load before the IDE can start. They can be given the benefit of the doubt, but one can easily ask for the benefits of a long load time.





On average, PyCharm has been reported to have extremely slow load time. Visual Studio Code on the other hand is really fast, and loads in less time. The modular approach of Code helps it in the performance race. Moreover, since Visual Studio Code depends heavily on extensions and add-ons, the projects and other libraries do not get loaded until they are needed to be loaded for the developers.





TypeScript, Python, Java and other similar libraries load as needed. Such as, when you open a file with type for Java program, your Red Hat Java extension will kick in. Same case for C# or Python files. This gives Visual Studio Code a good ranking when it comes to performance. Lastly, the delay in rest would be a fault of the extension and how it works.





If you still want to consider PyCharm for development: You are more than welcome, however this post would help you even improve the load time of PyCharm by converting it to Power Save mode and to load less amount of resources at the startup.

Extensions

I am not saying, only Visual Studio Code has extensions, PyCharm and almost every other IDE has some ways to extend the functionality beyond the "compile and run". The marketplace for both of the IDEs support quite a plethora of extensions to bring more features and services.

PyCharm: https://plugins.jetbrains.com/pycharm

Visual Studio Code: https://marketplace.visualstudio.com/vscode Both the communities have a good support available. But in this case, since Visual Studio Code is a modular IDE, it can be converted to a full-featured IDE for any framework/platform/language. Whereas PyCharm is tailored solution for Python developers, and you might be needed to download and setup other IDEs such as IntelliJ for Java, and CLion for C/C++ programming.





Visual Studio Code, only needs to know what type of project you are currently in and will enable those plugins making it an IDE for that project. Sounds good, right?

Virtual Environment support

This is an interesting portion. In Python, virtual environments play a huge amount of role in the overall development of libraries and experiments. I am not going to dig deeper in the concepts of virtual environment, merely suggest that you need to learn some basics of Anaconda or other virtual environment creation tool for Python projects.





Now, the main concept in the virtual environments is to select a different interpreter and then target that one for the current project. Unlike other installations, such as for C++ compilers or C# build systems, this is a great feature for developers targeting different projects, where a different version of Python or Python packages is needed. Anyways, the following are the steps taken in both the IDEs to work around with the virtual environments,





Starting with Visual Studio Code, the IDE supports the CTRL + SHIFT + P hotkeys to configure the properties and bring out most common settings and tasks pane for you. There you can select the "Python Interpreter" and then select the interpreter that you want to select.







Figure 2: CTRL + SHIFT + P options.







Figure 3: Selection of Python interpreter in Visual Studio Code.





Now, notice here, in PyCharm, on the other hand the process is somehow same, you can add the virtual environments and set their interpreters as the default.



Figure 4: Selection of Python interpreter in PyCharm.





The main problem with these environments is that they are mainly slow. A lot slow. You get same time delays in both the IDEs whcih is mainly due to the interpreter, Visual Studio Code and PyCharm -- so they both do not win, nor lose. For instance, have a look here,







Figure 5: Code execution in Visual Studio Code.





This simple task took this much time, however executing the same command with Anaconda's Python 3.6, takes the time down to almost 0.08 seconds. But that is a different story in itself. In this case, I would recommend not switching the IDE but the interpreter or the source code which makes the run take more time.

Resource Consumption

Lastly, you need to double check whether an IDE would be suitable to run on your machine or not. Such as, when you want to build an Android app, you are scared of what Android Studio would do to your machine, aren't you?





Same is the case here, the IDEs at hand, should be soft at our machines otherwise they will become a pain at the development themselves.



Figure 6: Resource consumption of Visual Studio Code and PyCharm.





Likewise, the programs both although serve the same purpose and as seen in the image above, they both have the same amount of projects open. They are both utilizing the CPU and RAM differently. Now it can be debated that PyCharm provides more services, such as context analysis, code analysis and other suggestions. But Visual Studio Code's Python extension is also smart enough and in many ways faster to provide intellisense and the overview of what a function/object is about.



In my own opinion, Visual Studio Code is a winner in resource management. IntelliJ is really bad at producing the IDE with better resource management; Android Studio, IntelliJ IDEA are just a few of such examples. Providing context analysis, is not an excuse for overuse of the memory and CPU.

Problems

So that was for basics and introduction. Now the real stuff beings. Python can be programmed in so many ways, you can use your text editor and then do a simple, to execute the code. You can then extend the support to virtual environments and use other IDEs such as Spyder or interactive shells, IPython let's say. But for hardcore Python programming, you need something more than just a text-editor, Python interpreter and a linter.PyCharm by IntelliJ and Visual Studio Code by Microsoft are the two primary IDEs that I keep using for Python development. Both IDEs support basic Python development, autocomplete suggestions, linters and extensibility of the IDE to support custom toolchains during development. I used Visual Studio Code a few months ago and I was let down,. Then, I shifted my interests to PyCharm for a while. But, (as with anyone who has ever used PyCharm, IntelliJ IDEA, Android Studio or any similar IDE by IntelliJ; and yes I have not used the CLion, so I cannot say anything for it but data suggests it's no different) you know that PyCharm is a memory and CPU hog. I cannot afford my machine to go down even for a minute, thus it kept itching deep in my mind to change the IDE. I can afford to go to plain text editor if I have to, but I cannot afford my machine getting stuck. Anyways, that is when I started testing PyCharm vs. Visual Studio Code battles and in most cases Visual Studio Code won my heart again; I am talking aboutand theSo, in this post I am going to cover up a few things that would guide you in better selection of an IDE — in no way I mean to make any personal or biased statement, I will only share what I feel like.Post will contain following sections,