3 Replies Latest reply on Jun 28, 2012 9:14 PM by Mannamal-Oracle

    Image searching interface

      Hi all,

      I need to build some basic interface which I will use to search my database (where I'm storing images). I want to view images, informations (SI_StillImage, SI_AverageColor, SI_Color, SI_ColorHistogram, SI_FeatureList, SI_PositionalColor, and SI_Texture), semantic metadata, compare pictures. Which tool I should use? Do you have some tutorials how can I do this? I'll be appreciate if you can help me.
        • 1. Re: Image searching interface
          You have to use a Pl/SQL block to get at the SI_ values once you have successfully inserted an image into the DB. I don't know off-hand if the DB supports extended semantic metadata but if so, you'd use the same mechanism as that for the SI_ values.

          As to image comparison, are you trying to do something similar to TinEye? If so, you'd have to integrate an image search/comparison library which is difficult even for experienced systems integrators to do.

          There are very few tutorials available for Oracle Multimedia. If you can be more specific I can point you in a general direction but be forewarned, there is a reason for the lack of tutorials - Oracle Multimedia is complex and requires a high degree of skill for proper use.
          • 2. Re: Image searching interface
            I did it but I have other problem. I created id, pictures and sygnature column in "Pictures" table. I have copied some pictures to "Pictures" table (I used stored procedure which generated sygnatures). When tried compile other stored procedure I received this message :

            Error(12,4): PL/SQL: SQL Statement ignored;
            Error(12,39): PL/SQL: ORA-00904: "ORDSYS"."IMGSIMILAR": incorrect identifier

            This stored procedure you can find below:

            create or replace
            procedure find (color varchar2, texture varchar2, shape varchar2, location varchar2, sensitivity number) is
            scale varchar2(200);
            number number;
            idd NUMBER;
            image ORDSYS.ORDIMAGE;
            query_signature ORDSYS.ORDIMAGESIGNATURE;
            query_image ORDSYS.ORDIMAGE;
            ctx raw(64) := null;

            CURSOR getphotos (c_scale varchar2) IS
            SELECT id, picture FROM pictures WHERE

            ordsys.imgsimilar(sygnature, query_image, c_scale, sensitivity) =1 order by id;

            SELECT picture INTO query_image FROM tab_obr WHERE id = (select max(id) from tab_obr ) ;
            -- Initialize signature object
            query_signature := ORDSYS.ORDIMAGESIGNATURE.init();
            -- Create temporary storage for the LOB in the signature object
            DBMS_LOB.CREATETEMPORARY(query_signature.signature, TRUE);
            scale := 'color='||color||' texture='||texture||' shape='||shape||' location='||location||'';
            OPEN getphotos (scale);
            FETCH getphotos INTO idd, image;
            EXIT WHEN getphotos%NOTFOUND;
            DBMS_OUTPUT.PUT_LINE('Image with ID ' || idd || ' matches query image');
            insert into tab_obr2 (select * from picture where id=idd);
            image.export(ctx, 'FILE', 'PICTURE_KAT_EKSS', image.getSourceName());
            END LOOP;
            CLOSE getphotos;

            Can you help me and tell me why I cannot compile this procedure? I have generated sygnatures before I tried compile procedure above...

            I'm so sorry for my bad English :)
            • 3. Re: Image searching interface
              What version of the database are you using? IMGSimilar has been deprecated and will not work in 11.2.