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 : 1710641 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 (2734893) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (2734893) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166636 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['2734893'] with mtr_portfolio_ids : ['22166636'] and first list_photo_ids : [] new path : /proc/1710641/ Name: python3 Umask: 0002 State: R (running) Tgid: 1710641 Ngid: 0 Pid: 1710641 PPid: 1710640 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 1710641 NSpid: 1710641 NSpgid: 1707827 NSsid: 1707827 VmPeak: 1106840 kB VmSize: 1106840 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 98764 kB VmRSS: 98764 kB RssAnon: 59756 kB RssFile: 39008 kB RssShmem: 0 kB VmData: 865588 kB VmStk: 132 kB VmExe: 2644 kB VmLib: 130468 kB VmPTE: 604 kB VmSwap: 0 kB HugetlbPages: 0 kB CoreDumping: 0 THP_enabled: 1 Threads: 1 SigQ: 0/63054 SigPnd: 0000000000000000 ShdPnd: 0000000000000000 SigBlk: 0000000000000000 SigIgn: 0000000001001000 SigCgt: 0000000180000002 CapInh: 0000000000000000 CapPrm: 0000000000000000 CapEff: 0000000000000000 CapBnd: 000001ffffffffff CapAmb: 0000000000000000 NoNewPrivs: 0 Seccomp: 0 Seccomp_filters: 0 Speculation_Store_Bypass: thread vulnerable SpeculationIndirectBranch: conditional enabled Cpus_allowed: ffffffff,ffffffff,ffffffff,ffffffff Cpus_allowed_list: 0-127 Mems_allowed: 00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001 Mems_allowed_list: 0 voluntary_ctxt_switches: 48 nonvoluntary_ctxt_switches: 93 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '1710641', 'Ngid': '0', 'Pid': '1710641', 'PPid': '1710640', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '1710641', 'NSpid': '1710641', 'NSpgid': '1707827', 'NSsid': '1707827', 'VmPeak': '1106840 kB', 'VmSize': '1106840 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '98764 kB', 'VmRSS': '98764 kB', 'RssAnon': '59756 kB', 'RssFile': '39008 kB', 'RssShmem': '0 kB', 'VmData': '865588 kB', 'VmStk': '132 kB', 'VmExe': '2644 kB', 'VmLib': '130468 kB', 'VmPTE': '604 kB', 'VmSwap': '0 kB', 'HugetlbPages': '0 kB', 'CoreDumping': '0', 'THP_enabled': '1', 'Threads': '1', 'SigQ': '0/63054', 'SigPnd': '0000000000000000', 'ShdPnd': '0000000000000000', 'SigBlk': '0000000000000000', 'SigIgn': '0000000001001000', 'SigCgt': '0000000180000002', 'CapInh': '0000000000000000', 'CapPrm': '0000000000000000', 'CapEff': '0000000000000000', 'CapBnd': '000001ffffffffff', 'CapAmb': '0000000000000000', 'NoNewPrivs': '0', 'Seccomp': '0', 'Seccomp_filters': '0', 'Speculation_Store_Bypass': 'thread vulnerable', 'SpeculationIndirectBranch': 'conditional enabled', 'Cpus_allowed': 'ffffffff,ffffffff,ffffffff,ffffffff', 'Cpus_allowed_list': '0-127', 'Mems_allowed': '00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001', 'Mems_allowed_list': '0', 'voluntary_ctxt_switches': '48', 'nonvoluntary_ctxt_switches': '93'} ('datou_batch_current', '1710641', '1106840', '0', '1106840', '865588', '98764', b'', 'marlene', '2734893') insert ignore into MTRAdmin.mem_info (script_name, PID, VMpeak,VMswap,VMsize,VMdata,VMrss,GPU_ram, hostname, mtr_current_id) VALUES (%s,%s,%s,%s,%s,%s,%s,%s,%s,%s) Inside batchDatouExec : verbose : True ##### chargement datou SELECT name, created_at,limit_max FROM MTRDatou.mtr_datou WHERE id=4302 SELECT mtd.id, mtdt.`type`, mtd.`param`, mtd.param_json, mtdt.nb_input, mtdt.nb_output, mtdt.prod, mtdt.is_local, mtdt.is_datou_depend, mtdt.is_photo_id_local FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_step_types mtdt WHERE mtdt.`id`=mtd.`type` AND mtd.mtd_id=4302 SELECT mtd.id, mtd.mtd_id, mdsdt.id, mdsdt.name, mdsdt.description, msid.output_or_input, msid.data_order_id, mdsdt.type FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_steptype_io_datatypes msid, MTRDatou.mtr_datou_step_data_types mdsdt WHERE mtd.`type`=msid.`mtr_datou_step_type` AND mtd.mtd_id= 4302 AND msid.data_type=mdsdt.id SELECT mts_id_output, id_output, mts_id_input, id_input FROM MTRDatou.mtr_datou_step_by_step WHERE mtd_id=4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! no param json to modify List Step Type Loaded in datou : ventilate_hashtags_in_portfolio, final, velours_tree, send_mail_cod, split_time_score over limit max, limiting to limit_max 200 list_input_json : [] ##### fin chargement datou ##### chargement data ##### Call load_data_input : nb_thread : 1 origin SELECT ph.photo_id, ph.url FROM MTRBack.photos ph WHERE ph.photo_id IN (SELECT mtr_photo_id from MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id in (22166636) 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 (2734893 ) ) 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 (22166636) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1350796734, 'portfolio_id': 22166636}, {'photo_id': 1350796688, 'portfolio_id': 22166636}, {'photo_id': 1350796684, 'portfolio_id': 22166636}, {'photo_id': 1350796530, 'portfolio_id': 22166636}, {'photo_id': 1350796515, 'portfolio_id': 22166636}, {'photo_id': 1350796509, 'portfolio_id': 22166636}, {'photo_id': 1350796501, 'portfolio_id': 22166636}, {'photo_id': 1350796489, 'portfolio_id': 22166636}, {'photo_id': 1350796343, 'portfolio_id': 22166636}, {'photo_id': 1350796332, 'portfolio_id': 22166636}, {'photo_id': 1350796057, 'portfolio_id': 22166636}, {'photo_id': 1350796053, 'portfolio_id': 22166636}, {'photo_id': 1350796046, 'portfolio_id': 22166636}, {'photo_id': 1350796042, 'portfolio_id': 22166636}, {'photo_id': 1350796030, 'portfolio_id': 22166636}, {'photo_id': 1350796026, 'portfolio_id': 22166636}, {'photo_id': 1350795877, 'portfolio_id': 22166636}, {'photo_id': 1350795872, 'portfolio_id': 22166636}, {'photo_id': 1350795870, 'portfolio_id': 22166636}, {'photo_id': 1350795852, 'portfolio_id': 22166636}, {'photo_id': 1350795723, 'portfolio_id': 22166636}, {'photo_id': 1350795715, 'portfolio_id': 22166636}, {'photo_id': 1350795711, 'portfolio_id': 22166636}, {'photo_id': 1350795707, 'portfolio_id': 22166636}, {'photo_id': 1350795680, 'portfolio_id': 22166636}, {'photo_id': 1350795676, 'portfolio_id': 22166636}, {'photo_id': 1350795673, 'portfolio_id': 22166636}, {'photo_id': 1350795669, 'portfolio_id': 22166636}, {'photo_id': 1350795664, 'portfolio_id': 22166636}, {'photo_id': 1350795660, 'portfolio_id': 22166636}, {'photo_id': 1350795512, 'portfolio_id': 22166636}, {'photo_id': 1350795504, 'portfolio_id': 22166636}, {'photo_id': 1350795493, 'portfolio_id': 22166636}, {'photo_id': 1350795482, 'portfolio_id': 22166636}, {'photo_id': 1350795478, 'portfolio_id': 22166636}, {'photo_id': 1350795424, 'portfolio_id': 22166636}, {'photo_id': 1350795388, 'portfolio_id': 22166636}, {'photo_id': 1350795352, 'portfolio_id': 22166636}, {'photo_id': 1350795338, 'portfolio_id': 22166636}, {'photo_id': 1350795193, 'portfolio_id': 22166636}, {'photo_id': 1350795182, 'portfolio_id': 22166636}, {'photo_id': 1350795179, 'portfolio_id': 22166636}, {'photo_id': 1350795142, 'portfolio_id': 22166636}] map_portfolio_id_photo_id: {22166636: [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489, 1350796343, 1350796332, 1350796057, 1350796053, 1350796046, 1350796042, 1350796030, 1350796026, 1350795877, 1350795872, 1350795870, 1350795852, 1350795723, 1350795715, 1350795711, 1350795707, 1350795680, 1350795676, 1350795673, 1350795669, 1350795664, 1350795660, 1350795512, 1350795504, 1350795493, 1350795482, 1350795478, 1350795424, 1350795388, 1350795352, 1350795338, 1350795193, 1350795182, 1350795179, 1350795142]} ##### 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.01620316505432129 #### 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 Wed Apr 9 15:42:56 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 (22166636) 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 : 22166636 get user id for portfolio 22166636 get sub ptf for main ptf 22166636, type 3726 and hashtags ['papier', 'metal', 'flou', 'environnement', 'kraft', 'mal_croppe', 'Teint_Dans_La_Masse', 'autre_refus', 'Carton_gris', 'cartonnette', 'plastique', 'Carton_brun'] SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22166636 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('papier','metal','flou','environnement','kraft','mal_croppe','Teint_Dans_La_Masse','autre_refus','Carton_gris','cartonnette','plastique','Carton_brun')) AND mptpi.`min_score`=0.5 SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22166636 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('papier','metal','flou','environnement','kraft','mal_croppe','Teint_Dans_La_Masse','autre_refus','Carton_gris','cartonnette','plastique','Carton_brun')) AND mptpi.`min_score`=0.5 To do returned map {'autre_refus': {'main_port_id': 22166636, 'sub_port_id': 22166639, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642577, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'metal': {'main_port_id': 22166636, 'sub_port_id': 22166640, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642578, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'kraft': {'main_port_id': 22166636, 'sub_port_id': 22166641, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642579, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'mal_croppe': {'main_port_id': 22166636, 'sub_port_id': 22166642, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642580, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'environnement': {'main_port_id': 22166636, 'sub_port_id': 22166643, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642581, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'Carton_gris': {'main_port_id': 22166636, 'sub_port_id': 22166644, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642582, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'flou': {'main_port_id': 22166636, 'sub_port_id': 22166645, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642583, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'papier': {'main_port_id': 22166636, 'sub_port_id': 22166646, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642584, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'Teint_Dans_La_Masse': {'main_port_id': 22166636, 'sub_port_id': 22166647, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642585, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'plastique': {'main_port_id': 22166636, 'sub_port_id': 22166648, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642586, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'Carton_brun': {'main_port_id': 22166636, 'sub_port_id': 22166649, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642587, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}, 'cartonnette': {'main_port_id': 22166636, 'sub_port_id': 22166650, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642588, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 34, 59)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22166639 , 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=22166636 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 (22166639) result : ((1350795569,), (1350795571,), (1350796118,), (1350796440,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166640 , 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=22166636 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 (22166640) result : ((1350796741,),) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166641 , 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=22166636 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 (22166641) result : ((1350795640,), (1350796125,), (1350796446,), (1350796447,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166642 , 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=22166636 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 (22166642) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166643 , 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=22166636 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 (22166643) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166644 , 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=22166636 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 (22166644) result : ((1350795637,), (1350795768,), (1350795861,), (1350796120,), (1350796121,), (1350796122,), (1350796123,), (1350796441,), (1350796442,), (1350796460,), (1350796461,), (1350796462,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166645 , 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=22166636 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 (22166645) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166646 , 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=22166636 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 (22166646) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166647 , 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=22166636 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 (22166647) result : ((1350795544,), (1350795546,), (1350795547,), (1350795549,), (1350795550,), (1350795860,), (1350796116,), (1350796117,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166648 , 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=22166636 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 (22166648) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166649 , 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=22166636 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 (22166649) result : ((1350795638,), (1350795639,), (1350795770,), (1350795771,), (1350795865,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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 22166650 , 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=22166636 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 (22166650) result : ((1350795769,), (1350795864,), (1350796085,), (1350796444,), (1350796445,), (1350796470,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22166636) result : ((1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) 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`=22166636 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('papier','metal','flou','environnement','kraft','mal_croppe','Teint_Dans_La_Masse','autre_refus','Carton_gris','cartonnette','plastique','Carton_brun')) AND mptpi.`min_score`=0.5 SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22166636 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('papier','metal','flou','environnement','kraft','mal_croppe','Teint_Dans_La_Masse','autre_refus','Carton_gris','cartonnette','plastique','Carton_brun')) AND mptpi.`min_score`=0.5 To do returned map {'autre_refus': {'main_port_id': 22166636, 'sub_port_id': 22166651, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642589, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'metal': {'main_port_id': 22166636, 'sub_port_id': 22166652, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642590, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'kraft': {'main_port_id': 22166636, 'sub_port_id': 22166653, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642591, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'mal_croppe': {'main_port_id': 22166636, 'sub_port_id': 22166654, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642592, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'environnement': {'main_port_id': 22166636, 'sub_port_id': 22166655, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642593, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'Carton_gris': {'main_port_id': 22166636, 'sub_port_id': 22166656, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642594, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'flou': {'main_port_id': 22166636, 'sub_port_id': 22166657, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642595, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'papier': {'main_port_id': 22166636, 'sub_port_id': 22166658, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642596, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'Teint_Dans_La_Masse': {'main_port_id': 22166636, 'sub_port_id': 22166659, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642597, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'plastique': {'main_port_id': 22166636, 'sub_port_id': 22166660, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642598, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'Carton_brun': {'main_port_id': 22166636, 'sub_port_id': 22166661, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642599, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 35, 1), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}, 'cartonnette': {'main_port_id': 22166636, 'sub_port_id': 22166662, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14642600, 'last_updated_at': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_desc': datetime.datetime(2025, 4, 9, 15, 41), 'last_updated_at_asc': datetime.datetime(2025, 4, 9, 15, 35, 1)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166651,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166639 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166652,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166640 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166653,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166641 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166654,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166642 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166655,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166643 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166656,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166644 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166657,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166645 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166658,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166646 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166659,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166647 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166660,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166648 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166661,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166649 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22166662,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22166650 lien utilise dans velours : https://www.fotonower.com/velours/22166651,22166652,22166653,22166654,22166655,22166656,22166657,22166658,22166659,22166660,22166661,22166662?tags=autre_refus,metal,kraft,mal_croppe,environnement,Carton_gris,flou,papier,Teint_Dans_La_Masse,plastique,Carton_brun,cartonnette After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22166636]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489] map_info['map_portfolio_photo'] : {22166636: [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489, 1350796343, 1350796332, 1350796057, 1350796053, 1350796046, 1350796042, 1350796030, 1350796026, 1350795877, 1350795872, 1350795870, 1350795852, 1350795723, 1350795715, 1350795711, 1350795707, 1350795680, 1350795676, 1350795673, 1350795669, 1350795664, 1350795660, 1350795512, 1350795504, 1350795493, 1350795482, 1350795478, 1350795424, 1350795388, 1350795352, 1350795338, 1350795193, 1350795182, 1350795179, 1350795142]} final : False mtd_id 4302 list_pids : [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489] Looping around the photos to save general results len do output : 1 /22166636. 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, '2734893') ('4302', '22166636', '1350796734', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796688', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796684', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796530', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796515', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796509', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796501', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796489', None, None, None, None, None, '2734893') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 9 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, '22166636', "{'autre_refus': 22166639, 'metal': 22166640, 'kraft': 22166641, 'mal_croppe': 22166642, 'environnement': 22166643, 'Carton_gris': 22166644, 'flou': 22166645, 'papier': 22166646, 'Teint_Dans_La_Masse': 22166647, 'plastique': 22166648, 'Carton_brun': 22166649, 'cartonnette': 22166650}", None, None, None, None, '2734893'), ('4302', '22166636', '1350796734', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796688', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796684', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796530', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796515', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796509', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796501', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796489', None, None, None, None, None, '2734893')] time used for this insertion : 0.01327061653137207 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.3958995342254639 time spend to save output : 0.013557195663452148 total time spend for step 1 : 1.409456729888916 step2:final Wed Apr 9 15:42:58 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :0, first value : [] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22166636) 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 22166636 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1350795193,1350795182,1350795179,1350795142,1350795424,1350795388,1350795352,1350795338,1350795512,1350795504,1350795493,1350795482,1350795478,1350795680,1350795676,1350795673,1350795669,1350795664,1350795660,1350795723,1350795715,1350795711,1350795707,1350795877,1350795852,1350795872,1350795870,1350796057,1350796053,1350796046,1350796042,1350796030,1350796026,1350796343,1350796332,1350796530,1350796515,1350796509,1350796501,1350796489,1350796734,1350796688,1350796684); 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([22166636]) Inside saveOutput : final : False verbose : True original output for save of step final : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} new output for save of step final : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489] map_info['map_portfolio_photo'] : {22166636: [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489, 1350796343, 1350796332, 1350796057, 1350796053, 1350796046, 1350796042, 1350796030, 1350796026, 1350795877, 1350795872, 1350795870, 1350795852, 1350795723, 1350795715, 1350795711, 1350795707, 1350795680, 1350795676, 1350795673, 1350795669, 1350795664, 1350795660, 1350795512, 1350795504, 1350795493, 1350795482, 1350795478, 1350795424, 1350795388, 1350795352, 1350795338, 1350795193, 1350795182, 1350795179, 1350795142]} final : False mtd_id 4302 list_pids : [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489] Looping around the photos to save general results len do output : 8 /1350796734.Didn't retrieve data . /1350796688.Didn't retrieve data . /1350796684.Didn't retrieve data . /1350796530.Didn't retrieve data . /1350796515.Didn't retrieve data . /1350796509.Didn't retrieve data . /1350796501.Didn't retrieve data . /1350796489.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, '2734893') ('4302', '22166636', '1350796734', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796688', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796684', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796530', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796515', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796509', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796501', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796489', None, None, None, None, None, '2734893') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 24 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', '22166636', '1350796734', '0.03714201882270479', None, None, None, None, '2734893'), ('4302', '22166636', '1350796688', '0.03714201882270479', None, None, None, None, '2734893'), ('4302', '22166636', '1350796684', '0.03714201882270479', None, None, None, None, '2734893'), ('4302', '22166636', '1350796530', '0.03714201882270479', None, None, None, None, '2734893'), ('4302', '22166636', '1350796515', '0.03714201882270479', None, None, None, None, '2734893'), ('4302', '22166636', '1350796509', '0.03714201882270479', None, None, None, None, '2734893'), ('4302', '22166636', '1350796501', '0.03714201882270479', None, None, None, None, '2734893'), ('4302', '22166636', '1350796489', '0.03714201882270479', None, None, None, None, '2734893')] time used for this insertion : 0.013936281204223633 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.09155988693237305 time spend to save output : 0.01441502571105957 total time spend for step 2 : 0.10597491264343262 step3:velours_tree Wed Apr 9 15:42:58 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : {22166636: [{'autre_refus': 22166639, 'metal': 22166640, 'kraft': 22166641, 'mal_croppe': 22166642, 'environnement': 22166643, 'Carton_gris': 22166644, 'flou': 22166645, 'papier': 22166646, 'Teint_Dans_La_Masse': 22166647, 'plastique': 22166648, 'Carton_brun': 22166649, 'cartonnette': 22166650}]} input_args_next_step : {22166636: ()} output_args : {22166636: [{'autre_refus': 22166639, 'metal': 22166640, 'kraft': 22166641, 'mal_croppe': 22166642, 'environnement': 22166643, 'Carton_gris': 22166644, 'flou': 22166645, 'papier': 22166646, 'Teint_Dans_La_Masse': 22166647, 'plastique': 22166648, 'Carton_brun': 22166649, 'cartonnette': 22166650}]} args : 22166636 depend.output_id : 0 VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :1, first value : ({'autre_refus': 22166639, 'metal': 22166640, 'kraft': 22166641, 'mal_croppe': 22166642, 'environnement': 22166643, 'Carton_gris': 22166644, 'flou': 22166645, 'papier': 22166646, 'Teint_Dans_La_Masse': 22166647, 'plastique': 22166648, 'Carton_brun': 22166649, 'cartonnette': 22166650},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22166636) 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([22166636]) 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.32408571243286133 time spend to save output : 5.412101745605469e-05 total time spend for step 3 : 0.3241398334503174 step4:send_mail_cod Wed Apr 9 15:42:58 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! complete output_args for input 2 : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} input_args_next_step : {1350796734: ()} output_args : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} args : 1350796734 depend.output_id : 0 input_args_next_step : {1350796734: ('0.03714201882270479',), 1350796688: ()} output_args : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} args : 1350796688 depend.output_id : 0 input_args_next_step : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ()} output_args : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} args : 1350796684 depend.output_id : 0 input_args_next_step : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ()} output_args : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} args : 1350796530 depend.output_id : 0 input_args_next_step : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ()} output_args : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} args : 1350796515 depend.output_id : 0 input_args_next_step : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ()} output_args : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} args : 1350796509 depend.output_id : 0 input_args_next_step : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ()} output_args : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} args : 1350796501 depend.output_id : 0 input_args_next_step : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ()} output_args : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',)} args : 1350796489 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 : {22166636: [{'autre_refus': 22166639, 'metal': 22166640, 'kraft': 22166641, 'mal_croppe': 22166642, 'environnement': 22166643, 'Carton_gris': 22166644, 'flou': 22166645, 'papier': 22166646, 'Teint_Dans_La_Masse': 22166647, 'plastique': 22166648, 'Carton_brun': 22166649, 'cartonnette': 22166650}]} input_args_next_step : {1350796734: ('0.03714201882270479',), 1350796688: ('0.03714201882270479',), 1350796684: ('0.03714201882270479',), 1350796530: ('0.03714201882270479',), 1350796515: ('0.03714201882270479',), 1350796509: ('0.03714201882270479',), 1350796501: ('0.03714201882270479',), 1350796489: ('0.03714201882270479',), 22166636: ()} output_args : {22166636: [{'autre_refus': 22166639, 'metal': 22166640, 'kraft': 22166641, 'mal_croppe': 22166642, 'environnement': 22166643, 'Carton_gris': 22166644, 'flou': 22166645, 'papier': 22166646, 'Teint_Dans_La_Masse': 22166647, 'plastique': 22166648, 'Carton_brun': 22166649, 'cartonnette': 22166650}]} args : 22166636 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 :9, first value : ('0.03714201882270479',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22166636) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} dans la step send mail cod work_area: /home/admin/workarea/git/Velours/python in order to get the selector url, please entre the license of selector SELECT photo_id, url FROM MTRBack.photos ph WHERE photo_id IN (1350796734,1350796688,1350796684,1350796530,1350796515,1350796509,1350796501,1350796489) Found this number of photos: 8 ##### Call download_photos : nb_thread : 5 begin to download photo : 1350796489 begin to download photo : 1350796509 begin to download photo : 1350796530 begin to download photo : 1350796688 download finish for photo 1350796530 begin to download photo : 1350796684 download finish for photo 1350796688 begin to download photo : 1350796734 download finish for photo 1350796509 begin to download photo : 1350796515 download finish for photo 1350796489 begin to download photo : 1350796501 download finish for photo 1350796684 download finish for photo 1350796734 download finish for photo 1350796515 download finish for photo 1350796501 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos length of list_filenames : 8 ; length of list_pids : 8 ; length of list_args : 8 results_Auto_P22166636_09-04-2025_15_42_58.pdf 22166639 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166639 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1350795569: '1744205594_2832356_1350795193_acd7d663468425d870054e8aea57bbd7_rle_crop_3751649037_0.png', 1350795571: '1744205594_2832356_1350795142_a5430d48bb87714756dfaff9e3a8beb7_rle_crop_3751649120_0.png', 1350796118: '1744205846_2433318_1350795676_dd6b4c811356203e450357c85280929e_rle_crop_3751651017_0.png', 1350796440: '1744205953_2835654_1350796053_beb8b7934aca4cee23310755595e7cf7_rle_crop_3751653933_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/14e1f59316105cf6177c64bc73494787_13762792.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/2ae7fbcc1b3863e44f9db57183834162_23697071.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/367006b23f7998aa16fe01ddbc1c053d_21608644.png change filename to text .imagette221666391744206178/ imagette221666391744206178/1744205846_2433318_1350795676_dd6b4c811356203e450357c85280929e_rle_crop_3751651017_0.png.png imagette221666391744206178/1744205953_2835654_1350796053_beb8b7934aca4cee23310755595e7cf7_rle_crop_3751653933_0.png.png imagette221666391744206178/1744205594_2832356_1350795193_acd7d663468425d870054e8aea57bbd7_rle_crop_3751649037_0.png.png imagette221666391744206178/1744205594_2832356_1350795142_a5430d48bb87714756dfaff9e3a8beb7_rle_crop_3751649120_0.png.png wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/c4ed1b4b8c4da40f134af99a5fba15fc_85189653.png imagette221666391744206178 22166640 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166640 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1350796741: '1744206062_2837174_1350796343_6faa314c12bbd768ef41f14b16cec4ce_rle_crop_3751656469_0.png'} change filename to text .imagette221666401744206179/ imagette221666401744206179/1744206062_2837174_1350796343_6faa314c12bbd768ef41f14b16cec4ce_rle_crop_3751656469_0.png.png wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/86f8d16f4a460c0f8cea4f83f7c9aafd_97466960.png imagette221666401744206179 22166641 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166641 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1350795640: '1744205594_2832356_1350795179_d69694b35848da47c47fc391e49ba29d_rle_crop_3751649099_0.png', 1350796125: '1744205846_2433318_1350795664_6851fa428d9eac8a842eb130565024cd_rle_crop_3751651063_0.png', 1350796446: '1744205953_2835654_1350796046_719cd6aa9e2d9625edae60f51ee9481f_rle_crop_3751653953_0.png', 1350796447: '1744205953_2835654_1350796046_719cd6aa9e2d9625edae60f51ee9481f_rle_crop_3751653959_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/8644cbb2c81ef8d4e9b08f43b24d757e_15087317.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/62ff9932785fd96c47e152021afae49a_52328906.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/03bb4a92e99a4dc9b99f5faee6284a5a_46653942.png change filename to text .imagette221666411744206179/ imagette221666411744206179/1744205953_2835654_1350796046_719cd6aa9e2d9625edae60f51ee9481f_rle_crop_3751653959_0.png.png imagette221666411744206179/1744205953_2835654_1350796046_719cd6aa9e2d9625edae60f51ee9481f_rle_crop_3751653953_0.png.png imagette221666411744206179/1744205846_2433318_1350795664_6851fa428d9eac8a842eb130565024cd_rle_crop_3751651063_0.png.png imagette221666411744206179/1744205594_2832356_1350795179_d69694b35848da47c47fc391e49ba29d_rle_crop_3751649099_0.png.png imagette221666421744206179/ imagette221666451744206179/ imagette221666481744206179/ wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/ee6cb5b797e94420dfcbb173a942ae9e_70701829.png imagette221666411744206179 22166642 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166642 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette221666421744206179 22166645 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166645 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette221666451744206179 22166648 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166648 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette221666481744206179 22166650 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166650 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1350795769: '1744205712_2833493_1350795388_0db0a3673e1e0d1f1179cf769b831962_rle_crop_3751649686_0.png', 1350795864: '1744205732_2833722_1350795482_3ed1173e5f45a7998c8c02ffb98be7e5_rle_crop_3751649927_0.png', 1350796085: '1744205845_2942300_1350795711_1bc30f060263570c672660cc1809138b_rle_crop_3751650986_0.png', 1350796444: '1744205953_2835654_1350796030_e28bd83f7513946a229fad68121b61f9_rle_crop_3751654036_0.png', 1350796445: '1744205953_2835654_1350796030_e28bd83f7513946a229fad68121b61f9_rle_crop_3751654038_0.png', 1350796470: '1744205972_2835903_1350796057_cefb0ab126a4b56ccf56c91a071a485c_rle_crop_3751654069_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/145edc397d21a7a6159a825dcb9450d3_9767027.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/cd2e785f1b0552d994b4353a3d0cf3aa_89681876.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/5f779020d0e274e0beb5df9347215897_27890744.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/ae6683cd6a182c2f6a682922012391e1_52342038.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/6960b2bcd66e4308a821e93b99de8c0e_23817653.png change filename to text .imagette221666501744206179/ imagette221666501744206179/1744205953_2835654_1350796030_e28bd83f7513946a229fad68121b61f9_rle_crop_3751654038_0.png.png imagette221666501744206179/1744205732_2833722_1350795482_3ed1173e5f45a7998c8c02ffb98be7e5_rle_crop_3751649927_0.png.png imagette221666501744206179/1744205953_2835654_1350796030_e28bd83f7513946a229fad68121b61f9_rle_crop_3751654036_0.png.png imagette221666501744206179/1744205845_2942300_1350795711_1bc30f060263570c672660cc1809138b_rle_crop_3751650986_0.png.png imagette221666501744206179/1744205972_2835903_1350796057_cefb0ab126a4b56ccf56c91a071a485c_rle_crop_3751654069_0.png.png imagette221666501744206179/1744205712_2833493_1350795388_0db0a3673e1e0d1f1179cf769b831962_rle_crop_3751649686_0.png.png wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/a6d7537da3d1a4dfddd37e482a46b446_63470034.png imagette221666501744206179 22166644 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166644 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1350795637: '1744205594_2832356_1350795193_acd7d663468425d870054e8aea57bbd7_rle_crop_3751649041_0.png', 1350795768: '1744205712_2833493_1350795338_026edf6dc0adf3e8cf2502bd7686b86c_rle_crop_3751649711_0.png', 1350795861: '1744205732_2833722_1350795478_c5fc5121d2ff37a76d4ebeb1b5f1498f_rle_crop_3751649938_0.png', 1350796120: '1744205846_2433318_1350795723_b56604d69b79fd8de29c7a2299ca3bee_rle_crop_3751651002_0.png', 1350796121: '1744205846_2433318_1350795676_dd6b4c811356203e450357c85280929e_rle_crop_3751651019_0.png', 1350796122: '1744205846_2433318_1350795673_aff9e4a4f80a40a6cf1692d6155aa7a9_rle_crop_3751651035_0.png', 1350796123: '1744205846_2433318_1350795669_dc067a706855721975dd37829cdf0d50_rle_crop_3751651054_0.png', 1350796441: '1744205953_2835654_1350796046_719cd6aa9e2d9625edae60f51ee9481f_rle_crop_3751653955_0.png', 1350796442: '1744205953_2835654_1350796030_e28bd83f7513946a229fad68121b61f9_rle_crop_3751654042_0.png', 1350796460: '1744205972_2835903_1350796057_cefb0ab126a4b56ccf56c91a071a485c_rle_crop_3751654072_0.png', 1350796461: '1744205972_2835903_1350796057_cefb0ab126a4b56ccf56c91a071a485c_rle_crop_3751654063_0.png', 1350796462: '1744205972_2835903_1350795870_77d65b924b4a60bab3250cde5eeccef1_rle_crop_3751654086_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/5dd14830695f89c40666e1e6b1c03727_35408622.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/fd3b4a2651774e223c5dd1824c5b8972_16176663.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/85e5e921cc1839aaf995ef3c69315391_6337278.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/d318bdd5fb9f4d3290d9accd68c047e8_5981738.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/2b604a1a58c9590d938e059fc0532991_64641099.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/9ea476e64771d20fb7c0f20255a0a673_56401017.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/eb1ac5cfb02b05d4f55ac15be4ecfc91_52301615.png change filename to text .wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/5221dc3433b4e322467c53335c004276_8980604.png change filename to text .wget -O 9.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/39ef4b2b4412808dc2bd7be24e59e4d6_75310901.png change filename to text .wget -O 10.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/ee4f8020fa4993064fdbff55f84ff009_63432154.png change filename to text .wget -O 11.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/1aeb70681fd84d6fe7054b7551a57ab0_62235335.png change filename to text .imagette221666441744206179/ imagette221666441744206179/1744205846_2433318_1350795669_dc067a706855721975dd37829cdf0d50_rle_crop_3751651054_0.png.png imagette221666441744206179/1744205732_2833722_1350795478_c5fc5121d2ff37a76d4ebeb1b5f1498f_rle_crop_3751649938_0.png.png imagette221666441744206179/1744205594_2832356_1350795193_acd7d663468425d870054e8aea57bbd7_rle_crop_3751649041_0.png.png imagette221666441744206179/1744205846_2433318_1350795723_b56604d69b79fd8de29c7a2299ca3bee_rle_crop_3751651002_0.png.png imagette221666441744206179/1744205953_2835654_1350796046_719cd6aa9e2d9625edae60f51ee9481f_rle_crop_3751653955_0.png.png imagette221666441744206179/1744205972_2835903_1350795870_77d65b924b4a60bab3250cde5eeccef1_rle_crop_3751654086_0.png.png imagette221666441744206179/1744205846_2433318_1350795673_aff9e4a4f80a40a6cf1692d6155aa7a9_rle_crop_3751651035_0.png.png imagette221666441744206179/1744205846_2433318_1350795676_dd6b4c811356203e450357c85280929e_rle_crop_3751651019_0.png.png imagette221666441744206179/1744205953_2835654_1350796030_e28bd83f7513946a229fad68121b61f9_rle_crop_3751654042_0.png.png imagette221666441744206179/1744205972_2835903_1350796057_cefb0ab126a4b56ccf56c91a071a485c_rle_crop_3751654063_0.png.png imagette221666441744206179/1744205712_2833493_1350795338_026edf6dc0adf3e8cf2502bd7686b86c_rle_crop_3751649711_0.png.png imagette221666441744206179/1744205972_2835903_1350796057_cefb0ab126a4b56ccf56c91a071a485c_rle_crop_3751654072_0.png.png wget -O 12.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/e7ce9bb1417a0a674c81d746f5060e9e_36475869.png imagette221666441744206179 22166647 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166647 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1350795544: '1744205594_2832356_1350795193_acd7d663468425d870054e8aea57bbd7_rle_crop_3751649038_0.png', 1350795546: '1744205594_2832356_1350795179_d69694b35848da47c47fc391e49ba29d_rle_crop_3751649100_0.png', 1350795547: '1744205594_2832356_1350795179_d69694b35848da47c47fc391e49ba29d_rle_crop_3751649103_0.png', 1350795549: '1744205594_2832356_1350795142_a5430d48bb87714756dfaff9e3a8beb7_rle_crop_3751649123_0.png', 1350795550: '1744205594_2832356_1350795142_a5430d48bb87714756dfaff9e3a8beb7_rle_crop_3751649116_0.png', 1350795860: '1744205732_2833722_1350795478_c5fc5121d2ff37a76d4ebeb1b5f1498f_rle_crop_3751649941_0.png', 1350796116: '1744205846_2433318_1350795673_aff9e4a4f80a40a6cf1692d6155aa7a9_rle_crop_3751651041_0.png', 1350796117: '1744205846_2433318_1350795660_d26fec2b30160d459a710a2fe6e34fbb_rle_crop_3751651077_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/9f600956b55a54132d02d9f95e39256a_40949808.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/2fdbca527ed2aee9d2329793e1ba517d_13218702.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/65741585bdc56ae7362f2bd525efe698_50921680.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/407177fcd9fdec318642677f978219f6_91781931.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/43a81dc7c5c47f8be738aafcd358a8a9_21701839.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/6804d0d965676decc6a3ae1504e43af3_68872127.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/69fb10a34487544e0dd01977599ecb1e_97241398.png change filename to text .imagette221666471744206180/ imagette221666471744206180/1744205594_2832356_1350795142_a5430d48bb87714756dfaff9e3a8beb7_rle_crop_3751649123_0.png.png imagette221666471744206180/1744205594_2832356_1350795179_d69694b35848da47c47fc391e49ba29d_rle_crop_3751649100_0.png.png imagette221666471744206180/1744205594_2832356_1350795193_acd7d663468425d870054e8aea57bbd7_rle_crop_3751649038_0.png.png imagette221666471744206180/1744205846_2433318_1350795673_aff9e4a4f80a40a6cf1692d6155aa7a9_rle_crop_3751651041_0.png.png imagette221666471744206180/1744205732_2833722_1350795478_c5fc5121d2ff37a76d4ebeb1b5f1498f_rle_crop_3751649941_0.png.png imagette221666471744206180/1744205594_2832356_1350795179_d69694b35848da47c47fc391e49ba29d_rle_crop_3751649103_0.png.png imagette221666471744206180/1744205846_2433318_1350795660_d26fec2b30160d459a710a2fe6e34fbb_rle_crop_3751651077_0.png.png imagette221666471744206180/1744205594_2832356_1350795142_a5430d48bb87714756dfaff9e3a8beb7_rle_crop_3751649116_0.png.png wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/55c44726a58f277ef9f81022a621cb23_60935635.png imagette221666471744206180 22166649 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166649 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1350795638: '1744205594_2832356_1350795193_acd7d663468425d870054e8aea57bbd7_rle_crop_3751649039_0.png', 1350795639: '1744205594_2832356_1350795182_5a8887a60bd9cf9152dde1349a86490a_rle_crop_3751649072_0.png', 1350795770: '1744205712_2833493_1350795388_0db0a3673e1e0d1f1179cf769b831962_rle_crop_3751649689_0.png', 1350795771: '1744205712_2833493_1350795338_026edf6dc0adf3e8cf2502bd7686b86c_rle_crop_3751649716_0.png', 1350795865: '1744205732_2833722_1350795478_c5fc5121d2ff37a76d4ebeb1b5f1498f_rle_crop_3751649944_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/d697257fca65f5a4e91967aac65cc8bf_70731109.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/9287a0636cd7c63eae0228e6bcf977f1_89207386.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/0f2aaea977c6151287b7d106b4bbca3e_86273288.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/4bd59f059d746b9e623ae5739707f376_49360325.png change filename to text .imagette221666491744206180/ imagette221666491744206180/1744205712_2833493_1350795388_0db0a3673e1e0d1f1179cf769b831962_rle_crop_3751649689_0.png.png imagette221666491744206180/1744205732_2833722_1350795478_c5fc5121d2ff37a76d4ebeb1b5f1498f_rle_crop_3751649944_0.png.png imagette221666491744206180/1744205594_2832356_1350795193_acd7d663468425d870054e8aea57bbd7_rle_crop_3751649039_0.png.png imagette221666491744206180/1744205712_2833493_1350795338_026edf6dc0adf3e8cf2502bd7686b86c_rle_crop_3751649716_0.png.png imagette221666491744206180/1744205594_2832356_1350795182_5a8887a60bd9cf9152dde1349a86490a_rle_crop_3751649072_0.png.png wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/dca69e7881d893989b02089253147fee_76441449.png imagette221666491744206180 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=22166636 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/22166651,22166652,22166653,22166654,22166655,22166656,22166657,22166658,22166659,22166660,22166661,22166662?tags=autre_refus,metal,kraft,mal_croppe,environnement,Carton_gris,flou,papier,Teint_Dans_La_Masse,plastique,Carton_brun,cartonnette your option no_mail is active, we will not send the real mail to your client args[1350796734] : ('0.03714201882270479',) no score found for photo 1350796734 We are sending mail with results at report@fotonower.com args[1350796688] : ('0.03714201882270479',) no score found for photo 1350796688 We are sending mail with results at report@fotonower.com args[1350796684] : ('0.03714201882270479',) no score found for photo 1350796684 We are sending mail with results at report@fotonower.com args[1350796530] : ('0.03714201882270479',) no score found for photo 1350796530 We are sending mail with results at report@fotonower.com args[1350796515] : ('0.03714201882270479',) no score found for photo 1350796515 We are sending mail with results at report@fotonower.com args[1350796509] : ('0.03714201882270479',) no score found for photo 1350796509 We are sending mail with results at report@fotonower.com args[1350796501] : ('0.03714201882270479',) no score found for photo 1350796501 We are sending mail with results at report@fotonower.com args[1350796489] : ('0.03714201882270479',) no score found for photo 1350796489 We are sending mail with results at report@fotonower.com refus_total : 0.03714201882270479 2022-04-13 10:29:59 0 SELECT ph.photo_id,ph.url,ph.username,ph.uploaded_at,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166636 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_P22166636_09-04-2025_15_42_58.pdf results_Auto_P22166636_09-04-2025_15_42_58.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22166636_09-04-2025_15_42_58.pdf start insert file to database insert into MTRUser.mtr_files (mtd_id,mtr_portfolio_id,text,url,format,tags,file_size,value) values ('4302','22166636','results_Auto_P22166636_09-04-2025_15_42_58.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22166636_09-04-2025_15_42_58.pdf','pdf','','0.19','0.03714201882270479') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22166636]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489] map_info['map_portfolio_photo'] : {22166636: [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489, 1350796343, 1350796332, 1350796057, 1350796053, 1350796046, 1350796042, 1350796030, 1350796026, 1350795877, 1350795872, 1350795870, 1350795852, 1350795723, 1350795715, 1350795711, 1350795707, 1350795680, 1350795676, 1350795673, 1350795669, 1350795664, 1350795660, 1350795512, 1350795504, 1350795493, 1350795482, 1350795478, 1350795424, 1350795388, 1350795352, 1350795338, 1350795193, 1350795182, 1350795179, 1350795142]} final : False mtd_id 4302 list_pids : [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489] 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, '2734893') ('4302', '22166636', '1350796734', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796688', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796684', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796530', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796515', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796509', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796501', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796489', None, None, None, None, None, '2734893') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 8 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', '22166636', '1350796734', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796688', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796684', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796530', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796515', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796509', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796501', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796489', None, None, None, None, None, '2734893')] time used for this insertion : 0.014968156814575195 save_final save missing photos in datou_result : time spend for datou_step_exec : 3.527217388153076 time spend to save output : 0.015207529067993164 total time spend for step 4 : 3.5424249172210693 step5:split_time_score Wed Apr 9 15:43:02 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : ['22166636'] 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 : [('22166636',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22166636) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1350796530: {'path': 'temp/1744206178_1710641_1350796530_6f9bf720621985ef704cea9e8bc78707.jpg', 'extension': 'jpg'}, 1350796684: {'path': 'temp/1744206178_1710641_1350796684_c50196103a93c12cd22c739acfc3cc09.jpg', 'extension': 'jpg'}, 1350796688: {'path': 'temp/1744206178_1710641_1350796688_8a02bf3ba02759e27699a91b44b593db.jpg', 'extension': 'jpg'}, 1350796734: {'path': 'temp/1744206178_1710641_1350796734_244798f00526ddafa388ce9173ea4ea7.jpg', 'extension': 'jpg'}, 1350796509: {'path': 'temp/1744206178_1710641_1350796509_7d6007625a81dd20a3bf97210468825e.jpg', 'extension': 'jpg'}, 1350796515: {'path': 'temp/1744206178_1710641_1350796515_b69b8100ac1e8b30f1fd6ed7ab87026d.jpg', 'extension': 'jpg'}, 1350796489: {'path': 'temp/1744206178_1710641_1350796489_588463e33d61a947ab2773e217c23573.jpg', 'extension': 'jpg'}, 1350796501: {'path': 'temp/1744206178_1710641_1350796501_05b799a31a4df12d817ceba7ed7607b1.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 = 22166636; (('arc_en_ciel_jrm',),) TODO : Insert select and so on Begin split_port_in_batch_balle thcls : [{'id': 861, 'mtr_user_id': 31, 'name': 'Rungis_class_dechets_1212', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': 'Rungis_Aluminium,Rungis_Carton,Rungis_Papier,Rungis_Plastique_clair,Rungis_Plastique_dur,Rungis_Plastique_fonce,Rungis_Tapis_vide,Rungis_Tetrapak', 'svm_portfolios_learning': '1160730,571842,571844,571839,571933,571840,571841,572307', 'photo_hashtag_type': 999, 'photo_desc_type': 3963, 'type_classification': 'caffe', 'hashtag_id_list': '2107751280,2107750907,2107750908,2107750909,2107750910,2107750911,2107750912,2107750913'}] thcls : [{'id': 758, 'mtr_user_id': 31, 'name': 'Rungis_amount_dechets_fall_2018_v2', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': '05102018_Papier_non_papier_dense,05102018_Papier_non_papier_peu_dense,05102018_Papier_non_papier_presque_vide,05102018_Papier_non_papier_tres_dense,05102018_Papier_non_papier_tres_peu_dense', 'svm_portfolios_learning': '1108385,1108386,1108388,1108384,1108387', 'photo_hashtag_type': 856, 'photo_desc_type': 3853, 'type_classification': 'caffe', 'hashtag_id_list': '2107751013,2107751014,2107751015,2107751016,2107751017'}] select SUBSTRING(ph.text,16,2) as h, count(*) from MTRUser.mtr_portfolio_photos mpp inner join MTRBack.photos ph on mpp.mtr_photo_id = ph.photo_id where mpp.mtr_portfolio_id = 22166636 group by h (('15', 43),) SELECT ph.photo_id,ph.url,ph.username,ph.uploaded_at,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22166636 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 (22166636) 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 (22166636) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 09042025 22166636 Nombre de photos uploadées : 43 / 23040 (0%) 09042025 22166636 Nombre de photos taguées (types de déchets): 0 / 43 (0%) 09042025 22166636 Nombre de photos taguées (volume) : 0 / 43 (0%) [{'photo_id': 1350795193, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/acd7d663468425d870054e8aea57bbd7.jpg', 'username': None, 'uploaded_at': 1744205467, 'text': 'image_09042025_15_30_05_10145.jpg'}, {'photo_id': 1350795182, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/5a8887a60bd9cf9152dde1349a86490a.jpg', 'username': None, 'uploaded_at': 1744205467, 'text': 'image_09042025_15_30_14_9125.jpg'}, {'photo_id': 1350795179, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/d69694b35848da47c47fc391e49ba29d.jpg', 'username': None, 'uploaded_at': 1744205467, 'text': 'image_09042025_15_30_24_10136.jpg'}, {'photo_id': 1350795142, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/9/a5430d48bb87714756dfaff9e3a8beb7.jpg', 'username': None, 'uploaded_at': 1744205467, 'text': 'image_09042025_15_30_44_10136.jpg'}] 0 [] elapsed_time : load_data_split_time_score 2.86102294921875e-06 elapsed_time : order_list_meta_photo_and_scores 6.67572021484375e-06 ??????????????????????????????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.0018033981323242188 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 22166636, '2025-04-09' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1725367,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.026278972625732422 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= 1725367 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1725367, 'dashboard_run_id': 1734121, 'mtr_portfolio_id': 22164380, 'dashboard_result_id': 9946139, '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_P22164380_09-04-2025_15_03_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22164383, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22164384, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22164385, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22164386, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22164387, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22164388, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22164389, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22164390, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22164391, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22164392, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22164393, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22164394, 'pht': 3726}}"}, {'dashboat_entry_day': 1725367, 'dashboard_run_id': 1734121, 'mtr_portfolio_id': 22165125, 'dashboard_result_id': 9946140, '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_P22165125_09-04-2025_15_18_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22165153, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22165154, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22165155, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22165156, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22165157, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22165158, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22165159, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22165160, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22165161, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22165162, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22165163, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22165164, 'pht': 3726}}"}, {'dashboat_entry_day': 1725367, 'dashboard_run_id': 1734121, 'mtr_portfolio_id': 22165756, 'dashboard_result_id': 9946141, '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_P22165756_09-04-2025_15_32_58.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 22165872, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22165877, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22165880, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22165881, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22165882, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22165883, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22165884, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22165885, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22165886, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22165887, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22165888, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22165889, 'pht': 3726}}"}, {'dashboat_entry_day': 1725367, 'dashboard_run_id': 1734121, 'mtr_portfolio_id': 22166636, 'dashboard_result_id': 9946142, '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_P22166636_09-04-2025_15_41_01.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22166639, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22166640, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22166641, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22166642, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22166643, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22166644, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22166645, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22166646, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22166647, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22166648, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22166649, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22166650, '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 = 22164380 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': 2734707, 'mtr_portfolio_id': 22164380, 'created_at': datetime.datetime(2025, 4, 9, 15, 3), 'result': '0.026813952344248798', 'result_long': None, 'result_double': None}] Qualite : 0.026813952344248798 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22164380 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22164380_09-04-2025_15_03_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22164380 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_P22164380_09-04-2025_15_03_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22164383, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22164384, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22164385, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22164386, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22164387, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22164388, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22164389, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22164390, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22164391, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22164392, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22164393, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22164394, 'pht': 3726}}" where mtr_portfolio_id = 22164380 and dashboard_run_id = 1734121 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`=22164380 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9946139, 0.026813952344248798, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22164380_09-04-2025_15_03_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22164383, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22164384, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22164385, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22164386, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22164387, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22164388, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22164389, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22164390, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22164391, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22164392, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22164393, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22164394, '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 = 22165125 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': 2734780, 'mtr_portfolio_id': 22165125, 'created_at': datetime.datetime(2025, 4, 9, 15, 18, 58), 'result': '0.038668448255467315', 'result_long': None, 'result_double': None}] Qualite : 0.038668448255467315 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22165125 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22165125_09-04-2025_15_18_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22165125 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_P22165125_09-04-2025_15_18_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22165153, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22165154, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22165155, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22165156, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22165157, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22165158, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22165159, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22165160, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22165161, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22165162, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22165163, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22165164, 'pht': 3726}}" where mtr_portfolio_id = 22165125 and dashboard_run_id = 1734121 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`=22165125 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9946140, 0.038668448255467315, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22165125_09-04-2025_15_18_59.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22165153, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22165154, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22165155, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22165156, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22165157, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22165158, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22165159, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22165160, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22165161, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22165162, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22165163, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22165164, '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 = 22165756 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': 2734827, 'mtr_portfolio_id': 22165756, 'created_at': datetime.datetime(2025, 4, 9, 15, 32, 57), 'result': '0.054439983139558175', 'result_long': None, 'result_double': None}] Qualite : 0.054439983139558175 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22165756 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22165756_09-04-2025_15_32_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22165756 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_P22165756_09-04-2025_15_32_58.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 22165872, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22165877, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22165880, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22165881, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22165882, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22165883, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22165884, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22165885, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22165886, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22165887, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22165888, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22165889, 'pht': 3726}}" where mtr_portfolio_id = 22165756 and dashboard_run_id = 1734121 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`=22165756 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9946141, 0.054439983139558175, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22165756_09-04-2025_15_32_58.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 22165872, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22165877, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22165880, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22165881, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22165882, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22165883, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22165884, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22165885, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22165886, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22165887, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22165888, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22165889, '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 = 22166636 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': 2734893, 'mtr_portfolio_id': 22166636, 'created_at': datetime.datetime(2025, 4, 9, 15, 42, 58), 'result': '0.03714201882270479', 'result_long': None, 'result_double': None}] Qualite : 0.03714201882270479 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22166636 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22166636_09-04-2025_15_42_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22166636 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_P22166636_09-04-2025_15_42_58.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22166639, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22166640, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22166641, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22166642, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22166643, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22166644, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22166645, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22166646, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22166647, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22166648, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22166649, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22166650, 'pht': 3726}}" where mtr_portfolio_id = 22166636 and dashboard_run_id = 1734121 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`=22166636 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9946142, 0.03714201882270479, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22166636_09-04-2025_15_42_58.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22166639, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22166640, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22166641, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22166642, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22166643, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22166644, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22166645, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22166646, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22166647, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22166648, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22166649, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22166650, '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 (22164380,22165125,22165756,22166636) result : ((1350786028,), (1350786038,), (1350786043,), (1350786096,), (1350786107,), (1350786113,), (1350786119,), (1350786122,), (1350786149,), (1350786155,), (1350786165,), (1350786169,), (1350786174,), (1350786252,), (1350786255,), (1350786259,), (1350786263,), (1350786268,), (1350786408,), (1350786417,), (1350786422,), (1350786578,), (1350786581,), (1350786584,), (1350786587,), (1350786620,), (1350786623,), (1350786626,), (1350786674,), (1350786680,), (1350786684,), (1350786688,), (1350786692,), (1350786698,), (1350786746,), (1350786749,), (1350786756,), (1350786772,), (1350786788,), (1350786940,), (1350786953,), (1350786957,), (1350786979,), (1350787019,), (1350787022,), (1350787026,), (1350787029,), (1350787372,), (1350787409,), (1350787426,), (1350787450,), (1350787493,), (1350787515,), (1350787611,), (1350787653,), (1350787656,), (1350787661,), (1350787724,), (1350787733,), (1350787741,), (1350787747,), (1350787755,), (1350788193,), (1350788172,), (1350788187,), (1350788332,), (1350788342,), (1350788378,), (1350788391,), (1350788399,), (1350788402,), (1350788508,), (1350788512,), (1350788517,), (1350788526,), (1350788536,), (1350788653,), (1350788677,), (1350788707,), (1350788940,), (1350788965,), (1350788994,), (1350789024,), (1350789051,), (1350789076,), (1350789262,), (1350789287,), (1350789312,), (1350789342,), (1350789367,), (1350789401,), (1350789609,), (1350789628,), (1350789657,), (1350789738,), (1350789792,), (1350789830,), (1350790252,), (1350790287,), (1350790317,), (1350790359,), (1350790642,), (1350790692,), (1350790714,), (1350790724,), (1350791027,), (1350791052,), (1350791067,), (1350791239,), (1350791241,), (1350791246,), (1350791248,), (1350791254,), (1350791330,), (1350791353,), (1350791381,), (1350791405,), (1350791429,), (1350791785,), (1350791818,), (1350791869,), (1350792083,), (1350792125,), (1350792154,), (1350792567,), (1350792505,), (1350792524,), (1350792534,), (1350792545,), (1350792558,), (1350792660,), (1350792664,), (1350792669,), (1350792674,), (1350792679,), (1350792683,), (1350792773,), (1350792805,), (1350792817,), (1350792862,), (1350792943,), (1350792950,), (1350792954,), (1350792968,), (1350793367,), (1350793375,), (1350793377,), (1350793378,), (1350793382,), (1350793386,), (1350793441,), (1350793446,), (1350793501,), (1350793503,), (1350793506,), (1350793507,), (1350793509,), (1350793512,), (1350793554,), (1350793557,), (1350793561,), (1350793565,), (1350793569,), (1350793595,), (1350793690,), (1350793692,), (1350793694,), (1350793696,), (1350793733,), (1350793737,), (1350793742,), (1350793749,), (1350793787,), (1350793798,), (1350793851,), (1350793854,), (1350793873,), (1350793875,), (1350793880,), (1350793916,), (1350793919,), (1350793923,), (1350793926,), (1350793928,), (1350794108,), (1350794159,), (1350794230,), (1350794245,), (1350794265,), (1350794284,), (1350794428,), (1350794514,), (1350794527,), (1350794531,), (1350794536,), (1350794751,), (1350794758,), (1350794763,), (1350794767,), (1350794773,), (1350795200,), (1350795142,), (1350795179,), (1350795182,), (1350795193,), (1350795338,), (1350795352,), (1350795388,), (1350795424,), (1350795478,), (1350795482,), (1350795493,), (1350795504,), (1350795512,), (1350795660,), (1350795664,), (1350795669,), (1350795673,), (1350795676,), (1350795680,), (1350795707,), (1350795711,), (1350795715,), (1350795723,), (1350795852,), (1350795870,), (1350795872,), (1350795877,), (1350796026,), (1350796030,), (1350796042,), (1350796046,), (1350796053,), (1350796057,), (1350796332,), (1350796343,), (1350796489,), (1350796501,), (1350796509,), (1350796515,), (1350796530,), (1350796684,), (1350796688,), (1350796734,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'09042025': {'nb_upload': 43, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22166636]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489] map_info['map_portfolio_photo'] : {22166636: [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489, 1350796343, 1350796332, 1350796057, 1350796053, 1350796046, 1350796042, 1350796030, 1350796026, 1350795877, 1350795872, 1350795870, 1350795852, 1350795723, 1350795715, 1350795711, 1350795707, 1350795680, 1350795676, 1350795673, 1350795669, 1350795664, 1350795660, 1350795512, 1350795504, 1350795493, 1350795482, 1350795478, 1350795424, 1350795388, 1350795352, 1350795338, 1350795193, 1350795182, 1350795179, 1350795142]} final : True mtd_id 4302 list_pids : [1350796734, 1350796688, 1350796684, 1350796530, 1350796515, 1350796509, 1350796501, 1350796489] Looping around the photos to save general results len do output : 1 /22166636Didn'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, '2734893') ('4302', '22166636', '1350796734', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796688', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796684', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796530', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796515', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796509', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796501', None, None, None, None, None, '2734893') ('4302', None, None, None, None, None, None, None, '2734893') ('4302', '22166636', '1350796489', None, None, None, None, None, '2734893') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 9 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, '22166636', 'None', None, None, None, None, '2734893'), ('4302', '22166636', '1350796734', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796688', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796684', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796530', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796515', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796509', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796501', None, None, None, None, None, '2734893'), ('4302', '22166636', '1350796489', None, None, None, None, None, '2734893')] time used for this insertion : 0.017331838607788086 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.35361504554748535 time spend to save output : 0.017662763595581055 total time spend for step 5 : 0.3712778091430664 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 (2734893) 2.02user 1.98system 0:07.89elapsed 50%CPU (0avgtext+0avgdata 159608maxresident)k 3280inputs+9952outputs (1major+63965minor)pagefaults 0swaps