Detecting Nude Pictures in WPMU-Blogs?

Hello,

what do you do on Edublogs against Nude pictures and/or more explicit content?

I know there are scripts available which can detect an unusal high amount of skin (and still sort out faces).

Many thanks...

Regards Bernd

  • Tom Eagles
    • Syntax Hero

    @bthes

    Hey great question answer is i don't know, edublogs has a lot of customisation done to it, I will check with @Sue Waters the edublogs support manager as to how they handle it for you. In the mean time i will have a hunt round for any plugins that may cover this for you.

    Kindest Regards

    Tom

  • bthes
    • Flash Drive

    HI Tom,

    thanks for the fast response. What I need is a "plugin" which informs me of such incidents. I want to build a website in which they can sjowcase there work, but nude only in private and password protected Galleries.

    Here is a Javascript example: http://www.patrick-wied.at/static/nudejs/. He handles also detection of faces.... (but I don't want to handle that on the Client).

    Here is some Phyton-code I found on the web, but never tried it :slight_smile: They classify Porn as a Skinrate over 30% (but no Face-Portrait-Detection)

    #!python
    import os, glob
    from PIL import Image

    def get_skin_ratio(im):
    im = im.crop((int(im.size[0]*0.2), int(im.size[1]*0.2), im.size[0]-int(im.size[0]*0.2), im.size[1]-int(im.size[1]*0.2)))
    skin = sum([count for count, rgb in im.getcolors(im.size[0]*im.size[1]) if rgb[0]>60 and rgb[1]<(rgb[0]*0.85) and rgb[2]<(rgb[0]*0.7) and rgb[1]>(rgb[0]*0.4) and rgb[2]>(rgb[0]*0.2)])
    return float(skin)/float(im.size[0]*im.size[1])

    for image_dir in ('porn','clean'):
    for image_file in glob.glob(os.path.join(image_dir,"*.jpg")):
    skin_percent = get_skin_ratio(Image.open(image_file)) * 100
    if skin_percent>30:
    print "PORN {0} has {1:.0f}% skin".format(image_file, skin_percent)
    else:
    print "CLEAN {0} has {1:.0f}% skin".format(image_file, skin_percent)

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.