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 : 801179 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 (2819020) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (2819020) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870688 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['2819020'] with mtr_portfolio_ids : ['22870688'] and first list_photo_ids : [] new path : /proc/801179/ Name: python3 Umask: 0002 State: R (running) Tgid: 801179 Ngid: 0 Pid: 801179 PPid: 801178 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 801179 NSpid: 801179 NSpgid: 799432 NSsid: 799432 VmPeak: 1107228 kB VmSize: 1107228 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 99596 kB VmRSS: 99596 kB RssAnon: 60200 kB RssFile: 39396 kB RssShmem: 0 kB VmData: 865976 kB VmStk: 132 kB VmExe: 2644 kB VmLib: 130468 kB VmPTE: 608 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: 55 nonvoluntary_ctxt_switches: 95 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '801179', 'Ngid': '0', 'Pid': '801179', 'PPid': '801178', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '801179', 'NSpid': '801179', 'NSpgid': '799432', 'NSsid': '799432', 'VmPeak': '1107228 kB', 'VmSize': '1107228 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '99596 kB', 'VmRSS': '99596 kB', 'RssAnon': '60200 kB', 'RssFile': '39396 kB', 'RssShmem': '0 kB', 'VmData': '865976 kB', 'VmStk': '132 kB', 'VmExe': '2644 kB', 'VmLib': '130468 kB', 'VmPTE': '608 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': '55', 'nonvoluntary_ctxt_switches': '95'} ('datou_batch_current', '801179', '1107228', '0', '1107228', '865976', '99596', b'', 'marlene', '2819020') 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 (22870688) 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 (2819020 ) ) 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 (22870688) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1357597603, 'portfolio_id': 22870688}, {'photo_id': 1357597555, 'portfolio_id': 22870688}, {'photo_id': 1357597553, 'portfolio_id': 22870688}, {'photo_id': 1357597549, 'portfolio_id': 22870688}, {'photo_id': 1357597516, 'portfolio_id': 22870688}, {'photo_id': 1357597515, 'portfolio_id': 22870688}, {'photo_id': 1357597514, 'portfolio_id': 22870688}, {'photo_id': 1357597513, 'portfolio_id': 22870688}, {'photo_id': 1357597512, 'portfolio_id': 22870688}, {'photo_id': 1357597510, 'portfolio_id': 22870688}, {'photo_id': 1357597490, 'portfolio_id': 22870688}, {'photo_id': 1357597489, 'portfolio_id': 22870688}, {'photo_id': 1357597488, 'portfolio_id': 22870688}, {'photo_id': 1357597483, 'portfolio_id': 22870688}, {'photo_id': 1357597480, 'portfolio_id': 22870688}, {'photo_id': 1357597422, 'portfolio_id': 22870688}, {'photo_id': 1357597421, 'portfolio_id': 22870688}, {'photo_id': 1357597418, 'portfolio_id': 22870688}, {'photo_id': 1357597400, 'portfolio_id': 22870688}, {'photo_id': 1357597399, 'portfolio_id': 22870688}, {'photo_id': 1357597398, 'portfolio_id': 22870688}, {'photo_id': 1357597395, 'portfolio_id': 22870688}, {'photo_id': 1357597393, 'portfolio_id': 22870688}, {'photo_id': 1357597371, 'portfolio_id': 22870688}, {'photo_id': 1357597370, 'portfolio_id': 22870688}, {'photo_id': 1357597368, 'portfolio_id': 22870688}, {'photo_id': 1357597366, 'portfolio_id': 22870688}, {'photo_id': 1357597365, 'portfolio_id': 22870688}, {'photo_id': 1357597362, 'portfolio_id': 22870688}, {'photo_id': 1357597341, 'portfolio_id': 22870688}, {'photo_id': 1357597339, 'portfolio_id': 22870688}, {'photo_id': 1357597335, 'portfolio_id': 22870688}, {'photo_id': 1357597331, 'portfolio_id': 22870688}, {'photo_id': 1357597272, 'portfolio_id': 22870688}, {'photo_id': 1357597268, 'portfolio_id': 22870688}, {'photo_id': 1357597266, 'portfolio_id': 22870688}, {'photo_id': 1357597248, 'portfolio_id': 22870688}, {'photo_id': 1357597247, 'portfolio_id': 22870688}, {'photo_id': 1357597246, 'portfolio_id': 22870688}, {'photo_id': 1357597244, 'portfolio_id': 22870688}, {'photo_id': 1357597240, 'portfolio_id': 22870688}, {'photo_id': 1357597216, 'portfolio_id': 22870688}, {'photo_id': 1357597214, 'portfolio_id': 22870688}, {'photo_id': 1357597213, 'portfolio_id': 22870688}, {'photo_id': 1357597211, 'portfolio_id': 22870688}, {'photo_id': 1357597103, 'portfolio_id': 22870688}, {'photo_id': 1357596683, 'portfolio_id': 22870688}] map_portfolio_id_photo_id: {22870688: [1357597603, 1357597555, 1357597553, 1357597549, 1357597516, 1357597515, 1357597514, 1357597513, 1357597512, 1357597510, 1357597490, 1357597489, 1357597488, 1357597483, 1357597480, 1357597422, 1357597421, 1357597418, 1357597400, 1357597399, 1357597398, 1357597395, 1357597393, 1357597371, 1357597370, 1357597368, 1357597366, 1357597365, 1357597362, 1357597341, 1357597339, 1357597335, 1357597331, 1357597272, 1357597268, 1357597266, 1357597248, 1357597247, 1357597246, 1357597244, 1357597240, 1357597216, 1357597214, 1357597213, 1357597211, 1357597103, 1357596683]} ##### 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.01534581184387207 #### 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 Mon May 12 05:32:57 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22870688) 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 : 22870688 get user id for portfolio 22870688 get sub ptf for main ptf 22870688, type 3726 and hashtags ['plastique', 'papier', 'mal_croppe', 'Teint_Dans_La_Masse', 'autre_refus', 'flou', 'environnement', 'Carton_gris', 'metal', 'kraft', 'cartonnette', '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`=22870688 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('plastique','papier','mal_croppe','Teint_Dans_La_Masse','autre_refus','flou','environnement','Carton_gris','metal','kraft','cartonnette','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`=22870688 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('plastique','papier','mal_croppe','Teint_Dans_La_Masse','autre_refus','flou','environnement','Carton_gris','metal','kraft','cartonnette','Carton_brun')) AND mptpi.`min_score`=0.5 To do returned map {'autre_refus': {'main_port_id': 22870688, 'sub_port_id': 22870690, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267826, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'Carton_brun': {'main_port_id': 22870688, 'sub_port_id': 22870691, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267827, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'Teint_Dans_La_Masse': {'main_port_id': 22870688, 'sub_port_id': 22870692, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267828, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'Carton_gris': {'main_port_id': 22870688, 'sub_port_id': 22870693, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267829, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'kraft': {'main_port_id': 22870688, 'sub_port_id': 22870694, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267830, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'plastique': {'main_port_id': 22870688, 'sub_port_id': 22870695, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267831, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'metal': {'main_port_id': 22870688, 'sub_port_id': 22870696, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267832, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'cartonnette': {'main_port_id': 22870688, 'sub_port_id': 22870697, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267833, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'papier': {'main_port_id': 22870688, 'sub_port_id': 22870698, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267834, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'mal_croppe': {'main_port_id': 22870688, 'sub_port_id': 22870699, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267835, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'environnement': {'main_port_id': 22870688, 'sub_port_id': 22870700, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267836, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}, 'flou': {'main_port_id': 22870688, 'sub_port_id': 22870701, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267837, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 56)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870690 , 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=22870688 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 (22870690) result : ((1357597291,), (1357597292,), (1357597442,), (1357597619,), (1357597620,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870691 , 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=22870688 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 (22870691) result : ((1357597467,), (1357597471,), (1357597541,), (1357597542,), (1357597543,), (1357597544,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870692 , 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=22870688 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 (22870692) result : ((1357597288,), (1357597438,), (1357597439,), (1357597440,), (1357597528,), (1357597530,), (1357597531,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870693 , 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=22870688 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 (22870693) result : ((1357597622,), (1357597623,), (1357597624,), (1357597625,), (1357597626,), (1357597627,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870694 , 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=22870688 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 (22870694) result : ((1357597477,), (1357597631,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870695 , 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=22870688 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 (22870695) result : ((1357597384,),) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870696 , 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=22870688 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 (22870696) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870697 , 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=22870688 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 (22870697) result : ((1357597294,), (1357597445,), (1357597446,), (1357597447,), (1357597448,), (1357597449,), (1357597532,), (1357597533,), (1357597534,), (1357597536,), (1357597537,), (1357597538,), (1357597628,), (1357597629,), (1357597630,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870698 , 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=22870688 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 (22870698) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870699 , 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=22870688 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 (22870699) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870700 , 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=22870688 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 (22870700) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22870701 , 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=22870688 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 (22870701) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870688) result : ((1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,)) 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 (1357597400) and cspi.crop_hashtag_id = chi.id; To do ! Use context local managing function ! SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22870688 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('plastique','papier','mal_croppe','Teint_Dans_La_Masse','autre_refus','flou','environnement','Carton_gris','metal','kraft','cartonnette','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`=22870688 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('plastique','papier','mal_croppe','Teint_Dans_La_Masse','autre_refus','flou','environnement','Carton_gris','metal','kraft','cartonnette','Carton_brun')) AND mptpi.`min_score`=0.5 To do returned map {'autre_refus': {'main_port_id': 22870688, 'sub_port_id': 22870702, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267838, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'Carton_brun': {'main_port_id': 22870688, 'sub_port_id': 22870703, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267839, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'Teint_Dans_La_Masse': {'main_port_id': 22870688, 'sub_port_id': 22870704, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267840, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'Carton_gris': {'main_port_id': 22870688, 'sub_port_id': 22870705, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267841, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'kraft': {'main_port_id': 22870688, 'sub_port_id': 22870706, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267842, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'plastique': {'main_port_id': 22870688, 'sub_port_id': 22870707, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267843, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'metal': {'main_port_id': 22870688, 'sub_port_id': 22870708, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267844, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'cartonnette': {'main_port_id': 22870688, 'sub_port_id': 22870709, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267845, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'papier': {'main_port_id': 22870688, 'sub_port_id': 22870710, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267846, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'mal_croppe': {'main_port_id': 22870688, 'sub_port_id': 22870711, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267847, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'environnement': {'main_port_id': 22870688, 'sub_port_id': 22870712, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267848, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 20, 58), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}, 'flou': {'main_port_id': 22870688, 'sub_port_id': 22870713, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 15267849, 'last_updated_at': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_desc': datetime.datetime(2025, 5, 12, 5, 30, 57), 'last_updated_at_asc': datetime.datetime(2025, 5, 12, 5, 20, 58)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870702,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870690 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870703,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870691 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870704,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870692 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870705,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870693 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870706,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870694 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870707,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870695 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870708,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870696 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870709,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870697 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870710,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870698 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870711,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870699 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870712,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870700 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22870713,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22870701 lien utilise dans velours : https://www.fotonower.com/velours/22870702,22870703,22870704,22870705,22870706,22870707,22870708,22870709,22870710,22870711,22870712,22870713?tags=autre_refus,Carton_brun,Teint_Dans_La_Masse,Carton_gris,kraft,plastique,metal,cartonnette,papier,mal_croppe,environnement,flou After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22870688]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1357597603] map_info['map_portfolio_photo'] : {22870688: [1357597603, 1357597555, 1357597553, 1357597549, 1357597516, 1357597515, 1357597514, 1357597513, 1357597512, 1357597510, 1357597490, 1357597489, 1357597488, 1357597483, 1357597480, 1357597422, 1357597421, 1357597418, 1357597400, 1357597399, 1357597398, 1357597395, 1357597393, 1357597371, 1357597370, 1357597368, 1357597366, 1357597365, 1357597362, 1357597341, 1357597339, 1357597335, 1357597331, 1357597272, 1357597268, 1357597266, 1357597248, 1357597247, 1357597246, 1357597244, 1357597240, 1357597216, 1357597214, 1357597213, 1357597211, 1357597103, 1357596683]} final : False mtd_id 4302 list_pids : [1357597603] Looping around the photos to save general results len do output : 1 /22870688. 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, '2819020') ('4302', '22870688', '1357597603', None, None, None, None, None, '2819020') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 2 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, '22870688', "{'autre_refus': 22870690, 'Carton_brun': 22870691, 'Teint_Dans_La_Masse': 22870692, 'Carton_gris': 22870693, 'kraft': 22870694, 'plastique': 22870695, 'metal': 22870696, 'cartonnette': 22870697, 'papier': 22870698, 'mal_croppe': 22870699, 'environnement': 22870700, 'flou': 22870701}", None, None, None, None, '2819020'), ('4302', '22870688', '1357597603', None, None, None, None, None, '2819020')] time used for this insertion : 0.01179194450378418 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.45029401779174805 time spend to save output : 0.012012481689453125 total time spend for step 1 : 0.46230649948120117 step2:final Mon May 12 05:32:57 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec 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 (22870688) 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 22870688 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1357596683,1357597216,1357597103,1357597214,1357597213,1357597211,1357597248,1357597247,1357597246,1357597244,1357597240,1357597272,1357597268,1357597266,1357597341,1357597339,1357597335,1357597331,1357597371,1357597370,1357597368,1357597366,1357597365,1357597362,1357597400,1357597399,1357597398,1357597395,1357597393,1357597422,1357597421,1357597418,1357597490,1357597489,1357597488,1357597483,1357597480,1357597516,1357597515,1357597514,1357597513,1357597512,1357597510,1357597555,1357597553,1357597549,1357597603); 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([22870688]) Inside saveOutput : final : False verbose : True original output for save of step final : {1357597603: ('0.040974598516487964',)} new output for save of step final : {1357597603: ('0.040974598516487964',)} [1357597603] map_info['map_portfolio_photo'] : {22870688: [1357597603, 1357597555, 1357597553, 1357597549, 1357597516, 1357597515, 1357597514, 1357597513, 1357597512, 1357597510, 1357597490, 1357597489, 1357597488, 1357597483, 1357597480, 1357597422, 1357597421, 1357597418, 1357597400, 1357597399, 1357597398, 1357597395, 1357597393, 1357597371, 1357597370, 1357597368, 1357597366, 1357597365, 1357597362, 1357597341, 1357597339, 1357597335, 1357597331, 1357597272, 1357597268, 1357597266, 1357597248, 1357597247, 1357597246, 1357597244, 1357597240, 1357597216, 1357597214, 1357597213, 1357597211, 1357597103, 1357596683]} final : False mtd_id 4302 list_pids : [1357597603] Looping around the photos to save general results len do output : 1 /1357597603.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, '2819020') ('4302', '22870688', '1357597603', None, None, None, None, None, '2819020') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 3 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', '22870688', '1357597603', '0.040974598516487964', None, None, None, None, '2819020')] time used for this insertion : 0.011821269989013672 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.0649712085723877 time spend to save output : 0.011976242065429688 total time spend for step 2 : 0.07694745063781738 step3:velours_tree Mon May 12 05:32:57 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec 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 : {22870688: [{'autre_refus': 22870690, 'Carton_brun': 22870691, 'Teint_Dans_La_Masse': 22870692, 'Carton_gris': 22870693, 'kraft': 22870694, 'plastique': 22870695, 'metal': 22870696, 'cartonnette': 22870697, 'papier': 22870698, 'mal_croppe': 22870699, 'environnement': 22870700, 'flou': 22870701}]} input_args_next_step : {22870688: ()} output_args : {22870688: [{'autre_refus': 22870690, 'Carton_brun': 22870691, 'Teint_Dans_La_Masse': 22870692, 'Carton_gris': 22870693, 'kraft': 22870694, 'plastique': 22870695, 'metal': 22870696, 'cartonnette': 22870697, 'papier': 22870698, 'mal_croppe': 22870699, 'environnement': 22870700, 'flou': 22870701}]} args : 22870688 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': 22870690, 'Carton_brun': 22870691, 'Teint_Dans_La_Masse': 22870692, 'Carton_gris': 22870693, 'kraft': 22870694, 'plastique': 22870695, 'metal': 22870696, 'cartonnette': 22870697, 'papier': 22870698, 'mal_croppe': 22870699, 'environnement': 22870700, 'flou': 22870701},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22870688) 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([22870688]) 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.2803797721862793 time spend to save output : 5.078315734863281e-05 total time spend for step 3 : 0.28043055534362793 step4:send_mail_cod Mon May 12 05:32: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 : {1357597603: ('0.040974598516487964',)} input_args_next_step : {1357597603: ()} output_args : {1357597603: ('0.040974598516487964',)} args : 1357597603 depend.output_id : 0 complete output_args for input 3 : {22870688: [{'autre_refus': 22870690, 'Carton_brun': 22870691, 'Teint_Dans_La_Masse': 22870692, 'Carton_gris': 22870693, 'kraft': 22870694, 'plastique': 22870695, 'metal': 22870696, 'cartonnette': 22870697, 'papier': 22870698, 'mal_croppe': 22870699, 'environnement': 22870700, 'flou': 22870701}]} input_args_next_step : {1357597603: ('0.040974598516487964',), 22870688: ()} output_args : {22870688: [{'autre_refus': 22870690, 'Carton_brun': 22870691, 'Teint_Dans_La_Masse': 22870692, 'Carton_gris': 22870693, 'kraft': 22870694, 'plastique': 22870695, 'metal': 22870696, 'cartonnette': 22870697, 'papier': 22870698, 'mal_croppe': 22870699, 'environnement': 22870700, 'flou': 22870701}]} args : 22870688 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 :2, first value : ('0.040974598516487964',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22870688) 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 (1357597603) Found this number of photos: 1 ##### Call download_photos : nb_thread : 5 begin to download photo : 1357597603 download finish for photo 1357597603 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 : 1 ; length of list_pids : 1 ; length of list_args : 1 results_Auto_P22870688_12-05-2025_05_32_58.pdf 22870690 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=22870690 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1357597291: '1747020206_2630970_1357597247_ee1d45408bfb68c093da85711de88c2b_rle_crop_3793819520_0.png', 1357597292: '1747020206_2630970_1357597240_4435eba11e60ea1d0861914c29eeb126_rle_crop_3793819553_0.png', 1357597442: '1747020446_2637781_1357597366_845b0cda5e1087a7afa21fa95b0a2c97_rle_crop_3793820667_0.png', 1357597619: '1747020687_2643484_1357597515_e613e5f3c6bed05efa725e40a785a681_rle_crop_3793821763_0.png', 1357597620: '1747020687_2643484_1357597514_6bd61cc845c682b90f4e81f9c35b71ea_rle_crop_3793821784_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/4d775c35bb68c4841cf4f9865af4b247_19335930.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/b630306c90dce6fa665c5b7e97e68ae9_73595615.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/fd41b4d04aedb280249228abeee700fe_75164259.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/cedeb8a582c368f90657611b1c423eb9_72581169.png change filename to text .imagette228706901747020778/ imagette228706901747020778/1747020446_2637781_1357597366_845b0cda5e1087a7afa21fa95b0a2c97_rle_crop_3793820667_0.png.png imagette228706901747020778/1747020206_2630970_1357597240_4435eba11e60ea1d0861914c29eeb126_rle_crop_3793819553_0.png.png imagette228706901747020778/1747020687_2643484_1357597515_e613e5f3c6bed05efa725e40a785a681_rle_crop_3793821763_0.png.png imagette228706901747020778/1747020687_2643484_1357597514_6bd61cc845c682b90f4e81f9c35b71ea_rle_crop_3793821784_0.png.png imagette228706901747020778/1747020206_2630970_1357597247_ee1d45408bfb68c093da85711de88c2b_rle_crop_3793819520_0.png.png wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/f3e12ff49924aede646cdb1af436fec1_1012913.png imagette228706901747020778 22870694 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=22870694 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1357597477: '1747020446_2637781_1357597366_845b0cda5e1087a7afa21fa95b0a2c97_rle_crop_3793820670_0.png', 1357597631: '1747020687_2643484_1357597555_ac5bbbb9ac0a30a2c6c990255fb134b2_rle_crop_3793821753_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/c5021cc80962a030db810de931c09fac_38496050.png change filename to text .imagette228706941747020778/ imagette228706941747020778/1747020687_2643484_1357597555_ac5bbbb9ac0a30a2c6c990255fb134b2_rle_crop_3793821753_0.png.png imagette228706941747020778/1747020446_2637781_1357597366_845b0cda5e1087a7afa21fa95b0a2c97_rle_crop_3793820670_0.png.png wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/dd4fb865cc78a606ee07542f98737d16_78249833.png imagette228706941747020778 22870695 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=22870695 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1357597384: '1747020327_2633724_1357597335_278e7b164ae2e30efa4308bdc142890e_rle_crop_3793820361_0.png'} change filename to text .imagette228706951747020778/ imagette228706951747020778/1747020327_2633724_1357597335_278e7b164ae2e30efa4308bdc142890e_rle_crop_3793820361_0.png.png imagette228706961747020778/ wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/e8e56f1d4597ea530b87851aae4dfd70_80224009.png imagette228706951747020778 22870696 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=22870696 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette228706961747020778 22870697 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=22870697 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1357597294: '1747020206_2630970_1357597246_f88b75c7ede1159179fc6f5aa1634731_rle_crop_3793819533_0.png', 1357597445: '1747020446_2637781_1357597368_7042ae77d33fefba219f09f764d114c3_rle_crop_3793820655_0.png', 1357597446: '1747020446_2637781_1357597368_7042ae77d33fefba219f09f764d114c3_rle_crop_3793820656_0.png', 1357597447: '1747020446_2637781_1357597366_845b0cda5e1087a7afa21fa95b0a2c97_rle_crop_3793820664_0.png', 1357597448: '1747020446_2637781_1357597365_b55aeb7f6f7e6a9ccdcc13059334b894_rle_crop_3793820678_0.png', 1357597449: '1747020446_2637781_1357597365_b55aeb7f6f7e6a9ccdcc13059334b894_rle_crop_3793820684_0.png', 1357597532: '1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821226_0.png', 1357597533: '1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821218_0.png', 1357597534: '1747020565_2640538_1357597488_bed898ee9e5259a608385237e1a61b53_rle_crop_3793821246_0.png', 1357597536: '1747020565_2640538_1357597488_bed898ee9e5259a608385237e1a61b53_rle_crop_3793821241_0.png', 1357597537: '1747020565_2640538_1357597483_2c563bbec2a0172e0b3ad30540234634_rle_crop_3793821269_0.png', 1357597538: '1747020565_2640538_1357597483_2c563bbec2a0172e0b3ad30540234634_rle_crop_3793821266_0.png', 1357597628: '1747020687_2643484_1357597555_ac5bbbb9ac0a30a2c6c990255fb134b2_rle_crop_3793821751_0.png', 1357597629: '1747020687_2643484_1357597513_69dcb6841544bdf368bd8103a23253dd_rle_crop_3793821799_0.png', 1357597630: '1747020687_2643484_1357597510_1f552bbe68bd96ca45404aa19edfc503_rle_crop_3793821833_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/a229cca437be295db65af88ec6f7aecb_91984137.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/59045fd715aff6b2aa191a8226f3711d_86418872.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/98dc9e3f55a915cc5c260abee5af3500_54949901.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/cc4214a91f5e3a7f90009d44c1f19cb7_250215.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/d2e32f2aef9659671d8d255b6e2e103a_79309199.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/64782421f60cba716db0e443f8c3991c_33724680.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/024d2953d8a3b02d16de0d4cb00e109e_25876934.png change filename to text .wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/83e8daaccb34366a52438d833bd5155b_83587575.png change filename to text .wget -O 9.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/58dfd01938010d8bee5b3927dfdd0722_1052546.png change filename to text .wget -O 10.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/fadb2c0f78126806ee98e4ebdf8d3487_62395736.png change filename to text .wget -O 11.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/ae9e1c5d1bb2ddfa5c191c83e8f3d8c7_36304649.png change filename to text .wget -O 12.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/c24ca7307eb0f2ed01dee0fb6467a4da_29661722.png change filename to text .wget -O 13.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/00d77ef31e45f9fdc763667c9c46128d_76272147.png change filename to text .wget -O 14.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/7c46b8940416398a9dc42e671841bf44_47543093.png change filename to text .imagette228706971747020778/ imagette228706971747020778/1747020446_2637781_1357597366_845b0cda5e1087a7afa21fa95b0a2c97_rle_crop_3793820664_0.png.png imagette228706971747020778/1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821226_0.png.png imagette228706971747020778/1747020687_2643484_1357597555_ac5bbbb9ac0a30a2c6c990255fb134b2_rle_crop_3793821751_0.png.png imagette228706971747020778/1747020687_2643484_1357597513_69dcb6841544bdf368bd8103a23253dd_rle_crop_3793821799_0.png.png imagette228706971747020778/1747020446_2637781_1357597365_b55aeb7f6f7e6a9ccdcc13059334b894_rle_crop_3793820684_0.png.png imagette228706971747020778/1747020446_2637781_1357597365_b55aeb7f6f7e6a9ccdcc13059334b894_rle_crop_3793820678_0.png.png imagette228706971747020778/1747020687_2643484_1357597510_1f552bbe68bd96ca45404aa19edfc503_rle_crop_3793821833_0.png.png imagette228706971747020778/1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821218_0.png.png imagette228706971747020778/1747020565_2640538_1357597483_2c563bbec2a0172e0b3ad30540234634_rle_crop_3793821266_0.png.png imagette228706971747020778/1747020565_2640538_1357597488_bed898ee9e5259a608385237e1a61b53_rle_crop_3793821241_0.png.png imagette228706971747020778/1747020446_2637781_1357597368_7042ae77d33fefba219f09f764d114c3_rle_crop_3793820655_0.png.png imagette228706971747020778/1747020206_2630970_1357597246_f88b75c7ede1159179fc6f5aa1634731_rle_crop_3793819533_0.png.png imagette228706971747020778/1747020446_2637781_1357597368_7042ae77d33fefba219f09f764d114c3_rle_crop_3793820656_0.png.png imagette228706971747020778/1747020565_2640538_1357597483_2c563bbec2a0172e0b3ad30540234634_rle_crop_3793821269_0.png.png imagette228706971747020778/1747020565_2640538_1357597488_bed898ee9e5259a608385237e1a61b53_rle_crop_3793821246_0.png.png imagette228706991747020779/ imagette228707011747020779/ wget -O 15.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/27ea6b2999fe84241a2e8c65deb6d953_80665266.png imagette228706971747020778 22870699 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=22870699 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette228706991747020779 22870701 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=22870701 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette228707011747020779 22870691 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=22870691 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1357597467: '1747020446_2637781_1357597366_845b0cda5e1087a7afa21fa95b0a2c97_rle_crop_3793820672_0.png', 1357597471: '1747020446_2637781_1357597362_d379ff68c8961af01f5463c56040b0c6_rle_crop_3793820694_0.png', 1357597541: '1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821222_0.png', 1357597542: '1747020565_2640538_1357597488_bed898ee9e5259a608385237e1a61b53_rle_crop_3793821243_0.png', 1357597543: '1747020565_2640538_1357597483_2c563bbec2a0172e0b3ad30540234634_rle_crop_3793821262_0.png', 1357597544: '1747020565_2640538_1357597480_d79b209343166e1f5e16f22fe5aa058e_rle_crop_3793821282_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/aa85bcff16196eb57b7d2a185e151d71_73325207.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/4fcd532a4e7a2708af617775acf83ac1_23082701.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/329fe109947cb6008b7f4f13af1af565_51037851.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/e8f0fe87f6143674d6524b6514b3b834_59310175.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/244eeaa4a3c3c03676e8a99600c4e16c_45464572.png change filename to text .imagette228706911747020779/ imagette228706911747020779/1747020446_2637781_1357597362_d379ff68c8961af01f5463c56040b0c6_rle_crop_3793820694_0.png.png imagette228706911747020779/1747020565_2640538_1357597480_d79b209343166e1f5e16f22fe5aa058e_rle_crop_3793821282_0.png.png imagette228706911747020779/1747020446_2637781_1357597366_845b0cda5e1087a7afa21fa95b0a2c97_rle_crop_3793820672_0.png.png imagette228706911747020779/1747020565_2640538_1357597483_2c563bbec2a0172e0b3ad30540234634_rle_crop_3793821262_0.png.png imagette228706911747020779/1747020565_2640538_1357597488_bed898ee9e5259a608385237e1a61b53_rle_crop_3793821243_0.png.png imagette228706911747020779/1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821222_0.png.png wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/15f20dadca66e164018fabf8067e098e_14454533.png imagette228706911747020779 22870692 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=22870692 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1357597288: '1747020206_2630970_1357597240_4435eba11e60ea1d0861914c29eeb126_rle_crop_3793819554_0.png', 1357597438: '1747020446_2637781_1357597370_15ce4b80774ed41d768d2119f37e3149_rle_crop_3793820646_0.png', 1357597439: '1747020446_2637781_1357597370_15ce4b80774ed41d768d2119f37e3149_rle_crop_3793820644_0.png', 1357597440: '1747020446_2637781_1357597365_b55aeb7f6f7e6a9ccdcc13059334b894_rle_crop_3793820685_0.png', 1357597528: '1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821220_0.png', 1357597530: '1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821224_0.png', 1357597531: '1747020565_2640538_1357597488_bed898ee9e5259a608385237e1a61b53_rle_crop_3793821242_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/149ca0ae374bec1fe9c743a8d6328f70_56453143.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/a42fc2e4c07f754fdcab16282a57c60e_62621462.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/c1babd79173b055be7c1c6d656eab973_59262463.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/6bfb0ea798c3a1cca43a36a9df759efe_9146348.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/63c927014145314467ed0f5845073f0c_13724631.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/7a915f5fec42c80175126feca8f6f9a6_32086409.png change filename to text .imagette228706921747020780/ imagette228706921747020780/1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821220_0.png.png imagette228706921747020780/1747020206_2630970_1357597240_4435eba11e60ea1d0861914c29eeb126_rle_crop_3793819554_0.png.png imagette228706921747020780/1747020446_2637781_1357597370_15ce4b80774ed41d768d2119f37e3149_rle_crop_3793820646_0.png.png imagette228706921747020780/1747020565_2640538_1357597489_9a3638bff5da3976775b85c828ffc4a7_rle_crop_3793821224_0.png.png imagette228706921747020780/1747020446_2637781_1357597365_b55aeb7f6f7e6a9ccdcc13059334b894_rle_crop_3793820685_0.png.png imagette228706921747020780/1747020446_2637781_1357597370_15ce4b80774ed41d768d2119f37e3149_rle_crop_3793820644_0.png.png imagette228706921747020780/1747020565_2640538_1357597488_bed898ee9e5259a608385237e1a61b53_rle_crop_3793821242_0.png.png wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/08bee696113a0a904c6e10e14528b07b_86369629.png imagette228706921747020780 22870693 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=22870693 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1357597622: '1747020687_2643484_1357597515_e613e5f3c6bed05efa725e40a785a681_rle_crop_3793821765_0.png', 1357597623: '1747020687_2643484_1357597514_6bd61cc845c682b90f4e81f9c35b71ea_rle_crop_3793821778_0.png', 1357597624: '1747020687_2643484_1357597514_6bd61cc845c682b90f4e81f9c35b71ea_rle_crop_3793821779_0.png', 1357597625: '1747020687_2643484_1357597514_6bd61cc845c682b90f4e81f9c35b71ea_rle_crop_3793821780_0.png', 1357597626: '1747020687_2643484_1357597513_69dcb6841544bdf368bd8103a23253dd_rle_crop_3793821801_0.png', 1357597627: '1747020687_2643484_1357597512_625c0e8f8241fee62f18240fe905b472_rle_crop_3793821812_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/cb8d671e845c9ee661ce79af097a6c97_52745511.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/f821daa4fec5523e4db0d020d740740f_25657231.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/afd974e9c92d23378ed06bb5d85861d5_55411446.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/8092612a3d8e831df4188dc507926a14_18473134.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/d1f93710d1589dc00be9757900d9290d_24786610.png change filename to text .imagette228706931747020780/ imagette228706931747020780/1747020687_2643484_1357597512_625c0e8f8241fee62f18240fe905b472_rle_crop_3793821812_0.png.png imagette228706931747020780/1747020687_2643484_1357597515_e613e5f3c6bed05efa725e40a785a681_rle_crop_3793821765_0.png.png imagette228706931747020780/1747020687_2643484_1357597514_6bd61cc845c682b90f4e81f9c35b71ea_rle_crop_3793821779_0.png.png imagette228706931747020780/1747020687_2643484_1357597513_69dcb6841544bdf368bd8103a23253dd_rle_crop_3793821801_0.png.png imagette228706931747020780/1747020687_2643484_1357597514_6bd61cc845c682b90f4e81f9c35b71ea_rle_crop_3793821778_0.png.png imagette228706931747020780/1747020687_2643484_1357597514_6bd61cc845c682b90f4e81f9c35b71ea_rle_crop_3793821780_0.png.png wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/4c8a094afa82ad71112d108fbb7a88f4_20606089.png imagette228706931747020780 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=22870688 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/22870702,22870703,22870704,22870705,22870706,22870707,22870708,22870709,22870710,22870711,22870712,22870713?tags=autre_refus,Carton_brun,Teint_Dans_La_Masse,Carton_gris,kraft,plastique,metal,cartonnette,papier,mal_croppe,environnement,flou your option no_mail is active, we will not send the real mail to your client args[1357597603] : ('0.040974598516487964',) no score found for photo 1357597603 We are sending mail with results at report@fotonower.com refus_total : 0.040974598516487964 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=22870688 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_P22870688_12-05-2025_05_32_58.pdf results_Auto_P22870688_12-05-2025_05_32_58.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22870688_12-05-2025_05_32_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','22870688','results_Auto_P22870688_12-05-2025_05_32_58.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22870688_12-05-2025_05_32_58.pdf','pdf','','0.13','0.040974598516487964') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22870688]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1357597603] map_info['map_portfolio_photo'] : {22870688: [1357597603, 1357597555, 1357597553, 1357597549, 1357597516, 1357597515, 1357597514, 1357597513, 1357597512, 1357597510, 1357597490, 1357597489, 1357597488, 1357597483, 1357597480, 1357597422, 1357597421, 1357597418, 1357597400, 1357597399, 1357597398, 1357597395, 1357597393, 1357597371, 1357597370, 1357597368, 1357597366, 1357597365, 1357597362, 1357597341, 1357597339, 1357597335, 1357597331, 1357597272, 1357597268, 1357597266, 1357597248, 1357597247, 1357597246, 1357597244, 1357597240, 1357597216, 1357597214, 1357597213, 1357597211, 1357597103, 1357596683]} final : False mtd_id 4302 list_pids : [1357597603] 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, '2819020') ('4302', '22870688', '1357597603', None, None, None, None, None, '2819020') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 1 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', '22870688', '1357597603', None, None, None, None, None, '2819020')] time used for this insertion : 0.011844158172607422 save_final save missing photos in datou_result : time spend for datou_step_exec : 3.452610492706299 time spend to save output : 0.012006998062133789 total time spend for step 4 : 3.4646174907684326 step5:split_time_score Mon May 12 05:33:01 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : ['22870688'] 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 : [('22870688',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22870688) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1357597603: {'path': 'temp/1747020778_801179_1357597603_145d5f7cdeef5309b6cf17c9f965f01c.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 = 22870688; (('arc_en_ciel_jrm_live',),) 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 = 22870688 group by h (('05', 47),) 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=22870688 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 (22870688) 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 (22870688) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 12052025 22870688 Nombre de photos uploadées : 47 / 23040 (0%) 12052025 22870688 Nombre de photos taguées (types de déchets): 0 / 47 (0%) 12052025 22870688 Nombre de photos taguées (volume) : 0 / 47 (0%) [{'photo_id': 1357596683, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/df34a00768996af3f1decf85ac4ddee6.jpg', 'username': None, 'uploaded_at': 1747019827, 'text': 'image_12052025_05_15_54_10135.jpg'}, {'photo_id': 1357597216, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/e878a40874895f9a4368ed13fca96e01.jpg', 'username': None, 'uploaded_at': 1747020067, 'text': 'image_12052025_05_16_05_10154.jpg'}, {'photo_id': 1357597103, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/ecda87d2ac3410984c41f5e4a11b3a91.jpg', 'username': None, 'uploaded_at': 1747019888, 'text': 'image_12052025_05_17_14_10134.jpg'}, {'photo_id': 1357597214, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/5/12/d6808198ab2609805d27a44143e33585.jpg', 'username': None, 'uploaded_at': 1747020067, 'text': 'image_12052025_05_20_04_9138.jpg'}] 0 [] elapsed_time : load_data_split_time_score 1.1920928955078125e-06 elapsed_time : order_list_meta_photo_and_scores 5.245208740234375e-06 ??????????????????????????????????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.0019068717956542969 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 218, 22870688, '2025-05-12' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1796685,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.02406454086303711 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= 1796685 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1796685, 'dashboard_run_id': 1804181, 'mtr_portfolio_id': 22870059, 'dashboard_result_id': 10477894, '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_P22870059_12-05-2025_05_16_29.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 22870060, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22870061, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22870062, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22870063, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22870064, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22870065, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22870066, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22870067, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22870068, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22870069, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22870070, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22870071, 'pht': 3726}}"}, {'dashboat_entry_day': 1796685, 'dashboard_run_id': 1804181, 'mtr_portfolio_id': 22870688, 'dashboard_result_id': 10477895, '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_P22870688_12-05-2025_05_30_58.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22870690, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22870691, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22870692, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22870693, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22870694, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22870695, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22870696, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22870697, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22870698, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22870699, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22870700, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22870701, 'pht': 3726}}"}, {'dashboat_entry_day': 1796685, 'dashboard_run_id': 1804181, 'mtr_portfolio_id': 22870938, 'dashboard_result_id': 10477896, 'hashtag': '_______JRM', 'completion_json': "{'max_time_prod_two_photos': 0}"}] 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 = 22870059 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': 2818985, 'mtr_portfolio_id': 22870059, 'created_at': datetime.datetime(2025, 5, 12, 5, 16, 29), 'result': '0.03814272581624625', 'result_long': None, 'result_double': None}] Qualite : 0.03814272581624625 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22870059 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22870059_12-05-2025_05_16_29.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22870059 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_P22870059_12-05-2025_05_16_29.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 22870060, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22870061, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22870062, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22870063, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22870064, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22870065, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22870066, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22870067, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22870068, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22870069, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22870070, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22870071, 'pht': 3726}}" where mtr_portfolio_id = 22870059 and dashboard_run_id = 1804181 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`=22870059 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10477894, 0.03814272581624625, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22870059_12-05-2025_05_16_29.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 22870060, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22870061, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22870062, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22870063, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22870064, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22870065, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22870066, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22870067, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22870068, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22870069, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22870070, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22870071, '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 = 22870688 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': 2819020, 'mtr_portfolio_id': 22870688, 'created_at': datetime.datetime(2025, 5, 12, 5, 32, 57), 'result': '0.040974598516487964', 'result_long': None, 'result_double': None}] Qualite : 0.040974598516487964 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22870688 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22870688_12-05-2025_05_32_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22870688 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_P22870688_12-05-2025_05_32_58.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22870690, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22870691, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22870692, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22870693, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22870694, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22870695, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22870696, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22870697, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22870698, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22870699, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22870700, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22870701, 'pht': 3726}}" where mtr_portfolio_id = 22870688 and dashboard_run_id = 1804181 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`=22870688 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10477895, 0.040974598516487964, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22870688_12-05-2025_05_32_58.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22870690, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22870691, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22870692, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22870693, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22870694, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22870695, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22870696, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22870697, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22870698, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22870699, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22870700, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22870701, '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 = 22870938 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 22870938 AND result is not null and result<>"None" and result=0.0 AND mtd_id=4302 ORDER BY created_at desc LIMIT 1 list_result_datou : [] select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22870938 order by file_id desc limit 1 select url from MTRUser.mtr_files where text like '%22870938%' order by file_id desc limit 1 find url: select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22870938 order by id desc limit 1 update MTRPhoto.dashboard_results set completion_json = "{'max_time_prod_two_photos': 0, 'url_report': ''}" where mtr_portfolio_id = 22870938 and dashboard_run_id = 1804181 SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22870059,22870688,22870938) result : ((1357593698,), (1357593717,), (1357593847,), (1357593880,), (1357593915,), (1357593940,), (1357594109,), (1357594311,), (1357594320,), (1357594322,), (1357594330,), (1357594594,), (1357594651,), (1357594652,), (1357594653,), (1357594656,), (1357594769,), (1357594771,), (1357594834,), (1357594860,), (1357594862,), (1357594952,), (1357594953,), (1357594955,), (1357594959,), (1357594984,), (1357594987,), (1357595394,), (1357595430,), (1357595457,), (1357595532,), (1357595561,), (1357595588,), (1357595936,), (1357595938,), (1357595939,), (1357595940,), (1357595941,), (1357596122,), (1357596167,), (1357596185,), (1357596271,), (1357596448,), (1357596683,), (1357597103,), (1357597211,), (1357597213,), (1357597214,), (1357597216,), (1357597240,), (1357597244,), (1357597246,), (1357597247,), (1357597248,), (1357597266,), (1357597268,), (1357597272,), (1357597331,), (1357597335,), (1357597339,), (1357597341,), (1357597362,), (1357597365,), (1357597366,), (1357597368,), (1357597370,), (1357597371,), (1357597393,), (1357597395,), (1357597398,), (1357597399,), (1357597400,), (1357597418,), (1357597421,), (1357597422,), (1357597480,), (1357597483,), (1357597488,), (1357597489,), (1357597490,), (1357597510,), (1357597512,), (1357597513,), (1357597514,), (1357597515,), (1357597516,), (1357597549,), (1357597553,), (1357597555,), (1357597603,), (1357597599,), (1357597601,), (1357597602,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'12052025': {'nb_upload': 47, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22870688]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1357597603] map_info['map_portfolio_photo'] : {22870688: [1357597603, 1357597555, 1357597553, 1357597549, 1357597516, 1357597515, 1357597514, 1357597513, 1357597512, 1357597510, 1357597490, 1357597489, 1357597488, 1357597483, 1357597480, 1357597422, 1357597421, 1357597418, 1357597400, 1357597399, 1357597398, 1357597395, 1357597393, 1357597371, 1357597370, 1357597368, 1357597366, 1357597365, 1357597362, 1357597341, 1357597339, 1357597335, 1357597331, 1357597272, 1357597268, 1357597266, 1357597248, 1357597247, 1357597246, 1357597244, 1357597240, 1357597216, 1357597214, 1357597213, 1357597211, 1357597103, 1357596683]} final : True mtd_id 4302 list_pids : [1357597603] Looping around the photos to save general results len do output : 1 /22870688Didn'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, '2819020') ('4302', '22870688', '1357597603', None, None, None, None, None, '2819020') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 2 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, '22870688', 'None', None, None, None, None, '2819020'), ('4302', '22870688', '1357597603', None, None, None, None, None, '2819020')] time used for this insertion : 0.012300968170166016 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.1054341793060303 time spend to save output : 0.012492656707763672 total time spend for step 5 : 1.117926836013794 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 (2819020) 1.83user 2.46system 0:08.45elapsed 50%CPU (0avgtext+0avgdata 156788maxresident)k 128inputs+5200outputs (24major+62306minor)pagefaults 0swaps