Master the basics of Conda environments in Python

Поделиться
HTML-код
  • Опубликовано: 13 июл 2020
  • Master the basics of conda environments in Python: create environments (from command-line and YAML files), get information on them, activate and deactivate, install extra packages, export environments into YAML for reproducibility. Conda is our favorite open-source package management and environment management system. It runs in Windows, macOS and Linux and allows users to easily install different versions of packages and libraries and switch between them.
  • НаукаНаука

Комментарии • 60

  • @amirshadmehr7752
    @amirshadmehr7752 2 года назад +3

    BEST tutorial ever. I had a hard time figuring out how to work with conda until watching this video. Thank you so much.

  • @Patiencelad
    @Patiencelad Год назад +2

    Erick. Thanks so much! This was a VERY helpful video and instructions, especially on the use of YML files. I plan to use what you taught today!

  • @kavyajeetbora2585
    @kavyajeetbora2585 2 года назад

    Thanks for the video. Now my confusion on conda virtual environments is cleared.

  • @RyanPu-js9gl
    @RyanPu-js9gl 2 года назад +3

    Great tutorial! Thanks for sharing this. One question: where are we supposed to find those yml files we wrote out. Can you give an example? Maybe the root folder of the Conda env? Thanks.

  • @williamgomez6087
    @williamgomez6087 3 года назад +1

    Perfectly explained¡ I really apreciate it so much¡

  • @davidcenteno8477
    @davidcenteno8477 3 года назад +1

    Thank you so much, great tutorial

  • @Rishu_Dakshin
    @Rishu_Dakshin 8 месяцев назад

    Your explaination over the topic is very clear. Thanks for the video and your hardwork. Appreciated😃😀

  • @dereckc
    @dereckc 2 года назад

    When creating a new environment do all packages from base carry over? Or is it a blank env. Alternatively should I clone the base env and then add all needed packages?

  • @tyswenson7542
    @tyswenson7542 2 года назад +1

    Great explanations. Enticing to use Anaconda more.

  • @QScientist
    @QScientist 2 года назад

    Thanks for the video. Question: if I update python version by creating new env, how I can add all the packages from old version but newer? So, maybe it can be done with creating yml file without explicit specifying version of libs? Instead numpy=0.25 just numpy? How to create this file?

  • @sukulmahadik0303
    @sukulmahadik0303 2 года назад

    Great video. Thank you.

  • @juleswombat5309
    @juleswombat5309 2 года назад

    Nice. I also prefer use Conda environment to native python virtual environment. I learn't a bit about yaml based Conda environment create package lists.
    Albeit I do get a little confused about any differences between Conda install packahes and Pip installed packages. They appear slightly different in Anaconda Navigator listing. I guess as they are sourced from different repositories.

  • @joshuantw
    @joshuantw 3 года назад +1

    Hi may I ask what is less? You used it to view the environment.yml file

  • @jeroen36
    @jeroen36 2 года назад

    My conda environment has pip installed but when I use the pip command (inside the conda environment) to install a package its installed inside my root instead of the environment. The command "which -a pip" shows me the path /usr/bin/pip and /bin/pip, but not the pip inside my conda environment. I tried adding the pip from my conda environment to my WSL2 PATH, but that doesn't work either. What do I do? How do I get pip to install my packages inside my conda environment?

  • @minyang497
    @minyang497 3 года назад +1

    Thank you

  • @stephanie_ong
    @stephanie_ong 3 года назад +3

    Thanks! I am new to Python environments and this tutorial helped me create one based on a Git repo I forked.

    • @koabraylen1142
      @koabraylen1142 2 года назад

      sorry to be off topic but does anybody know of a tool to get back into an Instagram account..?
      I was stupid lost the password. I would love any tricks you can offer me.

  • @AFCAjaxO
    @AFCAjaxO 2 года назад +1

    great vid. I have a problem - when trying to load an environment I have installed it tells me that it could not find the encironment. even though while doing conda info --envs I see the same name..

  • @drewfrench8784
    @drewfrench8784 Год назад

    Very helpful and simple.

  • @VishwasShukla12345
    @VishwasShukla12345 Год назад

    what would be the difference between packages under dependencies and packages under pip?

  • @azkarehman8366
    @azkarehman8366 3 года назад +1

    thanks alotttt love

  • @wigglyhoney6711
    @wigglyhoney6711 2 года назад +1

    very helpful.

  • @karinamatos4253
    @karinamatos4253 2 года назад

    How did you get out after the less environment.yml command? I can't go back.

  • @shivamdobariya63
    @shivamdobariya63 2 года назад

    Thanks man :)

  • @ludovikc2032
    @ludovikc2032 2 года назад

    How do I code after setting things up. I have every library I need but no way to code using those libraries

  • @namratadash123
    @namratadash123 3 года назад

    Hi, I am trying to install Mintpy. Can I try these?

  • @theyb7802
    @theyb7802 3 года назад

    I wish you've made this video couple of years ago) - would save me a lot of time if i'd stumble upon it earlier. But, at least now i know

    • @djuzla89
      @djuzla89 3 года назад

      Maybe he didn't know all those stuff back then :D

  • @sailfromsurigao
    @sailfromsurigao 3 года назад

    how to precompile a code from another computer to use in another computer

  • @Mahankalinikhil
    @Mahankalinikhil Год назад

    How can I do this in Windows Powershell instead of conda prompt?

  • @maneeshd247
    @maneeshd247 2 года назад

    I am getting condaHTTPError while creating new environment. I tried lot of steps, but it is not resolving. Anyone can help me out with this.

  • @HappyAnimals3D
    @HappyAnimals3D 3 года назад

    Would there be any differences on Windows machine at Anaconda prompt? I guess you are on a Linux machine if I am not mistaken.

    • @jacksonlaboratory
      @jacksonlaboratory  3 года назад

      I was running everything using Windows Subsystem for Linux (WSL), which is essentially a Linux virtual machine inside Linux. Your Anaconda prompt should be able to do the exact same things! -- Erick

  • @SaranyaS-yv3ud
    @SaranyaS-yv3ud Год назад

    I am getting Invalid archive error, and no such file or directory error, someone pls help

  • @techbays675
    @techbays675 2 года назад

    how to install conda new environment in Windows 10

  • @Kunal4980
    @Kunal4980 3 года назад

    Other day I was trying to create environment for my azure DataBricks and eventually created as well but could not use it pycharm if possible please come up with a video showing the same . Thanks

    • @jacksonlaboratory
      @jacksonlaboratory  3 года назад

      PyCharm automates a lot of the environment creation, both from scratch and from an yml file. You can check their documentation at www.jetbrains.com/help/pycharm/conda-support-creating-conda-virtual-environment.html . If you already have conda environments, PyCharm should be able to see them on their “interpreter selector” option. -- Erick

    • @Kunal4980
      @Kunal4980 3 года назад

      @@jacksonlaboratory My issue is specific to using DataBricks from pycharm because DataBricks does not have line by line debug facility and I could not find any video related with this issue

  • @kayeceedangca5214
    @kayeceedangca5214 3 года назад

    hi can ask how to change the prefix of the given .yml file in anaconda?

    • @jacksonlaboratory
      @jacksonlaboratory  3 года назад

      You can manually edit the .yml file in your text editor of choice to change the prefix. Most of the time you can safely delete that whole line altogether, in fact! I didn’t get into details because I was trying to keep the video short, but the exported .yml file we generated could be improved in a few other ways, like using the “--no-builds” option to make them more general. - Erick

  • @chaihanya
    @chaihanya 2 года назад +2

    when I use the command less test.yml, it says that
    less : The term 'less' is not recognized as the name of a cmdlet,
    function, script file, or operable program. Check the spelling of the
    name, or if a path was included, verify that the path is correct and try
    again.
    can u help me out with this?

    • @roeslib10
      @roeslib10 2 года назад

      how did you solve it? I have the same problem.

    • @chaihanya
      @chaihanya 2 года назад

      @@roeslib10 i am still working on it.

    • @roeslib10
      @roeslib10 2 года назад

      @@chaihanya thank you for your answer

    • @adi6516
      @adi6516 Год назад

      it is a linux command and he is using a linux terminal in the video.
      hope this helps

  • @maplebob23
    @maplebob23 3 года назад

    What's the first step here? How do you get to where you are in conda in the first place to be able to set the environment?

    • @jacksonlaboratory
      @jacksonlaboratory  3 года назад

      You will need to have Anaconda (or Miniconda) installed and start a prompt. The prompt you need will depend on your system - we briefly discuss different prompts and how to access them on the video. With a version of conda installed, your prompt should start at base environment already! - Erick

  • @jacquelingonza9685
    @jacquelingonza9685 2 года назад

    Seems like a great tutorial but I am on mac...

  • @StevenLangOfficial
    @StevenLangOfficial 8 месяцев назад +1

    does not work in miniforge prompt

  • @JorgeHernandez-kj2ul
    @JorgeHernandez-kj2ul 2 месяца назад

    2:4 contestar batallando así sabes que hace un mes y medio murió mi esposa

  • @sabinoramirez2600
    @sabinoramirez2600 2 года назад

    this is great but hopefully two years later you guys have learned to clear the terminal before new commands

  • @lukeno4143
    @lukeno4143 Год назад

    Conda is so terrible. First they dont auto-add Windows paths, second you cant even choose conda interpreter as a virtual environment even if its listed as a global interpreter. the Conda developers are the worst. And never going to trust Conda for anything.

  • @vedprakash2056
    @vedprakash2056 3 года назад +1

    (base) ved@DESKTOP-EHGUM68:~$ less environment.yml
    environment.yml: No such file or directory
    I am getting this. please suggest the required correction

    • @qm142009
      @qm142009 3 года назад

      You don't have environment.yml file in your directory. You don't need that. Just proceed without that line.

    • @leirepapepv2411
      @leirepapepv2411 3 года назад

      The same thing happens to me and I can no longer continue

  • @aliozeir708
    @aliozeir708 2 года назад

    Thank you