Issue 1:
I am working with bidimensional arrays on Numpy. One of my arrays, H, is random, and I want to compute its pseudoinverse. If I use scipy.linalg.pinv2 everything runs smoothly. However, if I use scipy.linalg.pinv, sometimes problems arise.

The problem is that, if the j-th column of H is all 1s, pinv(H) has huge coefficients at the j-th row. This is in turn a problem because, in such cases, np.dot(pinv(H), Y) contains some nan values (Y is an array of small integers).

Now, I am not into linear algebra and numeric computation enough to understand if this is a bug or some precision related property of the two functions. If this is not a bug, please close this issue and I apologize.

I saved the arrays with np.savetxt(fn, a, '%.2e', ';'): please, see https://dl.dropboxusercontent.com/u/48242012/example.tar.gz to find them.

In the provided file, you can see in pinv(H).csv that rows 14, 33, 55, 56 and 99 have huge values, while in pinv2(H) the same rows have more decent values.

(I posted the same question on StackOverflow yesterday, but it did not receive much attention: http://stackoverflow.com/questions/27775986/numpy-scipy-pinv-and-pinv2-behave-differently . I am reposting here just to signal this behaviour and to suggest that it may be documented - I can survive with pinv2.)

I appreciate your efforts.

Issue 2:
it is currently not possible to install scipy on MacOs 12 + M1 Max

python: 3.9.7

Running

OPENBLAS="$(brew --prefix openblas)" python3 -m pip install scipy

yields

2 warnings generated.
/opt/homebrew/bin/gfortran -Wall -g -Wall -g -undefined dynamic_lookup -bundle build/temp.macosx-12.0-arm64-3.9/scipy/integrate/_quadpackmodule.o -L/opt/homebrew/opt/openblas/lib -L/opt/homebrew/Cellar/gcc/11.2.0/lib/gcc/11/gcc/aarch64-apple-darwin20/11.1.0 -L/opt/homebrew/Cellar/gcc/11.2.0/lib/gcc/11/gcc/aarch64-apple-darwin20/11.1.0/../../.. -L/opt/homebrew/Cellar/gcc/11.2.0/lib/gcc/11/gcc/aarch64-apple-darwin20/11.1.0/../../.. -Lbuild/temp.macosx-12.0-arm64-3.9 -Wl,-rpath,/opt/homebrew/opt/openblas/lib -lquadpack -lmach -lopenblas -lopenblas -lgfortran -o build/lib.macosx-12.0-arm64-3.9/scipy/integrate/_quadpack.cpython-39-darwin.so
gfortran: warning: could not understand version 12.0
ld: -rpath can only be used when targeting Mac OS X 10.5 or later
collect2: error: ld returned 1 exit status
error: Command "/opt/homebrew/bin/gfortran -Wall -g -Wall -g -undefined dynamic_lookup -bundle build/temp.macosx-12.0-arm64-3.9/scipy/integrate/_quadpackmodule.o -L/opt/homebrew/opt/openblas/lib -L/opt/homebrew/Cellar/gcc/11.2.0/lib/gcc/11/gcc/aarch64-apple-darwin20/11.1.0 -L/opt/homebrew/Cellar/gcc/11.2.0/lib/gcc/11/gcc/aarch64-apple-darwin20/11.1.0/../../.. -L/opt/homebrew/Cellar/gcc/11.2.0/lib/gcc/11/gcc/aarch64-apple-darwin20/11.1.0/../../.. -Lbuild/temp.macosx-12.0-arm64-3.9 -Wl,-rpath,/opt/homebrew/opt/openblas/lib -lquadpack -lmach -lopenblas -lopenblas -lgfortran -o build/lib.macosx-12.0-arm64-3.9/scipy/integrate/_quadpack.cpython-39-darwin.so" failed with exit status 1
----------------------------------------
ERROR: Failed building wheel for scipy
Failed to build scipy
ERROR: Could not build wheels for scipy, which is required to install pyproject.toml-based projects