Code Monkey home page Code Monkey logo

python-toolbox-faq's Introduction

Forum for questions and answers about Python/Pangeo Toolbox

python-toolbox-faq's People

Contributors

andersy005 avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

python-toolbox-faq's Issues

Where can I get X questions answered, where X is a Python package such as numpy, dask, xarray?

How to use dask on CGD's Hobart?

ncar-jobqueue: https://github.com/NCAR/ncar-jobqueue provides convenient utilities for using dask-jobqueue on some clusters used @ NCAR. Hobart is one of the supported clusters:

  • Install ncar-jobqueue
pip install ncar-jobqueue
  • Import and use NCARCluster from ncar-jobqueue
>>> from ncar_jobqueue import NCARCluster
>>> from dask.distributed import Client
>>> cluster = NCARCluster()
>>> cluster
NCARCluster(cores=0, memory=0 B, workers=0/0, jobs=0/0)
>>> cluster.scale(2)
>>> cluster
NCARCluster(cores=96, memory=192.00 GB, workers=2/2, jobs=2/2)
>>> client = Client(cluster)

cc @jkshuman

Originally posted by @matt-long in ncar-hackathons/faq#1

Which warning messages (Non-fatal alerts) from python packages should I ignore or be attentive to?

Python packages use the Python warnings module to issue warning messages. The details of using the warnings module are general to Python, and apply to any Python software that uses this system.

Since warnings are not fatal, a program may encounter the same warn-able situation many times in the course of running.

Warning messages are typically issued in situations where it is useful to alert the user of some condition in a program, where that condition (normally) doesn’t warrant raising an exception and terminating the program. For example, one might want to issue a warning when a program uses an obsolete module.

Categories

The warning categories are described in the documentation

How to hide warnings?

At the beginning of your script or jupyter notebook, include:

import warnings
warnings.filterwarnings('ignore')

Note: This might not suppress all the warnings, but it will suppress most of them.

Which warnings should I be attentive to?

DeprecationWarnings

It's a good practice to gradually deprecate one's library's API, so that users get advance warning of coming changes. Therefore, if you see deprecation warning from a package that you plan on updating in the future, you should be pay attention that features might go away in the future releases.

Which warnings should I be ignore?

TODO

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.