Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Java/C++ vs Matlab in Image Processing?

  1. Feb 6, 2013 #1
    I just recently picked up MATLAB and still learning its syntax and built-in functions. I am working on a project that deals with image analysis, such as extract every pixels from an image and analyze them in forms of matrices.

    I am more experienced in Java than C++ or Matlab. I also feel that full programming language gives me more freedom to program the way I want. However, I am not sure if that is efficient.

    I am deciding either spend more time in learning Matlab or just start right away with Java?
    Does C++ offer any advantage over Java? (in speed, in organization, and etc ?)
    I am looking forward to build a robust program that can handle heavy duty tasks.

    Thank you,
    Calvin
     
  2. jcsd
  3. Feb 6, 2013 #2

    jim mcnamara

    User Avatar

    Staff: Mentor

    Stick with what you know. If what you need to compute is in a time-critical system like realtime image processing, then you may want something else.

    java runs under a virtual machine, that with jit compilation into bytecode, provides a lot of performance and has builtin optimizations like inlining.

    However, java is not normally the codebase for realtime apps. But the trade off of being able to write good code from the getgo is worth an awful lot. Stick with java unless there is a compelling reason.

    Also, this kind of post is going to elicit a lot of thinly guised 'use my favorite language!'
    posts. Ignore them.
     
  4. Feb 6, 2013 #3

    chiro

    User Avatar
    Science Advisor

    I'm with jim on this one.

    Just use the right tool for the right job and if you need to use something out of necessity (existing platform, legacy code, time issues, etc) then use it.
     
  5. Feb 7, 2013 #4
    The answer, as usual, is "It depends", in this case, upon what you actually want to do with the images.

    Matlab (Matrix Laboratory) inherently does matrix maths and has a number of standard functions that handle image I/O. There are also specialist Matlab toolboxes that perform a wide range of image processing tasks.

    Other applications to consider are Mathematica, which seems to have good matrix and image handling, and Mathcad (which I find easier to use than either Mathematica or Matlab).

    The image processing routines for all these have undergone lengthy testing and benefitted from operational experience, and are often quite efficient in terms of performance because the underlying applications are inherently designed to work at matrix level.
     
  6. Feb 7, 2013 #5
    If you follow Jim's advice, you should ignore me, 'cause I am about to recommend a programming language you did not mention: Python.

    Along the same lines and because of the same reasons NemoReally recommends Matlab, Mathematica or Mathcad...I recommend Python.

    Python (and its popular numpy, scipy, matplotlib, pil modules) can handle matrices very powerfully and it has various algorithms for image processing and tools for quickly visualizing them.

    Python is useful all around for many things and it is starting to be picked up as the scripting language of OTHER applications: Salome, Blender, SPSS, etc.

    Even a US agency provided $3M to fund further Python development, just a few days ago...that's how much Python is being used.

    my 2 cents
     
  7. Feb 8, 2013 #6

    jedishrfu

    Staff: Mentor

    and then there's processing at processing.org where you can play with java and opengl and draw pretty interactive pictures on the screen like what you see in scifi movies.

    so when you're tired of matlab, try processing to get a feel for what java can do.
     
  8. Feb 10, 2013 #7
    I just want to say thank you for all the thoughtful responses and help.
     
  9. Feb 10, 2013 #8
    It's indeed very cool.
    Is it an IDE software and provide library for java?

    EDITED: Nevermind I will look through the tutorial myself. Thank you so much.
     
    Last edited: Feb 10, 2013
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Java/C++ vs Matlab in Image Processing?
  1. Python VS Java (Replies: 13)

  2. C# vs c (Replies: 5)

Loading...