Since you already have `units` defined, this could simplify to:
```
points = units.date2num(valid_date)
```