DETECT THE OBJECT IN MONOCHROME IMAGE

I want to detect an extra object present in my product but it has the same color as the background.  using thresholding and  particle analysis i got the detection but the resulting values are too small that sometimes this procedure leads me to  make the false rejection for my products.
In the attachment one of the good image and a bad image i.e. image with the extra object are provided. 
Attachments:
good.png ‏563 KB
bad.png ‏575 KB

It looks like the defective side has a distinct bright line.  If most defects are similar to this, you could use a Find Edge tool and just set the limits so if any edge is found, call it a reject.  If no edges are found, then call it good.  This really depends upon how consistant your background is.
The other option might be to count pixel values in the 200 to 255 range with a region of interest (ROI) set in this area.  Then, set a limit based on a good part background (say no more than 20 pixels found in a ROI that contains 500 or so total pixels).  I've used this method in the past, but the set limit is quite sensitive to the area of the ROI is low contrast conditions.   

Similar Messages

  • Detecting an object in an image

    hi all
    i need to know how to detect a particular object like a ball or a rectangular block within an image
    i tried opencv but it failed to detect an object within an image the C code used in JNI is given below
    #include <stdio.h>
    #include <stdlib.h>
    #include <jni.h>
    #include "sift.h"
    #include "imgfeatures.h"
    #include "kdtree.h"
    #include "utils.h"
    #include "xform.h"
    #include <cv.h>
    #include <cxcore.h>
    #include <highgui.h>
    #include "helloworld_HelloWorld.h"
    #define KDTREE_BBF_MAX_NN_CHKS 200
    /* threshold on squared ratio of distances between NN and 2nd NN */
    #define NN_SQ_DIST_RATIO_THR 0.49
    /******************************** Globals ************************************/
    char img1_file[] = "..\\football.png";
    char img2_file[] = "..\\sift.png";
    JNIEXPORT jint JNICALL
    Java_helloworld_HelloWorld_printNat(JNIEnv *env, jobject obj)
    IplImage * img1, * img2, * stacked;
         struct feature* feat1, * feat2, * feat;
         struct feature** nbrs;
         struct kd_node* kd_root;
         CvPoint pt1, pt2;
         double d0, d1;
         int n1, n2, k, i, m = 0;
         img1 = cvLoadImage( img1_file, 1 );
         if( ! img1 )
              fatal_error( "unable to load image from %s", img1_file );
         img2 = cvLoadImage( img2_file, 1 );
         if( ! img2 )
              fatal_error( "unable to load image from %s", img2_file );
         stacked = stack_imgs( img1, img2 );
         fprintf( stderr, "Finding features in %s...\n", img1_file );
         n1 = sift_features( img1, &feat1 );
         fprintf( stderr, "Finding features in %s...\n", img2_file );
         n2 = sift_features( img2, &feat2 );
         kd_root = kdtree_build( feat2, n2 );
         for( i = 0; i < n1; i++ )
              feat = feat1 + i;
              k = kdtree_bbf_knn( kd_root, feat, 2, &nbrs, KDTREE_BBF_MAX_NN_CHKS );
              if( k == 2 )
                   d0 = descr_dist_sq( feat, nbrs[0] );
                   d1 = descr_dist_sq( feat, nbrs[1] );
                   if( d0 < d1 * NN_SQ_DIST_RATIO_THR )
                        pt1 = cvPoint( cvRound( feat->x ), cvRound( feat->y ) );
                        pt2 = cvPoint( cvRound( nbrs[0]->x ), cvRound( nbrs[0]->y ) );
                        pt2.y += img1->height;
                        cvLine( stacked, pt1, pt2, CV_RGB(255,0,255), 1, 8, 0 );
                        m++;
                        feat1.fwd_match = nbrs[0];
              free( nbrs );
         fprintf( stderr, "Found %d total matches\n", m );
         cvNamedWindow( "Matches", 1 );
         cvShowImage( "Matches", stacked );
         cvWaitKey( 0 );
    cvReleaseImage( &stacked );
         cvReleaseImage( &img1 );
         cvReleaseImage( &img2 );
         kdtree_release( kd_root );
         free( feat1 );
         free( feat2 );
         return m;
    i donot want help exactly with opencv but a java code to detect an object within an image will be helpful and
    help on any modification i can make on the above program will be also helpful
    thank u                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    Hi friend!
    I have the following issue:
    I'm trying to build a C++ DLL that uses OpenCV.
    But when I try to compile, I have the following errors:
    [Link Error] undefined reference to 'cvQueryFrame'
    [Link Error] undefined reference to 'cvReleaseCapture'
    [Link Error] undefined reference to 'cvReleaseImage'
    I'm using Dev-C++, and I set all the libraries directories correctly. If I try to compile an .exe file that uses OpenCV, it compiles successfully.
    Please help me! I'm getting "crazy" with that...

  • How to detect the object or session in a database with library cache lock

    Hi Everyone,
    We've been experiencing frequent and high time waits for this event: library cache lock.
    - What causes this?
    - Is there a way to detect the object being locked?
    (this doesnt show up in V$LOCK)
    - Is there a way to detect the session that is causing the lock? aka blocking session?
    (I can detect the objects being blocked, they show up in v$session)
    thanks,

    Similar post is here, maybe that helps already:
    library cache lock
    And You can read this as well:
    http://www.ixora.com.au/q+a/0101/19235723.htm

  • How to detect the size of an image

    Hi,
    I have a servlet which grabs an image (jpg or gif) from a BLOB stored in my database and sents the image back to the client through the ServletOutputStream. This all works good and the image is presented nicely. However, I now want to have my servlet detect the size of the image, and if it is too big resize the image and return it.
    As I am new to images in JAVA I am unsure how to do this and what tools to use for it. I found some information on JAI, but this seems way to elaborate for what I need. Please let me know if anyone knows how to do this.
    Thank you and regards,
    Joost Schouten

    This code figures out the size of any object in bytes. I am not sure about resizing the image though..
    public int getSerializedSize(Object object)
           try
              ByteArrayOutputStream baos = new ByteArrayOutputStream();
              ObjectOutputStream oos = new ObjectOutputStream(baos);
              oos.writeObject(object);
              byte[] bytes = baos.toByteArray();
              oos.close();
              baos.close();
              return bytes.length;
           catch(Exception e) //not good
              e.printStackTrace();
           return -1;
         }Rishi

  • Algorithm to find the area and color  of the objects in an image

    Hello everyone,
    I have some problems in finding the segmented objects once i find the threshold , i want to find the area of the objects in the image . for example i have some lymphocytes in the image and i need to seperate them from the background by labelling them. can i seperate them by using the colour as well . please give some idea .
    my code till now is:
    int data = -1;
    try {
    System.out.println("Is the input a FloatImage ?");
    m_fi_in = (FloatImage)inputData[0];
    data = 0;
    catch (ClassCastException cce) {
    System.out.println("Not a FloatImage");
    data = -1;
    try {
    System.out.println("Is the input a Volume ?");
    m_vol_in = (Volume)inputData[0];
    data = 1;
    catch (ClassCastException cce2) {
    System.out.println("Not a Volume");
    data = -1;
    System.out.println(data);
    // For the FloatImage
    if (data == 0) {
    // For the Volume
    else if(data == 1) {
    System.out.println("Entering Volume for segmentation....");
    // Get target dimensions
    int depth = m_vol_in.getDepth();
    int height = m_vol_in.getHeight();
    int width = m_vol_in.getWidth();
    int region = 1;
    // Create a label structure
    // Consists of Image and region info
    m_label = new Label(m_vol_in);
    if(m_label == null) {
    System.out.println("Label could not be created");
    return false;
    // apply the threshold set by user
    float threshold = m_threshold.getValue();
    float maxi = m_threshold.getMaximum();
    float mini = m_threshold.getMinimum();
    // label the center of the volume in the region part of label as region 1
    m_label.setRegion(m_start_z.getValue(), m_start_y.getValue(), m_start_x.getValue(), region);
    System.out.println("Set starting voxel ("+m_start_z.getValue()+","+m_start_y.getValue()+","+m_start_x.getValue()+" to "+region);
    // Now process 8 partial volumina starting from a given point in the yz-plane in positive and then negative x directions
    // check the neighbours if they are already segmented and set the region in the target volume accordingly
    // do so for the whole yz-plane
    int x,y,z;
    int dir = 0; // the direction of the search. Only initialised here !
    System.out.println("Processing Volume in z++");
    for (z = m_start_z.getValue(); z < depth-1; z++) {
    for (y = m_start_y.getValue(); y < height-1; y++) {
    dir = 1;
    for (x = m_start_x.getValue(); x < width-1; x++) {
    checkRegion(m_label, z, y, x, threshold, region, dir);
    dir = -1;
    for (x = m_start_x.getValue(); x > 0; x--) {
    checkRegion(m_label, z, y, x, threshold, region, dir);
    for (y = m_start_y.getValue(); y > 0; y--) {
    dir = 1;
    for (x = m_start_x.getValue(); x < width-1; x++) {
    checkRegion(m_label, z, y, x, threshold, region, dir);
    dir = -1;
    for (x = m_start_x.getValue(); x > 0; x--) {
    checkRegion(m_label, z, y, x, threshold, region, dir);
    System.out.println("Processing Volume in z--");
    for (z = m_start_z.getValue(); z > 0 ; z--) {
    for (y = m_start_y.getValue(); y < height-1; y++) {
    dir = 1;
    for (x = m_start_x.getValue(); x < width-1; x++) {
    checkRegion(m_label, z, y, x, threshold, region, dir);
    dir = -1;
    for (x = m_start_x.getValue(); x > 0; x--) {
    checkRegion(m_label, z, y, x, threshold, region, dir);
    for (y = m_start_y.getValue(); y > 0; y--) {
    dir = 1;
    for (x = m_start_x.getValue(); x < width-1; x++) {
    checkRegion(m_label, z, y, x, threshold, region, dir);
    dir = -1;
    for (x = m_start_x.getValue(); x > 0; x--) {
    checkRegion(m_label, z, y, x, threshold, region, dir);
    // Apply result to output
    outputData[0] = m_label;
    else {
    return false;
    }

    search for cluster analysis
    spieler

  • Detecting the resolution of external images.

    Is there any way to detect the resolution of the external jpg
    file?

    You'll need to use a SS script, like PHP. If you do use PHP,
    it's pretty
    easy though - have a look at the getimagesize() method in the
    PHP docs -
    it'll do just what you need.
    Dave -
    Head Developer
    http://www.blurredistinction.com
    Adobe Community Expert
    http://www.adobe.com/communities/experts/

  • Detect the centerpoint of an object on grey background

    I have many photos I want to center my crop script.
    It is done already, but now I want to more:
    Is it possible to detect the top right down left sides of the object in the grey background and give me the x,y center of this object?
    The object is always surrounded by grey background.
    The grey background is almost allways similar and with no dust (almost...).
    I can imagine that I could create a rough tile selection (larger or smaller), move it on all the image to read the colour and leave what is similar with the first lefttop reading. Then select al the remains: my object.
    But something tells me that there is an easy and smart way of doing this with not much processor saturation.

    Doesn't work. I only do this when the backgroung is flat color.
    My grey background has smooth variations and it trims the image on all of it, not only the object.
    It should be helpful if the trim dialogue could have a fuzziness % to tell what I want to really select.

  • Problem in the code for detecting the components on the PCB image.

    I am working on a code to detect whether all the trained components are present on the PCB or not.
    I am using the quantum camera and vision acquisition software in labview to capture the image of the PCB to be tested. Then the image is compared with the original PCB image which is having all components.
    I had written the code and it is working only at some instances. I can't understand what the problem really was. Please help to know what the problem was and also help me by specifying the requirements like camera pixel, surrounding effects when the image was being captured, camera options like ZOOM, distance of the object from the camera.
    Thank you

    Hello,
    for starters I suggest reading:
    http://zone.ni.com/reference/en-XX/help/372916M-01​/nivisionconcepts/setting_up_your_imaging_system/
    And in my opinion, you should (in the future) describe the problem more thoroughly and in detail. There is not enough information in your explanation.
    Best regards,
    K
    https://decibel.ni.com/content/blogs/kl3m3n
    "Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."

  • A cycle is detected in the object graph.  This will cause an infinite loop.

    People,
    Looking for a little guidance.  Please point me in the correct direction if I am mistaken.  I am using Jersey 2.11 and generating JAXB definitions from XSD.
    I have a periodic exception that seems to be timing based.  If I change the timing of the message sent in anyway the error does not occur.  The other issue is that the cycle reported in the error changes some times, however, the cycles reported can not occur based on the XSD definition.  I have also dumped the message before sending and it definitely does not contain the cycle reported.
    In this specific scenario, I am sending a message of NotificationType which contains a list of DocumentType, however, DocumentType can never contain NotificationType so the following cycle is not possible:
    net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3 -> net.es.nsi.pce.discovery.jaxb.NotificationType@7f06bc07 -> net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3]
    I am wondering if there could be a different reason for receiving the following exception?
    Thank you for the help,
    John
    [code]
    [ERROR] [08/22/2014 11:16:22.307] [NSI-DISCOVERY-akka.actor.default-dispatcher-4] [akka://NSI-DISCOVERY/user/discovery-notificationRouter/$c] HTTP 500 Internal Server Error
    javax.ws.rs.ProcessingException: HTTP 500 Internal Server Error
            at org.glassfish.jersey.client.ClientRuntime.invoke(ClientRuntime.java:255)
            at org.glassfish.jersey.client.JerseyInvocation$1.call(JerseyInvocation.java:667)
            at org.glassfish.jersey.client.JerseyInvocation$1.call(JerseyInvocation.java:664)
            at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
            at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
            at org.glassfish.jersey.internal.Errors.process(Errors.java:228)        at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:424)
            at org.glassfish.jersey.client.JerseyInvocation.invoke(JerseyInvocation.java:664)
            at org.glassfish.jersey.client.JerseyInvocation$Builder.method(JerseyInvocation.java:424)
            at org.glassfish.jersey.client.JerseyInvocation$Builder.post(JerseyInvocation.java:333)
            at net.es.nsi.pce.discovery.actors.NotificationActor.onReceive(NotificationActor.java:100)
            at akka.actor.UntypedActor$$anonfun$receive$1.applyOrElse(UntypedActor.scala:167)
            at akka.actor.Actor$class.aroundReceive(Actor.scala:465)
            at akka.actor.UntypedActor.aroundReceive(UntypedActor.scala:97)        at akka.actor.ActorCell.receiveMessage(ActorCell.scala:516)
            at akka.actor.ActorCell.invoke(ActorCell.scala:487)
            at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:238)
            at akka.dispatch.Mailbox.run(Mailbox.scala:220)
            at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(AbstractDispatcher.scala:393)
            at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
            at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
            at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
            at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)
    Caused by: javax.ws.rs.InternalServerErrorException: HTTP 500 Internal Server Error
            at org.glassfish.jersey.message.internal.AbstractJaxbElementProvider.writeTo(AbstractJaxbElementProvider.java:152)
            at org.glassfish.jersey.message.internal.AbstractJaxbElementProvider.writeTo(AbstractJaxbElementProvider.java:85)
            at org.glassfish.jersey.message.internal.WriterInterceptorExecutor$TerminalWriterInterceptor.invokeWriteTo(WriterInterceptorExecutor.java:265)
            at org.glassfish.jersey.message.internal.WriterInterceptorExecutor$TerminalWriterInterceptor.aroundWriteTo(WriterInterceptorExecutor.java:250)
            at org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:162)
            at org.glassfish.jersey.filter.LoggingFilter.aroundWriteTo(LoggingFilter.java:293)
            at org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:162)
            at org.glassfish.jersey.message.internal.MessageBodyFactory.writeTo(MessageBodyFactory.java:1154)
            at org.glassfish.jersey.client.ClientRequest.writeEntity(ClientRequest.java:503)
            at org.glassfish.jersey.client.HttpUrlConnector._apply(HttpUrlConnector.java:315)
            at org.glassfish.jersey.client.HttpUrlConnector.apply(HttpUrlConnector.java:227)
            at org.glassfish.jersey.client.ClientRuntime.invoke(ClientRuntime.java:246)
            ... 22 more
    Caused by: javax.xml.bind.MarshalException
    - with linked exception:
    [Exception [EclipseLink-25003] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: An error occurred marshalling the object
    Internal Exception: Exception [EclipseLink-25037] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: A cycle is detected in the object graph.  This will cause an infinite loop: net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3 -> net.es.nsi.pce.discovery.jaxb.NotificationType@7f06bc07 -> net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3]
            at org.eclipse.persistence.jaxb.JAXBMarshaller.marshal(JAXBMarshaller.java:403)
            at org.glassfish.jersey.message.internal.XmlJaxbElementProvider.writeTo(XmlJaxbElementProvider.java:139)
            at org.glassfish.jersey.message.internal.AbstractJaxbElementProvider.writeTo(AbstractJaxbElementProvider.java:150)
            ... 33 more
    Caused by: Exception [EclipseLink-25003] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: An error occurred marshalling the object
    Internal Exception: Exception [EclipseLink-25037] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: A cycle is detected in the object graph.  This will cause an infinite loop: net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3 -> net.es.nsi.pce.discovery.jaxb.NotificationType@7f06bc07 -> net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3
            at org.eclipse.persistence.exceptions.XMLMarshalException.marshalException(XMLMarshalException.java:97)
            at org.eclipse.persistence.internal.oxm.XMLMarshaller.marshal(XMLMarshaller.java:911)
            at org.eclipse.persistence.internal.oxm.XMLMarshaller.marshal(XMLMarshaller.java:848)
            at org.eclipse.persistence.jaxb.JAXBMarshaller.marshal(JAXBMarshaller.java:401)
            ... 35 more
    Caused by: Exception [EclipseLink-25037] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: A cycle is detected in the object graph.  This will cause an infinite loop: net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3 -> net.es.nsi.pce.discovery.jaxb.NotificationType@7f06bc07 -> net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3
            at org.eclipse.persistence.exceptions.XMLMarshalException.objectCycleDetected(XMLMarshalException.java:400)
            at org.eclipse.persistence.internal.oxm.XPathObjectBuilder.buildRow(XPathObjectBuilder.java:207)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:118)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:1)
            at org.eclipse.persistence.internal.oxm.XMLCompositeObjectMappingNodeValue.marshalSingleValue(XMLCompositeObjectMappingNodeValue.java:237)
            at org.eclipse.persistence.internal.oxm.XMLCompositeObjectMappingNodeValue.marshal(XMLCompositeObjectMappingNodeValue.java:149)
            at org.eclipse.persistence.internal.oxm.NodeValue.marshal(NodeValue.java:102)
            at org.eclipse.persistence.internal.oxm.record.ObjectMarshalContext.marshal(ObjectMarshalContext.java:59)
            at org.eclipse.persistence.internal.oxm.XPathNode.marshal(XPathNode.java:393)
            at org.eclipse.persistence.internal.oxm.XPathObjectBuilder.buildRow(XPathObjectBuilder.java:238)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:118)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:1)
            at org.eclipse.persistence.internal.oxm.XMLCompositeCollectionMappingNodeValue.marshalSingleValue(XMLCompositeCollectionMappingNodeValue.java:321)
            at org.eclipse.persistence.internal.oxm.XMLCompositeCollectionMappingNodeValue.marshal(XMLCompositeCollectionMappingNodeValue.java:104)
            at org.eclipse.persistence.internal.oxm.NodeValue.marshal(NodeValue.java:149)
            at org.eclipse.persistence.internal.oxm.NodeValue.marshal(NodeValue.java:102)
            at org.eclipse.persistence.internal.oxm.record.ObjectMarshalContext.marshal(ObjectMarshalContext.java:59)
            at org.eclipse.persistence.internal.oxm.XPathNode.marshal(XPathNode.java:393)
            at org.eclipse.persistence.internal.oxm.XPathObjectBuilder.buildRow(XPathObjectBuilder.java:238)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:118)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:1)
            at org.eclipse.persistence.internal.oxm.XMLMarshaller.marshal(XMLMarshaller.java:743)
            at org.eclipse.persistence.internal.oxm.XMLMarshaller.marshal(XMLMarshaller.java:901)
            ... 37 more
    [/code]

    Unfortunately, even this thread is unanswered, i am closing the thread.as it it creating problems for further posting

  • How do I 'assign a higher layer to the object on the master' (page numbers on master) I understand the layer needs to be at the top to show above placed images on pages but how do I do this?

    I've added the page numbers to my master pages. They are displaying on the pages but I have images on the individual pages that are covering the numbers. I understand I need to assign a higher layer to the object but I don't understand how to do that. Please help me? Please explain a simply clearly as possible, I've read other answers but still don't understand. Wish it was as simple as select object, right click, edit layer!
    Many thanks!

    Layers panel;
    Create new layer
    Switch to Master page
    Make sure new layer is on top in the Layers panel, if not drag the layer on top in the Layers panel.
    Select (click once on) that top layer (pen symbol appears behind that layer in the Layer panel)
    Now draw your page numbers etc on the Mastet page
    From now on, select (click once on) any Layer in the Layers panel that is below the layer you used on your Master page items and create new objects in your document pages.
    If you accidently created objects on a 'wrong' layer:
    Select those objects
    You will see a square behind the layers name in the Layers panel
    Click and hold the mouse on that square and drag it behind the name of the layer you want to move the objects to.
    Buy a book about InDesign and start learning these basic principles!

  • EJB3 Entities + Web Services: A cycle is detected in the object graph

    I have a Java EE 5 application, using Glassfish v2. My ejb project consists of a handful of entity beans, session beans, and this problem arose when I added a new web service.
    Here is a simple scenario borrowed from another forum post with a similar problem:
    Let's say I have a web service called getVehicle(int vehicleId) that returns a Vehicle object.
    Vehicle has a java.util.Set of Wheel objects.
    The Wheel object has a reference to its owner (Vehicle).
    The issue is this bi-directional relationship causes a cycle that the JAX system doesn�t like.
    Caused by: javax.xml.bind.MarshalException
    - with linked exception:
    [com.sun.istack.SAXException2: A cycle is detected in the object graph. This will cause infinitely deep XML: org.test.Vehicle at 13c6308 -> org.test.Wheel at 15880be -> org.test.Vehicle at 13c6308
                  at com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:282)
                  at com.sun.xml.bind.v2.runtime.BridgeImpl.marshal(BridgeImpl.java:110)
                  at com.sun.xml.bind.api.Bridge.marshal(Bridge.java:178)
                  at com.sun.xml.ws.message.jaxb.JAXBMessage.writePayloadTo(JAXBMessage.java:299)
                  ... 54 more
    The one bit of information that I found that might fix this doesn't do much for me:
    https://jaxb.dev.java.net/guide/Mapping_cyclic_references_to_XML.html
    What options do I have to make my soap method work?
    Thanks,
    Hugh                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    i have got the same issue�C
    how did you implement onCycleDetected method�H
    can you send your full code to my mail [email protected]
    thanks !

  • JPA:A cycle is detected in the object graph

    HI Friends,
    I am facing bit too many errors while working with JPA.unfortunately we dont have proper examples which can provided  clarity.
    Here in my case : I have Two Entities
    One to One bidirectional.
      EMPLOYEE
      CUBICLE.
    Employee.java
    @Entity
    @Table(name = "CS1_EMPLOYEE")
    public class Employee {
         @Id
         private int id;
         private String name;
        @OneToOne(cascade=CascadeType.ALL)
        private Cubicle cubicle;
         public int getId() {
              return id;
         public void setId(int id) {
              this.id = id;
         public String getName() {
              return name;
         public void setName(String name) {
              this.name = name;
         public Cubicle getCubicle() {
              return cubicle;
         public void setCubicle(Cubicle assignedCubicle) {
              this.cubicle = assignedCubicle;
    Cubicle.java
    @Entity
    @Table(name = "CS1_CUBICLE")
    public class Cubicle {
         @Id
         private int id;
         private String cubeName;
         // Bidirectional
         @OneToOne(mappedBy="cubicle",cascade=CascadeType.ALL)
         private Employee employee;
         public int getId() {
              return id;
         public void setId(int id) {
              this.id = id;
         public String getCubeName() {
              return cubeName;
         public void setCubeName(String cubeName) {
              this.cubeName = cubeName;
         public Employee getEmployee() {
              return employee;
         public void setEmployee(Employee residentEmployee) {
              this.employee = residentEmployee;
    *sql file*
    CREATE TABLE "CS1_EMPLOYEE"
        "ID"           Integer    NOT NULL,
        "NAME"         Varchar (12) UNICODE,
        "CUBICLE_ID"   Integer,
        PRIMARY KEY ("ID")
    CREATE TABLE "CS1_CUBICLE"
    "ID"          Integer    NOT NULL,
        "CUBENAME"      Varchar (12) UNICODE,
        PRIMARY KEY ("ID")
    Session Bean(EJB)
    when i test this method i am gettig the error(Method In Bean)
    public Cubicle findCubicleById(int id)
         String jpql = "select c from Cubicle c where c.id = " +id;
             Query q = em.createQuery(jpql);
             Cubicle c = (Cubicle)q.getSingleResult();
             return c;
    error
    [com.sun.istack.SAXException2: A cycle is detected in the object graph. This will cause infinitely deep XML: com.sap.com.jpacasestudy1.model.Employee@1ae5bf7 -> com.sap.com.jpacasestudy1.model.Cubicle@75e38d -> com.sap.com.jpacasestudy1.model.Employee@1ae5bf7])->com.sap.engine.services.webservices.espbase.server.additions.exceptions.ProcessException: Connection IO Exception. Check nested exception for details. (Exception; nested exception is:  javax.xml.bind.MarshalException
    I am unable to trace what the error is.Any help from SDN Experts?
    Regards
    Chandra Dasari
    Edited by: chandra shekar dasari on Jul 16, 2009 1:48 PM:ver1te
    Edited by: chandra shekar dasari on Jul 16, 2009 1:49 PM:code re

    Unfortunately, even this thread is unanswered, i am closing the thread.as it it creating problems for further posting

  • Does any body knows how to detect the resolution of an inserted image in word?

    Does any body knows how to detect the resolution of an inserted image in word?

    I'm not sure I understand your reply but when you insert images into Word that are larger than will fit on the page, they are automatically compressed. If you right click and select Size and Position you can restore it to 100% but you will not see all the image.
    See www.grainge.org for RoboHelp and Authoring tips
    @petergrainge

  • Calculate the perimeter of object in binary image how!!!!!!!

    Hi 
     I try to use labview to find area and perimeter of object in binary using vision function
    for the area the labview find it in pixel]
    but for   perimeter I have problem I read from ni.com vision manual this words
    http://zone.ni.com/reference/en-XX/help/372916M-01​/nivisionconcepts/particle_measurements/
    """Length of a boundary of a region. Because the boundary of a binary image is comprised of discrete pixels, NI Vision subsamples the boundary points to approximate a smoother, more accurate perimeter. Boundary points are the pixel corners that form the boundary of the particle. Refer to the introduction for an illustration of pixel corners."""
    what is the problem I really did not understand what he mean::"""Because the boundary of a binary image is comprised of discrete pixels""
    can any one explain to us the case please and who will lv find the  perimeter
    best regards
    hi ?Q>

    Hornless.Rhino wrote:
    mangood wrote:
    what is the problem I really did not understand what he mean::"""Because the boundary of a binary image is comprised of discrete pixels""
    can any one explain to us the case please and who will lv find the  perimeter
    best regards
    Take the following image on the left. You can see it is quite jagged.
    Since pixels are square/rectangular you cannot have a perfectly straight edge on a line that is not horizontal or vertical.
    But looking at how the edge of the object actually is, the jaggedness can be "smoothed out" and hence help determine what the perimiter should be were it perfectly smooth.
    thank you 
    do you mean that lv do a low pass filter for image before he caculate the  perimeter?????
    finally which connectivity is best 4 or 8 for finding the perimeter??? or which algorthem used by lv to find the  perimeter???
    best regards
    hi ?Q>

  • Can you stitch digital TIFFs taken from all sides of the object into a 3D image in CS-6

    Can you stitch digital TIFFs taken from all sides of the object into a 3d image in CS-6

    It depends on the object. The mesh must have surfaces (texture names) for each side of that object. Then an image can be applied to each side.
    Photoshop currently lacks a way to select a side and give it a name.
    You may want to try a program like blender to assign surfaces to a mesh. It is a very robust and daunting program, but its free and if you have the time maybe worth your while to learn it.

Maybe you are looking for