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 : 1245475 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 (2967645) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (2967645) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384275 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['2967645'] with mtr_portfolio_ids : ['23384275'] and first list_photo_ids : [] new path : /proc/1245475/ Name: python3 Umask: 0002 State: R (running) Tgid: 1245475 Ngid: 0 Pid: 1245475 PPid: 1245474 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 1245475 NSpid: 1245475 NSpgid: 1244353 NSsid: 1244353 VmPeak: 1107324 kB VmSize: 1107324 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 97668 kB VmRSS: 97668 kB RssAnon: 60220 kB RssFile: 37448 kB RssShmem: 0 kB VmData: 866072 kB VmStk: 132 kB VmExe: 2644 kB VmLib: 130468 kB VmPTE: 560 kB VmSwap: 0 kB HugetlbPages: 0 kB CoreDumping: 0 THP_enabled: 1 Threads: 1 SigQ: 0/63054 SigPnd: 0000000000000000 ShdPnd: 0000000000000000 SigBlk: 0000000000000000 SigIgn: 0000000001001000 SigCgt: 0000000180000002 CapInh: 0000000000000000 CapPrm: 0000000000000000 CapEff: 0000000000000000 CapBnd: 000001ffffffffff CapAmb: 0000000000000000 NoNewPrivs: 0 Seccomp: 0 Seccomp_filters: 0 Speculation_Store_Bypass: thread vulnerable SpeculationIndirectBranch: conditional enabled Cpus_allowed: ffffffff,ffffffff,ffffffff,ffffffff Cpus_allowed_list: 0-127 Mems_allowed: 00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001 Mems_allowed_list: 0 voluntary_ctxt_switches: 48 nonvoluntary_ctxt_switches: 142 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '1245475', 'Ngid': '0', 'Pid': '1245475', 'PPid': '1245474', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '1245475', 'NSpid': '1245475', 'NSpgid': '1244353', 'NSsid': '1244353', 'VmPeak': '1107324 kB', 'VmSize': '1107324 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '97668 kB', 'VmRSS': '97668 kB', 'RssAnon': '60220 kB', 'RssFile': '37448 kB', 'RssShmem': '0 kB', 'VmData': '866072 kB', 'VmStk': '132 kB', 'VmExe': '2644 kB', 'VmLib': '130468 kB', 'VmPTE': '560 kB', 'VmSwap': '0 kB', 'HugetlbPages': '0 kB', 'CoreDumping': '0', 'THP_enabled': '1', 'Threads': '1', 'SigQ': '0/63054', 'SigPnd': '0000000000000000', 'ShdPnd': '0000000000000000', 'SigBlk': '0000000000000000', 'SigIgn': '0000000001001000', 'SigCgt': '0000000180000002', 'CapInh': '0000000000000000', 'CapPrm': '0000000000000000', 'CapEff': '0000000000000000', 'CapBnd': '000001ffffffffff', 'CapAmb': '0000000000000000', 'NoNewPrivs': '0', 'Seccomp': '0', 'Seccomp_filters': '0', 'Speculation_Store_Bypass': 'thread vulnerable', 'SpeculationIndirectBranch': 'conditional enabled', 'Cpus_allowed': 'ffffffff,ffffffff,ffffffff,ffffffff', 'Cpus_allowed_list': '0-127', 'Mems_allowed': '00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001', 'Mems_allowed_list': '0', 'voluntary_ctxt_switches': '48', 'nonvoluntary_ctxt_switches': '142'} ('datou_batch_current', '1245475', '1107324', '0', '1107324', '866072', '97668', b'', 'marlene', '2967645') 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 (23384275) 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 (2967645 ) ) 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 (23384275) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1361348775, 'portfolio_id': 23384275}, {'photo_id': 1361348771, 'portfolio_id': 23384275}, {'photo_id': 1361348768, 'portfolio_id': 23384275}, {'photo_id': 1361348764, 'portfolio_id': 23384275}, {'photo_id': 1361348737, 'portfolio_id': 23384275}, {'photo_id': 1361348709, 'portfolio_id': 23384275}, {'photo_id': 1361348577, 'portfolio_id': 23384275}, {'photo_id': 1361348553, 'portfolio_id': 23384275}, {'photo_id': 1361348550, 'portfolio_id': 23384275}, {'photo_id': 1361348547, 'portfolio_id': 23384275}, {'photo_id': 1361348412, 'portfolio_id': 23384275}, {'photo_id': 1361348378, 'portfolio_id': 23384275}, {'photo_id': 1361348356, 'portfolio_id': 23384275}, {'photo_id': 1361348042, 'portfolio_id': 23384275}, {'photo_id': 1361348010, 'portfolio_id': 23384275}, {'photo_id': 1361347809, 'portfolio_id': 23384275}] map_portfolio_id_photo_id: {23384275: [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547, 1361348412, 1361348378, 1361348356, 1361348042, 1361348010, 1361347809]} ##### 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.015050411224365234 #### 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 Tue May 27 17:18:28 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 (23384275) 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 : 23384275 get user id for portfolio 23384275 get sub ptf for main ptf 23384275, type 3726 and hashtags ['environnement', 'mal_croppe', 'Carton_brun', 'kraft', 'flou', 'metal', 'Carton_gris', 'cartonnette', 'plastique', 'papier', 'Teint_Dans_La_Masse', 'autre_refus'] 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`=23384275 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('environnement','mal_croppe','Carton_brun','kraft','flou','metal','Carton_gris','cartonnette','plastique','papier','Teint_Dans_La_Masse','autre_refus')) 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`=23384275 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('environnement','mal_croppe','Carton_brun','kraft','flou','metal','Carton_gris','cartonnette','plastique','papier','Teint_Dans_La_Masse','autre_refus')) AND mptpi.`min_score`=0.5 To do returned map {'autre_refus': {'main_port_id': 23384275, 'sub_port_id': 23384301, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600135, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'Carton_brun': {'main_port_id': 23384275, 'sub_port_id': 23384302, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600136, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'flou': {'main_port_id': 23384275, 'sub_port_id': 23384303, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600137, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'plastique': {'main_port_id': 23384275, 'sub_port_id': 23384304, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600138, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'metal': {'main_port_id': 23384275, 'sub_port_id': 23384305, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600139, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'Teint_Dans_La_Masse': {'main_port_id': 23384275, 'sub_port_id': 23384306, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600140, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'cartonnette': {'main_port_id': 23384275, 'sub_port_id': 23384307, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600141, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'environnement': {'main_port_id': 23384275, 'sub_port_id': 23384308, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600142, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'papier': {'main_port_id': 23384275, 'sub_port_id': 23384309, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600143, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'kraft': {'main_port_id': 23384275, 'sub_port_id': 23384310, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600144, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'mal_croppe': {'main_port_id': 23384275, 'sub_port_id': 23384311, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600145, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}, 'Carton_gris': {'main_port_id': 23384275, 'sub_port_id': 23384312, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600146, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 16, 59)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384301 , 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=23384275 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 (23384301) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384302 , 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=23384275 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 (23384302) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384303 , 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=23384275 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 (23384303) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384304 , 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=23384275 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 (23384304) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384305 , 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=23384275 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 (23384305) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384306 , 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=23384275 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 (23384306) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384307 , 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=23384275 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 (23384307) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384308 , 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=23384275 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 (23384308) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384309 , 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=23384275 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 (23384309) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384310 , 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=23384275 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 (23384310) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384311 , 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=23384275 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 (23384311) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 23384312 , 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=23384275 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 (23384312) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23384275) result : ((1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) 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 () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") 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`=23384275 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('environnement','mal_croppe','Carton_brun','kraft','flou','metal','Carton_gris','cartonnette','plastique','papier','Teint_Dans_La_Masse','autre_refus')) 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`=23384275 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('environnement','mal_croppe','Carton_brun','kraft','flou','metal','Carton_gris','cartonnette','plastique','papier','Teint_Dans_La_Masse','autre_refus')) AND mptpi.`min_score`=0.5 To do returned map {'autre_refus': {'main_port_id': 23384275, 'sub_port_id': 23384313, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600147, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'Carton_brun': {'main_port_id': 23384275, 'sub_port_id': 23384314, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600148, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'flou': {'main_port_id': 23384275, 'sub_port_id': 23384315, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600149, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'plastique': {'main_port_id': 23384275, 'sub_port_id': 23384316, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600150, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'metal': {'main_port_id': 23384275, 'sub_port_id': 23384317, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600151, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'Teint_Dans_La_Masse': {'main_port_id': 23384275, 'sub_port_id': 23384318, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600152, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'cartonnette': {'main_port_id': 23384275, 'sub_port_id': 23384319, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600153, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'environnement': {'main_port_id': 23384275, 'sub_port_id': 23384320, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600154, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'papier': {'main_port_id': 23384275, 'sub_port_id': 23384321, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600155, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'kraft': {'main_port_id': 23384275, 'sub_port_id': 23384322, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600156, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'mal_croppe': {'main_port_id': 23384275, 'sub_port_id': 23384323, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600157, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}, 'Carton_gris': {'main_port_id': 23384275, 'sub_port_id': 23384324, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15600158, 'last_updated_at': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_desc': datetime.datetime(2025, 5, 27, 17, 17, 1), 'last_updated_at_asc': datetime.datetime(2025, 5, 27, 17, 17, 1)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384313,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384301 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384314,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384302 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384315,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384303 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384316,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384304 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384317,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384305 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384318,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384306 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384319,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384307 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384320,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384308 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384321,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384309 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384322,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384310 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384323,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384311 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 23384324,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 23384312 lien utilise dans velours : https://www.fotonower.com/velours/23384313,23384314,23384315,23384316,23384317,23384318,23384319,23384320,23384321,23384322,23384323,23384324?tags=autre_refus,Carton_brun,flou,plastique,metal,Teint_Dans_La_Masse,cartonnette,environnement,papier,kraft,mal_croppe,Carton_gris After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([23384275]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547] map_info['map_portfolio_photo'] : {23384275: [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547, 1361348412, 1361348378, 1361348356, 1361348042, 1361348010, 1361347809]} final : False mtd_id 4302 list_pids : [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547] Looping around the photos to save general results len do output : 1 /23384275. 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, '2967645') ('4302', '23384275', '1361348775', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348771', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348768', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348764', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348737', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348709', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348577', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348553', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348550', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348547', None, None, None, None, None, '2967645') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 11 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', None, '23384275', "{'autre_refus': 23384301, 'Carton_brun': 23384302, 'flou': 23384303, 'plastique': 23384304, 'metal': 23384305, 'Teint_Dans_La_Masse': 23384306, 'cartonnette': 23384307, 'environnement': 23384308, 'papier': 23384309, 'kraft': 23384310, 'mal_croppe': 23384311, 'Carton_gris': 23384312}", None, None, None, None, '2967645'), ('4302', '23384275', '1361348775', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348771', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348768', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348764', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348737', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348709', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348577', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348553', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348550', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348547', None, None, None, None, None, '2967645')] time used for this insertion : 0.01992630958557129 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.444648027420044 time spend to save output : 0.02036285400390625 total time spend for step 1 : 1.4650108814239502 step2:final Tue May 27 17:18:30 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 (23384275) 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 23384275 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1361347809,1361348042,1361348010,1361348412,1361348378,1361348356,1361348577,1361348553,1361348550,1361348547,1361348775,1361348771,1361348768,1361348764,1361348737,1361348709); After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([23384275]) Inside saveOutput : final : False verbose : True original output for save of step final : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} new output for save of step final : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547] map_info['map_portfolio_photo'] : {23384275: [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547, 1361348412, 1361348378, 1361348356, 1361348042, 1361348010, 1361347809]} final : False mtd_id 4302 list_pids : [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547] Looping around the photos to save general results len do output : 10 /1361348775.Didn't retrieve data . /1361348771.Didn't retrieve data . /1361348768.Didn't retrieve data . /1361348764.Didn't retrieve data . /1361348737.Didn't retrieve data . /1361348709.Didn't retrieve data . /1361348577.Didn't retrieve data . /1361348553.Didn't retrieve data . /1361348550.Didn't retrieve data . /1361348547.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, '2967645') ('4302', '23384275', '1361348775', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348771', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348768', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348764', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348737', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348709', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348577', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348553', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348550', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348547', None, None, None, None, None, '2967645') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 30 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', '23384275', '1361348775', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348771', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348768', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348764', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348737', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348709', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348577', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348553', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348550', '0.0', None, None, None, None, '2967645'), ('4302', '23384275', '1361348547', '0.0', None, None, None, None, '2967645')] time used for this insertion : 0.016628503799438477 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.056851863861083984 time spend to save output : 0.0173490047454834 total time spend for step 2 : 0.07420086860656738 step3:velours_tree Tue May 27 17:18:30 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 : {23384275: [{'autre_refus': 23384301, 'Carton_brun': 23384302, 'flou': 23384303, 'plastique': 23384304, 'metal': 23384305, 'Teint_Dans_La_Masse': 23384306, 'cartonnette': 23384307, 'environnement': 23384308, 'papier': 23384309, 'kraft': 23384310, 'mal_croppe': 23384311, 'Carton_gris': 23384312}]} input_args_next_step : {23384275: ()} output_args : {23384275: [{'autre_refus': 23384301, 'Carton_brun': 23384302, 'flou': 23384303, 'plastique': 23384304, 'metal': 23384305, 'Teint_Dans_La_Masse': 23384306, 'cartonnette': 23384307, 'environnement': 23384308, 'papier': 23384309, 'kraft': 23384310, 'mal_croppe': 23384311, 'Carton_gris': 23384312}]} args : 23384275 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 : ({'autre_refus': 23384301, 'Carton_brun': 23384302, 'flou': 23384303, 'plastique': 23384304, 'metal': 23384305, 'Teint_Dans_La_Masse': 23384306, 'cartonnette': 23384307, 'environnement': 23384308, 'papier': 23384309, 'kraft': 23384310, 'mal_croppe': 23384311, 'Carton_gris': 23384312},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (23384275) 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([23384275]) 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.33721351623535156 time spend to save output : 6.937980651855469e-05 total time spend for step 3 : 0.3372828960418701 step4:send_mail_cod Tue May 27 17:18:30 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 : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} input_args_next_step : {1361348775: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348775 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348771 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348768 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348764 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348737 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348709 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348577 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348553 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348550 depend.output_id : 0 input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ()} output_args : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',)} args : 1361348547 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 : {23384275: [{'autre_refus': 23384301, 'Carton_brun': 23384302, 'flou': 23384303, 'plastique': 23384304, 'metal': 23384305, 'Teint_Dans_La_Masse': 23384306, 'cartonnette': 23384307, 'environnement': 23384308, 'papier': 23384309, 'kraft': 23384310, 'mal_croppe': 23384311, 'Carton_gris': 23384312}]} input_args_next_step : {1361348775: ('0.0',), 1361348771: ('0.0',), 1361348768: ('0.0',), 1361348764: ('0.0',), 1361348737: ('0.0',), 1361348709: ('0.0',), 1361348577: ('0.0',), 1361348553: ('0.0',), 1361348550: ('0.0',), 1361348547: ('0.0',), 23384275: ()} output_args : {23384275: [{'autre_refus': 23384301, 'Carton_brun': 23384302, 'flou': 23384303, 'plastique': 23384304, 'metal': 23384305, 'Teint_Dans_La_Masse': 23384306, 'cartonnette': 23384307, 'environnement': 23384308, 'papier': 23384309, 'kraft': 23384310, 'mal_croppe': 23384311, 'Carton_gris': 23384312}]} args : 23384275 depend.output_id : 0 We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :11, first value : ('0.0',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (23384275) 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 (1361348775,1361348771,1361348768,1361348764,1361348737,1361348709,1361348577,1361348553,1361348550,1361348547) Found this number of photos: 10 ##### Call download_photos : nb_thread : 5 begin to download photo : 1361348547 begin to download photo : 1361348577 begin to download photo : 1361348764 begin to download photo : 1361348775 download finish for photo 1361348577 begin to download photo : 1361348709 download finish for photo 1361348775 download finish for photo 1361348547 begin to download photo : 1361348550 download finish for photo 1361348764 begin to download photo : 1361348768 download finish for photo 1361348709 begin to download photo : 1361348737 download finish for photo 1361348550 begin to download photo : 1361348553 download finish for photo 1361348768 begin to download photo : 1361348771 download finish for photo 1361348737 download finish for photo 1361348553 download finish for photo 1361348771 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos imagette233843011748359111/ imagette233843031748359111/ imagette233843041748359111/ imagette233843051748359111/ imagette233843071748359111/ imagette233843101748359111/ imagette233843111748359111/ imagette233843021748359111/ imagette233843061748359111/ imagette233843121748359111/ length of list_filenames : 10 ; length of list_pids : 10 ; length of list_args : 10 results_Auto_P23384275_27-05-2025_17_18_31.pdf 23384301 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=23384301 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843011748359111 23384303 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=23384303 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843031748359111 23384304 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=23384304 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843041748359111 23384305 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=23384305 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843051748359111 23384307 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=23384307 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843071748359111 23384310 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=23384310 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843101748359111 23384311 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=23384311 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843111748359111 23384302 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=23384302 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843021748359111 23384306 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=23384306 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843061748359111 23384312 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=23384312 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette233843121748359111 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=23384275 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/23384313,23384314,23384315,23384316,23384317,23384318,23384319,23384320,23384321,23384322,23384323,23384324?tags=autre_refus,Carton_brun,flou,plastique,metal,Teint_Dans_La_Masse,cartonnette,environnement,papier,kraft,mal_croppe,Carton_gris your option no_mail is active, we will not send the real mail to your client args[1361348775] : ('0.0',) no score found for photo 1361348775 We are sending mail with results at report@fotonower.com args[1361348771] : ('0.0',) no score found for photo 1361348771 We are sending mail with results at report@fotonower.com args[1361348768] : ('0.0',) no score found for photo 1361348768 We are sending mail with results at report@fotonower.com args[1361348764] : ('0.0',) no score found for photo 1361348764 We are sending mail with results at report@fotonower.com args[1361348737] : ('0.0',) no score found for photo 1361348737 We are sending mail with results at report@fotonower.com args[1361348709] : ('0.0',) no score found for photo 1361348709 We are sending mail with results at report@fotonower.com args[1361348577] : ('0.0',) no score found for photo 1361348577 We are sending mail with results at report@fotonower.com args[1361348553] : ('0.0',) no score found for photo 1361348553 We are sending mail with results at report@fotonower.com args[1361348550] : ('0.0',) no score found for photo 1361348550 We are sending mail with results at report@fotonower.com args[1361348547] : ('0.0',) no score found for photo 1361348547 We are sending mail with results at report@fotonower.com refus_total : 0.0 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=23384275 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_P23384275_27-05-2025_17_18_31.pdf results_Auto_P23384275_27-05-2025_17_18_31.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23384275_27-05-2025_17_18_31.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','23384275','results_Auto_P23384275_27-05-2025_17_18_31.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23384275_27-05-2025_17_18_31.pdf','pdf','','0.1','0.0') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([23384275]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547] map_info['map_portfolio_photo'] : {23384275: [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547, 1361348412, 1361348378, 1361348356, 1361348042, 1361348010, 1361347809]} final : False mtd_id 4302 list_pids : [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547] 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, '2967645') ('4302', '23384275', '1361348775', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348771', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348768', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348764', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348737', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348709', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348577', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348553', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348550', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348547', None, None, None, None, None, '2967645') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 10 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', '23384275', '1361348775', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348771', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348768', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348764', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348737', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348709', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348577', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348553', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348550', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348547', None, None, None, None, None, '2967645')] time used for this insertion : 0.015444278717041016 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.43634033203125 time spend to save output : 0.015756845474243164 total time spend for step 4 : 1.4520971775054932 step5:split_time_score Tue May 27 17:18:32 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 : ['23384275'] 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 : [('23384275',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (23384275) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1361348775: {'path': 'temp/1748359110_1245475_1361348775_ac2231fb73daeac62171dfafc6ebbf36.jpg', 'extension': 'jpg'}, 1361348577: {'path': 'temp/1748359110_1245475_1361348577_158e34b606d5932797e3b2c0cb7d2249.jpg', 'extension': 'jpg'}, 1361348709: {'path': 'temp/1748359110_1245475_1361348709_9c1b3987aaa1a0b39955f089624f7a2b.jpg', 'extension': 'jpg'}, 1361348737: {'path': 'temp/1748359110_1245475_1361348737_f7bc64b20eadda9329135a5df4051bd6.jpg', 'extension': 'jpg'}, 1361348547: {'path': 'temp/1748359110_1245475_1361348547_fc8de9f571d35415b5d990ebd6b00d42.jpg', 'extension': 'jpg'}, 1361348550: {'path': 'temp/1748359110_1245475_1361348550_315d4487ffd9121032564f5f12538a0f.jpg', 'extension': 'jpg'}, 1361348553: {'path': 'temp/1748359110_1245475_1361348553_a56f0e2b58597e7da0856741a02f28b8.jpg', 'extension': 'jpg'}, 1361348764: {'path': 'temp/1748359110_1245475_1361348764_fc8d87c82784439aa3789f8532d08391.jpg', 'extension': 'jpg'}, 1361348768: {'path': 'temp/1748359110_1245475_1361348768_57ba16ab494bc40b8f2a0200c11d35eb.jpg', 'extension': 'jpg'}, 1361348771: {'path': 'temp/1748359110_1245475_1361348771_e4480f8da701b841ce2a7166cf415a86.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 = 23384275; (('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 = 23384275 group by h (('16', 16),) 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=23384275 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 (23384275) 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 (23384275) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 27052025 23384275 Nombre de photos uploadées : 16 / 23040 (0%) 27052025 23384275 Nombre de photos taguées (types de déchets): 0 / 16 (0%) 27052025 23384275 Nombre de photos taguées (volume) : 0 / 16 (0%) [{'photo_id': 1361347809, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/27/cce4263fea865074bfd521b0355a51e0.jpg', 'username': None, 'uploaded_at': 1748358823, 'text': 'image_27052025_16_45_04_10141.jpg'}, {'photo_id': 1361348042, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/27/84f3e7dc0ea05ecf43335b0b287870ce.jpg', 'username': None, 'uploaded_at': 1748358883, 'text': 'image_27052025_16_48_14_10136.jpg'}, {'photo_id': 1361348010, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/27/4f9633820e2ddcf271d7a59e257b8128.jpg', 'username': None, 'uploaded_at': 1748358883, 'text': 'image_27052025_16_49_44_10142.jpg'}, {'photo_id': 1361348412, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/27/77bbafce49375de4d545da27dd09388e.jpg', 'username': None, 'uploaded_at': 1748358943, 'text': 'image_27052025_16_49_54_10135.jpg'}] 0 [] elapsed_time : load_data_split_time_score 2.1457672119140625e-06 elapsed_time : order_list_meta_photo_and_scores 6.67572021484375e-06 ???????????????? elapsed_time : fill_and_build_computed_from_old_data 0.0009331703186035156 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 23384275, '2025-05-27' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1837719,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.023962020874023438 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= 1837719 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23360575, 'dashboard_result_id': 10949943, '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_P23360575_27-05-2025_06_09_29.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23360577, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23360578, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23360579, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23360580, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23360581, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23360582, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23360583, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23360584, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23360585, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23360586, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23360587, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23360588, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23363233, 'dashboard_result_id': 10949944, '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_P23363233_27-05-2025_06_10_01.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23363234, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23363235, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23363236, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23363237, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23363238, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23363239, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23363240, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23363241, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23363242, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23363243, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23363244, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23363245, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23364430, 'dashboard_result_id': 10949946, '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_P23364430_27-05-2025_06_10_29.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364455, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364456, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364457, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364458, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364459, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364460, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364461, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23364462, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364463, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364464, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364465, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364466, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23364644, 'dashboard_result_id': 10949947, '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_P23364644_27-05-2025_06_11_30.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 23364646, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364647, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364648, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364649, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364650, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364651, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364652, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364653, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364654, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364655, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364656, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364657, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23364943, 'dashboard_result_id': 10949948, '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_P23364943_27-05-2025_05_49_30.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364944, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364945, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364946, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364947, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23364948, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364949, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364950, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364951, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364952, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364953, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364954, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364955, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23365280, 'dashboard_result_id': 10949949, '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_P23365280_27-05-2025_06_03_30.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365317, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365318, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365319, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365320, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365321, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365322, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365323, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365324, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365325, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365326, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365327, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365328, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23365499, 'dashboard_result_id': 10949950, '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_P23365499_27-05-2025_06_16_30.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365504, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365505, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365506, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365507, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365508, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365509, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365510, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365511, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365512, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365513, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365514, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365515, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23365879, 'dashboard_result_id': 10949951, '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_P23365879_27-05-2025_06_32_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365886, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365887, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365888, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365889, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365890, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365891, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365892, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365893, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365894, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365895, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365896, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365897, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23366127, 'dashboard_result_id': 10949952, '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_P23366127_27-05-2025_06_47_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366136, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366137, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366138, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366139, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366140, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366141, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366142, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366143, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366144, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366145, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366146, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366147, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23366405, 'dashboard_result_id': 10949953, '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_P23366405_27-05-2025_07_03_00.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366418, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366419, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366420, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366421, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366422, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366423, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366424, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366425, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366426, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366427, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366429, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366430, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23366747, 'dashboard_result_id': 10949954, '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_P23366747_27-05-2025_07_16_57.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366767, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366768, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366769, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366770, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366771, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366772, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366773, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366774, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366775, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366776, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366777, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366778, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23367127, 'dashboard_result_id': 10949955, '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_P23367127_27-05-2025_07_33_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23367190, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23367191, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23367192, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23367193, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23367194, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23367195, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23367196, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23367197, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23367198, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23367199, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23367200, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23367201, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23367737, 'dashboard_result_id': 10949956, '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_P23367737_27-05-2025_07_48_59.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 23367754, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23367755, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23367756, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23367757, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23367758, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23367759, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23367760, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23367761, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23367762, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23367763, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23367764, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23367765, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23368144, 'dashboard_result_id': 10949957, '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_P23368144_27-05-2025_08_02_59.pdf', 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23368168, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23368169, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23368170, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23368171, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23368172, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23368173, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23368174, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23368175, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23368176, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23368177, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23368178, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23368179, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23368596, 'dashboard_result_id': 10949958, '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_P23368596_27-05-2025_08_17_29.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23368640, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23368642, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23368643, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23368644, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23368646, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23368647, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23368648, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23368650, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23368651, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23368653, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23368655, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23368656, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23369119, 'dashboard_result_id': 10949959, '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_P23369119_27-05-2025_08_32_59.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23369129, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23369130, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23369131, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23369132, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23369133, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23369134, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23369135, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23369136, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23369137, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23369138, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23369139, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23369140, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23369690, 'dashboard_result_id': 10949960, '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_P23369690_27-05-2025_08_49_29.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23369709, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23369710, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23369711, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23369712, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23369713, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23369714, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23369715, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23369716, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23369717, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23369718, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23369719, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23369720, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23370429, 'dashboard_result_id': 10949961, '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_P23370429_27-05-2025_09_33_01.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23370446, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23370447, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23370448, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23370449, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23370450, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23370451, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23370452, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23370453, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23370454, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23370455, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23370456, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23370457, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23373043, 'dashboard_result_id': 10949962, '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_P23373043_27-05-2025_09_43_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23373045, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23373046, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23373047, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23373048, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23373049, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23373050, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23373051, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23373052, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23373053, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23373054, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23373055, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23373056, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23373337, 'dashboard_result_id': 10949963, '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_P23373337_27-05-2025_10_00_58.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23373398, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23373399, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23373400, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23373401, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23373402, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23373403, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23373404, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23373405, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23373406, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23373407, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23373408, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23373409, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23373916, 'dashboard_result_id': 10949964, '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_P23373916_27-05-2025_10_12_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 23373917, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23373918, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23373919, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23373920, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23373921, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23373922, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23373923, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23373924, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23373925, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23373926, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23373927, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23373928, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23374097, 'dashboard_result_id': 10949965, '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_P23374097_27-05-2025_10_31_01.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23374110, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23374111, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23374112, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23374113, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23374114, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23374115, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23374116, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23374117, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23374118, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23374119, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23374120, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23374121, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23374431, 'dashboard_result_id': 10949966, '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_P23374431_27-05-2025_13_24_59.pdf', 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23374444, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23374445, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23374446, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23374447, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23374448, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23374449, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23374450, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23374451, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23374452, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23374453, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23374454, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23374455, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23377701, 'dashboard_result_id': 10949967, '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_P23377701_27-05-2025_14_12_58.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23377707, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23377708, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23377709, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23377710, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23377711, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23377712, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23377713, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23377714, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23377715, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23377716, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23377717, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23377718, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23377961, 'dashboard_result_id': 10949968, '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_P23377961_27-05-2025_14_27_01.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378010, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378011, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378012, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23378013, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378014, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378015, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378016, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378017, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378018, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378019, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378020, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378021, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23378375, 'dashboard_result_id': 10949969, '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_P23378375_27-05-2025_14_42_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23378408, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378409, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378410, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378411, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378412, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378413, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378414, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378415, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378416, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378417, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378418, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378419, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23378837, 'dashboard_result_id': 10949970, '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_P23378837_27-05-2025_14_59_57.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23378906, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378907, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378908, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378909, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378910, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378911, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378912, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378913, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378914, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378915, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378916, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378917, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23379365, 'dashboard_result_id': 10949971, '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_P23379365_27-05-2025_15_12_59.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23379368, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23379369, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23379370, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23379371, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23379372, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23379373, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23379374, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23379375, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23379376, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23379377, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23379378, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23379379, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23379884, 'dashboard_result_id': 10949972, '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_P23379884_27-05-2025_15_24_30.pdf', 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23379891, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23379892, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23379893, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23379894, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23379895, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23379896, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23379897, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23379898, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23379899, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23379900, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23379901, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23379902, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23383478, 'dashboard_result_id': 10949973, '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_P23383478_27-05-2025_17_13_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23383523, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23383524, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23383525, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23383526, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23383527, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23383528, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23383529, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23383530, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23383531, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23383532, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23383533, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23383534, 'pht': 3726}}"}, {'dashboat_entry_day': 1837719, 'dashboard_run_id': 1847752, 'mtr_portfolio_id': 23384275, 'dashboard_result_id': 10949974, '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_P23384275_27-05-2025_17_17_02.pdf'}"}] 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 = 23360575 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': 2961754, 'mtr_portfolio_id': 23360575, 'created_at': datetime.datetime(2025, 5, 27, 6, 9, 28), 'result': '0.1234835479789914', 'result_long': None, 'result_double': None}] Qualite : 0.1234835479789914 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23360575 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23360575_27-05-2025_06_09_29.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23360575 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_P23360575_27-05-2025_06_09_29.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23360577, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23360578, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23360579, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23360580, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23360581, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23360582, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23360583, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23360584, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23360585, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23360586, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23360587, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23360588, 'pht': 3726}}" where mtr_portfolio_id = 23360575 and dashboard_run_id = 1847752 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`=23360575 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949943, 0.1234835479789914, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23360575_27-05-2025_06_09_29.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23360577, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23360578, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23360579, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23360580, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23360581, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23360582, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23360583, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23360584, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23360585, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23360586, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23360587, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23360588, '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 = 23363233 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': 2961755, 'mtr_portfolio_id': 23363233, 'created_at': datetime.datetime(2025, 5, 27, 6, 10), 'result': '0.049981317891323276', 'result_long': None, 'result_double': None}] Qualite : 0.049981317891323276 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23363233 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23363233_27-05-2025_06_10_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23363233 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_P23363233_27-05-2025_06_10_01.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23363234, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23363235, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23363236, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23363237, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23363238, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23363239, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23363240, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23363241, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23363242, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23363243, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23363244, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23363245, 'pht': 3726}}" where mtr_portfolio_id = 23363233 and dashboard_run_id = 1847752 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`=23363233 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949944, 0.049981317891323276, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23363233_27-05-2025_06_10_01.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23363234, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23363235, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23363236, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23363237, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23363238, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23363239, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23363240, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23363241, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23363242, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23363243, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23363244, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23363245, '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 = 23364430 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': 2961756, 'mtr_portfolio_id': 23364430, 'created_at': datetime.datetime(2025, 5, 27, 6, 10, 28), 'result': '0.0409221154453971', 'result_long': None, 'result_double': None}] Qualite : 0.0409221154453971 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23364430 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23364430_27-05-2025_06_10_29.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23364430 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_P23364430_27-05-2025_06_10_29.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364455, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364456, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364457, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364458, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364459, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364460, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364461, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23364462, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364463, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364464, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364465, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364466, 'pht': 3726}}" where mtr_portfolio_id = 23364430 and dashboard_run_id = 1847752 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`=23364430 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949946, 0.0409221154453971, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23364430_27-05-2025_06_10_29.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364455, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364456, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364457, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364458, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364459, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364460, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364461, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23364462, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364463, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364464, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364465, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364466, '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 = 23364644 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': 2961757, 'mtr_portfolio_id': 23364644, 'created_at': datetime.datetime(2025, 5, 27, 6, 11, 29), 'result': '0.05081041669502847', 'result_long': None, 'result_double': None}] Qualite : 0.05081041669502847 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23364644 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23364644_27-05-2025_06_11_30.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23364644 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_P23364644_27-05-2025_06_11_30.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 23364646, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364647, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364648, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364649, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364650, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364651, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364652, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364653, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364654, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364655, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364656, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364657, 'pht': 3726}}" where mtr_portfolio_id = 23364644 and dashboard_run_id = 1847752 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`=23364644 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949947, 0.05081041669502847, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23364644_27-05-2025_06_11_30.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 23364646, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364647, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364648, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364649, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364650, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364651, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364652, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364653, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364654, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364655, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364656, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364657, '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 = 23364943 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': 2961763, 'mtr_portfolio_id': 23364943, 'created_at': datetime.datetime(2025, 5, 27, 5, 49, 30), 'result': '0.057623003765354966', 'result_long': None, 'result_double': None}] Qualite : 0.057623003765354966 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23364943 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23364943_27-05-2025_05_49_30.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23364943 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_P23364943_27-05-2025_05_49_30.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364944, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364945, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364946, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364947, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23364948, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364949, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364950, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364951, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364952, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364953, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364954, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364955, 'pht': 3726}}" where mtr_portfolio_id = 23364943 and dashboard_run_id = 1847752 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`=23364943 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949948, 0.057623003765354966, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23364943_27-05-2025_05_49_30.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23364944, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23364945, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23364946, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23364947, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23364948, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23364949, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23364950, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23364951, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23364952, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23364953, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23364954, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23364955, '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 = 23365280 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': 2961786, 'mtr_portfolio_id': 23365280, 'created_at': datetime.datetime(2025, 5, 27, 6, 3, 30), 'result': '0.055547372776310666', 'result_long': None, 'result_double': None}] Qualite : 0.055547372776310666 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23365280 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23365280_27-05-2025_06_03_30.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23365280 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_P23365280_27-05-2025_06_03_30.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365317, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365318, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365319, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365320, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365321, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365322, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365323, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365324, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365325, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365326, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365327, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365328, 'pht': 3726}}" where mtr_portfolio_id = 23365280 and dashboard_run_id = 1847752 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`=23365280 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949949, 0.055547372776310666, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23365280_27-05-2025_06_03_30.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365317, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365318, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365319, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365320, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365321, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365322, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365323, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365324, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365325, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365326, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365327, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365328, '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 = 23365499 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': 2961854, 'mtr_portfolio_id': 23365499, 'created_at': datetime.datetime(2025, 5, 27, 6, 16, 30), 'result': '0.0642922766973338', 'result_long': None, 'result_double': None}] Qualite : 0.0642922766973338 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23365499 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23365499_27-05-2025_06_16_30.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23365499 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_P23365499_27-05-2025_06_16_30.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365504, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365505, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365506, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365507, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365508, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365509, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365510, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365511, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365512, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365513, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365514, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365515, 'pht': 3726}}" where mtr_portfolio_id = 23365499 and dashboard_run_id = 1847752 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`=23365499 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949950, 0.0642922766973338, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23365499_27-05-2025_06_16_30.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365504, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365505, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365506, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365507, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365508, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365509, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365510, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365511, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365512, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365513, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365514, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365515, '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 = 23365879 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': 2961941, 'mtr_portfolio_id': 23365879, 'created_at': datetime.datetime(2025, 5, 27, 6, 32, 59), 'result': '0.042681626082129054', 'result_long': None, 'result_double': None}] Qualite : 0.042681626082129054 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23365879 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23365879_27-05-2025_06_32_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23365879 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_P23365879_27-05-2025_06_32_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365886, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365887, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365888, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365889, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365890, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365891, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365892, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365893, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365894, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365895, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365896, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365897, 'pht': 3726}}" where mtr_portfolio_id = 23365879 and dashboard_run_id = 1847752 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`=23365879 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949951, 0.042681626082129054, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23365879_27-05-2025_06_32_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23365886, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23365887, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23365888, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23365889, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23365890, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23365891, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23365892, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23365893, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23365894, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23365895, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23365896, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23365897, '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 = 23366127 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': 2962009, 'mtr_portfolio_id': 23366127, 'created_at': datetime.datetime(2025, 5, 27, 6, 46, 59), 'result': '0.03416169082599736', 'result_long': None, 'result_double': None}] Qualite : 0.03416169082599736 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23366127 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23366127_27-05-2025_06_47_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23366127 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_P23366127_27-05-2025_06_47_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366136, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366137, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366138, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366139, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366140, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366141, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366142, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366143, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366144, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366145, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366146, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366147, 'pht': 3726}}" where mtr_portfolio_id = 23366127 and dashboard_run_id = 1847752 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`=23366127 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949952, 0.03416169082599736, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23366127_27-05-2025_06_47_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366136, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366137, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366138, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366139, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366140, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366141, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366142, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366143, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366144, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366145, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366146, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366147, '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 = 23366405 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': 2962109, 'mtr_portfolio_id': 23366405, 'created_at': datetime.datetime(2025, 5, 27, 7, 3), 'result': '0.06886596649535763', 'result_long': None, 'result_double': None}] Qualite : 0.06886596649535763 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23366405 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23366405_27-05-2025_07_03_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23366405 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_P23366405_27-05-2025_07_03_00.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366418, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366419, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366420, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366421, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366422, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366423, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366424, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366425, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366426, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366427, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366429, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366430, 'pht': 3726}}" where mtr_portfolio_id = 23366405 and dashboard_run_id = 1847752 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`=23366405 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949953, 0.06886596649535763, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23366405_27-05-2025_07_03_00.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366418, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366419, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366420, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366421, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366422, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366423, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366424, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366425, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366426, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366427, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366429, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366430, '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 = 23366747 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': 2962272, 'mtr_portfolio_id': 23366747, 'created_at': datetime.datetime(2025, 5, 27, 7, 16, 56), 'result': '0.05824219422854155', 'result_long': None, 'result_double': None}] Qualite : 0.05824219422854155 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23366747 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23366747_27-05-2025_07_16_57.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23366747 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_P23366747_27-05-2025_07_16_57.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366767, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366768, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366769, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366770, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366771, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366772, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366773, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366774, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366775, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366776, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366777, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366778, 'pht': 3726}}" where mtr_portfolio_id = 23366747 and dashboard_run_id = 1847752 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`=23366747 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949954, 0.05824219422854155, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23366747_27-05-2025_07_16_57.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23366767, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23366768, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23366769, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23366770, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23366771, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23366772, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23366773, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23366774, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23366775, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23366776, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23366777, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23366778, '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 = 23367127 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': 2962396, 'mtr_portfolio_id': 23367127, 'created_at': datetime.datetime(2025, 5, 27, 7, 32, 59), 'result': '0.028270765429593316', 'result_long': None, 'result_double': None}] Qualite : 0.028270765429593316 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23367127 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23367127_27-05-2025_07_33_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23367127 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_P23367127_27-05-2025_07_33_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23367190, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23367191, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23367192, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23367193, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23367194, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23367195, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23367196, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23367197, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23367198, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23367199, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23367200, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23367201, 'pht': 3726}}" where mtr_portfolio_id = 23367127 and dashboard_run_id = 1847752 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`=23367127 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949955, 0.028270765429593316, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23367127_27-05-2025_07_33_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23367190, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23367191, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23367192, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23367193, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23367194, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23367195, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23367196, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23367197, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23367198, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23367199, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23367200, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23367201, '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 = 23367737 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': 2962697, 'mtr_portfolio_id': 23367737, 'created_at': datetime.datetime(2025, 5, 27, 7, 48, 59), 'result': '0.06961479734485368', 'result_long': None, 'result_double': None}] Qualite : 0.06961479734485368 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23367737 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23367737_27-05-2025_07_48_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23367737 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_P23367737_27-05-2025_07_48_59.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 23367754, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23367755, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23367756, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23367757, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23367758, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23367759, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23367760, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23367761, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23367762, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23367763, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23367764, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23367765, 'pht': 3726}}" where mtr_portfolio_id = 23367737 and dashboard_run_id = 1847752 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`=23367737 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949956, 0.06961479734485368, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23367737_27-05-2025_07_48_59.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 23367754, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23367755, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23367756, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23367757, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23367758, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23367759, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23367760, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23367761, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23367762, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23367763, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23367764, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23367765, '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 = 23368144 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': 2962995, 'mtr_portfolio_id': 23368144, 'created_at': datetime.datetime(2025, 5, 27, 8, 2, 58), 'result': '0.05816491282476588', 'result_long': None, 'result_double': None}] Qualite : 0.05816491282476588 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23368144 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23368144_27-05-2025_08_02_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23368144 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_P23368144_27-05-2025_08_02_59.pdf', 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23368168, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23368169, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23368170, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23368171, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23368172, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23368173, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23368174, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23368175, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23368176, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23368177, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23368178, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23368179, 'pht': 3726}}" where mtr_portfolio_id = 23368144 and dashboard_run_id = 1847752 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`=23368144 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949957, 0.05816491282476588, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23368144_27-05-2025_08_02_59.pdf', 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23368168, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23368169, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23368170, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23368171, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23368172, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23368173, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23368174, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23368175, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23368176, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23368177, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23368178, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23368179, '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 = 23368596 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': 2963282, 'mtr_portfolio_id': 23368596, 'created_at': datetime.datetime(2025, 5, 27, 8, 17, 28), 'result': '0.05772818180980148', 'result_long': None, 'result_double': None}] Qualite : 0.05772818180980148 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23368596 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23368596_27-05-2025_08_17_29.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23368596 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_P23368596_27-05-2025_08_17_29.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23368640, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23368642, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23368643, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23368644, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23368646, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23368647, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23368648, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23368650, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23368651, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23368653, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23368655, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23368656, 'pht': 3726}}" where mtr_portfolio_id = 23368596 and dashboard_run_id = 1847752 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`=23368596 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949958, 0.05772818180980148, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23368596_27-05-2025_08_17_29.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23368640, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23368642, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23368643, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23368644, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23368646, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23368647, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23368648, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23368650, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23368651, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23368653, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23368655, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23368656, '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 = 23369119 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': 2963541, 'mtr_portfolio_id': 23369119, 'created_at': datetime.datetime(2025, 5, 27, 8, 32, 59), 'result': '0.021210344156639943', 'result_long': None, 'result_double': None}] Qualite : 0.021210344156639943 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23369119 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23369119_27-05-2025_08_32_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23369119 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_P23369119_27-05-2025_08_32_59.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23369129, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23369130, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23369131, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23369132, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23369133, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23369134, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23369135, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23369136, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23369137, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23369138, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23369139, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23369140, 'pht': 3726}}" where mtr_portfolio_id = 23369119 and dashboard_run_id = 1847752 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`=23369119 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949959, 0.021210344156639943, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23369119_27-05-2025_08_32_59.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23369129, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23369130, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23369131, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23369132, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23369133, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23369134, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23369135, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23369136, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23369137, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23369138, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23369139, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23369140, '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 = 23369690 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': 2963836, 'mtr_portfolio_id': 23369690, 'created_at': datetime.datetime(2025, 5, 27, 8, 49, 28), 'result': '0.023794299417790408', 'result_long': None, 'result_double': None}] Qualite : 0.023794299417790408 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23369690 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23369690_27-05-2025_08_49_29.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23369690 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_P23369690_27-05-2025_08_49_29.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23369709, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23369710, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23369711, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23369712, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23369713, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23369714, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23369715, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23369716, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23369717, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23369718, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23369719, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23369720, 'pht': 3726}}" where mtr_portfolio_id = 23369690 and dashboard_run_id = 1847752 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`=23369690 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949960, 0.023794299417790408, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23369690_27-05-2025_08_49_29.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23369709, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23369710, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23369711, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23369712, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23369713, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23369714, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23369715, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23369716, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23369717, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23369718, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23369719, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23369720, '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 = 23370429 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': 2964217, 'mtr_portfolio_id': 23370429, 'created_at': datetime.datetime(2025, 5, 27, 9, 33), 'result': '0.0742641152719624', 'result_long': None, 'result_double': None}] Qualite : 0.0742641152719624 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23370429 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23370429_27-05-2025_09_33_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23370429 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_P23370429_27-05-2025_09_33_01.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23370446, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23370447, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23370448, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23370449, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23370450, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23370451, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23370452, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23370453, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23370454, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23370455, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23370456, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23370457, 'pht': 3726}}" where mtr_portfolio_id = 23370429 and dashboard_run_id = 1847752 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`=23370429 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949961, 0.0742641152719624, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23370429_27-05-2025_09_33_01.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23370446, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23370447, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23370448, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23370449, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23370450, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23370451, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23370452, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23370453, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23370454, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23370455, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23370456, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23370457, '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 = 23373043 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': 2965012, 'mtr_portfolio_id': 23373043, 'created_at': datetime.datetime(2025, 5, 27, 9, 42, 59), 'result': '0.07942100400833528', 'result_long': None, 'result_double': None}] Qualite : 0.07942100400833528 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23373043 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23373043_27-05-2025_09_43_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23373043 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_P23373043_27-05-2025_09_43_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23373045, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23373046, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23373047, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23373048, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23373049, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23373050, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23373051, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23373052, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23373053, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23373054, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23373055, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23373056, 'pht': 3726}}" where mtr_portfolio_id = 23373043 and dashboard_run_id = 1847752 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`=23373043 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949962, 0.07942100400833528, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23373043_27-05-2025_09_43_00.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23373045, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23373046, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23373047, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23373048, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23373049, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23373050, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23373051, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23373052, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23373053, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23373054, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23373055, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23373056, '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 = 23373337 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': 2965066, 'mtr_portfolio_id': 23373337, 'created_at': datetime.datetime(2025, 5, 27, 10, 0, 57), 'result': '0.06222480347235249', 'result_long': None, 'result_double': None}] Qualite : 0.06222480347235249 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23373337 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23373337_27-05-2025_10_00_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23373337 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_P23373337_27-05-2025_10_00_58.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23373398, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23373399, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23373400, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23373401, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23373402, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23373403, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23373404, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23373405, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23373406, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23373407, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23373408, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23373409, 'pht': 3726}}" where mtr_portfolio_id = 23373337 and dashboard_run_id = 1847752 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`=23373337 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949963, 0.06222480347235249, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23373337_27-05-2025_10_00_58.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23373398, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23373399, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23373400, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23373401, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23373402, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23373403, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23373404, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23373405, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23373406, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23373407, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23373408, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23373409, '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 = 23373916 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 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 = 23373916 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ORDER BY created_at desc LIMIT 1 select value from MTRUser.portfolio_carac_ratio where portfolio_id = 23373916 and created_at >= ( SELECT min(created_at) FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 23373916 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 )and created_at < ( SELECT addtime(max(created_at),100) FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 23373916 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ) order by value desc list_result_datou : [] select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23373916 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23373916_27-05-2025_10_12_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23373916 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_P23373916_27-05-2025_10_12_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 23373917, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23373918, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23373919, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23373920, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23373921, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23373922, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23373923, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23373924, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23373925, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23373926, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23373927, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23373928, 'pht': 3726}}" where mtr_portfolio_id = 23373916 and dashboard_run_id = 1847752 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 = 23374097 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 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 = 23374097 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ORDER BY created_at desc LIMIT 1 select value from MTRUser.portfolio_carac_ratio where portfolio_id = 23374097 and created_at >= ( SELECT min(created_at) FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 23374097 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 )and created_at < ( SELECT addtime(max(created_at),100) FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 23374097 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ) order by value desc list_result_datou : [] select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23374097 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23374097_27-05-2025_10_31_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23374097 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_P23374097_27-05-2025_10_31_01.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23374110, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23374111, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23374112, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23374113, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23374114, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23374115, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23374116, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23374117, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23374118, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23374119, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23374120, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23374121, 'pht': 3726}}" where mtr_portfolio_id = 23374097 and dashboard_run_id = 1847752 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 = 23374431 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 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 = 23374431 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ORDER BY created_at desc LIMIT 1 select value from MTRUser.portfolio_carac_ratio where portfolio_id = 23374431 and created_at >= ( SELECT min(created_at) FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 23374431 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 )and created_at < ( SELECT addtime(max(created_at),100) FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 23374431 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ) order by value desc list_result_datou : [] select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23374431 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23374431_27-05-2025_13_24_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23374431 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_P23374431_27-05-2025_13_24_59.pdf', 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23374444, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23374445, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23374446, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23374447, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23374448, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23374449, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23374450, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23374451, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23374452, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23374453, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23374454, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23374455, 'pht': 3726}}" where mtr_portfolio_id = 23374431 and dashboard_run_id = 1847752 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 = 23377701 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': 2966247, 'mtr_portfolio_id': 23377701, 'created_at': datetime.datetime(2025, 5, 27, 14, 12, 57), 'result': '0.05346146879834977', 'result_long': None, 'result_double': None}] Qualite : 0.05346146879834977 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23377701 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23377701_27-05-2025_14_12_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23377701 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_P23377701_27-05-2025_14_12_58.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23377707, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23377708, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23377709, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23377710, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23377711, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23377712, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23377713, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23377714, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23377715, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23377716, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23377717, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23377718, 'pht': 3726}}" where mtr_portfolio_id = 23377701 and dashboard_run_id = 1847752 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`=23377701 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949967, 0.05346146879834977, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23377701_27-05-2025_14_12_58.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23377707, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23377708, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23377709, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23377710, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23377711, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23377712, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23377713, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23377714, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23377715, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23377716, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23377717, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23377718, '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 = 23377961 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': 2966285, 'mtr_portfolio_id': 23377961, 'created_at': datetime.datetime(2025, 5, 27, 14, 27), 'result': '0.05135615518503732', 'result_long': None, 'result_double': None}] Qualite : 0.05135615518503732 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23377961 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23377961_27-05-2025_14_27_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23377961 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_P23377961_27-05-2025_14_27_01.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378010, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378011, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378012, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23378013, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378014, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378015, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378016, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378017, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378018, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378019, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378020, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378021, 'pht': 3726}}" where mtr_portfolio_id = 23377961 and dashboard_run_id = 1847752 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`=23377961 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949968, 0.05135615518503732, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23377961_27-05-2025_14_27_01.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378010, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378011, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378012, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23378013, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378014, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378015, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378016, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378017, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378018, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378019, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378020, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378021, '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 = 23378375 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': 2966376, 'mtr_portfolio_id': 23378375, 'created_at': datetime.datetime(2025, 5, 27, 14, 42, 58), 'result': '0.08075340963732429', 'result_long': None, 'result_double': None}] Qualite : 0.08075340963732429 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23378375 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23378375_27-05-2025_14_42_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23378375 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_P23378375_27-05-2025_14_42_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23378408, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378409, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378410, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378411, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378412, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378413, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378414, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378415, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378416, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378417, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378418, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378419, 'pht': 3726}}" where mtr_portfolio_id = 23378375 and dashboard_run_id = 1847752 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`=23378375 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949969, 0.08075340963732429, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23378375_27-05-2025_14_42_59.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23378408, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378409, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378410, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378411, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378412, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378413, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378414, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378415, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378416, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378417, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378418, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378419, '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 = 23378837 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': 2966466, 'mtr_portfolio_id': 23378837, 'created_at': datetime.datetime(2025, 5, 27, 14, 59, 57), 'result': '0.02730764912237019', 'result_long': None, 'result_double': None}] Qualite : 0.02730764912237019 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23378837 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23378837_27-05-2025_14_59_57.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23378837 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_P23378837_27-05-2025_14_59_57.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23378906, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378907, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378908, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378909, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378910, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378911, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378912, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378913, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378914, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378915, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378916, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378917, 'pht': 3726}}" where mtr_portfolio_id = 23378837 and dashboard_run_id = 1847752 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`=23378837 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949970, 0.02730764912237019, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23378837_27-05-2025_14_59_57.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 23378906, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23378907, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23378908, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23378909, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23378910, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23378911, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23378912, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23378913, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23378914, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23378915, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23378916, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23378917, '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 = 23379365 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': 2966618, 'mtr_portfolio_id': 23379365, 'created_at': datetime.datetime(2025, 5, 27, 15, 12, 58), 'result': '0.052102291328378667', 'result_long': None, 'result_double': None}] Qualite : 0.052102291328378667 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23379365 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23379365_27-05-2025_15_12_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23379365 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_P23379365_27-05-2025_15_12_59.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23379368, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23379369, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23379370, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23379371, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23379372, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23379373, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23379374, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23379375, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23379376, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23379377, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23379378, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23379379, 'pht': 3726}}" where mtr_portfolio_id = 23379365 and dashboard_run_id = 1847752 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`=23379365 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949971, 0.052102291328378667, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23379365_27-05-2025_15_12_59.pdf', 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23379368, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23379369, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23379370, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23379371, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23379372, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23379373, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23379374, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23379375, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23379376, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23379377, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23379378, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23379379, '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 = 23379884 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': 2966716, 'mtr_portfolio_id': 23379884, 'created_at': datetime.datetime(2025, 5, 27, 15, 27), 'result': '0.051102785594435436', 'result_long': None, 'result_double': None}] Qualite : 0.051102785594435436 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23379884 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23379884_27-05-2025_15_27_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23379884 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_P23379884_27-05-2025_15_27_00.pdf', 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23379891, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23379892, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23379893, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23379894, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23379895, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23379896, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23379897, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23379898, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23379899, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23379900, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23379901, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23379902, 'pht': 3726}}" where mtr_portfolio_id = 23379884 and dashboard_run_id = 1847752 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`=23379884 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949972, 0.051102785594435436, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23379884_27-05-2025_15_27_00.pdf', 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23379891, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23379892, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23379893, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23379894, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23379895, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23379896, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23379897, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23379898, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23379899, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23379900, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23379901, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23379902, '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 = 23383478 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': 2967443, 'mtr_portfolio_id': 23383478, 'created_at': datetime.datetime(2025, 5, 27, 17, 13), 'result': '0.03664416705276368', 'result_long': None, 'result_double': None}] Qualite : 0.03664416705276368 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23383478 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23383478_27-05-2025_17_13_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23383478 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_P23383478_27-05-2025_17_13_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23383523, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23383524, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23383525, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23383526, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23383527, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23383528, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23383529, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23383530, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23383531, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23383532, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23383533, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23383534, 'pht': 3726}}" where mtr_portfolio_id = 23383478 and dashboard_run_id = 1847752 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`=23383478 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10949973, 0.03664416705276368, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23383478_27-05-2025_17_13_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 23383523, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 23383524, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 23383525, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 23383526, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 23383527, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 23383528, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 23383529, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 23383530, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 23383531, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 23383532, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 23383533, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 23383534, '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 = 23384275 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 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 = 23384275 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ORDER BY created_at desc LIMIT 1 select value from MTRUser.portfolio_carac_ratio where portfolio_id = 23384275 and created_at >= ( SELECT min(created_at) FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 23384275 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 )and created_at < ( SELECT addtime(max(created_at),100) FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 23384275 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ) order by value desc list_result_datou : [] select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 23384275 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P23384275_27-05-2025_17_18_31.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 23384275 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_P23384275_27-05-2025_17_18_31.pdf'}" where mtr_portfolio_id = 23384275 and dashboard_run_id = 1847752 SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (23360575,23363233,23364430,23364644,23364943,23365280,23365499,23365879,23366127,23366405,23366747,23367127,23367737,23368144,23368596,23369119,23369690,23370429,23373043,23373337,23373916,23374097,23374431,23377701,23377961,23378375,23378837,23379365,23379884,23383478,23384275) result : ((1361175828,), (1361175894,), (1361175896,), (1361175897,), (1361175998,), (1361176782,), (1361177113,), (1361177123,), (1361180815,), (1361201120,), (1361201124,), (1361201160,), (1361201163,), (1361201250,), (1361201280,), (1361201283,), (1361202942,), (1361206468,), (1361206493,), (1361206556,), (1361206573,), (1361206589,), (1361206616,), (1361206619,), (1361206644,), (1361206683,), (1361206687,), (1361206754,), (1361206802,), (1361207028,), (1361207055,), (1361207064,), (1361207068,), (1361207222,), (1361207226,), (1361207230,), (1361207234,), (1361207279,), (1361207281,), (1361207648,), (1361207919,), (1361208128,), (1361209604,), (1361209633,), (1361209674,), (1361210118,), (1361210120,), (1361210140,), (1361210363,), (1361210532,), (1361210582,), (1361210698,), (1361210701,), (1361210703,), (1361211212,), (1361211090,), (1361211176,), (1361211201,), (1361211205,), (1361211306,), (1361211309,), (1361211334,), (1361211337,), (1361211364,), (1361211368,), (1361211371,), (1361211559,), (1361211567,), (1361211743,), (1361211746,), (1361211773,), (1361211978,), (1361212007,), (1361212035,), (1361212457,), (1361212405,), (1361212430,), (1361212873,), (1361212875,), (1361212878,), (1361213083,), (1361213107,), (1361213134,), (1361213164,), (1361213273,), (1361213275,), (1361213301,), (1361213327,), (1361213444,), (1361213446,), (1361213448,), (1361213451,), (1361213455,), (1361213644,), (1361213646,), (1361213648,), (1361213651,), (1361213654,), (1361213677,), (1361213680,), (1361213682,), (1361213684,), (1361213688,), (1361213702,), (1361213705,), (1361213708,), (1361213711,), (1361213717,), (1361213721,), (1361213747,), (1361213750,), (1361213753,), (1361213779,), (1361213781,), (1361213786,), (1361213790,), (1361213794,), (1361213805,), (1361213809,), (1361213811,), (1361213814,), (1361213818,), (1361213831,), (1361213856,), (1361213858,), (1361213917,), (1361213991,), (1361213994,), (1361214139,), (1361214171,), (1361214174,), (1361214176,), (1361214179,), (1361214181,), (1361214257,), (1361214261,), (1361214264,), (1361214292,), (1361214296,), (1361214301,), (1361214306,), (1361214310,), (1361214324,), (1361214327,), (1361214329,), (1361214332,), (1361214336,), (1361214340,), (1361214367,), (1361214369,), (1361214372,), (1361214376,), (1361214416,), (1361214402,), (1361214404,), (1361214406,), (1361214409,), (1361214413,), (1361214436,), (1361214443,), (1361214449,), (1361214453,), (1361214468,), (1361214469,), (1361214471,), (1361214475,), (1361214502,), (1361214505,), (1361214508,), (1361214510,), (1361214524,), (1361214528,), (1361214531,), (1361214552,), (1361214554,), (1361214557,), (1361214560,), (1361214565,), (1361214567,), (1361214580,), (1361214583,), (1361214585,), (1361214588,), (1361214590,), (1361214594,), (1361214607,), (1361214610,), (1361214613,), (1361214616,), (1361214621,), (1361214634,), (1361214637,), (1361214640,), (1361214644,), (1361214666,), (1361214668,), (1361214670,), (1361214672,), (1361214675,), (1361214688,), (1361214697,), (1361214700,), (1361214704,), (1361214707,), (1361214709,), (1361214728,), (1361214735,), (1361214740,), (1361214755,), (1361214758,), (1361214760,), (1361214762,), (1361214765,), (1361214791,), (1361214794,), (1361214797,), (1361214800,), (1361214805,), (1361214808,), (1361214822,), (1361214825,), (1361214828,), (1361214830,), (1361214864,), (1361214857,), (1361214859,), (1361214862,), (1361214879,), (1361214882,), (1361214885,), (1361214887,), (1361214890,), (1361215094,), (1361215119,), (1361215127,), (1361215130,), (1361215134,), (1361215303,), (1361215523,), (1361215527,), (1361215530,), (1361215543,), (1361215550,), (1361215556,), (1361215586,), (1361215899,), (1361215928,), (1361215953,), (1361215981,), (1361216012,), (1361216038,), (1361216304,), (1361216337,), (1361216367,), (1361216403,), (1361216433,), (1361216464,), (1361216712,), (1361216737,), (1361216767,), (1361217094,), (1361217120,), (1361217134,), (1361217138,), (1361217142,), (1361217157,), (1361218385,), (1361218558,), (1361219183,), (1361219080,), (1361219106,), (1361219133,), (1361219157,), (1361219642,), (1361219847,), (1361219850,), (1361219853,), (1361219858,), (1361219864,), (1361219990,), (1361220016,), (1361220044,), (1361220072,), (1361220100,), (1361220287,), (1361220291,), (1361220319,), (1361220344,), (1361220403,), (1361220405,), (1361220425,), (1361220452,), (1361220485,), (1361220513,), (1361220631,), (1361220634,), (1361220638,), (1361220651,), (1361220692,), (1361220696,), (1361220698,), (1361220741,), (1361220744,), (1361220754,), (1361220770,), (1361220776,), (1361220863,), (1361220868,), (1361220872,), (1361220875,), (1361220904,), (1361220908,), (1361220911,), (1361220943,), (1361220946,), (1361220950,), (1361220954,), (1361220959,), (1361220965,), (1361220986,), (1361220991,), (1361220997,), (1361221001,), (1361221007,), (1361221041,), (1361221044,), (1361221050,), (1361221056,), (1361221062,), (1361221068,), (1361221090,), (1361221095,), (1361221102,), (1361221109,), (1361221117,), (1361221157,), (1361221150,), (1361221153,), (1361221211,), (1361221216,), (1361221222,), (1361221229,), (1361221234,), (1361221272,), (1361221279,), (1361221287,), (1361221294,), (1361221324,), (1361221327,), (1361221329,), (1361221333,), (1361221336,), (1361221344,), (1361221371,), (1361221375,), (1361221379,), (1361221381,), (1361221384,), (1361221385,), (1361221421,), (1361221428,), (1361221442,), (1361221526,), (1361221530,), (1361221533,), (1361221537,), (1361221541,), (1361221545,), (1361221573,), (1361221577,), (1361221582,), (1361221588,), (1361221629,), (1361221634,), (1361221638,), (1361221641,), (1361221649,), (1361221683,), (1361221688,), (1361221694,), (1361221701,), (1361221708,), (1361221741,), (1361221746,), (1361221750,), (1361221805,), (1361221809,), (1361221812,), (1361221817,), (1361221820,), (1361221826,), (1361221860,), (1361221864,), (1361221869,), (1361221874,), (1361221880,), (1361221886,), (1361221914,), (1361221918,), (1361221921,), (1361221926,), (1361221963,), (1361221969,), (1361221976,), (1361221983,), (1361221990,), (1361221998,), (1361222311,), (1361222220,), (1361222250,), (1361222281,), (1361222362,), (1361222365,), (1361222367,), (1361222371,), (1361222376,), (1361222386,), (1361222415,), (1361222422,), (1361222427,), (1361222432,), (1361222437,), (1361222463,), (1361222465,), (1361222466,), (1361222469,), (1361222504,), (1361222510,), (1361222514,), (1361222520,), (1361222527,), (1361222533,), (1361222565,), (1361222570,), (1361222574,), (1361222578,), (1361222583,), (1361222609,), (1361222612,), (1361222616,), (1361222621,), (1361222659,), (1361222664,), (1361222669,), (1361222674,), (1361222680,), (1361222687,), (1361222715,), (1361222718,), (1361222724,), (1361222729,), (1361222736,), (1361222768,), (1361222773,), (1361222776,), (1361222781,), (1361222825,), (1361222832,), (1361222837,), (1361222844,), (1361222850,), (1361222872,), (1361222876,), (1361222879,), (1361222884,), (1361222889,), (1361222894,), (1361222911,), (1361222915,), (1361222918,), (1361222944,), (1361222947,), (1361222953,), (1361222964,), (1361222967,), (1361222970,), (1361222983,), (1361223000,), (1361223005,), (1361223012,), (1361223067,), (1361223144,), (1361223033,), (1361223037,), (1361223045,), (1361223057,), (1361223063,), (1361223083,), (1361223085,), (1361223087,), (1361223089,), (1361223090,), (1361223102,), (1361223118,), (1361223124,), (1361223130,), (1361223135,), (1361223139,), (1361223152,), (1361223156,), (1361223183,), (1361223262,), (1361223420,), (1361223469,), (1361223472,), (1361223485,), (1361223489,), (1361223523,), (1361223527,), (1361223530,), (1361223534,), (1361223539,), (1361223738,), (1361223741,), (1361223753,), (1361223839,), (1361224033,), (1361224036,), (1361224069,), (1361224920,), (1361224927,), (1361224934,), (1361225004,), (1361224994,), (1361225001,), (1361225056,), (1361225061,), (1361225067,), (1361225073,), (1361225079,), (1361225081,), (1361225137,), (1361225142,), (1361225146,), (1361225157,), (1361225167,), (1361225228,), (1361225258,), (1361225293,), (1361225436,), (1361225440,), (1361225441,), (1361225445,), (1361225448,), (1361225454,), (1361225486,), (1361225490,), (1361225495,), (1361225501,), (1361225506,), (1361225535,), (1361225539,), (1361225545,), (1361225549,), (1361225554,), (1361225598,), (1361225600,), (1361225606,), (1361225612,), (1361225616,), (1361225622,), (1361225655,), (1361225661,), (1361225667,), (1361225673,), (1361225705,), (1361225709,), (1361225715,), (1361225720,), (1361225726,), (1361225827,), (1361225830,), (1361225834,), (1361225839,), (1361225850,), (1361225956,), (1361225962,), (1361225966,), (1361225972,), (1361226011,), (1361226017,), (1361226027,), (1361226039,), (1361226048,), (1361226056,), (1361226147,), (1361226159,), (1361226167,), (1361226172,), (1361226177,), (1361226211,), (1361226214,), (1361226216,), (1361226220,), (1361226267,), (1361226251,), (1361226254,), (1361226258,), (1361226262,), (1361226288,), (1361226291,), (1361226295,), (1361226301,), (1361226340,), (1361226342,), (1361226346,), (1361226350,), (1361226356,), (1361226360,), (1361226390,), (1361226395,), (1361226400,), (1361226406,), (1361226411,), (1361226419,), (1361226439,), (1361226441,), (1361226444,), (1361226483,), (1361226487,), (1361226491,), (1361226495,), (1361226500,), (1361226506,), (1361226535,), (1361226539,), (1361226543,), (1361226547,), (1361226551,), (1361226557,), (1361226582,), (1361226585,), (1361226588,), (1361226592,), (1361226624,), (1361226628,), (1361226632,), (1361226636,), (1361226642,), (1361226648,), (1361226672,), (1361226676,), (1361226682,), (1361226687,), (1361226716,), (1361226719,), (1361226722,), (1361226726,), (1361226734,), (1361226762,), (1361226764,), (1361226766,), (1361226770,), (1361226775,), (1361226780,), (1361226804,), (1361226807,), (1361226811,), (1361226843,), (1361226848,), (1361226851,), (1361226854,), (1361226858,), (1361226890,), (1361226894,), (1361226899,), (1361226905,), (1361226913,), (1361226950,), (1361226941,), (1361226945,), (1361226997,), (1361227001,), (1361227005,), (1361227010,), (1361227042,), (1361227045,), (1361227048,), (1361227084,), (1361227092,), (1361227128,), (1361227171,), (1361227174,), (1361227181,), (1361227214,), (1361227219,), (1361227223,), (1361227229,), (1361227234,), (1361227239,), (1361227262,), (1361227266,), (1361227268,), (1361227272,), (1361227307,), (1361227310,), (1361227312,), (1361227316,), (1361227322,), (1361227348,), (1361227350,), (1361227431,), (1361227475,), (1361227480,), (1361227485,), (1361227493,), (1361227499,), (1361227526,), (1361227530,), (1361227533,), (1361227537,), (1361227571,), (1361227575,), (1361227578,), (1361227629,), (1361227608,), (1361227610,), (1361227613,), (1361227618,), (1361227621,), (1361227652,), (1361227655,), (1361227658,), (1361227662,), (1361227669,), (1361227703,), (1361227706,), (1361227745,), (1361227750,), (1361227894,), (1361227921,), (1361227949,), (1361228127,), (1361228147,), (1361228175,), (1361228179,), (1361228191,), (1361228242,), (1361228244,), (1361228247,), (1361228249,), (1361228274,), (1361246556,), (1361246497,), (1361246528,), (1361246934,), (1361246939,), (1361246948,), (1361246978,), (1361246982,), (1361247036,), (1361247261,), (1361247295,), (1361247312,), (1361247411,), (1361247505,), (1361247662,), (1361248048,), (1361248101,), (1361248442,), (1361248485,), (1361248682,), (1361248690,), (1361248707,), (1361248710,), (1361248712,), (1361248715,), (1361248758,), (1361248776,), (1361248780,), (1361248787,), (1361248816,), (1361248843,), (1361249025,), (1361249011,), (1361249022,), (1361249066,), (1361249068,), (1361249071,), (1361249073,), (1361249075,), (1361249077,), (1361249146,), (1361249173,), (1361249200,), (1361249873,), (1361249931,), (1361249982,), (1361250203,), (1361250232,), (1361250259,), (1361250568,), (1361250678,), (1361250776,), (1361250907,), (1361250935,), (1361250998,), (1361251066,), (1361251638,), (1361251690,), (1361251741,), (1361251801,), (1361251869,), (1361252586,), (1361252625,), (1361252657,), (1361252710,), (1361252748,), (1361252776,), (1361253346,), (1361253422,), (1361253885,), (1361253960,), (1361254474,), (1361254491,), (1361255218,), (1361255252,), (1361255265,), (1361255995,), (1361256035,), (1361257033,), (1361257000,), (1361257022,), (1361257024,), (1361257027,), (1361257030,), (1361257073,), (1361257079,), (1361257082,), (1361257085,), (1361257117,), (1361257120,), (1361257145,), (1361257147,), (1361257149,), (1361257152,), (1361257171,), (1361257177,), (1361257181,), (1361257183,), (1361257185,), (1361257214,), (1361257216,), (1361257219,), (1361257222,), (1361257225,), (1361257258,), (1361257262,), (1361257266,), (1361257268,), (1361257271,), (1361257307,), (1361257311,), (1361257313,), (1361257346,), (1361257349,), (1361257351,), (1361257353,), (1361257355,), (1361257358,), (1361257390,), (1361257394,), (1361257396,), (1361257401,), (1361257402,), (1361257436,), (1361257440,), (1361257445,), (1361257448,), (1361257483,), (1361257487,), (1361257491,), (1361257492,), (1361257496,), (1361257498,), (1361257534,), (1361257525,), (1361257528,), (1361257530,), (1361257532,), (1361257564,), (1361257568,), (1361257570,), (1361257573,), (1361257576,), (1361257607,), (1361257612,), (1361257615,), (1361257619,), (1361257624,), (1361257628,), (1361257650,), (1361257654,), (1361257657,), (1361257661,), (1361257695,), (1361257700,), (1361257705,), (1361257707,), (1361257709,), (1361257711,), (1361257747,), (1361257751,), (1361257755,), (1361257759,), (1361257763,), (1361257765,), (1361257789,), (1361257823,), (1361257825,), (1361257827,), (1361257864,), (1361257868,), (1361257871,), (1361257874,), (1361257877,), (1361257880,), (1361257913,), (1361257917,), (1361257920,), (1361257964,), (1361257967,), (1361257970,), (1361257973,), (1361257975,), (1361257978,), (1361258007,), (1361258011,), (1361258014,), (1361258016,), (1361258059,), (1361258062,), (1361258065,), (1361258067,), (1361258069,), (1361258072,), (1361258279,), (1361258304,), (1361258499,), (1361258495,), (1361258497,), (1361258530,), (1361258535,), (1361258570,), (1361258604,), (1361258955,), (1361278504,), (1361297866,), (1361298148,), (1361298268,), (1361298416,), (1361298424,), (1361298427,), (1361298432,), (1361298436,), (1361298440,), (1361298460,), (1361298463,), (1361298467,), (1361298471,), (1361298475,), (1361298504,), (1361298508,), (1361298511,), (1361298516,), (1361298524,), (1361298528,), (1361298575,), (1361298593,), (1361298612,), (1361298622,), (1361298695,), (1361298700,), (1361298708,), (1361298712,), (1361298747,), (1361298753,), (1361298757,), (1361298761,), (1361298765,), (1361298798,), (1361298805,), (1361298809,), (1361298812,), (1361298815,), (1361298817,), (1361298850,), (1361298854,), (1361298857,), (1361298859,), (1361298862,), (1361298920,), (1361298901,), (1361298961,), (1361298981,), (1361298988,), (1361299008,), (1361299013,), (1361299017,), (1361299027,), (1361299037,), (1361299066,), (1361299070,), (1361299073,), (1361299304,), (1361299308,), (1361299407,), (1361299411,), (1361299413,), (1361299451,), (1361299454,), (1361299463,), (1361299467,), (1361299559,), (1361299565,), (1361299566,), (1361299568,), (1361299710,), (1361299716,), (1361299744,), (1361299768,), (1361299775,), (1361299873,), (1361299876,), (1361299880,), (1361299884,), (1361299980,), (1361300018,), (1361300063,), (1361300068,), (1361300072,), (1361300075,), (1361300143,), (1361300147,), (1361300153,), (1361300159,), (1361300169,), (1361300172,), (1361300175,), (1361300178,), (1361300181,), (1361300432,), (1361300362,), (1361300400,), (1361300407,), (1361300430,), (1361300575,), (1361300583,), (1361300771,), (1361300776,), (1361300799,), (1361301111,), (1361301114,), (1361301118,), (1361301120,), (1361301122,), (1361301143,), (1361301148,), (1361301151,), (1361301153,), (1361301155,), (1361301185,), (1361301190,), (1361301235,), (1361301241,), (1361301244,), (1361301247,), (1361301250,), (1361301397,), (1361301400,), (1361301407,), (1361301559,), (1361301567,), (1361301789,), (1361301870,), (1361302108,), (1361302112,), (1361302116,), (1361302354,), (1361302383,), (1361302562,), (1361302588,), (1361302593,), (1361302829,), (1361302868,), (1361302896,), (1361302907,), (1361302909,), (1361302946,), (1361302951,), (1361302960,), (1361302964,), (1361303344,), (1361303163,), (1361303250,), (1361303282,), (1361303316,), (1361303555,), (1361303567,), (1361303570,), (1361303574,), (1361303604,), (1361303621,), (1361303646,), (1361303658,), (1361303661,), (1361303870,), (1361303901,), (1361303989,), (1361304069,), (1361304108,), (1361304113,), (1361304302,), (1361304315,), (1361304319,), (1361304332,), (1361304361,), (1361304396,), (1361304400,), (1361304403,), (1361304406,), (1361304408,), (1361304448,), (1361304452,), (1361304485,), (1361305242,), (1361308324,), (1361308242,), (1361308270,), (1361308300,), (1361308473,), (1361308506,), (1361308533,), (1361308559,), (1361308606,), (1361308720,), (1361308723,), (1361308727,), (1361308731,), (1361308735,), (1361308898,), (1361308927,), (1361308954,), (1361308989,), (1361309485,), (1361309531,), (1361309655,), (1361309688,), (1361309716,), (1361309741,), (1361310159,), (1361310195,), (1361310226,), (1361310254,), (1361310303,), (1361310608,), (1361310708,), (1361310713,), (1361310718,), (1361310773,), (1361310777,), (1361310780,), (1361310785,), (1361310806,), (1361310823,), (1361310888,), (1361310898,), (1361310917,), (1361310964,), (1361310993,), (1361311406,), (1361311442,), (1361311483,), (1361312158,), (1361312226,), (1361312279,), (1361312319,), (1361312365,), (1361312409,), (1361312845,), (1361312911,), (1361312973,), (1361313011,), (1361313043,), (1361313275,), (1361313230,), (1361313247,), (1361313261,), (1361313728,), (1361313796,), (1361313866,), (1361314469,), (1361314519,), (1361314621,), (1361314716,), (1361314807,), (1361315305,), (1361315375,), (1361315457,), (1361315520,), (1361315588,), (1361315650,), (1361316135,), (1361316169,), (1361316225,), (1361316626,), (1361316649,), (1361316661,), (1361316683,), (1361316701,), (1361316912,), (1361316927,), (1361316948,), (1361316962,), (1361316980,), (1361317740,), (1361317810,), (1361317895,), (1361318689,), (1361318791,), (1361318891,), (1361318993,), (1361319072,), (1361319160,), (1361319858,), (1361319938,), (1361320000,), (1361320065,), (1361320142,), (1361320769,), (1361320785,), (1361320804,), (1361320814,), (1361320817,), (1361321043,), (1361321064,), (1361321090,), (1361321123,), (1361321839,), (1361321904,), (1361321961,), (1361322041,), (1361322119,), (1361323359,), (1361323392,), (1361323471,), (1361323532,), (1361323576,), (1361323598,), (1361324116,), (1361345342,), (1361345380,), (1361345410,), (1361345437,), (1361345695,), (1361345699,), (1361345709,), (1361345739,), (1361345769,), (1361345892,), (1361345922,), (1361345949,), (1361346024,), (1361346029,), (1361346032,), (1361346035,), (1361346037,), (1361346040,), (1361346052,), (1361346054,), (1361346056,), (1361346058,), (1361346066,), (1361346119,), (1361346125,), (1361346132,), (1361346137,), (1361346193,), (1361346198,), (1361346203,), (1361346208,), (1361346211,), (1361346215,), (1361346262,), (1361346266,), (1361346270,), (1361346273,), (1361346276,), (1361346480,), (1361346487,), (1361346490,), (1361346493,), (1361346496,), (1361346667,), (1361346671,), (1361346675,), (1361346682,), (1361346689,), (1361346827,), (1361346855,), (1361346874,), (1361346990,), (1361346994,), (1361346997,), (1361346999,), (1361347062,), (1361347067,), (1361347080,), (1361347254,), (1361347256,), (1361347608,), (1361347809,), (1361348010,), (1361348042,), (1361348356,), (1361348378,), (1361348412,), (1361348547,), (1361348550,), (1361348553,), (1361348577,), (1361348709,), (1361348737,), (1361348764,), (1361348768,), (1361348771,), (1361348775,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'27052025': {'nb_upload': 16, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([23384275]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547] map_info['map_portfolio_photo'] : {23384275: [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547, 1361348412, 1361348378, 1361348356, 1361348042, 1361348010, 1361347809]} final : True mtd_id 4302 list_pids : [1361348775, 1361348771, 1361348768, 1361348764, 1361348737, 1361348709, 1361348577, 1361348553, 1361348550, 1361348547] Looping around the photos to save general results len do output : 1 /23384275Didn'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, '2967645') ('4302', '23384275', '1361348775', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348771', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348768', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348764', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348737', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348709', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348577', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348553', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348550', None, None, None, None, None, '2967645') ('4302', None, None, None, None, None, None, None, '2967645') ('4302', '23384275', '1361348547', None, None, None, None, None, '2967645') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 11 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', None, '23384275', 'None', None, None, None, None, '2967645'), ('4302', '23384275', '1361348775', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348771', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348768', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348764', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348737', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348709', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348577', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348553', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348550', None, None, None, None, None, '2967645'), ('4302', '23384275', '1361348547', None, None, None, None, None, '2967645')] time used for this insertion : 0.017362594604492188 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.8216605186462402 time spend to save output : 0.017615079879760742 total time spend for step 5 : 1.839275598526001 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 (2967645) 2.29user 2.01system 0:09.00elapsed 47%CPU (0avgtext+0avgdata 158464maxresident)k 208inputs+6176outputs (2major+77838minor)pagefaults 0swaps