0

I get the warning

OpenBLAS WARNING - could not determine the L2 cache size on this system, assuming 256k

in the logs of the "LOGS" tab of the Cloud Function.

There is already a Q/A on this on Stack Overflow at AppEngine warning - OpenBLAS WARNING - could not determine the L2 cache size on this system, but it is not asked for a Google Cloud Function, only for the Google App Engine.

I wonder how I can get rid of this warning in a Google Cloud Function and whether I should care at all?

  • It is just a warning anyway and the quite heavy Cloud Function (with a lot of calculations + saving 50 MB csv, 700 MB needed RAM, 1 GB allocated, 540s timeout time) runs through anyway. Doing nothing can be an accepted answer.
  • Perhaps I can find the L2 cache size somewhere in the settings, which system is meant here?
questionto42
  • 353
  • 5
  • 23
  • The L2 cache is a feature of the CPU you are using. Possible cross-site duplicate of https://stackoverflow.com/questions/55016899/appengine-warning-openblas-warning-could-not-determine-the-l2-cache-size-on – tripleee Feb 04 '22 at 06:49
  • @tripleee This Q/A has the `google-cloud-functions` tag. – questionto42 Feb 04 '22 at 19:53

1 Answers1

1

The warning is just telling you that OpenBLAS which is a dependency of Pandas is not able to determine some settings of Cloud Function environment, most likely due to Cloud Function runs on virtualized environments. I suggest that you just ignore the warning as it is not an issue in Cloud Function.

tripleee
  • 1,416
  • 3
  • 15
  • 24
Catherine O
  • 153
  • 4
  • Makes sense since a CF is also just using a container. I do indeed `import pandas as pd` for the `pd.to_csv()` function :). Good catch. Perhaps a bit similar to running my own docker container locally to get [WARNING: Running pip as the 'root' user](https://stackoverflow.com/a/70586037/11154841) - which you can also just ignore. – questionto42 Feb 04 '22 at 17:48
  • 1
    Might perhaps get fixed with the help of [Compiling numpy with OpenBLAS integration](https://stackoverflow.com/questions/11443302/compiling-numpy-with-openblas-integration). I did not take the time to test this, but it might be possible to use OpenBLAS in a Cloud Function as well. – questionto42 Feb 04 '22 at 18:47
  • @questionto42 - this is not similar to the warning from Pip. By default in a container you are running as root (this can be changed). What pip is warning you is that you can possibly trash the system install when you install into the system python packages, which happens when you run it as root. You could run it as another user and do a --user install in pip, use a python venv, or you can add the argument: "--root-user-action=ignore" or define the environment variable: PIP_ROOT_USER_ACTION=ignore – Kevin Buchs Apr 28 '23 at 15:53
  • @KevinBuchs I cannot test this anymore. This answer here says that it is a problem of a virtualized environment, which would fit to your hint. You should make your hint an answer since it seems to fix the issue easily. – questionto42 May 02 '23 at 15:04