Many comments and simplifications.  There is now a problem when loading a lens file.  I don't understand why loading once fails but it works great the second time.  Need to debug this.