Coder Social home page Coder Social logo

huantwang / funded_nisl Goto Github PK

View Code? Open in Web Editor NEW
116.0 7.0 36.0 130.91 MB

FUNDED is a novel learning framework for building vulnerability detection models.

C 0.09% Java 24.57% Python 45.19% Shell 10.67% Batchfile 7.41% Scala 12.07%
vulnerability-detection datacollection machine-learning graphneuralnetwork

funded_nisl's People

Contributors

garyhf avatar huantwang avatar jie-2000 avatar xiao1i avatar xiao1ii avatar xxrz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

funded_nisl's Issues

May I get your email?

I have some questions about Java program preprocessing that I want to communicate with you. 😀

Data Preprocessing for Java is not available

Artifact to generate the edges for Java is missing.

It is mentioned in the paper, the authors are using Soot. In the readme, it is mentioned edges are constructed using Soot and JDT.

Unfortunately, we do not find the artifacts for generating edges are available in the repository.

Are you planning to share them?

Can't find java and php related processing programs

I can't find any java and php related processing programs. Do c/c++, java, and php use the same Main.java file?

$ cd NISL_TIFS2021/EdgesGenerationAndDataPreprocess/Java_jdt_AST_CDFG/src/main/java/yoshikihigo/tinypdg/
$ java Main.java sourceFilePath savafilePath

$ cd NISL_TIFS2021/EdgesGenerationAndDataPreprocess/php_swift/src/php/main
$ java TestPhp.java sourceFilePath savafilePath

$ cd NISL_TIFS2021/EdgesGenerationAndDataPreprocess/php_swift/src/swift3/main
$ java TestSwift3.java sourceFilePath savafilePath

Adjusting batch size

I meet the problem

tensorflow.python.framework.errors_impl.InternalError:  Blas GEMM launch failed : a.shape=(1451673, 100), b.shape=(100, 16), m=1451673, n=16, k=100
         [[node dense_1/MatMul (defined at /home/wj/anaconda3/envs/funded/lib/python3.7/site-packages/tensorflow_core/python/framework/ops.py:1751) ]] [Op:__forward__internal_call_7111]

I have checked TensorFlow and Cuda, and I believe it is due to insufficient graphics memory

Can't pickle local object 'DoubleBufferedIterator._

I met a problem: Can't pickle local object 'DoubleBufferedIterator._
env:cuda10.0 cudnn7.4.1 GPURTX 3090 x1

console output

2022-03-27 11:30:04.495748: W tensorflow/core/framework/op_kernel.cc:1610] Unknown: AttributeError: Can't pickle local object 'DoubleBufferedIterator.__init__.<locals>.<lambda>'
Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 464, in get_iterator
    return self._iterators[iterator_id]

KeyError: 0


During handling of the above exception, another exception occurred:


Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\ops\script_ops.py", line 221, in __call__
    ret = func(*args)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 585, in generator_py_func
    values = next(generator_state.get_iterator(iterator_id))

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 466, in get_iterator
    iterator = iter(self._generator(*self._args.pop(iterator_id)))

  File "E:\FUNDED\FUNDED\data\graph_dataset.py", line 216, in <lambda>
    self.graph_batch_iterator(data_fold)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\dpu_utils\utils\iterators.py", line 148, in __init__
    self.__worker_process_inner.start()

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\process.py", line 112, in start
    self._popen = self._Popen(self)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\context.py", line 223, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\context.py", line 322, in _Popen
    return Popen(process_obj)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\popen_spawn_win32.py", line 65, in __init__
    reduction.dump(process_obj, to_child)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)

AttributeError: Can't pickle local object 'DoubleBufferedIterator.__init__.<locals>.<lambda>'


2022-03-27 11:30:04.496721: W tensorflow/core/framework/op_kernel.cc:1622] OP_REQUIRES failed at iterator_ops.cc:929 : Unknown: AttributeError: Can't pickle local object 'DoubleBufferedIterator.__init__.<locals>.<lambda>'
Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 464, in get_iterator
    return self._iterators[iterator_id]

KeyError: 0


During handling of the above exception, another exception occurred:


Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\ops\script_ops.py", line 221, in __call__
    ret = func(*args)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 585, in generator_py_func
    values = next(generator_state.get_iterator(iterator_id))

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 466, in get_iterator
    iterator = iter(self._generator(*self._args.pop(iterator_id)))

  File "E:\FUNDED\FUNDED\data\graph_dataset.py", line 216, in <lambda>
    self.graph_batch_iterator(data_fold)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\dpu_utils\utils\iterators.py", line 148, in __init__
    self.__worker_process_inner.start()

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\process.py", line 112, in start
    self._popen = self._Popen(self)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\context.py", line 223, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\context.py", line 322, in _Popen
    return Popen(process_obj)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\popen_spawn_win32.py", line 65, in __init__
    reduction.dump(process_obj, to_child)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)

AttributeError: Can't pickle local object 'DoubleBufferedIterator.__init__.<locals>.<lambda>'


         [[{{node PyFunc}}]]
2022-03-27 11:30:04.497356: W tensorflow/core/framework/op_kernel.cc:1610] Unknown: KeyError: 0
Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 464, in get_iterator
    return self._iterators[iterator_id]

KeyError: 0


During handling of the above exception, another exception occurred:


Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\ops\script_ops.py", line 221, in __call__
    ret = func(*args)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 585, in generator_py_func
    values = next(generator_state.get_iterator(iterator_id))

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 466, in get_iterator
    iterator = iter(self._generator(*self._args.pop(iterator_id)))

KeyError: 0


Traceback (most recent call last):
  File "train.py", line 62, in <module>
    run()
  File "train.py", line 37, in run
2022-03-27 11:30:04.502260: W tensorflow/core/framework/op_kernel.cc:1610] Unknown: KeyError: 0
Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 464, in get_iterator
    return self._iterators[iterator_id]

KeyError: 0


During handling of the above exception, another exception occurred:


Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\ops\script_ops.py", line 221, in __call__
    ret = func(*args)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 585, in generator_py_func
    values = next(generator_state.get_iterator(iterator_id))

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 466, in get_iterator
    iterator = iter(self._generator(*self._args.pop(iterator_id)))

KeyError: 0


    lambda: run_train_from_args(args, hyperdrive_hyperparameter_overrides), args.debug
  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\dpu_utils\utils\debughelper.py", line 21, in run_and_debug
2022-03-27 11:30:04.503196: W tensorflow/core/framework/op_kernel.cc:1610] Unknown: KeyError: 0
Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 464, in get_iterator
    return self._iterators[iterator_id]

KeyError: 0


During handling of the above exception, another exception occurred:


Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\ops\script_ops.py", line 221, in __call__
    ret = func(*args)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 585, in generator_py_func
    values = next(generator_state.get_iterator(iterator_id))

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 466, in get_iterator
    iterator = iter(self._generator(*self._args.pop(iterator_id)))

KeyError: 0


    func()
  File "train.py", line 37, in <lambda>
    lambda: run_train_from_args(args, hyperdrive_hyperparameter_overrides), args.debug
  File "E:\FUNDED\FUNDED\cli_utils\training_utils.py", line 219, in run_train_from_args
    aml_run=aml_run,
  File "E:\FUNDED\FUNDED\cli_utils\training_utils.py", line 59, in train
    _, _, initial_valid_results = model.run_one_epoch_new(train_data,train_data_2, training=False, quiet=quiet)
  File "E:\FUNDED\FUNDED\models\graph_task_model.py", line 318, in run_one_epoch_new
    for ((step, (batch_features, batch_labels)),(step_2, (batch_features_2, batch_labels_2))) in zip(enumerate(dataset),enumerate(dataset2)):
  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\iterator_ops.py", line 622, in __next__
    return self.next()
  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\iterator_ops.py", line 666, in next
    return self._next_internal()
  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\iterator_ops.py", line 651, in _next_internal
    output_shapes=self._flat_output_shapes)
  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\ops\gen_dataset_ops.py", line 2673, in iterator_get_next_sync
    _six.raise_from(_core._status_to_exception(e.code, message), None)
  File "<string>", line 3, in raise_from
tensorflow.python.framework.errors_impl.UnknownError: AttributeError: Can't pickle local object 'DoubleBufferedIterator.__init__.<locals>.<lambda>'
Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 464, in get_iterator
    return self._iterators[iterator_id]

KeyError: 0


During handling of the above exception, another exception occurred:


Traceback (most recent call last):

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\ops\script_ops.py", line 221, in __call__
    ret = func(*args)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 585, in generator_py_func
    values = next(generator_state.get_iterator(iterator_id))

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\tensorflow_core\python\data\ops\dataset_ops.py", line 466, in get_iterator
    iterator = iter(self._generator(*self._args.pop(iterator_id)))

  File "E:\FUNDED\FUNDED\data\graph_dataset.py", line 216, in <lambda>
    self.graph_batch_iterator(data_fold)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\site-packages\dpu_utils\utils\iterators.py", line 148, in __init__
    self.__worker_process_inner.start()

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\process.py", line 112, in start
    self._popen = self._Popen(self)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\context.py", line 223, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\context.py", line 322, in _Popen
    return Popen(process_obj)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\popen_spawn_win32.py", line 65, in __init__
    reduction.dump(process_obj, to_child)

  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)

AttributeError: Can't pickle local object 'DoubleBufferedIterator.__init__.<locals>.<lambda>'


         [[{{node PyFunc}}]] [Op:IteratorGetNextSync]
2022-03-27 11:30:05.779555: W tensorflow/core/kernels/data/generator_dataset_op.cc:102] Error occurred when finalizing GeneratorDataset iterator: Failed precondition: Python interpreter state is not initialized. The process may be terminated.
         [[{{node PyFunc}}]]
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\spawn.py", line 105, in spawn_main
    exitcode = _main(fd)
  File "D:\ProgramData\Anaconda3\envs\funded\lib\multiprocessing\spawn.py", line 115, in _main
    self = reduction.pickle.load(from_parent)
EOFError: Ran out of input

cpg.runScript error

I have modified the generated result path in graph/all.sc
3IPB~4E7V RT@ _M)}4`BNU
I could not find a similar problem online,How could I solve it?

the bug:ValueError: setting an array element with a sequence.

When I try to run the command $ CUDA_VISIBLE_DEVICES=2 python train.py GGNN GraphBinaryClassification ../data/data/CWE-77
I encountered the following error:
Invalid argument: TypeError: generator yielded an element that could not be converted to the expected type. The expected type was float32, but the yielded element was [list([0.5488135039273248, 0.7151893663724195, 0.6027633760716439, 0.5448831829968969, 0.4236547993389047, 0.6458941130666561, 0.4375872112626925, 0.8917730007820798, 0.9636627605010293, 0.3834415188257777, 0.7917250380826646, 0.5288949197529045, 0.5680445610939323, 0.925596638292661, 0.07103605819788694, 0.08712929970154071, 0.02021839744032572, 0.832619845547938, 0.7781567509498505, 0.8700121482468192, 0.978618342232764, 0.7991585642167236, 0.46147936225293185, 0.7805291762864555, 0.11827442586893322, 0.6399210213275238, 0.1433532874090464, 0.9446689170495839, 0.5218483217500717, 0.4146619399905236, 0.26455561210462697, 0.7742336894342167, 0.45615033221654855, 0.5684339488686485, 0.018789800436355142, 0.6176354970758771, 0.6120957227224214, 0.6169339968747569, 0.9437480785146242, 0.6818202991034834, 0.359507900573786, 0.43703195379934145, 0.6976311959272649, 0.06022547162926983, 0.6667667154456677, 0.6706378696181594, 0.2103825610738409, 0.1289262976548533, 0.31542835092418386, 0.3637107709426226, 0.5701967704178796, 0.43860151346232035, 0.9883738380592262, 0.10204481074802807, 0.2088767560948347, 0.16130951788499626, 0.6531083254653984, 0.2532916025397821, 0.4663107728563063, 0.24442559200160274, 0.15896958364551972, 0.11037514116430513, 0.6563295894652734, 0.1381829513486138, 0.1965823616800535, 0.3687251706609641, 0.8209932298479351, 0.09710127579306127, 0.8379449074988039, 0.09609840789396307, 0.9764594650133958, 0.4686512016477016, 0.9767610881903371, 0.604845519745046, 0.7392635793983017, 0.039187792254320675, 0.2828069625764096, 0.1201965612131689, 0.29614019752214493, 0.11872771895424405, 0.317983179393976, 0.41426299451466997, 0.06414749634878436, 0.6924721193700198, 0.5666014542065752, 0.2653894909394454, 0.5232480534666997, 0.09394051075844168, 0.5759464955561793, 0.9292961975762141, 0.31856895245132366, 0.6674103799636817, 0.13179786240439217, 0.7163272041185655, 0.2894060929472011, 0.18319136200711683, 0.5865129348100832, 0.020107546187493552, 0.8289400292173631, 0.004695476192547066])
list([0.5488135039273248, 0.7151893663724195, 0.6027633760716439, 0.5448831829968969, 0.4236547993389047, 0.6458941130666561, 0.4375872112626925, 0.8917730007820798, 0.9636627605010293, 0.3834415188257777, 0.7917250380826646, 0.5288949197529045, 0.5680445610939323, 0.925596638292661, 0.07103605819788694, 0.08712929970154071, 0.02021839744032572, 0.832619845547938, 0.7781567509498505, 0.8700121482468192, 0.978618342232764, 0.7991585642167236, 0.46147936225293185, 0.7805291762864555, 0.11827442586893322, 0.6399210213275238, 0.1433532874090464, 0.9446689170495839, 0.5218483217500717, 0.4146619399905236, 0.26455561210462697, 0.7742336894342167, 0.45615033221654855, 0.5684339488686485, 0.018789800436355142, 0.6176354970758771, 0.6120957227224214, 0.6169339968747569, 0.9437480785146242, 0.6818202991034834, 0.359507900573786, 0.43703195379934145, 0.6976311959272649, 0.06022547162926983, 0.6667667154456677, 0.6706378696181594, 0.2103825610738409, 0.1289262976548533, 0.31542835092418386, 0.3637107709426226, 0.5701967704178796, 0.43860151346232035, 0.9883738380592262, 0.10204481074802807, 0.2088767560948347, 0.16130951788499626, 0.6531083254653984, 0.2532916025397821, 0.4663107728563063, 0.24442559200160274, 0.15896958364551972, 0.11037514116430513, 0.6563295894652734, 0.1381829513486138, 0.1965823616800535, 0.3687251706609641, 0.8209932298479351, 0.09710127579306127, 0.8379449074988039, 0.09609840789396307, 0.9764594650133958, 0.4686512016477016, 0.9767610881903371, 0.604845519745046, 0.7392635793983017, 0.039187792254320675, 0.2828069625764096, 0.1201965612131689, 0.29614019752214493, 0.11872771895424405, 0.317983179393976, 0.41426299451466997, 0.06414749634878436, 0.6924721193700198, 0.5666014542065752, 0.2653894909394454, 0.5232480534666997, 0.09394051075844168, 0.5759464955561793, 0.9292961975762141, 0.31856895245132366, 0.6674103799636817, 0.13179786240439217, 0.7163272041185655, 0.2894060929472011, 0.18319136200711683, 0.5865129348100832, 0.020107546187493552, 0.8289400292173631, 0.004695476192547066])
list([0.5488135039273248, 0.7151893663724195, 0.6027633760716439, 0.5448831829968969, 0.4236547993389047, 0.6458941130666561, 0.4375872112626925, 0.8917730007820798, 0.9636627605010293, 0.3834415188257777, 0.7917250380826646, 0.5288949197529045, 0.5680445610939323, 0.925596638292661, 0.07103605819788694, 0.08712929970154071, 0.02021839744032572, 0.832619845547938, 0.7781567509498505, 0.8700121482468192, 0.978618342232764, 0.7991585642167236, 0.46147936225293185, 0.7805291762864555, 0.11827442586893322, 0.6399210213275238, 0.1433532874090464, 0.9446689170495839, 0.5218483217500717, 0.4146619399905236, 0.26455561210462697, 0.7742336894342167, 0.45615033221654855, 0.5684339488686485, 0.018789800436355142, 0.6176354970758771, 0.6120957227224214, 0.6169339968747569, 0.9437480785146242, 0.6818202991034834, 0.359507900573786, 0.43703195379934145, 0.6976311959272649, 0.06022547162926983, 0.6667667154456677, 0.6706378696181594, 0.2103825610738409, 0.1289262976548533, 0.31542835092418386, 0.3637107709426226, 0.5701967704178796, 0.43860151346232035, 0.9883738380592262, 0.10204481074802807, 0.2088767560948347, 0.16130951788499626, 0.6531083254653984, 0.2532916025397821, 0.4663107728563063, 0.24442559200160274, 0.15896958364551972, 0.11037514116430513, 0.6563295894652734, 0.1381829513486138, 0.1965823616800535, 0.3687251706609641, 0.8209932298479351, 0.09710127579306127, 0.8379449074988039, 0.09609840789396307, 0.9764594650133958, 0.4686512016477016, 0.9767610881903371, 0.604845519745046, 0.7392635793983017, 0.039187792254320675, 0.2828069625764096, 0.1201965612131689, 0.29614019752214493, 0.11872771895424405, 0.317983179393976, 0.41426299451466997, 0.06414749634878436, 0.6924721193700198, 0.5666014542065752, 0.2653894909394454, 0.5232480534666997, 0.09394051075844168, 0.5759464955561793, 0.9292961975762141, 0.31856895245132366, 0.6674103799636817, 0.13179786240439217, 0.7163272041185655, 0.2894060929472011, 0.18319136200711683, 0.5865129348100832, 0.020107546187493552, 0.8289400292173631, 0.004695476192547066])
...
list([0.5488135039273248, 0.7151893663724195, 0.6027633760716439, 0.5448831829968969, 0.4236547993389047, 0.6458941130666561, 0.4375872112626925, 0.8917730007820798, 0.9636627605010293, 0.3834415188257777, 0.7917250380826646, 0.5288949197529045, 0.5680445610939323, 0.925596638292661, 0.07103605819788694, 0.08712929970154071, 0.02021839744032572, 0.832619845547938, 0.7781567509498505, 0.8700121482468192, 0.978618342232764, 0.7991585642167236, 0.46147936225293185, 0.7805291762864555, 0.11827442586893322, 0.6399210213275238, 0.1433532874090464, 0.9446689170495839, 0.5218483217500717, 0.4146619399905236, 0.26455561210462697, 0.7742336894342167, 0.45615033221654855, 0.5684339488686485, 0.018789800436355142, 0.6176354970758771, 0.6120957227224214, 0.6169339968747569, 0.9437480785146242, 0.6818202991034834, 0.359507900573786, 0.43703195379934145, 0.6976311959272649, 0.06022547162926983, 0.6667667154456677, 0.6706378696181594, 0.2103825610738409, 0.1289262976548533, 0.31542835092418386, 0.3637107709426226, 0.5701967704178796, 0.43860151346232035, 0.9883738380592262, 0.10204481074802807, 0.2088767560948347, 0.16130951788499626, 0.6531083254653984, 0.2532916025397821, 0.4663107728563063, 0.24442559200160274, 0.15896958364551972, 0.11037514116430513, 0.6563295894652734, 0.1381829513486138, 0.1965823616800535, 0.3687251706609641, 0.8209932298479351, 0.09710127579306127, 0.8379449074988039, 0.09609840789396307, 0.9764594650133958, 0.4686512016477016, 0.9767610881903371, 0.604845519745046, 0.7392635793983017, 0.039187792254320675, 0.2828069625764096, 0.1201965612131689, 0.29614019752214493, 0.11872771895424405, 0.317983179393976, 0.41426299451466997, 0.06414749634878436, 0.6924721193700198, 0.5666014542065752, 0.2653894909394454, 0.5232480534666997, 0.09394051075844168, 0.5759464955561793, 0.9292961975762141, 0.31856895245132366, 0.6674103799636817, 0.13179786240439217, 0.7163272041185655, 0.2894060929472011, 0.18319136200711683, 0.5865129348100832, 0.020107546187493552, 0.8289400292173631, 0.004695476192547066])
list([0.008409093134105206, -0.004053284414112568, 7.326030026888475e-05, -0.003323172451928258, -0.004530687350779772, -0.005977425258606672, 0.006403673905879259, 0.0009572462295182049, 0.009286242537200451, 0.0033146804198622704, 0.001019165152683854, -0.003735858015716076, 0.0015958514995872974, 0.007626178674399853, -0.001008189981803298, -0.005622914992272854, -0.007142676040530205, 0.0036189176607877016, -0.004547593183815479, -0.007775846868753433, 0.004584384150803089, -0.0014593001687899232, -0.0021724356338381767, -0.001054807216860354, -0.006158124655485153, -0.007687584962695837, 0.0057273004204034805, -0.008095096796751022, 0.004045872017741203, -0.005266474559903145, 0.007967010140419006, -0.007006239611655474, -0.0011461457470431924, -0.002239846857264638, -0.003727403236553073, -0.0038196921814233065, -0.0008946113521233201, 0.0003634033491834998, 0.0025940861087292433, 0.00986107625067234, -0.00040067831287160516, 0.0052842251025140285, -0.003648065961897373, -0.009799609892070293, 0.0029974905773997307, -0.0028086623642593622, 0.006827087607234716, -0.003136902116239071, 0.008423320949077606, -0.0037651490420103073])
list([0.5488135039273248, 0.7151893663724195, 0.6027633760716439, 0.5448831829968969, 0.4236547993389047, 0.6458941130666561, 0.4375872112626925, 0.8917730007820798, 0.9636627605010293, 0.3834415188257777, 0.7917250380826646, 0.5288949197529045, 0.5680445610939323, 0.925596638292661, 0.07103605819788694, 0.08712929970154071, 0.02021839744032572, 0.832619845547938, 0.7781567509498505, 0.8700121482468192, 0.978618342232764, 0.7991585642167236, 0.46147936225293185, 0.7805291762864555, 0.11827442586893322, 0.6399210213275238, 0.1433532874090464, 0.9446689170495839, 0.5218483217500717, 0.4146619399905236, 0.26455561210462697, 0.7742336894342167, 0.45615033221654855, 0.5684339488686485, 0.018789800436355142, 0.6176354970758771, 0.6120957227224214, 0.6169339968747569, 0.9437480785146242, 0.6818202991034834, 0.359507900573786, 0.43703195379934145, 0.6976311959272649, 0.06022547162926983, 0.6667667154456677, 0.6706378696181594, 0.2103825610738409, 0.1289262976548533, 0.31542835092418386, 0.3637107709426226, 0.5701967704178796, 0.43860151346232035, 0.9883738380592262, 0.10204481074802807, 0.2088767560948347, 0.16130951788499626, 0.6531083254653984, 0.2532916025397821, 0.4663107728563063, 0.24442559200160274, 0.15896958364551972, 0.11037514116430513, 0.6563295894652734, 0.1381829513486138, 0.1965823616800535, 0.3687251706609641, 0.8209932298479351, 0.09710127579306127, 0.8379449074988039, 0.09609840789396307, 0.9764594650133958, 0.4686512016477016, 0.9767610881903371, 0.604845519745046, 0.7392635793983017, 0.039187792254320675, 0.2828069625764096, 0.1201965612131689, 0.29614019752214493, 0.11872771895424405, 0.317983179393976, 0.41426299451466997, 0.06414749634878436, 0.6924721193700198, 0.5666014542065752, 0.2653894909394454, 0.5232480534666997, 0.09394051075844168, 0.5759464955561793, 0.9292961975762141, 0.31856895245132366, 0.6674103799636817, 0.13179786240439217, 0.7163272041185655, 0.2894060929472011, 0.18319136200711683, 0.5865129348100832, 0.020107546187493552, 0.8289400292173631, 0.004695476192547066])].
TypeError: float() argument must be a string or a number, not 'list'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):

File "/home/rjd02/.conda/envs/rjd02_yangbo_newtensor/lib/python3.7/site-packages/tensorflow_core/python/data/ops/dataset_ops.py", line 601, in generator_py_func
ret, dtype=dtype.as_numpy_dtype))

File "/home/rjd02/.conda/envs/rjd02_yangbo_newtensor/lib/python3.7/site-packages/tensorflow_core/python/ops/script_ops.py", line 181, in _convert
result = np.asarray(value, dtype=dtype, order="C")

File "/home/rjd02/.conda/envs/rjd02_yangbo_newtensor/lib/python3.7/site-packages/numpy/core/_asarray.py", line 85, in asarray
return array(a, dtype, copy=False, order=order)

ValueError: setting an array element with a sequence.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

File "/home/rjd02/.conda/envs/rjd02_yangbo_newtensor/lib/python3.7/site-packages/tensorflow_core/python/ops/script_ops.py", line 221, in call
ret = func(*args)

File "/home/rjd02/.conda/envs/rjd02_yangbo_newtensor/lib/python3.7/site-packages/tensorflow_core/python/data/ops/dataset_ops.py", line 606, in generator_py_func
"element was %s." % (dtype.name, ret))
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/rjd02/.conda/envs/rjd02_yangbo_newtensor/lib/python3.7/site-packages/tensorflow_core/python/data/ops/dataset_ops.py", line 601, in generator_py_func
ret, dtype=dtype.as_numpy_dtype))
File "/home/rjd02/.conda/envs/rjd02_yangbo_newtensor/lib/python3.7/site-packages/tensorflow_core/python/ops/script_ops.py", line 181, in _convert
result = np.asarray(value, dtype=dtype, order="C")

File "/home/rjd02/.conda/envs/rjd02_yangbo_newtensor/lib/python3.7/site-packages/numpy/core/_asarray.py", line 85, in asarray
return array(a, dtype, copy=False, order=order)

ValueError: setting an array element with a sequence.

How can I fix the bug?

May I get your email ?

The previous link is dead T_T. I want to communicate some questions about java code processing. Greatly appreciated!

Where is the code for Java Data Preprocessing

With the same idea like parsing c/c++ above,we construct all relationships in different edges using [soot] and [jdt].

$ cd NISL_TIFS2021/EdgesGenerationAndDataPreprocess/Java_jdt_AST_CDFG/src/main/java/yoshikihigo/tinypdg/
$ java Main.java sourceFilePath savafilePath

I can't find the related file in the project.

Java files processing

Could you please provide the data processing code for Java files? What's the " EdgesGenerationAndDataPreprocess"?

Loading pre-trained model weights fails.

Hello! When I try to follow the command CUDA_VISIBLE_DEVICES=2 python test.py GGNN GraphBinaryClassification ../data/data/data/cve/badall --storedModel_path "./trained_model/GGNN_GraphBinaryClassification__2023-02-01_05-36-00_f1 = 0.800_best.pkl", one issue occurred. The details are as follows:
image
It mentioned error! in traububg_utils.py line199. Does it mean cli_data_hyperparameter_overrides=args.data_param_override, line 199 in file training_utils.py? So how can I solve this problem? And is this the reason why loading pre-trained model weights fails? Looking forward to your reply : ).

dataset request

Hi Huant,

Thanks for your time and attention. We have sent u the dataset application email but didn't receive any reply. Is there any updates?

Kind regards,
Junyang

RuntimeError: you must first build vocabulary before training the model

When I try to run the code, I get the following error:

Traceback (most recent call last):
File "train.py", line 60, in
run()
File "train.py", line 35, in run
lambda:run_train_from_args(args, hyperdrive_hyperparameter_overrides), args.debug
File "/home/yang/Desktop/tensor/lib/python3.7/site-packages/dpu_utils/utils/debughelper.py", line 21, in run_and_debug
func()
File "train.py", line 35, in
lambda:run_train_from_args(args, hyperdrive_hyperparameter_overrides), args.debug
File "/home/yang/Desktop/FUNDED_NISL/FUNDED/cli_utils/training_utils.py", line 249, in run_train_from_args
DataSplit.Preprocess(args.data_path)
File "/home/yang/Desktop/FUNDED_NISL/FUNDED/data/data/data_preprocess.py", line 531, in Preprocess
w2v(path, cwetype)
File "/home/yang/Desktop/FUNDED_NISL/FUNDED/data/data/data_preprocess.py", line 67, in w2v
negative=3, sample=0.001, hs=1, workers=4)
File "/home/yang/Desktop/tensor/lib/python3.7/site-packages/gensim/models/word2vec.py", line 783, in init
fast_version=FAST_VERSION)
File "/home/yang/Desktop/tensor/lib/python3.7/site-packages/gensim/models/base_any2vec.py", line 763, in init
end_alpha=self.min_alpha, compute_loss=compute_loss)
File "/home/yang/Desktop/tensor/lib/python3.7/site-packages/gensim/models/word2vec.py", line 910, in train
queue_factor=queue_factor, report_delay=report_delay, compute_loss=compute_loss, callbacks=callbacks)
File "/home/yang/Desktop/tensor/lib/python3.7/site-packages/gensim/models/base_any2vec.py", line 1081, in train
**kwargs)
File "/home/yang/Desktop/tensor/lib/python3.7/site-packages/gensim/models/base_any2vec.py", line 536, in train
total_words=total_words, **kwargs)
File "/home/yang/Desktop/tensor/lib/python3.7/site-packages/gensim/models/base_any2vec.py", line 1187, in _check_training_sanity
raise RuntimeError("you must first build vocabulary before training the model")
RuntimeError: you must first build vocabulary before training the model

I find the faulty line of code:

model = Word2Vec(words, min_count=1, size=100, sg=1, window=5,negative=3, sample=0.001, hs=1, workers=4)

But shouldn't the model automatically build a vocabulary during training?

Can someone help me with this problem

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.