Convert Image into Matrix - Like a Pro!

แชร์
ฝัง
  • เผยแพร่เมื่อ 15 พ.ย. 2024

ความคิดเห็น • 119

  • @darcewirralgan1379
    @darcewirralgan1379 4 ปีที่แล้ว +14

    I've been a graphic designer for years and never thought of RGB so deeply before! Thank you!

    • @PythonSimplified
      @PythonSimplified  4 ปีที่แล้ว +7

      Me too! I've only realized the complexity of images once I've built my first classifier neural network, before that - I knew what pixels and vectors are, but I couldn't really translate them into math!
      The good news is, us designers don't really need to know that because Adobe Illustrator is doing this hard work for us (abbreviated to AI for a reason, no?), but in Machine Learning - it's a must! ;)

  • @DeepuKumar-mp4hl
    @DeepuKumar-mp4hl ปีที่แล้ว +1

    The most lucid explanation one can get on youtube

  • @AdamMundok
    @AdamMundok 3 ปีที่แล้ว +12

    You did a GREAT job explaining as a teacher. Keep up the great work and vids, and thanks for making and sharing!! 🙌🏼

  • @ChristopherOBrienPSU
    @ChristopherOBrienPSU ปีที่แล้ว +2

    Wow, I love the way that you explain things in easy to understand concepts and language. Keep it up!

  • @darwinayrtonespejoquintana7507
    @darwinayrtonespejoquintana7507 ปีที่แล้ว +1

    Great explanation !! I was a little confused at first, but now I understand this subject better.

  • @martinoolivieri3779
    @martinoolivieri3779 2 ปีที่แล้ว

    Thanks a lot ! Clear and complete description. I have solved a important issue for my exam in Artificial Neuronal Network at Uni Trento - Italy.

  • @mchess7157
    @mchess7157 2 ปีที่แล้ว +2

    That's great. I think this is exactly what I was looking for even though I didn't realize that. Some time ago I was working on a project that was supposed to enable automatic straightening of scans (I don't know if this is the correct term 🤔). I used the Pillow library for this to be able to iterate through the pixels in the selected axis and find the points in which text appeared on the basis of the color of the pixels. After finding several points the program could calculate the angle by which the image should be rotated. The results were in fact quite good. But the whole process lasted long. And from time to time the program landed in the empty space between the lines of text and couldn't find any darker pixel and was falling into a loop.
    I suppose that converting an image into a matrix and using numpy should be a much more effective and faster way.
    I'm so excited. I can't wait to try it in practice.
    Fantastic video. Thanks

    • @josholin31
      @josholin31 2 ปีที่แล้ว

      How goes putting it into practice?
      With your original method, I'd probably start closer to the center and work your way out. Rather than work your way inwards. - Less pixels to initially compare.
      But I'd definitely figure out the max used rgb / gray before doing so. And count how many similar pixels there are, to allow a tolerance + cap based on how many pixels it scanned through the width. Otherwise, it would needlessly rotate it when it reached a letter with a tail, like "g" or "y". - Could probably just rotate it up to 180 (original image or distortion) to see if it sees more of the background color on the width. And if it doesn't, it searches a wider area. (Also larger angle differences near the start and use a fraction of it as it goes out until hear area, would probably be best... also maybe a check to see if there is more background pixels initially within the new area before it tries rotating)
      But yeah, I've been working on a program to make an image into a bunch of algorithms. To compress an image. Most image formats have "filters" to decrease space but they neglect some patterns for speed. And I've been avoiding looking into matrices for far too long - hated them in school. But I think they are definitely the answer to analyze data.
      Although I'll add an observation, when I separated an image by rpga values, it took much more time when 0ing out values by matrix, rather than using merge with a new black image. I think it has to do with getdata / putdata... processor wasn't working that hard so I think it was the method of retrieving data and then writing it. - today I'm going to see how quick matrices are to search through. It definitely avoids a bunch of loops so is quicker. But I'm going to avoid using putdata/getdata whenever possible. - Using it only when analysis is necessary.
      (Have a very low end laptop for programming since I want to make efficient code.)
      Sorry needed to organize my thoughts. Helps when I think someone else might read it.

  • @justiccoolman1816
    @justiccoolman1816 ปีที่แล้ว +2

    Btw. at 4:59, the calculation is right, but unneccessary complicated: 85% of 256 is just 256 * 0,85.
    Calclating a percentage is really easy: Just shift the comma two digits to the left (which is equivalent to devide by 100) and multiplicate that result with the amount u need the percentage from.

  • @jyoshnabejjam4983
    @jyoshnabejjam4983 3 ปีที่แล้ว +3

    Im an indian thank u very much
    Ur video helped me to clear all my doubts

    • @PythonSimplified
      @PythonSimplified  3 ปีที่แล้ว

      Thank you Jyoshna! I'm glad I could help! 😃

  • @h7opolo
    @h7opolo ปีที่แล้ว +1

    thank you! this was very informative and pleasant to listen to.

  • @neelsamshah
    @neelsamshah 3 ปีที่แล้ว +3

    Great explanation and graphics! Thank you!

    • @PythonSimplified
      @PythonSimplified  3 ปีที่แล้ว

      Thank you so much Sameer! glad you liked it! 😊

  • @rohithperumandla4302
    @rohithperumandla4302 3 ปีที่แล้ว +1

    I've been searching for this explanation and finally found

  • @trippy7415
    @trippy7415 4 ปีที่แล้ว +4

    Great tutorial! Now I understand everything!

  • @VishalSingh-mi8je
    @VishalSingh-mi8je 4 ปีที่แล้ว +4

    never seen anything better than this : )

  • @aristideregal
    @aristideregal 3 ปีที่แล้ว +2

    Best teacher ever!

  • @maximesamara
    @maximesamara ปีที่แล้ว

    Hello! Could you please tell me what type of editor did you use in this video?
    Thanks a lot

  • @bolhasani
    @bolhasani 2 ปีที่แล้ว +3

    Really informative and interesting. Many thanks for sharing your great knowledge and experience. It's admirable.

  • @chiranjeebroychowdhury7759
    @chiranjeebroychowdhury7759 3 ปีที่แล้ว +1

    Nice elementary video on images. In my experience, I have come across people with little to no knowledge of raster or vector images, or the different color models (RGB, CMY, HSI, etc.). Many UI designers just use online color palettes and color pickers to put different colors!

  • @constantincostea2823
    @constantincostea2823 3 ปีที่แล้ว +8

    She is super smart, beautiful, relevant and funny. I promise :)

    • @faisalee
      @faisalee ปีที่แล้ว +1

      I loved that “I promise” 😄

  • @nikluz3807
    @nikluz3807 2 ปีที่แล้ว +2

    Not only well explained, but the presentation is excellent. What program do you use to make presentations like this? They’re so clean!

  • @sprecmoles
    @sprecmoles 3 ปีที่แล้ว +2

    Hello, first of all, thank you very much for the video. I couldn't find an answer to this question in your video, can you please answer? " What is the relationship between matrices and image processing ? " . Thank you from now :)

  • @AlexanderRodriguez-cursos
    @AlexanderRodriguez-cursos 4 ปีที่แล้ว +3

    Congratulations, Excelent explanation with good illustrations

  • @jooyichen
    @jooyichen 3 ปีที่แล้ว +3

    Hello ma'am, just want to ask for your advice.
    I've been given a task to in my programming class which I was unable to do.
    1st step I've accomplished - txtfile full of floats > into Ndarrays > into matlotlib > savefig image
    2nd step I couldn't do ( done in reverse ) - from a png or jpeg > imread to ndarrays > Back to *floating arrays*
    I don't know why my arrays are all 255 and 0. The task was to produce arrays with values 0.654646 for example, then saved to a textfile.
    Thank you.

    • @PythonSimplified
      @PythonSimplified  3 ปีที่แล้ว +1

      I believe it's a matter of conversion from one colour format to another, but it's difficult to tell without seeing the code and which images you're testing it on...
      Realistically if your values are between 0 - 255 maybe try dividing each value by 256 to get floating point numbers, this might solve it but I don't know if I fully understood the task 😊

    • @AliHassan-wc6nb
      @AliHassan-wc6nb 2 ปีที่แล้ว +1

      @@PythonSimplified so nice of you to answer trying answering this!!

  • @jpinheiro7523
    @jpinheiro7523 ปีที่แล้ว

    Sua pronúncia é incrível aprendo muito com você fora que você é linda 🎉👏👏👏👏👏

  • @emiliomartineziii2980
    @emiliomartineziii2980 6 หลายเดือนก่อน

    She’s a genius supermodel! She’s superior to the rest of us :)

  • @stemcell11222
    @stemcell11222 ปีที่แล้ว +1

    It worked, my brain got bigger but not where I wanted it to! XD Too disctracted by talent, too much talent!

  • @SastaYoutubian
    @SastaYoutubian 3 ปีที่แล้ว +1

    I really like you and also the way of explaining

  • @wassel327
    @wassel327 3 ปีที่แล้ว +1

    Underrated content

  • @nehalkalita1
    @nehalkalita1 ปีที่แล้ว

    Really good presentation.

  • @KJ7JHN
    @KJ7JHN 2 ปีที่แล้ว +1

    Do you have a python or java video on filtering specific colors? As an example, load image, cycle through x by y for 00FFA6 output result? And the next question is how would you do this for a web cam feed? Thank you! Keep up the great content.

  • @kuaranir2440
    @kuaranir2440 2 ปีที่แล้ว

    Fantastic explanation👍

  • @ankitkumardip90
    @ankitkumardip90 6 หลายเดือนก่อน

    Thank you so much ❤ 😊

  • @md.musfiqurrahaman8612
    @md.musfiqurrahaman8612 3 ปีที่แล้ว

    Amazing explanations!

  • @hazirahmuslim
    @hazirahmuslim 4 ปีที่แล้ว +1

    This is a detailed and good video! Thank you!

  • @MicheleTorbak
    @MicheleTorbak 3 ปีที่แล้ว

    I like the explanation. Plus very useful. Thank you

  • @okabirintaro976
    @okabirintaro976 3 ปีที่แล้ว +3

    the explication is so gooood , thak you ,(also you are beautiful)

    • @PythonSimplified
      @PythonSimplified  3 ปีที่แล้ว

      Thank you Okabi! Glad you liked it! 😀

  • @asmodeus4310
    @asmodeus4310 3 ปีที่แล้ว

    Your channels the best

  • @mahdishadroh1643
    @mahdishadroh1643 3 ปีที่แล้ว +1

    hi im from iran
    thank you so much your video answered all my questions
    you are beautifule im subscribing you right now

  • @foustcor
    @foustcor 2 ปีที่แล้ว

    terrific!! thank you!

  • @louaykhammar7268
    @louaykhammar7268 2 ปีที่แล้ว

    great explanation

  • @agx111
    @agx111 11 หลายเดือนก่อน +1

    1. binary = 0-1
    2. grey scale = 0 -255
    3. rgb - all red green blue got their different grey scale values
    red = 0 - 255
    green = 0- 255
    blue = 0-255
    so total three

  • @rahulranjan8682
    @rahulranjan8682 2 ปีที่แล้ว

    great. but just one doubt. why the intensity ranges from 0 to 255 why not other number as 511 or 1023?

  • @BanothAnusha-hv4qn
    @BanothAnusha-hv4qn 8 หลายเดือนก่อน

    thank you madam so mach for understanding concept over teacher teaches i cant understand know i understand

  • @Yaya-hr9ho
    @Yaya-hr9ho 3 ปีที่แล้ว

    is there any app, software or website for color to matrix converter?

  • @SohailKhan-rw2gb
    @SohailKhan-rw2gb 4 ปีที่แล้ว +2

    i install open cv but cv2 is not working, please help. i says about version error. So which version will work, and if i change python version will it uninstall all other installed numpy, pandas atc? i have problem dear, i even not reading image.

    • @PythonSimplified
      @PythonSimplified  4 ปีที่แล้ว

      Hi Sohail! 😀
      Did you recently upgrade to Python 3.9 by any chance? you may be experiencing issues with several libraries in this case, as this version of Python is brand new and some of the packages are not integrated yet (including PIL by the way, I have a few viewers who had to go back to 3.8 to get it to work).
      As to your second question, if you installed your Python inside a virtual environment - you don't need to override anything.
      Just create a brand new virtual environment and install a different version of Python (and it's dependencies) inside it. That way you can have multiple versions of Python installed on your computer at once and you can jump from one environment to another very easily.
      If you installed Python with Anaconda, checkout my video where I explain how to create a new environment:
      th-cam.com/video/FZ5baopI_mo/w-d-xo.html
      If you didn't use Anaconda, checkout these instructions on how and why you should consider working with virtual environments 😁:
      www.geeksforgeeks.org/python-virtual-environment/#:~:text=A%20virtual%20environment%20is%20a,of%20the%20Python%20developers%20use.

    • @SohailKhan-rw2gb
      @SohailKhan-rw2gb 4 ปีที่แล้ว

      Hi python simplified 🤠
      Thanks for such a sincere reply. You exactly said right. I am new to python. I need help from person like you much. I am lonely learning it, as I spent 3 days in just installing keras.
      I have installed 3.8.3 python version, is this still not suitable version?
      if you have any link related3.8 please give it. I will do the same as you said, Love you much.
      I am going to watch your video related environment. And yes I have installed Anaconda snake. ( But it is stinging me from few days)🐍😃. Thanks again. Can I mail you the shots of my python error. That will help me alot.

    • @SohailKhan-rw2gb
      @SohailKhan-rw2gb 4 ปีที่แล้ว

      I faced this issue when I told my friend cN we convert image into math. He said it very hard., but we did through python. But we did it with their own laptop. When I was going to do it with my own laptop, it wasn't happening due to opencv issue. Is there any code to convert image to matrix without opencv.

    • @PythonSimplified
      @PythonSimplified  4 ปีที่แล้ว

      ​@@SohailKhan-rw2gb hahaha Python 3.8 is great, that's the version I'm using so you shouldn't experience any issues if you follow the instructions of the Python installation video I sent you.
      In terms of Keras... I recommend learning much more about Python before you dive into this. This is not a beginners module and you will waste lots of time tying to understand it. It's like getting your drivers license for the first time and instead of driving an old Toyota - you go for Lamborghini. Machine Learning is not an easy task to understand, but it's easier with experience.
      Open CV and Pillow (PIL) are really good in terms of image processing, they are both great for image conversion.
      If you'd like to send me a screenshot you can either do this through LinkedIn:
      www.linkedin.com/in/mariyasha888
      or through my new Facebook page:
      facebook.com/PythonSimplified

  • @sam2718e
    @sam2718e 2 ปีที่แล้ว +1

    10:28 all good, but these are not the three dimensions.
    The third dimension is depth which allows to store more than one 2d matrix.

  • @madslug7139
    @madslug7139 4 ปีที่แล้ว

    Awesome vid as usual!

    • @PythonSimplified
      @PythonSimplified  4 ปีที่แล้ว +1

      Thank you so much for the support Dan!! :)

  • @Jriad
    @Jriad 3 ปีที่แล้ว +1

    15% black is 85% white = 0.85*256 = 218
    easier to understand i think

  • @mithunchandrasaha403
    @mithunchandrasaha403 3 ปีที่แล้ว +1

    Nice Explanation.Madam

    • @PythonSimplified
      @PythonSimplified  3 ปีที่แล้ว

      Thank you Mithun! Glad you liked it! 😁

  • @RiturajGhoshTech
    @RiturajGhoshTech 3 ปีที่แล้ว

    Hey, can you explain the steps of RIP in detail?

  • @sadaamashraf6288
    @sadaamashraf6288 3 ปีที่แล้ว

    Good work

  • @jituonline4u
    @jituonline4u 3 ปีที่แล้ว

    is it same like correlation pearson heatmap ?

  • @rbk00006
    @rbk00006 4 ปีที่แล้ว +1

    Awesome video but why did you changed your background music u know that mr bean music..i liked it very much

    • @PythonSimplified
      @PythonSimplified  4 ปีที่แล้ว

      Thank you so much! :)
      I though I've used the same music, no? It should be Creeping Spiders from the TH-cam gallery but now I'm not sure hahaha XD

  • @athulyajayakrishnan8694
    @athulyajayakrishnan8694 3 ปีที่แล้ว

    Thank you so much

  • @mohamedabdelbaset6769
    @mohamedabdelbaset6769 3 ปีที่แล้ว +1

    Try to make intro longer please😂😂

  • @stephenlittman
    @stephenlittman 3 ปีที่แล้ว

    Smart and beautiful

  • @velumaniramasamy4587
    @velumaniramasamy4587 2 หลายเดือนก่อน

    Thank you madam

  • @samsonmakumbe7388
    @samsonmakumbe7388 7 หลายเดือนก่อน

    thanks😁

  • @electricelectric5224
    @electricelectric5224 ปีที่แล้ว

    How i can to send it to plc please

  • @munivoltarc
    @munivoltarc ปีที่แล้ว

    today u look beautiful, great learning from you on python

  • @haboubikhouloud5060
    @haboubikhouloud5060 3 ปีที่แล้ว

    hi can you give me the program that image has smile thank you

  • @davidtindell950
    @davidtindell950 3 ปีที่แล้ว

    Thank You Again ! Also, Amazing how great are the images from Perseverance after landing on Mars this week !!!

  • @azizelmajdoubi
    @azizelmajdoubi 3 ปีที่แล้ว

    Thank u i understand nowww

  • @topgearIQ
    @topgearIQ 9 หลายเดือนก่อน

    How do you do

  • @csp405
    @csp405 2 ปีที่แล้ว

    4:23 The correct way to math it is 256/100 = 2.56 * 15 = 38.4 255 - 38 = 217
    And I have no idea what does 100 divided by 85 = 1.176 256/1.176 to do with 15 %

  • @dibbyabarua9499
    @dibbyabarua9499 4 ปีที่แล้ว +1

    cool video

  • @s.aadhithiyan9022
    @s.aadhithiyan9022 3 ปีที่แล้ว

    How to do the vice versa?

  • @solomondeveloper
    @solomondeveloper ปีที่แล้ว +1

    Nice to meet you. 😊
    Since I can't see your nose ring, it shows that you are even more beautiful.
    ~ 😄👍

  • @tersintech6779
    @tersintech6779 3 ปีที่แล้ว

    Great! cheers.

  • @philtoa334
    @philtoa334 3 ปีที่แล้ว

    Thank , it s nice.

  • @topjeeneethindi1064
    @topjeeneethindi1064 3 ปีที่แล้ว

    I don’t what should I appreciate first You or Code?

  • @shahriaralom4547
    @shahriaralom4547 3 ปีที่แล้ว

    thank you mam

  • @shinymp7691
    @shinymp7691 3 ปีที่แล้ว

    Nice

  • @sajibbiswas7709
    @sajibbiswas7709 2 ปีที่แล้ว

    Python absolutely beginner video where??

  • @aquahydroman7623
    @aquahydroman7623 4 ปีที่แล้ว +1

    I only thought thier was 50 shades of grey..... not 250....

    • @PythonSimplified
      @PythonSimplified  4 ปีที่แล้ว +2

      I guess Hollywood does a better job with marketing than mathematicians 🤣

  • @xxaqploboxx
    @xxaqploboxx 3 ปีที่แล้ว

    Im in love

  • @justnivek4345
    @justnivek4345 2 ปีที่แล้ว

    Kay fine but it doesn't explain how to do it on Python, it's only the theoric part

  • @ayachibassem8642
    @ayachibassem8642 3 ปีที่แล้ว

    the best explanation I've seen, thanks my pretty teacher, you are so attractive

  • @drizer4real
    @drizer4real 2 ปีที่แล้ว

    I love that woman. End of discusion. Sorry if that makes me a sexist pig or if it is inappropriate.

  • @surkewrasoul4711
    @surkewrasoul4711 ปีที่แล้ว

    😍

  • @senjuchidori9448
    @senjuchidori9448 3 ปีที่แล้ว +1

    Lets face it guys, you're not here to learn Python, lets face guys ....... @@

  • @csp405
    @csp405 2 ปีที่แล้ว

    0:11 ice humans??

  • @__________________________6910
    @__________________________6910 2 ปีที่แล้ว

    I'm also back

  • @greenpumpkin172
    @greenpumpkin172 3 ปีที่แล้ว

    I wouldn't call it a 3 dimensional matrix, but a tensor though. Tensors are generalizations of vectors and matrices.

  • @tejaspatil3978
    @tejaspatil3978 2 ปีที่แล้ว

    this exactly happens in CNN right..?

  • @rforrohitarorasirclasses6500
    @rforrohitarorasirclasses6500 3 ปีที่แล้ว

    Nice content my channel name is r for rohit arora sir classes

  • @RasamAsrani
    @RasamAsrani 2 ปีที่แล้ว

    I think I have a crush on you!

  • @akashesa4001
    @akashesa4001 3 ปีที่แล้ว

    Nice Dress, I Love You

  • @Shankarfamikay
    @Shankarfamikay 3 หลายเดือนก่อน

    Good video

  • @agx111
    @agx111 11 หลายเดือนก่อน +1

    wow nice ty 👍🫡