Page 1 of 6 123456 LastLast
Results 1 to 10 of 58

Thread: Calling Any Java Programmers - Computer Vision Project

  1. #1
    FLAC sama's Avatar
    Join Date
    Feb 2006
    Location
    London, UK
    Posts
    1,375

    Calling Any Java Programmers - Computer Vision Project

    This is what this project aims to do:



    Here's a comptuer vision primer.

    And here's a sticky link to the latest code: CarVision_0.4a.jar. This also contains the source code.

    If you don't know anything about coding but would like to see how things are developing, then here are the instructions on how to install the progam posted below.

    First, you need to get a Java Runtime Environment installed. Go to http://java.sun.com and download the latest for your operating system.

    Then, you'll need the Java Media Framework. Get that for your OS from here

    ensure that your webcam/video capture card is working first, without Java. So use whatever program you normally use to do bi-directional porn and make sure the video feed is working.

    Now that you have all the software, start JMStudio, which JMF should have just installed, and go to File -> Preferences. Click on the Capture Devices tab, and click on Detect Capture Devices. This will register any capture devices you have so that Java can see them. Just make sure the VFW (video for windows) one is visible, and that it's locator is vfw://0 (I'll add the ability to select which locator to use later).

    Finally, double click on the jar and you should get a window appear, which will immediately start to capture the background. Do not stand in it's way whilst it's learning. Let it point at some part of the room/road for a few seconds so it can distinguish between background and foreground.

    The result will be that any moving objects should only appear, whilst non-moving objects will remain black.

    This currently works best indoors, or on a day with consistant lighting.


    Orignal post

    I'm developing a computer vision library to later create applications with. The Java Media Framework and Advanced Imagine Api's are being used to extract frames from a stream and process the pixel data.

    So far, I have exactly that. The next steps are to create algorithms for motion detection and the likes. If you have any experience in the field and would like to get involved, please get in touch.

  2. #2
    Variable Bitrate 84RegalRider's Avatar
    Join Date
    Nov 2004
    Location
    San Diego
    Posts
    427
    Good luck.
    Would help a bit but im busy with my own stuff.

    dont suppose you know why im only getting 0s or 255s bytes of my serial line instead of numbers 0-255???

    haha (been asking all over the place).
    Core duo
    1tb harddrive
    256 ddr
    8 lilliput
    bu-353

    still installing...

  3. #3
    FLAC sama's Avatar
    Join Date
    Feb 2006
    Location
    London, UK
    Posts
    1,375
    what are you feeding into it?

  4. #4
    Newbie
    Join Date
    Feb 2006
    Posts
    28
    i have some decent experience with java, but not much with vision in java. i've done some java3d programming and what not. i have also done some vision programming in c++. if you could give me some more details on what you've done and where you want to go, i might be able to help.

  5. #5
    FLAC sama's Avatar
    Join Date
    Feb 2006
    Location
    London, UK
    Posts
    1,375
    I was loosing hope there and getting ready to take the plunge.

    So far, I have the following algorithms that I've done in different projects. I'm currently in the processes of grouping them into a library.

    1. A motion detector that continuously learns a background, and subtracts the current frame from that background. This difference image shows moving objects. This image is then scanned using a connected components algorithm, which groups connected pixels together, and labels them as unique regions.

    2. I've also got a tracker, that will predict (in a linear fashion) the next location of a moving region from the above region identifier. It uses the centroid of the as the coordinates.

    3. I've got code to connect to a video source, either file/url/capture (currently video for windows... not the best but ok for now. directshow would be better). Each frame that is captured fires off an event, which a connected listner can use to retrieve that frame.

    the projects I've got in mind are these:

    Buffered Recording:
    This project is the primary directive. To continuously record, and discard any footage older than a specified timeframe. The idea is that if something happens, like an accident or similar, the user can press a button and have a record of what just happened, in addition to everything that happens after that, up to a specified timeframe / when the user aborts.

    Since this stream is running all the time, it can be used for other things. There's a massive distniction between moving and stationary projects, so here's the stationary one first:

    Motion Initiated Recording:
    This project is failry easy, and can currently be done through various means, but this would put the library to the test. It's to record only when a certan sized region appears in view. The regions can be profiled to distinguish between person/car/animal, using some matching techniques, which will require some research and development. I'm aware that some users will have power issues, but it would be useful to have a recorder run whilst away from the car in a dodgy area for example.

    Rain Sensor:
    This is sort of both moving and stationary! Using some filters, it should be possible to identify rain drops on the screen. And after a certain threshold, it would be possible to fire off an event to turn the wipres on.

    A Passive Radar:
    This will be a real challange. A rear view camera that alerts the user of fast moving objects. Since the vehicle is in motion, object detection takes a whole different direction. I'm assuming that optic flow will have to be used here see (this link) for more info.

    Interested?

  6. #6
    Newbie
    Join Date
    Feb 2006
    Posts
    28
    Sure, I'm interested. I worked with a professor at my college last semester, and he's developed something similar in c. It basically is an object detector. It will constantly monitor a scene, and if an object is added/removed it will take a few pictures of it, and try to match it to something in its database, i.e. a coffee cup, etc. It sounds like what you want to do is pretty similar, and I can tell you that it is a whole lot of work. There is alot of code written in c for this, and im sure we could use a lot of the same algorithms. Have you looked at OpenCV at all? They have excellent motion detection algorithms. Also, if I speak to my professor he might be willing to give me some hints for some good algorithms for the object detection stuff. Another option would be to create Java that interfaces with C, and then we could use some of the code that's already written, unless you just want to write all the code yourself?

  7. #7
    FLAC sama's Avatar
    Join Date
    Feb 2006
    Location
    London, UK
    Posts
    1,375
    Quote Originally Posted by pyrotechnique
    Sure, I'm interested. I worked with a professor at my college last semester, and he's developed something similar in c. It basically is an object detector. It will constantly monitor a scene, and if an object is added/removed it will take a few pictures of it, and try to match it to something in its database, i.e. a coffee cup, etc. It sounds like what you want to do is pretty similar, and I can tell you that it is a whole lot of work.
    I've already got that far except the matching. I'm not even sure matching is required at the moment, as long as some form of distinguishment between cars and people is done. that way cars / newspapers flying by can be ignored, but people walking can be recorded, since they may end up breaking in.

    Quote Originally Posted by pyrotechnique
    There is alot of code written in c for this, and im sure we could use a lot of the same algorithms. Have you looked at OpenCV at all? They have excellent motion detection algorithms.
    I've brielfy looked at CV, but I was a little offput by the non-java stuff. Although I've done some C++ in the past, it's a bit dated and I've now got 5 years of industry experience in Java. You're right about it containing everything though. I just had another look.

    I've also found a Java library of similar features. ImageJ. Have a look at the speed charecteristics! I came accross this when looking for a java optic flow implementation that I could steal. Turns out it was a plugin for the ImageJ opensource api.

    Quote Originally Posted by pyrotechnique
    Also, if I speak to my professor he might be willing to give me some hints for some good algorithms for the object detection stuff.
    defo a good idea. I'm also in touch with a Dr. at university here, whom I also worked with whilst at uni! this is where my experience comes from so we're in similar waters here He's offered to help and I may do a part time phd in this. I figured if I'm going to do all this work, I may as well get something for it. But we'll see how that pans out.

    Quote Originally Posted by pyrotechnique
    Another option would be to create Java that interfaces with C, and then we could use some of the code that's already written,...
    sure we can, if we have to take something from the OpenCV library that's in not in ImageJ. I'm not completely closed to the idea of working with C++. I'm rusty but I can get back into it. What I don't want is to be held up by my inablity with C++ rather than getting on with getting the project stuff going.

    Quote Originally Posted by pyrotechnique
    ...unless you just want to write all the code yourself?
    I'm more interested in getting a solution to work more than anything. If we can just plug a load of modules together and get the requirements done, then that's great. I'm not concerened about performance or anything else at the moment, just getting the goals done. The rest is a known science and attackable.



    so.. today I tried to work with ImageJ but didn't get very far in integrating it to my code. ImageJ needs to get its frames from somewhere, so the video capture stuff I have should be good starting point for that. I expect to have a working demo of the stuff I have so far by Friday. I can send that to you to get familiar with whilst it's nice and early, and we can collaborate in moving from there.

    The type of help I'd like is someone to experiment and share ideas with, since this is a research based project.

  8. #8
    Variable Bitrate 84RegalRider's Avatar
    Join Date
    Nov 2004
    Location
    San Diego
    Posts
    427
    damn im interesting now.
    dont know how much time i can add tho.

    ill try to get into it a bit.
    give me a couple days to look more into it.
    Core duo
    1tb harddrive
    256 ddr
    8 lilliput
    bu-353

    still installing...

  9. #9
    FLAC sama's Avatar
    Join Date
    Feb 2006
    Location
    London, UK
    Posts
    1,375
    great! I'll send my code tommorow, when I hope to get a working version done

  10. #10
    FLAC alti's Avatar
    Join Date
    Sep 2004
    Location
    NY
    Posts
    1,723
    I also am interested, I will have to read up on what you are doing, but this sounds really interesting. I am in the process of adding a nitemax camera to my setup and was just thinking about software possibilities.
    My Install

    Software:
    CFiG v1
    iGuidance Plugin for CF

    CarShell
    Working shell for a CarPC

    StopWatch
    StopWatch plugin remade for centrafuse RC1

Page 1 of 6 123456 LastLast

Similar Threads

  1. Making a Car Computer; Need Your Help!
    By Fear Effect in forum Newbie
    Replies: 20
    Last Post: 08-18-2008, 09:51 AM
  2. Project start for 1965 Mustang Fastback
    By 65_2plus2 in forum General MP3Car Discussion
    Replies: 3
    Last Post: 03-24-2005, 10:43 AM
  3. 1994 Honda Accord Coupe Computer Project
    By project94coupe in forum Show off your project
    Replies: 20
    Last Post: 07-28-2004, 10:50 AM
  4. just got other computer so project is back on
    By babas151 in forum General Hardware Discussion
    Replies: 2
    Last Post: 10-10-2003, 06:35 PM
  5. new computer project... question about ebay LCDs...
    By nadir_s in forum LCD/Display
    Replies: 10
    Last Post: 10-19-2002, 04:23 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •