Python Forum
Python equivalent of Matlab code
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Python equivalent of Matlab code
#1
I am converting a section of Matlab code from others as my project and I have no idea what it is doing.

CC_horiz=bwconncomp(horiz_erode,8);
CC_vert=bwconncomp(vert_erode,8);
stats_horiz=regionprops(CC_horiz,'Area','PixelIdxList');
stats_vert=regionprops(CC_vert,'Area','PixelIdxList');

Documentation of the two functions:
bwconncomp
regionprops

The outputs are all structural arrays and I wantregionprops to separate the Area and PixelIdxList field into two different variables. I have no idea what the functions are doing. It would be great to have some help.

Thanks in advance!
Reply
#2
I believe that as it is your project, you will need to research it on your own.
Of course if you have specific questions or run into some errors/obstacles, feel free to post your attempt and someone might be able to help you.
Also let us know if it is a homework/coursework, so the thread is moved to Homework section.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Equivalent Python code from VBA Mishal0488 1 633 Jul-05-2023, 10:43 AM
Last Post: carecavoador
  PySpark Equivalent Code cpatte7372 0 1,228 Jan-14-2022, 08:59 PM
Last Post: cpatte7372
  Python C++ Template Equivalent deanhystad 7 3,313 May-04-2021, 07:45 PM
Last Post: deanhystad
Photo Matlab to Python Sateesh 0 1,636 Nov-04-2020, 09:11 AM
Last Post: Sateesh
  From Matlab to Python erbab 1 1,970 Oct-27-2020, 02:16 PM
Last Post: jefsummers
  Arrays in MATLAB and PYTHON cokhuatlanyeuthuongconhetmuc 2 2,156 Jul-24-2020, 10:47 AM
Last Post: cokhuatlanyeuthuongconhetmuc
  Hi Guys, please help me to write SAS macro parameter equivalent code in Python Manohar9589 2 2,538 Jun-14-2020, 05:07 PM
Last Post: Larz60+
  Matlab to Python -- Parallel Computing zistambo 1 1,934 Jun-10-2020, 04:59 PM
Last Post: pyzyx3qwerty
  Python v MatLab for graphs and plots CynthiaMoore 4 2,979 Apr-22-2020, 02:13 PM
Last Post: CynthiaMoore
  python equivalent to MATLAB xcov chai0404 2 3,818 Apr-02-2020, 10:29 PM
Last Post: chai0404

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020