Debug Node streaming
This commit is contained in:
parent
d8f0fe3c19
commit
f024ea8c45
@ -25,9 +25,9 @@
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"load = ld2dap.LoadTIFF('../Data/test.tiff')\n",
|
||||
"trsh = ld2dap.Treshold(1e3)\n",
|
||||
"trsh = ld2dap.Treshold(1e4)\n",
|
||||
"disp = ld2dap.ShowFig(fname=None)\n",
|
||||
"out = ld2dap.Output()"
|
||||
"out = ld2dap.RawOutput()"
|
||||
]
|
||||
},
|
||||
{
|
||||
@ -56,7 +56,17 @@
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"out.data, out.metadata"
|
||||
"out.data.shape"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"for i, m in enumerate(out.metadata):\n",
|
||||
" print('{}: {}'.format(i, m))"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
||||
21
ld2dap/RawOutput.py
Normal file
21
ld2dap/RawOutput.py
Normal file
@ -0,0 +1,21 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
# \file RawOutput.py
|
||||
# \brief TODO
|
||||
# \author Florent Guiotte <florent.guiotte@gmail.com>
|
||||
# \version 0.1
|
||||
# \date 13 avril 2018
|
||||
#
|
||||
# TODO details
|
||||
|
||||
from ld2dap.core import Output
|
||||
|
||||
class RawOutput(Output):
|
||||
def __init__(self):
|
||||
super().__init__(self.__class__.__name__)
|
||||
self.data = None
|
||||
self.metadata = None
|
||||
|
||||
def _process(self, data, metadata):
|
||||
self.data = data
|
||||
self.metadata = metadata
|
||||
@ -13,3 +13,4 @@ from .Treshold import Treshold
|
||||
from .LoadTIFF import LoadTIFF
|
||||
from .SaveFig import SaveFig
|
||||
from .ShowFig import ShowFig
|
||||
from .RawOutput import RawOutput
|
||||
|
||||
@ -23,3 +23,7 @@ class Stack(object):
|
||||
if symb is not None:
|
||||
for i in range(size):
|
||||
self.symb.append(symb.copy() if isinstance(symb, list) else [symb])
|
||||
|
||||
def __str__(self):
|
||||
return ("Stack: begin: {}, end: {}, desc: {}, symb: {}".format(
|
||||
self.begin, self.end, self.desc, self.symb))
|
||||
|
||||
Loading…
Reference in New Issue
Block a user