The gallon is a unit of volume in the imperial unit system with the symbol gal.
1 British imperial gallon is defined as 4.54609 litres or 277.4194 in³.
The term gallon derives directly from the Old Northern French term 'galun' which means 'liquid measure'. The origin of the word prior to this is still unknown. It originated as the base of the system for measuring wine and beer in the UK and has now been adopted across the world and there are similar versions in the US and associated states (although they measure slightly differently).
The cubic yard is a unit of volume derived from the imperial system of units. It uses the symbol yd³.
It equals the volume of a cube with edges that each measure 1 yard. It is equivalent to 27 ft³, 46656 in³ or ≈ 0.764554 m³.
The yard (and derivatives like the cubic yard for example) are the same in both the imperial systems and US customary systems so require less conversion systems to calculate / convert to SI or metric.