More Marshmallow argument updates
This commit is contained in:
parent
e22f36b308
commit
9dbb083ee7
18 changed files with 102 additions and 87 deletions
|
|
@ -169,39 +169,49 @@ class DeleteLSTView(ActionView):
|
|||
microscope.save_settings()
|
||||
|
||||
|
||||
percentile_field = fields.Float(
|
||||
load_default=99.9,
|
||||
metadata={
|
||||
"example": 99.9,
|
||||
"description": (
|
||||
"A float between 0 and 100 setting the centile to use "
|
||||
"to measure the white point of the image. A value "
|
||||
"of 99.9 allows 0.1% of the pixels to be erroneously "
|
||||
"bright - this helps stability in low light."
|
||||
),
|
||||
},
|
||||
)
|
||||
|
||||
|
||||
class AutoExposureFromRawView(ActionView):
|
||||
args = {
|
||||
"target_white_level": fields.Int(
|
||||
load_default=700,
|
||||
example=700,
|
||||
description=(
|
||||
"The pixel value (10-bit format) that we aim for when adjusting shutter/gain."
|
||||
),
|
||||
metadata={
|
||||
"example": 700,
|
||||
"description": (
|
||||
"The pixel value (10-bit format) that we aim for when adjusting shutter/gain."
|
||||
),
|
||||
},
|
||||
),
|
||||
"max_iterations": fields.Int(
|
||||
load_default=20,
|
||||
description=(
|
||||
"The number of adjustments to the camera's settings to make before giving up."
|
||||
),
|
||||
load_default=20,metadata={
|
||||
"description": (
|
||||
"The number of adjustments to the camera's settings to make before giving up."
|
||||
),
|
||||
},
|
||||
),
|
||||
"tolerance": fields.Float(
|
||||
load_default=0.05,
|
||||
example=0.05,
|
||||
description=(
|
||||
"We stop adjusting when we get within this fraction of the target "
|
||||
"value. It is a number between 0 and 1, usually 0.01--0.1."
|
||||
),
|
||||
),
|
||||
"percentile": fields.Float(
|
||||
load_default=99.9,
|
||||
example=99.9,
|
||||
description=(
|
||||
"A float between 0 and 100 setting the centile to use "
|
||||
"to measure the white point of the image. A value "
|
||||
"of 99.9 allows 0.1% of the pixels to be erroneously "
|
||||
"bright - this helps stability in low light."
|
||||
),
|
||||
metadata={
|
||||
"example": 0.05,
|
||||
"description": (
|
||||
"We stop adjusting when we get within this fraction of the target "
|
||||
"value. It is a number between 0 and 1, usually 0.01--0.1."
|
||||
),
|
||||
},
|
||||
),
|
||||
"percentile": percentile_field,
|
||||
}
|
||||
|
||||
def post(self, args):
|
||||
|
|
@ -211,16 +221,7 @@ class AutoExposureFromRawView(ActionView):
|
|||
|
||||
class AutoWhiteBalanceFromRawView(ActionView):
|
||||
args = {
|
||||
"percentile": fields.Float(
|
||||
load_default=99.9,
|
||||
example=99.9,
|
||||
description=(
|
||||
"A float between 0 and 100 setting the centile to use "
|
||||
"to measure the white point of the image. A value "
|
||||
"of 99.9 allows 0.1% of the pixels to be erroneously "
|
||||
"bright - this helps stability in low light."
|
||||
),
|
||||
)
|
||||
"percentile": percentile_field,
|
||||
}
|
||||
|
||||
def post(self, args):
|
||||
|
|
@ -231,8 +232,10 @@ class AutoWhiteBalanceFromRawView(ActionView):
|
|||
class GetRawChannelPercentilesView(ActionView):
|
||||
args = {
|
||||
"percentile": fields.Float(
|
||||
example=99.9,
|
||||
metadata={"description": "A float between 0 and 100 setting the centile to calculate"},
|
||||
metadata={
|
||||
"description": "A float between 0 and 100 setting the centile to calculate",
|
||||
"example": 99.9,
|
||||
},
|
||||
)
|
||||
}
|
||||
schema = fields.List(fields.Integer)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue