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 : 2168434 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 (3362181) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (3362181) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361494 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['3362181'] with mtr_portfolio_ids : ['25361494'] and first list_photo_ids : [] new path : /proc/2168434/ Name: python3 Umask: 0002 State: R (running) Tgid: 2168434 Ngid: 0 Pid: 2168434 PPid: 2168433 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 2168434 NSpid: 2168434 NSpgid: 2166799 NSsid: 2166799 VmPeak: 1106896 kB VmSize: 1106896 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 99732 kB VmRSS: 99732 kB RssAnon: 59816 kB RssFile: 39916 kB RssShmem: 0 kB VmData: 865648 kB VmStk: 132 kB VmExe: 2644 kB VmLib: 130468 kB VmPTE: 600 kB VmSwap: 0 kB HugetlbPages: 0 kB CoreDumping: 0 THP_enabled: 1 Threads: 1 SigQ: 0/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: 50 nonvoluntary_ctxt_switches: 102 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '2168434', 'Ngid': '0', 'Pid': '2168434', 'PPid': '2168433', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '2168434', 'NSpid': '2168434', 'NSpgid': '2166799', 'NSsid': '2166799', 'VmPeak': '1106896 kB', 'VmSize': '1106896 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '99732 kB', 'VmRSS': '99732 kB', 'RssAnon': '59816 kB', 'RssFile': '39916 kB', 'RssShmem': '0 kB', 'VmData': '865648 kB', 'VmStk': '132 kB', 'VmExe': '2644 kB', 'VmLib': '130468 kB', 'VmPTE': '600 kB', 'VmSwap': '0 kB', 'HugetlbPages': '0 kB', 'CoreDumping': '0', 'THP_enabled': '1', 'Threads': '1', 'SigQ': '0/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': '50', 'nonvoluntary_ctxt_switches': '102'} ('datou_batch_current', '2168434', '1106896', '0', '1106896', '865648', '99732', b'', 'marlene', '3362181') 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 (25361494) 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 (3362181 ) ) 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 (25361494) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1373861780, 'portfolio_id': 25361494}, {'photo_id': 1373861776, 'portfolio_id': 25361494}, {'photo_id': 1373861773, 'portfolio_id': 25361494}, {'photo_id': 1373861770, 'portfolio_id': 25361494}, {'photo_id': 1373861767, 'portfolio_id': 25361494}, {'photo_id': 1373861765, 'portfolio_id': 25361494}, {'photo_id': 1373861749, 'portfolio_id': 25361494}, {'photo_id': 1373861747, 'portfolio_id': 25361494}, {'photo_id': 1373861746, 'portfolio_id': 25361494}, {'photo_id': 1373861745, 'portfolio_id': 25361494}, {'photo_id': 1373861744, 'portfolio_id': 25361494}, {'photo_id': 1373861743, 'portfolio_id': 25361494}, {'photo_id': 1373861727, 'portfolio_id': 25361494}, {'photo_id': 1373861724, 'portfolio_id': 25361494}, {'photo_id': 1373861722, 'portfolio_id': 25361494}, {'photo_id': 1373861721, 'portfolio_id': 25361494}, {'photo_id': 1373861719, 'portfolio_id': 25361494}, {'photo_id': 1373861716, 'portfolio_id': 25361494}, {'photo_id': 1373861700, 'portfolio_id': 25361494}, {'photo_id': 1373861685, 'portfolio_id': 25361494}, {'photo_id': 1373861681, 'portfolio_id': 25361494}, {'photo_id': 1373861678, 'portfolio_id': 25361494}, {'photo_id': 1373861676, 'portfolio_id': 25361494}, {'photo_id': 1373861674, 'portfolio_id': 25361494}, {'photo_id': 1373861673, 'portfolio_id': 25361494}] map_portfolio_id_photo_id: {25361494: [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765, 1373861749, 1373861747, 1373861746, 1373861745, 1373861744, 1373861743, 1373861727, 1373861724, 1373861722, 1373861721, 1373861719, 1373861716, 1373861700, 1373861685, 1373861681, 1373861678, 1373861676, 1373861674, 1373861673]} ##### 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.013738393783569336 #### 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 26 03:36: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 (25361494) 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 : 25361494 get user id for portfolio 25361494 get sub ptf for main ptf 25361494, type 3726 and hashtags ['plastique', 'mal_croppe', 'Teint_Dans_La_Masse', 'flou', 'environnement', 'metal', 'Carton_gris', 'papier', 'kraft', 'autre_refus', 'Carton_brun', 'cartonnette'] 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`=25361494 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('plastique','mal_croppe','Teint_Dans_La_Masse','flou','environnement','metal','Carton_gris','papier','kraft','autre_refus','Carton_brun','cartonnette')) 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`=25361494 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('plastique','mal_croppe','Teint_Dans_La_Masse','flou','environnement','metal','Carton_gris','papier','kraft','autre_refus','Carton_brun','cartonnette')) AND mptpi.`min_score`=0.5 To do returned map {'cartonnette': {'main_port_id': 25361494, 'sub_port_id': 25361500, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107007, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'Carton_brun': {'main_port_id': 25361494, 'sub_port_id': 25361501, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107008, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'Teint_Dans_La_Masse': {'main_port_id': 25361494, 'sub_port_id': 25361502, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107009, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'metal': {'main_port_id': 25361494, 'sub_port_id': 25361503, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107010, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'mal_croppe': {'main_port_id': 25361494, 'sub_port_id': 25361504, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107011, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'Carton_gris': {'main_port_id': 25361494, 'sub_port_id': 25361505, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107012, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'autre_refus': {'main_port_id': 25361494, 'sub_port_id': 25361506, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107013, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'environnement': {'main_port_id': 25361494, 'sub_port_id': 25361507, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107014, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'flou': {'main_port_id': 25361494, 'sub_port_id': 25361508, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107015, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'plastique': {'main_port_id': 25361494, 'sub_port_id': 25361509, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107016, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'papier': {'main_port_id': 25361494, 'sub_port_id': 25361510, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107017, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}, 'kraft': {'main_port_id': 25361494, 'sub_port_id': 25361511, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107018, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 58), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 56)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 25361500 , 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=25361494 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 (25361500) result : ((1373861760,), (1373861761,), (1373861762,), (1373861763,), (1373861764,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361501 , 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=25361494 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 (25361501) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361502 , 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=25361494 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 (25361502) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361503 , 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=25361494 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 (25361503) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361504 , 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=25361494 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 (25361504) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361505 , 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=25361494 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 (25361505) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361506 , 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=25361494 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 (25361506) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361507 , 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=25361494 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 (25361507) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361508 , 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=25361494 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 (25361508) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361509 , 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=25361494 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 (25361509) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361510 , 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=25361494 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 (25361510) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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 25361511 , 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=25361494 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 (25361511) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (25361494) result : ((1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) 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 (1373861700) 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`=25361494 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('plastique','mal_croppe','Teint_Dans_La_Masse','flou','environnement','metal','Carton_gris','papier','kraft','autre_refus','Carton_brun','cartonnette')) 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`=25361494 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('plastique','mal_croppe','Teint_Dans_La_Masse','flou','environnement','metal','Carton_gris','papier','kraft','autre_refus','Carton_brun','cartonnette')) AND mptpi.`min_score`=0.5 To do returned map {'cartonnette': {'main_port_id': 25361494, 'sub_port_id': 25361512, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107019, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'Carton_brun': {'main_port_id': 25361494, 'sub_port_id': 25361513, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107020, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'Teint_Dans_La_Masse': {'main_port_id': 25361494, 'sub_port_id': 25361514, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107021, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'metal': {'main_port_id': 25361494, 'sub_port_id': 25361515, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107022, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'mal_croppe': {'main_port_id': 25361494, 'sub_port_id': 25361516, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107023, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'Carton_gris': {'main_port_id': 25361494, 'sub_port_id': 25361517, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107024, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'autre_refus': {'main_port_id': 25361494, 'sub_port_id': 25361518, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107025, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'environnement': {'main_port_id': 25361494, 'sub_port_id': 25361519, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107026, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'flou': {'main_port_id': 25361494, 'sub_port_id': 25361520, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107027, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'plastique': {'main_port_id': 25361494, 'sub_port_id': 25361521, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107028, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'papier': {'main_port_id': 25361494, 'sub_port_id': 25361522, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107029, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 32, 57), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}, 'kraft': {'main_port_id': 25361494, 'sub_port_id': 25361523, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 17107030, 'last_updated_at': datetime.datetime(2025, 7, 26, 3, 34, 59), 'last_updated_at_desc': datetime.datetime(2025, 7, 26, 3, 34, 59), 'last_updated_at_asc': datetime.datetime(2025, 7, 26, 3, 32, 57)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361512,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361500 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361513,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361501 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361514,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361502 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361515,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361503 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361516,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361504 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361517,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361505 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361518,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361506 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361519,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361507 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361520,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361508 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361521,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361509 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361522,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361510 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 25361523,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 25361511 lien utilise dans velours : https://www.fotonower.com/velours/25361512,25361513,25361514,25361515,25361516,25361517,25361518,25361519,25361520,25361521,25361522,25361523?tags=cartonnette,Carton_brun,Teint_Dans_La_Masse,metal,mal_croppe,Carton_gris,autre_refus,environnement,flou,plastique,papier,kraft After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([25361494]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765] map_info['map_portfolio_photo'] : {25361494: [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765, 1373861749, 1373861747, 1373861746, 1373861745, 1373861744, 1373861743, 1373861727, 1373861724, 1373861722, 1373861721, 1373861719, 1373861716, 1373861700, 1373861685, 1373861681, 1373861678, 1373861676, 1373861674, 1373861673]} final : False mtd_id 4302 list_pids : [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765] Looping around the photos to save general results len do output : 1 /25361494. 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, '3362181') ('4302', '25361494', '1373861780', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861776', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861773', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861770', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861767', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861765', None, None, None, None, None, '3362181') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 7 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, '25361494', "{'cartonnette': 25361500, 'Carton_brun': 25361501, 'Teint_Dans_La_Masse': 25361502, 'metal': 25361503, 'mal_croppe': 25361504, 'Carton_gris': 25361505, 'autre_refus': 25361506, 'environnement': 25361507, 'flou': 25361508, 'plastique': 25361509, 'papier': 25361510, 'kraft': 25361511}", None, None, None, None, '3362181'), ('4302', '25361494', '1373861780', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861776', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861773', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861770', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861767', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861765', None, None, None, None, None, '3362181')] time used for this insertion : 0.016733884811401367 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.4130244255065918 time spend to save output : 0.01700448989868164 total time spend for step 1 : 0.43002891540527344 step2:final Sat Jul 26 03:36: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 ! 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 (25361494) 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 25361494 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1373861685,1373861700,1373861681,1373861678,1373861676,1373861674,1373861673,1373861727,1373861724,1373861722,1373861721,1373861719,1373861716,1373861749,1373861747,1373861746,1373861745,1373861744,1373861743,1373861780,1373861776,1373861773,1373861770,1373861767,1373861765); 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([25361494]) Inside saveOutput : final : False verbose : True original output for save of step final : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} new output for save of step final : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765] map_info['map_portfolio_photo'] : {25361494: [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765, 1373861749, 1373861747, 1373861746, 1373861745, 1373861744, 1373861743, 1373861727, 1373861724, 1373861722, 1373861721, 1373861719, 1373861716, 1373861700, 1373861685, 1373861681, 1373861678, 1373861676, 1373861674, 1373861673]} final : False mtd_id 4302 list_pids : [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765] Looping around the photos to save general results len do output : 6 /1373861780.Didn't retrieve data . /1373861776.Didn't retrieve data . /1373861773.Didn't retrieve data . /1373861770.Didn't retrieve data . /1373861767.Didn't retrieve data . /1373861765.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, '3362181') ('4302', '25361494', '1373861780', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861776', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861773', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861770', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861767', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861765', None, None, None, None, None, '3362181') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 18 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', '25361494', '1373861780', '0.1718169854322869', None, None, None, None, '3362181'), ('4302', '25361494', '1373861776', '0.1718169854322869', None, None, None, None, '3362181'), ('4302', '25361494', '1373861773', '0.1718169854322869', None, None, None, None, '3362181'), ('4302', '25361494', '1373861770', '0.1718169854322869', None, None, None, None, '3362181'), ('4302', '25361494', '1373861767', '0.1718169854322869', None, None, None, None, '3362181'), ('4302', '25361494', '1373861765', '0.1718169854322869', None, None, None, None, '3362181')] time used for this insertion : 0.013571739196777344 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.06170988082885742 time spend to save output : 0.013944625854492188 total time spend for step 2 : 0.07565450668334961 step3:velours_tree Sat Jul 26 03:36: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 complete output_args for input 0 : {25361494: [{'cartonnette': 25361500, 'Carton_brun': 25361501, 'Teint_Dans_La_Masse': 25361502, 'metal': 25361503, 'mal_croppe': 25361504, 'Carton_gris': 25361505, 'autre_refus': 25361506, 'environnement': 25361507, 'flou': 25361508, 'plastique': 25361509, 'papier': 25361510, 'kraft': 25361511}]} input_args_next_step : {25361494: ()} output_args : {25361494: [{'cartonnette': 25361500, 'Carton_brun': 25361501, 'Teint_Dans_La_Masse': 25361502, 'metal': 25361503, 'mal_croppe': 25361504, 'Carton_gris': 25361505, 'autre_refus': 25361506, 'environnement': 25361507, 'flou': 25361508, 'plastique': 25361509, 'papier': 25361510, 'kraft': 25361511}]} args : 25361494 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': 25361500, 'Carton_brun': 25361501, 'Teint_Dans_La_Masse': 25361502, 'metal': 25361503, 'mal_croppe': 25361504, 'Carton_gris': 25361505, 'autre_refus': 25361506, 'environnement': 25361507, 'flou': 25361508, 'plastique': 25361509, 'papier': 25361510, 'kraft': 25361511},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (25361494) 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([25361494]) 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.2760004997253418 time spend to save output : 5.1021575927734375e-05 total time spend for step 3 : 0.27605152130126953 step4:send_mail_cod Sat Jul 26 03:36: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 : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} input_args_next_step : {1373861780: ()} output_args : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} args : 1373861780 depend.output_id : 0 input_args_next_step : {1373861780: ('0.1718169854322869',), 1373861776: ()} output_args : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} args : 1373861776 depend.output_id : 0 input_args_next_step : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ()} output_args : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} args : 1373861773 depend.output_id : 0 input_args_next_step : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ()} output_args : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} args : 1373861770 depend.output_id : 0 input_args_next_step : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ()} output_args : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} args : 1373861767 depend.output_id : 0 input_args_next_step : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ()} output_args : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',)} args : 1373861765 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 : {25361494: [{'cartonnette': 25361500, 'Carton_brun': 25361501, 'Teint_Dans_La_Masse': 25361502, 'metal': 25361503, 'mal_croppe': 25361504, 'Carton_gris': 25361505, 'autre_refus': 25361506, 'environnement': 25361507, 'flou': 25361508, 'plastique': 25361509, 'papier': 25361510, 'kraft': 25361511}]} input_args_next_step : {1373861780: ('0.1718169854322869',), 1373861776: ('0.1718169854322869',), 1373861773: ('0.1718169854322869',), 1373861770: ('0.1718169854322869',), 1373861767: ('0.1718169854322869',), 1373861765: ('0.1718169854322869',), 25361494: ()} output_args : {25361494: [{'cartonnette': 25361500, 'Carton_brun': 25361501, 'Teint_Dans_La_Masse': 25361502, 'metal': 25361503, 'mal_croppe': 25361504, 'Carton_gris': 25361505, 'autre_refus': 25361506, 'environnement': 25361507, 'flou': 25361508, 'plastique': 25361509, 'papier': 25361510, 'kraft': 25361511}]} args : 25361494 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 :7, first value : ('0.1718169854322869',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (25361494) 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 (1373861780,1373861776,1373861773,1373861770,1373861767,1373861765) Found this number of photos: 6 ##### Call download_photos : nb_thread : 5 begin to download photo : 1373861765 begin to download photo : 1373861770 begin to download photo : 1373861776 download finish for photo 1373861770 begin to download photo : 1373861773 download finish for photo 1373861765 begin to download photo : 1373861767 download finish for photo 1373861776 begin to download photo : 1373861780 download finish for photo 1373861767 download finish for photo 1373861773 download finish for photo 1373861780 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 : 6 ; length of list_pids : 6 ; length of list_args : 6 results_Auto_P25361494_26-07-2025_03_36_59.pdf 25361500 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=25361500 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1373861760: '1753493665_170532_1373861700_16d67a6cecdb86f5d7d3594739199c2c_rle_crop_3894719200_0.png', 1373861761: '1753493665_170532_1373861685_0f5d2603664ed72f5e5bcad034be1e5a_rle_crop_3894719205_0.png', 1373861762: '1753493665_170532_1373861681_8597bac66fa35718f9bbe681f8cf46b7_rle_crop_3894719209_0.png', 1373861763: '1753493665_170532_1373861678_5d21c5432a4cd109cf9b323cc218f73c_rle_crop_3894719214_0.png', 1373861764: '1753493665_170532_1373861676_fcd5505d2de6cdd7f127f975476f78c8_rle_crop_3894719221_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/f97988b55be39833b1ab687a0833ec8b_14106785.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/f97988b55be39833b1ab687a0833ec8b_68648255.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/0c21a02b790d05ee5684a618e01df3bf_63343387.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/7478521f0a7bb27deaf99967d1b7c56b_95858223.png change filename to text .imagette253615001753493819/ imagette253615001753493819/1753493665_170532_1373861681_8597bac66fa35718f9bbe681f8cf46b7_rle_crop_3894719209_0.png.png imagette253615001753493819/1753493665_170532_1373861700_16d67a6cecdb86f5d7d3594739199c2c_rle_crop_3894719200_0.png.png imagette253615001753493819/1753493665_170532_1373861685_0f5d2603664ed72f5e5bcad034be1e5a_rle_crop_3894719205_0.png.png imagette253615001753493819/1753493665_170532_1373861678_5d21c5432a4cd109cf9b323cc218f73c_rle_crop_3894719214_0.png.png imagette253615001753493819/1753493665_170532_1373861676_fcd5505d2de6cdd7f127f975476f78c8_rle_crop_3894719221_0.png.png imagette253615031753493820/ imagette253615041753493820/ imagette253615061753493820/ imagette253615081753493820/ imagette253615091753493820/ imagette253615111753493820/ imagette253615011753493820/ imagette253615021753493820/ imagette253615051753493820/ wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/5146181efd21f796fb7e3b443b0a6eb2_52770890.png imagette253615001753493819 25361503 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=25361503 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615031753493820 25361504 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=25361504 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615041753493820 25361506 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=25361506 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615061753493820 25361508 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=25361508 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615081753493820 25361509 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=25361509 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615091753493820 25361511 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=25361511 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615111753493820 25361501 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=25361501 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615011753493820 25361502 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=25361502 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615021753493820 25361505 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=25361505 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette253615051753493820 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=25361494 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/25361512,25361513,25361514,25361515,25361516,25361517,25361518,25361519,25361520,25361521,25361522,25361523?tags=cartonnette,Carton_brun,Teint_Dans_La_Masse,metal,mal_croppe,Carton_gris,autre_refus,environnement,flou,plastique,papier,kraft your option no_mail is active, we will not send the real mail to your client args[1373861780] : ('0.1718169854322869',) no score found for photo 1373861780 We are sending mail with results at report@fotonower.com args[1373861776] : ('0.1718169854322869',) no score found for photo 1373861776 We are sending mail with results at report@fotonower.com args[1373861773] : ('0.1718169854322869',) no score found for photo 1373861773 We are sending mail with results at report@fotonower.com args[1373861770] : ('0.1718169854322869',) no score found for photo 1373861770 We are sending mail with results at report@fotonower.com args[1373861767] : ('0.1718169854322869',) no score found for photo 1373861767 We are sending mail with results at report@fotonower.com args[1373861765] : ('0.1718169854322869',) no score found for photo 1373861765 We are sending mail with results at report@fotonower.com refus_total : 0.1718169854322869 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=25361494 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_P25361494_26-07-2025_03_36_59.pdf results_Auto_P25361494_26-07-2025_03_36_59.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25361494_26-07-2025_03_36_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','25361494','results_Auto_P25361494_26-07-2025_03_36_59.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25361494_26-07-2025_03_36_59.pdf','pdf','','0.08','0.1718169854322869') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([25361494]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765] map_info['map_portfolio_photo'] : {25361494: [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765, 1373861749, 1373861747, 1373861746, 1373861745, 1373861744, 1373861743, 1373861727, 1373861724, 1373861722, 1373861721, 1373861719, 1373861716, 1373861700, 1373861685, 1373861681, 1373861678, 1373861676, 1373861674, 1373861673]} final : False mtd_id 4302 list_pids : [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765] 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, '3362181') ('4302', '25361494', '1373861780', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861776', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861773', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861770', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861767', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861765', None, None, None, None, None, '3362181') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 6 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', '25361494', '1373861780', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861776', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861773', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861770', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861767', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861765', None, None, None, None, None, '3362181')] time used for this insertion : 0.01543116569519043 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.635411024093628 time spend to save output : 0.01570415496826172 total time spend for step 4 : 1.6511151790618896 step5:split_time_score Sat Jul 26 03:37:01 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 : ['25361494'] 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 : [('25361494',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (25361494) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1373861765: {'path': 'temp/1753493819_2168434_1373861765_1124d9cab430fab393ee484c7ed86d9b.jpg', 'extension': 'jpg'}, 1373861767: {'path': 'temp/1753493819_2168434_1373861767_954dc148f96a083fee1524ec965dbdaa.jpg', 'extension': 'jpg'}, 1373861770: {'path': 'temp/1753493819_2168434_1373861770_c9374f03a7d64b9538c96ef729d66b47.jpg', 'extension': 'jpg'}, 1373861773: {'path': 'temp/1753493819_2168434_1373861773_a62e9cebd0e2b44584b4f74ea54f9462.jpg', 'extension': 'jpg'}, 1373861776: {'path': 'temp/1753493819_2168434_1373861776_f5f73b556054d0b811098522b6f674d9.jpg', 'extension': 'jpg'}, 1373861780: {'path': 'temp/1753493819_2168434_1373861780_89ecc50ce04731718637798eff08812c.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 = 25361494; (('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 = 25361494 group by h (('03', 25),) 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=25361494 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 (25361494) 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 (25361494) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 26072025 25361494 Nombre de photos uploadées : 25 / 23040 (0%) 26072025 25361494 Nombre de photos taguées (types de déchets): 0 / 25 (0%) 26072025 25361494 Nombre de photos taguées (volume) : 0 / 25 (0%) [{'photo_id': 1373861685, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/0f5d2603664ed72f5e5bcad034be1e5a.jpg', 'username': None, 'uploaded_at': 1753493465, 'text': 'image_26072025_03_30_03_10151.jpg 1e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1373861700, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/16d67a6cecdb86f5d7d3594739199c2c.jpg', 'username': None, 'uploaded_at': 1753493527, 'text': 'image_26072025_03_30_03_10151.jpg 2e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1373861681, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/8597bac66fa35718f9bbe681f8cf46b7.jpg', 'username': None, 'uploaded_at': 1753493465, 'text': 'image_26072025_03_30_14_10139.jpg 3.0000000000000004e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1373861678, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/7/26/5d21c5432a4cd109cf9b323cc218f73c.jpg', 'username': None, 'uploaded_at': 1753493465, 'text': 'image_26072025_03_30_24_10134.jpg 4e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}] 0 [] elapsed_time : load_data_split_time_score 2.6226043701171875e-06 elapsed_time : order_list_meta_photo_and_scores 6.198883056640625e-06 ????????????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.0021812915802001953 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 25361494, '2025-07-26' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (2010380,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.028772592544555664 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= 2010380 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25355301, 'dashboard_result_id': 13166745, '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_P25355301_26-07-2025_00_17_01.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 25355314, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25355315, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25355316, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25355317, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25355318, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25355319, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25355320, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25355321, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25355322, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25355323, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25355324, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25355325, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25355557, 'dashboard_result_id': 13166746, '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_P25355557_26-07-2025_01_02_57.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25355621, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25355622, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25355623, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25355624, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25355625, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25355626, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25355627, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25355628, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25355629, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25355630, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25355631, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25355632, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25356024, 'dashboard_result_id': 13166747, '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_P25356024_26-07-2025_00_47_30.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356030, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356031, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356032, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356033, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356034, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356035, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356036, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356037, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356038, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356039, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356040, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356041, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25356383, 'dashboard_result_id': 13166748, '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_P25356383_26-07-2025_01_00_32.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356413, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356414, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356415, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356416, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356417, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356418, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356419, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356420, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356421, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356422, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356423, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356424, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25356726, 'dashboard_result_id': 13166749, '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_P25356726_26-07-2025_01_16_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356829, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356830, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356832, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356833, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356834, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356835, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356836, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356837, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356838, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356839, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356840, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356841, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25357325, 'dashboard_result_id': 13166750, '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_P25357325_26-07-2025_01_30_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25357330, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25357331, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25357332, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25357333, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25357334, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25357335, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25357336, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25357337, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25357338, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25357339, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25357340, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25357341, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25357747, 'dashboard_result_id': 13166751, '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_P25357747_26-07-2025_01_46_59.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25357753, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25357754, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25357755, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25357756, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25357757, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25357758, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25357759, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25357760, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25357761, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25357762, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25357763, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25357764, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25358202, 'dashboard_result_id': 13166752, '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_P25358202_26-07-2025_02_00_58.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25358215, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25358216, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25358217, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25358218, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25358219, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25358220, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25358221, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25358222, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25358223, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25358224, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25358225, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25358226, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25358712, 'dashboard_result_id': 13166753, '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_P25358712_26-07-2025_02_16_58.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25358728, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25358729, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25358730, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25358731, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25358732, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25358733, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25358734, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25358735, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25358736, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25358737, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25358738, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25358739, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25359335, 'dashboard_result_id': 13166754, '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_P25359335_26-07-2025_02_30_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 25359354, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25359355, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25359356, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25359357, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25359358, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25359359, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25359360, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25359361, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25359362, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25359363, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25359364, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25359365, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25359733, 'dashboard_result_id': 13166755, '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_P25359733_26-07-2025_02_46_58.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25359737, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25359738, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25359739, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25359740, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25359741, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25359742, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25359743, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25359744, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25359745, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25359746, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25359747, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25359748, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25360112, 'dashboard_result_id': 13166756, '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_P25360112_26-07-2025_03_00_57.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25360161, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25360162, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25360163, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25360164, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25360165, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25360166, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25360167, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25360168, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25360169, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25360170, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25360171, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25360172, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25360473, 'dashboard_result_id': 13166757, '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_P25360473_26-07-2025_03_16_31.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25360474, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25360475, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25360476, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25360477, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25360478, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25360479, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25360480, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25360481, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25360482, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25360483, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25360484, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25360485, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25361118, 'dashboard_result_id': 13166758, '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_P25361118_26-07-2025_03_30_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25361119, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25361120, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25361121, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25361122, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25361123, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25361124, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25361125, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25361126, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25361127, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25361128, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25361129, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25361130, 'pht': 3726}}"}, {'dashboat_entry_day': 2010380, 'dashboard_run_id': 2018140, 'mtr_portfolio_id': 25361494, 'dashboard_result_id': 13166759, '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_P25361494_26-07-2025_03_32_58.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25361500, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25361501, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25361502, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25361503, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25361504, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25361505, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25361506, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25361507, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25361508, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25361509, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25361510, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25361511, '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 = 25355301 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': 3360864, 'mtr_portfolio_id': 25355301, 'created_at': datetime.datetime(2025, 7, 26, 0, 17), 'result': '0.04350535935102565', 'result_long': None, 'result_double': None}] Qualite : 0.04350535935102565 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25355301 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25355301_26-07-2025_00_17_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25355301 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_P25355301_26-07-2025_00_17_01.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 25355314, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25355315, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25355316, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25355317, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25355318, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25355319, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25355320, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25355321, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25355322, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25355323, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25355324, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25355325, 'pht': 3726}}" where mtr_portfolio_id = 25355301 and dashboard_run_id = 2018140 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`=25355301 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166745, 0.04350535935102565, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25355301_26-07-2025_00_17_01.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 25355314, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25355315, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25355316, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25355317, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25355318, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25355319, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25355320, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25355321, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25355322, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25355323, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25355324, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25355325, '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 = 25355557 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': 3360915, 'mtr_portfolio_id': 25355557, 'created_at': datetime.datetime(2025, 7, 26, 1, 2, 57), 'result': '0.07381431508147096', 'result_long': None, 'result_double': None}] Qualite : 0.07381431508147096 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25355557 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25355557_26-07-2025_01_02_57.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25355557 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_P25355557_26-07-2025_01_02_57.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25355621, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25355622, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25355623, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25355624, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25355625, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25355626, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25355627, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25355628, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25355629, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25355630, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25355631, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25355632, 'pht': 3726}}" where mtr_portfolio_id = 25355557 and dashboard_run_id = 2018140 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`=25355557 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166746, 0.07381431508147096, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25355557_26-07-2025_01_02_57.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25355621, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25355622, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25355623, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25355624, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25355625, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25355626, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25355627, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25355628, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25355629, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25355630, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25355631, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25355632, '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 = 25356024 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': 3361007, 'mtr_portfolio_id': 25356024, 'created_at': datetime.datetime(2025, 7, 26, 0, 47, 29), 'result': '0.10719126764138359', 'result_long': None, 'result_double': None}] Qualite : 0.10719126764138359 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25356024 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25356024_26-07-2025_00_47_30.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25356024 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_P25356024_26-07-2025_00_47_30.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356030, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356031, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356032, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356033, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356034, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356035, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356036, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356037, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356038, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356039, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356040, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356041, 'pht': 3726}}" where mtr_portfolio_id = 25356024 and dashboard_run_id = 2018140 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`=25356024 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166747, 0.10719126764138359, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25356024_26-07-2025_00_47_30.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356030, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356031, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356032, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356033, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356034, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356035, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356036, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356037, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356038, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356039, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356040, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356041, '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 = 25356383 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': 3361100, 'mtr_portfolio_id': 25356383, 'created_at': datetime.datetime(2025, 7, 26, 1, 0, 32), 'result': '0.05492209439366332', 'result_long': None, 'result_double': None}] Qualite : 0.05492209439366332 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25356383 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25356383_26-07-2025_01_00_32.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25356383 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_P25356383_26-07-2025_01_00_32.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356413, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356414, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356415, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356416, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356417, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356418, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356419, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356420, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356421, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356422, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356423, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356424, 'pht': 3726}}" where mtr_portfolio_id = 25356383 and dashboard_run_id = 2018140 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`=25356383 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166748, 0.05492209439366332, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25356383_26-07-2025_01_00_32.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356413, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356414, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356415, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356416, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356417, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356418, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356419, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356420, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356421, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356422, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356423, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356424, '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 = 25356726 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': 3361210, 'mtr_portfolio_id': 25356726, 'created_at': datetime.datetime(2025, 7, 26, 1, 16, 58), 'result': '0.02502067535634038', 'result_long': None, 'result_double': None}] Qualite : 0.02502067535634038 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25356726 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25356726_26-07-2025_01_16_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25356726 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_P25356726_26-07-2025_01_16_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356829, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356830, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356832, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356833, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356834, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356835, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356836, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356837, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356838, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356839, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356840, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356841, 'pht': 3726}}" where mtr_portfolio_id = 25356726 and dashboard_run_id = 2018140 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`=25356726 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166749, 0.02502067535634038, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25356726_26-07-2025_01_16_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25356829, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25356830, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25356832, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25356833, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25356834, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25356835, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25356836, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25356837, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25356838, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25356839, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25356840, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25356841, '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 = 25357325 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': 3361316, 'mtr_portfolio_id': 25357325, 'created_at': datetime.datetime(2025, 7, 26, 1, 30, 58), 'result': '0.02750181159715733', 'result_long': None, 'result_double': None}] Qualite : 0.02750181159715733 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25357325 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25357325_26-07-2025_01_30_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25357325 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_P25357325_26-07-2025_01_30_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25357330, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25357331, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25357332, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25357333, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25357334, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25357335, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25357336, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25357337, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25357338, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25357339, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25357340, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25357341, 'pht': 3726}}" where mtr_portfolio_id = 25357325 and dashboard_run_id = 2018140 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`=25357325 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166750, 0.02750181159715733, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25357325_26-07-2025_01_30_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25357330, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25357331, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25357332, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25357333, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25357334, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25357335, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25357336, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25357337, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25357338, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25357339, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25357340, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25357341, '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 = 25357747 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': 3361409, 'mtr_portfolio_id': 25357747, 'created_at': datetime.datetime(2025, 7, 26, 1, 46, 58), 'result': '0.03484047156154063', 'result_long': None, 'result_double': None}] Qualite : 0.03484047156154063 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25357747 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25357747_26-07-2025_01_46_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25357747 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_P25357747_26-07-2025_01_46_59.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25357753, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25357754, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25357755, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25357756, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25357757, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25357758, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25357759, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25357760, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25357761, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25357762, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25357763, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25357764, 'pht': 3726}}" where mtr_portfolio_id = 25357747 and dashboard_run_id = 2018140 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`=25357747 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166751, 0.03484047156154063, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25357747_26-07-2025_01_46_59.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25357753, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25357754, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25357755, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25357756, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25357757, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25357758, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25357759, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25357760, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25357761, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25357762, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25357763, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25357764, '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 = 25358202 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': 3361531, 'mtr_portfolio_id': 25358202, 'created_at': datetime.datetime(2025, 7, 26, 2, 0, 57), 'result': '0.021311767897973788', 'result_long': None, 'result_double': None}] Qualite : 0.021311767897973788 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25358202 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25358202_26-07-2025_02_00_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25358202 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_P25358202_26-07-2025_02_00_58.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25358215, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25358216, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25358217, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25358218, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25358219, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25358220, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25358221, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25358222, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25358223, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25358224, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25358225, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25358226, 'pht': 3726}}" where mtr_portfolio_id = 25358202 and dashboard_run_id = 2018140 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`=25358202 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166752, 0.021311767897973788, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25358202_26-07-2025_02_00_58.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25358215, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25358216, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25358217, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25358218, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25358219, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25358220, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25358221, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25358222, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25358223, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25358224, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25358225, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25358226, '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 = 25358712 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': 3361638, 'mtr_portfolio_id': 25358712, 'created_at': datetime.datetime(2025, 7, 26, 2, 16, 57), 'result': '0.04786645152349526', 'result_long': None, 'result_double': None}] Qualite : 0.04786645152349526 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25358712 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25358712_26-07-2025_02_16_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25358712 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_P25358712_26-07-2025_02_16_58.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25358728, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25358729, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25358730, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25358731, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25358732, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25358733, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25358734, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25358735, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25358736, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25358737, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25358738, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25358739, 'pht': 3726}}" where mtr_portfolio_id = 25358712 and dashboard_run_id = 2018140 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`=25358712 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166753, 0.04786645152349526, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25358712_26-07-2025_02_16_58.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25358728, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25358729, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25358730, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25358731, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25358732, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25358733, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25358734, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25358735, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25358736, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25358737, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25358738, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25358739, '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 = 25359335 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': 3361752, 'mtr_portfolio_id': 25359335, 'created_at': datetime.datetime(2025, 7, 26, 2, 30, 58), 'result': '0.0265633758083267', 'result_long': None, 'result_double': None}] Qualite : 0.0265633758083267 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25359335 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25359335_26-07-2025_02_30_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25359335 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_P25359335_26-07-2025_02_30_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 25359354, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25359355, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25359356, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25359357, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25359358, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25359359, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25359360, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25359361, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25359362, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25359363, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25359364, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25359365, 'pht': 3726}}" where mtr_portfolio_id = 25359335 and dashboard_run_id = 2018140 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`=25359335 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166754, 0.0265633758083267, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25359335_26-07-2025_02_30_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 25359354, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25359355, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25359356, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25359357, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25359358, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25359359, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25359360, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25359361, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25359362, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25359363, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25359364, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25359365, '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 = 25359733 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': 3361828, 'mtr_portfolio_id': 25359733, 'created_at': datetime.datetime(2025, 7, 26, 2, 46, 58), 'result': '0.037232871340269216', 'result_long': None, 'result_double': None}] Qualite : 0.037232871340269216 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25359733 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25359733_26-07-2025_02_46_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25359733 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_P25359733_26-07-2025_02_46_58.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25359737, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25359738, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25359739, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25359740, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25359741, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25359742, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25359743, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25359744, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25359745, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25359746, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25359747, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25359748, 'pht': 3726}}" where mtr_portfolio_id = 25359733 and dashboard_run_id = 2018140 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`=25359733 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166755, 0.037232871340269216, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25359733_26-07-2025_02_46_58.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25359737, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25359738, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25359739, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25359740, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25359741, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25359742, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25359743, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25359744, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25359745, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25359746, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25359747, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25359748, '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 = 25360112 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': 3361902, 'mtr_portfolio_id': 25360112, 'created_at': datetime.datetime(2025, 7, 26, 3, 0, 56), 'result': '0.04767642330542805', 'result_long': None, 'result_double': None}] Qualite : 0.04767642330542805 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25360112 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25360112_26-07-2025_03_00_57.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25360112 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_P25360112_26-07-2025_03_00_57.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25360161, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25360162, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25360163, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25360164, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25360165, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25360166, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25360167, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25360168, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25360169, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25360170, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25360171, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25360172, 'pht': 3726}}" where mtr_portfolio_id = 25360112 and dashboard_run_id = 2018139 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`=25360112 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166756, 0.04767642330542805, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25360112_26-07-2025_03_00_57.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25360161, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25360162, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25360163, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25360164, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25360165, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25360166, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25360167, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25360168, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25360169, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25360170, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25360171, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25360172, '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 = 25360473 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': 3362005, 'mtr_portfolio_id': 25360473, 'created_at': datetime.datetime(2025, 7, 26, 3, 16, 30), 'result': '0.0659289065652644', 'result_long': None, 'result_double': None}] Qualite : 0.0659289065652644 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25360473 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25360473_26-07-2025_03_16_31.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25360473 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_P25360473_26-07-2025_03_16_31.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25360474, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25360475, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25360476, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25360477, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25360478, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25360479, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25360480, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25360481, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25360482, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25360483, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25360484, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25360485, 'pht': 3726}}" where mtr_portfolio_id = 25360473 and dashboard_run_id = 2018139 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`=25360473 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166757, 0.0659289065652644, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25360473_26-07-2025_03_16_31.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25360474, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25360475, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25360476, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25360477, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25360478, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25360479, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25360480, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25360481, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25360482, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25360483, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25360484, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25360485, '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 = 25361118 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': 3362110, 'mtr_portfolio_id': 25361118, 'created_at': datetime.datetime(2025, 7, 26, 3, 30, 58), 'result': '0.018704900255951878', 'result_long': None, 'result_double': None}] Qualite : 0.018704900255951878 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25361118 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25361118_26-07-2025_03_30_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25361118 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_P25361118_26-07-2025_03_30_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25361119, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25361120, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25361121, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25361122, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25361123, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25361124, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25361125, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25361126, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25361127, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25361128, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25361129, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25361130, 'pht': 3726}}" where mtr_portfolio_id = 25361118 and dashboard_run_id = 2018139 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`=25361118 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166758, 0.018704900255951878, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25361118_26-07-2025_03_30_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 25361119, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25361120, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25361121, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25361122, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25361123, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25361124, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25361125, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25361126, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25361127, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25361128, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25361129, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25361130, '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 = 25361494 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': 3362181, 'mtr_portfolio_id': 25361494, 'created_at': datetime.datetime(2025, 7, 26, 3, 36, 59), 'result': '0.1718169854322869', 'result_long': None, 'result_double': None}] Qualite : 0.1718169854322869 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 25361494 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25361494_26-07-2025_03_36_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 25361494 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_P25361494_26-07-2025_03_36_59.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25361500, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25361501, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25361502, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25361503, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25361504, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25361505, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25361506, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25361507, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25361508, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25361509, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25361510, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25361511, 'pht': 3726}}" where mtr_portfolio_id = 25361494 and dashboard_run_id = 2018139 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`=25361494 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (13166759, 0.1718169854322869, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P25361494_26-07-2025_03_36_59.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 25361500, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 25361501, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 25361502, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 25361503, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 25361504, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 25361505, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 25361506, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 25361507, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 25361508, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 25361509, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 25361510, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 25361511, '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 (25355301,25355557,25356024,25356383,25356726,25357325,25357747,25358202,25358712,25359335,25359733,25360112,25360473,25361118,25361494) result : ((1373845745,), (1373845819,), (1373845822,), (1373845825,), (1373845827,), (1373845829,), (1373845831,), (1373845846,), (1373845847,), (1373845848,), (1373845849,), (1373845851,), (1373845854,), (1373846223,), (1373846311,), (1373846347,), (1373846349,), (1373846351,), (1373846355,), (1373846549,), (1373846554,), (1373846559,), (1373846563,), (1373846566,), (1373846569,), (1373846583,), (1373846590,), (1373846592,), (1373846594,), (1373846597,), (1373846599,), (1373846620,), (1373846621,), (1373846622,), (1373846623,), (1373846626,), (1373846628,), (1373846654,), (1373846657,), (1373846658,), (1373846661,), (1373846664,), (1373846666,), (1373846678,), (1373846701,), (1373846704,), (1373846706,), (1373846707,), (1373846711,), (1373846715,), (1373846725,), (1373846727,), (1373846729,), (1373846745,), (1373846754,), (1373846756,), (1373846778,), (1373846790,), (1373846792,), (1373846793,), (1373846794,), (1373846795,), (1373846798,), (1373846812,), (1373846813,), (1373846816,), (1373846819,), (1373846822,), (1373846826,), (1373846860,), (1373847030,), (1373847120,), (1373847206,), (1373847230,), (1373847256,), (1373847284,), (1373847494,), (1373847497,), (1373847498,), (1373847499,), (1373847509,), (1373847533,), (1373847566,), (1373847569,), (1373847570,), (1373847594,), (1373847621,), (1373847647,), (1373847755,), (1373847763,), (1373847767,), (1373847783,), (1373847790,), (1373847794,), (1373847895,), (1373847898,), (1373847901,), (1373847902,), (1373847904,), (1373847907,), (1373847916,), (1373847918,), (1373847920,), (1373847921,), (1373847924,), (1373847928,), (1373847951,), (1373848125,), (1373848153,), (1373848181,), (1373848206,), (1373848232,), (1373848260,), (1373848406,), (1373848411,), (1373848412,), (1373848413,), (1373848415,), (1373848417,), (1373848430,), (1373848431,), (1373848433,), (1373848435,), (1373848438,), (1373848440,), (1373848453,), (1373848471,), (1373848488,), (1373848497,), (1373848500,), (1373848502,), (1373848579,), (1373848724,), (1373848778,), (1373848780,), (1373848782,), (1373848784,), (1373848785,), (1373848789,), (1373848802,), (1373848805,), (1373848821,), (1373848832,), (1373848835,), (1373848839,), (1373852523,), (1373848849,), (1373848851,), (1373848853,), (1373848854,), (1373848856,), (1373848859,), (1373848879,), (1373848919,), (1373848921,), (1373848922,), (1373848923,), (1373848924,), (1373848926,), (1373848940,), (1373848941,), (1373848946,), (1373848964,), (1373848968,), (1373849000,), (1373849293,), (1373849318,), (1373849341,), (1373849362,), (1373849387,), (1373849419,), (1373849617,), (1373849620,), (1373849623,), (1373849644,), (1373849655,), (1373849658,), (1373849757,), (1373849784,), (1373849813,), (1373849837,), (1373849866,), (1373849893,), (1373850009,), (1373850012,), (1373850014,), (1373850016,), (1373850018,), (1373850020,), (1373850036,), (1373850037,), (1373850039,), (1373850041,), (1373850042,), (1373850045,), (1373850140,), (1373850164,), (1373850189,), (1373850234,), (1373850265,), (1373850294,), (1373850398,), (1373850429,), (1373850432,), (1373850454,), (1373850458,), (1373850460,), (1373850462,), (1373850474,), (1373850477,), (1373850499,), (1373850506,), (1373850508,), (1373850510,), (1373850524,), (1373850528,), (1373850551,), (1373850554,), (1373850558,), (1373850560,), (1373850574,), (1373850578,), (1373850581,), (1373850582,), (1373850583,), (1373850585,), (1373850599,), (1373850601,), (1373850620,), (1373850623,), (1373850626,), (1373850629,), (1373850652,), (1373850667,), (1373850668,), (1373850670,), (1373850672,), (1373850674,), (1373850676,), (1373850694,), (1373850711,), (1373850713,), (1373850716,), (1373850718,), (1373850720,), (1373850722,), (1373850735,), (1373850755,), (1373850762,), (1373850764,), (1373850766,), (1373850769,), (1373850772,), (1373850789,), (1373850791,), (1373850793,), (1373850795,), (1373850797,), (1373850799,), (1373850810,), (1373850813,), (1373850814,), (1373850817,), (1373850820,), (1373850822,), (1373850829,), (1373850831,), (1373850833,), (1373850835,), (1373850839,), (1373850842,), (1373850848,), (1373850851,), (1373850855,), (1373850858,), (1373850861,), (1373850865,), (1373850873,), (1373850875,), (1373850877,), (1373850880,), (1373850882,), (1373850887,), (1373850984,), (1373851039,), (1373851086,), (1373851132,), (1373851188,), (1373851236,), (1373852292,), (1373852512,), (1373852514,), (1373852516,), (1373852518,), (1373852520,), (1373852546,), (1373852573,), (1373852595,), (1373852597,), (1373852600,), (1373852603,), (1373852605,), (1373852608,), (1373852621,), (1373852622,), (1373852623,), (1373852625,), (1373852627,), (1373852629,), (1373852652,), (1373852655,), (1373852657,), (1373852660,), (1373852663,), (1373852666,), (1373852684,), (1373852686,), (1373852688,), (1373852689,), (1373852692,), (1373852696,), (1373852711,), (1373852717,), (1373852723,), (1373852730,), (1373852732,), (1373852735,), (1373852751,), (1373852759,), (1373852766,), (1373852768,), (1373852769,), (1373852771,), (1373852783,), (1373852789,), (1373852795,), (1373852796,), (1373852797,), (1373852799,), (1373852816,), (1373852859,), (1373852867,), (1373852876,), (1373852878,), (1373852881,), (1373852883,), (1373852894,), (1373852913,), (1373852935,), (1373852974,), (1373852976,), (1373852978,), (1373852992,), (1373853002,), (1373853005,), (1373853034,), (1373853035,), (1373853036,), (1373853037,), (1373853039,), (1373853042,), (1373853066,), (1373853076,), (1373853078,), (1373853080,), (1373853081,), (1373853085,), (1373853107,), (1373853117,), (1373853120,), (1373853122,), (1373853126,), (1373853128,), (1373853141,), (1373853143,), (1373853145,), (1373853147,), (1373853149,), (1373853151,), (1373853163,), (1373853198,), (1373853204,), (1373853212,), (1373853219,), (1373853222,), (1373853225,), (1373853246,), (1373853271,), (1373853273,), (1373853275,), (1373853285,), (1373853294,), (1373853297,), (1373853311,), (1373853315,), (1373853316,), (1373853319,), (1373853323,), (1373853326,), (1373853334,), (1373853335,), (1373853336,), (1373853337,), (1373853338,), (1373853340,), (1373853364,), (1373853365,), (1373853366,), (1373853368,), (1373853370,), (1373853373,), (1373853383,), (1373853388,), (1373853395,), (1373853403,), (1373853405,), (1373853408,), (1373853416,), (1373853418,), (1373853421,), (1373853424,), (1373853425,), (1373853429,), (1373853445,), (1373853454,), (1373853463,), (1373853464,), (1373853466,), (1373853468,), (1373853488,), (1373853491,), (1373853494,), (1373853495,), (1373853497,), (1373853500,), (1373853525,), (1373853555,), (1373853563,), (1373853565,), (1373853567,), (1373853569,), (1373853572,), (1373853590,), (1373853594,), (1373853604,), (1373853612,), (1373853613,), (1373853617,), (1373853628,), (1373853638,), (1373853647,), (1373853649,), (1373853650,), (1373853653,), (1373853666,), (1373853677,), (1373853682,), (1373853684,), (1373853686,), (1373853690,), (1373853718,), (1373853719,), (1373853720,), (1373853721,), (1373853723,), (1373853726,), (1373853748,), (1373853751,), (1373853753,), (1373853754,), (1373853756,), (1373853758,), (1373853769,), (1373853771,), (1373853772,), (1373853773,), (1373853776,), (1373853780,), (1373853798,), (1373853800,), (1373853802,), (1373853807,), (1373853809,), (1373853812,), (1373853831,), (1373853878,), (1373853879,), (1373853882,), (1373853885,), (1373853887,), (1373853891,), (1373853901,), (1373853902,), (1373853903,), (1373853904,), (1373853905,), (1373853907,), (1373853934,), (1373853936,), (1373853938,), (1373853940,), (1373853941,), (1373853944,), (1373853972,), (1373853974,), (1373853976,), (1373853978,), (1373853979,), (1373853981,), (1373853997,), (1373853999,), (1373854001,), (1373854002,), (1373854004,), (1373854010,), (1373854033,), (1373854035,), (1373854037,), (1373854039,), (1373854041,), (1373854043,), (1373854057,), (1373854059,), (1373854061,), (1373854063,), (1373854065,), (1373854068,), (1373854080,), (1373854082,), (1373854084,), (1373854085,), (1373854087,), (1373854090,), (1373854106,), (1373854108,), (1373854109,), (1373854110,), (1373854112,), (1373854114,), (1373854138,), (1373854150,), (1373854157,), (1373854165,), (1373854166,), (1373854168,), (1373854171,), (1373854276,), (1373854300,), (1373854328,), (1373854350,), (1373854374,), (1373854398,), (1373854649,), (1373854673,), (1373854696,), (1373854726,), (1373854749,), (1373854774,), (1373854846,), (1373854847,), (1373854848,), (1373854863,), (1373854884,), (1373854908,), (1373855094,), (1373855103,), (1373855115,), (1373855120,), (1373855123,), (1373855126,), (1373855144,), (1373855167,), (1373855171,), (1373855173,), (1373855176,), (1373855178,), (1373855181,), (1373855413,), (1373855425,), (1373855428,), (1373855429,), (1373855432,), (1373855436,), (1373855456,), (1373855458,), (1373855464,), (1373855470,), (1373855472,), (1373855474,), (1373855494,), (1373855518,), (1373855545,), (1373855568,), (1373855574,), (1373855576,), (1373855578,), (1373855588,), (1373855618,), (1373855795,), (1373855821,), (1373855827,), (1373855851,), (1373855866,), (1373855872,), (1373855884,), (1373855887,), (1373855890,), (1373855893,), (1373855894,), (1373855898,), (1373855925,), (1373855934,), (1373855936,), (1373855938,), (1373855940,), (1373855944,), (1373855968,), (1373855988,), (1373855995,), (1373855997,), (1373856000,), (1373856003,), (1373856006,), (1373856021,), (1373856043,), (1373856044,), (1373856046,), (1373856048,), (1373856051,), (1373856053,), (1373856065,), (1373856092,), (1373856115,), (1373856136,), (1373856161,), (1373856186,), (1373856446,), (1373856480,), (1373856503,), (1373856529,), (1373856554,), (1373856584,), (1373856704,), (1373856726,), (1373856748,), (1373856765,), (1373856768,), (1373856784,), (1373856856,), (1373856858,), (1373856867,), (1373856868,), (1373856874,), (1373856876,), (1373856887,), (1373856888,), (1373856890,), (1373856893,), (1373856896,), (1373856899,), (1373856912,), (1373856918,), (1373856920,), (1373856922,), (1373856926,), (1373856930,), (1373856943,), (1373856947,), (1373856949,), (1373856951,), (1373856954,), (1373856957,), (1373856977,), (1373856981,), (1373856984,), (1373856985,), (1373856987,), (1373856989,), (1373857000,), (1373857001,), (1373857003,), (1373857005,), (1373857008,), (1373857011,), (1373857029,), (1373857048,), (1373857050,), (1373857052,), (1373857054,), (1373857057,), (1373857059,), (1373857075,), (1373857076,), (1373857078,), (1373857080,), (1373857082,), (1373857086,), (1373857099,), (1373857123,), (1373857126,), (1373857127,), (1373857128,), (1373857130,), (1373857132,), (1373857149,), (1373857150,), (1373857151,), (1373857152,), (1373857153,), (1373857155,), (1373857166,), (1373857167,), (1373857169,), (1373857171,), (1373857174,), (1373857178,), (1373857192,), (1373857194,), (1373857197,), (1373857201,), (1373857204,), (1373857209,), (1373857228,), (1373857231,), (1373857234,), (1373857237,), (1373857241,), (1373857244,), (1373857266,), (1373857271,), (1373857272,), (1373857274,), (1373857276,), (1373857280,), (1373857298,), (1373857315,), (1373857317,), (1373857319,), (1373857321,), (1373857325,), (1373857327,), (1373857338,), (1373857340,), (1373857342,), (1373857344,), (1373857347,), (1373857351,), (1373857364,), (1373857374,), (1373857377,), (1373857379,), (1373857382,), (1373857384,), (1373857401,), (1373857410,), (1373857412,), (1373857414,), (1373857415,), (1373857419,), (1373857448,), (1373857450,), (1373857451,), (1373857453,), (1373857454,), (1373857456,), (1373857478,), (1373857488,), (1373857492,), (1373857494,), (1373857496,), (1373857498,), (1373857515,), (1373857518,), (1373857520,), (1373857521,), (1373857524,), (1373857527,), (1373857534,), (1373857535,), (1373857537,), (1373857539,), (1373857541,), (1373857546,), (1373857585,), (1373857636,), (1373857643,), (1373857645,), (1373857647,), (1373857649,), (1373857652,), (1373857662,), (1373857663,), (1373857664,), (1373857665,), (1373857666,), (1373857669,), (1373857686,), (1373857693,), (1373857695,), (1373857697,), (1373857698,), (1373857701,), (1373857722,), (1373857724,), (1373857725,), (1373857727,), (1373857728,), (1373857730,), (1373857741,), (1373857746,), (1373857749,), (1373857751,), (1373857752,), (1373857755,), (1373857796,), (1373857798,), (1373857800,), (1373857801,), (1373857804,), (1373857807,), (1373857818,), (1373857821,), (1373857824,), (1373857827,), (1373857830,), (1373857834,), (1373857846,), (1373857849,), (1373857850,), (1373857852,), (1373857855,), (1373857858,), (1373857878,), (1373857880,), (1373857884,), (1373857886,), (1373857889,), (1373857892,), (1373857936,), (1373857937,), (1373857938,), (1373857939,), (1373857941,), (1373857944,), (1373857993,), (1373858025,), (1373858034,), (1373858036,), (1373858038,), (1373858039,), (1373858042,), (1373858065,), (1373858068,), (1373858070,), (1373858072,), (1373858074,), (1373858076,), (1373858093,), (1373858094,), (1373858095,), (1373858096,), (1373858097,), (1373858101,), (1373858117,), (1373858118,), (1373858119,), (1373858120,), (1373858122,), (1373858126,), (1373858139,), (1373858140,), (1373858141,), (1373858142,), (1373858156,), (1373858184,), (1373858429,), (1373858456,), (1373858484,), (1373858510,), (1373858534,), (1373858559,), (1373859190,), (1373859427,), (1373859441,), (1373859456,), (1373859460,), (1373859463,), (1373859656,), (1373859995,), (1373860026,), (1373860055,), (1373860079,), (1373860104,), (1373860138,), (1373860263,), (1373860286,), (1373860310,), (1373860336,), (1373860357,), (1373860418,), (1373860559,), (1373860570,), (1373860579,), (1373860581,), (1373860583,), (1373860586,), (1373860608,), (1373860609,), (1373860611,), (1373860613,), (1373860615,), (1373860618,), (1373860632,), (1373860634,), (1373860642,), (1373860645,), (1373860647,), (1373860651,), (1373860668,), (1373860670,), (1373860673,), (1373860676,), (1373860678,), (1373860680,), (1373860692,), (1373860695,), (1373860697,), (1373860699,), (1373860702,), (1373860705,), (1373860723,), (1373860725,), (1373860728,), (1373860731,), (1373860734,), (1373860736,), (1373860822,), (1373860823,), (1373860834,), (1373860836,), (1373860849,), (1373860854,), (1373860951,), (1373860998,), (1373861002,), (1373861004,), (1373861006,), (1373861008,), (1373861012,), (1373861084,), (1373861090,), (1373861091,), (1373861092,), (1373861093,), (1373861095,), (1373861119,), (1373861143,), (1373861145,), (1373861147,), (1373861149,), (1373861152,), (1373861155,), (1373861176,), (1373861179,), (1373861181,), (1373861183,), (1373861185,), (1373861187,), (1373861200,), (1373861209,), (1373861212,), (1373861214,), (1373861215,), (1373861218,), (1373861233,), (1373861240,), (1373861248,), (1373861254,), (1373861256,), (1373861261,), (1373861270,), (1373861277,), (1373861288,), (1373861289,), (1373861290,), (1373861292,), (1373861339,), (1373861356,), (1373861363,), (1373861366,), (1373861367,), (1373861370,), (1373861372,), (1373861382,), (1373861383,), (1373861396,), (1373861404,), (1373861411,), (1373861414,), (1373861418,), (1373861436,), (1373861444,), (1373861446,), (1373861447,), (1373861450,), (1373861453,), (1373861463,), (1373861466,), (1373861469,), (1373861471,), (1373861473,), (1373861477,), (1373861486,), (1373861492,), (1373861500,), (1373861502,), (1373861504,), (1373861507,), (1373861527,), (1373861547,), (1373861549,), (1373861550,), (1373861551,), (1373861553,), (1373861555,), (1373861570,), (1373861571,), (1373861573,), (1373861575,), (1373861578,), (1373861580,), (1373861596,), (1373861598,), (1373861600,), (1373861602,), (1373861604,), (1373861607,), (1373861673,), (1373861674,), (1373861676,), (1373861678,), (1373861681,), (1373861685,), (1373861700,), (1373861716,), (1373861719,), (1373861721,), (1373861722,), (1373861724,), (1373861727,), (1373861743,), (1373861744,), (1373861745,), (1373861746,), (1373861747,), (1373861749,), (1373861765,), (1373861767,), (1373861770,), (1373861773,), (1373861776,), (1373861780,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'26072025': {'nb_upload': 25, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([25361494]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765] map_info['map_portfolio_photo'] : {25361494: [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765, 1373861749, 1373861747, 1373861746, 1373861745, 1373861744, 1373861743, 1373861727, 1373861724, 1373861722, 1373861721, 1373861719, 1373861716, 1373861700, 1373861685, 1373861681, 1373861678, 1373861676, 1373861674, 1373861673]} final : True mtd_id 4302 list_pids : [1373861780, 1373861776, 1373861773, 1373861770, 1373861767, 1373861765] Looping around the photos to save general results len do output : 1 /25361494Didn'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, '3362181') ('4302', '25361494', '1373861780', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861776', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861773', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861770', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861767', None, None, None, None, None, '3362181') ('4302', None, None, None, None, None, None, None, '3362181') ('4302', '25361494', '1373861765', None, None, None, None, None, '3362181') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 7 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, '25361494', 'None', None, None, None, None, '3362181'), ('4302', '25361494', '1373861780', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861776', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861773', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861770', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861767', None, None, None, None, None, '3362181'), ('4302', '25361494', '1373861765', None, None, None, None, None, '3362181')] time used for this insertion : 0.016727209091186523 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.9222025871276855 time spend to save output : 0.016966581344604492 total time spend for step 5 : 0.93916916847229 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 (3362181) 1.93user 2.89system 0:07.33elapsed 65%CPU (0avgtext+0avgdata 159756maxresident)k 104inputs+4696outputs (1major+63982minor)pagefaults 0swaps