-- Database schema
| cars : id [ INTEGER ] primary_key , train_id [ INTEGER ] cars.train_id = trains.id , position [ INTEGER ] , shape [ TEXT ] , len [ TEXT ] , sides [ TEXT ] , roof [ TEXT ] , wheels [ INTEGER ] , load_shape [ TEXT ] , load_num [ INTEGER ] | trains : id [ INTEGER ] primary_key , direction [ TEXT ] |
-- -- Among the trains that have at least one non-regular shaped car, what is the percentage of it running in the east direction?

SELECT CAST(COUNT(DISTINCT CASE WHEN T2.direction = 'east' THEN T1.train_id ELSE NULL END) AS REAL) * 100 / COUNT(DISTINCT T1.train_id) FROM cars AS T1 INNER JOIN trains AS T2 ON T1.train_id = T2.id WHERE T1.shape IN ('bucket', 'ellipse');