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 : 1342948 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 (3274462) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (3274462) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872219 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['3274462'] with mtr_portfolio_ids : ['24872219'] and first list_photo_ids : [] new path : /proc/1342948/ Name: python3 Umask: 0002 State: R (running) Tgid: 1342948 Ngid: 0 Pid: 1342948 PPid: 1342947 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 1342948 NSpid: 1342948 NSpgid: 1341802 NSsid: 1341802 VmPeak: 1106868 kB VmSize: 1106868 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 99300 kB VmRSS: 99300 kB RssAnon: 59796 kB RssFile: 39504 kB RssShmem: 0 kB VmData: 865620 kB VmStk: 132 kB VmExe: 2644 kB VmLib: 130468 kB VmPTE: 592 kB VmSwap: 0 kB HugetlbPages: 0 kB CoreDumping: 0 THP_enabled: 1 Threads: 1 SigQ: 6/63019 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: 47 nonvoluntary_ctxt_switches: 88 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '1342948', 'Ngid': '0', 'Pid': '1342948', 'PPid': '1342947', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '1342948', 'NSpid': '1342948', 'NSpgid': '1341802', 'NSsid': '1341802', 'VmPeak': '1106868 kB', 'VmSize': '1106868 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '99300 kB', 'VmRSS': '99300 kB', 'RssAnon': '59796 kB', 'RssFile': '39504 kB', 'RssShmem': '0 kB', 'VmData': '865620 kB', 'VmStk': '132 kB', 'VmExe': '2644 kB', 'VmLib': '130468 kB', 'VmPTE': '592 kB', 'VmSwap': '0 kB', 'HugetlbPages': '0 kB', 'CoreDumping': '0', 'THP_enabled': '1', 'Threads': '1', 'SigQ': '6/63019', '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': '47', 'nonvoluntary_ctxt_switches': '88'} ('datou_batch_current', '1342948', '1106868', '0', '1106868', '865620', '99300', b'', 'marlene', '3274462') 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 (24872219) 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 (3274462 ) ) 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 (24872219) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1371787031, 'portfolio_id': 24872219}, {'photo_id': 1371787029, 'portfolio_id': 24872219}, {'photo_id': 1371787027, 'portfolio_id': 24872219}, {'photo_id': 1371787023, 'portfolio_id': 24872219}, {'photo_id': 1371787019, 'portfolio_id': 24872219}, {'photo_id': 1371787018, 'portfolio_id': 24872219}, {'photo_id': 1371787008, 'portfolio_id': 24872219}, {'photo_id': 1371786999, 'portfolio_id': 24872219}, {'photo_id': 1371786992, 'portfolio_id': 24872219}, {'photo_id': 1371786990, 'portfolio_id': 24872219}, {'photo_id': 1371786988, 'portfolio_id': 24872219}, {'photo_id': 1371786986, 'portfolio_id': 24872219}, {'photo_id': 1371786962, 'portfolio_id': 24872219}, {'photo_id': 1371786960, 'portfolio_id': 24872219}, {'photo_id': 1371786959, 'portfolio_id': 24872219}, {'photo_id': 1371786958, 'portfolio_id': 24872219}, {'photo_id': 1371786957, 'portfolio_id': 24872219}, {'photo_id': 1371786956, 'portfolio_id': 24872219}, {'photo_id': 1371786923, 'portfolio_id': 24872219}, {'photo_id': 1371786921, 'portfolio_id': 24872219}, {'photo_id': 1371786918, 'portfolio_id': 24872219}, {'photo_id': 1371786915, 'portfolio_id': 24872219}, {'photo_id': 1371786912, 'portfolio_id': 24872219}, {'photo_id': 1371786909, 'portfolio_id': 24872219}, {'photo_id': 1371786902, 'portfolio_id': 24872219}, {'photo_id': 1371786900, 'portfolio_id': 24872219}, {'photo_id': 1371786897, 'portfolio_id': 24872219}, {'photo_id': 1371786895, 'portfolio_id': 24872219}, {'photo_id': 1371786894, 'portfolio_id': 24872219}, {'photo_id': 1371786892, 'portfolio_id': 24872219}, {'photo_id': 1371786866, 'portfolio_id': 24872219}, {'photo_id': 1371786865, 'portfolio_id': 24872219}, {'photo_id': 1371786862, 'portfolio_id': 24872219}, {'photo_id': 1371786860, 'portfolio_id': 24872219}, {'photo_id': 1371786859, 'portfolio_id': 24872219}, {'photo_id': 1371786856, 'portfolio_id': 24872219}, {'photo_id': 1371786815, 'portfolio_id': 24872219}, {'photo_id': 1371786813, 'portfolio_id': 24872219}, {'photo_id': 1371786811, 'portfolio_id': 24872219}, {'photo_id': 1371786809, 'portfolio_id': 24872219}, {'photo_id': 1371786808, 'portfolio_id': 24872219}, {'photo_id': 1371786804, 'portfolio_id': 24872219}, {'photo_id': 1371786796, 'portfolio_id': 24872219}, {'photo_id': 1371786795, 'portfolio_id': 24872219}, {'photo_id': 1371786792, 'portfolio_id': 24872219}, {'photo_id': 1371786791, 'portfolio_id': 24872219}, {'photo_id': 1371786789, 'portfolio_id': 24872219}, {'photo_id': 1371786788, 'portfolio_id': 24872219}, {'photo_id': 1371786787, 'portfolio_id': 24872219}, {'photo_id': 1371786786, 'portfolio_id': 24872219}, {'photo_id': 1371786785, 'portfolio_id': 24872219}, {'photo_id': 1371786784, 'portfolio_id': 24872219}, {'photo_id': 1371786783, 'portfolio_id': 24872219}, {'photo_id': 1371786782, 'portfolio_id': 24872219}] map_portfolio_id_photo_id: {24872219: [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986, 1371786962, 1371786960, 1371786959, 1371786958, 1371786957, 1371786956, 1371786923, 1371786921, 1371786918, 1371786915, 1371786912, 1371786909, 1371786902, 1371786900, 1371786897, 1371786895, 1371786894, 1371786892, 1371786866, 1371786865, 1371786862, 1371786860, 1371786859, 1371786856, 1371786815, 1371786813, 1371786811, 1371786809, 1371786808, 1371786804, 1371786796, 1371786795, 1371786792, 1371786791, 1371786789, 1371786788, 1371786787, 1371786786, 1371786785, 1371786784, 1371786783, 1371786782]} ##### 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.016011714935302734 #### 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 Sat Jul 12 03:54: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 After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (24872219) 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 : 24872219 get user id for portfolio 24872219 get sub ptf for main ptf 24872219, type 3726 and hashtags ['Carton_gris', 'cartonnette', 'Teint_Dans_La_Masse', 'autre_refus', 'papier', 'Carton_brun', 'flou', 'plastique', 'metal', 'mal_croppe', 'kraft', 'environnement'] 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`=24872219 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Carton_gris','cartonnette','Teint_Dans_La_Masse','autre_refus','papier','Carton_brun','flou','plastique','metal','mal_croppe','kraft','environnement')) 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`=24872219 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Carton_gris','cartonnette','Teint_Dans_La_Masse','autre_refus','papier','Carton_brun','flou','plastique','metal','mal_croppe','kraft','environnement')) AND mptpi.`min_score`=0.5 To do returned map {'cartonnette': {'main_port_id': 24872219, 'sub_port_id': 24872245, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745186, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'kraft': {'main_port_id': 24872219, 'sub_port_id': 24872246, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745187, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'Teint_Dans_La_Masse': {'main_port_id': 24872219, 'sub_port_id': 24872247, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745188, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'autre_refus': {'main_port_id': 24872219, 'sub_port_id': 24872248, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745189, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'metal': {'main_port_id': 24872219, 'sub_port_id': 24872249, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745190, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'plastique': {'main_port_id': 24872219, 'sub_port_id': 24872250, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745191, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'mal_croppe': {'main_port_id': 24872219, 'sub_port_id': 24872251, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745192, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'papier': {'main_port_id': 24872219, 'sub_port_id': 24872252, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745193, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'flou': {'main_port_id': 24872219, 'sub_port_id': 24872253, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745194, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'Carton_brun': {'main_port_id': 24872219, 'sub_port_id': 24872254, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745195, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'Carton_gris': {'main_port_id': 24872219, 'sub_port_id': 24872255, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745196, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}, 'environnement': {'main_port_id': 24872219, 'sub_port_id': 24872256, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745197, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 57)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 24872245 , 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=24872219 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 (24872245) result : ((1371786906,), (1371787007,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872246 , 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=24872219 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 (24872246) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872247 , 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=24872219 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 (24872247) result : ((1371786993,), (1371786994,), (1371786995,), (1371786996,), (1371786997,), (1371786998,), (1371787000,), (1371787001,), (1371787060,), (1371787061,), (1371787124,), (1371787126,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872248 , 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=24872219 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 (24872248) result : ((1371787002,),) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872249 , 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=24872219 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 (24872249) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872250 , 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=24872219 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 (24872250) result : ((1371787127,), (1371787128,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872251 , 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=24872219 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 (24872251) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872252 , 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=24872219 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 (24872252) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872253 , 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=24872219 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 (24872253) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872254 , 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=24872219 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 (24872254) result : ((1371787009,), (1371787010,), (1371787011,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872255 , 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=24872219 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 (24872255) result : ((1371786904,), (1371787005,), (1371787006,), (1371787072,), (1371787074,), (1371787076,), (1371787078,), (1371787080,), (1371787082,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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 24872256 , 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=24872219 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 (24872256) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (24872219) result : ((1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) 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 (1371786900) 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`=24872219 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Carton_gris','cartonnette','Teint_Dans_La_Masse','autre_refus','papier','Carton_brun','flou','plastique','metal','mal_croppe','kraft','environnement')) 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`=24872219 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Carton_gris','cartonnette','Teint_Dans_La_Masse','autre_refus','papier','Carton_brun','flou','plastique','metal','mal_croppe','kraft','environnement')) AND mptpi.`min_score`=0.5 To do returned map {'cartonnette': {'main_port_id': 24872219, 'sub_port_id': 24872257, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745198, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'kraft': {'main_port_id': 24872219, 'sub_port_id': 24872258, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745199, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'Teint_Dans_La_Masse': {'main_port_id': 24872219, 'sub_port_id': 24872259, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745200, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'autre_refus': {'main_port_id': 24872219, 'sub_port_id': 24872260, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745201, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'metal': {'main_port_id': 24872219, 'sub_port_id': 24872261, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745202, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'plastique': {'main_port_id': 24872219, 'sub_port_id': 24872262, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745203, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'mal_croppe': {'main_port_id': 24872219, 'sub_port_id': 24872263, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745204, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'papier': {'main_port_id': 24872219, 'sub_port_id': 24872264, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745205, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'flou': {'main_port_id': 24872219, 'sub_port_id': 24872265, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745206, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'Carton_brun': {'main_port_id': 24872219, 'sub_port_id': 24872266, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745207, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'Carton_gris': {'main_port_id': 24872219, 'sub_port_id': 24872267, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745208, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 48, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}, 'environnement': {'main_port_id': 24872219, 'sub_port_id': 24872268, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 16745209, 'last_updated_at': datetime.datetime(2025, 7, 12, 3, 52, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 12, 3, 52, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 12, 3, 48, 59)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872257,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872245 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872258,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872246 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872259,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872247 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872260,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872248 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872261,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872249 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872262,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872250 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872263,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872251 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872264,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872252 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872265,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872253 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872266,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872254 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872267,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872255 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 24872268,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 24872256 lien utilise dans velours : https://www.fotonower.com/velours/24872257,24872258,24872259,24872260,24872261,24872262,24872263,24872264,24872265,24872266,24872267,24872268?tags=cartonnette,kraft,Teint_Dans_La_Masse,autre_refus,metal,plastique,mal_croppe,papier,flou,Carton_brun,Carton_gris,environnement After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([24872219]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986] map_info['map_portfolio_photo'] : {24872219: [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986, 1371786962, 1371786960, 1371786959, 1371786958, 1371786957, 1371786956, 1371786923, 1371786921, 1371786918, 1371786915, 1371786912, 1371786909, 1371786902, 1371786900, 1371786897, 1371786895, 1371786894, 1371786892, 1371786866, 1371786865, 1371786862, 1371786860, 1371786859, 1371786856, 1371786815, 1371786813, 1371786811, 1371786809, 1371786808, 1371786804, 1371786796, 1371786795, 1371786792, 1371786791, 1371786789, 1371786788, 1371786787, 1371786786, 1371786785, 1371786784, 1371786783, 1371786782]} final : False mtd_id 4302 list_pids : [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986] Looping around the photos to save general results len do output : 1 /24872219. 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, '3274462') ('4302', '24872219', '1371787031', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787029', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787027', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787023', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787019', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787018', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787008', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786999', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786992', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786990', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786988', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786986', None, None, None, None, None, '3274462') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 13 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, '24872219', "{'cartonnette': 24872245, 'kraft': 24872246, 'Teint_Dans_La_Masse': 24872247, 'autre_refus': 24872248, 'metal': 24872249, 'plastique': 24872250, 'mal_croppe': 24872251, 'papier': 24872252, 'flou': 24872253, 'Carton_brun': 24872254, 'Carton_gris': 24872255, 'environnement': 24872256}", None, None, None, None, '3274462'), ('4302', '24872219', '1371787031', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787029', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787027', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787023', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787019', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787018', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787008', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786999', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786992', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786990', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786988', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786986', None, None, None, None, None, '3274462')] time used for this insertion : 0.02277064323425293 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.46828126907348633 time spend to save output : 0.02306199073791504 total time spend for step 1 : 0.49134325981140137 step2:final Sat Jul 12 03:54: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 (24872219) 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 24872219 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1371786795,1371786796,1371786791,1371786792,1371786788,1371786789,1371786786,1371786787,1371786784,1371786785,1371786783,1371786782,1371786815,1371786813,1371786811,1371786809,1371786808,1371786804,1371786866,1371786865,1371786862,1371786860,1371786859,1371786856,1371786902,1371786900,1371786897,1371786895,1371786894,1371786892,1371786923,1371786921,1371786918,1371786915,1371786912,1371786909,1371786962,1371786960,1371786959,1371786958,1371786957,1371786956,1371787008,1371786999,1371786992,1371786990,1371786988,1371786986,1371787031,1371787029,1371787027,1371787023,1371787019,1371787018); 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([24872219]) Inside saveOutput : final : False verbose : True original output for save of step final : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} new output for save of step final : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986] map_info['map_portfolio_photo'] : {24872219: [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986, 1371786962, 1371786960, 1371786959, 1371786958, 1371786957, 1371786956, 1371786923, 1371786921, 1371786918, 1371786915, 1371786912, 1371786909, 1371786902, 1371786900, 1371786897, 1371786895, 1371786894, 1371786892, 1371786866, 1371786865, 1371786862, 1371786860, 1371786859, 1371786856, 1371786815, 1371786813, 1371786811, 1371786809, 1371786808, 1371786804, 1371786796, 1371786795, 1371786792, 1371786791, 1371786789, 1371786788, 1371786787, 1371786786, 1371786785, 1371786784, 1371786783, 1371786782]} final : False mtd_id 4302 list_pids : [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986] Looping around the photos to save general results len do output : 12 /1371787031.Didn't retrieve data . /1371787029.Didn't retrieve data . /1371787027.Didn't retrieve data . /1371787023.Didn't retrieve data . /1371787019.Didn't retrieve data . /1371787018.Didn't retrieve data . /1371787008.Didn't retrieve data . /1371786999.Didn't retrieve data . /1371786992.Didn't retrieve data . /1371786990.Didn't retrieve data . /1371786988.Didn't retrieve data . /1371786986.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, '3274462') ('4302', '24872219', '1371787031', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787029', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787027', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787023', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787019', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787018', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787008', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786999', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786992', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786990', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786988', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786986', None, None, None, None, None, '3274462') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 36 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', '24872219', '1371787031', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371787029', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371787027', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371787023', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371787019', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371787018', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371787008', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371786999', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371786992', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371786990', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371786988', '0.047041016685700696', None, None, None, None, '3274462'), ('4302', '24872219', '1371786986', '0.047041016685700696', None, None, None, None, '3274462')] time used for this insertion : 0.017485857009887695 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.07291841506958008 time spend to save output : 0.018045902252197266 total time spend for step 2 : 0.09096431732177734 step3:velours_tree Sat Jul 12 03:54: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 : {24872219: [{'cartonnette': 24872245, 'kraft': 24872246, 'Teint_Dans_La_Masse': 24872247, 'autre_refus': 24872248, 'metal': 24872249, 'plastique': 24872250, 'mal_croppe': 24872251, 'papier': 24872252, 'flou': 24872253, 'Carton_brun': 24872254, 'Carton_gris': 24872255, 'environnement': 24872256}]} input_args_next_step : {24872219: ()} output_args : {24872219: [{'cartonnette': 24872245, 'kraft': 24872246, 'Teint_Dans_La_Masse': 24872247, 'autre_refus': 24872248, 'metal': 24872249, 'plastique': 24872250, 'mal_croppe': 24872251, 'papier': 24872252, 'flou': 24872253, 'Carton_brun': 24872254, 'Carton_gris': 24872255, 'environnement': 24872256}]} args : 24872219 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 : ({'cartonnette': 24872245, 'kraft': 24872246, 'Teint_Dans_La_Masse': 24872247, 'autre_refus': 24872248, 'metal': 24872249, 'plastique': 24872250, 'mal_croppe': 24872251, 'papier': 24872252, 'flou': 24872253, 'Carton_brun': 24872254, 'Carton_gris': 24872255, 'environnement': 24872256},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (24872219) 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([24872219]) 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.27654337882995605 time spend to save output : 5.173683166503906e-05 total time spend for step 3 : 0.2765951156616211 step4:send_mail_cod Sat Jul 12 03:54:59 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 : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} input_args_next_step : {1371787031: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371787031 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371787029 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371787027 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371787023 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371787019 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371787018 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371787008 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371786999 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371786992 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371786990 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371786988 depend.output_id : 0 input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ()} output_args : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',)} args : 1371786986 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 : {24872219: [{'cartonnette': 24872245, 'kraft': 24872246, 'Teint_Dans_La_Masse': 24872247, 'autre_refus': 24872248, 'metal': 24872249, 'plastique': 24872250, 'mal_croppe': 24872251, 'papier': 24872252, 'flou': 24872253, 'Carton_brun': 24872254, 'Carton_gris': 24872255, 'environnement': 24872256}]} input_args_next_step : {1371787031: ('0.047041016685700696',), 1371787029: ('0.047041016685700696',), 1371787027: ('0.047041016685700696',), 1371787023: ('0.047041016685700696',), 1371787019: ('0.047041016685700696',), 1371787018: ('0.047041016685700696',), 1371787008: ('0.047041016685700696',), 1371786999: ('0.047041016685700696',), 1371786992: ('0.047041016685700696',), 1371786990: ('0.047041016685700696',), 1371786988: ('0.047041016685700696',), 1371786986: ('0.047041016685700696',), 24872219: ()} output_args : {24872219: [{'cartonnette': 24872245, 'kraft': 24872246, 'Teint_Dans_La_Masse': 24872247, 'autre_refus': 24872248, 'metal': 24872249, 'plastique': 24872250, 'mal_croppe': 24872251, 'papier': 24872252, 'flou': 24872253, 'Carton_brun': 24872254, 'Carton_gris': 24872255, 'environnement': 24872256}]} args : 24872219 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 :13, first value : ('0.047041016685700696',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (24872219) 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 (1371787031,1371787029,1371787027,1371787023,1371787019,1371787018,1371787008,1371786999,1371786992,1371786990,1371786988,1371786986) Found this number of photos: 12 ##### Call download_photos : nb_thread : 5 begin to download photo : 1371786986 begin to download photo : 1371786992 begin to download photo : 1371787018 begin to download photo : 1371787027 download finish for photo 1371787027 begin to download photo : 1371787029 download finish for photo 1371786986 begin to download photo : 1371786988 download finish for photo 1371787018 begin to download photo : 1371787019 download finish for photo 1371786992 begin to download photo : 1371786999 download finish for photo 1371787029 begin to download photo : 1371787031 download finish for photo 1371786988 begin to download photo : 1371786990 download finish for photo 1371787019 begin to download photo : 1371787023 download finish for photo 1371786999 begin to download photo : 1371787008 download finish for photo 1371786990 download finish for photo 1371787031 download finish for photo 1371787008 download finish for photo 1371787023 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 : 12 ; length of list_pids : 12 ; length of list_args : 12 results_Auto_P24872219_12-07-2025_03_54_59.pdf 24872245 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=24872245 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1371786906: '1752284966_2345526_1371786804_b0daac3030a648492e88ea6edcc85ac4_rle_crop_3880945522_0.png', 1371787007: '1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946035_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/7952f9f96ae10471569bc2ed57f10883_98330015.png change filename to text .imagette248722451752285299/ imagette248722451752285299/1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946035_0.png.png imagette248722451752285299/1752284966_2345526_1371786804_b0daac3030a648492e88ea6edcc85ac4_rle_crop_3880945522_0.png.png imagette248722461752285299/ wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/fd8bdae3dd3e9d2ef82a10a3aeddbd4d_82132758.png imagette248722451752285299 24872246 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=24872246 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette248722461752285299 24872248 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=24872248 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1371787002: '1752285127_80619_1371786902_c99df257b96de8fba1ce49b78921e321_rle_crop_3880946008_0.png'} change filename to text .imagette248722481752285299/ imagette248722481752285299/1752285127_80619_1371786902_c99df257b96de8fba1ce49b78921e321_rle_crop_3880946008_0.png.png imagette248722491752285299/ wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/77e9f5f1bc74696b196f1e0776c6423e_69856304.png imagette248722481752285299 24872249 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=24872249 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette248722491752285299 24872250 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=24872250 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1371787127: '1752285247_84891_1371786923_30fd119011f31511676c26bf996a17b0_rle_crop_3880946661_0.png', 1371787128: '1752285247_84891_1371786909_18a4310d72d709871b0ccf35b814aabb_rle_crop_3880946689_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/ca2ab7720430dc9b968397be110d4595_66978352.png change filename to text .imagette248722501752285299/ imagette248722501752285299/1752285247_84891_1371786909_18a4310d72d709871b0ccf35b814aabb_rle_crop_3880946689_0.png.png imagette248722501752285299/1752285247_84891_1371786923_30fd119011f31511676c26bf996a17b0_rle_crop_3880946661_0.png.png imagette248722511752285299/ imagette248722531752285299/ wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/a6550100ace75a0828d191ac2ea3e3f2_97842561.png imagette248722501752285299 24872251 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=24872251 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette248722511752285299 24872253 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=24872253 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette248722531752285299 24872247 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=24872247 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1371786993: '1752285127_80619_1371786902_c99df257b96de8fba1ce49b78921e321_rle_crop_3880946011_0.png', 1371786994: '1752285127_80619_1371786900_45ec04a7e39c8b592c98911efc04b94f_rle_crop_3880946025_0.png', 1371786995: '1752285127_80619_1371786900_45ec04a7e39c8b592c98911efc04b94f_rle_crop_3880946031_0.png', 1371786996: '1752285127_80619_1371786900_45ec04a7e39c8b592c98911efc04b94f_rle_crop_3880946026_0.png', 1371786997: '1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946041_0.png', 1371786998: '1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946049_0.png', 1371787000: '1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946048_0.png', 1371787001: '1752285127_80619_1371786895_a4addaf7152510a8d533aa5d5ac46068_rle_crop_3880946077_0.png', 1371787060: '1752285207_2350847_1371786957_08cbf1df2bd435f8dc4ca3f72b475e2d_rle_crop_3880946555_0.png', 1371787061: '1752285207_2350847_1371786956_6d01c01238315dad2c5a337029d0c50f_rle_crop_3880946572_0.png', 1371787124: '1752285247_84891_1371786923_30fd119011f31511676c26bf996a17b0_rle_crop_3880946659_0.png', 1371787126: '1752285247_84891_1371786909_18a4310d72d709871b0ccf35b814aabb_rle_crop_3880946690_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/95c90f79245b7c53c31fcc8f12879d33_15566052.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/bb503736a8965b082e39d63b5fab364a_83031562.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/a6730a45063f6ea09a0d7761cbd6b2be_12131335.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/c00882c8371a139e750f97f16bafc025_12770540.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/90b0f4187d332c42bc3e82c7a2086909_73983873.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/d7bc0456082a8e8335231dee146ccd68_73512277.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/79704730ac9864d4b245064fae7e45d0_25993409.png change filename to text .wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/4275413c114d8250210133204f3d6032_43499403.png change filename to text .wget -O 9.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/ff15ba73eac321766283372bb591a5dc_21539260.png change filename to text .wget -O 10.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/25072c99fe8eabbe169f61afde565689_24856910.png change filename to text .wget -O 11.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/e0e262117b9f8b64629479c993874cff_18751793.png change filename to text .imagette248722471752285300/ imagette248722471752285300/1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946049_0.png.png imagette248722471752285300/1752285127_80619_1371786900_45ec04a7e39c8b592c98911efc04b94f_rle_crop_3880946031_0.png.png imagette248722471752285300/1752285127_80619_1371786900_45ec04a7e39c8b592c98911efc04b94f_rle_crop_3880946025_0.png.png imagette248722471752285300/1752285247_84891_1371786909_18a4310d72d709871b0ccf35b814aabb_rle_crop_3880946690_0.png.png imagette248722471752285300/1752285207_2350847_1371786957_08cbf1df2bd435f8dc4ca3f72b475e2d_rle_crop_3880946555_0.png.png imagette248722471752285300/1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946048_0.png.png imagette248722471752285300/1752285127_80619_1371786902_c99df257b96de8fba1ce49b78921e321_rle_crop_3880946011_0.png.png imagette248722471752285300/1752285247_84891_1371786923_30fd119011f31511676c26bf996a17b0_rle_crop_3880946659_0.png.png imagette248722471752285300/1752285207_2350847_1371786956_6d01c01238315dad2c5a337029d0c50f_rle_crop_3880946572_0.png.png imagette248722471752285300/1752285127_80619_1371786895_a4addaf7152510a8d533aa5d5ac46068_rle_crop_3880946077_0.png.png imagette248722471752285300/1752285127_80619_1371786900_45ec04a7e39c8b592c98911efc04b94f_rle_crop_3880946026_0.png.png imagette248722471752285300/1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946041_0.png.png wget -O 12.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/c0cca9fcb4c64b8908af8e843fa05f49_95581251.png imagette248722471752285300 24872254 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=24872254 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1371787009: '1752285127_80619_1371786895_a4addaf7152510a8d533aa5d5ac46068_rle_crop_3880946076_0.png', 1371787010: '1752285127_80619_1371786894_580d21c1c596d90096cb71ee85ed02fa_rle_crop_3880946087_0.png', 1371787011: '1752285127_80619_1371786892_328d7c2bebaef61f413331260845bdef_rle_crop_3880946099_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/bfaf31174ec175b0474e0c8fca5737ec_44194613.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/9a8e5b232e6d8e6a3a31f6843e55810d_33679530.png change filename to text .imagette248722541752285300/ imagette248722541752285300/1752285127_80619_1371786895_a4addaf7152510a8d533aa5d5ac46068_rle_crop_3880946076_0.png.png imagette248722541752285300/1752285127_80619_1371786892_328d7c2bebaef61f413331260845bdef_rle_crop_3880946099_0.png.png imagette248722541752285300/1752285127_80619_1371786894_580d21c1c596d90096cb71ee85ed02fa_rle_crop_3880946087_0.png.png wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/9fcee411ab671374a83890be1b0599d6_30556438.png imagette248722541752285300 24872255 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=24872255 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1371786904: '1752284966_2345526_1371786815_50f7d4fbfc1d2675a49881c6076e654e_rle_crop_3880945457_0.png', 1371787005: '1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946046_0.png', 1371787006: '1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946042_0.png', 1371787072: '1752285207_2350847_1371786962_39c7b6a62de78afadd98e3e8b9832763_rle_crop_3880946506_0.png', 1371787074: '1752285207_2350847_1371786959_eae9943c230f3724c8b89c34f25277f8_rle_crop_3880946532_0.png', 1371787076: '1752285207_2350847_1371786958_424d94c32411c5a4c39f6313bc747ee8_rle_crop_3880946547_0.png', 1371787078: '1752285207_2350847_1371786957_08cbf1df2bd435f8dc4ca3f72b475e2d_rle_crop_3880946556_0.png', 1371787080: '1752285207_2350847_1371786957_08cbf1df2bd435f8dc4ca3f72b475e2d_rle_crop_3880946562_0.png', 1371787082: '1752285207_2350847_1371786956_6d01c01238315dad2c5a337029d0c50f_rle_crop_3880946573_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/c0fdb701aeb93e31f7c414c012f38002_76621061.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/eb3d1cfc0686658df77f27607ea45ef2_2715027.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/0523f5122afcdf185dae69d8339eb328_27290896.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/92f40b16fd15c1645e166fc2183a57fc_21630268.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/2f4823001247e003bc7fe8deb04c5385_28968853.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/c2aef54fe5fe6dbf1c6660f1cecbc552_33144279.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/77df0c4d35aa4b6556d3d7570c4ac8d3_27306030.png change filename to text .wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/b7b01f19459fc802a245027786c139c9_48674553.png change filename to text .imagette248722551752285300/ imagette248722551752285300/1752285207_2350847_1371786958_424d94c32411c5a4c39f6313bc747ee8_rle_crop_3880946547_0.png.png imagette248722551752285300/1752285207_2350847_1371786962_39c7b6a62de78afadd98e3e8b9832763_rle_crop_3880946506_0.png.png imagette248722551752285300/1752285207_2350847_1371786959_eae9943c230f3724c8b89c34f25277f8_rle_crop_3880946532_0.png.png imagette248722551752285300/1752285207_2350847_1371786957_08cbf1df2bd435f8dc4ca3f72b475e2d_rle_crop_3880946556_0.png.png imagette248722551752285300/1752285207_2350847_1371786956_6d01c01238315dad2c5a337029d0c50f_rle_crop_3880946573_0.png.png imagette248722551752285300/1752285207_2350847_1371786957_08cbf1df2bd435f8dc4ca3f72b475e2d_rle_crop_3880946562_0.png.png imagette248722551752285300/1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946042_0.png.png imagette248722551752285300/1752284966_2345526_1371786815_50f7d4fbfc1d2675a49881c6076e654e_rle_crop_3880945457_0.png.png imagette248722551752285300/1752285127_80619_1371786897_b172352d8c6338a70f9562c83d9394ef_rle_crop_3880946046_0.png.png wget -O 9.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/258eef4bb14fd145b80cfeff9cf1cf29_94234713.png imagette248722551752285300 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=24872219 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/24872257,24872258,24872259,24872260,24872261,24872262,24872263,24872264,24872265,24872266,24872267,24872268?tags=cartonnette,kraft,Teint_Dans_La_Masse,autre_refus,metal,plastique,mal_croppe,papier,flou,Carton_brun,Carton_gris,environnement your option no_mail is active, we will not send the real mail to your client args[1371787031] : ('0.047041016685700696',) no score found for photo 1371787031 We are sending mail with results at report@fotonower.com args[1371787029] : ('0.047041016685700696',) no score found for photo 1371787029 We are sending mail with results at report@fotonower.com args[1371787027] : ('0.047041016685700696',) no score found for photo 1371787027 We are sending mail with results at report@fotonower.com args[1371787023] : ('0.047041016685700696',) no score found for photo 1371787023 We are sending mail with results at report@fotonower.com args[1371787019] : ('0.047041016685700696',) no score found for photo 1371787019 We are sending mail with results at report@fotonower.com args[1371787018] : ('0.047041016685700696',) no score found for photo 1371787018 We are sending mail with results at report@fotonower.com args[1371787008] : ('0.047041016685700696',) no score found for photo 1371787008 We are sending mail with results at report@fotonower.com args[1371786999] : ('0.047041016685700696',) no score found for photo 1371786999 We are sending mail with results at report@fotonower.com args[1371786992] : ('0.047041016685700696',) no score found for photo 1371786992 We are sending mail with results at report@fotonower.com args[1371786990] : ('0.047041016685700696',) no score found for photo 1371786990 We are sending mail with results at report@fotonower.com args[1371786988] : ('0.047041016685700696',) no score found for photo 1371786988 We are sending mail with results at report@fotonower.com args[1371786986] : ('0.047041016685700696',) no score found for photo 1371786986 We are sending mail with results at report@fotonower.com refus_total : 0.047041016685700696 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=24872219 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_P24872219_12-07-2025_03_54_59.pdf results_Auto_P24872219_12-07-2025_03_54_59.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24872219_12-07-2025_03_54_59.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','24872219','results_Auto_P24872219_12-07-2025_03_54_59.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24872219_12-07-2025_03_54_59.pdf','pdf','','0.18','0.047041016685700696') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([24872219]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986] map_info['map_portfolio_photo'] : {24872219: [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986, 1371786962, 1371786960, 1371786959, 1371786958, 1371786957, 1371786956, 1371786923, 1371786921, 1371786918, 1371786915, 1371786912, 1371786909, 1371786902, 1371786900, 1371786897, 1371786895, 1371786894, 1371786892, 1371786866, 1371786865, 1371786862, 1371786860, 1371786859, 1371786856, 1371786815, 1371786813, 1371786811, 1371786809, 1371786808, 1371786804, 1371786796, 1371786795, 1371786792, 1371786791, 1371786789, 1371786788, 1371786787, 1371786786, 1371786785, 1371786784, 1371786783, 1371786782]} final : False mtd_id 4302 list_pids : [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986] 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, '3274462') ('4302', '24872219', '1371787031', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787029', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787027', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787023', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787019', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787018', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787008', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786999', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786992', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786990', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786988', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786986', None, None, None, None, None, '3274462') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 12 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', '24872219', '1371787031', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787029', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787027', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787023', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787019', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787018', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787008', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786999', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786992', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786990', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786988', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786986', None, None, None, None, None, '3274462')] time used for this insertion : 0.01978015899658203 save_final save missing photos in datou_result : time spend for datou_step_exec : 3.4524526596069336 time spend to save output : 0.019997119903564453 total time spend for step 4 : 3.472449779510498 step5:split_time_score Sat Jul 12 03:55:02 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 : ['24872219'] 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 : [('24872219',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (24872219) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1371786986: {'path': 'temp/1752285299_1342948_1371786986_d651b7ec7fe263dc7af9be4a798961e6.jpg', 'extension': 'jpg'}, 1371786988: {'path': 'temp/1752285299_1342948_1371786988_4da26edc6f5eedc21a74a218a1ab4290.jpg', 'extension': 'jpg'}, 1371786990: {'path': 'temp/1752285299_1342948_1371786990_d98db546c2f2a618aeece59b299c380f.jpg', 'extension': 'jpg'}, 1371787027: {'path': 'temp/1752285299_1342948_1371787027_03d4c4c2ae515c727d8b7447f76030c9.jpg', 'extension': 'jpg'}, 1371787029: {'path': 'temp/1752285299_1342948_1371787029_5e38c544a791f6d940fb10ecb13d6d00.jpg', 'extension': 'jpg'}, 1371787031: {'path': 'temp/1752285299_1342948_1371787031_f8a835665a06202823eb21bbde0662c1.jpg', 'extension': 'jpg'}, 1371786992: {'path': 'temp/1752285299_1342948_1371786992_b179d1c05a431a07f2c7bad4e373ee2a.jpg', 'extension': 'jpg'}, 1371786999: {'path': 'temp/1752285299_1342948_1371786999_a4495fe461eb320310d651bab9920feb.jpg', 'extension': 'jpg'}, 1371787008: {'path': 'temp/1752285299_1342948_1371787008_63f9324126af18578bd75b2d2d157d55.jpg', 'extension': 'jpg'}, 1371787018: {'path': 'temp/1752285299_1342948_1371787018_026597dc1d5130732dec183ab1733a26.jpg', 'extension': 'jpg'}, 1371787019: {'path': 'temp/1752285299_1342948_1371787019_6833e4e26c9ab9bd01c14f416243dcd1.jpg', 'extension': 'jpg'}, 1371787023: {'path': 'temp/1752285299_1342948_1371787023_8061f3883968fa9a88c890a90f39cf65.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 = 24872219; (('arc_en_ciel_jrm_live',), ('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 = 24872219 group by h (('03', 54),) 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=24872219 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 (24872219) 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 (24872219) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 12072025 24872219 Nombre de photos uploadées : 54 / 23040 (0%) 12072025 24872219 Nombre de photos taguées (types de déchets): 0 / 54 (0%) 12072025 24872219 Nombre de photos taguées (volume) : 0 / 54 (0%) [{'photo_id': 1371786795, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/4d04568373c73309c5c06506b2fd7a02.jpg', 'username': None, 'uploaded_at': 1752284792, 'text': 'image_12072025_03_45_04_9139.jpg'}, {'photo_id': 1371786796, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/e60ef67ee8da6e9f4bb6ae5738e94e8b.jpg', 'username': None, 'uploaded_at': 1752284792, 'text': 'image_12072025_03_45_04_9139.jpg'}, {'photo_id': 1371786791, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/c9929e86ca61c2f36e4e8fcf40bd4188.jpg', 'username': None, 'uploaded_at': 1752284792, 'text': 'image_12072025_03_45_14_10136.jpg'}, {'photo_id': 1371786792, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/12/e9cf41d96a29aadd3b578d5ff2b0b284.jpg', 'username': None, 'uploaded_at': 1752284792, 'text': 'image_12072025_03_45_14_10136.jpg'}] 0 [] elapsed_time : load_data_split_time_score 1.9073486328125e-06 elapsed_time : order_list_meta_photo_and_scores 5.4836273193359375e-06 ?????????????????????????????????????????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.0032901763916015625 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 24872219, '2025-07-12' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1972167,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.024683237075805664 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= 1972167 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24862874, 'dashboard_result_id': 12455354, '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_P24862874_12-07-2025_00_17_00.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24862879, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24862880, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24862881, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24862882, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24862883, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24862884, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24862885, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24862886, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24862887, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24862888, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24862889, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24862890, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24863716, 'dashboard_result_id': 12455355, '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_P24863716_12-07-2025_00_32_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24863736, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24863737, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24863738, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24863739, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24863740, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24863741, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24863742, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24863743, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24863744, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24863745, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24863746, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24863747, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24864264, 'dashboard_result_id': 12455356, '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_P24864264_12-07-2025_00_46_57.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24864292, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24864293, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24864294, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24864295, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24864296, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24864297, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24864298, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24864299, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24864300, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24864301, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24864302, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24864303, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24864799, 'dashboard_result_id': 12455357, '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_P24864799_12-07-2025_01_02_58.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 24864803, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24864804, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24864805, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24864806, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24864807, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24864808, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24864809, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24864810, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24864811, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24864812, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24864813, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24864814, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24865363, 'dashboard_result_id': 12455358, '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_P24865363_12-07-2025_01_17_00.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 24865438, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24865439, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24865440, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24865441, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24865442, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24865443, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24865444, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24865445, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24865446, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24865447, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24865448, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24865449, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24866369, 'dashboard_result_id': 12455359, '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_P24866369_12-07-2025_01_32_58.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 24866430, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24866432, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24866433, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24866434, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24866435, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24866437, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24866438, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24866440, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24866441, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24866442, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24866443, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24866445, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24867390, 'dashboard_result_id': 12455360, '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_P24867390_12-07-2025_01_46_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24867515, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24867516, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24867517, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24867518, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24867519, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24867520, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24867521, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24867522, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24867523, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24867524, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24867525, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24867526, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24868411, 'dashboard_result_id': 12455361, '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_P24868411_12-07-2025_02_03_01.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24868440, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24868441, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24868442, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24868443, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24868444, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24868445, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24868446, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24868447, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24868448, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24868449, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24868450, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24868451, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24868961, 'dashboard_result_id': 12455362, '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_P24868961_12-07-2025_02_16_58.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24868988, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24868989, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24868990, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24868991, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24868992, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24868993, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24868994, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24868995, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24868996, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24868997, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24868998, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24868999, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24869534, 'dashboard_result_id': 12455363, '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_P24869534_12-07-2025_02_33_01.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24869538, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24869539, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24869540, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24869541, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24869542, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24869543, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24869544, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24869545, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24869546, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24869547, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24869548, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24869549, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24869978, 'dashboard_result_id': 12455364, '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_P24869978_12-07-2025_02_47_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24870006, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870007, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870008, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870009, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870010, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870011, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870012, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870013, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870014, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870015, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870016, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870017, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24870447, 'dashboard_result_id': 12455365, '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_P24870447_12-07-2025_03_02_57.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870473, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870474, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24870475, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870476, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870477, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870478, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870479, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870480, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870481, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870482, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870483, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870484, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24870835, 'dashboard_result_id': 12455366, '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_P24870835_12-07-2025_03_17_02.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870863, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870864, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870865, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870866, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870867, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870868, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870869, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24870870, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870871, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870872, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870873, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870874, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24871373, 'dashboard_result_id': 12455367, '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_P24871373_12-07-2025_03_33_00.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24871376, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24871377, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24871378, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24871379, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24871380, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24871381, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24871382, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24871383, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24871384, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24871385, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24871386, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24871387, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24871764, 'dashboard_result_id': 12455368, '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_P24871764_12-07-2025_03_47_00.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24871792, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24871793, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24871794, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24871795, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24871796, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24871797, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24871798, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24871799, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24871800, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24871801, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24871802, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24871803, 'pht': 3726}}"}, {'dashboat_entry_day': 1972167, 'dashboard_run_id': 1980002, 'mtr_portfolio_id': 24872219, 'dashboard_result_id': 12455369, '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_P24872219_12-07-2025_03_52_58.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24872245, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24872246, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24872247, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24872248, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24872249, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24872250, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24872251, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24872252, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24872253, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24872254, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24872255, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24872256, '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 = 24862874 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': 3273672, 'mtr_portfolio_id': 24862874, 'created_at': datetime.datetime(2025, 7, 12, 0, 16, 59), 'result': '0.037367531886799636', 'result_long': None, 'result_double': None}] Qualite : 0.037367531886799636 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24862874 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24862874_12-07-2025_00_17_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24862874 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_P24862874_12-07-2025_00_17_00.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24862879, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24862880, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24862881, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24862882, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24862883, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24862884, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24862885, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24862886, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24862887, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24862888, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24862889, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24862890, 'pht': 3726}}" where mtr_portfolio_id = 24862874 and dashboard_run_id = 1980002 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`=24862874 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455354, 0.037367531886799636, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24862874_12-07-2025_00_17_00.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24862879, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24862880, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24862881, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24862882, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24862883, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24862884, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24862885, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24862886, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24862887, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24862888, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24862889, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24862890, '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 = 24863716 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': 3273753, 'mtr_portfolio_id': 24863716, 'created_at': datetime.datetime(2025, 7, 12, 0, 32, 58), 'result': '0.03280463110763884', 'result_long': None, 'result_double': None}] Qualite : 0.03280463110763884 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24863716 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24863716_12-07-2025_00_32_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24863716 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_P24863716_12-07-2025_00_32_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24863736, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24863737, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24863738, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24863739, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24863740, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24863741, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24863742, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24863743, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24863744, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24863745, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24863746, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24863747, 'pht': 3726}}" where mtr_portfolio_id = 24863716 and dashboard_run_id = 1980002 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`=24863716 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455355, 0.03280463110763884, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24863716_12-07-2025_00_32_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24863736, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24863737, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24863738, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24863739, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24863740, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24863741, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24863742, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24863743, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24863744, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24863745, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24863746, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24863747, '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 = 24864264 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': 3273801, 'mtr_portfolio_id': 24864264, 'created_at': datetime.datetime(2025, 7, 12, 0, 46, 56), 'result': '0.045803300599373216', 'result_long': None, 'result_double': None}] Qualite : 0.045803300599373216 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24864264 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24864264_12-07-2025_00_46_57.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24864264 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_P24864264_12-07-2025_00_46_57.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24864292, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24864293, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24864294, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24864295, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24864296, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24864297, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24864298, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24864299, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24864300, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24864301, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24864302, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24864303, 'pht': 3726}}" where mtr_portfolio_id = 24864264 and dashboard_run_id = 1980002 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`=24864264 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455356, 0.045803300599373216, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24864264_12-07-2025_00_46_57.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24864292, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24864293, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24864294, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24864295, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24864296, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24864297, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24864298, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24864299, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24864300, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24864301, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24864302, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24864303, '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 = 24864799 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': 3273845, 'mtr_portfolio_id': 24864799, 'created_at': datetime.datetime(2025, 7, 12, 1, 2, 58), 'result': '0.05501512360551966', 'result_long': None, 'result_double': None}] Qualite : 0.05501512360551966 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24864799 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24864799_12-07-2025_01_02_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24864799 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_P24864799_12-07-2025_01_02_58.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 24864803, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24864804, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24864805, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24864806, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24864807, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24864808, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24864809, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24864810, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24864811, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24864812, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24864813, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24864814, 'pht': 3726}}" where mtr_portfolio_id = 24864799 and dashboard_run_id = 1980002 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`=24864799 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455357, 0.05501512360551966, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24864799_12-07-2025_01_02_58.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 24864803, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24864804, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24864805, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24864806, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24864807, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24864808, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24864809, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24864810, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24864811, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24864812, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24864813, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24864814, '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 = 24865363 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': 3273898, 'mtr_portfolio_id': 24865363, 'created_at': datetime.datetime(2025, 7, 12, 1, 16, 59), 'result': '0.03769358954030426', 'result_long': None, 'result_double': None}] Qualite : 0.03769358954030426 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24865363 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24865363_12-07-2025_01_17_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24865363 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_P24865363_12-07-2025_01_17_00.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 24865438, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24865439, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24865440, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24865441, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24865442, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24865443, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24865444, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24865445, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24865446, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24865447, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24865448, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24865449, 'pht': 3726}}" where mtr_portfolio_id = 24865363 and dashboard_run_id = 1980002 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`=24865363 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455358, 0.03769358954030426, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24865363_12-07-2025_01_17_00.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 24865438, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24865439, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24865440, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24865441, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24865442, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24865443, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24865444, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24865445, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24865446, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24865447, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24865448, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24865449, '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 = 24866369 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': 3273993, 'mtr_portfolio_id': 24866369, 'created_at': datetime.datetime(2025, 7, 12, 1, 32, 57), 'result': '0.04421412132428314', 'result_long': None, 'result_double': None}] Qualite : 0.04421412132428314 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24866369 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24866369_12-07-2025_01_32_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24866369 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_P24866369_12-07-2025_01_32_58.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 24866430, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24866432, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24866433, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24866434, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24866435, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24866437, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24866438, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24866440, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24866441, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24866442, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24866443, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24866445, 'pht': 3726}}" where mtr_portfolio_id = 24866369 and dashboard_run_id = 1980002 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`=24866369 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455359, 0.04421412132428314, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24866369_12-07-2025_01_32_58.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 24866430, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24866432, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24866433, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24866434, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24866435, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24866437, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24866438, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24866440, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24866441, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24866442, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24866443, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24866445, '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 = 24867390 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': 3274040, 'mtr_portfolio_id': 24867390, 'created_at': datetime.datetime(2025, 7, 12, 1, 46, 59), 'result': '0.039274434489525195', 'result_long': None, 'result_double': None}] Qualite : 0.039274434489525195 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24867390 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24867390_12-07-2025_01_46_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24867390 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_P24867390_12-07-2025_01_46_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24867515, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24867516, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24867517, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24867518, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24867519, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24867520, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24867521, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24867522, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24867523, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24867524, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24867525, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24867526, 'pht': 3726}}" where mtr_portfolio_id = 24867390 and dashboard_run_id = 1980002 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`=24867390 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455360, 0.039274434489525195, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24867390_12-07-2025_01_46_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24867515, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24867516, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24867517, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24867518, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24867519, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24867520, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24867521, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24867522, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24867523, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24867524, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24867525, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24867526, '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 = 24868411 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': 3274086, 'mtr_portfolio_id': 24868411, 'created_at': datetime.datetime(2025, 7, 12, 2, 3), 'result': '0.03749161848983475', 'result_long': None, 'result_double': None}] Qualite : 0.03749161848983475 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24868411 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24868411_12-07-2025_02_03_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24868411 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_P24868411_12-07-2025_02_03_01.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24868440, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24868441, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24868442, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24868443, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24868444, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24868445, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24868446, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24868447, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24868448, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24868449, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24868450, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24868451, 'pht': 3726}}" where mtr_portfolio_id = 24868411 and dashboard_run_id = 1980002 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`=24868411 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455361, 0.03749161848983475, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24868411_12-07-2025_02_03_01.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24868440, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24868441, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24868442, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24868443, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24868444, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24868445, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24868446, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24868447, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24868448, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24868449, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24868450, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24868451, '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 = 24868961 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': 3274146, 'mtr_portfolio_id': 24868961, 'created_at': datetime.datetime(2025, 7, 12, 2, 16, 57), 'result': '0.02968191619785732', 'result_long': None, 'result_double': None}] Qualite : 0.02968191619785732 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24868961 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24868961_12-07-2025_02_16_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24868961 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_P24868961_12-07-2025_02_16_58.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24868988, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24868989, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24868990, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24868991, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24868992, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24868993, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24868994, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24868995, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24868996, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24868997, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24868998, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24868999, 'pht': 3726}}" where mtr_portfolio_id = 24868961 and dashboard_run_id = 1980002 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`=24868961 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455362, 0.02968191619785732, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24868961_12-07-2025_02_16_58.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24868988, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24868989, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24868990, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24868991, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24868992, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24868993, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24868994, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24868995, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24868996, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24868997, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24868998, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24868999, '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 = 24869534 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': 3274195, 'mtr_portfolio_id': 24869534, 'created_at': datetime.datetime(2025, 7, 12, 2, 33), 'result': '0.03656668690141409', 'result_long': None, 'result_double': None}] Qualite : 0.03656668690141409 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24869534 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24869534_12-07-2025_02_33_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24869534 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_P24869534_12-07-2025_02_33_01.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24869538, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24869539, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24869540, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24869541, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24869542, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24869543, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24869544, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24869545, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24869546, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24869547, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24869548, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24869549, 'pht': 3726}}" where mtr_portfolio_id = 24869534 and dashboard_run_id = 1980002 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`=24869534 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455363, 0.03656668690141409, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24869534_12-07-2025_02_33_01.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24869538, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24869539, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24869540, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24869541, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24869542, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24869543, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24869544, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24869545, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24869546, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24869547, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24869548, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24869549, '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 = 24869978 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': 3274235, 'mtr_portfolio_id': 24869978, 'created_at': datetime.datetime(2025, 7, 12, 2, 46, 59), 'result': '0.04038063491783955', 'result_long': None, 'result_double': None}] Qualite : 0.04038063491783955 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24869978 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24869978_12-07-2025_02_47_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24869978 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_P24869978_12-07-2025_02_47_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24870006, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870007, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870008, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870009, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870010, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870011, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870012, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870013, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870014, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870015, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870016, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870017, 'pht': 3726}}" where mtr_portfolio_id = 24869978 and dashboard_run_id = 1980002 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`=24869978 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455364, 0.04038063491783955, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24869978_12-07-2025_02_47_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 24870006, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870007, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870008, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870009, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870010, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870011, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870012, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870013, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870014, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870015, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870016, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870017, '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 = 24870447 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': 3274281, 'mtr_portfolio_id': 24870447, 'created_at': datetime.datetime(2025, 7, 12, 3, 2, 56), 'result': '0.04984134724630969', 'result_long': None, 'result_double': None}] Qualite : 0.04984134724630969 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24870447 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24870447_12-07-2025_03_02_57.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24870447 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_P24870447_12-07-2025_03_02_57.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870473, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870474, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24870475, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870476, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870477, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870478, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870479, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870480, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870481, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870482, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870483, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870484, 'pht': 3726}}" where mtr_portfolio_id = 24870447 and dashboard_run_id = 1980002 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`=24870447 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455365, 0.04984134724630969, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24870447_12-07-2025_03_02_57.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870473, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870474, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24870475, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870476, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870477, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870478, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870479, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870480, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870481, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870482, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870483, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870484, '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 = 24870835 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': 3274336, 'mtr_portfolio_id': 24870835, 'created_at': datetime.datetime(2025, 7, 12, 3, 17, 1), 'result': '0.05701784532078715', 'result_long': None, 'result_double': None}] Qualite : 0.05701784532078715 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24870835 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24870835_12-07-2025_03_17_02.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24870835 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_P24870835_12-07-2025_03_17_02.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870863, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870864, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870865, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870866, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870867, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870868, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870869, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24870870, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870871, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870872, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870873, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870874, 'pht': 3726}}" where mtr_portfolio_id = 24870835 and dashboard_run_id = 1980000 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`=24870835 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455366, 0.05701784532078715, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24870835_12-07-2025_03_17_02.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24870863, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24870864, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24870865, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24870866, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24870867, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24870868, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24870869, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24870870, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24870871, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24870872, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24870873, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24870874, '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 = 24871373 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': 3274384, 'mtr_portfolio_id': 24871373, 'created_at': datetime.datetime(2025, 7, 12, 3, 32, 59), 'result': '0.05093827072838168', 'result_long': None, 'result_double': None}] Qualite : 0.05093827072838168 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24871373 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24871373_12-07-2025_03_33_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24871373 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_P24871373_12-07-2025_03_33_00.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24871376, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24871377, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24871378, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24871379, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24871380, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24871381, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24871382, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24871383, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24871384, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24871385, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24871386, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24871387, 'pht': 3726}}" where mtr_portfolio_id = 24871373 and dashboard_run_id = 1980000 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`=24871373 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455367, 0.05093827072838168, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24871373_12-07-2025_03_33_00.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24871376, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24871377, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24871378, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24871379, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24871380, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24871381, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24871382, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24871383, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24871384, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24871385, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24871386, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24871387, '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 = 24871764 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': 3274421, 'mtr_portfolio_id': 24871764, 'created_at': datetime.datetime(2025, 7, 12, 3, 46, 59), 'result': '0.03973405683915852', 'result_long': None, 'result_double': None}] Qualite : 0.03973405683915852 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24871764 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24871764_12-07-2025_03_47_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24871764 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_P24871764_12-07-2025_03_47_00.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24871792, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24871793, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24871794, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24871795, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24871796, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24871797, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24871798, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24871799, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24871800, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24871801, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24871802, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24871803, 'pht': 3726}}" where mtr_portfolio_id = 24871764 and dashboard_run_id = 1980000 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`=24871764 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455368, 0.03973405683915852, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24871764_12-07-2025_03_47_00.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24871792, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24871793, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24871794, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24871795, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24871796, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24871797, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24871798, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24871799, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24871800, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24871801, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24871802, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24871803, '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 = 24872219 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': 3274462, 'mtr_portfolio_id': 24872219, 'created_at': datetime.datetime(2025, 7, 12, 3, 54, 58), 'result': '0.047041016685700696', 'result_long': None, 'result_double': None}] Qualite : 0.047041016685700696 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 24872219 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24872219_12-07-2025_03_54_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 24872219 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_P24872219_12-07-2025_03_54_59.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24872245, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24872246, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24872247, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24872248, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24872249, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24872250, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24872251, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24872252, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24872253, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24872254, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24872255, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24872256, 'pht': 3726}}" where mtr_portfolio_id = 24872219 and dashboard_run_id = 1980000 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`=24872219 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (12455369, 0.047041016685700696, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P24872219_12-07-2025_03_54_59.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 24872245, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 24872246, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 24872247, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 24872248, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 24872249, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 24872250, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 24872251, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 24872252, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 24872253, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 24872254, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 24872255, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 24872256, '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 (24862874,24863716,24864264,24864799,24865363,24866369,24867390,24868411,24868961,24869534,24869978,24870447,24870835,24871373,24871764,24872219) result : ((1371742379,), (1371742409,), (1371742439,), (1371742467,), (1371742493,), (1371742810,), (1371742839,), (1371742869,), (1371742894,), (1371742918,), (1371742943,), (1371743083,), (1371743084,), (1371743103,), (1371743104,), (1371743131,), (1371743137,), (1371743164,), (1371743167,), (1371743191,), (1371743196,), (1371743220,), (1371743223,), (1371743306,), (1371743309,), (1371743312,), (1371743340,), (1371743358,), (1371743368,), (1371743470,), (1371743474,), (1371743479,), (1371743505,), (1371743531,), (1371743558,), (1371743769,), (1371743777,), (1371743781,), (1371743786,), (1371743808,), (1371743836,), (1371743987,), (1371744038,), (1371744092,), (1371744216,), (1371744321,), (1371744440,), (1371744789,), (1371744950,), (1371745105,), (1371745166,), (1371745248,), (1371745345,), (1371745593,), (1371745621,), (1371745663,), (1371745726,), (1371745808,), (1371745824,), (1371746189,), (1371746240,), (1371746298,), (1371746311,), (1371746325,), (1371746331,), (1371746501,), (1371746504,), (1371746508,), (1371746512,), (1371746515,), (1371746520,), (1371746569,), (1371746583,), (1371746607,), (1371746632,), (1371746659,), (1371746685,), (1371746815,), (1371746817,), (1371746818,), (1371746838,), (1371746843,), (1371746854,), (1371747126,), (1371747160,), (1371747186,), (1371747211,), (1371747235,), (1371747269,), (1371747638,), (1371747660,), (1371747687,), (1371747705,), (1371747710,), (1371747716,), (1371747773,), (1371747803,), (1371747842,), (1371747869,), (1371747882,), (1371747883,), (1371748191,), (1371748226,), (1371748292,), (1371748342,), (1371748367,), (1371748380,), (1371748740,), (1371748777,), (1371748817,), (1371748841,), (1371748871,), (1371748900,), (1371749035,), (1371749067,), (1371749121,), (1371749168,), (1371749218,), (1371749277,), (1371749616,), (1371749631,), (1371749649,), (1371749652,), (1371749653,), (1371749657,), (1371749730,), (1371749732,), (1371749735,), (1371749737,), (1371749739,), (1371749741,), (1371749784,), (1371749788,), (1371749791,), (1371749794,), (1371749799,), (1371749804,), (1371749818,), (1371749821,), (1371749823,), (1371749826,), (1371749829,), (1371749833,), (1371749877,), (1371749879,), (1371749883,), (1371749887,), (1371749891,), (1371749895,), (1371749945,), (1371749947,), (1371749949,), (1371749950,), (1371749970,), (1371749981,), (1371750000,), (1371750004,), (1371750007,), (1371750022,), (1371750048,), (1371750075,), (1371750384,), (1371750395,), (1371750398,), (1371750403,), (1371750406,), (1371750407,), (1371750451,), (1371750455,), (1371750459,), (1371750462,), (1371750467,), (1371750470,), (1371750523,), (1371750526,), (1371750528,), (1371750533,), (1371750538,), (1371750545,), (1371750621,), (1371750663,), (1371750711,), (1371750754,), (1371750800,), (1371750854,), (1371751193,), (1371751204,), (1371751218,), (1371751221,), (1371751224,), (1371751226,), (1371751298,), (1371751302,), (1371751313,), (1371751317,), (1371751321,), (1371751326,), (1371751335,), (1371751336,), (1371751343,), (1371751344,), (1371751351,), (1371751353,), (1371751356,), (1371751358,), (1371751362,), (1371751366,), (1371751374,), (1371751376,), (1371751394,), (1371751397,), (1371751399,), (1371751413,), (1371751421,), (1371751428,), (1371751438,), (1371751467,), (1371751472,), (1371751476,), (1371751480,), (1371751484,), (1371751492,), (1371751493,), (1371751495,), (1371751496,), (1371751498,), (1371751499,), (1371751501,), (1371751502,), (1371751504,), (1371751505,), (1371751508,), (1371751509,), (1371751527,), (1371751539,), (1371751544,), (1371751548,), (1371751552,), (1371751555,), (1371751613,), (1371751618,), (1371751622,), (1371751639,), (1371751665,), (1371751689,), (1371752002,), (1371752028,), (1371752051,), (1371752078,), (1371752104,), (1371752129,), (1371752184,), (1371752189,), (1371752193,), (1371752195,), (1371752198,), (1371752201,), (1371752337,), (1371752367,), (1371752392,), (1371752421,), (1371752446,), (1371752477,), (1371752620,), (1371752626,), (1371752631,), (1371752635,), (1371752639,), (1371752642,), (1371752818,), (1371752820,), (1371752824,), (1371752828,), (1371752832,), (1371752834,), (1371753104,), (1371753112,), (1371753115,), (1371753118,), (1371753120,), (1371753122,), (1371753173,), (1371753174,), (1371753177,), (1371753178,), (1371753182,), (1371753183,), (1371753189,), (1371753191,), (1371753200,), (1371753202,), (1371753207,), (1371753210,), (1371753216,), (1371753218,), (1371753221,), (1371753224,), (1371753228,), (1371753234,), (1371753581,), (1371753610,), (1371753640,), (1371753666,), (1371753691,), (1371753720,), (1371753908,), (1371753911,), (1371753915,), (1371753917,), (1371753921,), (1371753923,), (1371753927,), (1371753929,), (1371753931,), (1371753934,), (1371753935,), (1371753936,), (1371753944,), (1371753948,), (1371753952,), (1371753956,), (1371753961,), (1371753967,), (1371754076,), (1371754100,), (1371754130,), (1371754157,), (1371754182,), (1371754210,), (1371754604,), (1371754634,), (1371754669,), (1371754697,), (1371754727,), (1371754764,), (1371754875,), (1371754886,), (1371754892,), (1371754895,), (1371754905,), (1371754932,), (1371755073,), (1371755086,), (1371755089,), (1371755092,), (1371755095,), (1371755096,), (1371755158,), (1371755163,), (1371755165,), (1371755167,), (1371755169,), (1371755172,), (1371755218,), (1371755219,), (1371755221,), (1371755222,), (1371755226,), (1371755227,), (1371755229,), (1371755231,), (1371755232,), (1371755234,), (1371755237,), (1371755239,), (1371755249,), (1371755254,), (1371755259,), (1371755263,), (1371755266,), (1371755270,), (1371755321,), (1371755325,), (1371755332,), (1371755364,), (1371755411,), (1371755496,), (1371755650,), (1371755722,), (1371755786,), (1371755844,), (1371755870,), (1371755897,), (1371756004,), (1371756031,), (1371756036,), (1371756052,), (1371756079,), (1371756151,), (1371756377,), (1371756421,), (1371756510,), (1371756560,), (1371756623,), (1371756665,), (1371757110,), (1371757119,), (1371757123,), (1371757129,), (1371757172,), (1371757216,), (1371757558,), (1371757570,), (1371757572,), (1371757574,), (1371757576,), (1371757626,), (1371757629,), (1371757631,), (1371757634,), (1371757637,), (1371757640,), (1371757661,), (1371757663,), (1371757666,), (1371757668,), (1371757671,), (1371757675,), (1371757691,), (1371757694,), (1371757699,), (1371757702,), (1371757703,), (1371757706,), (1371757734,), (1371757736,), (1371757739,), (1371757743,), (1371757745,), (1371757750,), (1371757776,), (1371757779,), (1371757781,), (1371757783,), (1371757786,), (1371757789,), (1371757825,), (1371757830,), (1371757835,), (1371757839,), (1371757844,), (1371757849,), (1371757862,), (1371757870,), (1371757885,), (1371757908,), (1371757934,), (1371757961,), (1371758310,), (1371758334,), (1371758359,), (1371758382,), (1371758386,), (1371758404,), (1371758485,), (1371758498,), (1371758510,), (1371758552,), (1371758596,), (1371758636,), (1371759065,), (1371759135,), (1371759194,), (1371759254,), (1371759329,), (1371759391,), (1371760020,), (1371760075,), (1371760108,), (1371760146,), (1371760171,), (1371760195,), (1371760545,), (1371760549,), (1371760570,), (1371760576,), (1371760588,), (1371760593,), (1371760596,), (1371760598,), (1371760600,), (1371760602,), (1371760605,), (1371760607,), (1371760730,), (1371760833,), (1371760936,), (1371760993,), (1371761086,), (1371761140,), (1371761572,), (1371761631,), (1371761679,), (1371761682,), (1371761684,), (1371761687,), (1371762013,), (1371762042,), (1371762069,), (1371762094,), (1371762123,), (1371762174,), (1371762342,), (1371762372,), (1371762429,), (1371762520,), (1371762599,), (1371762662,), (1371763239,), (1371763288,), (1371763312,), (1371763315,), (1371763317,), (1371763324,), (1371763659,), (1371763663,), (1371763692,), (1371763738,), (1371763819,), (1371763888,), (1371763904,), (1371763916,), (1371763921,), (1371763924,), (1371763925,), (1371763926,), (1371764086,), (1371764112,), (1371764140,), (1371764170,), (1371764216,), (1371764267,), (1371764836,), (1371764868,), (1371764887,), (1371764913,), (1371764958,), (1371764978,), (1371765863,), (1371765866,), (1371765933,), (1371765937,), (1371766023,), (1371766030,), (1371766105,), (1371766122,), (1371766175,), (1371766196,), (1371766261,), (1371766277,), (1371766432,), (1371766474,), (1371766509,), (1371766535,), (1371766592,), (1371766622,), (1371766701,), (1371766705,), (1371766709,), (1371766711,), (1371766717,), (1371766719,), (1371766975,), (1371766977,), (1371766999,), (1371767003,), (1371767023,), (1371767028,), (1371767084,), (1371767099,), (1371767169,), (1371767188,), (1371767230,), (1371767235,), (1371767299,), (1371767323,), (1371767345,), (1371767407,), (1371767409,), (1371767415,), (1371767520,), (1371767523,), (1371767527,), (1371767531,), (1371767533,), (1371767536,), (1371767704,), (1371767706,), (1371767728,), (1371767730,), (1371767746,), (1371767789,), (1371767904,), (1371767932,), (1371767957,), (1371767984,), (1371767999,), (1371768000,), (1371768392,), (1371768431,), (1371768481,), (1371768538,), (1371768569,), (1371768674,), (1371769369,), (1371769405,), (1371769461,), (1371769523,), (1371769558,), (1371769585,), (1371769831,), (1371769857,), (1371769883,), (1371769917,), (1371769945,), (1371769979,), (1371770071,), (1371770099,), (1371770122,), (1371770148,), (1371770174,), (1371770199,), (1371770824,), (1371770863,), (1371770906,), (1371770952,), (1371771003,), (1371771056,), (1371771490,), (1371771564,), (1371771588,), (1371771631,), (1371771647,), (1371771675,), (1371771770,), (1371771774,), (1371771790,), (1371771811,), (1371771816,), (1371771836,), (1371772100,), (1371772123,), (1371772147,), (1371772175,), (1371772192,), (1371772224,), (1371772528,), (1371772550,), (1371772583,), (1371772623,), (1371772645,), (1371772666,), (1371772807,), (1371772830,), (1371772860,), (1371772886,), (1371772913,), (1371772918,), (1371773175,), (1371773198,), (1371773220,), (1371773232,), (1371773246,), (1371773254,), (1371773812,), (1371773843,), (1371773876,), (1371773932,), (1371773981,), (1371774026,), (1371774161,), (1371774164,), (1371774167,), (1371774169,), (1371774174,), (1371774180,), (1371774192,), (1371774200,), (1371774203,), (1371774205,), (1371774206,), (1371774207,), (1371774234,), (1371774237,), (1371774240,), (1371774242,), (1371774244,), (1371774247,), (1371774417,), (1371774442,), (1371774465,), (1371774492,), (1371774527,), (1371774555,), (1371774626,), (1371774636,), (1371774640,), (1371774643,), (1371774653,), (1371774655,), (1371774697,), (1371774699,), (1371774702,), (1371774703,), (1371774707,), (1371774715,), (1371774729,), (1371774734,), (1371774738,), (1371774741,), (1371774744,), (1371774745,), (1371774765,), (1371774767,), (1371774771,), (1371774773,), (1371774776,), (1371774778,), (1371774807,), (1371774809,), (1371774811,), (1371774812,), (1371774813,), (1371774814,), (1371774832,), (1371774841,), (1371774845,), (1371774849,), (1371774852,), (1371774855,), (1371774931,), (1371774936,), (1371774941,), (1371774946,), (1371774950,), (1371774953,), (1371775067,), (1371775091,), (1371775116,), (1371775139,), (1371775160,), (1371775184,), (1371775332,), (1371775333,), (1371775363,), (1371775374,), (1371775415,), (1371775424,), (1371775461,), (1371775468,), (1371775501,), (1371775516,), (1371775551,), (1371775562,), (1371775671,), (1371775706,), (1371775724,), (1371775728,), (1371775729,), (1371775730,), (1371775859,), (1371775862,), (1371775865,), (1371775868,), (1371775870,), (1371775872,), (1371776209,), (1371776254,), (1371776293,), (1371776337,), (1371776389,), (1371776415,), (1371776860,), (1371776866,), (1371776891,), (1371776901,), (1371776904,), (1371776907,), (1371776915,), (1371776917,), (1371776924,), (1371776932,), (1371776934,), (1371776942,), (1371776944,), (1371776955,), (1371776963,), (1371776965,), (1371776967,), (1371777018,), (1371777023,), (1371777039,), (1371777067,), (1371777092,), (1371777117,), (1371777255,), (1371777350,), (1371777462,), (1371777578,), (1371777682,), (1371777788,), (1371778657,), (1371778699,), (1371778754,), (1371778783,), (1371778827,), (1371778887,), (1371779059,), (1371779112,), (1371779146,), (1371779177,), (1371779213,), (1371779220,), (1371779434,), (1371779482,), (1371779527,), (1371779591,), (1371779639,), (1371779684,), (1371779998,), (1371780013,), (1371780026,), (1371780050,), (1371780072,), (1371780086,), (1371780243,), (1371780244,), (1371780248,), (1371780249,), (1371780253,), (1371780254,), (1371780259,), (1371780261,), (1371780265,), (1371780266,), (1371780271,), (1371780272,), (1371780279,), (1371780280,), (1371780282,), (1371780283,), (1371780285,), (1371780287,), (1371780313,), (1371780316,), (1371780320,), (1371780324,), (1371780326,), (1371780329,), (1371780365,), (1371780368,), (1371780371,), (1371780372,), (1371780375,), (1371780380,), (1371780392,), (1371780394,), (1371780398,), (1371780401,), (1371780408,), (1371780409,), (1371780435,), (1371780437,), (1371780440,), (1371780443,), (1371780446,), (1371780448,), (1371780471,), (1371780474,), (1371780475,), (1371780477,), (1371780479,), (1371780480,), (1371780520,), (1371780521,), (1371780523,), (1371780524,), (1371780526,), (1371780527,), (1371780529,), (1371780530,), (1371780531,), (1371780534,), (1371780535,), (1371780538,), (1371780547,), (1371780551,), (1371780556,), (1371780557,), (1371780559,), (1371780561,), (1371780603,), (1371780605,), (1371780608,), (1371780611,), (1371780614,), (1371780616,), (1371780646,), (1371780647,), (1371780649,), (1371780651,), (1371780652,), (1371780654,), (1371780662,), (1371780665,), (1371780669,), (1371780679,), (1371780684,), (1371780685,), (1371780710,), (1371780712,), (1371780716,), (1371780717,), (1371780719,), (1371780721,), (1371780771,), (1371780772,), (1371780775,), (1371780777,), (1371780781,), (1371780784,), (1371780798,), (1371780802,), (1371780805,), (1371780808,), (1371780810,), (1371780812,), (1371780845,), (1371780847,), (1371780851,), (1371780853,), (1371780855,), (1371780858,), (1371780864,), (1371780867,), (1371780870,), (1371780874,), (1371780876,), (1371780878,), (1371780958,), (1371780960,), (1371780961,), (1371780994,), (1371780996,), (1371780999,), (1371781018,), (1371781020,), (1371781024,), (1371781028,), (1371781030,), (1371781034,), (1371781060,), (1371781062,), (1371781063,), (1371781065,), (1371781068,), (1371781069,), (1371781082,), (1371781085,), (1371781086,), (1371781090,), (1371781094,), (1371781097,), (1371781134,), (1371781136,), (1371781138,), (1371781139,), (1371781140,), (1371781141,), (1371781161,), (1371781162,), (1371781164,), (1371781166,), (1371781171,), (1371781179,), (1371781184,), (1371781187,), (1371781191,), (1371781193,), (1371781196,), (1371781198,), (1371781233,), (1371781235,), (1371781236,), (1371781238,), (1371781240,), (1371781241,), (1371781279,), (1371781280,), (1371781282,), (1371781285,), (1371781286,), (1371781288,), (1371781313,), (1371781314,), (1371781315,), (1371781316,), (1371781319,), (1371781321,), (1371781325,), (1371781326,), (1371781327,), (1371781328,), (1371781330,), (1371781331,), (1371781336,), (1371781338,), (1371781339,), (1371781340,), (1371781341,), (1371781343,), (1371781373,), (1371781375,), (1371781379,), (1371781382,), (1371781385,), (1371781389,), (1371781419,), (1371781420,), (1371781422,), (1371781423,), (1371781425,), (1371781426,), (1371781428,), (1371781429,), (1371781431,), (1371781433,), (1371781435,), (1371781436,), (1371781456,), (1371781467,), (1371781472,), (1371781483,), (1371781484,), (1371781488,), (1371781513,), (1371781514,), (1371781516,), (1371781519,), (1371781522,), (1371781528,), (1371781565,), (1371781566,), (1371781568,), (1371781569,), (1371781578,), (1371781579,), (1371781580,), (1371781581,), (1371781584,), (1371781585,), (1371781586,), (1371781587,), (1371781601,), (1371781606,), (1371781608,), (1371781613,), (1371781617,), (1371781619,), (1371781651,), (1371781653,), (1371781655,), (1371781657,), (1371781659,), (1371781660,), (1371781691,), (1371781692,), (1371781695,), (1371781697,), (1371781699,), (1371781701,), (1371781703,), (1371781707,), (1371781708,), (1371781713,), (1371781714,), (1371781717,), (1371781729,), (1371781732,), (1371781734,), (1371781735,), (1371781743,), (1371781746,), (1371781774,), (1371781775,), (1371781777,), (1371781779,), (1371781781,), (1371781784,), (1371781791,), (1371781802,), (1371781805,), (1371781819,), (1371781825,), (1371781834,), (1371781877,), (1371781879,), (1371781881,), (1371781882,), (1371781883,), (1371781885,), (1371781922,), (1371781923,), (1371781925,), (1371781928,), (1371781931,), (1371781935,), (1371781942,), (1371781945,), (1371781949,), (1371781951,), (1371781954,), (1371781957,), (1371781987,), (1371781989,), (1371781993,), (1371781997,), (1371782000,), (1371782003,), (1371782050,), (1371782052,), (1371782055,), (1371782058,), (1371782061,), (1371782063,), (1371782085,), (1371782089,), (1371782092,), (1371782095,), (1371782099,), (1371782101,), (1371782136,), (1371782138,), (1371782139,), (1371782140,), (1371782142,), (1371782144,), (1371782162,), (1371782165,), (1371782168,), (1371782171,), (1371782172,), (1371782174,), (1371782199,), (1371782201,), (1371782204,), (1371782207,), (1371782209,), (1371782213,), (1371782221,), (1371782225,), (1371782228,), (1371782230,), (1371782232,), (1371782234,), (1371782276,), (1371782279,), (1371782282,), (1371782285,), (1371782289,), (1371782291,), (1371782360,), (1371782385,), (1371782419,), (1371782478,), (1371782524,), (1371782571,), (1371783353,), (1371783368,), (1371783373,), (1371783376,), (1371783379,), (1371783383,), (1371783631,), (1371783633,), (1371783648,), (1371783675,), (1371783698,), (1371784025,), (1371784051,), (1371784076,), (1371784106,), (1371784135,), (1371784162,), (1371784366,), (1371784367,), (1371784368,), (1371784369,), (1371784370,), (1371784371,), (1371784372,), (1371784373,), (1371784375,), (1371784376,), (1371784391,), (1371784398,), (1371784501,), (1371784524,), (1371784550,), (1371784573,), (1371784581,), (1371784588,), (1371784715,), (1371784717,), (1371784720,), (1371784722,), (1371784723,), (1371784725,), (1371784755,), (1371784756,), (1371784758,), (1371784760,), (1371784762,), (1371784765,), (1371784770,), (1371784772,), (1371784775,), (1371784778,), (1371784781,), (1371784785,), (1371784821,), (1371784824,), (1371784827,), (1371784829,), (1371784835,), (1371784843,), (1371784849,), (1371784851,), (1371784852,), (1371784854,), (1371784855,), (1371784857,), (1371784880,), (1371784883,), (1371784885,), (1371784887,), (1371784889,), (1371784890,), (1371784948,), (1371784949,), (1371784950,), (1371784952,), (1371784954,), (1371784956,), (1371784993,), (1371784996,), (1371785006,), (1371785011,), (1371785012,), (1371785015,), (1371785024,), (1371785027,), (1371785029,), (1371785031,), (1371785032,), (1371785034,), (1371785063,), (1371785065,), (1371785067,), (1371785069,), (1371785071,), (1371785074,), (1371785101,), (1371785102,), (1371785104,), (1371785105,), (1371785107,), (1371785108,), (1371785113,), (1371785116,), (1371785120,), (1371785126,), (1371785131,), (1371785133,), (1371785145,), (1371785147,), (1371785149,), (1371785151,), (1371785153,), (1371785154,), (1371785191,), (1371785192,), (1371785193,), (1371785194,), (1371785195,), (1371785196,), (1371785197,), (1371785198,), (1371785200,), (1371785201,), (1371785204,), (1371785205,), (1371785218,), (1371785220,), (1371785222,), (1371785223,), (1371785224,), (1371785225,), (1371785263,), (1371785266,), (1371785268,), (1371785270,), (1371785272,), (1371785274,), (1371785334,), (1371785335,), (1371785336,), (1371785337,), (1371785340,), (1371785357,), (1371785365,), (1371785368,), (1371785372,), (1371785374,), (1371785375,), (1371785376,), (1371785409,), (1371785411,), (1371785414,), (1371785417,), (1371785420,), (1371785424,), (1371785468,), (1371785470,), (1371785471,), (1371785473,), (1371785474,), (1371785475,), (1371785520,), (1371785521,), (1371785524,), (1371785525,), (1371785528,), (1371785529,), (1371785538,), (1371785540,), (1371785543,), (1371785544,), (1371785548,), (1371785551,), (1371785560,), (1371785564,), (1371785565,), (1371785569,), (1371785571,), (1371785573,), (1371785603,), (1371785604,), (1371785606,), (1371785608,), (1371785610,), (1371785614,), (1371785641,), (1371785644,), (1371785647,), (1371785650,), (1371785653,), (1371785656,), (1371785664,), (1371785668,), (1371785670,), (1371785680,), (1371785694,), (1371785703,), (1371785738,), (1371785740,), (1371785742,), (1371785743,), (1371785744,), (1371785745,), (1371785761,), (1371785772,), (1371785775,), (1371785779,), (1371785781,), (1371785783,), (1371785833,), (1371785836,), (1371785841,), (1371785846,), (1371785849,), (1371785851,), (1371785883,), (1371785886,), (1371785888,), (1371785890,), (1371785892,), (1371785894,), (1371785921,), (1371785922,), (1371785924,), (1371785925,), (1371785928,), (1371785929,), (1371785931,), (1371785933,), (1371785935,), (1371785936,), (1371785940,), (1371785941,), (1371785954,), (1371785956,), (1371785958,), (1371785961,), (1371785963,), (1371785965,), (1371786004,), (1371786007,), (1371786009,), (1371786011,), (1371786012,), (1371786013,), (1371786037,), (1371786040,), (1371786045,), (1371786049,), (1371786051,), (1371786053,), (1371786057,), (1371786061,), (1371786064,), (1371786066,), (1371786069,), (1371786070,), (1371786098,), (1371786099,), (1371786102,), (1371786105,), (1371786106,), (1371786110,), (1371786141,), (1371786142,), (1371786145,), (1371786147,), (1371786149,), (1371786152,), (1371786153,), (1371786155,), (1371786156,), (1371786158,), (1371786159,), (1371786160,), (1371786178,), (1371786179,), (1371786188,), (1371786198,), (1371786202,), (1371786206,), (1371786220,), (1371786222,), (1371786223,), (1371786225,), (1371786227,), (1371786246,), (1371786357,), (1371786383,), (1371786412,), (1371786437,), (1371786441,), (1371786442,), (1371786511,), (1371786516,), (1371786524,), (1371786547,), (1371786551,), (1371786552,), (1371786696,), (1371786700,), (1371786702,), (1371786705,), (1371786707,), (1371786708,), (1371786741,), (1371786742,), (1371786744,), (1371786746,), (1371786748,), (1371786751,), (1371786782,), (1371786783,), (1371786784,), (1371786785,), (1371786786,), (1371786787,), (1371786788,), (1371786789,), (1371786791,), (1371786792,), (1371786795,), (1371786796,), (1371786804,), (1371786808,), (1371786809,), (1371786811,), (1371786813,), (1371786815,), (1371786856,), (1371786859,), (1371786860,), (1371786862,), (1371786865,), (1371786866,), (1371786892,), (1371786894,), (1371786895,), (1371786897,), (1371786900,), (1371786902,), (1371786909,), (1371786912,), (1371786915,), (1371786918,), (1371786921,), (1371786923,), (1371786956,), (1371786957,), (1371786958,), (1371786959,), (1371786960,), (1371786962,), (1371786986,), (1371786988,), (1371786990,), (1371786992,), (1371786999,), (1371787008,), (1371787018,), (1371787019,), (1371787023,), (1371787027,), (1371787029,), (1371787031,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'12072025': {'nb_upload': 54, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([24872219]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986] map_info['map_portfolio_photo'] : {24872219: [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986, 1371786962, 1371786960, 1371786959, 1371786958, 1371786957, 1371786956, 1371786923, 1371786921, 1371786918, 1371786915, 1371786912, 1371786909, 1371786902, 1371786900, 1371786897, 1371786895, 1371786894, 1371786892, 1371786866, 1371786865, 1371786862, 1371786860, 1371786859, 1371786856, 1371786815, 1371786813, 1371786811, 1371786809, 1371786808, 1371786804, 1371786796, 1371786795, 1371786792, 1371786791, 1371786789, 1371786788, 1371786787, 1371786786, 1371786785, 1371786784, 1371786783, 1371786782]} final : True mtd_id 4302 list_pids : [1371787031, 1371787029, 1371787027, 1371787023, 1371787019, 1371787018, 1371787008, 1371786999, 1371786992, 1371786990, 1371786988, 1371786986] Looping around the photos to save general results len do output : 1 /24872219Didn'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, '3274462') ('4302', '24872219', '1371787031', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787029', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787027', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787023', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787019', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787018', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371787008', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786999', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786992', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786990', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786988', None, None, None, None, None, '3274462') ('4302', None, None, None, None, None, None, None, '3274462') ('4302', '24872219', '1371786986', None, None, None, None, None, '3274462') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 13 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, '24872219', 'None', None, None, None, None, '3274462'), ('4302', '24872219', '1371787031', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787029', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787027', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787023', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787019', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787018', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371787008', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786999', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786992', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786990', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786988', None, None, None, None, None, '3274462'), ('4302', '24872219', '1371786986', None, None, None, None, None, '3274462')] time used for this insertion : 0.019799232482910156 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.0048420429229736 time spend to save output : 0.02001357078552246 total time spend for step 5 : 1.024855613708496 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 (3274462) 2.17user 2.38system 0:09.34elapsed 48%CPU (0avgtext+0avgdata 160212maxresident)k 96inputs+10200outputs (3major+64204minor)pagefaults 0swaps