1- Introduction

In this lesson, we want to show how to start coding Python inside grasshopper by using the Python script component. In this lesson, we want to show you how can write a simple code inside Python and also learn how to import library components of grasshopper to make things easier!

Comments

  • AlbertoMargo
    Reply

    Do we have to load some phyton library to grasshopper or something?
    I’m having some errors: “Solution Excepction: Method Not Found”

  • erfanrezaei_
    Reply

    Hi Alberto
    you just need to use this code at first in your python editor to load grasshopper components:
    import ghpython.library.components as gh

  • chuachinghong
    Reply

    Thanks for the video. Just curious…if let’s say we have two solutions to a problem. Say one was done with the visual programming (wired) way and another was done with python script. Will there be a cpu computational time advantage for python?

    • naseri2

      You’re welcome. Scripts are faster for the most part. For instance, you might have a routine that you do often which uses 10 components, you can cluster that into one component (but it is usually slower) or you can script the routine as one component and it can be very fast. But if you replace one component with a python script, then it will be similar in speed.

  • spaced2009
    Reply

    hi i can’t seem to dowlaod the video, can anyone help me? thanks!!

    • parametric

      Hi Spaced2009

      Thank you for the report. Please check the link again