<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Utkarsh vijay on Medium]]></title>
        <description><![CDATA[Stories by Utkarsh vijay on Medium]]></description>
        <link>https://medium.com/@utkarshvijay99?source=rss-bcf6ab801f49------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*sCpIlZeDoyVWJ5icP4vTow.jpeg</url>
            <title>Stories by Utkarsh vijay on Medium</title>
            <link>https://medium.com/@utkarshvijay99?source=rss-bcf6ab801f49------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 08:35:20 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@utkarshvijay99/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Pet Statistics (2026): 40 Sourced Figures]]></title>
            <link>https://medium.com/@utkarshvijay99/pet-statistics-2026-40-sourced-figures-55f7d1a7f77a?source=rss-bcf6ab801f49------2</link>
            <guid isPermaLink="false">https://medium.com/p/55f7d1a7f77a</guid>
            <dc:creator><![CDATA[Utkarsh vijay]]></dc:creator>
            <pubDate>Thu, 05 Nov 2026 09:54:17 GMT</pubDate>
            <atom:updated>2026-11-05T09:54:17.167Z</atom:updated>
            <content:encoded><![CDATA[<h3>Key figures</h3><p>US households that own a pet, 2025 (APPA) 95 million</p><p>US pet industry expenditures, 2025 (APPA) US$158 billion</p><p>Dogs and cats that entered US shelters and rescues, 2025 (ASPCA) 5.8 million</p><p>Share of US dogs and cats with pet insurance, 2025 (NAPHIA) 4.27%</p><p>This page collects figures on pets in the United States. It covers how many households own pets, what owners spend, how many pets are insured, what happens in shelters and who provides veterinary care. Every number links to the document that first published it. The main sources are the American Pet Products Association (APPA), the North American Pet Health Insurance Association (NAPHIA), the ASPCA, the US Bureau of Labor Statistics (BLS) and a public company filing. For more data pages on other markets, see the <a href="https://statwharf.com/research/">StatWharf research directory</a>.</p><h3>Method</h3><p>The data window runs from 2022 to the third quarter of 2026. Most figures describe calendar year 2025. StatWharf used primary sources only. These are industry bodies (APPA, NAPHIA), the ASPCA and the Shelter Animals Count data it publishes, the BLS, and an SEC filing. BLS household spending data is read from the series that the Federal Reserve Bank of St. Louis distributes. Statistics aggregators and blogs that re-quote other sources were excluded. Each figure was checked against its source in October 2026. StatWharf dropped each figure that did not appear on its primary source. No value on this page is modeled, estimated or calculated by StatWharf.</p><p>Several popular questions have no primary source. StatWharf found no government agency or industry body that publishes an average cost for pet euthanasia or for a pet sitter per day. Figures on those costs found online come from vendor price lists or blogs, so this page leaves them out. The AVMA Pet Ownership and Demographics Sourcebook was not reachable at the check date. Its dog and cat population counts appear on this page only where NAPHIA cites them.</p><h3>Pet ownership</h3><p>APPA runs the National Pet Owners Survey. Its 2026 State of the Industry Report draws on the 2025 edition of that survey. The dog and cat population counts come from a 2025 AVMA survey that NAPHIA cites in its own report.</p><p>Dog ownership rose from <a href="https://www.accessnewswire.com/newsroom/en/business-and-professional-services/u.s.-pet-industry-reaches-158-billion-in-2025-poised-for-continu-1165595">51% of households in 2024</a> to 53% in 2025. APPA describes this as about 4 million more dog-owning households in one year. APPA also reports that cat ownership grew 5% year over year. It names Gen Z and Millennials as the main drivers. Gen X dog ownership rose 12% in the same period, according to the same release.</p><p>There are two different ways to count pets. APPA counts households. The AVMA figures that NAPHIA cites count animals. A household with two dogs counts once in the first measure and twice in the second. The two measures therefore do not compare directly.</p><h3>Pet spending</h3><p>APPA publishes total US pet industry expenditures each year. The figures cover sales to consumers in four categories. The BLS Consumer Expenditure Survey measures pet spending from the household side. Its figure is an average across all US consumer units, including those with no pet.</p><p>APPA’s “other services” category covers boarding, grooming, insurance, training, pet sitting, pet walking and all other services outside veterinary care. APPA projects vet care and product sales of <a href="https://americanpetproducts.org/industry-trends-and-stats">US$42.4 billion</a> in 2026. Its May 2026 release says that roughly 2 points of the projected 4.4% growth for 2026 come from inflation. It also reports that <a href="https://www.accessnewswire.com/newsroom/en/business-and-professional-services/u.s.-pet-industry-reaches-158-billion-in-2025-poised-for-continu-1165595">22% of pet owners</a> spent less on their pets in 2025.</p><p>One labeling point needs care. APPA’s trends page shows the category split under the heading “2025 actual sales”, while a line below it refers to 2024. The State of the Industry page and the May 2026 release both give US$158 billion for 2025. This page follows those two documents.</p><p>US pet industry expenditures by category, 2025 (US$ billion)</p><p>Source: APPA Industry Trends and Stats, checked October 2026.</p><p>The BLS figure is not the cost of owning one pet. It is the mean spending of all consumer units, and many of them own no pet. Spending per pet-owning household is therefore higher than US$880. The BLS series shows a large rise from 2022 to 2023 and a flat 2024.</p><p>Average annual pet spending per US consumer unit (US$)</p><p>Source: BLS Consumer Expenditure Survey, series CXUPETSLB0101M via FRED, checked October 2026.</p><h3>Pet insurance</h3><p>NAPHIA’s annual State of the Industry Report is compiled by Willis Towers Watson. NAPHIA estimates that its data covers about 99% of written pet health insurance premium in the US and Canada. The 2026 report describes calendar year 2025. Premium figures are in-force figures at December 31, 2025.</p><p>The penetration rates use a base of <a href="https://naphia.org/wp-content/uploads/2026/06/NAPHIA_SOI2026_Report_HIGHLIGHTS_26-06-24.pdf">163.6 million</a> US dogs and cats. NAPHIA reports that the number of insured US pets grew 9.0% in 2025. Premium grew faster than the number of pets. NAPHIA attributes this to a consistent rise in average premium each year. The accident and illness premium for a US dog was US$625 in 2021 and US$836 in 2025. An accident-only plan for a dog averaged <a href="https://naphia.org/wp-content/uploads/2026/06/NAPHIA_SOI2026_Report_HIGHLIGHTS_26-06-24.pdf">US$190</a> in 2025. California held 18.1% of insured US pets, the largest share of any state.</p><p>Average annual accident and illness premium per US dog (US$)</p><p>Source: NAPHIA State of the Industry Report, June 2026.</p><h3>Shelters, adoption and abandonment</h3><p>Shelter Animals Count collects intake and outcome data from US shelters and rescues. It joined the ASPCA in 2025. The ASPCA publishes the national estimates below. They are estimates based on full-year data from reporting organizations, and figures vary by state.</p><p>Intake in 2025 was 2.8 million dogs and 3 million cats. The euthanasia rate fell from 10% in 2019 to 8% in 2025. The ASPCA reports that dog euthanasia fell nearly 7% and cat euthanasia fell 2% compared with 2024. The ASPCA also reports that dogs, especially large dogs, stay longer in shelters than they did five years ago. It names staff and veterinarian shortages as added pressures on shelters.</p><p>Owner surrender is the closest measured figure to “pet abandonment”. It covers pets that owners bring to a shelter. Strays are a separate intake route, and the data does not show how many strays were once owned. The ASPCA links surrender to gaps in access to veterinary care, pet-friendly housing and behavioral support.</p><p>US shelter dogs and cats, 2025 (million)</p><p>Source: ASPCA, Shelter Animals Count 2025 data, checked October 2026.</p><h3>Veterinary workforce and online pet retail</h3><p>The BLS Occupational Outlook Handbook reports pay, jobs and projected growth for veterinary occupations. Chewy, a listed online pet retailer, reports its customer base in quarterly SEC filings.</p><p>The BLS projects about 3,100 openings for veterinarians and about <a href="https://www.bls.gov/ooh/healthcare/veterinary-technologists-and-technicians.htm">13,400 openings</a> for veterinary technologists and technicians each year over the decade. Veterinary technicians outnumber veterinarians in the BLS job counts. Chewy reported net sales of <a href="https://www.sec.gov/Archives/edgar/data/1766502/000162828026061011/chwyq22026exhibit991.htm">US$3.33 billion</a> for the quarter, up 7.3% year over year. Chewy defines an Autoship customer as one with an order shipped through its subscription program in the preceding 364 days. The figures describe one company, not the whole pet retail market.</p><h3>What the figures show</h3><p>Three points stand out. First, pet ownership is broad and stable. APPA counts <a href="https://americanpetproducts.org/industry-trends-and-stats">95 million</a> pet-owning households, and dog ownership rose to 53% in 2025. Spending grew <a href="https://americanpetproducts.org/2026-state-of-the-industry">3.7%</a> in the same year, while more owners reported cutting back.</p><p>Second, veterinary care is the second largest spending category after food. Vet care and product sales reached <a href="https://americanpetproducts.org/industry-trends-and-stats">US$41.0 billion</a> in 2025. At the same time, insurance covers only <a href="https://naphia.org/wp-content/uploads/2026/06/NAPHIA_SOI2026_Report_HIGHLIGHTS_26-06-24.pdf">4.27%</a> of US dogs and cats. Most owners still pay vet bills directly.</p><p>Third, the clinical workforce is small relative to the pet population. The BLS counts <a href="https://www.bls.gov/ooh/healthcare/veterinarians.htm">about 91,100</a> veterinarian jobs for about 87.3 million dogs and 76.3 million cats. Shelters also report veterinarian shortages. Clinics with fixed staff need efficient scheduling, records, reminders and insurance claim handling to see more patients.</p><h3>Where to go next</h3><p>Veterinary practices that want to handle more appointments with the same staff are able to review the <a href="https://statwharf.com/best/veterinary-practice-management-software/">veterinary practice management software comparison</a>. It sets out practice-type fit, diagnostics and payment integrations, and published pricing for each product. It does not name a single best product.</p><p>The next update follows three releases: the APPA 2027 State of the Industry Report, the 2027 NAPHIA State of the Industry Report and the Shelter Animals Count data for 2026. Send corrections to any figure to the editorial address below.</p><p>Factual corrections are free: <a href="/service/mailto:editorial@statwharf.com">editorial@statwharf.com</a>.</p><p><em>Originally published at </em><a href="https://statwharf.com/research/pet-statistics/"><em>https://statwharf.com</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=55f7d1a7f77a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Docker Optimizations]]></title>
            <link>https://medium.com/@utkarshvijay99/docker-optimizations-9bbd3ea7e658?source=rss-bcf6ab801f49------2</link>
            <guid isPermaLink="false">https://medium.com/p/9bbd3ea7e658</guid>
            <category><![CDATA[docker-imag]]></category>
            <category><![CDATA[no-cache]]></category>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[docker-caching]]></category>
            <dc:creator><![CDATA[Utkarsh vijay]]></dc:creator>
            <pubDate>Sat, 09 Mar 2024 12:35:09 GMT</pubDate>
            <atom:updated>2024-03-09T12:35:09.047Z</atom:updated>
            <content:encoded><![CDATA[<p>It’s a fact that Docker images tend to gain weight quickly. With all those layers and dependencies, your once-sleek container might become bulky. In this blog post we’ll go over some simple methods that will make your Docker images look great and function flawlessly.</p><p><strong>Use Small Docker Base Images</strong></p><ul><li>Smaller images build, push, and pull faster and are more secure by including only essential dependencies for your application.</li><li>The choice of a Docker base image depends on your needs. In development, start with a *-slim flavor to avoid constant Dockerfile updates for system dependencies. As you progress to production, consider using Alpine in a multi-stage build for a hardened and streamlined final image. It’s all about finding the right balance as extra dependencies will increase the size but is also less hassle.</li></ul><pre>                  REPOSITORY         TAG           SIZE<br>                   sample           alpine        66.3MB<br>                   sample            slim         165MB<br>                   sample           normal        1.03GB</pre><p><strong>Use of </strong><strong>--no-cache-dir</strong></p><ul><li>Using — no-cache-dir in a docker file during package installation is generally a good idea. Why?</li><li>Although package caching generally speeds up installation times and reduces network traffic, Docker comes with its own caching system.</li><li>What sets the installer’s caching system apart from Docker’s:</li><li>Installation files (.whl,.tar.gz (archive files)) are typically stored by installers to prevent re-downloading when they are not expired. However, using the installer’s cache can cause cross-dependency problems; for example, if a requirement file changes and a new version of a library is needed but an older one is cached, an error may occur; therefore, when a file change occurs, a fresh installation is recommended.</li></ul><pre><br>#previously run <br>export PYCURL_SSL_LIBRARY=nss and pip install pycurl<br>#want new run<br>export PYCURL_SSL_LIBRARY=openssl and pip install pycurl --compile --no-cache-dir<br>&quot;&quot;&quot;<br>By default, pip might try to use cached build artifacts (compiled files)<br>from the previous installation. However,these artifacts were built with nss,<br>not openssl. --no-cache-dir forces pip to ignore any cached build artifacts <br>and perform a fresh compilation specifically linked against <br>the openssl library according to your new environment variable setting.<br>&quot;&quot;&quot;<br></pre><ul><li>Although Docker usually caches the layer, every instruction in a dockerfile is a layer. If the base of a layer is not modified, that layer is cached and utilized in subsequent builds to achieve the same functionality. Clearing the cache also results in a smaller image.</li></ul><p><strong>Ordering and Grouping of Commands</strong></p><ul><li>It is generally a good practice to insert RUN commands for files that changes frequently below in the Dockerfile, as if any layer in the image changes, all the succeeding layers below are rebuilt. The order in which the Dockerfile commands are placed matters.</li><li>Dockerfile 1: Here, all the layers are rebuilt if there is a change to the primary code file, sample.py.</li></ul><pre>COPY sample.py<br>COPY requirements.py<br>RUN pip install -r requirements.txt<br>CMD [&quot;python&quot;,&quot;sample.py&quot;]</pre><ul><li>Dockerfile 2: Here, we are copying the sample.py after installing all the dependencies as generally they are less interfered than main code. This is also called grouping of commands , here we have grouped copy and run command of requirements, similarly if there are other files that are less interfered than main code file should be grouped and put above the copy command of main file.</li></ul><pre>COPY requirements.py<br>RUN pip install -r requirements.txt<br>COPY sample.py<br>CMD [&quot;python&quot;,&quot;sample.py&quot;]</pre><p><strong>Using Multi-Stage build</strong></p><ul><li>A multi-stage build in Docker is a powerful technique for creating smaller and more secure container images. It allows you to break down the image creation process into multiple stages, each with its own Dockerfile instructions and base image.</li><li>One of the most common use-case i encountered with it was use of gcc to install requirements.</li></ul><pre>#temp stage<br>FROM python:3.12.2-slim as builder<br>#The --no-install-recommends flag instructs apt-get to install only the essential dependencies required by the specified package (gcc).<br>RUN apt-get update &amp;&amp; apt-get install -y --no-install-recommends gcc  <br>COPY requirements.txt .<br>RUN pip wheel --no-cache-dir --no-deps --wheel-dir /wheels -r requirements.txt<br><br>#final stage<br>FROM python:3.12.2-slim<br>COPY --from = builder /wheels /wheels<br>COPY --from = builder /requirements.txt .<br>RUN pip install --no-cache /wheels/*</pre><ul><li>GCC is being installed in temp stage in order to install the dependencies that need it. Once all of the needs or.whl packages (a format for Python libraries) are constructed, GCC will no longer be needed.</li><li>Hence, we created another stage over the temp stage to create final image for our code which doesn’t include GCC and hence trims our final image size.</li></ul><p>There are more optimization techniques you can make in docker but it’s all about finding the right balance. The practices i have stated above are some of the most basic and effective in optimizing docker files.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9bbd3ea7e658" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>