python /home/admin/mtr/script_for_cron.py -j datou_current3 -m 20 -a ' -a 4302 -v ' -s datou_current_4302 -M 0 -S 0 -U 95,95,120 import MySQLdb succeeded Import error (python version) ['/Users/moilerat/Documents/Fotonower/install/caffe/distribute/python', '/home/admin/workarea/git/Velours/python/prod', '/home/admin/workarea/install/caffe_cuda8_python3/python', '/home/admin/workarea/install/darknet', '/home/admin/workarea/git/Velours/python', '/home/admin/workarea/install/caffe_frcnn_python3/py-faster-rcnn/caffe-fast-rcnn/python', '/home/admin/mtr/.credentials', '/home/admin/workarea/install/caffe/python', '/home/admin/workarea/install/caffe_frcnn/py-faster-rcnn/tools', '/home/admin/workarea/git/fotonowerpip', '/home/admin/workarea/install/segment-anything', '/home/admin/workarea/git/pyfvs', '/usr/lib/python38.zip', '/usr/lib/python3.8', '/usr/lib/python3.8/lib-dynload', '/home/admin/.local/lib/python3.8/site-packages', '/usr/local/lib/python3.8/dist-packages', '/usr/lib/python3/dist-packages'] Namespace(auto=False, cert_args='/home/fotonower/https/cert.pem', contextDataFile='', custom_size=0, database='', datou_id='4302', datou_id_excluded='', fifo=False, host='', is_cpu_mode=False, job='batch_current', json_args='', key_args='/home/fotonower/https/vision.fotonower.com.key', limit=1000, list_photo_ids='', local='', mtr_current_id=0, mtr_portfolio_ids='', nb_thread=1, no_current=False, offset=0, only_client=False, output_file='', password='', port=5100, rand=0, save=2, use_client=False, user_id=440, username='', verbose=True) process id : 1227312 load datou : 4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! Unexpected type seems boolean for variable list_input_json ERROR or WARNING : can't parse json string Expecting value: line 1 column 1 (char 0) Tried to parse : None was removed should we ? donnée sous forme de texte was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? id de la photo (peut être local ou global) was removed should we ? donnée sous forme de texte was removed should we ? donnée sous forme de texte was removed should we ? donnée sous forme de texte was removed should we ? None was removed should we ? donnée sous forme de nombre was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? donnée sous forme de texte was removed should we ? None was removed should we ? donnée sous forme de texte was removed should we ? [ptf_id0,ptf_id1...] was removed should we ? load thcls load pdts Running datou job : batch_current 4302 [] TODO datou_current to load to do maybe to take outside batchDatouExec SELECT * from MTRPhoto.mtr_datou_current where state = 0 AND mtr_portfolio_id is not NULL AND mtd_id = 4302 order by created_at desc LIMIT 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (2588223) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (2588223) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562858 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['2588223'] with mtr_portfolio_ids : ['20562858'] and first list_photo_ids : [] new path : /proc/1227312/ Name: python3 Umask: 0002 State: R (running) Tgid: 1227312 Ngid: 0 Pid: 1227312 PPid: 1227311 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 1227312 NSpid: 1227312 NSpgid: 1222543 NSsid: 1222543 VmPeak: 1106932 kB VmSize: 1106932 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 98068 kB VmRSS: 98068 kB RssAnon: 59764 kB RssFile: 38304 kB RssShmem: 0 kB VmData: 865684 kB VmStk: 132 kB VmExe: 2640 kB VmLib: 130468 kB VmPTE: 604 kB VmSwap: 0 kB HugetlbPages: 0 kB CoreDumping: 0 THP_enabled: 1 Threads: 1 SigQ: 0/63054 SigPnd: 0000000000000000 ShdPnd: 0000000000000000 SigBlk: 0000000000000000 SigIgn: 0000000001001000 SigCgt: 0000000180000002 CapInh: 0000000000000000 CapPrm: 0000000000000000 CapEff: 0000000000000000 CapBnd: 000001ffffffffff CapAmb: 0000000000000000 NoNewPrivs: 0 Seccomp: 0 Seccomp_filters: 0 Speculation_Store_Bypass: thread vulnerable SpeculationIndirectBranch: conditional enabled Cpus_allowed: ffffffff,ffffffff,ffffffff,ffffffff Cpus_allowed_list: 0-127 Mems_allowed: 00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001 Mems_allowed_list: 0 voluntary_ctxt_switches: 57 nonvoluntary_ctxt_switches: 174 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '1227312', 'Ngid': '0', 'Pid': '1227312', 'PPid': '1227311', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '1227312', 'NSpid': '1227312', 'NSpgid': '1222543', 'NSsid': '1222543', 'VmPeak': '1106932 kB', 'VmSize': '1106932 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '98068 kB', 'VmRSS': '98068 kB', 'RssAnon': '59764 kB', 'RssFile': '38304 kB', 'RssShmem': '0 kB', 'VmData': '865684 kB', 'VmStk': '132 kB', 'VmExe': '2640 kB', 'VmLib': '130468 kB', 'VmPTE': '604 kB', 'VmSwap': '0 kB', 'HugetlbPages': '0 kB', 'CoreDumping': '0', 'THP_enabled': '1', 'Threads': '1', 'SigQ': '0/63054', 'SigPnd': '0000000000000000', 'ShdPnd': '0000000000000000', 'SigBlk': '0000000000000000', 'SigIgn': '0000000001001000', 'SigCgt': '0000000180000002', 'CapInh': '0000000000000000', 'CapPrm': '0000000000000000', 'CapEff': '0000000000000000', 'CapBnd': '000001ffffffffff', 'CapAmb': '0000000000000000', 'NoNewPrivs': '0', 'Seccomp': '0', 'Seccomp_filters': '0', 'Speculation_Store_Bypass': 'thread vulnerable', 'SpeculationIndirectBranch': 'conditional enabled', 'Cpus_allowed': 'ffffffff,ffffffff,ffffffff,ffffffff', 'Cpus_allowed_list': '0-127', 'Mems_allowed': '00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001', 'Mems_allowed_list': '0', 'voluntary_ctxt_switches': '57', 'nonvoluntary_ctxt_switches': '174'} ('datou_batch_current', '1227312', '1106932', '0', '1106932', '865684', '98068', b'', 'marlene', '2588223') insert ignore into MTRAdmin.mem_info (script_name, PID, VMpeak,VMswap,VMsize,VMdata,VMrss,GPU_ram, hostname, mtr_current_id) VALUES (%s,%s,%s,%s,%s,%s,%s,%s,%s,%s) Inside batchDatouExec : verbose : True ##### chargement datou SELECT name, created_at,limit_max FROM MTRDatou.mtr_datou WHERE id=4302 SELECT mtd.id, mtdt.`type`, mtd.`param`, mtd.param_json, mtdt.nb_input, mtdt.nb_output, mtdt.prod, mtdt.is_local, mtdt.is_datou_depend, mtdt.is_photo_id_local FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_step_types mtdt WHERE mtdt.`id`=mtd.`type` AND mtd.mtd_id=4302 SELECT mtd.id, mtd.mtd_id, mdsdt.id, mdsdt.name, mdsdt.description, msid.output_or_input, msid.data_order_id, mdsdt.type FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_steptype_io_datatypes msid, MTRDatou.mtr_datou_step_data_types mdsdt WHERE mtd.`type`=msid.`mtr_datou_step_type` AND mtd.mtd_id= 4302 AND msid.data_type=mdsdt.id SELECT mts_id_output, id_output, mts_id_input, id_input FROM MTRDatou.mtr_datou_step_by_step WHERE mtd_id=4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! no param json to modify List Step Type Loaded in datou : ventilate_hashtags_in_portfolio, final, velours_tree, send_mail_cod, split_time_score over limit max, limiting to limit_max 200 list_input_json : [] ##### fin chargement datou ##### chargement data ##### Call load_data_input : nb_thread : 1 origin SELECT ph.photo_id, ph.url FROM MTRBack.photos ph WHERE ph.photo_id IN (SELECT mtr_photo_id from MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id in (20562858) and hide_status = 0 ) AND ph.photo_id not in (SELECT mtr_photo_id from MTRPhoto.mtr_datou_result_search where mtr_current_id in (2588223 ) ) ORDER BY ph.photo_id DESC LIMIT 0, 200 We have 1 , {} SELECT mtr_photo_id, mtr_portfolio_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id in (20562858) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1337656467, 'portfolio_id': 20562858}, {'photo_id': 1337656460, 'portfolio_id': 20562858}, {'photo_id': 1337656451, 'portfolio_id': 20562858}, {'photo_id': 1337656446, 'portfolio_id': 20562858}, {'photo_id': 1337656420, 'portfolio_id': 20562858}, {'photo_id': 1337656417, 'portfolio_id': 20562858}, {'photo_id': 1337656409, 'portfolio_id': 20562858}, {'photo_id': 1337656407, 'portfolio_id': 20562858}, {'photo_id': 1337656400, 'portfolio_id': 20562858}, {'photo_id': 1337656398, 'portfolio_id': 20562858}, {'photo_id': 1337656226, 'portfolio_id': 20562858}, {'photo_id': 1337656222, 'portfolio_id': 20562858}, {'photo_id': 1337656220, 'portfolio_id': 20562858}, {'photo_id': 1337656184, 'portfolio_id': 20562858}, {'photo_id': 1337656179, 'portfolio_id': 20562858}, {'photo_id': 1337656174, 'portfolio_id': 20562858}, {'photo_id': 1337656170, 'portfolio_id': 20562858}, {'photo_id': 1337656166, 'portfolio_id': 20562858}, {'photo_id': 1337656107, 'portfolio_id': 20562858}, {'photo_id': 1337656102, 'portfolio_id': 20562858}, {'photo_id': 1337656099, 'portfolio_id': 20562858}, {'photo_id': 1337656095, 'portfolio_id': 20562858}, {'photo_id': 1337656091, 'portfolio_id': 20562858}, {'photo_id': 1337656083, 'portfolio_id': 20562858}, {'photo_id': 1337656021, 'portfolio_id': 20562858}, {'photo_id': 1337656017, 'portfolio_id': 20562858}, {'photo_id': 1337656014, 'portfolio_id': 20562858}, {'photo_id': 1337655727, 'portfolio_id': 20562858}, {'photo_id': 1337655723, 'portfolio_id': 20562858}, {'photo_id': 1337655719, 'portfolio_id': 20562858}, {'photo_id': 1337655716, 'portfolio_id': 20562858}, {'photo_id': 1337655713, 'portfolio_id': 20562858}, {'photo_id': 1337655711, 'portfolio_id': 20562858}, {'photo_id': 1337654669, 'portfolio_id': 20562858}, {'photo_id': 1337654604, 'portfolio_id': 20562858}, {'photo_id': 1337654593, 'portfolio_id': 20562858}, {'photo_id': 1337654592, 'portfolio_id': 20562858}, {'photo_id': 1337654566, 'portfolio_id': 20562858}, {'photo_id': 1337654565, 'portfolio_id': 20562858}, {'photo_id': 1337654563, 'portfolio_id': 20562858}, {'photo_id': 1337654561, 'portfolio_id': 20562858}, {'photo_id': 1337654559, 'portfolio_id': 20562858}, {'photo_id': 1337654528, 'portfolio_id': 20562858}, {'photo_id': 1337654527, 'portfolio_id': 20562858}, {'photo_id': 1337654522, 'portfolio_id': 20562858}, {'photo_id': 1337654505, 'portfolio_id': 20562858}, {'photo_id': 1337654500, 'portfolio_id': 20562858}, {'photo_id': 1337654499, 'portfolio_id': 20562858}, {'photo_id': 1337654460, 'portfolio_id': 20562858}, {'photo_id': 1337654458, 'portfolio_id': 20562858}, {'photo_id': 1337654456, 'portfolio_id': 20562858}, {'photo_id': 1337654455, 'portfolio_id': 20562858}, {'photo_id': 1337654426, 'portfolio_id': 20562858}, {'photo_id': 1337654423, 'portfolio_id': 20562858}, {'photo_id': 1337654418, 'portfolio_id': 20562858}, {'photo_id': 1337654414, 'portfolio_id': 20562858}, {'photo_id': 1337654409, 'portfolio_id': 20562858}, {'photo_id': 1337654402, 'portfolio_id': 20562858}, {'photo_id': 1337654216, 'portfolio_id': 20562858}, {'photo_id': 1337654212, 'portfolio_id': 20562858}, {'photo_id': 1337654160, 'portfolio_id': 20562858}, {'photo_id': 1337654157, 'portfolio_id': 20562858}] map_portfolio_id_photo_id: {20562858: [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398, 1337656226, 1337656222, 1337656220, 1337656184, 1337656179, 1337656174, 1337656170, 1337656166, 1337656107, 1337656102, 1337656099, 1337656095, 1337656091, 1337656083, 1337656021, 1337656017, 1337656014, 1337655727, 1337655723, 1337655719, 1337655716, 1337655713, 1337655711, 1337654669, 1337654604, 1337654593, 1337654592, 1337654566, 1337654565, 1337654563, 1337654561, 1337654559, 1337654528, 1337654527, 1337654522, 1337654505, 1337654500, 1337654499, 1337654460, 1337654458, 1337654456, 1337654455, 1337654426, 1337654423, 1337654418, 1337654414, 1337654409, 1337654402, 1337654216, 1337654212, 1337654160, 1337654157]} ##### Call download_photos : nb_thread : 1 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos ##### After load_data_input time to download the photos : 0.015793561935424805 #### fin chargement data Blocking on flush ? No conitnuing About to test input to load Calling datou_exec Inside datou_exec : verbose : True number of steps : 5 step1:ventilate_hashtags_in_portfolio Fri Feb 14 16:28:57 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (20562858) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} beginning of datou step ventilate_hashtags_in_portfolio : To implement ! To do loadFromThcl(), then load ParamDescType : thcl2725 get_desc_type_from_thcl : type of cat SELECT id, mtr_user_id, name, pb_hashtag_id, hashtag_id_list, button_legend_list, portfolio_id_lists, photo_hashtag_type, photo_desc_type, svm_limit, limit_tagging, is_public, live, created_at, updated_at, type_classification FROM MTRDatou.classification_theme WHERE `id` IN (2725) thcls : [{'id': 2725, 'mtr_user_id': 31, 'name': 'learn_qualipapia_rle_210302_2', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': 'Carton_brun,Carton_gris,Teint_Dans_La_Masse,autre_refus,cartonnette,environnement,kraft,metal,papier,plastique', 'svm_portfolios_learning': '3460440,3460441,3460446,3460434,3460439,3467416,3460442,3460443,3486028,3460445', 'photo_hashtag_type': 3410, 'photo_desc_type': 5186, 'type_classification': 'caffe', 'hashtag_id_list': '2107753024,2107753020,2107752385,2107752406,702398920,493012381,493202403,492628673,492668766,492725882'}] thcl {'id': 2725, 'mtr_user_id': 31, 'name': 'learn_qualipapia_rle_210302_2', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': 'Carton_brun,Carton_gris,Teint_Dans_La_Masse,autre_refus,cartonnette,environnement,kraft,metal,papier,plastique', 'svm_portfolios_learning': '3460440,3460441,3460446,3460434,3460439,3467416,3460442,3460443,3486028,3460445', 'photo_hashtag_type': 3410, 'photo_desc_type': 5186, 'type_classification': 'caffe', 'hashtag_id_list': '2107753024,2107753020,2107752385,2107752406,702398920,493012381,493202403,492628673,492668766,492725882'} Update svm_hashtag_type_desc : 5186 remove imagettes from duplicated photo Iterating over portfolio : 20562858 get user id for portfolio 20562858 get sub ptf for main ptf 20562858, type 3726 and hashtags ['cartonnette', 'kraft', 'environnement', 'mal_croppe', 'papier', 'Carton_gris', 'flou', 'autre_refus', 'plastique', 'metal', 'Teint_Dans_La_Masse', 'Carton_brun'] SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=20562858 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('cartonnette','kraft','environnement','mal_croppe','papier','Carton_gris','flou','autre_refus','plastique','metal','Teint_Dans_La_Masse','Carton_brun')) AND mptpi.`min_score`=0.5 SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=20562858 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('cartonnette','kraft','environnement','mal_croppe','papier','Carton_gris','flou','autre_refus','plastique','metal','Teint_Dans_La_Masse','Carton_brun')) AND mptpi.`min_score`=0.5 To do returned map {'plastique': {'main_port_id': 20562858, 'sub_port_id': 20562884, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225143, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'metal': {'main_port_id': 20562858, 'sub_port_id': 20562885, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225144, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'Carton_brun': {'main_port_id': 20562858, 'sub_port_id': 20562887, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225145, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'environnement': {'main_port_id': 20562858, 'sub_port_id': 20562893, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225146, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'cartonnette': {'main_port_id': 20562858, 'sub_port_id': 20562899, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225147, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'Teint_Dans_La_Masse': {'main_port_id': 20562858, 'sub_port_id': 20562901, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225148, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'flou': {'main_port_id': 20562858, 'sub_port_id': 20562902, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225149, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'kraft': {'main_port_id': 20562858, 'sub_port_id': 20562903, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225150, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'autre_refus': {'main_port_id': 20562858, 'sub_port_id': 20562904, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225151, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'mal_croppe': {'main_port_id': 20562858, 'sub_port_id': 20562905, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225152, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'papier': {'main_port_id': 20562858, 'sub_port_id': 20562906, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225153, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}, 'Carton_gris': {'main_port_id': 20562858, 'sub_port_id': 20562907, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225154, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 18, 59)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562884 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='plastique' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562884) result : ((1337654539,), (1337654540,), (1337656090,), (1337656161,), (1337656162,), (1337656395,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562885 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='metal' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562885) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562887 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='Carton_brun' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562887) result : ((1337654536,), (1337654537,), (1337656033,), (1337656034,), (1337656049,), (1337656050,), (1337656084,), (1337656085,), (1337656086,), (1337656087,), (1337656152,), (1337656153,), (1337656154,), (1337656155,), (1337656156,), (1337656157,), (1337656158,), (1337656159,), (1337656160,), (1337656393,), (1337656394,), (1337656416,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562893 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='environnement' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562893) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562899 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='cartonnette' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562899) result : ((1337656080,), (1337656081,), (1337656151,), (1337656392,), (1337656413,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562901 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='Teint_Dans_La_Masse' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562901) result : ((1337656031,), (1337656038,), (1337656073,), (1337656074,), (1337656075,), (1337656149,), (1337656386,), (1337656387,), (1337656411,), (1337656412,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562902 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='flou' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562902) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562903 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='kraft' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562903) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562904 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='autre_refus' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562904) result : ((1337656076,), (1337656218,), (1337656388,), (1337656389,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562905 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='mal_croppe' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562905) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562906 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='papier' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562906) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 20562907 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=20562858 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='Carton_gris' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562907) result : ((1337654532,), (1337654533,), (1337656047,), (1337656048,), (1337656077,), (1337656078,), (1337656150,), (1337656219,), (1337656390,), (1337656391,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20562858) result : ((1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in (1337656400,1337654500) and cspi.crop_hashtag_id = chi.id; To do ! Use context local managing function ! SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=20562858 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('cartonnette','kraft','environnement','mal_croppe','papier','Carton_gris','flou','autre_refus','plastique','metal','Teint_Dans_La_Masse','Carton_brun')) AND mptpi.`min_score`=0.5 SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=20562858 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('cartonnette','kraft','environnement','mal_croppe','papier','Carton_gris','flou','autre_refus','plastique','metal','Teint_Dans_La_Masse','Carton_brun')) AND mptpi.`min_score`=0.5 To do returned map {'plastique': {'main_port_id': 20562858, 'sub_port_id': 20562920, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225167, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'metal': {'main_port_id': 20562858, 'sub_port_id': 20562921, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225168, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'Carton_brun': {'main_port_id': 20562858, 'sub_port_id': 20562922, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225169, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'environnement': {'main_port_id': 20562858, 'sub_port_id': 20562923, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225170, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'cartonnette': {'main_port_id': 20562858, 'sub_port_id': 20562924, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225171, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'Teint_Dans_La_Masse': {'main_port_id': 20562858, 'sub_port_id': 20562925, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225172, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'flou': {'main_port_id': 20562858, 'sub_port_id': 20562926, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225173, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'kraft': {'main_port_id': 20562858, 'sub_port_id': 20562927, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225174, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'autre_refus': {'main_port_id': 20562858, 'sub_port_id': 20562928, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225175, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'mal_croppe': {'main_port_id': 20562858, 'sub_port_id': 20562929, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225176, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'papier': {'main_port_id': 20562858, 'sub_port_id': 20562930, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225177, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 19), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}, 'Carton_gris': {'main_port_id': 20562858, 'sub_port_id': 20562931, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 13225178, 'last_updated_at': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_desc': datetime.datetime(2025, 2, 14, 16, 26, 57), 'last_updated_at_asc': datetime.datetime(2025, 2, 14, 16, 19)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562920,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562884 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562921,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562885 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562922,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562887 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562923,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562893 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562924,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562899 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562925,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562901 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562926,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562902 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562927,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562903 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562928,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562904 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562929,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562905 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562930,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562906 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 20562931,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 20562907 lien utilise dans velours : https://www.fotonower.com/velours/20562920,20562921,20562922,20562923,20562924,20562925,20562926,20562927,20562928,20562929,20562930,20562931?tags=plastique,metal,Carton_brun,environnement,cartonnette,Teint_Dans_La_Masse,flou,kraft,autre_refus,mal_croppe,papier,Carton_gris After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([20562858]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398] map_info['map_portfolio_photo'] : {20562858: [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398, 1337656226, 1337656222, 1337656220, 1337656184, 1337656179, 1337656174, 1337656170, 1337656166, 1337656107, 1337656102, 1337656099, 1337656095, 1337656091, 1337656083, 1337656021, 1337656017, 1337656014, 1337655727, 1337655723, 1337655719, 1337655716, 1337655713, 1337655711, 1337654669, 1337654604, 1337654593, 1337654592, 1337654566, 1337654565, 1337654563, 1337654561, 1337654559, 1337654528, 1337654527, 1337654522, 1337654505, 1337654500, 1337654499, 1337654460, 1337654458, 1337654456, 1337654455, 1337654426, 1337654423, 1337654418, 1337654414, 1337654409, 1337654402, 1337654216, 1337654212, 1337654160, 1337654157]} final : False mtd_id 4302 list_pids : [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398] Looping around the photos to save general results len do output : 1 /20562858. before output type Here is an output not treated by saveGeneral : Managing all output in save final without adding information in the mtr_datou_result ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656467', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656460', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656451', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656446', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656420', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656417', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656409', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656407', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656400', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656398', None, None, None, None, None, '2588223') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 11 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', None, '20562858', "{'plastique': 20562884, 'metal': 20562885, 'Carton_brun': 20562887, 'environnement': 20562893, 'cartonnette': 20562899, 'Teint_Dans_La_Masse': 20562901, 'flou': 20562902, 'kraft': 20562903, 'autre_refus': 20562904, 'mal_croppe': 20562905, 'papier': 20562906, 'Carton_gris': 20562907}", None, None, None, None, '2588223'), ('4302', '20562858', '1337656467', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656460', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656451', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656446', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656420', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656417', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656409', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656407', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656400', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656398', None, None, None, None, None, '2588223')] time used for this insertion : 0.0137176513671875 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.48864030838012695 time spend to save output : 0.014029979705810547 total time spend for step 1 : 0.5026702880859375 step2:final Fri Feb 14 16:28:58 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :0, first value : [] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (20562858) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} Beginning of datou step final ! query to retrieve results for portfolio 20562858 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1337654216,1337654212,1337654160,1337654157,1337654426,1337654423,1337654418,1337654414,1337654409,1337654402,1337654460,1337654458,1337654456,1337654455,1337654528,1337654527,1337654522,1337654505,1337654500,1337654499,1337654566,1337654565,1337654563,1337654561,1337654559,1337654669,1337654604,1337654593,1337654592,1337655727,1337655723,1337655719,1337655716,1337655713,1337655711,1337656021,1337656017,1337656014,1337656107,1337656102,1337656099,1337656095,1337656091,1337656083,1337656184,1337656179,1337656174,1337656170,1337656166,1337656226,1337656222,1337656220,1337656420,1337656417,1337656409,1337656407,1337656400,1337656398,1337656467,1337656460,1337656451,1337656446); insert ignore into MTRUser.portfolio_carac_ratio (portfolio_id, hashtag_type, hashtag_id, value) values (%s,%s,%s,%s) on DUPLICATE KEY UPDATE value=VALUES(value) After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([20562858]) Inside saveOutput : final : False verbose : True original output for save of step final : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} new output for save of step final : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398] map_info['map_portfolio_photo'] : {20562858: [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398, 1337656226, 1337656222, 1337656220, 1337656184, 1337656179, 1337656174, 1337656170, 1337656166, 1337656107, 1337656102, 1337656099, 1337656095, 1337656091, 1337656083, 1337656021, 1337656017, 1337656014, 1337655727, 1337655723, 1337655719, 1337655716, 1337655713, 1337655711, 1337654669, 1337654604, 1337654593, 1337654592, 1337654566, 1337654565, 1337654563, 1337654561, 1337654559, 1337654528, 1337654527, 1337654522, 1337654505, 1337654500, 1337654499, 1337654460, 1337654458, 1337654456, 1337654455, 1337654426, 1337654423, 1337654418, 1337654414, 1337654409, 1337654402, 1337654216, 1337654212, 1337654160, 1337654157]} final : False mtd_id 4302 list_pids : [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398] Looping around the photos to save general results len do output : 10 /1337656467.Didn't retrieve data . /1337656460.Didn't retrieve data . /1337656451.Didn't retrieve data . /1337656446.Didn't retrieve data . /1337656420.Didn't retrieve data . /1337656417.Didn't retrieve data . /1337656409.Didn't retrieve data . /1337656407.Didn't retrieve data . /1337656400.Didn't retrieve data . /1337656398.Didn't retrieve data . before output type Used above Used above Managing all output in save final without adding information in the mtr_datou_result ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656467', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656460', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656451', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656446', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656420', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656417', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656409', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656407', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656400', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656398', None, None, None, None, None, '2588223') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 30 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', '20562858', '1337656467', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656460', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656451', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656446', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656420', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656417', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656409', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656407', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656400', '0.02959268931527197', None, None, None, None, '2588223'), ('4302', '20562858', '1337656398', '0.02959268931527197', None, None, None, None, '2588223')] time used for this insertion : 0.013849496841430664 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.07068133354187012 time spend to save output : 0.014240503311157227 total time spend for step 2 : 0.08492183685302734 step3:velours_tree Fri Feb 14 16:28:58 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : {20562858: [{'plastique': 20562884, 'metal': 20562885, 'Carton_brun': 20562887, 'environnement': 20562893, 'cartonnette': 20562899, 'Teint_Dans_La_Masse': 20562901, 'flou': 20562902, 'kraft': 20562903, 'autre_refus': 20562904, 'mal_croppe': 20562905, 'papier': 20562906, 'Carton_gris': 20562907}]} input_args_next_step : {20562858: ()} output_args : {20562858: [{'plastique': 20562884, 'metal': 20562885, 'Carton_brun': 20562887, 'environnement': 20562893, 'cartonnette': 20562899, 'Teint_Dans_La_Masse': 20562901, 'flou': 20562902, 'kraft': 20562903, 'autre_refus': 20562904, 'mal_croppe': 20562905, 'papier': 20562906, 'Carton_gris': 20562907}]} args : 20562858 depend.output_id : 0 VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :1, first value : ({'plastique': 20562884, 'metal': 20562885, 'Carton_brun': 20562887, 'environnement': 20562893, 'cartonnette': 20562899, 'Teint_Dans_La_Masse': 20562901, 'flou': 20562902, 'kraft': 20562903, 'autre_refus': 20562904, 'mal_croppe': 20562905, 'papier': 20562906, 'Carton_gris': 20562907},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (20562858) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} can't find the photo_desc_type After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([20562858]) Inside saveOutput : final : False verbose : True ouput is None No outpout to save, returning out of save general time spend for datou_step_exec : 0.3100893497467041 time spend to save output : 7.414817810058594e-05 total time spend for step 3 : 0.3101634979248047 step4:send_mail_cod Fri Feb 14 16:28:58 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! complete output_args for input 2 : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} input_args_next_step : {1337656467: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656467 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656460 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656451 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656446 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656420 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656417 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656409 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656407 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656400 depend.output_id : 0 input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ()} output_args : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',)} args : 1337656398 depend.output_id : 0 Inconsistent number of input and output, step which parrallelize and manage error in input by avoiding sending an output for this data can't be used in tree dependencies of input and output complete output_args for input 3 : {20562858: [{'plastique': 20562884, 'metal': 20562885, 'Carton_brun': 20562887, 'environnement': 20562893, 'cartonnette': 20562899, 'Teint_Dans_La_Masse': 20562901, 'flou': 20562902, 'kraft': 20562903, 'autre_refus': 20562904, 'mal_croppe': 20562905, 'papier': 20562906, 'Carton_gris': 20562907}]} input_args_next_step : {1337656467: ('0.02959268931527197',), 1337656460: ('0.02959268931527197',), 1337656451: ('0.02959268931527197',), 1337656446: ('0.02959268931527197',), 1337656420: ('0.02959268931527197',), 1337656417: ('0.02959268931527197',), 1337656409: ('0.02959268931527197',), 1337656407: ('0.02959268931527197',), 1337656400: ('0.02959268931527197',), 1337656398: ('0.02959268931527197',), 20562858: ()} output_args : {20562858: [{'plastique': 20562884, 'metal': 20562885, 'Carton_brun': 20562887, 'environnement': 20562893, 'cartonnette': 20562899, 'Teint_Dans_La_Masse': 20562901, 'flou': 20562902, 'kraft': 20562903, 'autre_refus': 20562904, 'mal_croppe': 20562905, 'papier': 20562906, 'Carton_gris': 20562907}]} args : 20562858 depend.output_id : 0 We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :11, first value : ('0.02959268931527197',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (20562858) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} dans la step send mail cod work_area: /home/admin/workarea/git/Velours/python in order to get the selector url, please entre the license of selector SELECT photo_id, url FROM MTRBack.photos ph WHERE photo_id IN (1337656467,1337656460,1337656451,1337656446,1337656420,1337656417,1337656409,1337656407,1337656400,1337656398) Found this number of photos: 10 ##### Call download_photos : nb_thread : 5 begin to download photo : 1337656398 begin to download photo : 1337656409 begin to download photo : 1337656446 begin to download photo : 1337656467 download finish for photo 1337656409 begin to download photo : 1337656417 download finish for photo 1337656467 download finish for photo 1337656398 begin to download photo : 1337656400 download finish for photo 1337656446 begin to download photo : 1337656451 download finish for photo 1337656417 begin to download photo : 1337656420 download finish for photo 1337656400 begin to download photo : 1337656407 download finish for photo 1337656451 begin to download photo : 1337656460 download finish for photo 1337656420 download finish for photo 1337656407 download finish for photo 1337656460 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos length of list_filenames : 10 ; length of list_pids : 10 ; length of list_args : 10 results_Auto_P20562858_14-02-2025_16_28_58.pdf 20562884 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562884 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1337654539: '1739546272_3673133_1337654212_42353a8d527b2c0c1777695f1e41a482_rle_crop_3675263391_0.png', 1337654540: '1739546272_3673133_1337654212_42353a8d527b2c0c1777695f1e41a482_rle_crop_3675263381_0.png', 1337656090: '1739546513_3683306_1337654522_648745394721e0b7c47a2cc03b8529d2_rle_crop_3675266055_0.png', 1337656161: '1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266428_0.png', 1337656162: '1739546573_3684320_1337654409_0d1e2f8ba7d1079fc9d07a452cace6c6_rle_crop_3675266499_0.png', 1337656395: '1739546750_3696204_1337655713_55f277fb1231994299e011c7dfc3be42_rle_crop_3675267127_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/53872c8244e4aeb659c3c7f77f113191_87512347.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/fb5e07787f6b09f9487c7cbd2c579cba_21050032.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/68f906b9531fddf9a286ee65236efb3f_66925363.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/82892acb4831998733ed73a33099f25e_64327427.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/dfeca95a7b6057bbd2208cfd4ebc75e5_17738996.png change filename to text .imagette205628841739546938/ imagette205628841739546938/1739546750_3696204_1337655713_55f277fb1231994299e011c7dfc3be42_rle_crop_3675267127_0.png.png imagette205628841739546938/1739546272_3673133_1337654212_42353a8d527b2c0c1777695f1e41a482_rle_crop_3675263381_0.png.png imagette205628841739546938/1739546573_3684320_1337654409_0d1e2f8ba7d1079fc9d07a452cace6c6_rle_crop_3675266499_0.png.png imagette205628841739546938/1739546513_3683306_1337654522_648745394721e0b7c47a2cc03b8529d2_rle_crop_3675266055_0.png.png imagette205628841739546938/1739546272_3673133_1337654212_42353a8d527b2c0c1777695f1e41a482_rle_crop_3675263391_0.png.png imagette205628841739546938/1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266428_0.png.png imagette205628851739546939/ wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/d981bd34a0a8fe53248c63e7369faf5c_50061425.png imagette205628841739546938 20562885 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562885 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette205628851739546939 20562899 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562899 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1337656080: '1739546513_3683306_1337654527_ec07b75019d6da4760ffd319751fd60c_rle_crop_3675266012_0.png', 1337656081: '1739546513_3683306_1337654499_f7ff1d3a53646dad9a55ecdd9c45eafd_rle_crop_3675266354_0.png', 1337656151: '1739546573_3684320_1337654409_0d1e2f8ba7d1079fc9d07a452cace6c6_rle_crop_3675266498_0.png', 1337656392: '1739546750_3696204_1337655716_e80f5b7eccd5b2034569363a53587d43_rle_crop_3675267105_0.png', 1337656413: '1739546771_3696698_1337654604_7559237b7aafa4596800b95a73aec8f3_rle_crop_3675267247_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/f3ff228c1f9dffccc28b0366f17fb5bc_41706271.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/f26e121a7964a44571dd6a43092c73e7_18341932.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/938253c3d70d318a68c179a2c585bf0b_32700901.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/8fe39915876dfd469527f1f09924eaeb_24947280.png change filename to text .imagette205628991739546939/ imagette205628991739546939/1739546750_3696204_1337655716_e80f5b7eccd5b2034569363a53587d43_rle_crop_3675267105_0.png.png imagette205628991739546939/1739546513_3683306_1337654499_f7ff1d3a53646dad9a55ecdd9c45eafd_rle_crop_3675266354_0.png.png imagette205628991739546939/1739546573_3684320_1337654409_0d1e2f8ba7d1079fc9d07a452cace6c6_rle_crop_3675266498_0.png.png imagette205628991739546939/1739546513_3683306_1337654527_ec07b75019d6da4760ffd319751fd60c_rle_crop_3675266012_0.png.png imagette205628991739546939/1739546771_3696698_1337654604_7559237b7aafa4596800b95a73aec8f3_rle_crop_3675267247_0.png.png imagette205629021739546939/ imagette205629031739546939/ wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/48e50a910e4f1b620638d19de6a977cb_69289485.png imagette205628991739546939 20562902 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562902 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette205629021739546939 20562903 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562903 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette205629031739546939 20562904 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562904 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1337656076: '1739546513_3683306_1337654505_877b372be407ea3db9657e704c0f2a2b_rle_crop_3675266263_0.png', 1337656218: '1739546729_3695874_1337656017_d5c58614c457208dcb3dd641478dfbe3_rle_crop_3675266707_0.png', 1337656388: '1739546750_3696204_1337656021_3f869756a86be4d51a9add8ec49ef055_rle_crop_3675266960_0.png', 1337656389: '1739546750_3696204_1337655711_7b234f3e10bee12da1b7135167aa416d_rle_crop_3675267142_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/dbc4482a556e5f58b55e77eb81ae38e1_25020910.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/b8c7fd9482ebb26b8f3baea61590fc51_73155327.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/f7b7e23de5a7447afc4f9208f3a4d57f_40884258.png change filename to text .imagette205629041739546939/ imagette205629041739546939/1739546750_3696204_1337656021_3f869756a86be4d51a9add8ec49ef055_rle_crop_3675266960_0.png.png imagette205629041739546939/1739546513_3683306_1337654505_877b372be407ea3db9657e704c0f2a2b_rle_crop_3675266263_0.png.png imagette205629041739546939/1739546750_3696204_1337655711_7b234f3e10bee12da1b7135167aa416d_rle_crop_3675267142_0.png.png imagette205629041739546939/1739546729_3695874_1337656017_d5c58614c457208dcb3dd641478dfbe3_rle_crop_3675266707_0.png.png imagette205629051739546939/ wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/1724741589b589c0208c9d653e6db822_17929772.png imagette205629041739546939 20562905 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562905 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette205629051739546939 20562887 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562887 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1337656153: '1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266430_0.png', 1337656416: '1739546771_3696698_1337654593_67f3faf5b49960975df76d42d81d0ee9_rle_crop_3675267259_0.png', 1337656394: '1739546750_3696204_1337655719_6e50ecfb5e29d947c225dbfe633b3799_rle_crop_3675267096_0.png', 1337656393: '1739546750_3696204_1337655723_17694e177d44485d4d7fa203161c2c86_rle_crop_3675267076_0.png', 1337656160: '1739546573_3684320_1337654414_6a72f12f5df8afd63965fb241166a7df_rle_crop_3675266483_0.png', 1337656159: '1739546573_3684320_1337654414_6a72f12f5df8afd63965fb241166a7df_rle_crop_3675266480_0.png', 1337656158: '1739546573_3684320_1337654414_6a72f12f5df8afd63965fb241166a7df_rle_crop_3675266485_0.png', 1337656157: '1739546573_3684320_1337654418_4a54f4b2f2b274e376948699c72bb4e1_rle_crop_3675266461_0.png', 1337656156: '1739546573_3684320_1337654418_4a54f4b2f2b274e376948699c72bb4e1_rle_crop_3675266460_0.png', 1337656155: '1739546573_3684320_1337654418_4a54f4b2f2b274e376948699c72bb4e1_rle_crop_3675266463_0.png', 1337656154: '1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266426_0.png', 1337654536: '1739546272_3673133_1337654160_59309b4251ccc17f900f00a3d35d949f_rle_crop_3675263414_0.png', 1337656152: '1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266432_0.png', 1337656087: '1739546513_3683306_1337654499_f7ff1d3a53646dad9a55ecdd9c45eafd_rle_crop_3675266357_0.png', 1337656086: '1739546513_3683306_1337654499_f7ff1d3a53646dad9a55ecdd9c45eafd_rle_crop_3675266361_0.png', 1337656085: '1739546513_3683306_1337654500_59825373a9de94c91bc695cc1e5e9a68_rle_crop_3675266340_0.png', 1337656084: '1739546513_3683306_1337654566_066f662ff075a449c3583c65232a035d_rle_crop_3675265998_0.png', 1337656050: '1739546533_3683647_1337654458_3d8b9c8d712818043386b5e2ebacb188_rle_crop_3675266028_0.png', 1337656049: '1739546533_3683647_1337654528_a2c80a6d723e9c6b5c8f7b014f942f23_rle_crop_3675265963_0.png', 1337656034: '1739546553_3684001_1337654426_6fc5309ff1b219e1f07d225c771b2e05_rle_crop_3675265973_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/3bb8276aaae2943c285d63389ea505d2_11846552.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/11f84e714c9c3882a9040137cfb916d2_42822099.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/f98e6ee7b68786e8c6de05a04016cd4f_78630976.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/1d37a7fd0132e395a5bd1fac3977af6e_90872924.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/7a782e9d2d2993b5c96682ae34106271_41280361.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/864c051cca7792979af2225a59e7ba7b_80360772.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/1e34b4940156f687604a6495a2c469b4_59982980.png change filename to text .wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/d9fd818e84af8fcf50d52800e25d301f_84937820.png change filename to text .wget -O 9.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/2553b4bc66e49565ae86e264f6ababf8_37798469.png change filename to text .wget -O 10.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/8d9d283a0876be992dd588ac42b77830_60411355.png change filename to text .wget -O 11.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/b34b0e91855e5e0a4d6044aaf2a19035_68626917.png change filename to text .wget -O 12.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/1e5ed2909d004df705a1e40e870344c3_26984050.png change filename to text .wget -O 13.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/67ef71cbec41399eafb5475504aa03d0_55310660.png change filename to text .wget -O 14.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/07a2eeaa51b6197032f6b2aa52a83145_11609164.png change filename to text .wget -O 15.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/1bd6ddb379a3eee1b2c4af38af08368a_36046027.png change filename to text .wget -O 16.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/3ca07ec6dc3dc65c838945ee3d568b97_91304041.png change filename to text .wget -O 17.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/1b6523c2103d3243fa62875d57237314_73179698.png change filename to text .wget -O 18.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/f44ef0a499d2ba6755a47db3331996df_15313563.png change filename to text .wget -O 19.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/127bd9ed7d89724a5394a3fd2b81a616_41604444.png change filename to text .imagette205628871739546939/ imagette205628871739546939/1739546573_3684320_1337654418_4a54f4b2f2b274e376948699c72bb4e1_rle_crop_3675266463_0.png.png imagette205628871739546939/1739546513_3683306_1337654499_f7ff1d3a53646dad9a55ecdd9c45eafd_rle_crop_3675266357_0.png.png imagette205628871739546939/1739546771_3696698_1337654593_67f3faf5b49960975df76d42d81d0ee9_rle_crop_3675267259_0.png.png imagette205628871739546939/1739546573_3684320_1337654414_6a72f12f5df8afd63965fb241166a7df_rle_crop_3675266485_0.png.png imagette205628871739546939/1739546750_3696204_1337655723_17694e177d44485d4d7fa203161c2c86_rle_crop_3675267076_0.png.png imagette205628871739546939/1739546573_3684320_1337654418_4a54f4b2f2b274e376948699c72bb4e1_rle_crop_3675266461_0.png.png imagette205628871739546939/1739546272_3673133_1337654160_59309b4251ccc17f900f00a3d35d949f_rle_crop_3675263414_0.png.png imagette205628871739546939/1739546513_3683306_1337654566_066f662ff075a449c3583c65232a035d_rle_crop_3675265998_0.png.png imagette205628871739546939/1739546573_3684320_1337654418_4a54f4b2f2b274e376948699c72bb4e1_rle_crop_3675266460_0.png.png imagette205628871739546939/1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266426_0.png.png imagette205628871739546939/1739546553_3684001_1337654426_6fc5309ff1b219e1f07d225c771b2e05_rle_crop_3675265973_0.png.png imagette205628871739546939/1739546533_3683647_1337654528_a2c80a6d723e9c6b5c8f7b014f942f23_rle_crop_3675265963_0.png.png imagette205628871739546939/1739546573_3684320_1337654414_6a72f12f5df8afd63965fb241166a7df_rle_crop_3675266483_0.png.png imagette205628871739546939/1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266432_0.png.png imagette205628871739546939/1739546573_3684320_1337654414_6a72f12f5df8afd63965fb241166a7df_rle_crop_3675266480_0.png.png imagette205628871739546939/1739546513_3683306_1337654499_f7ff1d3a53646dad9a55ecdd9c45eafd_rle_crop_3675266361_0.png.png imagette205628871739546939/1739546513_3683306_1337654500_59825373a9de94c91bc695cc1e5e9a68_rle_crop_3675266340_0.png.png imagette205628871739546939/1739546750_3696204_1337655719_6e50ecfb5e29d947c225dbfe633b3799_rle_crop_3675267096_0.png.png imagette205628871739546939/1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266430_0.png.png imagette205628871739546939/1739546533_3683647_1337654458_3d8b9c8d712818043386b5e2ebacb188_rle_crop_3675266028_0.png.png wget -O 20.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/72b39e7a3cc2282b65a51e2d9a8758e8_59963136.png imagette205628871739546939 20562901 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562901 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1337656031: '1739546553_3684001_1337654426_6fc5309ff1b219e1f07d225c771b2e05_rle_crop_3675265977_0.png', 1337656038: '1739546533_3683647_1337654528_a2c80a6d723e9c6b5c8f7b014f942f23_rle_crop_3675265957_0.png', 1337656073: '1739546513_3683306_1337654566_066f662ff075a449c3583c65232a035d_rle_crop_3675266002_0.png', 1337656074: '1739546513_3683306_1337654505_877b372be407ea3db9657e704c0f2a2b_rle_crop_3675266266_0.png', 1337656075: '1739546513_3683306_1337654500_59825373a9de94c91bc695cc1e5e9a68_rle_crop_3675266343_0.png', 1337656149: '1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266427_0.png', 1337656386: '1739546750_3696204_1337655723_17694e177d44485d4d7fa203161c2c86_rle_crop_3675267081_0.png', 1337656387: '1739546750_3696204_1337655716_e80f5b7eccd5b2034569363a53587d43_rle_crop_3675267107_0.png', 1337656411: '1739546771_3696698_1337655727_e4e13d5f9a9dcf7de56b4e5117b139ef_rle_crop_3675267241_0.png', 1337656412: '1739546771_3696698_1337654592_963ad7abb00974adfcf7dce9018af96c_rle_crop_3675267273_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/d533e0f8445540fcf85051d58c0c1a26_76857010.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/c2649ce537ee4565e39a3dd75e332123_10990183.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/2689eb1311e7c5271e7f3cb67cdcce74_87858995.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/ff4008400f6a04f5ec8173d4c89b5aef_75748047.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/047b6da96da1ed2f7552717f904369d9_9527636.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/7712c61ca591641096dd7c101a7cf64c_74831480.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/bed693f2905ab4e689503d510dca86fe_79982183.png change filename to text .wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/8a44f51b00112e5550ff7b1de424bde6_63179192.png change filename to text .wget -O 9.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/99a48589c2e6362cb371741d4d9fe57a_31433377.png change filename to text .imagette205629011739546940/ imagette205629011739546940/1739546513_3683306_1337654566_066f662ff075a449c3583c65232a035d_rle_crop_3675266002_0.png.png imagette205629011739546940/1739546553_3684001_1337654426_6fc5309ff1b219e1f07d225c771b2e05_rle_crop_3675265977_0.png.png imagette205629011739546940/1739546533_3683647_1337654528_a2c80a6d723e9c6b5c8f7b014f942f23_rle_crop_3675265957_0.png.png imagette205629011739546940/1739546771_3696698_1337655727_e4e13d5f9a9dcf7de56b4e5117b139ef_rle_crop_3675267241_0.png.png imagette205629011739546940/1739546573_3684320_1337654423_4f8116cfe09f28640ebe97e10c147d2d_rle_crop_3675266427_0.png.png imagette205629011739546940/1739546513_3683306_1337654500_59825373a9de94c91bc695cc1e5e9a68_rle_crop_3675266343_0.png.png imagette205629011739546940/1739546750_3696204_1337655723_17694e177d44485d4d7fa203161c2c86_rle_crop_3675267081_0.png.png imagette205629011739546940/1739546750_3696204_1337655716_e80f5b7eccd5b2034569363a53587d43_rle_crop_3675267107_0.png.png imagette205629011739546940/1739546771_3696698_1337654592_963ad7abb00974adfcf7dce9018af96c_rle_crop_3675267273_0.png.png imagette205629011739546940/1739546513_3683306_1337654505_877b372be407ea3db9657e704c0f2a2b_rle_crop_3675266266_0.png.png wget -O 10.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/c82a1fbb1dc1db647a2c215a8c091b49_74327011.png imagette205629011739546940 20562907 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562907 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1337654532: '1739546272_3673133_1337654160_59309b4251ccc17f900f00a3d35d949f_rle_crop_3675263401_0.png', 1337654533: '1739546272_3673133_1337654160_59309b4251ccc17f900f00a3d35d949f_rle_crop_3675263406_0.png', 1337656047: '1739546533_3683647_1337654528_a2c80a6d723e9c6b5c8f7b014f942f23_rle_crop_3675265951_0.png', 1337656048: '1739546533_3683647_1337654458_3d8b9c8d712818043386b5e2ebacb188_rle_crop_3675266037_0.png', 1337656077: '1739546513_3683306_1337654566_066f662ff075a449c3583c65232a035d_rle_crop_3675266000_0.png', 1337656078: '1739546513_3683306_1337654500_59825373a9de94c91bc695cc1e5e9a68_rle_crop_3675266335_0.png', 1337656150: '1739546573_3684320_1337654402_b275605e6c7f8a5dc520f1a53d9926cb_rle_crop_3675266524_0.png', 1337656219: '1739546729_3695874_1337656017_d5c58614c457208dcb3dd641478dfbe3_rle_crop_3675266702_0.png', 1337656390: '1739546750_3696204_1337655719_6e50ecfb5e29d947c225dbfe633b3799_rle_crop_3675267091_0.png', 1337656391: '1739546750_3696204_1337655711_7b234f3e10bee12da1b7135167aa416d_rle_crop_3675267136_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/eba84938d179aa3a6c69e277b7c1790b_15025047.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/5f1e119ad57098c973d8b6d205a102a4_14358939.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/143c23ac01b98370da6ec1eb8cabc567_73018381.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/d8317e7dcd8f21defa6a5ae6541685a9_59084003.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/482a9faad0aecc45bde25f97c208ec6f_32290502.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/b79d539931ca7668d851c361ba134a64_93673733.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/e48d3944e05203061a8c9b8be10db8bb_12815065.png change filename to text .wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/d372d286298782eac4aed56c45a62556_68063090.png change filename to text .wget -O 9.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/d55e166fe0294293c461280c0609fc6e_76430540.png change filename to text .imagette205629071739546941/ imagette205629071739546941/1739546750_3696204_1337655711_7b234f3e10bee12da1b7135167aa416d_rle_crop_3675267136_0.png.png imagette205629071739546941/1739546272_3673133_1337654160_59309b4251ccc17f900f00a3d35d949f_rle_crop_3675263401_0.png.png imagette205629071739546941/1739546533_3683647_1337654458_3d8b9c8d712818043386b5e2ebacb188_rle_crop_3675266037_0.png.png imagette205629071739546941/1739546513_3683306_1337654566_066f662ff075a449c3583c65232a035d_rle_crop_3675266000_0.png.png imagette205629071739546941/1739546272_3673133_1337654160_59309b4251ccc17f900f00a3d35d949f_rle_crop_3675263406_0.png.png imagette205629071739546941/1739546513_3683306_1337654500_59825373a9de94c91bc695cc1e5e9a68_rle_crop_3675266335_0.png.png imagette205629071739546941/1739546729_3695874_1337656017_d5c58614c457208dcb3dd641478dfbe3_rle_crop_3675266702_0.png.png imagette205629071739546941/1739546533_3683647_1337654528_a2c80a6d723e9c6b5c8f7b014f942f23_rle_crop_3675265951_0.png.png imagette205629071739546941/1739546573_3684320_1337654402_b275605e6c7f8a5dc520f1a53d9926cb_rle_crop_3675266524_0.png.png imagette205629071739546941/1739546750_3696204_1337655719_6e50ecfb5e29d947c225dbfe633b3799_rle_crop_3675267091_0.png.png wget -O 10.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/aa9a01f5f7ba4c2ba7ad31da827ad204_33228836.png imagette205629071739546941 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=20562858 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/20562920,20562921,20562922,20562923,20562924,20562925,20562926,20562927,20562928,20562929,20562930,20562931?tags=plastique,metal,Carton_brun,environnement,cartonnette,Teint_Dans_La_Masse,flou,kraft,autre_refus,mal_croppe,papier,Carton_gris your option no_mail is active, we will not send the real mail to your client args[1337656467] : ('0.02959268931527197',) no score found for photo 1337656467 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656460] : ('0.02959268931527197',) no score found for photo 1337656460 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656451] : ('0.02959268931527197',) no score found for photo 1337656451 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656446] : ('0.02959268931527197',) no score found for photo 1337656446 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656420] : ('0.02959268931527197',) no score found for photo 1337656420 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656417] : ('0.02959268931527197',) no score found for photo 1337656417 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656409] : ('0.02959268931527197',) no score found for photo 1337656409 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656407] : ('0.02959268931527197',) no score found for photo 1337656407 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656400] : ('0.02959268931527197',) no score found for photo 1337656400 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com args[1337656398] : ('0.02959268931527197',) no score found for photo 1337656398 apple ('0.02959268931527197',) We are sending mail with results at report@fotonower.com refus_total : 0.02959268931527197 2022-04-13 10:29:59 0 SELECT ph.photo_id,ph.url,ph.username,ph.uploaded_at,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562858 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 1000 start upload file to ovh https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562858_14-02-2025_16_28_58.pdf results_Auto_P20562858_14-02-2025_16_28_58.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562858_14-02-2025_16_28_58.pdf start insert file to database insert into MTRUser.mtr_files (mtd_id,mtr_portfolio_id,text,url,format,tags,file_size,value) values ('4302','20562858','results_Auto_P20562858_14-02-2025_16_28_58.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562858_14-02-2025_16_28_58.pdf','pdf','','0.23','0.02959268931527197') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([20562858]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398] map_info['map_portfolio_photo'] : {20562858: [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398, 1337656226, 1337656222, 1337656220, 1337656184, 1337656179, 1337656174, 1337656170, 1337656166, 1337656107, 1337656102, 1337656099, 1337656095, 1337656091, 1337656083, 1337656021, 1337656017, 1337656014, 1337655727, 1337655723, 1337655719, 1337655716, 1337655713, 1337655711, 1337654669, 1337654604, 1337654593, 1337654592, 1337654566, 1337654565, 1337654563, 1337654561, 1337654559, 1337654528, 1337654527, 1337654522, 1337654505, 1337654500, 1337654499, 1337654460, 1337654458, 1337654456, 1337654455, 1337654426, 1337654423, 1337654418, 1337654414, 1337654409, 1337654402, 1337654216, 1337654212, 1337654160, 1337654157]} final : False mtd_id 4302 list_pids : [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398] Looping around the photos to save general results len do output : 0 before output type Used above Managing all output in save final without adding information in the mtr_datou_result ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656467', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656460', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656451', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656446', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656420', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656417', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656409', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656407', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656400', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656398', None, None, None, None, None, '2588223') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 10 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', '20562858', '1337656467', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656460', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656451', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656446', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656420', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656417', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656409', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656407', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656400', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656398', None, None, None, None, None, '2588223')] time used for this insertion : 0.013998746871948242 save_final save missing photos in datou_result : time spend for datou_step_exec : 4.5628821849823 time spend to save output : 0.014275074005126953 total time spend for step 4 : 4.577157258987427 step5:split_time_score Fri Feb 14 16:29:03 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : ['20562858'] We expect there is only one output and this part is used while all output are not tuple or array Inconsistent number of input and output, step which parrallelize and manage error in input by avoiding sending an output for this data can't be used in tree dependencies of input and output complete output_args for input 1 : VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :1, first value : [('20562858',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (20562858) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1337656467: {'path': 'temp/1739546938_1227312_1337656467_036c4636b51fd8e939b9bc42e810f7d0.jpg', 'extension': 'jpg'}, 1337656409: {'path': 'temp/1739546938_1227312_1337656409_3bc0f8bfc38a5e72e3df6a5c71e2e8b3.jpg', 'extension': 'jpg'}, 1337656417: {'path': 'temp/1739546938_1227312_1337656417_3562aecde48c1403b8daa8e6b7400bd6.jpg', 'extension': 'jpg'}, 1337656420: {'path': 'temp/1739546938_1227312_1337656420_1c3b74265b9be07b38eb3e17e22ef978.jpg', 'extension': 'jpg'}, 1337656398: {'path': 'temp/1739546938_1227312_1337656398_d678cd4c810043ec99cb9e8407b24547.jpg', 'extension': 'jpg'}, 1337656400: {'path': 'temp/1739546938_1227312_1337656400_f291c0b5fbf2cdb0d670bd117c794916.jpg', 'extension': 'jpg'}, 1337656407: {'path': 'temp/1739546938_1227312_1337656407_eafa35b0c9691e0b9e6128f374bc434c.jpg', 'extension': 'jpg'}, 1337656446: {'path': 'temp/1739546938_1227312_1337656446_e10cf39502bba08d0f4771d15b1e34f0.jpg', 'extension': 'jpg'}, 1337656451: {'path': 'temp/1739546938_1227312_1337656451_90781c4a1fba27bf5306e23ebbd3516f.jpg', 'extension': 'jpg'}, 1337656460: {'path': 'temp/1739546938_1227312_1337656460_47dc88f1ca18716b0e11823ab0310729.jpg', 'extension': 'jpg'}} map_subphoto_mainphoto : {} begin split time score SELECT app_name, token FROM MTRUser.mtr_app_api_token WHERE mtr_user_id=979 AND app_name="token_split_time_score" AND expire_at > NOW() select distinct dp.name from MTRPhoto.dashboard_entry_day ded, MTRPhoto.dashboard_places dp, MTRPhoto.dashboard_results dr where ded.dashboard_place_id = dp.id and ded.last_run_id = dr.dashboard_run_id and dp.id = ded.dashboard_place_id and dr.mtr_portfolio_id = 20562858; (('arc_en_ciel_jrm',),) TODO : Insert select and so on Begin split_port_in_batch_balle thcls : [{'id': 861, 'mtr_user_id': 31, 'name': 'Rungis_class_dechets_1212', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': 'Rungis_Aluminium,Rungis_Carton,Rungis_Papier,Rungis_Plastique_clair,Rungis_Plastique_dur,Rungis_Plastique_fonce,Rungis_Tapis_vide,Rungis_Tetrapak', 'svm_portfolios_learning': '1160730,571842,571844,571839,571933,571840,571841,572307', 'photo_hashtag_type': 999, 'photo_desc_type': 3963, 'type_classification': 'caffe', 'hashtag_id_list': '2107751280,2107750907,2107750908,2107750909,2107750910,2107750911,2107750912,2107750913'}] thcls : [{'id': 758, 'mtr_user_id': 31, 'name': 'Rungis_amount_dechets_fall_2018_v2', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': '05102018_Papier_non_papier_dense,05102018_Papier_non_papier_peu_dense,05102018_Papier_non_papier_presque_vide,05102018_Papier_non_papier_tres_dense,05102018_Papier_non_papier_tres_peu_dense', 'svm_portfolios_learning': '1108385,1108386,1108388,1108384,1108387', 'photo_hashtag_type': 856, 'photo_desc_type': 3853, 'type_classification': 'caffe', 'hashtag_id_list': '2107751013,2107751014,2107751015,2107751016,2107751017'}] select SUBSTRING(ph.text,16,2) as h, count(*) from MTRUser.mtr_portfolio_photos mpp inner join MTRBack.photos ph on mpp.mtr_photo_id = ph.photo_id where mpp.mtr_portfolio_id = 20562858 group by h (('16', 62),) SELECT ph.photo_id,ph.url,ph.username,ph.uploaded_at,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=20562858 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 100000 SELECT cps.photo_id, cps.score, h.hashtag, cps.hashtag_id, mpp1.mtr_portfolio_id FROM MTRPhoto.class_photo_score cps, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp1 where mpp1.mtr_photo_id=cps.photo_id AND h.hashtag_id=cps.hashtag_id AND mpp1.hide_status=0 AND mpp1.mtr_portfolio_id in (20562858) AND cps.thcl in (861) order by cps.score desc LIMIT 0, 100000 SELECT cps.photo_id, cps.score, h.hashtag, cps.hashtag_id, mpp1.mtr_portfolio_id FROM MTRPhoto.class_photo_score cps, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp1 where mpp1.mtr_photo_id=cps.photo_id AND h.hashtag_id=cps.hashtag_id AND mpp1.hide_status=0 AND mpp1.mtr_portfolio_id in (20562858) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 14022025 20562858 Nombre de photos uploadées : 62 / 23040 (0%) 14022025 20562858 Nombre de photos taguées (types de déchets): 0 / 62 (0%) 14022025 20562858 Nombre de photos taguées (volume) : 0 / 62 (0%) [{'photo_id': 1337654216, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/27d12525641d14fa47f1f456a0693e38.jpg', 'username': None, 'uploaded_at': 1739546167, 'text': 'image_14022025_16_15_14_010136m0.jpg 1e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1337654212, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/42353a8d527b2c0c1777695f1e41a482.jpg', 'username': None, 'uploaded_at': 1739546167, 'text': 'image_14022025_16_15_24_010132m0.jpg 2e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1337654160, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/59309b4251ccc17f900f00a3d35d949f.jpg', 'username': None, 'uploaded_at': 1739546167, 'text': 'image_14022025_16_15_33_009124m0.jpg 3.0000000000000004e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1337654157, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/2/14/1a5fb277fb773b7e1e7a10f700615e6f.jpg', 'username': None, 'uploaded_at': 1739546167, 'text': 'image_14022025_16_15_43_010141m0.jpg 4e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}] 0 [] elapsed_time : load_data_split_time_score 2.6226043701171875e-06 elapsed_time : order_list_meta_photo_and_scores 7.3909759521484375e-06 ?????????????????????????????????????????????????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.0029687881469726562 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 20562858, '2025-02-14' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1602310,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.0233609676361084 We will return after consolidate but for now we need the day, how to get it, for now depending on the previous heavy steps SELECT dri.dashboard_entry_day, dr.dashboard_run_id, dr.mtr_portfolio_id, dr.id, dr.hashtag, dr.completion_json FROM MTRPhoto.dashboard_results dr, MTRPhoto.dashboard_run_ids dri, MTRPhoto.dashboard_entry_day ded WHERE ded.id= 1602310 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1602310, 'dashboard_run_id': 1611861, 'mtr_portfolio_id': 20561560, 'dashboard_result_id': 8900622, 'hashtag': '_______JRM', 'completion_json': "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20561560_14-02-2025_16_06_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 20561592, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20561593, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20561594, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20561595, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20561596, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20561597, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20561598, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20561599, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20561600, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20561601, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20561602, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20561603, 'pht': 3726}}"}, {'dashboat_entry_day': 1602310, 'dashboard_run_id': 1611861, 'mtr_portfolio_id': 20562576, 'dashboard_result_id': 8900623, 'hashtag': '_______JRM', 'completion_json': "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562576_14-02-2025_16_19_31.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20562578, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20562579, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20562580, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20562581, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20562582, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 20562583, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20562584, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20562585, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20562586, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20562587, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20562588, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20562589, 'pht': 3726}}"}, {'dashboat_entry_day': 1602310, 'dashboard_run_id': 1611861, 'mtr_portfolio_id': 20562858, 'dashboard_result_id': 8900624, 'hashtag': '_______JRM', 'completion_json': "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562858_14-02-2025_16_26_58.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20562884, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 20562885, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20562887, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20562893, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20562899, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20562901, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20562902, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20562903, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20562904, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20562905, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20562906, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20562907, 'pht': 3726}}"}] SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 20561560 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 list_result_datou : [{'mtr_datou_id': 4302, 'mtr_datou_current_id': 2588093, 'mtr_portfolio_id': 20561560, 'created_at': datetime.datetime(2025, 2, 14, 16, 6, 59), 'result': '0.037740468220729594', 'result_long': None, 'result_double': None}] Qualite : 0.037740468220729594 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 20561560 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20561560_14-02-2025_16_06_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 20561560 order by id desc limit 1 update MTRPhoto.dashboard_results set completion_json = "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20561560_14-02-2025_16_06_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 20561592, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20561593, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20561594, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20561595, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20561596, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20561597, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20561598, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20561599, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20561600, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20561601, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20561602, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20561603, 'pht': 3726}}" where mtr_portfolio_id = 20561560 and dashboard_run_id = 1611861 SELECT name, created_at,limit_max FROM MTRDatou.mtr_datou WHERE id=4302 SELECT mtd.id, mtdt.`type`, mtd.`param`, mtd.param_json, mtdt.nb_input, mtdt.nb_output, mtdt.prod, mtdt.is_local, mtdt.is_datou_depend, mtdt.is_photo_id_local FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_step_types mtdt WHERE mtdt.`id`=mtd.`type` AND mtd.mtd_id=4302 SELECT mtd.id, mtd.mtd_id, mdsdt.id, mdsdt.name, mdsdt.description, msid.output_or_input, msid.data_order_id, mdsdt.type FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_steptype_io_datatypes msid, MTRDatou.mtr_datou_step_data_types mdsdt WHERE mtd.`type`=msid.`mtr_datou_step_type` AND mtd.mtd_id= 4302 AND msid.data_type=mdsdt.id SELECT mts_id_output, id_output, mts_id_input, id_input FROM MTRDatou.mtr_datou_step_by_step WHERE mtd_id=4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! no param json to modify TODO Duplicate data, are they consistent 3 ? Duplicate data, are they consistent 4 ? SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=20561560 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (8900622, 0.037740468220729594, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20561560_14-02-2025_16_06_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 20561592, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20561593, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20561594, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20561595, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20561596, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20561597, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20561598, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20561599, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20561600, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20561601, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20561602, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20561603, 'pht': 3726}}") ON DUPLICATE KEY UPDATE qualite=VALUES(qualite), completion_json=VALUES(completion_json) ret update_qualite_results : None SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 20562576 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 list_result_datou : [{'mtr_datou_id': 4302, 'mtr_datou_current_id': 2588182, 'mtr_portfolio_id': 20562576, 'created_at': datetime.datetime(2025, 2, 14, 16, 19, 31), 'result': '0.06581101861628913', 'result_long': None, 'result_double': None}] Qualite : 0.06581101861628913 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 20562576 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562576_14-02-2025_16_19_31.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 20562576 order by id desc limit 1 update MTRPhoto.dashboard_results set completion_json = "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562576_14-02-2025_16_19_31.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20562578, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20562579, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20562580, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20562581, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20562582, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 20562583, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20562584, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20562585, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20562586, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20562587, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20562588, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20562589, 'pht': 3726}}" where mtr_portfolio_id = 20562576 and dashboard_run_id = 1611861 SELECT name, created_at,limit_max FROM MTRDatou.mtr_datou WHERE id=4302 SELECT mtd.id, mtdt.`type`, mtd.`param`, mtd.param_json, mtdt.nb_input, mtdt.nb_output, mtdt.prod, mtdt.is_local, mtdt.is_datou_depend, mtdt.is_photo_id_local FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_step_types mtdt WHERE mtdt.`id`=mtd.`type` AND mtd.mtd_id=4302 SELECT mtd.id, mtd.mtd_id, mdsdt.id, mdsdt.name, mdsdt.description, msid.output_or_input, msid.data_order_id, mdsdt.type FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_steptype_io_datatypes msid, MTRDatou.mtr_datou_step_data_types mdsdt WHERE mtd.`type`=msid.`mtr_datou_step_type` AND mtd.mtd_id= 4302 AND msid.data_type=mdsdt.id SELECT mts_id_output, id_output, mts_id_input, id_input FROM MTRDatou.mtr_datou_step_by_step WHERE mtd_id=4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! no param json to modify TODO Duplicate data, are they consistent 3 ? Duplicate data, are they consistent 4 ? SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=20562576 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (8900623, 0.06581101861628913, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562576_14-02-2025_16_19_31.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20562578, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20562579, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20562580, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20562581, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20562582, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 20562583, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20562584, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20562585, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20562586, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20562587, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20562588, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20562589, 'pht': 3726}}") ON DUPLICATE KEY UPDATE qualite=VALUES(qualite), completion_json=VALUES(completion_json) ret update_qualite_results : None SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 20562858 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 list_result_datou : [{'mtr_datou_id': 4302, 'mtr_datou_current_id': 2588223, 'mtr_portfolio_id': 20562858, 'created_at': datetime.datetime(2025, 2, 14, 16, 28, 58), 'result': '0.02959268931527197', 'result_long': None, 'result_double': None}] Qualite : 0.02959268931527197 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 20562858 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562858_14-02-2025_16_28_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 20562858 order by id desc limit 1 update MTRPhoto.dashboard_results set completion_json = "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562858_14-02-2025_16_28_58.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20562884, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 20562885, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20562887, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20562893, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20562899, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20562901, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20562902, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20562903, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20562904, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20562905, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20562906, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20562907, 'pht': 3726}}" where mtr_portfolio_id = 20562858 and dashboard_run_id = 1611861 SELECT name, created_at,limit_max FROM MTRDatou.mtr_datou WHERE id=4302 SELECT mtd.id, mtdt.`type`, mtd.`param`, mtd.param_json, mtdt.nb_input, mtdt.nb_output, mtdt.prod, mtdt.is_local, mtdt.is_datou_depend, mtdt.is_photo_id_local FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_step_types mtdt WHERE mtdt.`id`=mtd.`type` AND mtd.mtd_id=4302 SELECT mtd.id, mtd.mtd_id, mdsdt.id, mdsdt.name, mdsdt.description, msid.output_or_input, msid.data_order_id, mdsdt.type FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_steptype_io_datatypes msid, MTRDatou.mtr_datou_step_data_types mdsdt WHERE mtd.`type`=msid.`mtr_datou_step_type` AND mtd.mtd_id= 4302 AND msid.data_type=mdsdt.id SELECT mts_id_output, id_output, mts_id_input, id_input FROM MTRDatou.mtr_datou_step_by_step WHERE mtd_id=4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! no param json to modify TODO Duplicate data, are they consistent 3 ? Duplicate data, are they consistent 4 ? SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=20562858 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (8900624, 0.02959268931527197, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P20562858_14-02-2025_16_28_58.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 20562884, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 20562885, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 20562887, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 20562893, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 20562899, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 20562901, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 20562902, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 20562903, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 20562904, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 20562905, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 20562906, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 20562907, 'pht': 3726}}") ON DUPLICATE KEY UPDATE qualite=VALUES(qualite), completion_json=VALUES(completion_json) ret update_qualite_results : None SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (20561560,20562576,20562858) result : ((1337643794,), (1337643795,), (1337643797,), (1337643836,), (1337643837,), (1337643840,), (1337643843,), (1337643844,), (1337643846,), (1337643993,), (1337644068,), (1337644159,), (1337644213,), (1337644215,), (1337644335,), (1337644358,), (1337644436,), (1337644456,), (1337644462,), (1337644467,), (1337644506,), (1337644509,), (1337644512,), (1337644516,), (1337644548,), (1337644573,), (1337644575,), (1337644578,), (1337644581,), (1337644585,), (1337644741,), (1337644821,), (1337644831,), (1337644837,), (1337644841,), (1337644854,), (1337644910,), (1337644918,), (1337644920,), (1337644989,), (1337644990,), (1337644992,), (1337644994,), (1337645014,), (1337645017,), (1337645078,), (1337645083,), (1337645088,), (1337645102,), (1337645109,), (1337646646,), (1337646740,), (1337646828,), (1337647101,), (1337647191,), (1337647203,), (1337647207,), (1337647209,), (1337647254,), (1337652460,), (1337652456,), (1337652458,), (1337652488,), (1337652490,), (1337652492,), (1337652493,), (1337652518,), (1337652520,), (1337652542,), (1337652543,), (1337652545,), (1337652547,), (1337652553,), (1337652601,), (1337652602,), (1337652604,), (1337652627,), (1337652628,), (1337652676,), (1337652677,), (1337652679,), (1337652862,), (1337652863,), (1337652865,), (1337652867,), (1337652869,), (1337653464,), (1337653661,), (1337653664,), (1337653666,), (1337653704,), (1337653917,), (1337653941,), (1337653951,), (1337653955,), (1337653959,), (1337654072,), (1337654075,), (1337654080,), (1337654085,), (1337654101,), (1337654220,), (1337654157,), (1337654160,), (1337654212,), (1337654216,), (1337654402,), (1337654409,), (1337654414,), (1337654418,), (1337654423,), (1337654426,), (1337654455,), (1337654456,), (1337654458,), (1337654460,), (1337654499,), (1337654500,), (1337654505,), (1337654522,), (1337654527,), (1337654528,), (1337654559,), (1337654561,), (1337654563,), (1337654565,), (1337654566,), (1337654592,), (1337654593,), (1337654604,), (1337654669,), (1337655711,), (1337655713,), (1337655716,), (1337655719,), (1337655723,), (1337655727,), (1337656014,), (1337656017,), (1337656021,), (1337656083,), (1337656091,), (1337656095,), (1337656099,), (1337656102,), (1337656107,), (1337656166,), (1337656170,), (1337656174,), (1337656179,), (1337656184,), (1337656220,), (1337656222,), (1337656226,), (1337656398,), (1337656400,), (1337656407,), (1337656409,), (1337656417,), (1337656420,), (1337656446,), (1337656451,), (1337656460,), (1337656467,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'14022025': {'nb_upload': 62, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([20562858]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398] map_info['map_portfolio_photo'] : {20562858: [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398, 1337656226, 1337656222, 1337656220, 1337656184, 1337656179, 1337656174, 1337656170, 1337656166, 1337656107, 1337656102, 1337656099, 1337656095, 1337656091, 1337656083, 1337656021, 1337656017, 1337656014, 1337655727, 1337655723, 1337655719, 1337655716, 1337655713, 1337655711, 1337654669, 1337654604, 1337654593, 1337654592, 1337654566, 1337654565, 1337654563, 1337654561, 1337654559, 1337654528, 1337654527, 1337654522, 1337654505, 1337654500, 1337654499, 1337654460, 1337654458, 1337654456, 1337654455, 1337654426, 1337654423, 1337654418, 1337654414, 1337654409, 1337654402, 1337654216, 1337654212, 1337654160, 1337654157]} final : True mtd_id 4302 list_pids : [1337656467, 1337656460, 1337656451, 1337656446, 1337656420, 1337656417, 1337656409, 1337656407, 1337656400, 1337656398] Looping around the photos to save general results len do output : 1 /20562858Didn't retrieve data . before output type Here is an output not treated by saveGeneral : Managing all output in save final without adding information in the mtr_datou_result ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656467', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656460', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656451', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656446', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656420', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656417', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656409', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656407', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656400', None, None, None, None, None, '2588223') ('4302', None, None, None, None, None, None, None, '2588223') ('4302', '20562858', '1337656398', None, None, None, None, None, '2588223') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 11 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', None, '20562858', 'None', None, None, None, None, '2588223'), ('4302', '20562858', '1337656467', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656460', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656451', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656446', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656420', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656417', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656409', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656407', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656400', None, None, None, None, None, '2588223'), ('4302', '20562858', '1337656398', None, None, None, None, None, '2588223')] time used for this insertion : 0.013023614883422852 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.29935312271118164 time spend to save output : 0.013325691223144531 total time spend for step 5 : 0.31267881393432617 caffe_path_current : About to save ! 2 After save, about to update current ! ret : 2 len(input) + len(total_photo_id_missing) : 1 set_done_treatment DELETE from MTRPhoto.mtr_datou_current where id in (2588223) 2.27user 2.44system 0:08.77elapsed 53%CPU (0avgtext+0avgdata 159744maxresident)k 488inputs+12920outputs (11major+74988minor)pagefaults 0swaps