From 29f057db0807019f15ab30d4872e044c4fd6cc52 Mon Sep 17 00:00:00 2001 From: Hal Simpson <hasimpson@usgs.gov> Date: Fri, 13 Nov 2015 09:56:22 -0700 Subject: [PATCH] Imported only the necessary classes from obspy and numpy --- geomagio/Util.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/geomagio/Util.py b/geomagio/Util.py index 1fa4f978..eb20b98c 100644 --- a/geomagio/Util.py +++ b/geomagio/Util.py @@ -1,6 +1,6 @@ import urllib2 -import numpy -import obspy +from numpy import full, nan +from obspy.core import Stats, Trace class ObjectView(object): @@ -65,8 +65,8 @@ def create_empty_trace(trace, channel): obspy.core.Trace Trace a duplicated empty channel. """ - stats = obspy.core.Stats(trace.stats) + stats = Stats(trace.stats) stats.channel = channel count = len(trace.data) - numpy_data = numpy.full((count), numpy.nan) - return obspy.core.Trace(numpy_data, stats) + numpy_data = full((count), nan) + return Trace(numpy_data, stats) -- GitLab