body_hash
stringlengths 64
64
| body
stringlengths 23
109k
| docstring
stringlengths 1
57k
| path
stringlengths 4
198
| name
stringlengths 1
115
| repository_name
stringlengths 7
111
| repository_stars
float64 0
191k
| lang
stringclasses 1
value | body_without_docstring
stringlengths 14
108k
| unified
stringlengths 45
133k
|
---|---|---|---|---|---|---|---|---|---|
2e2ad7407a7529140c0b0fe6612909b549d3e5737a6024a70a81998ce77eb581 | def settings(_klass=None, *, prefix: str='', case_sensitive: bool=False, frozen: bool=True, aliases: Mapping=None):
'Create a typed class which fetches its defaults from env vars.\n\n The resolution order of values is `default(s) -> env value(s) -> passed value(s)`.\n\n Settings instances are indistinguishable from other `typical` dataclasses at\n run-time and are frozen by default. If you really want your settings to be mutable,\n you may pass in `frozen=False` manually.\n\n Parameters\n ----------\n prefix\n The prefix to strip from you env variables, i.e., `APP_`\n case_sensitive\n Whether your variables are case-sensitive. Defaults to `False`.\n frozen\n Whether to generate a frozen dataclass. Defaults to `True`\n aliases\n An optional mapping of potential aliases for your dataclass\'s fields.\n `{\'other_foo\': \'foo\'}` will locate the env var `OTHER_FOO` and place it\n on the `Bar.foo` attribute.\n\n Examples\n --------\n >>> import os\n >>> import typic\n >>>\n >>> os.environ[\'FOO\'] = "1"\n >>>\n >>> @typic.settings\n ... class Bar:\n ... foo: int\n ...\n >>> Bar()\n Bar(foo=1)\n >>> Bar("3")\n Bar(foo=3)\n >>> bar = Bar()\n >>> bar.foo = 2\n Traceback (most recent call last):\n ...\n dataclasses.FrozenInstanceError: cannot assign to field \'foo\'\n '
aliases = (aliases or {})
def settings_wrapper(_cls):
_resolve_from_env(_cls, prefix, case_sensitive, aliases)
cls = wrap_cls(dataclasses.dataclass(_cls, frozen=frozen), jsonschema=False, always=False)
return cls
return (settings_wrapper(_klass) if (_klass is not None) else settings_wrapper) | Create a typed class which fetches its defaults from env vars.
The resolution order of values is `default(s) -> env value(s) -> passed value(s)`.
Settings instances are indistinguishable from other `typical` dataclasses at
run-time and are frozen by default. If you really want your settings to be mutable,
you may pass in `frozen=False` manually.
Parameters
----------
prefix
The prefix to strip from you env variables, i.e., `APP_`
case_sensitive
Whether your variables are case-sensitive. Defaults to `False`.
frozen
Whether to generate a frozen dataclass. Defaults to `True`
aliases
An optional mapping of potential aliases for your dataclass's fields.
`{'other_foo': 'foo'}` will locate the env var `OTHER_FOO` and place it
on the `Bar.foo` attribute.
Examples
--------
>>> import os
>>> import typic
>>>
>>> os.environ['FOO'] = "1"
>>>
>>> @typic.settings
... class Bar:
... foo: int
...
>>> Bar()
Bar(foo=1)
>>> Bar("3")
Bar(foo=3)
>>> bar = Bar()
>>> bar.foo = 2
Traceback (most recent call last):
...
dataclasses.FrozenInstanceError: cannot assign to field 'foo' | typic/api.py | settings | wyfo/typical | 157 | python | def settings(_klass=None, *, prefix: str=, case_sensitive: bool=False, frozen: bool=True, aliases: Mapping=None):
'Create a typed class which fetches its defaults from env vars.\n\n The resolution order of values is `default(s) -> env value(s) -> passed value(s)`.\n\n Settings instances are indistinguishable from other `typical` dataclasses at\n run-time and are frozen by default. If you really want your settings to be mutable,\n you may pass in `frozen=False` manually.\n\n Parameters\n ----------\n prefix\n The prefix to strip from you env variables, i.e., `APP_`\n case_sensitive\n Whether your variables are case-sensitive. Defaults to `False`.\n frozen\n Whether to generate a frozen dataclass. Defaults to `True`\n aliases\n An optional mapping of potential aliases for your dataclass\'s fields.\n `{\'other_foo\': \'foo\'}` will locate the env var `OTHER_FOO` and place it\n on the `Bar.foo` attribute.\n\n Examples\n --------\n >>> import os\n >>> import typic\n >>>\n >>> os.environ[\'FOO\'] = "1"\n >>>\n >>> @typic.settings\n ... class Bar:\n ... foo: int\n ...\n >>> Bar()\n Bar(foo=1)\n >>> Bar("3")\n Bar(foo=3)\n >>> bar = Bar()\n >>> bar.foo = 2\n Traceback (most recent call last):\n ...\n dataclasses.FrozenInstanceError: cannot assign to field \'foo\'\n '
aliases = (aliases or {})
def settings_wrapper(_cls):
_resolve_from_env(_cls, prefix, case_sensitive, aliases)
cls = wrap_cls(dataclasses.dataclass(_cls, frozen=frozen), jsonschema=False, always=False)
return cls
return (settings_wrapper(_klass) if (_klass is not None) else settings_wrapper) | def settings(_klass=None, *, prefix: str=, case_sensitive: bool=False, frozen: bool=True, aliases: Mapping=None):
'Create a typed class which fetches its defaults from env vars.\n\n The resolution order of values is `default(s) -> env value(s) -> passed value(s)`.\n\n Settings instances are indistinguishable from other `typical` dataclasses at\n run-time and are frozen by default. If you really want your settings to be mutable,\n you may pass in `frozen=False` manually.\n\n Parameters\n ----------\n prefix\n The prefix to strip from you env variables, i.e., `APP_`\n case_sensitive\n Whether your variables are case-sensitive. Defaults to `False`.\n frozen\n Whether to generate a frozen dataclass. Defaults to `True`\n aliases\n An optional mapping of potential aliases for your dataclass\'s fields.\n `{\'other_foo\': \'foo\'}` will locate the env var `OTHER_FOO` and place it\n on the `Bar.foo` attribute.\n\n Examples\n --------\n >>> import os\n >>> import typic\n >>>\n >>> os.environ[\'FOO\'] = "1"\n >>>\n >>> @typic.settings\n ... class Bar:\n ... foo: int\n ...\n >>> Bar()\n Bar(foo=1)\n >>> Bar("3")\n Bar(foo=3)\n >>> bar = Bar()\n >>> bar.foo = 2\n Traceback (most recent call last):\n ...\n dataclasses.FrozenInstanceError: cannot assign to field \'foo\'\n '
aliases = (aliases or {})
def settings_wrapper(_cls):
_resolve_from_env(_cls, prefix, case_sensitive, aliases)
cls = wrap_cls(dataclasses.dataclass(_cls, frozen=frozen), jsonschema=False, always=False)
return cls
return (settings_wrapper(_klass) if (_klass is not None) else settings_wrapper)<|docstring|>Create a typed class which fetches its defaults from env vars.
The resolution order of values is `default(s) -> env value(s) -> passed value(s)`.
Settings instances are indistinguishable from other `typical` dataclasses at
run-time and are frozen by default. If you really want your settings to be mutable,
you may pass in `frozen=False` manually.
Parameters
----------
prefix
The prefix to strip from you env variables, i.e., `APP_`
case_sensitive
Whether your variables are case-sensitive. Defaults to `False`.
frozen
Whether to generate a frozen dataclass. Defaults to `True`
aliases
An optional mapping of potential aliases for your dataclass's fields.
`{'other_foo': 'foo'}` will locate the env var `OTHER_FOO` and place it
on the `Bar.foo` attribute.
Examples
--------
>>> import os
>>> import typic
>>>
>>> os.environ['FOO'] = "1"
>>>
>>> @typic.settings
... class Bar:
... foo: int
...
>>> Bar()
Bar(foo=1)
>>> Bar("3")
Bar(foo=3)
>>> bar = Bar()
>>> bar.foo = 2
Traceback (most recent call last):
...
dataclasses.FrozenInstanceError: cannot assign to field 'foo'<|endoftext|> |
b324b895862f611c0855a8a037e957f39056b84d354922d055465ab34d3b4409 | @lru_cache(maxsize=None)
def schema(obj: Type[ObjectT], *, primitive: bool=False) -> SchemaReturnT:
'Get a JSON schema for object for the given object.\n\n Parameters\n ----------\n obj\n The class for which you wish to generate a JSON schema\n primitive\n Whether to return an instance of :py:class:`typic.schema.ObjectSchemaField` or\n a "primitive" (dict object).\n\n Examples\n --------\n >>> import typic\n >>>\n >>> @typic.klass\n ... class Foo:\n ... bar: str\n ...\n >>> typic.schema(Foo)\n ObjectSchemaField(title=\'Foo\', description=\'Foo(bar: str)\', properties={\'bar\': StrSchemaField()}, additionalProperties=False, required=(\'bar\',))\n >>> typic.schema(Foo, primitive=True)\n {\'type\': \'object\', \'title\': \'Foo\', \'description\': \'Foo(bar: str)\', \'properties\': {\'bar\': {\'type\': \'string\'}}, \'additionalProperties\': False, \'required\': [\'bar\'], \'definitions\': {}}\n\n '
if (obj in {FunctionType, MethodType}):
raise ValueError('Cannot build schema for function or method.')
annotation = resolver.resolve(obj)
schm = schema_builder.get_field(annotation)
try:
setattr(obj, SCHEMA_NAME, schm)
except (AttributeError, TypeError):
pass
return cast(SchemaReturnT, (schm.primitive() if primitive else schm)) | Get a JSON schema for object for the given object.
Parameters
----------
obj
The class for which you wish to generate a JSON schema
primitive
Whether to return an instance of :py:class:`typic.schema.ObjectSchemaField` or
a "primitive" (dict object).
Examples
--------
>>> import typic
>>>
>>> @typic.klass
... class Foo:
... bar: str
...
>>> typic.schema(Foo)
ObjectSchemaField(title='Foo', description='Foo(bar: str)', properties={'bar': StrSchemaField()}, additionalProperties=False, required=('bar',))
>>> typic.schema(Foo, primitive=True)
{'type': 'object', 'title': 'Foo', 'description': 'Foo(bar: str)', 'properties': {'bar': {'type': 'string'}}, 'additionalProperties': False, 'required': ['bar'], 'definitions': {}} | typic/api.py | schema | wyfo/typical | 157 | python | @lru_cache(maxsize=None)
def schema(obj: Type[ObjectT], *, primitive: bool=False) -> SchemaReturnT:
'Get a JSON schema for object for the given object.\n\n Parameters\n ----------\n obj\n The class for which you wish to generate a JSON schema\n primitive\n Whether to return an instance of :py:class:`typic.schema.ObjectSchemaField` or\n a "primitive" (dict object).\n\n Examples\n --------\n >>> import typic\n >>>\n >>> @typic.klass\n ... class Foo:\n ... bar: str\n ...\n >>> typic.schema(Foo)\n ObjectSchemaField(title=\'Foo\', description=\'Foo(bar: str)\', properties={\'bar\': StrSchemaField()}, additionalProperties=False, required=(\'bar\',))\n >>> typic.schema(Foo, primitive=True)\n {\'type\': \'object\', \'title\': \'Foo\', \'description\': \'Foo(bar: str)\', \'properties\': {\'bar\': {\'type\': \'string\'}}, \'additionalProperties\': False, \'required\': [\'bar\'], \'definitions\': {}}\n\n '
if (obj in {FunctionType, MethodType}):
raise ValueError('Cannot build schema for function or method.')
annotation = resolver.resolve(obj)
schm = schema_builder.get_field(annotation)
try:
setattr(obj, SCHEMA_NAME, schm)
except (AttributeError, TypeError):
pass
return cast(SchemaReturnT, (schm.primitive() if primitive else schm)) | @lru_cache(maxsize=None)
def schema(obj: Type[ObjectT], *, primitive: bool=False) -> SchemaReturnT:
'Get a JSON schema for object for the given object.\n\n Parameters\n ----------\n obj\n The class for which you wish to generate a JSON schema\n primitive\n Whether to return an instance of :py:class:`typic.schema.ObjectSchemaField` or\n a "primitive" (dict object).\n\n Examples\n --------\n >>> import typic\n >>>\n >>> @typic.klass\n ... class Foo:\n ... bar: str\n ...\n >>> typic.schema(Foo)\n ObjectSchemaField(title=\'Foo\', description=\'Foo(bar: str)\', properties={\'bar\': StrSchemaField()}, additionalProperties=False, required=(\'bar\',))\n >>> typic.schema(Foo, primitive=True)\n {\'type\': \'object\', \'title\': \'Foo\', \'description\': \'Foo(bar: str)\', \'properties\': {\'bar\': {\'type\': \'string\'}}, \'additionalProperties\': False, \'required\': [\'bar\'], \'definitions\': {}}\n\n '
if (obj in {FunctionType, MethodType}):
raise ValueError('Cannot build schema for function or method.')
annotation = resolver.resolve(obj)
schm = schema_builder.get_field(annotation)
try:
setattr(obj, SCHEMA_NAME, schm)
except (AttributeError, TypeError):
pass
return cast(SchemaReturnT, (schm.primitive() if primitive else schm))<|docstring|>Get a JSON schema for object for the given object.
Parameters
----------
obj
The class for which you wish to generate a JSON schema
primitive
Whether to return an instance of :py:class:`typic.schema.ObjectSchemaField` or
a "primitive" (dict object).
Examples
--------
>>> import typic
>>>
>>> @typic.klass
... class Foo:
... bar: str
...
>>> typic.schema(Foo)
ObjectSchemaField(title='Foo', description='Foo(bar: str)', properties={'bar': StrSchemaField()}, additionalProperties=False, required=('bar',))
>>> typic.schema(Foo, primitive=True)
{'type': 'object', 'title': 'Foo', 'description': 'Foo(bar: str)', 'properties': {'bar': {'type': 'string'}}, 'additionalProperties': False, 'required': ['bar'], 'definitions': {}}<|endoftext|> |
0670c0ac20f72cb2de8d5573befa310cbf1b2965a45640ee982a9c0351d0cb00 | def __init__(self, bag_capacity=9, item_sizes=(2, 3), item_probabilities=(0.8, 0.2), time_horizon=1000, reward_scale=1.0, bin_observation_scale=1.0, time_in_observation=False, time_remaining_equality_ignore=False):
'Initializes BinPacking\n\n Args:\n bag_capacity (int): limit of total size of items in the single bag.\n item_sizes (tuple): possible sizes of items.\n item_probabilities (tuple): distribution over item sizes sampled\n at each timestep.\n time_horizon (int): number of timesteps in singe episode.\n reward_scale (float): rescaling factor for rewards\n bin_observation_scale (float): rescaling factor for part of\n observation encoding number of bags with given filling level.\n time_in_observation (bool): if observation should consist scalar\n (in range [0,1]) encoding remaining number of timesteps.\n time_remaining_equality_ignore: if time remaining should be taken\n into consideration while comparing two states (this works only\n when time_in_observation is set to True)\n '
self._env = BinPackingNewBinForInvalidAction(bag_capacity=bag_capacity, item_sizes=item_sizes, item_probabilities=item_probabilities, time_horizon=time_horizon)
self._reward_scale = reward_scale
self._bin_observation_scale = bin_observation_scale
self.time_in_obs = time_in_observation
self._time_remaining_equality_ignore = time_remaining_equality_ignore
self.action_space = self._env.action_space
additional_obs_dim = (1 if self.time_in_obs else 0)
self.observation_space = gym.spaces.Box(shape=((self._env.observation_space.shape[0] + additional_obs_dim),), low=(- np.inf), high=np.inf, dtype=np.float32) | Initializes BinPacking
Args:
bag_capacity (int): limit of total size of items in the single bag.
item_sizes (tuple): possible sizes of items.
item_probabilities (tuple): distribution over item sizes sampled
at each timestep.
time_horizon (int): number of timesteps in singe episode.
reward_scale (float): rescaling factor for rewards
bin_observation_scale (float): rescaling factor for part of
observation encoding number of bags with given filling level.
time_in_observation (bool): if observation should consist scalar
(in range [0,1]) encoding remaining number of timesteps.
time_remaining_equality_ignore: if time remaining should be taken
into consideration while comparing two states (this works only
when time_in_observation is set to True) | alpacka/envs/bin_packing.py | __init__ | shoot-tree-search/sts | 2 | python | def __init__(self, bag_capacity=9, item_sizes=(2, 3), item_probabilities=(0.8, 0.2), time_horizon=1000, reward_scale=1.0, bin_observation_scale=1.0, time_in_observation=False, time_remaining_equality_ignore=False):
'Initializes BinPacking\n\n Args:\n bag_capacity (int): limit of total size of items in the single bag.\n item_sizes (tuple): possible sizes of items.\n item_probabilities (tuple): distribution over item sizes sampled\n at each timestep.\n time_horizon (int): number of timesteps in singe episode.\n reward_scale (float): rescaling factor for rewards\n bin_observation_scale (float): rescaling factor for part of\n observation encoding number of bags with given filling level.\n time_in_observation (bool): if observation should consist scalar\n (in range [0,1]) encoding remaining number of timesteps.\n time_remaining_equality_ignore: if time remaining should be taken\n into consideration while comparing two states (this works only\n when time_in_observation is set to True)\n '
self._env = BinPackingNewBinForInvalidAction(bag_capacity=bag_capacity, item_sizes=item_sizes, item_probabilities=item_probabilities, time_horizon=time_horizon)
self._reward_scale = reward_scale
self._bin_observation_scale = bin_observation_scale
self.time_in_obs = time_in_observation
self._time_remaining_equality_ignore = time_remaining_equality_ignore
self.action_space = self._env.action_space
additional_obs_dim = (1 if self.time_in_obs else 0)
self.observation_space = gym.spaces.Box(shape=((self._env.observation_space.shape[0] + additional_obs_dim),), low=(- np.inf), high=np.inf, dtype=np.float32) | def __init__(self, bag_capacity=9, item_sizes=(2, 3), item_probabilities=(0.8, 0.2), time_horizon=1000, reward_scale=1.0, bin_observation_scale=1.0, time_in_observation=False, time_remaining_equality_ignore=False):
'Initializes BinPacking\n\n Args:\n bag_capacity (int): limit of total size of items in the single bag.\n item_sizes (tuple): possible sizes of items.\n item_probabilities (tuple): distribution over item sizes sampled\n at each timestep.\n time_horizon (int): number of timesteps in singe episode.\n reward_scale (float): rescaling factor for rewards\n bin_observation_scale (float): rescaling factor for part of\n observation encoding number of bags with given filling level.\n time_in_observation (bool): if observation should consist scalar\n (in range [0,1]) encoding remaining number of timesteps.\n time_remaining_equality_ignore: if time remaining should be taken\n into consideration while comparing two states (this works only\n when time_in_observation is set to True)\n '
self._env = BinPackingNewBinForInvalidAction(bag_capacity=bag_capacity, item_sizes=item_sizes, item_probabilities=item_probabilities, time_horizon=time_horizon)
self._reward_scale = reward_scale
self._bin_observation_scale = bin_observation_scale
self.time_in_obs = time_in_observation
self._time_remaining_equality_ignore = time_remaining_equality_ignore
self.action_space = self._env.action_space
additional_obs_dim = (1 if self.time_in_obs else 0)
self.observation_space = gym.spaces.Box(shape=((self._env.observation_space.shape[0] + additional_obs_dim),), low=(- np.inf), high=np.inf, dtype=np.float32)<|docstring|>Initializes BinPacking
Args:
bag_capacity (int): limit of total size of items in the single bag.
item_sizes (tuple): possible sizes of items.
item_probabilities (tuple): distribution over item sizes sampled
at each timestep.
time_horizon (int): number of timesteps in singe episode.
reward_scale (float): rescaling factor for rewards
bin_observation_scale (float): rescaling factor for part of
observation encoding number of bags with given filling level.
time_in_observation (bool): if observation should consist scalar
(in range [0,1]) encoding remaining number of timesteps.
time_remaining_equality_ignore: if time remaining should be taken
into consideration while comparing two states (this works only
when time_in_observation is set to True)<|endoftext|> |
0af375cb03137adadcfa43c3c1892ae4b720b2657dd2b359260dddef16728aae | def clone_state(self):
'Returns the current environment state.'
return self.BinPackingState(num_bins_levels=self._env.num_bins_levels.copy(), item_size=self._env.item_size, time_remaining=self._env.time_remaining, time_remaining_equality_ignore=self._time_remaining_equality_ignore) | Returns the current environment state. | alpacka/envs/bin_packing.py | clone_state | shoot-tree-search/sts | 2 | python | def clone_state(self):
return self.BinPackingState(num_bins_levels=self._env.num_bins_levels.copy(), item_size=self._env.item_size, time_remaining=self._env.time_remaining, time_remaining_equality_ignore=self._time_remaining_equality_ignore) | def clone_state(self):
return self.BinPackingState(num_bins_levels=self._env.num_bins_levels.copy(), item_size=self._env.item_size, time_remaining=self._env.time_remaining, time_remaining_equality_ignore=self._time_remaining_equality_ignore)<|docstring|>Returns the current environment state.<|endoftext|> |
3887ed6868474e8ac278d618d832815e606c0b818502ebbccc8b5d91de41d712 | def restore_state(self, state):
'Restores environment state, returns the observation.'
assert isinstance(state, self.BinPackingState)
state = deepcopy(state)
self._env.num_bins_levels = state.num_bins_levels
self._env.item_size = state.item_size
self._env.time_remaining = state.time_remaining
return self._get_observation() | Restores environment state, returns the observation. | alpacka/envs/bin_packing.py | restore_state | shoot-tree-search/sts | 2 | python | def restore_state(self, state):
assert isinstance(state, self.BinPackingState)
state = deepcopy(state)
self._env.num_bins_levels = state.num_bins_levels
self._env.item_size = state.item_size
self._env.time_remaining = state.time_remaining
return self._get_observation() | def restore_state(self, state):
assert isinstance(state, self.BinPackingState)
state = deepcopy(state)
self._env.num_bins_levels = state.num_bins_levels
self._env.item_size = state.item_size
self._env.time_remaining = state.time_remaining
return self._get_observation()<|docstring|>Restores environment state, returns the observation.<|endoftext|> |
9518e0f50720b09948763079637465426e0e7a90b27adb06e86f1288bd5d6984 | def produce(self, *, inputs: Inputs, iterations: int=None, timeout: float=None) -> base.CallResult[Outputs]:
'\n Inputs: DataFrame of features or numerical inputs\n Returns: Pandas DataFrame Containing predictions\n '
if (not self._fitted):
raise PrimitiveNotFittedError('Primitive not fitted.')
(XTest, _, feature_columns, label_name_columns) = self._curate_data(training_inputs=inputs, get_labels=True)
outputs = inputs.remove_columns(feature_columns)
predictions = self._kmeans.predict(XTest)
predictions = container.DataFrame(predictions, generate_metadata=True)
if (len(label_name_columns) != 0):
for col in range(predictions.shape[1]):
col_dict = dict(predictions.metadata.query((metadata_base.ALL_ELEMENTS, col)))
col_dict['structural_type'] = type(1.0)
col_dict['name'] = label_name_columns[col]
col_dict['semantic_types'] = ('http://schema.org/Float', 'https://metadata.datadrivendiscovery.org/types/PredictedTarget')
predictions.metadata = predictions.metadata.update((metadata_base.ALL_ELEMENTS, col), col_dict)
predictions.columns = label_name_columns
else:
for col in range(predictions.shape[1]):
col_dict = dict(predictions.metadata.query((metadata_base.ALL_ELEMENTS, col)))
col_dict['structural_type'] = type(1.0)
col_dict['name'] = 'KMeansPredictions'
col_dict['semantic_types'] = ('http://schema.org/Float', 'https://metadata.datadrivendiscovery.org/types/PredictedTarget')
predictions.metadata = predictions.metadata.update((metadata_base.ALL_ELEMENTS, col), col_dict)
outputs = outputs.append_columns(predictions)
return base.CallResult(outputs) | Inputs: DataFrame of features or numerical inputs
Returns: Pandas DataFrame Containing predictions | primitives_ubc/kmeans/kmeansClustering.py | produce | tonyjo/ubc_primitives | 0 | python | def produce(self, *, inputs: Inputs, iterations: int=None, timeout: float=None) -> base.CallResult[Outputs]:
'\n Inputs: DataFrame of features or numerical inputs\n Returns: Pandas DataFrame Containing predictions\n '
if (not self._fitted):
raise PrimitiveNotFittedError('Primitive not fitted.')
(XTest, _, feature_columns, label_name_columns) = self._curate_data(training_inputs=inputs, get_labels=True)
outputs = inputs.remove_columns(feature_columns)
predictions = self._kmeans.predict(XTest)
predictions = container.DataFrame(predictions, generate_metadata=True)
if (len(label_name_columns) != 0):
for col in range(predictions.shape[1]):
col_dict = dict(predictions.metadata.query((metadata_base.ALL_ELEMENTS, col)))
col_dict['structural_type'] = type(1.0)
col_dict['name'] = label_name_columns[col]
col_dict['semantic_types'] = ('http://schema.org/Float', 'https://metadata.datadrivendiscovery.org/types/PredictedTarget')
predictions.metadata = predictions.metadata.update((metadata_base.ALL_ELEMENTS, col), col_dict)
predictions.columns = label_name_columns
else:
for col in range(predictions.shape[1]):
col_dict = dict(predictions.metadata.query((metadata_base.ALL_ELEMENTS, col)))
col_dict['structural_type'] = type(1.0)
col_dict['name'] = 'KMeansPredictions'
col_dict['semantic_types'] = ('http://schema.org/Float', 'https://metadata.datadrivendiscovery.org/types/PredictedTarget')
predictions.metadata = predictions.metadata.update((metadata_base.ALL_ELEMENTS, col), col_dict)
outputs = outputs.append_columns(predictions)
return base.CallResult(outputs) | def produce(self, *, inputs: Inputs, iterations: int=None, timeout: float=None) -> base.CallResult[Outputs]:
'\n Inputs: DataFrame of features or numerical inputs\n Returns: Pandas DataFrame Containing predictions\n '
if (not self._fitted):
raise PrimitiveNotFittedError('Primitive not fitted.')
(XTest, _, feature_columns, label_name_columns) = self._curate_data(training_inputs=inputs, get_labels=True)
outputs = inputs.remove_columns(feature_columns)
predictions = self._kmeans.predict(XTest)
predictions = container.DataFrame(predictions, generate_metadata=True)
if (len(label_name_columns) != 0):
for col in range(predictions.shape[1]):
col_dict = dict(predictions.metadata.query((metadata_base.ALL_ELEMENTS, col)))
col_dict['structural_type'] = type(1.0)
col_dict['name'] = label_name_columns[col]
col_dict['semantic_types'] = ('http://schema.org/Float', 'https://metadata.datadrivendiscovery.org/types/PredictedTarget')
predictions.metadata = predictions.metadata.update((metadata_base.ALL_ELEMENTS, col), col_dict)
predictions.columns = label_name_columns
else:
for col in range(predictions.shape[1]):
col_dict = dict(predictions.metadata.query((metadata_base.ALL_ELEMENTS, col)))
col_dict['structural_type'] = type(1.0)
col_dict['name'] = 'KMeansPredictions'
col_dict['semantic_types'] = ('http://schema.org/Float', 'https://metadata.datadrivendiscovery.org/types/PredictedTarget')
predictions.metadata = predictions.metadata.update((metadata_base.ALL_ELEMENTS, col), col_dict)
outputs = outputs.append_columns(predictions)
return base.CallResult(outputs)<|docstring|>Inputs: DataFrame of features or numerical inputs
Returns: Pandas DataFrame Containing predictions<|endoftext|> |
cfe9ca25fcc678f8be315b3c66227b142aa499da435fedfcba4a76bdfa80b866 | def __init__(__self__, *, service_account_id: pulumi.Input[str], keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None):
'\n The set of arguments for constructing a Key resource.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n '
pulumi.set(__self__, 'service_account_id', service_account_id)
if (keepers is not None):
pulumi.set(__self__, 'keepers', keepers)
if (key_algorithm is not None):
pulumi.set(__self__, 'key_algorithm', key_algorithm)
if (private_key_type is not None):
pulumi.set(__self__, 'private_key_type', private_key_type)
if (public_key_data is not None):
pulumi.set(__self__, 'public_key_data', public_key_data)
if (public_key_type is not None):
pulumi.set(__self__, 'public_key_type', public_key_type) | The set of arguments for constructing a Key resource.
:param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.
:param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.
:param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)
:param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.
:param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.
:param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format. | sdk/python/pulumi_gcp/serviceaccount/key.py | __init__ | la3mmchen/pulumi-gcp | 121 | python | def __init__(__self__, *, service_account_id: pulumi.Input[str], keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None):
'\n The set of arguments for constructing a Key resource.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n '
pulumi.set(__self__, 'service_account_id', service_account_id)
if (keepers is not None):
pulumi.set(__self__, 'keepers', keepers)
if (key_algorithm is not None):
pulumi.set(__self__, 'key_algorithm', key_algorithm)
if (private_key_type is not None):
pulumi.set(__self__, 'private_key_type', private_key_type)
if (public_key_data is not None):
pulumi.set(__self__, 'public_key_data', public_key_data)
if (public_key_type is not None):
pulumi.set(__self__, 'public_key_type', public_key_type) | def __init__(__self__, *, service_account_id: pulumi.Input[str], keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None):
'\n The set of arguments for constructing a Key resource.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n '
pulumi.set(__self__, 'service_account_id', service_account_id)
if (keepers is not None):
pulumi.set(__self__, 'keepers', keepers)
if (key_algorithm is not None):
pulumi.set(__self__, 'key_algorithm', key_algorithm)
if (private_key_type is not None):
pulumi.set(__self__, 'private_key_type', private_key_type)
if (public_key_data is not None):
pulumi.set(__self__, 'public_key_data', public_key_data)
if (public_key_type is not None):
pulumi.set(__self__, 'public_key_type', public_key_type)<|docstring|>The set of arguments for constructing a Key resource.
:param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.
:param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.
:param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)
:param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.
:param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.
:param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.<|endoftext|> |
bff66f85abd1af66e294f784cce63a4094869814722f5d8b973f0d8725931b3c | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> pulumi.Input[str]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id') | The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account. | sdk/python/pulumi_gcp/serviceaccount/key.py | service_account_id | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> pulumi.Input[str]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id') | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> pulumi.Input[str]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id')<|docstring|>The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.<|endoftext|> |
ab54c64bf5861641e3c34dbcf4e92cae44aa801bf23e5dd59736d5379793f523 | @property
@pulumi.getter
def keepers(self) -> Optional[pulumi.Input[Mapping[(str, Any)]]]:
'\n Arbitrary map of values that, when changed, will trigger a new key to be generated.\n '
return pulumi.get(self, 'keepers') | Arbitrary map of values that, when changed, will trigger a new key to be generated. | sdk/python/pulumi_gcp/serviceaccount/key.py | keepers | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter
def keepers(self) -> Optional[pulumi.Input[Mapping[(str, Any)]]]:
'\n \n '
return pulumi.get(self, 'keepers') | @property
@pulumi.getter
def keepers(self) -> Optional[pulumi.Input[Mapping[(str, Any)]]]:
'\n \n '
return pulumi.get(self, 'keepers')<|docstring|>Arbitrary map of values that, when changed, will trigger a new key to be generated.<|endoftext|> |
8e3fa6033304057e7a0b0bdaf1c3f3ad16c74d481aeae952ea59c08d3d71837e | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> Optional[pulumi.Input[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm') | The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create) | sdk/python/pulumi_gcp/serviceaccount/key.py | key_algorithm | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> Optional[pulumi.Input[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm') | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> Optional[pulumi.Input[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm')<|docstring|>The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)<|endoftext|> |
ff1b98948cd88260b1be5dcae7c24f4c9ab89e101beda0895d9aeb3e10494902 | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> Optional[pulumi.Input[str]]:
'\n The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n '
return pulumi.get(self, 'private_key_type') | The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format. | sdk/python/pulumi_gcp/serviceaccount/key.py | private_key_type | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'private_key_type') | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'private_key_type')<|docstring|>The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.<|endoftext|> |
c60dc428410d6cf8aa64a95f807bb7e8086ecab93377e0cfe28dceff6c7e47ab | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> Optional[pulumi.Input[str]]:
'\n Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n '
return pulumi.get(self, 'public_key_data') | Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`. | sdk/python/pulumi_gcp/serviceaccount/key.py | public_key_data | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key_data') | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key_data')<|docstring|>Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.<|endoftext|> |
b8c0de7f73ecc6859e034acfbbde6b0d6e57293f1ca288f60225790151b46ecd | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> Optional[pulumi.Input[str]]:
'\n The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n '
return pulumi.get(self, 'public_key_type') | The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format. | sdk/python/pulumi_gcp/serviceaccount/key.py | public_key_type | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key_type') | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key_type')<|docstring|>The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.<|endoftext|> |
ef6586147916ef9de0d160776fc0c972e3cce9185a806094933d5d8c803780a3 | def __init__(__self__, *, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, name: Optional[pulumi.Input[str]]=None, private_key: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, valid_after: Optional[pulumi.Input[str]]=None, valid_before: Optional[pulumi.Input[str]]=None):
'\n Input properties used for looking up and filtering Key resources.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] name: The name used for this key pair\n :param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key: The public key, base64 encoded\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n :param pulumi.Input[str] valid_before: The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
if (keepers is not None):
pulumi.set(__self__, 'keepers', keepers)
if (key_algorithm is not None):
pulumi.set(__self__, 'key_algorithm', key_algorithm)
if (name is not None):
pulumi.set(__self__, 'name', name)
if (private_key is not None):
pulumi.set(__self__, 'private_key', private_key)
if (private_key_type is not None):
pulumi.set(__self__, 'private_key_type', private_key_type)
if (public_key is not None):
pulumi.set(__self__, 'public_key', public_key)
if (public_key_data is not None):
pulumi.set(__self__, 'public_key_data', public_key_data)
if (public_key_type is not None):
pulumi.set(__self__, 'public_key_type', public_key_type)
if (service_account_id is not None):
pulumi.set(__self__, 'service_account_id', service_account_id)
if (valid_after is not None):
pulumi.set(__self__, 'valid_after', valid_after)
if (valid_before is not None):
pulumi.set(__self__, 'valid_before', valid_before) | Input properties used for looking up and filtering Key resources.
:param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.
:param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)
:param pulumi.Input[str] name: The name used for this key pair
:param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating
service account keys through the CLI or web console. This is only populated when creating a new key.
:param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.
:param pulumi.Input[str] public_key: The public key, base64 encoded
:param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.
:param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.
:param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.
:param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".
:param pulumi.Input[str] valid_before: The key can be used before this timestamp.
A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z". | sdk/python/pulumi_gcp/serviceaccount/key.py | __init__ | la3mmchen/pulumi-gcp | 121 | python | def __init__(__self__, *, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, name: Optional[pulumi.Input[str]]=None, private_key: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, valid_after: Optional[pulumi.Input[str]]=None, valid_before: Optional[pulumi.Input[str]]=None):
'\n Input properties used for looking up and filtering Key resources.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] name: The name used for this key pair\n :param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key: The public key, base64 encoded\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n :param pulumi.Input[str] valid_before: The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
if (keepers is not None):
pulumi.set(__self__, 'keepers', keepers)
if (key_algorithm is not None):
pulumi.set(__self__, 'key_algorithm', key_algorithm)
if (name is not None):
pulumi.set(__self__, 'name', name)
if (private_key is not None):
pulumi.set(__self__, 'private_key', private_key)
if (private_key_type is not None):
pulumi.set(__self__, 'private_key_type', private_key_type)
if (public_key is not None):
pulumi.set(__self__, 'public_key', public_key)
if (public_key_data is not None):
pulumi.set(__self__, 'public_key_data', public_key_data)
if (public_key_type is not None):
pulumi.set(__self__, 'public_key_type', public_key_type)
if (service_account_id is not None):
pulumi.set(__self__, 'service_account_id', service_account_id)
if (valid_after is not None):
pulumi.set(__self__, 'valid_after', valid_after)
if (valid_before is not None):
pulumi.set(__self__, 'valid_before', valid_before) | def __init__(__self__, *, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, name: Optional[pulumi.Input[str]]=None, private_key: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, valid_after: Optional[pulumi.Input[str]]=None, valid_before: Optional[pulumi.Input[str]]=None):
'\n Input properties used for looking up and filtering Key resources.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] name: The name used for this key pair\n :param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key: The public key, base64 encoded\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n :param pulumi.Input[str] valid_before: The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
if (keepers is not None):
pulumi.set(__self__, 'keepers', keepers)
if (key_algorithm is not None):
pulumi.set(__self__, 'key_algorithm', key_algorithm)
if (name is not None):
pulumi.set(__self__, 'name', name)
if (private_key is not None):
pulumi.set(__self__, 'private_key', private_key)
if (private_key_type is not None):
pulumi.set(__self__, 'private_key_type', private_key_type)
if (public_key is not None):
pulumi.set(__self__, 'public_key', public_key)
if (public_key_data is not None):
pulumi.set(__self__, 'public_key_data', public_key_data)
if (public_key_type is not None):
pulumi.set(__self__, 'public_key_type', public_key_type)
if (service_account_id is not None):
pulumi.set(__self__, 'service_account_id', service_account_id)
if (valid_after is not None):
pulumi.set(__self__, 'valid_after', valid_after)
if (valid_before is not None):
pulumi.set(__self__, 'valid_before', valid_before)<|docstring|>Input properties used for looking up and filtering Key resources.
:param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.
:param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)
:param pulumi.Input[str] name: The name used for this key pair
:param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating
service account keys through the CLI or web console. This is only populated when creating a new key.
:param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.
:param pulumi.Input[str] public_key: The public key, base64 encoded
:param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.
:param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.
:param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.
:param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".
:param pulumi.Input[str] valid_before: The key can be used before this timestamp.
A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".<|endoftext|> |
ab54c64bf5861641e3c34dbcf4e92cae44aa801bf23e5dd59736d5379793f523 | @property
@pulumi.getter
def keepers(self) -> Optional[pulumi.Input[Mapping[(str, Any)]]]:
'\n Arbitrary map of values that, when changed, will trigger a new key to be generated.\n '
return pulumi.get(self, 'keepers') | Arbitrary map of values that, when changed, will trigger a new key to be generated. | sdk/python/pulumi_gcp/serviceaccount/key.py | keepers | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter
def keepers(self) -> Optional[pulumi.Input[Mapping[(str, Any)]]]:
'\n \n '
return pulumi.get(self, 'keepers') | @property
@pulumi.getter
def keepers(self) -> Optional[pulumi.Input[Mapping[(str, Any)]]]:
'\n \n '
return pulumi.get(self, 'keepers')<|docstring|>Arbitrary map of values that, when changed, will trigger a new key to be generated.<|endoftext|> |
8e3fa6033304057e7a0b0bdaf1c3f3ad16c74d481aeae952ea59c08d3d71837e | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> Optional[pulumi.Input[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm') | The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create) | sdk/python/pulumi_gcp/serviceaccount/key.py | key_algorithm | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> Optional[pulumi.Input[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm') | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> Optional[pulumi.Input[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm')<|docstring|>The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)<|endoftext|> |
4caed200cca866665caafd178ea359b520ed34060faf88bb74b1fcd84bab32b9 | @property
@pulumi.getter
def name(self) -> Optional[pulumi.Input[str]]:
'\n The name used for this key pair\n '
return pulumi.get(self, 'name') | The name used for this key pair | sdk/python/pulumi_gcp/serviceaccount/key.py | name | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter
def name(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'name') | @property
@pulumi.getter
def name(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'name')<|docstring|>The name used for this key pair<|endoftext|> |
e18b2ac411d273aed5a103024f992df849ac4ac445fd4246ee0a1faf2d16d4b8 | @property
@pulumi.getter(name='privateKey')
def private_key(self) -> Optional[pulumi.Input[str]]:
'\n The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n '
return pulumi.get(self, 'private_key') | The private key in JSON format, base64 encoded. This is what you normally get as a file when creating
service account keys through the CLI or web console. This is only populated when creating a new key. | sdk/python/pulumi_gcp/serviceaccount/key.py | private_key | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='privateKey')
def private_key(self) -> Optional[pulumi.Input[str]]:
'\n The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n '
return pulumi.get(self, 'private_key') | @property
@pulumi.getter(name='privateKey')
def private_key(self) -> Optional[pulumi.Input[str]]:
'\n The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n '
return pulumi.get(self, 'private_key')<|docstring|>The private key in JSON format, base64 encoded. This is what you normally get as a file when creating
service account keys through the CLI or web console. This is only populated when creating a new key.<|endoftext|> |
ff1b98948cd88260b1be5dcae7c24f4c9ab89e101beda0895d9aeb3e10494902 | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> Optional[pulumi.Input[str]]:
'\n The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n '
return pulumi.get(self, 'private_key_type') | The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format. | sdk/python/pulumi_gcp/serviceaccount/key.py | private_key_type | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'private_key_type') | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'private_key_type')<|docstring|>The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.<|endoftext|> |
6dad62bb0c223bb6336b8bf299e4604d10e537dd7969b4c8182355f54d3908ed | @property
@pulumi.getter(name='publicKey')
def public_key(self) -> Optional[pulumi.Input[str]]:
'\n The public key, base64 encoded\n '
return pulumi.get(self, 'public_key') | The public key, base64 encoded | sdk/python/pulumi_gcp/serviceaccount/key.py | public_key | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='publicKey')
def public_key(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key') | @property
@pulumi.getter(name='publicKey')
def public_key(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key')<|docstring|>The public key, base64 encoded<|endoftext|> |
c60dc428410d6cf8aa64a95f807bb7e8086ecab93377e0cfe28dceff6c7e47ab | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> Optional[pulumi.Input[str]]:
'\n Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n '
return pulumi.get(self, 'public_key_data') | Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`. | sdk/python/pulumi_gcp/serviceaccount/key.py | public_key_data | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key_data') | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key_data')<|docstring|>Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.<|endoftext|> |
b8c0de7f73ecc6859e034acfbbde6b0d6e57293f1ca288f60225790151b46ecd | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> Optional[pulumi.Input[str]]:
'\n The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n '
return pulumi.get(self, 'public_key_type') | The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format. | sdk/python/pulumi_gcp/serviceaccount/key.py | public_key_type | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key_type') | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'public_key_type')<|docstring|>The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.<|endoftext|> |
f7d151184b4bf716c0a6d7f621925ae0052a70acbd6fb1497b9b2f5bd32d86d1 | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> Optional[pulumi.Input[str]]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id') | The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account. | sdk/python/pulumi_gcp/serviceaccount/key.py | service_account_id | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> Optional[pulumi.Input[str]]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id') | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> Optional[pulumi.Input[str]]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id')<|docstring|>The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.<|endoftext|> |
82ff7ee2cda20bacba3215a86b054fa42131d3de109f32377efe49f2425856cf | @property
@pulumi.getter(name='validAfter')
def valid_after(self) -> Optional[pulumi.Input[str]]:
'\n The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
return pulumi.get(self, 'valid_after') | The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z". | sdk/python/pulumi_gcp/serviceaccount/key.py | valid_after | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='validAfter')
def valid_after(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'valid_after') | @property
@pulumi.getter(name='validAfter')
def valid_after(self) -> Optional[pulumi.Input[str]]:
'\n \n '
return pulumi.get(self, 'valid_after')<|docstring|>The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".<|endoftext|> |
be332bec80f8a886c1bfa86e680a773669e677c2f2ce8354cafb4ba8d9bf43c4 | @property
@pulumi.getter(name='validBefore')
def valid_before(self) -> Optional[pulumi.Input[str]]:
'\n The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
return pulumi.get(self, 'valid_before') | The key can be used before this timestamp.
A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z". | sdk/python/pulumi_gcp/serviceaccount/key.py | valid_before | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='validBefore')
def valid_before(self) -> Optional[pulumi.Input[str]]:
'\n The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
return pulumi.get(self, 'valid_before') | @property
@pulumi.getter(name='validBefore')
def valid_before(self) -> Optional[pulumi.Input[str]]:
'\n The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
return pulumi.get(self, 'valid_before')<|docstring|>The key can be used before this timestamp.
A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".<|endoftext|> |
4cf0cc9ed18388aba658e81a0b0ecd7c177e0f5ef7b0d3d55237a92b706cfca1 | @overload
def __init__(__self__, resource_name: str, opts: Optional[pulumi.ResourceOptions]=None, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, __props__=None):
'\n Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.\n\n * [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)\n * How-to Guides\n * [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)\n\n ## Example Usage\n ### Creating A New Key\n\n ```python\n import pulumi\n import pulumi_gcp as gcp\n\n myaccount = gcp.service_account.Account("myaccount",\n account_id="myaccount",\n display_name="My Service Account")\n mykey = gcp.service_account.Key("mykey",\n service_account_id=myaccount.name,\n public_key_type="TYPE_X509_PEM_FILE")\n ```\n\n ## Import\n\n This resource does not support import.\n\n :param str resource_name: The name of the resource.\n :param pulumi.ResourceOptions opts: Options for the resource.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
... | Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.
* [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)
* How-to Guides
* [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)
## Example Usage
### Creating A New Key
```python
import pulumi
import pulumi_gcp as gcp
myaccount = gcp.service_account.Account("myaccount",
account_id="myaccount",
display_name="My Service Account")
mykey = gcp.service_account.Key("mykey",
service_account_id=myaccount.name,
public_key_type="TYPE_X509_PEM_FILE")
```
## Import
This resource does not support import.
:param str resource_name: The name of the resource.
:param pulumi.ResourceOptions opts: Options for the resource.
:param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.
:param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)
:param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.
:param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.
:param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.
:param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account. | sdk/python/pulumi_gcp/serviceaccount/key.py | __init__ | la3mmchen/pulumi-gcp | 121 | python | @overload
def __init__(__self__, resource_name: str, opts: Optional[pulumi.ResourceOptions]=None, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, __props__=None):
'\n Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.\n\n * [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)\n * How-to Guides\n * [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)\n\n ## Example Usage\n ### Creating A New Key\n\n ```python\n import pulumi\n import pulumi_gcp as gcp\n\n myaccount = gcp.service_account.Account("myaccount",\n account_id="myaccount",\n display_name="My Service Account")\n mykey = gcp.service_account.Key("mykey",\n service_account_id=myaccount.name,\n public_key_type="TYPE_X509_PEM_FILE")\n ```\n\n ## Import\n\n This resource does not support import.\n\n :param str resource_name: The name of the resource.\n :param pulumi.ResourceOptions opts: Options for the resource.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
... | @overload
def __init__(__self__, resource_name: str, opts: Optional[pulumi.ResourceOptions]=None, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, __props__=None):
'\n Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.\n\n * [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)\n * How-to Guides\n * [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)\n\n ## Example Usage\n ### Creating A New Key\n\n ```python\n import pulumi\n import pulumi_gcp as gcp\n\n myaccount = gcp.service_account.Account("myaccount",\n account_id="myaccount",\n display_name="My Service Account")\n mykey = gcp.service_account.Key("mykey",\n service_account_id=myaccount.name,\n public_key_type="TYPE_X509_PEM_FILE")\n ```\n\n ## Import\n\n This resource does not support import.\n\n :param str resource_name: The name of the resource.\n :param pulumi.ResourceOptions opts: Options for the resource.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
...<|docstring|>Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.
* [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)
* How-to Guides
* [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)
## Example Usage
### Creating A New Key
```python
import pulumi
import pulumi_gcp as gcp
myaccount = gcp.service_account.Account("myaccount",
account_id="myaccount",
display_name="My Service Account")
mykey = gcp.service_account.Key("mykey",
service_account_id=myaccount.name,
public_key_type="TYPE_X509_PEM_FILE")
```
## Import
This resource does not support import.
:param str resource_name: The name of the resource.
:param pulumi.ResourceOptions opts: Options for the resource.
:param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.
:param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)
:param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.
:param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.
:param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.
:param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.<|endoftext|> |
3274fd4aa4d3b9975c92327887a3656591b332df3b13fa861630289e212d7955 | @overload
def __init__(__self__, resource_name: str, args: KeyArgs, opts: Optional[pulumi.ResourceOptions]=None):
'\n Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.\n\n * [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)\n * How-to Guides\n * [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)\n\n ## Example Usage\n ### Creating A New Key\n\n ```python\n import pulumi\n import pulumi_gcp as gcp\n\n myaccount = gcp.service_account.Account("myaccount",\n account_id="myaccount",\n display_name="My Service Account")\n mykey = gcp.service_account.Key("mykey",\n service_account_id=myaccount.name,\n public_key_type="TYPE_X509_PEM_FILE")\n ```\n\n ## Import\n\n This resource does not support import.\n\n :param str resource_name: The name of the resource.\n :param KeyArgs args: The arguments to use to populate this resource\'s properties.\n :param pulumi.ResourceOptions opts: Options for the resource.\n '
... | Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.
* [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)
* How-to Guides
* [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)
## Example Usage
### Creating A New Key
```python
import pulumi
import pulumi_gcp as gcp
myaccount = gcp.service_account.Account("myaccount",
account_id="myaccount",
display_name="My Service Account")
mykey = gcp.service_account.Key("mykey",
service_account_id=myaccount.name,
public_key_type="TYPE_X509_PEM_FILE")
```
## Import
This resource does not support import.
:param str resource_name: The name of the resource.
:param KeyArgs args: The arguments to use to populate this resource's properties.
:param pulumi.ResourceOptions opts: Options for the resource. | sdk/python/pulumi_gcp/serviceaccount/key.py | __init__ | la3mmchen/pulumi-gcp | 121 | python | @overload
def __init__(__self__, resource_name: str, args: KeyArgs, opts: Optional[pulumi.ResourceOptions]=None):
'\n Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.\n\n * [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)\n * How-to Guides\n * [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)\n\n ## Example Usage\n ### Creating A New Key\n\n ```python\n import pulumi\n import pulumi_gcp as gcp\n\n myaccount = gcp.service_account.Account("myaccount",\n account_id="myaccount",\n display_name="My Service Account")\n mykey = gcp.service_account.Key("mykey",\n service_account_id=myaccount.name,\n public_key_type="TYPE_X509_PEM_FILE")\n ```\n\n ## Import\n\n This resource does not support import.\n\n :param str resource_name: The name of the resource.\n :param KeyArgs args: The arguments to use to populate this resource\'s properties.\n :param pulumi.ResourceOptions opts: Options for the resource.\n '
... | @overload
def __init__(__self__, resource_name: str, args: KeyArgs, opts: Optional[pulumi.ResourceOptions]=None):
'\n Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.\n\n * [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)\n * How-to Guides\n * [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)\n\n ## Example Usage\n ### Creating A New Key\n\n ```python\n import pulumi\n import pulumi_gcp as gcp\n\n myaccount = gcp.service_account.Account("myaccount",\n account_id="myaccount",\n display_name="My Service Account")\n mykey = gcp.service_account.Key("mykey",\n service_account_id=myaccount.name,\n public_key_type="TYPE_X509_PEM_FILE")\n ```\n\n ## Import\n\n This resource does not support import.\n\n :param str resource_name: The name of the resource.\n :param KeyArgs args: The arguments to use to populate this resource\'s properties.\n :param pulumi.ResourceOptions opts: Options for the resource.\n '
...<|docstring|>Creates and manages service account keys, which allow the use of a service account outside of Google Cloud.
* [API documentation](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys)
* How-to Guides
* [Official Documentation](https://cloud.google.com/iam/docs/creating-managing-service-account-keys)
## Example Usage
### Creating A New Key
```python
import pulumi
import pulumi_gcp as gcp
myaccount = gcp.service_account.Account("myaccount",
account_id="myaccount",
display_name="My Service Account")
mykey = gcp.service_account.Key("mykey",
service_account_id=myaccount.name,
public_key_type="TYPE_X509_PEM_FILE")
```
## Import
This resource does not support import.
:param str resource_name: The name of the resource.
:param KeyArgs args: The arguments to use to populate this resource's properties.
:param pulumi.ResourceOptions opts: Options for the resource.<|endoftext|> |
72d70166a2e25fc241d6d890690d84a5d34656f2231b8f0e3c003a1bee3d7ed5 | @staticmethod
def get(resource_name: str, id: pulumi.Input[str], opts: Optional[pulumi.ResourceOptions]=None, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, name: Optional[pulumi.Input[str]]=None, private_key: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, valid_after: Optional[pulumi.Input[str]]=None, valid_before: Optional[pulumi.Input[str]]=None) -> 'Key':
'\n Get an existing Key resource\'s state with the given name, id, and optional extra\n properties used to qualify the lookup.\n\n :param str resource_name: The unique name of the resulting resource.\n :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.\n :param pulumi.ResourceOptions opts: Options for the resource.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] name: The name used for this key pair\n :param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key: The public key, base64 encoded\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n :param pulumi.Input[str] valid_before: The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
__props__ = _KeyState.__new__(_KeyState)
__props__.__dict__['keepers'] = keepers
__props__.__dict__['key_algorithm'] = key_algorithm
__props__.__dict__['name'] = name
__props__.__dict__['private_key'] = private_key
__props__.__dict__['private_key_type'] = private_key_type
__props__.__dict__['public_key'] = public_key
__props__.__dict__['public_key_data'] = public_key_data
__props__.__dict__['public_key_type'] = public_key_type
__props__.__dict__['service_account_id'] = service_account_id
__props__.__dict__['valid_after'] = valid_after
__props__.__dict__['valid_before'] = valid_before
return Key(resource_name, opts=opts, __props__=__props__) | Get an existing Key resource's state with the given name, id, and optional extra
properties used to qualify the lookup.
:param str resource_name: The unique name of the resulting resource.
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
:param pulumi.ResourceOptions opts: Options for the resource.
:param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.
:param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)
:param pulumi.Input[str] name: The name used for this key pair
:param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating
service account keys through the CLI or web console. This is only populated when creating a new key.
:param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.
:param pulumi.Input[str] public_key: The public key, base64 encoded
:param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.
:param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.
:param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.
:param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".
:param pulumi.Input[str] valid_before: The key can be used before this timestamp.
A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z". | sdk/python/pulumi_gcp/serviceaccount/key.py | get | la3mmchen/pulumi-gcp | 121 | python | @staticmethod
def get(resource_name: str, id: pulumi.Input[str], opts: Optional[pulumi.ResourceOptions]=None, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, name: Optional[pulumi.Input[str]]=None, private_key: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, valid_after: Optional[pulumi.Input[str]]=None, valid_before: Optional[pulumi.Input[str]]=None) -> 'Key':
'\n Get an existing Key resource\'s state with the given name, id, and optional extra\n properties used to qualify the lookup.\n\n :param str resource_name: The unique name of the resulting resource.\n :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.\n :param pulumi.ResourceOptions opts: Options for the resource.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] name: The name used for this key pair\n :param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key: The public key, base64 encoded\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n :param pulumi.Input[str] valid_before: The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
__props__ = _KeyState.__new__(_KeyState)
__props__.__dict__['keepers'] = keepers
__props__.__dict__['key_algorithm'] = key_algorithm
__props__.__dict__['name'] = name
__props__.__dict__['private_key'] = private_key
__props__.__dict__['private_key_type'] = private_key_type
__props__.__dict__['public_key'] = public_key
__props__.__dict__['public_key_data'] = public_key_data
__props__.__dict__['public_key_type'] = public_key_type
__props__.__dict__['service_account_id'] = service_account_id
__props__.__dict__['valid_after'] = valid_after
__props__.__dict__['valid_before'] = valid_before
return Key(resource_name, opts=opts, __props__=__props__) | @staticmethod
def get(resource_name: str, id: pulumi.Input[str], opts: Optional[pulumi.ResourceOptions]=None, keepers: Optional[pulumi.Input[Mapping[(str, Any)]]]=None, key_algorithm: Optional[pulumi.Input[str]]=None, name: Optional[pulumi.Input[str]]=None, private_key: Optional[pulumi.Input[str]]=None, private_key_type: Optional[pulumi.Input[str]]=None, public_key: Optional[pulumi.Input[str]]=None, public_key_data: Optional[pulumi.Input[str]]=None, public_key_type: Optional[pulumi.Input[str]]=None, service_account_id: Optional[pulumi.Input[str]]=None, valid_after: Optional[pulumi.Input[str]]=None, valid_before: Optional[pulumi.Input[str]]=None) -> 'Key':
'\n Get an existing Key resource\'s state with the given name, id, and optional extra\n properties used to qualify the lookup.\n\n :param str resource_name: The unique name of the resulting resource.\n :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.\n :param pulumi.ResourceOptions opts: Options for the resource.\n :param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.\n :param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n :param pulumi.Input[str] name: The name used for this key pair\n :param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n :param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n :param pulumi.Input[str] public_key: The public key, base64 encoded\n :param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n :param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n :param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n :param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n :param pulumi.Input[str] valid_before: The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
__props__ = _KeyState.__new__(_KeyState)
__props__.__dict__['keepers'] = keepers
__props__.__dict__['key_algorithm'] = key_algorithm
__props__.__dict__['name'] = name
__props__.__dict__['private_key'] = private_key
__props__.__dict__['private_key_type'] = private_key_type
__props__.__dict__['public_key'] = public_key
__props__.__dict__['public_key_data'] = public_key_data
__props__.__dict__['public_key_type'] = public_key_type
__props__.__dict__['service_account_id'] = service_account_id
__props__.__dict__['valid_after'] = valid_after
__props__.__dict__['valid_before'] = valid_before
return Key(resource_name, opts=opts, __props__=__props__)<|docstring|>Get an existing Key resource's state with the given name, id, and optional extra
properties used to qualify the lookup.
:param str resource_name: The unique name of the resulting resource.
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
:param pulumi.ResourceOptions opts: Options for the resource.
:param pulumi.Input[Mapping[str, Any]] keepers: Arbitrary map of values that, when changed, will trigger a new key to be generated.
:param pulumi.Input[str] key_algorithm: The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)
:param pulumi.Input[str] name: The name used for this key pair
:param pulumi.Input[str] private_key: The private key in JSON format, base64 encoded. This is what you normally get as a file when creating
service account keys through the CLI or web console. This is only populated when creating a new key.
:param pulumi.Input[str] private_key_type: The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.
:param pulumi.Input[str] public_key: The public key, base64 encoded
:param pulumi.Input[str] public_key_data: Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.
:param pulumi.Input[str] public_key_type: The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.
:param pulumi.Input[str] service_account_id: The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.
:param pulumi.Input[str] valid_after: The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".
:param pulumi.Input[str] valid_before: The key can be used before this timestamp.
A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".<|endoftext|> |
2835be7efdadbe4b28c07422f04bacc14777675af04e147ce4ac31ebca89ddb8 | @property
@pulumi.getter
def keepers(self) -> pulumi.Output[Optional[Mapping[(str, Any)]]]:
'\n Arbitrary map of values that, when changed, will trigger a new key to be generated.\n '
return pulumi.get(self, 'keepers') | Arbitrary map of values that, when changed, will trigger a new key to be generated. | sdk/python/pulumi_gcp/serviceaccount/key.py | keepers | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter
def keepers(self) -> pulumi.Output[Optional[Mapping[(str, Any)]]]:
'\n \n '
return pulumi.get(self, 'keepers') | @property
@pulumi.getter
def keepers(self) -> pulumi.Output[Optional[Mapping[(str, Any)]]]:
'\n \n '
return pulumi.get(self, 'keepers')<|docstring|>Arbitrary map of values that, when changed, will trigger a new key to be generated.<|endoftext|> |
f56f1a1d9904efd8c803014911b8f4256d7619aa848bea16873c8ab6268bf32c | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> pulumi.Output[Optional[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm') | The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create) | sdk/python/pulumi_gcp/serviceaccount/key.py | key_algorithm | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> pulumi.Output[Optional[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm') | @property
@pulumi.getter(name='keyAlgorithm')
def key_algorithm(self) -> pulumi.Output[Optional[str]]:
'\n The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.\n Valid values are listed at\n [ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)\n (only used on create)\n '
return pulumi.get(self, 'key_algorithm')<|docstring|>The algorithm used to generate the key. KEY_ALG_RSA_2048 is the default algorithm.
Valid values are listed at
[ServiceAccountPrivateKeyType](https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts.keys#ServiceAccountKeyAlgorithm)
(only used on create)<|endoftext|> |
1b798614bf0cc8dfe1c365e50f88779c1b7cea830ddb88126f0d0b20b743e1f4 | @property
@pulumi.getter
def name(self) -> pulumi.Output[str]:
'\n The name used for this key pair\n '
return pulumi.get(self, 'name') | The name used for this key pair | sdk/python/pulumi_gcp/serviceaccount/key.py | name | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter
def name(self) -> pulumi.Output[str]:
'\n \n '
return pulumi.get(self, 'name') | @property
@pulumi.getter
def name(self) -> pulumi.Output[str]:
'\n \n '
return pulumi.get(self, 'name')<|docstring|>The name used for this key pair<|endoftext|> |
04c79921e2936ecd25f48744cf4b02bee4c891376e549d2fa729ee3486101f63 | @property
@pulumi.getter(name='privateKey')
def private_key(self) -> pulumi.Output[str]:
'\n The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n '
return pulumi.get(self, 'private_key') | The private key in JSON format, base64 encoded. This is what you normally get as a file when creating
service account keys through the CLI or web console. This is only populated when creating a new key. | sdk/python/pulumi_gcp/serviceaccount/key.py | private_key | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='privateKey')
def private_key(self) -> pulumi.Output[str]:
'\n The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n '
return pulumi.get(self, 'private_key') | @property
@pulumi.getter(name='privateKey')
def private_key(self) -> pulumi.Output[str]:
'\n The private key in JSON format, base64 encoded. This is what you normally get as a file when creating\n service account keys through the CLI or web console. This is only populated when creating a new key.\n '
return pulumi.get(self, 'private_key')<|docstring|>The private key in JSON format, base64 encoded. This is what you normally get as a file when creating
service account keys through the CLI or web console. This is only populated when creating a new key.<|endoftext|> |
dc32e44aa9d94072989686e6fe19b8f8b6e4b3f493508e52cdb889fdbdf86206 | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> pulumi.Output[Optional[str]]:
'\n The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.\n '
return pulumi.get(self, 'private_key_type') | The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format. | sdk/python/pulumi_gcp/serviceaccount/key.py | private_key_type | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> pulumi.Output[Optional[str]]:
'\n \n '
return pulumi.get(self, 'private_key_type') | @property
@pulumi.getter(name='privateKeyType')
def private_key_type(self) -> pulumi.Output[Optional[str]]:
'\n \n '
return pulumi.get(self, 'private_key_type')<|docstring|>The output format of the private key. TYPE_GOOGLE_CREDENTIALS_FILE is the default output format.<|endoftext|> |
b53d8754f93456d67d5b7c5ec317c7e9ed1bf57c603c3cfa2ec2e23ba8ee63ed | @property
@pulumi.getter(name='publicKey')
def public_key(self) -> pulumi.Output[str]:
'\n The public key, base64 encoded\n '
return pulumi.get(self, 'public_key') | The public key, base64 encoded | sdk/python/pulumi_gcp/serviceaccount/key.py | public_key | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='publicKey')
def public_key(self) -> pulumi.Output[str]:
'\n \n '
return pulumi.get(self, 'public_key') | @property
@pulumi.getter(name='publicKey')
def public_key(self) -> pulumi.Output[str]:
'\n \n '
return pulumi.get(self, 'public_key')<|docstring|>The public key, base64 encoded<|endoftext|> |
5162e6ae6900881e41222c8f87e473b30d5bee25dede02e6accdd02546173b04 | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> pulumi.Output[Optional[str]]:
'\n Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.\n '
return pulumi.get(self, 'public_key_data') | Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`. | sdk/python/pulumi_gcp/serviceaccount/key.py | public_key_data | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> pulumi.Output[Optional[str]]:
'\n \n '
return pulumi.get(self, 'public_key_data') | @property
@pulumi.getter(name='publicKeyData')
def public_key_data(self) -> pulumi.Output[Optional[str]]:
'\n \n '
return pulumi.get(self, 'public_key_data')<|docstring|>Public key data to create a service account key for given service account. The expected format for this field is a base64 encoded X509_PEM and it conflicts with `public_key_type` and `private_key_type`.<|endoftext|> |
77742147202af3e01b0b1556d856b69872b0a2b1b945e19059e6d94b65f55b7d | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> pulumi.Output[Optional[str]]:
'\n The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.\n '
return pulumi.get(self, 'public_key_type') | The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format. | sdk/python/pulumi_gcp/serviceaccount/key.py | public_key_type | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> pulumi.Output[Optional[str]]:
'\n \n '
return pulumi.get(self, 'public_key_type') | @property
@pulumi.getter(name='publicKeyType')
def public_key_type(self) -> pulumi.Output[Optional[str]]:
'\n \n '
return pulumi.get(self, 'public_key_type')<|docstring|>The output format of the public key requested. TYPE_X509_PEM_FILE is the default output format.<|endoftext|> |
32e2446cbea61a18db50205caed8ba69675ca48860359f38c838ac20ecffd72a | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> pulumi.Output[str]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id') | The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account. | sdk/python/pulumi_gcp/serviceaccount/key.py | service_account_id | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> pulumi.Output[str]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id') | @property
@pulumi.getter(name='serviceAccountId')
def service_account_id(self) -> pulumi.Output[str]:
'\n The Service account id of the Key. This can be a string in the format\n `{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or\n unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.\n '
return pulumi.get(self, 'service_account_id')<|docstring|>The Service account id of the Key. This can be a string in the format
`{ACCOUNT}` or `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`, where `{ACCOUNT}` is the email address or
unique id of the service account. If the `{ACCOUNT}` syntax is used, the project will be inferred from the account.<|endoftext|> |
6f929db190b4b92862d2b929803721001056c00672246bddca96712125357cde | @property
@pulumi.getter(name='validAfter')
def valid_after(self) -> pulumi.Output[str]:
'\n The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
return pulumi.get(self, 'valid_after') | The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z". | sdk/python/pulumi_gcp/serviceaccount/key.py | valid_after | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='validAfter')
def valid_after(self) -> pulumi.Output[str]:
'\n \n '
return pulumi.get(self, 'valid_after') | @property
@pulumi.getter(name='validAfter')
def valid_after(self) -> pulumi.Output[str]:
'\n \n '
return pulumi.get(self, 'valid_after')<|docstring|>The key can be used after this timestamp. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".<|endoftext|> |
ac499dc305a80ac46076de8af2353b392574a5d59f4d7c51ab42f01a570231d8 | @property
@pulumi.getter(name='validBefore')
def valid_before(self) -> pulumi.Output[str]:
'\n The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
return pulumi.get(self, 'valid_before') | The key can be used before this timestamp.
A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z". | sdk/python/pulumi_gcp/serviceaccount/key.py | valid_before | la3mmchen/pulumi-gcp | 121 | python | @property
@pulumi.getter(name='validBefore')
def valid_before(self) -> pulumi.Output[str]:
'\n The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
return pulumi.get(self, 'valid_before') | @property
@pulumi.getter(name='validBefore')
def valid_before(self) -> pulumi.Output[str]:
'\n The key can be used before this timestamp.\n A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".\n '
return pulumi.get(self, 'valid_before')<|docstring|>The key can be used before this timestamp.
A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".<|endoftext|> |
d8157fdcde8ab97792153fdd241b0b67bfbd7d83ef05c7dfe4c3f914c40fcc9f | def getLicenseDetails(self, orgId):
'getLicenseDetails returns license details for the specified Org Id.\n\n Args:\n orgId (string): Org Id.\n\n Returns:\n dict: <License Details in dict Format>\n '
url = ((self._v3BaseURL + '/public/core/v3/license/org/') + orgId)
headers = {'Content-Type': 'application/json', 'Accept': 'application/json', 'INFA-SESSION-ID': self._v3SessionID}
infapy.log.info(('getLicenseDetails URL - ' + url))
infapy.log.info(('API Headers: ' + str(headers)))
infapy.log.info(('Body: ' + 'This API requires no body'))
try:
response = re.get(url=url, headers=headers)
infapy.log.debug(str(response.json()))
except Exception as e:
infapy.log.exception(e)
raise
infapy.log.info(('Fetched License Details for Org ' + orgId))
data = response.json()
return data | getLicenseDetails returns license details for the specified Org Id.
Args:
orgId (string): Org Id.
Returns:
dict: <License Details in dict Format> | infapy/v3/license.py | getLicenseDetails | infapy/infapy | 0 | python | def getLicenseDetails(self, orgId):
'getLicenseDetails returns license details for the specified Org Id.\n\n Args:\n orgId (string): Org Id.\n\n Returns:\n dict: <License Details in dict Format>\n '
url = ((self._v3BaseURL + '/public/core/v3/license/org/') + orgId)
headers = {'Content-Type': 'application/json', 'Accept': 'application/json', 'INFA-SESSION-ID': self._v3SessionID}
infapy.log.info(('getLicenseDetails URL - ' + url))
infapy.log.info(('API Headers: ' + str(headers)))
infapy.log.info(('Body: ' + 'This API requires no body'))
try:
response = re.get(url=url, headers=headers)
infapy.log.debug(str(response.json()))
except Exception as e:
infapy.log.exception(e)
raise
infapy.log.info(('Fetched License Details for Org ' + orgId))
data = response.json()
return data | def getLicenseDetails(self, orgId):
'getLicenseDetails returns license details for the specified Org Id.\n\n Args:\n orgId (string): Org Id.\n\n Returns:\n dict: <License Details in dict Format>\n '
url = ((self._v3BaseURL + '/public/core/v3/license/org/') + orgId)
headers = {'Content-Type': 'application/json', 'Accept': 'application/json', 'INFA-SESSION-ID': self._v3SessionID}
infapy.log.info(('getLicenseDetails URL - ' + url))
infapy.log.info(('API Headers: ' + str(headers)))
infapy.log.info(('Body: ' + 'This API requires no body'))
try:
response = re.get(url=url, headers=headers)
infapy.log.debug(str(response.json()))
except Exception as e:
infapy.log.exception(e)
raise
infapy.log.info(('Fetched License Details for Org ' + orgId))
data = response.json()
return data<|docstring|>getLicenseDetails returns license details for the specified Org Id.
Args:
orgId (string): Org Id.
Returns:
dict: <License Details in dict Format><|endoftext|> |
77d15d9e476a613601a63e2789d71c667b2135186429011ecc5d0657fe9cc468 | def updateSubOrgLicense(self, body, orgId):
'updateSubOrgLicense can be used to update license for subOrg specified by the orgId, using the provided JSON body.\n\n Args:\n orgId (string): Sub Org Id.\n body (dict): JSON body for POST request.\n\n Returns:\n dict: <License Details in dict Format>\n '
url = ((self._v3BaseURL + '/public/core/v3/license/org/') + orgId)
headers = {'Content-Type': 'application/json', 'Accept': 'application/json', 'INFA-SESSION-ID': self._v3SessionID}
infapy.log.info(('updateSubOrgLicense URL - ' + url))
infapy.log.info(('API Headers: ' + str(headers)))
infapy.log.info(('Body: ' + str(body)))
try:
response = re.put(url=url, headers=headers, json=body)
if (response.status_code == 200):
infapy.log.debug(str(response.reason))
else:
infapy.log.debug(str(response.json()))
except Exception as e:
infapy.log.exception(e)
raise
infapy.log.info((('Licenses for Sub Org ' + orgId) + ' have been updated'))
if (response.status_code == 200):
data = {'Status': (('Licenses for Sub Org ' + orgId) + ' have been updated.')}
else:
data = response.json()
return data | updateSubOrgLicense can be used to update license for subOrg specified by the orgId, using the provided JSON body.
Args:
orgId (string): Sub Org Id.
body (dict): JSON body for POST request.
Returns:
dict: <License Details in dict Format> | infapy/v3/license.py | updateSubOrgLicense | infapy/infapy | 0 | python | def updateSubOrgLicense(self, body, orgId):
'updateSubOrgLicense can be used to update license for subOrg specified by the orgId, using the provided JSON body.\n\n Args:\n orgId (string): Sub Org Id.\n body (dict): JSON body for POST request.\n\n Returns:\n dict: <License Details in dict Format>\n '
url = ((self._v3BaseURL + '/public/core/v3/license/org/') + orgId)
headers = {'Content-Type': 'application/json', 'Accept': 'application/json', 'INFA-SESSION-ID': self._v3SessionID}
infapy.log.info(('updateSubOrgLicense URL - ' + url))
infapy.log.info(('API Headers: ' + str(headers)))
infapy.log.info(('Body: ' + str(body)))
try:
response = re.put(url=url, headers=headers, json=body)
if (response.status_code == 200):
infapy.log.debug(str(response.reason))
else:
infapy.log.debug(str(response.json()))
except Exception as e:
infapy.log.exception(e)
raise
infapy.log.info((('Licenses for Sub Org ' + orgId) + ' have been updated'))
if (response.status_code == 200):
data = {'Status': (('Licenses for Sub Org ' + orgId) + ' have been updated.')}
else:
data = response.json()
return data | def updateSubOrgLicense(self, body, orgId):
'updateSubOrgLicense can be used to update license for subOrg specified by the orgId, using the provided JSON body.\n\n Args:\n orgId (string): Sub Org Id.\n body (dict): JSON body for POST request.\n\n Returns:\n dict: <License Details in dict Format>\n '
url = ((self._v3BaseURL + '/public/core/v3/license/org/') + orgId)
headers = {'Content-Type': 'application/json', 'Accept': 'application/json', 'INFA-SESSION-ID': self._v3SessionID}
infapy.log.info(('updateSubOrgLicense URL - ' + url))
infapy.log.info(('API Headers: ' + str(headers)))
infapy.log.info(('Body: ' + str(body)))
try:
response = re.put(url=url, headers=headers, json=body)
if (response.status_code == 200):
infapy.log.debug(str(response.reason))
else:
infapy.log.debug(str(response.json()))
except Exception as e:
infapy.log.exception(e)
raise
infapy.log.info((('Licenses for Sub Org ' + orgId) + ' have been updated'))
if (response.status_code == 200):
data = {'Status': (('Licenses for Sub Org ' + orgId) + ' have been updated.')}
else:
data = response.json()
return data<|docstring|>updateSubOrgLicense can be used to update license for subOrg specified by the orgId, using the provided JSON body.
Args:
orgId (string): Sub Org Id.
body (dict): JSON body for POST request.
Returns:
dict: <License Details in dict Format><|endoftext|> |
f55bd3d8660fddf2b400321494973a581b32ea483254f8703289315881245e11 | def __init__(self, host, port, **kwargs):
'Communicates with the 32-bit ``OL756SDKActiveXCtrl`` library.'
prog_id = kwargs.pop('prog_id')
mode = int(kwargs.pop('mode'))
com_port = int(kwargs.pop('com_port'))
Server32.remove_site_packages_64bit()
super(OL756, self).__init__(prog_id, 'activex', host, port, **kwargs)
self.mode = self.connect_to_ol756(mode, com_port=com_port) | Communicates with the 32-bit ``OL756SDKActiveXCtrl`` library. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | __init__ | MSLNZ/msl-equipment | 9 | python | def __init__(self, host, port, **kwargs):
prog_id = kwargs.pop('prog_id')
mode = int(kwargs.pop('mode'))
com_port = int(kwargs.pop('com_port'))
Server32.remove_site_packages_64bit()
super(OL756, self).__init__(prog_id, 'activex', host, port, **kwargs)
self.mode = self.connect_to_ol756(mode, com_port=com_port) | def __init__(self, host, port, **kwargs):
prog_id = kwargs.pop('prog_id')
mode = int(kwargs.pop('mode'))
com_port = int(kwargs.pop('com_port'))
Server32.remove_site_packages_64bit()
super(OL756, self).__init__(prog_id, 'activex', host, port, **kwargs)
self.mode = self.connect_to_ol756(mode, com_port=com_port)<|docstring|>Communicates with the 32-bit ``OL756SDKActiveXCtrl`` library.<|endoftext|> |
97c73a63aacd83f06294d352ebde2e194bc7cfc5e5db9d13df4081833a97a186 | def accumulate_signals(self, meas_type):
'Function needs to be called after a measurement was performed.\n\n This essentially accumulates the data together until the user is\n ready to average out the data. This function is used in combination\n with :meth:`.reset_averaging` and :meth:`.do_averaging`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.AccumulateSignals(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE)) | Function needs to be called after a measurement was performed.
This essentially accumulates the data together until the user is
ready to average out the data. This function is used in combination
with :meth:`.reset_averaging` and :meth:`.do_averaging`.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | accumulate_signals | MSLNZ/msl-equipment | 9 | python | def accumulate_signals(self, meas_type):
'Function needs to be called after a measurement was performed.\n\n This essentially accumulates the data together until the user is\n ready to average out the data. This function is used in combination\n with :meth:`.reset_averaging` and :meth:`.do_averaging`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.AccumulateSignals(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE)) | def accumulate_signals(self, meas_type):
'Function needs to be called after a measurement was performed.\n\n This essentially accumulates the data together until the user is\n ready to average out the data. This function is used in combination\n with :meth:`.reset_averaging` and :meth:`.do_averaging`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.AccumulateSignals(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE))<|docstring|>Function needs to be called after a measurement was performed.
This essentially accumulates the data together until the user is
ready to average out the data. This function is used in combination
with :meth:`.reset_averaging` and :meth:`.do_averaging`.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration<|endoftext|> |
f4eb9be0eb87490c3702e2ecbb5bd3f2090053c97604aceed3344fad585ae6a1 | def connect_to_ol756(self, mode, com_port=1):
'Desired mode to connect to OL756. If attempting to connect in RS232 or\n USB mode, and OL756 is not detected, then a dialog box will appear to prompt\n user to select either to retry, cancel or switch to DEMO.\n\n Parameters\n ----------\n mode : :class:`int`\n Valid modes are:\n\n * -1: Disconnect. Call this before quitting the application.\n * 0: RS232\n * 1: USB\n * 2: DEMO mode\n\n com_port : :class:`int`, optional\n If connecting through RS232 then `port` is the COM port number to use.\n\n Returns\n -------\n :class:`int`\n The mode that was actually used for the connection.\n '
return self.lib.ConnectToOl756(mode, com_port) | Desired mode to connect to OL756. If attempting to connect in RS232 or
USB mode, and OL756 is not detected, then a dialog box will appear to prompt
user to select either to retry, cancel or switch to DEMO.
Parameters
----------
mode : :class:`int`
Valid modes are:
* -1: Disconnect. Call this before quitting the application.
* 0: RS232
* 1: USB
* 2: DEMO mode
com_port : :class:`int`, optional
If connecting through RS232 then `port` is the COM port number to use.
Returns
-------
:class:`int`
The mode that was actually used for the connection. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | connect_to_ol756 | MSLNZ/msl-equipment | 9 | python | def connect_to_ol756(self, mode, com_port=1):
'Desired mode to connect to OL756. If attempting to connect in RS232 or\n USB mode, and OL756 is not detected, then a dialog box will appear to prompt\n user to select either to retry, cancel or switch to DEMO.\n\n Parameters\n ----------\n mode : :class:`int`\n Valid modes are:\n\n * -1: Disconnect. Call this before quitting the application.\n * 0: RS232\n * 1: USB\n * 2: DEMO mode\n\n com_port : :class:`int`, optional\n If connecting through RS232 then `port` is the COM port number to use.\n\n Returns\n -------\n :class:`int`\n The mode that was actually used for the connection.\n '
return self.lib.ConnectToOl756(mode, com_port) | def connect_to_ol756(self, mode, com_port=1):
'Desired mode to connect to OL756. If attempting to connect in RS232 or\n USB mode, and OL756 is not detected, then a dialog box will appear to prompt\n user to select either to retry, cancel or switch to DEMO.\n\n Parameters\n ----------\n mode : :class:`int`\n Valid modes are:\n\n * -1: Disconnect. Call this before quitting the application.\n * 0: RS232\n * 1: USB\n * 2: DEMO mode\n\n com_port : :class:`int`, optional\n If connecting through RS232 then `port` is the COM port number to use.\n\n Returns\n -------\n :class:`int`\n The mode that was actually used for the connection.\n '
return self.lib.ConnectToOl756(mode, com_port)<|docstring|>Desired mode to connect to OL756. If attempting to connect in RS232 or
USB mode, and OL756 is not detected, then a dialog box will appear to prompt
user to select either to retry, cancel or switch to DEMO.
Parameters
----------
mode : :class:`int`
Valid modes are:
* -1: Disconnect. Call this before quitting the application.
* 0: RS232
* 1: USB
* 2: DEMO mode
com_port : :class:`int`, optional
If connecting through RS232 then `port` is the COM port number to use.
Returns
-------
:class:`int`
The mode that was actually used for the connection.<|endoftext|> |
ba9985630f79e15eeb2b61a92da6a1b8da6a9295c8692471c36e472013b3574d | def do_averaging(self, meas_type, num_to_average):
'Function divides the accumulated signal by the number of scans\n performed. It then sets the array containing the data with the\n averaged data. This function is used in combination with\n :meth:`.reset_averaging` and :meth:`.accumulate_signals`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n num_to_average : :class:`int`\n The number of scans to average.\n '
ret = self.lib.DoAveraging(meas_type, num_to_average)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE)) | Function divides the accumulated signal by the number of scans
performed. It then sets the array containing the data with the
averaged data. This function is used in combination with
:meth:`.reset_averaging` and :meth:`.accumulate_signals`.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
num_to_average : :class:`int`
The number of scans to average. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | do_averaging | MSLNZ/msl-equipment | 9 | python | def do_averaging(self, meas_type, num_to_average):
'Function divides the accumulated signal by the number of scans\n performed. It then sets the array containing the data with the\n averaged data. This function is used in combination with\n :meth:`.reset_averaging` and :meth:`.accumulate_signals`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n num_to_average : :class:`int`\n The number of scans to average.\n '
ret = self.lib.DoAveraging(meas_type, num_to_average)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE)) | def do_averaging(self, meas_type, num_to_average):
'Function divides the accumulated signal by the number of scans\n performed. It then sets the array containing the data with the\n averaged data. This function is used in combination with\n :meth:`.reset_averaging` and :meth:`.accumulate_signals`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n num_to_average : :class:`int`\n The number of scans to average.\n '
ret = self.lib.DoAveraging(meas_type, num_to_average)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE))<|docstring|>Function divides the accumulated signal by the number of scans
performed. It then sets the array containing the data with the
averaged data. This function is used in combination with
:meth:`.reset_averaging` and :meth:`.accumulate_signals`.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
num_to_average : :class:`int`
The number of scans to average.<|endoftext|> |
4eca96914987f9fc9b6de62a49396b4b14f0ed3ac73b9d22e013949854096e22 | def do_calculations(self, meas_type):
'Function needs to be called after each measurement to update the calculations.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.DoCalculations(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE)) | Function needs to be called after each measurement to update the calculations.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | do_calculations | MSLNZ/msl-equipment | 9 | python | def do_calculations(self, meas_type):
'Function needs to be called after each measurement to update the calculations.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.DoCalculations(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE)) | def do_calculations(self, meas_type):
'Function needs to be called after each measurement to update the calculations.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.DoCalculations(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE))<|docstring|>Function needs to be called after each measurement to update the calculations.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration<|endoftext|> |
d51fe6441e9ea19c93ba09c4ae9c99d31eb1a54b37d2361af9e92e412bb712f5 | def enable_calibration_file(self, meas_type, enable):
'Enables or disables the use of a calibration file.\n\n Use this option to generate calibrated results. To open a standard file\n used to create a calibration, use :meth:`.enable_standard_file` instead.\n\n The user should call :meth:`.load_calibration_file` first to load\n the calibration file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n enable : :class:`bool`\n Whether to enable or disable the use of a calibration file.\n '
ret = self.lib.EnableCalibrationFile(meas_type, enable)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.FILE_IO_FAILED)) | Enables or disables the use of a calibration file.
Use this option to generate calibrated results. To open a standard file
used to create a calibration, use :meth:`.enable_standard_file` instead.
The user should call :meth:`.load_calibration_file` first to load
the calibration file before enabling it.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
enable : :class:`bool`
Whether to enable or disable the use of a calibration file. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | enable_calibration_file | MSLNZ/msl-equipment | 9 | python | def enable_calibration_file(self, meas_type, enable):
'Enables or disables the use of a calibration file.\n\n Use this option to generate calibrated results. To open a standard file\n used to create a calibration, use :meth:`.enable_standard_file` instead.\n\n The user should call :meth:`.load_calibration_file` first to load\n the calibration file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n enable : :class:`bool`\n Whether to enable or disable the use of a calibration file.\n '
ret = self.lib.EnableCalibrationFile(meas_type, enable)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.FILE_IO_FAILED)) | def enable_calibration_file(self, meas_type, enable):
'Enables or disables the use of a calibration file.\n\n Use this option to generate calibrated results. To open a standard file\n used to create a calibration, use :meth:`.enable_standard_file` instead.\n\n The user should call :meth:`.load_calibration_file` first to load\n the calibration file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n enable : :class:`bool`\n Whether to enable or disable the use of a calibration file.\n '
ret = self.lib.EnableCalibrationFile(meas_type, enable)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.FILE_IO_FAILED))<|docstring|>Enables or disables the use of a calibration file.
Use this option to generate calibrated results. To open a standard file
used to create a calibration, use :meth:`.enable_standard_file` instead.
The user should call :meth:`.load_calibration_file` first to load
the calibration file before enabling it.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
enable : :class:`bool`
Whether to enable or disable the use of a calibration file.<|endoftext|> |
f16e11b8d94318d28586224deb709db2d0cb9e9deefb1323a44174e5e6f600f9 | def enable_dark_current(self, enable):
'Turn the dark current on or off.\n\n Enable this feature if you want the dark current automatically\n acquired and subtracted before each measurement. If you wish to\n take a dark current manually, see the :meth:`.get_dark_current` function.\n\n The parameters for the dark current will need to be set using\n :meth:`.set_dark_current_params`.\n\n Parameters\n ----------\n enable : :class:`bool`\n Whether to turn the dark current on or off.\n '
ret = self.lib.EnableDarkCurrent(enable)
self._check(ret, (_Error.SYSTEM_BUSY,)) | Turn the dark current on or off.
Enable this feature if you want the dark current automatically
acquired and subtracted before each measurement. If you wish to
take a dark current manually, see the :meth:`.get_dark_current` function.
The parameters for the dark current will need to be set using
:meth:`.set_dark_current_params`.
Parameters
----------
enable : :class:`bool`
Whether to turn the dark current on or off. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | enable_dark_current | MSLNZ/msl-equipment | 9 | python | def enable_dark_current(self, enable):
'Turn the dark current on or off.\n\n Enable this feature if you want the dark current automatically\n acquired and subtracted before each measurement. If you wish to\n take a dark current manually, see the :meth:`.get_dark_current` function.\n\n The parameters for the dark current will need to be set using\n :meth:`.set_dark_current_params`.\n\n Parameters\n ----------\n enable : :class:`bool`\n Whether to turn the dark current on or off.\n '
ret = self.lib.EnableDarkCurrent(enable)
self._check(ret, (_Error.SYSTEM_BUSY,)) | def enable_dark_current(self, enable):
'Turn the dark current on or off.\n\n Enable this feature if you want the dark current automatically\n acquired and subtracted before each measurement. If you wish to\n take a dark current manually, see the :meth:`.get_dark_current` function.\n\n The parameters for the dark current will need to be set using\n :meth:`.set_dark_current_params`.\n\n Parameters\n ----------\n enable : :class:`bool`\n Whether to turn the dark current on or off.\n '
ret = self.lib.EnableDarkCurrent(enable)
self._check(ret, (_Error.SYSTEM_BUSY,))<|docstring|>Turn the dark current on or off.
Enable this feature if you want the dark current automatically
acquired and subtracted before each measurement. If you wish to
take a dark current manually, see the :meth:`.get_dark_current` function.
The parameters for the dark current will need to be set using
:meth:`.set_dark_current_params`.
Parameters
----------
enable : :class:`bool`
Whether to turn the dark current on or off.<|endoftext|> |
a098a9873a5bffbf9abd9c0c7c88f41ae2eadff566158703d1f390551d9865c0 | def enable_pmt_protection_mode(self, enable):
'Turn the PMT protection routines on or off.\n\n Enable this feature if you want the PMT to be shielded while traveling\n through high intensity spikes. This feature will make the scan slower\n since the wavelength and filter drive will move asynchronously.\n\n The PMT is still protected by the hardware. This function prevents\n exposure of the PMT while traveling.\n\n Parameters\n ----------\n enable : :class:`bool`\n Whether to turn the PMT protection routines on or off.\n '
ret = self.lib.EnablePMTProtectionMode(enable)
self._check(ret, (_Error.SYSTEM_BUSY,)) | Turn the PMT protection routines on or off.
Enable this feature if you want the PMT to be shielded while traveling
through high intensity spikes. This feature will make the scan slower
since the wavelength and filter drive will move asynchronously.
The PMT is still protected by the hardware. This function prevents
exposure of the PMT while traveling.
Parameters
----------
enable : :class:`bool`
Whether to turn the PMT protection routines on or off. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | enable_pmt_protection_mode | MSLNZ/msl-equipment | 9 | python | def enable_pmt_protection_mode(self, enable):
'Turn the PMT protection routines on or off.\n\n Enable this feature if you want the PMT to be shielded while traveling\n through high intensity spikes. This feature will make the scan slower\n since the wavelength and filter drive will move asynchronously.\n\n The PMT is still protected by the hardware. This function prevents\n exposure of the PMT while traveling.\n\n Parameters\n ----------\n enable : :class:`bool`\n Whether to turn the PMT protection routines on or off.\n '
ret = self.lib.EnablePMTProtectionMode(enable)
self._check(ret, (_Error.SYSTEM_BUSY,)) | def enable_pmt_protection_mode(self, enable):
'Turn the PMT protection routines on or off.\n\n Enable this feature if you want the PMT to be shielded while traveling\n through high intensity spikes. This feature will make the scan slower\n since the wavelength and filter drive will move asynchronously.\n\n The PMT is still protected by the hardware. This function prevents\n exposure of the PMT while traveling.\n\n Parameters\n ----------\n enable : :class:`bool`\n Whether to turn the PMT protection routines on or off.\n '
ret = self.lib.EnablePMTProtectionMode(enable)
self._check(ret, (_Error.SYSTEM_BUSY,))<|docstring|>Turn the PMT protection routines on or off.
Enable this feature if you want the PMT to be shielded while traveling
through high intensity spikes. This feature will make the scan slower
since the wavelength and filter drive will move asynchronously.
The PMT is still protected by the hardware. This function prevents
exposure of the PMT while traveling.
Parameters
----------
enable : :class:`bool`
Whether to turn the PMT protection routines on or off.<|endoftext|> |
6270d330e05d79c850efd4c117fe994544ad31f782eec91d188c13f8dfaae316 | def enable_standard_file(self, meas_type, enable):
'Function enables standard files to be used.\n\n To open a calibration file used to create a measurement, use\n :meth:`.enable_calibration_file` instead.\n\n The user should call :meth:`.load_standard_file` first to load\n the standard file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The calibration measurement type wanted.\n\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n enable : :class:`bool`\n Whether to turn the application of the standard file on or off.\n '
ret = self.lib.EnableStandardFile(meas_type, enable)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.FILE_IO_FAILED)) | Function enables standard files to be used.
To open a calibration file used to create a measurement, use
:meth:`.enable_calibration_file` instead.
The user should call :meth:`.load_standard_file` first to load
the standard file before enabling it.
Parameters
----------
meas_type : :class:`int`
The calibration measurement type wanted.
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
enable : :class:`bool`
Whether to turn the application of the standard file on or off. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | enable_standard_file | MSLNZ/msl-equipment | 9 | python | def enable_standard_file(self, meas_type, enable):
'Function enables standard files to be used.\n\n To open a calibration file used to create a measurement, use\n :meth:`.enable_calibration_file` instead.\n\n The user should call :meth:`.load_standard_file` first to load\n the standard file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The calibration measurement type wanted.\n\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n enable : :class:`bool`\n Whether to turn the application of the standard file on or off.\n '
ret = self.lib.EnableStandardFile(meas_type, enable)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.FILE_IO_FAILED)) | def enable_standard_file(self, meas_type, enable):
'Function enables standard files to be used.\n\n To open a calibration file used to create a measurement, use\n :meth:`.enable_calibration_file` instead.\n\n The user should call :meth:`.load_standard_file` first to load\n the standard file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The calibration measurement type wanted.\n\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n enable : :class:`bool`\n Whether to turn the application of the standard file on or off.\n '
ret = self.lib.EnableStandardFile(meas_type, enable)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.FILE_IO_FAILED))<|docstring|>Function enables standard files to be used.
To open a calibration file used to create a measurement, use
:meth:`.enable_calibration_file` instead.
The user should call :meth:`.load_standard_file` first to load
the standard file before enabling it.
Parameters
----------
meas_type : :class:`int`
The calibration measurement type wanted.
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
enable : :class:`bool`
Whether to turn the application of the standard file on or off.<|endoftext|> |
4ef14a252e09b3693e66b09dad3754558d82c87a0c9c1c6b83e875be27b7232d | def export_config_file(self, file_path):
'Exports the config file into a OL756 compatible configuration file.\n\n Not all settings used will be applicable.\n\n Parameters\n ----------\n file_path : :class:`str`\n A valid path to save the file at.\n '
ret = self.lib.ExportConfigFile(file_path)
self._check(ret, (_Error.FILE_IO_FAILED,)) | Exports the config file into a OL756 compatible configuration file.
Not all settings used will be applicable.
Parameters
----------
file_path : :class:`str`
A valid path to save the file at. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | export_config_file | MSLNZ/msl-equipment | 9 | python | def export_config_file(self, file_path):
'Exports the config file into a OL756 compatible configuration file.\n\n Not all settings used will be applicable.\n\n Parameters\n ----------\n file_path : :class:`str`\n A valid path to save the file at.\n '
ret = self.lib.ExportConfigFile(file_path)
self._check(ret, (_Error.FILE_IO_FAILED,)) | def export_config_file(self, file_path):
'Exports the config file into a OL756 compatible configuration file.\n\n Not all settings used will be applicable.\n\n Parameters\n ----------\n file_path : :class:`str`\n A valid path to save the file at.\n '
ret = self.lib.ExportConfigFile(file_path)
self._check(ret, (_Error.FILE_IO_FAILED,))<|docstring|>Exports the config file into a OL756 compatible configuration file.
Not all settings used will be applicable.
Parameters
----------
file_path : :class:`str`
A valid path to save the file at.<|endoftext|> |
6f9fd30228155e15dbacd8ff5f20693c197fe0cfd46a26ffee2d5be4307ccc62 | def export_registry(self):
'Save data out to the Windows registry.\n\n Make sure that a read was done at some point using\n :meth:`.import_registry`. Does not create a configuration file that can\n be loaded into another computer. For that particular function, call\n :meth:`.export_config_file`.\n '
ret = self.lib.ExportRegistry()
self._check(ret, (_Error.SYSTEM_BUSY,)) | Save data out to the Windows registry.
Make sure that a read was done at some point using
:meth:`.import_registry`. Does not create a configuration file that can
be loaded into another computer. For that particular function, call
:meth:`.export_config_file`. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | export_registry | MSLNZ/msl-equipment | 9 | python | def export_registry(self):
'Save data out to the Windows registry.\n\n Make sure that a read was done at some point using\n :meth:`.import_registry`. Does not create a configuration file that can\n be loaded into another computer. For that particular function, call\n :meth:`.export_config_file`.\n '
ret = self.lib.ExportRegistry()
self._check(ret, (_Error.SYSTEM_BUSY,)) | def export_registry(self):
'Save data out to the Windows registry.\n\n Make sure that a read was done at some point using\n :meth:`.import_registry`. Does not create a configuration file that can\n be loaded into another computer. For that particular function, call\n :meth:`.export_config_file`.\n '
ret = self.lib.ExportRegistry()
self._check(ret, (_Error.SYSTEM_BUSY,))<|docstring|>Save data out to the Windows registry.
Make sure that a read was done at some point using
:meth:`.import_registry`. Does not create a configuration file that can
be loaded into another computer. For that particular function, call
:meth:`.export_config_file`.<|endoftext|> |
95a3d75cc80c8b8bb5aa8d363bf67335ec4a6e979409a20375c9a1202835e9c2 | def get_adaptive_int_time_index(self, gain_index):
'Get the adaptive integration time index.\n\n Parameters\n ----------\n gain_index : :class:`int`\n The index of the gain to use to get the integration time.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10\n * 6 - 1.0E-11\n\n Returns\n -------\n :class:`int`\n The adaptive integration time index.\n '
ret = self.lib.GetAdaptiveIntTimeIndex(gain_index)
if (ret == (- 1)):
raise ValueError('Invalid gain index.')
return ret | Get the adaptive integration time index.
Parameters
----------
gain_index : :class:`int`
The index of the gain to use to get the integration time.
* 0 - 1.0E-5
* 1 - 1.0E-6
* 2 - 1.0E-7
* 3 - 1.0E-8
* 4 - 1.0E-9
* 5 - 1.0E-10
* 6 - 1.0E-11
Returns
-------
:class:`int`
The adaptive integration time index. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_adaptive_int_time_index | MSLNZ/msl-equipment | 9 | python | def get_adaptive_int_time_index(self, gain_index):
'Get the adaptive integration time index.\n\n Parameters\n ----------\n gain_index : :class:`int`\n The index of the gain to use to get the integration time.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10\n * 6 - 1.0E-11\n\n Returns\n -------\n :class:`int`\n The adaptive integration time index.\n '
ret = self.lib.GetAdaptiveIntTimeIndex(gain_index)
if (ret == (- 1)):
raise ValueError('Invalid gain index.')
return ret | def get_adaptive_int_time_index(self, gain_index):
'Get the adaptive integration time index.\n\n Parameters\n ----------\n gain_index : :class:`int`\n The index of the gain to use to get the integration time.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10\n * 6 - 1.0E-11\n\n Returns\n -------\n :class:`int`\n The adaptive integration time index.\n '
ret = self.lib.GetAdaptiveIntTimeIndex(gain_index)
if (ret == (- 1)):
raise ValueError('Invalid gain index.')
return ret<|docstring|>Get the adaptive integration time index.
Parameters
----------
gain_index : :class:`int`
The index of the gain to use to get the integration time.
* 0 - 1.0E-5
* 1 - 1.0E-6
* 2 - 1.0E-7
* 3 - 1.0E-8
* 4 - 1.0E-9
* 5 - 1.0E-10
* 6 - 1.0E-11
Returns
-------
:class:`int`
The adaptive integration time index.<|endoftext|> |
e84d74be081250cac29bb6c112bf628a107ddf336aa7ec0c95af63c7fac4eb4e | def get_cri(self, meas_type, index):
'Get the color-rendering information.\n\n The user should call :meth:`.do_calculations` at least once before\n calling this function.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The color-rendering index.\n\n * 0 - General CRI\n * 1 - Light Greyish Red (CRI#1)\n * 2 - Dark Greyish Yellow (CRI#2)\n * 3 - Strong Yellow Green (CRI#3)\n * 4 - Moderate Yellowish Green (CRI#4)\n * 5 - Light Bluish Green (CRI#5)\n * 6 - Light Blue (CRI#6)\n * 7 - Light Violet (CRI#7)\n * 8 - Light Reddish Purple (CRI#8)\n * 9 - Strong Red (CRI#9)\n * 10 - Strong Yellow (CRI#10)\n * 11 - Strong Green (CRI#11)\n * 12 - Strong Blue (CRI#12)\n * 13 - Light Yellowish Pink (CRI#13)\n * 14 - Moderate Olive Green (CRI#14)\n\n Returns\n -------\n :class:`float`\n The color-rendering information.\n '
data = c_double()
ret = self.lib.GetCRI(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value | Get the color-rendering information.
The user should call :meth:`.do_calculations` at least once before
calling this function.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
index : :class:`int`
The color-rendering index.
* 0 - General CRI
* 1 - Light Greyish Red (CRI#1)
* 2 - Dark Greyish Yellow (CRI#2)
* 3 - Strong Yellow Green (CRI#3)
* 4 - Moderate Yellowish Green (CRI#4)
* 5 - Light Bluish Green (CRI#5)
* 6 - Light Blue (CRI#6)
* 7 - Light Violet (CRI#7)
* 8 - Light Reddish Purple (CRI#8)
* 9 - Strong Red (CRI#9)
* 10 - Strong Yellow (CRI#10)
* 11 - Strong Green (CRI#11)
* 12 - Strong Blue (CRI#12)
* 13 - Light Yellowish Pink (CRI#13)
* 14 - Moderate Olive Green (CRI#14)
Returns
-------
:class:`float`
The color-rendering information. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_cri | MSLNZ/msl-equipment | 9 | python | def get_cri(self, meas_type, index):
'Get the color-rendering information.\n\n The user should call :meth:`.do_calculations` at least once before\n calling this function.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The color-rendering index.\n\n * 0 - General CRI\n * 1 - Light Greyish Red (CRI#1)\n * 2 - Dark Greyish Yellow (CRI#2)\n * 3 - Strong Yellow Green (CRI#3)\n * 4 - Moderate Yellowish Green (CRI#4)\n * 5 - Light Bluish Green (CRI#5)\n * 6 - Light Blue (CRI#6)\n * 7 - Light Violet (CRI#7)\n * 8 - Light Reddish Purple (CRI#8)\n * 9 - Strong Red (CRI#9)\n * 10 - Strong Yellow (CRI#10)\n * 11 - Strong Green (CRI#11)\n * 12 - Strong Blue (CRI#12)\n * 13 - Light Yellowish Pink (CRI#13)\n * 14 - Moderate Olive Green (CRI#14)\n\n Returns\n -------\n :class:`float`\n The color-rendering information.\n '
data = c_double()
ret = self.lib.GetCRI(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value | def get_cri(self, meas_type, index):
'Get the color-rendering information.\n\n The user should call :meth:`.do_calculations` at least once before\n calling this function.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The color-rendering index.\n\n * 0 - General CRI\n * 1 - Light Greyish Red (CRI#1)\n * 2 - Dark Greyish Yellow (CRI#2)\n * 3 - Strong Yellow Green (CRI#3)\n * 4 - Moderate Yellowish Green (CRI#4)\n * 5 - Light Bluish Green (CRI#5)\n * 6 - Light Blue (CRI#6)\n * 7 - Light Violet (CRI#7)\n * 8 - Light Reddish Purple (CRI#8)\n * 9 - Strong Red (CRI#9)\n * 10 - Strong Yellow (CRI#10)\n * 11 - Strong Green (CRI#11)\n * 12 - Strong Blue (CRI#12)\n * 13 - Light Yellowish Pink (CRI#13)\n * 14 - Moderate Olive Green (CRI#14)\n\n Returns\n -------\n :class:`float`\n The color-rendering information.\n '
data = c_double()
ret = self.lib.GetCRI(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value<|docstring|>Get the color-rendering information.
The user should call :meth:`.do_calculations` at least once before
calling this function.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
index : :class:`int`
The color-rendering index.
* 0 - General CRI
* 1 - Light Greyish Red (CRI#1)
* 2 - Dark Greyish Yellow (CRI#2)
* 3 - Strong Yellow Green (CRI#3)
* 4 - Moderate Yellowish Green (CRI#4)
* 5 - Light Bluish Green (CRI#5)
* 6 - Light Blue (CRI#6)
* 7 - Light Violet (CRI#7)
* 8 - Light Reddish Purple (CRI#8)
* 9 - Strong Red (CRI#9)
* 10 - Strong Yellow (CRI#10)
* 11 - Strong Green (CRI#11)
* 12 - Strong Blue (CRI#12)
* 13 - Light Yellowish Pink (CRI#13)
* 14 - Moderate Olive Green (CRI#14)
Returns
-------
:class:`float`
The color-rendering information.<|endoftext|> |
227c0fcf1426f827330cc82d4ec4ac7727922893f7ecabfdd7f9e7f3e326e040 | def get_cal_array(self):
'This method allows user to get the spectral data of a calibration\n after it is made. The data allows the user to take the data and\n create their own data files.\n\n Returns\n -------\n :class:`int`\n A pointer to an array of signals.\n :class:`int`\n The number of points acquired.\n '
num_points = c_long()
pointer = self.lib.GetCalArray(byref(num_points))
return (pointer, num_points.value) | This method allows user to get the spectral data of a calibration
after it is made. The data allows the user to take the data and
create their own data files.
Returns
-------
:class:`int`
A pointer to an array of signals.
:class:`int`
The number of points acquired. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_cal_array | MSLNZ/msl-equipment | 9 | python | def get_cal_array(self):
'This method allows user to get the spectral data of a calibration\n after it is made. The data allows the user to take the data and\n create their own data files.\n\n Returns\n -------\n :class:`int`\n A pointer to an array of signals.\n :class:`int`\n The number of points acquired.\n '
num_points = c_long()
pointer = self.lib.GetCalArray(byref(num_points))
return (pointer, num_points.value) | def get_cal_array(self):
'This method allows user to get the spectral data of a calibration\n after it is made. The data allows the user to take the data and\n create their own data files.\n\n Returns\n -------\n :class:`int`\n A pointer to an array of signals.\n :class:`int`\n The number of points acquired.\n '
num_points = c_long()
pointer = self.lib.GetCalArray(byref(num_points))
return (pointer, num_points.value)<|docstring|>This method allows user to get the spectral data of a calibration
after it is made. The data allows the user to take the data and
create their own data files.
Returns
-------
:class:`int`
A pointer to an array of signals.
:class:`int`
The number of points acquired.<|endoftext|> |
cc446441b1d85fce73786dc251145a7e88809feb8ee77eb77c20f73f57d63018 | def get_cal_file_enabled(self, meas_type):
'Checks to see if the calibration file is enabled.\n\n The user should call :meth:`.load_calibration_file` first to load the\n calibration file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`bool`\n Whether the calibration file is enabled.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return bool(self.lib.GetCalFileEnabled(meas_type)) | Checks to see if the calibration file is enabled.
The user should call :meth:`.load_calibration_file` first to load the
calibration file before enabling it.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
Returns
-------
:class:`bool`
Whether the calibration file is enabled. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_cal_file_enabled | MSLNZ/msl-equipment | 9 | python | def get_cal_file_enabled(self, meas_type):
'Checks to see if the calibration file is enabled.\n\n The user should call :meth:`.load_calibration_file` first to load the\n calibration file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`bool`\n Whether the calibration file is enabled.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return bool(self.lib.GetCalFileEnabled(meas_type)) | def get_cal_file_enabled(self, meas_type):
'Checks to see if the calibration file is enabled.\n\n The user should call :meth:`.load_calibration_file` first to load the\n calibration file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`bool`\n Whether the calibration file is enabled.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return bool(self.lib.GetCalFileEnabled(meas_type))<|docstring|>Checks to see if the calibration file is enabled.
The user should call :meth:`.load_calibration_file` first to load the
calibration file before enabling it.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
Returns
-------
:class:`bool`
Whether the calibration file is enabled.<|endoftext|> |
f3bf87f61c867786afb2865f4903cf5530862cbd30e7897a53858b64b439f4a3 | def get_calculated_data(self, meas_type, index):
'Gets data calculated from the intensities.\n\n The user should call :meth:`.do_calculations` at least once before\n calling this function.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The index to retrieve data of.\n\n * 0 - Color Temperature\n * 1 - Dominant Wavelength\n * 2 - LED Half Bandwidth\n * 3 - Left Half Bandwidth\n * 4 - Right Half Bandwidth\n * 5 - Peak Spectral Value\n * 6 - LEDPeakWavelength\n * 7 - Radiometric Value\n * 8 - Purity\n * 9 - Center Wavelength\n * 10 - Photometric Value\n\n Returns\n -------\n :class:`float`\n Pointer to a double to hold the data.\n '
data = c_double()
ret = self.lib.GetCalculatedData(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value | Gets data calculated from the intensities.
The user should call :meth:`.do_calculations` at least once before
calling this function.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
index : :class:`int`
The index to retrieve data of.
* 0 - Color Temperature
* 1 - Dominant Wavelength
* 2 - LED Half Bandwidth
* 3 - Left Half Bandwidth
* 4 - Right Half Bandwidth
* 5 - Peak Spectral Value
* 6 - LEDPeakWavelength
* 7 - Radiometric Value
* 8 - Purity
* 9 - Center Wavelength
* 10 - Photometric Value
Returns
-------
:class:`float`
Pointer to a double to hold the data. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_calculated_data | MSLNZ/msl-equipment | 9 | python | def get_calculated_data(self, meas_type, index):
'Gets data calculated from the intensities.\n\n The user should call :meth:`.do_calculations` at least once before\n calling this function.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The index to retrieve data of.\n\n * 0 - Color Temperature\n * 1 - Dominant Wavelength\n * 2 - LED Half Bandwidth\n * 3 - Left Half Bandwidth\n * 4 - Right Half Bandwidth\n * 5 - Peak Spectral Value\n * 6 - LEDPeakWavelength\n * 7 - Radiometric Value\n * 8 - Purity\n * 9 - Center Wavelength\n * 10 - Photometric Value\n\n Returns\n -------\n :class:`float`\n Pointer to a double to hold the data.\n '
data = c_double()
ret = self.lib.GetCalculatedData(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value | def get_calculated_data(self, meas_type, index):
'Gets data calculated from the intensities.\n\n The user should call :meth:`.do_calculations` at least once before\n calling this function.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The index to retrieve data of.\n\n * 0 - Color Temperature\n * 1 - Dominant Wavelength\n * 2 - LED Half Bandwidth\n * 3 - Left Half Bandwidth\n * 4 - Right Half Bandwidth\n * 5 - Peak Spectral Value\n * 6 - LEDPeakWavelength\n * 7 - Radiometric Value\n * 8 - Purity\n * 9 - Center Wavelength\n * 10 - Photometric Value\n\n Returns\n -------\n :class:`float`\n Pointer to a double to hold the data.\n '
data = c_double()
ret = self.lib.GetCalculatedData(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value<|docstring|>Gets data calculated from the intensities.
The user should call :meth:`.do_calculations` at least once before
calling this function.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
index : :class:`int`
The index to retrieve data of.
* 0 - Color Temperature
* 1 - Dominant Wavelength
* 2 - LED Half Bandwidth
* 3 - Left Half Bandwidth
* 4 - Right Half Bandwidth
* 5 - Peak Spectral Value
* 6 - LEDPeakWavelength
* 7 - Radiometric Value
* 8 - Purity
* 9 - Center Wavelength
* 10 - Photometric Value
Returns
-------
:class:`float`
Pointer to a double to hold the data.<|endoftext|> |
a03f3f842564a98c1c80de0ba7c50ea6223196d2a82da700d3bfed50786f623c | def get_calibration_file(self, meas_type):
'Get a calibration file that is loaded.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`str`\n String containing the name and path of the calibration file\n that is loaded for a particular measurement type.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return self.lib.GetCalibrationFile(meas_type) | Get a calibration file that is loaded.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
Returns
-------
:class:`str`
String containing the name and path of the calibration file
that is loaded for a particular measurement type. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_calibration_file | MSLNZ/msl-equipment | 9 | python | def get_calibration_file(self, meas_type):
'Get a calibration file that is loaded.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`str`\n String containing the name and path of the calibration file\n that is loaded for a particular measurement type.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return self.lib.GetCalibrationFile(meas_type) | def get_calibration_file(self, meas_type):
'Get a calibration file that is loaded.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`str`\n String containing the name and path of the calibration file\n that is loaded for a particular measurement type.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return self.lib.GetCalibrationFile(meas_type)<|docstring|>Get a calibration file that is loaded.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
Returns
-------
:class:`str`
String containing the name and path of the calibration file
that is loaded for a particular measurement type.<|endoftext|> |
31c161910a76c635826c8f1da91983377e5a33ed3e82dc2a5a438972f83b5330 | def get_chromaticity_data(self, meas_type, index):
'Get the calculated chromaticity values requested.\n\n Must have called :meth:`.do_calculations` at least once.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The chromaticity index value [0..70]. See the SDK manual for more details.\n\n Returns\n -------\n :class:`float`\n Pointer to a double to hold the data.\n '
data = c_double()
ret = self.lib.GetChromaticityData(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value | Get the calculated chromaticity values requested.
Must have called :meth:`.do_calculations` at least once.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
index : :class:`int`
The chromaticity index value [0..70]. See the SDK manual for more details.
Returns
-------
:class:`float`
Pointer to a double to hold the data. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_chromaticity_data | MSLNZ/msl-equipment | 9 | python | def get_chromaticity_data(self, meas_type, index):
'Get the calculated chromaticity values requested.\n\n Must have called :meth:`.do_calculations` at least once.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The chromaticity index value [0..70]. See the SDK manual for more details.\n\n Returns\n -------\n :class:`float`\n Pointer to a double to hold the data.\n '
data = c_double()
ret = self.lib.GetChromaticityData(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value | def get_chromaticity_data(self, meas_type, index):
'Get the calculated chromaticity values requested.\n\n Must have called :meth:`.do_calculations` at least once.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n index : :class:`int`\n The chromaticity index value [0..70]. See the SDK manual for more details.\n\n Returns\n -------\n :class:`float`\n Pointer to a double to hold the data.\n '
data = c_double()
ret = self.lib.GetChromaticityData(meas_type, index, byref(data))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE, _Error.PARAM_ERR_VAL_INDEX))
return data.value<|docstring|>Get the calculated chromaticity values requested.
Must have called :meth:`.do_calculations` at least once.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration
index : :class:`int`
The chromaticity index value [0..70]. See the SDK manual for more details.
Returns
-------
:class:`float`
Pointer to a double to hold the data.<|endoftext|> |
19c33e0a18fa9465eea66a7a05d3517e4eabeb5e28980017d9a52f5bdf0f5ad5 | def get_dark_current(self, use_compensation):
'Takes a manual dark current.\n\n User will have to subtract from data array by retrieving this array via\n a :meth:`.get_cal_array` or :meth:`.get_signal_array`. This is a special\n function and most users will want to use :meth:`.enable_dark_current`\n instead because it automatically does the subtraction.\n\n Function if called externally by user program will not have result\n saved out to data file. If the :meth:`.enable_dark_current` was enabled,\n then this function need should not be called.\n\n Parameters\n ----------\n use_compensation : :class:`int`\n Adjusts dark current for more dynamic ranging using reverse current.\n\n Returns\n -------\n :class:`float`\n The dark current.\n '
dark_current = c_double()
ret = self.lib.GetDarkCurrent(byref(dark_current), use_compensation)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SCAN_PARAMSNOTSENT, _Error.SCAN_DCFAILED))
return dark_current.value | Takes a manual dark current.
User will have to subtract from data array by retrieving this array via
a :meth:`.get_cal_array` or :meth:`.get_signal_array`. This is a special
function and most users will want to use :meth:`.enable_dark_current`
instead because it automatically does the subtraction.
Function if called externally by user program will not have result
saved out to data file. If the :meth:`.enable_dark_current` was enabled,
then this function need should not be called.
Parameters
----------
use_compensation : :class:`int`
Adjusts dark current for more dynamic ranging using reverse current.
Returns
-------
:class:`float`
The dark current. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_dark_current | MSLNZ/msl-equipment | 9 | python | def get_dark_current(self, use_compensation):
'Takes a manual dark current.\n\n User will have to subtract from data array by retrieving this array via\n a :meth:`.get_cal_array` or :meth:`.get_signal_array`. This is a special\n function and most users will want to use :meth:`.enable_dark_current`\n instead because it automatically does the subtraction.\n\n Function if called externally by user program will not have result\n saved out to data file. If the :meth:`.enable_dark_current` was enabled,\n then this function need should not be called.\n\n Parameters\n ----------\n use_compensation : :class:`int`\n Adjusts dark current for more dynamic ranging using reverse current.\n\n Returns\n -------\n :class:`float`\n The dark current.\n '
dark_current = c_double()
ret = self.lib.GetDarkCurrent(byref(dark_current), use_compensation)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SCAN_PARAMSNOTSENT, _Error.SCAN_DCFAILED))
return dark_current.value | def get_dark_current(self, use_compensation):
'Takes a manual dark current.\n\n User will have to subtract from data array by retrieving this array via\n a :meth:`.get_cal_array` or :meth:`.get_signal_array`. This is a special\n function and most users will want to use :meth:`.enable_dark_current`\n instead because it automatically does the subtraction.\n\n Function if called externally by user program will not have result\n saved out to data file. If the :meth:`.enable_dark_current` was enabled,\n then this function need should not be called.\n\n Parameters\n ----------\n use_compensation : :class:`int`\n Adjusts dark current for more dynamic ranging using reverse current.\n\n Returns\n -------\n :class:`float`\n The dark current.\n '
dark_current = c_double()
ret = self.lib.GetDarkCurrent(byref(dark_current), use_compensation)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SCAN_PARAMSNOTSENT, _Error.SCAN_DCFAILED))
return dark_current.value<|docstring|>Takes a manual dark current.
User will have to subtract from data array by retrieving this array via
a :meth:`.get_cal_array` or :meth:`.get_signal_array`. This is a special
function and most users will want to use :meth:`.enable_dark_current`
instead because it automatically does the subtraction.
Function if called externally by user program will not have result
saved out to data file. If the :meth:`.enable_dark_current` was enabled,
then this function need should not be called.
Parameters
----------
use_compensation : :class:`int`
Adjusts dark current for more dynamic ranging using reverse current.
Returns
-------
:class:`float`
The dark current.<|endoftext|> |
78aec9cb64b7b11d79382d2d4ff10fe7d6baf8c9736ac6f6d4e0140518286f1a | def get_dark_current_enable(self):
'Returns whether the dark-current mode is enabled.\n\n Returns\n -------\n :class:`bool`\n Whether the dark-current mode is enabled or disabled.\n '
return bool(self.lib.GetDarkCurrentEnable()) | Returns whether the dark-current mode is enabled.
Returns
-------
:class:`bool`
Whether the dark-current mode is enabled or disabled. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_dark_current_enable | MSLNZ/msl-equipment | 9 | python | def get_dark_current_enable(self):
'Returns whether the dark-current mode is enabled.\n\n Returns\n -------\n :class:`bool`\n Whether the dark-current mode is enabled or disabled.\n '
return bool(self.lib.GetDarkCurrentEnable()) | def get_dark_current_enable(self):
'Returns whether the dark-current mode is enabled.\n\n Returns\n -------\n :class:`bool`\n Whether the dark-current mode is enabled or disabled.\n '
return bool(self.lib.GetDarkCurrentEnable())<|docstring|>Returns whether the dark-current mode is enabled.
Returns
-------
:class:`bool`
Whether the dark-current mode is enabled or disabled.<|endoftext|> |
d5607469665fad67a49ea70f990be80f2a4662d7d427581049263c93dae8bca1 | def get_dark_current_mode(self):
'Returns whether the dark current is taken at a wavelength or in shutter mode.\n\n Returns\n -------\n :class:`int`\n The dark-current mode\n\n * 0 - Dark current in wavelength mode (taken at a particular wavelength designated by the user).\n * 1 - Dark current in shutter mode\n\n '
return self.lib.GetDarkCurrentMode() | Returns whether the dark current is taken at a wavelength or in shutter mode.
Returns
-------
:class:`int`
The dark-current mode
* 0 - Dark current in wavelength mode (taken at a particular wavelength designated by the user).
* 1 - Dark current in shutter mode | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_dark_current_mode | MSLNZ/msl-equipment | 9 | python | def get_dark_current_mode(self):
'Returns whether the dark current is taken at a wavelength or in shutter mode.\n\n Returns\n -------\n :class:`int`\n The dark-current mode\n\n * 0 - Dark current in wavelength mode (taken at a particular wavelength designated by the user).\n * 1 - Dark current in shutter mode\n\n '
return self.lib.GetDarkCurrentMode() | def get_dark_current_mode(self):
'Returns whether the dark current is taken at a wavelength or in shutter mode.\n\n Returns\n -------\n :class:`int`\n The dark-current mode\n\n * 0 - Dark current in wavelength mode (taken at a particular wavelength designated by the user).\n * 1 - Dark current in shutter mode\n\n '
return self.lib.GetDarkCurrentMode()<|docstring|>Returns whether the dark current is taken at a wavelength or in shutter mode.
Returns
-------
:class:`int`
The dark-current mode
* 0 - Dark current in wavelength mode (taken at a particular wavelength designated by the user).
* 1 - Dark current in shutter mode<|endoftext|> |
af5059f01d7fa1615cd383c2bce1078bab6bd94089301754a634171ad348233b | def get_dark_current_wavelength(self):
'Get the dark current wavelength.\n\n Returns\n -------\n :class:`float`\n Wavelength that the dark current will be taken at.\n '
return self.lib.GetDarkCurrentWavelength() | Get the dark current wavelength.
Returns
-------
:class:`float`
Wavelength that the dark current will be taken at. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_dark_current_wavelength | MSLNZ/msl-equipment | 9 | python | def get_dark_current_wavelength(self):
'Get the dark current wavelength.\n\n Returns\n -------\n :class:`float`\n Wavelength that the dark current will be taken at.\n '
return self.lib.GetDarkCurrentWavelength() | def get_dark_current_wavelength(self):
'Get the dark current wavelength.\n\n Returns\n -------\n :class:`float`\n Wavelength that the dark current will be taken at.\n '
return self.lib.GetDarkCurrentWavelength()<|docstring|>Get the dark current wavelength.
Returns
-------
:class:`float`
Wavelength that the dark current will be taken at.<|endoftext|> |
6e159e57134932f5e8ec4b11ab51108b5fbe34091852a2c58bc1b8e2546b1c69 | def get_ending_wavelength(self):
'Get the ending wavelength of the scan range.\n\n Returns\n -------\n :class:`float`\n The ending wavelength, in nanometers, of the scan range.\n '
return self.lib.GetEndingWavelength() | Get the ending wavelength of the scan range.
Returns
-------
:class:`float`
The ending wavelength, in nanometers, of the scan range. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_ending_wavelength | MSLNZ/msl-equipment | 9 | python | def get_ending_wavelength(self):
'Get the ending wavelength of the scan range.\n\n Returns\n -------\n :class:`float`\n The ending wavelength, in nanometers, of the scan range.\n '
return self.lib.GetEndingWavelength() | def get_ending_wavelength(self):
'Get the ending wavelength of the scan range.\n\n Returns\n -------\n :class:`float`\n The ending wavelength, in nanometers, of the scan range.\n '
return self.lib.GetEndingWavelength()<|docstring|>Get the ending wavelength of the scan range.
Returns
-------
:class:`float`
The ending wavelength, in nanometers, of the scan range.<|endoftext|> |
898d3d9ac98bb5db81cc914638e2375c32ebcf5911a26c165f38202435595798 | def get_gain_index(self):
'Get the index of the gain that will be applied when\n the parameters are to be sent down.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n '
return self.lib.GetGainIndex() | Get the index of the gain that will be applied when
the parameters are to be sent down.
Applies to both quick scan and point to point scans.
Returns
-------
:class:`int`
The gain index.
* 0 - 1.0E-5
* 1 - 1.0E-6
* 2 - 1.0E-7
* 3 - 1.0E-8
* 4 - 1.0E-9
* 5 - 1.0E-10 (Point to Point mode only)
* 6 - 1.0E-11 (Point to Point mode only)
* 7 - Auto Gain Ranging (Point to Point mode only) | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_gain_index | MSLNZ/msl-equipment | 9 | python | def get_gain_index(self):
'Get the index of the gain that will be applied when\n the parameters are to be sent down.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n '
return self.lib.GetGainIndex() | def get_gain_index(self):
'Get the index of the gain that will be applied when\n the parameters are to be sent down.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n '
return self.lib.GetGainIndex()<|docstring|>Get the index of the gain that will be applied when
the parameters are to be sent down.
Applies to both quick scan and point to point scans.
Returns
-------
:class:`int`
The gain index.
* 0 - 1.0E-5
* 1 - 1.0E-6
* 2 - 1.0E-7
* 3 - 1.0E-8
* 4 - 1.0E-9
* 5 - 1.0E-10 (Point to Point mode only)
* 6 - 1.0E-11 (Point to Point mode only)
* 7 - Auto Gain Ranging (Point to Point mode only)<|endoftext|> |
f84bc98ec52a73fc34bdd2810d40f029dcc80bf3c44bdb38c71a1213c7266318 | def get_increment(self):
'Get the wavelength increment that is used for a scan.\n\n Returns\n -------\n :class:`float`\n The wavelength increment, in nanometers.\n '
return self.lib.GetIncrement() | Get the wavelength increment that is used for a scan.
Returns
-------
:class:`float`
The wavelength increment, in nanometers. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_increment | MSLNZ/msl-equipment | 9 | python | def get_increment(self):
'Get the wavelength increment that is used for a scan.\n\n Returns\n -------\n :class:`float`\n The wavelength increment, in nanometers.\n '
return self.lib.GetIncrement() | def get_increment(self):
'Get the wavelength increment that is used for a scan.\n\n Returns\n -------\n :class:`float`\n The wavelength increment, in nanometers.\n '
return self.lib.GetIncrement()<|docstring|>Get the wavelength increment that is used for a scan.
Returns
-------
:class:`float`
The wavelength increment, in nanometers.<|endoftext|> |
6529ea4da8f2441d92ba75a34944494fd3950576e8796af10c967b4abb39968e | def get_increment_index(self):
'Get the index of the wavelength increment that is used for a scan.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`int`\n Index of the wavelength increment of a scan.\n\n * 0 - 0.025 nm\n * 1 - 0.05 nm\n * 2 - 0.1 nm\n * 3 - 0.2 nm\n * 4 - 0.5 nm\n * 5 - 1.0 nm\n * 6 - 2.0 nm\n * 7 - 5.0 nm\n * 8 - 10.0 nm\n\n '
index = self.lib.GetIncrementIndex()
return index | Get the index of the wavelength increment that is used for a scan.
Applies to both quick scan and point to point scans.
Returns
-------
:class:`int`
Index of the wavelength increment of a scan.
* 0 - 0.025 nm
* 1 - 0.05 nm
* 2 - 0.1 nm
* 3 - 0.2 nm
* 4 - 0.5 nm
* 5 - 1.0 nm
* 6 - 2.0 nm
* 7 - 5.0 nm
* 8 - 10.0 nm | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_increment_index | MSLNZ/msl-equipment | 9 | python | def get_increment_index(self):
'Get the index of the wavelength increment that is used for a scan.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`int`\n Index of the wavelength increment of a scan.\n\n * 0 - 0.025 nm\n * 1 - 0.05 nm\n * 2 - 0.1 nm\n * 3 - 0.2 nm\n * 4 - 0.5 nm\n * 5 - 1.0 nm\n * 6 - 2.0 nm\n * 7 - 5.0 nm\n * 8 - 10.0 nm\n\n '
index = self.lib.GetIncrementIndex()
return index | def get_increment_index(self):
'Get the index of the wavelength increment that is used for a scan.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`int`\n Index of the wavelength increment of a scan.\n\n * 0 - 0.025 nm\n * 1 - 0.05 nm\n * 2 - 0.1 nm\n * 3 - 0.2 nm\n * 4 - 0.5 nm\n * 5 - 1.0 nm\n * 6 - 2.0 nm\n * 7 - 5.0 nm\n * 8 - 10.0 nm\n\n '
index = self.lib.GetIncrementIndex()
return index<|docstring|>Get the index of the wavelength increment that is used for a scan.
Applies to both quick scan and point to point scans.
Returns
-------
:class:`int`
Index of the wavelength increment of a scan.
* 0 - 0.025 nm
* 1 - 0.05 nm
* 2 - 0.1 nm
* 3 - 0.2 nm
* 4 - 0.5 nm
* 5 - 1.0 nm
* 6 - 2.0 nm
* 7 - 5.0 nm
* 8 - 10.0 nm<|endoftext|> |
a214463dd132b3d74b1b83c7c85e0a44688df456c0ebc9fc622bdb5103828fde | def get_integration_time_index(self, scan_mode):
'Get the index into the integration time array.\n\n Applies to both quick scan and point to point scans. In quick scan,\n the speed will vary based on the scan range and increments.\n\n Parameters\n ----------\n scan_mode : :class:`int`\n The scan mode to use to get the index of.\n\n Returns\n -------\n :class:`int`\n Point to Point mode\n\n * 0 - 1.000 sec\n * 1 - 0.500 sec\n * 2 - 0.200 sec\n * 3 - 0.100 sec\n * 4 - 0.050 sec\n * 5 - 0.020 sec\n * 6 - 0.010 sec\n * 7 - 0.005 sec\n * 8 - 0.002 sec\n * 9 - 0.001 sec\n * 10 - Adaptive\t(Point To Point mode only)\n\n Quick Scan mode\n\n * 0 - slowest\n * 10 - fastest\n\n '
if (scan_mode not in [0, 1]):
raise ValueError('Invalid scan mode {}. Must be 0 or 1'.format(scan_mode))
return self.lib.GetIntegrationTimeIndex(scan_mode) | Get the index into the integration time array.
Applies to both quick scan and point to point scans. In quick scan,
the speed will vary based on the scan range and increments.
Parameters
----------
scan_mode : :class:`int`
The scan mode to use to get the index of.
Returns
-------
:class:`int`
Point to Point mode
* 0 - 1.000 sec
* 1 - 0.500 sec
* 2 - 0.200 sec
* 3 - 0.100 sec
* 4 - 0.050 sec
* 5 - 0.020 sec
* 6 - 0.010 sec
* 7 - 0.005 sec
* 8 - 0.002 sec
* 9 - 0.001 sec
* 10 - Adaptive (Point To Point mode only)
Quick Scan mode
* 0 - slowest
* 10 - fastest | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_integration_time_index | MSLNZ/msl-equipment | 9 | python | def get_integration_time_index(self, scan_mode):
'Get the index into the integration time array.\n\n Applies to both quick scan and point to point scans. In quick scan,\n the speed will vary based on the scan range and increments.\n\n Parameters\n ----------\n scan_mode : :class:`int`\n The scan mode to use to get the index of.\n\n Returns\n -------\n :class:`int`\n Point to Point mode\n\n * 0 - 1.000 sec\n * 1 - 0.500 sec\n * 2 - 0.200 sec\n * 3 - 0.100 sec\n * 4 - 0.050 sec\n * 5 - 0.020 sec\n * 6 - 0.010 sec\n * 7 - 0.005 sec\n * 8 - 0.002 sec\n * 9 - 0.001 sec\n * 10 - Adaptive\t(Point To Point mode only)\n\n Quick Scan mode\n\n * 0 - slowest\n * 10 - fastest\n\n '
if (scan_mode not in [0, 1]):
raise ValueError('Invalid scan mode {}. Must be 0 or 1'.format(scan_mode))
return self.lib.GetIntegrationTimeIndex(scan_mode) | def get_integration_time_index(self, scan_mode):
'Get the index into the integration time array.\n\n Applies to both quick scan and point to point scans. In quick scan,\n the speed will vary based on the scan range and increments.\n\n Parameters\n ----------\n scan_mode : :class:`int`\n The scan mode to use to get the index of.\n\n Returns\n -------\n :class:`int`\n Point to Point mode\n\n * 0 - 1.000 sec\n * 1 - 0.500 sec\n * 2 - 0.200 sec\n * 3 - 0.100 sec\n * 4 - 0.050 sec\n * 5 - 0.020 sec\n * 6 - 0.010 sec\n * 7 - 0.005 sec\n * 8 - 0.002 sec\n * 9 - 0.001 sec\n * 10 - Adaptive\t(Point To Point mode only)\n\n Quick Scan mode\n\n * 0 - slowest\n * 10 - fastest\n\n '
if (scan_mode not in [0, 1]):
raise ValueError('Invalid scan mode {}. Must be 0 or 1'.format(scan_mode))
return self.lib.GetIntegrationTimeIndex(scan_mode)<|docstring|>Get the index into the integration time array.
Applies to both quick scan and point to point scans. In quick scan,
the speed will vary based on the scan range and increments.
Parameters
----------
scan_mode : :class:`int`
The scan mode to use to get the index of.
Returns
-------
:class:`int`
Point to Point mode
* 0 - 1.000 sec
* 1 - 0.500 sec
* 2 - 0.200 sec
* 3 - 0.100 sec
* 4 - 0.050 sec
* 5 - 0.020 sec
* 6 - 0.010 sec
* 7 - 0.005 sec
* 8 - 0.002 sec
* 9 - 0.001 sec
* 10 - Adaptive (Point To Point mode only)
Quick Scan mode
* 0 - slowest
* 10 - fastest<|endoftext|> |
03604fd48f714ef176c566f9fbad2875d08b2a95774ad228e3a2517dae42214f | def get_ocx_version(self):
'Get the version of the OL756 SDK ActiveX control.\n\n Returns\n -------\n :class:`str`\n The software version.\n '
return self.lib.GetOCXVersion() | Get the version of the OL756 SDK ActiveX control.
Returns
-------
:class:`str`
The software version. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_ocx_version | MSLNZ/msl-equipment | 9 | python | def get_ocx_version(self):
'Get the version of the OL756 SDK ActiveX control.\n\n Returns\n -------\n :class:`str`\n The software version.\n '
return self.lib.GetOCXVersion() | def get_ocx_version(self):
'Get the version of the OL756 SDK ActiveX control.\n\n Returns\n -------\n :class:`str`\n The software version.\n '
return self.lib.GetOCXVersion()<|docstring|>Get the version of the OL756 SDK ActiveX control.
Returns
-------
:class:`str`
The software version.<|endoftext|> |
bcc3b09edfb7655069394cfce914656671b9837f199ddcf7d295195c0cbd0d57 | def get_pmt_flux_overload(self):
'Get the voltage of the photomultiplier tube flux overload.\n\n Returns\n -------\n :class:`float`\n Voltage that the PMT will determine to be at the overload point.\n '
return self.lib.GetPMTFluxOverload() | Get the voltage of the photomultiplier tube flux overload.
Returns
-------
:class:`float`
Voltage that the PMT will determine to be at the overload point. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_pmt_flux_overload | MSLNZ/msl-equipment | 9 | python | def get_pmt_flux_overload(self):
'Get the voltage of the photomultiplier tube flux overload.\n\n Returns\n -------\n :class:`float`\n Voltage that the PMT will determine to be at the overload point.\n '
return self.lib.GetPMTFluxOverload() | def get_pmt_flux_overload(self):
'Get the voltage of the photomultiplier tube flux overload.\n\n Returns\n -------\n :class:`float`\n Voltage that the PMT will determine to be at the overload point.\n '
return self.lib.GetPMTFluxOverload()<|docstring|>Get the voltage of the photomultiplier tube flux overload.
Returns
-------
:class:`float`
Voltage that the PMT will determine to be at the overload point.<|endoftext|> |
9a62aa64f60109a8240369d511259e93d1fff2d340a011f5959b3e70b91d5318 | def get_pmt_voltage(self):
'Returns the voltage that will sent or has been sent down to the PMT.\n\n Returns\n -------\n :class:`float`\n Voltage value, in volts, of the photomultiplier tube.\n '
return self.lib.GetPmtVoltage() | Returns the voltage that will sent or has been sent down to the PMT.
Returns
-------
:class:`float`
Voltage value, in volts, of the photomultiplier tube. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_pmt_voltage | MSLNZ/msl-equipment | 9 | python | def get_pmt_voltage(self):
'Returns the voltage that will sent or has been sent down to the PMT.\n\n Returns\n -------\n :class:`float`\n Voltage value, in volts, of the photomultiplier tube.\n '
return self.lib.GetPmtVoltage() | def get_pmt_voltage(self):
'Returns the voltage that will sent or has been sent down to the PMT.\n\n Returns\n -------\n :class:`float`\n Voltage value, in volts, of the photomultiplier tube.\n '
return self.lib.GetPmtVoltage()<|docstring|>Returns the voltage that will sent or has been sent down to the PMT.
Returns
-------
:class:`float`
Voltage value, in volts, of the photomultiplier tube.<|endoftext|> |
9aaaed0ebe58cde316fc0fbd4fe5c30f6df53eb322cf325315b405d44a19dee0 | def get_quick_scan_rate(self):
'Returns the rate at the quick scan index.\n\n Returns\n -------\n :class:`float`\n Rate of the quick scan at the current index in nm/s.\n '
return self.lib.GetQuickScanRate() | Returns the rate at the quick scan index.
Returns
-------
:class:`float`
Rate of the quick scan at the current index in nm/s. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_quick_scan_rate | MSLNZ/msl-equipment | 9 | python | def get_quick_scan_rate(self):
'Returns the rate at the quick scan index.\n\n Returns\n -------\n :class:`float`\n Rate of the quick scan at the current index in nm/s.\n '
return self.lib.GetQuickScanRate() | def get_quick_scan_rate(self):
'Returns the rate at the quick scan index.\n\n Returns\n -------\n :class:`float`\n Rate of the quick scan at the current index in nm/s.\n '
return self.lib.GetQuickScanRate()<|docstring|>Returns the rate at the quick scan index.
Returns
-------
:class:`float`
Rate of the quick scan at the current index in nm/s.<|endoftext|> |
f0e60969a4e3635bfba273be68f6c4dcd63909b779a70e9130181efa69919b49 | def get_quick_scan_rate_index(self):
'Returns the index of the quick scan rate.\n\n Returns\n -------\n :class:`int`\n Index of the quick scan rate.\n '
return self.lib.GetQuickScanRateIndex() | Returns the index of the quick scan rate.
Returns
-------
:class:`int`
Index of the quick scan rate. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_quick_scan_rate_index | MSLNZ/msl-equipment | 9 | python | def get_quick_scan_rate_index(self):
'Returns the index of the quick scan rate.\n\n Returns\n -------\n :class:`int`\n Index of the quick scan rate.\n '
return self.lib.GetQuickScanRateIndex() | def get_quick_scan_rate_index(self):
'Returns the index of the quick scan rate.\n\n Returns\n -------\n :class:`int`\n Index of the quick scan rate.\n '
return self.lib.GetQuickScanRateIndex()<|docstring|>Returns the index of the quick scan rate.
Returns
-------
:class:`int`
Index of the quick scan rate.<|endoftext|> |
b8f8bf6d2fafacdba5dba6c849ba9c678d621b83bc789c7fe2d1741df4d12289 | def get_scan_mode(self):
'Get the mode the scan will be done in.\n\n Returns\n -------\n :class:`int`\n The scan mode\n\n * 0 - Point to Point mode\n * 1 - Quick Scan mode\n\n '
return self.lib.GetScanMode() | Get the mode the scan will be done in.
Returns
-------
:class:`int`
The scan mode
* 0 - Point to Point mode
* 1 - Quick Scan mode | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_scan_mode | MSLNZ/msl-equipment | 9 | python | def get_scan_mode(self):
'Get the mode the scan will be done in.\n\n Returns\n -------\n :class:`int`\n The scan mode\n\n * 0 - Point to Point mode\n * 1 - Quick Scan mode\n\n '
return self.lib.GetScanMode() | def get_scan_mode(self):
'Get the mode the scan will be done in.\n\n Returns\n -------\n :class:`int`\n The scan mode\n\n * 0 - Point to Point mode\n * 1 - Quick Scan mode\n\n '
return self.lib.GetScanMode()<|docstring|>Get the mode the scan will be done in.
Returns
-------
:class:`int`
The scan mode
* 0 - Point to Point mode
* 1 - Quick Scan mode<|endoftext|> |
cb1d69fe531acd784bd0bde6404bc141aa165d3f080465e70440baa28c61b1ca | def get_settling_time(self):
'Gte the settling time.\n\n Settling time is time where the wavelength drive pauses once\n it reaches its target wavelength.\n\n Returns\n -------\n :class:`float`\n Settling time, in seconds, to be sent down or has already been\n sent to the system.\n '
return self.lib.GetSettlingTime() | Gte the settling time.
Settling time is time where the wavelength drive pauses once
it reaches its target wavelength.
Returns
-------
:class:`float`
Settling time, in seconds, to be sent down or has already been
sent to the system. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_settling_time | MSLNZ/msl-equipment | 9 | python | def get_settling_time(self):
'Gte the settling time.\n\n Settling time is time where the wavelength drive pauses once\n it reaches its target wavelength.\n\n Returns\n -------\n :class:`float`\n Settling time, in seconds, to be sent down or has already been\n sent to the system.\n '
return self.lib.GetSettlingTime() | def get_settling_time(self):
'Gte the settling time.\n\n Settling time is time where the wavelength drive pauses once\n it reaches its target wavelength.\n\n Returns\n -------\n :class:`float`\n Settling time, in seconds, to be sent down or has already been\n sent to the system.\n '
return self.lib.GetSettlingTime()<|docstring|>Gte the settling time.
Settling time is time where the wavelength drive pauses once
it reaches its target wavelength.
Returns
-------
:class:`float`
Settling time, in seconds, to be sent down or has already been
sent to the system.<|endoftext|> |
2da56adc7a3decec30ec3a014e5cd6ab1a31f34de2d9cfef60083425e4c33a52 | def get_signal_array(self):
'Get the spectral data of a measurement after it is made.\n\n Returns\n -------\n :class:`tuple`\n The spectral data.\n '
num_points = c_long()
array = self.lib.GetSignalVariantArray(byref(num_points))
if (len(array) != num_points.value):
raise RuntimeError('Length of the array does not equal the number of points')
return array | Get the spectral data of a measurement after it is made.
Returns
-------
:class:`tuple`
The spectral data. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_signal_array | MSLNZ/msl-equipment | 9 | python | def get_signal_array(self):
'Get the spectral data of a measurement after it is made.\n\n Returns\n -------\n :class:`tuple`\n The spectral data.\n '
num_points = c_long()
array = self.lib.GetSignalVariantArray(byref(num_points))
if (len(array) != num_points.value):
raise RuntimeError('Length of the array does not equal the number of points')
return array | def get_signal_array(self):
'Get the spectral data of a measurement after it is made.\n\n Returns\n -------\n :class:`tuple`\n The spectral data.\n '
num_points = c_long()
array = self.lib.GetSignalVariantArray(byref(num_points))
if (len(array) != num_points.value):
raise RuntimeError('Length of the array does not equal the number of points')
return array<|docstring|>Get the spectral data of a measurement after it is made.
Returns
-------
:class:`tuple`
The spectral data.<|endoftext|> |
39fea775f2b6019f64167fc874240b519427dffda5171e768985e40db4ca6996 | def get_standard_file(self, meas_type):
'Retrieves the name of standard file.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 3 - Irradiance calibration\n * 4 - Radiance calibration\n * 5 - Transmittance calibration\n\n Returns\n -------\n :class:`str`\n String containing the name and path of the standard file that is\n loaded for a particular calibration type.\n '
if (meas_type not in [3, 4, 5]):
raise ValueError('Invalid measurement type {}. Must be 3, 4 or 5'.format(meas_type))
return self.lib.GetStandardFile(meas_type) | Retrieves the name of standard file.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 3 - Irradiance calibration
* 4 - Radiance calibration
* 5 - Transmittance calibration
Returns
-------
:class:`str`
String containing the name and path of the standard file that is
loaded for a particular calibration type. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_standard_file | MSLNZ/msl-equipment | 9 | python | def get_standard_file(self, meas_type):
'Retrieves the name of standard file.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 3 - Irradiance calibration\n * 4 - Radiance calibration\n * 5 - Transmittance calibration\n\n Returns\n -------\n :class:`str`\n String containing the name and path of the standard file that is\n loaded for a particular calibration type.\n '
if (meas_type not in [3, 4, 5]):
raise ValueError('Invalid measurement type {}. Must be 3, 4 or 5'.format(meas_type))
return self.lib.GetStandardFile(meas_type) | def get_standard_file(self, meas_type):
'Retrieves the name of standard file.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type wanted.\n\n * 3 - Irradiance calibration\n * 4 - Radiance calibration\n * 5 - Transmittance calibration\n\n Returns\n -------\n :class:`str`\n String containing the name and path of the standard file that is\n loaded for a particular calibration type.\n '
if (meas_type not in [3, 4, 5]):
raise ValueError('Invalid measurement type {}. Must be 3, 4 or 5'.format(meas_type))
return self.lib.GetStandardFile(meas_type)<|docstring|>Retrieves the name of standard file.
Parameters
----------
meas_type : :class:`int`
The measurement type wanted.
* 3 - Irradiance calibration
* 4 - Radiance calibration
* 5 - Transmittance calibration
Returns
-------
:class:`str`
String containing the name and path of the standard file that is
loaded for a particular calibration type.<|endoftext|> |
db717a635859286f2e2fe2c2b5887668f34f8f8f9fd69246d15fcb464e282739 | def get_start_wavelength(self):
'Get the starting wavelength of a scan.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`float`\n The wavelength, in nanometers, that the scan will start from.\n '
return self.lib.GetStartWavelength() | Get the starting wavelength of a scan.
Applies to both quick scan and point to point scans.
Returns
-------
:class:`float`
The wavelength, in nanometers, that the scan will start from. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_start_wavelength | MSLNZ/msl-equipment | 9 | python | def get_start_wavelength(self):
'Get the starting wavelength of a scan.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`float`\n The wavelength, in nanometers, that the scan will start from.\n '
return self.lib.GetStartWavelength() | def get_start_wavelength(self):
'Get the starting wavelength of a scan.\n\n Applies to both quick scan and point to point scans.\n\n Returns\n -------\n :class:`float`\n The wavelength, in nanometers, that the scan will start from.\n '
return self.lib.GetStartWavelength()<|docstring|>Get the starting wavelength of a scan.
Applies to both quick scan and point to point scans.
Returns
-------
:class:`float`
The wavelength, in nanometers, that the scan will start from.<|endoftext|> |
456d647d9b11dd061e5a9a7f0ec9e8576666a3a780330a66d6adad41b7526339 | def get_std_file_enabled(self, meas_type):
'Checks to see if the standard file is enabled.\n\n The user should call :meth:`.load_standard_file` first to load\n the standard file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The calibration type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`bool`\n Whether a standard file is enabled.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return bool(self.lib.GetStdFileEnabled(meas_type)) | Checks to see if the standard file is enabled.
The user should call :meth:`.load_standard_file` first to load
the standard file before enabling it.
Parameters
----------
meas_type : :class:`int`
The calibration type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
Returns
-------
:class:`bool`
Whether a standard file is enabled. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | get_std_file_enabled | MSLNZ/msl-equipment | 9 | python | def get_std_file_enabled(self, meas_type):
'Checks to see if the standard file is enabled.\n\n The user should call :meth:`.load_standard_file` first to load\n the standard file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The calibration type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`bool`\n Whether a standard file is enabled.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return bool(self.lib.GetStdFileEnabled(meas_type)) | def get_std_file_enabled(self, meas_type):
'Checks to see if the standard file is enabled.\n\n The user should call :meth:`.load_standard_file` first to load\n the standard file before enabling it.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The calibration type wanted.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n Returns\n -------\n :class:`bool`\n Whether a standard file is enabled.\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
return bool(self.lib.GetStdFileEnabled(meas_type))<|docstring|>Checks to see if the standard file is enabled.
The user should call :meth:`.load_standard_file` first to load
the standard file before enabling it.
Parameters
----------
meas_type : :class:`int`
The calibration type wanted.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
Returns
-------
:class:`bool`
Whether a standard file is enabled.<|endoftext|> |
acf6ecd4c2d9337dbe20729fb7298c0eeb3dfb9a2d98dcfb2385a24fb92a4a56 | def import_config_file(self, path):
'The file is a standard OL756 configuration file.\n\n Not all settings used will be applicable. Measurement type is not used\n because in the SDK, the :meth:`.take_point_to_point_measurement`\n function has as an input the measurement type. The user should select\n the type and not have it based on the configuration file.\n\n Parameters\n ----------\n path : :class:`str`\n A valid path to load the file at.\n '
ret = self.lib.ImportConfigFile(path)
self._check(ret, (_Error.FILE_IO_FAILED,)) | The file is a standard OL756 configuration file.
Not all settings used will be applicable. Measurement type is not used
because in the SDK, the :meth:`.take_point_to_point_measurement`
function has as an input the measurement type. The user should select
the type and not have it based on the configuration file.
Parameters
----------
path : :class:`str`
A valid path to load the file at. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | import_config_file | MSLNZ/msl-equipment | 9 | python | def import_config_file(self, path):
'The file is a standard OL756 configuration file.\n\n Not all settings used will be applicable. Measurement type is not used\n because in the SDK, the :meth:`.take_point_to_point_measurement`\n function has as an input the measurement type. The user should select\n the type and not have it based on the configuration file.\n\n Parameters\n ----------\n path : :class:`str`\n A valid path to load the file at.\n '
ret = self.lib.ImportConfigFile(path)
self._check(ret, (_Error.FILE_IO_FAILED,)) | def import_config_file(self, path):
'The file is a standard OL756 configuration file.\n\n Not all settings used will be applicable. Measurement type is not used\n because in the SDK, the :meth:`.take_point_to_point_measurement`\n function has as an input the measurement type. The user should select\n the type and not have it based on the configuration file.\n\n Parameters\n ----------\n path : :class:`str`\n A valid path to load the file at.\n '
ret = self.lib.ImportConfigFile(path)
self._check(ret, (_Error.FILE_IO_FAILED,))<|docstring|>The file is a standard OL756 configuration file.
Not all settings used will be applicable. Measurement type is not used
because in the SDK, the :meth:`.take_point_to_point_measurement`
function has as an input the measurement type. The user should select
the type and not have it based on the configuration file.
Parameters
----------
path : :class:`str`
A valid path to load the file at.<|endoftext|> |
7dfd5653d5f2f59d8ff5f62d88a118a5ea37cb03f84384831feb69b3607da68f | def import_registry(self):
'Loads data from the registry.\n\n Loads default if no registry exists. To import the configuration\n from another computer, use :meth:`.import_config_file` instead.\n\n Not all settings used will be applicable. Measurement type is not\n used because in the SDK, the :meth:`.take_point_to_point_measurement`\n function has as an input the measurement type. The user should\n select the type and not have it based on the configuration file.\n '
ret = self.lib.ImportRegistry()
self._check(ret, (_Error.SYSTEM_BUSY,)) | Loads data from the registry.
Loads default if no registry exists. To import the configuration
from another computer, use :meth:`.import_config_file` instead.
Not all settings used will be applicable. Measurement type is not
used because in the SDK, the :meth:`.take_point_to_point_measurement`
function has as an input the measurement type. The user should
select the type and not have it based on the configuration file. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | import_registry | MSLNZ/msl-equipment | 9 | python | def import_registry(self):
'Loads data from the registry.\n\n Loads default if no registry exists. To import the configuration\n from another computer, use :meth:`.import_config_file` instead.\n\n Not all settings used will be applicable. Measurement type is not\n used because in the SDK, the :meth:`.take_point_to_point_measurement`\n function has as an input the measurement type. The user should\n select the type and not have it based on the configuration file.\n '
ret = self.lib.ImportRegistry()
self._check(ret, (_Error.SYSTEM_BUSY,)) | def import_registry(self):
'Loads data from the registry.\n\n Loads default if no registry exists. To import the configuration\n from another computer, use :meth:`.import_config_file` instead.\n\n Not all settings used will be applicable. Measurement type is not\n used because in the SDK, the :meth:`.take_point_to_point_measurement`\n function has as an input the measurement type. The user should\n select the type and not have it based on the configuration file.\n '
ret = self.lib.ImportRegistry()
self._check(ret, (_Error.SYSTEM_BUSY,))<|docstring|>Loads data from the registry.
Loads default if no registry exists. To import the configuration
from another computer, use :meth:`.import_config_file` instead.
Not all settings used will be applicable. Measurement type is not
used because in the SDK, the :meth:`.take_point_to_point_measurement`
function has as an input the measurement type. The user should
select the type and not have it based on the configuration file.<|endoftext|> |
9c6f3dc46e3bd504ea0e12f26586872c95c722e9dc9236c57cc64aea7d49f239 | def load_calibration_file(self, path, meas_type):
'Load a calibration file.\n\n Parameters\n ----------\n path : :class:`str`\n The path of a calibration file.\n meas_type : :class:`int`\n The measurement type.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
ret = self.lib.LoadCalibrationFile(path, meas_type)
self._check(ret, (_Error.FILE_IO_FAILED,)) | Load a calibration file.
Parameters
----------
path : :class:`str`
The path of a calibration file.
meas_type : :class:`int`
The measurement type.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | load_calibration_file | MSLNZ/msl-equipment | 9 | python | def load_calibration_file(self, path, meas_type):
'Load a calibration file.\n\n Parameters\n ----------\n path : :class:`str`\n The path of a calibration file.\n meas_type : :class:`int`\n The measurement type.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
ret = self.lib.LoadCalibrationFile(path, meas_type)
self._check(ret, (_Error.FILE_IO_FAILED,)) | def load_calibration_file(self, path, meas_type):
'Load a calibration file.\n\n Parameters\n ----------\n path : :class:`str`\n The path of a calibration file.\n meas_type : :class:`int`\n The measurement type.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n\n '
if (meas_type not in [0, 1, 2]):
raise ValueError('Invalid measurement type {}. Must be 0, 1 or 2'.format(meas_type))
ret = self.lib.LoadCalibrationFile(path, meas_type)
self._check(ret, (_Error.FILE_IO_FAILED,))<|docstring|>Load a calibration file.
Parameters
----------
path : :class:`str`
The path of a calibration file.
meas_type : :class:`int`
The measurement type.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance<|endoftext|> |
2d2d6c9328dd82ab93901c73656660b78649cd7332e4ca22f63413187c10bf83 | def load_standard_file(self, path, meas_type):
'Load a standard file.\n\n Parameters\n ----------\n path : :class:`str`\n The path of a standard file.\n meas_type : :class:`int`\n The measurement type.\n\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
if (meas_type not in [3, 4, 5]):
raise ValueError('Invalid measurement type {}. Must be 3, 4 or 5'.format(meas_type))
ret = self.lib.LoadStandardFile(path, meas_type)
self._check(ret, (_Error.FILE_IO_FAILED,)) | Load a standard file.
Parameters
----------
path : :class:`str`
The path of a standard file.
meas_type : :class:`int`
The measurement type.
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | load_standard_file | MSLNZ/msl-equipment | 9 | python | def load_standard_file(self, path, meas_type):
'Load a standard file.\n\n Parameters\n ----------\n path : :class:`str`\n The path of a standard file.\n meas_type : :class:`int`\n The measurement type.\n\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
if (meas_type not in [3, 4, 5]):
raise ValueError('Invalid measurement type {}. Must be 3, 4 or 5'.format(meas_type))
ret = self.lib.LoadStandardFile(path, meas_type)
self._check(ret, (_Error.FILE_IO_FAILED,)) | def load_standard_file(self, path, meas_type):
'Load a standard file.\n\n Parameters\n ----------\n path : :class:`str`\n The path of a standard file.\n meas_type : :class:`int`\n The measurement type.\n\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
if (meas_type not in [3, 4, 5]):
raise ValueError('Invalid measurement type {}. Must be 3, 4 or 5'.format(meas_type))
ret = self.lib.LoadStandardFile(path, meas_type)
self._check(ret, (_Error.FILE_IO_FAILED,))<|docstring|>Load a standard file.
Parameters
----------
path : :class:`str`
The path of a standard file.
meas_type : :class:`int`
The measurement type.
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration<|endoftext|> |
d2a011f48da7776821fba6356aa9ec3f4af32fe484ec5ef6bf433cf3962d8122 | def manual_filter_drive_connect(self, connect):
'Used to connect or disconnect the filter drive.\n\n Disconnecting essentially acquires scans without the filter.\n\n Parameters\n ----------\n connect : :class:`bool`\n Connect or disconnect the filter drive. Reconnecting will\n home the wavelength and filter drive.\n '
ret = self.lib.ManualFilterDriveConnect(connect)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED)) | Used to connect or disconnect the filter drive.
Disconnecting essentially acquires scans without the filter.
Parameters
----------
connect : :class:`bool`
Connect or disconnect the filter drive. Reconnecting will
home the wavelength and filter drive. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_filter_drive_connect | MSLNZ/msl-equipment | 9 | python | def manual_filter_drive_connect(self, connect):
'Used to connect or disconnect the filter drive.\n\n Disconnecting essentially acquires scans without the filter.\n\n Parameters\n ----------\n connect : :class:`bool`\n Connect or disconnect the filter drive. Reconnecting will\n home the wavelength and filter drive.\n '
ret = self.lib.ManualFilterDriveConnect(connect)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED)) | def manual_filter_drive_connect(self, connect):
'Used to connect or disconnect the filter drive.\n\n Disconnecting essentially acquires scans without the filter.\n\n Parameters\n ----------\n connect : :class:`bool`\n Connect or disconnect the filter drive. Reconnecting will\n home the wavelength and filter drive.\n '
ret = self.lib.ManualFilterDriveConnect(connect)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED))<|docstring|>Used to connect or disconnect the filter drive.
Disconnecting essentially acquires scans without the filter.
Parameters
----------
connect : :class:`bool`
Connect or disconnect the filter drive. Reconnecting will
home the wavelength and filter drive.<|endoftext|> |
7358698364c3e9fe204981487a726a8a10f66a87c520301da451a0138e7e88b7 | def manual_get_gain(self):
'The index of the gain that will be applied when the parameters are to be sent down.\n\n Returns\n -------\n :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n '
gain_index = c_short()
mode = c_short()
ret = self.lib.ManualGetGain(byref(gain_index), byref(mode))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return gain_index.value | The index of the gain that will be applied when the parameters are to be sent down.
Returns
-------
:class:`int`
The gain index.
* 0 - 1.0E-5
* 1 - 1.0E-6
* 2 - 1.0E-7
* 3 - 1.0E-8
* 4 - 1.0E-9
* 5 - 1.0E-10 (Point to Point mode only)
* 6 - 1.0E-11 (Point to Point mode only)
* 7 - Auto Gain Ranging (Point to Point mode only) | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_get_gain | MSLNZ/msl-equipment | 9 | python | def manual_get_gain(self):
'The index of the gain that will be applied when the parameters are to be sent down.\n\n Returns\n -------\n :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n '
gain_index = c_short()
mode = c_short()
ret = self.lib.ManualGetGain(byref(gain_index), byref(mode))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return gain_index.value | def manual_get_gain(self):
'The index of the gain that will be applied when the parameters are to be sent down.\n\n Returns\n -------\n :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n '
gain_index = c_short()
mode = c_short()
ret = self.lib.ManualGetGain(byref(gain_index), byref(mode))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return gain_index.value<|docstring|>The index of the gain that will be applied when the parameters are to be sent down.
Returns
-------
:class:`int`
The gain index.
* 0 - 1.0E-5
* 1 - 1.0E-6
* 2 - 1.0E-7
* 3 - 1.0E-8
* 4 - 1.0E-9
* 5 - 1.0E-10 (Point to Point mode only)
* 6 - 1.0E-11 (Point to Point mode only)
* 7 - Auto Gain Ranging (Point to Point mode only)<|endoftext|> |
3b00ea1f612ad108df88f77bafad0fb63040df546297af038ac8d19c27e8ff22 | def manual_get_integration_time(self):
'Returns the integration time set in the system.\n\n Only applies to the integration time used for Point to Point scans.\n\n Returns\n -------\n :class:`float`\n The integration time in seconds.\n '
int_time = c_float()
ret = self.lib.ManualGetIntegrationTime(byref(int_time))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return int_time.value | Returns the integration time set in the system.
Only applies to the integration time used for Point to Point scans.
Returns
-------
:class:`float`
The integration time in seconds. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_get_integration_time | MSLNZ/msl-equipment | 9 | python | def manual_get_integration_time(self):
'Returns the integration time set in the system.\n\n Only applies to the integration time used for Point to Point scans.\n\n Returns\n -------\n :class:`float`\n The integration time in seconds.\n '
int_time = c_float()
ret = self.lib.ManualGetIntegrationTime(byref(int_time))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return int_time.value | def manual_get_integration_time(self):
'Returns the integration time set in the system.\n\n Only applies to the integration time used for Point to Point scans.\n\n Returns\n -------\n :class:`float`\n The integration time in seconds.\n '
int_time = c_float()
ret = self.lib.ManualGetIntegrationTime(byref(int_time))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return int_time.value<|docstring|>Returns the integration time set in the system.
Only applies to the integration time used for Point to Point scans.
Returns
-------
:class:`float`
The integration time in seconds.<|endoftext|> |
632eadeb3bb722d7a69becd0c1f12dde34958a3aedfec195b90f7b47cb5f5494 | def manual_get_pmt_overload(self):
'Returns the PMT overload voltage set in the system.\n\n Returns\n -------\n :class:`float`\n Overload voltage, in volts, of the photomultiplier tube.\n '
overload = c_double()
ret = self.lib.ManualGetPMTOverload(byref(overload))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return overload.value | Returns the PMT overload voltage set in the system.
Returns
-------
:class:`float`
Overload voltage, in volts, of the photomultiplier tube. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_get_pmt_overload | MSLNZ/msl-equipment | 9 | python | def manual_get_pmt_overload(self):
'Returns the PMT overload voltage set in the system.\n\n Returns\n -------\n :class:`float`\n Overload voltage, in volts, of the photomultiplier tube.\n '
overload = c_double()
ret = self.lib.ManualGetPMTOverload(byref(overload))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return overload.value | def manual_get_pmt_overload(self):
'Returns the PMT overload voltage set in the system.\n\n Returns\n -------\n :class:`float`\n Overload voltage, in volts, of the photomultiplier tube.\n '
overload = c_double()
ret = self.lib.ManualGetPMTOverload(byref(overload))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return overload.value<|docstring|>Returns the PMT overload voltage set in the system.
Returns
-------
:class:`float`
Overload voltage, in volts, of the photomultiplier tube.<|endoftext|> |
79c31c73d699ac6d54a22f4d39f7c7dfa22e827b442d4b629e0ae9cae4fb2e86 | def manual_get_pmt_voltage(self):
'Returns the PMT high voltage set in the system.\n\n Returns\n -------\n :class:`float`\n Voltage, in volts, of the photomultiplier tube.\n '
pmt_voltage = c_double()
ret = self.lib.ManualGetPMTVoltage(byref(pmt_voltage))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return pmt_voltage.value | Returns the PMT high voltage set in the system.
Returns
-------
:class:`float`
Voltage, in volts, of the photomultiplier tube. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_get_pmt_voltage | MSLNZ/msl-equipment | 9 | python | def manual_get_pmt_voltage(self):
'Returns the PMT high voltage set in the system.\n\n Returns\n -------\n :class:`float`\n Voltage, in volts, of the photomultiplier tube.\n '
pmt_voltage = c_double()
ret = self.lib.ManualGetPMTVoltage(byref(pmt_voltage))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return pmt_voltage.value | def manual_get_pmt_voltage(self):
'Returns the PMT high voltage set in the system.\n\n Returns\n -------\n :class:`float`\n Voltage, in volts, of the photomultiplier tube.\n '
pmt_voltage = c_double()
ret = self.lib.ManualGetPMTVoltage(byref(pmt_voltage))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return pmt_voltage.value<|docstring|>Returns the PMT high voltage set in the system.
Returns
-------
:class:`float`
Voltage, in volts, of the photomultiplier tube.<|endoftext|> |
e31d03f6ac6304a5c1e840fca7abb1e73e0e25a6fbce187ef225a7f6413596f4 | def manual_get_settling_time(self):
'Returns the settling time of the instrument.\n\n Returns\n -------\n :class:`float`\n Settling time of the system in seconds.\n '
settling_time = c_float()
ret = self.lib.ManualGetSettlingTime(byref(settling_time))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return settling_time.value | Returns the settling time of the instrument.
Returns
-------
:class:`float`
Settling time of the system in seconds. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_get_settling_time | MSLNZ/msl-equipment | 9 | python | def manual_get_settling_time(self):
'Returns the settling time of the instrument.\n\n Returns\n -------\n :class:`float`\n Settling time of the system in seconds.\n '
settling_time = c_float()
ret = self.lib.ManualGetSettlingTime(byref(settling_time))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return settling_time.value | def manual_get_settling_time(self):
'Returns the settling time of the instrument.\n\n Returns\n -------\n :class:`float`\n Settling time of the system in seconds.\n '
settling_time = c_float()
ret = self.lib.ManualGetSettlingTime(byref(settling_time))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return settling_time.value<|docstring|>Returns the settling time of the instrument.
Returns
-------
:class:`float`
Settling time of the system in seconds.<|endoftext|> |
e8857ca635ae8a0c5fc0133f20d097c2c87ce2b1a5f17bca3309cc85d6cb8800 | def manual_get_signal(self):
'Returns the signal at the current position of the wavelength drive.\n\n Returns\n -------\n :class:`float`\n The signal, in amperes.\n '
signal = c_double()
ret = self.lib.ManualGetSignal(byref(signal))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return signal.value | Returns the signal at the current position of the wavelength drive.
Returns
-------
:class:`float`
The signal, in amperes. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_get_signal | MSLNZ/msl-equipment | 9 | python | def manual_get_signal(self):
'Returns the signal at the current position of the wavelength drive.\n\n Returns\n -------\n :class:`float`\n The signal, in amperes.\n '
signal = c_double()
ret = self.lib.ManualGetSignal(byref(signal))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return signal.value | def manual_get_signal(self):
'Returns the signal at the current position of the wavelength drive.\n\n Returns\n -------\n :class:`float`\n The signal, in amperes.\n '
signal = c_double()
ret = self.lib.ManualGetSignal(byref(signal))
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))
return signal.value<|docstring|>Returns the signal at the current position of the wavelength drive.
Returns
-------
:class:`float`
The signal, in amperes.<|endoftext|> |
182b6d6bafcd8b5859120dfb466fc0b9be936d0d2b8fad2264f33cbb095ee12a | def manual_home_ol756(self):
'Homes the wavelength and filter drive.\n\n Will reconnect the filter drive if it was disconnected\n '
ret = self.lib.ManualHomeOL756()
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | Homes the wavelength and filter drive.
Will reconnect the filter drive if it was disconnected | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_home_ol756 | MSLNZ/msl-equipment | 9 | python | def manual_home_ol756(self):
'Homes the wavelength and filter drive.\n\n Will reconnect the filter drive if it was disconnected\n '
ret = self.lib.ManualHomeOL756()
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | def manual_home_ol756(self):
'Homes the wavelength and filter drive.\n\n Will reconnect the filter drive if it was disconnected\n '
ret = self.lib.ManualHomeOL756()
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))<|docstring|>Homes the wavelength and filter drive.
Will reconnect the filter drive if it was disconnected<|endoftext|> |
6ebd04ab94f452e80cc32e6846c9cee0a09da211d6e9e8d168c1cafdcbb69b99 | def manual_move_to_wavelength(self, wavelength):
'Moves the wavelength drive to a particular location.\n\n Parameters\n ----------\n wavelength : :class:`float`\n The wavelength to move the wavelength drive to.\n '
ret = self.lib.ManualMoveToWavelength(wavelength)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_WAVE_RANGE, _Error.PARAM_ERR_ATOD_MODE)) | Moves the wavelength drive to a particular location.
Parameters
----------
wavelength : :class:`float`
The wavelength to move the wavelength drive to. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_move_to_wavelength | MSLNZ/msl-equipment | 9 | python | def manual_move_to_wavelength(self, wavelength):
'Moves the wavelength drive to a particular location.\n\n Parameters\n ----------\n wavelength : :class:`float`\n The wavelength to move the wavelength drive to.\n '
ret = self.lib.ManualMoveToWavelength(wavelength)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_WAVE_RANGE, _Error.PARAM_ERR_ATOD_MODE)) | def manual_move_to_wavelength(self, wavelength):
'Moves the wavelength drive to a particular location.\n\n Parameters\n ----------\n wavelength : :class:`float`\n The wavelength to move the wavelength drive to.\n '
ret = self.lib.ManualMoveToWavelength(wavelength)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_WAVE_RANGE, _Error.PARAM_ERR_ATOD_MODE))<|docstring|>Moves the wavelength drive to a particular location.
Parameters
----------
wavelength : :class:`float`
The wavelength to move the wavelength drive to.<|endoftext|> |
622419e7302a804c2cc772b061f584bb3a1d26a0d7aab992f28fb9690af59177 | def manual_set_gain(self, gain_index, mode):
'Set the gain.\n\n Parameters\n ----------\n gain_index : :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n mode : :class:`int`\n The scan mode\n\n * 0 - point to point\n * 1 - quick scan\n '
ret = self.lib.ManualSetGain(gain_index, mode)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE, _Error.PARAM_ERR_SCAN_MODE, _Error.PARAM_ERR_GAIN)) | Set the gain.
Parameters
----------
gain_index : :class:`int`
The gain index.
* 0 - 1.0E-5
* 1 - 1.0E-6
* 2 - 1.0E-7
* 3 - 1.0E-8
* 4 - 1.0E-9
* 5 - 1.0E-10 (Point to Point mode only)
* 6 - 1.0E-11 (Point to Point mode only)
* 7 - Auto Gain Ranging (Point to Point mode only)
mode : :class:`int`
The scan mode
* 0 - point to point
* 1 - quick scan | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_set_gain | MSLNZ/msl-equipment | 9 | python | def manual_set_gain(self, gain_index, mode):
'Set the gain.\n\n Parameters\n ----------\n gain_index : :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n mode : :class:`int`\n The scan mode\n\n * 0 - point to point\n * 1 - quick scan\n '
ret = self.lib.ManualSetGain(gain_index, mode)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE, _Error.PARAM_ERR_SCAN_MODE, _Error.PARAM_ERR_GAIN)) | def manual_set_gain(self, gain_index, mode):
'Set the gain.\n\n Parameters\n ----------\n gain_index : :class:`int`\n The gain index.\n\n * 0 - 1.0E-5\n * 1 - 1.0E-6\n * 2 - 1.0E-7\n * 3 - 1.0E-8\n * 4 - 1.0E-9\n * 5 - 1.0E-10 (Point to Point mode only)\n * 6 - 1.0E-11 (Point to Point mode only)\n * 7 - Auto Gain Ranging (Point to Point mode only)\n\n mode : :class:`int`\n The scan mode\n\n * 0 - point to point\n * 1 - quick scan\n '
ret = self.lib.ManualSetGain(gain_index, mode)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE, _Error.PARAM_ERR_SCAN_MODE, _Error.PARAM_ERR_GAIN))<|docstring|>Set the gain.
Parameters
----------
gain_index : :class:`int`
The gain index.
* 0 - 1.0E-5
* 1 - 1.0E-6
* 2 - 1.0E-7
* 3 - 1.0E-8
* 4 - 1.0E-9
* 5 - 1.0E-10 (Point to Point mode only)
* 6 - 1.0E-11 (Point to Point mode only)
* 7 - Auto Gain Ranging (Point to Point mode only)
mode : :class:`int`
The scan mode
* 0 - point to point
* 1 - quick scan<|endoftext|> |
8ee31626ef4eaa97091666cbfda0d7067179c7e5a3be2da916c7214c597ecbfb | def manual_set_integration_time(self, time):
'Sets the integration time set in the system.\n\n Only applies to the integration time used for Point to Point scans.\n\n Parameters\n ----------\n time : :class:`float`\n The integration time in seconds.\n '
ret = self.lib.ManualSetIntegrationTime(time)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | Sets the integration time set in the system.
Only applies to the integration time used for Point to Point scans.
Parameters
----------
time : :class:`float`
The integration time in seconds. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_set_integration_time | MSLNZ/msl-equipment | 9 | python | def manual_set_integration_time(self, time):
'Sets the integration time set in the system.\n\n Only applies to the integration time used for Point to Point scans.\n\n Parameters\n ----------\n time : :class:`float`\n The integration time in seconds.\n '
ret = self.lib.ManualSetIntegrationTime(time)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | def manual_set_integration_time(self, time):
'Sets the integration time set in the system.\n\n Only applies to the integration time used for Point to Point scans.\n\n Parameters\n ----------\n time : :class:`float`\n The integration time in seconds.\n '
ret = self.lib.ManualSetIntegrationTime(time)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))<|docstring|>Sets the integration time set in the system.
Only applies to the integration time used for Point to Point scans.
Parameters
----------
time : :class:`float`
The integration time in seconds.<|endoftext|> |
ca096b5ec5288ca487f85046a62b035445b46fa1f2a82b67ccd2e1d32ad39c74 | def manual_set_pmt_overload(self, overload):
'Sets the PMT overload voltage set in the system.\n\n Parameters\n ----------\n overload : :class:`float`\n Overload voltage, in volts, of the photomultiplier tube in Volts.\n '
ret = self.lib.ManualSetPMTOverload(overload)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | Sets the PMT overload voltage set in the system.
Parameters
----------
overload : :class:`float`
Overload voltage, in volts, of the photomultiplier tube in Volts. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_set_pmt_overload | MSLNZ/msl-equipment | 9 | python | def manual_set_pmt_overload(self, overload):
'Sets the PMT overload voltage set in the system.\n\n Parameters\n ----------\n overload : :class:`float`\n Overload voltage, in volts, of the photomultiplier tube in Volts.\n '
ret = self.lib.ManualSetPMTOverload(overload)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | def manual_set_pmt_overload(self, overload):
'Sets the PMT overload voltage set in the system.\n\n Parameters\n ----------\n overload : :class:`float`\n Overload voltage, in volts, of the photomultiplier tube in Volts.\n '
ret = self.lib.ManualSetPMTOverload(overload)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))<|docstring|>Sets the PMT overload voltage set in the system.
Parameters
----------
overload : :class:`float`
Overload voltage, in volts, of the photomultiplier tube in Volts.<|endoftext|> |
0e5f618f5ed278936f055599a4bc5ffd4e71e400836aa2de4424ea5cfeaea53b | def manual_set_pmt_voltage(self, voltage):
'Sets the PMT high voltage set in the system.\n\n Parameters\n ----------\n voltage : :class:`float`\n Voltage, in volts, of the photomultiplier tube.\n '
ret = self.lib.ManualSetPMTVoltage(voltage)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | Sets the PMT high voltage set in the system.
Parameters
----------
voltage : :class:`float`
Voltage, in volts, of the photomultiplier tube. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_set_pmt_voltage | MSLNZ/msl-equipment | 9 | python | def manual_set_pmt_voltage(self, voltage):
'Sets the PMT high voltage set in the system.\n\n Parameters\n ----------\n voltage : :class:`float`\n Voltage, in volts, of the photomultiplier tube.\n '
ret = self.lib.ManualSetPMTVoltage(voltage)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | def manual_set_pmt_voltage(self, voltage):
'Sets the PMT high voltage set in the system.\n\n Parameters\n ----------\n voltage : :class:`float`\n Voltage, in volts, of the photomultiplier tube.\n '
ret = self.lib.ManualSetPMTVoltage(voltage)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))<|docstring|>Sets the PMT high voltage set in the system.
Parameters
----------
voltage : :class:`float`
Voltage, in volts, of the photomultiplier tube.<|endoftext|> |
09221952e32f58c2c4a0107622439fb0be35f15399736c2bcedd86dbff0c546d | def manual_set_settling_time(self, time):
'Sets the settling time of the instrument.\n\n Parameters\n ----------\n time : :class:`float`\n Settling time of the system.\n '
ret = self.lib.ManualSetSettlingTime(time)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | Sets the settling time of the instrument.
Parameters
----------
time : :class:`float`
Settling time of the system. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | manual_set_settling_time | MSLNZ/msl-equipment | 9 | python | def manual_set_settling_time(self, time):
'Sets the settling time of the instrument.\n\n Parameters\n ----------\n time : :class:`float`\n Settling time of the system.\n '
ret = self.lib.ManualSetSettlingTime(time)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE)) | def manual_set_settling_time(self, time):
'Sets the settling time of the instrument.\n\n Parameters\n ----------\n time : :class:`float`\n Settling time of the system.\n '
ret = self.lib.ManualSetSettlingTime(time)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.PARAM_ERR_ATOD_MODE))<|docstring|>Sets the settling time of the instrument.
Parameters
----------
time : :class:`float`
Settling time of the system.<|endoftext|> |
901770400c0ad63f3204abaa04d7d87fc6257bb008e1593e967d17c4f13e6c50 | def move_to_wavelength(self, wavelength):
'Moves the wavelength drive to a particular location.\n\n Parameters\n ----------\n wavelength : :class:`float`\n The wavelength, in nanometers, to move the wavelength drive to.\n '
ret = self.lib.MoveToWavelength(wavelength)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_WAVE_RANGE)) | Moves the wavelength drive to a particular location.
Parameters
----------
wavelength : :class:`float`
The wavelength, in nanometers, to move the wavelength drive to. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | move_to_wavelength | MSLNZ/msl-equipment | 9 | python | def move_to_wavelength(self, wavelength):
'Moves the wavelength drive to a particular location.\n\n Parameters\n ----------\n wavelength : :class:`float`\n The wavelength, in nanometers, to move the wavelength drive to.\n '
ret = self.lib.MoveToWavelength(wavelength)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_WAVE_RANGE)) | def move_to_wavelength(self, wavelength):
'Moves the wavelength drive to a particular location.\n\n Parameters\n ----------\n wavelength : :class:`float`\n The wavelength, in nanometers, to move the wavelength drive to.\n '
ret = self.lib.MoveToWavelength(wavelength)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_WAVE_RANGE))<|docstring|>Moves the wavelength drive to a particular location.
Parameters
----------
wavelength : :class:`float`
The wavelength, in nanometers, to move the wavelength drive to.<|endoftext|> |
ade7dcc15b64e1cb8aee81c3172da9d3970131211d288ccf3537a914c534090a | def read_ol756_flash_settings(self):
'Reads the saved settings from the flash memory.\n\n Reads the settings such as the grating alignment factor, filter skew\n and wavelength skew. Loads these values into the ActiveX control memory.\n '
ret = self.lib.ReadOL756FlashSettings()
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.FLASH_READ_ERROR)) | Reads the saved settings from the flash memory.
Reads the settings such as the grating alignment factor, filter skew
and wavelength skew. Loads these values into the ActiveX control memory. | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | read_ol756_flash_settings | MSLNZ/msl-equipment | 9 | python | def read_ol756_flash_settings(self):
'Reads the saved settings from the flash memory.\n\n Reads the settings such as the grating alignment factor, filter skew\n and wavelength skew. Loads these values into the ActiveX control memory.\n '
ret = self.lib.ReadOL756FlashSettings()
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.FLASH_READ_ERROR)) | def read_ol756_flash_settings(self):
'Reads the saved settings from the flash memory.\n\n Reads the settings such as the grating alignment factor, filter skew\n and wavelength skew. Loads these values into the ActiveX control memory.\n '
ret = self.lib.ReadOL756FlashSettings()
self._check(ret, (_Error.SYSTEM_BUSY, _Error.SYSTEM_NOT_CONNECTED, _Error.FLASH_READ_ERROR))<|docstring|>Reads the saved settings from the flash memory.
Reads the settings such as the grating alignment factor, filter skew
and wavelength skew. Loads these values into the ActiveX control memory.<|endoftext|> |
e3186d6697d422b75090c6194b3283c11c162cc1def072999e311040505ae477 | def reset_averaging(self, meas_type):
'Resets the accumulated signal array for the specified measurement type.\n\n This function is used in combination with :meth:`.do_averaging`\n and :meth:`.accumulate_signals`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.ResetAveraging(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE)) | Resets the accumulated signal array for the specified measurement type.
This function is used in combination with :meth:`.do_averaging`
and :meth:`.accumulate_signals`.
Parameters
----------
meas_type : :class:`int`
The measurement type.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration | msl/equipment/resources/optronic_laboratories/ol756ocx_32.py | reset_averaging | MSLNZ/msl-equipment | 9 | python | def reset_averaging(self, meas_type):
'Resets the accumulated signal array for the specified measurement type.\n\n This function is used in combination with :meth:`.do_averaging`\n and :meth:`.accumulate_signals`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.ResetAveraging(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE)) | def reset_averaging(self, meas_type):
'Resets the accumulated signal array for the specified measurement type.\n\n This function is used in combination with :meth:`.do_averaging`\n and :meth:`.accumulate_signals`.\n\n Parameters\n ----------\n meas_type : :class:`int`\n The measurement type.\n\n * 0 - Irradiance\n * 1 - Radiance\n * 2 - Transmittance\n * 3 - Irradiance Calibration\n * 4 - Radiance Calibration\n * 5 - Transmittance Calibration\n\n '
ret = self.lib.ResetAveraging(meas_type)
self._check(ret, (_Error.SYSTEM_BUSY, _Error.PARAM_ERR_MEASTYPE))<|docstring|>Resets the accumulated signal array for the specified measurement type.
This function is used in combination with :meth:`.do_averaging`
and :meth:`.accumulate_signals`.
Parameters
----------
meas_type : :class:`int`
The measurement type.
* 0 - Irradiance
* 1 - Radiance
* 2 - Transmittance
* 3 - Irradiance Calibration
* 4 - Radiance Calibration
* 5 - Transmittance Calibration<|endoftext|> |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.