Error saying ''Dot Indexing is not supported for variables of this type".

조회 수: 17(최근 30일)
Iam studying about ''Unsupervised Day to Dusk image translation using UNIT''.Source code is given in below link.
I executed the code in MATLAB R2022a.While training It shows me an error indicating "Dot indexing is not supported for variables of this type" in adamupdate built-in function (line 152) , deep.internal.networkContainerFixedArgsFun (line 29) and in deep.internal.recording.containerfeval ((line 38,194,358,460). So I analzed all functions and guessed that the actual error is in line 460 and I have attached the corresponding code below. I tried to resolve the error by modifying the below code but it shows "Access denied".
function args = iTablesToCells(args)
% Convert a set of tables to cell arrays of arguments.
if ~isempty(args)
% Extract Value cell arrays from inputs
for input=1:numel(args)
args{input} = args{input}.Value;
So I can't able to modify the built-in source code "deep.internal.recording.containerfeval" (This function is called inside "deep.internal.networkContainerFixedArgsFun" and this "deep.internal.networkContainerFixedArgsFun" function is called inside adamupdate function). Please tell me where the actual error resides and help me in resolving the above stated error.
  댓글 수: 6

댓글을 달려면 로그인하십시오.


Image Analyst
Image Analyst 2022년 12월 5일
편집: Image Analyst 2022년 12월 5일
@Sowparnika and @Sowparnika R S It doesn't make any sense to have a function to extract contents/variables out of a cell array, args, just to put it back in the same cell array as output.
You need to know what to expect. For example if args contains an image, and optionally a threshold value, then you could do this:
function [imageArray, thresholdValue] = iTablesToCells(args)
% Convert a set of tables to cell arrays of arguments.
% Initialize.
imageArray = [];
thresholdValue = 0;
if isempty(args)
if numel(args) >= 1
% Extract the image array out of the first cell.
imageArray = args{1};
if numel(args) >= 2
% Extract the threshold value out of the second cell.
thresholdValue = args{2};
DON'T use input, or any other built-in function name as the name for one of your variables.

Joss Knight
Joss Knight 2022년 12월 17일
This could be a bug, especially if you didn't modify the example code. What is the data you passed to adamupdate?
  댓글 수: 11

댓글을 달려면 로그인하십시오.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by