How to plot a streamlines from CSV data

Dear all !!!
I have faced two issues:

  1. To plot a streamline from CSV data (basically to deal with meshgrid )

  2. To control these streamline on the domain only (e.g. a T shaped domain )

I have worked on it up to some extent but the results are not as my expectation.

Hello Skr,
I am new to GitHub and would like to contribute to matplotlib. Could you please tell me if we can collaborate and help you with coding?

Thanks @vandinimodi ,
please tell me how could we proceed further.

Hello @skr, I am excited to work with you. I would like to know the requirement of ‘how to plot a streamline from csv data’ in detail. I am open to having a zoom/Teams/Webex call to discuss the expected timelines if required. Please let me know the tool through which we can communicate.

Good to see your positive response @vandinimodi.

We can together handle the streamline contour plot problems together. You can reach me through Github page, mail (, or this community.

Anyway, what I know from past experience for a streamline plot from CSV type data is :

  1. Import your CSV data [x , y , e1, e2]
  2. make a uniform grid over the computational domain using numpy.mgrid or numpy.meshgrid.
  3. Interpolate these grids for e1 and e2 using scipy griddata interpolation.
  4. Mask out the unwanted region from the computational domain which you don’t want.
  5. Finally call the streamline plot.

for your best understanding a CSV file and python script has attached here:
Kindly go through it

Hello @skr, I am doing this for the first time and also as a part of my course project. May I know the approximately expected time required to complete it?

To generate a plot using CSV data is not a big deal in the case of a 2D problem.

Additional to this, you have to quantify the additional ideas that you are trying to embed here, which may take few extra time.

Rest you can ask freely if you need any help/support.