You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
首先就是,无论我是py3.9还是py3.8的环境,均会报错Traceback (most recent call last):
File "test.py", line 4, in
from task import Task
File "C:\Users\80564\Desktop\VeryFL-main\task.py", line 13, in
from dataset.DatasetSpliter import DatasetSpliter
File "C:\Users\80564\Desktop\VeryFL-main\dataset\DatasetSpliter.py", line 11, in
class DatasetSpliter:
File "C:\Users\80564\Desktop\VeryFL-main\dataset\DatasetSpliter.py", line 49, in DatasetSpliter
def dirichlet_split(self, dataset: Dataset, client_list: dict, batch_size: int = 32, alpha: int = 1) -> dict[DataLoader]: TypeError: 'type' object is not subscriptable
GPT说py3.9这个-> dict[DataLoader]注释语法是正确的,不应该会报错,莫名其妙。
鉴于其为注释语法,删除后继续尝试运行,又会报错Traceback (most recent call last):
File "test.py", line 8, in
set_log_config()
File "C:\Users\80564\Desktop\VeryFL-main\config\log.py", line 24, in set_log_config
logging.basicConfig(filename = get_file_name(),
File "D:\anaconda3\envs\FLL\lib\logging_init_.py", line 1988, in basicConfig
h = FileHandler(filename, mode)
File "D:\anaconda3\envs\FLL\lib\logging_init_.py", line 1147, in init
StreamHandler.init(self, self.open())
File "D:\anaconda3\envs\FLL\lib\logging_init.py", line 1176, in open
return open(self.baseFilename, self.mode, encoding=self.encoding)
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\80564\Desktop\VeryFL-main\log\2024_08_11_0.log',看起来是找不到log日志文件夹,遂手动目录中新建一个文件夹,之后运行,仍然报错如下。。。。
Traceback (most recent call last):
File "test.py", line 8, in
set_log_config()
File "C:\Users\80564\Desktop\VeryFL-main\config\log.py", line 24, in set_log_config
logging.basicConfig(filename = get_file_name(),
File "D:\anaconda3\envs\FLL\lib\logging_init.py", line 2009, in basicConfig
raise ValueError('Unrecognised argument(s): %s' % keys)
ValueError: Unrecognised argument(s): encoding
真是让人莫名其妙又头大,gpt4也无法解决
The text was updated successfully, but these errors were encountered:
首先就是,无论我是py3.9还是py3.8的环境,均会报错Traceback (most recent call last):
File "test.py", line 4, in
from task import Task
File "C:\Users\80564\Desktop\VeryFL-main\task.py", line 13, in
from dataset.DatasetSpliter import DatasetSpliter
File "C:\Users\80564\Desktop\VeryFL-main\dataset\DatasetSpliter.py", line 11, in
class DatasetSpliter:
File "C:\Users\80564\Desktop\VeryFL-main\dataset\DatasetSpliter.py", line 49, in DatasetSpliter
def dirichlet_split(self, dataset: Dataset, client_list: dict, batch_size: int = 32, alpha: int = 1) -> dict[DataLoader]:
TypeError: 'type' object is not subscriptable
GPT说py3.9这个-> dict[DataLoader]注释语法是正确的,不应该会报错,莫名其妙。
鉴于其为注释语法,删除后继续尝试运行,又会报错Traceback (most recent call last):
File "test.py", line 8, in
set_log_config()
File "C:\Users\80564\Desktop\VeryFL-main\config\log.py", line 24, in set_log_config
logging.basicConfig(filename = get_file_name(),
File "D:\anaconda3\envs\FLL\lib\logging_init_.py", line 1988, in basicConfig
h = FileHandler(filename, mode)
File "D:\anaconda3\envs\FLL\lib\logging_init_.py", line 1147, in init
StreamHandler.init(self, self.open())
File "D:\anaconda3\envs\FLL\lib\logging_init.py", line 1176, in open
return open(self.baseFilename, self.mode, encoding=self.encoding)
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\80564\Desktop\VeryFL-main\log\2024_08_11_0.log',看起来是找不到log日志文件夹,遂手动目录中新建一个文件夹,之后运行,仍然报错如下。。。。
Traceback (most recent call last):
File "test.py", line 8, in
set_log_config()
File "C:\Users\80564\Desktop\VeryFL-main\config\log.py", line 24, in set_log_config
logging.basicConfig(filename = get_file_name(),
File "D:\anaconda3\envs\FLL\lib\logging_init.py", line 2009, in basicConfig
raise ValueError('Unrecognised argument(s): %s' % keys)
ValueError: Unrecognised argument(s): encoding
真是让人莫名其妙又头大,gpt4也无法解决
The text was updated successfully, but these errors were encountered: