Open jckhang opened 2 years ago
Backward compatibility is not possible with the new syntax. The new syntax has been designed to be mypy and pyright compliant and with more expressiveness. These were things that were not possible in the 1.*
syntax unfortunately.
What difficulties do you precisely have with migrating to the 2.*
version? Have you considered maybe to carefully replace your hints with regular expressions throughout your codebase?
I really like the new API for shapes. However the new change in the
NDArray
is now backward compatible.In v1.4.4, you can construct a NDArray of int32 with any dimension like this
The old ways of hint no longer works and you need to do the same thing with
Backward compatible will make the migration a lot easier.