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 : 3278332 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 (4260869) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (4260869) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638070 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['4260869'] with mtr_portfolio_ids : ['29638070'] and first list_photo_ids : [] new path : /proc/3278332/ Name: python3 Umask: 0002 State: R (running) Tgid: 3278332 Ngid: 0 Pid: 3278332 PPid: 3278331 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 3278332 NSpid: 3278332 NSpgid: 3277179 NSsid: 3277179 VmPeak: 1113364 kB VmSize: 1113364 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 106828 kB VmRSS: 106828 kB RssAnon: 66284 kB RssFile: 40544 kB RssShmem: 0 kB VmData: 872092 kB VmStk: 132 kB VmExe: 2644 kB VmLib: 130476 kB VmPTE: 600 kB VmSwap: 0 kB HugetlbPages: 0 kB CoreDumping: 0 THP_enabled: 1 Threads: 1 SigQ: 0/63019 SigPnd: 0000000000000000 ShdPnd: 0000000000000000 SigBlk: 0000000000000000 SigIgn: 0000000001001000 SigCgt: 0000000180000002 CapInh: 0000000000000000 CapPrm: 0000000000000000 CapEff: 0000000000000000 CapBnd: 000001ffffffffff CapAmb: 0000000000000000 NoNewPrivs: 0 Seccomp: 0 Seccomp_filters: 0 Speculation_Store_Bypass: thread vulnerable SpeculationIndirectBranch: conditional enabled Cpus_allowed: ffffffff,ffffffff,ffffffff,ffffffff Cpus_allowed_list: 0-127 Mems_allowed: 00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001 Mems_allowed_list: 0 voluntary_ctxt_switches: 45 nonvoluntary_ctxt_switches: 92 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '3278332', 'Ngid': '0', 'Pid': '3278332', 'PPid': '3278331', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '3278332', 'NSpid': '3278332', 'NSpgid': '3277179', 'NSsid': '3277179', 'VmPeak': '1113364 kB', 'VmSize': '1113364 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '106828 kB', 'VmRSS': '106828 kB', 'RssAnon': '66284 kB', 'RssFile': '40544 kB', 'RssShmem': '0 kB', 'VmData': '872092 kB', 'VmStk': '132 kB', 'VmExe': '2644 kB', 'VmLib': '130476 kB', 'VmPTE': '600 kB', 'VmSwap': '0 kB', 'HugetlbPages': '0 kB', 'CoreDumping': '0', 'THP_enabled': '1', 'Threads': '1', 'SigQ': '0/63019', 'SigPnd': '0000000000000000', 'ShdPnd': '0000000000000000', 'SigBlk': '0000000000000000', 'SigIgn': '0000000001001000', 'SigCgt': '0000000180000002', 'CapInh': '0000000000000000', 'CapPrm': '0000000000000000', 'CapEff': '0000000000000000', 'CapBnd': '000001ffffffffff', 'CapAmb': '0000000000000000', 'NoNewPrivs': '0', 'Seccomp': '0', 'Seccomp_filters': '0', 'Speculation_Store_Bypass': 'thread vulnerable', 'SpeculationIndirectBranch': 'conditional enabled', 'Cpus_allowed': 'ffffffff,ffffffff,ffffffff,ffffffff', 'Cpus_allowed_list': '0-127', 'Mems_allowed': '00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001', 'Mems_allowed_list': '0', 'voluntary_ctxt_switches': '45', 'nonvoluntary_ctxt_switches': '92'} ('datou_batch_current', '3278332', '1113364', '0', '1113364', '872092', '106828', b'', 'marlene', '4260869') 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_view ph WHERE ph.photo_id IN (SELECT mtr_photo_id from MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id in (29638070) 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 (4260869 ) ) 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 (29638070) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1400627919, 'portfolio_id': 29638070}, {'photo_id': 1400627918, 'portfolio_id': 29638070}, {'photo_id': 1400627917, 'portfolio_id': 29638070}, {'photo_id': 1400627895, 'portfolio_id': 29638070}, {'photo_id': 1400627890, 'portfolio_id': 29638070}, {'photo_id': 1400627889, 'portfolio_id': 29638070}, {'photo_id': 1400627888, 'portfolio_id': 29638070}, {'photo_id': 1400627887, 'portfolio_id': 29638070}, {'photo_id': 1400627872, 'portfolio_id': 29638070}, {'photo_id': 1400627869, 'portfolio_id': 29638070}, {'photo_id': 1400627868, 'portfolio_id': 29638070}, {'photo_id': 1400627867, 'portfolio_id': 29638070}, {'photo_id': 1400627865, 'portfolio_id': 29638070}, {'photo_id': 1400627848, 'portfolio_id': 29638070}, {'photo_id': 1400627846, 'portfolio_id': 29638070}, {'photo_id': 1400627844, 'portfolio_id': 29638070}, {'photo_id': 1400627826, 'portfolio_id': 29638070}, {'photo_id': 1400627825, 'portfolio_id': 29638070}, {'photo_id': 1400627824, 'portfolio_id': 29638070}, {'photo_id': 1400627807, 'portfolio_id': 29638070}] map_portfolio_id_photo_id: {29638070: [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865, 1400627848, 1400627846, 1400627844, 1400627826, 1400627825, 1400627824, 1400627807]} ##### 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.01919078826904297 #### 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 Dec 23 01:38:57 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (29638070) 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 : 29638070 get user id for portfolio 29638070 get sub ptf for main ptf 29638070, type 3726 and hashtags ['Teint_Dans_La_Masse', 'kraft', 'metal', 'Carton_brun', 'cartonnette', 'autre_refus', 'flou', 'mal_croppe', 'environnement', 'papier', 'Carton_gris', 'plastique'] 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`=29638070 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Teint_Dans_La_Masse','kraft','metal','Carton_brun','cartonnette','autre_refus','flou','mal_croppe','environnement','papier','Carton_gris','plastique')) 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`=29638070 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Teint_Dans_La_Masse','kraft','metal','Carton_brun','cartonnette','autre_refus','flou','mal_croppe','environnement','papier','Carton_gris','plastique')) AND mptpi.`min_score`=0.5 To do returned map {'papier': {'main_port_id': 29638070, 'sub_port_id': 29638072, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236749, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'flou': {'main_port_id': 29638070, 'sub_port_id': 29638073, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236750, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'plastique': {'main_port_id': 29638070, 'sub_port_id': 29638074, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236751, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'metal': {'main_port_id': 29638070, 'sub_port_id': 29638075, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236752, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'cartonnette': {'main_port_id': 29638070, 'sub_port_id': 29638076, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236753, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'Teint_Dans_La_Masse': {'main_port_id': 29638070, 'sub_port_id': 29638077, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236754, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'environnement': {'main_port_id': 29638070, 'sub_port_id': 29638078, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236755, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'Carton_brun': {'main_port_id': 29638070, 'sub_port_id': 29638079, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236756, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'Carton_gris': {'main_port_id': 29638070, 'sub_port_id': 29638080, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236757, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'mal_croppe': {'main_port_id': 29638070, 'sub_port_id': 29638081, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236758, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'autre_refus': {'main_port_id': 29638070, 'sub_port_id': 29638082, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236759, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}, 'kraft': {'main_port_id': 29638070, 'sub_port_id': 29638083, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236760, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 34, 58)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 29638072 , 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=29638070 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 (29638072) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638073 , 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=29638070 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 (29638073) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638074 , 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=29638070 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 (29638074) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638075 , 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=29638070 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 (29638075) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638076 , 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=29638070 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 (29638076) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638077 , 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=29638070 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 (29638077) result : ((1400627896,), (1400627912,), (1400627913,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638078 , 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=29638070 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 (29638078) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638079 , 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=29638070 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 (29638079) result : ((1400627914,),) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638080 , 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=29638070 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 (29638080) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638081 , 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=29638070 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 (29638081) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638082 , 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=29638070 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 (29638082) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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 29638083 , 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=29638070 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 (29638083) result : ((1400627899,), (1400627915,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29638070) result : ((1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) 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`=29638070 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Teint_Dans_La_Masse','kraft','metal','Carton_brun','cartonnette','autre_refus','flou','mal_croppe','environnement','papier','Carton_gris','plastique')) 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`=29638070 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Teint_Dans_La_Masse','kraft','metal','Carton_brun','cartonnette','autre_refus','flou','mal_croppe','environnement','papier','Carton_gris','plastique')) AND mptpi.`min_score`=0.5 To do returned map {'papier': {'main_port_id': 29638070, 'sub_port_id': 29638084, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236761, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'flou': {'main_port_id': 29638070, 'sub_port_id': 29638085, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236762, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'plastique': {'main_port_id': 29638070, 'sub_port_id': 29638086, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236763, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'metal': {'main_port_id': 29638070, 'sub_port_id': 29638087, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236764, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'cartonnette': {'main_port_id': 29638070, 'sub_port_id': 29638088, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236765, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'Teint_Dans_La_Masse': {'main_port_id': 29638070, 'sub_port_id': 29638089, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236766, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'environnement': {'main_port_id': 29638070, 'sub_port_id': 29638090, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236767, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'Carton_brun': {'main_port_id': 29638070, 'sub_port_id': 29638091, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236768, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'Carton_gris': {'main_port_id': 29638070, 'sub_port_id': 29638092, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236769, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'mal_croppe': {'main_port_id': 29638070, 'sub_port_id': 29638093, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236770, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'autre_refus': {'main_port_id': 29638070, 'sub_port_id': 29638094, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236771, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 35), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}, 'kraft': {'main_port_id': 29638070, 'sub_port_id': 29638095, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 20236772, 'last_updated_at': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_desc': datetime.datetime(2025, 12, 23, 1, 37), 'last_updated_at_asc': datetime.datetime(2025, 12, 23, 1, 35)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638084,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638072 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638085,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638073 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638086,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638074 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638087,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638075 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638088,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638076 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638089,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638077 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638090,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638078 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638091,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638079 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638092,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638080 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638093,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638081 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638094,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638082 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 29638095,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 29638083 lien utilise dans velours : https://marlene.fotonower.com/velours/29638084,29638085,29638086,29638087,29638088,29638089,29638090,29638091,29638092,29638093,29638094,29638095?tags=papier,flou,plastique,metal,cartonnette,Teint_Dans_La_Masse,environnement,Carton_brun,Carton_gris,mal_croppe,autre_refus,kraft After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([29638070]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865] map_info['map_portfolio_photo'] : {29638070: [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865, 1400627848, 1400627846, 1400627844, 1400627826, 1400627825, 1400627824, 1400627807]} final : False mtd_id 4302 list_pids : [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865] Looping around the photos to save general results len do output : 1 /29638070. 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, '4260869') ('4302', '29638070', '1400627919', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627918', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627917', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627895', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627890', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627889', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627888', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627887', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627872', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627869', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627868', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627867', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627865', None, None, None, None, None, '4260869') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 14 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, '29638070', "{'papier': 29638072, 'flou': 29638073, 'plastique': 29638074, 'metal': 29638075, 'cartonnette': 29638076, 'Teint_Dans_La_Masse': 29638077, 'environnement': 29638078, 'Carton_brun': 29638079, 'Carton_gris': 29638080, 'mal_croppe': 29638081, 'autre_refus': 29638082, 'kraft': 29638083}", None, None, None, None, '4260869'), ('4302', '29638070', '1400627919', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627918', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627917', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627895', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627890', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627889', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627888', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627887', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627872', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627869', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627868', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627867', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627865', None, None, None, None, None, '4260869')] time used for this insertion : 0.016675949096679688 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.8120718002319336 time spend to save output : 0.01695847511291504 total time spend for step 1 : 1.8290302753448486 step2:final Tue Dec 23 01:38:59 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :0, first value : [] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (29638070) 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 29638070 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1400627807,1400627826,1400627825,1400627824,1400627848,1400627846,1400627844,1400627872,1400627869,1400627868,1400627867,1400627865,1400627895,1400627890,1400627889,1400627888,1400627887,1400627919,1400627918,1400627917); insert ignore into MTRUser.portfolio_carac_ratio (portfolio_id, hashtag_type, hashtag_id, value) values (%s,%s,%s,%s) on DUPLICATE KEY UPDATE value=VALUES(value) After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([29638070]) Inside saveOutput : final : False verbose : True original output for save of step final : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} new output for save of step final : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865] map_info['map_portfolio_photo'] : {29638070: [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865, 1400627848, 1400627846, 1400627844, 1400627826, 1400627825, 1400627824, 1400627807]} final : False mtd_id 4302 list_pids : [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865] Looping around the photos to save general results len do output : 13 /1400627919.Didn't retrieve data . /1400627918.Didn't retrieve data . /1400627917.Didn't retrieve data . /1400627895.Didn't retrieve data . /1400627890.Didn't retrieve data . /1400627889.Didn't retrieve data . /1400627888.Didn't retrieve data . /1400627887.Didn't retrieve data . /1400627872.Didn't retrieve data . /1400627869.Didn't retrieve data . /1400627868.Didn't retrieve data . /1400627867.Didn't retrieve data . /1400627865.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, '4260869') ('4302', '29638070', '1400627919', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627918', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627917', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627895', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627890', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627889', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627888', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627887', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627872', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627869', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627868', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627867', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627865', None, None, None, None, None, '4260869') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 39 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', '29638070', '1400627919', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627918', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627917', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627895', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627890', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627889', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627888', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627887', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627872', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627869', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627868', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627867', '0.022169094897383262', None, None, None, None, '4260869'), ('4302', '29638070', '1400627865', '0.022169094897383262', None, None, None, None, '4260869')] time used for this insertion : 0.01896834373474121 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.07852721214294434 time spend to save output : 0.019551515579223633 total time spend for step 2 : 0.09807872772216797 step3:velours_tree Tue Dec 23 01:38:59 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : {29638070: [{'papier': 29638072, 'flou': 29638073, 'plastique': 29638074, 'metal': 29638075, 'cartonnette': 29638076, 'Teint_Dans_La_Masse': 29638077, 'environnement': 29638078, 'Carton_brun': 29638079, 'Carton_gris': 29638080, 'mal_croppe': 29638081, 'autre_refus': 29638082, 'kraft': 29638083}]} input_args_next_step : {29638070: ()} output_args : {29638070: [{'papier': 29638072, 'flou': 29638073, 'plastique': 29638074, 'metal': 29638075, 'cartonnette': 29638076, 'Teint_Dans_La_Masse': 29638077, 'environnement': 29638078, 'Carton_brun': 29638079, 'Carton_gris': 29638080, 'mal_croppe': 29638081, 'autre_refus': 29638082, 'kraft': 29638083}]} args : 29638070 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 : ({'papier': 29638072, 'flou': 29638073, 'plastique': 29638074, 'metal': 29638075, 'cartonnette': 29638076, 'Teint_Dans_La_Masse': 29638077, 'environnement': 29638078, 'Carton_brun': 29638079, 'Carton_gris': 29638080, 'mal_croppe': 29638081, 'autre_refus': 29638082, 'kraft': 29638083},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (29638070) 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([29638070]) 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.24194574356079102 time spend to save output : 5.2928924560546875e-05 total time spend for step 3 : 0.24199867248535156 step4:send_mail_cod Tue Dec 23 01:38:59 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! complete output_args for input 2 : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} input_args_next_step : {1400627919: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627919 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627918 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627917 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627895 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627890 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627889 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627888 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627887 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627872 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627869 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627868 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627867 depend.output_id : 0 input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ()} output_args : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',)} args : 1400627865 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 : {29638070: [{'papier': 29638072, 'flou': 29638073, 'plastique': 29638074, 'metal': 29638075, 'cartonnette': 29638076, 'Teint_Dans_La_Masse': 29638077, 'environnement': 29638078, 'Carton_brun': 29638079, 'Carton_gris': 29638080, 'mal_croppe': 29638081, 'autre_refus': 29638082, 'kraft': 29638083}]} input_args_next_step : {1400627919: ('0.022169094897383262',), 1400627918: ('0.022169094897383262',), 1400627917: ('0.022169094897383262',), 1400627895: ('0.022169094897383262',), 1400627890: ('0.022169094897383262',), 1400627889: ('0.022169094897383262',), 1400627888: ('0.022169094897383262',), 1400627887: ('0.022169094897383262',), 1400627872: ('0.022169094897383262',), 1400627869: ('0.022169094897383262',), 1400627868: ('0.022169094897383262',), 1400627867: ('0.022169094897383262',), 1400627865: ('0.022169094897383262',), 29638070: ()} output_args : {29638070: [{'papier': 29638072, 'flou': 29638073, 'plastique': 29638074, 'metal': 29638075, 'cartonnette': 29638076, 'Teint_Dans_La_Masse': 29638077, 'environnement': 29638078, 'Carton_brun': 29638079, 'Carton_gris': 29638080, 'mal_croppe': 29638081, 'autre_refus': 29638082, 'kraft': 29638083}]} args : 29638070 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 :14, first value : ('0.022169094897383262',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (29638070) 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_view ph WHERE photo_id IN (1400627919,1400627918,1400627917,1400627895,1400627890,1400627889,1400627888,1400627887,1400627872,1400627869,1400627868,1400627867,1400627865) Found this number of photos: 13 ##### Call download_photos : nb_thread : 5 begin to download photo : 1400627865 begin to download photo : 1400627869 begin to download photo : 1400627888 begin to download photo : 1400627895 begin to download photo : 1400627919 download finish for photo 1400627888 begin to download photo : 1400627889 download finish for photo 1400627919 download finish for photo 1400627895 begin to download photo : 1400627917 download finish for photo 1400627865 begin to download photo : 1400627867 download finish for photo 1400627869 begin to download photo : 1400627872 download finish for photo 1400627889 begin to download photo : 1400627890 download finish for photo 1400627867 begin to download photo : 1400627868 download finish for photo 1400627872 begin to download photo : 1400627887 download finish for photo 1400627917 begin to download photo : 1400627918 download finish for photo 1400627890 download finish for photo 1400627868 download finish for photo 1400627918 download finish for photo 1400627887 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos imagette296380731766450339/ imagette296380741766450339/ imagette296380751766450339/ imagette296380761766450339/ imagette296380811766450339/ imagette296380821766450339/ length of list_filenames : 13 ; length of list_pids : 13 ; length of list_args : 13 results_Auto_P29638070_23-12-2025_01_38_59.pdf 29638073 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638073 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette296380731766450339 29638074 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638074 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette296380741766450339 29638075 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638075 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette296380751766450339 29638076 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638076 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette296380761766450339 29638081 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638081 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette296380811766450339 29638082 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638082 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette296380821766450339 29638083 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638083 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1400627899: '1766450225_57685_1400627848_c9a41eb00415809d85243aff6ad6e088_rle_crop_4078724001_0.png', 1400627915: '1766450246_58816_1400627844_2de2e783daed1984fadb32933d9d5c98_rle_crop_4078724069_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/24dd358720d24366b2078fc8dc6190de_60059331.png change filename to text .imagette296380831766450339/ imagette296380831766450339/1766450246_58816_1400627844_2de2e783daed1984fadb32933d9d5c98_rle_crop_4078724069_0.png.png imagette296380831766450339/1766450225_57685_1400627848_c9a41eb00415809d85243aff6ad6e088_rle_crop_4078724001_0.png.png wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/e19b40624b9f168d6400bdd294181d54_90326792.png imagette296380831766450339 29638077 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638077 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1400627896: '1766450225_57685_1400627848_c9a41eb00415809d85243aff6ad6e088_rle_crop_4078724003_0.png', 1400627912: '1766450246_58816_1400627844_2de2e783daed1984fadb32933d9d5c98_rle_crop_4078724071_0.png', 1400627913: '1766450246_58816_1400627844_2de2e783daed1984fadb32933d9d5c98_rle_crop_4078724083_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/8a0e823aea6d0a00754933a6380766a2_20935147.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/f01ee9ac048981418c8bab86eaad83af_9671048.png change filename to text .imagette296380771766450340/ imagette296380771766450340/1766450246_58816_1400627844_2de2e783daed1984fadb32933d9d5c98_rle_crop_4078724083_0.png.png imagette296380771766450340/1766450246_58816_1400627844_2de2e783daed1984fadb32933d9d5c98_rle_crop_4078724071_0.png.png imagette296380771766450340/1766450225_57685_1400627848_c9a41eb00415809d85243aff6ad6e088_rle_crop_4078724003_0.png.png wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/0d7966aa4422ea3b41d8979af99cd5c9_34152185.png imagette296380771766450340 29638079 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638079 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1400627914: '1766450246_58816_1400627846_58709eb50a79bb98c679a1ede9d531e3_rle_crop_4078724064_0.png'} change filename to text .imagette296380791766450340/ imagette296380791766450340/1766450246_58816_1400627846_58709eb50a79bb98c679a1ede9d531e3_rle_crop_4078724064_0.png.png imagette296380801766450340/ wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/63babdf4227cb15032c940d79d7ba045_961686.png imagette296380791766450340 29638080 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638080 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette296380801766450340 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=29638070 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://marlene.fotonower.com/velours/29638084,29638085,29638086,29638087,29638088,29638089,29638090,29638091,29638092,29638093,29638094,29638095?tags=papier,flou,plastique,metal,cartonnette,Teint_Dans_La_Masse,environnement,Carton_brun,Carton_gris,mal_croppe,autre_refus,kraft your option no_mail is active, we will not send the real mail to your client args[1400627919] : ('0.022169094897383262',) no score found for photo 1400627919 We are sending mail with results at report@fotonower.com args[1400627918] : ('0.022169094897383262',) no score found for photo 1400627918 We are sending mail with results at report@fotonower.com args[1400627917] : ('0.022169094897383262',) no score found for photo 1400627917 We are sending mail with results at report@fotonower.com args[1400627895] : ('0.022169094897383262',) no score found for photo 1400627895 We are sending mail with results at report@fotonower.com args[1400627890] : ('0.022169094897383262',) no score found for photo 1400627890 We are sending mail with results at report@fotonower.com args[1400627889] : ('0.022169094897383262',) no score found for photo 1400627889 We are sending mail with results at report@fotonower.com args[1400627888] : ('0.022169094897383262',) no score found for photo 1400627888 We are sending mail with results at report@fotonower.com args[1400627887] : ('0.022169094897383262',) no score found for photo 1400627887 We are sending mail with results at report@fotonower.com args[1400627872] : ('0.022169094897383262',) no score found for photo 1400627872 We are sending mail with results at report@fotonower.com args[1400627869] : ('0.022169094897383262',) no score found for photo 1400627869 We are sending mail with results at report@fotonower.com args[1400627868] : ('0.022169094897383262',) no score found for photo 1400627868 We are sending mail with results at report@fotonower.com args[1400627867] : ('0.022169094897383262',) no score found for photo 1400627867 We are sending mail with results at report@fotonower.com args[1400627865] : ('0.022169094897383262',) no score found for photo 1400627865 We are sending mail with results at report@fotonower.com refus_total : 0.022169094897383262 2022-04-13 10:29:59 0 SELECT ph.photo_id,ph.url,ph.username,ph.uploaded_at,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638070 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_P29638070_23-12-2025_01_38_59.pdf results_Auto_P29638070_23-12-2025_01_38_59.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29638070_23-12-2025_01_38_59.pdf start insert file to database insert into MTRUser.mtr_files (mtd_id,mtr_portfolio_id,text,url,format,tags,file_size,value) values ('4302','29638070','results_Auto_P29638070_23-12-2025_01_38_59.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29638070_23-12-2025_01_38_59.pdf','pdf','','0.12','0.022169094897383262') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([29638070]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865] map_info['map_portfolio_photo'] : {29638070: [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865, 1400627848, 1400627846, 1400627844, 1400627826, 1400627825, 1400627824, 1400627807]} final : False mtd_id 4302 list_pids : [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865] 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, '4260869') ('4302', '29638070', '1400627919', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627918', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627917', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627895', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627890', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627889', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627888', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627887', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627872', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627869', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627868', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627867', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627865', None, None, None, None, None, '4260869') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 13 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', '29638070', '1400627919', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627918', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627917', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627895', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627890', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627889', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627888', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627887', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627872', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627869', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627868', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627867', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627865', None, None, None, None, None, '4260869')] time used for this insertion : 0.015912771224975586 save_final save missing photos in datou_result : time spend for datou_step_exec : 2.2319889068603516 time spend to save output : 0.01617908477783203 total time spend for step 4 : 2.2481679916381836 step5:split_time_score Tue Dec 23 01:39:01 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : ['29638070'] 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 : [('29638070',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (29638070) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1400627919: {'path': 'temp/1766450339_3278332_1400627919_de2c46514933555886bd5da0f9afb3e4.jpg', 'extension': 'jpg'}, 1400627888: {'path': 'temp/1766450339_3278332_1400627888_6c0a483f9728e70a0240838907f8daf0.jpg', 'extension': 'jpg'}, 1400627889: {'path': 'temp/1766450339_3278332_1400627889_c9753feea8485736437f2ebf0fb5725a.jpg', 'extension': 'jpg'}, 1400627890: {'path': 'temp/1766450339_3278332_1400627890_31cb32c1dc8db99a8d5721426ca1f338.jpg', 'extension': 'jpg'}, 1400627865: {'path': 'temp/1766450339_3278332_1400627865_9c9d236ea3283a594b05f8989bd3de16.jpg', 'extension': 'jpg'}, 1400627867: {'path': 'temp/1766450339_3278332_1400627867_2b6b466c4f6e869c8e5c23669ee90fb4.jpg', 'extension': 'jpg'}, 1400627868: {'path': 'temp/1766450339_3278332_1400627868_466a0dcbed870a60de92b09302d795a7.jpg', 'extension': 'jpg'}, 1400627895: {'path': 'temp/1766450339_3278332_1400627895_e9a443f851b3228c725c4ef23ddd5ef3.jpg', 'extension': 'jpg'}, 1400627917: {'path': 'temp/1766450339_3278332_1400627917_ac8386f4968ced2d08fea7638a3a863f.jpg', 'extension': 'jpg'}, 1400627918: {'path': 'temp/1766450339_3278332_1400627918_0275e6da5564c1a9584ee55cf65bfed2.jpg', 'extension': 'jpg'}, 1400627869: {'path': 'temp/1766450339_3278332_1400627869_3d14f653d0a9a47cdc14cd68318e6907.jpg', 'extension': 'jpg'}, 1400627872: {'path': 'temp/1766450339_3278332_1400627872_40604254163e887834a12efd1c77ec05.jpg', 'extension': 'jpg'}, 1400627887: {'path': 'temp/1766450339_3278332_1400627887_ec4879dffdd7578c726bb82a6db29d8d.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 = 29638070; (('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_view ph on mpp.mtr_photo_id = ph.photo_id where mpp.mtr_portfolio_id = 29638070 group by h (('01', 20),) SELECT ph.photo_id,ph.url,ph.username,ph.uploaded_at,ph.text FROM MTRBack.photos_view ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=29638070 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 (29638070) 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 (29638070) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 23122025 29638070 Nombre de photos uploadées : 20 / 23040 (0%) 23122025 29638070 Nombre de photos taguées (types de déchets): 0 / 20 (0%) 23122025 29638070 Nombre de photos taguées (volume) : 0 / 20 (0%) [{'photo_id': 1400627807, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/36802357388a3669d02aa153586591ad.jpg', 'username': None, 'uploaded_at': 1766449987, 'text': 'image_23122025_01_31_54_9125.jpg'}, {'photo_id': 1400627826, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/de7f95b3350a222682699e8ba7b498f4.jpg', 'username': None, 'uploaded_at': 1766450048, 'text': 'image_23122025_01_32_04_10151.jpg'}, {'photo_id': 1400627825, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/63d52e2a8d2cd8b03a16d8b2cf68a401.jpg', 'username': None, 'uploaded_at': 1766450048, 'text': 'image_23122025_01_33_14_010138m0.jpg 1e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1400627824, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/12/23/a679693865ae5c0164326866f0b6aa0c.jpg', 'username': None, 'uploaded_at': 1766450048, 'text': 'image_23122025_01_33_24_010186m0.jpg 2e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}] 0 [] elapsed_time : load_data_split_time_score 7.152557373046875e-07 elapsed_time : order_list_meta_photo_and_scores 2.86102294921875e-06 ???????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.000507354736328125 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 29638070, '2025-12-23' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); Catched exception ! Connect or reconnect ! SELECT id FROM MTRPhoto.dashboard_entry_day where dashboard_place_id = 10 and date = '2025-12-23' ; INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (2776859,979,"{}"); Catched exception ! Connect or reconnect ! elapsed_time : insert_dashboard_record_day_entry 0.2364211082458496 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= 2776859 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 2776859, 'dashboard_run_id': 2783661, 'mtr_portfolio_id': 29636316, 'dashboard_result_id': 18636676, '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_P29636316_23-12-2025_00_20_59.pdf', 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29636321, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29636322, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29636323, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29636324, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29636325, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29636326, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29636327, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29636328, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29636329, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29636330, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29636331, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29636332, 'pht': 3726}}"}, {'dashboat_entry_day': 2776859, 'dashboard_run_id': 2783661, 'mtr_portfolio_id': 29636749, 'dashboard_result_id': 18636677, '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_P29636749_23-12-2025_00_33_30.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 29636751, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29636752, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29636753, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29636754, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29636755, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29636756, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29636757, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29636758, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29636759, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29636760, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29636761, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29636762, 'pht': 3726}}"}, {'dashboat_entry_day': 2776859, 'dashboard_run_id': 2783661, 'mtr_portfolio_id': 29637002, 'dashboard_result_id': 18636678, '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_P29637002_23-12-2025_00_46_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 29637006, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29637007, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29637008, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29637009, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29637010, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29637011, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29637012, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29637013, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29637014, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29637015, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29637016, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29637017, 'pht': 3726}}"}, {'dashboat_entry_day': 2776859, 'dashboard_run_id': 2783661, 'mtr_portfolio_id': 29637369, 'dashboard_result_id': 18636679, '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_P29637369_23-12-2025_01_03_30.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29637374, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29637375, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29637376, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29637377, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29637378, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29637379, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29637380, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29637381, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29637382, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29637383, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29637384, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29637385, 'pht': 3726}}"}, {'dashboat_entry_day': 2776859, 'dashboard_run_id': 2783661, 'mtr_portfolio_id': 29638070, 'dashboard_result_id': 18636680, '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_P29638070_23-12-2025_01_35_01.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 29638072, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29638073, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29638074, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29638075, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29638076, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29638077, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29638078, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29638079, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29638080, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29638081, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29638082, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29638083, 'pht': 3726}}"}] SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 29636316 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': 4260623, 'mtr_portfolio_id': 29636316, 'created_at': datetime.datetime(2025, 12, 23, 0, 20, 58), 'result': '0.040700966366868756', 'result_long': None, 'result_double': None}] Qualite : 0.040700966366868756 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 29636316 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29636316_23-12-2025_00_20_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 29636316 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_P29636316_23-12-2025_00_20_59.pdf', 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29636321, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29636322, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29636323, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29636324, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29636325, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29636326, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29636327, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29636328, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29636329, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29636330, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29636331, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29636332, 'pht': 3726}}" where mtr_portfolio_id = 29636316 and dashboard_run_id = 2783661 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`=29636316 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (18636676, 0.040700966366868756, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29636316_23-12-2025_00_20_59.pdf', 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29636321, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29636322, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29636323, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29636324, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29636325, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29636326, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29636327, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29636328, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29636329, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29636330, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29636331, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29636332, '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 = 29636749 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': 4260664, 'mtr_portfolio_id': 29636749, 'created_at': datetime.datetime(2025, 12, 23, 0, 33, 29), 'result': '0.19526065960367417', 'result_long': None, 'result_double': None}] Qualite : 0.19526065960367417 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 29636749 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29636749_23-12-2025_00_33_30.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 29636749 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_P29636749_23-12-2025_00_33_30.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 29636751, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29636752, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29636753, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29636754, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29636755, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29636756, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29636757, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29636758, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29636759, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29636760, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29636761, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29636762, 'pht': 3726}}" where mtr_portfolio_id = 29636749 and dashboard_run_id = 2783661 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`=29636749 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (18636677, 0.19526065960367417, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29636749_23-12-2025_00_33_30.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 29636751, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29636752, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29636753, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29636754, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29636755, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29636756, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29636757, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29636758, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29636759, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29636760, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29636761, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29636762, '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 = 29637002 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': 4260689, 'mtr_portfolio_id': 29637002, 'created_at': datetime.datetime(2025, 12, 23, 0, 46, 58), 'result': '0.06958774364948957', 'result_long': None, 'result_double': None}] Qualite : 0.06958774364948957 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 29637002 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29637002_23-12-2025_00_46_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 29637002 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_P29637002_23-12-2025_00_46_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 29637006, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29637007, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29637008, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29637009, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29637010, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29637011, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29637012, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29637013, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29637014, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29637015, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29637016, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29637017, 'pht': 3726}}" where mtr_portfolio_id = 29637002 and dashboard_run_id = 2783661 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`=29637002 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (18636678, 0.06958774364948957, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29637002_23-12-2025_00_46_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 29637006, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29637007, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29637008, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29637009, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29637010, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29637011, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29637012, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29637013, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29637014, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29637015, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29637016, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29637017, '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 = 29637369 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': 4260736, 'mtr_portfolio_id': 29637369, 'created_at': datetime.datetime(2025, 12, 23, 1, 3, 29), 'result': '0.0429940679226893', 'result_long': None, 'result_double': None}] Qualite : 0.0429940679226893 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 29637369 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29637369_23-12-2025_01_03_30.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 29637369 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_P29637369_23-12-2025_01_03_30.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29637374, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29637375, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29637376, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29637377, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29637378, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29637379, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29637380, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29637381, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29637382, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29637383, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29637384, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29637385, 'pht': 3726}}" where mtr_portfolio_id = 29637369 and dashboard_run_id = 2783663 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`=29637369 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (18636679, 0.0429940679226893, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29637369_23-12-2025_01_03_30.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29637374, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29637375, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29637376, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29637377, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29637378, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29637379, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29637380, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29637381, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29637382, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29637383, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29637384, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 29637385, '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 = 29638070 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': 4260869, 'mtr_portfolio_id': 29638070, 'created_at': datetime.datetime(2025, 12, 23, 1, 38, 59), 'result': '0.022169094897383262', 'result_long': None, 'result_double': None}] Qualite : 0.022169094897383262 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 29638070 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29638070_23-12-2025_01_38_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 29638070 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_P29638070_23-12-2025_01_38_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 29638072, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29638073, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29638074, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29638075, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29638076, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29638077, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29638078, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29638079, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29638080, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29638081, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29638082, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29638083, 'pht': 3726}}" where mtr_portfolio_id = 29638070 and dashboard_run_id = 2783663 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`=29638070 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (18636680, 0.022169094897383262, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P29638070_23-12-2025_01_38_59.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 29638072, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 29638073, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 29638074, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 29638075, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 29638076, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 29638077, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 29638078, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 29638079, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 29638080, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 29638081, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 29638082, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 29638083, 'pht': 3726}}") ON DUPLICATE KEY UPDATE qualite=VALUES(qualite), completion_json=VALUES(completion_json) ret update_qualite_results : None SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (29636316,29636749,29637002,29637369,29638070) result : ((1400619724,), (1400619761,), (1400619795,), (1400619831,), (1400620155,), (1400620158,), (1400620162,), (1400620784,), (1400620848,), (1400620936,), (1400620977,), (1400621034,), (1400621529,), (1400621566,), (1400621601,), (1400621636,), (1400621861,), (1400621863,), (1400621865,), (1400621868,), (1400621872,), (1400621875,), (1400621941,), (1400621976,), (1400622114,), (1400622141,), (1400622147,), (1400622251,), (1400622252,), (1400622253,), (1400622255,), (1400622259,), (1400622277,), (1400622278,), (1400622279,), (1400622280,), (1400622296,), (1400622298,), (1400622428,), (1400622430,), (1400622432,), (1400622437,), (1400622471,), (1400622495,), (1400622678,), (1400622679,), (1400622682,), (1400622714,), (1400622732,), (1400622737,), (1400622771,), (1400622774,), (1400623012,), (1400623007,), (1400623010,), (1400623033,), (1400623035,), (1400623053,), (1400623054,), (1400623217,), (1400623220,), (1400623223,), (1400623243,), (1400623246,), (1400623247,), (1400623249,), (1400623265,), (1400623267,), (1400623268,), (1400623270,), (1400623273,), (1400623310,), (1400623313,), (1400623339,), (1400623341,), (1400623344,), (1400623335,), (1400623337,), (1400623338,), (1400623362,), (1400623364,), (1400623365,), (1400623382,), (1400623384,), (1400623386,), (1400623388,), (1400623392,), (1400623395,), (1400623411,), (1400623413,), (1400623414,), (1400623428,), (1400623454,), (1400623455,), (1400623456,), (1400623458,), (1400623472,), (1400623474,), (1400623476,), (1400623494,), (1400623495,), (1400623496,), (1400623497,), (1400623500,), (1400623513,), (1400623514,), (1400623535,), (1400623536,), (1400623557,), (1400623559,), (1400623561,), (1400623565,), (1400623568,), (1400623570,), (1400623576,), (1400623579,), (1400623583,), (1400623584,), (1400623586,), (1400623588,), (1400623601,), (1400623604,), (1400623606,), (1400623609,), (1400623612,), (1400623620,), (1400623622,), (1400623623,), (1400623629,), (1400623632,), (1400623640,), (1400623643,), (1400623644,), (1400623650,), (1400623652,), (1400623655,), (1400623688,), (1400623686,), (1400623702,), (1400623703,), (1400623704,), (1400623706,), (1400623730,), (1400623731,), (1400623732,), (1400623734,), (1400623737,), (1400623754,), (1400623756,), (1400623758,), (1400623760,), (1400623779,), (1400623797,), (1400623799,), (1400623800,), (1400623801,), (1400623803,), (1400623804,), (1400623821,), (1400623822,), (1400623823,), (1400623825,), (1400623838,), (1400623839,), (1400623840,), (1400623842,), (1400623865,), (1400623867,), (1400623870,), (1400623871,), (1400623889,), (1400623891,), (1400623892,), (1400623893,), (1400623910,), (1400623911,), (1400623912,), (1400623929,), (1400623931,), (1400623934,), (1400623936,), (1400623955,), (1400623958,), (1400623959,), (1400623982,), (1400623986,), (1400623990,), (1400623995,), (1400623999,), (1400624341,), (1400624377,), (1400624410,), (1400624431,), (1400624434,), (1400624437,), (1400627807,), (1400627824,), (1400627825,), (1400627826,), (1400627844,), (1400627846,), (1400627848,), (1400627865,), (1400627867,), (1400627868,), (1400627869,), (1400627872,), (1400627887,), (1400627888,), (1400627889,), (1400627890,), (1400627895,), (1400627917,), (1400627918,), (1400627919,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'23122025': {'nb_upload': 20, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([29638070]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865] map_info['map_portfolio_photo'] : {29638070: [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865, 1400627848, 1400627846, 1400627844, 1400627826, 1400627825, 1400627824, 1400627807]} final : True mtd_id 4302 list_pids : [1400627919, 1400627918, 1400627917, 1400627895, 1400627890, 1400627889, 1400627888, 1400627887, 1400627872, 1400627869, 1400627868, 1400627867, 1400627865] Looping around the photos to save general results len do output : 1 /29638070Didn'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, '4260869') ('4302', '29638070', '1400627919', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627918', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627917', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627895', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627890', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627889', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627888', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627887', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627872', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627869', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627868', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627867', None, None, None, None, None, '4260869') ('4302', None, None, None, None, None, None, None, '4260869') ('4302', '29638070', '1400627865', None, None, None, None, None, '4260869') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 14 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, '29638070', 'None', None, None, None, None, '4260869'), ('4302', '29638070', '1400627919', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627918', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627917', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627895', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627890', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627889', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627888', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627887', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627872', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627869', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627868', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627867', None, None, None, None, None, '4260869'), ('4302', '29638070', '1400627865', None, None, None, None, None, '4260869')] time used for this insertion : 0.0187838077545166 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.6732087135314941 time spend to save output : 0.019000530242919922 total time spend for step 5 : 0.6922092437744141 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 (4260869) 2.02user 2.50system 0:07.75elapsed 58%CPU (0avgtext+0avgdata 167996maxresident)k 248inputs+7592outputs (0major+67401minor)pagefaults 0swaps