Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
include pydartdiags/obs_sequence/composite_types.yaml
include src/pydartdiags/obs_sequence/composite_types.yaml

9 changes: 9 additions & 0 deletions docs/api/example_data.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
.. example_data:

=====================
module: data
=====================

.. automodule:: data
:members:
:member-order: bysource
1 change: 1 addition & 0 deletions docs/api/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ API Guide
stats
matplots
plots
example_data
7 changes: 3 additions & 4 deletions examples/01_manipulating/plot_duplicates.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,14 @@

###########################################
# Import the obs_sequence module
import os
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.data import get_example_data

###########################################
# Read in the observation sequence file. In this example we'll use a real obs_seq file,
# the NCEP+ACARS.201303_6H.obs_seq2013030306 file that comes with the pyDARTdiags package.
# the NCEP+ACARS.201303_6H.obs_seq2013030306 file.
# This is 6 hours of observations from March 3, 2013.
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "NCEP+ACARS.201303_6H.obs_seq2013030306")
data_file = get_example_data("NCEP+ACARS.201303_6H.obs_seq2013030306")

obs_seq = obsq.ObsSequence(data_file)

Expand Down
9 changes: 4 additions & 5 deletions examples/01_manipulating/plot_external_fo.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,15 @@

###########################################
# Import the obs_sequence module, and numpy
import os
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.data import get_example_data
import numpy as np

###########################################
# Read in the observation sequence file. In this example we'll use the
# obs_seq.out.tracer file that comes with the pyDARTdiags package.
# This file only has two observations.
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "obs_seq.out.tracer")
# obs_seq.out.tracer file.
# This file only has two observations.
data_file = get_example_data("obs_seq.out.tracer")
obs_seq = obsq.ObsSequence(data_file)

###########################################
Expand Down
11 changes: 4 additions & 7 deletions examples/01_manipulating/plot_join_obs_seq.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,12 @@
###########################################
# Import the obs_sequence module.
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.data import get_example_data

###########################################
# Chose the first obs_seq file to read.
# In this example, we are using a small obs_seq file "obs_seq.final.1000"
# that comes with the pyDARTdiags package
# in the data directory, so we ``import os`` to get the path to the file.
import os
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file1 = os.path.join(data_dir, "obs_seq.final.1000")
# In this example, we are using a small obs_seq file "obs_seq.final.1000".
data_file1 = get_example_data("obs_seq.final.1000")

###########################################
# Read the obs_seq file into an obs_seq object.
Expand All @@ -30,7 +27,7 @@
###########################################
# Chose the second obs_seq file to read.

data_file2 = os.path.join(data_dir, "obs_seq.final.ascii.small")
data_file2 = get_example_data("obs_seq.final.ascii.small")
obs_seq2 = obsq.ObsSequence(data_file2)

print('obs_seq2 has assimilation info:', obs_seq2.has_assimilation_info())
Expand Down
9 changes: 3 additions & 6 deletions examples/01_manipulating/plot_remove_obs.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,12 @@
###########################################
# Import the obs_sequence module
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.data import get_example_data

###########################################
# Chose an obs_seq file to read.
# In this example, we are using a small obs_seq file "obs_seq.final.medium"
# that comes with the pyDARTdiags package
# in the data directory, so we ``import os`` to get the path to the file.
import os
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "obs_seq.final.ascii.medium")
# In this example, we are using a small obs_seq file "obs_seq.final.medium".
data_file = get_example_data("obs_seq.final.ascii.medium")

###########################################
# Read the obs_seq file into an obs_seq object.
Expand Down
9 changes: 3 additions & 6 deletions examples/02_visualizing/plot_qc_hover.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,17 @@

###########################################
# Import the modules
import os
import plotly.express as px
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.data import get_example_data

# sphinx_gallery_thumbnail_path = '_static/geo_thumb.png'


###########################################
# Read the obs_seq file into an obs_seq object.
# In this example, we use a small obs_seq file "obs_seq.final.ascii.medium"
# that comes with the pyDARTdiags package
# in the data directory, so we use ``os`` to get the path to the file
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "obs_seq.final.ascii.medium")
# In this example, we use a small obs_seq file "obs_seq.final.ascii.medium".
data_file = get_example_data("obs_seq.final.ascii.medium")

obs_seq = obsq.ObsSequence(data_file)

Expand Down
7 changes: 2 additions & 5 deletions examples/03_diagnostics/plot_evolution.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,13 @@
# and the matplots module for plotting.
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.matplots import matplots as mp
from pydartdiags.data import get_example_data

###########################################
# Chose an obs_seq file to read.
# In this example, we are using "obs_seq.final.lorenz_96" which is from
# a Lorenz 96 model run with the DART assimilation system.
# The obs_seq.final.lorenz_96 file comes with the pyDARTdiags package
# in the data directory, so we ``import os`` to get the path to the file.
import os
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "obs_seq.final.lorenz_96")
data_file = get_example_data("obs_seq.final.lorenz_96")

###########################################
# Read the obs_seq file into an obs_seq object.
Expand Down
10 changes: 4 additions & 6 deletions examples/03_diagnostics/plot_grand_stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,12 @@
# and the statistics module.
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.stats import stats
from pydartdiags.data import get_example_data

###########################################
# Chose an obs_seq file to read.
# This is a small obs_seq file "obs_seq.final.ascii.medium"
# that comes with the pyDARTdiags package
# in the data directory, so we ``import os`` to get the path to the file
import os
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "obs_seq.final.ascii.medium")
# This is a small obs_seq file "obs_seq.final.ascii.medium".
data_file = get_example_data("obs_seq.final.ascii.medium")


###########################################
Expand Down
9 changes: 3 additions & 6 deletions examples/03_diagnostics/plot_profiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,12 @@
# and the matplots module for plotting.
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.matplots import matplots as mp
from pydartdiags.data import get_example_data

###########################################
# Chose an obs_seq file to read.
# In this example, we are using a small obs_seq file "obs_seq.final.1000"
# that comes with the pyDARTdiags package
# in the data directory, so we ``import os`` to get the path to the file.
import os
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "obs_seq.final.1000")
# In this example, we are using a small obs_seq file "obs_seq.final.1000".
data_file = get_example_data("obs_seq.final.1000")

###########################################
# Read the obs_seq file into an obs_seq object.
Expand Down
9 changes: 3 additions & 6 deletions examples/03_diagnostics/plot_qc_poss_vs_used.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,12 @@
###########################################
# Import the obs_sequence module
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.data import get_example_data

###########################################
# Chose an obs_seq file to read.
# This is a small obs_seq file "obs_seq.final.ascii.small"
# that comes with the pyDARTdiags package
# in the data directory, so we ``import os`` to get the path to the file
import os
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "obs_seq.final.ascii.small")
# This is a small obs_seq file "obs_seq.final.ascii.small".
data_file = get_example_data("obs_seq.final.ascii.small")

###########################################
# read the obs_seq file into an obs_seq object
Expand Down
9 changes: 3 additions & 6 deletions examples/03_diagnostics/plot_rank_histogram.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,12 @@
# and the matplots module for plotting.
import pydartdiags.obs_sequence.obs_sequence as obsq
from pydartdiags.matplots import matplots as mp
from pydartdiags.data import get_example_data

###########################################
# Chose an obs_seq file to read.
# In this example, we are using a small obs_seq file "obs_seq.final.1000"
# that comes with the pyDARTdiags package
# in the data directory, so we ``import os`` to get the path to the file.
import os
data_dir = os.path.join(os.getcwd(), "../..", "data")
data_file = os.path.join(data_dir, "obs_seq.final.1000")
# In this example, we are using a small obs_seq file "obs_seq.final.1000".
data_file = get_example_data("obs_seq.final.1000")

###########################################
# Read the obs_seq file into an obs_seq object.
Expand Down
5 changes: 4 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[build-system]
requires = ["setuptools", "wheel"]
requires = ["setuptools>=64", "wheel"]
build-backend = "setuptools.build_meta"

[project]
Expand Down Expand Up @@ -29,3 +29,6 @@ Homepage = "https://github.com/NCAR/pyDARTdiags.git"
Issues = "https://github.com/NCAR/pyDARTdiags/issues"
Documentation = "https://ncar.github.io/pyDARTdiags"

[tool.setuptools.packages.find]
where = ["src"]
include = ["pydartdiags*"]
31 changes: 0 additions & 31 deletions setup.py

This file was deleted.

Loading
Loading