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 : 1798464 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 (2746177) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (2746177) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297260 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['2746177'] with mtr_portfolio_ids : ['22297260'] and first list_photo_ids : [] new path : /proc/1798464/ Name: python3 Umask: 0002 State: R (running) Tgid: 1798464 Ngid: 0 Pid: 1798464 PPid: 1798463 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 1798464 NSpid: 1798464 NSpgid: 1795763 NSsid: 1795763 VmPeak: 1106932 kB VmSize: 1106932 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 97532 kB VmRSS: 97532 kB RssAnon: 59772 kB RssFile: 37760 kB RssShmem: 0 kB VmData: 865680 kB VmStk: 132 kB VmExe: 2644 kB VmLib: 130468 kB VmPTE: 604 kB VmSwap: 0 kB HugetlbPages: 0 kB CoreDumping: 0 THP_enabled: 1 Threads: 1 SigQ: 0/63054 SigPnd: 0000000000000000 ShdPnd: 0000000000000000 SigBlk: 0000000000000000 SigIgn: 0000000001001000 SigCgt: 0000000180000002 CapInh: 0000000000000000 CapPrm: 0000000000000000 CapEff: 0000000000000000 CapBnd: 000001ffffffffff CapAmb: 0000000000000000 NoNewPrivs: 0 Seccomp: 0 Seccomp_filters: 0 Speculation_Store_Bypass: thread vulnerable SpeculationIndirectBranch: conditional enabled Cpus_allowed: ffffffff,ffffffff,ffffffff,ffffffff Cpus_allowed_list: 0-127 Mems_allowed: 00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001 Mems_allowed_list: 0 voluntary_ctxt_switches: 50 nonvoluntary_ctxt_switches: 88 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '1798464', 'Ngid': '0', 'Pid': '1798464', 'PPid': '1798463', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '1798464', 'NSpid': '1798464', 'NSpgid': '1795763', 'NSsid': '1795763', 'VmPeak': '1106932 kB', 'VmSize': '1106932 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '97532 kB', 'VmRSS': '97532 kB', 'RssAnon': '59772 kB', 'RssFile': '37760 kB', 'RssShmem': '0 kB', 'VmData': '865680 kB', 'VmStk': '132 kB', 'VmExe': '2644 kB', 'VmLib': '130468 kB', 'VmPTE': '604 kB', 'VmSwap': '0 kB', 'HugetlbPages': '0 kB', 'CoreDumping': '0', 'THP_enabled': '1', 'Threads': '1', 'SigQ': '0/63054', 'SigPnd': '0000000000000000', 'ShdPnd': '0000000000000000', 'SigBlk': '0000000000000000', 'SigIgn': '0000000001001000', 'SigCgt': '0000000180000002', 'CapInh': '0000000000000000', 'CapPrm': '0000000000000000', 'CapEff': '0000000000000000', 'CapBnd': '000001ffffffffff', 'CapAmb': '0000000000000000', 'NoNewPrivs': '0', 'Seccomp': '0', 'Seccomp_filters': '0', 'Speculation_Store_Bypass': 'thread vulnerable', 'SpeculationIndirectBranch': 'conditional enabled', 'Cpus_allowed': 'ffffffff,ffffffff,ffffffff,ffffffff', 'Cpus_allowed_list': '0-127', 'Mems_allowed': '00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001', 'Mems_allowed_list': '0', 'voluntary_ctxt_switches': '50', 'nonvoluntary_ctxt_switches': '88'} ('datou_batch_current', '1798464', '1106932', '0', '1106932', '865680', '97532', b'', 'marlene', '2746177') 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 (22297260) 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 (2746177 ) ) 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 (22297260) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1351863935, 'portfolio_id': 22297260}, {'photo_id': 1351863872, 'portfolio_id': 22297260}, {'photo_id': 1351863810, 'portfolio_id': 22297260}, {'photo_id': 1351863735, 'portfolio_id': 22297260}, {'photo_id': 1351863550, 'portfolio_id': 22297260}, {'photo_id': 1351863526, 'portfolio_id': 22297260}, {'photo_id': 1351863490, 'portfolio_id': 22297260}, {'photo_id': 1351863459, 'portfolio_id': 22297260}, {'photo_id': 1351863444, 'portfolio_id': 22297260}, {'photo_id': 1351863003, 'portfolio_id': 22297260}, {'photo_id': 1351862953, 'portfolio_id': 22297260}, {'photo_id': 1351862916, 'portfolio_id': 22297260}, {'photo_id': 1351862701, 'portfolio_id': 22297260}, {'photo_id': 1351862647, 'portfolio_id': 22297260}, {'photo_id': 1351862611, 'portfolio_id': 22297260}, {'photo_id': 1351862577, 'portfolio_id': 22297260}, {'photo_id': 1351862540, 'portfolio_id': 22297260}, {'photo_id': 1351862498, 'portfolio_id': 22297260}, {'photo_id': 1351862319, 'portfolio_id': 22297260}, {'photo_id': 1351862295, 'portfolio_id': 22297260}, {'photo_id': 1351862278, 'portfolio_id': 22297260}, {'photo_id': 1351862270, 'portfolio_id': 22297260}, {'photo_id': 1351862257, 'portfolio_id': 22297260}, {'photo_id': 1351862243, 'portfolio_id': 22297260}, {'photo_id': 1351862181, 'portfolio_id': 22297260}, {'photo_id': 1351862173, 'portfolio_id': 22297260}, {'photo_id': 1351862149, 'portfolio_id': 22297260}, {'photo_id': 1351861981, 'portfolio_id': 22297260}, {'photo_id': 1351861973, 'portfolio_id': 22297260}, {'photo_id': 1351861966, 'portfolio_id': 22297260}] map_portfolio_id_photo_id: {22297260: [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444, 1351863003, 1351862953, 1351862916, 1351862701, 1351862647, 1351862611, 1351862577, 1351862540, 1351862498, 1351862319, 1351862295, 1351862278, 1351862270, 1351862257, 1351862243, 1351862181, 1351862173, 1351862149, 1351861981, 1351861973, 1351861966]} ##### 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.020018815994262695 #### 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 Fri Apr 11 20:08:59 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22297260) 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 : 22297260 get user id for portfolio 22297260 get sub ptf for main ptf 22297260, type 3726 and hashtags ['flou', 'cartonnette', 'Carton_brun', 'kraft', 'autre_refus', 'environnement', 'Teint_Dans_La_Masse', 'metal', 'papier', 'mal_croppe', 'Carton_gris', 'plastique'] SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22297260 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('flou','cartonnette','Carton_brun','kraft','autre_refus','environnement','Teint_Dans_La_Masse','metal','papier','mal_croppe','Carton_gris','plastique')) AND mptpi.`min_score`=0.5 SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22297260 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('flou','cartonnette','Carton_brun','kraft','autre_refus','environnement','Teint_Dans_La_Masse','metal','papier','mal_croppe','Carton_gris','plastique')) AND mptpi.`min_score`=0.5 To do returned map {'cartonnette': {'main_port_id': 22297260, 'sub_port_id': 22297294, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761320, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'Carton_gris': {'main_port_id': 22297260, 'sub_port_id': 22297295, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761321, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'Teint_Dans_La_Masse': {'main_port_id': 22297260, 'sub_port_id': 22297296, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761322, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'flou': {'main_port_id': 22297260, 'sub_port_id': 22297297, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761323, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'autre_refus': {'main_port_id': 22297260, 'sub_port_id': 22297298, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761324, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'plastique': {'main_port_id': 22297260, 'sub_port_id': 22297299, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761325, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'mal_croppe': {'main_port_id': 22297260, 'sub_port_id': 22297300, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761326, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'environnement': {'main_port_id': 22297260, 'sub_port_id': 22297301, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761327, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'kraft': {'main_port_id': 22297260, 'sub_port_id': 22297302, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761328, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'papier': {'main_port_id': 22297260, 'sub_port_id': 22297303, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761329, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'Carton_brun': {'main_port_id': 22297260, 'sub_port_id': 22297304, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761330, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}, 'metal': {'main_port_id': 22297260, 'sub_port_id': 22297305, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761331, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297294 , 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=22297260 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 (22297294) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297295 , 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=22297260 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 (22297295) result : ((1351863729,), (1351863736,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297296 , 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=22297260 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 (22297296) result : ((1351863690,), (1351863709,), (1351863711,), (1351863712,), (1351863713,), (1351863714,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297297 , 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=22297260 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 (22297297) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297298 , 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=22297260 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 (22297298) result : ((1351863725,),) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297299 , 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=22297260 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 (22297299) result : ((1351863762,), (1351863765,), (1351863766,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297300 , 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=22297260 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 (22297300) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297301 , 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=22297260 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 (22297301) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297302 , 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=22297260 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 (22297302) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297303 , 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=22297260 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 (22297303) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297304 , 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=22297260 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 (22297304) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22297305 , 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=22297260 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 (22297305) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22297260) result : ((1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") To do ! Use context local managing function ! SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22297260 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('flou','cartonnette','Carton_brun','kraft','autre_refus','environnement','Teint_Dans_La_Masse','metal','papier','mal_croppe','Carton_gris','plastique')) AND mptpi.`min_score`=0.5 SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22297260 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('flou','cartonnette','Carton_brun','kraft','autre_refus','environnement','Teint_Dans_La_Masse','metal','papier','mal_croppe','Carton_gris','plastique')) AND mptpi.`min_score`=0.5 To do returned map {'cartonnette': {'main_port_id': 22297260, 'sub_port_id': 22297306, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761332, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'Carton_gris': {'main_port_id': 22297260, 'sub_port_id': 22297307, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761333, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'Teint_Dans_La_Masse': {'main_port_id': 22297260, 'sub_port_id': 22297308, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761334, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'flou': {'main_port_id': 22297260, 'sub_port_id': 22297309, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761335, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'autre_refus': {'main_port_id': 22297260, 'sub_port_id': 22297310, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761336, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'plastique': {'main_port_id': 22297260, 'sub_port_id': 22297311, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761337, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'mal_croppe': {'main_port_id': 22297260, 'sub_port_id': 22297312, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761338, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'environnement': {'main_port_id': 22297260, 'sub_port_id': 22297313, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761339, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'kraft': {'main_port_id': 22297260, 'sub_port_id': 22297314, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761340, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'papier': {'main_port_id': 22297260, 'sub_port_id': 22297315, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761341, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'Carton_brun': {'main_port_id': 22297260, 'sub_port_id': 22297316, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761342, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 5, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}, 'metal': {'main_port_id': 22297260, 'sub_port_id': 22297317, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14761343, 'last_updated_at': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_desc': datetime.datetime(2025, 4, 11, 20, 7), 'last_updated_at_asc': datetime.datetime(2025, 4, 11, 20, 5, 3)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297306,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297294 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297307,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297295 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297308,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297296 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297309,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297297 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297310,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297298 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297311,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297299 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297312,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297300 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297313,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297301 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297314,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297302 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297315,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297303 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297316,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297304 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22297317,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22297305 lien utilise dans velours : https://www.fotonower.com/velours/22297306,22297307,22297308,22297309,22297310,22297311,22297312,22297313,22297314,22297315,22297316,22297317?tags=cartonnette,Carton_gris,Teint_Dans_La_Masse,flou,autre_refus,plastique,mal_croppe,environnement,kraft,papier,Carton_brun,metal After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22297260]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444] map_info['map_portfolio_photo'] : {22297260: [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444, 1351863003, 1351862953, 1351862916, 1351862701, 1351862647, 1351862611, 1351862577, 1351862540, 1351862498, 1351862319, 1351862295, 1351862278, 1351862270, 1351862257, 1351862243, 1351862181, 1351862173, 1351862149, 1351861981, 1351861973, 1351861966]} final : False mtd_id 4302 list_pids : [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444] Looping around the photos to save general results len do output : 1 /22297260. 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, '2746177') ('4302', '22297260', '1351863935', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863872', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863810', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863735', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863550', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863526', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863490', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863459', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863444', None, None, None, None, None, '2746177') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 10 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', None, '22297260', "{'cartonnette': 22297294, 'Carton_gris': 22297295, 'Teint_Dans_La_Masse': 22297296, 'flou': 22297297, 'autre_refus': 22297298, 'plastique': 22297299, 'mal_croppe': 22297300, 'environnement': 22297301, 'kraft': 22297302, 'papier': 22297303, 'Carton_brun': 22297304, 'metal': 22297305}", None, None, None, None, '2746177'), ('4302', '22297260', '1351863935', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863872', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863810', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863735', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863550', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863526', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863490', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863459', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863444', None, None, None, None, None, '2746177')] time used for this insertion : 0.017218828201293945 save_final save missing photos in datou_result : time spend for datou_step_exec : 2.4470596313476562 time spend to save output : 0.01759505271911621 total time spend for step 1 : 2.4646546840667725 step2:final Fri Apr 11 20:09: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 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 (22297260) 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 22297260 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1351861981,1351861973,1351861966,1351862181,1351862173,1351862149,1351862319,1351862295,1351862278,1351862270,1351862257,1351862243,1351862701,1351862647,1351862611,1351862577,1351862540,1351862498,1351863003,1351862953,1351862916,1351863550,1351863526,1351863490,1351863459,1351863444,1351863935,1351863872,1351863810,1351863735); 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([22297260]) Inside saveOutput : final : False verbose : True original output for save of step final : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} new output for save of step final : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444] map_info['map_portfolio_photo'] : {22297260: [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444, 1351863003, 1351862953, 1351862916, 1351862701, 1351862647, 1351862611, 1351862577, 1351862540, 1351862498, 1351862319, 1351862295, 1351862278, 1351862270, 1351862257, 1351862243, 1351862181, 1351862173, 1351862149, 1351861981, 1351861973, 1351861966]} final : False mtd_id 4302 list_pids : [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444] Looping around the photos to save general results len do output : 9 /1351863935.Didn't retrieve data . /1351863872.Didn't retrieve data . /1351863810.Didn't retrieve data . /1351863735.Didn't retrieve data . /1351863550.Didn't retrieve data . /1351863526.Didn't retrieve data . /1351863490.Didn't retrieve data . /1351863459.Didn't retrieve data . /1351863444.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, '2746177') ('4302', '22297260', '1351863935', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863872', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863810', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863735', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863550', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863526', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863490', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863459', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863444', None, None, None, None, None, '2746177') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 27 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', '22297260', '1351863935', '0.03767567242816349', None, None, None, None, '2746177'), ('4302', '22297260', '1351863872', '0.03767567242816349', None, None, None, None, '2746177'), ('4302', '22297260', '1351863810', '0.03767567242816349', None, None, None, None, '2746177'), ('4302', '22297260', '1351863735', '0.03767567242816349', None, None, None, None, '2746177'), ('4302', '22297260', '1351863550', '0.03767567242816349', None, None, None, None, '2746177'), ('4302', '22297260', '1351863526', '0.03767567242816349', None, None, None, None, '2746177'), ('4302', '22297260', '1351863490', '0.03767567242816349', None, None, None, None, '2746177'), ('4302', '22297260', '1351863459', '0.03767567242816349', None, None, None, None, '2746177'), ('4302', '22297260', '1351863444', '0.03767567242816349', None, None, None, None, '2746177')] time used for this insertion : 0.017322778701782227 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.4365675449371338 time spend to save output : 0.01783013343811035 total time spend for step 2 : 0.45439767837524414 step3:velours_tree Fri Apr 11 20:09: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 : {22297260: [{'cartonnette': 22297294, 'Carton_gris': 22297295, 'Teint_Dans_La_Masse': 22297296, 'flou': 22297297, 'autre_refus': 22297298, 'plastique': 22297299, 'mal_croppe': 22297300, 'environnement': 22297301, 'kraft': 22297302, 'papier': 22297303, 'Carton_brun': 22297304, 'metal': 22297305}]} input_args_next_step : {22297260: ()} output_args : {22297260: [{'cartonnette': 22297294, 'Carton_gris': 22297295, 'Teint_Dans_La_Masse': 22297296, 'flou': 22297297, 'autre_refus': 22297298, 'plastique': 22297299, 'mal_croppe': 22297300, 'environnement': 22297301, 'kraft': 22297302, 'papier': 22297303, 'Carton_brun': 22297304, 'metal': 22297305}]} args : 22297260 depend.output_id : 0 VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :1, first value : ({'cartonnette': 22297294, 'Carton_gris': 22297295, 'Teint_Dans_La_Masse': 22297296, 'flou': 22297297, 'autre_refus': 22297298, 'plastique': 22297299, 'mal_croppe': 22297300, 'environnement': 22297301, 'kraft': 22297302, 'papier': 22297303, 'Carton_brun': 22297304, 'metal': 22297305},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22297260) 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([22297260]) 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.39829349517822266 time spend to save output : 8.249282836914062e-05 total time spend for step 3 : 0.3983759880065918 step4:send_mail_cod Fri Apr 11 20:09:02 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed 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 : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} input_args_next_step : {1351863935: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863935 depend.output_id : 0 input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863872 depend.output_id : 0 input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863810 depend.output_id : 0 input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863735 depend.output_id : 0 input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863550 depend.output_id : 0 input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863526 depend.output_id : 0 input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863490 depend.output_id : 0 input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863459 depend.output_id : 0 input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ()} output_args : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',)} args : 1351863444 depend.output_id : 0 Inconsistent number of input and output, step which parrallelize and manage error in input by avoiding sending an output for this data can't be used in tree dependencies of input and output complete output_args for input 3 : {22297260: [{'cartonnette': 22297294, 'Carton_gris': 22297295, 'Teint_Dans_La_Masse': 22297296, 'flou': 22297297, 'autre_refus': 22297298, 'plastique': 22297299, 'mal_croppe': 22297300, 'environnement': 22297301, 'kraft': 22297302, 'papier': 22297303, 'Carton_brun': 22297304, 'metal': 22297305}]} input_args_next_step : {1351863935: ('0.03767567242816349',), 1351863872: ('0.03767567242816349',), 1351863810: ('0.03767567242816349',), 1351863735: ('0.03767567242816349',), 1351863550: ('0.03767567242816349',), 1351863526: ('0.03767567242816349',), 1351863490: ('0.03767567242816349',), 1351863459: ('0.03767567242816349',), 1351863444: ('0.03767567242816349',), 22297260: ()} output_args : {22297260: [{'cartonnette': 22297294, 'Carton_gris': 22297295, 'Teint_Dans_La_Masse': 22297296, 'flou': 22297297, 'autre_refus': 22297298, 'plastique': 22297299, 'mal_croppe': 22297300, 'environnement': 22297301, 'kraft': 22297302, 'papier': 22297303, 'Carton_brun': 22297304, 'metal': 22297305}]} args : 22297260 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 :10, first value : ('0.03767567242816349',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22297260) 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 (1351863935,1351863872,1351863810,1351863735,1351863550,1351863526,1351863490,1351863459,1351863444) Found this number of photos: 9 ##### Call download_photos : nb_thread : 5 begin to download photo : 1351863444 begin to download photo : 1351863490 begin to download photo : 1351863550 begin to download photo : 1351863810 begin to download photo : 1351863935 download finish for photo 1351863444 begin to download photo : 1351863459 download finish for photo 1351863935 download finish for photo 1351863490 begin to download photo : 1351863526 download finish for photo 1351863810 begin to download photo : 1351863872 download finish for photo 1351863550 begin to download photo : 1351863735 download finish for photo 1351863459 download finish for photo 1351863526 download finish for photo 1351863872 download finish for photo 1351863735 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos imagette222972941744394942/ imagette222972971744394942/ length of list_filenames : 9 ; length of list_pids : 9 ; length of list_args : 9 results_Auto_P22297260_11-04-2025_20_09_02.pdf 22297294 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=22297294 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette222972941744394942 22297297 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=22297297 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette222972971744394942 22297298 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=22297298 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351863725: '1744394654_2219864_1351861973_a14b178b31e35e70127f147d065a1c14_rle_crop_3758661229_0.png'} change filename to text .imagette222972981744394942/ imagette222972981744394942/1744394654_2219864_1351861973_a14b178b31e35e70127f147d065a1c14_rle_crop_3758661229_0.png.png wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/d018b69a6338c5ffad6b86d0e887a43d_12417971.png imagette222972981744394942 22297299 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=22297299 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351863762: '1744394654_2219864_1351861981_7ac61c9025417dd0a7eb14675e61a3e8_rle_crop_3758660432_0.png', 1351863765: '1744394654_2219864_1351861973_a14b178b31e35e70127f147d065a1c14_rle_crop_3758661226_0.png', 1351863766: '1744394654_2219864_1351861966_367d9e980f32c211dc2c027cb483da9f_rle_crop_3758662974_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/c8188139a99a3395aabca7013668cb28_75263883.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/b74996b72e6cd90bc4b672b51da9bc61_5771717.png change filename to text .imagette222972991744394942/ imagette222972991744394942/1744394654_2219864_1351861973_a14b178b31e35e70127f147d065a1c14_rle_crop_3758661226_0.png.png imagette222972991744394942/1744394654_2219864_1351861966_367d9e980f32c211dc2c027cb483da9f_rle_crop_3758662974_0.png.png imagette222972991744394942/1744394654_2219864_1351861981_7ac61c9025417dd0a7eb14675e61a3e8_rle_crop_3758660432_0.png.png imagette222973001744394942/ imagette222973021744394942/ imagette222973051744394942/ wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/02ba79407b6ae18a73de47fba254595a_39492128.png imagette222972991744394942 22297300 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=22297300 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette222973001744394942 22297302 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=22297302 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette222973021744394942 22297305 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=22297305 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette222973051744394942 22297295 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=22297295 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351863729: '1744394654_2219864_1351862181_f8d6c0ac83df26f2add3a01cf5d69105_rle_crop_3758658184_0.png', 1351863736: '1744394654_2219864_1351861981_7ac61c9025417dd0a7eb14675e61a3e8_rle_crop_3758660427_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/172f5ac3e49af8e06f26706e93e13357_61676207.png change filename to text .imagette222972951744394942/ imagette222972951744394942/1744394654_2219864_1351861981_7ac61c9025417dd0a7eb14675e61a3e8_rle_crop_3758660427_0.png.png imagette222972951744394942/1744394654_2219864_1351862181_f8d6c0ac83df26f2add3a01cf5d69105_rle_crop_3758658184_0.png.png wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/f1549a1cb0c21b0cb99212b9d1143ee1_86518825.png imagette222972951744394942 22297296 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=22297296 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351863690: '1744394714_2221041_1351862173_e675d37c2123dc2f88eec02c3e3b76d9_rle_crop_3758661322_0.png', 1351863709: '1744394654_2219864_1351862181_f8d6c0ac83df26f2add3a01cf5d69105_rle_crop_3758658181_0.png', 1351863711: '1744394654_2219864_1351862181_f8d6c0ac83df26f2add3a01cf5d69105_rle_crop_3758658182_0.png', 1351863712: '1744394654_2219864_1351862181_f8d6c0ac83df26f2add3a01cf5d69105_rle_crop_3758658183_0.png', 1351863713: '1744394654_2219864_1351861981_7ac61c9025417dd0a7eb14675e61a3e8_rle_crop_3758660430_0.png', 1351863714: '1744394654_2219864_1351861973_a14b178b31e35e70127f147d065a1c14_rle_crop_3758661231_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/8a6cdbe53d3b7971f30003fd7feb81ac_22505807.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/098237c4c8d695c074e054a3b0fe7479_85199634.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/466703c5abdff6660b083605c31a59c0_61869117.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/047bf9cbf5bbb74a8bb98faf38c18bb9_66008939.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/cac7c404dffa4556695bec248b17a0e7_51115951.png change filename to text .imagette222972961744394943/ imagette222972961744394943/1744394714_2221041_1351862173_e675d37c2123dc2f88eec02c3e3b76d9_rle_crop_3758661322_0.png.png imagette222972961744394943/1744394654_2219864_1351862181_f8d6c0ac83df26f2add3a01cf5d69105_rle_crop_3758658182_0.png.png imagette222972961744394943/1744394654_2219864_1351862181_f8d6c0ac83df26f2add3a01cf5d69105_rle_crop_3758658181_0.png.png imagette222972961744394943/1744394654_2219864_1351862181_f8d6c0ac83df26f2add3a01cf5d69105_rle_crop_3758658183_0.png.png imagette222972961744394943/1744394654_2219864_1351861981_7ac61c9025417dd0a7eb14675e61a3e8_rle_crop_3758660430_0.png.png imagette222972961744394943/1744394654_2219864_1351861973_a14b178b31e35e70127f147d065a1c14_rle_crop_3758661231_0.png.png imagette222973041744394943/ wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/37edf4cd92b4a1378528536c5d948ab6_22512960.png imagette222972961744394943 22297304 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=22297304 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette222973041744394943 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=22297260 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/22297306,22297307,22297308,22297309,22297310,22297311,22297312,22297313,22297314,22297315,22297316,22297317?tags=cartonnette,Carton_gris,Teint_Dans_La_Masse,flou,autre_refus,plastique,mal_croppe,environnement,kraft,papier,Carton_brun,metal your option no_mail is active, we will not send the real mail to your client args[1351863935] : ('0.03767567242816349',) no score found for photo 1351863935 We are sending mail with results at report@fotonower.com args[1351863872] : ('0.03767567242816349',) no score found for photo 1351863872 We are sending mail with results at report@fotonower.com args[1351863810] : ('0.03767567242816349',) no score found for photo 1351863810 We are sending mail with results at report@fotonower.com args[1351863735] : ('0.03767567242816349',) no score found for photo 1351863735 We are sending mail with results at report@fotonower.com args[1351863550] : ('0.03767567242816349',) no score found for photo 1351863550 We are sending mail with results at report@fotonower.com args[1351863526] : ('0.03767567242816349',) no score found for photo 1351863526 We are sending mail with results at report@fotonower.com args[1351863490] : ('0.03767567242816349',) no score found for photo 1351863490 We are sending mail with results at report@fotonower.com args[1351863459] : ('0.03767567242816349',) no score found for photo 1351863459 We are sending mail with results at report@fotonower.com args[1351863444] : ('0.03767567242816349',) no score found for photo 1351863444 We are sending mail with results at report@fotonower.com refus_total : 0.03767567242816349 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=22297260 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_P22297260_11-04-2025_20_09_02.pdf results_Auto_P22297260_11-04-2025_20_09_02.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22297260_11-04-2025_20_09_02.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','22297260','results_Auto_P22297260_11-04-2025_20_09_02.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22297260_11-04-2025_20_09_02.pdf','pdf','','0.13','0.03767567242816349') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22297260]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444] map_info['map_portfolio_photo'] : {22297260: [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444, 1351863003, 1351862953, 1351862916, 1351862701, 1351862647, 1351862611, 1351862577, 1351862540, 1351862498, 1351862319, 1351862295, 1351862278, 1351862270, 1351862257, 1351862243, 1351862181, 1351862173, 1351862149, 1351861981, 1351861973, 1351861966]} final : False mtd_id 4302 list_pids : [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444] 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, '2746177') ('4302', '22297260', '1351863935', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863872', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863810', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863735', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863550', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863526', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863490', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863459', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863444', None, None, None, None, None, '2746177') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 9 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', '22297260', '1351863935', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863872', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863810', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863735', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863550', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863526', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863490', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863459', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863444', None, None, None, None, None, '2746177')] time used for this insertion : 0.013506650924682617 save_final save missing photos in datou_result : time spend for datou_step_exec : 2.3818132877349854 time spend to save output : 0.013744831085205078 total time spend for step 4 : 2.3955581188201904 step5:split_time_score Fri Apr 11 20:09:04 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 : ['22297260'] 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 : [('22297260',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22297260) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1351863935: {'path': 'temp/1744394942_1798464_1351863935_e50b4bb4f4a6047b2e0b7889b1749d9b.jpg', 'extension': 'jpg'}, 1351863444: {'path': 'temp/1744394942_1798464_1351863444_5155822abe7473ba3e3214a3b29d1105.jpg', 'extension': 'jpg'}, 1351863459: {'path': 'temp/1744394942_1798464_1351863459_458964be8f99da5a054167573de17bc6.jpg', 'extension': 'jpg'}, 1351863490: {'path': 'temp/1744394942_1798464_1351863490_8e8b561746b3cae6f46ae42aaea3f4ca.jpg', 'extension': 'jpg'}, 1351863526: {'path': 'temp/1744394942_1798464_1351863526_dc760edad1fed3d07dc39d25f8a3ce88.jpg', 'extension': 'jpg'}, 1351863810: {'path': 'temp/1744394942_1798464_1351863810_5819b4e9f905bf0632f58e3090037c59.jpg', 'extension': 'jpg'}, 1351863872: {'path': 'temp/1744394942_1798464_1351863872_8d41fa2c08627a44c925605ddeed35a0.jpg', 'extension': 'jpg'}, 1351863550: {'path': 'temp/1744394942_1798464_1351863550_b3f8af1c72eb18e7fa5422ed1afea9ed.jpg', 'extension': 'jpg'}, 1351863735: {'path': 'temp/1744394942_1798464_1351863735_b08ece2d7d52f0f35b4ce14fad3fc2ff.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 = 22297260; (('arc_en_ciel_jrm',),) TODO : Insert select and so on Begin split_port_in_batch_balle thcls : [{'id': 861, 'mtr_user_id': 31, 'name': 'Rungis_class_dechets_1212', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': 'Rungis_Aluminium,Rungis_Carton,Rungis_Papier,Rungis_Plastique_clair,Rungis_Plastique_dur,Rungis_Plastique_fonce,Rungis_Tapis_vide,Rungis_Tetrapak', 'svm_portfolios_learning': '1160730,571842,571844,571839,571933,571840,571841,572307', 'photo_hashtag_type': 999, 'photo_desc_type': 3963, 'type_classification': 'caffe', 'hashtag_id_list': '2107751280,2107750907,2107750908,2107750909,2107750910,2107750911,2107750912,2107750913'}] thcls : [{'id': 758, 'mtr_user_id': 31, 'name': 'Rungis_amount_dechets_fall_2018_v2', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': '05102018_Papier_non_papier_dense,05102018_Papier_non_papier_peu_dense,05102018_Papier_non_papier_presque_vide,05102018_Papier_non_papier_tres_dense,05102018_Papier_non_papier_tres_peu_dense', 'svm_portfolios_learning': '1108385,1108386,1108388,1108384,1108387', 'photo_hashtag_type': 856, 'photo_desc_type': 3853, 'type_classification': 'caffe', 'hashtag_id_list': '2107751013,2107751014,2107751015,2107751016,2107751017'}] select SUBSTRING(ph.text,16,2) as h, count(*) from MTRUser.mtr_portfolio_photos mpp inner join MTRBack.photos ph on mpp.mtr_photo_id = ph.photo_id where mpp.mtr_portfolio_id = 22297260 group by h (('20', 30),) 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=22297260 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 (22297260) 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 (22297260) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 11042025 22297260 Nombre de photos uploadées : 30 / 23040 (0%) 11042025 22297260 Nombre de photos taguées (types de déchets): 0 / 30 (0%) 11042025 22297260 Nombre de photos taguées (volume) : 0 / 30 (0%) [{'photo_id': 1351861981, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/7ac61c9025417dd0a7eb14675e61a3e8.jpg', 'username': None, 'uploaded_at': 1744394467, 'text': 'image_11042025_20_00_13_010215m0.jpg 1e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1351861973, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/a14b178b31e35e70127f147d065a1c14.jpg', 'username': None, 'uploaded_at': 1744394467, 'text': 'image_11042025_20_00_24_010140m0.jpg 2e-05 for time 1, id_amount 1 this amount prod time diff : 1e-05'}, {'photo_id': 1351861966, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/367d9e980f32c211dc2c027cb483da9f.jpg', 'username': None, 'uploaded_at': 1744394467, 'text': 'image_11042025_20_00_44_010141m0.jpg 3.0000000000000004e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1351862181, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/11/f8d6c0ac83df26f2add3a01cf5d69105.jpg', 'username': None, 'uploaded_at': 1744394527, 'text': 'image_11042025_20_00_54_010138m0.jpg 4e-05 for time 1, id_amount 3 this amount prod time diff : 1e-05'}] 0 [] elapsed_time : load_data_split_time_score 3.5762786865234375e-06 elapsed_time : order_list_meta_photo_and_scores 1.0251998901367188e-05 ?????????????????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.0014286041259765625 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 22297260, '2025-04-11' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1733453,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.02465987205505371 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= 1733453 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1733453, 'dashboard_run_id': 1744608, 'mtr_portfolio_id': 22294513, 'dashboard_result_id': 10035319, '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_P22294513_11-04-2025_19_33_33.pdf', 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22294577, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22294578, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22294579, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22294580, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22294581, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22294582, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22294583, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22294584, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22294585, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22294586, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22294587, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22294588, 'pht': 3726}}"}, {'dashboat_entry_day': 1733453, 'dashboard_run_id': 1744608, 'mtr_portfolio_id': 22295582, 'dashboard_result_id': 10035320, '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_P22295582_11-04-2025_19_47_33.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22295585, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22295586, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22295587, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22295588, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22295589, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22295590, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22295591, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22295592, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22295593, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22295594, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22295595, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22295596, 'pht': 3726}}"}, {'dashboat_entry_day': 1733453, 'dashboard_run_id': 1744608, 'mtr_portfolio_id': 22296376, 'dashboard_result_id': 10035321, '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_P22296376_11-04-2025_20_03_32.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 22296402, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22296404, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22296405, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22296406, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22296407, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22296409, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22296410, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22296411, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22296412, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22296413, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22296414, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22296415, 'pht': 3726}}"}, {'dashboat_entry_day': 1733453, 'dashboard_run_id': 1744608, 'mtr_portfolio_id': 22297260, 'dashboard_result_id': 10035322, '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_P22297260_11-04-2025_20_07_01.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22297294, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22297295, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22297296, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22297297, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22297298, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22297299, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22297300, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22297301, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22297302, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22297303, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22297304, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22297305, 'pht': 3726}}"}] SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 22294513 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': 2745986, 'mtr_portfolio_id': 22294513, 'created_at': datetime.datetime(2025, 4, 11, 19, 33, 32), 'result': '0.04393922219327648', 'result_long': None, 'result_double': None}] Qualite : 0.04393922219327648 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22294513 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22294513_11-04-2025_19_33_33.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22294513 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_P22294513_11-04-2025_19_33_33.pdf', 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22294577, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22294578, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22294579, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22294580, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22294581, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22294582, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22294583, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22294584, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22294585, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22294586, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22294587, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22294588, 'pht': 3726}}" where mtr_portfolio_id = 22294513 and dashboard_run_id = 1744608 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`=22294513 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10035319, 0.04393922219327648, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22294513_11-04-2025_19_33_33.pdf', 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22294577, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22294578, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22294579, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22294580, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22294581, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22294582, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22294583, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22294584, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22294585, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22294586, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22294587, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22294588, '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 = 22295582 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': 2746069, 'mtr_portfolio_id': 22295582, 'created_at': datetime.datetime(2025, 4, 11, 19, 47, 32), 'result': '0.06369179666235565', 'result_long': None, 'result_double': None}] Qualite : 0.06369179666235565 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22295582 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22295582_11-04-2025_19_47_33.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22295582 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_P22295582_11-04-2025_19_47_33.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22295585, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22295586, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22295587, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22295588, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22295589, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22295590, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22295591, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22295592, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22295593, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22295594, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22295595, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22295596, 'pht': 3726}}" where mtr_portfolio_id = 22295582 and dashboard_run_id = 1744608 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`=22295582 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10035320, 0.06369179666235565, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22295582_11-04-2025_19_47_33.pdf', 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22295585, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22295586, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22295587, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22295588, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22295589, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22295590, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22295591, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22295592, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22295593, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22295594, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22295595, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22295596, '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 = 22296376 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': 2746110, 'mtr_portfolio_id': 22296376, 'created_at': datetime.datetime(2025, 4, 11, 20, 3, 31), 'result': '0.04363770098468186', 'result_long': None, 'result_double': None}] Qualite : 0.04363770098468186 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22296376 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22296376_11-04-2025_20_03_32.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22296376 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_P22296376_11-04-2025_20_03_32.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 22296402, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22296404, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22296405, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22296406, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22296407, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22296409, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22296410, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22296411, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22296412, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22296413, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22296414, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22296415, 'pht': 3726}}" where mtr_portfolio_id = 22296376 and dashboard_run_id = 1744608 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`=22296376 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10035321, 0.04363770098468186, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22296376_11-04-2025_20_03_32.pdf', 'metal': {'hashtag': 'metal', 'sub_port_id': 22296402, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22296404, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22296405, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22296406, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22296407, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22296409, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22296410, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22296411, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22296412, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22296413, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22296414, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22296415, '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 = 22297260 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': 2746177, 'mtr_portfolio_id': 22297260, 'created_at': datetime.datetime(2025, 4, 11, 20, 9, 1), 'result': '0.03767567242816349', 'result_long': None, 'result_double': None}] Qualite : 0.03767567242816349 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22297260 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22297260_11-04-2025_20_09_02.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22297260 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_P22297260_11-04-2025_20_09_02.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22297294, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22297295, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22297296, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22297297, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22297298, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22297299, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22297300, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22297301, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22297302, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22297303, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22297304, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22297305, 'pht': 3726}}" where mtr_portfolio_id = 22297260 and dashboard_run_id = 1744608 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`=22297260 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (10035322, 0.03767567242816349, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22297260_11-04-2025_20_09_02.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22297294, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22297295, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22297296, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22297297, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22297298, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22297299, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22297300, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22297301, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22297302, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22297303, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22297304, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22297305, 'pht': 3726}}") ON DUPLICATE KEY UPDATE qualite=VALUES(qualite), completion_json=VALUES(completion_json) ret update_qualite_results : None SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22294513,22295582,22296376,22297260) result : ((1351846508,), (1351846511,), (1351846514,), (1351846974,), (1351847009,), (1351847046,), (1351847064,), (1351847104,), (1351847202,), (1351847475,), (1351847497,), (1351847510,), (1351847570,), (1351847644,), (1351847795,), (1351847837,), (1351847864,), (1351847887,), (1351847924,), (1351847990,), (1351848173,), (1351848175,), (1351848177,), (1351848256,), (1351848260,), (1351848282,), (1351848643,), (1351848697,), (1351848739,), (1351848775,), (1351848792,), (1351848818,), (1351849043,), (1351849070,), (1351849097,), (1351849293,), (1351849299,), (1351849303,), (1351849332,), (1351849343,), (1351849462,), (1351849466,), (1351849479,), (1351849494,), (1351849514,), (1351849542,), (1351849580,), (1351849610,), (1351849638,), (1351849654,), (1351849709,), (1351849721,), (1351849749,), (1351849772,), (1351849788,), (1351849797,), (1351849950,), (1351850045,), (1351850106,), (1351850127,), (1351850387,), (1351850410,), (1351850436,), (1351850459,), (1351850485,), (1351850788,), (1351850828,), (1351850840,), (1351850852,), (1351850872,), (1351850893,), (1351850974,), (1351850962,), (1351850968,), (1351851013,), (1351851028,), (1351851040,), (1351851061,), (1351851263,), (1351851279,), (1351851286,), (1351851300,), (1351851310,), (1351851334,), (1351851400,), (1351851409,), (1351851411,), (1351851415,), (1351851556,), (1351851560,), (1351851565,), (1351851927,), (1351851946,), (1351851949,), (1351851954,), (1351852009,), (1351852017,), (1351852084,), (1351852114,), (1351852134,), (1351852144,), (1351852148,), (1351852256,), (1351852275,), (1351852285,), (1351852319,), (1351852368,), (1351852613,), (1351852629,), (1351852653,), (1351852669,), (1351852915,), (1351852951,), (1351852975,), (1351852997,), (1351853024,), (1351853270,), (1351853300,), (1351853330,), (1351853778,), (1351853825,), (1351853900,), (1351853937,), (1351853963,), (1351854516,), (1351854589,), (1351854642,), (1351854703,), (1351854806,), (1351854866,), (1351855433,), (1351855483,), (1351855526,), (1351856032,), (1351856090,), (1351856162,), (1351856199,), (1351856220,), (1351856904,), (1351856726,), (1351856783,), (1351856808,), (1351856859,), (1351857338,), (1351857390,), (1351857424,), (1351857470,), (1351857508,), (1351857798,), (1351857806,), (1351857831,), (1351857840,), (1351857863,), (1351857889,), (1351858138,), (1351858170,), (1351858191,), (1351858219,), (1351858247,), (1351858272,), (1351858562,), (1351858576,), (1351858607,), (1351858626,), (1351858652,), (1351858687,), (1351859036,), (1351859117,), (1351859151,), (1351859474,), (1351859518,), (1351859570,), (1351859642,), (1351859678,), (1351859726,), (1351859969,), (1351860025,), (1351860079,), (1351860137,), (1351860179,), (1351860330,), (1351860348,), (1351860393,), (1351860796,), (1351860824,), (1351860855,), (1351860883,), (1351860988,), (1351861019,), (1351861070,), (1351861113,), (1351861120,), (1351861147,), (1351861151,), (1351861156,), (1351861178,), (1351861285,), (1351861306,), (1351861341,), (1351861368,), (1351861398,), (1351861426,), (1351861784,), (1351861802,), (1351861811,), (1351861989,), (1351861966,), (1351861973,), (1351861981,), (1351862149,), (1351862173,), (1351862181,), (1351862243,), (1351862257,), (1351862270,), (1351862278,), (1351862295,), (1351862319,), (1351862498,), (1351862540,), (1351862577,), (1351862611,), (1351862647,), (1351862701,), (1351862916,), (1351862953,), (1351863003,), (1351863444,), (1351863459,), (1351863490,), (1351863526,), (1351863550,), (1351863735,), (1351863810,), (1351863872,), (1351863935,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'11042025': {'nb_upload': 30, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22297260]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444] map_info['map_portfolio_photo'] : {22297260: [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444, 1351863003, 1351862953, 1351862916, 1351862701, 1351862647, 1351862611, 1351862577, 1351862540, 1351862498, 1351862319, 1351862295, 1351862278, 1351862270, 1351862257, 1351862243, 1351862181, 1351862173, 1351862149, 1351861981, 1351861973, 1351861966]} final : True mtd_id 4302 list_pids : [1351863935, 1351863872, 1351863810, 1351863735, 1351863550, 1351863526, 1351863490, 1351863459, 1351863444] Looping around the photos to save general results len do output : 1 /22297260Didn'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, '2746177') ('4302', '22297260', '1351863935', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863872', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863810', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863735', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863550', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863526', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863490', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863459', None, None, None, None, None, '2746177') ('4302', None, None, None, None, None, None, None, '2746177') ('4302', '22297260', '1351863444', None, None, None, None, None, '2746177') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 10 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', None, '22297260', 'None', None, None, None, None, '2746177'), ('4302', '22297260', '1351863935', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863872', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863810', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863735', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863550', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863526', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863490', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863459', None, None, None, None, None, '2746177'), ('4302', '22297260', '1351863444', None, None, None, None, None, '2746177')] time used for this insertion : 0.016379117965698242 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.36157870292663574 time spend to save output : 0.016645431518554688 total time spend for step 5 : 0.37822413444519043 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 (2746177) 2.06user 2.50system 0:09.88elapsed 46%CPU (0avgtext+0avgdata 158860maxresident)k 18776inputs+7760outputs (161major+64297minor)pagefaults 0swaps