Retailers are on a constant quest to understand what customers do in their stores: What do they look at, touch, reject or buy? Do they return? Answers allow store operators to adjust inventory, refine store layout, price goods, optimize costs and give customers a better experience.\nAfter six years of operating its own brick-and-mortar stores, century-old textile giant Gul Ahmed has gained an understanding of shopper behaviour through machine vision technology. The project aims to streamline operations, attract return customers and\u00a0 boost revenue -- goals that are in line with what CIOs across the Middle East use to justify large-scale expenditures in IT, according to Gartner.\nThe company sells its textile merchandise online as well as in retail stores, and has a presence in the UAE, Pakistan and the UK. Across the MENAP (Middle East, North Africa, Afghanistan and Pakistan) region, it operates over 100 stores for Ideas, its direct-to-consumer (D2C) business launched in 2013, for Eastern fashion apparel and home linen.\nThe multinational enterprise generates more than 90 percent of its annual revenue through distribution hubs -- which supply merchandise for online sales -- and D2C retail outlets in Sharjah in the UAE and Haslingden in the UK.\nEmphasizing retail first-party data\nMost textile producers in the MENAP region that operate online businesses are working with either Amazon's Souq or Alibaba Group's Daraz to white-label an e-commerce site. Others emphasize ownership and control of first-party data and operate their own online stores on Magento (like Gul Ahmed) or Shopify.\nAlong with its online data-gathering, the company was also interested in introducing analytics to the brick-and-mortar world. The idea was to learn which marketing initiatives, merchandising and in-store displays most effectively drive people to retail\u00a0 locations and convert them to paying customers.\n\u00a0Gul Ahmed leveraged the capabilities of SenseR, a machine vision system developed by Integration Xperts, applying facial recognition on video from closed-circuit TVs at more than 100 outlets.\nWhen shoppers enter a store, SenseR's machine-learning technology makes best guesses -- based on data it has already been fed -- for emotional state and demographic attributes such as age and gender.\nAfter a front-facing camera captures a shopper's demographics, secondary cameras track the person's movements and correlate the data with information\u00a0 collected at the point of sale (POS). This includes information that people give -- such as date of birth, email addresses and phone numbers -- when opting to fill a loyalty\/discount form.\nBehaviour tracking to enhance customer experience\n\u00a0\u201cSenseR allows us to track visit duration, attain zone-wise heatmaps, pinpoint returning customers, monitor high traffic areas, understand peak hours, quantify product popularity, and substantially improve customer experience,\u201d said Muhammad Khalilullah, CTO of Gul Ahmed.\nThis behavioural and purchase information collected in the store is ported to a data- and order-management system connected to the company's cloud-based marketing platform, and used to finetune its omnichannel strategy. Based on purchase history, customers are retargeted for similar products in the same or next fashion line.\n\u201cOptimizing in-store video analytics empowered our business to focus on the development of products, streamlined our store layout, and gave the customers what they wanted," Khalilullah said. "When retail is involved, customers want to touch and feel what they\u2019re purchasing. Video analytics is the perfect opportunity to find out what our customers prefer.\u201d\u00a0\nAI helps resource and demand planning\nAccording to Ilsa Khan Baqai, a data scientist at Integration Xperts, machine-learning vision tech like SenseR can help large brick and mortar retailers with various aspects of resource and demand planning.\n\u201cFor example, if it is observed that the dwell times of visitors in a store is generally high however the transactions are low, it can easily be depicted via an on-screen dashboard via a sales conversion chart,\u201d Baqai said. \u201cThis can now then be given attention to by the management by planning actions such as sales staff training or improving the price of the products etc.\u201d\n\u00a0In the implementation phase at Gul Ahmed, Microsoft Azure ended up being used for analytics and database requirements. Since the cognitive services from Microsoft were not performing very well on closed-circuit TV footage, they were not used.\nThe machine vision system also required on-premise compute, which meant that implementation technicians from Integration Xperts had to go to each branch to deploy and configure SenseR. The distributed approach was to save data transmission cost from branch to cloud, hence all videos were processed on-site, while results were sent to Azure.\nDeployment causes friction\n\u00a0\u201cOn-site deployment was the major challenge,\u201d said Zia Saleem, head of product development at Integration Xperts. \u201cThe focus of the branch is day-to-day operations. In the middle of the operations, expecting [staff] to take time out to help us align closed-circuit TV cameras, arrange and install compute on-site is difficult.\u201d\n\u00a0For Saleem\u2019s team, the experience reinstilled the importance of communications to reduce friction between store staff and technical personnel. To reduce disruption, Integration Xperts devised a software deployment package. Integration Xperts is also planning a number of system enhancements, including an in-store kiosk display that\u00a0 can identify recurring customers and suggest new offers within a store based on customer demographics and in the case of a recurring customer, historic buying pattern and store journeys, Saleem said.\n\u201cKnow your customer - the better you know the customer, the more targeted the sales effort can be,\u201d Saleem said. Machine vision when deployed for retail analytics can, for example, identify weak staff performance, when there are many shoppers in a store but relatively few purchases.\u00a0\u00a0\n\u00a0\u201cThe system can analyze sales staff behavior with the customer and analyze the sentiment of the customer while they were being dealt with by the sales staff. This can give the business a very clear idea of how much effort the sales team is making in satisfying customer queries," Saleem said.\nMachine vision enhances security\nDepending on the placement of cameras within and outside stores, machine vision layered on top of a closed-circuit TV system can also help retailers with security and prevent theft or fraud, removing the need for human security to be sitting behind a screen, while initiating physical intervention when alerted to a threat.\nGul Ahmed plans to take advantage of this capability in phase two of the machine vision project.\n\u00a0Over the next few years, 5G transmission speeds are expected to further enhance data-gathering and analysis. When operating in an ecosystem supported by 5G, D2C companies with retail analytics applications built on machine vision will be able to pull IoT data from closed-circuit TVs, homes, drones, and metering systems.\nIn the Middle East, Saudi Arabia piloted a 5G network in the city of Al Khobar, while Ooredoo in Qatar and Etisalat in the UAE have also taken active steps toward adoption. Shortly after setting up a 5G Ecosystem Programme in 2018, Huawei announced in early 2019 that 50 operators, vertical industry partners, and industry leaders from the Middle East were on board to bring 5G applications to a range of industries.\n\u00a0The transfer of data among smart devices is expected to refine the quality of first-party data being gathered by retailers, opening doors for end-to-end omnichannel strategies that optimize the costs of customer acquisition and retention, the customer lifetime value, and ultimately shareholder value.