Module ImportFrom alias alias Import alias Import alias ImportFrom alias ImportFrom alias Assign NameStore Call AttributeLoad NameLoad attr Str FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If CompareIsNot NameLoad NameLoad body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr Str Num If CompareIsNot NameLoad NameLoad body Assign NameStore NameLoad Assign NameStore Call AttributeLoad Str attr ListLoad NameLoad NameLoad Return Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad decorator_list Call NameLoad NameLoad FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num body Expr Str Assign NameStore BinOpSub SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num Assign NameStore BinOpSub SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num Assign NameStore BinOpMult NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Num Assign NameStore BinOpMult NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Num If CompareIs NameLoad AttributeLoad NameLoad attr body Assign NameStore NameLoad Assign NameStore BinOpAdd NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Num orelse If CompareIs NameLoad AttributeLoad NameLoad attr body Assign NameStore BinOpSub SubscriptLoad AttributeLoad NameLoad attr Index Num NameLoad Assign NameStore BinOpSub NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Num orelse Assign NameStore BinOpDiv NameLoad Num Assign NameStore BinOpSub SubscriptLoad AttributeLoad NameLoad attr Index Num NameLoad If CompareIs NameLoad AttributeLoad NameLoad attr body Assign NameStore NameLoad Assign NameStore BinOpAdd NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Num orelse If CompareIs NameLoad AttributeLoad NameLoad attr body Assign NameStore BinOpSub SubscriptLoad AttributeLoad NameLoad attr Index Num NameLoad Assign NameStore BinOpSub NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Num orelse Assign NameStore BinOpDiv NameLoad Num Assign NameStore BinOpSub SubscriptLoad AttributeLoad NameLoad attr Index Num NameLoad Assign NameStore ListLoad NameLoad NameLoad NameLoad NameLoad For TupleStore NameStore NameStore Call NameLoad NameLoad body If CompareLt NameLoad Num body Raise Call NameLoad Str Assign SubscriptStore NameLoad Index NameLoad Call NameLoad Call NameLoad NameLoad Return Call NameLoad NameLoad decorator_list
N/A __future__ print_function division N/A logging N/A os watermark.logutils log_start watermark.constants Position N/A logger N/A N/A logging getLogger watermark.utils get_new_filepath N/A N/A file_path new_path ext N/A None N/A N/A 
    Get image name from old path, and assigns to new path

    :param file_path:
    :param new_path:
    :param ext: extension of output file eg: jpg
    :return:
     N/A filename N/A N/A N/A os path basename file_path N/A N/A ext None N/A N/A N/A _filename _fileext N/A N/A filename rsplit . 1 N/A N/A _fileext ext N/A N/A _fileext ext N/A filename N/A N/A . join N/A _filename _fileext N/A N/A N/A N/A os path join new_path filename N/A N/A log_start logger get_watermark_box N/A N/A im wmim posy posx wmspacing N/A N/A Position BOTTOM N/A Position RIGHT 0.037 N/A N/A 
    Get box sizes of watermark image and sends back box and location
    :param im:
    :param wmim:
    :param position:
    :param wmspacing: .037 default
    :return: tuple: Position of watermark eg : (12,
     N/A delta_width N/A N/A N/A im size N/A 0 N/A N/A wmim size N/A 0 N/A delta_height N/A N/A N/A im size N/A 1 N/A N/A wmim size N/A 1 N/A width_spacing N/A wmspacing N/A N/A im size N/A 0 N/A height_spacing N/A wmspacing N/A N/A im size N/A 1 N/A N/A posx N/A Position LEFT N/A N/A left width_spacing N/A right N/A left N/A N/A wmim size N/A 0 N/A N/A N/A posx N/A Position RIGHT N/A N/A right N/A N/A N/A im size N/A 0 width_spacing N/A left N/A right N/A N/A wmim size N/A 0 N/A N/A left N/A delta_width 2 N/A right N/A N/A N/A im size N/A 0 left N/A N/A posy N/A Position TOP N/A N/A top height_spacing N/A bottom N/A top N/A N/A wmim size N/A 1 N/A N/A N/A posy N/A Position BOTTOM N/A N/A bottom N/A N/A N/A im size N/A 1 height_spacing N/A top N/A bottom N/A N/A wmim size N/A 1 N/A N/A top N/A delta_height 2 N/A bottom N/A N/A N/A im size N/A 1 top N/A result N/A left top right bottom N/A N/A i item N/A enumerate result N/A N/A N/A item 0 N/A N/A N/A ValueError Watermark image is larger than source image, Skipping N/A N/A result N/A i N/A int N/A round item N/A N/A tuple result N/A