11 Nov 2025
by Phil Weir

Simulation and photonics: How Dewret supports the next generation of engineering

Photonics Needs New Simulation Infrastructure 

Photonics sits at the heart of some of the most transformative technologies today, from data storage and quantum computing, to advanced sensing and imaging systems. Yet as the applications of photonics grow more complex, the simulation tools that engineers rely on often lag behind. Off-the-shelf solutions are not always designed with emerging use-cases in mind. They can limit exploration, slow down prototyping, and restrict collaboration between disciplines. 

At Flax & Teal, we recognise that the photonics community, and indeed engineering more widely, needs  adaptable, transparent, and integrated simulation infrastructure. That recognition is what led to the development of Dewret, our open-source workflow system designed to make simulation pipelines more flexible, reproducible, and powerful. 

What we call SciX - the user experience for scientists - is a hot topic in simulation right now. As emerging computational techniques become more accessible and central to product offerings, scientists are expected to contribute robust, complex algorithms and models. However, they are forced to learn cloud data engineering, production coding skills, or connect directly to the inner workings of number-crunching behemoths, when what they really know is how to write clean, local Python for amazing science. SciX is the measure of how far we force scientists to deviate from that. Dewret is our answer to make clean, flexible deployable, DevSecOps-friendly, workflows achievable without going beyond clean Python. 

Dewret was originally developed to support a real client open source need in photonics, and is spreading across our work in digital twins, simulation pipelines, and multi-disciplinary engineering projects. It is targeted for adoption across sectors where rigorous, scalable simulation and data modelling is a necessity. 

Introducing Dewret 

Dewret - the DEclarative Workflow REndering Tool - is a package for creating complex workflows, written in a dynamic language (Python), to be rendered to a static representation; which can be consumed by multiple declarative workflow engines, where workflows are often written in a YAML-like declarative syntax. It makes it easier for users to define tasks and organise them into workflows. Fixing a workflow should not be a choice between dynamic execution (where you can only check your workflow by executing it) or hand-editing YAML. 

It is based on Dask - a firm favourite for scientist-friendly dynamic workflow execution - but is designed to output using pluggable renderers, and heavily leverages Python’s typing system to make contextual, non-code information, such as the parametrizability of variables, expressible. While other tools have started to explore this area, Dewret focuses on clean code and semantic correctness - good SciX means calling a task function with the same number and type of parameters you see in the function’s signature - and avoids dependence on, say, Kubernetes or a single execution engine. Good SciX means that if your simple Python linting and type-checking passes on your Dewret code, that should be a strong indication that all your task graph nodes will be wired up right. 

 

 

 

Key features of Dewret include: 

  • Workflow flexibility: Engineers can define and run simulations using multiple renderers, including Snakemake and CWL, without being locked into a single approach. 
  • Reproducibility: Dewret captures workflow annotations, provenance, and metadata, ensuring results can be trusted, repeated, and built upon. 
  • Scalability: With native support for parallel and distributed execution (e.g. through Dask), Dewret helps projects scale from local test runs to high-performance compute environments. 
  • Transparency: Its open-source nature means engineers can understand, adapt, and extend the framework to suit their specific needs. 

Why It Matters for Photonics Infrastructure 

Photonics research often involves multi-physics simulations: combining optics, materials, thermal, and electronic models in a single workflow. These simulations demand not only computational power but also careful orchestration of different tools and models. This is where Dewret comes in. 

By enabling engineers to: 

  • Use Python to seamlessly integrate different simulation tools into exportable parametrisable pipelines; 
  • Track dependencies, rendered workflow graphs and inputs rigorously in git; 
  • Share and adapt workflows openly within a research community, independently of the workflow framework used for execution; 

A key in-progress feature is to generate multi-engine pipelines - this makes deployment patterns  

We are building Dewret to be a valuable cog in the infrastructure of the UK photonics ecosystem. It provides the scaffolding for faster, more reliable modelling, supporting researchers, SMEs, and larger industrial partners in making better use of shared facilities and high-performance compute assets. 

From Digital Twins to a Stronger UK Ecosystem 

At Flax & Teal, we have long worked on bridging digital simulation and real-world engineering. Our broader portfolio includes digital twin development, workflow and systems integration, and analytics for complex systems. Dewret is a natural extension of this expertise, bringing together lessons from software engineering, data science, and physics into a single, coherent platform. 

For photonics, the implications are clear. The industry needs robust modelling to explore new device architectures, optimise fabrication processes, and validate system-level performance before expensive hardware is built. Dewret strengthens the UK’s simulation infrastructure, ensuring that photonics engineers have the kind of modern, reproducible environments that accelerate innovation and encourage collaboration across academia, SMEs, and global supply chains. 

Looking Ahead 

The development of Dewret is only the beginning. We are actively working with partners in Northern Ireland, across the UK, and worldwide to apply the framework to real photonics challenges - from nanoscale applications to advanced test engineering. We see Dewret as a way to empower engineers and researchers to push boundaries without being constrained by their tools. 

By building a stronger foundation for simulation infrastructure, we can accelerate breakthroughs that matter - in communications, computing, healthcare, and beyond. 

For more information, visit the Dewret documentation or explore the GitHub presentation

Author

Phil Weir

Phil Weir

Founder and Director, Flax & Teal

Phil Weir is Founder and Director of Flax & Teal, a Belfast-based consultancy with a global team specialising in open-source software, data science, and digital engineering solutions. His professional background spans software engineering, research, consultancy, and leadership across multiple sectors including photonics, advanced manufacturing, and cultural heritage. Phil is passionate about building collaborative ecosystems that connect research and industry to accelerate innovation, and is an active contributor to the photonics and digital technology community, mentoring SMEs and supporting cluster development. 

Technology and Innovation programme activities

techUK bring members, industry stakeholders, and UK Government together to champion emerging technologies as an integral part of the UK economy. We help to create an environment where innovation can flourish, helping our members to build relationships, showcase their technology, and grow their business. Visit the programme page here.

 

Upcoming events

Latest news and insights 

Learn more and get involved

 

Sign-up to get the latest updates and opportunities across Technology and Innovation.

 

Here are five reasons to join the Tech and Innovation programme

Download

Join techUK groups

techUK members can get involved in our work by joining our groups, and stay up to date with the latest meetings and opportunities in the programme.

Learn more

Become a techUK member

Our members develop strong networks, build meaningful partnerships and grow their businesses as we all work together to create a thriving environment where industry, government and stakeholders come together to realise the positive outcomes tech can deliver.

Learn more

Meet the team 

Sue Daley OBE

Sue Daley OBE

Director, Technology and Innovation

Laura Foster

Laura Foster

Associate Director - Technology and Innovation, techUK

Kir Nuthi

Kir Nuthi

Head of AI and Data, techUK

Rory Daniels

Rory Daniels

Head of Emerging Technology and Innovation, techUK

Tess Buckley

Tess Buckley

Programme Manager - Digital Ethics and AI Safety, techUK

Usman Ikhlaq

Usman Ikhlaq

Programme Manager - Artificial Intelligence, techUK

Chris Hazell

Chris Hazell

Programme Manager - Cloud, Tech and Innovation, techUK

Elis Thomas

Elis Thomas

Programme Manager, Tech and Innovation, techUK

Ella Shuter

Ella Shuter

Junior Programme Manager, Emerging Technologies, techUK

Harriet Allen

Harriet Allen

Programme Assistant, Technology and Innovation, techUK

Sara Duodu  ​​​​

Sara Duodu ​​​​

Programme Manager ‑ Quantum and Digital Twins, techUK

 

 

 

Related topics

Authors

Phil Weir

Phil Weir

Founder and Director, Flax & Teal

Phil Weir is Founder and Director of Flax & Teal, a Belfast-based consultancy with a global team specialising in open-source software, data science, and digital engineering solutions. His professional background spans software engineering, research, consultancy, and leadership across multiple sectors including photonics, advanced manufacturing, and cultural heritage. Phil is passionate about building collaborative ecosystems that connect research and industry to accelerate innovation, and is an active contributor to the photonics and digital technology community, mentoring SMEs and supporting cluster development.